Fix creation of stamp-h by gdb's configure script
[deliverable/binutils-gdb.git] / gdb / gdbserver / ChangeLog
1 2019-10-17 Tom Tromey <tromey@adacore.com>
2
3 * configure: Rebuild.
4 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
5 in AC_CONFIG_FILES invocation.
6 * Makefile.in (stamp-h, Makefile): Use new-style config.status
7 invocation.
8
9 2019-10-16 Christian Biesinger <cbiesinger@google.com>
10
11 * server.c: Include xml-builtin.h.
12 (get_xml_features): Don't declare xml_builtins here.
13
14 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
15
16 * Makefile.in: Remove references to vec-ipa.o.
17
18 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
19
20 * Makefile.in: Remove references to vec.c.
21
22 2019-10-02 Christian Biesinger <cbiesinger@google.com>
23
24 * server.c (server_waiting): Change to bool.
25 (extended_protocol): Likewise.
26 (response_needed): Likewise.
27 (exit_requested): Likewise.
28 (run_once): Likewise.
29 (report_no_resumed): Likewise.
30 (non_stop): Likewise.
31 (disable_packet_vCont): Likewise.
32 (disable_packet_Tthread): Likewise.
33 (disable_packet_qC): Likewise.
34 (disable_packet_qfThreadInfo): Likewise.
35 (handle_general_set): Update.
36 (handle_detach): Update.
37 (handle_monitor_command): Update.
38 (handle_query): Update.
39 (captured_main): Update.
40 (process_serial_event): Update.
41 * server.h (server_waiting): Change to bool.
42 (disable_packet_vCont): Likewise.
43 (disable_packet_Tthread): Likewise.
44 (disable_packet_qC): Likewise.
45 (disable_packet_qfThreadInfo): Likewise.
46 (run_once): Likewise.
47 (non_stop): Likewise.
48 * target.c (target_stop_and_wait): Update.
49
50 2019-10-02 Tom Tromey <tromey@adacore.com>
51
52 * Makefile.in (SFILES): Add common-inferior.c.
53 (OBS): Add common-inferior.o.
54 * server.c (startup_with_shell): Don't define.
55
56 2019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
57
58 * linux-low.c (linux_low_read_btrace): Update for change to
59 std::vector.
60
61 2019-09-20 Christian Biesinger <cbiesinger@google.com>
62
63 * debug.c (debug_threads): Remove comment in favor of the header.
64 * debug.h (using_threads): Add declaration.
65 (debug_threads): Add comment.
66 * linux-aarch64-low.c: Include debug.h and remove declaration of
67 debug_threads.
68 * nto-low.c: Likewise.
69 * remote-utils.c: Likewise.
70 * thread-db.c: Likewise.
71
72 2019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
73
74 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
75 and powerpc-cell64l-ipa.o.
76 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
77 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
78 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
79 (spu*-*-*): Remove.
80
81 * spu-low.c: Remove file.
82
83 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
84 (parse_spufs_run): Remove.
85 (ppc_get_pc): Remove Cell/B.E. support.
86 (ppc_set_pc): Likewise.
87 (ppc_breakpoint_at): Likewise.
88 (ppc_arch_setup): Likewise.
89 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
90 tdesc_powerpc_cell32l.
91 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
92 or init_registers_powerpc_cell32l.
93 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
94 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
95 or init_registers_powerpc_cell32l.
96 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
97 (init_registers_powerpc_cell32l): Remove prototype.
98 (init_registers_powerpc_cell64l): Likewise.
99
100 * target.h (struct target_ops): Remove qxfer_spu member.
101 * server.c (handle_qxfer_spu): Remove.
102 (qxfer_packets): Remove entry for "spu".
103 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
104 * linux-low.c (SPUFS_MAGIC): Remove.
105 (spu_enumerate_spu_ids): Remove.
106 (linux_qxfer_spu): Remove.
107 (linux_target_ops): Remove qxfer_spu member.
108 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
109 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
110 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
111
112 2019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
113
114 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
115 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
116 * config.in: Regenerate.
117 * configure: Regenerate.
118
119 2019-08-15 Tom Tromey <tromey@adacore.com>
120
121 * target.c (target_write_memory): Use gdb::byte_vector.
122
123 2019-08-15 Tom Tromey <tromey@adacore.com>
124
125 * tracepoint.c (write_inferior_data_pointer)
126 (write_inferior_integer, write_inferior_int8)
127 (write_inferior_uinteger, m_tracepoint_action_download)
128 (r_tracepoint_action_download, x_tracepoint_action_download)
129 (l_tracepoint_action_download, clear_inferior_trace_buffer)
130 (download_agent_expr, download_tracepoint_1)
131 (download_trace_state_variables, upload_fast_traceframes): Update.
132 * server.c (gdb_write_memory): Update.
133 * remote-utils.c (relocate_instruction): Update.
134 * proc-service.c (ps_pdwrite): Update.
135 * mem-break.c (remove_memory_breakpoint)
136 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
137 (uninsert_fast_tracepoint_jumps_at)
138 (reinsert_fast_tracepoint_jumps_at): Update.
139 * linux-x86-low.c (append_insns)
140 (i386_install_fast_tracepoint_jump_pad)
141 (amd64_write_goto_address, i386_write_goto_address): Update.
142 * linux-s390-low.c (append_insns, s390_write_goto_address):
143 Update.
144 * linux-ppc-low.c (ppc_relocate_instruction)
145 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
146 (ppc_write_goto_address): Update.
147 * linux-aarch64-low.c (append_insns): Update.
148 * target.h (struct target_ops): Update.
149 (write_inferior_memory): Don't declare.
150 * target.c (target_write_memory): Rename from
151 write_inferior_memory. Remove old target_write_memory.
152
153 2019-08-15 Tom Tromey <tromey@adacore.com>
154
155 * target.c (write_inferior_memory): Use std::vector.
156
157 2019-08-06 Frank Ch. Eigler <fche@redhat.com>
158
159 PR build/24886
160 * configure.ac: Drop enable-libmcheck support.
161 * configure, config.in: Rebuild.
162 * acinclude.m4: Don't include it.
163
164 2019-07-19 Alan Hayward <alan.hayward@arm.com>
165
166 * configure.srv: Remove Arm xml files.
167
168 2019-07-19 Alan Hayward <alan.hayward@arm.com>
169
170 * configure.srv: Add new files. Remove xml generated files.
171 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
172 registers.
173 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
174 * linux-aarch32-tdesc.c: New file.
175 * linux-aarch32-tdesc.h: New file.
176 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
177 * linux-arm-low.c (init_registers_arm, tdesc_arm)
178 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
179 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
180 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
181 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
182 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
183 (arm_read_description): Call arm_linux_read_description.
184 (initialize_low_arch): Don't init registers.
185 * linux-arm-tdesc.c: New file.
186 * linux-arm-tdesc.h: New file.
187
188 2019-07-10 Alan Hayward <alan.hayward@arm.com>
189
190 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
191 Move counter inside for.
192 (arm_read_description): Check ptrace earlier.
193 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
194
195 2019-07-09 Tom Tromey <tom@tromey.com>
196
197 * configure: Rebuild.
198 * configure.ac: Change common to gdbsupport.
199 * acinclude.m4: Change common to gdbsupport.
200 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
201 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
202 common to gdbsupport.
203 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
204 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
205 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
206 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
207 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
208 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
209 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
210 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
211 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
212 common to gdbsupport.
213
214 2019-07-04 Alan Hayward <alan.hayward@arm.com>
215
216 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
217 defines.
218 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
219
220 2019-07-04 Alan Hayward <alan.hayward@arm.com>
221
222 * configure.srv: Remove legacy xml.
223 * linux-aarch64-low.c (initialize_low_arch): Remove
224 initialize_low_tdesc call.
225 * linux-aarch64-tdesc-selftest.c: Remove file.
226 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
227 * linux-x86-low.c (initialize_low_arch): Remove
228 initialize_low_tdesc call.
229 * linux-x86-tdesc-selftest.c: Remove file.
230 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
231
232 2019-06-20 Tom de Vries <tdevries@suse.de>
233
234 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
235 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
236
237 2019-06-19 Tom de Vries <tdevries@suse.de>
238
239 * debug.h (debug_write): Change return type to ssize_t.
240 * debug.c (debug_write): Same.
241
242 2019-06-14 Tom Tromey <tom@tromey.com>
243
244 * configure.ac: Use new path to gnulib.
245 * configure: Rebuild.
246 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
247 to gnulib.
248
249 2019-06-11 Tom Tromey <tom@tromey.com>
250
251 * Makefile.in (SFILES): Add alloc.c.
252 (OBS): Add alloc.o.
253 (IPA_OBJS): Add alloc-ipa.o.
254 (alloc-ipa.o): New target.
255 (%.o: ../%.c): New pattern rule.
256
257 2019-06-10 Tom Tromey <tromey@adacore.com>
258
259 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
260 end warning with a newline.
261 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
262 newline.
263 * thread-db.c (attach_thread): Don't end warning with a newline.
264 (thread_db_notice_clone): Likewise.
265 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
266 newline.
267 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
268 end warning with a newline.
269
270 2019-06-04 Pedro Alves <palves@redhat.com>
271
272 * server.c (captured_main): Use make_unique_xstrdup.
273
274 2019-06-02 Tom Tromey <tom@tromey.com>
275
276 * gdbreplay.c (fromhex): Remove.
277 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
278
279 2019-05-29 Tom Tromey <tromey@adacore.com>
280
281 * configure: Rebuild.
282
283 2019-05-06 Kevin Buettner <kevinb@redhat.com>
284
285 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
286 sign extension code on 32-bit builds.
287
288 2019-05-03 Eli Zaretskii <eliz@gnu.org>
289
290 * remote-utils.c:
291 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
292
293 2019-04-19 Tom Tromey <tom@tromey.com>
294
295 * server.c (struct vstop_notif): Derive from notif_event.
296 <base>: Remove.
297 (queue_stop_reply): Update.
298 (remove_all_on_match_ptid): Change type. Rewrite.
299 (discard_queued_stop_replies): Rewrite.
300 (in_queued_stop_replies_ptid): Change type.
301 (in_queued_stop_replies): Rewrite.
302 (notif_stop): Update.
303 (queue_stop_reply_callback): Update.
304 (captured_main): Don't call initialize_notif.
305 (push_stop_notification): Update.
306 * notif.c (notif_write_event, handle_notif_ack)
307 (notif_event_enque, notif_push): Update.
308 (notif_event_xfree, initialize_notif): Remove.
309 * notif.h (struct notif_event): Include <list>, not
310 "common/queue.h".
311 (struct notif_server) <queue>: Now a std::list.
312 (notif_event_p): Remove typedef.
313 (initialize_notif): Don't declare.
314 (struct notif_event): Add virtual destructor.
315
316 2019-04-17 Alan Hayward <alan.hayward@arm.com>
317
318 * ax.c (ax_vdebug): Call debug_printf.
319 * debug.c (debug_write): New function.
320 * debug.h (debug_write): New declaration.
321 * linux-low.c (sigchld_handler): Call debug_write.
322
323 2019-04-17 Alan Hayward <alan.hayward@arm.com>
324
325 * debug.c (debug_set_output): New function.
326 (debug_vprintf): Send output to debug_file.
327 (debug_flush): Likewise.
328 * debug.h (debug_set_output): New declaration.
329 * server.c (handle_monitor_command): Add debug-file option.
330 (captured_main): Likewise.
331
332 2019-04-17 Alan Hayward <alan.hayward@arm.com>
333
334 * debug.c (remote_debug): Add definition.
335 * debug.h (remote_debug): Add declaration.
336 * hostio.c (remote_debug): Remove declaration.
337 * remote-utils.c (struct ui_file): Likewise.
338 (remote_debug): Likewise.
339 * remote-utils.h (remote_debug): Likewise,
340 * server.c (remote_debug): Remove definition.
341
342 2019-04-10 Kevin Buettner <kevinb@redhat.com>
343
344 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
345 when using a 64-bit gdbserver.
346
347 2019-04-09 Tom Tromey <tromey@adacore.com>
348
349 * linux-low.c (select_event_lwp): Use find_thread_in_random.
350
351 2019-04-08 Tom Tromey <tom@tromey.com>
352
353 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
354 throw.
355 (linux_resume_one_lwp): Likewise.
356
357 2019-04-08 Tom Tromey <tom@tromey.com>
358
359 * gdbreplay.c: Update.
360 * linux-low.c: Update.
361 * server.c: Update.
362
363 2019-04-08 Tom Tromey <tom@tromey.com>
364
365 * server.c: Use C++ exception handling.
366 * linux-low.c: Use C++ exception handling.
367 * gdbreplay.c: Use C++ exception handling.
368
369 2019-04-08 Tom Tromey <tom@tromey.com>
370
371 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
372 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
373 (captured_main, main): Update.
374 * gdbreplay.c (main): Update.
375
376 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
377
378 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
379 value in argument pointer, return 1 if the entry is found and 0
380 otherwise. Move comment.
381 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
382 * linux-low.h (linux_get_auxv): Declare.
383 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
384
385 2019-04-05 Tom Tromey <tromey@adacore.com>
386
387 * server.c (gdbserver_usage): Use upper-case for metasyntactic
388 variables.
389
390 2019-03-28 Alan Hayward <alan.hayward@arm.com>
391
392 * linux-low.c (AT_HWCAP2): Add define if not already included.
393
394 2019-03-26 Alan Hayward <alan.hayward@arm.com>
395
396 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
397 (aarch64_arch_setup): Call linux_get_hwcap.
398 * linux-arm-low.c (arm_get_hwcap): Remove function.
399 (arm_read_description): Call linux_get_hwcap.
400 * linux-low.c (linux_get_auxv): New function.
401 (linux_get_hwcap): Likewise.
402 (linux_get_hwcap2): Likewise.
403 * linux-low.h (linux_get_hwcap): New declaration.
404 (linux_get_hwcap2): Likewise.
405 * linux-ppc-low.c (ppc_get_auxv): Remove function.
406 (ppc_arch_setup): Call linux_get_hwcap.
407 * linux-s390-low.c (s390_get_hwcap): Remove function.
408 (s390_arch_setup): Call linux_get_hwcap.
409
410 2019-03-22 Alan Hayward <alan.hayward@arm.com>
411 Jiong Wang <jiong.wang@arm.com>
412
413 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
414 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
415 to fail.
416 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
417
418 2019-03-22 Alan Hayward <alan.hayward@arm.com>
419 Jiong Wang <jiong.wang@arm.com>
420
421 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
422 (aarch64_get_hwcap): New function.
423 (aarch64_arch_setup): Read APIA hwcap.
424
425 2019-03-22 Alan Hayward <alan.hayward@arm.com>
426 Jiong Wang <jiong.wang@arm.com>
427
428 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
429 (initialize_low_tracepoint): Likewise.
430 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
431 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
432 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
433 (aarch64_linux_read_description): Likewise.
434 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
435
436 2019-03-12 John Baldwin <jhb@FreeBSD.org>
437
438 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
439 i386_create_target_description for 'segments' parameter.
440 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
441 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
442 * win32-i386-low.c (i386_arch_setup): Likewise.
443
444 2019-03-12 Tom Tromey <tromey@adacore.com>
445
446 * linux-low.c (iterate_over_lwps): Update.
447
448 2019-03-06 Tom Tromey <tom@tromey.com>
449
450 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
451 (captured_main): Use SCOPE_EXIT.
452
453 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
454
455 * configure.srv: Use '$enable_unittest' instead of '$development'
456 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
457 case.
458
459 2019-02-27 Tom Tromey <tromey@adacore.com>
460
461 * gdbreplay.c (logchar): Handle \r\n.
462
463 2019-02-07 Alan Hayward <alan.hayward@arm.com>
464
465 * linux-low.c (linux_attach): Add process before lwp.
466 * server.c (attach_inferior): Check if already attached.
467
468 2019-02-07 Tom Tromey <tom@tromey.com>
469
470 * x86-tdesc.h: Rename include guard.
471 * x86-low.h: Add include guard.
472 * wincecompat.h: Rename include guard.
473 * win32-low.h: Add include guard.
474 * utils.h: Rename include guard.
475 * tracepoint.h: Rename include guard.
476 * tdesc.h: Rename include guard.
477 * target.h: Rename include guard.
478 * server.h: Rename include guard.
479 * remote-utils.h: Rename include guard.
480 * regcache.h: Rename include guard.
481 * nto-low.h: Rename include guard.
482 * notif.h: Add include guard.
483 * mem-break.h: Rename include guard.
484 * lynx-low.h: Add include guard.
485 * linux-x86-tdesc.h: Add include guard.
486 * linux-s390-tdesc.h: Add include guard.
487 * linux-ppc-tdesc-init.h: Add include guard.
488 * linux-low.h: Add include guard.
489 * linux-aarch64-tdesc.h: Add include guard.
490 * linux-aarch32-low.h: Add include guard.
491 * inferiors.h: Rename include guard.
492 * i387-fp.h: Rename include guard.
493 * hostio.h: Rename include guard.
494 * gdbthread.h: Rename include guard.
495 * gdb_proc_service.h: Rename include guard.
496 * event-loop.h: Rename include guard.
497 * dll.h: Rename include guard.
498 * debug.h: Rename include guard.
499 * ax.h: Rename include guard.
500
501 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
502
503 PR gdb/23985
504 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
505 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
506
507 2019-01-25 Tom Tromey <tom@tromey.com>
508
509 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
510
511 2019-01-25 Tom Tromey <tom@tromey.com>
512
513 * win32-low.c: Fix common/ includes.
514 * win32-i386-low.c: Fix common/ includes.
515 * tracepoint.c: Fix common/ includes.
516 * thread-db.c: Fix common/ includes.
517 * target.h: Fix common/ includes.
518 * symbol.c: Fix common/ includes.
519 * spu-low.c: Fix common/ includes.
520 * server.h: Fix common/ includes.
521 * server.c: Fix common/ includes.
522 * remote-utils.c: Fix common/ includes.
523 * regcache.h: Fix common/ includes.
524 * regcache.c: Fix common/ includes.
525 * nto-x86-low.c: Fix common/ includes.
526 * notif.h: Fix common/ includes.
527 * mem-break.h: Fix common/ includes.
528 * lynx-low.c: Fix common/ includes.
529 * lynx-i386-low.c: Fix common/ includes.
530 * linux-x86-tdesc-selftest.c: Fix common/ includes.
531 * linux-x86-low.c: Fix common/ includes.
532 * linux-low.c: Fix common/ includes.
533 * inferiors.h: Fix common/ includes.
534 * i387-fp.c: Fix common/ includes.
535 * hostio.c: Fix common/ includes.
536 * hostio-errno.c: Fix common/ includes.
537 * gdbthread.h: Fix common/ includes.
538 * gdbreplay.c: Fix common/ includes.
539 * fork-child.c: Fix common/ includes.
540 * event-loop.c: Fix common/ includes.
541 * ax.c:
542 (enum gdb_agent_op): Fix common/ includes.
543
544 2019-01-21 Tom Tromey <tom@tromey.com>
545
546 * tracepoint.c: Fix includes.
547 * remote-utils.c: Fix includes.
548 * linux-x86-low.c: Fix includes.
549
550 2019-01-01 Joel Brobecker <brobecker@adacore.com>
551
552 * gdbreplay.c (gdbreplay_version): Update copyright year in
553 version message.
554 * server.c (gdbserver_version): Likewise.
555
556 2018-12-05 Alan Hayward <alan.hayward@arm.com>
557
558 * linux-low.c (add_lwp): Switch ordering.
559
560 2018-11-29 Tom Tromey <tom@tromey.com>
561
562 * win32-low.c (win32_join): Take pid, not process.
563 * target.h (struct target_ops) <join>: Change argument type.
564 (join_inferior): Change argument name.
565 * spu-low.c (spu_join): Take pid, not process.
566 * server.c (handle_detach): Preserve pid before destroying
567 process.
568 * lynx-low.c (lynx_join): Take pid, not process.
569 * linux-low.c (linux_join): Take pid, not process.
570
571 2018-11-23 Alan Hayward <alan.hayward@arm.com>
572
573 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
574 (aarch64_cannot_fetch_register): Likewise.
575 (struct linux_target_ops): Update references.
576
577 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
578
579 * linux-ppc-low.c: Include nat/linux-ptrace.h.
580
581 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
582
583 * configure.srv (ipa_ppc_linux_regobj): Add
584 powerpc-isa207-htm-vsx32l-ipa.o and
585 powerpc-isa207-htm-vsx64l-ipa.o.
586 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
587 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
588 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
589 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
590 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
591 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
592 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
593 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
594 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
595 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
596 (init_registers_powerpc_isa207_htm_vsx32l)
597 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
598 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
599 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
600 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
601 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
602 (ppc_store_tm_ctarregset): New functions.
603 (ppc_regsets): Add entries for HTM regsets.
604 (ppc_arch_setup): Set htm in features struct when needed. Set
605 sizes for the HTM regsets.
606 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
607 (initialize_low_arch): Call
608 init_registers_powerpc_isa207_htm_vsx32l and
609 init_registers_powerpc_isa207_htm_vsx64l.
610 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
611 PPC_TDESC_ISA207_HTM_VSX.
612 (initialize_low_tracepoint): Call
613 init_registers_powerpc_isa207_htm_vsx32l and
614 init_registers_powerpc_isa207_htm_vsx64l.
615
616 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
617
618 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
619 rs6000/power-linux-pmu.xml to srv_xmlfiles.
620 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
621 (ppc_store_pmuregset): New functions.
622 (ppc_regsets): Add entries for ebb and pmu regsets.
623 (ppc_arch_setup): Set isa207 in features struct if the ebb and
624 pmu regsets are available. Set sizes for these regsets.
625
626 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
627
628 * configure.srv (ipa_ppc_linux_regobj): Add
629 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
630 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
631 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
632 rs6000/powerpc-isa207-vsx32l.xml, and
633 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
634 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
635 <PPC_TDESC_ISA207_VSX>: New enum value.
636 (init_registers_powerpc_isa207_vsx32l): Declare.
637 (init_registers_powerpc_isa207_vsx64l): Declare.
638 * linux-ppc-low.c (ppc_fill_tarregset): New function.
639 (ppc_store_tarregset): New function.
640 (ppc_regsets): Add entry for the TAR regset.
641 (ppc_arch_setup): Set isa207 in features struct when needed. Set
642 size for the TAR regsets.
643 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
644 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
645 and init_registers_powerpc_isa207_vsx64l.
646 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
647 (initialize_low_tracepoint): Call
648 init_registers_powerpc_isa207_vsx32l and
649 init_registers_powerpc_isa207_vsx64l.
650
651 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
652 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
653
654 * configure.srv (ipa_ppc_linux_regobj): Add
655 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
656 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
657 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
658 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
659 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
660 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
661 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
662 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
663 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
664 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
665 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
666 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
667 (ppc_hwcap): Add comment.
668 (ppc_hwcap2): New global.
669 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
670 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
671 (ppc_regsets): Add entries for the DSCR and PPR regsets.
672 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
673 when needed. Set sizes for the the DSCR and PPR regsets.
674 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
675 (initialize_low_arch): Call
676 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
677 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
678 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
679 PPC_TDESC_ISA205_PPR_DSCR_VSX.
680 (initialize_low_tracepoint): Call
681 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
682 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
683
684 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
685
686 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
687
688 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
689 Simon Marchi <simark@simark.ca>
690
691 * acinclude.m4: Include "../selftest.m4".
692 * configure: Regenerate.
693 * configure.ac: Use "GDB_AC_SELFTEST".
694 * configure.srv: Use "$enable_unittests" instead of
695 "$development" when checking whether unit tests have been
696 enabled.
697 * server.c (captured_main): Update message informing that
698 selftests have been disabled.
699
700 2018-10-04 Tom Tromey <tom@tromey.com>
701
702 * configure: Rebuild.
703
704 2018-10-04 Tom Tromey <tom@tromey.com>
705
706 * server.c (handle_status): Rename inner "thread".
707 (process_serial_event): Declare "res" in 'm' case.
708 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
709 (iterate_over_lwps): Rename inner "thread".
710 (linux_qxfer_libraries_svr4): Rename inner "len".
711 * gdbthread.h (find_thread_in_random): Rename inner "thread".
712
713 2018-10-01 Gary Benson <gbenson@redhat.com>
714
715 * gdb_proc_service.h: Moved common code to
716 common/gdb_proc_service.h.
717
718 2018-10-01 Gary Benson <gbenson@redhat.com>
719
720 * gdb_proc_service.h: Synchronize comments and whitespace with
721 GDB's version of this file.
722
723 2018-09-25 Tom Tromey <tom@tromey.com>
724
725 * configure: Rebuild.
726 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
727
728 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
729
730 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
731 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
732 ($(IPA_LIB)): Sort IPA_OBJS.
733
734 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
735
736 * Makefile.in: Remove references to $(ADD_DEPS).
737
738 2018-09-16 Tom Tromey <tom@tromey.com>
739
740 * remote-utils.c (remote_open): Use GNU style for metasyntactic
741 variables.
742 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
743 variables.
744
745 2018-09-05 Tom Tromey <tom@tromey.com>
746
747 * configure: Rebuild.
748
749 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
750
751 PR build/23399
752 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
753
754 2018-08-27 Tom Tromey <tom@tromey.com>
755
756 PR build/23087:
757 * configure: Rebuild.
758
759 2018-08-27 Tom Tromey <tom@tromey.com>
760
761 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
762 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
763 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
764 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
765 (s390x_emit_stack_adjust): Add casts to unsigned char.
766
767 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
768
769 PR gdb/23374
770 PR gdb/23375
771 * server.h (struct client_state) <disable_randomization>:
772 Initialize to 1.
773
774 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
775
776 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
777 variable.
778 (mips_supply_ptrace_register): Likewise.
779
780 2018-07-22 Tom Tromey <tom@tromey.com>
781
782 * configure: Rebuild.
783
784 2018-07-22 Tom Tromey <tom@tromey.com>
785
786 * win32-low.c (win32_create_inferior): Remove unused variables.
787 * gdbreplay.c (remote_open): Remove unused variable.
788 * remote-utils.c (remote_prepare): Remove unused variable.
789 * x86-tdesc.h (X86_TDESC_H): Define.
790 (amd64_expedite_regs): Define conditionally.
791 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
792 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
793 * remote-utils.c (readchar): Remove unused variable.
794
795 2018-07-13 Pedro Alves <palves@redhat.com>
796
797 * linux-low.c (linux_kill): Change parameter to process_info
798 pointer instead of pid. Adjust.
799 * lynx-low.c (lynx_kill): Likewise.
800 * nto-low.c (nto_kill): Likewise.
801 * spu-low.c (spu_kill): Likewise.
802 * win32-low.c (win32_kill): Likewise.
803 * server.c (handle_v_kill, kill_inferior_callback)
804 (detach_or_kill_for_exit): Adjust.
805 * target.c (kill_inferior): Change parameter to process_info
806 pointer instead of pid. Adjust.
807 * target.h (struct target_ops) <kill>: Change parameter to
808 process_info pointer instead of pid. Adjust all implementations
809 and callers.
810 (kill_inferior): Likewise.
811
812 2018-07-13 Pedro Alves <palves@redhat.com>
813
814 * linux-low.c (linux_detach, linux_join): Change parameter to
815 process_info pointer instead of pid. Adjust.
816 * lynx-low.c (lynx_detach, lynx_join): Likewise.
817 * nto-low.c (nto_detach): Likewise.
818 * spu-low.c (spu_detach, spu_join): Likewise.
819 * win32-low.c (win32_detach, win32_join): Likewise.
820 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
821 * target.h (struct target_ops) <detach, join>: Change parameter to
822 process_info pointer instead of pid. Adjust all implementations
823 and callers.
824 (detach_inferior, join_inferior): Rename 'pid' parameter to
825 'proc'.
826
827 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
828 Jan Kratochvil <jan.kratochvil@redhat.com>
829 Paul Fertser <fercerpav@gmail.com>
830 Tsutomu Seki <sekiriki@gmail.com>
831
832 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
833 (OBS): Add 'common/netstuff.o'.
834 (GDBREPLAY_OBS): Likewise.
835 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
836 (remote_open): Implement support for IPv6
837 connections.
838 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
839 and 'wspiapi.h'.
840 (handle_accept_event): Accept connections from IPv6 sources.
841 (remote_prepare): Handle IPv6-style hostnames; implement
842 support for IPv6 connections.
843 (remote_open): Implement support for printing connections from
844 IPv6 sources.
845
846 2018-07-11 Pedro Alves <palves@redhat.com>
847
848 PR gdb/23377
849 * mem-break.c (any_persistent_commands): Add process_info
850 parameter and use it instead of relying on the current process.
851 Change return type to bool.
852 * mem-break.h (any_persistent_commands): Add process_info
853 parameter and change return type to bool.
854 * server.c (handle_detach): Remove require_running_or_return call.
855 Look up the process_info for the process we're about to detach.
856 If not found, return back error to GDB. Adjust
857 any_persistent_commands call to pass down a process pointer.
858
859 2018-07-11 Pedro Alves <palves@redhat.com>
860
861 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
862 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
863 instead of collect_register_by_name.
864 * regcache.c (regcache_raw_get_unsigned_by_name): New.
865 * regcache.h (regcache_raw_get_unsigned_by_name): New.
866
867 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
868 Pedro Alves <palves@redhat.com>
869
870 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
871
872 2018-07-03 Tom Tromey <tom@tromey.com>
873
874 * linux-low.c: Update.
875 * lynx-low.c: Update.
876 * mem-break.c: Update.
877 * nto-low.c: Update.
878 * remote-utils.c: Update.
879 * server.c: Update.
880 * spu-low.c: Update.
881 * target.c: Update.
882 * win32-low.c: Update.
883
884 2018-07-03 Tom Tromey <tom@tromey.com>
885
886 * server.c: Update.
887
888 2018-07-03 Tom Tromey <tom@tromey.com>
889
890 * linux-low.c: Update.
891
892 2018-07-03 Tom Tromey <tom@tromey.com>
893
894 * target.c: Update.
895
896 2018-07-03 Tom Tromey <tom@tromey.com>
897
898 * linux-low.c: Update.
899 * linux-mips-low.c: Update.
900 * lynx-low.c: Update.
901 * nto-low.c: Update.
902 * remote-utils.c: Update.
903 * server.c: Update.
904 * spu-low.c: Update.
905 * target.c: Update.
906 * thread-db.c: Update.
907
908 2018-07-03 Tom Tromey <tom@tromey.com>
909
910 * linux-low.c: Update.
911 * linux-mips-low.c: Update.
912 * lynx-low.c: Update.
913 * mem-break.c: Update.
914 * nto-low.c: Update.
915 * remote-utils.c: Update.
916 * server.c: Update.
917 * spu-low.c: Update.
918 * target.c: Update.
919 * tracepoint.c: Update.
920
921 2018-07-03 Tom Tromey <tom@tromey.com>
922
923 * linux-low.c: Update.
924 * linux-ppc-low.c: Update.
925 * linux-x86-low.c: Update.
926 * proc-service.c: Update.
927 * server.c: Update.
928 * spu-low.c: Update.
929 * thread-db.c: Update.
930 * win32-low.c: Update.
931
932 2018-07-03 Tom Tromey <tom@tromey.com>
933
934 * linux-low.c: Update.
935 * lynx-low.c: Update.
936 * nto-low.c: Update.
937 * remote-utils.c: Update.
938 * spu-low.c: Update.
939 * thread-db.c: Update.
940 * win32-low.c: Update.
941
942 2018-06-29 Joel Brobecker <brobecker@adacore.com>
943
944 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
945 parameter in call to 'amd64_create_target_description'.
946
947 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
948
949 * x86-tdesc.h: Remove executable permission flag.
950
951 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
952
953 * configure.ac: Remove AC_PREREQ, add missing quoting.
954 * configure: Re-generate.
955 * config.in: Re-generate.
956 * aclocal.m4: Re-generate.
957
958 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
959
960 * tracepoint.h (current_traceframe): Remove declaration.
961
962 2018-06-18 Alan Hayward <alan.hayward@arm.com>
963
964 * linux-aarch64-low.c (is_sve_tdesc): New function.
965 (aarch64_sve_regs_copy_to_regcache): Likewise.
966 (aarch64_sve_regs_copy_from_regcache): Likewise.
967 (aarch64_regs_info): Add SVE checks.
968 (initialize_low_arch): Initialize SVE.
969
970 2018-06-18 Alan Hayward <alan.hayward@arm.com>
971
972 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
973
974 2018-06-11 Alan Hayward <alan.hayward@arm.com>
975
976 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
977 (initialize_low_tracepoint): Likewise
978 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
979 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
980 param.
981 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
982 checks.
983 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
984
985 2018-06-11 Alan Hayward <alan.hayward@arm.com>
986
987 * server.h (PBUFSIZ): Increase size
988
989 2018-06-11 Alan Hayward <alan.hayward@arm.com>
990
991 * regcache.c (regcache::raw_compare): New function.
992 * regcache.h (regcache::raw_compare): New declaration.
993
994 2018-06-11 Alan Hayward <alan.hayward@arm.com>
995
996 * regcache.c (new_register_cache): Use new.
997 (free_register_cache): Use delete.
998 (register_data): Use const.
999 (supply_register): Move body inside regcache.
1000 (regcache::raw_supply): New override function.
1001 (collect_register): Move body inside regcache.
1002 (regcache::raw_collect): New override function.
1003 (regcache::get_register_status): New override function.
1004 * regcache.h (struct regcache): Inherit from reg_buffer_common.
1005
1006 2018-06-09 Tom Tromey <tom@tromey.com>
1007
1008 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
1009 declare queue.
1010 (event_queue): Use std::queue.
1011 (gdb_event_xfree): Remove.
1012 (initialize_event_loop, process_event, wait_for_event): Update.
1013
1014 2018-06-08 Stan Cox <scox@redhat.com>
1015
1016 * win32-low.c (win32_create_inferior): last_ptid and last_status
1017 moved to client_state.
1018
1019 2018-06-08 Pedro Alves <palves@redhat.com>
1020
1021 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
1022 common/common-exceptions.o, common/common-utils.o,
1023 common/errors.o, common/print-utils.o and utils.o.
1024 * gdbreplay.c: Include "common-defs.h" instead of the two
1025 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
1026 string.h or alloca.h.
1027 (perror_with_name): Delete.
1028 (remote_open): Use xstrdup instead of strdup.
1029 (main): Rename to ...
1030 (captured_main): ... this.
1031 (main): New.
1032
1033 2018-06-08 Tom Tromey <tom@tromey.com>
1034
1035 * linux-low.c (linux_low_read_btrace): Update.
1036
1037 2018-06-04 Stan Cox <scox@redhat.com>
1038
1039 * server.h (struct client_state): New.
1040 * server.c (cont_thread, general_thread, multi_process)
1041 (report_fork_events, report_vfork_events, report_exec_events)
1042 (report_thread_events, swbreak_feature, hwbreak_feature)
1043 (vCont_supported, disable_randomization, pass_signals)
1044 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
1045 Moved to client_state.
1046 * remote-utils.c (remote_debug, noack_mode)
1047 (transport_is_reliable): Moved to client_state.
1048 * tracepoint.c (current_traceframe): Moved to client_state.
1049
1050 Update all callers.
1051 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
1052 linux-low.c, remote-utils.h, target.c: Use client_state.
1053
1054 2018-05-31 Alan Hayward <alan.hayward@arm.com>
1055
1056 * configure.srv: Add new c/h file.
1057
1058 2018-05-31 Alan Hayward <alan.hayward@arm.com>
1059
1060 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
1061 null VQ.
1062
1063 2018-05-25 Maciej W. Rozycki <macro@mips.com>
1064
1065 * gdb.arch/mips-fpregset-core.exp: New test.
1066 * gdb.arch/mips-fpregset-core.c: New test source.
1067
1068 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
1069
1070 PR server/23198
1071 * hostio.c (require_int): Do not report overflow for integers
1072 between 0xfffffff and 0x7fffffff.
1073
1074 2018-05-22 Maciej W. Rozycki <macro@mips.com>
1075
1076 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
1077 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
1078 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
1079 functions.
1080 (the_low_target): Wire them.
1081
1082 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1083
1084 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
1085 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
1086 mode. Call collect_register_by_name with vscr using
1087 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
1088 (ppc_store_vrregset): Add and set vscr_offset variable as in
1089 ppc_fill_vrregset. Call supply_register_by_name with vscr using
1090 vscr_offset.
1091
1092 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1093
1094 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
1095 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
1096 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
1097
1098 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1099
1100 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
1101 (ppc_store_vsxregset): Likewise.
1102 (ppc_fill_vrregset): Likewise.
1103 (ppc_store_vrregset): Likewise.
1104 (ppc_fill_evrregset): Likewise.
1105 (ppc_store_evrregset): Likewise.
1106 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
1107 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
1108 needed.
1109
1110 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1111
1112 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
1113 wordsize of the inferior. Call ppc_linux_target_wordsize.
1114
1115 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1116
1117 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
1118 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
1119 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
1120 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
1121 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
1122 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
1123 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
1124 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
1125 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
1126 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
1127 (tdesc_powerpc_e500l): Remove.
1128 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
1129 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
1130 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
1131 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
1132 linux-ppc-tdesc.h.
1133 (ppc_arch_setup): Remove target description matching code. Fill a
1134 ppc_linux_features struct and call ppc_linux_match_description
1135 with it.
1136
1137 2018-05-22 Maciej W. Rozycki <macro@mips.com>
1138
1139 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
1140 width of the requested register exceeds the width of the
1141 `ptrace' data type.
1142 (mips_cannot_store_register): Likewise.
1143
1144 2018-05-21 Maciej W. Rozycki <macro@mips.com>
1145
1146 * linux-mips-low.c (mips_fetch_register): New function. Update
1147 preceding comment.
1148 (mips_store_gregset): Supply 0 rather than $restart for $zero.
1149 (the_low_target): Wire `mips_fetch_register'.
1150
1151 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1152
1153 * lynx-i386-low.c (LYNXOS_178): New macro.
1154 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
1155 the layout on LynxOS-178.
1156 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
1157 handle floating point registers that are not supported by
1158 LynxOS-178.
1159
1160 2018-05-10 Tom Tromey <tom@tromey.com>
1161
1162 * configure: Rebuild.
1163
1164 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1165
1166 PR server/23158:
1167 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
1168 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
1169 Use it to set the expedite_regs field in the given tdesc.
1170 * x86-tdesc.h: New file.
1171 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
1172 Adjust following the addition of the new expedite_regs parameter
1173 to init_target_desc.
1174 * linux-tic6x-low.c (tic6x_read_description): Likewise.
1175 * linux-x86-tdesc.c: #include "x86-tdesc.h".
1176 (i386_linux_read_description, amd64_linux_read_description):
1177 Adjust following the addition of the new expedite_regs parameter
1178 to init_target_desc.
1179 * lynx-i386-low.c: #include "x86-tdesc.h".
1180 (lynx_i386_arch_setup): Adjust following the addition of the new
1181 expedite_regs parameter to init_target_desc.
1182 * nto-x86-low.c: #include "x86-tdesc.h".
1183 (nto_x86_arch_setup): Adjust following the addition of the new
1184 expedite_regs parameter to init_target_desc.
1185 * win32-i386-low.c: #include "x86-tdesc.h".
1186 (i386_arch_setup): Adjust following the addition of the new
1187 expedite_regs parameter to init_target_desc.
1188
1189 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1190
1191 PR server/23158:
1192 * win32-low.c (win32_create_inferior): Add call to my_wait
1193 setting last_status global.
1194
1195 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1196
1197 PR server/23158:
1198 * win32-low.c (create_process): Only call gdb_tilde_expand if
1199 inferior_cwd is not NULL.
1200
1201 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
1202
1203 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
1204 registers to the cache if their values have changed.
1205 (i387_xsave_to_cache): Provide default values for x87 control
1206 registers when these features are available, but disabled.
1207 * regcache.c (supply_register_by_name_zeroed): New function.
1208 * regcache.h (supply_register_by_name_zeroed): Declare new
1209 function.
1210
1211 2018-05-07 Tom Tromey <tom@tromey.com>
1212
1213 * configure: Rebuild.
1214
1215 2018-05-04 Tom Tromey <tom@tromey.com>
1216
1217 * configure: Rebuild.
1218
1219 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
1220 Pedro Alves <palves@redhat.com>
1221
1222 * linux-aarch64-low.c (aarch64_stopped_data_address):
1223 Likewise.
1224
1225 2018-04-27 Tom Tromey <tom@tromey.com>
1226
1227 * configure: Rebuild.
1228
1229 2018-04-23 Tom Tromey <tom@tromey.com>
1230
1231 * configure: Rebuild.
1232
1233 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
1234
1235 * Makefile.in (depcomp): Add "..".
1236 (all_deps_files): New and use it.
1237
1238 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1239
1240 * configure.srv (aarch64*-*-linux*): Don't include xml.
1241 (i[34567]86-*-cygwin*): Likewise.
1242 (i[34567]86-*-linux*): Likewise.
1243 (i[34567]86-*-lynxos*): Likewise.
1244 (i[34567]86-*-mingw32ce*): Likewise.
1245 (i[34567]86-*-mingw*): Likewise.
1246 (i[34567]86-*-nto*): Likewise.
1247 (tic6x-*-uclinux): Likewise.
1248 (x86_64-*-linux*): Likewise.
1249 (x86_64-*-mingw*): Likewise.
1250 (x86_64-*-cygwin*): Likewise.
1251
1252 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1253
1254 * tdesc.c: Remove xml parameter.
1255
1256 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1257
1258 * server.c (get_features_xml): Remove cast.
1259 * tdesc.c (void target_desc::accept): Fill in function.
1260 (tdesc_get_features_xml): Remove old xml creation.
1261 (print_xml_feature::visit_pre): Add xml vistor.
1262 * tdesc.h (struct target_desc): Make xmltarget mutable.
1263 (tdesc_get_features_xml): Remove declaration.
1264
1265 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1266
1267 * tdesc.c (tdesc_architecture_name): Add new function.
1268 (tdesc_osabi_name): Likewise.
1269 (tdesc_get_features_xml): Use new functions.
1270
1271 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1272
1273 * tdesc.c (tdesc_create_flags): Remove.
1274 (tdesc_add_flag): Likewise.
1275 (tdesc_named_type): Likewise.
1276 (tdesc_create_union): Likewise.
1277 (tdesc_create_struct): Likewise.
1278 (tdesc_create_vector): Likewise.
1279 (tdesc_add_bitfield): Likewise.
1280 (tdesc_add_field): Likewise.
1281 (tdesc_set_struct_size): Likewise.
1282
1283 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1284
1285 * tdesc.c (~target_desc): Remove implictly deleted items.
1286 (init_target_desc): Iterate all features.
1287 (tdesc_get_features_xml): Use vector.
1288 (tdesc_create_feature): Create feature.
1289 * tdesc.h (tdesc_feature) Remove
1290 (target_desc): Add features.
1291
1292 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1293
1294 * Makefile.in: Add common/tdesc.c
1295 * tdesc.c (init_target_desc): init all reg_defs from register
1296 vector.
1297 (tdesc_create_reg): Create tdesc_reg.
1298 * tdesc.h (tdesc_feature): Add register vector.
1299
1300 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
1301
1302 * tdesc.h (struct target_desc) <features>: Change type to
1303 std::vector<std::string>.
1304 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
1305 changes.
1306 (tdesc_get_features_xml): Likewise.
1307 (tdesc_create_feature): Likewise.
1308
1309 2018-03-26 Alan Hayward <alan.hayward@arm.com>
1310
1311 * regcache.c (find_register_by_number): Return a ref.
1312 (find_regno): Use references.
1313 (register_size): Likewise.
1314 (register_data): Likewise.
1315 * tdesc.c (target_desc::~target_desc): Remove free calls.
1316 (target_desc::operator==): Use std::vector compare.
1317 (init_target_desc): Use reference.
1318 (tdesc_create_reg): Use reg constructors.
1319 * tdesc.h (struct target_desc): Replace pointer with object.
1320
1321 2018-03-23 Alan Hayward <alan.hayward@arm.com>
1322
1323 * regcache.c (find_register_by_number): Make static.
1324 (find_regno): Use find_register_by_number
1325 * regcache.h (struct reg): Remove declaration.
1326
1327 2018-03-23 Alan Hayward <alan.hayward@arm.com>
1328
1329 * tdesc.c (target_desc::~target_desc): Move to here.
1330 (target_desc::operator==): Likewise.
1331 * tdesc.h (target_desc::~target_desc): Move from here.
1332 (target_desc::operator==): Likewise.
1333
1334 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
1335
1336 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
1337
1338 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1339
1340 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
1341 S390_TDESC_GS.
1342 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
1343 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
1344 and init_registers_s390_gs_linux64.
1345
1346 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1347
1348 * linux-s390-low.c (s390_fill_gs): Remove function.
1349 (s390_fill_gsbc): Remove function.
1350 (s390_regsets): Set fill functions for the guarded storage regsets
1351 to NULL.
1352
1353 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1354
1355 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
1356 the word size. Add comment.
1357 (s390_get_wordsize): New function.
1358 (s390_arch_setup): No longer select a temporary tdesc to fetch the
1359 pswm with it. Instead, use s390_get_wordsize to determine the
1360 word size first and derive the correct tdesc from that directly.
1361
1362 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
1363
1364 * Makefile.in: Include silent-rules.mk.
1365 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
1366 (COMPILE): Add ECHO_CXX.
1367 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
1368 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
1369 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
1370 (version-generated.c): Add ECHO_GEN.
1371 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
1372 (IPAGENT_COMPILE): Add ECHO_CXX.
1373 (%-generated.c): Add ECHO_REGDAT.
1374
1375 2018-03-14 Tom Tromey <tom@tromey.com>
1376
1377 PR cli/14977:
1378 * ax.c (ax_printf): Special case for NULL.
1379
1380 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1381
1382 * linux-low.c (linux_qxfer_libraries_svr4): Use
1383 xml_escape_text_append.
1384
1385 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1386
1387 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
1388
1389 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1390
1391 * server.c (handle_general_set): Remove unnecessary xstrdup.
1392
1393 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1394
1395 * server.c (parse_debug_format_options): Adjust to
1396 delim_string_to_char_ptr_vec changes.
1397 * thread-db.c (thread_db_load_search): Adjust to
1398 dirnames_to_char_ptr_vec changes.
1399
1400 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
1401
1402 * target.h (target_enable_btrace, target_disable_btrace)
1403 (target_read_btrace, target_read_btrace_conf): Turn macro into
1404 inline function. Throw error if target method is not defined.
1405 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
1406 check for btrace target method. Be prepared to handle exceptions
1407 from btrace target methods.
1408
1409 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1410
1411 * server.c (captured_main): Change order of error message printed
1412 when the current working directory cannot be found.
1413
1414 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1415
1416 * server.c: Include "filenames.h" and "pathstuff.h".
1417 (program_name): Delete variable.
1418 (program_path): New anonymous class.
1419 (get_exec_wrapper): Use "program_path" instead of
1420 "program_name".
1421 (handle_v_run): Likewise.
1422 (captured_main): Likewise.
1423 (process_serial_event): Likewise.
1424
1425 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1426
1427 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
1428 (OBJS): Add "pathstuff.o".
1429 * server.c (current_directory): New global variable.
1430 (captured_main): Initialize "current_directory".
1431
1432 2018-02-26 Alan Hayward <alan.hayward@arm.com>
1433
1434 * tdesc.c: Use common/tdesc.h.
1435 * tdesc.h: Likewise.
1436
1437 2018-02-20 Alan Hayward <alan.hayward@arm.com>
1438 Simon Marchi <simon.marchi@ericsson.com>
1439
1440 * Makefile.in: Switch order of make rules.
1441
1442 2018-02-19 Alan Hayward <alan.hayward@arm.com>
1443
1444 * Makefile.in: Add common directory in build.
1445 * configure.ac: Add common reference.
1446 * configure: Regenerate.
1447
1448 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1449
1450 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
1451 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
1452 * spu-low.c (spu_target_ops): Likewise.
1453 * win32-low.c (win32_target_ops): Likewise.
1454 * server.c (supported_btrace_packets): Report packets unconditionally.
1455 * target.h (target_ops) <supports_btrace>: Remove.
1456 (target_supports_btrace): Remove.
1457
1458 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1459
1460 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
1461 (handle_btrace_disable): Change return type to void. Use exceptions
1462 to report errors.
1463 (handle_btrace_general_set): Catch exception and copy message to
1464 return message.
1465
1466 2018-02-08 Tom Tromey <tom@tromey.com>
1467
1468 * linux-low.c (install_software_single_step_breakpoints): Use
1469 make_scoped_restore.
1470 * inferiors.c (make_cleanup_restore_current_thread): Remove.
1471 (do_restore_current_thread_cleanup): Remove.
1472 * gdbthread.h (make_cleanup_restore_current_thread): Don't
1473 declare.
1474
1475 2018-02-08 Tom Tromey <tom@tromey.com>
1476
1477 * mem-break.c (set_raw_breakpoint_at): Use
1478 gdb::unique_xmalloc_ptr.
1479
1480 2018-01-30 Pedro Alves <palves@redhat.com>
1481
1482 PR gdb/13211
1483 * target.c (target_terminal::terminal_state): Rename to ...
1484 (target_terminal::m_terminal_state): ... this.
1485
1486 2018-01-19 James Clarke <jrtc27@jrtc27.com>
1487
1488 * linux-low.c (handle_extended_wait): Surround call to
1489 thread_db_notice_clone with #ifdef USE_THREAD_DB.
1490
1491 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
1492
1493 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
1494 linux_ptrace_attach_fail_reason_string now returning an
1495 std::string.
1496 (linux_attach): Likewise.
1497 * thread-db.c (attach_thread): Likewise.
1498
1499 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
1500
1501 PR gdb/21559
1502 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
1503 checking for fs_base/gs_base fields in struct user_regs_struct.
1504 * configure: Regenerate.
1505
1506 2018-01-16 Yao Qi <yao.qi@linaro.org>
1507
1508 PR gdb/18749
1509 * linux-low.c (fetch_register): Call supply_register instead of
1510 error.
1511
1512 2018-01-08 Yao Qi <yao.qi@linaro.org>
1513 Simon Marchi <simon.marchi@ericsson.com>
1514
1515 * Makefile.in (OBS): Remove selftest.o.
1516 * configure.ac: Set srv_selftest_objs if $development is true.
1517 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
1518 * configure: Re-generated.
1519 * server.c (captured_main): Wrap variable selftest_filter with
1520 GDB_SELF_TEST.
1521
1522 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
1523
1524 * server.c (parse_debug_format_options): Return std::string.
1525 (handle_monitor_command, captured_main): Adjust.
1526
1527 2018-01-05 Pedro Alves <palves@redhat.com>
1528
1529 PR gdb/18653
1530 * server.c (captured_main): Pass quiet=false to
1531 save_original_signals_state.
1532
1533 2018-01-01 Joel Brobecker <brobecker@adacore.com>
1534
1535 * gdbreplay.c (gdbreplay_version): Update copyright year in
1536 version message.
1537 * server.c (gdbserver_version): Likewise.
1538
1539 2017-12-08 Tom Tromey <tom@tromey.com>
1540
1541 * ax.c (ax_printf): Update.
1542
1543 2017-12-07 Yao Qi <yao.qi@linaro.org>
1544
1545 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
1546 aarch64_linux_read_description.
1547 * linux-amd64-ipa.c (idx2mask): New array.
1548 (get_ipa_tdesc): Move idx2mask out.
1549 (initialize_low_tracepoint): Initialize target descriptions.
1550 * linux-i386-ipa.c (idx2mask): New array.
1551 (get_ipa_tdesc): Move idx2mask out.
1552 (initialize_low_tracepoint): Initialize target descriptions.
1553
1554 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
1555
1556 * tdesc.c (struct tdesc_type): Change return type.
1557 (tdesc_add_flag): Change parameter type.
1558 (tdesc_add_bitfield): Likewise.
1559 (tdesc_add_field): Likewise.
1560 (tdesc_set_struct_size): Likewise.
1561
1562 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
1563
1564 * regcache.c (registers_to_string): Remove unused variable.
1565
1566 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1567
1568 * inferiors.c (for_each_inferior_with_data): Remove.
1569 * inferiors.h (for_each_inferior_with_data): Remove.
1570 * server.c (handle_qxfer_threads_worker): Change parameter type.
1571 (handle_qxfer_threads_proper): Use for_each_thread.
1572
1573 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1574
1575 * inferiors.c (for_each_inferior): Remove.
1576 (clear_inferiors): Use for_each_thread.
1577 * inferiors.h (for_each_inferior): Remove.
1578 * linux-low.c (linux_wait_for_event_filtered): Use
1579 for_each_thread.
1580 (linux_stabilize_threads): Likewise.
1581 * regcache.c (regcache_release): Likewise.
1582 * server.c (gdb_wants_all_threads_stopped): Likewise.
1583 (clear_pending_status_callback): Remove.
1584 (handle_status): Use for_each_thread.
1585 (captured_main): Likewise.
1586 * win32-low.c (child_init_thread_list): Likewise.
1587 (win32_clear_inferiors): Likewise.
1588 (fake_breakpoint_event): Likewise.
1589
1590 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1591
1592 * inferiors.h (find_inferior): Remove.
1593 * inferiors.c (find_inferior): Remove.
1594
1595 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1596
1597 * linux-low.c (resume_status_pending_p): Update comment.
1598 (need_step_over_p): Update comment.
1599
1600 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1601
1602 * linux-low.c (proceed_one_lwp): Return void, change parameter
1603 type.
1604 (unsuspend_and_proceed_one_lwp): Likewise.
1605 (proceed_all_lwps): Use for_each_thread.
1606 (unstop_all_lwps): Likewise.
1607
1608 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1609
1610 * linux-low.c (linux_resume_one_thread): Return void, take
1611 parameter directly.
1612 (linux_resume): Use for_each_thread.
1613
1614 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1615
1616 * linux-low.c (send_sigstop_callback): Return void, change
1617 parameter type. Rename to...
1618 (send_sigstop): ... this.
1619 (suspend_and_send_sigstop_callback): Return void, change parameter
1620 type. Rename to...
1621 (suspend_and_send_sigstop): ... this.
1622 (stop_all_lwps): Use for_each_thread.
1623
1624 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1625
1626 * linux-low.c (lwp_running): Return bool, remove unused
1627 argument.
1628 (linux_stabilize_threads): Use find_thread.
1629
1630 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1631
1632 * linux-low.c (select_singlestep_lwp_callback): Remove.
1633 (count_events_callback): Remove.
1634 (select_event_lwp_callback): Remove.
1635 (select_event_lwp): Use find_thread/for_each_thread.
1636
1637 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1638
1639 * linux-low.c (not_stopped_callback): Return bool, take filter
1640 argument directly.
1641 (linux_wait_for_event_filtered): Use find_thread.
1642 (linux_wait_1): Likewise.
1643
1644 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1645
1646 * linux-low.c (same_lwp): Remove.
1647 (find_lwp_pid): Use find_thread.
1648
1649 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1650
1651 * linux-low.c (delete_lwp_callback): Remove.
1652 (linux_mourn): Use for_each_thread.
1653
1654 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1655
1656 * linux-low.c (linux_detach_lwp_callback): Return void, remove
1657 args parameter, don't check for pid.
1658 (linux_detach): Use for_each_thread.
1659
1660 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1661
1662 * linux-low.c (struct counter): Remove.
1663 (second_thread_of_pid_p): Remove.
1664 (last_thread_of_process_p): Use find_thread.
1665
1666 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1667
1668 * inferiors.c (find_inferior_in_random): Remove.
1669 * inferiors.h (find_inferior_in_random): Remove.
1670 * linux-low.c (status_pending_p_callback): Return bool, accept
1671 parameter ptid directly.
1672 (linux_wait_for_event_filtered): Use find_thread_in_random.
1673 (linux_wait_1): Likewise.
1674
1675 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1676
1677 * inferiors.c (find_inferior_id): Remove.
1678 (find_thread_ptid): Move implemention from find_inferior_id to
1679 here.
1680 * inferiors.h (find_inferior_id): Remove.
1681 * server.c (handle_status): Use find_thread_ptid.
1682 (process_serial_event): Likewise.
1683 * thread-db.c (find_one_thread): Likewise.
1684 (thread_db_thread_handle): Likewise.
1685 * win32-low.c (thread_rec): Likewise.
1686 (child_delete_thread): Likewise.
1687 (win32_thread_alive): Likewise.
1688 (get_child_debug_event): Likewise.
1689
1690 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1691
1692 * linux-mips-low.c (update_watch_registers_callback): Return
1693 void, remove pid_p parameter, don't check for pid.
1694 (mips_insert_point, mips_remove_point): Use for_each_thread.
1695
1696 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1697
1698 * lynx.low (lynx_delete_thread_callback): Remove.
1699 (lynx_mourn): Use for_each_thread.
1700
1701 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1702
1703 * regcache.c (regcache_invalidate_one): Remove.
1704 (regcache_invalidate_pid): use for_each_thread.
1705
1706 2017-11-26 Tom Tromey <tom@tromey.com>
1707
1708 * linux-low.c (linux_create_inferior): Update.
1709
1710 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
1711
1712 * spu-low.c (spu_create_inferior): Fix typo in argument name.
1713
1714 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1715
1716 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
1717 * linux-aarch64-low.c (initialize_low_arch): Call init func.
1718 * linux-aarch64-tdesc-selftest.c: New file.
1719 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
1720
1721 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1722
1723 * configure.srv: Add new file.
1724 * linux-aarch64-low.c (initialize_low_arch): Call init func.
1725 * linux-aarch64-tdesc-selftest.c: New file.
1726 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
1727
1728 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1729
1730 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
1731 * linux-aarch64-low.c (initialize_low_arch): Remove init.
1732 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
1733
1734 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1735
1736 * configure.srv: Add new files.
1737 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
1738 aarch64_linux_read_description.
1739 * linux-aarch64-low.c (aarch64_linux_read_description):
1740 Merge with aarch64_arch_setup.
1741 (aarch64_arch_setup): Call aarch64_linux_read_description.
1742 * linux-aarch64-tdesc.c: New file.
1743 * linux-aarch64-tdesc.h: New file.
1744
1745 2017-11-24 Yao Qi <yao.qi@linaro.org>
1746
1747 * configure.srv: Set $srv_regobj for tic6x-linux.
1748 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
1749 (tic6x_read_description): Move some code to tic6x_arch_setup.
1750 (tic6x_tdesc_test): New function.
1751 (initialize_low_arch): Call selftests::register_test.
1752
1753 2017-11-22 Yao Qi <yao.qi@linaro.org>
1754
1755 * remote-utils.c (prepare_resume_reply): Use memcpy.
1756
1757 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1758
1759 * linux-low.c (kill_one_lwp_callback): Return void, take
1760 argument directly, don't filter on pid.
1761 (linux_kill): Use for_each_thread.
1762
1763 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1764
1765 * linux-low.c (need_step_over_p): Return bool, remove dummy
1766 argument.
1767 (linux_resume, proceed_all_lwps): Use find_thread.
1768
1769 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1770
1771 * linux-low.c (resume_status_pending_p): Return bool, remove
1772 flag_p argument.
1773 (linux_resume): Use find_thread.
1774
1775 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1776
1777 * linux-low.c (struct thread_resume_array): Remove.
1778 (linux_set_resume_request): Return void, take arguments
1779 directly.
1780 (linux_resume): Use for_each_thread.
1781
1782 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1783
1784 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
1785 return bool, remove data argument.
1786 (linux_stabilize_threads): Use find_thread.
1787
1788 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1789
1790 * linux-low.c (unsuspend_one_lwp): Remove.
1791 (unsuspend_all_lwps): Use for_each_thread, inline code from
1792 unsuspend_one_lwp.
1793
1794 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1795
1796 * gdbthread.h (find_thread): Add overload with ptid_t filter.
1797 * linux-low.c (struct iterate_over_lwps_args): Remove.
1798 (iterate_over_lwps_filter): Remove.
1799 (iterate_over_lwps): Use find_thread.
1800
1801 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1802
1803 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
1804 (linux_handle_new_gdb_connection): Use for_each_thread, inline
1805 code from reset_lwp_ptrace_options_callback.
1806
1807 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1808
1809 * linux-arm-low.c (struct update_registers_data): Remove.
1810 (update_registers_callback): Return void, take arguments
1811 directly, don't check thread's pid.
1812 (arm_insert_point, arm_remove_point): Use for_each_thread.
1813
1814 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1815
1816 * win32-low.c (continue_one_thread): Return void, take argument
1817 directly.
1818 (child_continue): Use for_each_thread.
1819
1820 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1821
1822 * win32-i386-low.c (update_debug_registers_callback): Rename
1823 to ...
1824 (update_debug_registers): ... this, return void, remove pid_p arg.
1825 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
1826
1827 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1828
1829 * inferiors.h (struct process_info): Add constructor, initialize
1830 fields..
1831 <syscalls_to_catch>: Change type to std::vector<int>.
1832 * inferiors.c (add_process): Allocate process_info with new.
1833 (remove_process): Free process_info with delete.
1834 * linux-low.c (handle_extended_wait): Adjust.
1835 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
1836 * server.c (handle_general_set): Adjust.
1837
1838 2017-11-16 Pedro Alves <palves@redhat.com>
1839
1840 * remote-utils.c (remote_close): Block SIGIO signals instead of
1841 uninstalling the SIGIO handler.
1842
1843 2017-11-16 Alan Hayward <alan.hayward@arm.com>
1844
1845 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
1846
1847 2017-11-16 Yao Qi <yao.qi@linaro.org>
1848
1849 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
1850 (tic6x_store_gregset): Likewise.
1851 (tic6x_usrregs_info): Move it up.
1852
1853 2017-11-15 Alan Hayward <alan.hayward@arm.com>
1854
1855 * Makefile.in: Update arch rules.
1856 * configure.srv: Explicitly mark arch/ files.
1857
1858 2017-11-13 Andreas Schwab <schwab@suse.de>
1859
1860 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
1861 function.
1862 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
1863
1864 2017-11-06 Pedro Alves <palves@redhat.com>
1865
1866 * config.in, configure: Regenerate.
1867
1868 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1869
1870 * target.c (struct thread_search): Remove.
1871 (thread_search_callback): Remove.
1872 (prepare_to_access_memory): Use for_each_thread instead of
1873 find_inferior. Inline code from thread_search_callback.
1874
1875 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1876
1877 * server.c (struct visit_actioned_threads_data): Remove.
1878 (visit_actioned_threads): Change prototype to take arguments
1879 directly.
1880 (resume): Use find_thread instead of find_inferior.
1881
1882 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1883
1884 * server.c (queue_stop_reply_callback): Change prototype, return
1885 void.
1886 (find_status_pending_thread_callback): Remove.
1887 (handle_status): Replace find_inferior with find_thread and
1888 for_each_thread.
1889
1890 2017-10-25 Alan Hayward <alan.hayward@arm.com>
1891
1892 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
1893 with REGNO.
1894 (aarch64_store_gregset): Likewise.
1895 (aarch64_fill_fpregset): Likewise.
1896 (aarch64_store_fpregset): Likewise.
1897
1898 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
1899
1900 * gdbthread.h (find_thread, for_each_thread): New functions.
1901 * inferiors.c (thread_of_pid): Remove.
1902 (find_any_thread_of_pid): Use find_thread.
1903 * linux-low.c (num_lwps): Use for_each_thread.
1904
1905 2017-10-17 Yao Qi <yao.qi@linaro.org>
1906
1907 * Makefile.in: Remove one rule.
1908 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
1909
1910 2017-10-17 Yao Qi <yao.qi@linaro.org>
1911
1912 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
1913 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
1914
1915 2017-10-17 Yao Qi <yao.qi@linaro.org>
1916
1917 * configure.srv: Rename arm.o with arch/arm.o.
1918
1919 2017-10-17 Yao Qi <yao.qi@linaro.org>
1920
1921 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
1922 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
1923 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
1924 (arch-i386.o, arch-amd64.o): Remove rules.
1925 (arch/%.o): New rule.
1926 Update POSTCOMPILE and COMPILE.pre.
1927 * configure.ac: Invoke AC_CONFIG_COMMANDS.
1928 * configure: Re-generated.
1929 * configure.srv: Replace arch-i386.o with arch/i386.o.
1930 Replace arch-amd64.o with arch/amd64.o.
1931
1932 2017-10-16 Yao Qi <yao.qi@linaro.org>
1933
1934 * configure: Regenerated.
1935
1936 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1937
1938 * inferiors.h: (struct inferior_list): Remove.
1939 (struct inferior_list_entry); Remove.
1940 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
1941 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
1942 get_first_inferior): Remove.
1943 (for_each_inferior, for_each_inferior_with_data, find_inferior,
1944 find_inferior_id, find_inferior_in_random): Change signature.
1945 * inferiors.c (all_threads): Change type to
1946 std::list<thread_info *>.
1947 (get_thread): Remove macro.
1948 (find_inferior, find_inferior_id): Change signature, implement
1949 using find_thread.
1950 (find_inferior_in_random): Change signature, implement using
1951 find_thread_in_random.
1952 (for_each_inferior, for_each_inferior_with_data): Change
1953 signature, implement using for_each_thread.
1954 (add_inferior_to_list, remove_inferior): Remove.
1955 (add_thread, get_first_thread, thread_of_pid,
1956 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
1957 (get_first_inferior, one_inferior_p, clear_inferior_list):
1958 Remove.
1959 (clear_inferiors, get_thread_process): Update.
1960 * gdbthread.h: Include <list>.
1961 (struct thread_info) <entry>: Remove field.
1962 <id>: New field.
1963 (all_threads): Change type to std::list<thread_info *>.
1964 (get_first_inferior): Add doc.
1965 (find_thread, for_each_thread, find_thread_in_random): New
1966 functions.
1967 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
1968 * linux-arm-low.c (update_registers_callback): Update.
1969 * linux-low.c (second_thread_of_pid_p): Update.
1970 (kill_one_lwp_callback, linux_detach_lwp_callback,
1971 delete_lwp_callback, status_pending_p_callback, same_lwp,
1972 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
1973 iterate_over_lwps, not_stopped_callback,
1974 resume_stopped_resumed_lwps, count_events_callback,
1975 select_singlestep_lwp_callback, select_event_lwp_callback,
1976 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
1977 suspend_and_send_sigstop_callback, wait_for_sigstop,
1978 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
1979 lwp_running, linux_set_resume_request, resume_status_pending_p,
1980 need_step_over_p, start_step_over, linux_resume_one_thread,
1981 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
1982 reset_lwp_ptrace_options_callback): Update.
1983 * linux-mips-low.c (update_watch_registers_callback): Update.
1984 * regcache.c (regcache_invalidate_one, regcache_invalidate):
1985 Update.
1986 (free_register_cache_thread_one): Remove.
1987 (regcache_release): Update.
1988 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
1989 handle_qxfer_threads_worker): Update.
1990 (handle_query): Update, use list iterator.
1991 (visit_actioned_threads, handle_pending_status,
1992 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
1993 clear_pending_status_callback, set_pending_status_callback,
1994 find_status_pending_thread_callback, handle_status,
1995 process_serial_event): Update.
1996 * target.c (thread_search_callback): Update.
1997 * thread-db.c (thread_db_get_tls_address): Update.
1998 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
1999 Update.
2000 * win32-i386-low.c (update_debug_registers_callback): Update.
2001 * win32-low.c (delete_thread_info, child_delete_thread,
2002 continue_one_thread, suspend_one_thread,
2003 get_child_debug_event): Adjust.
2004
2005 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2006
2007 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
2008 * inferiors.h: Include <list>.
2009 (struct process_info) <entry>: Remove field.
2010 <pid>: New field.
2011 (pid_of): Change macro to function.
2012 (ptid_of, lwpid_of): Remove macro.
2013 (all_processes): Change type to std::list<process_info *>.
2014 (ALL_PROCESSES): Remove macro.
2015 (for_each_process, find_process): New function.
2016 * inferiors.c (all_processes): Change type to
2017 std::list<process_info *>.
2018 (find_thread_process): Adjust.
2019 (add_process): Likewise.
2020 (remove_process): Likewise.
2021 (find_process_pid): Likewise.
2022 (get_first_process): Likewise.
2023 (started_inferior_callback): Remove.
2024 (have_started_inferiors_p): Adjust.
2025 (attached_inferior_callback): Remove.
2026 (have_attached_inferiors_p): Adjust.
2027 * linux-low.c (check_zombie_leaders): Likewise.
2028 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
2029 (x86_linux_update_xmltarget): Adjust.
2030 * server.c (handle_query): Likewise.
2031 (gdb_reattached_process): Remove.
2032 (handle_status): Adjust.
2033 (kill_inferior_callback): Likewise.
2034 (detach_or_kill_inferior): Remove.
2035 (print_started_pid): Likewise.
2036 (print_attached_pid): Likewise.
2037 (detach_or_kill_for_exit): Update.
2038 (process_serial_event): Likewise.
2039 * linux-arm-low.c (arm_new_fork): Likewise.
2040
2041 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2042
2043 * dll.h: Include <list>.
2044 (struct dll_info): Add constructor.
2045 <entry>: Remove field.
2046 (all_dlls): Change type to std::list<dll_info>.
2047 * dll.c: Include <algorithm>.
2048 (get_dll): Remove macro.
2049 (all_dlls): Change type to std::list<dll_info *>.
2050 (free_one_dll): Remove.
2051 (match_dll): Likewise.
2052 (loaded_dll): Adjust.
2053 (unloaded_dll): Adjust to all_dlls type change, use
2054 std::find_if. Inline code from match_dll.
2055 (clear_dlls): Adjust to all_dlls type change.
2056 * server.c (emit_dll_description): Remove.
2057 (handle_qxfer_libraries): Adjust to all_dlls type change,
2058 integrate emit_dll_description's functionality.
2059
2060 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2061
2062 * linux-low.h (struct linux_target_ops) <delete_process>: New
2063 field.
2064 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
2065 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
2066 (struct linux_target_ops): Add delete_process callback.
2067 * linux-arm-low.c (arm_delete_process): New.
2068 (struct linux_target_ops): Add delete_process callback.
2069 * linux-bfin-low.c (struct linux_target_ops): Likewise.
2070 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
2071 * linux-m32r-low.c (struct linux_target_ops): Likewise.
2072 * linux-mips-low.c (mips_linux_delete_process): New.
2073 (struct linux_target_ops): Add delete_process callback.
2074 * linux-ppc-low.c (struct linux_target_ops): Likewise.
2075 * linux-s390-low.c (struct linux_target_ops): Likewise.
2076 * linux-sh-low.c (struct linux_target_ops): Likewise.
2077 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
2078 * linux-tile-low.c (struct linux_target_ops): Likewise.
2079 * linux-x86-low.c (x86_linux_delete_process): New.
2080 (struct linux_target_ops): Add delete_process callback.
2081 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
2082
2083 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2084
2085 * linux-aarch64-low.c (the_low_target): Add thread delete
2086 callback.
2087 * linux-arm-low.c (arm_delete_thread): New function.
2088 (the_low_target): Add thread delete callback.
2089 * linux-bfin-low.c (the_low_target): Likewise.
2090 * linux-crisv32-low.c (the_low_target): Likewise.
2091 * linux-low.c (delete_lwp): Invoke delete_thread callback if
2092 set.
2093 * linux-low.h (struct linux_target_ops) <delete_thread>: New
2094 field.
2095 * linux-m32r-low.c (the_low_target): Add thread delete callback.
2096 * linux-mips-low.c (mips_linux_delete_thread): New function.
2097 (the_low_target): Add thread delete callback.
2098 * linux-ppc-low.c (the_low_target): Likewise.
2099 * linux-s390-low.c (the_low_target): Likewise.
2100 * linux-sh-low.c (the_low_target): Likewise.
2101 * linux-tic6x-low.c (the_low_target): Likewise.
2102 * linux-tile-low.c (the_low_target): Likewise.
2103 * linux-x86-low.c (the_low_target): Likewise.
2104 * linux-xtensa-low.c (the_low_target): Likewise.
2105
2106 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
2107
2108 * win32-low.c: Include "common-inferior.h".
2109
2110 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2111
2112 * inferiors.c (set_inferior_cwd): New function.
2113 * server.c (handle_general_set): Handle QSetWorkingDir packet.
2114 (handle_query): Inform that QSetWorkingDir is supported.
2115 * win32-low.c (create_process): Pass the inferior's cwd to
2116 CreateProcess.
2117
2118 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2119
2120 * inferiors.c (current_inferior_cwd): New global variable.
2121 (get_inferior_cwd): New function.
2122 * inferiors.h (struct process_info) <cwd>: New field.
2123
2124 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2125
2126 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
2127 (OBS): Add gdb_tilde_expand.o.
2128
2129 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
2130
2131 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
2132 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
2133
2134 2017-09-29 Pedro Alves <palves@redhat.com>
2135
2136 * ax.c (gdb_parse_agent_expr): Constify.
2137 * ax.h (gdb_parse_agent_expr): Constify.
2138 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
2139 Constify.
2140 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
2141 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
2142 * remote-utils.h (read_ptid): Constify.
2143 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
2144 (process_point_options, process_serial_event): Constify.
2145 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
2146 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
2147 (cmd_qtbuffer): Constify.
2148
2149 2017-09-29 Pedro Alves <palves@redhat.com>
2150
2151 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
2152 fails.
2153
2154 2017-09-29 Pedro Alves <palves@redhat.com>
2155
2156 * linux-low.c (handle_extended_wait): Pass parent thread instead
2157 of process to thread_db_notice_clone.
2158 * linux-low.h (thread_db_notice_clone): Replace parent process
2159 parameter with parent thread parameter.
2160 * thread-db.c (find_one_thread): Add comment.
2161 (thread_db_notice_clone): Replace parent process parameter with
2162 parent thread parameter. Temporarily switch to the parent thread.
2163
2164 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
2165
2166 * gdbthread.h: Include "common-gdbthread.h".
2167 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
2168 "if" when validating the ptid.
2169 * remote-utils.c: Include "gdbthread.h".
2170 (prepare_resume_reply): Use "switch_to_thread".
2171 * target.c (done_accessing_memory): Likewise.
2172
2173 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
2174
2175 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
2176 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
2177 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
2178 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
2179 s390x-gs-linux64-ipa.o to ipa_obj.
2180 * linux-s390-low.c (HWCAP_S390_GS): New define.
2181 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
2182 New functions.
2183 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
2184 (s390_arch_setup): Check for guarded-storage support and choose
2185 appropriate tdesc.
2186 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
2187 init_registers_s390x_gs_linux64.
2188 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
2189 enum value.
2190 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
2191 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
2192
2193 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
2194
2195 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
2196
2197 2017-09-21 Kevin Buettner <kevinb@redhat.com>
2198
2199 * linux-low.h (struct lwp_info): Add new field, thread_handle.
2200 (thread_db_thread_handle): Declare.
2201 * linux-low.c (linux_target_ops): Initialize thread_handle.
2202 * server.c (handle_qxfer_threads_worker): Add support for
2203 "handle" attribute.
2204 * target.h (struct target_ops): Add new function pointer,
2205 thread_handle.
2206 (target_thread_handle): Define.
2207 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
2208 field in lwp.
2209 (thread_db_thread_handle): New function.
2210
2211 2017-09-21 Kevin Buettner <kevinb@redhat.com>
2212
2213 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
2214 * linux-low.h (thread_db_notice_clone): Declare.
2215 * thread-db.c (thread_db_notice_clone): New function.
2216
2217 2017-09-21 Pedro Alves <palves@redhat.com>
2218
2219 * server.c (gdb_read_memory, handle_status, process_serial_event)
2220 (handle_serial_event, handle_target_event): Adjust to
2221 set_desired_thread prototype change.
2222 * target.c (set_desired_thread): Remove 'use_general' parameter
2223 and adjust.
2224 * target.h (set_desired_thread): Remove 'use_general' parameter.
2225
2226 2017-09-20 Tom Tromey <tom@tromey.com>
2227
2228 * target.c (target_terminal::terminal_state): Define.
2229 (target_terminal::init): Rename from target_terminal_init.
2230 (target_terminal::inferior): Rename from
2231 target_terminal_inferior.
2232 (target_terminal::ours): Rename from target_terminal_ours.
2233 (target_terminal::ours_for_output, target_terminal::info): New.
2234
2235 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2236
2237 * server.c (accumulate_file_name_length): Remove.
2238 (emit_dll_description): Adjust to std::string change.
2239 (handle_qxfer_libraries): Use std::string to hold document.
2240
2241 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2242
2243 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
2244 return type of xml_escape_text.
2245 * server.c (emit_dll_description): Likewise.
2246
2247 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2248
2249 * server.c (captured_main): Accept argument for --selftest.
2250 Update run_tests call.
2251 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
2252 when registering selftests.
2253
2254 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
2255
2256 * regcache.c (get_thread_regcache): Update code to use "std::vector"
2257 instead of "VEC" for "target_desc.reg_defs".
2258 (regcache_cpy): Likewise.
2259 (registers_to_string): Likewise.
2260 (registers_from_string): Likewise.
2261 (find_regno): Likewise.
2262 (supply_regblock): Likewise.
2263 (regcache_raw_read_unsigned): Likewise.
2264 * tdesc.c (init_target_desc): Likewise.
2265 (tdesc_create_reg): Likewise.
2266 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
2267 (struct target_desc) <reg_defs>: Convert to "std::vector".
2268 (target_desc): Do not initialize "reg_defs".
2269 (~target_desc): Update code to use "std::vector" instead of "VEC"
2270 for "target_desc.reg_defs".
2271 (operator==): Likewise.
2272
2273 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2274
2275 * inferiors.h (thread_to_gdb_id): Remove.
2276 * inferiors.c (thread_to_gdb_id): Remove.
2277 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
2278 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
2279 lynx_store_registers, lynx_read_memory, lynx_write_memory):
2280 Likewise.
2281 * nto-low.c (nto_fetch_registers, nto_store_registers,
2282 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
2283
2284 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2285
2286 * inferiors.h (gdb_id_to_thread_id): Remove.
2287 * inferiors.c (gdb_id_to_thread_id): Remove.
2288 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
2289 removal. Move pid declaration closer to where it's used.
2290
2291 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2292
2293 * server.c (handle_detach): New function.
2294 (process_serial_event): Move code out, call handle_detach.
2295
2296 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2297
2298 * server.c (require_running): Rename to ...
2299 (require_running_or_return): ... this ...
2300 (require_running_or_break): ... and this.
2301 (handle_query, process_serial_event): Adjust.
2302
2303 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2304
2305 * linux-low.c (linux_set_resume_request): Remove unused
2306 variables.
2307
2308 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2309
2310 * server.c (first_thread_of): Remove.
2311 (process_serial_event): Replace usage of first_thread_of with
2312 find_any_thread_of_pid.
2313 * tracepoint.c (same_process_p): Remove.
2314 (gdb_agent_about_to_close): Replace usage of same_process_p with
2315 find_any_thread_of_pid.
2316 * linux-x86-low.c (same_process_callback): Remove.
2317 (x86_arch_setup_process_callback): Replace usage of
2318 same_process_callback with find_any_thread_of_pid.
2319 * thread-db.c (any_thread_of): Remove.
2320 (switch_to_process): Replace usage of any_thread_of with
2321 find_any_thread_of_pid.
2322 * inferiors.c (thread_pid_matches_callback): Remove.
2323 (find_thread_process): Adjust to use find_any_thread_of_pid.
2324
2325 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
2326
2327 * regcache.c (get_thread_regcache): Guard calls to "memset"
2328 with "!VEC_empty".
2329
2330 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
2331
2332 * linux-low.c (handle_extended_wait): Use
2333 "allocate_target_description" instead of "XNEW".
2334 * linux-x86-low.c (initialize_low_arch): Likewise.
2335
2336 2017-09-05 Yao Qi <yao.qi@linaro.org>
2337
2338 * configure.srv (srv_i386_regobj): Remove.
2339 (srv_amd64_regobj): Remove.
2340 (srv_regobj): Set it to "" for x86 non-linux targets.
2341 * linux-x86-tdesc.c (i386_linux_read_description):
2342 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
2343 (init_registers_i386): Remove the declaration.
2344 (tdesc_i386): Remove the declaration.
2345 (lynx_i386_arch_setup): Call i386_create_target_description.
2346 * nto-x86-low.c: Likewise.
2347 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
2348 [!__x86_64__]: include arch/i386.h.
2349 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
2350
2351 2017-09-05 Yao Qi <yao.qi@linaro.org>
2352
2353 * configure.srv (srv_amd64_linux_xmlfiles): Remove
2354 i386/amd64-XXX-linux from it.
2355
2356 2017-09-05 Yao Qi <yao.qi@linaro.org>
2357
2358 * configure.srv: Empty srv_amd64_linux_regobj if $development is
2359 false.
2360 (ipa_amd64_linux_regobj): Remove.
2361 (ipa_x32_linux_regobj): Remove.
2362
2363 2017-09-05 Yao Qi <yao.qi@linaro.org>
2364
2365 * Makefile.in (arch-amd64.o): New rule.
2366 * configure.srv: Append arch-amd64.o.
2367 * linux-amd64-ipa.c: Include common/x86-xstate.h.
2368 (get_ipa_tdesc): Call amd64_linux_read_description.
2369 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
2370 and init_registers_amd64_XXX.
2371 * linux-x86-low.c (x86_linux_read_description): Call
2372 amd64_linux_read_description.
2373 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
2374 (initialize_low_arch): Don't call init_registers_x32_XXX and
2375 init_registers_amd64_XXX.
2376 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
2377 and tdesc_amd64_XXX.
2378 [__x86_64__] (amd64_tdesc_test): New function.
2379 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
2380 and init_registers_amd64_XXX.
2381 * linux-x86-tdesc.c: Include arch/amd64.h.
2382 (xcr0_to_tdesc_idx): New function.
2383 (i386_linux_read_description): New function.
2384 (amd64_get_ipa_tdesc_idx): New function.
2385 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
2386 (amd64_get_ipa_tdesc): Declare.
2387
2388 2017-09-05 Yao Qi <yao.qi@linaro.org>
2389
2390 * configure.srv (srv_i386_linux_xmlfiles): Remove
2391 i386/i386-XXX-linux.xml from it.
2392
2393 2017-09-05 Yao Qi <yao.qi@linaro.org>
2394
2395 * configure.srv: Set srv_i386_linux_regobj empty if $development
2396 is false.
2397 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
2398 initialize_low_tdesc.
2399 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
2400 with #if initialize_low_tdesc.
2401 * linux-x86-tdesc-selftest.c: New file.
2402 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
2403
2404 2017-09-05 Yao Qi <yao.qi@linaro.org>
2405
2406 * Makefile.in (arch-i386.o): New rule.
2407 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
2408 (x86_64-*-linux*): Likewise.
2409 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
2410 include arch/i386.h.
2411 (i386_linux_read_description): Remove code and call
2412 i386_create_target_description.
2413 * tdesc.c (allocate_target_description): New function.
2414 * tdesc.h (set_tdesc_architecture): Remove declaration.
2415 (set_tdesc_osabi): Likewise.
2416
2417 2017-09-05 Yao Qi <yao.qi@linaro.org>
2418
2419 * linux-x86-tdesc.c: Don't include <inttypes.h>.
2420 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
2421 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
2422 .xmltarget.
2423 * server.c (get_features_xml): Call tdesc_get_features_xml.
2424 * tdesc.c (set_tdesc_architecture): New function.
2425 (set_tdesc_osabi): New function.
2426 (tdesc_get_features_xml): New function.
2427 (tdesc_create_feature): Add an argument.
2428 * tdesc.h (struct target_desc) <features>: New field.
2429 <arch, osabi>: New field.
2430 (~target_desc): xfree features, arch, and osabi.
2431 (target_desc::oerator==): Don't compare .xmltarget.
2432 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
2433 (set_tdesc_osabi): Likewise.
2434 (tdesc_get_features_xml): Likewise.
2435
2436 2017-09-05 Yao Qi <yao.qi@linaro.org>
2437
2438 * linux-x86-tdesc.c: Include selftest.h.
2439 (i386_tdesc_test): New function.
2440 (initialize_low_tdesc): Call selftests::register_test.
2441 * tdesc.h: Include regdef.h.
2442 (target_desc): Override operator == and !=.
2443
2444 2017-09-05 Yao Qi <yao.qi@linaro.org>
2445
2446 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
2447 (ipa_obj): Likewise.
2448 * linux-i386-ipa.c: Include common/x86-xstate.h
2449 (get_ipa_tdesc): Call i386_linux_read_description.
2450 (initialize_low_tracepoint): Don't call init_registers_XXX
2451 functions, call initialize_low_tdesc instead.
2452 * linux-x86-low.c (x86_linux_read_description): Call
2453 i386_linux_read_description.
2454 (initialize_low_arch): Don't call init_registers_i386_XXX
2455 functions, call initialize_low_tdesc.
2456 * linux-x86-tdesc.c: New file.
2457 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
2458 (i386_get_ipa_tdesc_idx): Declare.
2459 (i386_get_ipa_tdesc): Declare.
2460 (initialize_low_tdesc): Declare.
2461
2462 2017-09-05 Yao Qi <yao.qi@linaro.org>
2463
2464 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
2465 instead of 0.
2466
2467 2017-09-05 Yao Qi <yao.qi@linaro.org>
2468
2469 * Makefile.in (IPA_OBJS): Add vec-ipa.o
2470 * regcache.c (get_thread_regcache): Use VEC_length.
2471 (init_register_cache): Likewise.
2472 (regcache_cpy): Likewise.
2473 (registers_to_string): Iterate reg_defs via VEC_iterate.
2474 (find_regno): Likewise.
2475 (find_register_by_number): Use VEC_index.
2476 (register_size): Call find_register_by_number.
2477 (register_data): Call find_register_by_number.
2478 (supply_regblock): Use VEC_length.
2479 (regcache_raw_read_unsigned): Likewise.
2480 * tdesc.c (init_target_desc): Iterate reg_defs via
2481 VEC_iterate.
2482 (default_description): Update initializer.
2483 (copy_target_description): Don't update field num_registers.
2484 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
2485 <num_registers>: Remove.
2486
2487 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2488
2489 * Makefile.in (.SECONDARY): Define target.
2490
2491 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
2492
2493 * linux-low.c (linux_wait_1): Adjust.
2494 * server.c (queue_stop_reply_callback): Adjust.
2495
2496 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
2497
2498 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
2499 QEnvironmentUnset and QEnvironmentReset packets.
2500 (handle_query): Inform remote that QEnvironmentHexEncoded,
2501 QEnvironmentUnset and QEnvironmentReset are supported.
2502
2503 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
2504
2505 * inferiors.h (inferior_target_data): Rename to ...
2506 (thread_target_data): ... this.
2507 (inferior_regcache_data): Rename to ...
2508 (thread_regcache_data): ... this.
2509 (set_inferior_regcache_data): Rename to ...
2510 (set_thread_regcache_data): ... this.
2511 * inferiors.c (inferior_target_data): Rename to ...
2512 (thread_target_data): ... this.
2513 (inferior_regcache_data): Rename to ...
2514 (thread_regcache_data): ... this.
2515 (set_inferior_regcache_data): Rename to ...
2516 (set_thread_regcache_data): ... this.
2517 (free_one_thread): Update.
2518 * linux-low.h (get_thread_lwp): Update.
2519 * regcache.c (get_thread_regcache): Update.
2520 (regcache_invalidate_thread): Update.
2521 (free_register_cache_thread): Update.
2522 * win32-i386-low.c (update_debug_registers_callback): Update.
2523 (win32_get_current_dr): Update.
2524 * win32-low.c (thread_rec): Update.
2525 (delete_thread_info): Update.
2526 (continue_one_thread): Update.
2527 (suspend_one_thread): Update.
2528
2529 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
2530
2531 * inferiors.c (set_inferior_target_data): Remove.
2532 * inferiors.h (set_inferior_target_data): Remove.
2533
2534 2017-08-18 Yao Qi <yao.qi@linaro.org>
2535
2536 * Makefile.in (OBS): Add selftest.o.
2537 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
2538 * configure, config.in: Re-generated.
2539 * server.c: Include common/sefltest.h.
2540 (captured_main): Handle option --selftest.
2541
2542 2017-08-09 Yao Qi <yao.qi@linaro.org>
2543
2544 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
2545 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
2546 i386-avx-mpx.o and i386-mmx.o.
2547 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
2548 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
2549 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
2550 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
2551 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
2552 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
2553 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
2554 i386/amd64-avx-mpx.xml.
2555
2556 2017-08-09 Yao Qi <yao.qi@linaro.org>
2557
2558 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
2559 and x32-avx-avx512.o.
2560 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
2561 i386/x32-avx-avx512.xml.
2562
2563 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
2564
2565 * tracepoint.h (enum class fast_tpoint_collect_result): New
2566 enumeration.
2567 (fast_tracepoint_collecting): Change return type to
2568 fast_tpoint_collect_result.
2569 * tracepoint.c (fast_tracepoint_collecting): Likewise.
2570 * linux-low.h: Include tracepoint.h.
2571 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
2572 fast_tpoint_collect_result.
2573 * linux-low.c (handle_tracepoints): Adjust.
2574 (linux_fast_tracepoint_collecting): Change return type to
2575 fast_tpoint_collect_result.
2576 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
2577 linux_wait_1, stuck_in_jump_pad_callback,
2578 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
2579 proceed_one_lwp): Adjust to type change.
2580
2581 2017-07-10 Yao Qi <yao.qi@linaro.org>
2582
2583 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
2584
2585 2017-06-29 Yao Qi <yao.qi@linaro.org>
2586
2587 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
2588 Remove.
2589 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
2590
2591 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
2592
2593 * Makefile.in (IPA_OBJS): Sort and format one item per line.
2594
2595 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
2596
2597 * linux-low.c (linux_create_inferior): Adjust code to access the
2598 environment information via 'gdb_environ' class.
2599 * lynx-low.c (lynx_create_inferior): Likewise.
2600 * server.c (our_environ): Make it an instance of 'gdb_environ'.
2601 (get_environ): Return a pointer to 'our_environ'.
2602 (captured_main): Initialize 'our_environ'.
2603 * server.h (get_environ): Adjust prototype.
2604 * spu-low.c (spu_create_inferior): Adjust code to access the
2605 environment information via 'gdb_environ' class.
2606
2607 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2608
2609 * linux-low.c (linux_read_memory, linux_write_memory): Remove
2610 usage of "register" keyword.
2611
2612 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2613
2614 * configure: Re-generate.
2615
2616 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2617
2618 * configure: Re-generate.
2619
2620 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2621
2622 * Makefile.in (COMPILE.pre): Add "-x c++".
2623
2624 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
2625
2626 * fork-child.c: Conditionally include <signal.h>.
2627
2628 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2629
2630 * server.c (handle_general_set): Handle new packet
2631 "QStartupWithShell".
2632 (handle_query): Add "QStartupWithShell" to the list of supported
2633 packets.
2634 (gdbserver_usage): Add help text explaining the
2635 new "--startup-with-shell" and "--no-startup-with-shell" CLI
2636 options.
2637 (captured_main): Recognize and act upon the presence of the new
2638 CLI options.
2639
2640 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2641 Pedro Alves <palves@redhat.com>
2642
2643 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
2644 * configure: Regenerate.
2645 * configure.srv (srv_linux_obj): Add "fork-child.o" and
2646 "fork-inferior.o".
2647 (i[34567]86-*-lynxos*): Likewise.
2648 (spu*-*-*): Likewise.
2649 * fork-child.c: New file.
2650 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
2651 and "environ.h".
2652 (linux_ptrace_fun): New function.
2653 (linux_create_inferior): Adjust function prototype to reflect
2654 change on "target.h". Adjust function code to use
2655 "fork_inferior".
2656 (linux_request_interrupt): Delete "signal_pid".
2657 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
2658 (lynx_ptrace_fun): New function.
2659 (lynx_create_inferior): Adjust function prototype to reflect
2660 change on "target.h". Adjust function code to use
2661 "fork_inferior".
2662 * nto-low.c (nto_create_inferior): Adjust function prototype and
2663 code to reflect change on "target.h". Update comments.
2664 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
2665 "common-terminal.h" and "environ.h".
2666 (terminal_fd): Moved to fork-child.c.
2667 (old_foreground_pgrp): Likewise.
2668 (restore_old_foreground_pgrp): Likewise.
2669 (last_status): Make it global.
2670 (last_ptid): Likewise.
2671 (our_environ): New variable.
2672 (startup_with_shell): Likewise.
2673 (program_name): Likewise.
2674 (program_argv): Rename to...
2675 (program_args): ...this.
2676 (wrapper_argv): New variable.
2677 (start_inferior): Delete function.
2678 (get_exec_wrapper): New function.
2679 (get_exec_file): Likewise.
2680 (get_environ): Likewise.
2681 (prefork_hook): Likewise.
2682 (post_fork_inferior): Likewise.
2683 (postfork_hook): Likewise.
2684 (postfork_child_hook): Likewise.
2685 (handle_v_run): Update code to deal with arguments coming from the
2686 remote host. Update calls from "start_inferior" to
2687 "create_inferior".
2688 (captured_main): Likewise. Initialize environment variable. Call
2689 "have_job_control".
2690 * server.h (post_fork_inferior): New prototype.
2691 (get_environ): Likewise.
2692 (last_status): Declare.
2693 (last_ptid): Likewise.
2694 (signal_pid): Likewise.
2695 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
2696 (spu_ptrace_fun): New function.
2697 (spu_create_inferior): Adjust function prototype to reflect change
2698 on "target.h". Adjust function code to use "fork_inferior".
2699 * target.c (target_terminal_init): New function.
2700 (target_terminal_inferior): Likewise.
2701 (target_terminal_ours): Likewise.
2702 * target.h: Include <vector>.
2703 (struct target_ops) <create_inferior>: Update prototype.
2704 (create_inferior): Update macro.
2705 * utils.c (gdb_flush_out_err): New function.
2706 * win32-low.c (win32_create_inferior): Adjust function prototype
2707 and code to reflect change on "target.h".
2708
2709 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2710
2711 * inferiors.c (switch_to_thread): New function.
2712
2713 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2714
2715 * Makefile.in (SFILE): Add "common/job-control.c".
2716 (OBS): Add "job-control.o".
2717
2718 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
2719
2720 * Makefile: Remove "@host_makefile_frag@".
2721
2722 2017-05-05 Pedro Alves <palves@redhat.com>
2723
2724 * configure: Regenerate.
2725
2726 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
2727
2728 * configure: Regenerate.
2729
2730 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
2731
2732 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
2733 software_single_step change of return type to
2734 std::vector<CORE_ADDR>.
2735 * linux-low.c (install_software_single_step_breakpoints):
2736 Likewise.
2737 * linux-low.h (install_software_single_step_breakpoints):
2738 Likewise.
2739
2740 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
2741
2742 * remote-utils.c: Include "gdb_termios.h" instead of
2743 "terminal.h".
2744 * terminal.h: Delete file.
2745
2746 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
2747
2748 * server.c: Include <vector>.
2749 <program_argv, wrapper_argv>: Convert to std::vector.
2750 (start_inferior): Rewrite function to use C++.
2751 (handle_v_run): Likewise. Update code that calculates the argv
2752 based on the vRun packet; use C++.
2753 (captured_main): Likewise.
2754
2755 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
2756
2757 * server.c (handle_v_cont): Initialize thread_resume::thread
2758 with null_ptid.
2759
2760 2017-04-05 Pedro Alves <palves@redhat.com>
2761
2762 * configure: Regenerate.
2763
2764 2017-04-05 Pedro Alves <palves@redhat.com>
2765
2766 * gdbreplay.c (sync_error): Constify.
2767 * linux-x86-low.c (push_opcode): Constify.
2768
2769 2017-04-05 Pedro Alves <palves@redhat.com>
2770
2771 * win32-low.c (get_child_debug_event)
2772 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
2773 Report TARGET_WAITKIND_SPURIOUS instead.
2774
2775 2017-04-05 Pedro Alves <palves@redhat.com>
2776
2777 * remote-utils.c (remote_prepare, remote_open): Constify.
2778 * remote-utils.h (remote_prepare, remote_open): Constify.
2779 * server.c (captured_main): Constify 'port' handling.
2780
2781 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
2782
2783 * Makefile.in (clean): Clear .deps.
2784
2785 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
2786
2787 * .gitignore: Remove generated files, replace with wildcard.
2788 * (clean): Replace removal of generated files with wildcard.
2789 (version.c): Replace with...
2790 (version-generated.c): ...this.
2791 (xml-builtin.c): Replace with...
2792 (xml-builtin-generated.c): ...this.
2793 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
2794 (%.c: *regformats*): Replace with...
2795 (%-generated.c: *regformats*): ...this.
2796
2797 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
2798
2799 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
2800 (xtensa_fill_gregset): Call collect_register_by_name for
2801 threadptr register.
2802 (xtensa_store_gregset): Call supply_register_by_name for
2803 threadptr register.
2804
2805 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
2806
2807 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
2808 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
2809 (xtensa_store_gregset): Call supply_register for all registers in
2810 a0_regnum..a0_regnum + C0_NREGS range.
2811
2812 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2813
2814 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
2815 (ax-ipa.o: ax.c): Remove.
2816 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
2817 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
2818 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
2819 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
2820 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
2821
2822 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2823
2824 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
2825 (print-utils-ipa.o: ../common/print-utils.c): Remove.
2826 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
2827 (errors-ipa.o: ../common/errors.c): Remove.
2828 (format-ipa.o: ../common/format.c): Remove.
2829 (common-utils-ipa.o: ../common/common-utils.c): Remove.
2830
2831 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2832
2833 * Makefile.in (%-ipa.o: %.c): New rule.
2834 (tracepoint-ipa.o: tracepoint.c): Remove.
2835 (utils-ipa.o: utils.c): Remove.
2836 (remote-utils-ipa.o: remote-utils.c): Remove.
2837 (regcache-ipa.o: regcache.c): Remove.
2838 (i386-linux-ipa.o: i386-linux.c): Remove.
2839 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
2840 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
2841 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
2842 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
2843 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
2844 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
2845 (amd64-linux-ipa.o: amd64-linux.c): Remove.
2846 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
2847 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
2848 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
2849 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
2850 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
2851 (aarch64-ipa.o: aarch64.c): Remove.
2852 (s390-linux32-ipa.o: s390-linux32.c): Remove.
2853 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
2854 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
2855 (s390-linux64-ipa.o: s390-linux64.c): Remove.
2856 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
2857 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
2858 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
2859 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
2860 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
2861 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
2862 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
2863 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
2864 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
2865 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
2866 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
2867 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
2868 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
2869 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
2870 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
2871 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
2872 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
2873 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
2874 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
2875 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
2876 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
2877 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
2878 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
2879 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
2880 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
2881 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
2882 (tdesc-ipa.o: tdesc.c): Remove.
2883 (x32-linux-ipa.o: x32-linux.c): Remove.
2884 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
2885 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
2886
2887 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2888
2889 * Makefile.in (%.o: ../arch/%.c): New rule.
2890 (arm.o: ../arch/arm.c): Remove.
2891 (arm-linux.o: ../arch/arm-linux.c): Remove.
2892 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
2893 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
2894
2895 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2896
2897 * Makefile.in (%.o: ../nat/%.c): New rule.
2898 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
2899 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
2900 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
2901 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
2902 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
2903 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
2904 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
2905 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
2906 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
2907 (linux-personality.o: ../nat/linux-personality.c): Remove.
2908 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
2909 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
2910 (x86-linux.o: ../nat/x86-linux.c): Remove.
2911 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
2912 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
2913
2914 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2915
2916 * Makefile.in (%.o: ../common/%.c): New rule.
2917 (signals.o: ../common/signals.c): Remove.
2918 (print-utils.o: ../common/print-utils.c): Remove.
2919 (rsp-low.o: ../common/rsp-low.c): Remove.
2920 (common-utils.o: ../common/common-utils.c): Remove.
2921 (posix-strerror.o: ../common/posix-strerror.c): Remove.
2922 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
2923 (vec.o: ../common/vec.c): Remove.
2924 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
2925 (xml-utils.o: ../common/xml-utils.c): Remove.
2926 (ptid.o: ../common/ptid.c): Remove.
2927 (buffer.o: ../common/buffer.c): Remove.
2928 (format.o: ../common/format.c): Remove.
2929 (filestuff.o: ../common/filestuff.c): Remove.
2930 (agent.o: ../common/agent.c): Remove.
2931 (errors.o: ../common/errors.c): Remove.
2932 (environ.o: ../common/environ.c): Remove.
2933 (common-debug.o: ../common/common-debug.c): Remove.
2934 (cleanups.o: ../common/cleanups.c): Remove.
2935 (common-exceptions.o: ../common/common-exceptions.c): Remove.
2936 (fileio.o: ../common/fileio.c): Remove.
2937 (common-regcache.o: ../common/common-regcache.c): Remove.
2938 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
2939 (new-op.o: ../common/new-op.c): Remove.
2940 (btrace-common.o: ../common/btrace-common.c): Remove.
2941
2942 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2943
2944 * Makefile.in (%.o: ../target/%.c): New rule.
2945 (waitstatus.o: ../target/waitstatus.c): Remove.
2946
2947 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2948
2949 * Makefile.in
2950 (%.c: ../regformats/%.dat,
2951 (%.c: ../regformats/arm/%.dat,
2952 (%.c: ../regformats/i386/%.dat,
2953 (%.c: ../regformats/rs6000/%.dat): New rules.
2954 (aarch64.c): Remove.
2955 (reg-arm.c): Remove.
2956 (arm-with-iwmmxt.c): Remove.
2957 (arm-with-vfpv2.c): Remove.
2958 (arm-with-vfpv3.c): Remove.
2959 (arm-with-neon.c): Remove.
2960 (reg-bfin.c): Remove.
2961 (reg-cris.c): Remove.
2962 (reg-crisv32.c): Remove.
2963 (i386.c): Remove.
2964 (i386-linux.c): Remove.
2965 (i386-avx.c): Remove.
2966 (i386-avx-linux.c): Remove.
2967 (i386-avx-avx512.c): Remove.
2968 (i386-avx-avx512-linux.c): Remove.
2969 (i386-mpx.c): Remove.
2970 (i386-mpx-linux.c): Remove.
2971 (i386-avx-mpx-avx512-pku.c): Remove.
2972 (i386-avx-mpx-avx512-pku-linux.c): Remove.
2973 (i386-avx-mpx.c): Remove.
2974 (i386-avx-mpx-linux.c): Remove.
2975 (i386-mmx.c): Remove.
2976 (i386-mmx-linux.c): Remove.
2977 (reg-ia64.c): Remove.
2978 (reg-m32r.c): Remove.
2979 (reg-m68k.c): Remove.
2980 (reg-cf.c): Remove.
2981 (mips-linux.c): Remove.
2982 (mips-dsp-linux.c): Remove.
2983 (mips64-linux.c): Remove.
2984 (mips64-dsp-linux.c): Remove.
2985 (nios2-linux.c): Remove.
2986 (powerpc-32.c): Remove.
2987 (powerpc-32l.c): Remove.
2988 (powerpc-altivec32l.c): Remove.
2989 (powerpc-cell32l.c): Remove.
2990 (powerpc-vsx32l.c): Remove.
2991 (powerpc-isa205-32l.c): Remove.
2992 (powerpc-isa205-altivec32l.c): Remove.
2993 (powerpc-isa205-vsx32l.c): Remove.
2994 (powerpc-e500l.c): Remove.
2995 (powerpc-64l.c): Remove.
2996 (powerpc-altivec64l.c): Remove.
2997 (powerpc-cell64l.c): Remove.
2998 (powerpc-vsx64l.c): Remove.
2999 (powerpc-isa205-64l.c): Remove.
3000 (powerpc-isa205-altivec64l.c): Remove.
3001 (powerpc-isa205-vsx64l.c): Remove.
3002 (s390-linux32.c): Remove.
3003 (s390-linux32v1.c): Remove.
3004 (s390-linux32v2.c): Remove.
3005 (s390-linux64.c): Remove.
3006 (s390-linux64v1.c): Remove.
3007 (s390-linux64v2.c): Remove.
3008 (s390-te-linux64.c): Remove.
3009 (s390-vx-linux64.c): Remove.
3010 (s390-tevx-linux64.c): Remove.
3011 (s390x-linux64.c): Remove.
3012 (s390x-linux64v1.c): Remove.
3013 (s390x-linux64v2.c): Remove.
3014 (s390x-te-linux64.c): Remove.
3015 (s390x-vx-linux64.c): Remove.
3016 (s390x-tevx-linux64.c): Remove.
3017 (tic6x-c64xp-linux.c): Remove.
3018 (tic6x-c64x-linux.c): Remove.
3019 (tic6x-c62x-linux.c): Remove.
3020 (reg-sh.c): Remove.
3021 (reg-sparc64.c): Remove.
3022 (reg-spu.c): Remove.
3023 (amd64.c): Remove.
3024 (amd64-linux.c): Remove.
3025 (amd64-avx.c): Remove.
3026 (amd64-avx-linux.c): Remove.
3027 (amd64-avx-avx512.c): Remove.
3028 (amd64-avx-avx512-linux.c): Remove.
3029 (amd64-mpx.c): Remove.
3030 (amd64-mpx-linux.c): Remove.
3031 (amd64-avx-mpx-avx512-pku.c): Remove.
3032 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
3033 (amd64-avx-mpx.c): Remove.
3034 (amd64-avx-mpx-linux.c): Remove.
3035 (x32.c): Remove.
3036 (x32-linux.c): Remove.
3037 (x32-avx.c): Remove.
3038 (x32-avx-linux.c): Remove.
3039 (x32-avx-avx512.c): Remove.
3040 (x32-avx-avx512-linux.c): Remove.
3041 (reg-xtensa.c): Remove.
3042 (reg-tilegx.c): Remove.
3043 (reg-tilegx32.c): Remove.
3044
3045 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
3046
3047 * Makefile.in (SFILES): Add "common/environ.c".
3048 (OBJS): Add "common/environ.h".
3049
3050 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
3051
3052 * configure.ac: Check if the fs_base and gs_base members of
3053 `struct user_regs_struct' exist.
3054 * config.in: Regenerated.
3055 * configure: Likewise.
3056
3057 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
3058
3059 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
3060 target_read_memory.
3061 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
3062 (get_next_pcs_syscall_next_pc): Likewise.
3063
3064 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
3065
3066 * win32-i386-low.c: Fix incorrect reference to a couple source files.
3067 * nto-x86-low.c: Likewise.
3068
3069 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
3070
3071 * Makefile.in: Include disable-implicit-rules.mk.
3072
3073 2016-11-23 Pedro Alves <palves@redhat.com>
3074
3075 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
3076 (debug_vprintf): Use std::chrono::steady_clock instead of
3077 gettimeofday. Use '.' instead of ':'.
3078 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
3079 (get_timestamp): Use std::chrono::steady_clock instead of
3080 gettimeofday.
3081
3082 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
3083
3084 * Makefile.in: Fix whitespace formatting.
3085
3086 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
3087
3088 * Makefile.in (SFILES, OBS): Flatten list and order
3089 alphabetically.
3090
3091 2016-11-23 Pedro Alves <palves@redhat.com>
3092
3093 * event-loop.c (handle_file_event): Use warning.
3094 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
3095 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
3096 Use warning.
3097
3098 2016-11-23 Pedro Alves <palves@redhat.com>
3099
3100 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
3101 output.
3102 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
3103 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
3104 debug_printf and debug_flush for debug output.
3105 * server.c (handle_general_set): Likewise.
3106 * thread-db.c (try_thread_db_load): Use debug_printf for debug
3107 output.
3108
3109 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
3110
3111 * Makefile.in (.c.o): Replace rule with ...
3112 (%.o: %.c): ... this one.
3113
3114 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
3115
3116 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
3117 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
3118 make.
3119 * configure.ac: Remove checks for the make program.
3120 * configure: Re-generate.
3121
3122 2016-10-28 Pedro Alves <palves@redhat.com>
3123
3124 * Makefile.in (CXX_DIALECT): Get from configure.
3125 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
3126 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
3127 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
3128 * config.in: Regenerate.
3129 * configure: Regenerate.
3130
3131 2016-10-27 Yao Qi <yao.qi@linaro.org>
3132
3133 * linux-low.c (linux_supports_range_stepping): Return true if
3134 can_software_single_step return true.
3135
3136 2016-10-27 Yao Qi <yao.qi@linaro.org>
3137
3138 * inferiors.c (find_inferior_in_random): New function.
3139 * inferiors.h (find_inferior_in_random): Declare.
3140 * linux-low.c (linux_wait_for_event_filtered): Call
3141 find_inferior_in_random instead of find_inferior.
3142
3143 2016-10-27 Yao Qi <yao.qi@linaro.org>
3144
3145 * linux-low.c (linux_wait_1): If single-step breakpoints are
3146 inserted, remove them.
3147
3148 2016-10-26 Pedro Alves <palves@redhat.com>
3149
3150 * linux-low.c (handle_extended_wait): Link parent/child fork
3151 threads.
3152 (linux_wait_1): Unlink them.
3153 (linux_set_resume_request): Ignore resume requests for
3154 already-resumed and unhandled fork child threads.
3155 * linux-low.h (struct lwp_info) <fork_relative>: New field.
3156 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
3157 New functions.
3158 (handle_v_requests) <vCont>: Don't call require_running.
3159 * server.h (in_queued_stop_replies): New declaration.
3160
3161 2016-10-24 Yao Qi <yao.qi@linaro.org>
3162
3163 PR server/20733
3164 * linux-aarch64-low.c (append_insns): Cast the return value to
3165 'uint32_t *'.
3166
3167 2016-10-10 Yao Qi <yao.qi@linaro.org>
3168
3169 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
3170
3171 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
3172
3173 * target.c (target_supports_multi_process): New function, moved
3174 from...
3175 * target.h (target_supports_multi_process): ... here. Remove
3176 macro.
3177
3178 2016-10-05 Tom Tromey <tom@tromey.com>
3179
3180 PR remote/20655:
3181 * tracepoint.c (handle_tracepoint_bkpts): Check
3182 ipa_error_tracepoint, not ipa_stopping_tracepoint.
3183
3184 2016-10-05 Yao Qi <yao.qi@linaro.org>
3185
3186 * configure.srv: Update the path of arm-*.xml files.
3187
3188 2016-10-05 Terry Guo <terry.guo@arm.com>
3189 Yao Qi <yao.qi@linaro.org>
3190
3191 * Makefile.in: Adjust the path of rules.
3192 * configure.srv: Update the path of xml files.
3193 * regformats/arm-with-iwmmxt.dat: Regenerated.
3194 * regformats/arm-with-neon.dat: Likewise.
3195 * regformats/arm-with-vfpv2.dat: Likewise.
3196 * regformats/arm-with-vfpv3.dat Likewise.
3197
3198 2016-09-30 Yao Qi <yao.qi@linaro.org>
3199
3200 PR gdbserver/20627
3201 * target.c (target_stop_and_wait): Don't call
3202 target_continue_no_signal, use resume_stop instead.
3203
3204 2016-09-26 Yao Qi <yao.qi@linaro.org>
3205
3206 * linux-low.c (linux_wait_1): Call debug_exit.
3207
3208 2016-09-23 Pedro Alves <palves@redhat.com>
3209
3210 * Makefile.in (SFILES): Add common/new-op.c.
3211 (OBS): Add common/new-op.o.
3212 (new-op.o): New rule.
3213
3214 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
3215
3216 * .gitinore: Ignore more files.
3217
3218 2016-09-21 Yao Qi <yao.qi@linaro.org>
3219
3220 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
3221 23.
3222
3223 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
3224
3225 * server.c (start_inferior): Call target_mourn_inferior instead of
3226 mourn_inferior; pass ptid_t argument to it.
3227 (resume): Likewise.
3228 (handle_target_event): Likewise.
3229 * target.c (target_mourn_inferior): New function.
3230 * target.h (mourn_inferior): Delete macro.
3231
3232 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
3233
3234 * linux-low.c (lwp_is_stepping): New function.
3235
3236 2016-09-06 Carl Love <cel@us.ibm.com>
3237
3238 * server.c (start_inferior): Fixed comment, requested comment change
3239 didn't get updated correctly. Removed reference to ptrace () call as
3240 it is only true on Linux systems.
3241
3242 2016-09-06 Carl Love <cel@us.ibm.com>
3243
3244 * server.c (start_inferior): Do not call
3245 function target_post_create_inferior () if the
3246 inferior process has already exited.
3247
3248 2016-09-05 Pedro Alves <palves@redhat.com>
3249
3250 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
3251 (COMPILE.pre, CC_LD): Use CXX directly.
3252 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
3253 * acinclude.m4: Don't include build-with-cxx.m4.
3254 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
3255 * configure: Regenerate.
3256
3257 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
3258
3259 PR gdb/19495
3260 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
3261 call writing data to own_buf.
3262
3263 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
3264
3265 * target.c (mywait): Call target_wait instead of
3266 the_target->wait.
3267 (target_wait): New function.
3268
3269 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
3270
3271 * server.c (start_inferior): New variable 'ptid'. Replace calls
3272 to the_target->resume by target_continue{,_no_signal}, depending
3273 on the case.
3274 * target.c (target_stop_and_wait): Call target_continue_no_signal
3275 instead of the_target->resume.
3276 (target_continue): New function.
3277
3278 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
3279
3280 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
3281
3282 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
3283
3284 PR server/20491
3285 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
3286 ps_prochandle.
3287 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
3288 * linux-arm-low.c (ps_get_thread_area): Likewise.
3289 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
3290 * linux-m68k-low.c (ps_get_thread_area): Likewise.
3291 * linux-mips-low.c (ps_get_thread_area): Likewise.
3292 * linux-nios2-low.c (ps_get_thread_area): Likewise.
3293 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
3294 * linux-x86-low.c (ps_get_thread_area): Likewise.
3295 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
3296
3297 2016-08-19 Pedro Alves <palves@redhat.com>
3298
3299 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
3300
3301 2016-08-19 Pedro Alves <palves@redhat.com>
3302
3303 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
3304 comment. Use memcpy instead of casting through unsigned long.
3305
3306 2016-08-19 Pedro Alves <palves@redhat.com>
3307
3308 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
3309 allocating around 0x80000000.
3310
3311 2016-08-19 Pedro Alves <palves@redhat.com>
3312
3313 PR gdb/20415
3314 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
3315 (x32-avx512-linux-ipa.o): New rules.
3316 * configure.ac (x86_64-*-linux*): New x32 check.
3317 * configure.srv (ipa_x32_linux_regobj): New.
3318 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
3319 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
3320 descriptions.
3321 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
3322 descriptions.
3323 * configure: Regenerate.
3324
3325 2016-08-09 Pedro Alves <palves@redhat.com>
3326
3327 PR gdb/18653
3328 * Makefile.in (OBS): Add signals-state-save-restore.o.
3329 (signals-state-save-restore.o): New rule.
3330 * config.in: Regenerate.
3331 * configure: Regenerate.
3332 * linux-low.c: Include "signals-state-save-restore.h".
3333 (linux_create_inferior): Call
3334 restore_original_signals_state.
3335 * server.c: Include "dispositions-save-restore.h".
3336 (captured_main): Call save_original_signals_state.
3337
3338 2016-08-05 Pedro Alves <palves@redhat.com>
3339
3340 * configure: Regenerate.
3341
3342 2016-08-04 Yao Qi <yao.qi@linaro.org>
3343
3344 * linux-low.c (regsets_fetch_inferior_registers): Check
3345 errno is ESRCH or not.
3346
3347 2016-08-02 Yao Qi <yao.qi@linaro.org>
3348
3349 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
3350 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
3351 (thread_db_load_search): Update.
3352 (try_thread_db_load_1): Don't look for td_ta_event_addr,
3353 td_ta_set_event and td_ta_event_getmsg.
3354
3355 2016-07-26 Pedro Alves <palves@redhat.com>
3356
3357 PR server/20414
3358 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
3359 of unsigned long for 64-bit registers and use uint32_t instead of
3360 unsigned int for 32-bit registers.
3361
3362 2016-07-26 Pedro Alves <palves@redhat.com>
3363
3364 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
3365 to 'ptrace'.
3366
3367 2016-07-21 Tom Tromey <tom@tromey.com>
3368
3369 * configure: Rebuild.
3370
3371 2016-07-21 Yao Qi <yao.qi@linaro.org>
3372
3373 * mem-break.c (find_gdb_breakpoint): Cast bp to
3374 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
3375
3376 2016-07-21 Yao Qi <yao.qi@linaro.org>
3377
3378 * server.c (handle_v_requests): Support s and S actions
3379 if target_supports_software_single_step return true.
3380
3381 2016-07-21 Yao Qi <yao.qi@linaro.org>
3382
3383 * linux-low.c (resume_stopped_resumed_lwps): If resume request
3384 is resume_step, call maybe_hw_step.
3385 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
3386 and unstop them.
3387 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
3388 breakpoints or not.
3389 (proceed_one_lwp): If resume request is resume_step, install
3390 reinsert breakpoints and call maybe_hw_step.
3391
3392 2016-07-21 Yao Qi <yao.qi@linaro.org>
3393
3394 * linux-low.c (proceed_one_lwp): Declare.
3395 (linux_resume_one_thread): Remove local variable 'step'.
3396 Lift code enqueue signal. Call proceed_one_lwp instead of
3397 linux_resume_one_lwp.
3398
3399 2016-07-21 Yao Qi <yao.qi@linaro.org>
3400
3401 * linux-low.c (linux_resume_one_thread): Call
3402 enqueue_pending_signal.
3403
3404 2016-07-21 Yao Qi <yao.qi@linaro.org>
3405
3406 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
3407 * inferiors.c (do_restore_current_thread_cleanup): New function.
3408 (make_cleanup_restore_current_thread): Likewise.
3409 * linux-low.c (install_software_single_step_breakpoints): Call
3410 make_cleanup_restore_current_thread. Switch current_thread to
3411 thread.
3412
3413 2016-07-21 Yao Qi <yao.qi@linaro.org>
3414
3415 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
3416 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
3417 (clone_one_breakpoint): Likewise.
3418 (delete_reinsert_breakpoints): Change parameter to thread.
3419 Callers updated.
3420 (has_reinsert_breakpoints): Likewise.
3421 (uninsert_reinsert_breakpoints): Likewise.
3422 (reinsert_reinsert_breakpoints): Likewise.
3423 * mem-break.h (set_reinsert_breakpoint): Update declaration.
3424 (delete_reinsert_breakpoints): Likewise.
3425 (reinsert_reinsert_breakpoints): Likewise.
3426 (uninsert_reinsert_breakpoints): Likewise.
3427 (has_reinsert_breakpoints): Likewise.
3428
3429 2016-07-21 Yao Qi <yao.qi@linaro.org>
3430
3431 * inferiors.c (get_thread_process): Make parameter const.
3432 * inferiors.h (get_thread_process): Update declaration.
3433 * mem-break.c (clone_all_breakpoints): Remove all parameters.
3434 Add new parameters child_thread and parent_thread. Callers
3435 updated.
3436 * mem-break.h (clone_all_breakpoints): Update declaration.
3437
3438 2016-07-21 Yao Qi <yao.qi@linaro.org>
3439
3440 * mem-break.c (struct breakpoint) <cond_list>: Remove.
3441 <command_list, handler>: Remove.
3442 (struct gdb_breakpoint): New.
3443 (struct other_breakpoint): New.
3444 (struct reinsert_breakpoint): New.
3445 (is_gdb_breakpoint): New function.
3446 (any_persistent_commands): Update command_list if
3447 is_gdb_breakpoint returns true.
3448 (set_breakpoint): Create breakpoints according to their types.
3449 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
3450 (set_gdb_breakpoint_1): Likewise.
3451 (set_gdb_breakpoint): Likewise.
3452 (clear_breakpoint_conditions): Change parameter type to
3453 'struct gdb_breakpoint *'.
3454 (clear_breakpoint_commands): Likewise.
3455 (clear_breakpoint_conditions_and_commands): Likewise.
3456 (add_condition_to_breakpoint): Likewise.
3457 (add_breakpoint_condition): Likewise.
3458 (add_commands_to_breakpoint): Likewise.
3459 (check_breakpoints): Check other_breakpoint.
3460 (clone_one_breakpoint): Clone breakpopint according to its type.
3461 * mem-break.h (struct gdb_breakpoint): Declare.
3462 (set_gdb_breakpoint): Update declaration.
3463 (clear_breakpoint_conditions_and_commands): Likewise.
3464 (add_breakpoint_condition): Likewise.
3465 (add_breakpoint_commands): Likewise.
3466 * server.c (process_point_options): Change parameter type to
3467 'struct gdb_breakpoint *'.
3468
3469 2016-07-21 Yao Qi <yao.qi@linaro.org>
3470
3471 * mem-break.c (set_breakpoint_at): Rename it to ...
3472 (set_breakpoint_type_at): ... it.
3473 (set_breakpoint_at): Call set_breakpoint_type_at.
3474 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
3475 * mem-break.h (set_breakpoint_at): Update comments.
3476
3477 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
3478
3479 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
3480 to buf parameter.
3481 (nios2_store_gregset): Likewise.
3482
3483 2016-07-01 Pedro Alves <palves@redhat.com>
3484 Antoine Tremblay <antoine.tremblay@ericsson.com>
3485
3486 * linux-low.c: Change interface to take the target lwp_info
3487 pointer directly and return void. Handle detaching from a zombie
3488 thread.
3489 (linux_detach_lwp_callback): New function.
3490 (linux_detach): Detach from the leader thread after detaching from
3491 the clone threads.
3492
3493 2016-06-28 Yao Qi <yao.qi@linaro.org>
3494
3495 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
3496 for variable new_offset.
3497 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
3498 (aarch64_ftrace_insn_reloc_cb): Likewise.
3499 (aarch64_ftrace_insn_reloc_tb): Likewise.
3500 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
3501 PRIx64 instead of PRIx32.
3502
3503 2016-06-28 Yao Qi <yao.qi@linaro.org>
3504
3505 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
3506 (the_low_target): Install arm_get_syscall_trapinfo.
3507
3508 2016-06-28 Yao Qi <yao.qi@linaro.org>
3509
3510 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
3511 function.
3512 (the_low_target): Install aarch64_get_syscall_trapinfo.
3513
3514 2016-06-28 Yao Qi <yao.qi@linaro.org>
3515
3516 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
3517 Callers updated.
3518 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
3519 Remove parameter sysno.
3520 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
3521 sysret.
3522
3523 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
3524
3525 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
3526 (s390_emit_ne_goto): Likewise.
3527 (s390_emit_lt_goto): Likewise.
3528 (s390_emit_le_goto): Likewise.
3529 (s390_emit_gt_goto): Likewise.
3530 (s390_emit_ge_goto): Likewise.
3531 (s390x_emit_eq_goto): Likewise.
3532 (s390x_emit_ne_goto): Likewise.
3533 (s390x_emit_lt_goto): Likewise.
3534 (s390x_emit_le_goto): Likewise.
3535 (s390x_emit_gt_goto): Likewise.
3536 (s390x_emit_ge_goto): Likewise.
3537 (s390_emit_ops_impl): Mark variable static.
3538 (s390x_emit_ops): Likewise.
3539
3540 2016-06-17 Yao Qi <yao.qi@linaro.org>
3541
3542 * linux-low.c (handle_extended_wait): Call
3543 uninsert_reinsert_breakpoints for the parent process. Remove
3544 reinsert breakpoints from the child process. Reinsert them to
3545 the parent process when vfork is done.
3546 * mem-break.c (uninsert_reinsert_breakpoints): New function.
3547 (reinsert_reinsert_breakpoints): New function.
3548 * mem-break.h (uninsert_reinsert_breakpoints): Declare
3549 (reinsert_reinsert_breakpoints): Declare.
3550
3551 2016-06-17 Yao Qi <yao.qi@linaro.org>
3552
3553 * linux-low.c (handle_extended_wait): If the parent is doing
3554 step-over, remove the reinsert breakpoints from the forked child.
3555
3556 2016-06-17 Yao Qi <yao.qi@linaro.org>
3557
3558 * linux-low.c (unsuspend_all_lwps): Declare.
3559 (linux_low_filter_event): If thread exited, call finish_step_over.
3560 If step-over is finished, unsuspend other threads.
3561
3562 2016-06-17 Yao Qi <yao.qi@linaro.org>
3563
3564 * linux-low.c (linux_resume_one_lwp_throw): Assert
3565 has_reinsert_breakpoints returns false.
3566 * mem-break.c (delete_disabled_breakpoints): Assert
3567 bp type isn't reinsert_breakpoint.
3568
3569 2016-06-17 Yao Qi <yao.qi@linaro.org>
3570
3571 * linux-low.c (maybe_hw_step): New function.
3572 (linux_resume_one_lwp_throw): Call maybe_hw_step.
3573 (finish_step_over): Switch current_thread to lwp temporarily,
3574 and assert has_reinsert_breakpoints returns true.
3575 (proceed_one_lwp): Call maybe_hw_step.
3576 * mem-break.c (has_reinsert_breakpoints): New function.
3577 * mem-break.h (has_reinsert_breakpoints): Declare.
3578
3579 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
3580
3581 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
3582
3583 2016-05-17 Yao Qi <yao.qi@linaro.org>
3584
3585 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
3586 instead of find_inferior.
3587
3588 2016-05-05 Yao Qi <yao.qi@linaro.org>
3589
3590 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
3591 Initialize res to zero.
3592
3593 2016-05-05 Yao Qi <yao.qi@linaro.org>
3594
3595 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
3596 to uint32_t.
3597
3598 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
3599
3600 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
3601 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
3602 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
3603
3604 2016-04-28 Par Olsson <par.olsson@windriver.com>
3605 Simon Marchi <simon.marchi@ericsson.com>
3606
3607 * tracepoint.c (write_inferior_int8): New function.
3608 (cmd_qtenable_disable): Write enable flag using
3609 write_inferior_int8.
3610
3611 2016-04-25 Yao Qi <yao.qi@linaro.org>
3612
3613 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
3614 (need_step_over_p): Return zero if the LWP has pending signals
3615 can be delivered on software single step target.
3616
3617 2016-04-25 Yao Qi <yao.qi@linaro.org>
3618
3619 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
3620 return instead of error.
3621
3622 2016-04-22 Yao Qi <yao.qi@linaro.org>
3623
3624 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
3625 to 23.
3626
3627 2016-04-22 Yao Qi <yao.qi@linaro.org>
3628
3629 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
3630 signal when stepping over breakpoint with software single
3631 step.
3632
3633 2016-04-21 Pedro Alves <palves@redhat.com>
3634
3635 * linux-s390-low.c (s390_collect_ptrace_register)
3636 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
3637 add casts.
3638 (s390_check_regset): Use void * instead of gdb_byte *.
3639
3640 2016-04-20 Pedro Alves <palves@redhat.com>
3641
3642 * configure: Renegerate.
3643
3644 2016-04-20 Yao Qi <yao.qi@linaro.org>
3645
3646 * linux-aarch32-low.c: Include "arch/arm-linux.h".
3647 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
3648 number 16.
3649 (arm_store_gregset): Likewise.
3650
3651 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
3652
3653 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
3654 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
3655 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
3656 (amd64-avx-mpx-linux.c): New rules.
3657 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
3658 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
3659 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
3660 (srv_amd64_regobj): Add amd64-avx-mpx.o.
3661 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
3662 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
3663 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
3664 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
3665 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
3666 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
3667 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
3668 * linux-x86-low.c (x86_linux_read_description): Add case for
3669 X86_XSTATE_AVX_MPX_MASK.
3670 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
3671 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
3672 init_registers_i386_avx_mpx_linux.
3673 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
3674 (initialize_low_tracepoint): Call
3675 init_registers_i386_avx_mpx_linux.
3676 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
3677 (initialize_low_tracepoint): Call
3678 init_registers_amd64_avx_mpx_linux.
3679 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
3680 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
3681 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
3682 declarations.
3683
3684 2016-04-18 Pedro Alves <palves@redhat.com>
3685
3686 * configure: Regenerate.
3687
3688 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
3689
3690 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
3691 (aarch64_emit_sub): Likewise.
3692
3693 2016-04-12 Pedro Alves <palves@redhat.com>
3694
3695 * utils.c (prepare_to_throw_exception): Delete.
3696
3697 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
3698
3699 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
3700
3701 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
3702
3703 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
3704
3705 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
3706
3707 * linux-aarch64-ipa.c: Add <elf.h> include.
3708 * linux-ppc-ipa.c: Add <elf.h> include.
3709 * linux-s390-ipa.c: Add <elf.h> include.
3710
3711 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
3712
3713 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
3714 (get_raw_reg_ptr): Likewise.
3715 (get_trace_state_variable_value_ptr): Likewise.
3716 (set_trace_state_variable_value_ptr): Likewise.
3717 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
3718 char *.
3719
3720 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
3721 Marcin Kościelnicki <koriakin@0x04.net>
3722
3723 PR/17221
3724 * linux-ppc-low.c (emit_insns): New function.
3725 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
3726 (ppc_emit_prologue): New function.
3727 (ppc_emit_epilogue): New function.
3728 (ppc_emit_add): New function.
3729 (ppc_emit_sub): New function.
3730 (ppc_emit_mul): New function.
3731 (ppc_emit_lsh): New function.
3732 (ppc_emit_rsh_signed): New function.
3733 (ppc_emit_rsh_unsigned): New function.
3734 (ppc_emit_ext): New function.
3735 (ppc_emit_zero_ext): New function.
3736 (ppc_emit_log_not): New function.
3737 (ppc_emit_bit_and): New function.
3738 (ppc_emit_bit_or): New function.
3739 (ppc_emit_bit_xor): New function.
3740 (ppc_emit_bit_not): New function.
3741 (ppc_emit_equal): New function.
3742 (ppc_emit_less_signed): New function.
3743 (ppc_emit_less_unsigned): New function.
3744 (ppc_emit_ref): New function.
3745 (ppc_emit_const): New function.
3746 (ppc_emit_reg): New function.
3747 (ppc_emit_pop): New function.
3748 (ppc_emit_stack_flush): New function.
3749 (ppc_emit_swap): New function.
3750 (ppc_emit_stack_adjust): New function.
3751 (ppc_emit_call): New function.
3752 (ppc_emit_int_call_1): New function.
3753 (ppc_emit_void_call_2): New function.
3754 (ppc_emit_if_goto): New function.
3755 (ppc_emit_goto): New function.
3756 (ppc_emit_eq_goto): New function.
3757 (ppc_emit_ne_goto): New function.
3758 (ppc_emit_lt_goto): New function.
3759 (ppc_emit_le_goto): New function.
3760 (ppc_emit_gt_goto): New function.
3761 (ppc_emit_ge_goto): New function.
3762 (ppc_write_goto_address): New function.
3763 (ppc_emit_ops_impl): New static variable.
3764 (ppc64v1_emit_prologue): New function.
3765 (ppc64v2_emit_prologue): New function.
3766 (ppc64_emit_epilogue): New function.
3767 (ppc64_emit_add): New function.
3768 (ppc64_emit_sub): New function.
3769 (ppc64_emit_mul): New function.
3770 (ppc64_emit_lsh): New function.
3771 (ppc64_emit_rsh_signed): New function.
3772 (ppc64_emit_rsh_unsigned): New function.
3773 (ppc64_emit_ext): New function.
3774 (ppc64_emit_zero_ext): New function.
3775 (ppc64_emit_log_not): New function.
3776 (ppc64_emit_bit_and): New function.
3777 (ppc64_emit_bit_or): New function.
3778 (ppc64_emit_bit_xor): New function.
3779 (ppc64_emit_bit_not): New function.
3780 (ppc64_emit_equal): New function.
3781 (ppc64_emit_less_signed): New function.
3782 (ppc64_emit_less_unsigned): New function.
3783 (ppc64_emit_ref): New function.
3784 (ppc64_emit_const): New function.
3785 (ppc64v1_emit_reg): New function.
3786 (ppc64v2_emit_reg): New function.
3787 (ppc64_emit_pop): New function.
3788 (ppc64_emit_stack_flush): New function.
3789 (ppc64_emit_swap): New function.
3790 (ppc64v1_emit_call): New function.
3791 (ppc64v2_emit_call): New function.
3792 (ppc64v1_emit_int_call_1): New function.
3793 (ppc64v2_emit_int_call_1): New function.
3794 (ppc64v1_emit_void_call_2): New function.
3795 (ppc64v2_emit_void_call_2): New function.
3796 (ppc64_emit_if_goto): New function.
3797 (ppc64_emit_eq_goto): New function.
3798 (ppc64_emit_ne_goto): New function.
3799 (ppc64_emit_lt_goto): New function.
3800 (ppc64_emit_le_goto): New function.
3801 (ppc64_emit_gt_goto): New function.
3802 (ppc64_emit_ge_goto): New function.
3803 (ppc64v1_emit_ops_impl): New static variable.
3804 (ppc64v2_emit_ops_impl): New static variable.
3805 (ppc_emit_ops): New function.
3806 (linux_low_target): Wire in ppc_emit_ops.
3807
3808 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
3809 Marcin Kościelnicki <koriakin@0x04.net>
3810
3811 PR/17221
3812 * Makefile.in: Add powerpc-*-ipa.o
3813 * configure.srv: Add ipa_obj for powerpc*-linux.
3814 * linux-ppc-ipa.c: New file.
3815 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
3816 includes.
3817 (PPC_FIELD): New macro.
3818 (PPC_SEXT): New macro.
3819 (PPC_OP6): New macro.
3820 (PPC_BO): New macro.
3821 (PPC_LI): New macro.
3822 (PPC_BD): New macro.
3823 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
3824 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
3825 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
3826 (ppc_get_thread_area): New function.
3827 (is_elfv2_inferior): New function.
3828 (gen_ds_form): New function.
3829 (GEN_STD): New macro.
3830 (GEN_STDU): New macro.
3831 (GEN_LD): New macro.
3832 (GEN_LDU): New macro.
3833 (gen_d_form): New function.
3834 (GEN_ADDI): New macro.
3835 (GEN_ADDIS): New macro.
3836 (GEN_LI): New macro.
3837 (GEN_LIS): New macro.
3838 (GEN_ORI): New macro.
3839 (GEN_ORIS): New macro.
3840 (GEN_LWZ): New macro.
3841 (GEN_STW): New macro.
3842 (GEN_STWU): New macro.
3843 (gen_xfx_form): New function.
3844 (GEN_MFSPR): New macro.
3845 (GEN_MTSPR): New macro.
3846 (GEN_MFCR): New macro.
3847 (GEN_MTCR): New macro.
3848 (GEN_SYNC): New macro.
3849 (GEN_LWSYNC): New macro.
3850 (gen_x_form): New function.
3851 (GEN_OR): New macro.
3852 (GEN_MR): New macro.
3853 (GEN_LWARX): New macro.
3854 (GEN_STWCX): New macro.
3855 (GEN_CMPW): New macro.
3856 (gen_md_form): New function.
3857 (GEN_RLDICL): New macro.
3858 (GEN_RLDICR): New macro.
3859 (gen_i_form): New function.
3860 (GEN_B): New macro.
3861 (GEN_BL): New macro.
3862 (gen_b_form): New function.
3863 (GEN_BNE): New macro.
3864 (GEN_LOAD): New macro.
3865 (GEN_STORE): New macro.
3866 (gen_limm): New function.
3867 (gen_atomic_xchg): New function.
3868 (gen_call): New function.
3869 (ppc_relocate_instruction): New function.
3870 (ppc_install_fast_tracepoint_jump_pad): New function.
3871 (ppc_get_min_fast_tracepoint_insn_len): New function.
3872 (ppc_get_ipa_tdesc_idx): New function.
3873 (the_low_target): Wire in the new functions.
3874 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
3875 tdescs.
3876 * linux-ppc-tdesc.h: New file.
3877
3878 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
3879
3880 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
3881 (alloc_jump_pad_buffer): New function.
3882 * linux-amd64-ipa.c: Add <sys/mman.h> include.
3883 (alloc_jump_pad_buffer): New function.
3884 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
3885 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
3886 (alloc_jump_pad_buffer): New function.
3887 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
3888 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
3889 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
3890 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
3891
3892 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
3893
3894 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
3895 * linux-amd64-ipa.c: Likewise.
3896 * linux-i386-ipa.c: Likewise.
3897 * linux-s390-ipa.c: Likewise.
3898 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
3899 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
3900 set_trace_state_variable_value_ptr.
3901 (struct ipa_sym_addresses): Likewise.
3902 (symbol_list): Likewise.
3903 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
3904 accessing gdb_collect directly.
3905 (gdb_collect_ptr_type): New typedef.
3906 (get_raw_reg_ptr_type): New typedef.
3907 (get_trace_state_variable_value_ptr_type): New typedef.
3908 (set_trace_state_variable_value_ptr_type): New typedef.
3909 (gdb_collect_ptr): New global.
3910 (get_raw_reg_ptr): New global.
3911 (get_trace_state_variable_value_ptr): New global.
3912 (set_trace_state_variable_value_ptr): New global.
3913 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
3914 accessing get_raw_reg directly.
3915 (get_get_tsv_func_addr): Likewise for
3916 get_trace_state_variable_value_ptr.
3917 (get_set_tsv_func_addr): Likewise for
3918 set_trace_state_variable_value_ptr.
3919 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
3920
3921 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
3922
3923 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
3924
3925 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
3926
3927 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
3928 packets.
3929 (relocate_instruction): Remove own_buf.
3930 * server.c (own_buf): Make global.
3931 (handle_v_requests): Make global.
3932 * server.h (own_buf): New declaration.
3933 (handle_v_requests): New prototype.
3934
3935 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
3936
3937 PR 18377
3938 * linux-s390-low.c (add_insns): New function.
3939 (s390_emit_prologue): New function.
3940 (s390_emit_epilogue): New function.
3941 (s390_emit_add): New function.
3942 (s390_emit_sub): New function.
3943 (s390_emit_mul): New function.
3944 (s390_emit_lsh): New function.
3945 (s390_emit_rsh_signed): New function.
3946 (s390_emit_rsh_unsigned): New function.
3947 (s390_emit_ext): New function.
3948 (s390_emit_log_not): New function.
3949 (s390_emit_bit_and): New function.
3950 (s390_emit_bit_or): New function.
3951 (s390_emit_bit_xor): New function.
3952 (s390_emit_bit_not): New function.
3953 (s390_emit_equal): New function.
3954 (s390_emit_less_signed): New function.
3955 (s390_emit_less_unsigned): New function.
3956 (s390_emit_ref): New function.
3957 (s390_emit_if_goto): New function.
3958 (s390_emit_goto): New function.
3959 (s390_write_goto_address): New function.
3960 (s390_emit_litpool): New function.
3961 (s390_emit_const): New function.
3962 (s390_emit_call): New function.
3963 (s390_emit_reg): New function.
3964 (s390_emit_pop): New function.
3965 (s390_emit_stack_flush): New function.
3966 (s390_emit_zero_ext): New function.
3967 (s390_emit_swap): New function.
3968 (s390_emit_stack_adjust): New function.
3969 (s390_emit_set_r2): New function.
3970 (s390_emit_int_call_1): New function.
3971 (s390_emit_void_call_2): New function.
3972 (s390_emit_eq_goto): New function.
3973 (s390_emit_ne_goto): New function.
3974 (s390_emit_lt_goto): New function.
3975 (s390_emit_le_goto): New function.
3976 (s390_emit_gt_goto): New function.
3977 (s390_emit_ge_goto): New function.
3978 (s390x_emit_prologue): New function.
3979 (s390x_emit_epilogue): New function.
3980 (s390x_emit_add): New function.
3981 (s390x_emit_sub): New function.
3982 (s390x_emit_mul): New function.
3983 (s390x_emit_lsh): New function.
3984 (s390x_emit_rsh_signed): New function.
3985 (s390x_emit_rsh_unsigned): New function.
3986 (s390x_emit_ext): New function.
3987 (s390x_emit_log_not): New function.
3988 (s390x_emit_bit_and): New function.
3989 (s390x_emit_bit_or): New function.
3990 (s390x_emit_bit_xor): New function.
3991 (s390x_emit_bit_not): New function.
3992 (s390x_emit_equal): New function.
3993 (s390x_emit_less_signed): New function.
3994 (s390x_emit_less_unsigned): New function.
3995 (s390x_emit_ref): New function.
3996 (s390x_emit_if_goto): New function.
3997 (s390x_emit_const): New function.
3998 (s390x_emit_call): New function.
3999 (s390x_emit_reg): New function.
4000 (s390x_emit_pop): New function.
4001 (s390x_emit_stack_flush): New function.
4002 (s390x_emit_zero_ext): New function.
4003 (s390x_emit_swap): New function.
4004 (s390x_emit_stack_adjust): New function.
4005 (s390x_emit_int_call_1): New function.
4006 (s390x_emit_void_call_2): New function.
4007 (s390x_emit_eq_goto): New function.
4008 (s390x_emit_ne_goto): New function.
4009 (s390x_emit_lt_goto): New function.
4010 (s390x_emit_le_goto): New function.
4011 (s390x_emit_gt_goto): New function.
4012 (s390x_emit_ge_goto): New function.
4013 (s390_emit_ops): New function.
4014 (struct linux_target_ops): Fill in emit_ops hook.
4015
4016 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
4017
4018 PR 18377
4019 * Makefile.in: Add s390 IPA files.
4020 * configure.srv: Build IPA for s390.
4021 * linux-s390-ipa.c: New file.
4022 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
4023 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
4024 (tdesc_s390_linux32): Likewise.
4025 (init_registers_s390_linux32v1): Likewise.
4026 (tdesc_s390_linux32v1): Likewise.
4027 (init_registers_s390_linux32v2): Likewise.
4028 (tdesc_s390_linux32v2): Likewise.
4029 (init_registers_s390_linux64): Likewise.
4030 (tdesc_s390_linux64): Likewise.
4031 (init_registers_s390_linux64v1): Likewise.
4032 (tdesc_s390_linux64v1): Likewise.
4033 (init_registers_s390_linux64v2): Likewise.
4034 (tdesc_s390_linux64v2): Likewise.
4035 (init_registers_s390_te_linux64): Likewise.
4036 (tdesc_s390_te_linux64): Likewise.
4037 (init_registers_s390_vx_linux64): Likewise.
4038 (tdesc_s390_vx_linux64): Likewise.
4039 (init_registers_s390_tevx_linux64): Likewise.
4040 (tdesc_s390_tevx_linux64): Likewise.
4041 (init_registers_s390x_linux64): Likewise.
4042 (tdesc_s390x_linux64): Likewise.
4043 (init_registers_s390x_linux64v1): Likewise.
4044 (tdesc_s390x_linux64v1): Likewise.
4045 (init_registers_s390x_linux64v2): Likewise.
4046 (tdesc_s390x_linux64v2): Likewise.
4047 (init_registers_s390x_te_linux64): Likewise.
4048 (tdesc_s390x_te_linux64): Likewise.
4049 (init_registers_s390x_vx_linux64): Likewise.
4050 (tdesc_s390x_vx_linux64): Likewise.
4051 (init_registers_s390x_tevx_linux64): Likewise.
4052 (tdesc_s390x_tevx_linux64): Likewise.
4053 (have_hwcap_s390_vx): New static variable.
4054 (s390_arch_setup): Fill have_hwcap_s390_vx.
4055 (s390_get_thread_area): New function.
4056 (s390_ft_entry_gpr_esa): New const.
4057 (s390_ft_entry_gpr_zarch): New const.
4058 (s390_ft_entry_misc): New const.
4059 (s390_ft_entry_fr): New const.
4060 (s390_ft_entry_vr): New const.
4061 (s390_ft_main_31): New const.
4062 (s390_ft_main_64): New const.
4063 (s390_ft_exit_fr): New const.
4064 (s390_ft_exit_vr): New const.
4065 (s390_ft_exit_misc): New const.
4066 (s390_ft_exit_gpr_esa): New const.
4067 (s390_ft_exit_gpr_zarch): New const.
4068 (append_insns): New function.
4069 (s390_relocate_instruction): New function.
4070 (s390_install_fast_tracepoint_jump_pad): New function.
4071 (s390_get_min_fast_tracepoint_insn_len): New function.
4072 (s390_get_ipa_tdesc_idx): New function.
4073 (struct linux_target_ops): Wire in the above functions.
4074 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
4075 * linux-s390-tdesc.h: New file.
4076
4077 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
4078
4079 * linux-s390-low.c (s390_supports_tracepoints): New function.
4080 (struct linux_target_ops): Fill supports_tracepoints hook.
4081
4082 2016-03-18 Yao Qi <yao.qi@linaro.org>
4083
4084 * linux-low.c (lwp_signal_can_be_delivered): New function.
4085 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
4086
4087 2016-03-18 Yao Qi <yao.qi@linaro.org>
4088
4089 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
4090 0 if signal is enqueued. Remove 'signal' from one debugging
4091 message. Move one debugging message to some lines below.
4092 Remove code setting 'signal' to 0.
4093
4094 2016-03-18 Yao Qi <yao.qi@linaro.org>
4095
4096 * linux-low.c (linux_low_filter_event): Remove redundant
4097 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
4098
4099 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
4100
4101 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
4102 (struct linux_target_ops): Wire in the above.
4103
4104 2016-03-03 Yao Qi <yao.qi@linaro.org>
4105
4106 * linux-low.c: Update comments to start_step_over.
4107
4108 2016-03-03 Yao Qi <yao.qi@linaro.org>
4109
4110 PR server/19736
4111 * linux-low.c (handle_extended_wait): Set child suspended
4112 if event_lwp->bp_reinsert isn't zero.
4113
4114 2016-03-02 Yao Qi <yao.qi@linaro.org>
4115
4116 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
4117 enqueue_pending_signal.
4118
4119 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
4120
4121 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
4122 is actually loaded.
4123
4124 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
4125
4126 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
4127 (s390_regmap_3264) [!__s390x__]: New global.
4128 (s390_collect_ptrace_register): Skip map entries containing -1.
4129 (s390_supply_ptrace_register): Ditto.
4130 (s390_fill_gprs_high): New function.
4131 (s390_store_gprs_high): New function.
4132 (s390_regsets): Add NT_S390_HIGH_GPRS.
4133 (s390_get_hwcap): Enable on 31-bit.
4134 (have_hwcap_s390_high_gprs): Enable on 31-bit.
4135 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
4136 Detect NT_S390_HIGH_GPRS.
4137 (s390_usrregs_info_3264): Enable on 31-bit.
4138 (s390_regs_info): Enable regs_info_3264 on 31-bit.
4139 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
4140
4141 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
4142
4143 PR gdb/13808
4144 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
4145 * configure.srv: Ditto.
4146 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
4147 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
4148 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
4149 (init_registers_amd64_linux): Remove prototype.
4150 (tdesc_amd64_linux): Remove declaration.
4151 (get_ipa_tdesc): New function.
4152 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
4153 initialize remaining tdescs.
4154 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
4155 (init_registers_i386_linux): Remove prototype.
4156 (tdesc_i386_linux): Remove declaration.
4157 (get_ipa_tdesc): New function.
4158 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
4159 initialize remaining tdescs.
4160 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
4161 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
4162 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
4163 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
4164 (x86_get_ipa_tdesc_idx): New function.
4165 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
4166 * linux-x86-tdesc.h: New file.
4167 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
4168 (target_get_ipa_tdesc_idx): New macro.
4169 * tracepoint.c (ipa_tdesc_idx): New macro.
4170 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
4171 (symbol_list): Add ipa_tdesc_idx.
4172 (cmd_qtstart): Write ipa_tdesc_idx in the target.
4173 (ipa_tdesc): Remove.
4174 (ipa_tdesc_idx): New variable.
4175 (get_context_regcache): Use get_ipa_tdesc.
4176 (gdb_collect): Ditto.
4177 (gdb_probe): Ditto.
4178 * tracepoint.h (get_ipa_tdesc): New prototype.
4179 (ipa_tdesc): Remove.
4180
4181 2016-02-24 Pedro Alves <palves@redhat.com>
4182
4183 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
4184 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
4185 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
4186 Factor out common code between the USE_SIGTRAP_SIGINFO and
4187 !USE_SIGTRAP_SIGINFO blocks.
4188 (linux_low_filter_event): Call save_stop_reason instead of
4189 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
4190 Update comments.
4191 (linux_wait_1): Update comments.
4192
4193 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
4194
4195 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
4196 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
4197 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
4198 ppc_insert_point, ppc_remove_point.
4199
4200 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
4201
4202 * linux-s390-low.c (s390_supports_z_point_type): New function.
4203 (struct linux_target_ops): Wire s390_supports_z_point_type in.
4204
4205 2016-02-16 Yao Qi <yao.qi@linaro.org>
4206
4207 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
4208 PC. Get pc from regcache_read_pc.
4209
4210 2016-02-12 Yao Qi <yao.qi@linaro.org>
4211
4212 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
4213 or linux_get_pc_32bit.
4214 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
4215
4216 2016-02-12 Yao Qi <yao.qi@linaro.org>
4217
4218 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
4219 arm_linux_get_next_pcs_fixup.
4220
4221 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
4222
4223 * tracepoint.c (x_tracepoint_action_download): Change
4224 write_inferior_data_ptr to write_inferior_data_pointer.
4225 (cmd_qtstart): Likewise.
4226 (write_inferior_data_ptr): Remove.
4227 (download_agent_expr): Change write_inferior_data_ptr to
4228 write_inferior_data_pointer.
4229 (download_tracepoint_1): Likewise.
4230 (download_tracepoint): Likewise.
4231 (download_trace_state_variables): Likewise.
4232
4233 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
4234 Marcin Kościelnicki <koriakin@0x04.net>
4235
4236 * tracepoint.c (struct tracepoint_action_ops): Remove.
4237 (struct tracepoint_action): Remove ops.
4238 (m_tracepoint_action_download, r_tracepoint_action_download)
4239 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
4240 size and offset accordingly.
4241 (m_tracepoint_action_ops, r_tracepoint_action_ops)
4242 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
4243 (tracepoint_action_send, tracepoint_action_download): New functions.
4244 Helpers for trace action handlers.
4245 (add_tracepoint_action): Remove setup actions ops.
4246 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
4247
4248 2016-02-10 Yao Qi <yao.qi@linaro.org>
4249
4250 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
4251
4252 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
4253
4254 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
4255 to AC_OUTPUT.
4256 * configure: Regenerate.
4257
4258 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
4259
4260 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
4261 void * to gdb_byte *.
4262 * linux-low.c (siginfo_fixup): Likewise.
4263 (linux_xfer_siginfo): Likewise.
4264 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
4265 Likewise.
4266 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
4267
4268 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
4269
4270 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
4271 to srv_tgtobj.
4272 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
4273 to srv_tgtobj.
4274 * linux-x86-low.c [__x86_64__]: Include
4275 "nat/amd64-linux-siginfo.h".
4276 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
4277 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
4278 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
4279 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
4280 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
4281 (cpt_si_fd, si_timerid, si_overrun): Move from
4282 nat/amd64-linux-siginfo.c.
4283 * Makefile.in (amd64-linux-siginfo.o:): New rule.
4284
4285 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
4286
4287 * server.c (skip_to_semicolon): Remove.
4288 (process_point_options): Use strchrnul instead of
4289 skip_to_semicolon.
4290
4291 2016-01-26 Yao Qi <yao.qi@linaro.org>
4292
4293 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
4294 * linux-low.c (install_software_single_step_breakpoints): Don't
4295 call regcache_read_pc.
4296 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
4297 argument pc.
4298
4299 2016-01-26 Yao Qi <yao.qi@linaro.org>
4300
4301 * linux-low.c (install_software_single_step_breakpoints): Call
4302 regcache_read_pc instead of get_pc.
4303
4304 2016-01-26 Yao Qi <yao.qi@linaro.org>
4305
4306 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
4307 (unblock_async_io): Rename to ...
4308 (block_unblock_async_io): ... it. New function.
4309 (enable_async_io): Don't install SIGIO handler. Unblock it
4310 instead.
4311 (disable_async_io): Don't ignore SIGIO. Block it instead.
4312 (initialize_async_io): Install SIGIO handler. Don't call
4313 unblock_async_io.
4314
4315 2016-01-26 Yao Qi <yao.qi@linaro.org>
4316
4317 * remote-utils.c (getpkt): If the buffer isn't empty, and the
4318 first character is '\003', call *the_target->request_interrupt.
4319
4320 2016-01-25 Yao Qi <yao.qi@linaro.org>
4321
4322 * remote-utils.c (new_thread_notify): Remove.
4323 (dead_thread_notify): Likewise.
4324 * remote-utils.h (new_thread_notify): Remove declaration.
4325 (dead_thread_notify): Likewise.
4326
4327 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
4328
4329 * gdb.trace/pending.exp: Fix expected message on continue.
4330
4331 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
4332
4333 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
4334 it works properly on big-endian machines where sizeof (CORE_ADDR)
4335 != sizeof (void *).
4336
4337 2016-01-21 Pedro Alves <palves@redhat.com>
4338
4339 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
4340 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
4341 * configure: Regenerate.
4342
4343 2016-01-21 Yao Qi <yao.qi@linaro.org>
4344
4345 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
4346 is_thumb and set it according to CPSR saved on the stack.
4347 (get_next_pcs_syscall_next_pc): Pass is_thumb to
4348 arm_sigreturn_next_pc.
4349
4350 2016-01-18 Yao Qi <yao.qi@linaro.org>
4351
4352 * linux-low.c (linux_set_pc_64bit): New function.
4353 (linux_get_pc_64bit): New function.
4354 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
4355 Declare.
4356 * linux-sparc-low.c (debug_threads): Remove declaration.
4357 (sparc_get_pc): Remove.
4358 (the_low_target): Use linux_get_pc_64bit instead of
4359 sparc_get_pc.
4360 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
4361 (the_low_target): Use linux_get_pc_64bit and
4362 linux_set_pc_64bit.
4363
4364 2016-01-18 Yao Qi <yao.qi@linaro.org>
4365
4366 * linux-arm-low.c (debug_threads): Remove declaration.
4367 (arm_get_pc, arm_set_pc): Remove.
4368 (the_low_target): Use linux_get_pc_32bit and
4369 linux_set_pc_32bit.
4370 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
4371 (the_low_target): Use linux_get_pc_32bit and
4372 linux_set_pc_32bit.
4373 * linux-cris-low.c (debug_threads): Remove declaration.
4374 (cris_get_pc, cris_set_pc,): Remove.
4375 (the_low_target): Use linux_get_pc_32bit and
4376 linux_set_pc_32bit.
4377 * linux-crisv32-low.c (debug_threads): Remove declaration.
4378 (cris_get_pc, cris_set_pc): Remove.
4379 (the_low_target): Use linux_get_pc_32bit and
4380 linux_set_pc_32bit.
4381 * linux-low.c: Include inttypes.h.
4382 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
4383 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
4384 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
4385 (the_low_target): Use linux_get_pc_32bit and
4386 linux_set_pc_32bit.
4387 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
4388 (the_low_target): Use linux_get_pc_32bit and
4389 linux_set_pc_32bit.
4390 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
4391 (the_low_target): Use linux_get_pc_32bit and
4392 linux_set_pc_32bit.
4393 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
4394 (the_low_target): Use linux_get_pc_32bit and
4395 linux_set_pc_32bit.
4396 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
4397 (the_low_target): Use linux_get_pc_32bit and
4398 linux_set_pc_32bit.
4399
4400 2016-01-18 Gary Benson <gbenson@redhat.com>
4401
4402 * configure.ac (AC_FUNC_FORK): New check.
4403 * config.in: Regenerate.
4404 * configure: Likewise.
4405
4406 2016-01-14 Yao Qi <yao.qi@linaro.org>
4407
4408 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
4409 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
4410 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
4411 arm_get_next_pcs_ctor.
4412
4413 2016-01-12 Josh Stone <jistone@redhat.com>
4414 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4415
4416 * inferiors.h: Include "gdb_vecs.h".
4417 (struct process_info): Add syscalls_to_catch.
4418 * inferiors.c (remove_process): Free syscalls_to_catch.
4419 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
4420 syscall_return stops.
4421 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
4422 * server.c (handle_general_set): Handle QCatchSyscalls.
4423 (handle_query): Report support for QCatchSyscalls.
4424 * target.h (struct target_ops): Add supports_catch_syscall.
4425 (target_supports_catch_syscall): New macro.
4426 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
4427 (struct lwp_info): Add syscall_state.
4428 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
4429 Maintain syscall_state and syscalls_to_catch across exec.
4430 (get_syscall_trapinfo): New function, proxy to the_low_target.
4431 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
4432 (linux_low_filter_event): Toggle syscall_state entry/return for
4433 syscall traps, and set it ignored for all others.
4434 (gdb_catching_syscalls_p): New function.
4435 (gdb_catch_this_syscall_p): New function.
4436 (linux_wait_1): Handle SYSCALL_SIGTRAP.
4437 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
4438 (linux_supports_catch_syscall): New function.
4439 (linux_target_ops): Install it.
4440 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
4441 (the_low_target): Install it.
4442
4443 2016-01-12 Mike Frysinger <vapier@gentoo.org>
4444
4445 * acinclude.m4: Include new ../warning.m4 file.
4446 * configure: Regenerated.
4447 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
4448
4449 2016-01-12 Mike Frysinger <vapier@gentoo.org>
4450
4451 * ax.c (is_goto_target): Mark static.
4452 * linux-low.c (register_addr): Likewise.
4453 (linux_fetch_registers, linux_store_registers): Likewise.
4454 * mem-break.c (any_persistent_commands): Fix old prototype.
4455 (add_commands_to_breakpoint): Mark static.
4456 * regcache.c (find_register_by_name): Delete unused func.
4457 * remote-utils.c (hex_or_minus_one): Mark static.
4458 * server.c (monitor_show_help): Mark static.
4459 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
4460 handle_v_requests): Likewise.
4461
4462 2016-01-12 Pedro Alves <palves@redhat.com>
4463
4464 Remove use of the registered trademark symbol throughout.
4465
4466 2016-01-08 Yao Qi <yao.qi@linaro.org>
4467
4468 * remote-utils.c (getpkt): If c is '\003', call target hook
4469 request_interrupt.
4470
4471 2016-01-06 Yao Qi <yao.qi@linaro.org>
4472
4473 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
4474 linux-aarch32-low.c.
4475 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4476 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
4477 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4478 (thumb2_breakpoint): Declare.
4479 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
4480 linux-aarch32-low.h.
4481 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4482 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
4483 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4484
4485 2016-01-01 Joel Brobecker <brobecker@adacore.com>
4486
4487 * gdbreplay.c (gdbreplay_version): Change copyright year in
4488 version message.
4489 * server.c (gdbserver_version): Likewise.
4490
4491 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
4492
4493 * server.c (crc32_table): Delete.
4494 (crc32): Use libiberty's xcrc32 function.
4495
4496 2015-12-22 Joel Brobecker <brobecker@adacore.com>
4497
4498 * lynx-low.c (lynx_delete_thread_callback): New function.
4499 (lynx_mourn): Properly delete our process and all of its
4500 threads. Remove call to clear_inferiors.
4501
4502 2015-12-22 Joel Brobecker <brobecker@adacore.com>
4503
4504 * target.c (thread_search_callback): Add check that
4505 the thread_stopped target callback is not NULL before
4506 calling it.
4507
4508 2015-12-21 Yao Qi <yao.qi@linaro.org>
4509
4510 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
4511 arm breakpoint.
4512
4513 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4514
4515 * server.c (handle_query): Call target_supports_software_single_step.
4516
4517 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4518
4519 * linux-low.c (single_step): New function.
4520 (linux_resume_one_lwp_throw): Call single_step.
4521 (start_step_over): Likewise.
4522
4523 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4524
4525 * Makefile.in (SFILES): Append arch/arm-linux.c,
4526 arch/arm-get-next-pcs.c.
4527 (arm-linux.o): New rule.
4528 (arm-get-next-pcs.o): New rule.
4529 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
4530 arm-linux.o.
4531 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
4532 to linux-aarch32-low.c.
4533 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4534 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4535 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4536 (thumb2_breakpoint_len): Likewise.
4537 (arm_is_thumb_mode): Make non-static.
4538 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
4539 from linux-aarch32-low.c.
4540 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4541 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4542 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4543 (thumb2_breakpoint_len): Likewise.
4544 (arm_is_thumb_mode): New declaration.
4545 * linux-arm-low.c: Include arch/arm-linux.h
4546 aarch/arm-get-next-pcs.h, sys/syscall.h.
4547 (get_next_pcs_ops): New struct.
4548 (get_next_pcs_addr_bits_remove): New function.
4549 (get_next_pcs_is_thumb): New function.
4550 (get_next_pcs_read_memory_unsigned_integer): Likewise.
4551 (arm_sigreturn_next_pc): Likewise.
4552 (get_next_pcs_syscall_next_pc): Likewise.
4553 (arm_gdbserver_get_next_pcs): Likewise.
4554 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
4555 Initialize.
4556 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
4557 * server.h: Include gdb_vecs.h.
4558
4559 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4560
4561 * Makefile.in (SFILES): Append common/common-regcache.c.
4562 (OBS): Append common-regcache.o.
4563 (common-regcache.o): New rule.
4564 * regcache.c (init_register_cache): Initialize cache to
4565 REG_UNAVAILABLE.
4566 (regcache_raw_read_unsigned): New function.
4567 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
4568 register_status enum.
4569
4570 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4571
4572 * linux-aarch64-low.c (the_low_targets): Rename
4573 breakpoint_reinsert_addr to get_next_pcs.
4574 * linux-arm-low.c (the_low_targets): Likewise.
4575 * linux-bfin-low.c (the_low_targets): Likewise.
4576 * linux-cris-low.c (the_low_targets): Likewise.
4577 * linux-crisv32-low.c (the_low_targets): Likewise.
4578 * linux-low.c (can_software_single_step): Likewise.
4579 (install_software_single_step_breakpoints): New function.
4580 (start_step_over): Use install_software_single_step_breakpoints.
4581 * linux-low.h: New CORE_ADDR vector.
4582 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
4583 get_next_pcs.
4584 * linux-mips-low.c (the_low_targets): Likewise.
4585 * linux-nios2-low.c (the_low_targets): Likewise.
4586 * linux-sparc-low.c (the_low_targets): Likewise.
4587
4588 2015-12-17 Pedro Alves <palves@redhat.com>
4589
4590 * linux-low.c (linux_kill_one_lwp): Remove references to
4591 LinuxThreads.
4592 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
4593 to 'kill'.
4594 (linux_init_signals): Delete.
4595 (initialize_low): Adjust.
4596 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
4597
4598 2015-12-16 Pedro Alves <palves@redhat.com>
4599
4600 * configure.ac (compiler warning flags): When testing a
4601 -Wno-foo option, check whether -Wfoo works instead.
4602 * configure: Regenerate.
4603
4604 2015-12-11 Don Breazeal <donb@codesourcery.com>
4605
4606 * server.c (process_serial_event): Don't exit from gdbserver
4607 in remote mode if there are still active inferiors.
4608
4609 2015-12-11 Yao Qi <yao.qi@linaro.org>
4610
4611 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
4612 arm_breakpoint_at if the process is 32-bit.
4613
4614 2015-12-11 Yao Qi <yao.qi@linaro.org>
4615
4616 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
4617 arm breakpoint.
4618
4619 2015-12-07 Yao Qi <yao.qi@linaro.org>
4620
4621 * configure.srv: Append arm.o to srv_tgtobj for
4622 aarch64*-*-linux* target.
4623 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
4624 from linux-arm-low.c.
4625 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4626 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4627 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4628 (thumb2_breakpoint_len): Likewise.
4629 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
4630 (arm_breakpoint_kinds): Likewise.
4631 (arm_breakpoint_kind_from_pc): Likewise.
4632 (arm_sw_breakpoint_from_kind): Likewise.
4633 (arm_breakpoint_kind_from_current_state): Likewise.
4634 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
4635 (arm_sw_breakpoint_from_kind): Declare.
4636 (arm_breakpoint_kind_from_current_state): Declare.
4637 (arm_breakpoint_at): Declare.
4638 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
4639 arm_sw_breakpoint_from_kind if process is 32-bit.
4640 (aarch64_breakpoint_kind_from_pc): New function.
4641 (aarch64_breakpoint_kind_from_current_state): New function.
4642 (the_low_target): Initialize fields breakpoint_kind_from_pc
4643 and breakpoint_kind_from_current_state.
4644 * linux-arm-low.c (arm_breakpoint_kinds): Move to
4645 linux-aarch32-low.c.
4646 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
4647 (arm_breakpoint, arm_breakpoint_len): Likewise.
4648 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
4649 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4650 (arm_is_thumb_mode): Likewise.
4651 (arm_breakpoint_at): Likewise.
4652 (arm_breakpoint_kind_from_pc): Likewise.
4653 (arm_sw_breakpoint_from_kind): Likewise.
4654 (arm_breakpoint_kind_from_current_state): Likewise.
4655
4656 Revert:
4657 2015-08-04 Yao Qi <yao.qi@linaro.org>
4658
4659 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
4660 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
4661 * server.c (extended_protocol): Remove "static".
4662 * server.h (extended_protocol): Declare it.
4663
4664 2015-12-04 Josh Stone <jistone@redhat.com>
4665
4666 * target.h (struct target_ops) <arch_setup>: Rename to ...
4667 (struct target_ops) <post_create_inferior>: ... this.
4668 (target_arch_setup): Rename to ...
4669 (target_post_create_inferior): ... this, calling post_create_inferior.
4670 * server.c (start_inferior): Update target_arch_setup calls to
4671 target_post_create_inferior.
4672 * linux-low.c (linux_low_ptrace_options): Forward declare.
4673 (linux_arch_setup): Update its comment for general use.
4674 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
4675 (struct linux_target_ops): Use linux_post_create_inferior.
4676 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
4677 to post_create_inferior.
4678 * nto-low.c (struct nto_target_ops): Likewise.
4679 * spu-low.c (struct spu_target_ops): Likewise.
4680 * win32-low.c (struct win32_target_ops): Likewise.
4681
4682 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
4683
4684 * linux-arm-low.c: Remove duplicate arch/arm.h include.
4685
4686 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4687
4688 * linux-arm-low.c (arm_reinsert_addr): Remove function.
4689 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
4690 * linux-cris-low.c (cris_reinsert_addr> Remove function.
4691 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4692 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
4693 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4694 * linux-mips-low.c (mips_reinsert_addr): Remove function.
4695 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4696 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
4697 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4698 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
4699 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4700
4701 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4702
4703 * linux-low.c (linux_look_up_symbols): Don't call
4704 linux_supports_traceclone.
4705 * linux-low.h (thread_db_init): Remove use_events argument.
4706 * thread-db.c (thread_db_use_event): Remove global variable.
4707 (struct thread_db) <td_thr_event_enable_p>: Remove field.
4708 (struct thread_db) <td_create_bp>: Remove field.
4709 (thread_db_create_event): Remove function.
4710 (thread_db_enable_reporting): Likewise.
4711 (find_one_thread): Don't check for thread_db_use_events.
4712 (attach_thread): Likewise.
4713 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
4714 (try_thread_db_load_1): Don't check for thread_db_use_events.
4715 (thread_db_init): Remove use_events argument and thread events
4716 handling.
4717 (remove_thread_event_breakpoints): Remove function.
4718 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
4719
4720 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4721
4722 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
4723 New function.
4724 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4725 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
4726 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4727 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
4728 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
4729 Initialize.
4730 * linux-crisv32-low.c (cris_supports_hardware_single_step):
4731 New function.
4732 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4733 * linux-low.c (can_hardware_single_step): Use
4734 supports_hardware_single_step.
4735 (can_software_single_step): New function.
4736 (start_step_over): Call can_software_single_step.
4737 (linux_supports_hardware_single_step): New function.
4738 (struct target_ops) <supports_software_single_step>: Initialize.
4739 * linux-low.h (struct linux_target_ops)
4740 <supports_hardware_single_step>: Initialize.
4741 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
4742 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4743 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
4744 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
4745 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
4746 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4747 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
4748 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4749 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
4750 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
4751 Initialize.
4752 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
4753 (struct linux_target_ops) <tile_supports_hardware_single_step>:
4754 Initialize.
4755 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
4756 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4757 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
4758 New function.
4759 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4760 * target.h (struct target_ops): <supports_software_single_step>:
4761 New field.
4762 (target_supports_software_single_step): New macro.
4763
4764 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4765
4766 * linux-low.c (linux_wait_1): Fix pc advance condition.
4767 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
4768 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
4769
4770 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4771
4772 * linux-arm-low.c (arm_is_thumb_mode): New function.
4773 (arm_breakpoint_at): Use arm_is_thumb_mode.
4774 (arm_breakpoint_kind_from_current_state): New function.
4775 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
4776 Initialize.
4777 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
4778 (linux_breakpoint_kind_from_current_state): New function.
4779 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
4780 * linux-low.h (struct linux_target_ops)
4781 <breakpoint_kind_from_current_state>: New field.
4782 * target.h (struct target_ops): Likewise.
4783 (target_breakpoint_kind_from_current_state): New macro.
4784
4785 2015-11-30 Pedro Alves <palves@redhat.com>
4786
4787 * linux-low.c (linux_resume): Wake up the event loop before
4788 returning.
4789
4790 2015-11-30 Pedro Alves <palves@redhat.com>
4791
4792 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
4793 check.
4794 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
4795 to -1.
4796 * target.c (struct thread_search): New structure.
4797 (thread_search_callback): New function.
4798 (prev_general_thread): New global.
4799 (prepare_to_access_memory, done_accessing_memory): New functions.
4800 * target.h (prepare_to_access_memory, done_accessing_memory):
4801 Replace macros with function declarations.
4802
4803 2015-11-30 Pedro Alves <palves@redhat.com>
4804
4805 PR 14618
4806 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
4807 report TARGET_WAITKIND_NO_RESUMED.
4808 * remote-utils.c (prepare_resume_reply): Handle
4809 TARGET_WAITKIND_NO_RESUMED.
4810 * server.c (report_no_resumed): New global.
4811 (handle_query) <qSupported>: Handle "no-resumed+". Report
4812 "no-resumed+" support.
4813 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
4814 return error if the client doesn't support no-resumed events.
4815 (push_stop_notification): New function.
4816 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
4817 events if the client supports them.
4818
4819 2015-11-30 Pedro Alves <palves@redhat.com>
4820
4821 * linux-low.c (thread_still_has_status_pending_p): Don't check
4822 vCont;t here.
4823 (lwp_resumed): New function.
4824 (status_pending_p_callback): Return early if the LWP is not
4825 supposed to be resumed.
4826
4827 2015-11-30 Pedro Alves <palves@redhat.com>
4828
4829 * linux-low.c (handle_extended_wait): Assert that the LWP's
4830 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
4831 thread create events, leave the new child's status pending.
4832 (linux_low_filter_event): If GDB wants to hear about thread exit
4833 events, leave the LWP marked dead and don't delete it.
4834 (linux_wait_for_event_filtered): Don't check for thread exit.
4835 (filter_exit_event): New function.
4836 (linux_wait_1): Use it, when returning an exit event.
4837 (linux_resume_one_lwp_throw): Assert that the LWP's
4838 waitstatus is TARGET_WAITKIND_IGNORE.
4839 * remote-utils.c (prepare_resume_reply): Handle
4840 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
4841 * server.c (report_thread_events): New global.
4842 (handle_general_set): Handle QThreadEvents.
4843 (handle_query) <qSupported>: Handle and report QThreadEvents+;
4844 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
4845 TARGET_WAITKIND_THREAD_EXITED.
4846 * server.h (report_thread_events): Declare.
4847
4848 2015-11-30 Pedro Alves <palves@redhat.com>
4849
4850 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
4851 the thread's last_resume_kind was resume_stop.
4852
4853 2015-11-30 Pedro Alves <palves@redhat.com>
4854
4855 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
4856 before returning.
4857
4858 2015-11-30 Pedro Alves <palves@redhat.com>
4859
4860 * server.c (handle_v_requests): Handle vCtrlC.
4861
4862 2015-11-30 Pedro Alves <palves@redhat.com>
4863
4864 * gdbthread.h (find_any_thread_of_pid): Declare.
4865 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
4866 functions.
4867 * server.c (handle_query): If current_thread is NULL, look for
4868 another thread of the selected process.
4869
4870 2015-11-26 Daniel Colascione <dancol@dancol.org>
4871 Simon Marchi <simon.marchi@ericsson.com>
4872
4873 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
4874 * server.c (handle_qxfer_threads_worker): Refactor to include thread
4875 name in reply.
4876 * target.h (struct target_ops) <thread_name>: New field.
4877 (target_thread_name): New macro.
4878
4879 2015-11-23 Joel Brobecker <brobecker@adacore.com>
4880
4881 * regcache.h (regcache_invalidate_pid): Add declaration.
4882 * regcache.c (regcache_invalidate_pid): New function, extracted
4883 from regcache_invalidate.
4884 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
4885 Add trivial documentation comment.
4886 * lynx-low.c: Use regcache_invalidate_pid instead of
4887 regcache_invalidate.
4888
4889 2015-11-23 Joel Brobecker <brobecker@adacore.com>
4890
4891 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
4892 and Elf64_auxv_t if the target is Android.
4893
4894 2015-11-22 Doug Evans <xdje42@gmail.com>
4895
4896 * target.h: #include <sys/types.h>.
4897
4898 2015-11-19 Pedro Alves <palves@redhat.com>
4899
4900 * linux-low.c (linux_process_qsupported): Change prototype.
4901 Adjust.
4902 * linux-low.h (struct linux_target_ops) <process_qsupported>:
4903 Change prototype.
4904 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
4905 and adjust to loop over all features.
4906 * server.c (handle_query) <qSupported>: Adjust to call
4907 target_process_qsupported once, passing it a vector of unprocessed
4908 features.
4909 * target.h (struct target_ops) <process_qsupported>: Change
4910 prototype.
4911 (target_process_qsupported): Adjust.
4912
4913 2015-11-19 Pedro Alves <palves@redhat.com>
4914
4915 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
4916 mode.
4917 * configure: Regenerate.
4918
4919 2015-11-19 Pedro Alves <palves@redhat.com>
4920
4921 * configure: Regenerate.
4922
4923 2015-11-19 Yao Qi <yao.qi@linaro.org>
4924
4925 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
4926 type to uint32_t.
4927
4928 2015-11-19 Yao Qi <yao.qi@linaro.org>
4929
4930 * linux-aarch64-low.c (enum aarch64_operand_type): New.
4931 (struct aarch64_operand): Move enum out.
4932
4933 2015-11-19 Yao Qi <yao.qi@linaro.org>
4934
4935 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
4936 struct user_fpsimd_state *.
4937 (aarch64_store_fpregset): Likewise.
4938
4939 2015-11-19 Yao Qi <yao.qi@linaro.org>
4940
4941 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
4942 struct user_pt_regs *.
4943 (aarch64_store_gregset): Likewise.
4944
4945 2015-11-18 Pedro Alves <palves@redhat.com>
4946
4947 * Makefile.in (all_object_files): Add $IPA_OBJS.
4948
4949 2015-11-17 Pedro Alves <palves@redhat.com>
4950
4951 * win32-low.c (win32_resume): Use gdb_signal_from_host,
4952 GDB_SIGNAL_0 and gdb_signal_to_string.
4953
4954 2015-11-17 Pedro Alves <palves@redhat.com>
4955
4956 * win32-low.c (handle_output_debug_string): Remove parameter.
4957 (win32_kill): Remove our_status local and adjust call to
4958 handle_output_debug_string.
4959 (get_child_debug_event): Adjust call to
4960 handle_output_debug_string.
4961
4962 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4963
4964 * linux-mips-low.c (mips_fill_gregset): Add cast.
4965 (mips_store_gregset): Likewise.
4966 (mips_fill_fpregset): Likewise.
4967 (mips_store_fpregset): Likewise.
4968
4969 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4970
4971 * linux-mips-low.c (mips_add_watchpoint): Rename private to
4972 priv.
4973
4974 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4975
4976 * linux-mips-low.c (mips_linux_new_thread): Change type of
4977 watch_type to enum target_hw_bp_type.
4978
4979 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4980
4981 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
4982 Change return type to arm_hwbp_type.
4983
4984 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4985
4986 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
4987 (arm_store_gregset): Likewise.
4988 * linux-arm-low.c (arm_get_hwcap): Likewise.
4989 (arm_read_description): Likewise.
4990
4991 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4992
4993 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
4994
4995 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4996
4997 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
4998 (ppc_fill_vsxregset): Likewise.
4999 (ppc_store_vsxregset): Likewise.
5000 (ppc_fill_vrregset): Likewise.
5001 (ppc_store_vrregset): Likewise.
5002 (ppc_fill_evrregset): Likewise.
5003 (ppc_store_evrregset): Likewise.
5004
5005 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5006
5007 * linux-ppc-low.c (ppc_usrregs_info): Remove
5008 forward-declaration.
5009 (ppc_arch_setup): Move lower in file.
5010
5011 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
5012
5013 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
5014 (ps_pdwrite): Likewise.
5015
5016 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
5017
5018 * linux-arm-low.c (arm_new_thread): Move pointer dereference
5019 to after assert checks.
5020
5021 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
5022
5023 * proc-service.c (ps_pdread): Add/adjust casts.
5024 (ps_pdwrite): Add/adjust casts.
5025
5026 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
5027
5028 * server.c (handle_search_memory_1): Cast return value of
5029 memmem.
5030
5031 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
5032
5033 * server.c (write_qxfer_response): Change type of data to
5034 gdb_byte *.
5035
5036 2015-10-29 Pedro Alves <palves@redhat.com>
5037
5038 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
5039
5040 2015-10-29 Pedro Alves <palves@redhat.com>
5041
5042 * tracepoint.c (clear_installed_tracepoints): Add casts.
5043
5044 2015-10-29 Pedro Alves <palves@redhat.com>
5045
5046 * server.c (handle_v_cont, process_serial_event): Add enum
5047 gdb_signal casts to signal parsing code.
5048
5049 2015-10-29 Pedro Alves <palves@redhat.com>
5050
5051 * linux-low.h (NULL_REGSET): Define.
5052 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
5053 * linux-arm-low.c (arm_regsets): Likewise.
5054 * linux-crisv32-low.c (cris_regsets): Likewise.
5055 * linux-m68k-low.c (m68k_regsets): Likewise.
5056 * linux-mips-low.c (mips_regsets): Likewise.
5057 * linux-nios2-low.c (nios2_regsets): Likewise.
5058 * linux-ppc-low.c (ppc_regsets): Likewise.
5059 * linux-s390-low.c (s390_regsets): Likewise.
5060 * linux-sh-low.c (sh_regsets): Likewise.
5061 * linux-sparc-low.c (sparc_regsets): Likewise.
5062 * linux-tic6x-low.c (tic6x_regsets): Likewise.
5063 * linux-tile-low.c (tile_regsets): Likewise.
5064 * linux-x86-low.c (x86_regsets): Likewise.
5065 * linux-xtensa-low.c (xtensa_regsets): Likewise.
5066
5067 2015-10-29 Pedro Alves <palves@redhat.com>
5068
5069 * linux-low.h (NULL_REGSET): Define.
5070 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
5071 * linux-arm-low.c (arm_regsets): Likewise.
5072 * linux-crisv32-low.c (cris_regsets): Likewise.
5073 * linux-m68k-low.c (m68k_regsets): Likewise.
5074 * linux-mips-low.c (mips_regsets): Likewise.
5075 * linux-nios2-low.c (nios2_regsets): Likewise.
5076 * linux-ppc-low.c (ppc_regsets): Likewise.
5077 * linux-s390-low.c (s390_regsets): Likewise.
5078 * linux-sh-low.c (sh_regsets): Likewise.
5079 * linux-sparc-low.c (sparc_regsets): Likewise.
5080 * linux-tic6x-low.c (tic6x_regsets): Likewise.
5081 * linux-tile-low.c (tile_regsets): Likewise.
5082 * linux-x86-low.c (x86_regsets): Likewise.
5083 * linux-xtensa-low.c (xtensa_regsets): Likewise.
5084
5085 2015-10-26 Doug Evans <dje@google.com>
5086
5087 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
5088
5089 2015-10-26 Doug Evans <dje@google.com>
5090
5091 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
5092
5093 2015-10-26 Doug Evans <dje@google.com>
5094
5095 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
5096 for debug_printf.
5097 (attach_thread, find_new_threads_callback): Ditto.
5098
5099 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5100
5101 * mem-break.h (set_breakpoint_data): Remove.
5102
5103 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5104
5105 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
5106 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
5107 (initialize_low): Remove set_breakpoint_data call.
5108 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
5109 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
5110 (initialize_low): Remove set_breakpoint_data call.
5111 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
5112 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
5113 (initialize_low): Remove set_breakpoint_data call.
5114
5115 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5116
5117 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
5118 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
5119 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
5120 * target.h (target_breakpoint_kind_from_pc): New macro.
5121
5122 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
5123
5124 * linux-low.c (default_breakpoint_kind_from_pc): New function.
5125 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
5126 the default breakpoint kind.
5127
5128 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5129
5130 * linux-arm-low.c (arm_supports_z_point_type): Add software
5131 breakpoint support.
5132
5133 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5134
5135 * linux-arm-low.c: Refactor breakpoint definitions.
5136 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
5137 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
5138
5139 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5140
5141 * Makefile.in: Add arm.c/o.
5142 * configure.srv: Likewise.
5143 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
5144 (arm_breakpoint_kind_from_pc): New function.
5145 (arm_sw_breakpoint_from_kind): Return proper kind.
5146 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
5147
5148 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5149
5150 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
5151 removal.
5152 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
5153 (struct raw_breakpoint) <size>: Remove.
5154 (struct raw_breakpoint) <kind>: Add.
5155 (bp_size): New function.
5156 (bp_opcode): Likewise.
5157 (find_raw_breakpoint_at): Adjust for kind.
5158 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
5159 (remove_memory_breakpoint): Adjust for kind call bp_size.
5160 (set_raw_breakpoint_at): Adjust for kind.
5161 (set_breakpoint): Likewise.
5162 (set_breakpoint_at): Call breakpoint_kind_from_pc.
5163 (delete_raw_breakpoint): Adjust for kind.
5164 (delete_breakpoint): Likewise.
5165 (find_gdb_breakpoint): Likewise.
5166 (set_gdb_breakpoint_1): Likewise.
5167 (set_gdb_breakpoint): Likewise.
5168 (delete_gdb_breakpoint_1): Likewise.
5169 (delete_gdb_breakpoint): Likewise.
5170 (uninsert_raw_breakpoint): Likewise.
5171 (reinsert_raw_breakpoint): Likewise.
5172 (set_breakpoint_data): Remove.
5173 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
5174 (check_mem_read): Adjust for kind call bp_size.
5175 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
5176 (clone_one_breakpoint): Adjust for kind.
5177 * mem-break.h (set_gdb_breakpoint): Likewise.
5178 (delete_gdb_breakpoint): Likewise.
5179 * server.c (process_serial_event): Likewise.
5180
5181 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5182
5183 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
5184 (struct linux_target_ops) <breakpoint>: Remove.
5185 (struct linux_target_ops) <breakpoint_len>: Remove.
5186 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5187 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5188 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
5189 (arm_sw_breakpoint_from_kind): New function.
5190 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
5191 (struct linux_target_ops) <breakpoint>: Remove.
5192 (struct linux_target_ops) <breakpoint_len>: Remove.
5193 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5194 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5195 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
5196 (struct linux_target_ops) <breakpoint>: Remove.
5197 (struct linux_target_ops) <breakpoint_len>: Remove.
5198 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5199 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5200 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
5201 (struct linux_target_ops) <breakpoint>: Remove.
5202 (struct linux_target_ops) <breakpoint_len>: Remove.
5203 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5204 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5205 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
5206 and sw_breakpoint_from_kind to increment the pc.
5207 (linux_breakpoint_kind_from_pc): New function.
5208 (linux_sw_breakpoint_from_kind): New function.
5209 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
5210 (initialize_low): Call breakpoint_kind_from_pc and
5211 sw_breakpoint_from_kind to replace breakpoint_data/len.
5212 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
5213 New field.
5214 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
5215 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
5216 (struct linux_target_ops) <breakpoint>: Remove.
5217 (struct linux_target_ops) <breakpoint_len>: Remove.
5218 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5219 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5220 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
5221 (struct linux_target_ops) <breakpoint>: Remove.
5222 (struct linux_target_ops) <breakpoint_len>: Remove.
5223 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5224 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5225 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
5226 (struct linux_target_ops) <breakpoint>: Remove.
5227 (struct linux_target_ops) <breakpoint_len>: Remove.
5228 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5229 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5230 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
5231 (struct linux_target_ops) <breakpoint>: Remove.
5232 (struct linux_target_ops) <breakpoint_len>: Remove.
5233 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5234 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5235 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
5236 (struct linux_target_ops) <breakpoint>: Remove.
5237 (struct linux_target_ops) <breakpoint_len>: Remove.
5238 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5239 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5240 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
5241 (struct linux_target_ops) <breakpoint>: Remove.
5242 (struct linux_target_ops) <breakpoint_len>: Remove.
5243 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5244 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5245 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
5246 (struct linux_target_ops) <breakpoint>: Remove.
5247 (struct linux_target_ops) <breakpoint_len>: Remove.
5248 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5249 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5250 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
5251 (struct linux_target_ops) <breakpoint>: Remove.
5252 (struct linux_target_ops) <breakpoint_len>: Remove.
5253 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5254 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5255 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
5256 (struct linux_target_ops) <breakpoint>: Remove.
5257 (struct linux_target_ops) <breakpoint_len>: Remove.
5258 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5259 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5260 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
5261 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
5262 (struct linux_target_ops) <breakpoint>: Remove.
5263 (struct linux_target_ops) <breakpoint_len>: Remove.
5264 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5265 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5266 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
5267 (struct linux_target_ops) <breakpoint>: Remove.
5268 (struct linux_target_ops) <breakpoint_len>: Remove.
5269 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5270 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5271
5272 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5273
5274 * linux-cris-low.c (cris_get_pc): Remove void arg.
5275
5276 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
5277
5278 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
5279 variable name.
5280
5281 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
5282
5283 * inferiors.c (thread_pid_matches_callback): New function.
5284 (find_thread_process): New function.
5285 (remove_thread): Reset current_thread.
5286 (remove_process): Assert threads have been removed first.
5287
5288 2015-10-15 Yao Qi <yao.qi@linaro.org>
5289
5290 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
5291 if it is 3.
5292 (aarch64_remove_point): Likewise.
5293 * regcache.c (regcache_register_size): New function.
5294
5295 2015-10-12 Yao Qi <yao.qi@linaro.org>
5296
5297 * linux-aarch64-low.c: Update all callers as emit_load_store
5298 is renamed to aarch64_emit_load_store.
5299
5300 2015-10-12 Yao Qi <yao.qi@linaro.org>
5301
5302 * linux-aarch64-low.c: Update all callers of function renaming
5303 from emit_insn to aarch64_emit_insn.
5304
5305 2015-10-12 Yao Qi <yao.qi@linaro.org>
5306
5307 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
5308 arch/aarch64-insn.h.
5309 (struct aarch64_memory_operand): Likewise.
5310 (ENCODE): Likewise.
5311 (emit_insn): Move to arch/aarch64-insn.c.
5312 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
5313 (emit_load_store): Move to arch/aarch64-insn.c.
5314 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
5315 (can_encode_int32): Remove.
5316
5317 2015-10-12 Yao Qi <yao.qi@linaro.org>
5318
5319 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
5320 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
5321 (aarch64_relocate_instruction): Likewise.
5322 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
5323 (struct aarch64_insn_visitor): Likewise.
5324
5325 2015-10-12 Yao Qi <yao.qi@linaro.org>
5326
5327 * linux-aarch64-low.c (struct aarch64_insn_data): New.
5328 (struct aarch64_insn_visitor): New.
5329 (struct aarch64_insn_relocation_data): New.
5330 (aarch64_ftrace_insn_reloc_b): New function.
5331 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
5332 (aarch64_ftrace_insn_reloc_cb): Likewise.
5333 (aarch64_ftrace_insn_reloc_tb): Likewise.
5334 (aarch64_ftrace_insn_reloc_adr): Likewise.
5335 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
5336 (aarch64_ftrace_insn_reloc_others): Likewise.
5337 (visitor): New.
5338 (aarch64_relocate_instruction): Use visitor.
5339
5340 2015-10-12 Yao Qi <yao.qi@linaro.org>
5341
5342 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
5343 int. Add argument buf.
5344 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
5345 aarch64_relocate_instruction.
5346
5347 2015-10-12 Yao Qi <yao.qi@linaro.org>
5348
5349 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
5350 argument insn. Remove local variable insn. Don't call
5351 target_read_uint32.
5352 (aarch64_install_fast_tracepoint_jump_pad): Call
5353 target_read_uint32.
5354
5355 2015-09-30 Yao Qi <yao.qi@linaro.org>
5356
5357 * linux-aarch64-low.c (emit_movk): Shorten a long line.
5358 (emit_load_store_pair): Likewise.
5359
5360 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
5361
5362 * dll.c (match_dll): Add cast(s).
5363 (unloaded_dll): Likewise.
5364 * linux-low.c (second_thread_of_pid_p): Likewise.
5365 (delete_lwp_callback): Likewise.
5366 (count_events_callback): Likewise.
5367 (select_event_lwp_callback): Likewise.
5368 (linux_set_resume_request): Likewise.
5369 * server.c (accumulate_file_name_length): Likewise.
5370 (emit_dll_description): Likewise.
5371 (handle_qxfer_threads_worker): Likewise.
5372 (visit_actioned_threads): Likewise.
5373 * thread-db.c (any_thread_of): Likewise.
5374 * tracepoint.c (same_process_p): Likewise.
5375 (match_blocktype): Likewise.
5376 (build_traceframe_info_xml): Likewise.
5377
5378 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
5379
5380 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
5381 assignment.
5382 (gdb_unparse_agent_expr): Likewise.
5383 * hostio.c (require_data): Likewise.
5384 (handle_pread): Likewise.
5385 * linux-low.c (disable_regset): Likewise.
5386 (fetch_register): Likewise.
5387 (store_register): Likewise.
5388 (get_dynamic): Likewise.
5389 (linux_qxfer_libraries_svr4): Likewise.
5390 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
5391 (set_fast_tracepoint_jump): Likewise.
5392 (uninsert_fast_tracepoint_jumps_at): Likewise.
5393 (reinsert_fast_tracepoint_jumps_at): Likewise.
5394 (validate_inserted_breakpoint): Likewise.
5395 (clone_agent_expr): Likewise.
5396 * regcache.c (init_register_cache): Likewise.
5397 * remote-utils.c (putpkt_binary_1): Likewise.
5398 (decode_M_packet): Likewise.
5399 (decode_X_packet): Likewise.
5400 (look_up_one_symbol): Likewise.
5401 (relocate_instruction): Likewise.
5402 (monitor_output): Likewise.
5403 * server.c (handle_search_memory): Likewise.
5404 (handle_qxfer_exec_file): Likewise.
5405 (handle_qxfer_libraries): Likewise.
5406 (handle_qxfer): Likewise.
5407 (handle_query): Likewise.
5408 (handle_v_cont): Likewise.
5409 (handle_v_run): Likewise.
5410 (captured_main): Likewise.
5411 * target.c (write_inferior_memory): Likewise.
5412 * thread-db.c (try_thread_db_load_from_dir): Likewise.
5413 * tracepoint.c (init_trace_buffer): Likewise.
5414 (add_tracepoint_action): Likewise.
5415 (add_traceframe): Likewise.
5416 (add_traceframe_block): Likewise.
5417 (cmd_qtdpsrc): Likewise.
5418 (cmd_qtdv): Likewise.
5419 (cmd_qtstatus): Likewise.
5420 (response_source): Likewise.
5421 (response_tsv): Likewise.
5422 (cmd_qtnotes): Likewise.
5423 (gdb_collect): Likewise.
5424 (initialize_tracepoint): Likewise.
5425
5426 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5427
5428 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
5429 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
5430 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
5431 <NOP>: New.
5432 (enum aarch64_condition_codes): New enum.
5433 (w0): New static global.
5434 (fp): Likewise.
5435 (lr): Likewise.
5436 (struct aarch64_memory_operand) <type>: New
5437 MEMORY_OPERAND_POSTINDEX type.
5438 (postindex_memory_operand): New helper function.
5439 (emit_ret): New function.
5440 (emit_load_store_pair): New function, factored out of emit_stp
5441 with support for MEMORY_OPERAND_POSTINDEX.
5442 (emit_stp): Rewrite using emit_load_store_pair.
5443 (emit_ldp): New function.
5444 (emit_load_store): Likewise.
5445 (emit_ldr): Mention post-index instruction in comment.
5446 (emit_ldrh): New function.
5447 (emit_ldrb): New function.
5448 (emit_ldrsw): Mention post-index instruction in comment.
5449 (emit_str): Likewise.
5450 (emit_subs): New function.
5451 (emit_cmp): Likewise.
5452 (emit_and): Likewise.
5453 (emit_orr): Likewise.
5454 (emit_orn): Likewise.
5455 (emit_eor): Likewise.
5456 (emit_mvn): Likewise.
5457 (emit_lslv): Likewise.
5458 (emit_lsrv): Likewise.
5459 (emit_asrv): Likewise.
5460 (emit_mul): Likewise.
5461 (emit_sbfm): Likewise.
5462 (emit_sbfx): Likewise.
5463 (emit_ubfm): Likewise.
5464 (emit_ubfx): Likewise.
5465 (emit_csinc): Likewise.
5466 (emit_cset): Likewise.
5467 (emit_nop): Likewise.
5468 (emit_ops_insns): New helper function.
5469 (emit_pop): Likewise.
5470 (emit_push): Likewise.
5471 (aarch64_emit_prologue): New function.
5472 (aarch64_emit_epilogue): Likewise.
5473 (aarch64_emit_add): Likewise.
5474 (aarch64_emit_sub): Likewise.
5475 (aarch64_emit_mul): Likewise.
5476 (aarch64_emit_lsh): Likewise.
5477 (aarch64_emit_rsh_signed): Likewise.
5478 (aarch64_emit_rsh_unsigned): Likewise.
5479 (aarch64_emit_ext): Likewise.
5480 (aarch64_emit_log_not): Likewise.
5481 (aarch64_emit_bit_and): Likewise.
5482 (aarch64_emit_bit_or): Likewise.
5483 (aarch64_emit_bit_xor): Likewise.
5484 (aarch64_emit_bit_not): Likewise.
5485 (aarch64_emit_equal): Likewise.
5486 (aarch64_emit_less_signed): Likewise.
5487 (aarch64_emit_less_unsigned): Likewise.
5488 (aarch64_emit_ref): Likewise.
5489 (aarch64_emit_if_goto): Likewise.
5490 (aarch64_emit_goto): Likewise.
5491 (aarch64_write_goto_address): Likewise.
5492 (aarch64_emit_const): Likewise.
5493 (aarch64_emit_call): Likewise.
5494 (aarch64_emit_reg): Likewise.
5495 (aarch64_emit_pop): Likewise.
5496 (aarch64_emit_stack_flush): Likewise.
5497 (aarch64_emit_zero_ext): Likewise.
5498 (aarch64_emit_swap): Likewise.
5499 (aarch64_emit_stack_adjust): Likewise.
5500 (aarch64_emit_int_call_1): Likewise.
5501 (aarch64_emit_void_call_2): Likewise.
5502 (aarch64_emit_eq_goto): Likewise.
5503 (aarch64_emit_ne_goto): Likewise.
5504 (aarch64_emit_lt_goto): Likewise.
5505 (aarch64_emit_le_goto): Likewise.
5506 (aarch64_emit_gt_goto): Likewise.
5507 (aarch64_emit_ge_got): Likewise.
5508 (aarch64_emit_ops_impl): New static global variable.
5509 (aarch64_emit_ops): New target function, return
5510 &aarch64_emit_ops_impl.
5511 (struct linux_target_ops): Install it.
5512
5513 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5514
5515 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
5516 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
5517 aarch64-ipa.o.
5518 * linux-aarch64-ipa.c: New file.
5519 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
5520 and endian.h.
5521 (aarch64_get_thread_area): New target method.
5522 (extract_signed_bitfield): New helper function.
5523 (aarch64_decode_ldr_literal): New function.
5524 (enum aarch64_opcodes): New enum.
5525 (struct aarch64_register): New struct.
5526 (struct aarch64_operand): New struct.
5527 (x0): New static global.
5528 (x1): Likewise.
5529 (x2): Likewise.
5530 (x3): Likewise.
5531 (x4): Likewise.
5532 (w2): Likewise.
5533 (ip0): Likewise.
5534 (sp): Likewise.
5535 (xzr): Likewise.
5536 (aarch64_register): New helper function.
5537 (register_operand): Likewise.
5538 (immediate_operand): Likewise.
5539 (struct aarch64_memory_operand): New struct.
5540 (offset_memory_operand): New helper function.
5541 (preindex_memory_operand): Likewise.
5542 (enum aarch64_system_control_registers): New enum.
5543 (ENCODE): New macro.
5544 (emit_insn): New helper function.
5545 (emit_b): New function.
5546 (emit_bcond): Likewise.
5547 (emit_cb): Likewise.
5548 (emit_tb): Likewise.
5549 (emit_blr): Likewise.
5550 (emit_stp): Likewise.
5551 (emit_ldp_q_offset): Likewise.
5552 (emit_stp_q_offset): Likewise.
5553 (emit_load_store): Likewise.
5554 (emit_ldr): Likewise.
5555 (emit_ldrsw): Likewise.
5556 (emit_str): Likewise.
5557 (emit_ldaxr): Likewise.
5558 (emit_stxr): Likewise.
5559 (emit_stlr): Likewise.
5560 (emit_data_processing_reg): Likewise.
5561 (emit_data_processing): Likewise.
5562 (emit_add): Likewise.
5563 (emit_sub): Likewise.
5564 (emit_mov): Likewise.
5565 (emit_movk): Likewise.
5566 (emit_mov_addr): Likewise.
5567 (emit_mrs): Likewise.
5568 (emit_msr): Likewise.
5569 (emit_sevl): Likewise.
5570 (emit_wfe): Likewise.
5571 (append_insns): Likewise.
5572 (can_encode_int32_in): New helper function.
5573 (aarch64_relocate_instruction): New function.
5574 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
5575 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
5576 (struct linux_target_ops): Install aarch64_get_thread_area,
5577 aarch64_install_fast_tracepoint_jump_pad and
5578 aarch64_get_min_fast_tracepoint_insn_len.
5579
5580 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5581
5582 * Makefile.in (aarch64-insn.o): New rule.
5583 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
5584
5585 2015-09-21 Yao Qi <yao.qi@linaro.org>
5586
5587 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
5588
5589 2015-09-21 Yao Qi <yao.qi@linaro.org>
5590
5591 * tracepoint.c (max_jump_pad_size): Remove.
5592
5593 2015-09-18 Yao Qi <yao.qi@linaro.org>
5594
5595 * linux-aarch64-low.c: Don't include sys/uio.h.
5596 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
5597
5598 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
5599
5600 * tracepoint.c (eval_result_type): Change prototype.
5601 (condition_true_at_tracepoint): Fix argument to compiled_cond.
5602
5603 2015-09-15 Pedro Alves <palves@redhat.com>
5604
5605 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
5606 Check whether to report exec events instead of checking whether
5607 multiprocess is enabled.
5608
5609 2015-09-15 Pedro Alves <palves@redhat.com>
5610
5611 PR remote/18965
5612 * remote-utils.c (prepare_resume_reply): Merge
5613 TARGET_WAITKIND_VFORK_DONE switch case with the
5614 TARGET_WAITKIND_FORKED case.
5615
5616 2015-09-15 Yao Qi <yao.qi@linaro.org>
5617
5618 * server.c (handle_query): Check string comparison using
5619 "else if" instead of "if".
5620
5621 2015-09-15 Yao Qi <yao.qi@linaro.org>
5622
5623 * server.c (vCont_supported): New global variable.
5624 (handle_query): Set vCont_supported to 1 if "vContSupported+"
5625 matches. Append ";vContSupported+" to own_buf.
5626 (handle_v_requests): Append ";s;S" to own_buf if target supports
5627 hardware single step or vCont_supported is false.
5628 (capture_main): Set vCont_supported to zero.
5629
5630 2015-09-15 Yao Qi <yao.qi@linaro.org>
5631
5632 * linux-low.c (linux_supports_conditional_breakpoints): Rename
5633 it to ...
5634 (linux_supports_hardware_single_step): ... New function.
5635 (linux_target_ops): Update.
5636 * lynx-low.c (lynx_target_ops): Set field
5637 supports_hardware_single_step to target_can_do_hardware_single_step.
5638 * nto-low.c (nto_target_ops): Likewise.
5639 * spu-low.c (spu_target_ops): Likewise.
5640 * win32-low.c (win32_target_ops): Likewise.
5641 * target.c (target_can_do_hardware_single_step): New function.
5642 * target.h (struct target_ops) <supports_conditional_breakpoints>:
5643 Remove. <supports_hardware_single_step>: New field.
5644 (target_supports_conditional_breakpoints): Remove.
5645 (target_supports_hardware_single_step): New macro.
5646 (target_can_do_hardware_single_step): Declare.
5647 * server.c (handle_query): Use target_supports_hardware_single_step
5648 instead of target_supports_conditional_breakpoints.
5649
5650 2015-09-15 Yao Qi <yao.qi@linaro.org>
5651
5652 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
5653 function.
5654 (struct linux_target_ops the_low_target): Install
5655 aarch64_linux_siginfo_fixup.
5656
5657 2015-09-11 Don Breazeal <donb@codesourcery.com>
5658 Luis Machado <lgustavo@codesourcery.com>
5659
5660 * linux-low.c (linux_mourn): Static declaration.
5661 (linux_arch_setup): Move in front of
5662 handle_extended_wait.
5663 (linux_arch_setup_thread): New function.
5664 (handle_extended_wait): Handle exec events. Call
5665 linux_arch_setup_thread. Make event_lwp argument a
5666 pointer-to-a-pointer.
5667 (check_zombie_leaders): Do not check stopped threads.
5668 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
5669 (linux_low_filter_event): Add lwp and thread for exec'ing
5670 non-leader thread if leader thread has been deleted.
5671 Refactor code into linux_arch_setup_thread and call it.
5672 Pass child lwp pointer by reference to handle_extended_wait.
5673 (linux_wait_for_event_filtered): Update comment.
5674 (linux_wait_1): Prevent clobbering exec event status.
5675 (linux_supports_exec_events): New function.
5676 (linux_target_ops) <supports_exec_events>: Initialize new member.
5677 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
5678 new member.
5679 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
5680 * server.c (report_exec_events): New global variable.
5681 (handle_query): Handle qSupported query for exec-events feature.
5682 (captured_main): Initialize report_exec_events.
5683 * server.h (report_exec_events): Declare new global variable.
5684 * target.h (struct target_ops) <supports_exec_events>: New
5685 member.
5686 (target_supports_exec_events): New macro.
5687 * win32-low.c (win32_target_ops) <supports_exec_events>:
5688 Initialize new member.
5689
5690 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
5691
5692 * linux-low.c (linux_low_enable_btrace): Remove.
5693 (linux_target_ops): Replace linux_low_enable_btrace with
5694 linux_enable_btrace.
5695
5696 2015-09-03 Yao Qi <yao.qi@linaro.org>
5697
5698 * linux-aarch64-low.c (aarch64_insert_point): Call
5699 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
5700 returns true.
5701
5702 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
5703
5704 * linux-low.c (check_stopped_by_breakpoint): Use
5705 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
5706
5707 2015-08-27 Pedro Alves <palves@redhat.com>
5708
5709 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
5710
5711 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
5712
5713 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
5714 the XNEW-family equivalent.
5715 (compile_bytecodes): Likewise.
5716 * dll.c (loaded_dll): Likewise.
5717 * event-loop.c (append_callback_event): Likewise.
5718 (create_file_handler): Likewise.
5719 (create_file_event): Likewise.
5720 * hostio.c (handle_open): Likewise.
5721 * inferiors.c (add_thread): Likewise.
5722 (add_process): Likewise.
5723 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
5724 * linux-arm-low.c (arm_new_process): Likewise.
5725 (arm_new_thread): Likewise.
5726 * linux-low.c (add_to_pid_list): Likewise.
5727 (linux_add_process): Likewise.
5728 (handle_extended_wait): Likewise.
5729 (add_lwp): Likewise.
5730 (enqueue_one_deferred_signal): Likewise.
5731 (enqueue_pending_signal): Likewise.
5732 (linux_resume_one_lwp_throw): Likewise.
5733 (linux_resume_one_thread): Likewise.
5734 (linux_read_memory): Likewise.
5735 (linux_write_memory): Likewise.
5736 * linux-mips-low.c (mips_linux_new_process): Likewise.
5737 (mips_linux_new_thread): Likewise.
5738 (mips_add_watchpoint): Likewise.
5739 * linux-x86-low.c (initialize_low_arch): Likewise.
5740 * lynx-low.c (lynx_add_process): Likewise.
5741 * mem-break.c (set_raw_breakpoint_at): Likewise.
5742 (set_breakpoint): Likewise.
5743 (add_condition_to_breakpoint): Likewise.
5744 (add_commands_to_breakpoint): Likewise.
5745 (clone_agent_expr): Likewise.
5746 (clone_one_breakpoint): Likewise.
5747 * regcache.c (new_register_cache): Likewise.
5748 * remote-utils.c (look_up_one_symbol): Likewise.
5749 * server.c (queue_stop_reply): Likewise.
5750 (start_inferior): Likewise.
5751 (queue_stop_reply_callback): Likewise.
5752 (handle_target_event): Likewise.
5753 * spu-low.c (fetch_ppc_memory): Likewise.
5754 (store_ppc_memory): Likewise.
5755 * target.c (set_target_ops): Likewise.
5756 * thread-db.c (thread_db_load_search): Likewise.
5757 (try_thread_db_load_1): Likewise.
5758 * tracepoint.c (add_tracepoint): Likewise.
5759 (add_tracepoint_action): Likewise.
5760 (create_trace_state_variable): Likewise.
5761 (cmd_qtdpsrc): Likewise.
5762 (cmd_qtro): Likewise.
5763 (add_while_stepping_state): Likewise.
5764 * win32-low.c (child_add_thread): Likewise.
5765 (get_image_name): Likewise.
5766
5767 2015-08-25 Yao Qi <yao.qi@linaro.org>
5768
5769 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
5770
5771 2015-08-25 Yao Qi <yao.qi@linaro.org>
5772
5773 * Makefile.in (aarch64-linux.o): New rule.
5774 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
5775 srv_tgtobj.
5776 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
5777 (aarch64_init_debug_reg_state): Make it extern.
5778 (aarch64_linux_prepare_to_resume): Remove.
5779
5780 2015-08-25 Yao Qi <yao.qi@linaro.org>
5781
5782 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
5783 lwp_arch_private_info and ptid_of_lwp.
5784
5785 2015-08-25 Yao Qi <yao.qi@linaro.org>
5786
5787 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
5788 Find proc_info by find_process_pid. All callers updated.
5789
5790 2015-08-25 Yao Qi <yao.qi@linaro.org>
5791
5792 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
5793 Remove.
5794 (debug_reg_change_callback): Remove.
5795 (aarch64_notify_debug_reg_change): Remove.
5796
5797 2015-08-25 Yao Qi <yao.qi@linaro.org>
5798
5799 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
5800 Call current_lwp_ptid.
5801
5802 2015-08-25 Yao Qi <yao.qi@linaro.org>
5803
5804 * linux-aarch64-low.c (debug_reg_change_callback): Use
5805 debug_printf.
5806
5807 2015-08-25 Yao Qi <yao.qi@linaro.org>
5808
5809 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
5810
5811 2015-08-25 Yao Qi <yao.qi@linaro.org>
5812
5813 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
5814
5815 2015-08-25 Yao Qi <yao.qi@linaro.org>
5816
5817 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
5818 the code.
5819
5820 2015-08-25 Yao Qi <yao.qi@linaro.org>
5821
5822 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
5823 Remove.
5824 (debug_reg_change_callback): Remove argument entry and add argument
5825 lwp. Remove local variable thread. Don't print thread id in the
5826 debugging output. Don't check whether pid of thread equals to pid.
5827 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
5828 iterate_over_lwps instead find_inferior.
5829
5830 2015-08-24 Pedro Alves <palves@redhat.com>
5831
5832 * inferiors.c (get_first_process): New function.
5833 * inferiors.h (get_first_process): New declaration.
5834 * remote-utils.c (read_ptid): Default to the first process in the
5835 list, instead of to the current thread's process.
5836
5837 2015-08-24 Pedro Alves <palves@redhat.com>
5838
5839 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
5840 * event-loop.c: Likewise.
5841 * remote-utils.c: Likewise.
5842 * tracepoint.c: Likewise.
5843
5844 2015-08-24 Pedro Alves <palves@redhat.com>
5845
5846 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
5847 ptid_get_lwp.
5848
5849 2015-08-21 Pedro Alves <palves@redhat.com>
5850
5851 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
5852 instead of literal 1.
5853
5854 2015-08-21 Pedro Alves <palves@redhat.com>
5855
5856 * tdesc.c (default_description): Explicitly zero-initialize.
5857
5858 2015-08-21 Pedro Alves <palves@redhat.com>
5859
5860 PR gdb/18749
5861 * inferiors.c (remove_thread): Discard any pending stop reply for
5862 this thread.
5863 * server.c (remove_all_on_match_pid): Rename to ...
5864 (remove_all_on_match_ptid): ... this. Work with a filter ptid
5865 instead of a pid.
5866 (discard_queued_stop_replies): Change parameter to a ptid. Now
5867 extern.
5868 (handle_v_kill, kill_inferior_callback, captured_main)
5869 (process_serial_event): Adjust.
5870 * server.h (discard_queued_stop_replies): Declare.
5871
5872 2015-08-21 Pedro Alves <palves@redhat.com>
5873
5874 * linux-low.c (wait_for_sigstop): Always switch to no thread
5875 selected if the previously current thread dies.
5876 * lynx-low.c (lynx_request_interrupt): Use the first thread's
5877 process instead of the current thread's.
5878 * remote-utils.c (input_interrupt): Don't check if there's no
5879 current thread.
5880 * server.c (gdb_read_memory, gdb_write_memory): If setting the
5881 current thread to the general thread fails, error out.
5882 (handle_qxfer_auxv, handle_qxfer_libraries)
5883 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
5884 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
5885 (handle_query): Check if there's a thread selected instead of
5886 checking whether there's any thread in the thread list.
5887 (handle_qxfer_threads, handle_qxfer_btrace)
5888 (handle_qxfer_btrace_conf): Don't error out early if there's no
5889 thread in the thread list.
5890 (handle_v_cont, myresume): Don't set the current thread to the
5891 continue thread.
5892 (process_serial_event) <Hg handling>: Also set thread_id if the
5893 previous general thread is still alive.
5894 (process_serial_event) <g/G handling>: If setting the current
5895 thread to the general thread fails, error out.
5896 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
5897 thread's lwp instead of the current thread's.
5898 * target.c (set_desired_thread): If the desired thread was not
5899 found, leave the current thread pointing to NULL. Return an int
5900 (boolean) indicating success.
5901 * target.h (set_desired_thread): Change return type to int.
5902
5903 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
5904
5905 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
5906 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
5907 #includes.
5908 (ps_get_thread_area): New function.
5909
5910 2015-08-19 Gary Benson <gbenson@redhat.com>
5911
5912 * hostio.c (handle_pread): Do not attempt to read more data
5913 than hostio_reply_with_data can fit in a packet.
5914
5915 2015-08-18 Joel Brobecker <brobecker@adacore.com>
5916
5917 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
5918
5919 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
5920
5921 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
5922
5923 2015-08-06 Pedro Alves <palves@redhat.com>
5924
5925 * tracepoint.c (expr_eval_result): Now an int.
5926
5927 2015-08-06 Pedro Alves <palves@redhat.com>
5928
5929 * gdbthread.h (struct regcache): Forward declare.
5930 (struct thread_info) <regcache_data>: Now a struct regcache
5931 pointer.
5932 * inferiors.c (inferior_regcache_data)
5933 (set_inferior_regcache_data): Now work with struct regcache
5934 pointers.
5935 * inferiors.h (struct regcache): Forward declare.
5936 (inferior_regcache_data, set_inferior_regcache_data): Now work
5937 with struct regcache pointers.
5938 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
5939 (free_register_cache_thread): Remove struct regcache pointer
5940 casts.
5941
5942 2015-08-06 Pedro Alves <palves@redhat.com>
5943
5944 * server.c (captured_main): On error, print the exception message
5945 to stderr, and if run_once is set, throw a quit.
5946
5947 2015-08-06 Pedro Alves <palves@redhat.com>
5948
5949 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
5950 the current thread.
5951
5952 2015-08-06 Pedro Alves <palves@redhat.com>
5953
5954 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
5955 reading beyond the passed in buffer length.
5956
5957 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
5958
5959 * tracepoint.c (symbol_list) <required>: Remove.
5960
5961 2015-08-06 Pedro Alves <palves@redhat.com>
5962
5963 * linux-low.c (handle_extended_wait): Set the fork child's suspend
5964 count if stopping and suspending threads.
5965 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
5966 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
5967 (linux_detach): Complete an ongoing step-over.
5968 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
5969 throughout.
5970 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
5971 (linux_wait_1): If passing a signal to the inferior after
5972 finishing a step-over, unsuspend and re-resume all lwps. If we
5973 see a single-step event but the thread should be continuing, don't
5974 pass the trap to gdb.
5975 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
5976 internal_error instead of gdb_assert.
5977 (enqueue_pending_signal): New function.
5978 (check_ptrace_stopped_lwp_gone): Add debug output.
5979 (start_step_over): Use internal_error instead of gdb_assert.
5980 (complete_ongoing_step_over): New function.
5981 (linux_resume_one_thread): Don't resume a suspended thread.
5982 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
5983 it stepping.
5984
5985 2015-08-06 Pedro Alves <palves@redhat.com>
5986
5987 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
5988 (linux_thread_alive): Use lwp_is_marked_dead.
5989 (extended_event_reported): Delete.
5990 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
5991 instead of extended_event_reported.
5992 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
5993 as well.
5994 (lwp_is_marked_dead): New function.
5995 (lwp_running): Use lwp_is_marked_dead.
5996 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
5997 comment.
5998
5999 2015-08-06 Pedro Alves <palves@redhat.com>
6000
6001 * linux-low.c (linux_wait_1): Move fork event output out of the
6002 !report_to_gdb check. Pass event_child->waitstatus to
6003 target_waitstatus_to_string instead of ourstatus.
6004
6005 2015-08-04 Yao Qi <yao.qi@linaro.org>
6006
6007 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
6008 if current_thread is 32 bit.
6009
6010 2015-08-04 Yao Qi <yao.qi@linaro.org>
6011
6012 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
6013 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
6014 * server.c (extended_protocol): Remove "static".
6015 * server.h (extended_protocol): Declare it.
6016
6017 2015-08-04 Yao Qi <yao.qi@linaro.org>
6018
6019 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
6020 both aarch64 and aarch32.
6021 (aarch64_set_pc): Likewise.
6022
6023 2015-08-04 Yao Qi <yao.qi@linaro.org>
6024
6025 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
6026 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
6027 arm-with-neon.xml to srv_xmlfiles.
6028 * linux-aarch64-low.c: Include linux-aarch32-low.h.
6029 (is_64bit_tdesc): New function.
6030 (aarch64_linux_read_description): New function.
6031 (aarch64_arch_setup): Call aarch64_linux_read_description.
6032 (regs_info): Rename to regs_info_aarch64.
6033 (aarch64_regs_info): Return right regs_info.
6034 (initialize_low_arch): Call initialize_low_arch_aarch32.
6035
6036 2015-08-04 Yao Qi <yao.qi@linaro.org>
6037
6038 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
6039 * linux-aarch32-low.c: New file.
6040 * linux-aarch32-low.h: New file.
6041 * linux-arm-low.c (arm_fill_gregset): Move it to
6042 linux-aarch32-low.c.
6043 (arm_store_gregset): Likewise.
6044 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
6045 (arm_store_vfpregset): Call arm_store_vfpregset_num.
6046 (arm_arch_setup): Check if PTRACE_GETREGSET works.
6047 (regs_info): Rename to regs_info_arm.
6048 (arm_regs_info): Return regs_info_aarch32 if
6049 have_ptrace_getregset is 1 and target description is
6050 arm_with_neon or arm_with_vfpv3.
6051 (initialize_low_arch): Don't call init_registers_arm_with_neon.
6052 Call initialize_low_arch_aarch32 instead.
6053
6054 2015-08-04 Yao Qi <yao.qi@linaro.org>
6055
6056 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
6057 * linux-low.c: ... here.
6058 * linux-low.h (have_ptrace_getregset): Declare it.
6059
6060 2015-08-04 Pedro Alves <palves@redhat.com>
6061
6062 * thread-db.c (struct thread_db): Use new typedefs.
6063 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
6064 CHK calls.
6065 (disable_thread_event_reporting): Cast result of dlsym to
6066 destination function pointer type.
6067 (thread_db_mourn): Use td_ta_delete_ftype.
6068
6069 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
6070
6071 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
6072 arch variant.
6073 (CDX_BREAKPOINT): Define for R2.
6074 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
6075 (the_low_target): Add comments.
6076
6077 2015-07-30 Yao Qi <yao.qi@linaro.org>
6078
6079 * linux-arm-low.c (arm_hwcap): Remove it.
6080 (arm_read_description): New local variable arm_hwcap. Don't
6081 set arm_hwcap to zero.
6082
6083 2015-07-30 Yao Qi <yao.qi@linaro.org>
6084
6085 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
6086 Use regcache->tdesc instead.
6087 (arm_store_wmmxregset): Likewise.
6088 (arm_fill_vfpregset): Likewise.
6089 (arm_store_vfpregset): Likewise.
6090
6091 2015-07-30 Yao Qi <yao.qi@linaro.org>
6092
6093 * linux-arm-low.c: Include arch/arm.h.
6094 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
6095 (arm_store_gregset): Likewise.
6096
6097 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
6098
6099 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
6100 ptrace's 4th parameter.
6101
6102 2015-07-27 Yao Qi <yao.qi@linaro.org>
6103
6104 * configure.srv (case aarch64*-*-linux*): Don't set
6105 srv_linux_usrregs.
6106
6107 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
6108
6109 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
6110 sys/ptrace.h.
6111 * linux-arm-low.c: Likewise.
6112 * linux-cris-low.c: Likewise.
6113 * linux-crisv32-low.c: Likewise.
6114 * linux-low.c: Likewise.
6115 * linux-m68k-low.c: Likewise.
6116 * linux-mips-low.c: Likewise.
6117 * linux-nios2-low.c: Likewise.
6118 * linux-s390-low.c: Likewise.
6119 * linux-sparc-low.c: Likewise.
6120 * linux-tic6x-low.c: Likewise.
6121 * linux-tile-low.c: Likewise.
6122 * linux-x86-low.c: Likewise.
6123
6124 2015-07-24 Pedro Alves <palves@redhat.com>
6125
6126 * config.in: Regenerate.
6127 * configure: Regenerate.
6128
6129 2015-07-24 Pedro Alves <palves@redhat.com>
6130
6131 * acinclude.m4: Include ../ptrace.m4.
6132 * configure.ac: Call GDB_AC_PTRACE.
6133 * config.in, configure: Regenerate.
6134
6135 2015-07-24 Yao Qi <yao.qi@linaro.org>
6136
6137 * linux-low.c (linux_create_inferior): Remove setting to
6138 proc->priv->new_inferior.
6139 (linux_attach): Likewise.
6140 (linux_low_filter_event): Likewise.
6141 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
6142
6143 2015-07-24 Yao Qi <yao.qi@linaro.org>
6144
6145 * linux-low.c (linux_arch_setup): New function.
6146 (linux_low_filter_event): If proc->tdesc is NULL and
6147 proc->attached is true, call the_low_target.arch_setup.
6148 Otherwise, keep status pending, and return.
6149 (linux_resume_one_lwp_throw): Don't call get_pc if
6150 thread->while_stepping isn't NULL. Don't call
6151 get_thread_regcache if proc->tdesc is NULL.
6152 (need_step_over_p): Return 0 if proc->tdesc is NULL.
6153 (linux_target_ops): Install arch_setup.
6154 * server.c (start_inferior): Call the_target->arch_setup.
6155 * target.h (struct target_ops) <arch_setup>: New field.
6156 (target_arch_setup): New marco.
6157 * lynx-low.c (lynx_target_ops): Update.
6158 * nto-low.c (nto_target_ops): Update.
6159 * spu-low.c (spu_target_ops): Update.
6160 * win32-low.c (win32_target_ops): Update.
6161
6162 2015-07-24 Yao Qi <yao.qi@linaro.org>
6163
6164 * linux-low.c (linux_add_process): Don't set
6165 proc->priv->new_inferior.
6166 (linux_create_inferior): Set proc->priv->new_inferior to 1.
6167 (linux_attach): Likewise.
6168
6169 2015-07-24 Yao Qi <yao.qi@linaro.org>
6170
6171 * server.c (start_inferior): Code refactor.
6172
6173 2015-07-24 Yao Qi <yao.qi@linaro.org>
6174
6175 * server.c (process_serial_event): Set general_thread.
6176
6177 2015-07-21 Yao Qi <yao.qi@linaro.org>
6178
6179 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
6180 aarch64_linux_get_debug_reg_capacity.
6181
6182 2015-07-17 Yao Qi <yao.qi@linaro.org>
6183
6184 * Makefile.in (aarch64-linux-hw-point.o): New rule.
6185 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
6186 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
6187 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
6188 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
6189 (AARCH64_HWP_ALIGNMENT): Likewise.
6190 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
6191 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
6192 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
6193 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
6194 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
6195 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
6196 (struct aarch64_debug_reg_state): Likewise.
6197 (struct arch_lwp_info): Likewise.
6198 (aarch64_align_watchpoint): Likewise.
6199 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
6200 (aarch64_watchpoint_length): Likewise.
6201 (aarch64_point_encode_ctrl_reg): Likewise
6202 (aarch64_point_is_aligned): Likewise.
6203 (aarch64_align_watchpoint): Likewise.
6204 (aarch64_linux_set_debug_regs):
6205 (aarch64_dr_state_insert_one_point): Likewise.
6206 (aarch64_dr_state_remove_one_point): Likewise.
6207 (aarch64_handle_breakpoint): Likewise.
6208 (aarch64_handle_aligned_watchpoint): Likewise.
6209 (aarch64_handle_unaligned_watchpoint): Likewise.
6210 (aarch64_handle_watchpoint): Likewise.
6211
6212 2015-07-17 Yao Qi <yao.qi@linaro.org>
6213
6214 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
6215 and don't aarch64_get_debug_reg_state. All callers update.
6216 (aarch64_handle_aligned_watchpoint): Likewise.
6217 (aarch64_handle_unaligned_watchpoint): Likewise.
6218 (aarch64_handle_watchpoint): Likewise.
6219 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
6220 (aarch64_remove_point): Likewise.
6221
6222 2015-07-17 Yao Qi <yao.qi@linaro.org>
6223
6224 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
6225 debug_printf.
6226 (aarch64_handle_unaligned_watchpoint): Likewise.
6227
6228 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
6229
6230 Revert the previous 3 commits:
6231 Move gdb_regex* to common/
6232 Move linux_find_memory_regions_full & co.
6233 gdbserver build-id attribute generator
6234
6235 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6236 Jan Kratochvil <jan.kratochvil@redhat.com>
6237
6238 gdbserver build-id attribute generator.
6239 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
6240 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
6241 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
6242 (find_phdr): New.
6243 (get_dynamic): Use find_pdhr to traverse program headers.
6244 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
6245 (compare_mapping_entry_range, struct find_memory_region_callback_data)
6246 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
6247 (get_hex_build_id): New.
6248 (linux_qxfer_libraries_svr4): Add optional build-id attribute
6249 to reply XML document.
6250
6251 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6252 Jan Kratochvil <jan.kratochvil@redhat.com>
6253
6254 * target.c: Include target/target-utils.h and fcntl.h.
6255 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
6256 (target_fileio_read_stralloc): New functions.
6257
6258 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
6259
6260 * Makefile.in (OBS): Add gdb_regex.o.
6261 (gdb_regex.o): New.
6262 * config.in: Rebuilt.
6263 * configure: Rebuilt.
6264
6265 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6266 Jan Kratochvil <jan.kratochvil@redhat.com>
6267
6268 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
6269 * Makefile.in (OBS): Add target-utils.o.
6270 (linux-maps.o, target-utils.o): New.
6271 * configure.srv (srv_linux_obj): Add linux-maps.o.
6272
6273 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
6274
6275 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
6276 function, return 1.
6277 (the_low_target): Install it.
6278
6279 2015-07-14 Pedro Alves <palves@redhat.com>
6280
6281 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
6282 Instead, ignore ECHILD, and throw an error for other errnos.
6283
6284 2015-07-10 Pedro Alves <palves@redhat.com>
6285
6286 * event-loop.c (struct callback_event) <data>: Change type to
6287 gdb_client_data instance instead of gdb_client_data pointer.
6288 (append_callback_event): Adjust.
6289
6290 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
6291
6292 * linux-aarch64-low.c: Add comments for each linux_target_ops
6293 method. Remove comments already covered in target_ops and
6294 linux_target_ops definitions.
6295 (the_low_target): Add comments for each unimplemented method.
6296
6297 2015-07-09 Yao Qi <yao.qi@linaro.org>
6298
6299 * linux-aarch64-low.c (aarch64_regmap): Remove.
6300 (aarch64_usrregs_info): Remove.
6301 (regs_info): Set field usrregs to NULL.
6302
6303 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
6304
6305 * linux-low.c: Include "rsp-low.h"
6306 (linux_low_encode_pt_config, linux_low_encode_raw): New.
6307 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
6308 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
6309 (handle_btrace_enable_pt): New.
6310 (handle_btrace_general_set): Support "pt".
6311 (handle_btrace_conf_general_set): Support "pt:size".
6312
6313 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
6314
6315 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
6316 Z_PACKET_SW_BP.
6317
6318 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
6319
6320 * linux-aarch64-low.c: Remove comment about endianness.
6321 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
6322 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
6323 memcmp.
6324
6325 2015-06-24 Gary Benson <gbenson@redhat.com>
6326
6327 * linux-i386-ipa.c (stdint.h): Do not include.
6328 * lynx-i386-low.c (stdint.h): Likewise.
6329 * lynx-ppc-low.c (stdint.h): Likewise.
6330 * mem-break.c (stdint.h): Likewise.
6331 * thread-db.c (stdint.h): Likewise.
6332 * tracepoint.c (stdint.h): Likewise.
6333 * win32-low.c (stdint.h): Likewise.
6334
6335 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
6336
6337 * server.c (write_qxfer_response): Update call to
6338 remote_escape_output.
6339
6340 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
6341 Jan Kratochvil <jan.kratochvil@redhat.com>
6342
6343 Merge multiple hex conversions.
6344 * gdbreplay.c (tohex): Rename to 'fromhex'.
6345 (logchar): Use fromhex.
6346
6347 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
6348
6349 * server.c (handle_qxfer_libraries): Set `version' attribute for
6350 <library-list>.
6351
6352 2015-06-10 Gary Benson <gbenson@redhat.com>
6353
6354 * target.h (struct target_ops) <multifs_open>: New field.
6355 <multifs_unlink>: Likewise.
6356 <multifs_readlink>: Likewise.
6357 * linux-low.c (nat/linux-namespaces.h): New include.
6358 (linux_target_ops): Initialize the_target->multifs_open,
6359 the_target->multifs_unlink and the_target->multifs_readlink.
6360 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
6361 * hostio.c (hostio_fs_pid): New static variable.
6362 (hostio_handle_new_gdb_connection): New function.
6363 (handle_setfs): Likewise.
6364 (handle_open): Use the_target->multifs_open as appropriate.
6365 (handle_unlink): Use the_target->multifs_unlink as appropriate.
6366 (handle_readlink): Use the_target->multifs_readlink as
6367 appropriate.
6368 (handle_vFile): Handle vFile:setfs packets.
6369 * server.c (handle_query): Call hostio_handle_new_gdb_connection
6370 after target_handle_new_gdb_connection.
6371
6372 2015-06-10 Gary Benson <gbenson@redhat.com>
6373
6374 * configure.ac (AC_CHECK_FUNCS): Add setns.
6375 * config.in: Regenerate.
6376 * configure: Likewise.
6377 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
6378 (linux-namespaces.o): New rule.
6379 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
6380
6381 2015-06-09 Gary Benson <gbenson@redhat.com>
6382
6383 * hostio.c (handle_open): Process mode argument with
6384 fileio_to_host_mode.
6385
6386 2015-06-01 Yao Qi <yao.qi@linaro.org>
6387
6388 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
6389 * linux-x86-low.c: Likewise.
6390
6391 2015-05-28 Don Breazeal <donb@codesourcery.com>
6392
6393 * linux-low.c (handle_extended_wait): Initialize
6394 thread_info.last_resume_kind for new fork children.
6395
6396 2015-05-15 Pedro Alves <palves@redhat.com>
6397
6398 * target.h (target_handle_new_gdb_connection): Rewrite using if
6399 wrapped in do/while.
6400
6401 2015-05-14 Joel Brobecker <brobecker@adacore.com>
6402
6403 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
6404 * configure, config.in: Regenerate.
6405 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
6406 Declare typedef.
6407
6408 2015-05-12 Don Breazeal <donb@codesourcery.com>
6409
6410 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
6411 PTRACE_EVENT_VFORK_DONE.
6412 (linux_low_ptrace_options, extended_event_reported): Add vfork
6413 events.
6414 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
6415 and "vforkdone" for RSP 'T' Stop Reply Packet.
6416 * server.h (report_vfork_events): Declare
6417 global variable.
6418
6419 2015-05-12 Don Breazeal <donb@codesourcery.com>
6420
6421 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
6422 (the_low_target) <new_fork>: Initialize new member.
6423 * linux-arm-low.c (arm_new_fork): New function.
6424 (the_low_target) <new_fork>: Initialize new member.
6425 * linux-low.c (handle_extended_wait): Call new target function
6426 new_fork.
6427 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
6428 * linux-mips-low.c (mips_add_watchpoint): New function
6429 extracted from mips_insert_point.
6430 (the_low_target) <new_fork>: Initialize new member.
6431 (mips_linux_new_fork): New function.
6432 (mips_insert_point): Call mips_add_watchpoint.
6433 * linux-x86-low.c (x86_linux_new_fork): New function.
6434 (the_low_target) <new_fork>: Initialize new member.
6435
6436 2015-05-12 Don Breazeal <donb@codesourcery.com>
6437
6438 * linux-low.c (handle_extended_wait): Implement return value,
6439 rename argument 'event_child' to 'event_lwp', handle
6440 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
6441 (linux_low_ptrace_options): New function.
6442 (linux_low_filter_event): Call linux_low_ptrace_options,
6443 use different argument fo linux_enable_event_reporting,
6444 use return value from handle_extended_wait.
6445 (extended_event_reported): New function.
6446 (linux_wait_1): Call extended_event_reported and set
6447 status to report fork events.
6448 (linux_write_memory): Add pid to debug message.
6449 (reset_lwp_ptrace_options_callback): New function.
6450 (linux_handle_new_gdb_connection): New function.
6451 (linux_target_ops): Initialize new structure member.
6452 * linux-low.h (struct lwp_info) <waitstatus>: New member.
6453 * lynx-low.c: Initialize new structure member.
6454 * remote-utils.c (prepare_resume_reply): Implement stop reason
6455 "fork" for "T" stop message.
6456 * server.c (handle_query): Call handle_new_gdb_connection.
6457 * server.h (report_fork_events): Declare global flag.
6458 * target.h (struct target_ops) <handle_new_gdb_connection>:
6459 New member.
6460 (target_handle_new_gdb_connection): New macro.
6461 * win32-low.c: Initialize new structure member.
6462
6463 2015-05-12 Don Breazeal <donb@codesourcery.com>
6464
6465 * mem-break.c (APPEND_TO_LIST): Define macro.
6466 (clone_agent_expr): New function.
6467 (clone_one_breakpoint): New function.
6468 (clone_all_breakpoints): New function.
6469 * mem-break.h: Declare new functions.
6470
6471 2015-05-12 Don Breazeal <donb@codesourcery.com>
6472
6473 * linux-low.c (linux_supports_fork_events): New function.
6474 (linux_supports_vfork_events): New function.
6475 (linux_target_ops): Initialize new structure members.
6476 (initialize_low): Call linux_check_ptrace_features.
6477 * lynx-low.c (lynx_target_ops): Initialize new structure
6478 members.
6479 * server.c (report_fork_events, report_vfork_events):
6480 New global flags.
6481 (handle_query): Add new features to qSupported packet and
6482 response.
6483 (captured_main): Initialize new global variables.
6484 * target.h (struct target_ops) <supports_fork_events>:
6485 New member.
6486 <supports_vfork_events>: New member.
6487 (target_supports_fork_events): New macro.
6488 (target_supports_vfork_events): New macro.
6489 * win32-low.c (win32_target_ops): Initialize new structure
6490 members.
6491
6492 2015-05-12 Gary Benson <gbenson@redhat.com>
6493
6494 * server.c (handle_qxfer_exec_file): Use current process
6495 if annex is empty.
6496
6497 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
6498
6499 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
6500 Remove HAVE_PTRACE_GETREGS conditionals.
6501 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
6502 instead of PTRACE_GETREGS and PTRACE_SETREGS.
6503
6504 2015-05-08 Yao Qi <yao.qi@linaro.org>
6505
6506 * linux-low.c (linux_supports_conditional_breakpoints): New
6507 function.
6508 (linux_target_ops): Install new target method.
6509 * lynx-low.c (lynx_target_ops): Install NULL hook for
6510 supports_conditional_breakpoints.
6511 * nto-low.c (nto_target_ops): Likewise.
6512 * spu-low.c (spu_target_ops): Likewise.
6513 * win32-low.c (win32_target_ops): Likewise.
6514 * server.c (handle_query): Check
6515 target_supports_conditional_breakpoints.
6516 * target.h (struct target_ops) <supports_conditional_breakpoints>:
6517 New field.
6518 (target_supports_conditional_breakpoints): New macro.
6519
6520 2015-05-06 Pedro Alves <palves@redhat.com>
6521
6522 PR server/18081
6523 * server.c (start_inferior): If the process exits, mourn it.
6524
6525 2015-04-21 Gary Benson <gbenson@redhat.com>
6526
6527 * hostio.c (fileio_open_flags_to_host): Factored out to
6528 fileio_to_host_openflags in common/fileio.c. Single use
6529 updated.
6530
6531 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
6532
6533 * linux-xtensa-low.c (xtensa_fill_gregset)
6534 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
6535 XCHAL_HAVE_LOOP.
6536
6537 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
6538
6539 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
6540 (regs_info): Replace usrregs pointer with NULL.
6541
6542 2015-04-17 Gary Benson <gbenson@redhat.com>
6543
6544 * target.h (struct target_ops) <pid_to_exec_file>: New field.
6545 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
6546 * server.c (handle_qxfer_exec_file): New function.
6547 (qxfer_packets): Add exec-file entry.
6548 (handle_query): Report qXfer:exec-file:read as supported packet.
6549
6550 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
6551
6552 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
6553
6554 2015-04-09 Gary Benson <gbenson@redhat.com>
6555
6556 * hostio-errno.c (errno_to_fileio_error): Remove function.
6557 Update caller to use remote_fileio_to_fio_error.
6558
6559 2015-04-09 Yao Qi <yao.qi@linaro.org>
6560
6561 * linux-low.c (linux_insert_point): Call
6562 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
6563 (linux_remove_point): Call remove_memory_breakpoint if type is
6564 raw_bkpt_type_sw.
6565 * linux-x86-low.c (x86_insert_point): Don't call
6566 insert_memory_breakpoint.
6567 (x86_remove_point): Don't call remove_memory_breakpoint.
6568
6569 2015-04-01 Pedro Alves <palves@redhat.com>
6570 Cleber Rosa <crosa@redhat.com>
6571
6572 * server.c (gdbserver_usage): Reorganize and extend the usage
6573 message.
6574
6575 2015-03-24 Pedro Alves <palves@redhat.com>
6576
6577 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
6578 output. Also dump TRAP_TRACE.
6579 (linux_low_filter_event): In debug output, distinguish a
6580 resume_stop SIGSTOP from a delayed SIGSTOP.
6581
6582 2015-03-24 Gary Benson <gbenson@redhat.com>
6583
6584 * linux-x86-low.c (x86_linux_new_thread): Moved to
6585 nat/x86-linux.c.
6586 (x86_linux_prepare_to_resume): Likewise.
6587
6588 2015-03-24 Gary Benson <gbenson@redhat.com>
6589
6590 * Makefile.in (x86-linux-dregs.o): New rule.
6591 * configure.srv: Add x86-linux-dregs.o to relevant targets.
6592 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
6593 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
6594 (x86_linux_dr_get): Likewise.
6595 (x86_linux_dr_set): Likewise.
6596 (update_debug_registers_callback): Likewise.
6597 (x86_linux_dr_set_addr): Likewise.
6598 (x86_linux_dr_get_addr): Likewise.
6599 (x86_linux_dr_set_control): Likewise.
6600 (x86_linux_dr_get_control): Likewise.
6601 (x86_linux_dr_get_status): Likewise.
6602 (x86_linux_update_debug_registers): Likewise.
6603
6604 2015-03-24 Gary Benson <gbenson@redhat.com>
6605
6606 * linux-x86-low.c (x86_linux_update_debug_registers):
6607 New function, factored out from...
6608 (x86_linux_prepare_to_resume): ...this.
6609
6610 2015-03-24 Gary Benson <gbenson@redhat.com>
6611
6612 * linux-x86-low.c (x86_linux_dr_get): Update comments.
6613 (x86_linux_dr_set): Likewise.
6614 (update_debug_registers_callback): Likewise.
6615 (x86_linux_dr_set_addr): Likewise.
6616 (x86_linux_dr_get_addr): Likewise.
6617 (x86_linux_dr_set_control): Likewise.
6618 (x86_linux_dr_get_control): Likewise.
6619 (x86_linux_dr_get_status): Likewise.
6620 (x86_linux_prepare_to_resume): Likewise.
6621
6622 2015-03-24 Gary Benson <gbenson@redhat.com>
6623
6624 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
6625 Use perror_with_name. Pass string through gettext.
6626 (x86_linux_dr_set): Likewise.
6627
6628 2015-03-24 Gary Benson <gbenson@redhat.com>
6629
6630 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
6631 (x86_linux_dr_set_addr): ...this.
6632 (x86_dr_low_get_addr): Rename to...
6633 (x86_linux_dr_get_addr): ...this.
6634 (x86_dr_low_set_control): Rename to...
6635 (x86_linux_dr_set_control): ...this.
6636 (x86_dr_low_get_control): Rename to...
6637 (x86_linux_dr_get_control): ...this.
6638 (x86_dr_low_get_status): Rename to...
6639 (x86_linux_dr_get_status): ...this.
6640 (x86_dr_low): Update with new function names.
6641
6642 2015-03-24 Gary Benson <gbenson@redhat.com>
6643
6644 * Makefile.in (x86-linux.o): New rule.
6645 * configure.srv: Add x86-linux.o to relevant targets.
6646 * linux-low.c (lwp_set_arch_private_info): New function.
6647 (lwp_arch_private_info): Likewise.
6648 * linux-x86-low.c: Include nat/x86-linux.h.
6649 (arch_lwp_info): Removed structure.
6650 (update_debug_registers_callback):
6651 Use lwp_set_debug_registers_changed.
6652 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
6653 and lwp_set_debug_registers_changed.
6654 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
6655
6656 2015-03-24 Gary Benson <gbenson@redhat.com>
6657
6658 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
6659 * linux-arm-low.c (arm_new_thread): Likewise.
6660 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
6661 * linux-mips-low.c (mips_linux_new_thread): Likewise.
6662 * linux-x86-low.c (x86_linux_new_thread): Likewise.
6663 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
6664
6665 2015-03-24 Gary Benson <gbenson@redhat.com>
6666
6667 * linux-low.c (ptid_of_lwp): New function.
6668 (lwp_is_stopped): Likewise.
6669 (lwp_stop_reason): Likewise.
6670 * linux-x86-low.c (update_debug_registers_callback):
6671 Use lwp_is_stopped.
6672 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
6673 lwp_stop_reason.
6674
6675 2015-03-24 Gary Benson <gbenson@redhat.com>
6676
6677 * linux-low.h (linux_stop_lwp): Remove declaration.
6678
6679 2015-03-24 Gary Benson <gbenson@redhat.com>
6680
6681 * linux-low.h: Include nat/linux-nat.h.
6682 * linux-low.c (iterate_over_lwps_args): New structure.
6683 (iterate_over_lwps_filter): New function.
6684 (iterate_over_lwps): Likewise.
6685 * linux-x86-low.c (update_debug_registers_callback):
6686 Update signature to what iterate_over_lwps expects.
6687 Remove PID check that iterate_over_lwps now performs.
6688 (x86_dr_low_set_addr): Use iterate_over_lwps.
6689 (x86_dr_low_set_control): Likewise.
6690
6691 2015-03-24 Gary Benson <gbenson@redhat.com>
6692
6693 * linux-x86-low.c (x86_debug_reg_state): New function.
6694 (x86_linux_prepare_to_resume): Use the above.
6695
6696 2015-03-24 Gary Benson <gbenson@redhat.com>
6697
6698 * linux-low.c (current_lwp_ptid): New function.
6699 * linux-x86-low.c: Include nat/linux-nat.h.
6700 (x86_dr_low_get_addr): Use current_lwp_ptid.
6701 (x86_dr_low_get_control): Likewise.
6702 (x86_dr_low_get_status): Likewise.
6703
6704 2015-03-20 Pedro Alves <palves@redhat.com>
6705
6706 * tracepoint.c (cmd_qtstatus): Make "str" const.
6707
6708 2015-03-20 Pedro Alves <palves@redhat.com>
6709
6710 * server.c (handle_general_set): Make "req_str" const.
6711
6712 2015-03-19 Pedro Alves <palves@redhat.com>
6713
6714 * linux-low.c (linux_resume_one_lwp): Rename to ...
6715 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
6716 instead call perror_with_name.
6717 (check_ptrace_stopped_lwp_gone): New function.
6718 (linux_resume_one_lwp): Reimplement as wrapper around
6719 linux_resume_one_lwp_throw that swallows errors if the LWP is
6720 gone.
6721
6722 2015-03-19 Pedro Alves <palves@redhat.com>
6723
6724 * linux-low.c (count_events_callback, select_event_lwp_callback):
6725 No longer check whether the thread has resume_stop as last resume
6726 kind.
6727
6728 2015-03-19 Pedro Alves <palves@redhat.com>
6729
6730 * linux-low.c (count_events_callback, select_event_lwp_callback):
6731 Use the lwp's status_pending_p field, not the thread's.
6732
6733 2015-03-19 Pedro Alves <palves@redhat.com>
6734
6735 * linux-low.c (select_event_lwp_callback): Update comments to
6736 no longer mention SIGTRAP.
6737
6738 2015-03-18 Gary Benson <gbenson@redhat.com>
6739
6740 * server.c (handle_query): Do not report vFile:fstat as supported.
6741
6742 2015-03-11 Gary Benson <gbenson@redhat.com>
6743
6744 * hostio.c (sys/types.h): New include.
6745 (sys/stat.h): Likewise.
6746 (common-remote-fileio.h): Likewise.
6747 (handle_fstat): New function.
6748 (handle_vFile): Handle vFile:fstat packets.
6749
6750 2015-03-11 Gary Benson <gbenson@redhat.com>
6751
6752 * configure.ac (AC_CHECK_MEMBERS): Add checks for
6753 struct stat.st_blocks and struct stat.st_blksize.
6754 * configure: Regenerate.
6755 * config.in: Likewise.
6756 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
6757 (OBS): Add common-remote-fileio.o.
6758 (common-remote-fileio.o): New rule.
6759
6760 2015-03-09 Pedro Alves <palves@redhat.com>
6761
6762 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
6763 'struct sockaddr' pointer in 'accept' call.
6764
6765 2015-03-09 Pedro Alves <palves@redhat.com>
6766
6767 Revert:
6768 2015-03-07 Pedro Alves <palves@redhat.com>
6769 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
6770 or <winsock2.h> here. Instead include "gdb_socket.h".
6771 (remote_open): Use union gdb_sockaddr_u.
6772 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
6773 or <winsock2.h> here. Instead include "gdb_socket.h".
6774 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
6775 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
6776 or <sys/un.h>.
6777 (init_named_socket, gdb_agent_helper_thread): Use union
6778 gdb_sockaddr_u.
6779
6780 2015-03-07 Pedro Alves <palves@redhat.com>
6781
6782 * configure.ac (build_warnings): Move
6783 -Wdeclaration-after-statement to the C-specific set.
6784 * configure: Regenerate.
6785
6786 2015-03-07 Pedro Alves <palves@redhat.com>
6787
6788 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
6789 or <winsock2.h> here. Instead include "gdb_socket.h".
6790 (remote_open): Use union gdb_sockaddr_u.
6791 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
6792 or <winsock2.h> here. Instead include "gdb_socket.h".
6793 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
6794 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
6795 or <sys/un.h>.
6796 (init_named_socket, gdb_agent_helper_thread): Use union
6797 gdb_sockaddr_u.
6798
6799 2015-03-07 Pedro Alves <palves@redhat.com>
6800
6801 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
6802 instead.
6803
6804 2015-03-06 Yao Qi <yao.qi@linaro.org>
6805
6806 * linux-aarch64-low.c (aarch64_insert_point): Use
6807 show_debug_regs as a boolean.
6808 (aarch64_remove_point): Likewise.
6809
6810 2015-03-05 Pedro Alves <palves@redhat.com>
6811
6812 * lynx-low.c (lynx_target_ops): Install NULL hooks for
6813 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
6814 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
6815 * nto-low.c (nto_target_ops): Likewise.
6816 * spu-low.c (spu_target_ops): Likewise.
6817 * win32-low.c (win32_target_ops): Likewise.
6818
6819 2015-03-04 Pedro Alves <palves@redhat.com>
6820
6821 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
6822 Decide whether a breakpoint triggered based on the SIGTRAP's
6823 siginfo.si_code.
6824 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
6825 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
6826 (linux_low_filter_event): Check for breakpoints before checking
6827 watchpoints.
6828 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
6829 siginfo.si_code.
6830 (linux_stopped_by_sw_breakpoint)
6831 (linux_supports_stopped_by_sw_breakpoint)
6832 (linux_stopped_by_hw_breakpoint)
6833 (linux_supports_stopped_by_hw_breakpoint): New functions.
6834 (linux_target_ops): Install new target methods.
6835
6836 2015-03-04 Pedro Alves <palves@redhat.com>
6837
6838 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
6839 * server.c (swbreak_feature, hwbreak_feature): New globals.
6840 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
6841 (captured_main): Clear swbreak_feature and hwbreak_feature.
6842 * server.h (swbreak_feature, hwbreak_feature): Declare.
6843 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
6844 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
6845 supports_stopped_by_hw_breakpoint>: New fields.
6846 (target_supports_stopped_by_sw_breakpoint)
6847 (target_stopped_by_sw_breakpoint)
6848 (target_supports_stopped_by_hw_breakpoint)
6849 (target_stopped_by_hw_breakpoint): Declare.
6850
6851 2015-03-04 Pedro Alves <palves@redhat.com>
6852
6853 enum lwp_stop_reason -> enum target_stop_reason
6854 * linux-low.c (check_stopped_by_breakpoint): Adjust.
6855 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
6856 (linux_wait_1, stuck_in_jump_pad_callback)
6857 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
6858 (linux_stopped_by_watchpoint):
6859 * linux-low.h (enum lwp_stop_reason): Delete.
6860 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
6861 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
6862
6863 2015-03-04 Yao Qi <yao.qi@linaro.org>
6864
6865 * Makefile.in (SFILES): Add linux-aarch64-low.c.
6866
6867 2015-03-03 Gary Benson <gbenson@redhat.com>
6868
6869 * hostio.c (handle_vFile): Fix prefix lengths.
6870
6871 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
6872
6873 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
6874 ptr_bits.
6875
6876 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
6877
6878 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
6879 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
6880 (clean): Add "rm -f" for above C files.
6881 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
6882 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
6883 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
6884 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
6885 * linux-s390-low.c (HWCAP_S390_VX): New macro.
6886 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
6887 (init_registers_s390x_vx_linux64)
6888 (init_registers_s390x_tevx_linux64)
6889 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
6890 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
6891 declarations.
6892 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
6893 (s390_store_vxrs_high): New functions.
6894 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
6895 NT_S390_VXRS_HIGH.
6896 (s390_arch_setup): Add logic for selecting one of the new target
6897 descriptions. Activate the new vector regsets if applicable.
6898 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
6899 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
6900 and init_registers_s390x_tevx_linux64.
6901
6902 2015-03-01 Pedro Alves <palves@redhat.com>
6903
6904 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
6905 parameter.
6906
6907 2015-02-27 Pedro Alves <palves@redhat.com>
6908
6909 * linux-x86-low.c (u_debugreg_offset): New function.
6910 (x86_linux_dr_get, x86_linux_dr_set): Use it.
6911
6912 2015-02-27 Pedro Alves <palves@redhat.com>
6913
6914 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
6915 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
6916 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
6917 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
6918 (ps_lsetfpregs, ps_getpid)
6919 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
6920 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
6921 (ps_lsetxregs, ps_plog): Declare.
6922
6923 2015-02-27 Pedro Alves <palves@redhat.com>
6924
6925 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
6926 IP_AGENT_EXPORT_FUNC.
6927 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
6928 IP_AGENT_EXPORT_FUNC.
6929 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
6930 (IP_AGENT_EXPORT): Delete.
6931 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
6932 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
6933 (gdb_trampoline_buffer_error, collecting, gdb_collect)
6934 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
6935 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
6936 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
6937 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
6938 (traceframe_read_count, traceframe_write_count)
6939 (traceframes_created, trace_state_variables, get_raw_reg)
6940 (get_trace_state_variable_value, set_trace_state_variable_value)
6941 (ust_loaded, helper_thread_id, cmd_buf): Use
6942 IPA_SYM_EXPORTED_NAME.
6943 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
6944 (tracepoints) Use IP_AGENT_EXPORT_VAR.
6945 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
6946 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
6947 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
6948 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
6949 EXTERN_C_PUSH/EXTERN_C_POP.
6950 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
6951 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
6952 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
6953 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
6954 (traceframe_write_count, traceframe_read_count)
6955 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
6956 (about_to_request_buffer_space, get_trace_state_variable_value)
6957 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
6958 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
6959 EXTERN_C_PUSH/EXTERN_C_POP.
6960 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
6961 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
6962 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
6963 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
6964 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
6965 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
6966 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
6967 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
6968 Define.
6969 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
6970 (IP_AGENT_EXPORT_VAR_DECL): Define.
6971 (tracing): Declare.
6972 (gdb_agent_get_raw_reg): Declare.
6973
6974 2015-02-27 Tom Tromey <tromey@redhat.com>
6975 Pedro Alves <palves@redhat.com>
6976
6977 Rename symbols whose names are reserved C++ keywords throughout.
6978
6979 2015-02-27 Pedro Alves <palves@redhat.com>
6980
6981 * Makefile.in (COMPILER): New, get it from autoconf.
6982 (CXX): Get from autoconf instead.
6983 (COMPILE.pre): Use COMPILER.
6984 (CC-LD): Rename to ...
6985 (CC_LD): ... this. Use COMPILER.
6986 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
6987 (CXX_FOR_TARGET): Default to g++ instead of gcc.
6988 * acinclude.m4: Include build-with-cxx.m4.
6989 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
6990 Disable -Werror by default if building in C++ mode.
6991 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
6992 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
6993 the C++ compiler. Save/restore CXXFLAGS too.
6994 * configure: Regenerate.
6995
6996 2015-02-27 Pedro Alves <palves@redhat.com>
6997
6998 * acinclude.m4: Include libiberty.m4.
6999 * configure.ac: Call libiberty_INIT.
7000 * config.in, configure: Regenerate.
7001
7002 2015-02-26 Pedro Alves <palves@redhat.com>
7003
7004 * linux-low.c (linux_wait_1): When incrementing the PC past a
7005 program breakpoint always use the_low_target.breakpoint_len as
7006 increment, rather than the maximum between that and
7007 the_low_target.decr_pc_after_break.
7008
7009 2015-02-23 Pedro Alves <palves@redhat.com>
7010
7011 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
7012 thread was doing a step-over; always adjust the PC if
7013 we stepped over a permanent breakpoint.
7014 (linux_wait_1): If we stepped over breakpoint that was on top of a
7015 permanent breakpoint, manually advance the PC past it.
7016
7017 2015-02-23 Pedro Alves <palves@redhat.com>
7018
7019 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
7020 modes.
7021 (x86_fill_gregset, x86_store_gregset): Use it when handling
7022 $orig_eax.
7023
7024 2015-02-20 Pedro Alves <palves@redhat.com>
7025
7026 * thread-db.c: Include "nat/linux-procfs.h".
7027 (thread_db_init): Skip listing new threads if the kernel supports
7028 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
7029
7030 2015-02-20 Pedro Alves <palves@redhat.com>
7031
7032 * linux-low.c (status_pending_p_callback): Use ptid_match.
7033
7034 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
7035
7036 PR breakpoints/16812
7037 * linux-low.c (wstatus_maybe_breakpoint): Remove.
7038 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
7039 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
7040
7041 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
7042
7043 PR breakpoints/15956
7044 * tracepoint.c (cmd_qtinit): Add check for current_thread.
7045
7046 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7047
7048 * linux-low.c (linux_low_btrace_conf): Print size.
7049 * server.c (handle_btrace_conf_general_set): New.
7050 (hanle_general_set): Call handle_btrace_conf_general_set.
7051 (handle_query): Report Qbtrace-conf:bts:size as supported.
7052
7053 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7054
7055 * linux-low.c (linux_low_enable_btrace): Update parameters.
7056 (linux_low_btrace_conf): New.
7057 (linux_target_ops)<to_btrace_conf>: Initialize.
7058 * server.c (current_btrace_conf): New.
7059 (handle_btrace_enable): Rename to ...
7060 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
7061 to target_enable_btrace. Update comment. Update users.
7062 (handle_qxfer_btrace_conf): New.
7063 (qxfer_packets): Add btrace-conf entry.
7064 (handle_query): Report qXfer:btrace-conf:read as supported packet.
7065 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
7066 (target_ops)<read_btrace_conf>: New.
7067 (target_enable_btrace): Update parameters.
7068 (target_read_btrace_conf): New.
7069
7070 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7071
7072 * server.c (handle_btrace_general_set): Remove call to
7073 target_supports_btrace.
7074 (supported_btrace_packets): New.
7075 (handle_query): Call supported_btrace_packets.
7076 * target.h: include btrace-common.h.
7077 (btrace_target_info): Removed.
7078 (supports_btrace, target_supports_btrace): Update parameters.
7079
7080 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7081
7082 * Makefile.in (SFILES): Add common/btrace-common.c.
7083 (OBS): Add common/btrace-common.o.
7084 (btrace-common.o): Add build rules.
7085 * linux-low: Include btrace-common.h.
7086 (linux_low_read_btrace): Use struct btrace_data. Call
7087 btrace_data_init and btrace_data_fini.
7088
7089 2015-02-06 Pedro Alves <palves@redhat.com>
7090
7091 * thread-db.c (find_new_threads_callback): Add debug output.
7092
7093 2015-02-04 Pedro Alves <palves@redhat.com>
7094
7095 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
7096 (resume_stopped_resumed_lwps): New function.
7097 (linux_wait_for_event_filtered): Use it.
7098
7099 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
7100
7101 * Makefile.in (SFILES): Add linux-personality.c.
7102 (linux-personality.o): New rule.
7103 * configure.srv (srv_linux_obj): Add linux-personality.o to the
7104 list of objects to be built.
7105 * linux-low.c: Include nat/linux-personality.h.
7106 (linux_create_inferior): Remove code to disable address space
7107 randomization (moved to ../nat/linux-personality.c). Create
7108 cleanup to disable address space randomization.
7109
7110 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
7111
7112 * Makefile.in (posix-strerror.o): New rule.
7113 (mingw-strerror.o): Likewise.
7114 * configure: Regenerated.
7115 * configure.ac: Source file ../common/common.host. Initialize new
7116 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
7117
7118 2015-01-14 Yao Qi <yao@codesourcery.com>
7119
7120 * Makefile.in (SFILES): Add nat/ppc-linux.c.
7121 (ppc-linux.o): New rule.
7122 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
7123 * configure.ac: AC_CHECK_FUNCS(getauxval).
7124 * config.in: Re-generated.
7125 * configure: Re-generated.
7126 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
7127 ppc64_64bit_inferior_p
7128
7129 2015-01-14 Yao Qi <yao@codesourcery.com>
7130
7131 * linux-ppc-low.c: Include "nat/ppc-linux.h".
7132 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
7133 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
7134 (PT_ORIG_R3, PT_TRAP): Likewise.
7135 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
7136 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
7137 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
7138
7139 2015-01-10 Joel Brobecker <brobecker@adacore.com>
7140
7141 * i387-fp.c (i387_cache_to_xsave): In look over
7142 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
7143 zmmh_low_space field by use of zmmh_high_space.
7144
7145 2015-01-09 Pedro Alves <palves@redhat.com>
7146
7147 * linux-low.c (step_over_bkpt): Move higher up in the file.
7148 (handle_extended_wait): Don't store the stop_pc here.
7149 (get_stop_pc): Adjust comments and rename to ...
7150 (check_stopped_by_breakpoint): ... this. Record whether the LWP
7151 stopped for a software breakpoint or hardware breakpoint.
7152 (thread_still_has_status_pending_p): New function.
7153 (status_pending_p_callback): Use
7154 thread_still_has_status_pending_p. If the event is no longer
7155 interesting, resume the LWP.
7156 (handle_tracepoints): Add assert.
7157 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
7158 (wstatus_maybe_breakpoint): New function.
7159 (cancel_breakpoint): Delete function.
7160 (check_stopped_by_watchpoint): New function, factored out from
7161 linux_low_filter_event.
7162 (lp_status_maybe_breakpoint): Delete function.
7163 (linux_low_filter_event): Remove filter_ptid argument.
7164 Leave thread group exits pending here. Store the LWP's stop PC.
7165 Always leave events pending.
7166 (linux_wait_for_event_filtered): Pull all events out of the
7167 kernel, and leave them all pending.
7168 (count_events_callback, select_event_lwp_callback): Consider all
7169 events.
7170 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
7171 (select_event_lwp): Only give preference to the stepping LWP in
7172 all-stop mode. Adjust comments.
7173 (ignore_event): New function.
7174 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
7175 references to cancel_breakpoints. Adjust to renames. Also give
7176 equal priority to all LWPs that have had events in non-stop mode.
7177 If reporting a software breakpoint event, unadjust the LWP's PC.
7178 (linux_wait): If linux_wait_1 returned an ignored event, retry.
7179 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
7180 Adjust.
7181 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
7182 (resume_status_pending_p): Use thread_still_has_status_pending_p.
7183 (linux_stopped_by_watchpoint): Adjust.
7184 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
7185 * linux-low.h (enum lwp_stop_reason): New.
7186 (struct lwp_info) <stop_pc>: Adjust comment.
7187 <stopped_by_watchpoint>: Delete field.
7188 <stop_reason>: New field.
7189 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
7190 * mem-break.c (software_breakpoint_inserted_here)
7191 (hardware_breakpoint_inserted_here): New function.
7192 * mem-break.h (software_breakpoint_inserted_here)
7193 (hardware_breakpoint_inserted_here): Declare.
7194 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
7195 (cancel_breakpoints): Delete.
7196 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
7197 (upload_fast_traceframes): Remove references to
7198 cancel_breakpoints.
7199
7200 2015-01-09 Pedro Alves <palves@redhat.com>
7201
7202 * thread-db.c (find_new_threads_callback): Ignore thread if the
7203 kernel thread ID is -1.
7204
7205 2015-01-09 Pedro Alves <palves@redhat.com>
7206
7207 * linux-low.c (linux_attach_fail_reason_string): Move to
7208 nat/linux-ptrace.c, and rename.
7209 (linux_attach_lwp): Update comment.
7210 (attach_proc_task_lwp_callback): New function.
7211 (linux_attach): Adjust to rename and use
7212 linux_proc_attach_tgid_threads.
7213 (linux_attach_fail_reason_string): Delete declaration.
7214
7215 2015-01-01 Joel Brobecker <brobecker@adacore.com>
7216
7217 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
7218 * server.c (gdbserver_version): Likewise.
7219
7220 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
7221
7222 * remote-utils.c: Include ctype.h.
7223 (input_interrupt): Explicitly handle the case when the char
7224 received is the NUL byte. Improve the printing of non-ASCII
7225 characters.
7226
7227 2014-12-16 Joel Brobecker <brobecker@adacore.com>
7228
7229 * linux-low.c (linux_low_filter_event): Update call to
7230 linux_enable_event_reporting following the addition of
7231 a new parameter to that function.
7232
7233 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
7234
7235 PR server/17457
7236 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
7237 (AARCH64_FPCR_REGNO): Likewise.
7238 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
7239 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
7240 (aarch64_store_fpregset): Likewise.
7241
7242 2014-12-15 Joel Brobecker <brobecker@adacore.com>
7243
7244 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
7245 Remove FIXME comment about assumption about N.
7246
7247 2014-12-13 Joel Brobecker <brobecker@adacore.com>
7248
7249 * configure.ac: If large-file support is disabled in GDBserver,
7250 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
7251 * configure: Regenerate.
7252
7253 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7254
7255 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
7256 warning upon ENODATA from ptrace.
7257 * linux-s390-low.c (s390_store_tdb): New.
7258 (s390_regsets): Add regset for NT_S390_TDB.
7259
7260 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7261
7262 * linux-low.c (regsets_store_inferior_registers): Skip regsets
7263 without a fill_function.
7264 * linux-s390-low.c (s390_fill_last_break): Remove.
7265 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
7266 (s390_arch_setup): Use regset's size instead of fill_function for
7267 loop end condition.
7268
7269 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7270
7271 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
7272 the regset's store function when ptrace returned an error.
7273 * regcache.c (get_thread_regcache): Invalidate register cache
7274 before fetching inferior's registers.
7275
7276 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7277
7278 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
7279 while-loop as for-loop.
7280 (regsets_store_inferior_registers): Likewise.
7281
7282 2014-11-28 Yao Qi <yao@codesourcery.com>
7283
7284 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
7285 * config.in, configure: Re-generate.
7286 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
7287 is defined.
7288
7289 2014-11-21 Yao Qi <yao@codesourcery.com>
7290
7291 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
7292 (AC_CHECK_HEADERS): Remove malloc.h.
7293 * configure: Re-generated.
7294 * config.in: Re-generated.
7295 * server.h: Don't include alloca.h and malloc.h.
7296 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
7297 Don't include malloc.h.
7298
7299 2014-11-17 Joel Brobecker <brobecker@adacore.com>
7300
7301 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
7302 corresponding ERRNO check in same block.
7303
7304 2014-11-12 Pedro Alves <palves@redhat.com>
7305
7306 * server.c (cont_thread): Update comment.
7307 (start_inferior, attach_inferior): No longer clear cont_thread.
7308 (handle_v_cont): No longer set cont_thread.
7309 (captured_main): Clear cont_thread each time a GDB connects.
7310
7311 2014-11-12 Pedro Alves <palves@redhat.com>
7312
7313 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
7314 thread, and don't resume all threads if the Hc thread has exited.
7315
7316 2014-11-12 Pedro Alves <palves@redhat.com>
7317
7318 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
7319 the process group instead of to a specific LWP.
7320
7321 2014-10-15 Pedro Alves <palves@redhat.com>
7322
7323 PR server/17487
7324 * win32-arm-low.c (arm_set_thread_context): Remove current_event
7325 parameter.
7326 (arm_set_thread_context): Delete.
7327 (the_low_target): Adjust.
7328 * win32-i386-low.c (debug_registers_changed)
7329 (debug_registers_used): Delete.
7330 (update_debug_registers_callback): New function.
7331 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
7332 needing to update their debug registers.
7333 (win32_get_current_dr): New function.
7334 (x86_dr_low_get_addr, x86_dr_low_get_control)
7335 (x86_dr_low_get_status): Fetch the debug register from the thread
7336 record's context.
7337 (i386_initial_stuff): Adjust.
7338 (i386_get_thread_context): Remove current_event parameter. Don't
7339 clear debug_registers_changed nor copy DR values to
7340 debug_reg_state.
7341 (i386_set_thread_context): Delete.
7342 (i386_prepare_to_resume): New function.
7343 (i386_thread_added): Mark the thread as needing to update irs
7344 debug registers.
7345 (the_low_target): Remove i386_set_thread_context and install
7346 i386_prepare_to_resume.
7347 * win32-low.c (win32_get_thread_context): Adjust.
7348 (win32_set_thread_context): Use SetThreadContext
7349 directly.
7350 (win32_prepare_to_resume): New function.
7351 (win32_require_context): New function, factored out from ...
7352 (thread_rec): ... this.
7353 (continue_one_thread): Call win32_prepare_to_resume on each thread
7354 we're about to continue.
7355 (win32_resume): Call win32_prepare_to_resume on the event thread.
7356 * win32-low.h (struct win32_thread_info)
7357 <debug_registers_changed>: New field.
7358 (struct win32_target_ops): Change prototype of set_thread_context,
7359 delete set_thread_context and add prepare_to_resume.
7360 (win32_require_context): New declaration.
7361
7362 2014-10-08 Gary Benson <gbenson@redhat.com>
7363
7364 * server.h: Do not include common-exceptions.h.
7365
7366 2014-10-08 Gary Benson <gbenson@redhat.com>
7367
7368 * server.h: Do not include cleanups.h.
7369
7370 2014-09-30 James Hogan <james.hogan@imgtec.com>
7371
7372 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
7373 mips64-dsp-linux.c.
7374
7375 2014-09-23 Yao Qi <yao@codesourcery.com>
7376
7377 * linux-low.c (lp_status_maybe_breakpoint): New function.
7378 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
7379 (count_events_callback): Likewise.
7380 (select_event_lwp_callback): Likewise.
7381 (cancel_breakpoints_callback): Likewise.
7382
7383 2014-09-19 Don Breazeal <donb@codesourcery.com>
7384
7385 * linux-low.c (handle_extended_wait): Call
7386 linux_ptrace_get_extended_event.
7387 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
7388 linux_is_extended_waitstatus.
7389
7390 2014-09-16 Joel Brobecker <brobecker@adacore.com>
7391
7392 * Makefile.in (CPPFLAGS): Define.
7393 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
7394 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
7395
7396 2014-09-16 Gary Benson <gbenson@redhat.com>
7397
7398 * inferiors.h (current_inferior): Renamed as...
7399 (current_thread): New variable. All uses updated.
7400 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
7401 (maybe_move_out_of_jump_pad): Likewise.
7402 (cancel_breakpoint): Likewise.
7403 (linux_low_filter_event): Likewise.
7404 (wait_for_sigstop): Likewise.
7405 (linux_resume_one_lwp): Likewise.
7406 (need_step_over_p): Likewise.
7407 (start_step_over): Likewise.
7408 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
7409 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
7410 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
7411 and save_inferior as saved_thread.
7412 * regcache.c (get_thread_regcache): Renamed saved_inferior as
7413 saved_thread.
7414 (regcache_invalidate_thread): Likewise.
7415 * remote-utils.c (prepare_resume_reply): Likewise.
7416 * thread-db.c (thread_db_get_tls_address): Likewise.
7417 (disable_thread_event_reporting): Likewise.
7418 (remove_thread_event_breakpoints): Likewise.
7419 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
7420 as saved_thread.
7421 * target.h (set_desired_inferior): Renamed as...
7422 (set_desired_thread): New declaration. All uses updated.
7423 * server.c (myresume): Updated comment to reference thread instead
7424 of inferior.
7425 (handle_serial_event): Likewise.
7426 (handle_target_event): Likewise.
7427
7428 2014-09-12 Tom Tromey <tromey@redhat.com>
7429 Gary Benson <gbenson@redhat.com>
7430
7431 * regcache.h: Include common-regcache.h.
7432 (regcache_read_pc): Don't declare.
7433 * regcache.c (get_thread_regcache_for_ptid): New function.
7434
7435 2014-09-11 Tom Tromey <tromey@redhat.com>
7436 Gary Benson <gbenson@redhat.com>
7437
7438 * symbol.c: New file.
7439 * Makefile.in (SFILES): Add symbol.c.
7440 (OBS): Add symbol.o.
7441
7442 2014-09-11 Gary Benson <gbenson@redhat.com>
7443
7444 * target.c (target_stop_ptid, target_continue_ptid): New
7445 functions.
7446
7447 2014-09-11 Tom Tromey <tromey@redhat.com>
7448 Gary Benson <gbenson@redhat.com>
7449
7450 * target.h: Include target/target.h.
7451 * target.c (target_read_memory, target_read_uint32)
7452 (target_write_memory): New functions.
7453
7454 2014-09-11 Gary Benson <gbenson@redhat.com>
7455
7456 * server.h (debug_hw_points): Don't declare.
7457 * server.c (debug_hw_points): Don't define. Replace all uses
7458 with show_debug_regs.
7459 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
7460 all uses with show_debug_regs.
7461
7462 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
7463
7464 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
7465 endianness into account.
7466 (ppc_supply_ptrace_register): Likewise.
7467
7468 2014-09-03 James Hogan <james.hogan@imgtec.com>
7469
7470 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
7471 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
7472
7473 2014-09-03 Gary Benson <gbenson@redhat.com>
7474
7475 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
7476 ALL_DEBUG_ADDRESS_REGISTERS.
7477
7478 2014-09-02 Gary Benson <gbenson@redhat.com>
7479
7480 * i386-low.h: Renamed as...
7481 * x86-low.h: New file. All type, function and variable name
7482 prefixes changed from "i386_" to "x86_". All references updated.
7483 * i386-low.c: Renamed as...
7484 * x86-low.c: New file. All type, function and variable name
7485 prefixes changed from "i386_" to "x86_". All references updated.
7486
7487 2014-09-02 Gary Benson <gbenson@redhat.com>
7488
7489 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
7490 (x86_linux_new_thread): Likewise.
7491
7492 2014-08-29 Gary Benson <gbenson@redhat.com>
7493
7494 * server.h (setjmp.h): Do not include.
7495 (toplevel): Do not declare.
7496 (common-exceptions.h): Include.
7497 (cleanups.h): Likewise.
7498 * server.c (toplevel): Do not define.
7499 (exit_code): New static global.
7500 (detach_or_kill_for_exit_cleanup): New function.
7501 (main): New function. Original main renamed to...
7502 (captured_main): New function.
7503 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
7504
7505 2014-08-29 Gary Benson <gbenson@redhat.com>
7506
7507 * Makefile.in (SFILES): Add common/common-exceptions.c.
7508 (OBS): Add common-exceptions.o.
7509 (common-exceptions.o): New rule.
7510 * utils.c (prepare_to_throw_exception): New function.
7511
7512 2014-08-29 Gary Benson <gbenson@redhat.com>
7513
7514 * config.in: Regenerate.
7515 * configure: Likewise.
7516
7517 2014-08-29 Gary Benson <gbenson@redhat.com>
7518
7519 * Makefile.in (SFILES): Add common/cleanups.c.
7520 (OBS): cleanups.o.
7521 (cleanups.o): New rule.
7522
7523 2014-08-29 Gary Benson <gbenson@redhat.com>
7524
7525 * utils.c (internal_vwarning): New function.
7526
7527 2014-08-28 Gary Benson <gbenson@redhat.com>
7528
7529 * utils.h (fatal): Remove declaration.
7530 * utils.c (fatal): Remove function.
7531
7532 2014-08-28 Gary Benson <gbenson@redhat.com>
7533
7534 * tracepoint.c (gdb_agent_init): Replace fatal with
7535 perror_with_name.
7536 (initialize_tracepoint): Likewise.
7537
7538 2014-08-28 Gary Benson <gbenson@redhat.com>
7539
7540 * remote-utils.c (remote_prepare): Replace fatal with error.
7541
7542 2014-08-28 Gary Benson <gbenson@redhat.com>
7543
7544 * linux-low.c (linux_async): Replace fatal with warning.
7545 Tidy up and return.
7546 (linux_start_non_stop): Return -1 if linux_async failed.
7547
7548 2014-08-28 Gary Benson <gbenson@redhat.com>
7549
7550 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
7551 gdb_assert.
7552 (i386_dr_low_get_addr): Remove vague comment.
7553 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
7554 gdb_assert.
7555
7556 2014-08-28 Gary Benson <gbenson@redhat.com>
7557
7558 * inferiors.c (get_thread_process): Replace check with gdb_assert.
7559 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
7560 internal_error.
7561 (linux_resume_one_lwp): Likewise.
7562 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
7563 gdb_assert.
7564 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
7565 with internal_error.
7566 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
7567 (init_register_cache): Replace fatal with gdb_assert_not_reached.
7568 (find_register_by_name): Replace fatal with internal_error.
7569 (find_regno): Likewise.
7570 * tdesc.c (init_target_desc): Replace check with gdb_assert.
7571 * thread-db.c (thread_db_create_event): Likewise.
7572 (thread_db_load_search): Likewise.
7573 (try_thread_db_load_1): Likewise.
7574 * tracepoint.c (get_jump_space_head): Replace fatal with
7575 internal_error.
7576 (claim_trampoline_space): Likewise.
7577 (have_fast_tracepoint_trampoline_buffer): Likewise.
7578 (cmd_qtstart): Likewise.
7579 (stop_tracing): Likewise.
7580 (fast_tracepoint_collecting): Likewise.
7581 (target_malloc): Likewise.
7582 (download_tracepoint): Likewise.
7583 (download_trace_state_variables): Replace check with gdb_assert.
7584 (upload_fast_traceframes): Replace fatal with internal_error.
7585
7586 2014-08-19 Tom Tromey <tromey@redhat.com>
7587 Gary Benson <gbenson@redhat.com>
7588
7589 * Makefile.in (SFILES): Add common/common-debug.c.
7590 (OBS): Add common-debug.o.
7591 (common-debug.o): New rule.
7592 * debug.h (debug_printf): Don't declare.
7593 * debug.c (debug_printf): Renamed and rewritten as...
7594 (debug_vprintf): New function.
7595
7596 2014-08-19 Gary Benson <gbenson@redhat.com>
7597
7598 * utils.h: Do not include print-utils.h.
7599
7600 2014-08-19 Tom Tromey <tromey@redhat.com>
7601 Gary Benson <gbenson@redhat.com>
7602
7603 * server.h: Add static assertion.
7604 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
7605
7606 2014-08-19 Tom Tromey <tromey@redhat.com>
7607 Gary Benson <gbenson@redhat.com>
7608
7609 * Makefile.in (SFILES): Add common/errors.c.
7610 (OBS): Add errors.o.
7611 (IPA_OBS): Add errors-ipa.o.
7612 (errors.o): New rule.
7613 (errors-ipa.o): Likewise.
7614 * utils.h (perror_with_name, error, warning): Don't declare.
7615 * utils.c (warning): Renamed and rewritten as...
7616 (vwarning): New function.
7617 (error): Renamed and rewritten as...
7618 (verror): New function.
7619 (internal_error): Renamed and rewritten as...
7620 (internal_verror): New function.
7621
7622 2014-08-07 Gary Benson <gbenson@redhat.com>
7623
7624 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
7625 * configure: Regenerate.
7626 * config.in: Likewise.
7627 * server.h: Do not include errno.h.
7628 * event-loop.c: Likewise.
7629 * hostio-errno.c: Likewise.
7630 * linux-low.c: Likewise.
7631 * remote-utils.c: Likewise.
7632 * spu-low.c: Likewise.
7633 * utils.c: Likewise.
7634 * gdbreplay.c: Unconditionally include errno.h.
7635
7636 2014-08-07 Gary Benson <gbenson@redhat.com>
7637
7638 * server.h: Do not include string.h.
7639 * event-loop.c: Likewise.
7640 * linux-low.c: Likewise.
7641 * regcache.c: Likewise.
7642 * remote-utils.c: Likewise.
7643 * spu-low.c: Likewise.
7644 * utils.c: Likewise.
7645
7646 2014-08-07 Gary Benson <gbenson@redhat.com>
7647
7648 * server.h: Do not include gdb_assert.h.
7649
7650 2014-08-07 Gary Benson <gbenson@redhat.com>
7651
7652 * server.h: Do not include common-utils.h.
7653
7654 2014-08-07 Gary Benson <gbenson@redhat.com>
7655
7656 * server.h: Do not include ptid.h.
7657 * notif.h: Likewise.
7658
7659 2014-08-07 Gary Benson <gbenson@redhat.com>
7660
7661 * server.h: Do not include gdb_locale.h.
7662
7663 2014-08-07 Gary Benson <gbenson@redhat.com>
7664
7665 * server.h: Do not include gdb/signals.h.
7666 * win32-low.c: Likewise.
7667
7668 2014-08-07 Gary Benson <gbenson@redhat.com>
7669
7670 * server.h: Do not include pathmax.h.
7671
7672 2014-08-07 Gary Benson <gbenson@redhat.com>
7673
7674 * server.h: Do not include libiberty.h.
7675 * linux-bfin-low.c: Likewise.
7676
7677 2014-08-07 Gary Benson <gbenson@redhat.com>
7678
7679 * server.h: Do not include ansidecl.h.
7680
7681 2014-08-07 Gary Benson <gbenson@redhat.com>
7682
7683 * linux-x86-low.c: Do not include stddef.h.
7684 * lynx-ppc-low.c: Likewise.
7685 * tracepoint.c: Likewise.
7686
7687 2014-08-07 Gary Benson <gbenson@redhat.com>
7688
7689 * server.h: Do not include stdarg.h.
7690 * nto-low.c: Likewise.
7691
7692 2014-08-07 Gary Benson <gbenson@redhat.com>
7693
7694 * server.h: Do not include stdlib.h.
7695 * inferiors.c: Likewise.
7696 * linux-low.c: Likewise.
7697 * regcache.c: Likewise.
7698 * spu-low.c: Likewise.
7699 * tracepoint.c: Likewise.
7700 * utils.c: Likewise.
7701
7702 2014-08-07 Gary Benson <gbenson@redhat.com>
7703
7704 * server.h: Do not include stdio.h.
7705 * linux-low.c: Likewise.
7706 * remote-utils.c: Likewise.
7707 * spu-low.c: Likewise.
7708 * utils.c: Likewise.
7709 * wincecompat.c: Likewise.
7710
7711 2014-08-06 Gary Benson <gbenson@redhat.com>
7712
7713 * regcache.c (init_register_cache): Move conditionals inside if.
7714
7715 2014-08-06 Gary Benson <gbenson@redhat.com>
7716
7717 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
7718
7719 2014-07-31 Gary Benson <gbenson@redhat.com>
7720
7721 * ax.h: Do not include server.h.
7722 * gdbthread.h: Likewise.
7723 * lynx-low.h: Likewise.
7724 * notif.h: Likewise.
7725
7726 2014-07-30 Gary Benson <gbenson@redhat.com>
7727
7728 * server.h: Include common-defs.h.
7729 Do not include config.h or build-gnulib-gdbserver/config.h.
7730
7731 2014-07-30 Gary Benson <gbenson@redhat.com>
7732
7733 * hostio-errno.c: Move server.h to top of includes list.
7734 * inferiors.c: Likewise.
7735 * linux-x86-low.c: Likewise.
7736 * notif.c: Include server.h.
7737
7738 2014-07-24 Tom Tromey <tromey@redhat.com>
7739 Gary Benson <gbenson@redhat.com>
7740
7741 * server.h (CORE_ADDR): Now unsigned.
7742
7743 2014-07-16 Pedro Alves <palves@redhat.com>
7744
7745 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
7746
7747 2014-07-15 Pedro Alves <palves@redhat.com>
7748
7749 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
7750 copy.
7751
7752 2014-07-11 Pedro Alves <palves@redhat.com>
7753
7754 * linux-low.c (kill_wait_lwp): New function, based on
7755 kill_one_lwp_callback, but use my_waitpid directly.
7756 (kill_one_lwp_callback, linux_kill): Use it.
7757
7758 2014-06-23 Pedro Alves <palves@redhat.com>
7759
7760 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
7761 before setting DR0..DR3.
7762
7763 2014-06-20 Gary Benson <gbenson@redhat.com>
7764
7765 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
7766 * configure: Regenerated.
7767 * config.in: Likewise.
7768
7769 2014-06-20 Gary Benson <gbenson@redhat.com>
7770
7771 * Makefile.in (SFILES): Update locations for files moved
7772 from common to nat.
7773 (object file files): Reordered.
7774
7775 2014-06-20 Gary Benson <gbenson@redhat.com>
7776
7777 * i386-low.h (i386_dr_low_can_set_addr): Removed.
7778 (i386_dr_low_set_addr): Likewise.
7779 (i386_dr_low_get_addr): Likewise.
7780 (i386_dr_low_can_set_control): Likewise.
7781 (i386_dr_low_set_control): Likewise.
7782 (i386_dr_low_get_control): Likewise.
7783 (i386_dr_low_get_status): Likewise.
7784 (i386_get_debug_register_length): Likewise.
7785 * linux-x86-low.c (i386_dr_low_set_addr):
7786 Changed signature. Made static.
7787 (i386_dr_low_get_addr): Likewise.
7788 (i386_dr_low_set_control): Likewise.
7789 (i386_dr_low_get_control): Likewise.
7790 (i386_dr_low_get_status): Likewise.
7791 (i386_dr_low): New global variable.
7792 * win32-i386-low.c (i386_dr_low_set_addr):
7793 Changed signature. Made static.
7794 (i386_dr_low_get_addr): Likewise.
7795 (i386_dr_low_set_control): Likewise.
7796 (i386_dr_low_get_control): Likewise.
7797 (i386_dr_low_get_status): Likewise.
7798 (i386_dr_low): New global variable.
7799
7800 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
7801
7802 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
7803 * Makefile.in (AR, AR_FLAGS): Define.
7804 * configure: Regenerate.
7805
7806 2014-06-19 Gary Benson <gbenson@redhat.com>
7807
7808 * Makefile.in (i386-dregs.o): New rule.
7809 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
7810 * i386-low.c (target.h): Remove include.
7811 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
7812 (DR_CONTROL_SHIFT): Likewise.
7813 (DR_CONTROL_SIZE): Likewise.
7814 (DR_RW_EXECUTE): Likewise.
7815 (DR_RW_WRITE): Likewise.
7816 (DR_RW_READ): Likewise.
7817 (DR_RW_IORW): Likewise.
7818 (DR_LEN_1): Likewise.
7819 (DR_LEN_2): Likewise.
7820 (DR_LEN_4): Likewise.
7821 (DR_LEN_8): Likewise.
7822 (DR_LOCAL_ENABLE_SHIFT): Likewise.
7823 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
7824 (DR_ENABLE_SIZE): Likewise.
7825 (DR_LOCAL_SLOWDOWN): Likewise.
7826 (DR_GLOBAL_SLOWDOWN): Likewise.
7827 (DR_CONTROL_RESERVED): Likewise.
7828 (I386_DR_CONTROL_MASK): Likewise.
7829 (I386_DR_VACANT): Likewise.
7830 (I386_DR_LOCAL_ENABLE): Likewise.
7831 (I386_DR_GLOBAL_ENABLE): Likewise.
7832 (I386_DR_DISABLE): Likewise.
7833 (I386_DR_SET_RW_LEN): Likewise.
7834 (I386_DR_GET_RW_LEN): Likewise.
7835 (I386_DR_WATCH_HIT): Likewise.
7836 (i386_wp_op_t): Likewise.
7837 (i386_show_dr): Likewise.
7838 (i386_length_and_rw_bits): Likewise.
7839 (i386_insert_aligned_watchpoint): Likewise.
7840 (i386_remove_aligned_watchpoint): Likewise.
7841 (i386_handle_nonaligned_watchpoint): Likewise.
7842 i386_update_inferior_debug_regs(): Likewise.
7843 (i386_dr_insert_watchpoint): Likewise.
7844 (i386_dr_remove_watchpoint): Likewise.
7845 (i386_dr_region_ok_for_watchpoint): Likewise.
7846 (i386_dr_stopped_data_address): Likewise.
7847 (i386_dr_stopped_by_watchpoint): Likewise.
7848
7849 2014-06-19 Gary Benson <gbenson@redhat.com>
7850
7851 * i386-low.c (i386_dr_show): Renamed to
7852 i386_show_dr and made static. All uses updated.
7853 (i386_dr_length_and_rw_bits): Renamed to
7854 i386_length_and_rw_bits and made static.
7855 All uses updated.
7856 (i386_dr_insert_aligned_watchpoint): Renamed to
7857 i386_insert_aligned_watchpoint and made static.
7858 All uses updated.
7859 (i386_dr_remove_aligned_watchpoint): Renamed to
7860 i386_remove_aligned_watchpoint and made static.
7861 All uses updated.
7862 (i386_dr_update_inferior_debug_regs): Renamed to
7863 i386_update_inferior_debug_regs and made static.
7864 All uses updated.
7865
7866 2014-06-18 Gary Benson <gbenson@redhat.com>
7867
7868 * i386-low.h (i386_dr_low_can_set_addr): New macro.
7869 (i386_dr_low_can_set_control): Likewise.
7870 (i386_get_debug_register_length): Likewise.
7871 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
7872 (i386_dr_low_can_set_control): Likewise.
7873 (i386_get_debug_register_length): Likewise.
7874
7875 2014-06-17 Gary Benson <gbenson@redhat.com>
7876
7877 * i386-low.h (i386-dregs.h): New include.
7878 (DR_FIRSTADDR): Now in i386-dregs.h.
7879 (DR_LASTADDR): Likewise.
7880 (DR_NADDR): Likewise.
7881 (DR_STATUS): Likewise.
7882 (DR_CONTROL): Likewise.
7883 (i386_debug_reg_state): Likewise.
7884 (i386_dr_insert_watchpoint): Likewise.
7885 (i386_dr_remove_watchpoint): Likewise.
7886 (i386_dr_region_ok_for_watchpoint): Likewise.
7887 (i386_dr_stopped_data_address): Likewise.
7888 (i386_dr_stopped_by_watchpoint): Likewise.
7889 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
7890
7891 2014-06-18 Gary Benson <gbenson@redhat.com>
7892
7893 * i386-low.h (i386_low_insert_watchpoint): Renamed to
7894 i386_dr_insert_watchpoint.
7895 (i386_low_remove_watchpoint): Renamed to
7896 i386_dr_remove_watchpoint.
7897 (i386_low_region_ok_for_watchpoint): Renamed to
7898 i386_dr_region_ok_for_watchpoint.
7899 (i386_low_stopped_data_address): Renamed to
7900 i386_dr_stopped_data_address.
7901 (i386_low_stopped_by_watchpoint): Renamed to
7902 i386_dr_stopped_by_watchpoint.
7903 * i386-low.c (i386_show_dr): Renamed to
7904 i386_dr_show and made nonstatic. All uses updated.
7905 (i386_length_and_rw_bits): Renamed to
7906 i386_dr_length_and_rw_bits and made nonstatic.
7907 All uses updated.
7908 (i386_insert_aligned_watchpoint): Renamed to
7909 i386_dr_insert_aligned_watchpoint and made nonstatic.
7910 All uses updated.
7911 (i386_remove_aligned_watchpoint): Renamed to
7912 i386_dr_remove_aligned_watchpoint and made nonstatic.
7913 All uses updated.
7914 (i386_update_inferior_debug_regs): Renamed to
7915 i386_dr_update_inferior_debug_regs and made nonstatic.
7916 All uses updated.
7917 (i386_low_insert_watchpoint): Renamed to
7918 i386_dr_insert_watchpoint. All uses updated.
7919 (i386_low_remove_watchpoint): Renamed to
7920 i386_dr_remove_watchpoint. All uses updated.
7921 (i386_low_region_ok_for_watchpoint): Renamed to
7922 i386_dr_region_ok_for_watchpoint. All uses updated.
7923 (i386_low_stopped_data_address): Renamed to
7924 i386_dr_stopped_data_address. All uses updated.
7925 (i386_low_stopped_by_watchpoint): Renamed to
7926 i386_dr_stopped_by_watchpoint. All uses updated.
7927
7928 2014-06-18 Gary Benson <gbenson@redhat.com>
7929
7930 * i386-low.c (i386_dr_low_can_set_addr): New macro.
7931 (i386_dr_low_can_set_control): Likewise.
7932 (i386_insert_aligned_watchpoint): New check.
7933
7934 2014-06-18 Gary Benson <gbenson@redhat.com>
7935
7936 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
7937 Renamed to state.
7938
7939 2014-06-18 Gary Benson <gbenson@redhat.com>
7940
7941 * i386-low.c (i386_length_and_rw_bits): Use internal_error
7942 instead of fatal and error.
7943 (i386_handle_nonaligned_watchpoint): Likewise.
7944
7945 2014-06-18 Gary Benson <gbenson@redhat.com>
7946
7947 * i386-low.c (i386_get_debug_register_length): New macro.
7948 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
7949 (i386_show_dr): Use debug_printf instead of fprintf. Use
7950 phex to format values.
7951
7952 2014-06-18 Gary Benson <gbenson@redhat.com>
7953
7954 * i386-low.h: Comment changes.
7955 * i386-low.c: Likewise.
7956
7957 2014-06-18 Gary Benson <gbenson@redhat.com>
7958
7959 * i386-low.c: Whitespace changes.
7960
7961 2014-06-12 Tom Tromey <tromey@redhat.com>
7962
7963 * utils.c (freeargv): Remove.
7964
7965 2014-06-12 Tom Tromey <tromey@redhat.com>
7966
7967 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
7968 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
7969 (parse_debug_format_options): Likewise.
7970 (gdbserver_usage): Likewise.
7971 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
7972 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
7973 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
7974 against libiberty.
7975 ($(LIBGNU)): Depend on libiberty.
7976 (all-lib): Recurse into all subdirs.
7977 (install-only): Invoke "install" target in subdirs.
7978 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
7979 targets.
7980 * configure: Rebuild.
7981 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
7982 for vasprintf, vsnprintf, or gettimeofday.
7983 * configure.srv: Don't add safe-ctype.o or lbasename.o to
7984 srv_tgtobj.
7985
7986 2014-06-05 Joel Brobecker <brobecker@adacore.com>
7987
7988 * development.sh: Delete.
7989 * Makefile.in (config.status): Adjust dependency on development.sh.
7990 * configure.ac: Adjust development.sh source call.
7991 * configure: Regenerate.
7992
7993 2014-06-02 Pedro Alves <palves@redhat.com>
7994
7995 * ax.c (gdb_free_agent_expr): New function.
7996 * ax.h (gdb_free_agent_expr): New declaration.
7997 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
7998 list.
7999 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
8000 static.
8001 (clear_breakpoint_conditions_and_commands): New function.
8002 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
8003 (clear_breakpoint_conditions_and_commands): New declaration.
8004
8005 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
8006
8007 * linux-aarch64-low.c (asm/ptrace.h): Include.
8008
8009 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
8010
8011 Fix TLS access for -static -pthread.
8012 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
8013 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
8014 (thread_db_load_search, try_thread_db_load_1): Initialize it.
8015
8016 2014-05-20 Pedro Alves <palves@redhat.com>
8017
8018 * linux-aarch64-low.c (aarch64_insert_point)
8019 (aarch64_remove_point): No longer check whether the type is
8020 supported here. Adjust to new interface.
8021 (the_low_target): Install aarch64_supports_z_point_type as
8022 supports_z_point_type method.
8023 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
8024 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
8025 instead of a Z packet char. Adjust.
8026 (arm_supports_z_point_type): New function.
8027 (arm_insert_point, arm_remove_point): Adjust to new interface.
8028 (the_low_target): Install arm_supports_z_point_type.
8029 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
8030 (cris_insert_point, cris_remove_point): Adjust to new interface.
8031 Don't check whether the type is supported here.
8032 (the_low_target): Install cris_supports_z_point_type.
8033 * linux-low.c (linux_supports_z_point_type): New function.
8034 (linux_insert_point, linux_remove_point): Adjust to new interface.
8035 * linux-low.h (struct linux_target_ops) <insert_point,
8036 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
8037 raw_breakpoint pointer parameter.
8038 <supports_z_point_type>: New method.
8039 * linux-mips-low.c (mips_supports_z_point_type): New function.
8040 (mips_insert_point, mips_remove_point): Adjust to new interface.
8041 Use mips_supports_z_point_type.
8042 (the_low_target): Install mips_supports_z_point_type.
8043 * linux-ppc-low.c (the_low_target): Install NULL as
8044 supports_z_point_type method.
8045 * linux-s390-low.c (the_low_target): Install NULL as
8046 supports_z_point_type method.
8047 * linux-sparc-low.c (the_low_target): Install NULL as
8048 supports_z_point_type method.
8049 * linux-x86-low.c (x86_supports_z_point_type): New function.
8050 (x86_insert_point): Adjust to new insert_point interface. Use
8051 insert_memory_breakpoint. Adjust to new
8052 i386_low_insert_watchpoint interface.
8053 (x86_remove_point): Adjust to remove_point interface. Use
8054 remove_memory_breakpoint. Adjust to new
8055 i386_low_remove_watchpoint interface.
8056 (the_low_target): Install x86_supports_z_point_type.
8057 * lynx-low.c (lynx_target_ops): Install NULL as
8058 supports_z_point_type callback.
8059 * nto-low.c (nto_supports_z_point_type): New.
8060 (nto_insert_point, nto_remove_point): Adjust to new interface.
8061 (nto_target_ops): Install nto_supports_z_point_type.
8062 * mem-break.c: Adjust intro comment.
8063 (struct raw_breakpoint) <raw_type, size>: New fields.
8064 <inserted>: Update comment.
8065 <shlib_disabled>: Delete field.
8066 (enum bkpt_type) <gdb_breakpoint>: Delete value.
8067 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
8068 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
8069 (raw_bkpt_type_to_target_hw_bp_type): New function.
8070 (find_enabled_raw_code_breakpoint_at): New function.
8071 (find_raw_breakpoint_at): New type and size parameters. Use them.
8072 (insert_memory_breakpoint): New function, based off
8073 set_raw_breakpoint_at.
8074 (remove_memory_breakpoint): New function.
8075 (set_raw_breakpoint_at): Reimplement.
8076 (set_breakpoint): New, based on set_breakpoint_at.
8077 (set_breakpoint_at): Reimplement.
8078 (delete_raw_breakpoint): Go through the_target->remove_point
8079 instead of assuming memory breakpoints.
8080 (find_gdb_breakpoint_at): Delete.
8081 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
8082 (find_gdb_breakpoint): New function.
8083 (set_gdb_breakpoint_at): Delete.
8084 (z_type_supported): New function.
8085 (set_gdb_breakpoint_1): New function, loosely based off
8086 set_gdb_breakpoint_at.
8087 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
8088 (delete_gdb_breakpoint_at): Delete.
8089 (delete_gdb_breakpoint_1): New function, loosely based off
8090 delete_gdb_breakpoint_at.
8091 (delete_gdb_breakpoint): New function.
8092 (clear_gdb_breakpoint_conditions): Rename to ...
8093 (clear_breakpoint_conditions): ... this. Don't handle a NULL
8094 breakpoint.
8095 (add_condition_to_breakpoint): Make static.
8096 (add_breakpoint_condition): Take a struct breakpoint pointer
8097 instead of an address. Adjust.
8098 (gdb_condition_true_at_breakpoint): Rename to ...
8099 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
8100 z_type parameter.
8101 (gdb_condition_true_at_breakpoint): Reimplement.
8102 (add_breakpoint_commands): Take a struct breakpoint pointer
8103 instead of an address. Adjust.
8104 (gdb_no_commands_at_breakpoint): Rename to ...
8105 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
8106 parameter. Return true if no breakpoint was found. Change debug
8107 output.
8108 (gdb_no_commands_at_breakpoint): Reimplement.
8109 (run_breakpoint_commands): Rename to ...
8110 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
8111 and change return type to boolean.
8112 (run_breakpoint_commands): New function.
8113 (gdb_breakpoint_here): Also check for Z1 breakpoints.
8114 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
8115 breakpoint. Go through the_target->remove_point instead of
8116 assuming memory breakpoint.
8117 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
8118 software and hardware breakpoints.
8119 (reinsert_raw_breakpoint): Go through the_target->insert_point
8120 instead of assuming memory breakpoint.
8121 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
8122 software and hardware breakpoints.
8123 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
8124 Check both software and hardware breakpoints.
8125 (validate_inserted_breakpoint): Assert the breakpoint is a
8126 software breakpoint. Set the inserted flag to -1 instead of
8127 setting shlib_disabled.
8128 (delete_disabled_breakpoints): Adjust.
8129 (validate_breakpoints): Only validate software breakpoints.
8130 Adjust to inserted flag change.
8131 (check_mem_read, check_mem_write): Skip breakpoint types other
8132 than software breakpoints. Adjust to inserted flag change.
8133 * mem-break.h (enum raw_bkpt_type): New enum.
8134 (raw_breakpoint, struct process_info): Forward declare.
8135 (Z_packet_to_target_hw_bp_type): Delete declaration.
8136 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
8137 (set_gdb_breakpoint, delete_gdb_breakpoint)
8138 (clear_breakpoint_conditions): New declarations.
8139 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
8140 (breakpoint_inserted_here): Update comment.
8141 (add_breakpoint_condition, add_breakpoint_commands): Replace
8142 address parameter with a breakpoint pointer parameter.
8143 (gdb_breakpoint_here): Update comment.
8144 (delete_gdb_breakpoint_at): Delete.
8145 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
8146 * server.c (process_point_options): Take a struct breakpoint
8147 pointer instead of an address. Adjust.
8148 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
8149 delete_gdb_breakpoint.
8150 * spu-low.c (spu_target_ops): Install NULL as
8151 supports_z_point_type method.
8152 * target.h: Include mem-break.h.
8153 (struct target_ops) <prepare_to_access_memory>: Update comment.
8154 <supports_z_point_type>: New field.
8155 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
8156 instead of a char. Also take a raw breakpoint pointer.
8157 * win32-arm-low.c (the_low_target): Install NULL as
8158 supports_z_point_type.
8159 * win32-i386-low.c (i386_supports_z_point_type): New function.
8160 (i386_insert_point, i386_remove_point): Adjust to new interface.
8161 (the_low_target): Install i386_supports_z_point_type.
8162 * win32-low.c (win32_supports_z_point_type): New function.
8163 (win32_insert_point, win32_remove_point): Adjust to new interface.
8164 (win32_target_ops): Install win32_supports_z_point_type.
8165 * win32-low.h (struct win32_target_ops):
8166 <supports_z_point_type>: New method.
8167 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
8168 instead of a char. Also take a raw breakpoint pointer.
8169
8170 2014-05-20 Pedro Alves <palves@redhat.com>
8171
8172 * mem-break.h: Include break-common.h.
8173 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
8174 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
8175 (Z_packet_to_target_hw_bp_type): New declaration.
8176 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
8177 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
8178 (Z_PACKET_ACCESS_WP): Delete macros.
8179 (Z_packet_to_hw_type): Delete function.
8180 * i386-low.h: Don't include break-common.h here.
8181 (Z_packet_to_hw_type): Delete declaration.
8182 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
8183 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
8184 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
8185 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
8186 * linux-aarch64-low.c: Don't include break-common.h here.
8187 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
8188 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
8189 (Z_packet_to_target_hw_bp_type): Delete function.
8190 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
8191 function.
8192 (mips_insert_point, mips_remove_point): Use
8193 Z_packet_to_target_hw_bp_type.
8194
8195 2014-05-20 Pedro Alves <palves@redhat.com>
8196
8197 * linux-aarch64-low.c: Include break-common.h.
8198 (enum target_point_type): Delete.
8199 (Z_packet_to_point_type): Rename to ...
8200 (Z_packet_to_target_hw_bp_type): ... this, and return a
8201 target_hw_bp_type instead.
8202 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
8203 instead of an enum target_point_type.
8204 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
8205 breakpoint type.
8206 (aarch64_dr_state_insert_one_point)
8207 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
8208 (aarch64_handle_aligned_watchpoint)
8209 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
8210 Take an enum target_hw_bp_type instead of an enum
8211 target_point_type.
8212 (aarch64_supports_z_point_type): New function.
8213 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
8214 use Z_packet_to_target_hw_bp_type.
8215
8216 2014-05-20 Joel Brobecker <brobecker@adacore.com>
8217
8218 * configure.ac: Only use -Werror by default when DEVELOPMENT
8219 is true.
8220 * configure: Regenerate.
8221
8222 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
8223
8224 Fix gdbserver qGetTLSAddr for x86_64 -m32.
8225 * linux-x86-low.c (X86_64_USER_REGS): New.
8226 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
8227
8228 2014-04-28 Yao Qi <yao@codesourcery.com>
8229
8230 * Makefile.in (i386-avx512.c): Fix the typo of generated file
8231 name.
8232
8233 2014-04-25 Pedro Alves <palves@redhat.com>
8234
8235 PR server/16255
8236 * linux-low.c (linux_attach_fail_reason_string): New function.
8237 (linux_attach_lwp): Delete.
8238 (linux_attach_lwp_1): Rename to ...
8239 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
8240 argument. Remove "initial" parameter. Return int instead of
8241 void. Don't error or warn here.
8242 (linux_attach): Adjust to call linux_attach_lwp. Call error on
8243 failure to attach to the tgid. Call warning when failing to
8244 attach to an lwp.
8245 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
8246 argument. Remove "initial" parameter. Return int instead of
8247 void. Don't error or warn here.
8248 (linux_attach_fail_reason_string): New declaration.
8249 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
8250 interface change. Use linux_attach_fail_reason_string.
8251
8252 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
8253 Walfred Tedeschi <walfred.tedeschi@intel.com>
8254
8255 * Makefile.in: Added rules to handle new files
8256 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
8257 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
8258 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
8259 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
8260 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
8261 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
8262 x32-avx512-linux.o.
8263 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
8264 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
8265 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
8266 i386/x32-avx512.xml.
8267 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
8268 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
8269 i386/x32-avx512-linux.xml.
8270 * i387-fp.c (num_avx512_k_registers): New constant for number
8271 of K registers.
8272 (num_avx512_zmmh_low_registers): New constant for number of
8273 lower ZMM registers (0-15).
8274 (num_avx512_zmmh_high_registers): New constant for number of
8275 higher ZMM registers (16-31).
8276 (num_avx512_ymmh_registers): New contant for number of higher
8277 YMM registers (ymm16-31 added by avx521 on x86_64).
8278 (num_avx512_xmm_registers): New constant for number of higher
8279 XMM registers (xmm16-31 added by AVX512 on x86_64).
8280 (struct i387_xsave): Add space for AVX512 registers.
8281 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
8282 Add code to handle AVX512 registers.
8283 (i387_xsave_to_cache): Add code to handle AVX512 registers.
8284 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
8285 prototypei from generated file.
8286 (tdesc_amd64_avx512_linux): Likewise.
8287 (init_registers_x32_avx512_linux): Likewise.
8288 (tdesc_x32_avx512_linux): Likewise.
8289 (init_registers_i386_avx512_linux): Likewise.
8290 (tdesc_i386_avx512_linux): Likewise.
8291 (x86_64_regmap): Add AVX512 registers.
8292 (x86_linux_read_description): Add code to handle AVX512 XSTATE
8293 mask.
8294 (initialize_low_arch): Add code to initialize AVX512 registers.
8295
8296 2014-04-23 Pedro Alves <palves@redhat.com>
8297
8298 * mem-break.c (find_gdb_breakpoint_at): Make static.
8299 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
8300
8301 2014-04-23 Pedro Alves <palves@redhat.com>
8302
8303 * i386-low.c: Don't include break-common.h here.
8304 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
8305 prototype to take target_hw_bp_type as argument instead of a Z
8306 packet char.
8307 * i386-low.h: Include break-common.h here.
8308 (Z_packet_to_hw_type): Declare.
8309 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
8310 prototypes.
8311 * linux-x86-low.c (x86_insert_point): Convert the packet number to
8312 a target_hw_bp_type before calling i386_low_insert_watchpoint.
8313 (x86_remove_point): Convert the packet number to a
8314 target_hw_bp_type before calling i386_low_remove_watchpoint.
8315 * win32-i386-low.c (i386_insert_point): Convert the packet number
8316 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
8317 (i386_remove_point): Convert the packet number to a
8318 target_hw_bp_type before calling i386_low_remove_watchpoint.
8319
8320 2014-04-23 Pedro Alves <palves@redhat.com>
8321
8322 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
8323
8324 2014-04-10 Pedro Alves <palves@redhat.com>
8325
8326 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
8327 Check if the condition or command is NULL before checking if the
8328 breakpoint is known. On success, return true.
8329 * mem-break.h (add_breakpoint_condition): Document return.
8330 (add_breakpoint_commands): Add describing comment.
8331 * server.c (skip_to_semicolon): New function.
8332 (process_point_options): Use it.
8333
8334 2014-04-09 Pedro Alves <palves@redhat.com>
8335
8336 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
8337 to lwpid_of.
8338
8339 2014-02-27 Pedro Alves <palves@redhat.com>
8340
8341 PR 12702
8342 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
8343 macros.
8344 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
8345 output.
8346 (last_thread_of_process_p): Take a PID argument instead of a
8347 thread pointer.
8348 (linux_wait_for_lwp): Delete.
8349 (num_lwps, check_zombie_leaders, not_stopped_callback): New
8350 functions.
8351 (linux_low_filter_event): New function, party factored out from
8352 linux_wait_for_event.
8353 (linux_wait_for_event): Rename to ...
8354 (linux_wait_for_event_filtered): ... this. Add new filter ptid
8355 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
8356 sigsuspend. Check for zombie leaders.
8357 (linux_wait_for_event): Reimplement as wrapper around
8358 linux_wait_for_event_filtered.
8359 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
8360 a normal or signal exit is seen, it's the whole process exiting.
8361 (wait_for_sigstop): No longer a for_each_inferior callback.
8362 Rewrite on top of linux_wait_for_event_filtered.
8363 (stop_all_lwps): Call wait_for_sigstop directly.
8364 * server.c (resume, handle_target_event): Handle
8365 TARGET_WAITKIND_NO_RESUMED.
8366
8367 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8368
8369 * win32-low.c (psapi_get_dll_name,
8370 * win32_CreateToolhelp32Snapshot): Delete.
8371 (win32_CreateToolhelp32Snapshot, win32_Module32First)
8372 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
8373 Delete.
8374 (handle_load_dll): Add function description.
8375 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
8376
8377 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8378
8379 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
8380 Add comment.
8381 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
8382 base address when calling win32_add_one_solib.
8383 (handle_load_dll): Delete local variable load_addr.
8384 Remove 0x1000 offset applied to DLL base address when calling
8385 win32_add_one_solib.
8386 (handle_unload_dll): Add comment.
8387
8388 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8389
8390 * win32-low.c (win32_add_all_dlls): Renames
8391 win32_ensure_ntdll_loaded. Rewrite function documentation.
8392 Adjust implementation to always load all DLLs.
8393 Add 0x1000 offset to DLL base address when calling
8394 win32_add_one_solib.
8395 (child_initialization_done): New static global.
8396 (do_initial_child_stuff): Set child_initialization_done to
8397 zero during child initialization, and 1 after. Replace call
8398 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
8399 Add comment.
8400 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
8401 (handle_unload_dll): Add function documentation.
8402 (get_child_debug_event): Ignore load and unload DLL events
8403 during child initialization.
8404
8405 2014-02-20 Doug Evans <dje@google.com>
8406
8407 Remove global all_lwps.
8408 * inferiors.h (ptid_of): Move here from linux-low.h.
8409 (pid_of, lwpid_of): Ditto.
8410 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
8411 parameter is a struct thread_info * now.
8412 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
8413 directly. Pass &all_threads to find_inferior instead of &all_lwps.
8414 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
8415 directly.
8416 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
8417 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
8418 * linux-arm-low.c (update_registers_callback): Update, "entry"
8419 parameter is a struct thread_info * now.
8420 Fetch lwpid from current_inferior directly.
8421 (arm_insert_point): Pass &all_threads to find_inferior instead of
8422 &all_lwps.
8423 (arm_remove_point): Ditto.
8424 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
8425 (arm_prepare_to_resume): Fetch pid from thread.
8426 (arm_read_description): Fetch lwpid from current_inferior directly.
8427 * linux-low.c (all_lwps): Delete.
8428 (delete_lwp): Delete call to remove_inferior.
8429 (handle_extended_wait): Fetch lwpid from thread.
8430 (add_lwp): Don't set lwp->entry.id. Remove call to
8431 add_inferior_to_list.
8432 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
8433 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
8434 (kill_one_lwp_callback): Ditto.
8435 (linux_kill): Don't dereference NULL pointer.
8436 Fetch ptid,lwpid from thread.
8437 (get_detach_signal): Fetch ptid from thread.
8438 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
8439 Simplify call to regcache_invalidate_thread.
8440 (delete_lwp_callback): Update, "entry" parameter is a
8441 struct thread_info * now. Fetch pid from thread.
8442 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
8443 (status_pending_p_callback): Update, "entry" parameter is a
8444 struct thread_info * now. Fetch ptid from thread.
8445 (find_lwp_pid): Update, "entry" parameter is a
8446 struct thread_info * now.
8447 (linux_wait_for_lwp): Fetch pid from thread.
8448 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
8449 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
8450 (enqueue_one_deferred_signal): Fetch lwpid from thread.
8451 (dequeue_one_deferred_signal): Ditto.
8452 (cancel_breakpoint): Fetch ptid from current_inferior.
8453 (linux_wait_for_event): Pass &all_threads to find_inferior,
8454 not &all_lwps. Fetch ptid, lwpid from thread.
8455 (count_events_callback): Update, "entry" parameter is a
8456 struct thread_info * now.
8457 (select_singlestep_lwp_callback): Ditto.
8458 (select_event_lwp_callback): Ditto.
8459 (cancel_breakpoints_callback): Ditto.
8460 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
8461 not &all_lwps.
8462 (select_event_lwp): Ditto. Fetch ptid from event_thread.
8463 (unsuspend_one_lwp): Update, "entry" parameter is a
8464 struct thread_info * now.
8465 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
8466 not &all_lwps.
8467 (linux_stabilize_threads): Ditto. And for for_each_inferior.
8468 Fetch lwpid from thread, not lwp.
8469 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
8470 Pass &all_threads to find_inferior, not &all_lwps.
8471 (send_sigstop): Fetch lwpid from thread, not lwp.
8472 (send_sigstop_callback): Update, "entry" parameter is a
8473 struct thread_info * now.
8474 (suspend_and_send_sigstop_callback): Ditto.
8475 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
8476 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
8477 struct thread_info * now.
8478 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
8479 from thread, lwp.
8480 (lwp_running): Update, "entry" parameter is a
8481 struct thread_info * now.
8482 (stop_all_lwps): Fetch ptid from thread.
8483 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
8484 (linux_resume_one_lwp): Fetch lwpid from thread.
8485 (linux_set_resume_request): Update, "entry" parameter is a
8486 struct thread_info * now. Fetch pid, lwpid from thread.
8487 (resume_status_pending_p): Update, "entry" parameter is a
8488 struct thread_info * now.
8489 (need_step_over_p): Ditto. Fetch lwpid from thread.
8490 (start_step_over): Fetch lwpid from thread.
8491 (linux_resume_one_thread): Update, "entry" parameter is a
8492 struct thread_info * now. Fetch lwpid from thread.
8493 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
8494 (proceed_one_lwp): Update, "entry" parameter is a
8495 struct thread_info * now. Fetch lwpid from thread.
8496 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
8497 struct thread_info * now.
8498 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
8499 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
8500 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
8501 directly.
8502 (regsets_store_inferior_registers): Ditto.
8503 (fetch_register, store_register): Ditto.
8504 (linux_read_memory, linux_write_memory): Ditto.
8505 (linux_request_interrupt): Ditto.
8506 (linux_read_auxv): Ditto.
8507 (linux_xfer_siginfo): Ditto.
8508 (linux_qxfer_spu): Ditto.
8509 (linux_qxfer_libraries_svr4): Ditto.
8510 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
8511 moved to inferiors.h.
8512 (get_lwp): Delete.
8513 (get_thread_lwp): Update.
8514 (struct lwp_info): Delete member "entry". Simplify comment for
8515 member "thread".
8516 (all_lwps): Delete.
8517 * linux-mips-low.c (mips_read_description): Fetch lwpid from
8518 current_inferior directly.
8519 (update_watch_registers_callback): Update, "entry" parameter is a
8520 struct thread_info * now. Fetch pid from thread.
8521 (mips_linux_prepare_to_resume): Fetch ptid from thread.
8522 (mips_insert_point): Fetch lwpid from current_inferior.
8523 Pass &all_threads to find_inferior, not &all_lwps.
8524 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
8525 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
8526 directly.
8527 (mips_stopped_data_address): Ditto.
8528 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
8529 directly.
8530 * linux-tile-low.c (tile_arch_setup): Ditto.
8531 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
8532 (update_debug_registers_callback): Update, "entry" parameter is a
8533 struct thread_info * now. Fetch pid from thread.
8534 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
8535 Pass &all_threads to find_inferior, not &all_lwps.
8536 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
8537 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
8538 Pass &all_threads to find_inferior, not &all_lwps.
8539 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
8540 (i386_dr_low_get_status): Ditto.
8541 (x86_linux_prepare_to_resume): Fetch ptid from thread.
8542 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
8543 (x86_linux_read_description): Ditto.
8544 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
8545
8546 2014-02-20 Doug Evans <dje@google.com>
8547
8548 * inferiors.c (get_first_inferior): Fix buglet.
8549
8550 2014-02-19 Doug Evans <dje@google.com>
8551
8552 * gdbthread.h (add_thread): Change result type to struct thread_info *.
8553 * inferiors.c (add_thread): Change result type to struct thread_info *.
8554 All callers updated.
8555 (add_lwp): Call add_thread here instead of in callers.
8556 All callers updated.
8557 * linux-low.h (get_lwp_thread): Rewrite.
8558 (struct lwp_info): New member "thread".
8559
8560 2014-02-19 Doug Evans <dje@google.com>
8561
8562 * linux-low.c (add_lwp): Change result to struct lwp_info *.
8563 All callers updated.
8564
8565 2014-02-19 Doug Evans <dje@google.com>
8566
8567 * inferiors.c (add_thread): Fix whitespace.
8568
8569 2014-02-19 Doug Evans <dje@google.com>
8570
8571 * dll.c (clear_dlls): Replace accessing list implemention details
8572 with API function.
8573 * gdbthread.h (get_first_thread): Declare.
8574 * inferiors.c (for_each_inferior_with_data): New function.
8575 (get_first_thread): New function.
8576 (find_thread_ptid): Simplify.
8577 (get_first_inferior): New function.
8578 (clear_list): Delete.
8579 (one_inferior_p): New function.
8580 (clear_inferior_list): New function.
8581 (clear_inferiors): Update.
8582 * inferiors.h (for_each_inferior_with_data): Declare.
8583 (clear_inferior_list): Declare.
8584 (one_inferior_p): Declare.
8585 (get_first_inferior): Declare.
8586 * linux-low.c (linux_wait_for_event): Replace accessing list
8587 implemention details with API function.
8588 * server.c (target_running): Ditto.
8589 (accumulate_file_name_length): New function.
8590 (emit_dll_description): New function.
8591 (handle_qxfer_libraries): Replace accessing list implemention
8592 details with API function.
8593 (handle_qxfer_threads_worker): New function.
8594 (handle_qxfer_threads_proper): Replace accessing list implemention
8595 details with API function.
8596 (handle_query): Ditto.
8597 (visit_actioned_threads_callback_ftype): New typedef.
8598 (visit_actioned_threads_data): New struct.
8599 (visit_actioned_threads): Rewrite to be find_inferior callback.
8600 (resume): Call find_inferior.
8601 (handle_status): Replace accessing list implemention
8602 details with API function.
8603 (process_serial_event): Replace accessing list implemention details
8604 with API function.
8605 * target.c (set_desired_inferior): Replace accessing list implemention
8606 details with API function.
8607 * tracepoint.c (same_process_p): New function.
8608 (gdb_agent_about_to_close): Replace accessing list implemention
8609 details with API function.
8610 * win32-low.c (child_delete_thread): Replace accessing list
8611 implemention details with API function.
8612 (match_dll_by_basename): New function.
8613 (dll_is_loaded_by_basename): New function.
8614 (win32_ensure_ntdll_loaded): Replace accessing list implemention
8615 details call to dll_is_loaded_by_basename.
8616
8617 2014-02-19 Doug Evans <dje@google.com>
8618
8619 * dll.h (struct dll_info): Add comment.
8620 * gdbthread.h (struct thread_info): Add comment.
8621 (current_ptid): Simplify.
8622 * inferiors.c (add_process): Update.
8623 (remove_process): Update.
8624 * inferiors.h (struct process_info): Rename member "head" to "entry".
8625 * linux-low.c (delete_lwp): Update.
8626 (add_lwp): Update.
8627 (last_thread_of_process_p): Update.
8628 (kill_one_lwp_callback, linux_kill): Update.
8629 (status_pending_p_callback): Update.
8630 (wait_for_sigstop): Update. Simplify read of ptid.
8631 (start_step_over): Update.
8632 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
8633 (get_lwp_thread): Update.
8634 (struct lwp_info): Rename member "head" to "entry".
8635 * regcache.h (inferior_list_entry): Delete.
8636 * server.c (kill_inferior_callback): Update.
8637 (detach_or_kill_inferior_callback): Update.
8638 (print_started_pid): Update.
8639 (print_attached_pid): Update.
8640 (process_serial_event): Simplify read of ptid.
8641 * thread-db.c (thread_db_create_event): Update.
8642 (thread_db_get_tls_address): Update.
8643 * win32-low.c (current_inferior_ptid): Simplify.
8644
8645 2014-02-19 Tom Tromey <tromey@redhat.com>
8646
8647 * target.h (struct target_ops) <supports_btrace>: Add target_ops
8648 argument.
8649 (target_supports_btrace): Update.
8650
8651 2014-02-14 Yao Qi <yao@codesourcery.com>
8652
8653 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
8654 (rsp-low-ipa.o): New target.
8655
8656 2014-02-12 Tom Tromey <tromey@redhat.com>
8657
8658 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
8659 convert_ascii_to_int.
8660 * regcache.c (registers_to_string): Likewise.
8661 * remote-utils.c (decode_M_packet): Likewise.
8662 * server.c (process_serial_event): Likewise.
8663
8664 2014-02-12 Tom Tromey <tromey@redhat.com>
8665
8666 * server.c (handle_query, handle_v_run): Use hex2bin, not
8667 unhexify.
8668 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
8669
8670 2014-02-12 Tom Tromey <tromey@redhat.com>
8671
8672 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
8673 convert_int_to_ascii.
8674 * regcache.c (registers_to_string, collect_register_as_string):
8675 Likewise.
8676 * remote-utils.c (look_up_one_symbol, relocate_instruction):
8677 Likewise.
8678 * server.c (process_serial_event): Likewise.
8679 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
8680 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
8681
8682 2014-02-12 Tom Tromey <tromey@redhat.com>
8683
8684 * remote-utils.c (look_up_one_symbol, monitor_output): Use
8685 bin2hex, not hexify.
8686 * tracepoint.c (cmd_qtstatus): Likewise.
8687
8688 2014-02-12 Tom Tromey <tromey@redhat.com>
8689
8690 * remote-utils.c (monitor_output): Pass explicit length to
8691 hexify.
8692
8693 2014-02-12 Tom Tromey <tromey@redhat.com>
8694
8695 * tracepoint.c: Include rsp-low.h.
8696 * server.c: Include rsp-low.h.
8697 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
8698 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
8699 declare.
8700 * remote-utils.c: Include rsp-low.h.
8701 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
8702 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
8703 (convert_int_to_ascii, convert_ascii_to_int): Move to
8704 common/rsp-low.c.
8705 * regcache.c: Include rsp-low.h.
8706 * ax.c: Include rsp-low.h.
8707 * Makefile.in (SFILES): Add common/rsp-low.c.
8708 (OBS): Add rsp-low.o.
8709 (rsp-low.o): New target.
8710
8711 2014-02-12 Tom Tromey <tromey@redhat.com>
8712
8713 * utils.h (pulongest, plongest, phex_nz): Don't declare.
8714 Include print-utils.h.
8715 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
8716 (plongest, thirty_two, phex_nz): Remove.
8717 * Makefile.in (SFILES): Add common/print-utils.c.
8718 (OBS): Add print-utils.o.
8719 (print-utils-ipa.o): New target.
8720 (print-utils.o): New target.
8721 (IPA_OBJS): Add print-utils-ipa.o.
8722
8723 2014-02-06 Tom Tromey <tromey@redhat.com>
8724
8725 * Makefile.in (SFILES): Fix indentation.
8726
8727 2014-02-05 Doug Evans <dje@google.com>
8728
8729 * linux-low.c (linux_wait_for_event): Improve comment.
8730 (linux_wait_1): Keep current_inferior in sync with event_child.
8731
8732 2014-01-22 Doug Evans <dje@google.com>
8733
8734 * gdbthread.h (gdb_id_to_thread): Delete, unused.
8735
8736 2014-01-22 Doug Evans <dje@google.com>
8737
8738 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
8739 * configure: Regenerate.
8740 * config.in: Regenerate.
8741 * Makefile.in (SFILES): Add debug.c.
8742 (OBS): Add debug.o.
8743 * debug.c: New file.
8744 * debug.h: New file.
8745 * linux-aarch64-low.c (*): Update all debugging printfs to use
8746 debug_printf instead of fprintf.
8747 * linux-arm-low.c (*): Ditto.
8748 * linux-cris-low.c (*): Ditto.
8749 * linux-crisv32-low.c (*): Ditto.
8750 * linux-m32r-low.c (*): Ditto.
8751 * linux-sparc-low.c (*): Ditto.
8752 * linux-x86.c (*): Ditto.
8753 * linux-low.c (*): Ditto.
8754 (linux_wait_1): Add calls to debug_enter, debug_exit.
8755 (linux_wait): Remove redundant debugging printf.
8756 (stop_all_lwps): Add calls to debug_enter, debug_exit.
8757 (linux_resume, unstop_all_lwps): Ditto.
8758 * mem-break.c (*): Update all debugging printfs to use
8759 debug_printf instead of fprintf.
8760 * remote-utils.c (*): Ditto.
8761 * thread-db.c (*): Ditto.
8762 * server.c #include <ctype.h>, "gdb_vecs.h".
8763 (debug_threads): Moved to debug.c.
8764 (*): Update all debugging printfs to use debug_printf instead of
8765 fprintf.
8766 (start_inferior): Replace call to fflush with call to debug_flush.
8767 (monitor_show_help): Mention set debug-format.
8768 (parse_debug_format_options): New function.
8769 (handle_monitor_command): Handle "monitor set debug-format".
8770 (gdbserver_usage): Mention --debug-format.
8771 (main): Parse --debug-format.
8772 * server.h (debug_threads): Declaration moved to debug.h.
8773 #include "debug.h".
8774 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
8775 trace_debug_1 that uses debug_printf.
8776 (tracepoint_look_up_symbols): Update all debugging printfs to use
8777 debug_printf instead of fprintf.
8778
8779 2014-01-20 Baruch Siach <baruch@tkos.co.il>
8780
8781 * linux-xtensa-low.c: Include asm/ptrace.h instead of
8782 sys/ptrace.h.
8783
8784 2014-01-17 Pedro Alves <palves@redhat.com>
8785
8786 PR build/16445
8787 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
8788 defined after including gdb_proc_service.h.
8789
8790 2014-01-16 Doug Evans <dje@google.com>
8791
8792 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
8793 (match_dll): Use it.
8794
8795 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
8796
8797 * target.h (target_ops) <read_btrace>: Change parameters and
8798 return type to allow error reporting.
8799 * server.c (handle_qxfer_btrace): Support delta reads. Pass
8800 trace reading errors on.
8801 * linux-low.c (linux_low_read_btrace): Pass trace reading
8802 errors on.
8803 (linux_low_disable_btrace): New.
8804
8805 2014-01-15 Doug Evans <dje@google.com>
8806
8807 * inferiors.c (thread_id_to_gdb_id): Delete.
8808 * inferiors.h (thread_id_to_gdb_id): Delete.
8809
8810 2014-01-13 Eli Zaretskii <eliz@gnu.org>
8811
8812 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
8813 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
8814 versions.
8815
8816 2014-01-08 Pedro Alves <palves@redhat.com>
8817
8818 * server.c (handle_status): Don't discard previous queued stop
8819 replies or thread's pending status here.
8820 (main) <disconnection>: Do it here instead.
8821
8822 2014-01-08 Pedro Alves <palves@redhat.com>
8823
8824 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
8825 * server.c (visit_actioned_threads, handle_pending_status): New
8826 function.
8827 (handle_v_cont): Factor out parts to ...
8828 (resume): ... this new function. If in all-stop, and a thread
8829 being resumed has a pending status, report it without actually
8830 resuming.
8831 (myresume): Adjust to use the new 'resume' function.
8832 (clear_pending_status_callback, set_pending_status_callback)
8833 (find_status_pending_thread_callback): New functions.
8834 (handle_status): Handle the case of multiple threads having
8835 interesting statuses to report. Report threads' real last signal
8836 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
8837 with an interesting thread to report the status for, instead of
8838 always reporting the status of the first thread.
8839
8840 2014-01-01 Joel Brobecker <brobecker@adacore.com>
8841
8842 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
8843 * gdbreplay.c (gdbreplay_version): Likewise.
8844
8845 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
8846
8847 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
8848 iov.iov_len with the real length in use.
8849
8850 2013-12-13 Joel Brobecker <brobecker@adacore.com>
8851
8852 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
8853 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
8854 for all targets that use win32-low.c.
8855 * win32-low.c (win32_ensure_ntdll_loaded): New function.
8856 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
8857
8858 2013-12-13 Pedro Alves <palves@redhat.com>
8859
8860 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
8861 if equal to TARGET_WAITKIND_LOADED.
8862 * win32-low.c (cached_status): New static global.
8863 (win32_wait): Add declaration.
8864 (do_initial_child_stuff): Flush all initial pending debug events
8865 up to the initial breakpoint.
8866 (win32_wait): If CACHED_STATUS was set, return that instead
8867 of doing a real wait. Remove the code resuming the execution
8868 of the inferior after receiving a TARGET_WAITKIND_LOADED event
8869 during the initial phase. Also remove the code changing
8870 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
8871 TARGET_WAITKIND_STOPPED.
8872
8873 2013-12-11 Yao Qi <yao@codesourcery.com>
8874
8875 * notif.c (handle_notif_ack): Return 0 if no notification
8876 matches.
8877
8878 2013-11-20 Doug Evans <dje@google.com>
8879
8880 * linux-low.c (linux_set_resume_request): Fix comment.
8881
8882 2013-11-20 Doug Evans <dje@google.com>
8883
8884 * linux-low.c (resume_status_pending_p): Tweak comment.
8885
8886 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
8887
8888 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
8889 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
8890 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
8891 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
8892 (srv_amd64_regobj): Add amd64-mpx.o.
8893 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
8894 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
8895 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
8896 * i387-fp.c (num_pl_bnd_register) Added constant.
8897 (num_pl_bnd_cfg_registers) Added constant.
8898 (struct i387_xsave) Added reserved area and MPX fields.
8899 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
8900 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
8901 function.
8902 (tdesc_i386_mpx_linux): Add MPX amd64 target.
8903 (init_registers_amd64_mpx_linux): Declare new function.
8904 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
8905 (x86_64_regmap): Add MPX registers.
8906 (x86_linux_read_description): Add MPX case.
8907 (initialize_low_arch): Initialize MPX targets.
8908
8909 2013-11-18 Tom Tromey <tromey@redhat.com>
8910
8911 * configure: Rebuild.
8912 * configure.ac: Don't check for stdlib.h.
8913 * gdbreplay.c: Unconditionally include stdlib.h.
8914
8915 2013-11-18 Tom Tromey <tromey@redhat.com>
8916
8917 * config.in: Rebuild.
8918 * configure: Rebuild.
8919 * configure.ac: Don't use AC_HEADER_DIRENT.
8920
8921 2013-11-18 Tom Tromey <tromey@redhat.com>
8922
8923 * server.h: Don't check HAVE_STRING_H.
8924 * gdbreplay.c: Don't check HAVE_STRING_H.
8925 * configure: Rebuild.
8926
8927 2013-11-18 Tom Tromey <tromey@redhat.com>
8928
8929 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
8930 LIBGNU.
8931
8932 2013-11-08 Tom Tromey <tromey@redhat.com>
8933
8934 * configure, config.in: Rebuild.
8935 * configure.ac: Remove unused configury.
8936
8937 2013-11-08 Tom Tromey <tromey@redhat.com>
8938
8939 * acinclude.m4: Include common.m4, codeset.m4.
8940 * configure, config.in: Rebuild.
8941 * configure.ac: Use GDB_AC_COMMON.
8942
8943 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
8944
8945 * linux-s390-low.c (HWCAP_S390_TE): New define.
8946 (s390_arch_setup): Consider the TE field in the HWCAP for
8947 determining 'have_regset_tdb'.
8948
8949 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
8950
8951 PR gdb/16014
8952 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
8953 call to sizeof.
8954
8955 2013-10-02 Pedro Alves <palves@redhat.com>
8956
8957 * server.c (process_serial_event): Don't output "GDBserver
8958 exiting" if GDB is connected through stdio.
8959 * target.c (mywait): Likewise, be silent if GDB is connected
8960 through stdio.
8961
8962 2013-10-01 Joel Brobecker <brobecker@adacore.com>
8963
8964 * lynx-low.c (lynx_add_threads_after_attach): New function.
8965 (lynx_attach): Remove call to add_thread. Add call to
8966 lynx_add_threads_after_attach instead.
8967
8968 2013-09-28 Mike Frysinger <vapier@gentoo.org>
8969
8970 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
8971 * config.in, configure: Regenerated.
8972
8973 2013-09-18 Yao Qi <yao@codesourcery.com>
8974
8975 PR server/15959
8976 * server.c (start_inferior): Clear 'resume_info'.
8977
8978 2013-09-16 Jiong Wang <jiwang@tilera.com>
8979
8980 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
8981 for each register.
8982
8983 2013-09-16 Jiong Wang <jiwang@tilera.com>
8984
8985 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
8986 linux-tile-low.o to srv_tgtobj.
8987
8988 2013-09-16 Will Newton <will.newton@linaro.org>
8989
8990 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
8991 out regs.
8992
8993 2013-09-06 Pedro Alves <palves@redhat.com>
8994
8995 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
8996 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
8997 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
8998 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
8999 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
9000 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
9001
9002 2013-09-06 Pedro Alves <palves@redhat.com>
9003
9004 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
9005 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
9006
9007 2013-09-06 Pedro Alves <palves@redhat.com>
9008
9009 * linux-amd64-ipa.c: Include tracepoint.h.
9010 * linux-i386-ipa.c: Include tracepoint.h.
9011
9012 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
9013
9014 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
9015 (ps_get_thread_area): New function.
9016
9017 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
9018
9019 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
9020 (initialize_low_arch): Call init_registers_crisv32 rather than
9021 init_register_crisv32.
9022
9023 2013-09-05 Pedro Alves <palves@redhat.com>
9024
9025 * server.h (handle_vFile, hostio_last_error_from_errno): Move
9026 to ...
9027 * hostio.h: ... this new file.
9028 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
9029 win32-low.c: Include hostio.h.
9030
9031 2013-09-05 Pedro Alves <palves@redhat.com>
9032
9033 * server.h (gdb_client_data, handler_func, callback_handler_func)
9034 (delete_file_handler, add_file_handler, append_callback_event)
9035 (delete_callback_event, start_event_loop, initialize_event_loop):
9036 Move to event-loop.h and include it.
9037 * event-loop.h: New file.
9038
9039 2013-09-05 Pedro Alves <palves@redhat.com>
9040
9041 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
9042 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
9043 (loaded_dll, unloaded_dll): Move to ...
9044 * dll.h: ... this new file.
9045 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
9046
9047 2013-09-05 Pedro Alves <palves@redhat.com>
9048
9049 * server.h (current_process, get_thread_process, all_processes)
9050 (add_inferior_to_list, for_each_inferior, current_inferior)
9051 (remove_inferior, add_process, remove_process, find_process_pid)
9052 (have_started_inferiors_p, have_attached_inferiors_p)
9053 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
9054 (clear_inferiors, find_inferior, find_inferior_id)
9055 (inferior_target_data, set_inferior_target_data)
9056 (inferior_regcache_data, set_inferior_regcache_data): Move to
9057 inferiors.h, and include it.
9058 * inferiors.h: New file.
9059
9060 2013-09-05 Pedro Alves <palves@redhat.com>
9061
9062 * server.h (struct emit_ops, current_insn_ptr, emit_error):
9063 Move ...
9064 * ax.h: ... here.
9065
9066 2013-09-05 Pedro Alves <palves@redhat.com>
9067
9068 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
9069 tracepoint.h.
9070 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
9071 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
9072 (handle_tracepoint_general_set, handle_tracepoint_query)
9073 (tracepoint_finished_step, tracepoint_was_hit)
9074 (release_while_stepping_state_list, current_traceframe)
9075 (in_readonly_region, traceframe_read_mem)
9076 (fetch_traceframe_registers, traceframe_read_sdata)
9077 (traceframe_read_info, struct fast_tpoint_collect_status)
9078 (fast_tracepoint_collecting, force_unlock_trace_buffer)
9079 (handle_tracepoit_bkpts, initialize_low_tracepoint)
9080 (supply_fast_tracepoint_registers)
9081 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
9082 (ipa_tdesc, claim_trampoline_space)
9083 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
9084 (agent_mem_read, agent_get_trace_state_variable_value)
9085 (agent_set_trace_state_variable_value, agent_tsv_read)
9086 (agent_mem_read_string, get_raw_reg_func_addr)
9087 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
9088 * tracepoint.h: ... this new file.
9089
9090 2013-09-05 Pedro Alves <palves@redhat.com>
9091
9092 * server.h (perror_with_name, error, fatal, warning, paddress)
9093 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
9094 include it.
9095 * utils.h: New file.
9096
9097 2013-09-05 Pedro Alves <palves@redhat.com>
9098
9099 * server.h (remote_debug, noack_mode, transport_is_reliable)
9100 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
9101 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
9102 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
9103 (write_enn, initialize_async_io, enable_async_io)
9104 (disable_async_io, check_remote_input_interrupt_request)
9105 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
9106 (dead_thread_notify, prepare_resume_reply)
9107 (decode_address_to_semicolon, decode_address, decode_m_packet)
9108 (decode_M_packet, decode_X_packet, decode_xfer_write)
9109 (decode_search_memory_packet, unhexify, hexify)
9110 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
9111 (look_up_one_symbol, relocate_instruction)
9112 (monitor_output): Move to remote-utils.h, and include it.
9113 * remote-utils.h: New file.
9114
9115 2013-09-05 Pedro Alves <palves@redhat.com>
9116
9117 * server.h (_): Delete.
9118
9119 2013-09-02 Pedro Alves <palves@redhat.com>
9120
9121 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
9122 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
9123 allocated.
9124 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
9125
9126 2013-09-02 Pierre Muller <muller@sourceware.org>
9127
9128 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
9129 or WriteProcessMemory complete successfully and handle
9130 ERROR_PARTIAL_COPY error.
9131
9132 2013-09-02 Pedro Alves <palves@redhat.com>
9133
9134 * server.c (gdb_read_memory): Return -1 on traceframe memory read
9135 error instead of EIO.
9136
9137 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
9138
9139 PR server/15604
9140 * linux-low.c: Include filestuff.h.
9141 (linux_create_inferior) <pid == 0>: Call close_most_fds.
9142 * lynx-low.c: Include filestuff.h.
9143 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
9144 * server.c: Include filestuff.h.
9145 (main): Call notice_open_fds.
9146 * spu-low.c: Include filestuff.h.
9147 (spu_create_inferior) <pid == 0>: Call close_most_fds.
9148
9149 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
9150
9151 * Makefile.in: Explain why ../target and ../nat are not
9152 listed as include file search paths.
9153 (linux-waitpid.o): New object file rule.
9154 * configure.srv (srv_native_linux_obj): New variable.
9155 Replace all occurrences of linux native object files with
9156 $srv_native_linux_obj.
9157 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
9158 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
9159 (linux_enable_event_reporting): Remove declaration.
9160 (my_waitpid): Moved to common/linux-waitpid.c.
9161 (linux_wait_for_event): Pass ptid when calling
9162 linux_enable_event_reporting.
9163 (linux_supports_tracefork_flag): Remove.
9164 (linux_enable_event_reporting): Likewise.
9165 (linux_tracefork_grandchild): Remove.
9166 (STACK_SIZE): Moved to common/linux-ptrace.c.
9167 (linux_tracefork_child): Remove.
9168 (linux_test_for_tracefork): Remove.
9169 (linux_look_up_symbols): Call linux_supports_traceclone.
9170 (initialize_low): Remove call to linux_test_for_tracefork.
9171 * linux-low.h (PTRACE_TYPE_ARG3): Move to
9172 common/linux-ptrace.h.
9173 (PTRACE_TYPE_ARG4): Likewise.
9174 Include linux-ptrace.h.
9175
9176 2013-08-21 Pedro Alves <palves@redhat.com>
9177
9178 * config.in: Renegerate.
9179
9180 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
9181
9182 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
9183 (SFILES): Remove $(srcdir)/common/target-common.c and
9184 add $(srcdir)/target/waitstatus.c.
9185 (OBS): Remove target-common.o and add waitstatus.o.
9186 (server_h): Remove $(srcdir)/../common/target-common.h and
9187 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
9188 and $(srcdir)/../target/waitstatus.h.
9189 (target-common.o): Remove.
9190 (waitstatus.o): New target object file.
9191 * target.h: Do not include target-common.h and
9192 include target/resume.h, target/wait.h and
9193 target/waitstatus.h.
9194
9195 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
9196
9197 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
9198 to PTRACE_TYPE_ARG3.
9199 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
9200 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
9201 PTRACE_TYPE_ARG4.
9202 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
9203 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
9204
9205 2013-07-27 Jie Zhang <jie@codesourcery.com>
9206 Daniel Jacobowitz <dan@codesourcery.com>
9207 Yao Qi <yao@codesourcery.com>
9208
9209 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
9210 (mips-linux-watch.o): New rule.
9211 (mips_linux_watch_h): New variable.
9212 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
9213 srv_tgtobj.
9214 * linux-mips-low.c: Include mips-linux-watch.h.
9215 (struct arch_process_info, struct arch_lwp_info): New.
9216 (update_watch_registers_callback): New function.
9217 (mips_linux_new_process, mips_linux_new_thread) New functions.
9218 (mips_linux_prepare_to_resume, mips_insert_point): New
9219 functions.
9220 (mips_remove_point, mips_stopped_by_watchpoint): New
9221 functions.
9222 (rsp_bp_type_to_target_hw_bp_type): New function.
9223 (mips_stopped_data_address): New function.
9224 (the_low_target): Add watchpoint support functions.
9225
9226 2013-07-27 Yao Qi <yao@codesourcery.com>
9227
9228 * i386-low.c: Include break-common.h.
9229 (enum target_hw_bp_type): Remove.
9230
9231 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
9232
9233 * Makefile.in (SFILES): /common/target-common.c.
9234 (OBS): Add target-common.o.
9235 (server_h): Add $(srcdir)/../common/target-common.h.
9236 (target-common.o): New target.
9237 * server.c (queue_stop_reply_callback): Free
9238 status string after use.
9239 * target.c (target_waitstatus_to_string): Remove.
9240 * target.h: Include target-common.h.
9241 (resume_kind): Likewise.
9242 (target_waitkind): Likewise.
9243 (target_waitstatus): Likewise.
9244 (TARGET_WNOHANG): Likewise.
9245
9246 2013-07-04 Yao Qi <yao@codesourcery.com>
9247
9248 * Makefile.in (host_alias): Use @host_noncanonical@.
9249 (target_alias): Use @target_noncanonical@.
9250 * configure.ac: Use ACX_NONCANONICAL_TARGET and
9251 ACX_NONCANONICAL_HOST.
9252 * configure: Regenerated.
9253
9254 Revert:
9255 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
9256
9257 * configure.ac (version_host, version_target): Set and AC_SUBST them.
9258 * configure: Rebuild.
9259 * Makefile.in (version_host, version_target): Get from configure.
9260 (version.c): Use $(version_host) and $(version_target).
9261
9262 2013-07-03 Pedro Alves <palves@redhat.com>
9263
9264 * Makefile.in (config.status): Depend on development.sh.
9265 * acinclude.m4: Include libmcheck.m4.
9266 * configure: Regenerate.
9267
9268 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
9269
9270 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
9271 attribute inside the parentheses.
9272 (winapi_DebugSetProcessKillOnExit): Ditto.
9273 (winapi_DebugBreakProcess): Ditto.
9274 (winapi_GenerateConsoleCtrlEvent): Ditto.
9275
9276 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
9277
9278 * notif.h (notif_event): Add a dummy member to avoid compiler
9279 errors.
9280
9281 2013-07-01 Pedro Alves <palves@redhat.com>
9282
9283 * hostio.c (HOSTIO_PATH_MAX): Define.
9284 (require_filename, handle_open, handle_unlink, handle_readlink):
9285 Use it.
9286
9287 2013-07-01 Pedro Alves <palves@redhat.com>
9288
9289 * server.h: Include "pathmax.h".
9290 * linux-low.c: Don't include sys/param.h.
9291 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
9292 MAXPATHLEN.
9293 * win32-low.c: Don't include sys/param.h.
9294 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
9295
9296 2013-07-01 Pedro Alves <palves@redhat.com>
9297
9298 * event-loop.c: Don't check HAVE_UNISTD_H before including
9299 <unistd.h>.
9300 * gdbreplay.c: Likewise.
9301 * remote-utils.c: Likewise.
9302 * server.c: Likewise.
9303 * configure.ac: Don't check for unistd.h.
9304 * configure: Regenerate.
9305
9306 2013-06-28 Tom Tromey <tromey@redhat.com>
9307
9308 * Makefile.in (version.c): Use version.in, not
9309 common/version.in.
9310
9311 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
9312
9313 * configure.ac (version_host, version_target): Set and AC_SUBST them.
9314 * configure: Rebuild.
9315 * Makefile.in (version_host, version_target): Get from configure.
9316 (version.c): Use $(version_host) and $(version_target).
9317
9318 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
9319
9320 Fix trace-status to output user name without trailing colon.
9321 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
9322
9323 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
9324
9325 Fix trace-status to output proper start-time and stop-time.
9326 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
9327 output start time and stop time in hex as gdb expects.
9328
9329 2013-06-26 Pedro Alves <pedro@codesourcery.com>
9330
9331 * tracepoint.c (build_traceframe_info_xml): Output trace state
9332 variables present in the trace buffer.
9333
9334 2013-06-24 Tom Tromey <tromey@redhat.com>
9335
9336 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
9337 create-version.sh.
9338 (version.o): Remove.
9339 * gdbreplay.c: Include version.h.
9340 (version, host_name): Don't declare.
9341 * server.h: Include version.h.
9342 (version, host_name): Don't declare.
9343
9344 2013-06-12 Pedro Alves <palves@redhat.com>
9345
9346 * linux-x86-low.c (linux_is_elf64): Delete global.
9347 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
9348 with local linux_pid_exe_is_elf_64_file use.
9349
9350 2013-06-11 Pedro Alves <palves@redhat.com>
9351
9352 * linux-low.c (regset_disabled, disable_regset): New functions.
9353 (regsets_fetch_inferior_registers)
9354 (regsets_store_inferior_registers): Use them.
9355 (initialize_regsets_info); Don't allocate the disabled_regsets
9356 array here.
9357 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
9358 comment.
9359
9360 2013-06-11 Pedro Alves <palves@redhat.com>
9361
9362 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
9363 xmalloc.
9364
9365 2013-06-11 Pedro Alves <palves@redhat.com>
9366
9367 * linux-x86-low.c (initialize_low_arch): Call
9368 init_registers_x32_avx_linux.
9369
9370 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
9371
9372 Fix compatibility with Android Bionic.
9373 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
9374 it is not empty.
9375
9376 2013-06-07 Pedro Alves <palves@redhat.com>
9377
9378 PR server/14823
9379 * Makefile.in (OBS): Add tdesc.o.
9380 (IPA_OBJS): Add tdesc-ipa.o.
9381 (tdesc-ipa.o): New rule.
9382 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
9383 interface.
9384 * linux-low.c (new_inferior): Delete.
9385 (disabled_regsets, num_regsets): Delete.
9386 (linux_add_process): Adjust to set the new per-process
9387 new_inferior flag.
9388 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
9389 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
9390 was a stop. When calling arch_setup, switch the current inferior
9391 to the thread that got an event.
9392 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
9393 (regsets_fetch_inferior_registers)
9394 (regsets_store_inferior_registers): New regsets_info parameter.
9395 Adjust to use it.
9396 (linux_register_in_regsets): New regs_info parameter. Adjust to
9397 use it.
9398 (register_addr, fetch_register, store_register): New usrregs_info
9399 parameter. Adjust to use it.
9400 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
9401 parameter regs_info. Adjust to use it.
9402 (linux_fetch_registers): Get the current inferior's regs_info, and
9403 adjust to use it.
9404 (linux_store_registers): Ditto.
9405 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
9406 (initialize_low): Don't initialize the target_regsets here. Call
9407 initialize_low_arch.
9408 * linux-low.h (target_regsets): Delete declaration.
9409 (struct regsets_info): New.
9410 (struct usrregs_info): New.
9411 (struct regs_info): New.
9412 (struct process_info_private) <new_inferior>: New field.
9413 (struct linux_target_ops): Delete the num_regs, regmap, and
9414 regset_bitmap fields. New field regs_info.
9415 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
9416 * i387-fp.c (num_xmm_registers): Delete.
9417 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
9418 calls to new interface.
9419 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
9420 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
9421 Infer the number of xmm registers from the regcache's target
9422 description.
9423 * i387-fp.h (num_xmm_registers): Delete.
9424 * inferiors.c (add_thread): Don't install the thread's regcache
9425 here.
9426 * proc-service.c (gregset_info): Fetch the current inferior's
9427 regs_info. Adjust to use it.
9428 * regcache.c: Include tdesc.h.
9429 (register_bytes, reg_defs, num_registers)
9430 (gdbserver_expedite_regs): Delete.
9431 (get_thread_regcache): If the thread doesn't have a regcache yet,
9432 create one, instead of aborting gdbserver.
9433 (regcache_invalidate_one): Rename to ...
9434 (regcache_invalidate_thread): ... this.
9435 (regcache_invalidate_one): New.
9436 (regcache_invalidate): Only invalidate registers of the current
9437 process.
9438 (init_register_cache): Add target_desc parameter, and use it.
9439 (new_register_cache): Ditto. Assert the target description has a
9440 non zero registers_size.
9441 (regcache_cpy): Add assertions. Adjust.
9442 (realloc_register_cache, set_register_cache): Delete.
9443 (registers_to_string, registers_from_string): Adjust.
9444 (find_register_by_name, find_regno, find_register_by_number)
9445 (register_cache_size): Add target_desc parameter, and use it.
9446 (free_register_cache_thread, free_register_cache_thread_one)
9447 (regcache_release, register_cache_size): New.
9448 (register_size): Add target_desc parameter, and use it.
9449 (register_data, supply_register, supply_register_zeroed)
9450 (supply_regblock, supply_register_by_name, collect_register)
9451 (collect_register_as_string, collect_register_by_name): Adjust.
9452 * regcache.h (struct target_desc): Forward declare.
9453 (struct regcache) <tdesc>: New field.
9454 (init_register_cache, new_register_cache): Add target_desc
9455 parameter.
9456 (regcache_invalidate_thread): Declare.
9457 (regcache_invalidate_one): Delete declaration.
9458 (regcache_release): Declare.
9459 (find_register_by_number, register_cache_size, register_size)
9460 (find_regno): Add target_desc parameter.
9461 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
9462 declarations.
9463 * remote-utils.c: Include tdesc.h.
9464 (outreg, prepare_resume_reply): Adjust.
9465 * server.c: Include tdesc.h.
9466 (gdbserver_xmltarget): Delete declaration.
9467 (get_features_xml, process_serial_event): Adjust.
9468 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
9469 declare.
9470 (struct process_info) <tdesc>: New field.
9471 (ipa_tdesc): Declare.
9472 * tdesc.c: New file.
9473 * tdesc.h: New file.
9474 * tracepoint.c: Include tdesc.h.
9475 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
9476 (get_context_regcache): Adjust to pass ipa_tdesc down.
9477 (do_action_at_tracepoint): Adjust to get the register cache size
9478 from the context regcache's description.
9479 (traceframe_walk_blocks): Adjust to get the register cache size
9480 from the current trace frame's description.
9481 (traceframe_get_pc): Adjust to get current trace frame's
9482 description and pass it down.
9483 (gdb_collect): Adjust to get the register cache size from the
9484 IPA's description.
9485 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
9486 (gdbserver_xmltarget): Delete.
9487 (initialize_low_tracepoint): Set the ipa's target description.
9488 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
9489 (initialize_low_tracepoint): Set the ipa's target description.
9490 * linux-x86-low.c: Include tdesc.h.
9491 [__x86_64__] (is_64bit_tdesc): New.
9492 (ps_get_thread_area, x86_get_thread_area): Use it.
9493 (i386_cannot_store_register): Rename to ...
9494 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
9495 (i386_cannot_fetch_register): Rename to ...
9496 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
9497 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
9498 to new interface.
9499 (target_regsets): Rename to ...
9500 (x86_regsets): ... this.
9501 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
9502 interface.
9503 (x86_siginfo_fixup): Use is_64bit_tdesc.
9504 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
9505 (tdesc_x32_avx_linux, tdesc_x32_linux)
9506 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
9507 Declare.
9508 (x86_linux_update_xmltarget): Delete.
9509 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
9510 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
9511 (AMD64_LINUX_USER64_CS): New.
9512 (x86_linux_read_description): New, based on
9513 x86_linux_update_xmltarget.
9514 (same_process_callback): New.
9515 (x86_arch_setup_process_callback): New.
9516 (x86_linux_update_xmltarget): New.
9517 (x86_regsets_info): New.
9518 (amd64_linux_regs_info): New.
9519 (i386_linux_usrregs_info): New.
9520 (i386_linux_regs_info): New.
9521 (x86_linux_regs_info): New.
9522 (x86_arch_setup): Reimplement.
9523 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
9524 (x86_emit_ops): Ditto.
9525 (the_low_target): Adjust. Install x86_linux_regs_info,
9526 x86_cannot_fetch_register, and x86_cannot_store_register.
9527 (initialize_low_arch): New.
9528 * linux-ia64-low.c (tdesc_ia64): Declare.
9529 (ia64_fetch_register): Adjust.
9530 (ia64_usrregs_info, regs_info): New globals.
9531 (ia64_regs_info): New function.
9532 (the_low_target): Adjust.
9533 (initialize_low_arch): New function.
9534 * linux-sparc-low.c (tdesc_sparc64): Declare.
9535 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
9536 Adjust.
9537 (sparc_arch_setup): New function.
9538 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
9539 (the_low_target): Adjust.
9540 (initialize_low_arch): New function.
9541 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
9542 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
9543 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
9544 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
9545 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
9546 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
9547 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
9548 (tdesc_powerpc_isa205_vsx64l): Declare.
9549 (ppc_cannot_store_register, ppc_collect_ptrace_register)
9550 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
9551 (ppc_set_pc, ppc_get_hwcap): Adjust.
9552 (ppc_usrregs_info): Forward declare.
9553 (!__powerpc64__) ppc_regmap_adjusted: New global.
9554 (ppc_arch_setup): Adjust to the current process'es target
9555 description.
9556 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
9557 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
9558 (ppc_store_evrregset): Adjust.
9559 (target_regsets): Rename to ...
9560 (ppc_regsets): ... this, and make static.
9561 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
9562 (ppc_regs_info): New function.
9563 (the_low_target): Adjust.
9564 (initialize_low_arch): New function.
9565 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
9566 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
9567 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
9568 (tdesc_s390x_linux64v2): Declare.
9569 (s390_collect_ptrace_register, s390_supply_ptrace_register)
9570 (s390_fill_gregset, s390_store_last_break): Adjust.
9571 (target_regsets): Rename to ...
9572 (s390_regsets): ... this, and make static.
9573 (s390_get_pc, s390_set_pc): Adjust.
9574 (s390_get_hwcap): New target_desc parameter, and use it.
9575 [__s390x__] (have_hwcap_s390_high_gprs): New global.
9576 (s390_arch_setup): Adjust to set the current process'es target
9577 description. Don't adjust the regmap.
9578 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
9579 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
9580 (regs_info_3264): New globals.
9581 (s390_regs_info): New function.
9582 (the_low_target): Adjust.
9583 (initialize_low_arch): New function.
9584 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
9585 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
9586 [__mips64] (init_registers_mips_linux)
9587 (init_registers_mips_dsp_linux): Delete defines.
9588 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
9589 (have_dsp): New global.
9590 (mips_read_description): New, based on mips_arch_setup.
9591 (mips_arch_setup): Reimplement.
9592 (get_usrregs_info): New function.
9593 (mips_cannot_fetch_register, mips_cannot_store_register)
9594 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
9595 (mips_fill_fpregset, mips_store_fpregset): Adjust.
9596 (target_regsets): Rename to ...
9597 (mips_regsets): ... this, and make static.
9598 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
9599 (dsp_regs_info, regs_info): New globals.
9600 (mips_regs_info): New function.
9601 (the_low_target): Adjust.
9602 (initialize_low_arch): New function.
9603 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
9604 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
9605 Declare.
9606 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
9607 (arm_read_description): New, with bits factored from
9608 arm_arch_setup.
9609 (arm_arch_setup): Reimplement.
9610 (target_regsets): Rename to ...
9611 (arm_regsets): ... this, and make static.
9612 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
9613 (arm_regs_info): New function.
9614 (the_low_target): Adjust.
9615 (initialize_low_arch): New function.
9616 * linux-m68k-low.c (tdesc_m68k): Declare.
9617 (target_regsets): Rename to ...
9618 (m68k_regsets): ... this, and make static.
9619 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
9620 (m68k_regs_info): New function.
9621 (m68k_arch_setup): New function.
9622 (the_low_target): Adjust.
9623 (initialize_low_arch): New function.
9624 * linux-sh-low.c (tdesc_sharch): Declare.
9625 (target_regsets): Rename to ...
9626 (sh_regsets): ... this, and make static.
9627 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
9628 (sh_regs_info, sh_arch_setup): New functions.
9629 (the_low_target): Adjust.
9630 (initialize_low_arch): New function.
9631 * linux-bfin-low.c (tdesc_bfin): Declare.
9632 (bfin_arch_setup): New function.
9633 (bfin_usrregs_info, regs_info): New globals.
9634 (bfin_regs_info): New function.
9635 (the_low_target): Adjust.
9636 (initialize_low_arch): New function.
9637 * linux-cris-low.c (tdesc_cris): Declare.
9638 (cris_arch_setup): New function.
9639 (cris_usrregs_info, regs_info): New globals.
9640 (cris_regs_info): New function.
9641 (the_low_target): Adjust.
9642 (initialize_low_arch): New function.
9643 * linux-cris-low.c (tdesc_crisv32): Declare.
9644 (cris_arch_setup): New function.
9645 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
9646 (cris_regs_info): New function.
9647 (the_low_target): Adjust.
9648 (initialize_low_arch): New function.
9649 * linux-m32r-low.c (tdesc_m32r): Declare.
9650 (m32r_arch_setup): New function.
9651 (m32r_usrregs_info, regs_info): New globals.
9652 (m32r_regs_info): Adjust.
9653 (initialize_low_arch): New function.
9654 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
9655 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
9656 (tic6x_usrregs_info): Forward declare.
9657 (tic6x_read_description): New function, based on ...
9658 (tic6x_arch_setup): ... this. Reimplement.
9659 (target_regsets): Rename to ...
9660 (tic6x_regsets): ... this, and make static.
9661 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
9662 (tic6x_regs_info): New function.
9663 (the_low_target): Adjust.
9664 (initialize_low_arch): New function.
9665 * linux-xtensa-low.c (tdesc_xtensa): Declare.
9666 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
9667 (target_regsets): Rename to ...
9668 (xtensa_regsets): ... this, and make static.
9669 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
9670 globals.
9671 (xtensa_arch_setup, xtensa_regs_info): New functions.
9672 (the_low_target): Adjust.
9673 (initialize_low_arch): New function.
9674 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
9675 (nios2_arch_setup): Set the current process'es tdesc.
9676 (target_regsets): Rename to ...
9677 (nios2_regsets): ... this.
9678 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
9679 (nios2_regs_info): New function.
9680 (the_low_target): Adjust.
9681 (initialize_low_arch): New function.
9682 * linux-aarch64-low.c (tdesc_aarch64): Declare.
9683 (aarch64_arch_setup): Set the current process'es tdesc.
9684 (target_regsets): Rename to ...
9685 (aarch64_regsets): ... this.
9686 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
9687 (aarch64_regs_info): New function.
9688 (the_low_target): Adjust.
9689 (initialize_low_arch): New function.
9690 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
9691 globals.
9692 (target_regsets): Rename to ...
9693 (tile_regsets): ... this.
9694 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
9695 (tile_regs_info): New function.
9696 (tile_arch_setup): Set the current process'es tdesc.
9697 (the_low_target): Adjust.
9698 (initialize_low_arch): New function.
9699 * spu-low.c (tdesc_spu): Declare.
9700 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
9701 * win32-arm-low.c (tdesc_arm): Declare.
9702 (arm_arch_setup): New function.
9703 (the_low_target): Install arm_arch_setup instead of
9704 init_registers_arm.
9705 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
9706 (init_windows_x86): Rename to ...
9707 (i386_arch_setup): ... this. Set `win32_tdesc'.
9708 (the_low_target): Adjust.
9709 * win32-low.c (win32_tdesc): New global.
9710 (child_add_thread): Don't create the thread cache here.
9711 (do_initial_child_stuff): Set the new process'es tdesc.
9712 * win32-low.h (struct target_desc): Forward declare.
9713 (win32_tdesc): Declare.
9714 * lynx-i386-low.c (tdesc_i386): Declare global.
9715 (lynx_i386_arch_setup): Set `lynx_tdesc'.
9716 * lynx-low.c (lynx_tdesc): New global.
9717 (lynx_add_process): Set the new process'es tdesc.
9718 * lynx-low.h (struct target_desc): Forward declare.
9719 (lynx_tdesc): Declare global.
9720 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
9721 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
9722 * nto-low.c (nto_tdesc): New global.
9723 (do_attach): Set the new process'es tdesc.
9724 * nto-low.h (struct target_desc): Forward declare.
9725 (nto_tdesc): Declare.
9726 * nto-x86-low.c (tdesc_i386): Declare.
9727 (nto_x86_arch_setup): Set `nto_tdesc'.
9728
9729 2013-06-04 Gary Benson <gbenson@redhat.com>
9730
9731 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
9732 to qSupported response when appropriate.
9733 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
9734 with nonzero-length annex.
9735 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
9736 arguments supplied in annex.
9737
9738 2013-05-31 Doug Evans <dje@google.com>
9739
9740 PR server/15594
9741 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
9742 64 bits in 64-cross-32 environment.
9743
9744 2013-05-28 Pedro Alves <palves@redhat.com>
9745
9746 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
9747 (aarch64-without-fpu.c): Delete rule.
9748 * configure.srv (aarch64*-*-linux*): Remove references to
9749 aarch64-without-fpu.o and aarch64-without-fpu.xml.
9750 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
9751 declaration.
9752
9753 2013-05-24 Pedro Alves <palves@redhat.com>
9754
9755 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
9756 instead of strchr/decode_address. Error if the range isn't split
9757 with a ','. Don't assume there's be a ':' in the action.
9758
9759 2013-05-23 Yao Qi <yao@codesourcery.com>
9760 Pedro Alves <palves@redhat.com>
9761
9762 * linux-low.c (lwp_in_step_range): New function.
9763 (linux_wait_1): If the thread was range stepping and stopped
9764 outside the stepping range, report the stop to GDB. Otherwise,
9765 continue stepping. Add range stepping debug output.
9766 (linux_set_resume_request): Copy the step range from the resume
9767 request to the lwp.
9768 (linux_supports_range_stepping): New.
9769 (linux_target_ops) <supports_range_stepping>: Set to
9770 linux_supports_range_stepping.
9771 * linux-low.h (struct linux_target_ops)
9772 <supports_range_stepping>: New field.
9773 (struct lwp_info) <step_range_start, step_range_end>: New fields.
9774 * linux-x86-low.c (x86_supports_range_stepping): New.
9775 (the_low_target) <supports_range_stepping>: Set to
9776 x86_supports_range_stepping.
9777 * server.c (handle_v_cont): Handle 'r' action.
9778 (handle_v_requests): Append ";r" if the target supports range
9779 stepping.
9780 * target.h (struct thread_resume) <step_range_start,
9781 step_range_end>: New fields.
9782 (struct target_ops) <supports_range_stepping>:
9783 New field.
9784 (target_supports_range_stepping): New macro.
9785
9786 2013-05-17 Joel Brobecker <brobecker@adacore.com>
9787
9788 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
9789 confusion in comment.
9790
9791 2013-05-17 Joel Brobecker <brobecker@adacore.com>
9792
9793 * lynx-low.c (struct process_info_private): New type.
9794 (lynx_add_process): New function.
9795 (lynx_create_inferior, lynx_attach): Replace calls to
9796 add_process by calls to lynx_add_process.
9797 (lynx_resume): If PTID is null, then try using
9798 current_process()->private->last_wait_event_ptid.
9799 Add comments.
9800 (lynx_clear_inferiors): Delete. The contents of that function
9801 has been inlined in lynx_mourn;
9802 (lynx_wait_1): Save the ptid in the process's private data.
9803 (lynx_mourn): Free the process' private data. Replace call
9804 to lynx_clear_inferiors by call to clear_inferiors.
9805
9806 2013-05-17 Yao Qi <yao@codesourcery.com>
9807
9808 * i386-low.c (i386_length_and_rw_bits): Move the comment to
9809 the right place.
9810
9811 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
9812
9813 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
9814 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
9815 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
9816 PT_TEXT_END_ADDR guards. Update comments.
9817 (linux_target_op) <read_offsets>: Conditionally define to
9818 linux_read_offsets if the target is UCLIBC and if it defines
9819 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
9820
9821 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
9822 Andrew Jenner <andrew@codesourcery.com>
9823
9824 * Makefile.in (SFILES): Add linux-nios2-low.c.
9825 (clean): Add action to delete nios2-linux.c.
9826 (nios2-linux.c): New rule.
9827 * configure.srv: Add nios2*-*-linux*.
9828 * linux-nios2-low.c: New.
9829
9830 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
9831
9832 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
9833
9834 2013-04-25 Hui Zhu <hui@codesourcery.com>
9835
9836 PR gdb/15186
9837 * ax.c (ax_printf): Add fflush.
9838
9839 2013-04-22 Tom Tromey <tromey@redhat.com>
9840
9841 * Makefile.in (SFILES): Add filestuff.c.
9842 (OBS): Add filestuff.o.
9843 (filestuff.o): New target.
9844 * config.in, configure: Rebuild.
9845 * configure.ac: Check for fdwalk, pipe2.
9846
9847 2013-04-17 Pedro Alves <palves@redhat.com>
9848
9849 * configure.ac (USE_THREAD_DB): Delete variable.
9850 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
9851 Don't AC_SUBST USE_THREAD_DB.
9852 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
9853 * config.in, configure: Regenerate.
9854
9855 2013-04-16 Pedro Alves <palves@redhat.com>
9856
9857 * linux-low.h (struct lwp_info) <thread_known>: Move under
9858 the USE_THREAD_DB #ifdef.
9859
9860 2013-04-16 Pedro Alves <palves@redhat.com>
9861
9862 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
9863 (linux-low.o): Delete rule.
9864 * linux-low.h: Always include "gdb_thread_db.h" instead of
9865 conditionally including thread_db.h.
9866 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
9867 HAVE_THREAD_DB_H.
9868
9869 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
9870
9871 * Makefile.in (install-only): Fix make install regression.
9872
9873 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
9874
9875 Convert man pages to texinfo, new gdbinit.5 texinfo page.
9876 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
9877 installation.
9878 * gdbserver.1: Remove.
9879
9880 2013-03-22 Pedro Alves <palves@redhat.com>
9881
9882 * linux-low.c (handle_extended_wait): Don't call
9883 linux_enable_event_reporting.
9884
9885 2013-03-15 Tony Theodore <tonyt@logyst.com>
9886
9887 PR build/9098:
9888 * Makefile.in (SHELL): Use @SHELL@.
9889
9890 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
9891
9892 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
9893 compiler warning.
9894
9895 2013-03-13 Joel Brobecker <brobecker@adacore.com>
9896
9897 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
9898 Remove extraneous NULL element.
9899
9900 2013-03-13 Yao Qi <yao@codesourcery.com>
9901
9902 * tracepoint.c (traceframe_read_tsv): Look for the last matched
9903 'V' block in trace frame.
9904
9905 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9906
9907 * target.h (struct target_ops): Add btrace ops.
9908 (target_supports_btrace): New macro.
9909 (target_enable_btrace): New macro.
9910 (target_disable_btrace): New macro.
9911 (target_read_btrace): New macro.
9912 * gdbthread.h (struct thread_info): Add btrace field.
9913 * server.c: Include btrace-common.h.
9914 (handle_btrace_general_set): New function.
9915 (handle_btrace_enable): New function.
9916 (handle_btrace_disable): New function.
9917 (handle_general_set): Call handle_btrace_general_set.
9918 (handle_qxfer_btrace): New function.
9919 (struct qxfer qxfer_packets[]): Add btrace entry.
9920 * inferiors.c (remove_thread): Disable btrace.
9921 * linux-low: Include linux-btrace.h.
9922 (linux_low_enable_btrace): New function.
9923 (linux_low_read_btrace): New function.
9924 (linux_target_ops): Add btrace ops.
9925 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
9926 Add srv_linux_btrace=yes.
9927 (x86_64-*-linux*): Add linux-btrace.o.
9928 Add srv_linux_btrace=yes.
9929 * configure.ac: Define HAVE_LINUX_BTRACE.
9930 * config.in: Regenerated.
9931 * configure: Regenerated.
9932
9933 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9934
9935 * server.c (handle_qxfer): Preserve error message if -3 is
9936 returned.
9937 (qxfer): Document the -3 return value.
9938
9939 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9940
9941 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
9942 (linux_btrace_h): New variable.
9943 (linux-btrace.o): New rule.
9944
9945 2013-03-08 Stan Shebs <stan@codesourcery.com>
9946 Hafiz Abid Qadeer <abidh@codesourcery.com>
9947
9948 * tracepoint.c (trace_buffer_size): New global.
9949 (DEFAULT_TRACE_BUFFER_SIZE): New define.
9950 (init_trace_buffer): Change to one-argument function. Allocate
9951 trace buffer memory.
9952 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
9953 handle QTBuffer:size packet.
9954 (cmd_bigqtbuffer_size): New function.
9955 (initialize_tracepoint): Call init_trace_buffer with
9956 DEFAULT_TRACE_BUFFER_SIZE.
9957 * server.c (handle_query): Add QTBuffer:size in the
9958 supported packets.
9959
9960 2013-03-07 Yao Qi <yao@codesourcery.com>
9961
9962 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
9963 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
9964 of -1.
9965 (cmd_qtsp): Adjust condition. Do post increment.
9966 Set cur_action and cur_step_action back to 0.
9967
9968 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
9969
9970 PR server/15236
9971 * linux-low.c (linux_write_memory): Return early success if LEN is
9972 zero.
9973
9974 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
9975
9976 * configure.srv: Add x86_64-*-cygwin* as target.
9977
9978 2013-02-28 Tom Tromey <tromey@redhat.com>
9979
9980 * configure.ac: Invoke AC_SYS_LARGEFILE.
9981 * configure, config.in: Rebuild.
9982
9983 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
9984
9985 * win32-low.c: Throughout, fix format strings and casts of
9986 printf-like functions to avoid type related warnings on all
9987 platforms.
9988 (get_child_debug_event): Print dwDebugEventCode as hex since
9989 that's how it's usually documented.
9990
9991 2013-02-28 Yao Qi <yao@codesourcery.com>
9992
9993 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
9994 pulongest.
9995
9996 2013-02-27 Jiong Wang <jiwang@tilera.com>
9997
9998 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
9999 (reg-tilegx32.c): New rule.
10000 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
10001 * linux-tile-low.c (tile_arch_setup): New function. Invoke
10002 different register info initializer according to elf class.
10003 (init_registers_tilgx32): New function. The tilegx32 register info
10004 initializer.
10005 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
10006 (tile_store_gregset): Likewise.
10007
10008 2013-02-27 Yao Qi <yao@codesourcery.com>
10009
10010 * server.c (process_point_options): Print debug message when
10011 debug_threads is true.
10012
10013 2013-02-26 Yao Qi <yao@codesourcery.com>
10014
10015 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
10016
10017 2013-02-19 Pedro Alves <palves@redhat.com>
10018 Kai Tietz <ktietz@redhat.com>
10019
10020 PR gdb/15161
10021
10022 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
10023 instead of strtoul to extract address from packet.
10024 (process_serial_event) <'z'>: Likewise.
10025
10026 2013-02-18 Yao Qi <yao@codesourcery.com>
10027
10028 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
10029
10030 2013-02-14 Pedro Alves <palves@redhat.com>
10031
10032 Plug memory leak.
10033
10034 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
10035 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
10036
10037 2013-02-14 Pedro Alves <palves@redhat.com>
10038
10039 * tracepoint.c (cmd_qtdpsrc): Use savestring.
10040
10041 2013-02-14 Pedro Alves <palves@redhat.com>
10042
10043 * tracepoint.c (save_string): Delete.
10044 (add_tracepoint_action): Use savestring instead of save_string.
10045
10046 2013-02-12 Pedro Alves <palves@redhat.com>
10047
10048 * linux-xtensa-low.c: Ditto.
10049 * xtensa-xtregs.c: Ditto.
10050
10051 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
10052
10053 * thread-db.c (thread_db_get_tls_address): NULL pointer check
10054 thread_db.
10055
10056 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
10057
10058 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
10059 aarch64_num_wp_regs and aarch64_num_bp_regs to
10060 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
10061
10062 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
10063
10064 * linux-aarch64-low.c (ps_get_thread_area): Replace
10065 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
10066
10067 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
10068 Marcus Shawcroft <marcus.shawcroft@arm.com>
10069 Nigel Stephens <nigel.stephens@arm.com>
10070 Yufeng Zhang <yufeng.zhang@arm.com>
10071
10072 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
10073 (aarch64.c, aarch64-without-fpu.c): New targets.
10074 * configure.srv (aarch64*-*-linux*): New.
10075 * linux-aarch64-low.c: New file.
10076
10077 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
10078
10079 * linux-low.c (handle_extended_wait, linux_create_inferior)
10080 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
10081 (dequeue_one_deferred_signal, linux_resume_one_thread)
10082 (fetch_register, linux_write_memory, linux_enable_event_reporting)
10083 (linux_tracefork_grandchild, linux_test_for_tracefork)
10084 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
10085 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
10086 where the argument is 0.
10087
10088 2013-01-25 Yao Qi <yao@codesourcery.com>
10089
10090 * event-loop.c: Include "queue.h".
10091 (gdb_event_p): New typedef.
10092 (struct gdb_event) <next_event>: Remove.
10093 (event_queue): Change to QUEUE(gdb_event_p).
10094 (async_queue_event): Remove.
10095 (gdb_event_xfree): New.
10096 (initialize_event_loop): New.
10097 (process_event): Use API from QUEUE.
10098 (wait_for_event): Likewise.
10099 * server.c (main): Call initialize_event_loop.
10100 * server.h (initialize_event_loop): Declare.
10101
10102 2013-01-18 Yao Qi <yao@codesourcery.com>
10103
10104 * ax.h (struct eval_agent_expr_context): New.
10105 (gdb_eval_agent_expr): Update declaration.
10106 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
10107 TFRAME. Add new argument CTX.
10108 * server.h (struct eval_agent_expr_context): Declare.
10109 (agent_mem_read, agent_tsv_read): Update declaration.
10110 (agent_mem_read_string): Likewise.
10111 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
10112 (add_traceframe_block): Add new argument TPOINT.
10113 Increase TPOINT->traceframe_usage.
10114 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
10115 eval_tracepoint_agent_expr.
10116 (condition_true_at_tracepoint): Likewise.
10117 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
10118 (agent_mem_read_string, agent_tsv_read): Likewise.
10119
10120 2013-01-16 Yao Qi <yao@codesourcery.com>
10121
10122 * linux-low.c (linux_resume_one_lwp): Don't check
10123 'lwp->bp_reinsert != 0'.
10124
10125 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10126 Pedro Alves <palves@redhat.com>
10127
10128 * lynx-low.c (ptrace_request_to_str): Define a temporary
10129 macro and use it to simplify this function's implementation.
10130
10131 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10132
10133 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
10134 sets errno.
10135
10136 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10137
10138 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
10139
10140 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10141
10142 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
10143
10144 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10145
10146 * lynx-low.c (lynx_resume): Use the resume_info parameter
10147 to determine the ptid for the lynx_ptrace call, unless
10148 it is equal to minus_one_ptid, in which case we use the
10149 ptid of the current_inferior.
10150 (lynx_wait_1): After having received a thread create/exit
10151 event, resume the inferior's execution using the signaling
10152 thread's ptid, rather than the old ptid.
10153
10154 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10155
10156 * lynx-low.c (lynx_resume): Delete variable ret.
10157
10158 2013-01-01 Joel Brobecker <brobecker@adacore.com>
10159
10160 * gdbreplay.c (gdbreplay_version): Update copyright year.
10161 * server.c (gdbserver_version): Likewise.
10162
10163 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10164
10165 * lynx-low.c (lynx_wait_1): Add debug trace before adding
10166 new thread.
10167
10168 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10169
10170 * lynx-low.c (ptrace_request_to_str): Add handling for
10171 PTRACE_GETTRACESIG.
10172
10173 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10174
10175 * lynx-low.c (lynx_attach): Delete variable new_process.
10176
10177 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10178
10179 * lynx-low.c (lynx_create_inferior): Delete variable
10180 new_process.
10181
10182 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10183
10184 * lynx-low.c (ptrace_request_to_str): Do not handle
10185 PTRACE_GETTHREADLIST if this macro does not exist.
10186
10187 2012-12-15 Yao Qi <yao@codesourcery.com>
10188
10189 * Makefile.in (OBS): Add notif.o.
10190 * notif.c, notif.h: New.
10191 * server.c: Include "notif.h".
10192 (struct vstop_notif) <next>: Remove.
10193 <base>: New field.
10194 (queue_stop_reply): Update.
10195 (push_event, send_next_stop_reply): Remove.
10196 (discard_queued_stop_replies): Update.
10197 (notif_stop): New variable.
10198 (handle_v_stopped): Remove.
10199 (handle_v_requests): Don't call handle_v_stopped. Call
10200 handle_ack_notif instead.
10201 (queue_stop_reply_callback): Call notif_event_enque instead
10202 of queue_stop_reply.
10203 (handle_status): Don't call send_next_stop_reply, call
10204 notif_write_event instead.
10205 (kill_inferior_callback): Likewise.
10206 (detach_or_kill_inferior_callback): Likewise.
10207 (main): Call initialize_notif.
10208 (process_serial_event): Call QUEUE_is_empty.
10209 (handle_target_event): Call notif_push instead of push event.
10210 * server.h (push_event): Remove declaration.
10211
10212 2012-12-10 Tom Tromey <tromey@redhat.com>
10213
10214 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
10215 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
10216 macros.
10217 (.c.o): Rewrite.
10218 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
10219 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
10220 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
10221 (amd64-linux-ipa.o, ax.o): Rewrite.
10222 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
10223 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
10224 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
10225 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
10226 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
10227 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
10228 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
10229 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
10230 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
10231 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
10232 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
10233 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
10234 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
10235 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
10236 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
10237 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
10238 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
10239 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
10240 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
10241 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
10242 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
10243 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
10244 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
10245 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
10246 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
10247 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
10248 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
10249 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
10250 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
10251 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
10252 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
10253 (reg-tilegx.o): Remove.
10254 (all_object_files): New macro.
10255 Include .deps files.
10256 * aclocal.m4, configure: Rebuild.
10257 * acinclude.m4: Include depstand.m4, lead-dot.m4.
10258 * configure.ac: Invoke ZW_CREATE_DEPDIR,
10259 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
10260
10261 2012-12-05 Tom Tromey <tromey@redhat.com>
10262
10263 PR gdb/14917:
10264 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
10265
10266 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
10267
10268 * configure.ac: Check for linux/perf_event.h.
10269 * config.in: Regenerated.
10270 * configure: Regenerated.
10271
10272 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
10273
10274 * hostio.c (handle_readlink): Decrease buffer size
10275 parameter passed to readlink by one byte.
10276
10277 2012-11-26 Yao Qi <yao@codesourcery.com>
10278
10279 * configure.ac (build_warnings): Append '-Wempty-body'.
10280 * configure: Regenerated.
10281 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
10282 body.
10283
10284 2012-11-15 Pierre Muller <muller@sourceware.org>
10285
10286 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
10287 * config.in: Regenerate.
10288 * configure: Regenerate.
10289 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
10290 Use "gdb_wait.h" header instead of <sys/wait.h> header.
10291 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
10292 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
10293 header.
10294 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
10295 instead of <sys/wait.h> header.
10296 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
10297
10298 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
10299
10300 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
10301 (various make rules): Remove -DGDBSERVER
10302
10303 2012-11-09 Yao Qi <yao@codesourcery.com>
10304
10305 * spu-low.c (current_ptid): Move it to ..
10306 * gdbthread.h: ... here. New.
10307 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
10308 * server.c (myresume, process_serial_event): Likewise.
10309 * thread-db.c (thread_db_find_new_threads): Likewise.
10310 * tracepoint.c (run_inferior_command): Likewise.
10311
10312 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
10313
10314 * server.c (handle_search_memory_1): Include access length in
10315 warning message.
10316
10317 2012-09-05 Michael Brandt <michael.brandt@axis.com>
10318
10319 * linux-crisv32-low.c: Fix compile errors.
10320
10321 2012-09-04 Yao Qi <yao@codesourcery.com>
10322
10323 * tracepoint.c (cmd_qtsv): Adjust debug message.
10324 Don't check CUR_TPOINT.
10325
10326 2012-08-28 Yao Qi <yao@codesourcery.com>
10327
10328 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
10329 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
10330 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
10331 Remove declarations of xmalloc, xreallloc, xstrdup and
10332 freeargv.
10333 * Makefile.in (libiberty_h): New.
10334 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
10335 (linux-bfin-low.o): Append dependency 'libiberty.h'.
10336
10337 2012-08-23 Yao Qi <yao@codesourcery.com>
10338
10339 * server.h: Remove declaration of 'xsnprintf'.
10340
10341 2012-08-22 Keith Seitz <keiths@redhat.com>
10342
10343 * server.h: Include build-gnulib-gbserver/config.h.
10344 * gdbreplay.c: Likewise.
10345
10346 2012-08-08 Doug Evans <dje@google.com>
10347
10348 * Makefile.in (SFILES): Add gdb_vecs.c.
10349 (OBS): Add gdb_vecs.o.
10350 (gdb_vecs_h, host_defs_h): New variables.
10351 (thread-db.o): Add $(gdb_vecs_h) dependency.
10352 (gdb_vecs.o): New rule.
10353 * thread-db.c: #include "gdb_vecs.h".
10354 (thread_db_load_search): Use a vector to iterate over path elements.
10355 Handle text appearing after "$pdir".
10356
10357 * configure.ac: Add check for strstr.
10358 * config.in: Regenerate.
10359 * configure: Regenerate.
10360
10361 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
10362
10363 * hostio.c (handle_pread): If pread fails, fall back to attempting
10364 lseek/read.
10365 (handle_pwrite): Likewise for pwrite.
10366
10367 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
10368
10369 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
10370 between unsupported TYPE and unimplementable ADDR/LEN combination.
10371 (arm_insert_point): Act on new return value.
10372
10373 2012-07-31 Pedro Alves <palves@redhat.com>
10374
10375 * server.c (process_point_options): Only skip tokens if we find
10376 one that is unrecognized. Don't treat 'X' specially while
10377 skipping unrecognized tokens.
10378
10379 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
10380
10381 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
10382 to 4-byte-align HW breakpoint addresses for Thumb.
10383
10384 2012-07-27 Yao Qi <yao@codesourcery.com>
10385
10386 PR remote/14161.
10387
10388 * server.h: Declare gdb_agent_about_to_close.
10389 * target.c (kill_inferior): Include "agent.h".
10390 New. Send command 'kill'.
10391 * target.h (kill_inferior): Removed macro.
10392 * tracepoint.c (gdb_agent_about_to_close): New.
10393 (gdb_agent_helper_thread): Handle command 'close'.
10394 Wait endlessly until the inferior stops.
10395 Install gdb_agent_remove_socket to atexit hook.
10396 (agent_socket_name): New static variable.
10397 (gdb_agent_socket_init): Replace local variable 'name' with
10398 'agent_socket_name'.
10399 (gdb_agent_remove_socket): New.
10400
10401 2012-07-27 Yao Qi <yao@codesourcery.com>
10402
10403 * server.c (process_point_options): Stop at 'X' when parsing.
10404
10405 2012-07-19 Michael Eager <eager@eagercon.com>
10406
10407 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
10408 to hw_execute.
10409 * linux-x86-low.c (x86_insert_point, x86_remove_point):
10410 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
10411 hardware breakpoint.
10412
10413 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
10414
10415 * gdbserver/linux-low.c (initialize_low): Call
10416 linux_ptrace_init_warnings.
10417
10418 2012-07-02 Doug Evans <dje@google.com>
10419
10420 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
10421 pointer to int.
10422
10423 2012-07-02 Stan Shebs <stan@codesourcery.com>
10424
10425 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
10426 (ax.o): Add it to build rule.
10427 (ax-ipa.o): Ditto.
10428 (OBS): Add format.o.
10429 (IPA_OBS): Add format.o.
10430 * server.c (handle_query): Claim support for breakpoint commands.
10431 (process_point_options): Add command case.
10432 (process_serial_event): Leave running if there are printfs in
10433 effect.
10434 * mem-break.h (any_persistent_commands): Declare.
10435 (add_breakpoint_commands): Declare.
10436 (gdb_no_commands_at_breakpoint): Declare.
10437 (run_breakpoint_commands): Declare.
10438 * mem-break.c (struct point_command_list): New struct.
10439 (struct breakpoint): New field command_list.
10440 (any_persistent_commands): New function.
10441 (add_commands_to_breakpoint): New function.
10442 (add_breakpoint_commands): New function.
10443 (gdb_no_commands_at_breakpoint): New function.
10444 (run_breakpoint_commands): New function.
10445 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
10446 locally.
10447 * ax.c: Include format.h.
10448 (ax_printf): New function.
10449 (gdb_eval_agent_expr): Add printf opcode.
10450
10451 2012-06-13 Yao Qi <yao@codesourcery.com>
10452
10453 * server.c (start_inferior): Remove duplicated writes to fields
10454 'last_resume_kind' and 'last_status' of 'current_inferior'.
10455
10456 2012-06-12 Yao Qi <yao@codesourcery.com>
10457 Pedro Alves <palves@redhat.com>
10458
10459 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
10460 comment.
10461 * server.c (handle_v_cont): Extend comment.
10462
10463 2012-06-11 Yao Qi <yao@codesourcery.com>
10464
10465 * linux-low.c (linux_attach): Add 'static'.
10466
10467 2012-06-06 Yao Qi <yao@codesourcery.com>
10468
10469 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
10470
10471 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
10472
10473 Fix gcc -flto compilation warning.
10474 * server.c (main): Make variable multi_mode and attach volatile.
10475
10476 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10477
10478 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
10479 if the platform doesn't know about it.
10480
10481 2012-05-30 Jeff Kenton <jkenton@tilera.com>
10482
10483 * Makefile.in (SFILES): Add linux-tile-low.c.
10484 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
10485 * configure.srv: Handle tilegx-*-linux*.
10486 * linux-tile-low.c: New file.
10487
10488 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
10489
10490 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
10491
10492 2012-05-24 Pedro Alves <palves@redhat.com>
10493
10494 PR gdb/7205
10495
10496 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
10497
10498 2012-05-24 Pedro Alves <palves@redhat.com>
10499
10500 PR gdb/7205
10501
10502 Replace target_signal with gdb_signal throughout.
10503
10504 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
10505
10506 * linux-low.c (linux_store_registers): Avoid the copying sequence
10507 when no data has been retrieved by ptrace.
10508
10509 2012-05-22 Will Deacon <will.deacon@arm.com>
10510
10511 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
10512 Include asm/ptrace.h.
10513 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
10514 already defined.
10515
10516 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
10517
10518 * linux-low.c (linux_store_registers): Don't re-retrieve data
10519 with ptrace that has already been obtained from /proc. Always
10520 copy any data retrieved with ptrace to the buffer supplied.
10521
10522 2012-05-11 Yao Qi <yao@codesourcery.com>
10523 Pedro Alves <palves@redhat.com>
10524
10525 * linux-low.c (enum stopping_threads_kind): New.
10526 (stopping_threads): Change type to `enum stopping_threads_kind'.
10527 (handle_extended_wait): If stopping and suspending threads, leave
10528 the new_lwp suspended too.
10529 (linux_wait_for_event): Adjust.
10530 (stop_all_lwps): Set `stopping_threads' to
10531 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
10532 whether we're suspending threads or just stopping them. Assert no
10533 recursion happens.
10534
10535 2012-04-29 Yao Qi <yao@codesourcery.com>
10536
10537 * server.h: Move some code to ...
10538 * gdbthread.h: ... here. New.
10539 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
10540 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
10541 (nto-low.o, win32-low.o): Likewise.
10542 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
10543 * regcache.c, remote-utils.c, server.c: Likewise.
10544 * target.c, tracepoint.c, win32-low.c: Likewise.
10545
10546 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10547
10548 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
10549 (PTRACE_ARG4_TYPE): Likewise.
10550 (PTRACE_XFER_TYPE): Likewise.
10551 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
10552 ptrace to PTRACE_ARG3_TYPE.
10553 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
10554 (PTRACE_ARG4_TYPE): Likewise.
10555 (PTRACE_XFER_TYPE): Likewise.
10556 (linux_detach_one_lwp): Cast fourth argument of
10557 ptrace to long then PTRACE_ARG4_TYPE.
10558 (regsets_fetch_inferior_registers): Cast third argument of
10559 ptrace to long then PTRACE_ARG3_TYPE.
10560 (regsets_store_inferior_registers): Likewise.
10561
10562 2012-04-20 Pedro Alves <palves@redhat.com>
10563
10564 * configure: Regenerate.
10565
10566 2012-04-19 Pedro Alves <palves@redhat.com>
10567
10568 * Makefile.in (GNULIB_BUILDDIR): New.
10569 (LIBGNU, INCGNU, GNULIB_H): Adjust.
10570 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
10571 (all, install-only, uninstall, clean-info, all-lib, clean): No
10572 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
10573 (maintainer-clean realclean distclean): Use subdir_do.
10574 (subdir_do): New.
10575 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
10576 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
10577 * acinclude.m4: Include acx_configure_dir.m4.
10578 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
10579 calls. Call AC_PROG_RANLIB. Configure gnulib using
10580 ACX_CONFIGURE_DIR.
10581 (GNULIB): New.
10582 (GNULIB_STDINT_H): Adjust.
10583 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
10584 * gdbreplay.c: Include build-gnulib/config.h.
10585 * server.h: Likewise.
10586 * aclocal.m4: Regenerate.
10587 * config.in: Regenerate.
10588 * configure: Regenerate.
10589
10590 2012-04-19 Pedro Alves <palves@redhat.com>
10591
10592 * Makefile.in (LIBGNU, INCGNU): Adjust.
10593 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
10594 (all, install-only, uninstall, clean-info, all-lib, clean)
10595 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
10596 * configure.ac: Adjust AC_OUTPUT output.
10597 * aclocal.m4: Regenerate.
10598 * configure: Regenerate.
10599
10600 2012-04-19 Pedro Alves <palves@redhat.com>
10601
10602 * Makefile.in (generated_files): New.
10603 (server_h): Remove the explicit dependency on config.h, and depend
10604 on $generated_files.
10605
10606 2012-04-19 Pedro Alves <palves@redhat.com>
10607
10608 * Makefile.in (INCGNU): Add -Ignulib.
10609
10610 2012-04-19 Pedro Alves <palves@redhat.com>
10611
10612 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
10613 (INCGNU): ... this, and spell out -I here.
10614 (GNULIB_LIB): Rename to ...
10615 (LIBGNU): ... this.
10616 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
10617
10618 2012-04-19 Pedro Alves <palves@redhat.com>
10619
10620 * config.in: Regenerate.
10621
10622 2012-04-19 Pedro Alves <palves@redhat.com>
10623
10624 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
10625 * server.h (memmem): Remove declaration.
10626 * config.in: Regenerate.
10627 * configure: Regenerate.
10628
10629 2012-04-19 Yao Qi <yao@codesourcery.com>
10630
10631 * Makefile.in (SFILES): Add common/vec.c.
10632 (OBS): Add vec.o.
10633 (vec.o): New rule.
10634
10635 2012-04-19 Yao Qi <yao@codesourcery.com>
10636
10637 * remote-utils.c (prepare_resume_reply): Replace with macro
10638 target_core_of_thread.
10639 * server.c (handle_qxfer_threads_proper): Likewise.
10640 * target.h (traget_core_of_thread): New macro.
10641
10642 2012-04-18 Pedro Alves <palves@redhat.com>
10643
10644 * aclocal.m4: Regenerate.
10645 * configure: Regenerate.
10646
10647 2012-04-16 Yao Qi <yao@codesourcery.com>
10648
10649 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
10650 duplicated on address.
10651
10652 2012-04-16 Yao Qi <yao@codesourcery.com>
10653
10654 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
10655 (struct tracepoint_action_ops) <send>: New field.
10656 (m_tracepoint_action_send, r_tracepoint_action_send): New.
10657 (agent_expr_send, x_tracepoint_action_send): New.
10658 (l_tracepoint_action_send): New.
10659 (cmd_qtdp): Download and install tracepoint
10660 according to `use_agent'.
10661 (run_inferior_command): Add one more parameter `len'.
10662 Update callers.
10663 (tracepoint_send_agent): New.
10664 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
10665
10666 2012-04-16 Yao Qi <yao@codesourcery.com>
10667
10668 * tracepoint.c (download_tracepoints): Moved to ...
10669 (cmd_qtstart): ... here.
10670
10671 2012-04-14 Yao Qi <yao@codesourcery.com>
10672
10673 * tracepoint.c: Include inttypes.h.
10674 (struct collect_memory_action): Use sized types.
10675 (struct tracepoint): Likewise.
10676 (cmd_qtdp, stop_tracing): Update print specifiers.
10677 (cmd_qtp, response_tracepoint): Likewise.
10678 (collect_data_at_tracepoint): Likewise.
10679 (collect_data_at_step): Likewise.
10680
10681 2012-04-14 Yao Qi <yao@codesourcery.com>
10682
10683 Import gnulib module inttypes.
10684 * aclocal.m4, config.in, configure: Regenerated.
10685
10686 2012-04-14 Yao Qi <yao@codesourcery.com>
10687
10688 * Makefile.in (maintainer-clean, realclean, distclean): Remove
10689 Makefile and config.status at last.
10690
10691 2012-04-13 Yao Qi <yao@codesourcery.com>
10692
10693 * tracepoint.c: Include stdint.h unconditionally.
10694
10695 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10696
10697 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
10698 on BFD_HAVE_SYS_PROCFS_TYPE.
10699 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
10700 * configure: Regenerate.
10701 * config.in: Likewise.
10702
10703 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
10704
10705 * Makefile.in (clean): Also remove x32.c x32-linux.c
10706 x32-avx.c x32-avx-linux.c.
10707 (x32.o): New target.
10708 (x32.c): Likewise.
10709 (x32-linux.o): Likewise.
10710 (x32-linux.c): Likewise.
10711 (x32-avx.o): Likewise.
10712 (x32-avx.c): Likewise.
10713 (x32-avx-linux.o): Likewise.
10714 (x32-avx-linux.c): Likewise.
10715
10716 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
10717 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
10718 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
10719 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
10720 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
10721 i386/x32-avx-linux.xml.
10722
10723 * linux-x86-low.c (init_registers_x32_linux): New prototype.
10724 (init_registers_x32_avx_linux): Likwise.
10725 (x86_linux_update_xmltarget): Call init_registers_x32_linux
10726 or init_registers_x32_avx_linux if linux_is_elf64 is false.
10727
10728 2012-04-13 Pedro Alves <palves@redhat.com>
10729
10730 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
10731 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
10732 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
10733 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
10734 the sub-make.
10735
10736 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
10737
10738 * linux-x86-low.c (compat_x32_clock_t): New.
10739 (compat_x32_siginfo_t): Likewise.
10740 (compat_x32_siginfo_from_siginfo): Likewise.
10741 (siginfo_from_compat_x32_siginfo): Likewise.
10742 (linux_is_elf64): Likewise.
10743 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
10744 and siginfo_from_compat_x32_siginfo for x32.
10745 (x86_arch_setup): Set linux_is_elf64.
10746
10747 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
10748
10749 PR gdb/13969
10750 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
10751 e_machine field.
10752 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
10753 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
10754 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
10755 compatible with process.
10756
10757 2012-04-12 Yao Qi <yao@codesourcery.com>
10758
10759 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
10760 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
10761 (install-only, install-info, clean): Handle sub dir gnulib.
10762 (all-lib, am--refresh): New targets.
10763 (memmem.o): Remove target.
10764 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
10765 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
10766 (AC_REPLACE_FUNCS): Remove memmem.
10767 Invoke gl_INIT and AM_INIT_AUTOMAKE.
10768 (AC_OUTPUT): Generate Makefile in gnulib/.
10769 * aclocal.m4, config.in, configure: Regenerated.
10770
10771 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
10772
10773 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
10774
10775 2012-04-05 Pedro Alves <palves@redhat.com>
10776
10777 -Werror=strict-aliasing
10778
10779 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
10780 pointer.
10781
10782 2012-04-04 Pedro Alves <palves@redhat.com>
10783
10784 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
10785 (sparc_store_gregset_from_stack, sparc_store_gregset)
10786 (sparc_breakpoint_at): Fix formatting.
10787
10788 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10789
10790 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
10791 are available.
10792 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
10793 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
10794 * config.in: Regenerate.
10795 * configure: Likewise.
10796
10797 2012-03-29 Pedro Alves <palves@redhat.com>
10798
10799 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
10800 Correct ptrace arguments.
10801
10802 2012-03-28 Pedro Alves <palves@redhat.com>
10803
10804 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
10805 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
10806 (IA64_FR1_REGNUM): New defines.
10807 (ia64_fetch_register): New.
10808 (the_low_target): Install it.
10809 * linux-low.h (struct linux_target_ops) <fetch_register>: New
10810 field.
10811 * linux-low.c (linux_fetch_registers): Try the
10812 the_low_target.fetch_register hook first.
10813
10814 * linux-arm-low.c (the_low_target): Adjust.
10815 * linux-bfin-low.c (the_low_target): Adjust.
10816 * linux-cris-low.c (the_low_target): Adjust.
10817 * linux-crisv32-low.c (the_low_target): Adjust.
10818 * linux-m32r-low.c (the_low_target): Adjust.
10819 * linux-m68k-low.c (the_low_target): Adjust.
10820 * linux-mips-low.c (the_low_target): Adjust.
10821 * linux-ppc-low.c (the_low_target): Adjust.
10822 * linux-s390-low.c (the_low_target): Adjust.
10823 * linux-sh-low.c (the_low_target): Adjust.
10824 * linux-sparc-low.c (the_low_target): Adjust.
10825 * linux-tic6x-low.c (the_low_target): Adjust.
10826 * linux-x86-low.c (the_low_target): Adjust.
10827 * linux-xtensa-low.c (the_low_target): Adjust.
10828
10829 2012-03-26 Pedro Alves <palves@redhat.com>
10830
10831 * server.c (handle_qxfer_libraries): Don't bail early if
10832 the_target->qxfer_libraries_svr4 is not NULL.
10833
10834 2012-03-26 Pedro Alves <palves@redhat.com>
10835
10836 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
10837
10838 2012-03-23 Pedro Alves <palves@redhat.com>
10839
10840 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
10841 "library-list-svr4" element's start tag when the the DSO list is
10842 empty.
10843
10844 2012-03-23 Pedro Alves <palves@redhat.com>
10845
10846 * linux-low.c (read_one_ptr): Read the inferior's pointer through
10847 a variable whose type size is the same as the inferior's pointer
10848 size.
10849
10850 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
10851
10852 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
10853 struct siginfo.
10854 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
10855 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
10856 * linux-low.h: Include <signal.h>.
10857 (struct siginfo): Remove forward declaration.
10858 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
10859 struct siginfo.
10860
10861 2012-03-21 Mike Frysinger <vapier@gentoo.org>
10862
10863 * .gitignore: Ignore more files.
10864
10865 2012-03-19 Pedro Alves <palves@redhat.com>
10866 Jan Kratochvil <jan.kratochvil@redhat.com>
10867
10868 * server.c (cont_thread, general_thread): Add describing comments.
10869 (start_inferior): Clear `cont_thread'.
10870 (handle_v_cont): Don't set `cont_thread' if resuming all threads
10871 of a process.
10872
10873 2012-03-15 Yao Qi <yao@codesourcery.com>
10874
10875 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
10876 handling to ...
10877 (cmd_qtdp): ... here.
10878
10879 2012-03-15 Yao Qi <yao@codesourcery.com>
10880
10881 * tracepoint.c (struct tracepoint_action_ops): New.
10882 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
10883 (m_tracepoint_action_download): New.
10884 (r_tracepoint_action_download): New.
10885 (x_tracepoint_action_download): New.
10886 (l_tracepoint_action_download): New.
10887 (add_tracepoint_action): Install `action->ops' according type.
10888 (download_tracepoint_1): Move code `download' function pointer
10889 of various tracepoint_action_ops.
10890
10891 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
10892
10893 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
10894 linux_ptrace_attach_warnings.
10895
10896 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
10897
10898 * Makefile.in (linux-ptrace.o): New.
10899 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
10900 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
10901 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
10902 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
10903 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
10904 of these targets.
10905 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
10906
10907 2012-03-08 Yao Qi <yao@codesourcery.com>
10908 Pedro Alves <palves@redhat.com>
10909
10910 Fix PR server/13392.
10911 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
10912 offset of JMP insn.
10913 * tracepoint.c (remove_tracepoint): New.
10914 (cmd_qtdp): Call remove_tracepoint when failed to install.
10915
10916 2012-03-07 Pedro Alves <palves@redhat.com>
10917
10918 * linux-low.c (get_detach_signal): New.
10919 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
10920 Pass on pending signals to PTRACE_DETACH. Check the result of the
10921 ptrace call.
10922 * server.c (program_signals, program_signals_p): New.
10923 (handle_general_set): Handle QProgramSignals.
10924 * server.h (program_signals, program_signals_p): Declare.
10925
10926 2012-03-05 Pedro Alves <palves@redhat.com>
10927 Jan Kratochvil <jan.kratochvil@redhat.com>
10928
10929 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
10930 New comment why.
10931
10932 2012-03-03 Yao Qi <yao@codesourcery.com>
10933
10934 * tracepoint.c (tracepoint_look_up_symbols): Update call to
10935 agent_look_up_symbols.
10936
10937 2012-03-03 Yao Qi <yao@codesourcery.com>
10938
10939 * Makefile.in (linux-low.o): Keep dependence on agent.h.
10940 (linux-x86-low.o): Likewise.
10941 * server.h: Remove in_process_agent_loaded.
10942 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
10943 common/agent.c.
10944 Update callers.
10945
10946 2012-03-03 Yao Qi <yao@codesourcery.com>
10947
10948 * tracepoint.c (gdb_agent_capability): New global.
10949 (in_process_agent_loaded_ust): Renamed to
10950 `in_process_agent_supports_ust'.
10951 Update callers.
10952 (in_process_agent_supports_ust): Call agent_capability_check.
10953 (clear_installed_tracepoints): Assert that agent supports
10954 agent.
10955
10956 2012-03-03 Yao Qi <yao@codesourcery.com>
10957
10958 * linux-low.c (linux_supports_agent): New.
10959 (linux_target_ops): Initialize field `supports_agent' with
10960 linux_supports_agent.
10961 * target.h (struct target_ops) <supports_agent>: New.
10962 (target_supports_agent): New macro.
10963 * server.c (handle_general_set): Handle packet 'QAgent'.
10964 (handle_query): Send `QAgent+'.
10965 * Makefile.in (server.o): Depends on agent.h.
10966
10967 2012-03-03 Yao Qi <yao@codesourcery.com>
10968
10969 * Makefile.in (OBS): Add agent.o.
10970 Add new rule for agent.o.
10971 Track dependence of tracepoint.c on agent.h.
10972 * tracepoint.c (run_inferior_command_1):
10973 (run_inferior_command): Call agent_run_command.
10974 (gdb_ust_connect_sync_socket): Deleted. Move it to
10975 common/agent.c.
10976 (resume_thread, stop_thread): Likewise.
10977 (gdb_ust_socket_init): Renamed to ...
10978 (gdb_agent_socket_init): ... New.
10979 (gdb_ust_thread): Renamed to ...
10980 (gdb_agent_helper_thread): ... New.
10981 (gdb_ust_init): Move some code to ...
10982 (gdb_agent_init): ... here. New.
10983 [HAVE_UST]: Call gdb_ust_init.
10984 (initialize_tracepoint_ftlib): Call gdb_agent_init.
10985 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
10986 * config.in, configure: Regenerated.
10987
10988 2012-03-02 Pedro Alves <palves@redhat.com>
10989
10990 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
10991 * linux-low.c (struct simple_pid_list): New.
10992 (stopped_pids): New a struct simple_pid_list pointer.
10993 (add_to_pid_list, pull_pid_from_list): New.
10994 (handle_extended_wait): Don't assume the first signal new children
10995 report is SIGSTOP. Adjust call to pull_pid_from_list.
10996 (linux_wait_for_lwp): Adjust.
10997
10998 2012-03-02 Yao Qi <yao@codesourcery.com>
10999
11000 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
11001 debug log.
11002
11003 2012-03-02 Yao Qi <yao@codesourcery.com>
11004
11005 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
11006 `stop_pc' and `tpoint'. Update caller.
11007
11008 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
11009
11010 * linux-low.h (linux_target_ops): Add regset_bitmap member.
11011 * linux-low.c (use_linux_regsets): New macro.
11012 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
11013 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
11014 (linux_register_in_regsets): New function.
11015 (usr_fetch_inferior_registers): Skip registers covered by
11016 regsets.
11017 (usr_store_inferior_registers): Likewise.
11018 (usr_fetch_inferior_registers): New macro.
11019 (usr_store_inferior_registers): Likewise.
11020 (linux_fetch_registers): Handle mixed regset/non-regset targets.
11021 (linux_store_registers): Likewise.
11022 * linux-mips-low.c (init_registers_mips_dsp_linux): New
11023 prototype.
11024 (init_registers_mips64_dsp_linux): Likewise.
11025 (init_registers_mips_linux): New macro.
11026 (init_registers_mips_dsp_linux): Likewise.
11027 (mips_dsp_num_regs): Likewise.
11028 (DSP_BASE, DSP_CONTROL): New fallback macros.
11029 (mips_base_regs): New macro.
11030 (mips_regmap): Use it. Fix the size.
11031 (mips_dsp_regmap): New variable.
11032 (mips_dsp_regset_bitmap): Likewise.
11033 (mips_arch_setup): New function.
11034 (mips_cannot_fetch_register): Use the_low_target.regmap rather
11035 than mips_regmap.
11036 (mips_cannot_store_register): Likewise.
11037 (the_low_target): Update .arch_setup, .num_regs and .regmap
11038 initializers. Add .regset_bitmap initializer.
11039 * linux-arm-low.c (the_low_target): Add .regset_bitmap
11040 initializer.
11041 * linux-bfin-low.c (the_low_target): Likewise.
11042 * linux-cris-low.c (the_low_target): Likewise.
11043 * linux-crisv32-low.c (the_low_target): Likewise.
11044 * linux-ia64-low.c (the_low_target): Likewise.
11045 * linux-m32r-low.c (the_low_target): Likewise.
11046 * linux-m68k-low.c (the_low_target): Likewise.
11047 * linux-ppc-low.c (the_low_target): Likewise.
11048 * linux-s390-low.c (the_low_target): Likewise.
11049 * linux-sh-low.c (the_low_target): Likewise.
11050 * linux-sparc-low.c (the_low_target): Likewise.
11051 * linux-tic6x-low.c (the_low_target): Likewise.
11052 * linux-x86-low.c (the_low_target): Likewise.
11053 * linux-xtensa-low.c (the_low_target): Likewise.
11054 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
11055 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
11056 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
11057 srv_xmlfiles.
11058 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
11059 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
11060
11061 2012-02-29 Yao Qi <yao@codesourcery.com>
11062 Pedro Alves <palves@redhat.com>
11063
11064 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
11065 `step_over_finished' is true.
11066
11067 2012-02-27 Pedro Alves <palves@redhat.com>
11068
11069 * linux-low.c (pid_is_stopped): Delete, moved to common/.
11070 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
11071
11072 2012-02-27 Pedro Alves <palves@redhat.com>
11073
11074 PR server/9684
11075 * linux-low.c (pid_is_stopped): New.
11076 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
11077
11078 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
11079
11080 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
11081 of conditions.
11082
11083 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
11084
11085 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
11086
11087 2012-02-24 Luis Machado <lgustavo@codesourcery>
11088
11089 * server.c (handle_query): Advertise support for target-side
11090 breakpoint condition evaluation.
11091 (process_point_options): New function.
11092 (process_serial_event): When inserting a breakpoint, check for
11093 a target-side condition that should be evaluated.
11094
11095 * mem-break.c: Include regcache.h and ax.h.
11096 (point_cond_list_t): New data structure.
11097 (breakpoint) <cond_list>: New field.
11098 (find_gdb_breakpoint_at): Make non-static.
11099 (delete_gdb_breakpoint_at): Clear any target-side
11100 conditions.
11101 (clear_gdb_breakpoint_conditions): New function.
11102 (add_condition_to_breakpoint): Likewise.
11103 (add_breakpoint_condition): Likewise.
11104 (gdb_condition_true_at_breakpoint): Likewise.
11105 (gdb_breakpoint_here): Return result directly instead
11106 of going through a local variable.
11107
11108 * mem-break.h (find_gdb_breakpoint_at): New prototype.
11109 (clear_gdb_breakpoint_conditions): Likewise.
11110 (add_breakpoint_condition): Likewise.
11111 (gdb_condition_true_at_breakpoint): Likewise.
11112
11113 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
11114 (need_step_over_p): Take target-side breakpoint condition into
11115 consideration.
11116
11117 2012-02-24 Luis Machado <lgustavo@codesourcery>
11118
11119 * server.h: Include tracepoint.h.
11120 (agent_mem_read, agent_get_trace_state_variable_value,
11121 agent_set_trace_state_variable_value,
11122 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
11123 get_set_tsv_func_addr): New prototypes.
11124
11125 * ax.h: New include file.
11126 * ax.c: New source file.
11127
11128 * tracepoint.c: Include ax.h.
11129 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
11130 agent_expr, eval_result_type): Move to ax.h.
11131 (parse_agent_expr): Rename to ...
11132 (gdb_parse_agent_expr): ... this, make it non-static and move
11133 to ax.h.
11134 (unparse_agent_expr) Rename to ...
11135 (gdb_unparse_agent_expr): ... this, make it non-static and move
11136 to ax.h.
11137 (eval_agent_expr): Rename to ...
11138 (eval_tracepoint_agent_expr): ... this.
11139 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
11140 forward declarations.
11141 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
11142 (agent_get_trace_state_variable_value): New function.
11143 (agent_set_trace_state_variable_value): New function.
11144 (cmd_qtdp): Call gdb_parse_agent_expr (...).
11145 (response_tracepoint): Call gdb_unparse_agent_expr (...).
11146 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
11147 (condition_true_at_tracepoint): Likewise.
11148 (parse_agent_expr): Rename to ...
11149 (gdb_parse_agent_expr): ... this and move to ax.c.
11150 (unparse_agent_expr): Rename to ...
11151 (gdb_unparse_agent_expr): ... this and move to ax.c.
11152 (gdb_agent_op_name): Move to ax.c.
11153 (eval_agent_expr): Rename to ...
11154 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
11155 and move to ax.c.
11156 (eval_tracepoint_agent_expr): New function.
11157 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
11158 non-static.
11159 (current_insn_ptr, emit_error, struct bytecode_address): Move to
11160 ax.c.
11161 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
11162 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
11163 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
11164 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
11165 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
11166 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
11167 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
11168 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
11169 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
11170 (compile_bytecodes): Remove forward declaration.
11171 (is_goto_target): Move to ax.c.
11172 (compile_bytecodes): Move to ax.c and call
11173 agent_get_trace_state_variable_value (...) and
11174 agent_set_trace_state_variable_value (...).
11175
11176 * Makefile.in: Update ax.c and IPA dependencies.
11177
11178 2012-02-24 Pedro Alves <palves@redhat.com>
11179
11180 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
11181 (cmd_bigqtbuffer_circular): ... this. Only handle
11182 'QTBuffer:circular:'.
11183 (handle_tracepoint_general_set): Adjust.
11184
11185 2012-02-16 Yao Qi <yao@codesourcery.com>
11186
11187 * inferiors.c: Move code to ...
11188 * dll.c: .... here. New.
11189 * server.h: Declare clear_dlls.
11190 * Makefile.in (SFILES): Add dll.c.
11191 (OBS): Add dll.o
11192 (dll.o): New rule.
11193
11194 2012-02-11 Yao Qi <yao@codesourcery.com>
11195
11196 * server.c: (handle_monitor_command): Add a new parameter
11197 `own_buf'.
11198 (handle_query): Update caller.
11199
11200 2012-02-09 Joel Brobecker <brobecker@adacore.com>
11201
11202 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
11203 * configure, config.in: Regenerate.
11204 * hostio.c: Provide an alternate implementation if HAVE_READLINK
11205 is not defined.
11206
11207 2012-02-02 Pedro Alves <palves@redhat.com>
11208
11209 Try SIGKILL first, then PTRACE_KILL.
11210 * linux-low.c (linux_kill_one_lwp): New.
11211 (linux_kill_one_lwp): Rename to ...
11212 (kill_one_lwp_callback): ... this. Use the new
11213 linux_kill_one_lwp.
11214
11215 2012-02-02 Pedro Alves <palves@redhat.com>
11216
11217 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
11218 inferior.
11219
11220 2012-01-27 Pedro Alves <palves@redhat.com>
11221
11222 * linux-low.c (linux_child_pid_to_exec_file): Delete.
11223 (elf_64_file_p): Make static.
11224 (linux_pid_exe_is_elf_64_file): New.
11225 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
11226 Delete declarations.
11227 (linux_pid_exe_is_elf_64_file): Declare.
11228 * linux-x86-low.c (x86_arch_setup): Use
11229 linux_pid_exe_is_elf_64_file.
11230
11231 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
11232
11233 * linux-low.c (linux_wait_for_event_1): Rename to ...
11234 (linux_wait_for_event): ... here and merge it with former
11235 linux_wait_for_event - new variable wait_ptid, use it.
11236 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
11237
11238 2012-01-23 Pedro Alves <palves@redhat.com>
11239
11240 * server.c (main): Avoid yet another case of infinite loop while
11241 detaching/killing after a longjmp.
11242
11243 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
11244
11245 Code cleanup.
11246 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
11247
11248 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
11249
11250 * hostio.c (handle_readlink): New function.
11251 (handle_vFile): Call it to handle "vFile:readlink" packets.
11252
11253 2012-01-20 Pedro Alves <palves@redhat.com>
11254 Ulrich Weigand <ulrich.weigand@linaro.org>
11255
11256 * server.c (handle_v_requests): Only support vAttach and vRun to
11257 start multiple processes when in extended protocol mode.
11258
11259 2012-01-17 Pedro Alves <palves@redhat.com>
11260
11261 * tracepoint.c (initialize_tracepoint): Use mmap instead of
11262 memalign plus mprotect to allocate the scratch buffer.
11263
11264 2012-01-13 Pedro Alves <palves@redhat.com>
11265
11266 * server.c (attach_inferior): Clear `cont_thread'.
11267
11268 2012-01-13 Pedro Alves <palves@redhat.com>
11269
11270 * server.c (main): Avoid infinite loop while detaching/killing
11271 after a longjmp.
11272
11273 2012-01-09 Doug Evans <dje@google.com>
11274
11275 * server.c (start_inferior): Set last_ptid in --wrapper case.
11276
11277 2012-01-06 Yao Qi <yao@codesourcery.com>
11278
11279 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
11280 defined.
11281 [IN_PROCESS_AGENT] (debug_agent): New global variable.
11282
11283 2012-01-04 Yao Qi <yao@codesourcery.com>
11284
11285 * tracepoint.c (cmd_qtdp): Print debug message
11286 for static tracepoint.
11287
11288 2012-01-04 Yao Qi <yao@codesourcery.com>
11289
11290 * tracepoint.c (trace_vdebug): Differentiate debug message
11291 between gdbserver and IPA.
11292
11293 2012-01-03 Yao Qi <yao@codesourcery.com>
11294
11295 * tracepoint.c (tracepoint_was_hit): Don't collect for
11296 static tracepoint.
11297
11298 2012-01-02 Joel Brobecker <brobecker@adacore.com>
11299
11300 * terminal.h: Reformat copyright header.
11301
11302 2012-01-02 Joel Brobecker <brobecker@adacore.com>
11303
11304 * server.c (gdbserver_version): Update copyright year.
11305 * gdbreplay.c (gdbreplay_version): Likewise.
11306
11307 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
11308
11309 * linux-low.c (linux_create_inferior): Put empty if clause for write.
11310
11311 Revert:
11312 2011-12-18 Hui Zhu <teawater@gmail.com>
11313 * linux-low.c (linux_create_inferior): Save return value to ret.
11314
11315 2011-12-18 Hui Zhu <teawater@gmail.com>
11316
11317 * linux-low.c (linux_create_inferior): Save return value to ret.
11318
11319 2011-12-16 Doug Evans <dje@google.com>
11320
11321 * linux-low.c (linux_create_inferior): If stdio connection,
11322 redirect stdin from /dev/null, stdout to stderr.
11323 * remote-utils.c (remote_is_stdio): New static global.
11324 (remote_connection_is_stdio): New function.
11325 (remote_prepare): Handle stdio connection.
11326 (remote_open): Ditto.
11327 (remote_close): Don't close stdin for stdio connections.
11328 (read_prim,write_prim): New functions. Replace all calls to
11329 read/write to these.
11330 * server.c (main): Watch for "-" argument. Move call to
11331 remote_prepare before start_inferior.
11332 * server.h (STDIO_CONNECTION_NAME): New macro.
11333 (remote_connection_is_stdio): Declare.
11334
11335 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
11336 in debugging output.
11337
11338 2011-12-15 Yao Qi <yao@codesourcery.com>
11339
11340 * tracepoint.c: Include sys/syscall.h.
11341 (gdb_ust_thread): Remove preprocessor conditional.
11342
11343 2011-12-14 Pedro Alves <pedro@codesourcery.com>
11344
11345 * linux-low.c (linux_detach_one_lwp): Call
11346 the_low_target.prepare_to_resume before detaching.
11347
11348 2011-12-14 Yao Qi <yao@codesourcery.com>
11349
11350 * tracepoint.c (gdb_ust_thread): Don't ignore return value
11351 of write.
11352
11353 2011-12-14 Yao Qi <yao@codesourcery.com>
11354
11355 * i386-low.c (i386_low_stopped_data_address): Initialize local
11356 variable `control'.
11357
11358 2011-12-13 Pedro Alves <pedro@codesourcery.com>
11359
11360 PR remote/13492
11361
11362 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
11363 DR_CONTROL unless necessary. Extend comments.
11364 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
11365 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
11366
11367 2011-12-13 Yao Qi <yao@codesourcery.com>
11368
11369 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
11370 macros.
11371 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
11372
11373 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
11374
11375 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
11376 Print new debug message for such case.
11377
11378 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
11379
11380 Fix overlapping memcpy.
11381 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
11382 the read_inferior_memory transfer.
11383 (delete_fast_tracepoint_jump): New variable buf. Use it for the
11384 write_inferior_memory transfer.
11385 (set_fast_tracepoint_jump): New variable buf. Use it for the
11386 read_inferior_memory and write_inferior_memory transfers.
11387 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
11388 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
11389 Use it for the write_inferior_memory transfer.
11390 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
11391 buffers.
11392
11393 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
11394
11395 * linux-low.c (fetch_register, store_register): Make code
11396 consistent, fix formatting.
11397
11398 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
11399
11400 * linux-low.c (usr_store_inferior_registers): Factor out code
11401 to handle individual registers into...
11402 (store_register): ... this new function.
11403
11404 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
11405
11406 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
11407 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
11408 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
11409 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
11410 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
11411 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
11412 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
11413 (srv_xmlfiles): Add new XML files.
11414
11415 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
11416 and <sys/uio.h>.
11417 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
11418 (init_registers_s390_linux32v1): Add prototype.
11419 (init_registers_s390_linux32v2): Likewise.
11420 (init_registers_s390_linux64v1): Likewise.
11421 (init_registers_s390_linux64v2): Likewise.
11422 (init_registers_s390x_linux64v1): Likewise.
11423 (init_registers_s390x_linux64v2): Likewise.
11424 (s390_num_regs): Increment to 52.
11425 (s390_regmap): Add orig_r2 register.
11426 (s390_num_regs_3264): Increment to 68.
11427 (s390_regmap_3264): Add orig_r2 register.
11428 (s390_collect_ptrace_register): Handle orig_r2 register.
11429 (s390_supply_ptrace_register): Likewise.
11430 (s390_fill_last_break): New function.
11431 (s390_store_last_break): Likewise.
11432 (s390_fill_system_call): New function.
11433 (s390_store_system_call): Likewise.
11434 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
11435 register sets.
11436 (s390_check_regset): New function.
11437 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
11438 NT_S390_SYSTEM_CALL regsets and use appropriate description.
11439 Update target_regsets for available register sets.
11440
11441 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
11442 Jan Kratochvil <jan.kratochvil@redhat.com>
11443
11444 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
11445 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
11446 New.
11447 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
11448 * linux-low.h (struct process_info_private): New member r_debug.
11449 * server.c (handle_qxfer_libraries): Call
11450 the_target->qxfer_libraries_svr4.
11451 (handle_qxfer_libraries_svr4): New function.
11452 (qxfer_packets): New entry "libraries-svr4".
11453 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
11454 * target.h (struct target_ops): New member qxfer_libraries_svr4.
11455 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
11456 PACKET_qXfer_libraries_svr4.
11457
11458 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
11459
11460 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
11461 PSW address/mask between 8-byte and 16-byte formats.
11462 (s390_supply_ptrace_register): Likewise.
11463 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
11464 basic addressing mode bit.
11465
11466 2011-11-24 Stan Shebs <stan@codesourcery.com>
11467
11468 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
11469
11470 2011-11-17 Stan Shebs <stan@codesourcery.com>
11471
11472 * tracepoint.c (struct tracepoint): New field traceframe_usage.
11473 (tracing_start_time): New global.
11474 (tracing_stop_time): New global.
11475 (tracing_user_name): New global.
11476 (tracing_notes): New global.
11477 (tracing_stop_note): New global.
11478 (cmd_qtstart): Set traceframe_usage, start_time.
11479 (stop_tracing): Set stop_time.
11480 (cmd_qtstatus): Report additional status.
11481 (cmd_qtp): New function.
11482 (handle_tracepoint_query): Call it.
11483 (cmd_qtnotes): New function.
11484 (handle_tracepoint_general_set): Call it.
11485 (get_timestamp): Rename from tsv_get_timestamp.
11486
11487 2011-11-14 Stan Shebs <stan@codesourcery.com>
11488 Kwok Cheung Yeung <kcy@codesourcery.com>
11489
11490 * linux-x86-low.c (small_jump_insn): New.
11491 (i386_install_fast_tracepoint_jump_pad): Add arguments for
11492 trampoline and error message, build a trampoline and issue a small
11493 jump instruction to it.
11494 (x86_install_fast_tracepoint_jump_pad): Add arguments for
11495 trampoline and error message.
11496 (x86_get_min_fast_tracepoint_insn_len): New.
11497 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
11498 * linux-low.h (struct linux_target_ops): Add arguments to
11499 install_fast_tracepoint_jump_pad operation, add new operation.
11500 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
11501 arguments.
11502 (linux_get_min_fast_tracepoint_insn_len): New function.
11503 (linux_target_op): Add new operation.
11504 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
11505 (gdb_trampoline_buffer_end): Ditto.
11506 (gdb_trampoline_buffer_error): Ditto.
11507 (struct ipa_sym_addresses): Add fields for new IPA variables.
11508 (symbol_list): Add entries for new IPA variables.
11509 (struct tracepoint): Add fields to hold the address range of the
11510 trampoline used by the tracepoint.
11511 (trampoline_buffer_head): New static variable.
11512 (trampoline_buffer_tail): Ditto.
11513 (claim_trampoline_space): New function.
11514 (have_fast_tracepoint_trampoline_buffer): New function.
11515 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
11516 structure.
11517 (install_fast_tracepoint): Ditto, also add error buffer argument.
11518 (cmd_qtminftpilen): New function.
11519 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
11520 (fast_tracepoint_from_trampoline_address): New function.
11521 (fast_tracepoint_collecting): Handle trampoline as part of jump
11522 pad space.
11523 (set_trampoline_buffer_space): New function.
11524 (initialize_tracepoint): Initialize new IPA variables.
11525 * target.h (struct target_ops): Add arguments to
11526 install_fast_tracepoint_jump_pad operation, add new
11527 get_min_fast_tracepoint_insn_len operation.
11528 (target_get_min_fast_tracepoint_insn_len): New.
11529 (install_fast_tracepoint_jump_pad): Add arguments.
11530 * server.h (IPA_BUFSIZ): Define.
11531 * linux-i386-ipa.c: Include extra header files.
11532 (initialize_fast_tracepoint_trampoline_buffer): New function.
11533 (initialize_low_tracepoint): Call it.
11534 * server.h (set_trampoline_buffer_space): Declare.
11535 (claim_trampoline_space): Ditto.
11536 (have_fast_tracepoint_trampoline_buffer): Ditto.
11537
11538 2011-11-14 Yao Qi <yao@codesourcery.com>
11539
11540 * server.c (handle_query): Handle InstallInTrace for qSupported.
11541 * tracepoint.c (add_tracepoint): Sort list.
11542 (install_tracepoint, download_tracepoint): New.
11543 (cmd_qtdp): Call them to install and download tracepoints.
11544 (sort_tracepoints): Removed.
11545 (cmd_qtstart): Update.
11546
11547 2011-11-14 Yao Qi <yao@codesourcery.com>
11548
11549 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
11550 * mem-break.h: Declare.
11551 * tracepoint.c (cmd_qtstart): Move some code to ...
11552 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
11553 New.
11554 (download_tracepoints): Move some code to ...
11555 (download_tracepoint_1): ... here. New.
11556
11557 2011-11-08 Yao Qi <yao@codesourcery.com>
11558
11559 * remote-utils.c (relocate_instruction): A comment fix.
11560
11561 2011-11-07 Joel Brobecker <brobecker@adacore.com>
11562
11563 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
11564 (i386_dr_low_get_control, i386_dr_low_get_status): Use
11565 dr_status_mirror and dr_control_mirror from debug_reg_state.
11566 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
11567 (i386_initial_stuff): Remove use of deleted globals.
11568 (i386_get_thread_context, i386_set_thread_context,
11569 i386_thread_added): Use dr_status_mirror and dr_control_mirror
11570 from debug_reg_state.
11571
11572 2011-11-05 Yao Qi <yao@codesourcery.com>
11573
11574 * tracepoint.c (gdb_collect): Loop over tracepoints of same
11575 address as TPOINT's.
11576
11577 2011-11-02 Stan Shebs <stan@codesourcery.com>
11578
11579 * tracepoint.c (agent_mem_read_string): New function.
11580 (eval_agent_expr): Call it for tracenz.
11581 * server.c (handle_query): Report support for tracenz.
11582
11583 2011-11-02 Yao Qi <yao@codesourcery.com>
11584
11585 * tracepoint.c (cmd_qtstart): Remove unused local variables.
11586
11587 2011-11-02 Yao Qi <yao@codesourcery.com>
11588
11589 * target.h: Fix a typo in comment.
11590
11591 2011-10-31 Pedro Alves <pedro@codesourcery.com>
11592
11593 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
11594 clobber the breakpoints' shadows with fast tracepoint jumps.
11595 * mem-break.h (check_mem_write): Add `myaddr' parameter.
11596 * target.c (write_inferior_memory): Also pass MYADDR down to
11597 check_mem_write.
11598
11599 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
11600
11601 * configure.ac: Check support for personality routine.
11602 * configure: Regenerate.
11603 * config.in: Likewise.
11604 * linux-low.c: Include <sys/personality.h>.
11605 Define ADDR_NO_RANDOMIZE if necessary.
11606 (linux_create_inferior): Disable address space randomization when
11607 forking inferior, if requested.
11608 (linux_supports_disable_randomization): New function.
11609 (linux_target_ops): Install it.
11610 * server.h (disable_randomization): Declare.
11611 * server.c (disable_randomization): New global variable.
11612 (handle_general_set): Handle QDisableRandomization.
11613 (handle_query): Likewise for qSupported.
11614 (main): Support --disable-randomization and --no-disable-randomization
11615 command line arguments.
11616 * target.h (struct target_ops): Add supports_disable_randomization.
11617 (target_supports_disable_randomization): New macro.
11618
11619 2011-09-29 Mike Frysinger <vapier@gentoo.org>
11620
11621 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
11622 ifdef check.
11623 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
11624 [!PT_GETDSBT] (target_loadmap): New definition.
11625 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
11626 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
11627 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
11628 and PT_GETDSBT to LINUX_LOADMAP.
11629 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
11630 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
11631
11632 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
11633
11634 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
11635 (arm_linux_hwbp_cap): New static variable.
11636 (arm_linux_get_hwbp_cap): Replace by ...
11637 (arm_linux_init_hwbp_cap): ... this new function.
11638 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
11639 (arm_linux_get_hw_watchpoint_count): Likewise.
11640 (arm_linux_get_hw_watchpoint_max_length): Likewise.
11641 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
11642 (arm_prepare_to_resume): Use perror_with_name instead of error.
11643
11644 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
11645
11646 * linux-arm-low.c: Include <signal.h>.
11647 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
11648 (struct arm_linux_hwbp_cap): New data type.
11649 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
11650 (struct arm_linux_hw_breakpoint): New data type.
11651 (MAX_BPTS, MAX_WPTS): Define.
11652 (struct arch_process_info, struct arch_lwp_info): New data types.
11653 (arm_linux_get_hwbp_cap): New function.
11654 (arm_linux_get_hw_breakpoint_count): Likewise.
11655 (arm_linux_get_hw_watchpoint_count): Likewise.
11656 (arm_linux_get_hw_watchpoint_max_length): Likewise.
11657 (arm_hwbp_control_initialize): Likewise.
11658 (arm_hwbp_control_is_enabled): Likewise.
11659 (arm_hwbp_control_is_initialized): Likewise.
11660 (arm_hwbp_control_disable): Likewise.
11661 (arm_linux_hw_breakpoint_equal): Likewise.
11662 (arm_linux_hw_point_initialize): Likewise.
11663 (struct update_registers_data): New data structure.
11664 (update_registers_callback: New function.
11665 (arm_insert_point): Likewise.
11666 (arm_remove_point): Likewise.
11667 (arm_stopped_by_watchpoint): Likewise.
11668 (arm_stopped_data_address): Likewise.
11669 (arm_new_process): Likewise.
11670 (arm_new_thread): Likewise.
11671 (arm_prepare_to_resume): Likewise.
11672 (the_low_target): Register arm_insert_point, arm_remove_point,
11673 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
11674 arm_new_thread, and arm_prepare_to_resume.
11675
11676 2011-09-15 Stan Shebs <stan@codesourcery.com>
11677
11678 * server.h (struct emit_ops): Add compare-goto fields.
11679 * tracepoint.c (gdb_agent_op_sizes): New table.
11680 (emit_eq_goto): New function.
11681 (emit_ne_goto): New function.
11682 (emit_lt_goto): New function.
11683 (emit_le_goto): New function.
11684 (emit_gt_goto): New function.
11685 (emit_ge_goto): New function.
11686 (is_goto_target): New function.
11687 (compile_bytecodes): Recognize special cases of compare-goto
11688 combinations and call specialized emitters for them.
11689 * linux-x86-low.c (amd64_emit_eq_goto): New function.
11690 (amd64_emit_ne_goto): New function.
11691 (amd64_emit_lt_goto): New function.
11692 (amd64_emit_le_goto): New function.
11693 (amd64_emit_gt_goto): New function.
11694 (amd64_emit_ge_goto): New function.
11695 (amd64_emit_ops): Add the new functions.
11696 (i386_emit_eq_goto): New function.
11697 (i386_emit_ne_goto): New function.
11698 (i386_emit_lt_goto): New function.
11699 (i386_emit_le_goto): New function.
11700 (i386_emit_gt_goto): New function.
11701 (i386_emit_ge_goto): New function.
11702 (i386_emit_ops): Add the new functions.
11703
11704 2011-09-08 Stan Shebs <stan@codesourcery.com>
11705
11706 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
11707 (i386_emit_epilogue): Restore %ebx.
11708
11709 2011-08-31 Jie Zhang <jzhang918@gmail.com>
11710
11711 * server.c (step_thread): Remove definition.
11712 (process_serial_event): Don't handle Hs.
11713 * server.h (step_thread): Remove declaration.
11714 * target.c (set_desired_inferior): Remove use of step_thread.
11715
11716 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
11717
11718 * linux-low.c: Include linux-procfs.h.
11719 (linux_attach_lwp_1): Update comments.
11720 (linux_attach): Scan for existing threads when attaching to a
11721 process that is the tgid.
11722 * Makefile.in: Update dependencies.
11723
11724 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
11725
11726 * configure.srv: Add linux-procfs.o dependencies.
11727
11728 2011-08-14 Yao Qi <yao@codesourcery.com>
11729
11730 * target.h (struct target_ops): Fix indent.
11731 * win32-low.c (win32_target_ops): Fix comment.
11732
11733 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
11734 Yao Qi <yao@codesourcery.com>
11735
11736 * Makefile.in (clean): Remove tic6x-*.c files.
11737 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
11738 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
11739 (tic6x-c64xp-linux.c): Likewise.
11740 * configure.srv: Add support for tic6x-*-uclinux.
11741 * linux-tic6x-low.c: New.
11742 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
11743
11744 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
11745 Yao Qi <yao@codesourcery.com>
11746
11747 * target.h (struct target_ops): Add read_loadmap.
11748 * linux-low.c (struct target_loadseg): New type.
11749 (struct target_loadmap): New type.
11750 (linux_read_loadmap): New function.
11751 (linux_target_ops): Add linux_read_loadmap.
11752 * server.c (handle_query): Support qXfer:fdpic:read packet.
11753 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
11754 to NULL.
11755
11756 2011-08-05 Eli Zaretskii <eliz@gnu.org>
11757
11758 * win32-low.c: Include <stdint.h>.
11759
11760 2011-07-22 Pedro Alves <pedro@codesourcery.com>
11761
11762 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
11763 to the inferior here.
11764 (i386_remove_aligned_watchpoint): Ditto.
11765 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
11766 fit part of the watchpoint in the debug registers.
11767 (i386_update_inferior_debug_regs): New.
11768 (i386_low_insert_watchpoint): Work on a local mirror of the debug
11769 registers, and only update the inferior on success.
11770 (i386_low_remove_watchpoint): Ditto.
11771
11772 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
11773
11774 * linux-low.c (compare_ints, unique, list_threads, show_process,
11775 linux_core_of_thread): Delete.
11776 (linux_target_ops): Change linux_core_of_thread to
11777 linux_common_core_of_thread.
11778 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
11779 * utils.c (malloc_failure): Change type of argument.
11780 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
11781 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
11782 common/linux-osdata.c, common/ptid.c and common/buffer.c.
11783 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
11784 (IPA_OBJS): Add common-utils-ipa.o.
11785 (ptid_h, linux_osdata_h): New macros.
11786 (server_h): Add common/common-utils.h, common/xml-utils.h,
11787 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
11788 common/ptid.h.
11789 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
11790 ptid.o, buffer.o): New rules.
11791 (linux-low.o): Add common/linux-osdata.h as a dependency.
11792 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
11793 * configure.ac: Add AC_HEADER_DIRENT check.
11794 * config.in: Regenerate.
11795 * configure: Regenerate.
11796 * remote-utils.c (xml_escape_text): Delete.
11797 (buffer_grow, buffer_free, buffer_init, buffer_finish,
11798 buffer_xml_printf): Move to common/buffer.c.
11799 * server.c (main): Remove call to initialize_inferiors.
11800 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
11801 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
11802 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
11803 internal_error, gdb_assert, gdb_assert_fail): Delete.
11804 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
11805 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
11806 common/buffer.h.
11807 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
11808 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
11809 initialize_inferiors): Delete.
11810
11811 2011-07-20 Pedro Alves <pedro@codesourcery.com>
11812
11813 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
11814 symbol error.
11815
11816 2011-05-31 Pedro Alves <pedro@codesourcery.com>
11817
11818 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
11819 assertion.
11820 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
11821
11822 2011-05-26 Yao Qi <yao@codesourcery.com>
11823
11824 * Makefile.in (thread-db.o): Track dependence to
11825 common/gdb_thread_db.h.
11826 * thread-db.c: include gdb_thread_db.h from right place.
11827
11828 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
11829
11830 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
11831 __FILE__ and __LINE__ to internal_error.
11832
11833 2011-05-13 Doug Evans <dje@google.com>
11834
11835 * thread-db.c (try_thread_db_load_from_sdir): New function.
11836 (try_thread_db_load_from_dir): New function.
11837 (thread_db_load_search): Handle $sdir, ignore $pdir.
11838 Remove trying of system directories if search of
11839 libthread-db-search-path fails, that is now done via $sdir.
11840
11841 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
11842
11843 * server.c (handle_query): Add EnableDisableTracepoints to the list
11844 of supported features.
11845 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
11846 tracepoints.
11847 (cmd_qtenable_disable): New.
11848 (cmd_qtstart): Install tracepoints even if disabled.
11849 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
11850 receiving a QTEnable or QTDisable packet.
11851 (gdb_collect): Skip data collection if fast tracepoint is disabled.
11852 (ust_marker_to_static_tracepoint): Do not ignore disabled static
11853 tracepoints.
11854 (gdb_probe): Skip data collection if static tracepoint is disabled.
11855
11856 2011-05-10 Doug Evans <dje@google.com>
11857
11858 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
11859
11860 2011-05-04 Doug Evans <dje@google.com>
11861
11862 * linux-low.c (linux_join): Skip process lookup.
11863 * spu-low.c (spu_join): Ditto.
11864 * server.c (join_inferiors_callback): Delete.
11865 (process_serial_event): For 'D' packet (detach) call join_inferior
11866 directly.
11867
11868 2011-05-04 Joseph Myers <joseph@codesourcery.com>
11869
11870 * README: Don't mention xscale*-*-linux*.
11871 * configure.srv (xscale*-*-linux*): Don't handle target.
11872
11873 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
11874
11875 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
11876 casting pointers.
11877 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
11878 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
11879 (i386_emit_void_call_2): Likewise.
11880
11881 2011-04-26 Yao Qi <yao@codesourcery.com>
11882
11883 * linux-low.c: Move common macros to linux-ptrace.h.
11884 Include linux-ptrace.h.
11885 * Makefile.in (linux_ptrace_h): New.
11886 (linux-low.o): Depends on linux-ptrace.h.
11887
11888 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
11889
11890 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
11891 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
11892 (remote_prepare): New function with most of the TCP code from ...
11893 (remote_open): ... here. Detect PORT here unconditionally. Move also
11894 setting transport_is_reliable.
11895 * server.c (run_once): New variable.
11896 (gdbserver_usage): Document it.
11897 (main): Set run_once for `--once'. Call remote_prepare. Exit after
11898 the first run if RUN_ONCE.
11899 * server.h (run_once, remote_prepare): New declarations.
11900
11901 2011-04-19 Tom Tromey <tromey@redhat.com>
11902
11903 * win32-low.c (handle_load_dll): Remove duplicate "the".
11904
11905 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
11906
11907 Remove support for old Cygwin 1.5 versions.
11908 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
11909 function to avoid warning.
11910 (win32_add_one_solib): Use cygwin_conv_path function to avoid
11911 warning.
11912
11913 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
11914
11915 * gdbserver/server.h (Macro _): Define it if not available.
11916
11917 2011-03-14 Michael Snyder <msnyder@vmware.com>
11918
11919 * hostio.c (handle_close): Remove unnecessary null test.
11920
11921 2011-03-10 Joel Brobecker <brobecker@adacore.com>
11922
11923 * Makefile.in (maintainer-clean realclean distclean): Remove
11924 "make ... subdir_do" command.
11925
11926 2011-03-10 Michael Snyder <msnyder@vmware.com>
11927
11928 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
11929
11930 * server.c (handle_v_run): Free alloced buffer on early return.
11931
11932 2011-03-09 Yao Qi <yao@codesourcery.com>
11933
11934 Revert:
11935 2011-03-04 Yao Qi <yao@codesourcery.com>
11936
11937 * Makefile.in: Remove GNU make feature --directory.
11938
11939 2011-03-05 Yao Qi <yao@codesourcery.com>
11940
11941 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
11942 (subdir_do): New make target. Copied from gdb/Makefile.
11943 (maintainer-clean, realclean, distclean, clean): Call corresponding
11944 make targets in common/Makefile.
11945
11946 2011-02-11 Yao Qi <yao@codesourcery.com>
11947
11948 * configure.ac: Call AC_PROG_RANLIB.
11949 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
11950 * configure: Regenerate.
11951
11952 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
11953
11954 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
11955
11956 2011-03-06 Yao Qi <yao@codesourcery.com>
11957
11958 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
11959
11960 2011-03-05 Yao Qi <yao@codesourcery.com>
11961
11962 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
11963 (subdir_do): New make target. Copied from gdb/Makefile.
11964 (maintainer-clean, realclean, distclean, clean): Call corresponding
11965 make targets in common/Makefile.
11966
11967 2011-03-04 Yao Qi <yao@codesourcery.com>
11968
11969 * Makefile.in: Remove GNU make feature --directory.
11970
11971 2011-03-04 Michael Snyder <msnyder@vmware.com>
11972
11973 * server.c (queue_stop_reply): Call xmalloc not malloc.
11974
11975 2011-03-02 Michael Snyder <msnyder@vmware.com>
11976
11977 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
11978
11979 2011-02-28 Michael Snyder <msnyder@vmware.com>
11980
11981 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
11982 (cmd_qtframe): Ditto.
11983 (cmd_qtbuffer): Ditto.
11984 (cmd_bigqtbuffer): Ditto.
11985
11986 * utils.c (decimal2str): Initialize 'width' to nine, then
11987 don't mess with it.
11988
11989 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
11990
11991 * hostio.c (require_data): Free *data, not data.
11992
11993 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
11994
11995 * hostio.c (require_data): Use free, not xfree.
11996
11997 2011-02-27 Michael Snyder <msnyder@vmware.com>
11998
11999 * server.c (handle_query): Discard unused value.
12000
12001 * hostio.c (require_data): Free malloc memory before returning
12002 error.
12003
12004 2011-02-26 Michael Snyder <msnyder@vmware.com>
12005
12006 * linux-low.c (list_threads): Call closedir for dirent.
12007
12008 2011-02-27 Michael Snyder <msnyder@vmware.com>
12009
12010 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
12011 a case statement falls through.
12012
12013 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
12014
12015 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
12016 in comparison.
12017
12018 2011-02-26 Michael Snyder <msnyder@vmware.com>
12019
12020 * utils.c (decimal2str): Eliminate dead code and dead param.
12021 (pulongest): Drop dead param from call to decimal2str.
12022 (plongest): Ditto.
12023
12024 2011-02-24 Joel Brobecker <brobecker@adacore.com>
12025
12026 Revert the following patch (not approved yet):
12027 2011-02-21 Hui Zhu <teawater@gmail.com>
12028 * tracepoint.c (tp_printf): New function.
12029 (eval_agent_expr): Handle gdb_agent_op_printf.
12030
12031 2011-02-21 Hui Zhu <teawater@gmail.com>
12032
12033 * tracepoint.c (tp_printf): New function.
12034 (eval_agent_expr): Handle gdb_agent_op_printf.
12035
12036 2011-02-18 Tom Tromey <tromey@redhat.com>
12037
12038 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
12039 (tracepoint.o): Likewise.
12040 * tracepoint.c (enum gdb_agent_op): Use ax.def.
12041 (gdb_agent_op_names): Likewise.
12042
12043 2011-02-18 Tom Tromey <tromey@redhat.com>
12044
12045 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
12046 gdb_agent_op_rot>: New constants.
12047 (gdb_agent_op_names): Add pick and roll.
12048 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
12049 cases.
12050
12051 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
12052
12053 * aclocal.m4: Regenerated with aclocal-1.11.1.
12054
12055 2011-02-14 Pedro Alves <pedro@codesourcery.com>
12056
12057 * server.c (handle_qxfer_traceframe_info): New.
12058 (qxfer_packets): Register "traceframe-info".
12059 (handle_query): Report support for qXfer:traceframe-info:read+.
12060 * tracepoint.c (match_blocktype): New.
12061 (traceframe_find_block_type): Rename to ...
12062 (traceframe_walk_blocks): ... this. Add callback filter argument,
12063 and use it.
12064 (traceframe_find_block_type): New, reimplemented on top of
12065 traceframe_walk_blocks.
12066 (build_traceframe_info_xml): New.
12067 (traceframe_read_info): New.
12068 * server.h (traceframe_read_info): Declare.
12069
12070 2011-02-11 Yao Qi <yao@codesourcery.com>
12071
12072 * configure.ac: Call AC_PROG_RANLIB.
12073 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
12074 * configure: Regenerate.
12075
12076 2011-02-07 Pedro Alves <pedro@codesourcery.com>
12077
12078 * server.c (gdb_read_memory): Change return semantics to allow
12079 partial transfers.
12080 (handle_search_memory_1): Adjust.
12081 (process_serial_event) <'m' packet>: Handle partial transfers.
12082 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
12083
12084 2011-01-28 Pedro Alves <pedro@codesourcery.com>
12085
12086 * regcache.c (init_register_cache): Initialize
12087 regcache->register_status.
12088 (free_register_cache): Release regcache->register_status.
12089 (regcache_cpy): Copy register_status.
12090 (registers_to_string): Print 'x's for unavailable registers.
12091 (supply_register): Mark the register's status valid or
12092 unavailable, depending on whether a buffer was passed in or not.
12093 (supply_register_zeroed): New.
12094 (supply_regblock): Mark the registers' status valid or
12095 unavailable, depending on whether a buffer was passed in or not.
12096 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
12097 (struct regcache): New `register_status' field.
12098 (supply_register_zeroed): Declare.
12099 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
12100 supply_register_zeroed, rather than passing a NULL buffer to
12101 supply_register.
12102 * tracepoint.c (fetch_traceframe_registers): Update comment.
12103
12104 2011-01-28 Pedro Alves <pedro@codesourcery.com>
12105
12106 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
12107 buffer explicit.
12108
12109 2011-01-25 Pedro Alves <pedro@codesourcery.com>
12110
12111 * server.h (decode_xfer_write): Change prototype.
12112 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
12113 and don't extract the annex here.
12114 * server.c (decode_xfer_read): Remove `annex' parameter,
12115 and don't extract the annex here.
12116 (decode_xfer): New.
12117 (struct qxfer): New.
12118 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
12119 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
12120 (handle_qxfer_statictrace): New functions, abstracted out from
12121 handle_query, and made to use the struct qxfer interface.
12122 (handle_threads_qxfer_proper): Rename to ...
12123 (handle_qxfer_threads_proper): ... this.
12124 (handle_threads_qxfer): Rename to ...
12125 (handle_qxfer_threads): ... this. Adjust.
12126 (qxfer_packets): New array.
12127 (handle_qxfer): New function.
12128 (handle_query): Use handle_qxfer.
12129
12130 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
12131
12132 * gdbreplay.c: Shorten lines of >= 80 columns.
12133 * linux-low.c: Ditto.
12134 * linux-ppc-low.c: Ditto.
12135 * linux-s390-low.c: Ditto.
12136 * linux-sparc-low.c: Ditto.
12137 * linux-x86-low.c: Ditto.
12138 * linux-xtensa-low.c: Ditto.
12139 * mem-break.c: Ditto.
12140 * nto-low.c: Ditto.
12141 * regcache.h: Ditto.
12142 * remote-utils.c: Ditto.
12143 * server.c: Ditto.
12144 * server.h: Ditto.
12145 * thread-db.c: Ditto.
12146 * tracepoint.c: Ditto.
12147 * utils.c: Ditto.
12148 * win32-low.h: Ditto.
12149
12150 2011-01-05 Joel Brobecker <brobecker@adacore.com>
12151
12152 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
12153 update.
12154
12155 2011-01-01 Joel Brobecker <brobecker@adacore.com>
12156
12157 * server.c (gdbserver_version): Update copyright year in version
12158 output.
12159 * gdbreplay.c (gdbreplay_version): Ditto.
12160
12161 2010-12-29 Jie Zhang <jie.zhang@analog.com>
12162
12163 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
12164 * linux-bfin-low.c: New file.
12165 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
12166 PT_DATA_ADDR for BFIN targets.
12167 * Makefile.in (SFILES): Add linux-bfin-low.c.
12168 (clean): Remove reg-bfin.c.
12169 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
12170 * README: Mention supported Blackfin targets.
12171
12172 2010-12-23 Mike Frysinger <vapier@gentoo.org>
12173
12174 * .gitignore: New file.
12175
12176 2010-11-16 Mike Frysinger <vapier@gentoo.org>
12177
12178 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
12179
12180 2010-10-22 Jie Zhang <jie@codesourcery.com>
12181
12182 * Makefile.in: Add FLAGS_TO_PASS variable.
12183 (install): Remove dependency of install-only and recursively
12184 invoke make for install-only.
12185
12186 2010-10-04 Doug Evans <dje@google.com>
12187
12188 * Makefile.in (uninstall): Use $(DESTDIR).
12189
12190 2010-09-24 Pedro Alves <pedro@codesourcery.com>
12191
12192 PR gdb/11842
12193
12194 * linux-x86-low.c (compat_siginfo_from_siginfo)
12195 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
12196 si_code is < 0. Check for si_code == SI_TIMER before checking for
12197 si_code < 0.
12198
12199 2010-09-13 Joel Brobecker <brobecker@adacore.com>
12200
12201 * lynx-i386-low.c: New file.
12202 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
12203
12204 2010-09-13 Joel Brobecker <brobecker@adacore.com>
12205
12206 * lynx-low.c (ptrace_request_to_str): Remove handling for
12207 request values that have been removed in LynxOS 5.x.
12208
12209 2010-09-13 Joel Brobecker <brobecker@adacore.com>
12210
12211 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
12212 <ptrace.h>
12213
12214 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
12215
12216 * configure.ac: Add --enable-inprocess-agent option.
12217 * configure: Rebuilt.
12218
12219 2010-09-06 Yao Qi <yao@codesourcery.com>
12220
12221 * linux-low.c (linux_kill): Remove unused variable.
12222 (linux_stabilize_threads): Likewise.
12223 * server.c (start_inferior): Likewise.
12224 (queue_stop_reply_callback): Likewise.
12225 * tracepoint.c (do_action_at_tracepoint): Likewise.
12226
12227 2010-09-06 Yao Qi <yao@codesourcery.com>
12228
12229 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
12230 on return.
12231
12232 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
12233
12234 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
12235
12236 2010-09-06 Pedro Alves <pedro@codesourcery.com>
12237
12238 * Makefile.in (install-only): Replace $IPA_DEPFILES with
12239 "$(IPA_DEPFILES)".
12240
12241 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12242
12243 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
12244 gdbserver/lynx-ppc-low.c: New files.
12245 * Makefile.in (lynx_low_h): New variable.
12246 (lynx-low.o, lynx-ppc-low.o): New rules.
12247 * configure.ac: On LynxOS, link with -lnetinet.
12248 * configure.srv: Add handling of powerpc-*-lynxos* targets.
12249 * configure: regenerate.
12250
12251 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12252
12253 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
12254 * configure.ac: Add check for vasprintf and vsnprintf.
12255 * configure, config.in: Regenerate.
12256 * server.h (vasprintf, vsnprintf): Add conditional declarations.
12257
12258 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12259
12260 * gdbreplay.c: Move include of alloca.h up, next to include of
12261 malloc.h.
12262 * server.h: Add include of malloc.h.
12263 * mem-break.c: Remove include of malloc.h.
12264 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
12265
12266 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12267
12268 * Makefile.in (memmem.o): Build with -Wno-error.
12269
12270 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12271
12272 * utils.c (xsnprintf): Make non-static.
12273 * server.h: Add xsnprintf declaration.
12274 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
12275 replace calls to snprintf by calls to xsnprintf throughout.
12276
12277 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12278
12279 * configure.ac: Add configure check for alloca.
12280 * configure, config.in: Regenerate.
12281 * server.h: Include alloca.h if it exists.
12282 * gdbreplay.c: Include alloca.h if it exists.
12283
12284 2010-08-28 Pedro Alves <pedro@codesourcery.com>
12285
12286 * linux-low.c (__SIGRTMIN): Define if not already defined.
12287 (linux_create_inferior): Check for __ANDROID__ rather than
12288 __SIGRTMIN.
12289 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
12290 are already deferred.
12291 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
12292 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
12293 stopped and already has a pending signal to report.
12294 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
12295 a pending signal to report or is moving out of a jump pad.
12296 (linux_init_signals): Check for __ANDROID__ rather than
12297 __SIGRTMIN.
12298
12299 2010-08-28 Pedro Alves <pedro@codesourcery.com>
12300
12301 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
12302 debug_threads check. Avoid a linear search when not doing debug
12303 output.
12304
12305 2010-08-27 Pedro Alves <pedro@codesourcery.com>
12306
12307 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
12308 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
12309 (struct file_handler) <fd>: Change type to gdb_fildes_t.
12310 (process_event): Change local fd's type to gdb_fildes_t.
12311 (create_file_handler): Adjust prototype.
12312 (delete_file_handler): Adjust prototype.
12313 (handle_file_event): Adjust prototype. Use pfildes.
12314 (create_file_event): Adjsut prototype.
12315 * remote-utils.c (remote_desc, listen_desc): Change type to
12316 gdb_fildes_t.
12317 * server.h: New gdb_fildes_t typedef.
12318 [USE_WIN32API]: Include winsock2.h.
12319 (delete_file_handler, add_file_handler): Adjust prototypes.
12320 (pfildes): Declare.
12321 * utils.c (pfildes): New.
12322
12323 2010-08-27 Pedro Alves <pedro@codesourcery.com>
12324
12325 * configure.ac (build_warnings): Add -Wno-char-subscripts.
12326 * configure: Regenerate.
12327
12328 2010-08-27 Pedro Alves <pedro@codesourcery.com>
12329
12330 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
12331 (linux_done_accessing_memory): ... this.
12332 (linux_target_ops): Adjust.
12333 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
12334 * nto-low.c (nto_target_ops): Adjust comment.
12335 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
12336 * spu-low.c (spu_target_ops): Adjust comment.
12337 * target.h (target_ops): Rename unprepare_to_access_memory field
12338 to done_accessing_memory.
12339 (unprepare_to_access_memory): Rename to ...
12340 (done_accessing_memory): ... this.
12341
12342 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12343
12344 * linux-low.c (linux_prepare_to_access_memory): New.
12345 (linux_unprepare_to_access_memory): New.
12346 (linux_target_ops): Install them.
12347 * server.c (read_memory): Rename to ...
12348 (gdb_read_memory): ... this. Use
12349 prepare_to_access_memory/prepare_to_access_memory.
12350 (write_memory): Rename to ...
12351 (gdb_write_memory): ... this. Use
12352 prepare_to_access_memory/prepare_to_access_memory.
12353 (handle_search_memory_1): Adjust.
12354 (process_serial_event): Adjust.
12355 * target.h (struct target_ops): New fields
12356 prepare_to_access_memory and unprepare_to_access_memory.
12357 (prepare_to_access_memory, unprepare_to_access_memory): New.
12358 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
12359 prepare_to_access_memory/prepare_to_access_memory.
12360 * nto-low.c (nto_target_ops): Adjust.
12361 * spu-low.c (spu_target_ops): Adjust.
12362 * win32-low.c (win32_target_ops): Adjust.
12363
12364 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12365
12366 * Makefile.in (WARN_CFLAGS): Get it from configure.
12367 (WERROR_CFLAGS): New.
12368 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
12369 * configure.ac: Introduce --enable-werror, which adds -Werror to
12370 the compiler command line. Enabled by default. Disable with
12371 --disable-werror. Add -Wdeclaration-after-statement
12372 Wpointer-arith and -Wformat-nonliteral to warning flags.
12373 * configure: Regenerate.
12374
12375 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12376
12377 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
12378
12379 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12380
12381 * gdbreplay.c (remote_error): New.
12382 (gdbchar): New.
12383 (expect): Use gdbchar. Check for error reading from GDB.
12384 Clarify sync error output.
12385 (play): Check for errors writing to GDB.
12386 * linux-low.c (sigchld_handler): Really ignore `write' errors.
12387 * remote-utils.c (getpkt): Check for errors writing to the remote
12388 descriptor.
12389
12390 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12391
12392 * linux-low.c (linux_wait_1): Move non-debugging code out of
12393 `debug_threads' control.
12394
12395 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12396
12397 * linux-low.c (linux_wait_1): Don't set last_status here.
12398 * server.c (push_event, queue_stop_reply_callback): Assert we're
12399 not pushing a TARGET_WAITKIND_IGNORE event.
12400 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
12401 (myresume, handle_target_event): Set the thread's last_resume_kind
12402 and last_status from the target returned status.
12403
12404 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12405
12406 PR threads/10729
12407
12408 * linux-x86-low.c (update_debug_registers_callback): New.
12409 (i386_dr_low_set_addr): Use it.
12410 (i386_dr_low_get_addr): New.
12411 (i386_dr_low_set_control): Use update_debug_registers_callback.
12412 (i386_dr_low_get_control): New.
12413 (i386_dr_low_get_status): Adjust.
12414 * linux-low.c (linux_stop_lwp): New.
12415 * linux-low.h (linux_stop_lwp): Declare.
12416
12417 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
12418 argument instead of a i386_debug_reg_state.
12419 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
12420 a i386_debug_reg_state.
12421 (i386_insert_aligned_watchpoint): Adjust.
12422 (i386_remove_aligned_watchpoint): Adjust.
12423 (i386_low_stopped_data_address): Read the debug registers from the
12424 inferior instead of from the mirrors.
12425 * i386-low.h (struct i386_debug_reg_state): Extend comment.
12426 (i386_dr_low_get_addr): Declare.
12427 (i386_dr_low_get_control): Declare.
12428 (i386_dr_low_get_status): Change prototype.
12429
12430 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
12431 (i386_dr_low_get_addr): New.
12432 (i386_dr_low_get_control): New.
12433 (i386_dr_low_get_status): Adjust prototype. Return
12434 dr_status_mirror.
12435 (i386_initial_stuff): Clear dr_status_mirror and
12436 dr_control_mirror.
12437 (i386_get_thread_context): Adjust.
12438 (i386_set_thread_context): Adjust.
12439 (i386_thread_added): Adjust.
12440
12441 2010-08-24 Pedro Alves <pedro@codesourcery.com>
12442
12443 * linux-low.h (linux_thread_area): Delete declaration.
12444
12445 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
12446
12447 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
12448 after its termination.
12449
12450 2010-08-09 Pedro Alves <pedro@codesourcery.com>
12451
12452 * linux-low.c (gdb_wants_lwp_stopped): Delete.
12453 (gdb_wants_all_stopped): Delete.
12454 (linux_wait_1): Don't call them.
12455 * server.c (handle_v_cont): Tag all threads as want-stopped.
12456 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
12457 stopped as "client-wants-stopped".
12458
12459 2010-07-31 Pedro Alves <pedro@codesourcery.com>
12460
12461 * Makefile.in (signals_h): New.
12462 (server_h): Depend on it.
12463 (server.o): Don't depend on $(signals_def).
12464 (signals.o): Depend on $(signals_def).
12465
12466 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
12467
12468 * Makefile.in (signals_def): New.
12469 (server_h): Append include/gdb/signals.h and signals_def.
12470 (server.o): Append signals_def.
12471
12472 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
12473
12474 * server.c (handle_target_event): Use target_signal_to_host for
12475 resume_info.sig initialization.
12476 * target.h (struct thread_resume) <sig>: New comment.
12477
12478 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
12479
12480 * server.c (handle_query): strcpy() the returned string from paddress()
12481 instead of sprintf().
12482 * utils.c (paddress): Return phex_nz().
12483
12484 2010-07-07 Joel Brobecker <brobecker@adacore.com>
12485
12486 * server.c (handle_v_cont): Call mourn_inferior if process
12487 just exited.
12488 (myresume): Likewise.
12489
12490 2010-07-01 Pedro Alves <pedro@codesourcery.com>
12491
12492 Static tracepoints, and integration with UST.
12493
12494 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
12495 * mem-break.c (uninsert_all_breakpoints)
12496 (reinsert_all_breakpoints): New.
12497 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
12498 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
12499 (gdb_agent_ust_loaded, helper_thread_id)
12500 (gdb_agent_helper_thread_id): New macros.
12501 (struct ipa_sym_addresses): Add addr_ust_loaded,
12502 addr_helper_thread_id, addr_cmd_buf.
12503 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
12504 (in_process_agent_loaded_ust): New.
12505 (write_e_ust_not_loaded): New.
12506 (maybe_write_ipa_ust_not_loaded): New.
12507 (struct collect_static_trace_data_action): New.
12508 (enum tracepoint_type) <static_tracepoint>: New.
12509 (struct tracepoint) <handle>: Mention static tracepoints.
12510 (struct static_tracepoint_ctx): New.
12511 (CMD_BUF_SIZE): New.
12512 (add_tracepoint_action): Handle static tracepoint actions.
12513 (unprobe_marker_at): New.
12514 (clear_installed_tracepoints): Handle static tracepoints.
12515 (cmd_qtdp): Handle static tracepoints.
12516 (probe_marker_at): New.
12517 (cmd_qtstart): Handle static tracepoints.
12518 (response_tracepoint): Handle static tracepoints.
12519 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
12520 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
12521 (get_context_regcache): Handle static tracepoints.
12522 (do_action_at_tracepoint): Handle static tracepoint actions.
12523 (traceframe_find_block_type): Handle static trace data blocks.
12524 (traceframe_read_sdata): New.
12525 (download_tracepoints): Download static tracepoint actions.
12526 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
12527 (GDB_PROBE_NAME): New.
12528 (ust_ops): New.
12529 (GET_UST_SYM): New.
12530 (USTF): New.
12531 (dlsym_ust): New.
12532 (ust_marker_to_static_tracepoint): New.
12533 (gdb_probe): New.
12534 (collect_ust_data_at_tracepoint): New.
12535 (gdb_ust_probe): New.
12536 (UNIX_PATH_MAX, SOCK_DIR): New.
12537 (gdb_ust_connect_sync_socket): New.
12538 (resume_thread, stop_thread): New.
12539 (run_inferior_command): New.
12540 (init_named_socket): New.
12541 (gdb_ust_socket_init): New.
12542 (cstr_to_hexstr): New.
12543 (next_st): New.
12544 (first_marker, next_marker): New.
12545 (response_ust_marker): New.
12546 (cmd_qtfstm, cmd_qtsstm): New.
12547 (unprobe_marker_at, probe_marker_at): New.
12548 (cmd_qtstmat, gdb_ust_thread): New.
12549 (gdb_ust_init): New.
12550 (initialize_tracepoint_ftlib): Call gdb_ust_init.
12551 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
12552 (ST_REGENTRY): New.
12553 (x86_64_st_collect_regmap): New.
12554 (X86_64_NUM_ST_COLLECT_GREGS): New.
12555 (AMD64_RIP_REGNUM): New.
12556 (supply_static_tracepoint_registers): New.
12557 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
12558 (ST_REGENTRY): New.
12559 (i386_st_collect_regmap): New.
12560 (i386_NUM_ST_COLLECT_GREGS): New.
12561 (supply_static_tracepoint_registers): New.
12562 * server.c (handle_query): Handle qXfer:statictrace:read.
12563 <qSupported>: Report support for StaticTracepoints, and
12564 qXfer:statictrace:read features.
12565 * server.h (traceframe_read_sdata)
12566 (supply_static_tracepoint_registers): Declare.
12567 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
12568 (unpack_varlen_hex): Include in IPA build.
12569 * Makefile.in (ustlibs, ustinc): New.
12570 (IPA_OBJS): Add remote-utils-ipa.o.
12571 ($(IPA_LIB)): Link -ldl and -lpthread.
12572 (UST_CFLAGS): New.
12573 (IPAGENT_CFLAGS): Add UST_CFLAGS.
12574 * config.in, configure: Regenerate.
12575
12576 2010-06-20 Ian Lance Taylor <iant@google.com>
12577 Pedro Alves <pedro@codesourcery.com>
12578
12579 * linux-x86-low.c (always_true): Delete.
12580 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
12581 trying to fool the compiler with always_true.
12582
12583 2010-06-20 Pedro Alves <pedro@codesourcery.com>
12584
12585 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
12586 conditions in gdbserver.
12587
12588 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
12589
12590 * spu-low.c (spu_read_memory): Wrap around local store limit.
12591 (spu_write_memory): Likewise.
12592
12593 2010-06-15 Pedro Alves <pedro@codesourcery.com>
12594
12595 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
12596 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
12597 LONGEST uses.
12598 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
12599 uses.
12600 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
12601 uses with LONGEST uses.
12602
12603 2010-06-14 Stan Shebs <stan@codesourcery.com>
12604 Pedro Alves <pedro@codesourcery.com>
12605
12606 Bytecode compiler.
12607
12608 * linux-x86-low.c: Include limits.h.
12609 (add_insns): New.
12610 (always_true): New.
12611 (EMIT_ASM): New.
12612 (EMIT_ASM32): New.
12613 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
12614 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
12615 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
12616 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
12617 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
12618 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
12619 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
12620 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
12621 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
12622 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
12623 (amd64_emit_void_call_2): New.
12624 (amd64_emit_ops): New.
12625 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
12626 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
12627 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
12628 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
12629 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
12630 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
12631 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
12632 (i386_emit_call, i386_emit_reg, i386_emit_pop)
12633 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
12634 (i386_emit_stack_adjust, i386_emit_int_call_1)
12635 (i386_emit_void_call_2): New.
12636 (i386_emit_ops): New.
12637 (x86_emit_ops): New.
12638 (the_low_target): Install x86_emit_ops.
12639 * server.h (struct emit_ops): New.
12640 (get_raw_reg_func_addr): Declare.
12641 (current_insn_ptr, emit_error): Declare.
12642 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
12643 (set_trace_state_variable_value): New defines.
12644 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
12645 addr_get_trace_state_variable_value and
12646 addr_set_trace_state_variable_value.
12647 (symbol_list): New fields for get_raw_reg,
12648 get_trace_state_variable_value and set_trace_state_variable_value.
12649 (condfn): New typedef.
12650 (struct tracepoint): New field `compiled_cond'.
12651 (do_action_at_tracepoint): Clear compiled_cond.
12652 (get_trace_state_variable_value, set_trace_state_variable_value):
12653 Export in the IPA.
12654 (condition_true_at_tracepoint): If there's a compiled condition,
12655 run that.
12656 (current_insn_ptr, emit_error): New globals.
12657 (struct bytecode_address): New.
12658 (get_raw_reg_func_addr): New.
12659 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
12660 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
12661 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
12662 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
12663 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
12664 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
12665 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
12666 (compile_tracepoint_condition, compile_bytecodes): New.
12667 * target.h (emit_ops): Forward declare.
12668 (struct target_ops): New field emit_ops.
12669 (target_emit_ops): New.
12670 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
12671 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
12672 * linux-low.c (linux_emit_ops): New.
12673 (linux_target_ops): Install it.
12674 * linux-low.h (struct linux_target_ops): New field emit_ops.
12675
12676 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
12677
12678 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
12679 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
12680
12681 2010-06-01 Pedro Alves <pedro@codesourcery.com>
12682 Stan Shebs <stan@codesourcery.com>
12683
12684 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
12685 (all): Depend on $(extra_libraries).
12686 (install-only): Install the IPA.
12687 (IPA_OBJS, IPA_LIB): New.
12688 (clean): Remove the IPA lib.
12689 (IPAGENT_CFLAGS): New.
12690 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
12691 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
12692 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
12693 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
12694 * configure.ac: Check for atomic builtins support in the compiler.
12695 (IPA_DEPFILES, extra_libraries): Define.
12696 * configure.srv (ipa_obj): Add description.
12697 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
12698 (i[34567]86-*-linux*): Set ipa_obj.
12699 (x86_64-*-linux*): Set ipa_obj.
12700 * linux-low.c (stabilizing_threads): New.
12701 (supports_fast_tracepoints): New.
12702 (linux_detach): Stabilize threads before detaching.
12703 (handle_tracepoints): Handle internal tracing breakpoints. Assert
12704 the lwp is either not stabilizing, or is moving out of a jump pad.
12705 (linux_fast_tracepoint_collecting): New.
12706 (maybe_move_out_of_jump_pad): New.
12707 (enqueue_one_deferred_signal): New.
12708 (dequeue_one_deferred_signal): New.
12709 (linux_wait_for_event_1): If moving out of a jump pad, defer
12710 pending signals to later.
12711 (linux_stabilize_threads): New.
12712 (linux_wait_1): Check if threads need moving out of jump pads, and
12713 do it if so.
12714 (stuck_in_jump_pad_callback): New.
12715 (move_out_of_jump_pad_callback): New.
12716 (lwp_running): New.
12717 (linux_resume_one_lwp): Handle moving out of jump pads.
12718 (linux_set_resume_request): Dequeue deferred signals.
12719 (need_step_over_p): Also step over fast tracepoint jumps.
12720 (start_step_over): Also uninsert fast tracepoint jumps.
12721 (finish_step_over): Also reinsert fast tracepoint jumps.
12722 (linux_install_fast_tracepoint_jump): New.
12723 (linux_target_ops): Install linux_stabilize_threads and
12724 linux_install_fast_tracepoint_jump_pad.
12725 * linux-low.h (linux_target_ops) <get_thread_area,
12726 install_fast_tracepoint_jump_pad>: New fields.
12727 (struct lwp_info) <collecting_fast_tracepoint,
12728 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
12729 (linux_get_thread_area): Declare.
12730 * linux-x86-low.c (jump_insn): New.
12731 (x86_get_thread_area): New.
12732 (append_insns): New.
12733 (push_opcode): New.
12734 (amd64_install_fast_tracepoint_jump_pad): New.
12735 (i386_install_fast_tracepoint_jump_pad): New.
12736 (x86_install_fast_tracepoint_jump_pad): New.
12737 (the_low_target): Install x86_get_thread_area and
12738 x86_install_fast_tracepoint_jump_pad.
12739 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
12740 (struct fast_tracepoint_jump): New.
12741 (fast_tracepoint_jump_insn): New.
12742 (fast_tracepoint_jump_shadow): New.
12743 (find_fast_tracepoint_jump_at): New.
12744 (fast_tracepoint_jump_here): New.
12745 (delete_fast_tracepoint_jump): New.
12746 (set_fast_tracepoint_jump): New.
12747 (uninsert_fast_tracepoint_jumps_at): New.
12748 (reinsert_fast_tracepoint_jumps_at): New.
12749 (set_breakpoint_at): Use write_inferior_memory.
12750 (uninsert_raw_breakpoint): Use write_inferior_memory.
12751 (check_mem_read): Mask out fast tracepoint jumps.
12752 (check_mem_write): Mask out fast tracepoint jumps.
12753 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
12754 (set_fast_tracepoint_jump): Declare.
12755 (delete_fast_tracepoint_jump)
12756 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
12757 (reinsert_fast_tracepoint_jumps_at): Declare.
12758 * regcache.c: Don't compile many functions when building the
12759 in-process agent library.
12760 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
12761 the register buffer in the heap.
12762 (free_register_cache): If the register buffer isn't owned by the
12763 regcache, don't free it.
12764 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
12765 pre-existing register caches.
12766 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
12767 type.
12768 (convert_ascii_to_int): : Constify `from' parameter type.
12769 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
12770 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
12771 the needed buffer in-place.
12772 (relocate_instruction): New.
12773 * server.c (handle_query) <qSymbols>: If the target supports
12774 tracepoints, give it a chance of looking up symbols. Report
12775 support for fast tracepoints.
12776 (handle_status): Stabilize threads.
12777 (process_serial_event): Adjust.
12778 * server.h (struct fast_tracepoint_jump): Forward declare.
12779 (struct process_info) <fast_tracepoint_jumps>: New field.
12780 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
12781 (decode_X_packet, decode_M_packet): Adjust.
12782 (relocate_instruction): Declare.
12783 (in_process_agent_loaded): Declare.
12784 (tracepoint_look_up_symbols): Declare.
12785 (struct fast_tpoint_collect_status): Declare.
12786 (fast_tracepoint_collecting): Declare.
12787 (force_unlock_trace_buffer): Declare.
12788 (handle_tracepoint_bkpts): Declare.
12789 (initialize_low_tracepoint)
12790 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
12791 * target.h (struct target_ops) <stabilize_threads,
12792 install_fast_tracepoint_jump_pad>: New fields.
12793 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
12794 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
12795 [HAVE_STDINT_H]: Include stdint.h.
12796 (trace_debug_1): Rename to ...
12797 (trace_vdebug): ... this.
12798 (trace_debug): Rename to ...
12799 (trace_debug_1): ... this. Add `level' parameter.
12800 (trace_debug): New.
12801 (ATTR_USED, ATTR_NOINLINE): New.
12802 (IP_AGENT_EXPORT): New.
12803 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
12804 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
12805 (about_to_request_buffer_space, trace_buffer_is_full)
12806 (stopping_tracepoint, expr_eval_result, error_tracepoint)
12807 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
12808 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
12809 (traceframe_write_count, traceframes_created)
12810 (trace_state_variables)
12811 New renaming defines.
12812 (struct ipa_sym_addresses): New.
12813 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
12814 (symbol_list): New.
12815 (ipa_sym_addrs): New.
12816 (all_tracepoint_symbols_looked_up): New.
12817 (in_process_agent_loaded): New.
12818 (write_e_ipa_not_loaded): New.
12819 (maybe_write_ipa_not_loaded): New.
12820 (tracepoint_look_up_symbols): New.
12821 (debug_threads) [IN_PROCESS_AGENT]: New.
12822 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
12823 (UNKNOWN_SIDE_EFFECTS): New.
12824 (stop_tracing): New.
12825 (flush_trace_buffer): New.
12826 (stop_tracing_bkpt): New.
12827 (flush_trace_buffer_bkpt): New.
12828 (read_inferior_integer): New.
12829 (read_inferior_uinteger): New.
12830 (read_inferior_data_pointer): New.
12831 (write_inferior_data_pointer): New.
12832 (write_inferior_integer): New.
12833 (write_inferior_uinteger): New.
12834 (struct collect_static_trace_data_action): Delete.
12835 (enum tracepoint_type): New.
12836 (struct tracepoint) <type>: New field `type'.
12837 <actions_str, step_actions, step_actions_str>: Only include in
12838 GDBserver.
12839 <orig_size, obj_addr_on_target, adjusted_insn_addr>
12840 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
12841 (tracepoints): Use IP_AGENT_EXPORT.
12842 (last_tracepoint): Don't include in the IPA.
12843 (stopping_tracepoint): Use IP_AGENT_EXPORT.
12844 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
12845 (alloced_trace_state_variables): New.
12846 (trace_state_variables): Use IP_AGENT_EXPORT.
12847 (traceframe_t): Delete unused variable.
12848 (circular_trace_buffer): Don't include in the IPA.
12849 (trace_buffer_start): Delete.
12850 (struct trace_buffer_control): New.
12851 (trace_buffer_free): Delete.
12852 (struct ipa_trace_buffer_control): New.
12853 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
12854 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
12855 New.
12856 (trace_buffer_ctrl): New.
12857 (TRACE_BUFFER_CTRL_CURR): New.
12858 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
12859 Reimplement as macros.
12860 (trace_buffer_wrap): Delete.
12861 (traceframe_write_count, traceframe_read_count)
12862 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
12863 (struct tracepoint_hit_ctx) <type>: New field.
12864 (struct fast_tracepoint_ctx): New.
12865 (memory_barrier): New.
12866 (cmpxchg): New.
12867 (record_tracepoint_error): Update atomically in the IPA.
12868 (clear_inferior_trace_buffer): New.
12869 (about_to_request_buffer_space): New.
12870 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
12871 updating the same buffer.
12872 (add_tracepoint): Default the tracepoint's type to trap
12873 tracepoint, and orig_size to -1.
12874 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
12875 internal variables.
12876 (create_trace_state_variable): New parameter `gdb'. Handle it.
12877 (clear_installed_tracepoints): Clear fast tracepoint jumps.
12878 (cmd_qtdp): Handle fast tracepoints.
12879 (cmd_qtdv): Adjust.
12880 (max_jump_pad_size): New.
12881 (gdb_jump_pad_head): New.
12882 (get_jump_space_head): New.
12883 (claim_jump_space): New.
12884 (sort_tracepoints): New.
12885 (MAX_JUMP_SIZE): New.
12886 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
12887 IPA.
12888 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
12889 support. Upload fast traceframes, and delete internal IPA
12890 breakpoints.
12891 (stop_tracing_handler): New.
12892 (flush_trace_buffer_handler): New.
12893 (cmd_qtstop): Upload fast tracepoints.
12894 (response_tracepoint): Handle fast tracepoints.
12895 (tracepoint_finished_step): Upload fast traceframes. Set the
12896 tracepoint hit context's tracepoint type.
12897 (handle_tracepoint_bkpts): New.
12898 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
12899 type. Add comment about fast tracepoints.
12900 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
12901 non-existing action_str field.
12902 (get_context_regcache): Handle fast tracepoints.
12903 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
12904 to the regcache.
12905 (fast_tracepoint_from_jump_pad_address): New.
12906 (fast_tracepoint_from_ipa_tpoint_address): New.
12907 (collecting_t): New.
12908 (force_unlock_trace_buffer): New.
12909 (fast_tracepoint_collecting): New.
12910 (collecting): New.
12911 (gdb_collect): New.
12912 (write_inferior_data_ptr): New.
12913 (target_tp_heap): New.
12914 (target_malloc): New.
12915 (download_agent_expr): New.
12916 (UALIGN): New.
12917 (download_tracepoints): New.
12918 (download_trace_state_variables): New.
12919 (upload_fast_traceframes): New.
12920 (IPA_FIRST_TRACEFRAME): New.
12921 (IPA_NEXT_TRACEFRAME_1): New.
12922 (IPA_NEXT_TRACEFRAME): New.
12923 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
12924 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
12925 (gdb_jump_pad_buffer_end): New.
12926 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
12927 (initialize_tracepoint): Adjust.
12928 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
12929 buffer. Initialize the low module.
12930 * utils.c (PREFIX, TOOLNAME): New.
12931 (malloc_failure): Use PREFIX.
12932 (error): In the IPA, an error causes an exit.
12933 (fatal, warning): Use PREFIX.
12934 (internal_error): Use TOOLNAME.
12935 (NUMCELLS): Increase to 10.
12936 * configure, config.in: Regenerate.
12937
12938 2010-06-01 Pedro Alves <pedro@codesourcery.com>
12939
12940 * server.c (handle_query) <qSupported>: Do two passes over the
12941 qSupported string to avoid nesting strtok.
12942
12943 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12944
12945 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
12946 (CDEPS): New.
12947 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
12948 -Wl,--dynamic-list.
12949 * configure: Regenerate.
12950 * proc-service.list: New.
12951
12952 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12953
12954 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
12955 New comment.
12956
12957 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
12958
12959 * gdbreplay.c (remote_open): Check error return from socket() call by
12960 its equality to -1 not by it being negative.
12961 * remote-utils.c (remote_open): Likewise.
12962
12963 2010-05-23 Pedro Alves <pedro@codesourcery.com>
12964
12965 * config.h: Regenerate.
12966
12967 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
12968
12969 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
12970 doesn't provide PTRACE_GET_THREAD_AREA.
12971
12972 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
12973
12974 * linux-m68k-low.c: Include <asm/ptrace.h>
12975 (ps_get_thread_area): Implement.
12976
12977 2010-05-03 Doug Evans <dje@google.com>
12978
12979 * event-loop.c (struct callback_event): New struct.
12980 (callback_list): New global.
12981 (append_callback_event, delete_callback_event): New functions.
12982 (process_callback): New function.
12983 (start_event_loop): Call it.
12984 * remote-utils.c (NOT_SCHEDULED): Define.
12985 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
12986 moved out of readchar.
12987 (readchar): Rewrite. Call reschedule before returning.
12988 (reset_readchar): New function.
12989 (remote_close): Call it.
12990 (process_remaining, reschedule): New functions.
12991 * server.h (callback_handler_func): New typedef.
12992 (append_callback_event, delete_callback_event): Declare.
12993
12994 2010-05-03 Pedro Alves <pedro@codesourcery.com>
12995
12996 * proc-service.c (ps_pglobal_lookup): Use
12997 thread_db_look_up_one_symbol.
12998 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
12999 parameter. Use it instead of all_symbols_looked_up.
13000 * server.h (struct process_info) <all_symbols_looked_up>: Delete
13001 field.
13002 (all_symbols_looked_up): Don't declare.
13003 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
13004 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
13005 field.
13006 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
13007 Set all_symbols_looked_up here.
13008 (thread_db_look_up_one_symbol): New.
13009 (thread_db_get_tls_address): Adjust.
13010 (thread_db_load_search, try_thread_db_load_1): Always allocate the
13011 thread_db object on the heap, and tentatively set it in the
13012 process structure.
13013 (thread_db_init): Don't set all_symbols_looked_up here.
13014 * linux-low.h (thread_db_look_up_one_symbol): Declare.
13015
13016 2010-05-03 Pedro Alves <pedro@codesourcery.com>
13017
13018 * linux-low.c (linux_kill, linux_detach): Adjust.
13019 (status_pending_p_callback): Remove redundant statement. Check
13020 for !TARGET_WAITIKIND_IGNORE, instead of
13021 TARGET_WAITKIND_STOPPED.
13022 (handle_tracepoints): Make sure LWP is locked. Adjust.
13023 (linux_wait_for_event_1): Adjust.
13024 (linux_cancel_breakpoints): New.
13025 (unsuspend_one_lwp): New.
13026 (unsuspend_all_lwps): New.
13027 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
13028 (send_sigstop_callback): Change return type to int, add new
13029 `except' parameter and handle it.
13030 (suspend_and_send_sigstop_callback): New.
13031 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
13032 pass them down. If SUSPEND, also increment the lwp's suspend
13033 count.
13034 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
13035 (need_step_over_p): Don't consider suspended LWPs.
13036 (start_step_over): Adjust.
13037 (proceed_one_lwp): Change return type to int, add new `except'
13038 parameter and handle it.
13039 (unsuspend_and_proceed_one_lwp): New.
13040 (proceed_all_lwps): Use find_inferior instead of
13041 for_each_inferior.
13042 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
13043 also decrement the suspend count of LWPs. Pass `except' down,
13044 instead of hacking its suspend count.
13045 (linux_pause_all): Add `freeze' parameter. Adjust.
13046 (linux_unpause_all): New.
13047 (linux_target_ops): Install linux_unpause_all.
13048 * server.c (handle_status): Adjust.
13049 * target.h (struct target_ops): New fields `unpause_all' and
13050 `cancel_breakpoints'. Add new parameter to `pause_all'.
13051 (pause_all): Add new `freeze' parameter.
13052 (unpause_all): New.
13053 (cancel_breakpoints): New.
13054 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
13055 cancel breakpoints.
13056 (cmd_qtstart): Pause threads.
13057 (stop_tracing): Pause threads, and cancel breakpoints.
13058 * win32-low.c (win32_target_ops): Adjust.
13059
13060 2010-05-03 Pedro Alves <pedro@codesourcery.com>
13061
13062 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
13063 the inferior right away from here...
13064 (linux_wait_1): ... to here, and adjust to check the thread's
13065 last_resume_kind instead of the lwp's step or stop_expected flags.
13066
13067 2010-05-02 Pedro Alves <pedro@codesourcery.com>
13068
13069 * README: Use consistent `GDB' and `GDBserver' spellings.
13070
13071 2010-05-02 Pedro Alves <pedro@codesourcery.com>
13072
13073 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
13074 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
13075 (linux_detach_one_lwp): Assume the lwp is stopped.
13076 (any_thread_of): Delete.
13077 (linux_detach): Stop all lwps here. Don't blindly delete all
13078 breakpoints.
13079 (delete_lwp_callback): New.
13080 (linux_mourn): Delete all lwps of the process that is gone.
13081 (linux_wait_1): Don't delete the last lwp of the process here.
13082 * mem-break.h (mark_breakpoints_out): Declare.
13083 * mem-break.c (mark_breakpoints_out): New.
13084 (free_all_breakpoints): Use it.
13085 * server.c (handle_target_event): If the process is gone, mark
13086 breakpoints out.
13087 * thread-db.c (struct thread_db) <create_bp>: New field.
13088 (thread_db_enable_reporting): Fix prototype. Store a thread event
13089 breakpoint reference in the thread_db struct.
13090 (thread_db_load_search): Clear the thread_db object.
13091 (try_thread_db_load_1): Ditto.
13092 (switch_to_process): New.
13093 (disable_thread_event_reporting): Use it.
13094 (remove_thread_event_breakpoints): New.
13095 (thread_db_detach, thread_db_mourn): Use it.
13096
13097 2010-05-01 Pedro Alves <pedro@codesourcery.com>
13098
13099 * linux-low.c (linux_enable_event_reporting): New.
13100 (linux_wait_for_event_1, handle_extended_wait): Use it.
13101
13102 2010-04-30 Pedro Alves <pedro@codesourcery.com>
13103
13104 * linux-low.c (linux_kill_one_lwp, linux_kill)
13105 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
13106 (send_sigstop): Take an lwp_info as parameter instead. Queue a
13107 SIGSTOP even if the LWP is stopped.
13108 (send_sigstop_callback): New.
13109 (stop_all_lwps): Use send_sigstop_callback instead.
13110 (linux_resume_one_thread): Adjust.
13111 (proceed_one_lwp): Still proceed an LWP that the client has
13112 requested to stop, if we haven't reported it as stopped yet. Make
13113 sure that LWPs the client want stopped, have a pending SIGSTOP.
13114
13115 2010-04-26 Doug Evans <dje@google.com>
13116
13117 * server.c (handle_general_set): Make static.
13118
13119 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
13120 Print received char after testing for error/eof instead of before.
13121 (input_interrupt): Tweak comment.
13122
13123 2010-04-23 Doug Evans <dje@google.com>
13124
13125 * server.c (start_inferior): Print inferior argv if --debug.
13126
13127 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
13128
13129 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
13130 * nto-x86-low.c: Include server.h
13131
13132 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
13133
13134 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
13135 be consistent with other sources of this directory.
13136 (init_registers_amd64): Correct name of source file of this function
13137 in the comment.
13138
13139 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13140
13141 * configure.srv (x86_64-*-mingw*): New configuration for Windows
13142 64-bit executables.
13143
13144 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13145
13146 * win32-i386-low.c: Add 64-bit support.
13147 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
13148 (init_registers_amd64): Declare.
13149 (mappings): Add 64-bit version of array.
13150 (init_windows_x86): New function.
13151 (the_low_target): Change init_arch field to init_windows_x86.
13152
13153 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13154
13155 * win32-low.c: Adapt to support also 64-bit architecture.
13156 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
13157 (get_image_name): Use SIZE_T type for local variable `done'.
13158 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
13159 (toolhelp_get_dll_name): Idem.
13160 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
13161 Use uintptr_t typecast to avoid warning.
13162 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
13163 (handle_exception): Use phex_nz to avoid warning.
13164 (win32_wait): Remove unused local variable `process'.
13165
13166 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13167
13168 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
13169 `amd64-avx.o'.
13170
13171 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
13172
13173 * configure.ac: Use `ws2_32' library for srv_mingw.
13174 * configure: Regenerate.
13175 * gdbreplay.c: Include winsock2.h instead of winsock.h.
13176 * remote-utils.c: Likewise.
13177
13178 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
13179
13180 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
13181 if __x86_64__ is defined.
13182
13183 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
13184
13185 * configure: Regenerate.
13186
13187 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
13188
13189 * server.c (handle_query): Handle 'qGetTIBAddr' query.
13190 * target.h (target_ops): New get_tib_address field.
13191 * win32-low.h (win32_thread_info): Add thread_local_base field.
13192 * win32-low.c (child_add_thread): Add tlb argument.
13193 Set thread_local_base field to TLB.
13194 (get_child_debug_event): Adapt to child_add_thread change.
13195 (win32_get_tib_address): New function.
13196 (win32_target_ops): Set get_tib_address field to
13197 win32_get_tib_address.
13198 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
13199
13200 2010-04-12 Pedro Alves <pedro@codesourcery.com>
13201
13202 * linux-low.c (linux_mourn): Also remove the process.
13203 * server.c (handle_target_event): Don't remove the process here.
13204 * nto-low.c (nto_mourn): New.
13205 (nto_target_ops): Install it.
13206 * spu-low.c (spu_mourn): New.
13207 (spu_target_ops): Install it.
13208 * win32-low.c (win32_mourn): New.
13209 (win32_target_ops): Install it.
13210
13211 2010-04-12 Pedro Alves <pedro@codesourcery.com>
13212
13213 * server.h (buffer_xml_printf): Remove redundant `;'.
13214
13215 2010-04-12 Pedro Alves <pedro@codesourcery.com>
13216
13217 * regcache.c (set_register_cache): Invalidate regcaches before
13218 changing the register cache layout.
13219 (regcache_invalidate_one): Allow a NULL regcache.
13220 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
13221 regcaches before changing the register cache layout or the target
13222 regsets.
13223
13224 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
13225
13226 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
13227 variable warning on Linux/x86-64.
13228
13229 2010-04-11 Pedro Alves <pedro@codesourcery.com>
13230
13231 GDBserver disconnected tracing support.
13232
13233 * linux-low.c (linux_remove_process): Delete.
13234 (add_lwp): Don't set last_resume_kind here.
13235 (linux_kill): Use `mourn'.
13236 (linux_detach): Use `thread_db_detach', and `mourn'.
13237 (linux_mourn): New.
13238 (linux_attach_lwp_1): Adjust comment.
13239 (linux_attach): last_resume_kind moved the thread_info; adjust.
13240 (status_pending_p_callback): Adjust.
13241 (linux_wait_for_event_1): Adjust.
13242 (count_events_callback, select_singlestep_lwp_callback)
13243 (select_event_lwp_callback, cancel_breakpoints_callback)
13244 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
13245 (proceed_one_lwp): Adjust.
13246 (linux_async): Add debug output.
13247 (linux_thread_stopped): New.
13248 (linux_pause_all): New.
13249 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
13250 linux_pause_all.
13251 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
13252 (thread_db_free): Delete declaration.
13253 (thread_db_detach, thread_db_mourn): Declare.
13254 * thread-db.c (thread_db_init): Use thread_db_mourn.
13255 (thread_db_free): Delete, split in two.
13256 (disable_thread_event_reporting): New.
13257 (thread_db_detach): New.
13258 (thread_db_mourn): New.
13259
13260 * server.h (struct thread_info) <last_resume_kind>: New field.
13261 <attached>: Add comment.
13262 <gdb_detached>: New field.
13263 (handler_func): Change return type to int.
13264 (handle_serial_event, handle_target_event): Ditto.
13265 (gdb_connected): Declare.
13266 (tracing): Delete.
13267 (disconnected_tracing): Declare.
13268 (stop_tracing): Declare.
13269
13270 * server.c (handle_query) <qSupported>: Report support for
13271 disconnected tracing.
13272 (queue_stop_reply_callback): Account for running threads.
13273 (gdb_wants_thread_stopped): New.
13274 (gdb_wants_all_threads_stopped): New.
13275 (gdb_reattached_process): New.
13276 (handle_status): Clear the `gdb_detached' flag of all processes.
13277 In all-stop, stop all threads.
13278 (main): Be sure to leave tfind mode. Handle disconnected tracing.
13279 (process_serial_event): If the remote connection breaks, or if an
13280 exit was forced with "monitor exit", force an event loop exit.
13281 Handle disconnected tracing on detach.
13282 (handle_serial_event): Adjust.
13283 (handle_target_event): If GDB isn't connected, forward events back
13284 to the inferior, unless the last process exited, in which case,
13285 exit gdbserver. Adjust interface.
13286
13287 * remote-utils.c (remote_open): Don't block in accept. Instead
13288 register an event loop source on the listen socket file
13289 descriptor. Refactor bits into ...
13290 (listen_desc): ... this new global.
13291 (gdb_connected): ... this new function.
13292 (enable_async_notification): ... this new function.
13293 (handle_accept_event): ... this new function.
13294 (remote_close): Clear remote_desc.
13295
13296 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
13297
13298 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
13299 New fields.
13300 (mourn_inferior): Define.
13301 (target_process_qsupported): Avoid the dangling else problem.
13302 (thread_stopped): Define.
13303 (pause_all): Define.
13304 (target_waitstatus_to_string): Declare.
13305 * target.c (target_waitstatus_to_string): New.
13306
13307 * tracepoint.c (tracing): Make extern.
13308 (disconnected_tracing): New.
13309 (stop_tracing): Make extern. Handle tracing stops due to GDB
13310 disconnecting.
13311 (cmd_qtdisconnected): New.
13312 (cmd_qtstatus): Report disconnected tracing status in trace reply.
13313 (handle_tracepoint_general_set): Handle QTDisconnected.
13314
13315 * event-loop.c (event_handler_func): Change return type to int.
13316 (process_event): Bail out if the event handler wants the event
13317 loop to stop.
13318 (handle_file_event): Ditto.
13319 (start_event_loop): Bail out if the event handler wants the event
13320 loop to stop.
13321
13322 * nto-low.c (nto_target_ops): Adjust.
13323 * spu-low.c (spu_wait): Don't remove the process here.
13324 (spu_target_ops): Adjust.
13325 * win32-low.c (win32_wait): Don't remove the process here.
13326 (win32_target_ops): Adjust.
13327
13328 2010-04-11 Pedro Alves <pedro@codesourcery.com>
13329
13330 * regcache.c (realloc_register_cache): Invalidate inferior's
13331 regcache before recreating it.
13332
13333 2010-04-09 Pedro Alves <pedro@codesourcery.com>
13334
13335 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
13336
13337 2010-04-09 Stan Shebs <stan@codesourcery.com>
13338 Pedro Alves <pedro@codesourcery.com>
13339
13340 * server.h (LONGEST): New.
13341 (struct thread_info) <while_stepping>: New field.
13342 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
13343 Declare.
13344 (initialize_tracepoint, handle_tracepoint_general_set)
13345 (handle_tracepoint_query, tracepoint_finished_step)
13346 (tracepoint_was_hit, release_while_stepping_state_list):
13347 (current_traceframe): Declare.
13348 * server.c (handle_general_set): Handle tracepoint packets.
13349 (read_memory): New.
13350 (write_memory): New.
13351 (handle_search_memory_1): Use read_memory.
13352 (handle_query): Report support for conditional tracepoints, trace
13353 state variables, and tracepoint sources. Handle tracepoint
13354 queries.
13355 (main): Initialize the tracepoints module.
13356 (process_serial_event): Handle traceframe reads/writes.
13357
13358 * linux-low.c (handle_tracepoints): New.
13359 (linux_wait_1): Call it.
13360 (linux_resume_one_lwp): Handle while-stepping.
13361 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
13362 (linux_target_ops): Install them.
13363 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
13364 New field.
13365 * linux-x86-low.c (x86_supports_tracepoints): New.
13366 (the_low_target). Install it.
13367
13368 * mem-break.h (delete_breakpoint): Declare.
13369 * mem-break.c (delete_breakpoint): Make external.
13370
13371 * target.h (struct target_ops): Add `supports_tracepoints',
13372 `read_pc', and `write_pc' fields.
13373 (target_supports_tracepoints): Define.
13374 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
13375 (phex_nz): New.
13376
13377 * regcache.h (struct regcache) <registers_owned>: New field.
13378 (init_register_cache, regcache_cpy): Declare.
13379 (regcache_read_pc, regcache_write_pc): Declare.
13380 (register_cache_size): Declare.
13381 (supply_regblock): Declare.
13382 * regcache.c (init_register_cache): New.
13383 (new_register_cache): Use it.
13384 (regcache_cpy): New.
13385 (register_cache_size): New.
13386 (supply_regblock): New.
13387 (regcache_read_pc, regcache_write_pc): New.
13388
13389 * tracepoint.c: New.
13390
13391 * Makefile.in (OBS): Add tracepoint.o.
13392 (tracepoint.o): New rule.
13393
13394 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
13395
13396 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
13397 (i386-mmx.o): New.
13398 (i386-mmx.c): Likewise.
13399 (i386-mmx-linux.o): Likewise.
13400 (i386-mmx-linux.c): Likewise.
13401
13402 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
13403 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
13404 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
13405 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
13406
13407 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
13408 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
13409 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
13410
13411 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
13412
13413 * Makefile.in (clean): Updated.
13414 (i386-avx.o): New.
13415 (i386-avx.c): Likewise.
13416 (i386-avx-linux.o): Likewise.
13417 (i386-avx-linux.c): Likewise.
13418 (amd64-avx.o): Likewise.
13419 (amd64-avx.c): Likewise.
13420 (amd64-avx-linux.o): Likewise.
13421 (amd64-avx-linux.c): Likewise.
13422
13423 * configure.srv (srv_i386_regobj): Add i386-avx.o.
13424 (srv_i386_linux_regobj): Add i386-avx-linux.o.
13425 (srv_amd64_regobj): Add amd64-avx.o.
13426 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
13427 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
13428 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
13429 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
13430 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
13431 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
13432 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
13433
13434 * i387-fp.c: Include "i386-xstate.h".
13435 (i387_xsave): New.
13436 (i387_cache_to_xsave): Likewise.
13437 (i387_xsave_to_cache): Likewise.
13438 (x86_xcr0): Likewise.
13439
13440 * i387-fp.h (i387_cache_to_xsave): Likewise.
13441 (i387_xsave_to_cache): Likewise.
13442 (x86_xcr0): Likewise.
13443
13444 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
13445 * linux-crisv32-low.c (target_regsets): Likewise.
13446 * linux-m68k-low.c (target_regsets): Likewise.
13447 * linux-mips-low.c (target_regsets): Likewise.
13448 * linux-ppc-low.c (target_regsets): Likewise.
13449 * linux-s390-low.c (target_regsets): Likewise.
13450 * linux-sh-low.c (target_regsets): Likewise.
13451 * linux-sparc-low.c (target_regsets): Likewise.
13452 * linux-xtensa-low.c (target_regsets): Likewise.
13453
13454 * linux-low.c: Include <sys/uio.h>.
13455 (regsets_fetch_inferior_registers): Support nt_type.
13456 (regsets_store_inferior_registers): Likewise.
13457 (linux_process_qsupported): New.
13458 (linux_target_ops): Add linux_process_qsupported.
13459
13460 * linux-low.h (regset_info): Add nt_type.
13461 (linux_target_ops): Add process_qsupported.
13462
13463 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
13464 and <sys/uio.h>.
13465 (init_registers_i386_avx_linux): New.
13466 (init_registers_amd64_avx_linux): Likewise.
13467 (xmltarget_i386_linux_no_xml): Likewise.
13468 (xmltarget_amd64_linux_no_xml): Likewise.
13469 (PTRACE_GETREGSET): Likewise.
13470 (PTRACE_SETREGSET): Likewise.
13471 (x86_fill_xstateregset): Likewise.
13472 (x86_store_xstateregset): Likewise.
13473 (use_xml): Likewise.
13474 (x86_linux_update_xmltarget): Likewise.
13475 (x86_linux_process_qsupported): Likewise.
13476 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
13477 (x86_arch_setup): Don't call init_registers_amd64_linux nor
13478 init_registers_i386_linux here. Call
13479 x86_linux_update_xmltarget.
13480 (the_low_target): Add x86_linux_process_qsupported.
13481
13482 * server.c (handle_query): Call target_process_qsupported.
13483
13484 * target.h (target_ops): Add process_qsupported.
13485 (target_process_qsupported): New.
13486
13487 2010-04-03 Pedro Alves <pedro@codesourcery.com>
13488
13489 * inferiors.c (add_thread): Set last_status kind to
13490 TARGET_WAITKIND_IGNORE.
13491 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
13492 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
13493 (linux_wait_1): Move `thread' local definition to block that uses
13494 it. Don't NULL initialize `event_child'.
13495 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
13496 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
13497 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
13498
13499 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13500
13501 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
13502 an extended waitstatus, or by a watchpoint.
13503 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
13504 thread was stepping or has been stopped by a watchpoint.
13505
13506 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13507
13508 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
13509 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
13510 of another, then delete the previous, and validate all
13511 breakpoints.
13512 (validate_inserted_breakpoint): New.
13513 (delete_disabled_breakpoints): New.
13514 (validate_breakpoints): New.
13515 (check_mem_read): Validate breakpoints before trusting their
13516 shadow. Delete disabled breakpoints.
13517 (check_mem_write): Validate breakpoints before trusting they
13518 should be inserted. Delete disabled breakpoints.
13519 * mem-break.h (validate_breakpoints):
13520 * server.c (handle_query): Validate breakpoints when we see a
13521 qSymbol query.
13522
13523 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13524
13525 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
13526 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
13527 if we could tell there's a GDB breakpoint at stop_pc.
13528 (need_step_over_p): Don't do a step over if we find a GDB
13529 breakpoint at the resume PC.
13530
13531 * mem-break.c (struct raw_breakpoint): New.
13532 (enum bkpt_type): New type `gdb_breakpoint'.
13533 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
13534 fields. New field `raw'.
13535 (find_raw_breakpoint_at): New.
13536 (set_raw_breakpoint_at): Handle refcounting. Create a raw
13537 breakpoint instead.
13538 (set_breakpoint_at): Adjust.
13539 (delete_raw_breakpoint): New.
13540 (release_breakpoint): New.
13541 (delete_breakpoint): Rename to...
13542 (delete_breakpoint_1): ... this. Add proc parameter. Use
13543 release_breakpoint. Return ENOENT.
13544 (delete_breakpoint): Reimplement.
13545 (find_breakpoint_at): Delete.
13546 (find_gdb_breakpoint_at): New.
13547 (delete_breakpoint_at): Delete.
13548 (set_gdb_breakpoint_at): New.
13549 (delete_gdb_breakpoint_at): New.
13550 (gdb_breakpoint_here): New.
13551 (set_reinsert_breakpoint): Use release_breakpoint.
13552 (uninsert_breakpoint): Rename to ...
13553 (uninsert_raw_breakpoint): ... this.
13554 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
13555 (reinsert_raw_breakpoint): Change parameter type to
13556 raw_breakpoint.
13557 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
13558 instead.
13559 (check_breakpoints): Adjust. Use release_breakpoint.
13560 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
13561 (breakpoint_inserted_here): Ditto.
13562 (check_mem_read): Adjust to iterate over raw breakpoints instead.
13563 Don't trust the breakpoint's shadow if it is not inserted.
13564 (check_mem_write): Adjust to iterate over raw breakpoints instead.
13565 (delete_all_breakpoints): Adjust.
13566 (free_all_breakpoints): Mark all breakpoints as uninserted, and
13567 use delete_breakpoint_1.
13568
13569 * mem-break.h (breakpoints_supported): Delete declaration.
13570 (set_gdb_breakpoint_at): Declare.
13571 (gdb_breakpoint_here): Declare.
13572 (delete_breakpoint_at): Delete.
13573 (delete_gdb_breakpoint_at): Declare.
13574
13575 * server.h (struct raw_breakpoint): Forward declare.
13576 (struct process_info): New field `raw_breakpoints'.
13577
13578 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
13579 breakpoints.
13580
13581 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13582
13583 * linux-low.c (status_pending_p_callback): Fix comment.
13584 (linux_wait_for_event_1): Move most of the internal breakpoint
13585 handling from here...
13586 (linux_wait_1): ... to here.
13587 (count_events_callback): New.
13588 (select_singlestep_lwp_callback): New.
13589 (select_event_lwp_callback): New.
13590 (cancel_breakpoints_callback): New.
13591 (select_event_lwp): New.
13592 (linux_wait_1): Simplify internal breakpoint handling. Give equal
13593 priority to all LWPs that have had events that should be reported
13594 to the client. Cancel breakpoints when about to reporting the
13595 event to the client, not while stopping lwps. No longer cancel
13596 finished single-steps here.
13597 (cancel_finished_single_step): Delete.
13598 (cancel_finished_single_steps): Delete.
13599
13600 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13601
13602 * mem-break.c (enum bkpt_type): New.
13603 (struct breakpoint): New field `type'.
13604 (set_breakpoint_at): Change return type to struct breakpoint
13605 pointer. Set type to `other_breakpoint' by default.
13606 (delete_breakpoint): Rewrite, supporting more than one breakpoint
13607 in the breakpoint list.
13608 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
13609 (reinsert_breakpoint): Rename to ...
13610 (reinsert_raw_breakpoint): ... this.
13611 (reinsert_breakpoints_at): Adjust.
13612 * mem-break.h (struct breakpoint): Declare.
13613 (set_breakpoint_at): Change return type to struct breakpoint
13614 pointer.
13615
13616 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13617
13618 * server.c (handle_query): Assign, not compare.
13619
13620 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13621
13622 Teach linux gdbserver to step-over-breakpoints.
13623
13624 * linux-low.c (can_hardware_single_step): New.
13625 (supports_breakpoints): New.
13626 (handle_extended_wait): If stopping threads, read the stop pc of
13627 the new cloned LWP.
13628 (get_pc): New.
13629 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
13630 low target doesn't support retrieving the PC.
13631 (add_lwp): Set last_resume_kind to resume_continue.
13632 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
13633 (linux_attach): Don't clear stop_expected. Set the lwp's
13634 last_resume_kind to resume_stop.
13635 (linux_detach_one_lwp): Don't check for removed breakpoints.
13636 (check_removed_breakpoint): Delete.
13637 (status_pending_p): Rename to ...
13638 (status_pending_p_callback): ... this. Don't check for removed
13639 breakpoints. Don't consider threads that are stopped from GDB's
13640 perspective.
13641 (linux_wait_for_lwp): Always read the stop_pc here.
13642 (cancel_breakpoint): New.
13643 (step_over_bkpt): New global.
13644 (linux_wait_for_event_1): Implement stepping over breakpoints.
13645 (gdb_wants_lwp_stopped): New.
13646 (gdb_wants_all_stopped): New.
13647 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
13648 single-step traps here. Store the thread's last reported target
13649 wait status.
13650 (send_sigstop): Don't clear stop_expected. Always set it,
13651 instead.
13652 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
13653 (cancel_finished_single_step): New.
13654 (cancel_finished_single_steps): New.
13655 (wait_for_sigstop): Don't cancel finished single-step traps here.
13656 (linux_resume_one_lwp): Don't check for removed breakpoints.
13657 Don't set `step' on non-hardware step archs.
13658 (linux_set_resume_request): Ignore resume_stop requests if already
13659 stopping or stopped. Set the lwp's last_resume_kind.
13660 (resume_status_pending_p): Don't check for removed breakpoints.
13661 (need_step_over_p): New.
13662 (start_step_over): New.
13663 (finish_step_over): New.
13664 (linux_resume_one_thread): Always queue a sigstop for resume_stop
13665 requests. Clear the thread's last reported target waitstatus.
13666 Don't use the `suspended' flag. Don't consider pending breakpoints.
13667 (linux_resume): Start a step-over if necessary.
13668 (proceed_one_lwp): New.
13669 (proceed_all_lwps): New.
13670 (unstop_all_lwps): New.
13671 * linux-low.h (struct lwp_info): Rewrite comment for the
13672 `suspended' flag. Add the `stop_pc' field. Delete the
13673 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
13674 Add `'last_resume_kind' and `need_step_over' fields.
13675 * inferiors.c (struct thread_info): Delete, moved elsewhere.
13676 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
13677 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
13678 (set_raw_breakpoint_at): New.
13679 (set_breakpoint_at): Rewrite to use it.
13680 (reinsert_breakpoint_handler): Delete.
13681 (set_reinsert_breakpoint): New.
13682 (reinsert_breakpoint_by_bp): Delete.
13683 (delete_reinsert_breakpoints): New.
13684 (uninsert_breakpoint): Rewrite.
13685 (uninsert_breakpoints_at): New.
13686 (reinsert_breakpoint): Rewrite.
13687 (reinsert_breakpoints_at): New.
13688 (check_breakpoints): Rewrite.
13689 (breakpoint_here): New.
13690 (breakpoint_inserted_here): New.
13691 (check_mem_read): Adjust.
13692 * mem-break.h (breakpoints_supported, breakpoint_here)
13693 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
13694 (reinsert_breakpoint_by_bp): Delete declaration.
13695 (delete_reinsert_breakpoints): Declare.
13696 (reinsert_breakpoint): Delete declaration.
13697 (reinsert_breakpoints_at): Declare.
13698 (uninsert_breakpoint): Delete declaration.
13699 (uninsert_breakpoints_at): Declare.
13700 (check_breakpoints): Adjust prototype.
13701 * server.h: Adjust include order.
13702 (struct thread_info): Declare here. Add a `last_status' field.
13703
13704 2010-03-23 Michael Snyder <msnyder@vmware.com>
13705
13706 * server.c (crc32): New function.
13707 (handle_query): Add handling for 'qCRC:' request.
13708
13709 2010-03-23 Pedro Alves <pedro@codesourcery.com>
13710
13711 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
13712 lwp had been stopped by a watchpoint.
13713
13714 2010-03-16 Pedro Alves <pedro@codesourcery.com>
13715
13716 * server.h (internal_error): Declare.
13717 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
13718 * utils.c (internal_error): New function.
13719
13720 2010-03-15 Andreas Schwab <schwab@redhat.com>
13721
13722 * configure.srv: Fix typo setting srv_regobj.
13723
13724 2010-03-15 Pedro Alves <pedro@codesourcery.com>
13725
13726 * linux-low.c (fetch_register): Avoid passing a non string literal
13727 format to `error'.
13728 (usr_store_inferior_registers): Ditto.
13729
13730 2010-03-14 Pedro Alves <pedro@codesourcery.com>
13731
13732 * linux-low.c (linux_write_memory): Bail out early if peeking
13733 memory failed.
13734
13735 2010-03-14 Pedro Alves <pedro@codesourcery.com>
13736
13737 * linux-low.h (struct lwp_info): New fields
13738 `stopped_by_watchpoint' and `stopped_data_address'.
13739 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
13740 here, and cache them in the lwp object.
13741 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
13742 directly.
13743 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
13744 field.
13745 (linux_stopped_by_watchpoint): Rewrite.
13746 (linux_stopped_data_address): Rewrite.
13747
13748 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
13749
13750 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
13751 switching the current inferior, not before.
13752
13753 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
13754
13755 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
13756 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
13757 i386-linux.c and amd64-linux.c.
13758 (reg-i386.o): Removed.
13759 (reg-i386.c): Likewise.
13760 (reg-i386-linux.o): Likewise.
13761 (reg-i386-linux.c): Likewise.
13762 (reg-x86-64.o): Likewise.
13763 (reg-x86-64.c): Likewise.
13764 (reg-x86-64-linux.o): Likewise.
13765 (reg-x86-64-linux.c): Likewise.
13766 (i386.o): New.
13767 (i386.c): Likewise.
13768 (i386-linux.o): Likewise.
13769 (i386-linux.c): Likewise.
13770 (amd64.o): Likewise.
13771 (amd64.c): Likewise.
13772 (amd64-linux.o): Likewise.
13773 (amd64-linux.c): Likewise.
13774
13775 * configure.srv (srv_i386_regobj): New.
13776 (srv_i386_linux_regobj): Likewise.
13777 (srv_amd64_regobj): Likewise.
13778 (srv_amd64_linux_regobj): Likewise.
13779 (srv_i386_32bit_xmlfiles): Likewise.
13780 (srv_i386_64bit_xmlfiles): Likewise.
13781 (srv_i386_xmlfiles): Likewise.
13782 (srv_amd64_xmlfiles): Likewise.
13783 (srv_i386_linux_xmlfiles): Likewise.
13784 (srv_amd64_linux_xmlfiles): Likewise.
13785 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
13786 srv_xmlfiles to $srv_i386_xmlfiles.
13787 (i[34567]86-*-mingw32ce*): Likewise.
13788 (i[34567]86-*-mingw*): Likewise.
13789 (i[34567]86-*-nto*): Likewise.
13790 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
13791 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
13792 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
13793 (x86_64-*-linux*): Likewise.
13794
13795 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
13796 (init_registers_amd64_linux): New.
13797 (x86_arch_setup): Replace init_registers_x86_64_linux with
13798 init_registers_amd64_linux.
13799
13800 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
13801
13802 * configure.ac: Check for libdl. If it is not available link against
13803 static libthread_db.
13804 * configure: Regenerate.
13805
13806 2010-02-22 Pedro Alves <pedro@codesourcery.com>
13807
13808 PR9605
13809
13810 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
13811 handing a read watchpoint.
13812 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
13813
13814 2010-02-12 Doug Evans <dje@google.com>
13815
13816 * linux-low.c (linux_supports_tracefork_flag): Document.
13817 (linux_look_up_symbols): Add comment.
13818
13819 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
13820
13821 * regcache.c (supply_register): Clear regcache if buf is NULL.
13822
13823 2010-02-02 Nicolas Roche <roche@sourceware.org>
13824 Joel Brobecker <brobecker@adacore.com>
13825
13826 * inferiors.c (find_inferior): Add function documentation.
13827 (unloaded_dll): Handle the case where the unloaded dll has not
13828 been previously registered in the dll list.
13829
13830 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
13831
13832 * linux-arm-low.c (thumb_breakpoint_len): Delete.
13833 (thumb2_breakpoint): New.
13834 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
13835
13836 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
13837
13838 * linux-low.c (get_stop_pc): Check for SIGTRAP.
13839 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
13840 breakpoints.
13841
13842 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13843
13844 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
13845
13846 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13847
13848 * linux-s390-low.c (s390_collect_ptrace_register)
13849 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
13850
13851 2010-01-21 Doug Evans <dje@google.com>
13852
13853 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
13854 (PTRACE_ARG4_TYPE): New macro.
13855 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
13856 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
13857 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
13858 (usr_store_inferior_registers): Ditto.
13859 (linux_read_memory, linux_write_memory): Ditto.
13860 (linux_test_for_tracefork): Ditto.
13861
13862 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
13863 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
13864
13865 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13866
13867 * proc-service.c (ps_lgetregs): Don't refetch registers from the
13868 target.
13869
13870 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13871
13872 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
13873 prototype to take a regcache. Adjust.
13874
13875 2010-01-20 Pedro Alves <pedro@codesourcery.com>
13876
13877 * regcache.h (struct thread_info): Forward declare.
13878 (struct regcache): New.
13879 (new_register_cache): Adjust prototype.
13880 (get_thread_regcache): Declare.
13881 (free_register_cache): Adjust prototype.
13882 (registers_to_string, registers_from_string): Ditto.
13883 (supply_register, supply_register_by_name, collect_register)
13884 (collect_register_as_string, collect_register_by_name): Ditto.
13885 * regcache.c (struct inferior_regcache_data): Delete.
13886 (get_regcache): Rename to ...
13887 (get_thread_regcache): ... this. Adjust. Switch inferior before
13888 fetching registers.
13889 (regcache_invalidate_one): Adjust.
13890 (regcache_invalidate): Fix prototype.
13891 (new_register_cache): Return the new register cache.
13892 (free_register_cache): Change prototype.
13893 (realloc_register_cache): Adjust.
13894 (registers_to_string): Change prototype to take a regcache. Adjust.
13895 (registers_from_string): Ditto.
13896 (register_data): Ditto.
13897 (supply_register): Ditto.
13898 (supply_register_by_name): Ditto.
13899 (collect_register): Ditto.
13900 (collect_register_as_string): Ditto.
13901 (collect_register_by_name): Ditto.
13902 * server.c (process_serial_event): Adjust.
13903 * linux-low.h (regset_fill_func, regset_store_func): Change
13904 prototype.
13905 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
13906 Change prototype.
13907 * linux-low.c (get_stop_pc): Adjust.
13908 (check_removed_breakpoint): Adjust.
13909 (linux_wait_for_event): Adjust.
13910 (linux_resume_one_lwp): Adjust.
13911 (fetch_register): Add regcache parameter. Adjust.
13912 (usr_store_inferior_registers): Ditto.
13913 (regsets_fetch_inferior_registers): Ditto.
13914 (regsets_store_inferior_registers): Ditto.
13915 (linux_fetch_registers, linux_store_registers): Ditto.
13916 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
13917 regcache. Adjust.
13918 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
13919 Ditto.
13920 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
13921 prototype to take a regcache.
13922 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
13923 * remote-utils.c (convert_ascii_to_int, outreg)
13924 (prepare_resume_reply): Change prototype to take a regcache.
13925 Adjust.
13926 * target.h (struct target_ops) <fetch_registers, store_registers>:
13927 Change prototype to take a regcache.
13928 (fetch_inferior_registers, store_inferior_registers): Change
13929 prototype to take a regcache. Adjust.
13930 * proc-service.c (ps_lgetregs): Adjust.
13931 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
13932 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
13933 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
13934 take a regcache. Adjust.
13935 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
13936 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
13937 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
13938 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
13939 * linux-cris-low.c (cris_get_pc, cris_set_pc)
13940 (cris_cannot_fetch_register):
13941 (cris_breakpoint_at): Change prototype to take a regcache.
13942 Adjust.
13943 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
13944 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
13945 to take a regcache. Adjust.
13946 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
13947 Adjust.
13948 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
13949 take a regcache. Adjust.
13950 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
13951 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
13952 (m68k_set_pc): Change prototype to take a regcache. Adjust.
13953 * linux-mips-low.c (mips_get_pc):
13954 (mips_set_pc): Change prototype to take a regcache. Adjust.
13955 (mips_reinsert_addr): Adjust.
13956 (mips_collect_register): Change prototype to take a regcache.
13957 Adjust.
13958 (mips_supply_register):
13959 (mips_collect_register_32bit, mips_supply_register_32bit)
13960 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
13961 (mips_store_fpregset): Ditto.
13962 * linux-ppc-low.c (ppc_supply_ptrace_register)
13963 (ppc_supply_ptrace_register): Ditto.
13964 (parse_spufs_run): Adjust.
13965 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
13966 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
13967 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
13968 take a regcache. Adjust.
13969 * linux-s390-low.c (s390_collect_ptrace_register)
13970 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
13971 (s390_set_pc): Change prototype to take a regcache. Adjust.
13972 (s390_arch_setup): Adjust.
13973 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
13974 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
13975 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
13976 (sparc_fill_gregset, sparc_store_gregset_from_stack)
13977 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
13978 regcache. Adjust.
13979 (sparc_breakpoint_at): Adjust.
13980 * linux-xtensa-low.c (xtensa_fill_gregset):
13981 (xtensa_store_gregset):
13982 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
13983 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
13984 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
13985 prototype to take a regcache. Adjust.
13986 * win32-arm-low.c (arm_fetch_inferior_register)
13987 (arm_store_inferior_register): Change prototype to take a
13988 regcache. Adjust.
13989 * win32-i386-low.c (i386_fetch_inferior_register)
13990 (i386_store_inferior_register): Change prototype to take a
13991 regcache. Adjust.
13992 * win32-low.c (child_fetch_inferior_registers)
13993 (child_store_inferior_registers): Change prototype to take a
13994 regcache. Adjust.
13995 (win32_wait): Adjust.
13996 (win32_fetch_inferior_registers): Change prototype to take a
13997 regcache. Adjust.
13998 (win32_store_inferior_registers): Adjust.
13999 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
14000 store_inferior_register>: Change prototype to take a regcache.
14001
14002 2010-01-20 Doug Evans <dje@google.com>
14003
14004 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
14005 #ifdef.
14006 (linux_wait_for_event1, linux_init_signals): Ditto.
14007 (W_STOPCODE): Provide definition if missing.
14008
14009 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
14010
14011 * linux-low.c (linux_core_of_thread): New.
14012 (compare_ints, show_process, list_threads): New.
14013 (linux_qxfer_osdata): Report threads and cores.
14014 (linux_target_op): Register linux_core_of_thread.
14015 * remote-utils.c (prepare_resume_reply): Report the core.
14016 (buffer_xml_printf): Support %d specifier.
14017 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
14018 New.
14019 (handle_query): Handle qXfer:threads. Announce availability
14020 thereof.
14021 * target.h (struct target_ops): New field core_of_thread.
14022
14023 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
14024
14025 * Makefile.in (clean): Remove new generated files.
14026 (reg-s390.o, reg-s390.c): Remove rules.
14027 (reg-s390x.o, reg-s390x.c): Likewise.
14028 (s390-linux32.o, s390-linux32.c): Add rules.
14029 (s390-linux64.o, s390-linux64.c): Likewise.
14030 (s390x-linux64.o, s390x-linux64.c): Likewise.
14031 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
14032 * linux-s390-low.c: Include <elf.h>.
14033 (HWCAP_S390_HIGH_GPRS): Define if undefined.
14034 (init_registers_s390): Remove prototype.
14035 (init_registers_s390x): Likewise.
14036 (init_registers_s390_linux32): Add prototype.
14037 (init_registers_s390_linux64): Likewise.
14038 (init_registers_s390x_linux64): Likewise.
14039 (s390_num_regs_3264): New define.
14040 (s390_regmap_3264): New global variable.
14041 (s390_cannot_fetch_register): Remove obsolete check.
14042 (s390_cannot_store_register): Likewise.
14043 (s390_collect_ptrace_register): Handle upper/lower register halves.
14044 (s390_supply_ptrace_register): Likewise.
14045 (s390_fill_gregset): Update to register number changes.
14046 (s390_get_hwcap): New routine.
14047 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
14048 Install appropriate regmap and register set.
14049
14050 2010-01-01 Joel Brobecker <brobecker@adacore.com>
14051
14052 * server.c (gdbserver_version): Update copyright year to 2010.
14053 * gdbreplay.c (gdbreplay_version): Likewise.
14054
14055 2009-12-28 Doug Evans <dje@google.com>
14056
14057 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
14058 elf/external.h. Include <elf.h> instead but only if necessary.
14059
14060 2009-12-28 Pedro Alves <pedro@codesourcery.com>
14061
14062 * linux-low.c (linux_remove_process): Remove `detaching'
14063 parameter. Don't release/detach from thread_db here.
14064 (linux_kill): Release/detach from thread_db here, ...
14065 (linux_detach): ... and here, before actually detaching.
14066 (linux_wait_1): ... and here, when a process exits.
14067 * thread-db.c (any_thread_of): New.
14068 (thread_db_free): Switch the current inferior to a thread of the
14069 passed in process.
14070
14071 2009-12-21 Doug Evans <dje@google.com>
14072
14073 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
14074
14075 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
14076 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
14077 warning ifndef __NR_tkill. Move setting of errno there too.
14078 Delete unnecessary resetting of errno after syscall.
14079 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
14080
14081 * configure.ac: Check for dladdr.
14082 * config.in: Regenerate.
14083 * configure: Regenerate.
14084 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
14085 (try_thread_db_load): Update.
14086
14087 * linux-low.c (my_waitpid): Delete unnecessary prototype.
14088
14089 2009-12-18 Doug Evans <dje@google.com>
14090
14091 * event-loop.c: Include unistd.h if it exists.
14092
14093 * linux-low.c (my_waitpid): Move definition away from being in
14094 between linux_tracefork_child/linux_test_for_tracefork.
14095
14096 * gdb_proc_service.h (psaddr_t): Fix type.
14097 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
14098 signature to match glibc.
14099
14100 2009-12-16 Doug Evans <dje@google.com>
14101
14102 * linux-low.c (linux_read_memory): Fix argument to read.
14103
14104 2009-11-26 Pedro Alves <pedro@codesourcery.com>
14105
14106 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
14107 events, don't leave current_inferior pointing at null.
14108
14109 2009-11-26 Pedro Alves <pedro@codesourcery.com>
14110
14111 * win32-low.c (LOG): Delete.
14112 (OUTMSG): Output to stderr.
14113 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
14114 on compile time LOG macro.
14115 (win32_wait): Fix debug output.
14116
14117 2009-11-26 Pedro Alves <pedro@codesourcery.com>
14118
14119 * win32-low.c (win32_add_one_solib): If the dll name is
14120 "ntdll.dll", prepend the system directory to the dll path.
14121
14122 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
14123
14124 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
14125
14126 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
14127 Vladimir Prus <vladimir@codesourcery.com>
14128
14129 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
14130 * configure.ac: Check for __mcoldfire__ and set
14131 gdb_cv_m68k_is_coldfire.
14132 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
14133 reg-cf.o and reg-m68k.o.
14134 * configure: Regenerated.
14135
14136 2009-11-16 Pedro Alves <pedro@codesourcery.com>
14137
14138 * linux-low.c (linux_remove_process): Add `detaching' parameter.
14139 Pass it to thread_db_free.
14140 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
14141 proper `detaching' argument to linux_remove_process.
14142 * linux-low.h (thread_db_free): Add `detaching' parameter.
14143 * thread-db.c (thread_db_init): Pass false as `detaching' argument
14144 to thread_db_free.
14145 (thread_db_free): Add `detaching' parameter. Only
14146 call td_ta_clear_event if detaching from process.
14147
14148 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
14149
14150 * thread-db.c (thread_db_free): Fix typo.
14151
14152 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
14153
14154 PR gdb/10838
14155 * thread-db.c (thread_db_free): Call td_ta_clear_event.
14156
14157 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
14158
14159 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
14160 with an i686 compiler.
14161 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
14162 needed.
14163 * configure: Rebuilt.
14164
14165 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
14166
14167 PR gdb/10783
14168
14169 * server.c (handle_search_memory_1): Correct read_addr initialization
14170 in loop for searching subsequent chunks.
14171
14172 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
14173
14174 * configure.ac: New --with-libthread-db option.
14175 * thread-db.c: Allow direct dependence on libthread_db.
14176 (thread_db_free): Adjust.
14177 * config.in: Regenerate.
14178 * configure: Likewise.
14179
14180 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
14181
14182 PR gdb/10757
14183 * thread-db.c (attach_thread): New function.
14184 (maybe_attach_thread): Return success/failure.
14185 (find_new_threads_callback): Adjust.
14186 (thread_db_find_new_threads): Loop until no new threads.
14187
14188 2009-10-13 Pedro Alves <pedro@codesourcery.com>
14189
14190 * proc-service.c (ps_lgetregs): Formatting.
14191
14192 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
14193
14194 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
14195 * configure.ac: Adjust.
14196 * linux-low.h (struct process_info_private): Move members to struct
14197 thread_db.
14198 (thread_db_free, thread_db_handle_monitor_command): New prototype.
14199 * linux-low.c (linux_remove_process): Adjust.
14200 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
14201 * server.c (handle_query): Move code ...
14202 (handle_monitor_command): ... here. New function.
14203 * target.h (struct target_ops): New member.
14204 * thread-db.c (struct thread_db): New.
14205 (libthread_db_search_path): New variable.
14206 (thread_db_create_event, thread_db_enable_reporting)
14207 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
14208 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
14209 (try_thread_db_load_1, dladdr_to_soname): New functions.
14210 (try_thread_db_load, thread_db_load_search): New functions.
14211 (thread_db_init): Search for libthread_db.
14212 (thread_db_free): New function.
14213 (thread_db_handle_monitor_command): Likewise.
14214 * config.in: Regenerate.
14215 * configure: Regenerate.
14216
14217 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
14218
14219 * spu-low.c (spu_kill): Wait for inferior to terminate.
14220 Call clear_inferiors.
14221 (spu_detach): Call clear_inferiors.
14222
14223 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
14224
14225 * aclocal.m4: Regenerate.
14226 * config.in: Likewise.
14227 * configure: Likewise.
14228
14229 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14230
14231 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
14232 (parse_spufs_run): New function.
14233 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
14234 (ppc_breakpoint_at): Handle SPU breakpoints.
14235
14236 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14237
14238 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
14239 (SPUFS_MAGIC): Define.
14240 (spu_enumerate_spu_ids): New function.
14241 (linux_qxfer_spu): New function.
14242 (linux_target_ops): Install linux_qxfer_spu.
14243
14244 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14245
14246 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
14247 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
14248 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
14249 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
14250 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
14251 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
14252 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
14253 (init_registers_powerpc_cell32l): Add prototype.
14254 (init_registers_powerpc_cell64l): Likewise.
14255 (ppc_arch_setup): Detect Cell/B.E. architecture.
14256
14257 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
14258
14259 * Makefile.in (datarootdir): New variable.
14260
14261 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
14262
14263 * linux-low.c (linux_write_memory): Update debugging output.
14264 * Makefile.in (clean): Add new descriptions.
14265 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
14266 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
14267 * configure.srv: Add new files for arm*-*-linux*.
14268 * linux-arm-low.c: Add new declarations.
14269 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
14270 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
14271 (HWCAP_VFPv3D16): New.
14272 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
14273 instead of __IWMMXT__.
14274 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
14275 (arm_arch_setup): New.
14276 (target_regsets): Remove #ifdef. Add VFP regset.
14277 (the_low_target): Use arm_arch_setup.
14278
14279 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
14280
14281 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
14282 the main thread again.
14283
14284 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
14285
14286 Adding Neutrino gdbserver.
14287 * configure: Regenerated.
14288 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
14289 * configure.srv (i[34567]86-*-nto*): New target.
14290 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
14291 * remote-utils.c [__QNX__]: Include sys/iomgr.h
14292 (nto_comctrl) [__QNX__]: New function.
14293 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
14294
14295 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
14296
14297 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
14298 srv_tgtobj.
14299
14300 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
14301 Pedro Alves <pedro@codesourcery.com>
14302
14303 * win32-i386-low.c (i386_get_thread_context): Handle systems that
14304 don't support CONTEXT_EXTENDED_REGISTERS.
14305 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
14306 (the_low_target): Install them.
14307 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
14308 failing with ERROR_PIPE_NOT_CONNECTED.
14309
14310 2009-06-30 Doug Evans <dje@google.com>
14311 Pierre Muller <muller@ics.u-strasbg.fr>
14312
14313 Add h/w watchpoint support to x86-linux, win32-i386.
14314 * Makefile.in (SFILES): Add i386-low.c
14315 (i386_low_h): Define.
14316 (i386-low.o): Add dependencies.
14317 (linux-x86-low.o): Add i386-low.h dependency.
14318 (win32-i386-low.o): Ditto.
14319 * i386-low.c: New file.
14320 * i386-low.h: New file.
14321 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
14322 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
14323 * linux-low.c (linux_add_process): Initialize arch_private.
14324 (linux_remove_process): Free arch_private.
14325 (add_lwp): Initialize arch_private.
14326 (delete_lwp): Free arch_private.
14327 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
14328 provided.
14329 * linux-low.h (process_info_private): New member arch_private.
14330 (lwp_info): New member arch_private.
14331 (linux_target_ops): New members new_process, new_thread,
14332 prepare_to_resume.
14333 (ptid_of): New macro.
14334 * linux-x86-low.c: Include stddef.h, i386-low.h.
14335 (arch_process_info): New struct.
14336 (arch_lwp_info): New struct.
14337 (x86_linux_dr_get, x86_linux_dr_set): New functions.
14338 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
14339 (i386_dr_low_get_status): New function.
14340 (x86_insert_point, x86_remove_point): New functions.
14341 (x86_stopped_by_watchpoint): New function.
14342 (x86_stopped_data_address): New function.
14343 (x86_linux_new_process, x86_linux_new_thread): New functions.
14344 (x86_linux_prepare_to_resume): New function.
14345 (the_low_target): Add entries for insert_point, remove_point,
14346 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
14347 prepare_to_resume.
14348 * server.c (debug_hw_points): New global.
14349 (monitor_show_help): Document set debug-hw-points.
14350 (handle_query): Process "set debug-hw-points".
14351 * server.h (debug_hw_points): Declare.
14352 (paddress): Declare.
14353 * utils.c (NUMCELLS, CELLSIZE): New macros.
14354 (get_sell, xsnprintf, paddress): New functions.
14355 * win32-arm-low.c (the_low_target): Add entries for insert_point,
14356 remove_point, stopped_by_watchpoint, stopped_data_address.
14357 * win32-i386-low.c: Include i386-low.h.
14358 (debug_reg_state): Replaces dr.
14359 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
14360 (i386_dr_low_get_status): New function.
14361 (i386_insert_point, i386_remove_point): New functions.
14362 (i386_stopped_by_watchpoint): New function.
14363 (i386_stopped_data_address): New function.
14364 (i386_initial_stuff): Update.
14365 (get_thread_context,set_thread_context,i386_thread_added): Update.
14366 (the_low_target): Add entries for insert_point,
14367 remove_point, stopped_by_watchpoint, stopped_data_address.
14368 * win32-low.c (win32_insert_watchpoint): New function.
14369 (win32_remove_watchpoint): New function.
14370 (win32_stopped_by_watchpoint): New function.
14371 (win32_stopped_data_address): New function.
14372 (win32_target_ops): Add entries for insert_watchpoint,
14373 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
14374 * win32-low.h (win32_target_ops): New members insert_point,
14375 remove_point, stopped_by_watchpoint, stopped_data_address.
14376
14377 2009-06-25 Pedro Alves <pedro@codesourcery.com>
14378
14379 * server.c (process_serial_event): Re-return unsupported, not
14380 error, if the type isn't recognized. Re-allow supporting only
14381 insert or remove packets. Also call require_running for
14382 breakpoints. Add missing break statement to default case. Tidy.
14383 * target.h (struct target_ops): Rename insert_watchpoint to
14384 insert_point, and remove_watchpoint to remove_point.
14385
14386 * linux-low.h (struct linux_target_ops): Likewise.
14387 * linux-low.c (linux_insert_watchpoint): Rename to ...
14388 (linux_insert_point): ... this. Adjust.
14389 (linux_remove_watchpoint): Rename to ...
14390 (linux_remove_point): ... this. Adjust.
14391 (linux_target_ops): Adjust.
14392 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
14393 (cris_insert_point): ... this.
14394 (cris_remove_watchpoint): Rename to ...
14395 (cris_remove_point): ... this.
14396 (the_low_target): Adjust.
14397
14398 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
14399
14400 * server.c (handle_v_kill): Pass signal_pid to
14401 kill_inferior if multi_process is zero.
14402
14403 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
14404
14405 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
14406 * target.h (target_ops): Comment for *_watchpoint to make it clear
14407 the functions can get types '0' and '1'.
14408
14409 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
14410
14411 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
14412 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
14413 * regcache.c (get_regcache): Likewise.
14414 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
14415 * win32-low.c (child_fetch_inferior_registers): Remove check for
14416 regno 0.
14417
14418 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
14419 Pedro Alves <pedro@codesourcery.com>
14420
14421 * target.h (struct target_ops) <supports_multi_process>: New
14422 callback.
14423 (target_supports_multi_process): New.
14424 * server.c (handle_query): Even if GDB reports support, only
14425 enable multi-process if the target also supports it. Report
14426 multi-process support only if the target backend supports it.
14427 * linux-low.c (linux_supports_multi_process): New function.
14428 (linux_target_ops): Install it as target_supports_multi_process
14429 callback.
14430
14431 2009-05-24 Doug Evans <dje@google.com>
14432
14433 Global renaming of find_thread_pid to find_thread_ptid.
14434 * server.h (find_thread_ptid): Renamed from find_thread_pid.
14435 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
14436 All callers updated.
14437
14438 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
14439 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
14440 directly.
14441
14442 * linux-low.c (get_stop_pc): Print pc if debug_threads.
14443 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
14444 (linux_resume_one_lwp): Ditto.
14445
14446 2009-05-23 Doug Evans <dje@google.com>
14447
14448 * linux-low.c (linux_resume_one_lwp): Change type of first arg
14449 from struct inferior_list_entry * to struct lwp_info *.
14450 All callers updated.
14451
14452 2009-05-13 Doug Evans <dje@google.com>
14453
14454 * linux-x86-low.c: Don't include assert.h.
14455 (x86_siginfo_fixup): Use fatal, not assert.
14456 (x86_arch_setup): Fix comment.
14457
14458 2009-05-12 Doug Evans <dje@google.com>
14459
14460 Biarch support for i386/amd64 gdbserver.
14461 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
14462 Add linux-x86-low.c.
14463 (linux-i386-low.o, linux-x86-64-low.o): Delete.
14464 (linux-x86-low.o): Add.
14465 * linux-x86-64-low.c: Delete.
14466 * linux-i386-low.c: Delete.
14467 * linux-x86-low.c: New file.
14468 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
14469 linux-x86-low.o.
14470 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
14471 linux-x86-low.o.
14472 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
14473 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
14474 (linux_child_pid_to_exec_file): New function.
14475 (elf_64_header_p, elf_64_file_p): New functions.
14476 (siginfo_fixup): New function.
14477 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
14478 give target a chance to convert layout.
14479 * linux-low.h (linux_target_ops): New member siginfo_fixup.
14480 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
14481
14482 2009-05-07 Doug Evans <dje@google.com>
14483
14484 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
14485 (regsets_store_inferior_registers): Ditto.
14486
14487 2009-05-06 Pedro Alves <pedro@codesourcery.com>
14488
14489 PR server/10048
14490
14491 * linux-low.c (must_set_ptrace_flags): Delete.
14492 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
14493 of the global.
14494 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
14495 `lwp->must_set_ptrace_flags' instead.
14496 (linux_wait_for_event_1): Set ptrace options here.
14497 (linux_wait_1): ... not here.
14498
14499 2009-04-30 Doug Evans <dje@google.com>
14500
14501 * inferiors.c (started_inferior_callback): New function.
14502 (attached_inferior_callback): New function.
14503 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
14504 * server.c (print_started_pid, print_attached_pid): New functions.
14505 (detach_or_kill_for_exit): New function.
14506 (main): Call it instead of for_each_inferior (kill_inferior_callback).
14507 * server.h (have_started_inferiors_p): Declare.
14508 (have_attached_inferiors_p): Declare.
14509
14510 * inferiors.c (remove_process): Fix memory leak, free process.
14511 * linux-low.c (linux_remove_process): New function.
14512 (linux_kill): Call it instead of remove_process.
14513 (linux_detach, linux_wait_1): Ditto.
14514
14515 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
14516
14517 * configure.srv: Add x86 Windows CE target.
14518
14519 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
14520
14521 * inferiors.c (get_thread_process): Make global.
14522 * server.h (get_thread_process): Add prototype.
14523 * thread-db.c (find_one_thread): Use get_thread_process
14524 instead of current_process.
14525 (thread_db_get_tls_address): Do not crash if called when
14526 thread layer is not yet initialized.
14527
14528 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
14529
14530 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
14531 * spu-low.c (current_tid): Rename to ...
14532 (current_ptid): ... this.
14533 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
14534 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
14535 ptid_get_lwp (current_ptid) instead of current_tid.
14536 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
14537 instead of current_tid. Use find_process_pid to verify pid
14538 argument is valid. Pass proper argument to remove_process.
14539 (spu_thread_alive): Compare current_ptid instead of current_tid.
14540 (spu_resume): Likewise.
14541
14542 2009-04-02 Pedro Alves <pedro@codesourcery.com>
14543
14544 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
14545 variable.
14546
14547 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14548
14549 Implement the multiprocess extensions, and add linux multiprocess
14550 support.
14551
14552 * server.h (ULONGEST): Declare.
14553 (struct ptid, ptid_t): New.
14554 (minus_one_ptid, null_ptid): Declare.
14555 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
14556 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
14557 (struct inferior_list_entry): Change `id' type from unsigned from
14558 to ptid_t.
14559 (struct sym_cache, struct breakpoint, struct
14560 process_info_private): Forward declare.
14561 (struct process_info): Declare.
14562 (current_process): Declare.
14563 (all_processes): Declare.
14564 (initialize_inferiors): Declare.
14565 (add_thread): Adjust to use ptid_t.
14566 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
14567 (add_process, remove_process, find_thread_pid): Declare.
14568 (find_inferior_id): Adjust to use ptid_t.
14569 (cont_thread, general_thread, step_thread): Change type to ptid_t.
14570 (multi_process): Declare.
14571 (push_event): Adjust to use ptid_t.
14572 (read_ptid, write_ptid): Declare.
14573 (prepare_resume_reply): Adjust to use ptid_t.
14574 (clear_symbol_cache): Declare.
14575 * inferiors.c (all_processes): New.
14576 (null_ptid, minus_one_ptid): New.
14577 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
14578 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
14579 (add_thread): Change unsigned long to ptid. Remove gdb_id
14580 parameter. Adjust.
14581 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
14582 (gdb_id_to_thread): Rename to ...
14583 (find_thread_pid): ... this. Change unsigned long to ptid.
14584 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
14585 (loaded_dll, pull_pid_from_list): Adjust.
14586 (add_process, remove_process, find_process_pid)
14587 (get_thread_process, current_process, initialize_inferiors): New.
14588 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
14589 (struct target_waitstatus) <related_pid>: Ditto.
14590 (struct target_ops) <kill, detach>: Add `pid' argument. Change
14591 return type to int.
14592 (struct target_ops) <join>: Add `pid' argument.
14593 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
14594 (struct target_ops) <wait>: Add `ptid' field. Change return type
14595 to ptid.
14596 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
14597 (mywait): Add `ptid' argument. Change return type to ptid_t.
14598 (target_pid_to_str): Declare.
14599 * target.c (set_desired_inferior): Adjust to use ptids.
14600 (mywait): Add new `ptid' argument. Adjust.
14601 (target_pid_to_str): New.
14602 * mem-break.h (free_all_breakpoints): Declare.
14603 * mem-break.c (breakpoints): Delelete.
14604 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
14605 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
14606 to use per-process breakpoint list.
14607 (free_all_breakpoints): New.
14608 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
14609 (symbol_cache, all_symbols_looked_up): Delete.
14610 (hexchars): New.
14611 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
14612 read_ptid): New.
14613 (prepare_resume_reply): Change ptid argument's type from unsigned
14614 long to ptid_t. Adjust. Implement W;process and X;process.
14615 (free_sym_cache, clear_symbol_cache): New.
14616 (look_up_one_symbol): Adjust to per-process symbol cache. *
14617 * server.c (cont_thread, general_thread, step_thread): Change type
14618 to ptid_t.
14619 (attached): Delete.
14620 (multi_process): New.
14621 (last_ptid): Change type to ptid_t.
14622 (struct vstop_notif) <ptid>: Change type to ptid_t.
14623 (queue_stop_reply, push_event): Change `ptid' argument's type to
14624 ptid_t.
14625 (discard_queued_stop_replies): Add `pid' argument.
14626 (start_inferior): Adjust to use ptids. Adjust to mywait interface
14627 changes. Don't reference the `attached' global.
14628 (attach_inferior): Adjust to mywait interface changes.
14629 (handle_query): Adjust to use ptids. Parse GDB's qSupported
14630 features. Handle and report "multiprocess+". Handle
14631 "qAttached:PID".
14632 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
14633 changes.
14634 (handle_v_kill): New.
14635 (handle_v_stopped): Adjust to use target_pid_to_str.
14636 (handle_v_requests): Allow multiple attaches and runs when
14637 multiprocess extensions are in effect. Handle "vKill".
14638 (myresume): Adjust to use ptids.
14639 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
14640 (handle_status): Adjust to discard_queued_stop_replies interface
14641 change.
14642 (first_thread_of, kill_inferior_callback)
14643 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
14644 (main): Call initialize_inferiors. Adjust to use ptids, killing
14645 and detaching from all inferiors. Handle multiprocess packet
14646 variants.
14647 * linux-low.h: Include gdb_proc_service.h.
14648 (struct process_info_private): New.
14649 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
14650 <lwpid_of>: Use ptid_get_lwp.
14651 (get_lwp_thread): Adjust.
14652 (struct lwp_info): Add `dead' member.
14653 (find_lwp_pid): Declare.
14654 * linux-low.c (thread_db_active): Delete.
14655 (new_inferior): Adjust comment.
14656 (inferior_pid): Delete.
14657 (linux_add_process): New.
14658 (handle_extended_wait): Adjust.
14659 (add_lwp): Change unsigned long to ptid.
14660 (linux_create_inferior): Add process to processes table. Adjust
14661 to use ptids. Don't set new_inferior here.
14662 (linux_attach_lwp): Rename to ...
14663 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
14664 it. Adjust to use ptids.
14665 (linux_attach_lwp): New.
14666 (linux_attach): Add process to processes table. Don't set
14667 new_inferior here.
14668 (struct counter): New.
14669 (second_thread_of_pid_p, last_thread_of_process_p): New.
14670 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
14671 multiple processes.
14672 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
14673 processes. Remove process from process table.
14674 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
14675 to multiple processes.
14676 (any_thread_of): New.
14677 (linux_detach): Add `pid' argument, and handle it. Remove process
14678 from processes table.
14679 (linux_join): Add `pid' argument. Handle it.
14680 (linux_thread_alive): Change unsighed long argument to ptid_t.
14681 Consider dead lwps as not being alive.
14682 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
14683 threads we're not interested in.
14684 (same_lwp, find_lwp_pid): New.
14685 (linux_wait_for_lwp): Change `pid' argument's type from int to
14686 ptid_t. Adjust.
14687 (linux_wait_for_event): Rename to ...
14688 (linux_wait_for_event_1): ... this. Change `pid' argument's type
14689 from int to ptid_t. Adjust.
14690 (linux_wait_for_event): New.
14691 (linux_wait_1): Add `ptid' argument. Change return type to
14692 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
14693 that exit from the process table.
14694 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
14695 Adjust.
14696 (mark_lwp_dead): New.
14697 (wait_for_sigstop): Adjust to use ptids. If a process exits while
14698 stopping all threads, mark its main lwp as dead.
14699 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
14700 ptids.
14701 (fetch_register, usr_store_inferior_registers)
14702 (regsets_fetch_inferior_registers)
14703 (regsets_store_inferior_registers, linux_read_memory)
14704 (linux_write_memory): Inline `inferior_pid'.
14705 (linux_look_up_symbols): Adjust to use per-process
14706 `thread_db_active'.
14707 (linux_request_interrupt): Adjust to use ptids.
14708 (linux_read_auxv): Inline `inferior_pid'.
14709 (initialize_low): Don't reference thread_db_active.
14710 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
14711 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
14712 (ps_getpid): Return the pid of the current inferior.
14713 * thread-db.c (proc_handle, thread_agent): Delete.
14714 (thread_db_create_event, thread_db_enable_reporting): Adjust to
14715 per-process data.
14716 (find_one_thread): Change argument type to ptid_t. Adjust to
14717 per-process data.
14718 (maybe_attach_thread): Adjust to per-process data and ptids.
14719 (thread_db_find_new_threads): Ditto.
14720 (thread_db_init): Ditto.
14721 * spu-low.c (spu_create_inferior, spu_attach): Add process to
14722 processes table. Adjust to use ptids.
14723 (spu_kill, spu_detach): Adjust interface. Remove process from
14724 processes table.
14725 (spu_join, spu_thread_alive): Adjust interface.
14726 (spu_wait): Adjust interface. Remove process from processes
14727 table. Adjust to use ptids.
14728 * win32-low.c (current_inferior_tid): Delete.
14729 (current_inferior_ptid): New.
14730 (debug_event_ptid): New.
14731 (thread_rec): Take a ptid. Adjust.
14732 (child_add_thread): Add `pid' argument. Adjust to use ptids.
14733 (child_delete_thread): Ditto.
14734 (do_initial_child_stuff): Add `attached' argument. Add process to
14735 processes table.
14736 (child_fetch_inferior_registers, child_store_inferior_registers):
14737 Adjust.
14738 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
14739 (win32_attach): Pass 1 to do_initial_child_stuff.
14740 (win32_kill): Adjust interface. Remove process from processes
14741 table.
14742 (win32_detach): Ditto.
14743 (win32_join): Adjust interface.
14744 (win32_thread_alive): Take a ptid.
14745 (win32_resume): Adjust to use ptids.
14746 (get_child_debug_event): Ditto.
14747 (win32_wait): Adjust interface. Remove exiting process from
14748 processes table.
14749
14750 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14751
14752 Non-stop mode support.
14753
14754 * server.h (non_stop): Declare.
14755 (gdb_client_data, handler_func): Declare.
14756 (delete_file_handler, add_file_handler, start_event_loop):
14757 Declare.
14758 (handle_serial_event, handle_target_event, push_event)
14759 (putpkt_notif): Declare.
14760 * target.h (enum resume_kind): New.
14761 (struct thread_resume): Replace `step' field by `kind' field.
14762 (TARGET_WNOHANG): Define.
14763 (struct target_ops) <wait>: Add `options' argument.
14764 <supports_non_stop, async, start_non_stop>: New fields.
14765 (target_supports_non_stop, target_async): New.
14766 (start_non_stop): Declare.
14767 (mywait): Add `options' argument.
14768 * target.c (mywait): Add `options' argument. Print child exit
14769 notifications here.
14770 (start_non_stop): New.
14771 * server.c (non_stop, own_buf, mem_buf): New globals.
14772 (struct vstop_notif): New.
14773 (notif_queue): New global.
14774 (queue_stop_reply, push_event, discard_queued_stop_replies)
14775 (send_next_stop_reply): New.
14776 (start_inferior): Adjust to use resume_kind. Adjust to mywait
14777 interface changes.
14778 (attach_inferior): In non-stop mode, don't wait for the target
14779 here.
14780 (handle_general_set): Handle QNonStop.
14781 (handle_query): When handling qC, return the current general
14782 thread, instead of the first thread of the list.
14783 (handle_query): If the backend supports non-stop mode, include
14784 QNonStop+ in the qSupported query response.
14785 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
14786 and non-stop mode.
14787 (handle_v_attach, handle_v_run): Handle non-stop mode.
14788 (handle_v_stopped): New.
14789 (handle_v_requests): Report support for vCont;t. Handle vStopped.
14790 (myresume): Adjust to use resume_kind. Handle non-stop.
14791 (queue_stop_reply_callback): New.
14792 (handle_status): Handle non-stop mode.
14793 (main): Clear non_stop flag on reconnection. Use the event-loop.
14794 Refactor serial protocol handling from here ...
14795 (process_serial_event): ... to this new function. When GDB
14796 selects any thread, select one here. In non-stop mode, wait until
14797 GDB acks all pending events before exiting.
14798 (handle_serial_event, handle_target_event): New.
14799 * remote-utils.c (remote_open): Install remote_desc in the event
14800 loop.
14801 (remote_close): Remove remote_desc from the event loop.
14802 (putpkt_binary): Rename to...
14803 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
14804 (putpkt_binary): New as wrapper around putpkt_binary_1.
14805 (putpkt_notif): New.
14806 (prepare_resume_reply): In non-stop mode, don't change the
14807 general_thread.
14808 * event-loop.c: New.
14809 * Makefile.in (OBJ): Add event-loop.o.
14810 (event-loop.o): New rule.
14811
14812 * linux-low.h (pid_of): Moved here.
14813 (lwpid_of): New.
14814 (get_lwp_thread): Use lwpid_of.
14815 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
14816 * linux-low.c (pid_of): Delete.
14817 (inferior_pid): Use lwpid_of.
14818 (linux_event_pipe): New.
14819 (target_is_async_p): New.
14820 (delete_lwp): New.
14821 (handle_extended_wait): Use lwpid_of.
14822 (add_lwp): Don't set lwpid field.
14823 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
14824 (linux_kill_one_lwp): If killing a running lwp, stop it first.
14825 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
14826 (linux_detach_one_lwp): If detaching from a running lwp, stop it
14827 first. Adjust to linux_wait_for_event interface changes. Use
14828 lwpid_of.
14829 (linux_detach): Don't delete the main lwp here.
14830 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
14831 (status_pending_p): Don't consider explicitly suspended lwps.
14832 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
14833 pointer. Add OPTIONS argument. Change return type to int. Use
14834 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
14835 (linux_wait_for_event): Take an integer pid instead of a lwp_info
14836 pointer. Add status pointer argument. Return a pid instead of a
14837 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
14838 changes. In non-stop mode, don't switch to a random thread.
14839 (linux_wait): Rename to...
14840 (linux_wait_1): ... this. Add target_options argument, and handle
14841 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
14842 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
14843 clean exit and signal exit code. Don't stop all threads in
14844 non-stop mode. In all-stop mode, only stop all threads when
14845 reporting a stop to GDB. Handle explicit thread stop requests.
14846 (async_file_flush, async_file_mark): New.
14847 (linux_wait): New.
14848 (send_sigstop): Use lwpid_of.
14849 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
14850 interface changes. In non-stop mode, don't switch to a random
14851 thread.
14852 (linux_resume_one_lwp): Use lwpid_of.
14853 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
14854 (linux_resume_one_thread): ... this. Handle resume_stop. In
14855 non-stop mode, don't look for pending flag in all threads.
14856 (resume_status_pending_p): Don't consider explicitly suspended
14857 threads.
14858 (my_waitpid): Reimplement. Emulate __WALL.
14859 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
14860 Use lwpid_of.
14861 (sigchld_handler, linux_supports_non_stop, linux_async)
14862 (linux_start_non_stop): New.
14863 (linux_target_ops): Register linux_supports_non_stop, linux_async
14864 and linux_start_non_stop.
14865 (initialize_low): Install SIGCHLD handler.
14866 * thread-db.c (thread_db_create_event, find_one_thread)
14867 (thread_db_get_tls_address): Use lwpid_of.
14868 * win32-low.c (win32_detach): Adjust to use resume_kind.
14869 (win32_wait): Add `options' argument.
14870 * spu-low.c (spu_resume): Adjust to use resume_kind.
14871 (spu_wait): Add `options' argument.
14872
14873 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14874
14875 Decouple target code from remote protocol.
14876
14877 * target.h (enum target_waitkind): New.
14878 (struct target_waitstatus): New.
14879 (struct target_ops) <wait>: Return an unsigned long. Take a
14880 target_waitstatus pointer instead of a char pointer.
14881 (mywait): Likewise.
14882 * target.c (mywait): Change prototype to return an unsigned long.
14883 Take a target_waitstatus pointer instead of a char pointer. Adjust.
14884 * server.h (thread_from_wait, old_thread_from_wait): Delete
14885 declarations.
14886 (prepare_resume_reply): Change prototype to take a
14887 target_waitstatus.
14888 * server.c (thread_from_wait, old_thread_from_wait): Delete.
14889 (last_status, last_ptid): New.
14890 (start_inferior): Remove "statusptr" argument. Adjust. Return a
14891 pid instead of a signal.
14892 (attach_inferior): Remove "status" and "signal" parameters.
14893 Adjust.
14894 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
14895 not as an address.
14896 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
14897 (handle_v_requests, myresume): Remove "status" and "signal"
14898 parameters. Adjust.
14899 (handle_status): New.
14900 (main): Delete local `status'. Adjust.
14901 * remote-utils.c: Include target.h.
14902 (prepare_resume_reply): Change prototype to take a
14903 target_waitstatus. Adjust.
14904
14905 * linux-low.c (linux_wait): Adjust to new target_ops->wait
14906 interface.
14907 * spu-low.c (spu_wait): Adjust.
14908 * win32-low.c (enum target_waitkind, struct target_waitstatus):
14909 Delete.
14910 (win32_wait): Adjust.
14911
14912 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14913
14914 * target.h (struct thread_resume): Delete leave_stopped member.
14915 (struct target_ops): Add a `n' argument to the `resume' callback.
14916 * server.c (start_inferior): Adjust.
14917 (handle_v_cont, myresume): Adjust.
14918 * linux-low.c (check_removed_breakpoint): Adjust to resume
14919 interface change, and to removed leave_stopped field.
14920 (resume_ptr): Delete.
14921 (struct thread_resume_array): New.
14922 (linux_set_resume_request): Add new `arg' parameter. Adjust to
14923 resume interface change.
14924 (linux_continue_one_thread, linux_queue_one_thread)
14925 (resume_status_pending_p): Check if the resume field is NULL
14926 instead of checking the leave_stopped member.
14927 (linux_resume): Adjust to the target resume interface change.
14928 * spu-low.c (spu_resume): Adjust to the target resume interface
14929 change.
14930 * win32-low.c (win32_detach, win32_resume): Ditto.
14931
14932 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14933
14934 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
14935 flag.
14936 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
14937 pending.
14938 (linux_continue_one_thread): Only preserve the stepping flag if
14939 there's a pending breakpoint.
14940
14941 2009-03-31 Pedro Alves <pedro@codesourcery.com>
14942
14943 * server.c (main): After the inferior having exited, call
14944 remote_close before exiting gdbserver.
14945
14946 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
14947
14948 Fix size of FPSCR in Power 7 processors.
14949 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
14950 (PPC_FEATURE_HAS_DFP): New #define.
14951 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
14952 size of the FPSCR.
14953
14954 2009-03-23 Pedro Alves <pedro@codesourcery.com>
14955
14956 * server.c (handle_query) Whitespace and formatting.
14957
14958 2009-03-22 Pedro Alves <pedro@codesourcery.com>
14959
14960 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
14961 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
14962 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
14963 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
14964 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
14965 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
14966 Makefile.in, configure.ac: Fix whitespace throughout.
14967 * configure: Regenerate.
14968
14969 2009-03-22 Pedro Alves <pedro@codesourcery.com>
14970
14971 * inferiors.c (find_inferior): Make it safe for the callback
14972 function to delete the currently iterated inferior.
14973
14974 2009-03-22 Pedro Alves <pedro@codesourcery.com>
14975
14976 * Makefile.in (linuw_low_h): Move higher.
14977 (thread-db.o): Depend on $(linux_low_h).
14978
14979 2009-03-17 Pedro Alves <pedro@codesourcery.com>
14980
14981 Rename "process" to "lwp" throughout.
14982
14983 * linux-low.c (all_processes): Rename to...
14984 (all_lwps): ... this.
14985 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
14986 (add_process): Rename to ...
14987 (add_lwp): ... this. Adjust.
14988 (linux_create_inferior): Adjust.
14989 (linux_attach_lwp): Adjust.
14990 (linux_attach): Adjust.
14991 (linux_kill_one_process): Rename to ...
14992 (linux_kill_one_lwp): ... this. Adjust.
14993 (linux_kill): Adjust.
14994 (linux_detach_one_process): Rename to ...
14995 (linux_detach_one_lwp): ... this. Adjust.
14996 (linux_detach): Adjust.
14997 (check_removed_breakpoint): Adjust.
14998 (status_pending_p): Adjust.
14999 (linux_wait_for_process): Rename to ...
15000 (linux_wait_for_lwp): ... this. Adjust.
15001 (linux_wait_for_event): Adjust.
15002 (send_sigstop): Adjust.
15003 (wait_for_sigstop): Adjust.
15004 (stop_all_processes): Rename to ...
15005 (stop_all_lwps): ... this.
15006 (linux_resume_one_process): Rename to ...
15007 (linux_resume_one_lwp): ... this. Adjust.
15008 (linux_set_resume_request, linux_continue_one_thread)
15009 (linux_queue_one_thread, resume_status_pending_p)
15010 (usr_store_inferior_registers, regsets_store_inferior_registers)
15011 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
15012 Adjust.
15013 * linux-low.h (get_process): Rename to ...
15014 (get_lwp): ... this. Adjust.
15015 (get_thread_process): Rename to ...
15016 (get_thread_lwp): ... this. Adjust.
15017 (get_process_thread): Rename to ...
15018 (get_lwp_thread): ... this. Adjust.
15019 (struct process_info): Rename to ...
15020 (struct lwp_info): ... this.
15021 (all_processes): Rename to ...
15022 (all_lwps): ... this.
15023 * proc-service.c (ps_lgetregs): Adjust.
15024 * thread-db.c (thread_db_create_event, find_one_thread)
15025 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
15026
15027 2009-03-14 Pedro Alves <pedro@codesourcery.com>
15028
15029 * server.c (handle_query): Handle "qAttached".
15030
15031 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
15032
15033 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
15034 GPLv3, update license URL.
15035
15036 2009-03-01 Doug Evans <dje@google.com>
15037
15038 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
15039 (server_h): Add gdb_signals.h.
15040 (signals.o): Update.
15041 * server.h (target_signal_from_host,target_signal_to_host_p)
15042 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
15043
15044 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
15045
15046 * remote-utils.c (getpkt): Also generate remote-debug
15047 information if noack_mode is set.
15048
15049 2009-02-06 Pedro Alves <pedro@codesourcery.com>
15050
15051 * server.c (handle_query): Report qXfer:siginfo:read and
15052 qXfer:siginfo:write as supported and handle them.
15053 * target.h (struct target_ops) <qxfer_siginfo>: New field.
15054 * linux-low.c (linux_xfer_siginfo): New.
15055 (linux_target_ops): Set it.
15056
15057 2009-01-26 Pedro Alves <pedro@codesourcery.com>
15058
15059 * server.c (gdbserver_usage): Mention --remote-debug.
15060 (main): Accept '--remote-debug' switch.
15061
15062 2009-01-18 Doug Evans <dje@google.com>
15063
15064 * regcache.c (new_register_cache): No need to check result of xcalloc.
15065 * server.c (handle_search_memory): Back out calls to xmalloc,
15066 result is checked and error is returned to user upon failure.
15067 (handle_query): Ditto. Add more checks for result of malloc.
15068 (handle_v_cont): Check result of malloc, report error back to
15069 user upon failure.
15070 (handle_v_run): Ditto. Call freeargv.
15071 * server.h (freeargv): Declare.
15072 * utils.c (freeargv): New fn.
15073
15074 2009-01-15 Doug Evans <dje@google.com>
15075
15076 * gdbreplay.c (perror_with_name): Make arg const char *.
15077 * server.h (target_signal_to_name): Make return type const char *.
15078 * thread-db.c (thread_db_err_str): Make return type const char *.
15079 * utils.c (perror_with_name): Make arg const char *.
15080
15081 2009-01-14 Pedro Alves <pedro@codesourcery.com>
15082
15083 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
15084 when handling a EXIT_PROCESS_DEBUG_EVENT.
15085
15086 2009-01-06 Joel Brobecker <brobecker@adacore.com>
15087
15088 * gdbreplay.c (gdbreplay_version): Update copyright year.
15089 * server.c (gdbserver_version): Likewise.
15090
15091 2009-01-05 Doug Evans <dje@google.com>
15092
15093 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
15094 (handle_extended_wait): Improve comment.
15095
15096 2008-12-13 Doug Evans <dje@google.com>
15097
15098 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
15099 * server.h (ATTR_MALLOC): New macro.
15100 (xmalloc,xcalloc,xstrdup): Declare.
15101 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
15102 * inferiors.c: Ditto.
15103 * linux-low.c: Ditto.
15104 * mem-break.c: Ditto.
15105 * regcache.c: Ditto.
15106 * remote-utils.c: Ditto.
15107 * server.c: Ditto.
15108 * target.c: Ditto.
15109 * win32-low.c: Ditto.
15110
15111 2008-12-12 Doug Evans <dje@google.com>
15112
15113 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
15114 in debugging printf.
15115
15116 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
15117
15118 2008-12-09 Doug Evans <dje@google.com>
15119
15120 * linux-low.h (struct process_info): Delete member tid, unused.
15121 * thread-db.c (find_one_thread): Update.
15122 (maybe_attach_thread): Update.
15123
15124 2008-12-02 Pedro Alves <pedro@codesourcery.com>
15125
15126 * target.h (struct target_ops): Add qxfer_osdata member.
15127 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
15128 and dirent.h.
15129 (linux_qxfer_osdata): New functions.
15130 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
15131 callback.
15132 * server.c (handle_query): Handle "qXfer:osdata:read:".
15133 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
15134 (buffer_xml_printf): New functions.
15135 * server.h (struct buffer): New.
15136 (buffer_grow_str, buffer_grow_str0): New macros.
15137 (buffer_grow, buffer_free, buffer_init, buffer_finish)
15138 (buffer_xml_printf): Declare.
15139
15140 2008-11-24 Doug Evans <dje@google.com>
15141
15142 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
15143
15144 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
15145
15146 * server.c (handle_v_run): Always use the supplied argument list.
15147
15148 2008-11-19 Bob Wilson <bob.wilson@acm.org>
15149
15150 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
15151 (xtensa_regmap_table): Add entry for scompare1.
15152
15153 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
15154
15155 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
15156 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
15157 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
15158 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
15159 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
15160 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
15161 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
15162 XML target descriptions.
15163 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
15164 when inferior is running on an ISA 2.05 or later processor. Add
15165 special case to return offset for full 64-bit slot of FPSCR when
15166 in 32-bits.
15167
15168 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
15169
15170 * Makefile.in (SFILES, clean): Added sparc64 files.
15171 (reg-sparc64.o, reg-sparc64.c): New.
15172 * configure.srv (sparc*-*-linux*): New configuration.
15173 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
15174 syscall arguments for SPARC.
15175 (regsets_store_inferior_registers): Likewise.
15176 * linux-sparc-low.c: New file.
15177
15178 2008-10-21 Doug Evans <dje@google.com>
15179
15180 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
15181 (READLINE_DIR,READLINE_DEP): Delete.
15182 (INTERNAL_CFLAGS): Update.
15183 (LINTFLAGS): Update.
15184
15185 2008-10-10 Pedro Alves <pedro@codesourcery.com>
15186
15187 * server.c (handle_v_run): If GDB didn't specify an argv, use the
15188 whole argv from the last run, not just argv[0].
15189
15190 2008-09-08 Pedro Alves <pedro@codesourcery.com>
15191
15192 * regcache.c (new_register_cache): Return NULL if the register
15193 cache size isn't known yet.
15194 (free_register_cache): Avoid dereferencing a NULL regcache.
15195
15196 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
15197
15198 * configure.srv: Merge MIPS and MIPS64.
15199
15200 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
15201
15202 * Makefile.in (uninstall): Apply $(EXEEXT) too.
15203
15204 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
15205
15206 * Makefile.in: Add required vsx dependencies.
15207
15208 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
15209 Declare init_registers_powerpc_vsx32l.
15210 Declare init_registers_powerpc_vsx64l.
15211 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
15212 (ppc_arch_setup): Check for VSX in hwcap.
15213 (ppc_fill_vsxregset): New function.
15214 (ppc_store_vsxregset): New function.
15215 Add new VSX entry in regset_info target_regsets.
15216
15217 * configure.srv: Add new VSX dependencies.
15218
15219 2008-08-12 Pedro Alves <pedro@codesourcery.com>
15220
15221 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
15222 (remote_open): Set or clear transport_is_reliable.
15223 (putpkt_binary): Don't expect acks in noack mode.
15224 (getpkt): Don't send ack/nac in noack mode.
15225 * server.c (handle_general_set): Handle QStartNoAckMode.
15226 (handle_query): If connected by tcp pass QStartNoAckMode+ in
15227 qSupported.
15228 (main): Reset noack_mode on every connection.
15229 * server.h (noack_mode): Declare.
15230
15231 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15232
15233 * Makefile.in (GDBREPLAY_OBS): New variable.
15234 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
15235
15236 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
15237 Daniel Jacobowitz <dan@codesourcery.com>
15238
15239 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
15240 (usr_store_inferior_registers): Likewise.
15241 (regsets_store_inferior_registers): Likewise.
15242
15243 2008-07-31 Rolf Jansen <rj@surtec.com>
15244 Pedro Alves <pedro@codesourcery.com>
15245
15246 * configure.ac: Check for memmem declaration.
15247 * server.c [HAVE_MALLOC_H]: Include malloc.h.
15248 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
15249 (disable_packet_qfThreadInfo): Unconditionally compile.
15250 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
15251 * configure, config.in: Regenerate.
15252
15253 2008-07-28 Doug Kwan <dougkwan@google.com>
15254
15255 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
15256 (linux_write_memory): Remove declaration of errno.
15257
15258 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
15259
15260 * linux-low.c (handle_extended_wait): Do not use "status"
15261 variable uninitialized.
15262
15263 2008-07-07 Pedro Alves <pedro@codesourcery.com>
15264
15265 * server.c (handle_v_attach): Inhibit reporting dll changes.
15266
15267 2008-06-27 Pedro Alves <pedro@codesourcery.com>
15268
15269 * remote-utils.c (prepare_resume_reply): If requested, don't
15270 output "thread:TID" in the T stop reply.
15271
15272 * server.c (disable_packet_vCont, disable_packet_Tthread)
15273 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
15274 (handle_query): If requested, disable support for qC, qfThreadInfo
15275 and qsThreadInfo.
15276 (handle_v_requests): If requested, disable support for vCont.
15277 (gdbserver_show_disableable): New.
15278 (main): Handle --disable-packet and --disable-packet=LIST.
15279
15280 * server.h (disable_packet_vCont, disable_packet_Tthread)
15281 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
15282
15283 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
15284
15285 * server.c (gdbserver_usage): Mention --version.
15286
15287 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
15288
15289 * Makefile.in (gdbreplay.o): New rule.
15290
15291 2008-06-06 Joseph Myers <joseph@codesourcery.com>
15292
15293 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
15294 message, not gdbserver.
15295
15296 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
15297 Nathan Sidwell <nathan@codesourcery.com>
15298 Joseph Myers <joseph@codesourcery.com>
15299
15300 * acinclude.m4: Include ../../config/acx.m4.
15301 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
15302 * configure, config.in: Regenerate.
15303 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
15304 * server.c (gdbserver_version): Print PKGVERSION.
15305 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
15306 (main): Adjust gdbserver_usage calls.
15307 * gdbreplay.c (version, host_name): Add declarations.
15308 (gdbreplay_version, gdbreplay_usage): New.
15309 (main): Accept --version and --help options.
15310
15311 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
15312
15313 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
15314 (arm_breakpoint_at): Handle Thumb.
15315 (the_low_target): Add comment.
15316
15317 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
15318
15319 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
15320
15321 2008-05-09 Doug Evans <dje@google.com>
15322
15323 * server.h (decode_search_memory_packet): Declare.
15324 * remote-utils.c (decode_search_memory_packet): New fn.
15325 * server.c (handle_search_memory_1): New fn.
15326 (handle_search_memory): New fn.
15327 (handle_query): Process qSearch:memory packets.
15328
15329 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
15330
15331 * regcache.c (registers_length): Remove.
15332 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
15333 full register packet.
15334 * regcache.h (registers_length): Remove prototype.
15335 * server.h (PBUFSIZ): Define to 16384.
15336
15337 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
15338
15339 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
15340 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
15341 powerpc-64l.o, and powerpc-altivec64l.o.
15342 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
15343 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
15344 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
15345 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
15346 rs6000/power-linux.xml, and rs6000/power64-linux.xml
15347 to srv_xmlfiles.
15348
15349 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
15350 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
15351 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
15352 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
15353 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
15354 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
15355 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
15356 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
15357 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
15358 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
15359 (clean): Update.
15360
15361 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
15362 (init_registers_powerpc_32l): ... this new prototype.
15363 (init_registers_powerpc_32): Remove, replace by ...
15364 (init_registers_powerpc_altivec32l): ... this new prototype.
15365 (init_registers_powerpc_e500): Remove, replace by ...
15366 (init_registers_powerpc_e500l): ... this new prototype.
15367 (init_registers_ppc64): Remove, replace by ...
15368 (init_registers_powerpc_64l): ... this new prototype.
15369 (init_registers_powerpc_64): Remove, replace by ...
15370 (init_registers_powerpc_altivec64l): ... this new prototype.
15371 (ppc_num_regs): Set to 73.
15372 (PT_ORIG_R3, PT_TRAP): Define if necessary.
15373 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
15374 (ppc_cannot_store_register): Handle orig_r3 and trap.
15375 (ppc_arch_setup): Update init_registers_... calls.
15376 (ppc_fill_gregset): Handle orig_r3 and trap.
15377
15378 * inferiors.c (clear_inferiors): Reset current_inferior.
15379
15380 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
15381
15382 * acinclude.m4: Add override.m4.
15383 * configure: Regenerate.
15384
15385 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
15386
15387 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
15388 initial call to init_register_ppc64.
15389
15390 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
15391
15392 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
15393 single powerpc*-*-linux* case.
15394 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
15395
15396 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
15397
15398 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
15399 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
15400 from reg_xmlfiles.
15401 * linux-ppc-low.c: Include <elf.h>.
15402 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
15403 (ppc_hwcap): New global variable.
15404 (ppc_regmap): Remove __SPE__ #ifdef sections.
15405 (ppc_regmap_e500): New global variable.
15406 (ppc_cannot_store_register): Update __SPE__ special case.
15407 (ppc_get_hwcap): New function.
15408 (ppc_arch_setup): Use it to determine whether inferior supports
15409 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
15410 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
15411 Do not access registers if target does not support AltiVec.
15412 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
15413 Do not access registers if target does not support SPE.
15414 (target_regsets): Unconditionally include AltiVec and SPE regsets.
15415
15416 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
15417
15418 * linux-low.c (disabled_regsets, num_regsets): New.
15419 (use_regsets_p): Delete.
15420 (linux_wait_for_process): Clear disabled_regsets.
15421 (regsets_fetch_inferior_registers): Check and set it.
15422 (regsets_store_inferior_registers): Likewise.
15423 (linux_fetch_registers, linux_store_registers): Do not use
15424 use_regsets_p.
15425 (initialize_low): Allocate disabled_regsets.
15426
15427 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
15428
15429 * Makefile.in (LIBOBJS): New.
15430 (OBS): Use LIBOBJS.
15431 (memmem.o): New rule.
15432 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
15433 * configure: Regenerated.
15434
15435 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
15436
15437 * server.c (handle_query): Never return "unsupported" for
15438 qXfer:features:read queries.
15439
15440 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
15441
15442 * server.c (get_features_xml): Fix inverted condition.
15443 (handle_query): Always support qXfer:feature:read.
15444
15445 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
15446
15447 * server.c (wrapper_argv): New.
15448 (start_inferior): Handle wrapper_argv. If set, expect an extra
15449 trap.
15450 (gdbserver_usage): Document --wrapper.
15451 (main): Parse --wrapper.
15452
15453 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15454
15455 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
15456 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
15457 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
15458 (ppc_set_pc): Likewise.
15459 (ppc_arch_setup): New function.
15460 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
15461 of collect_register.
15462 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
15463
15464 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15465
15466 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
15467 instead of linux-ppc64-low.o.
15468 * linux-ppc64-low.c: Remove file.
15469 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
15470 (linux-ppc64-low.o): Remove rule.
15471
15472 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
15473 (init_registers_powerpc_64): Likewise.
15474 (ppc_regmap): Conditionally define depending on __powerpc64__.
15475 (ppc_cannot_store_register): Do not special-case "fpscr" when
15476 compiled on __powerpc64__.
15477 (ppc_collect_ptrace_register): New function.
15478 (ppc_supply_ptrace_register): New function.
15479 (ppc_breakpoint): Change type to "unsigned int".
15480 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
15481 (the_low_target): Conditionally provide initializers for the
15482 arch_setup member depending on __powerpc64__. Install
15483 collect_ptrace_register and supply_ptrace_register members.
15484
15485 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15486
15487 * regcache.h (gdbserver_xmltarget): Add extern declaration.
15488 * server.c (gdbserver_xmltarget): Define.
15489 (get_features_xml): Use it to replace "target.xml" and arch_string.
15490
15491 * configure.srv: Remove srv_xmltarget. Add XML files that were
15492 mentioned there to srv_xmlfiles instead. Remove conditional tests
15493 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
15494 srv_xmlfiles and srv_regobj to include all possible choices.
15495 * configure.ac (srv_xmltarget): Remove.
15496 (srv_xmlfiles): Do not add "target.xml".
15497 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
15498 checks for supplementary target information.
15499 * configure: Regenerate.
15500 * Makefile.in (XML_TARGET): Remove.
15501 (target.xml): Remove rule.
15502 (clean): Do not clean up target.xml.
15503 (.PRECIOUS): Do not mention target.xml.
15504
15505 * target.h (struct target_ops): Remove arch_string member.
15506 * linux-low.c (linux_arch_string): Remove.
15507 (linux_target_ops): Remove arch_string initializer.
15508 * linux-low.h (struct linux_target_ops): Remove arch_string member.
15509 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
15510 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
15511 * spu-low.c (spu_arch_string): Remove.
15512 (spu_target_ops): Remove arch_string initializer.
15513 * win32-low.c (win32_arch_string): Remove.
15514 (win32_target_ops): Remove arch_string initializer.
15515 * win32-low.h (struct win32_target_ops): Remove arch_string member.
15516 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
15517 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
15518
15519 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15520
15521 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
15522 by collect_ptrace_register and supply_ptrace_register hooks.
15523 * linux-low.c (fetch_register): Use supply_ptrace_register callback
15524 instead of checking for the_low_target.left_pad_xfer.
15525 (usr_store_inferior_registers): Use collect_ptrace_register callback
15526 instead of checking for the_low_target.left_pad_xfer.
15527
15528 * linux-s390-low.c (s390_collect_ptrace_register): New function.
15529 (s390_supply_ptrace_register): Likewise.
15530 (s390_fill_gregset): Call s390_collect_ptrace_register.
15531 (the_low_target): Update.
15532
15533 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
15534 (ppc_supply_ptrace_register): Likewise.
15535 (the_low_target): Update.
15536
15537 * linux-i386-low.c (the_low_target): Update.
15538 * linux-x86-64-low.c (the_low_target): Update.
15539
15540 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15541
15542 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
15543 reg-s390.o and reg-s390x.o.
15544
15545 * linux-low.c (new_inferior): New global variable.
15546 (linux_create_inferior, linux_attach): Set it.
15547 (linux_wait_for_process): Call the_low_target.arch_setup after the
15548 target has stopped for the first time.
15549 (initialize_low): Do not call the_low_target.arch_setup.
15550
15551 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
15552 (s390_set_pc): Likewise.
15553 (s390_arch_setup): New function.
15554 (the_low_target): Use s390_arch_setup as arch_setup routine.
15555
15556 * regcache.c (realloc_register_cache): New function.
15557 (set_register_cache): Call it for each existing regcache.
15558
15559 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15560
15561 * server.h (init_registers): Remove prototype.
15562
15563 * linux-low.h (struct linux_target_ops): Add arch_setup field.
15564 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
15565 instead of init_registers ().
15566 * linux-arm-low.c (init_registers_arm): Add prototype.
15567 (init_registers_arm_with_iwmmxt): Likewise.
15568 (the_low_target): Add initializer for arch_setup field.
15569 * linux-cris-low.c (init_registers_cris): Add prototype.
15570 (the_low_target): Add initializer for arch_setup field.
15571 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
15572 (the_low_target): Add initializer for arch_setup field.
15573 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
15574 (the_low_target): Add initializer for arch_setup field.
15575 * linux-ia64-low.c (init_registers_ia64): Add prototype.
15576 (the_low_target): Add initializer for arch_setup field.
15577 * linux-m32r-low.c (init_registers_m32r): Add prototype.
15578 (the_low_target): Add initializer for arch_setup field.
15579 * linux-m68k-low.c (init_registers_m68k): Add prototype.
15580 (the_low_target): Add initializer for arch_setup field.
15581 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
15582 (init_registers_mips64_linux): Likewise.
15583 (the_low_target): Add initializer for arch_setup field.
15584 * linux-ppc-low.c (init_registers_ppc): Add prototype.
15585 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
15586 (the_low_target): Add initializer for arch_setup field.
15587 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
15588 (init_registers_powerpc_64): Likewise.
15589 (the_low_target): Add initializer for arch_setup field.
15590 * linux-s390-low.c (init_registers_s390): Add prototype.
15591 (init_registers_s390x): Likewise.
15592 (the_low_target): Add initializer for arch_setup field.
15593 * linux-sh-low.c (init_registers_sh): Add prototype.
15594 (the_low_target): Add initializer for arch_setup field.
15595 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
15596 (the_low_target): Add initializer for arch_setup field.
15597 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
15598 (the_low_target): Add initializer for arch_setup field.
15599
15600 * win32-low.h (struct win32_target_ops): Add arch_setup field.
15601 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
15602 instead of init_registers ().
15603 * win32-arm-low.c (init_registers_arm): Add prototype.
15604 (the_low_target): Add initializer for arch_setup field.
15605 * win32-i386-low.c (init_registers_i386): Add prototype.
15606 (the_low_target): Add initializer for arch_setup field.
15607
15608 * spu-low.c (init_registers_spu): Add prototype.
15609 (initialize_low): Call initialie_registers_spu () instead of
15610 initialize_registers ().
15611
15612 2008-02-19 Pedro Alves <pedro@codesourcery.com>
15613
15614 * server.c (handle_v_requests): When handling the vRun and vAttach
15615 packets, if already debugging a process, don't kill it. Return an
15616 error instead.
15617
15618 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
15619
15620 * server.c (handle_query): Correct length check.
15621
15622 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
15623
15624 * win32-low.c (do_initial_child_stuff): Add process handle
15625 parameter. Set current_process_handle and current_process_id from the
15626 parameters. Clear globals.
15627 (win32_create_inferior): Don't set current_process_handle and
15628 current_process_id here. Instead pass them on the call to
15629 do_initial_child_stuff.
15630 (win32_attach): Likewise.
15631 (win32_clear_inferiors): New.
15632 (win32_kill): Don't close the current process handle or the
15633 current thread handle here. Instead call win32_clear_inferiors.
15634 (win32_detach): Don't open a new handle to the process. Call
15635 win32_clear_inferiors.
15636 (win32_join): Don't rely on current_process_handle; open a new
15637 handle using the process id.
15638 (win32_wait): Call win32_clear_inferiors when the inferior process
15639 has exited.
15640
15641 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
15642
15643 * server.c (monitor_show_help): Add "exit".
15644
15645 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
15646
15647 * Makefile.in (SFILES): Add linux-xtensa-low.c.
15648 (clean): Add reg-xtensa.c.
15649 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
15650 * configure.srv (xtensa*-*-linux*) New target.
15651 * linux-xtensa-low.c: New.
15652 * xtensa-xtregs.c: New.
15653
15654 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
15655
15656 * hostio.c: Don't include errno.h.
15657 (errno_to_fileio_errno): Move to hostio-errno.
15658 * hostio.c: (hostio_error): Remove the error parameter. Defer the
15659 error number outputting to the target->hostio_last_error callback.
15660 (hostio_packet_error): Use FILEIO_EINVAL directly.
15661 (handle_open, handle_pread, hostio_error, handle_unlink): Update
15662 calls to hostio_error.
15663 * hostio-errno.c: New.
15664 * server.h (hostio_last_error_from_errno): Declare.
15665 * target.h (target_ops): Add hostio_last_error member.
15666 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
15667 as hostio_last_error handler.
15668 * spu-low.c (spu_target_ops): Likewise.
15669 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
15670 (wince_hostio_last_error): New functions.
15671 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
15672 as hostio_last_error handler.
15673 (win32_target_ops) [!_WIN32_WCE]: Register
15674 hostio_last_error_from_errno as hostio_last_error handler.
15675 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
15676 (hostio-errno.o): New rule.
15677 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
15678 * configure.srv (srv_hostio_err_objs): New variable. Default to
15679 hostio-errno.o.
15680 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
15681 * configure: Regenerate.
15682
15683 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
15684
15685 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
15686 (linux_kill, linux_detach): Clean up the process list.
15687 * remote-utils.c (remote_open): Improve port number parsing.
15688 (putpkt_binary, input_interrupt): Only send interrupts if the target
15689 is running.
15690 * server.c (extended_protocol): Make static.
15691 (attached): Define earlier.
15692 (exit_requested, response_needed, program_argv): New variables.
15693 (target_running): New.
15694 (start_inferior): Clear attached here.
15695 (attach_inferior): Set attached here.
15696 (require_running): Define.
15697 (handle_query): Use require_running and target_running. Implement
15698 "monitor exit".
15699 (handle_v_attach, handle_v_run): New.
15700 (handle_v_requests): Use require_running. Handle vAttach and vRun.
15701 (gdbserver_usage): Update.
15702 (main): Redo argument parsing. Handle --debug and --multi. Handle
15703 --attach along with other options or after the port. Save
15704 program_argv. Support no initial program. Resynchronize
15705 communication with GDB after an error. Handle "monitor exit".
15706 Use require_running and target_running. Always allow the extended
15707 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
15708 restart in extended mode.
15709 * README: Refer to the GDB manual. Update --attach usage.
15710
15711 2007-12-20 Andreas Schwab <schwab@suse.de>
15712
15713 * linux-low.c (STACK_SIZE): Define.
15714 (linux_tracefork_child): Use it. Use __clone2 on ia64.
15715 (linux_test_for_tracefork): Likewise.
15716
15717 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
15718
15719 * linux-low.c (linux_wait_for_event): Update messages. Do not
15720 reinsert auto-delete breakpoints.
15721 * mem-break.c (struct breakpoint): Change return type of handler to
15722 int.
15723 (set_breakpoint_at): Update handler type.
15724 (reinsert_breakpoint_handler): Return 1 instead of calling
15725 delete_breakpoint.
15726 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
15727 setting a new one.
15728 (check_breakpoints): Delete auto-delete breakpoints and return 2.
15729 * mem-break.h (set_breakpoint_at): Update handler type.
15730 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
15731 * win32-low.c (auto_delete_breakpoint): New.
15732 (get_child_debug_event): Use it.
15733
15734 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
15735
15736 * configure.ac: Check for pread and pwrite.
15737 * hostio.c (handle_pread): Fall back to lseek and read.
15738 (handle_pwrite): Fall back to lseek and write.
15739 * config.in, configure: Regenerated.
15740
15741 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
15742
15743 * server.c (myresume): Add own_buf argument.
15744 (main): Update calls.
15745
15746 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
15747
15748 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
15749 * remote-utils.c (remote_open): Do not call disable_async_io.
15750 (block_async_io): Delete.
15751 (unblock_async_io): Make static.
15752 (initialize_async_io): New.
15753 * server.c (handle_v_cont): Handle async I/O here.
15754 (myresume): Likewise. Move other common resume tasks here...
15755 (main): ... from here. Call initialize_async_io. Disable async
15756 I/O before the main loop.
15757 * server.h (initialize_async_io): Declare.
15758 (block_async_io, unblock_async_io): Delete prototypes.
15759 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
15760
15761 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
15762
15763 * remote-utils.c (readchar): Allow binary data in received messages.
15764
15765 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15766
15767 * win32-low.c (attaching): New global.
15768 (win32_create_inferior): Clear the `attaching' global.
15769 (win32_attach): Set the `attaching' global.
15770 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
15771 attaching. Only set a breakpoint at the entry point if not
15772 attaching.
15773
15774 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15775
15776 * server.c (main): Don't report dll events on the initial
15777 connection on attaches.
15778
15779 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15780
15781 * server.c (main): Relax numerical bases supported for the pid of
15782 the --attach command line argument.
15783
15784 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15785
15786 * win32-low.c (win32_attach): Call OpenProcess before
15787 DebugActiveProcess, not after. Add last error output to error
15788 call.
15789
15790 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15791
15792 * win32-low.c (win32_get_thread_context)
15793 (win32_set_thread_context): New functions.
15794 (thread_rec): Use win32_get_thread_context.
15795 (continue_one_thread, win32_resume): Use win32_set_thread_context.
15796 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
15797 field.
15798
15799 2007-12-03 Leo Zayas
15800 Pedro Alves <pedro_alves@portugalmail.pt>
15801
15802 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
15803 global variables.
15804 (child_add_thread): Minor cleanup.
15805 (child_continue): Resume artificially suspended threads before
15806 calling ContinueDebugEvent.
15807 (suspend_one_thread): New.
15808 (fake_breakpoint_event): New.
15809 (get_child_debug_event): Change return type to int. Check here if
15810 gdb sent an interrupt request. If a soft interrupt was requested,
15811 fake a breakpoint event. Return 0 if there is no event to handle,
15812 and 1 otherwise.
15813 (win32_wait): Don't check here if gdb sent an interrupt request.
15814 Ensure there is a valid event to handle.
15815 (win32_request_interrupt): Add soft interruption method as last
15816 resort.
15817
15818 2007-12-03 Leo Zayas
15819 Pedro Alves <pedro_alves@portugalmail.pt>
15820
15821 * win32-low.h (win32_thread_info): Add descriptions to the
15822 structure members. Replace `suspend_count' counter by a
15823 `suspended' flag.
15824 * win32-low.c (thread_rec): Update condition of when to get the
15825 context from the inferior. Rely on ContextFlags being set if it
15826 has already been retrieved. Only suspend the inferior thread if
15827 we haven't already. Warn if that fails.
15828 (continue_one_thread): s/suspend_count/suspended/. Only call
15829 ResumeThread once. Warn if that fails.
15830
15831 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
15832
15833 * win32-low.c (win32_wait): Don't read from the inferior when it
15834 has already exited.
15835
15836 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
15837
15838 * Makefile.in (win32_low_h): New variable.
15839 (win32-low.o): Add dependency on $(win32_low_h).
15840 (win32-arm-low.o, win32-i386-low.o): New rules.
15841
15842 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
15843
15844 * hostio.c: Correct copyright year.
15845
15846 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
15847
15848 * Makefile.in (OBS): Add hostio.o.
15849 (hostio.o): New rule.
15850 * server.h (handle_vFile): Declare.
15851 * hostio.c: New file.
15852 * server.c (handle_v_requests): Take packet_len and new_packet_len
15853 for binary packets. Call handle_vFile.
15854 (main): Update call to handle_v_requests.
15855
15856 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
15857
15858 * linux-low.c: Include <sched.h>.
15859
15860 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
15861
15862 * linux-low.c (linux_tracefork_grandchild): New.
15863 (linux_tracefork_child): Use clone.
15864 (linux_test_for_tracefork): Use clone; allocate and free a stack.
15865
15866 2007-10-31 Joel Brobecker <brobecker@adacore.com>
15867
15868 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
15869
15870 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
15871
15872 * linux-low.c (handle_extended_wait): Handle unexpected signals.
15873
15874 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
15875
15876 * inferiors.c (change_inferior_id): Delete.
15877 (add_pid_to_list, pull_pid_from_list): New.
15878 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
15879 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
15880 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
15881 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
15882 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
15883 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
15884 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
15885 (using_threads): Always set to 1.
15886 (handle_extended_wait): New.
15887 (add_process): Do not set TID.
15888 (linux_create_inferior): Set must_set_ptrace_flags.
15889 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
15890 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
15891 (linux_thread_alive): Rename TID argument to LWPID.
15892 (linux_wait_for_process): Handle unknown processes. Do not use TID.
15893 (linux_wait_for_event): Do not use TID or check using_threads. Update
15894 call to dead_thread_notify. Call handle_extended_wait.
15895 (linux_create_inferior): Use PTRACE_SETOPTIONS.
15896 (send_sigstop): Delete sigstop_sent.
15897 (wait_for_sigstop): Avoid TID.
15898 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
15899 (linux_test_for_tracefork): New.
15900 (linux_lookup_signals): Use thread_db_active and
15901 linux_supports_tracefork_flag.
15902 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
15903 * linux-low.h (get_process_thread): Avoid TID.
15904 (struct process_ifo): Move thread_known and tid to the end. Remove
15905 sigstop_sent.
15906 (linux_attach_lwp, thread_db_init): Update prototypes.
15907 * server.h (change_inferior_id): Delete prototype.
15908 (add_pid_to_list, pull_pid_from_list): New prototypes.
15909 * thread-db.c (thread_db_use_events): New.
15910 (find_first_thread): Rename to...
15911 (find_one_thread): ...this. Update callers and messages. Do not
15912 call fatal. Check thread_db_use_events. Do not call
15913 change_inferior_id or new_thread_notify.
15914 (maybe_attach_thread): Update. Do not call new_thread_notify.
15915 (thread_db_init): Set thread_db_use_events. Check use_events.
15916 * utils.c (fatal, warning): Correct message prefix.
15917
15918 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
15919
15920 * Makefile.in (clean): Remove new files.
15921 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
15922 (powerpc-64.o, powerpc-64.c): New rules.
15923 * configure.srv: Use alternate register sets for powerpc64-*-linux*
15924 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
15925 with SPE.
15926 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
15927 SPE targets.
15928 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
15929 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
15930 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
15931 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
15932 (target_regsets): Add AltiVec and SPE register sets.
15933 * configure.ac: Check for AltiVec and SPE.
15934 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
15935 (ppc_fill_vrregset, ppc_store_vrregset): New.
15936 (target_regsets): Add AltiVec register set.
15937 * configure: Regenerated.
15938
15939 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
15940
15941 * linux-low.c (O_LARGEFILE): Define.
15942 (linux_read_memory): Use /proc/PID/mem.
15943 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
15944 * configure, config.in: Regenerated.
15945
15946 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
15947
15948 * linux-low.c (linux_wait_for_event): Do not pass signals while
15949 single-stepping.
15950
15951 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
15952
15953 * win32-low.c (create_process): New.
15954 (win32_create_inferior): Use create_process instead of
15955 CreateProcess. If create_process failed retry appending an ".exe"
15956 suffix. Store the GetLastError result immediatelly after
15957 create_process calls and use it on the call to error.
15958
15959 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
15960
15961 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
15962
15963 2007-08-23 Joel Brobecker <brobecker@adacore.com>
15964
15965 * configure.ac: Switch license to GPLv3.
15966
15967 2007-08-01 Michael Snyder <msnyder@access-company.com>
15968
15969 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
15970
15971 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
15972
15973 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
15974 typedef.
15975 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
15976 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
15977 CloseToolhelp32Snapshot.
15978 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
15979 CloseToolhelp32Snapshot.
15980
15981 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
15982
15983 * server.c (main): Check for inferior exit before main loop.
15984
15985 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
15986
15987 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
15988 instead of on tmp_desc.
15989
15990 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
15991 Daniel Jacobowitz <dan@codesourcery.com>
15992
15993 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
15994 (add_thread): Minor cleanups.
15995 (clear_inferiors): Move lower in the file. Clear the DLL
15996 list.
15997 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
15998 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
15999 (xml_escape_text): New.
16000 * server.c (handle_query): Handle qXfer:libraries:read. Report it
16001 for qSupported.
16002 (handle_v_cont): Report errors.
16003 (gdbserver_version): Update.
16004 (main): Correct size of own_buf. Do not report initial DLL events.
16005 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
16006 (unloaded_dll, xml_escape_text): New.
16007 * win32-low.c (enum target_waitkind): Update comments.
16008 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
16009 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
16010 (win32_EnumProcessModules, win32_GetModuleInformation)
16011 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
16012 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
16013 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
16014 (win32_Module32First, win32_Module32Next, load_toolhelp)
16015 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
16016 (get_child_debug_event): Handle DLL events.
16017 (win32_wait): Likewise.
16018
16019 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
16020
16021 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
16022 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
16023
16024 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
16025
16026 * win32-low.c (handle_output_debug_string): Ignore event if not
16027 waiting.
16028
16029 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
16030
16031 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
16032
16033 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
16034
16035 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
16036
16037 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
16038
16039 * inferiors.c (change_inferior_id): Add comment.
16040 * linux-low.c (check_removed_breakpoint): Add an early
16041 prototype. Improve debug output.
16042 (linux_attach): Doc update.
16043 (linux_detach_one_process, linux_detach): Clean up before releasing
16044 each process.
16045 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
16046 * linux-low.h (struct process_info): Doc improvement.
16047 * mem-break.c (delete_all_breakpoints): New.
16048 * mem-break.h (delete_all_breakpoints): New prototype.
16049 * thread-db.c (find_first_thread): New.
16050 (thread_db_create_event): Call it instead of
16051 thread_db_find_new_threads. Clean up unused variables.
16052 (maybe_attach_thread): Remove first thread handling.
16053 (thread_db_find_new_threads): Use find_first_thread.
16054 (thread_db_get_tls_address): Likewise.
16055
16056 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
16057
16058 * thread-db.c (thread_db_find_new_threads): Add prototype.
16059 (thread_db_create_event): Check for the main thread before adding
16060 a new thread.
16061 (maybe_attach_thread): Only enable event reporting if TID == 0.
16062 (thread_db_get_tls_address): Check for new threads.
16063
16064 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
16065
16066 * linux-low.c (linux_create_inferior): Try execv before execvp.
16067 * spu-low.c (spu_create_inferior): Likewise.
16068
16069 2007-06-13 Mike Frysinger <vapier@gentoo.org>
16070
16071 * linux-low.c (linux_create_inferior): Change execv to execvp.
16072 * spu-low.c (spu_create_inferior): Likewies.
16073
16074 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
16075
16076 * Makefile.in (clean): Clean new files instead of deleted ones.
16077 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
16078 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
16079 rules.
16080 * configure.srv: Specify XML files and new regformats for MIPS and
16081 MIPS64 GNU/Linux.
16082 * linux-mips-low.c (mips_num_regs): Set to only used registers.
16083 (mips_regmap): Do not fetch $0. Remove unused registers. Add
16084 an entry for the restart register.
16085 (mips_cannot_fetch_register, mips_cannot_store_register)
16086 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
16087 register names to match the XML descriptions.
16088 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
16089 restart register instead of $0.
16090
16091 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
16092 Markus Deuling <deuling@de.ibm.com>
16093
16094 * remote-utils.c (decode_xfer_write): New function.
16095 * server.h (decode_xfer_write): Add prototype.
16096 * server.c (handle_query): Add PACKET_LEN argument. Support
16097 qXfer:spu:read and qXfer:spu:write packets.
16098 (main): Pass packet_len to handle_query.
16099 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
16100 * target.h (target_ops): Add qxfer_spu.
16101
16102 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
16103
16104 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
16105 accessing non-seekable spufs files.
16106
16107 2007-05-16 Markus Deuling <deuling@de.ibm.com>
16108
16109 * server.c (handle_query): Add reply for qC packet.
16110
16111 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16112 Leo Zayas <lerele@champenstudios@com>
16113
16114 * server.h (check_remote_input_interrupt_request): New function.
16115 * remote_utils.c (INVALID_DESCRIPTOR): New define.
16116 (remote_desc): Initialize with INVALID_DESCRIPTOR.
16117 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
16118 (check_remote_input_interrupt_request): New function.
16119 * server.h (check_remote_input_interrupt_request): Declare.
16120 * win32-low.c (winapi_DebugBreakProcess,
16121 winapi_GenerateConsoleCtrlEvent): New typedefs.
16122 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
16123 to 250 ms.
16124 (win32_wait): Check for remote interrupt request
16125 with check_remote_input_interrupt_request.
16126 (win32_request_interrupt): New function.
16127 (win32_target_op): Set request_interrupt to win32_request_interrupt.
16128
16129 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16130
16131 * win32-low.c (debug_registers_changed,
16132 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
16133 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
16134 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
16135 (thread_rec): Get context using the low target.
16136 (child_add_thread): Call thread_added on the low target,
16137 which does the same thing.
16138 (regptr): Delete.
16139 (do_initial_child_stuff): Remove debug registers references.
16140 Set context using the low target. Resume threads after
16141 setting the contexts.
16142 (child_continue): Remove dead variable. Remove debug
16143 registers references.
16144 (child_fetch_inferior_registers): Go through the low target.
16145 (do_child_store_inferior_registers): Remove.
16146 (child_store_inferior_registers): Go through the low target.
16147 (win32_resume): Remove debug registers references.
16148 Set context using the low target.
16149 (handle_exception): Change return type to void. Don't record
16150 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
16151 first chance exception.
16152 (get_child_debug_event): Change return type to void. Remove
16153 goto loop. Always return after waiting for debug event.
16154 (win32_wait): Convert to switch statement. Handle spurious
16155 events.
16156
16157 * win32-i386-low.c (debug_registers_changed,
16158 debug_registers_used): New.
16159 (initial_stuff): Rename to ...
16160 (i386_initial_stuff): ... this. Clear debug registers
16161 state variables.
16162 (store_debug_registers): Delete.
16163 (i386_get_thread_context): New.
16164 (load_debug_registers): Delete.
16165 (i386_set_thread_context): New.
16166 (i386_thread_added): New.
16167 (single_step): Rename to ...
16168 (i386_single_step): ... this.
16169 (do_fetch_inferior_registers): Rename to ...
16170 (i386_fetch_inferior_register): ... this.
16171 (i386_store_inferior_register): New.
16172 (the_low_target): Adapt to new interface.
16173
16174 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
16175 (arm_get_thread_context): New.
16176 (arm_set_thread_context): New.
16177 (regptr): New.
16178 (do_fetch_inferior_registers): Rename to ...
16179 (arm_fetch_inferior_register): ... this.
16180 (arm_store_inferior_register): New.
16181 (arm_wince_breakpoint): Reimplement as unsigned long.
16182 (arm_wince_breakpoint_len): Define.
16183 (the_low_target): Adapt to new interface.
16184
16185 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
16186 load_debug_registers. Add get_thread_context, set_thread_context,
16187 thread_added and store_inferior_register. Rename
16188 fetch_inferior_registers to fetch_inferior_register.
16189 (regptr): Remove declaration.
16190
16191 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16192
16193 * linux-low.c (linux_detach): Change return type to int. Return 0.
16194 * spu-low.c (spu_detach): Likewise.
16195
16196 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16197
16198 * target.h (target_ops): Change return type of detach to int.
16199 Add join.
16200 (join_inferior): New.
16201 * server.c (main): Don't skip detach support on mingw32.
16202 If the inferior doesn't support detaching return error.
16203 Call join_inferior instead of using waitpid.
16204 * linux-low.c (linux_join): New.
16205 (linux_target_op): Add linux_join.
16206 * spu-low.c (spu_join): New.
16207 (spu_target_ops): Add spu_join.
16208 * win32-low.c (win32_detach): Adapt to new interface.
16209 Reopen current_process_handle before detaching. Issue a child
16210 resume before detaching.
16211 (win32_join): New.
16212 (win32_target_op): Add win32_join.
16213
16214 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16215
16216 * win32-low.c (win32-attach): Fix return value.
16217 * target.h (target_ops): Describe ATTACH return values.
16218
16219 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16220
16221 * win32-low.c (GETPROCADDRESS): Define.
16222 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
16223 (winapi_DebugSetProcessKillOnExit): Likewise.
16224 (win32_create_inferior): Force usage of ansi CreateProcessA.
16225 (win32_attach): Use GETPROCADDRESS.
16226 (win32_detach): Likewise.
16227
16228 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16229
16230 * win32-low.c (win32_wait): Don't use WSTOPSIG.
16231
16232 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
16233
16234 * win32-low.c: Commit leftover changes from 2007-03-29.
16235
16236 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
16237
16238 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
16239 fields short instead of int. Add explicit padding.
16240 (i387_cache_to_fsave): Remove unnecessary casts.
16241 (i387_fsave_to_cache): Doc fix.
16242 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
16243
16244 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
16245
16246 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
16247 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
16248
16249 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
16250
16251 * configure.srv (arm*-*-mingw32ce*): Move near the other
16252 arm targets.
16253
16254 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
16255
16256 * configure.ac: Add errno checking.
16257 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
16258 sys/file.h and malloc.h.
16259 (AC_CHECK_DECLS): Add perror.
16260 (srv_mingwce): Handle.
16261 * configure.srv (i[34567]86-*-cygwin*): Add
16262 win32-i386-low.o to srv_tgtobj.
16263 (i[34567]86-*-mingw*): Likewise.
16264 (arm*-*-mingw32ce*): Add case.
16265 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
16266 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
16267 [__MINGW32CE__] (strerror): New function.
16268 [__MINGW32CE__] (errno): Define to GetLastError.
16269 [__MINGW32CE__] (COUNTOF): New macro.
16270 (remote_open): Remove extra close call.
16271 * mem-break.c (delete_breakpoint_at): New function.
16272 * mem-break.h (delete_breakpoint_at): Declare.
16273 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
16274 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
16275 [USE_WIN32API] (read, write): Add char* casts.
16276 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
16277 * server.h: Include wincecompat.h on Windows CE.
16278 [HAVE_ERRNO_H]: Check.
16279 (perror): Declare if not declared.
16280 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
16281 (perror_with_name): Remove errno declaration.
16282 * wincecompat.h: New.
16283 * wincecompat.c: New.
16284 * win32-low.h: New.
16285 * win32-arm-low.c: New.
16286 * win32-i386-low.c: New.
16287 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
16288 (OUTMSG2): Make it safe.
16289 (_T): New macro.
16290 (COUNTOF): New macro.
16291 (NUM_REGS): Get it from the low target.
16292 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
16293 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
16294 (thread_rec): Let low target handle debug registers.
16295 (child_add_thread): Likewise.
16296 (child_init_thread_list): Likewise.
16297 (continue_one_thread): Likewise.
16298 (regptr): New.
16299 (do_child_fetch_inferior_registers): Move to ...
16300 * win32-i386-low.c: ... here, and rename to ...
16301 (do_fetch_inferior_registers): ... this.
16302 * win32-low.c (child_fetch_inferior_registers):
16303 Go through the low target.
16304 (do_child_store_inferior_registers): Use regptr.
16305 (strwinerror): New function.
16306 (win32_create_inferior): Handle Windows CE.
16307 Use strwinerror instead of strerror on Windows error
16308 codes. Add program to the error output.
16309 Don't close the main thread handle on Windows CE.
16310 (win32_attach): Use coredll.dll on Windows CE.
16311 (win32_kill): Close current process and current
16312 thread handles.
16313 (win32_detach): Use coredll.dll on Windows CE.
16314 (win32_resume): Let low target handle debug registers, and
16315 step request.
16316 (handle_exception): Add/Remove initial breakpoint. Avoid
16317 non-existant WSTOPSIG on Windows CE.
16318 (win32_read_inferior_memory): Cast to remove warning.
16319 (win32_arch_string): Go through the low target.
16320 (initialize_low): Call set_breakpoint_data with the low
16321 target's breakpoint.
16322 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
16323 FOP_REGNUM, mappings): Move to ...
16324 * win32-i386-low.c: ... here.
16325 * win32-low.c (win32_thread_info): Move to ...
16326 * win32-low.h: ... here.
16327 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
16328 win32-arm-low.c and wincecompat.c.
16329 (all:): Add $EXEEXT.
16330 (install-only:): Likewise.
16331 (gdbserver:): Likewise.
16332 (gdbreplay:): Likewise.
16333 * config.in: Regenerate.
16334 * configure: Regenerate.
16335
16336 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
16337
16338 * win32-low.c: Rename typedef thread_info to
16339 win32_thread_info throughout.
16340
16341 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
16342
16343 * win32-i386-low.c: Rename to ...
16344 * win32-low.c: ... this.
16345 * configure.srv: Replace win32-i386-low.o with win32-low.o.
16346 * Makefile.in: Likewise.
16347
16348 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
16349
16350 * remote-utils.c (monitor_output): Constify msg parameter.
16351 * server.h (monitor_output): Likewise.
16352 * win32-i386-low.c (handle_output_debug_string): New.
16353 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
16354 handle_output_debug_string.
16355 (get_child_debug_event): Likewise.
16356
16357 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
16358
16359 * server.c (main): Correct strtoul check.
16360
16361 2007-03-27 Jon Ringle <jon@ringle.org>
16362
16363 * linux-low.c: Check __ARCH_HAS_MMU__ also.
16364
16365 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
16366
16367 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
16368
16369 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
16370
16371 * terminal.h: Check HAVE_SGTTY_H.
16372
16373 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
16374
16375 * remote-utils.c (remote_open): Print out the assigned port number.
16376
16377 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
16378
16379 * remote-utils.c (monitor_output): New function.
16380 * server.c (debug_threads): Define here.
16381 (monitor_show_help): New function.
16382 (handle_query): Handle qRcmd.
16383 (main): Do not handle 'd' packet.
16384 * server.h (debug_threads, remote_debug, monitor_output): Declare.
16385 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
16386 of debug_threads.
16387
16388 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16389
16390 * Makefile.in (EXEEXT): New.
16391 (clean): Use $(EXEEXT).
16392
16393 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16394
16395 * target.h (target_ops): Rename send_signal to request_interrupt,
16396 and remove enum target_signal parameter.
16397 * linux-low.c (linux_request_interrupt): Rename from
16398 linux_send_signal, and always send SIGINT.
16399 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
16400 and always send SIGINT.
16401 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
16402 of send_signal.
16403 (input_interrupt): Likewise.
16404
16405 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16406
16407 * server.c (get_features_xml): Check if target implemented
16408 arch_string.
16409 * win32-i386-low.c (win32_arch_string): New.
16410 (win32_target_ops): Add win32_arch_string as arch_string member.
16411
16412 2007-02-22 Markus Deuling <deuling@de.ibm.com>
16413
16414 * spu-low.c (spu_arch_string): New.
16415 (spu_target_ops): Add spu_arch_string.
16416
16417 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
16418
16419 * remote-utils.c: Remove HAVE_TERMINAL_H check.
16420 * configure.ac: Do not check for terminal.h.
16421 * configure, config.in: Regenerated.
16422
16423 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
16424
16425 * Makefile.in (OBS): Add $(XML_BUILTIN).
16426 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
16427 (clean): Update.
16428 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
16429 (arm-with-iwmmxt.c): New.
16430 * config.in, configure: Regenerate.
16431 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
16432 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
16433 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
16434 (arm*-*-linux*): Add iWMMXt and regset support.
16435 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
16436 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
16437 (arm_store_wmmxregset, target_regsets): New.
16438 * server.c (get_features_xml): Take annex argument. Check builtin
16439 XML documents.
16440 (handle_query): Handle multiple annexes.
16441
16442 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
16443
16444 * remote-utils.c [USE_WIN32API] (read, write): Define.
16445 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
16446 write.
16447
16448 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
16449
16450 * linux-i386-low.c (the_low_target): Set arch_string.
16451 * linux-x86-64-low.c (the_low_target): Likewise.
16452 * linux-low.c (linux_arch_string): New.
16453 (linux_target_ops): Add it.
16454 * linux-low.h (struct linux_target_ops): Add arch_string.
16455 * server.c (write_qxfer_response): Use const void * for DATA.
16456 (get_features_xml): New.
16457 (handle_query): Handle qXfer:features:read. Report it for qSupported.
16458 * target.h (struct target_ops): Add arch_string method.
16459
16460 2007-01-03 Denis Pilat <denis.pilat@st.com>
16461 Daniel Jacobowitz <dan@codesourcery.com>
16462
16463 * linux-low.c (linux_kill): Handle being called with no threads.
16464 * win32-i386-low.c (win32_kill): Likewise.
16465 (get_child_debug_event): Clear current_process_handle.
16466
16467 2006-12-30 Denis PILAT <denis.pilat@st.com>
16468 Daniel Jacobowitz <dan@codesourcery.com>
16469
16470 * remote-utils.c (remote_open): Check the type of specified
16471 serial port devices before opening them.
16472 * server.c (main): Kill the inferior if an error occurs during
16473 the first remote_open.
16474
16475 2006-12-05 Markus Deuling <deuling@de.ibm.com>
16476
16477 * README: Update supported targets.
16478
16479 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
16480
16481 * Makefile.in (clean): Remove reg-mips64.c.
16482 (reg-mips64.c, reg-mips64.o): New rules.
16483 * configure.srv: Handle mips64. Include regset support for mips.
16484 * linux-mips-low.c (union mips_register): New.
16485 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
16486 (mips_breakpoint, mips_breakpoint_at): Use int.
16487 (mips_collect_register, mips_supply_register)
16488 (mips_collect_register_32bit, mips_supply_register_32bit)
16489 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
16490 (mips_store_fpregset, target_regsets): New.
16491 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
16492
16493 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
16494
16495 * configure.srv: Add target "spu*-*-*".
16496 * Makefile.in (clean): Remove reg-spu.c.
16497 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
16498 * spu-low.c: New file.
16499
16500 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
16501
16502 * configure.ac: Correct td_thr_tls_get_addr test.
16503 * configure: Regenerated.
16504
16505 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
16506
16507 * linux-low.c (linux_wait_for_event): Reformat. Use the
16508 pass_signals array.
16509 * remote-utils.c (decode_address_to_semicolon): New.
16510 * server.c (pass_signals, handle_general_set): New.
16511 (handle_query): Mention QPassSignals for qSupported.
16512 (main): Call handle_general_set.
16513 * server.h (pass_signals, decode_address_to_semicolon): New.
16514
16515 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
16516
16517 * server.c (handle_query): Correct error handling for read_auxv.
16518
16519 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
16520
16521 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
16522 and srv_linux_thread_db to yes.
16523 * linux-s390-low.c (s390_fill_gregset): New function.
16524 (target_regsets): Define data structure.
16525
16526 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
16527
16528 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
16529 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
16530 * config.in, configure: Regenerated.
16531 * inferiors.c (gdb_id_to_thread): New function.
16532 (gdb_id_to_thread_id): Use it.
16533 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
16534 * linux-low.h (struct process_info): Add th member.
16535 (thread_db_get_tls_address): New prototype.
16536 * remote-utils.c (decode_address): Make non-static.
16537 * server.c (handle_query): Handle qGetTLSAddr.
16538 * server.h (gdb_id_to_thread, decode_address): New prototypes.
16539 * target.h (struct target_ops): Add get_tls_address.
16540 * thread-db.c (maybe_attach_thread): Save the thread handle.
16541 (thread_db_get_tls_address): New.
16542
16543 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
16544
16545 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
16546 (linux_resume_one_process): Take a siginfo_t *. Update all
16547 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
16548 (struct pending_signals): Add a siginfo_t.
16549 (linux_wait_for_process): Always set last_status.
16550 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
16551 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
16552 * linux-low.h (struct process_info): Add last_status.
16553
16554 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
16555
16556 * remote-utils.c (try_rle): New function.
16557 (putpkt_binary): Use it.
16558
16559 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
16560
16561 * Makefile.in (clean): Clean reg-x86-64-linux.c.
16562 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
16563 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
16564 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
16565 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
16566 point registers.
16567
16568 2006-08-08 Richard Sandiford <richard@codesourcery.com>
16569
16570 * server.c (terminal_fd): New variable.
16571 (old_foreground_pgrp): Likewise.
16572 (restore_old_foreground_pgrp): New function.
16573 (start_inferior): Record the terminal file descriptor in terminal_fd
16574 and its original foreground group in old_foreground_pgrp. Register
16575 restore_old_foreground_pgrp with atexit().
16576
16577 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
16578
16579 * server.c (handle_query): Correct qPart to qXfer.
16580
16581 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
16582
16583 * configure.ac: Check for more headers which are missing on
16584 Windows. Automatically supply -lwsock32 and USE_WIN32API.
16585 * configure.srv: Add Cygwin and mingw32.
16586 * remote-utils.c: Don't include headers unconditionally which
16587 are missing on mingw32. Include <winsock.h> for mingw32.
16588 (remote_open): Adjust for mingw32 support. Flush
16589 standard error after writing to it.
16590 (remote_close, putpkt_binary, input_interrupt, block_async_io)
16591 (unblock_async_io, enable_async_io, disable_async_io)
16592 (readchar, getpkt): Update for Winsock support.
16593 (prepare_resume_reply): Expect a protocol signal number.
16594 * server.c: Disable <sys/wait.h> on mingw32.
16595 (start_inferior): Adjust for mingw32 support. Flush
16596 standard error after writing to it.
16597 (attach_inferior): Likewise. Use protocol signal
16598 numbers.
16599 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
16600 and names.
16601 * win32-i386-low.c: New file.
16602 * Makefile.in (XM_CLIBS): Set.
16603 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
16604 (win32-i386-low.o): New dependency rule.
16605 * linux-low.c (linux_wait): Use target signal numbers.
16606 * target.h (struct target_ops): Doc fix.
16607 * server.h (target_signal_to_name): New prototype.
16608 * gdbreplay.c: Don't include headers unconditionally which
16609 are missing on mingw32. Include <winsock.h> for mingw32.
16610 (remote_close, remote_open): Adjust for Winsock support.
16611 * configure, config.in: Regenerated.
16612
16613 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
16614
16615 * server.c (decode_xfer_read, write_qxfer_response): New.
16616 (handle_query): Take a packet length argument. Handle
16617 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
16618 the qSupported response.
16619 (main): Update call to handle_query.
16620
16621 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
16622
16623 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
16624 (putpkt_binary): Renamed from putpkt and adjusted for binary
16625 data.
16626 (putpkt): New wrapper for putpkt_binary.
16627 (readchar): Don't mask off the high bit.
16628 (decode_X_packet): New function.
16629 * server.c (main): Call putpkt_binary if a handler sets the packet
16630 length. Save the length of the incoming packet. Handle 'X'.
16631 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
16632
16633 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
16634
16635 * server.c (handle_query): Handle qSupported.
16636
16637 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
16638
16639 * remote-utils.c (all_symbols_looked_up): New variable.
16640 (look_up_one_symbol): Check it.
16641 * server.h (look_up_one_symbol): New declaration.
16642 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
16643
16644 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
16645
16646 * Makefile.in (linux-arm-low.o): Update dependencies.
16647 * linux-arm-low.c: Include "gdb_proc_service.h".
16648 (PTRACE_GET_THREAD_AREA): Define.
16649 (ps_get_thread_area): New function.
16650
16651 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
16652
16653 * configure.srv (m68k*-*-uclinux*): New target.
16654 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
16655 (linux_resume_one_process): Remove extraneous cast.
16656 (linux_read_offsets): New.
16657 (linux_target_op): Add linux_read_offsets on mmuless systems.
16658 * server.c (handle_query): Add qOffsets logic.
16659 * target.h (struct target_ops): Add read_offsets.
16660
16661 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
16662
16663 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
16664 (PTRACE_GET_THREAD_AREA): Define.
16665 (ps_get_thread_area): New function.
16666 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
16667 (linux-x86-64-low.o): Update.
16668
16669 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
16670
16671 * configure.ac: Remove checks for prfpregset_t.
16672 * gdb_proc_service.h: New file.
16673 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
16674 new "gdb_proc_service.h".
16675 * proc-service.c: Likewise.
16676 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
16677 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
16678 * Makefile.in (gdb_proc_service_h): Updated.
16679 * configure, config.in: Regenerated.
16680
16681 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
16682
16683 * remote-utils.c (prepare_resume_reply): Move declaration
16684 of gdb_id_from_wait to the top of the block.
16685
16686 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
16687
16688 * linux-low.c (regsets_store_inferior_registers): Read the regset
16689 from the target before filling it.
16690
16691 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
16692
16693 * server.c (attach_inferior): Return SIGTRAP for a successful
16694 attach.
16695
16696 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
16697
16698 * Makefile.in (OBS): Add version.o.
16699 (STAGESTUFF): Delete.
16700 (version.o): Add dependencies.
16701 (version.c): Replace rule.
16702 (clean): Remove version.c.
16703 * server.c (gdbserver_version): New.
16704 (gdbserver_usage): Use printf.
16705 (main): Handle --version and --help.
16706 * server.h (version, host_name): Add declarations.
16707
16708 2005-12-23 Eli Zaretskii <eliz@gnu.org>
16709
16710 * linux-arm-low.c:
16711 * linux-arm-low.c:
16712 * inferiors.c:
16713 * i387-fp.h:
16714 * i387-fp.c:
16715 * gdbreplay.c:
16716 * regcache.c:
16717 * proc-service.c:
16718 * mem-break.h:
16719 * mem-break.c:
16720 * linux-x86-64-low.c:
16721 * linux-sh-low.c:
16722 * linux-s390-low.c:
16723 * linux-ppc64-low.c:
16724 * linux-ppc-low.c:
16725 * linux-mips-low.c:
16726 * linux-m68k-low.c:
16727 * linux-m32r-low.c:
16728 * linux-low.h:
16729 * linux-low.c:
16730 * linux-ia64-low.c:
16731 * linux-i386-low.c:
16732 * linux-crisv32-low.c:
16733 * thread-db.c:
16734 * terminal.h:
16735 * target.h:
16736 * target.c:
16737 * server.h:
16738 * server.c:
16739 * remote-utils.c:
16740 * regcache.h:
16741 * utils.c:
16742 * Makefile.in:
16743 * configure.ac:
16744 * gdbserver.1: Add (C) after Copyright. Update the FSF
16745 address.
16746
16747 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
16748
16749 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
16750 (arm_breakpoint_at): Recognize both breakpoints.
16751 (the_low_target): Use the correct breakpoint instruction.
16752
16753 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
16754
16755 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
16756 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
16757 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
16758 (the_low_target): Update.
16759
16760 2005-10-25 Andreas Schwab <schwab@suse.de>
16761
16762 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
16763
16764 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
16765 (ia64_num_regs): Reduce to 462.
16766
16767 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
16768
16769 * acinclude.m4: Correct quoting.
16770 * aclocal.m4: Regenerated.
16771
16772 Suggested by SZOKOVACS Robert <szo@ies.hu>:
16773 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
16774 (thread_db_init): Call thread_db_err_str.
16775 * configure.ac: Check for TD_VERSION.
16776 * config.in, configure: Regenerated.
16777
16778 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16779
16780 * server.h (error, fatal, warning): Add ATTR_FORMAT.
16781
16782 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16783
16784 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
16785 is not available. Define HAVE_PTRACE_GETREGS if it is.
16786 * config.in, configure: Regenerated.
16787 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
16788 * linux-i386-low.c, linux-m68k-low.c: Update to use
16789 HAVE_PTRACE_GETREGS.
16790 * linux-low.c (regsets_fetch_inferior_registers)
16791 (regsets_store_inferior_registers): Only return 0 if we processed
16792 GENERAL_REGS.
16793 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
16794 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
16795
16796 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16797
16798 * inferiors.c (struct thread_info): Add gdb_id.
16799 (add_thread): Add gdb_id argument.
16800 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
16801 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
16802 calls to add_thread.
16803 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
16804 * server.c (handle_query): Use thread_to_gdb_id.
16805 (handle_v_cont, main): Use gdb_id_to_thread_id.
16806 * server.h (add_thread): Update prototype.
16807 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
16808 prototypes.
16809
16810 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16811
16812 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
16813 left-padded registers.
16814 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
16815 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
16816
16817 2005-07-01 Steve Ellcey <sje@cup.hp.com>
16818
16819 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
16820 * configure: Regenerate.
16821 * config.in: Regenerate.
16822 * server.h (NEED_DECLARATION_STRERROR):
16823 Replace with !HAVE_DECL_STRERROR.
16824
16825 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
16826
16827 * linux-low.c (linux_wait, linux_send_signal): Don't test
16828 an unsigned long variable for > 0 if it could be MAX_ULONG.
16829 * server.c (myresume): Likewise.
16830 * target.c (set_desired_inferior): Likewise.
16831
16832 2005-06-13 Mark Kettenis <kettenis@gnu.org>
16833
16834 * configure.ac: Simplify and improve check for socklen_t.
16835 * configure, config.in: Regenerate.
16836
16837 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
16838
16839 * acconfig.h: Remove.
16840 * configure.ac: Add a test for socklen_t. Use three-argument
16841 AC_DEFINE throughout.
16842 * config.in: Regenerated using autoheader 2.59.
16843 * configure: Regenerated.
16844
16845 * gdbreplay.c (socklen_t): Provide a default.
16846 (remote_open): Use socklen_t.
16847 * remote-utils.c (socklen_t): Provide a default.
16848 (remote_open): Use socklen_t.
16849 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
16850 unsigned char.
16851
16852 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
16853 char for buffers.
16854 * linux-low.c (linux_read_memory, linux_write_memory)
16855 (linux_read_auxv): Likewise.
16856 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
16857 (check_mem_write): Likewise.
16858 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
16859 Likewise.
16860 * regcache.c (struct inferior_rgcache_data, registers_to_string)
16861 (registers_from_string, register_data): Likewise.
16862 * server.c (handle_query, main): Likewise.
16863 * server.h (convert_ascii_to_int, convert_int_to_ascii)
16864 (decode_M_packet): Likewise.
16865 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
16866 * target.h (struct target_ops): Update read_memory, write_memory,
16867 and read_auxv.
16868 (read_inferior_memory, write_inferior_memory): Update.
16869 * linux-low.h (struct linux_target_ops): Change type of breakpoint
16870 to unsigned char *.
16871 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
16872 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
16873 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
16874 linux-s390-low.c, linux-sh-low.c: Update for changes in
16875 read_inferior_memory and the_low_target->breakpoint.
16876
16877 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
16878
16879 * Makefile.in (SFILES): Add linux-ppc64-low.c.
16880 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
16881 * configure.srv: Add powerpc64-*-linux*.
16882 * linux-ppc64-low.c: New file.
16883
16884 2005-05-23 Orjan Friberg <orjanf@axis.com>
16885
16886 * linux-cris-low.c: New file with support for CRIS.
16887 * linux-crisv32-low.c: Ditto for CRISv32.
16888 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
16889 (clean): Add reg-cris.c and reg-crisv32.c.
16890 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
16891 reg-crisv32.o, and reg-crisv32.c to make rules.
16892 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
16893 recognized targets.
16894
16895 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
16896
16897 * linux-low.c (fetch_register): Ensure buffer size is a multiple
16898 of sizeof (PTRACE_XFER_TYPE).
16899 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
16900
16901 2005-05-12 Orjan Friberg <orjanf@axis.com>
16902
16903 * target.h (struct target_ops): Add insert_watchpoint,
16904 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
16905 pointers for hardware watchpoint support.
16906 * linux-low.h (struct linux_target_ops): Ditto.
16907 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
16908 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
16909 to linux_target_ops.
16910 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
16911 reply packet.
16912 * server.c (main): Recognize 'Z' and 'z' packets.
16913
16914 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
16915
16916 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
16917 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
16918 (the_low_target): Add new members.
16919
16920 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
16921
16922 * proc-service.c (ps_lgetregs): Search all_processes instead of
16923 all_threads.
16924
16925 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
16926
16927 * server.c (start_inferior): Change return type to int.
16928 (attach_inferior): Change sigptr to int *.
16929 (handle_v_cont, handle_v_requests): Change signal to int *.
16930 (main): Change signal to int.
16931
16932 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
16933
16934 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
16935 * configure.srv: Add m32r*-*-linux*.
16936 * linux-m32r-low.c: New file.
16937
16938 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
16939
16940 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
16941
16942 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
16943
16944 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
16945 Take unsigned long arguments for PIDs.
16946 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
16947 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
16948 (wait_for_sigstop, linux_resume_one_process)
16949 (regsets_fetch_inferior_registers, linux_send_signal)
16950 (linux_read_auxv): Likewise. Update the types of variables holding
16951 PIDs. Update format string specifiers.
16952 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
16953 * remote-utils.c (prepare_resume_reply): Likewise.
16954 * server.c (cont_thread, general_thread, step_thread)
16955 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
16956 unsigned long.
16957 (handle_query): Update format specifiers.
16958 (handle_v_cont, main): Use strtoul for thread IDs.
16959 * server.h (struct inferior_list_entry): Use unsigned long for ID.
16960 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
16961 (general_thread, step_thread, thread_from_wait)
16962 (old_thread_from_wait): Update.
16963 * target.h (struct thread_resume): Use unsigned long for THREAD.
16964 (struct target_ops): Use unsigned long for arguments to attach and
16965 thread_alive.
16966
16967 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
16968
16969 * acinclude.m4: Include bfd/bfd.m4 directly.
16970 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
16971 <agriffis@toolchain.org>.
16972 * aclocal.m4, configure: Regenerated.
16973
16974 2005-01-07 Andrew Cagney <cagney@gnu.org>
16975
16976 * configure.ac: Rename configure.in, require autoconf 2.59.
16977 * configure: Re-generate.
16978
16979 2004-12-08 Daniel Jacobowitz <dan@debian.org>
16980
16981 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
16982 LIBS when finished.
16983 * aclocal.m4: Regenerated.
16984 * configure: Regenerated.
16985
16986 2004-11-21 Andreas Schwab <schwab@suse.de>
16987
16988 * linux-m68k-low.c (m68k_num_gregs): Define.
16989 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
16990 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
16991 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
16992 (m68k_breakpoint_at): New. Add to the_low_target.
16993
16994 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
16995 srv_linux_thread_db to yes.
16996
16997 2004-10-20 Joel Brobecker <brobecker@gnat.com>
16998
16999 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
17000 (ARCH_SET_FS): Likewise.
17001 (ARCH_GET_FS): Likewise.
17002 (ARCH_GET_GS): Likewise.
17003
17004 2004-10-16 Daniel Jacobowitz <dan@debian.org>
17005
17006 * linux-i386-low.c (ps_get_thread_area): New.
17007 * linux-x86-64-low.c (ps_get_thread_area): New.
17008 * linux-low.c: Include <sys/syscall.h>.
17009 (linux_kill_one_process): Don't kill the first thread here.
17010 (linux_kill): Kill the first thread here.
17011 (kill_lwp): New function.
17012 (send_sigstop, linux_send_signal): Use it.
17013 * proc-service.c: Clean up #ifdefs.
17014 (fpregset_info): Delete.
17015 (ps_lgetregs): Update and enable implementation.
17016 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
17017 implementations.
17018 * remote-utils.c (struct sym_cache, symbol_cache): New.
17019 (input_interrupt): Print a clearer message.
17020 (async_io_enabled): New variable.
17021 (enable_async_io, disable_async_io): Use it. Update comments.
17022 (look_up_one_symbol): Use the symbol cache.
17023 * thread-db.c (thread_db_look_up_symbols): New function.
17024 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
17025
17026 2004-10-16 Daniel Jacobowitz <dan@debian.org>
17027
17028 * configure.in: Test for -rdynamic.
17029 * configure: Regenerated.
17030 * Makefile (INTERNAL_LDFLAGS): New.
17031 (gdbserver, gdbreplay): Use it.
17032
17033 2004-09-02 Andrew Cagney <cagney@gnu.org>
17034
17035 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
17036
17037 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
17038
17039 * linux-low.c (linux_wait): Clear all_processes list also.
17040
17041 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
17042
17043 * linux-low.c: Include <errno.h>. Remove extern declaration of
17044 errno.
17045
17046 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
17047
17048 * gdbreplay.c, server.h, utils.c: Update copyright years.
17049
17050 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
17051
17052 * server.c (main): Print child status or termination signal from
17053 variable 'signal', not 'sig'.
17054
17055 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
17056
17057 * linux-low.c (linux_read_memory): Change return type to
17058 int. Check for and return error from ptrace().
17059 * target.c (read_inferior_memory): Change return type to int. Pass
17060 back return status from the_target->read_memory().
17061 * target.h (struct target_ops): Adapt *read_memory() prototype.
17062 Update comment.
17063 (read_inferior_memory): Adapt prototype.
17064 * server.c (main): Return an error packet if
17065 read_inferior_memory() returns an error.
17066
17067 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
17068
17069 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
17070 Unify with other clean targets.
17071
17072 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17073
17074 * server.c (handle_v_cont): Call set_desired_inferior.
17075
17076 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17077
17078 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
17079
17080 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17081
17082 * linux-low.c (linux_wait): Unblock async I/O.
17083 (linux_resume): Block and enable async I/O.
17084 * remote-utils.c (block_async_io, unblock_async_io): New functions.
17085 * server.h (block_async_io, unblock_async_io): Add prototypes.
17086
17087 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17088
17089 * remote-utils.c (remote_open): Print a status notice after
17090 opening a TCP port.
17091 * server.c (attach_inferior): Print a status notice after
17092 attaching.
17093
17094 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17095
17096 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
17097
17098 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
17099
17100 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
17101 error packet.
17102 * server.c, target.h: Update copyright years.
17103
17104 2004-02-25 Roland McGrath <roland@redhat.com>
17105
17106 * target.h (struct target_ops): New member `read_auxv'.
17107 * server.c (handle_query): Handle qPart:auxv:read: query using that.
17108 * linux-low.c (linux_read_auxv): New function.
17109 (linux_target_ops): Initialize `read_auxv' member to that.
17110
17111 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
17112
17113 Committed by Jim Blandy <jimb@redhat.com>.
17114
17115 * linux-s390-low.c (s390_num_regs): Update.
17116 (s390_regmap): Remove control registers. Use __s390x__ predefine
17117 instead of GPR_SIZE to distiguish s390 and s390x targets.
17118
17119 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
17120
17121 * linux-low.c: Update copyright year.
17122 (check_removed_breakpoint): Clear pending_is_breakpoint.
17123 (linux_set_resume_request, linux_queue_one_thread)
17124 (resume_status_pending_p): New functions.
17125 (linux_continue_one_thread): Use process->resume.
17126 (linux_resume): Only resume threads if there are no pending events.
17127 * linux-low.h (struct process_info): Add resume request
17128 pointer.
17129
17130 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
17131
17132 * regcache.c (new_register_cache): Clear the allocated register
17133 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
17134
17135 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
17136
17137 * linux-low.c (linux_resume): Take a struct thread_resume *
17138 argument.
17139 (linux_wait): Update call.
17140 (resume_ptr): New static variable.
17141 (linux_continue_one_thread): Renamed from
17142 linux_continue_one_process. Use resume_ptr.
17143 (linux_resume): Use linux_continue_one_thread.
17144 * server.c (handle_v_cont, handle_v_requests): New functions.
17145 (myresume): New function.
17146 (main): Handle 'v' case.
17147 * target.h (struct thread_resume): New type.
17148 (struct target_ops): Change argument of "resume" to struct
17149 thread_resume *.
17150 (myresume): Delete macro.
17151
17152 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
17153
17154 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
17155 (uninstall): Support DESTDIR.
17156
17157 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
17158
17159 * configure.srv: Add xscale*linux copy of arm*linux entry.
17160
17161 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
17162
17163 * linux-arm-low.c (arm_reinsert_addr): New function.
17164 (the_low_target): Add arm_reinsert_addr.
17165
17166 2003-07-08 Mark Kettenis <kettenis@gnu.org>
17167
17168 * mem-break.c: Remove whitespace at end of file.
17169
17170 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
17171
17172 * configure.in: Check whether we need to prototype strerror.
17173 * server.h: Optionally prototype strerror.
17174 * gdbreplay.c (perror_with_name): Use strerror.
17175 * linux-low.c (linux_attach_lwp): Use strerror.
17176 * utils.c (perror_with_name): Use strerror.
17177 * config.in, configure: Regenerated.
17178
17179 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
17180
17181 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
17182 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
17183
17184 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
17185
17186 * Makefile.in (SFILES): Update.
17187 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
17188 low-sun3.c: Remove files.
17189
17190 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
17191
17192 * linux-low.c: Move comment to linux_thread_alive where it belonged.
17193 (linux_detach_one_process, linux_detach): New functions.
17194 (linux_target_ops): Add linux_detach.
17195 * server.c (main): Handle 'D' packet.
17196 * target.h (struct target_ops): Add "detach" member.
17197 (detach_inferior): Define.
17198
17199 2003-06-13 Mark Kettenis <kettenis@gnu.org>
17200
17201 From Kelley Cook <kelleycook@wideopenwest.com>:
17202 * configure.srv: Accept i[34567]86 variants.
17203
17204 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
17205
17206 * linux-low.c (linux_wait_for_event): Correct comment typos.
17207 (linux_resume_one_process): Call check_removed_breakpoint.
17208 (linux_send_signal): New function.
17209 (linux_target_ops): Add linux_send_signal.
17210 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
17211 of kill.
17212 * target.h (struct target_ops): Add send_signal.
17213
17214 2003-05-29 Jim Blandy <jimb@redhat.com>
17215
17216 * linux-low.c (usr_store_inferior_registers): Transfer buf in
17217 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
17218 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
17219 away part of the register's value.
17220
17221 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
17222
17223 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
17224 (linux_wait_for_event, linux_init_signals): Likewise.
17225
17226 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
17227
17228 * configure.in: Check for stdlib.h.
17229 * configure: Regenerated.
17230 * config.in: Regenerated.
17231
17232 2003-01-04 Andreas Schwab <schwab@suse.de>
17233
17234 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
17235
17236 2003-01-02 Andrew Cagney <ac131313@redhat.com>
17237
17238 * Makefile.in: Remove obsolete code.
17239
17240 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
17241
17242 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
17243 defined(PT_FPR0_HI).
17244
17245 2002-11-17 Stuart Hughes <seh@zee2.com>
17246
17247 * linux-arm-low.c (arm_num_regs): Increase.
17248 (arm_regmap): Include status register.
17249
17250 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
17251
17252 * linux-low.c (register_addr): Remove incorrect -1 check.
17253
17254 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
17255
17256 * linux-low.c (linux_create_inferior): Call setpgid. Return
17257 the new PID.
17258 (unstopped_p, linux_signal_pid): Remove.
17259 (linux_target_ops): Remove linux_signal_pid.
17260 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
17261 global instead of target method.
17262 * target.h (struct target_ops): Remove signal_pid. Update comment
17263 for create_inferior.
17264 * server.c (signal_pid): New variable.
17265 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
17266 gdbserver. Set the child to be the foreground process group.
17267 (attach_inferior): Set signal_pid.
17268
17269 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
17270
17271 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
17272
17273 2002-08-20 Jim Blandy <jimb@redhat.com>
17274
17275 * Makefile.in (LDFLAGS): Allow the configure script to establish a
17276 default for this.
17277
17278 2002-08-01 Andrew Cagney <cagney@redhat.com>
17279
17280 * Makefile.in: Make chill references obsolete.
17281
17282 2002-07-24 Kevin Buettner <kevinb@redhat.com>
17283
17284 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
17285 * configure: Regenerate.
17286 * config.in: Regenerate.
17287
17288 2002-07-09 David O'Brien <obrien@FreeBSD.org>
17289
17290 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
17291 (perror_with_name, remote_close, remote_open, expect, play): Static.
17292
17293 2002-07-04 Michal Ludvig <mludvig@suse.cz>
17294
17295 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
17296 byte offsets instead of an array of indexes.
17297 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
17298
17299 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
17300
17301 * regcache.c: Add comment.
17302
17303 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
17304
17305 * thread-db.c: New file.
17306 * proc-service.c: New file.
17307 * acinclude.m4: New file.
17308 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
17309 proc-service.o, and thread-db.o.
17310 (linux-low.o): Add USE_THREAD_DB.
17311 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
17312 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
17313 * aclocal.m4: Regenerated.
17314 * config.in: Regenerated.
17315 * configure: Regenerated.
17316 * configure.in: Check for proc_service.h, sys/procfs.h,
17317 thread_db.h, and linux/elf.h headrs.
17318 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
17319 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
17320 Check for -lthread_db and thread support.
17321 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
17322 PowerPC, and SuperH.
17323 * i387-fp.c: Constify arguments.
17324 * i387-fp.h: Likewise.
17325 * inferiors.c: (struct thread_info): Renamed from
17326 `struct inferior_info'. Remove PID member. Use generic inferior
17327 list header. All uses updated.
17328 (inferiors, signal_pid): Removed.
17329 (all_threads): New variable.
17330 (get_thread): Define.
17331 (add_inferior_to_list): New function.
17332 (for_each_inferior): New function.
17333 (change_inferior_id): New function.
17334 (add_inferior): Removed.
17335 (remove_inferior): New function.
17336 (add_thread): New function.
17337 (free_one_thread): New function.
17338 (remove_thread): New function.
17339 (clear_inferiors): Use for_each_inferior and free_one_thread.
17340 (find_inferior): New function.
17341 (find_inferior_id): New function.
17342 (inferior_target_data): Update argument type.
17343 (set_inferior_target_data): Likewise.
17344 (inferior_regcache_data): Likewise.
17345 (set_inferior_regcache_data): Likewise.
17346 * linux-low.c (linux_bp_reinsert): Remove.
17347 (all_processes, stopping_threads, using_thrads)
17348 (struct pending_signals, debug_threads, pid_of): New.
17349 (inferior_pid): Replace with macro.
17350 (struct inferior_linux_data): Remove.
17351 (get_stop_pc, add_process): New functions.
17352 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
17353 Use add_process and add_thread.
17354 (linux_attach_lwp): New function, based on old linux_attach. Use
17355 add_process and add_thread. Set stop_expected for new threads.
17356 (linux_attach): New function.
17357 (linux_kill_one_process): New function.
17358 (linux_kill): Kill all LWPs.
17359 (linux_thread_alive): Use find_inferior_id.
17360 (check_removed_breakpoints, status_pending_p): New functions.
17361 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
17362 Update. Use WNOHANG. Wait for cloned processes also. Update process
17363 struct for the found process.
17364 (linux_wait_for_event): New function.
17365 (linux_wait): Use it. Support LWPs.
17366 (send_sigstop, wait_for_sigstop, stop_all_processes)
17367 (linux_resume_one_process, linux_continue_one_process): New functions.
17368 (linux_resume): Support LWPs.
17369 (REGISTER_RAW_SIZE): Remove.
17370 (fetch_register): Use register_size instead. Call supply_register.
17371 (usr_store_inferior_registers): Likewise. Call collect_register.
17372 Fix recursive case.
17373 (regsets_fetch_inferior_registers): Improve error message.
17374 (regsets_store_inferior_registers): Add debugging.
17375 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
17376 (unstopped_p, linux_signal_pid): New functions.
17377 (linux_target_ops): Add linux_signal_pid.
17378 (linux_init_signals): New function.
17379 (initialize_low): Call it. Initialize using_threads.
17380 * regcache.c (inferior_regcache_data): Add valid
17381 flag.
17382 (get_regcache): Fetch registers lazily. Add fetch argument
17383 and update all callers.
17384 (regcache_invalidate_one, regcache_invalidate): New
17385 functions.
17386 (new_register_cache): Renamed from create_register_cache.
17387 Return the new regcache.
17388 (free_register_cache): Change argument to a void *.
17389 (registers_to_string, registers_from_string): Call get_regcache
17390 with fetch flag set.
17391 (register_data): Make static. Pass fetch flag to get_regcache.
17392 (supply_register): Call get_regcache with fetch flag clear.
17393 (collect_register): Call get_regcache with fetch flag set.
17394 (collect_register_as_string): New function.
17395 * regcache.h: Update.
17396 * remote-utils.c (putpkt): Flush after debug output and use
17397 stderr.
17398 Handle input interrupts while waiting for an ACK.
17399 (input_interrupt): Use signal_pid method.
17400 (getpkt): Flush after debug output and use stderr.
17401 (outreg): Use collect_register_as_string.
17402 (new_thread_notify, dead_thread_notify): New functions.
17403 (prepare_resume_reply): Check using_threads. Set thread_from_wait
17404 and general_thread.
17405 (look_up_one_symbol): Flush after debug output.
17406 * server.c (step_thread, server_waiting): New variables.
17407 (start_inferior): Don't use signal_pid. Update call to mywait.
17408 (attach_inferior): Update call to mywait.
17409 (handle_query): Handle qfThreadInfo and qsThreadInfo.
17410 (main): Don't fetch/store registers explicitly. Use
17411 set_desired_inferior. Support proposed ``Hs'' packet. Update
17412 calls to mywait.
17413 * server.h: Update.
17414 (struct inferior_list, struct_inferior_list_entry): New.
17415 * target.c (set_desired_inferior): New.
17416 (write_inferior_memory): Constify.
17417 (mywait): New function.
17418 * target.h: Update.
17419 (struct target_ops): New signal_pid method.
17420 (mywait): Removed macro, added prototype.
17421
17422 * linux-low.h (regset_func): Removed.
17423 (regset_fill_func, regset_store_func): New.
17424 (enum regset_type): New.
17425 (struct regset_info): Add type field. Use new operation types.
17426 (struct linux_target_ops): stop_pc renamed to get_pc.
17427 Add decr_pc_after_break and breakpoint_at.
17428 (get_process, get_thread_proess, get_process_thread)
17429 (strut process_info, all_processes, linux_attach_lwp)
17430 (thread_db_init): New.
17431
17432 * linux-arm-low.c (arm_get_pc, arm_set_pc,
17433 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
17434 (the_low_target): Add new members.
17435 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
17436 (i386_store_fpxregset): Constify.
17437 (target_regsets): Add new kind identifier.
17438 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
17439 (i386_set_pc): Add debugging.
17440 (i386_breakpoint_at): New function.
17441 (the_low_target): Add new members.
17442 * linux-mips-low.c (mips_get_pc, mips_set_pc)
17443 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
17444 (mips_breakpoint_at): New.
17445 (the_low_target): Add new members.
17446 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
17447 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
17448 (the_low_target): Add new members.
17449 * linux-sh-low.c (sh_get_pc, sh_set_pc)
17450 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
17451 (the_low_target): Add new members.
17452 * linux-x86-64-low.c (target_regsets): Add new kind
17453 identifier.
17454
17455 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
17456
17457 From Martin Pool <mbp@samba.org>:
17458 * server.c (gdbserver_usage): New function.
17459 (main): Call it.
17460
17461 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
17462
17463 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
17464 stop_at -> stop_pc.
17465
17466 2002-05-04 Andrew Cagney <ac131313@redhat.com>
17467
17468 * Makefile.in: Remove obsolete code.
17469
17470 2002-04-24 Michal Ludvig <mludvig@suse.cz>
17471
17472 * linux-low.c (regsets_fetch_inferior_registers),
17473 (regsets_store_inferior_registers): Removed cast to int from
17474 ptrace() calls.
17475 * regcache.h: Added declaration of struct inferior_info.
17476
17477 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
17478
17479 * inferiors.c (struct inferior_info): Add regcache_data.
17480 (add_inferior): Call create_register_cache.
17481 (clear_inferiors): Call free_register_cache.
17482 (inferior_regcache_data, set_inferior_regcache_data): New functions.
17483 * regcache.c (struct inferior_regcache_data): New.
17484 (registers): Remove.
17485 (get_regcache): New function.
17486 (create_register_cache, free_register_cache): New functions.
17487 (set_register_cache): Don't initialize the register cache here.
17488 (registers_to_string, registers_from_string, register_data): Call
17489 get_regcache.
17490 * regcache.h: Add prototypes.
17491 * server.h: Likewise.
17492
17493 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
17494
17495 * mem-break.c: New file.
17496 * mem-break.h: New file.
17497 * Makefile.in: Add mem-break.o rule; update server.h
17498 dependencies.
17499 * inferiors.c (struct inferior_info): Add target_data
17500 member.
17501 (clear_inferiors): Free target_data member if set.
17502 (inferior_target_data, set_inferior_target_data): New functions.
17503 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
17504 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
17505 * linux-low.c (linux_bp_reinsert): New variable.
17506 (struct inferior_linux_data): New.
17507 (linux_create_inferior): Use set_inferior_target_data.
17508 (linux_attach): Likewise. Call add_inferior.
17509 (linux_wait_for_one_inferior): New function.
17510 (linux_wait): Call it.
17511 (linux_write_memory): Add const.
17512 (initialize_low): Call set_breakpoint_data.
17513 * linux-low.h (struct linux_target_ops): Add breakpoint
17514 handling members.
17515 * server.c (attach_inferior): Remove extra add_inferior
17516 call.
17517 * server.h: Include mem-break.h. Update inferior.c
17518 prototypes.
17519 * target.c (read_inferior_memory)
17520 (write_inferior_memory): New functions.
17521 * target.h (read_inferior_memory)
17522 (write_inferior_memory): Change macros to prototypes.
17523 (struct target_ops): Update comments. Add const to write_memory
17524 definition.
17525
17526 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
17527
17528 * linux-low.c (usr_store_inferior_registers): Support
17529 registers which are allowed to fail to store.
17530 * linux-low.h (linux_target_ops): Likewise.
17531 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
17532 (ppc_cannot_store_register): FPSCR may not be storable.
17533
17534 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17535
17536 * server.h: Include <string.h> if HAVE_STRING_H.
17537 * ChangeLog: Correct paths in last ChangeLog entry.
17538
17539 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17540
17541 * linux-low.h: Remove obsolete prototypes.
17542 (struct linux_target_ops): New.
17543 (extern the_low_target): New.
17544 * linux-low.c (num_regs, regmap): Remove declarations.
17545 (register_addr): Use the_low_target explicitly.
17546 (fetch_register): Likewise.
17547 (usr_fetch_inferior_registers): Likewise.
17548 (usr_store_inferior_registers): Likewise.
17549 * linux-arm-low.c (num_regs): Remove.
17550 (arm_num_regs): Define.
17551 (arm_regmap): Renamed from regmap, made static.
17552 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
17553 made static.
17554 (arm_cannot_store_register): Renamed from cannot_store_register,
17555 made static.
17556 (the_low_target): New.
17557 * linux-i386-low.c (num_regs): Remove.
17558 (i386_num_regs): Define.
17559 (i386_regmap): Renamed from regmap, made static.
17560 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
17561 made static.
17562 (i386_cannot_store_register): Renamed from cannot_store_register,
17563 made static.
17564 (the_low_target): New.
17565 * linux-ia64-low.c (num_regs): Remove.
17566 (ia64_num_regs): Define.
17567 (ia64_regmap): Renamed from regmap, made static.
17568 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
17569 made static.
17570 (ia64_cannot_store_register): Renamed from cannot_store_register,
17571 made static.
17572 (the_low_target): New.
17573 * linux-m68k-low.c (num_regs): Remove.
17574 (m68k_num_regs): Define.
17575 (m68k_regmap): Renamed from regmap, made static.
17576 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
17577 made static.
17578 (m68k_cannot_store_register): Renamed from cannot_store_register,
17579 made static.
17580 (the_low_target): New.
17581 * linux-mips-low.c (num_regs): Remove.
17582 (mips_num_regs): Define.
17583 (mips_regmap): Renamed from regmap, made static.
17584 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
17585 made static.
17586 (mips_cannot_store_register): Renamed from cannot_store_register,
17587 made static.
17588 (the_low_target): New.
17589 * linux-ppc-low.c (num_regs): Remove.
17590 (ppc_num_regs): Define.
17591 (ppc_regmap): Renamed from regmap, made static.
17592 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
17593 made static.
17594 (ppc_cannot_store_register): Renamed from cannot_store_register,
17595 made static.
17596 (the_low_target): New.
17597 * linux-s390-low.c (num_regs): Remove.
17598 (s390_num_regs): Define.
17599 (s390_regmap): Renamed from regmap, made static.
17600 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
17601 made static.
17602 (s390_cannot_store_register): Renamed from cannot_store_register,
17603 made static.
17604 (the_low_target): New.
17605 * linux-sh-low.c (num_regs): Remove.
17606 (sh_num_regs): Define.
17607 (sh_regmap): Renamed from regmap, made static.
17608 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
17609 made static.
17610 (sh_cannot_store_register): Renamed from cannot_store_register,
17611 made static.
17612 (the_low_target): New.
17613 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
17614 (the_low_target): New.
17615
17616 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17617
17618 * Makefile.in: Add stamp-h target.
17619 * configure.in: Create stamp-h.
17620 * configure: Regenerated.
17621
17622 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17623
17624 * inferiors.c: New file.
17625 * target.c: New file.
17626 * target.h: New file.
17627 * Makefile.in: Add target.o and inferiors.o. Update
17628 dependencies.
17629 * linux-low.c (inferior_pid): New static variable,
17630 moved from server.c.
17631 (linux_create_inferior): Renamed from create_inferior.
17632 Call add_inferior. Return 0 on success instead of a PID.
17633 (linux_attach): Renamed from myattach.
17634 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
17635 (linux_thread_alive): Renamed from mythread_alive.
17636 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
17637 child dies.
17638 (linux_resume): Renamed from myresume. Add missing ``return 0''.
17639 (regsets_store_inferior_registers): Correct error message.
17640 Add missing ``return 0''.
17641 (linux_fetch_registers): Renamed from fetch_inferior_registers.
17642 (linux_store_registers): Renamed from store_inferior_registers.
17643 (linux_read_memory): Renamed from read_inferior_memory.
17644 (linux_write_memory): Renamed from write_inferior_memory.
17645 (linux_target_ops): New structure.
17646 (initialize_low): Call set_target_ops ().
17647 * remote-utils.c (unhexify): New function.
17648 (hexify): New function.
17649 (input_interrupt): Send signals to ``signal_pid''.
17650 * server.c (inferior_pid): Remove.
17651 (start_inferior): Update create_inferior call.
17652 (attach_inferior): Call add_inferior.
17653 (handle_query): New function.
17654 (main): Call handle_query for `q' packets.
17655 * server.h: Include "target.h". Remove obsolete prototypes.
17656 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
17657
17658 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17659
17660 * Makefile.in: Add WARN_CFLAGS. Update configury
17661 dependencies.
17662 * configure.in: Check for <string.h>
17663 * configure: Regenerate.
17664 * config.in: Regenerate.
17665 * gdbreplay.c: Include needed system headers.
17666 (remote_open): Remove strchr prototype.
17667 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
17668 * regcache.c (supply_register): Change buf argument to const void *.
17669 (supply_register_by_name): Likewise.
17670 (collect_register): Change buf argument to void *.
17671 (collect_register_by_name): Likewise.
17672 * regcache.h: Add missing prototypes.
17673 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
17674 * server.c (handle_query): New function.
17675 (attached): New static variable, moved out of main.
17676 (main): Quiet longjmp clobber warnings.
17677 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
17678 * utils.c (error): Remove NORETURN.
17679 (fatal): Likewise.
This page took 0.393607 seconds and 5 git commands to generate.