c0c6f51a0695b9891f8c275e7f2f3792d47d6a9d
[deliverable/binutils-gdb.git] / gdb / gdbserver / ChangeLog
1 2019-09-20 Christian Biesinger <cbiesinger@google.com>
2
3 * debug.c (debug_threads): Remove comment in favor of the header.
4 * debug.h (using_threads): Add declaration.
5 (debug_threads): Add comment.
6 * linux-aarch64-low.c: Include debug.h and remove declaration of
7 debug_threads.
8 * nto-low.c: Likewise.
9 * remote-utils.c: Likewise.
10 * thread-db.c: Likewise.
11
12 2019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
13
14 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
15 and powerpc-cell64l-ipa.o.
16 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
17 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
18 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
19 (spu*-*-*): Remove.
20
21 * spu-low.c: Remove file.
22
23 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
24 (parse_spufs_run): Remove.
25 (ppc_get_pc): Remove Cell/B.E. support.
26 (ppc_set_pc): Likewise.
27 (ppc_breakpoint_at): Likewise.
28 (ppc_arch_setup): Likewise.
29 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
30 tdesc_powerpc_cell32l.
31 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
32 or init_registers_powerpc_cell32l.
33 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
34 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
35 or init_registers_powerpc_cell32l.
36 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
37 (init_registers_powerpc_cell32l): Remove prototype.
38 (init_registers_powerpc_cell64l): Likewise.
39
40 * target.h (struct target_ops): Remove qxfer_spu member.
41 * server.c (handle_qxfer_spu): Remove.
42 (qxfer_packets): Remove entry for "spu".
43 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
44 * linux-low.c (SPUFS_MAGIC): Remove.
45 (spu_enumerate_spu_ids): Remove.
46 (linux_qxfer_spu): Remove.
47 (linux_target_ops): Remove qxfer_spu member.
48 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
49 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
50 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
51
52 2019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
53
54 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
55 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
56 * config.in: Regenerate.
57 * configure: Regenerate.
58
59 2019-08-15 Tom Tromey <tromey@adacore.com>
60
61 * target.c (target_write_memory): Use gdb::byte_vector.
62
63 2019-08-15 Tom Tromey <tromey@adacore.com>
64
65 * tracepoint.c (write_inferior_data_pointer)
66 (write_inferior_integer, write_inferior_int8)
67 (write_inferior_uinteger, m_tracepoint_action_download)
68 (r_tracepoint_action_download, x_tracepoint_action_download)
69 (l_tracepoint_action_download, clear_inferior_trace_buffer)
70 (download_agent_expr, download_tracepoint_1)
71 (download_trace_state_variables, upload_fast_traceframes): Update.
72 * server.c (gdb_write_memory): Update.
73 * remote-utils.c (relocate_instruction): Update.
74 * proc-service.c (ps_pdwrite): Update.
75 * mem-break.c (remove_memory_breakpoint)
76 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
77 (uninsert_fast_tracepoint_jumps_at)
78 (reinsert_fast_tracepoint_jumps_at): Update.
79 * linux-x86-low.c (append_insns)
80 (i386_install_fast_tracepoint_jump_pad)
81 (amd64_write_goto_address, i386_write_goto_address): Update.
82 * linux-s390-low.c (append_insns, s390_write_goto_address):
83 Update.
84 * linux-ppc-low.c (ppc_relocate_instruction)
85 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
86 (ppc_write_goto_address): Update.
87 * linux-aarch64-low.c (append_insns): Update.
88 * target.h (struct target_ops): Update.
89 (write_inferior_memory): Don't declare.
90 * target.c (target_write_memory): Rename from
91 write_inferior_memory. Remove old target_write_memory.
92
93 2019-08-15 Tom Tromey <tromey@adacore.com>
94
95 * target.c (write_inferior_memory): Use std::vector.
96
97 2019-08-06 Frank Ch. Eigler <fche@redhat.com>
98
99 PR build/24886
100 * configure.ac: Drop enable-libmcheck support.
101 * configure, config.in: Rebuild.
102 * acinclude.m4: Don't include it.
103
104 2019-07-19 Alan Hayward <alan.hayward@arm.com>
105
106 * configure.srv: Remove Arm xml files.
107
108 2019-07-19 Alan Hayward <alan.hayward@arm.com>
109
110 * configure.srv: Add new files. Remove xml generated files.
111 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
112 registers.
113 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
114 * linux-aarch32-tdesc.c: New file.
115 * linux-aarch32-tdesc.h: New file.
116 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
117 * linux-arm-low.c (init_registers_arm, tdesc_arm)
118 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
119 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
120 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
121 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
122 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
123 (arm_read_description): Call arm_linux_read_description.
124 (initialize_low_arch): Don't init registers.
125 * linux-arm-tdesc.c: New file.
126 * linux-arm-tdesc.h: New file.
127
128 2019-07-10 Alan Hayward <alan.hayward@arm.com>
129
130 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
131 Move counter inside for.
132 (arm_read_description): Check ptrace earlier.
133 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
134
135 2019-07-09 Tom Tromey <tom@tromey.com>
136
137 * configure: Rebuild.
138 * configure.ac: Change common to gdbsupport.
139 * acinclude.m4: Change common to gdbsupport.
140 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
141 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
142 common to gdbsupport.
143 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
144 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
145 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
146 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
147 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
148 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
149 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
150 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
151 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
152 common to gdbsupport.
153
154 2019-07-04 Alan Hayward <alan.hayward@arm.com>
155
156 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
157 defines.
158 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
159
160 2019-07-04 Alan Hayward <alan.hayward@arm.com>
161
162 * configure.srv: Remove legacy xml.
163 * linux-aarch64-low.c (initialize_low_arch): Remove
164 initialize_low_tdesc call.
165 * linux-aarch64-tdesc-selftest.c: Remove file.
166 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
167 * linux-x86-low.c (initialize_low_arch): Remove
168 initialize_low_tdesc call.
169 * linux-x86-tdesc-selftest.c: Remove file.
170 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
171
172 2019-06-20 Tom de Vries <tdevries@suse.de>
173
174 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
175 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
176
177 2019-06-19 Tom de Vries <tdevries@suse.de>
178
179 * debug.h (debug_write): Change return type to ssize_t.
180 * debug.c (debug_write): Same.
181
182 2019-06-14 Tom Tromey <tom@tromey.com>
183
184 * configure.ac: Use new path to gnulib.
185 * configure: Rebuild.
186 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
187 to gnulib.
188
189 2019-06-11 Tom Tromey <tom@tromey.com>
190
191 * Makefile.in (SFILES): Add alloc.c.
192 (OBS): Add alloc.o.
193 (IPA_OBJS): Add alloc-ipa.o.
194 (alloc-ipa.o): New target.
195 (%.o: ../%.c): New pattern rule.
196
197 2019-06-10 Tom Tromey <tromey@adacore.com>
198
199 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
200 end warning with a newline.
201 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
202 newline.
203 * thread-db.c (attach_thread): Don't end warning with a newline.
204 (thread_db_notice_clone): Likewise.
205 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
206 newline.
207 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
208 end warning with a newline.
209
210 2019-06-04 Pedro Alves <palves@redhat.com>
211
212 * server.c (captured_main): Use make_unique_xstrdup.
213
214 2019-06-02 Tom Tromey <tom@tromey.com>
215
216 * gdbreplay.c (fromhex): Remove.
217 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
218
219 2019-05-29 Tom Tromey <tromey@adacore.com>
220
221 * configure: Rebuild.
222
223 2019-05-06 Kevin Buettner <kevinb@redhat.com>
224
225 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
226 sign extension code on 32-bit builds.
227
228 2019-05-03 Eli Zaretskii <eliz@gnu.org>
229
230 * remote-utils.c:
231 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
232
233 2019-04-19 Tom Tromey <tom@tromey.com>
234
235 * server.c (struct vstop_notif): Derive from notif_event.
236 <base>: Remove.
237 (queue_stop_reply): Update.
238 (remove_all_on_match_ptid): Change type. Rewrite.
239 (discard_queued_stop_replies): Rewrite.
240 (in_queued_stop_replies_ptid): Change type.
241 (in_queued_stop_replies): Rewrite.
242 (notif_stop): Update.
243 (queue_stop_reply_callback): Update.
244 (captured_main): Don't call initialize_notif.
245 (push_stop_notification): Update.
246 * notif.c (notif_write_event, handle_notif_ack)
247 (notif_event_enque, notif_push): Update.
248 (notif_event_xfree, initialize_notif): Remove.
249 * notif.h (struct notif_event): Include <list>, not
250 "common/queue.h".
251 (struct notif_server) <queue>: Now a std::list.
252 (notif_event_p): Remove typedef.
253 (initialize_notif): Don't declare.
254 (struct notif_event): Add virtual destructor.
255
256 2019-04-17 Alan Hayward <alan.hayward@arm.com>
257
258 * ax.c (ax_vdebug): Call debug_printf.
259 * debug.c (debug_write): New function.
260 * debug.h (debug_write): New declaration.
261 * linux-low.c (sigchld_handler): Call debug_write.
262
263 2019-04-17 Alan Hayward <alan.hayward@arm.com>
264
265 * debug.c (debug_set_output): New function.
266 (debug_vprintf): Send output to debug_file.
267 (debug_flush): Likewise.
268 * debug.h (debug_set_output): New declaration.
269 * server.c (handle_monitor_command): Add debug-file option.
270 (captured_main): Likewise.
271
272 2019-04-17 Alan Hayward <alan.hayward@arm.com>
273
274 * debug.c (remote_debug): Add definition.
275 * debug.h (remote_debug): Add declaration.
276 * hostio.c (remote_debug): Remove declaration.
277 * remote-utils.c (struct ui_file): Likewise.
278 (remote_debug): Likewise.
279 * remote-utils.h (remote_debug): Likewise,
280 * server.c (remote_debug): Remove definition.
281
282 2019-04-10 Kevin Buettner <kevinb@redhat.com>
283
284 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
285 when using a 64-bit gdbserver.
286
287 2019-04-09 Tom Tromey <tromey@adacore.com>
288
289 * linux-low.c (select_event_lwp): Use find_thread_in_random.
290
291 2019-04-08 Tom Tromey <tom@tromey.com>
292
293 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
294 throw.
295 (linux_resume_one_lwp): Likewise.
296
297 2019-04-08 Tom Tromey <tom@tromey.com>
298
299 * gdbreplay.c: Update.
300 * linux-low.c: Update.
301 * server.c: Update.
302
303 2019-04-08 Tom Tromey <tom@tromey.com>
304
305 * server.c: Use C++ exception handling.
306 * linux-low.c: Use C++ exception handling.
307 * gdbreplay.c: Use C++ exception handling.
308
309 2019-04-08 Tom Tromey <tom@tromey.com>
310
311 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
312 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
313 (captured_main, main): Update.
314 * gdbreplay.c (main): Update.
315
316 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
317
318 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
319 value in argument pointer, return 1 if the entry is found and 0
320 otherwise. Move comment.
321 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
322 * linux-low.h (linux_get_auxv): Declare.
323 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
324
325 2019-04-05 Tom Tromey <tromey@adacore.com>
326
327 * server.c (gdbserver_usage): Use upper-case for metasyntactic
328 variables.
329
330 2019-03-28 Alan Hayward <alan.hayward@arm.com>
331
332 * linux-low.c (AT_HWCAP2): Add define if not already included.
333
334 2019-03-26 Alan Hayward <alan.hayward@arm.com>
335
336 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
337 (aarch64_arch_setup): Call linux_get_hwcap.
338 * linux-arm-low.c (arm_get_hwcap): Remove function.
339 (arm_read_description): Call linux_get_hwcap.
340 * linux-low.c (linux_get_auxv): New function.
341 (linux_get_hwcap): Likewise.
342 (linux_get_hwcap2): Likewise.
343 * linux-low.h (linux_get_hwcap): New declaration.
344 (linux_get_hwcap2): Likewise.
345 * linux-ppc-low.c (ppc_get_auxv): Remove function.
346 (ppc_arch_setup): Call linux_get_hwcap.
347 * linux-s390-low.c (s390_get_hwcap): Remove function.
348 (s390_arch_setup): Call linux_get_hwcap.
349
350 2019-03-22 Alan Hayward <alan.hayward@arm.com>
351 Jiong Wang <jiong.wang@arm.com>
352
353 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
354 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
355 to fail.
356 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
357
358 2019-03-22 Alan Hayward <alan.hayward@arm.com>
359 Jiong Wang <jiong.wang@arm.com>
360
361 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
362 (aarch64_get_hwcap): New function.
363 (aarch64_arch_setup): Read APIA hwcap.
364
365 2019-03-22 Alan Hayward <alan.hayward@arm.com>
366 Jiong Wang <jiong.wang@arm.com>
367
368 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
369 (initialize_low_tracepoint): Likewise.
370 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
371 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
372 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
373 (aarch64_linux_read_description): Likewise.
374 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
375
376 2019-03-12 John Baldwin <jhb@FreeBSD.org>
377
378 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
379 i386_create_target_description for 'segments' parameter.
380 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
381 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
382 * win32-i386-low.c (i386_arch_setup): Likewise.
383
384 2019-03-12 Tom Tromey <tromey@adacore.com>
385
386 * linux-low.c (iterate_over_lwps): Update.
387
388 2019-03-06 Tom Tromey <tom@tromey.com>
389
390 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
391 (captured_main): Use SCOPE_EXIT.
392
393 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
394
395 * configure.srv: Use '$enable_unittest' instead of '$development'
396 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
397 case.
398
399 2019-02-27 Tom Tromey <tromey@adacore.com>
400
401 * gdbreplay.c (logchar): Handle \r\n.
402
403 2019-02-07 Alan Hayward <alan.hayward@arm.com>
404
405 * linux-low.c (linux_attach): Add process before lwp.
406 * server.c (attach_inferior): Check if already attached.
407
408 2019-02-07 Tom Tromey <tom@tromey.com>
409
410 * x86-tdesc.h: Rename include guard.
411 * x86-low.h: Add include guard.
412 * wincecompat.h: Rename include guard.
413 * win32-low.h: Add include guard.
414 * utils.h: Rename include guard.
415 * tracepoint.h: Rename include guard.
416 * tdesc.h: Rename include guard.
417 * target.h: Rename include guard.
418 * server.h: Rename include guard.
419 * remote-utils.h: Rename include guard.
420 * regcache.h: Rename include guard.
421 * nto-low.h: Rename include guard.
422 * notif.h: Add include guard.
423 * mem-break.h: Rename include guard.
424 * lynx-low.h: Add include guard.
425 * linux-x86-tdesc.h: Add include guard.
426 * linux-s390-tdesc.h: Add include guard.
427 * linux-ppc-tdesc-init.h: Add include guard.
428 * linux-low.h: Add include guard.
429 * linux-aarch64-tdesc.h: Add include guard.
430 * linux-aarch32-low.h: Add include guard.
431 * inferiors.h: Rename include guard.
432 * i387-fp.h: Rename include guard.
433 * hostio.h: Rename include guard.
434 * gdbthread.h: Rename include guard.
435 * gdb_proc_service.h: Rename include guard.
436 * event-loop.h: Rename include guard.
437 * dll.h: Rename include guard.
438 * debug.h: Rename include guard.
439 * ax.h: Rename include guard.
440
441 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
442
443 PR gdb/23985
444 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
445 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
446
447 2019-01-25 Tom Tromey <tom@tromey.com>
448
449 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
450
451 2019-01-25 Tom Tromey <tom@tromey.com>
452
453 * win32-low.c: Fix common/ includes.
454 * win32-i386-low.c: Fix common/ includes.
455 * tracepoint.c: Fix common/ includes.
456 * thread-db.c: Fix common/ includes.
457 * target.h: Fix common/ includes.
458 * symbol.c: Fix common/ includes.
459 * spu-low.c: Fix common/ includes.
460 * server.h: Fix common/ includes.
461 * server.c: Fix common/ includes.
462 * remote-utils.c: Fix common/ includes.
463 * regcache.h: Fix common/ includes.
464 * regcache.c: Fix common/ includes.
465 * nto-x86-low.c: Fix common/ includes.
466 * notif.h: Fix common/ includes.
467 * mem-break.h: Fix common/ includes.
468 * lynx-low.c: Fix common/ includes.
469 * lynx-i386-low.c: Fix common/ includes.
470 * linux-x86-tdesc-selftest.c: Fix common/ includes.
471 * linux-x86-low.c: Fix common/ includes.
472 * linux-low.c: Fix common/ includes.
473 * inferiors.h: Fix common/ includes.
474 * i387-fp.c: Fix common/ includes.
475 * hostio.c: Fix common/ includes.
476 * hostio-errno.c: Fix common/ includes.
477 * gdbthread.h: Fix common/ includes.
478 * gdbreplay.c: Fix common/ includes.
479 * fork-child.c: Fix common/ includes.
480 * event-loop.c: Fix common/ includes.
481 * ax.c:
482 (enum gdb_agent_op): Fix common/ includes.
483
484 2019-01-21 Tom Tromey <tom@tromey.com>
485
486 * tracepoint.c: Fix includes.
487 * remote-utils.c: Fix includes.
488 * linux-x86-low.c: Fix includes.
489
490 2019-01-01 Joel Brobecker <brobecker@adacore.com>
491
492 * gdbreplay.c (gdbreplay_version): Update copyright year in
493 version message.
494 * server.c (gdbserver_version): Likewise.
495
496 2018-12-05 Alan Hayward <alan.hayward@arm.com>
497
498 * linux-low.c (add_lwp): Switch ordering.
499
500 2018-11-29 Tom Tromey <tom@tromey.com>
501
502 * win32-low.c (win32_join): Take pid, not process.
503 * target.h (struct target_ops) <join>: Change argument type.
504 (join_inferior): Change argument name.
505 * spu-low.c (spu_join): Take pid, not process.
506 * server.c (handle_detach): Preserve pid before destroying
507 process.
508 * lynx-low.c (lynx_join): Take pid, not process.
509 * linux-low.c (linux_join): Take pid, not process.
510
511 2018-11-23 Alan Hayward <alan.hayward@arm.com>
512
513 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
514 (aarch64_cannot_fetch_register): Likewise.
515 (struct linux_target_ops): Update references.
516
517 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
518
519 * linux-ppc-low.c: Include nat/linux-ptrace.h.
520
521 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
522
523 * configure.srv (ipa_ppc_linux_regobj): Add
524 powerpc-isa207-htm-vsx32l-ipa.o and
525 powerpc-isa207-htm-vsx64l-ipa.o.
526 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
527 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
528 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
529 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
530 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
531 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
532 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
533 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
534 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
535 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
536 (init_registers_powerpc_isa207_htm_vsx32l)
537 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
538 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
539 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
540 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
541 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
542 (ppc_store_tm_ctarregset): New functions.
543 (ppc_regsets): Add entries for HTM regsets.
544 (ppc_arch_setup): Set htm in features struct when needed. Set
545 sizes for the HTM regsets.
546 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
547 (initialize_low_arch): Call
548 init_registers_powerpc_isa207_htm_vsx32l and
549 init_registers_powerpc_isa207_htm_vsx64l.
550 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
551 PPC_TDESC_ISA207_HTM_VSX.
552 (initialize_low_tracepoint): Call
553 init_registers_powerpc_isa207_htm_vsx32l and
554 init_registers_powerpc_isa207_htm_vsx64l.
555
556 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
557
558 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
559 rs6000/power-linux-pmu.xml to srv_xmlfiles.
560 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
561 (ppc_store_pmuregset): New functions.
562 (ppc_regsets): Add entries for ebb and pmu regsets.
563 (ppc_arch_setup): Set isa207 in features struct if the ebb and
564 pmu regsets are available. Set sizes for these regsets.
565
566 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
567
568 * configure.srv (ipa_ppc_linux_regobj): Add
569 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
570 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
571 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
572 rs6000/powerpc-isa207-vsx32l.xml, and
573 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
574 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
575 <PPC_TDESC_ISA207_VSX>: New enum value.
576 (init_registers_powerpc_isa207_vsx32l): Declare.
577 (init_registers_powerpc_isa207_vsx64l): Declare.
578 * linux-ppc-low.c (ppc_fill_tarregset): New function.
579 (ppc_store_tarregset): New function.
580 (ppc_regsets): Add entry for the TAR regset.
581 (ppc_arch_setup): Set isa207 in features struct when needed. Set
582 size for the TAR regsets.
583 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
584 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
585 and init_registers_powerpc_isa207_vsx64l.
586 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
587 (initialize_low_tracepoint): Call
588 init_registers_powerpc_isa207_vsx32l and
589 init_registers_powerpc_isa207_vsx64l.
590
591 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
592 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
593
594 * configure.srv (ipa_ppc_linux_regobj): Add
595 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
596 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
597 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
598 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
599 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
600 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
601 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
602 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
603 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
604 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
605 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
606 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
607 (ppc_hwcap): Add comment.
608 (ppc_hwcap2): New global.
609 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
610 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
611 (ppc_regsets): Add entries for the DSCR and PPR regsets.
612 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
613 when needed. Set sizes for the the DSCR and PPR regsets.
614 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
615 (initialize_low_arch): Call
616 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
617 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
618 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
619 PPC_TDESC_ISA205_PPR_DSCR_VSX.
620 (initialize_low_tracepoint): Call
621 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
622 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
623
624 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
625
626 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
627
628 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
629 Simon Marchi <simark@simark.ca>
630
631 * acinclude.m4: Include "../selftest.m4".
632 * configure: Regenerate.
633 * configure.ac: Use "GDB_AC_SELFTEST".
634 * configure.srv: Use "$enable_unittests" instead of
635 "$development" when checking whether unit tests have been
636 enabled.
637 * server.c (captured_main): Update message informing that
638 selftests have been disabled.
639
640 2018-10-04 Tom Tromey <tom@tromey.com>
641
642 * configure: Rebuild.
643
644 2018-10-04 Tom Tromey <tom@tromey.com>
645
646 * server.c (handle_status): Rename inner "thread".
647 (process_serial_event): Declare "res" in 'm' case.
648 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
649 (iterate_over_lwps): Rename inner "thread".
650 (linux_qxfer_libraries_svr4): Rename inner "len".
651 * gdbthread.h (find_thread_in_random): Rename inner "thread".
652
653 2018-10-01 Gary Benson <gbenson@redhat.com>
654
655 * gdb_proc_service.h: Moved common code to
656 common/gdb_proc_service.h.
657
658 2018-10-01 Gary Benson <gbenson@redhat.com>
659
660 * gdb_proc_service.h: Synchronize comments and whitespace with
661 GDB's version of this file.
662
663 2018-09-25 Tom Tromey <tom@tromey.com>
664
665 * configure: Rebuild.
666 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
667
668 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
669
670 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
671 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
672 ($(IPA_LIB)): Sort IPA_OBJS.
673
674 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
675
676 * Makefile.in: Remove references to $(ADD_DEPS).
677
678 2018-09-16 Tom Tromey <tom@tromey.com>
679
680 * remote-utils.c (remote_open): Use GNU style for metasyntactic
681 variables.
682 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
683 variables.
684
685 2018-09-05 Tom Tromey <tom@tromey.com>
686
687 * configure: Rebuild.
688
689 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
690
691 PR build/23399
692 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
693
694 2018-08-27 Tom Tromey <tom@tromey.com>
695
696 PR build/23087:
697 * configure: Rebuild.
698
699 2018-08-27 Tom Tromey <tom@tromey.com>
700
701 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
702 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
703 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
704 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
705 (s390x_emit_stack_adjust): Add casts to unsigned char.
706
707 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
708
709 PR gdb/23374
710 PR gdb/23375
711 * server.h (struct client_state) <disable_randomization>:
712 Initialize to 1.
713
714 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
715
716 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
717 variable.
718 (mips_supply_ptrace_register): Likewise.
719
720 2018-07-22 Tom Tromey <tom@tromey.com>
721
722 * configure: Rebuild.
723
724 2018-07-22 Tom Tromey <tom@tromey.com>
725
726 * win32-low.c (win32_create_inferior): Remove unused variables.
727 * gdbreplay.c (remote_open): Remove unused variable.
728 * remote-utils.c (remote_prepare): Remove unused variable.
729 * x86-tdesc.h (X86_TDESC_H): Define.
730 (amd64_expedite_regs): Define conditionally.
731 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
732 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
733 * remote-utils.c (readchar): Remove unused variable.
734
735 2018-07-13 Pedro Alves <palves@redhat.com>
736
737 * linux-low.c (linux_kill): Change parameter to process_info
738 pointer instead of pid. Adjust.
739 * lynx-low.c (lynx_kill): Likewise.
740 * nto-low.c (nto_kill): Likewise.
741 * spu-low.c (spu_kill): Likewise.
742 * win32-low.c (win32_kill): Likewise.
743 * server.c (handle_v_kill, kill_inferior_callback)
744 (detach_or_kill_for_exit): Adjust.
745 * target.c (kill_inferior): Change parameter to process_info
746 pointer instead of pid. Adjust.
747 * target.h (struct target_ops) <kill>: Change parameter to
748 process_info pointer instead of pid. Adjust all implementations
749 and callers.
750 (kill_inferior): Likewise.
751
752 2018-07-13 Pedro Alves <palves@redhat.com>
753
754 * linux-low.c (linux_detach, linux_join): Change parameter to
755 process_info pointer instead of pid. Adjust.
756 * lynx-low.c (lynx_detach, lynx_join): Likewise.
757 * nto-low.c (nto_detach): Likewise.
758 * spu-low.c (spu_detach, spu_join): Likewise.
759 * win32-low.c (win32_detach, win32_join): Likewise.
760 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
761 * target.h (struct target_ops) <detach, join>: Change parameter to
762 process_info pointer instead of pid. Adjust all implementations
763 and callers.
764 (detach_inferior, join_inferior): Rename 'pid' parameter to
765 'proc'.
766
767 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
768 Jan Kratochvil <jan.kratochvil@redhat.com>
769 Paul Fertser <fercerpav@gmail.com>
770 Tsutomu Seki <sekiriki@gmail.com>
771
772 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
773 (OBS): Add 'common/netstuff.o'.
774 (GDBREPLAY_OBS): Likewise.
775 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
776 (remote_open): Implement support for IPv6
777 connections.
778 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
779 and 'wspiapi.h'.
780 (handle_accept_event): Accept connections from IPv6 sources.
781 (remote_prepare): Handle IPv6-style hostnames; implement
782 support for IPv6 connections.
783 (remote_open): Implement support for printing connections from
784 IPv6 sources.
785
786 2018-07-11 Pedro Alves <palves@redhat.com>
787
788 PR gdb/23377
789 * mem-break.c (any_persistent_commands): Add process_info
790 parameter and use it instead of relying on the current process.
791 Change return type to bool.
792 * mem-break.h (any_persistent_commands): Add process_info
793 parameter and change return type to bool.
794 * server.c (handle_detach): Remove require_running_or_return call.
795 Look up the process_info for the process we're about to detach.
796 If not found, return back error to GDB. Adjust
797 any_persistent_commands call to pass down a process pointer.
798
799 2018-07-11 Pedro Alves <palves@redhat.com>
800
801 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
802 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
803 instead of collect_register_by_name.
804 * regcache.c (regcache_raw_get_unsigned_by_name): New.
805 * regcache.h (regcache_raw_get_unsigned_by_name): New.
806
807 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
808 Pedro Alves <palves@redhat.com>
809
810 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
811
812 2018-07-03 Tom Tromey <tom@tromey.com>
813
814 * linux-low.c: Update.
815 * lynx-low.c: Update.
816 * mem-break.c: Update.
817 * nto-low.c: Update.
818 * remote-utils.c: Update.
819 * server.c: Update.
820 * spu-low.c: Update.
821 * target.c: Update.
822 * win32-low.c: Update.
823
824 2018-07-03 Tom Tromey <tom@tromey.com>
825
826 * server.c: Update.
827
828 2018-07-03 Tom Tromey <tom@tromey.com>
829
830 * linux-low.c: Update.
831
832 2018-07-03 Tom Tromey <tom@tromey.com>
833
834 * target.c: Update.
835
836 2018-07-03 Tom Tromey <tom@tromey.com>
837
838 * linux-low.c: Update.
839 * linux-mips-low.c: Update.
840 * lynx-low.c: Update.
841 * nto-low.c: Update.
842 * remote-utils.c: Update.
843 * server.c: Update.
844 * spu-low.c: Update.
845 * target.c: Update.
846 * thread-db.c: Update.
847
848 2018-07-03 Tom Tromey <tom@tromey.com>
849
850 * linux-low.c: Update.
851 * linux-mips-low.c: Update.
852 * lynx-low.c: Update.
853 * mem-break.c: Update.
854 * nto-low.c: Update.
855 * remote-utils.c: Update.
856 * server.c: Update.
857 * spu-low.c: Update.
858 * target.c: Update.
859 * tracepoint.c: Update.
860
861 2018-07-03 Tom Tromey <tom@tromey.com>
862
863 * linux-low.c: Update.
864 * linux-ppc-low.c: Update.
865 * linux-x86-low.c: Update.
866 * proc-service.c: Update.
867 * server.c: Update.
868 * spu-low.c: Update.
869 * thread-db.c: Update.
870 * win32-low.c: Update.
871
872 2018-07-03 Tom Tromey <tom@tromey.com>
873
874 * linux-low.c: Update.
875 * lynx-low.c: Update.
876 * nto-low.c: Update.
877 * remote-utils.c: Update.
878 * spu-low.c: Update.
879 * thread-db.c: Update.
880 * win32-low.c: Update.
881
882 2018-06-29 Joel Brobecker <brobecker@adacore.com>
883
884 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
885 parameter in call to 'amd64_create_target_description'.
886
887 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
888
889 * x86-tdesc.h: Remove executable permission flag.
890
891 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
892
893 * configure.ac: Remove AC_PREREQ, add missing quoting.
894 * configure: Re-generate.
895 * config.in: Re-generate.
896 * aclocal.m4: Re-generate.
897
898 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
899
900 * tracepoint.h (current_traceframe): Remove declaration.
901
902 2018-06-18 Alan Hayward <alan.hayward@arm.com>
903
904 * linux-aarch64-low.c (is_sve_tdesc): New function.
905 (aarch64_sve_regs_copy_to_regcache): Likewise.
906 (aarch64_sve_regs_copy_from_regcache): Likewise.
907 (aarch64_regs_info): Add SVE checks.
908 (initialize_low_arch): Initialize SVE.
909
910 2018-06-18 Alan Hayward <alan.hayward@arm.com>
911
912 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
913
914 2018-06-11 Alan Hayward <alan.hayward@arm.com>
915
916 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
917 (initialize_low_tracepoint): Likewise
918 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
919 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
920 param.
921 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
922 checks.
923 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
924
925 2018-06-11 Alan Hayward <alan.hayward@arm.com>
926
927 * server.h (PBUFSIZ): Increase size
928
929 2018-06-11 Alan Hayward <alan.hayward@arm.com>
930
931 * regcache.c (regcache::raw_compare): New function.
932 * regcache.h (regcache::raw_compare): New declaration.
933
934 2018-06-11 Alan Hayward <alan.hayward@arm.com>
935
936 * regcache.c (new_register_cache): Use new.
937 (free_register_cache): Use delete.
938 (register_data): Use const.
939 (supply_register): Move body inside regcache.
940 (regcache::raw_supply): New override function.
941 (collect_register): Move body inside regcache.
942 (regcache::raw_collect): New override function.
943 (regcache::get_register_status): New override function.
944 * regcache.h (struct regcache): Inherit from reg_buffer_common.
945
946 2018-06-09 Tom Tromey <tom@tromey.com>
947
948 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
949 declare queue.
950 (event_queue): Use std::queue.
951 (gdb_event_xfree): Remove.
952 (initialize_event_loop, process_event, wait_for_event): Update.
953
954 2018-06-08 Stan Cox <scox@redhat.com>
955
956 * win32-low.c (win32_create_inferior): last_ptid and last_status
957 moved to client_state.
958
959 2018-06-08 Pedro Alves <palves@redhat.com>
960
961 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
962 common/common-exceptions.o, common/common-utils.o,
963 common/errors.o, common/print-utils.o and utils.o.
964 * gdbreplay.c: Include "common-defs.h" instead of the two
965 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
966 string.h or alloca.h.
967 (perror_with_name): Delete.
968 (remote_open): Use xstrdup instead of strdup.
969 (main): Rename to ...
970 (captured_main): ... this.
971 (main): New.
972
973 2018-06-08 Tom Tromey <tom@tromey.com>
974
975 * linux-low.c (linux_low_read_btrace): Update.
976
977 2018-06-04 Stan Cox <scox@redhat.com>
978
979 * server.h (struct client_state): New.
980 * server.c (cont_thread, general_thread, multi_process)
981 (report_fork_events, report_vfork_events, report_exec_events)
982 (report_thread_events, swbreak_feature, hwbreak_feature)
983 (vCont_supported, disable_randomization, pass_signals)
984 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
985 Moved to client_state.
986 * remote-utils.c (remote_debug, noack_mode)
987 (transport_is_reliable): Moved to client_state.
988 * tracepoint.c (current_traceframe): Moved to client_state.
989
990 Update all callers.
991 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
992 linux-low.c, remote-utils.h, target.c: Use client_state.
993
994 2018-05-31 Alan Hayward <alan.hayward@arm.com>
995
996 * configure.srv: Add new c/h file.
997
998 2018-05-31 Alan Hayward <alan.hayward@arm.com>
999
1000 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
1001 null VQ.
1002
1003 2018-05-25 Maciej W. Rozycki <macro@mips.com>
1004
1005 * gdb.arch/mips-fpregset-core.exp: New test.
1006 * gdb.arch/mips-fpregset-core.c: New test source.
1007
1008 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
1009
1010 PR server/23198
1011 * hostio.c (require_int): Do not report overflow for integers
1012 between 0xfffffff and 0x7fffffff.
1013
1014 2018-05-22 Maciej W. Rozycki <macro@mips.com>
1015
1016 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
1017 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
1018 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
1019 functions.
1020 (the_low_target): Wire them.
1021
1022 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1023
1024 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
1025 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
1026 mode. Call collect_register_by_name with vscr using
1027 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
1028 (ppc_store_vrregset): Add and set vscr_offset variable as in
1029 ppc_fill_vrregset. Call supply_register_by_name with vscr using
1030 vscr_offset.
1031
1032 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1033
1034 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
1035 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
1036 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
1037
1038 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1039
1040 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
1041 (ppc_store_vsxregset): Likewise.
1042 (ppc_fill_vrregset): Likewise.
1043 (ppc_store_vrregset): Likewise.
1044 (ppc_fill_evrregset): Likewise.
1045 (ppc_store_evrregset): Likewise.
1046 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
1047 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
1048 needed.
1049
1050 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1051
1052 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
1053 wordsize of the inferior. Call ppc_linux_target_wordsize.
1054
1055 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1056
1057 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
1058 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
1059 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
1060 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
1061 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
1062 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
1063 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
1064 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
1065 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
1066 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
1067 (tdesc_powerpc_e500l): Remove.
1068 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
1069 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
1070 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
1071 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
1072 linux-ppc-tdesc.h.
1073 (ppc_arch_setup): Remove target description matching code. Fill a
1074 ppc_linux_features struct and call ppc_linux_match_description
1075 with it.
1076
1077 2018-05-22 Maciej W. Rozycki <macro@mips.com>
1078
1079 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
1080 width of the requested register exceeds the width of the
1081 `ptrace' data type.
1082 (mips_cannot_store_register): Likewise.
1083
1084 2018-05-21 Maciej W. Rozycki <macro@mips.com>
1085
1086 * linux-mips-low.c (mips_fetch_register): New function. Update
1087 preceding comment.
1088 (mips_store_gregset): Supply 0 rather than $restart for $zero.
1089 (the_low_target): Wire `mips_fetch_register'.
1090
1091 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1092
1093 * lynx-i386-low.c (LYNXOS_178): New macro.
1094 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
1095 the layout on LynxOS-178.
1096 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
1097 handle floating point registers that are not supported by
1098 LynxOS-178.
1099
1100 2018-05-10 Tom Tromey <tom@tromey.com>
1101
1102 * configure: Rebuild.
1103
1104 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1105
1106 PR server/23158:
1107 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
1108 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
1109 Use it to set the expedite_regs field in the given tdesc.
1110 * x86-tdesc.h: New file.
1111 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
1112 Adjust following the addition of the new expedite_regs parameter
1113 to init_target_desc.
1114 * linux-tic6x-low.c (tic6x_read_description): Likewise.
1115 * linux-x86-tdesc.c: #include "x86-tdesc.h".
1116 (i386_linux_read_description, amd64_linux_read_description):
1117 Adjust following the addition of the new expedite_regs parameter
1118 to init_target_desc.
1119 * lynx-i386-low.c: #include "x86-tdesc.h".
1120 (lynx_i386_arch_setup): Adjust following the addition of the new
1121 expedite_regs parameter to init_target_desc.
1122 * nto-x86-low.c: #include "x86-tdesc.h".
1123 (nto_x86_arch_setup): Adjust following the addition of the new
1124 expedite_regs parameter to init_target_desc.
1125 * win32-i386-low.c: #include "x86-tdesc.h".
1126 (i386_arch_setup): Adjust following the addition of the new
1127 expedite_regs parameter to init_target_desc.
1128
1129 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1130
1131 PR server/23158:
1132 * win32-low.c (win32_create_inferior): Add call to my_wait
1133 setting last_status global.
1134
1135 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1136
1137 PR server/23158:
1138 * win32-low.c (create_process): Only call gdb_tilde_expand if
1139 inferior_cwd is not NULL.
1140
1141 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
1142
1143 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
1144 registers to the cache if their values have changed.
1145 (i387_xsave_to_cache): Provide default values for x87 control
1146 registers when these features are available, but disabled.
1147 * regcache.c (supply_register_by_name_zeroed): New function.
1148 * regcache.h (supply_register_by_name_zeroed): Declare new
1149 function.
1150
1151 2018-05-07 Tom Tromey <tom@tromey.com>
1152
1153 * configure: Rebuild.
1154
1155 2018-05-04 Tom Tromey <tom@tromey.com>
1156
1157 * configure: Rebuild.
1158
1159 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
1160 Pedro Alves <palves@redhat.com>
1161
1162 * linux-aarch64-low.c (aarch64_stopped_data_address):
1163 Likewise.
1164
1165 2018-04-27 Tom Tromey <tom@tromey.com>
1166
1167 * configure: Rebuild.
1168
1169 2018-04-23 Tom Tromey <tom@tromey.com>
1170
1171 * configure: Rebuild.
1172
1173 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
1174
1175 * Makefile.in (depcomp): Add "..".
1176 (all_deps_files): New and use it.
1177
1178 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1179
1180 * configure.srv (aarch64*-*-linux*): Don't include xml.
1181 (i[34567]86-*-cygwin*): Likewise.
1182 (i[34567]86-*-linux*): Likewise.
1183 (i[34567]86-*-lynxos*): Likewise.
1184 (i[34567]86-*-mingw32ce*): Likewise.
1185 (i[34567]86-*-mingw*): Likewise.
1186 (i[34567]86-*-nto*): Likewise.
1187 (tic6x-*-uclinux): Likewise.
1188 (x86_64-*-linux*): Likewise.
1189 (x86_64-*-mingw*): Likewise.
1190 (x86_64-*-cygwin*): Likewise.
1191
1192 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1193
1194 * tdesc.c: Remove xml parameter.
1195
1196 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1197
1198 * server.c (get_features_xml): Remove cast.
1199 * tdesc.c (void target_desc::accept): Fill in function.
1200 (tdesc_get_features_xml): Remove old xml creation.
1201 (print_xml_feature::visit_pre): Add xml vistor.
1202 * tdesc.h (struct target_desc): Make xmltarget mutable.
1203 (tdesc_get_features_xml): Remove declaration.
1204
1205 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1206
1207 * tdesc.c (tdesc_architecture_name): Add new function.
1208 (tdesc_osabi_name): Likewise.
1209 (tdesc_get_features_xml): Use new functions.
1210
1211 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1212
1213 * tdesc.c (tdesc_create_flags): Remove.
1214 (tdesc_add_flag): Likewise.
1215 (tdesc_named_type): Likewise.
1216 (tdesc_create_union): Likewise.
1217 (tdesc_create_struct): Likewise.
1218 (tdesc_create_vector): Likewise.
1219 (tdesc_add_bitfield): Likewise.
1220 (tdesc_add_field): Likewise.
1221 (tdesc_set_struct_size): Likewise.
1222
1223 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1224
1225 * tdesc.c (~target_desc): Remove implictly deleted items.
1226 (init_target_desc): Iterate all features.
1227 (tdesc_get_features_xml): Use vector.
1228 (tdesc_create_feature): Create feature.
1229 * tdesc.h (tdesc_feature) Remove
1230 (target_desc): Add features.
1231
1232 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1233
1234 * Makefile.in: Add common/tdesc.c
1235 * tdesc.c (init_target_desc): init all reg_defs from register
1236 vector.
1237 (tdesc_create_reg): Create tdesc_reg.
1238 * tdesc.h (tdesc_feature): Add register vector.
1239
1240 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
1241
1242 * tdesc.h (struct target_desc) <features>: Change type to
1243 std::vector<std::string>.
1244 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
1245 changes.
1246 (tdesc_get_features_xml): Likewise.
1247 (tdesc_create_feature): Likewise.
1248
1249 2018-03-26 Alan Hayward <alan.hayward@arm.com>
1250
1251 * regcache.c (find_register_by_number): Return a ref.
1252 (find_regno): Use references.
1253 (register_size): Likewise.
1254 (register_data): Likewise.
1255 * tdesc.c (target_desc::~target_desc): Remove free calls.
1256 (target_desc::operator==): Use std::vector compare.
1257 (init_target_desc): Use reference.
1258 (tdesc_create_reg): Use reg constructors.
1259 * tdesc.h (struct target_desc): Replace pointer with object.
1260
1261 2018-03-23 Alan Hayward <alan.hayward@arm.com>
1262
1263 * regcache.c (find_register_by_number): Make static.
1264 (find_regno): Use find_register_by_number
1265 * regcache.h (struct reg): Remove declaration.
1266
1267 2018-03-23 Alan Hayward <alan.hayward@arm.com>
1268
1269 * tdesc.c (target_desc::~target_desc): Move to here.
1270 (target_desc::operator==): Likewise.
1271 * tdesc.h (target_desc::~target_desc): Move from here.
1272 (target_desc::operator==): Likewise.
1273
1274 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
1275
1276 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
1277
1278 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1279
1280 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
1281 S390_TDESC_GS.
1282 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
1283 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
1284 and init_registers_s390_gs_linux64.
1285
1286 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1287
1288 * linux-s390-low.c (s390_fill_gs): Remove function.
1289 (s390_fill_gsbc): Remove function.
1290 (s390_regsets): Set fill functions for the guarded storage regsets
1291 to NULL.
1292
1293 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1294
1295 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
1296 the word size. Add comment.
1297 (s390_get_wordsize): New function.
1298 (s390_arch_setup): No longer select a temporary tdesc to fetch the
1299 pswm with it. Instead, use s390_get_wordsize to determine the
1300 word size first and derive the correct tdesc from that directly.
1301
1302 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
1303
1304 * Makefile.in: Include silent-rules.mk.
1305 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
1306 (COMPILE): Add ECHO_CXX.
1307 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
1308 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
1309 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
1310 (version-generated.c): Add ECHO_GEN.
1311 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
1312 (IPAGENT_COMPILE): Add ECHO_CXX.
1313 (%-generated.c): Add ECHO_REGDAT.
1314
1315 2018-03-14 Tom Tromey <tom@tromey.com>
1316
1317 PR cli/14977:
1318 * ax.c (ax_printf): Special case for NULL.
1319
1320 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1321
1322 * linux-low.c (linux_qxfer_libraries_svr4): Use
1323 xml_escape_text_append.
1324
1325 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1326
1327 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
1328
1329 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1330
1331 * server.c (handle_general_set): Remove unnecessary xstrdup.
1332
1333 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1334
1335 * server.c (parse_debug_format_options): Adjust to
1336 delim_string_to_char_ptr_vec changes.
1337 * thread-db.c (thread_db_load_search): Adjust to
1338 dirnames_to_char_ptr_vec changes.
1339
1340 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
1341
1342 * target.h (target_enable_btrace, target_disable_btrace)
1343 (target_read_btrace, target_read_btrace_conf): Turn macro into
1344 inline function. Throw error if target method is not defined.
1345 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
1346 check for btrace target method. Be prepared to handle exceptions
1347 from btrace target methods.
1348
1349 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1350
1351 * server.c (captured_main): Change order of error message printed
1352 when the current working directory cannot be found.
1353
1354 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1355
1356 * server.c: Include "filenames.h" and "pathstuff.h".
1357 (program_name): Delete variable.
1358 (program_path): New anonymous class.
1359 (get_exec_wrapper): Use "program_path" instead of
1360 "program_name".
1361 (handle_v_run): Likewise.
1362 (captured_main): Likewise.
1363 (process_serial_event): Likewise.
1364
1365 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1366
1367 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
1368 (OBJS): Add "pathstuff.o".
1369 * server.c (current_directory): New global variable.
1370 (captured_main): Initialize "current_directory".
1371
1372 2018-02-26 Alan Hayward <alan.hayward@arm.com>
1373
1374 * tdesc.c: Use common/tdesc.h.
1375 * tdesc.h: Likewise.
1376
1377 2018-02-20 Alan Hayward <alan.hayward@arm.com>
1378 Simon Marchi <simon.marchi@ericsson.com>
1379
1380 * Makefile.in: Switch order of make rules.
1381
1382 2018-02-19 Alan Hayward <alan.hayward@arm.com>
1383
1384 * Makefile.in: Add common directory in build.
1385 * configure.ac: Add common reference.
1386 * configure: Regenerate.
1387
1388 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1389
1390 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
1391 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
1392 * spu-low.c (spu_target_ops): Likewise.
1393 * win32-low.c (win32_target_ops): Likewise.
1394 * server.c (supported_btrace_packets): Report packets unconditionally.
1395 * target.h (target_ops) <supports_btrace>: Remove.
1396 (target_supports_btrace): Remove.
1397
1398 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1399
1400 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
1401 (handle_btrace_disable): Change return type to void. Use exceptions
1402 to report errors.
1403 (handle_btrace_general_set): Catch exception and copy message to
1404 return message.
1405
1406 2018-02-08 Tom Tromey <tom@tromey.com>
1407
1408 * linux-low.c (install_software_single_step_breakpoints): Use
1409 make_scoped_restore.
1410 * inferiors.c (make_cleanup_restore_current_thread): Remove.
1411 (do_restore_current_thread_cleanup): Remove.
1412 * gdbthread.h (make_cleanup_restore_current_thread): Don't
1413 declare.
1414
1415 2018-02-08 Tom Tromey <tom@tromey.com>
1416
1417 * mem-break.c (set_raw_breakpoint_at): Use
1418 gdb::unique_xmalloc_ptr.
1419
1420 2018-01-30 Pedro Alves <palves@redhat.com>
1421
1422 PR gdb/13211
1423 * target.c (target_terminal::terminal_state): Rename to ...
1424 (target_terminal::m_terminal_state): ... this.
1425
1426 2018-01-19 James Clarke <jrtc27@jrtc27.com>
1427
1428 * linux-low.c (handle_extended_wait): Surround call to
1429 thread_db_notice_clone with #ifdef USE_THREAD_DB.
1430
1431 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
1432
1433 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
1434 linux_ptrace_attach_fail_reason_string now returning an
1435 std::string.
1436 (linux_attach): Likewise.
1437 * thread-db.c (attach_thread): Likewise.
1438
1439 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
1440
1441 PR gdb/21559
1442 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
1443 checking for fs_base/gs_base fields in struct user_regs_struct.
1444 * configure: Regenerate.
1445
1446 2018-01-16 Yao Qi <yao.qi@linaro.org>
1447
1448 PR gdb/18749
1449 * linux-low.c (fetch_register): Call supply_register instead of
1450 error.
1451
1452 2018-01-08 Yao Qi <yao.qi@linaro.org>
1453 Simon Marchi <simon.marchi@ericsson.com>
1454
1455 * Makefile.in (OBS): Remove selftest.o.
1456 * configure.ac: Set srv_selftest_objs if $development is true.
1457 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
1458 * configure: Re-generated.
1459 * server.c (captured_main): Wrap variable selftest_filter with
1460 GDB_SELF_TEST.
1461
1462 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
1463
1464 * server.c (parse_debug_format_options): Return std::string.
1465 (handle_monitor_command, captured_main): Adjust.
1466
1467 2018-01-05 Pedro Alves <palves@redhat.com>
1468
1469 PR gdb/18653
1470 * server.c (captured_main): Pass quiet=false to
1471 save_original_signals_state.
1472
1473 2018-01-01 Joel Brobecker <brobecker@adacore.com>
1474
1475 * gdbreplay.c (gdbreplay_version): Update copyright year in
1476 version message.
1477 * server.c (gdbserver_version): Likewise.
1478
1479 2017-12-08 Tom Tromey <tom@tromey.com>
1480
1481 * ax.c (ax_printf): Update.
1482
1483 2017-12-07 Yao Qi <yao.qi@linaro.org>
1484
1485 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
1486 aarch64_linux_read_description.
1487 * linux-amd64-ipa.c (idx2mask): New array.
1488 (get_ipa_tdesc): Move idx2mask out.
1489 (initialize_low_tracepoint): Initialize target descriptions.
1490 * linux-i386-ipa.c (idx2mask): New array.
1491 (get_ipa_tdesc): Move idx2mask out.
1492 (initialize_low_tracepoint): Initialize target descriptions.
1493
1494 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
1495
1496 * tdesc.c (struct tdesc_type): Change return type.
1497 (tdesc_add_flag): Change parameter type.
1498 (tdesc_add_bitfield): Likewise.
1499 (tdesc_add_field): Likewise.
1500 (tdesc_set_struct_size): Likewise.
1501
1502 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
1503
1504 * regcache.c (registers_to_string): Remove unused variable.
1505
1506 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1507
1508 * inferiors.c (for_each_inferior_with_data): Remove.
1509 * inferiors.h (for_each_inferior_with_data): Remove.
1510 * server.c (handle_qxfer_threads_worker): Change parameter type.
1511 (handle_qxfer_threads_proper): Use for_each_thread.
1512
1513 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1514
1515 * inferiors.c (for_each_inferior): Remove.
1516 (clear_inferiors): Use for_each_thread.
1517 * inferiors.h (for_each_inferior): Remove.
1518 * linux-low.c (linux_wait_for_event_filtered): Use
1519 for_each_thread.
1520 (linux_stabilize_threads): Likewise.
1521 * regcache.c (regcache_release): Likewise.
1522 * server.c (gdb_wants_all_threads_stopped): Likewise.
1523 (clear_pending_status_callback): Remove.
1524 (handle_status): Use for_each_thread.
1525 (captured_main): Likewise.
1526 * win32-low.c (child_init_thread_list): Likewise.
1527 (win32_clear_inferiors): Likewise.
1528 (fake_breakpoint_event): Likewise.
1529
1530 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1531
1532 * inferiors.h (find_inferior): Remove.
1533 * inferiors.c (find_inferior): Remove.
1534
1535 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1536
1537 * linux-low.c (resume_status_pending_p): Update comment.
1538 (need_step_over_p): Update comment.
1539
1540 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1541
1542 * linux-low.c (proceed_one_lwp): Return void, change parameter
1543 type.
1544 (unsuspend_and_proceed_one_lwp): Likewise.
1545 (proceed_all_lwps): Use for_each_thread.
1546 (unstop_all_lwps): Likewise.
1547
1548 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1549
1550 * linux-low.c (linux_resume_one_thread): Return void, take
1551 parameter directly.
1552 (linux_resume): Use for_each_thread.
1553
1554 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1555
1556 * linux-low.c (send_sigstop_callback): Return void, change
1557 parameter type. Rename to...
1558 (send_sigstop): ... this.
1559 (suspend_and_send_sigstop_callback): Return void, change parameter
1560 type. Rename to...
1561 (suspend_and_send_sigstop): ... this.
1562 (stop_all_lwps): Use for_each_thread.
1563
1564 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1565
1566 * linux-low.c (lwp_running): Return bool, remove unused
1567 argument.
1568 (linux_stabilize_threads): Use find_thread.
1569
1570 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1571
1572 * linux-low.c (select_singlestep_lwp_callback): Remove.
1573 (count_events_callback): Remove.
1574 (select_event_lwp_callback): Remove.
1575 (select_event_lwp): Use find_thread/for_each_thread.
1576
1577 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1578
1579 * linux-low.c (not_stopped_callback): Return bool, take filter
1580 argument directly.
1581 (linux_wait_for_event_filtered): Use find_thread.
1582 (linux_wait_1): Likewise.
1583
1584 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1585
1586 * linux-low.c (same_lwp): Remove.
1587 (find_lwp_pid): Use find_thread.
1588
1589 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1590
1591 * linux-low.c (delete_lwp_callback): Remove.
1592 (linux_mourn): Use for_each_thread.
1593
1594 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1595
1596 * linux-low.c (linux_detach_lwp_callback): Return void, remove
1597 args parameter, don't check for pid.
1598 (linux_detach): Use for_each_thread.
1599
1600 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1601
1602 * linux-low.c (struct counter): Remove.
1603 (second_thread_of_pid_p): Remove.
1604 (last_thread_of_process_p): Use find_thread.
1605
1606 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1607
1608 * inferiors.c (find_inferior_in_random): Remove.
1609 * inferiors.h (find_inferior_in_random): Remove.
1610 * linux-low.c (status_pending_p_callback): Return bool, accept
1611 parameter ptid directly.
1612 (linux_wait_for_event_filtered): Use find_thread_in_random.
1613 (linux_wait_1): Likewise.
1614
1615 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1616
1617 * inferiors.c (find_inferior_id): Remove.
1618 (find_thread_ptid): Move implemention from find_inferior_id to
1619 here.
1620 * inferiors.h (find_inferior_id): Remove.
1621 * server.c (handle_status): Use find_thread_ptid.
1622 (process_serial_event): Likewise.
1623 * thread-db.c (find_one_thread): Likewise.
1624 (thread_db_thread_handle): Likewise.
1625 * win32-low.c (thread_rec): Likewise.
1626 (child_delete_thread): Likewise.
1627 (win32_thread_alive): Likewise.
1628 (get_child_debug_event): Likewise.
1629
1630 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1631
1632 * linux-mips-low.c (update_watch_registers_callback): Return
1633 void, remove pid_p parameter, don't check for pid.
1634 (mips_insert_point, mips_remove_point): Use for_each_thread.
1635
1636 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1637
1638 * lynx.low (lynx_delete_thread_callback): Remove.
1639 (lynx_mourn): Use for_each_thread.
1640
1641 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1642
1643 * regcache.c (regcache_invalidate_one): Remove.
1644 (regcache_invalidate_pid): use for_each_thread.
1645
1646 2017-11-26 Tom Tromey <tom@tromey.com>
1647
1648 * linux-low.c (linux_create_inferior): Update.
1649
1650 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
1651
1652 * spu-low.c (spu_create_inferior): Fix typo in argument name.
1653
1654 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1655
1656 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
1657 * linux-aarch64-low.c (initialize_low_arch): Call init func.
1658 * linux-aarch64-tdesc-selftest.c: New file.
1659 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
1660
1661 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1662
1663 * configure.srv: Add new file.
1664 * linux-aarch64-low.c (initialize_low_arch): Call init func.
1665 * linux-aarch64-tdesc-selftest.c: New file.
1666 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
1667
1668 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1669
1670 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
1671 * linux-aarch64-low.c (initialize_low_arch): Remove init.
1672 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
1673
1674 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1675
1676 * configure.srv: Add new files.
1677 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
1678 aarch64_linux_read_description.
1679 * linux-aarch64-low.c (aarch64_linux_read_description):
1680 Merge with aarch64_arch_setup.
1681 (aarch64_arch_setup): Call aarch64_linux_read_description.
1682 * linux-aarch64-tdesc.c: New file.
1683 * linux-aarch64-tdesc.h: New file.
1684
1685 2017-11-24 Yao Qi <yao.qi@linaro.org>
1686
1687 * configure.srv: Set $srv_regobj for tic6x-linux.
1688 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
1689 (tic6x_read_description): Move some code to tic6x_arch_setup.
1690 (tic6x_tdesc_test): New function.
1691 (initialize_low_arch): Call selftests::register_test.
1692
1693 2017-11-22 Yao Qi <yao.qi@linaro.org>
1694
1695 * remote-utils.c (prepare_resume_reply): Use memcpy.
1696
1697 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1698
1699 * linux-low.c (kill_one_lwp_callback): Return void, take
1700 argument directly, don't filter on pid.
1701 (linux_kill): Use for_each_thread.
1702
1703 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1704
1705 * linux-low.c (need_step_over_p): Return bool, remove dummy
1706 argument.
1707 (linux_resume, proceed_all_lwps): Use find_thread.
1708
1709 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1710
1711 * linux-low.c (resume_status_pending_p): Return bool, remove
1712 flag_p argument.
1713 (linux_resume): Use find_thread.
1714
1715 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1716
1717 * linux-low.c (struct thread_resume_array): Remove.
1718 (linux_set_resume_request): Return void, take arguments
1719 directly.
1720 (linux_resume): Use for_each_thread.
1721
1722 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1723
1724 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
1725 return bool, remove data argument.
1726 (linux_stabilize_threads): Use find_thread.
1727
1728 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1729
1730 * linux-low.c (unsuspend_one_lwp): Remove.
1731 (unsuspend_all_lwps): Use for_each_thread, inline code from
1732 unsuspend_one_lwp.
1733
1734 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1735
1736 * gdbthread.h (find_thread): Add overload with ptid_t filter.
1737 * linux-low.c (struct iterate_over_lwps_args): Remove.
1738 (iterate_over_lwps_filter): Remove.
1739 (iterate_over_lwps): Use find_thread.
1740
1741 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1742
1743 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
1744 (linux_handle_new_gdb_connection): Use for_each_thread, inline
1745 code from reset_lwp_ptrace_options_callback.
1746
1747 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1748
1749 * linux-arm-low.c (struct update_registers_data): Remove.
1750 (update_registers_callback): Return void, take arguments
1751 directly, don't check thread's pid.
1752 (arm_insert_point, arm_remove_point): Use for_each_thread.
1753
1754 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1755
1756 * win32-low.c (continue_one_thread): Return void, take argument
1757 directly.
1758 (child_continue): Use for_each_thread.
1759
1760 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1761
1762 * win32-i386-low.c (update_debug_registers_callback): Rename
1763 to ...
1764 (update_debug_registers): ... this, return void, remove pid_p arg.
1765 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
1766
1767 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1768
1769 * inferiors.h (struct process_info): Add constructor, initialize
1770 fields..
1771 <syscalls_to_catch>: Change type to std::vector<int>.
1772 * inferiors.c (add_process): Allocate process_info with new.
1773 (remove_process): Free process_info with delete.
1774 * linux-low.c (handle_extended_wait): Adjust.
1775 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
1776 * server.c (handle_general_set): Adjust.
1777
1778 2017-11-16 Pedro Alves <palves@redhat.com>
1779
1780 * remote-utils.c (remote_close): Block SIGIO signals instead of
1781 uninstalling the SIGIO handler.
1782
1783 2017-11-16 Alan Hayward <alan.hayward@arm.com>
1784
1785 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
1786
1787 2017-11-16 Yao Qi <yao.qi@linaro.org>
1788
1789 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
1790 (tic6x_store_gregset): Likewise.
1791 (tic6x_usrregs_info): Move it up.
1792
1793 2017-11-15 Alan Hayward <alan.hayward@arm.com>
1794
1795 * Makefile.in: Update arch rules.
1796 * configure.srv: Explicitly mark arch/ files.
1797
1798 2017-11-13 Andreas Schwab <schwab@suse.de>
1799
1800 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
1801 function.
1802 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
1803
1804 2017-11-06 Pedro Alves <palves@redhat.com>
1805
1806 * config.in, configure: Regenerate.
1807
1808 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1809
1810 * target.c (struct thread_search): Remove.
1811 (thread_search_callback): Remove.
1812 (prepare_to_access_memory): Use for_each_thread instead of
1813 find_inferior. Inline code from thread_search_callback.
1814
1815 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1816
1817 * server.c (struct visit_actioned_threads_data): Remove.
1818 (visit_actioned_threads): Change prototype to take arguments
1819 directly.
1820 (resume): Use find_thread instead of find_inferior.
1821
1822 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1823
1824 * server.c (queue_stop_reply_callback): Change prototype, return
1825 void.
1826 (find_status_pending_thread_callback): Remove.
1827 (handle_status): Replace find_inferior with find_thread and
1828 for_each_thread.
1829
1830 2017-10-25 Alan Hayward <alan.hayward@arm.com>
1831
1832 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
1833 with REGNO.
1834 (aarch64_store_gregset): Likewise.
1835 (aarch64_fill_fpregset): Likewise.
1836 (aarch64_store_fpregset): Likewise.
1837
1838 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
1839
1840 * gdbthread.h (find_thread, for_each_thread): New functions.
1841 * inferiors.c (thread_of_pid): Remove.
1842 (find_any_thread_of_pid): Use find_thread.
1843 * linux-low.c (num_lwps): Use for_each_thread.
1844
1845 2017-10-17 Yao Qi <yao.qi@linaro.org>
1846
1847 * Makefile.in: Remove one rule.
1848 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
1849
1850 2017-10-17 Yao Qi <yao.qi@linaro.org>
1851
1852 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
1853 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
1854
1855 2017-10-17 Yao Qi <yao.qi@linaro.org>
1856
1857 * configure.srv: Rename arm.o with arch/arm.o.
1858
1859 2017-10-17 Yao Qi <yao.qi@linaro.org>
1860
1861 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
1862 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
1863 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
1864 (arch-i386.o, arch-amd64.o): Remove rules.
1865 (arch/%.o): New rule.
1866 Update POSTCOMPILE and COMPILE.pre.
1867 * configure.ac: Invoke AC_CONFIG_COMMANDS.
1868 * configure: Re-generated.
1869 * configure.srv: Replace arch-i386.o with arch/i386.o.
1870 Replace arch-amd64.o with arch/amd64.o.
1871
1872 2017-10-16 Yao Qi <yao.qi@linaro.org>
1873
1874 * configure: Regenerated.
1875
1876 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1877
1878 * inferiors.h: (struct inferior_list): Remove.
1879 (struct inferior_list_entry); Remove.
1880 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
1881 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
1882 get_first_inferior): Remove.
1883 (for_each_inferior, for_each_inferior_with_data, find_inferior,
1884 find_inferior_id, find_inferior_in_random): Change signature.
1885 * inferiors.c (all_threads): Change type to
1886 std::list<thread_info *>.
1887 (get_thread): Remove macro.
1888 (find_inferior, find_inferior_id): Change signature, implement
1889 using find_thread.
1890 (find_inferior_in_random): Change signature, implement using
1891 find_thread_in_random.
1892 (for_each_inferior, for_each_inferior_with_data): Change
1893 signature, implement using for_each_thread.
1894 (add_inferior_to_list, remove_inferior): Remove.
1895 (add_thread, get_first_thread, thread_of_pid,
1896 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
1897 (get_first_inferior, one_inferior_p, clear_inferior_list):
1898 Remove.
1899 (clear_inferiors, get_thread_process): Update.
1900 * gdbthread.h: Include <list>.
1901 (struct thread_info) <entry>: Remove field.
1902 <id>: New field.
1903 (all_threads): Change type to std::list<thread_info *>.
1904 (get_first_inferior): Add doc.
1905 (find_thread, for_each_thread, find_thread_in_random): New
1906 functions.
1907 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
1908 * linux-arm-low.c (update_registers_callback): Update.
1909 * linux-low.c (second_thread_of_pid_p): Update.
1910 (kill_one_lwp_callback, linux_detach_lwp_callback,
1911 delete_lwp_callback, status_pending_p_callback, same_lwp,
1912 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
1913 iterate_over_lwps, not_stopped_callback,
1914 resume_stopped_resumed_lwps, count_events_callback,
1915 select_singlestep_lwp_callback, select_event_lwp_callback,
1916 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
1917 suspend_and_send_sigstop_callback, wait_for_sigstop,
1918 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
1919 lwp_running, linux_set_resume_request, resume_status_pending_p,
1920 need_step_over_p, start_step_over, linux_resume_one_thread,
1921 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
1922 reset_lwp_ptrace_options_callback): Update.
1923 * linux-mips-low.c (update_watch_registers_callback): Update.
1924 * regcache.c (regcache_invalidate_one, regcache_invalidate):
1925 Update.
1926 (free_register_cache_thread_one): Remove.
1927 (regcache_release): Update.
1928 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
1929 handle_qxfer_threads_worker): Update.
1930 (handle_query): Update, use list iterator.
1931 (visit_actioned_threads, handle_pending_status,
1932 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
1933 clear_pending_status_callback, set_pending_status_callback,
1934 find_status_pending_thread_callback, handle_status,
1935 process_serial_event): Update.
1936 * target.c (thread_search_callback): Update.
1937 * thread-db.c (thread_db_get_tls_address): Update.
1938 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
1939 Update.
1940 * win32-i386-low.c (update_debug_registers_callback): Update.
1941 * win32-low.c (delete_thread_info, child_delete_thread,
1942 continue_one_thread, suspend_one_thread,
1943 get_child_debug_event): Adjust.
1944
1945 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1946
1947 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
1948 * inferiors.h: Include <list>.
1949 (struct process_info) <entry>: Remove field.
1950 <pid>: New field.
1951 (pid_of): Change macro to function.
1952 (ptid_of, lwpid_of): Remove macro.
1953 (all_processes): Change type to std::list<process_info *>.
1954 (ALL_PROCESSES): Remove macro.
1955 (for_each_process, find_process): New function.
1956 * inferiors.c (all_processes): Change type to
1957 std::list<process_info *>.
1958 (find_thread_process): Adjust.
1959 (add_process): Likewise.
1960 (remove_process): Likewise.
1961 (find_process_pid): Likewise.
1962 (get_first_process): Likewise.
1963 (started_inferior_callback): Remove.
1964 (have_started_inferiors_p): Adjust.
1965 (attached_inferior_callback): Remove.
1966 (have_attached_inferiors_p): Adjust.
1967 * linux-low.c (check_zombie_leaders): Likewise.
1968 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
1969 (x86_linux_update_xmltarget): Adjust.
1970 * server.c (handle_query): Likewise.
1971 (gdb_reattached_process): Remove.
1972 (handle_status): Adjust.
1973 (kill_inferior_callback): Likewise.
1974 (detach_or_kill_inferior): Remove.
1975 (print_started_pid): Likewise.
1976 (print_attached_pid): Likewise.
1977 (detach_or_kill_for_exit): Update.
1978 (process_serial_event): Likewise.
1979 * linux-arm-low.c (arm_new_fork): Likewise.
1980
1981 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1982
1983 * dll.h: Include <list>.
1984 (struct dll_info): Add constructor.
1985 <entry>: Remove field.
1986 (all_dlls): Change type to std::list<dll_info>.
1987 * dll.c: Include <algorithm>.
1988 (get_dll): Remove macro.
1989 (all_dlls): Change type to std::list<dll_info *>.
1990 (free_one_dll): Remove.
1991 (match_dll): Likewise.
1992 (loaded_dll): Adjust.
1993 (unloaded_dll): Adjust to all_dlls type change, use
1994 std::find_if. Inline code from match_dll.
1995 (clear_dlls): Adjust to all_dlls type change.
1996 * server.c (emit_dll_description): Remove.
1997 (handle_qxfer_libraries): Adjust to all_dlls type change,
1998 integrate emit_dll_description's functionality.
1999
2000 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2001
2002 * linux-low.h (struct linux_target_ops) <delete_process>: New
2003 field.
2004 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
2005 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
2006 (struct linux_target_ops): Add delete_process callback.
2007 * linux-arm-low.c (arm_delete_process): New.
2008 (struct linux_target_ops): Add delete_process callback.
2009 * linux-bfin-low.c (struct linux_target_ops): Likewise.
2010 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
2011 * linux-m32r-low.c (struct linux_target_ops): Likewise.
2012 * linux-mips-low.c (mips_linux_delete_process): New.
2013 (struct linux_target_ops): Add delete_process callback.
2014 * linux-ppc-low.c (struct linux_target_ops): Likewise.
2015 * linux-s390-low.c (struct linux_target_ops): Likewise.
2016 * linux-sh-low.c (struct linux_target_ops): Likewise.
2017 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
2018 * linux-tile-low.c (struct linux_target_ops): Likewise.
2019 * linux-x86-low.c (x86_linux_delete_process): New.
2020 (struct linux_target_ops): Add delete_process callback.
2021 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
2022
2023 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2024
2025 * linux-aarch64-low.c (the_low_target): Add thread delete
2026 callback.
2027 * linux-arm-low.c (arm_delete_thread): New function.
2028 (the_low_target): Add thread delete callback.
2029 * linux-bfin-low.c (the_low_target): Likewise.
2030 * linux-crisv32-low.c (the_low_target): Likewise.
2031 * linux-low.c (delete_lwp): Invoke delete_thread callback if
2032 set.
2033 * linux-low.h (struct linux_target_ops) <delete_thread>: New
2034 field.
2035 * linux-m32r-low.c (the_low_target): Add thread delete callback.
2036 * linux-mips-low.c (mips_linux_delete_thread): New function.
2037 (the_low_target): Add thread delete callback.
2038 * linux-ppc-low.c (the_low_target): Likewise.
2039 * linux-s390-low.c (the_low_target): Likewise.
2040 * linux-sh-low.c (the_low_target): Likewise.
2041 * linux-tic6x-low.c (the_low_target): Likewise.
2042 * linux-tile-low.c (the_low_target): Likewise.
2043 * linux-x86-low.c (the_low_target): Likewise.
2044 * linux-xtensa-low.c (the_low_target): Likewise.
2045
2046 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
2047
2048 * win32-low.c: Include "common-inferior.h".
2049
2050 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2051
2052 * inferiors.c (set_inferior_cwd): New function.
2053 * server.c (handle_general_set): Handle QSetWorkingDir packet.
2054 (handle_query): Inform that QSetWorkingDir is supported.
2055 * win32-low.c (create_process): Pass the inferior's cwd to
2056 CreateProcess.
2057
2058 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2059
2060 * inferiors.c (current_inferior_cwd): New global variable.
2061 (get_inferior_cwd): New function.
2062 * inferiors.h (struct process_info) <cwd>: New field.
2063
2064 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2065
2066 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
2067 (OBS): Add gdb_tilde_expand.o.
2068
2069 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
2070
2071 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
2072 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
2073
2074 2017-09-29 Pedro Alves <palves@redhat.com>
2075
2076 * ax.c (gdb_parse_agent_expr): Constify.
2077 * ax.h (gdb_parse_agent_expr): Constify.
2078 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
2079 Constify.
2080 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
2081 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
2082 * remote-utils.h (read_ptid): Constify.
2083 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
2084 (process_point_options, process_serial_event): Constify.
2085 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
2086 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
2087 (cmd_qtbuffer): Constify.
2088
2089 2017-09-29 Pedro Alves <palves@redhat.com>
2090
2091 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
2092 fails.
2093
2094 2017-09-29 Pedro Alves <palves@redhat.com>
2095
2096 * linux-low.c (handle_extended_wait): Pass parent thread instead
2097 of process to thread_db_notice_clone.
2098 * linux-low.h (thread_db_notice_clone): Replace parent process
2099 parameter with parent thread parameter.
2100 * thread-db.c (find_one_thread): Add comment.
2101 (thread_db_notice_clone): Replace parent process parameter with
2102 parent thread parameter. Temporarily switch to the parent thread.
2103
2104 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
2105
2106 * gdbthread.h: Include "common-gdbthread.h".
2107 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
2108 "if" when validating the ptid.
2109 * remote-utils.c: Include "gdbthread.h".
2110 (prepare_resume_reply): Use "switch_to_thread".
2111 * target.c (done_accessing_memory): Likewise.
2112
2113 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
2114
2115 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
2116 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
2117 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
2118 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
2119 s390x-gs-linux64-ipa.o to ipa_obj.
2120 * linux-s390-low.c (HWCAP_S390_GS): New define.
2121 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
2122 New functions.
2123 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
2124 (s390_arch_setup): Check for guarded-storage support and choose
2125 appropriate tdesc.
2126 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
2127 init_registers_s390x_gs_linux64.
2128 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
2129 enum value.
2130 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
2131 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
2132
2133 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
2134
2135 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
2136
2137 2017-09-21 Kevin Buettner <kevinb@redhat.com>
2138
2139 * linux-low.h (struct lwp_info): Add new field, thread_handle.
2140 (thread_db_thread_handle): Declare.
2141 * linux-low.c (linux_target_ops): Initialize thread_handle.
2142 * server.c (handle_qxfer_threads_worker): Add support for
2143 "handle" attribute.
2144 * target.h (struct target_ops): Add new function pointer,
2145 thread_handle.
2146 (target_thread_handle): Define.
2147 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
2148 field in lwp.
2149 (thread_db_thread_handle): New function.
2150
2151 2017-09-21 Kevin Buettner <kevinb@redhat.com>
2152
2153 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
2154 * linux-low.h (thread_db_notice_clone): Declare.
2155 * thread-db.c (thread_db_notice_clone): New function.
2156
2157 2017-09-21 Pedro Alves <palves@redhat.com>
2158
2159 * server.c (gdb_read_memory, handle_status, process_serial_event)
2160 (handle_serial_event, handle_target_event): Adjust to
2161 set_desired_thread prototype change.
2162 * target.c (set_desired_thread): Remove 'use_general' parameter
2163 and adjust.
2164 * target.h (set_desired_thread): Remove 'use_general' parameter.
2165
2166 2017-09-20 Tom Tromey <tom@tromey.com>
2167
2168 * target.c (target_terminal::terminal_state): Define.
2169 (target_terminal::init): Rename from target_terminal_init.
2170 (target_terminal::inferior): Rename from
2171 target_terminal_inferior.
2172 (target_terminal::ours): Rename from target_terminal_ours.
2173 (target_terminal::ours_for_output, target_terminal::info): New.
2174
2175 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2176
2177 * server.c (accumulate_file_name_length): Remove.
2178 (emit_dll_description): Adjust to std::string change.
2179 (handle_qxfer_libraries): Use std::string to hold document.
2180
2181 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2182
2183 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
2184 return type of xml_escape_text.
2185 * server.c (emit_dll_description): Likewise.
2186
2187 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2188
2189 * server.c (captured_main): Accept argument for --selftest.
2190 Update run_tests call.
2191 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
2192 when registering selftests.
2193
2194 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
2195
2196 * regcache.c (get_thread_regcache): Update code to use "std::vector"
2197 instead of "VEC" for "target_desc.reg_defs".
2198 (regcache_cpy): Likewise.
2199 (registers_to_string): Likewise.
2200 (registers_from_string): Likewise.
2201 (find_regno): Likewise.
2202 (supply_regblock): Likewise.
2203 (regcache_raw_read_unsigned): Likewise.
2204 * tdesc.c (init_target_desc): Likewise.
2205 (tdesc_create_reg): Likewise.
2206 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
2207 (struct target_desc) <reg_defs>: Convert to "std::vector".
2208 (target_desc): Do not initialize "reg_defs".
2209 (~target_desc): Update code to use "std::vector" instead of "VEC"
2210 for "target_desc.reg_defs".
2211 (operator==): Likewise.
2212
2213 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2214
2215 * inferiors.h (thread_to_gdb_id): Remove.
2216 * inferiors.c (thread_to_gdb_id): Remove.
2217 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
2218 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
2219 lynx_store_registers, lynx_read_memory, lynx_write_memory):
2220 Likewise.
2221 * nto-low.c (nto_fetch_registers, nto_store_registers,
2222 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
2223
2224 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2225
2226 * inferiors.h (gdb_id_to_thread_id): Remove.
2227 * inferiors.c (gdb_id_to_thread_id): Remove.
2228 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
2229 removal. Move pid declaration closer to where it's used.
2230
2231 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2232
2233 * server.c (handle_detach): New function.
2234 (process_serial_event): Move code out, call handle_detach.
2235
2236 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2237
2238 * server.c (require_running): Rename to ...
2239 (require_running_or_return): ... this ...
2240 (require_running_or_break): ... and this.
2241 (handle_query, process_serial_event): Adjust.
2242
2243 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2244
2245 * linux-low.c (linux_set_resume_request): Remove unused
2246 variables.
2247
2248 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2249
2250 * server.c (first_thread_of): Remove.
2251 (process_serial_event): Replace usage of first_thread_of with
2252 find_any_thread_of_pid.
2253 * tracepoint.c (same_process_p): Remove.
2254 (gdb_agent_about_to_close): Replace usage of same_process_p with
2255 find_any_thread_of_pid.
2256 * linux-x86-low.c (same_process_callback): Remove.
2257 (x86_arch_setup_process_callback): Replace usage of
2258 same_process_callback with find_any_thread_of_pid.
2259 * thread-db.c (any_thread_of): Remove.
2260 (switch_to_process): Replace usage of any_thread_of with
2261 find_any_thread_of_pid.
2262 * inferiors.c (thread_pid_matches_callback): Remove.
2263 (find_thread_process): Adjust to use find_any_thread_of_pid.
2264
2265 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
2266
2267 * regcache.c (get_thread_regcache): Guard calls to "memset"
2268 with "!VEC_empty".
2269
2270 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
2271
2272 * linux-low.c (handle_extended_wait): Use
2273 "allocate_target_description" instead of "XNEW".
2274 * linux-x86-low.c (initialize_low_arch): Likewise.
2275
2276 2017-09-05 Yao Qi <yao.qi@linaro.org>
2277
2278 * configure.srv (srv_i386_regobj): Remove.
2279 (srv_amd64_regobj): Remove.
2280 (srv_regobj): Set it to "" for x86 non-linux targets.
2281 * linux-x86-tdesc.c (i386_linux_read_description):
2282 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
2283 (init_registers_i386): Remove the declaration.
2284 (tdesc_i386): Remove the declaration.
2285 (lynx_i386_arch_setup): Call i386_create_target_description.
2286 * nto-x86-low.c: Likewise.
2287 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
2288 [!__x86_64__]: include arch/i386.h.
2289 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
2290
2291 2017-09-05 Yao Qi <yao.qi@linaro.org>
2292
2293 * configure.srv (srv_amd64_linux_xmlfiles): Remove
2294 i386/amd64-XXX-linux from it.
2295
2296 2017-09-05 Yao Qi <yao.qi@linaro.org>
2297
2298 * configure.srv: Empty srv_amd64_linux_regobj if $development is
2299 false.
2300 (ipa_amd64_linux_regobj): Remove.
2301 (ipa_x32_linux_regobj): Remove.
2302
2303 2017-09-05 Yao Qi <yao.qi@linaro.org>
2304
2305 * Makefile.in (arch-amd64.o): New rule.
2306 * configure.srv: Append arch-amd64.o.
2307 * linux-amd64-ipa.c: Include common/x86-xstate.h.
2308 (get_ipa_tdesc): Call amd64_linux_read_description.
2309 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
2310 and init_registers_amd64_XXX.
2311 * linux-x86-low.c (x86_linux_read_description): Call
2312 amd64_linux_read_description.
2313 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
2314 (initialize_low_arch): Don't call init_registers_x32_XXX and
2315 init_registers_amd64_XXX.
2316 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
2317 and tdesc_amd64_XXX.
2318 [__x86_64__] (amd64_tdesc_test): New function.
2319 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
2320 and init_registers_amd64_XXX.
2321 * linux-x86-tdesc.c: Include arch/amd64.h.
2322 (xcr0_to_tdesc_idx): New function.
2323 (i386_linux_read_description): New function.
2324 (amd64_get_ipa_tdesc_idx): New function.
2325 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
2326 (amd64_get_ipa_tdesc): Declare.
2327
2328 2017-09-05 Yao Qi <yao.qi@linaro.org>
2329
2330 * configure.srv (srv_i386_linux_xmlfiles): Remove
2331 i386/i386-XXX-linux.xml from it.
2332
2333 2017-09-05 Yao Qi <yao.qi@linaro.org>
2334
2335 * configure.srv: Set srv_i386_linux_regobj empty if $development
2336 is false.
2337 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
2338 initialize_low_tdesc.
2339 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
2340 with #if initialize_low_tdesc.
2341 * linux-x86-tdesc-selftest.c: New file.
2342 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
2343
2344 2017-09-05 Yao Qi <yao.qi@linaro.org>
2345
2346 * Makefile.in (arch-i386.o): New rule.
2347 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
2348 (x86_64-*-linux*): Likewise.
2349 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
2350 include arch/i386.h.
2351 (i386_linux_read_description): Remove code and call
2352 i386_create_target_description.
2353 * tdesc.c (allocate_target_description): New function.
2354 * tdesc.h (set_tdesc_architecture): Remove declaration.
2355 (set_tdesc_osabi): Likewise.
2356
2357 2017-09-05 Yao Qi <yao.qi@linaro.org>
2358
2359 * linux-x86-tdesc.c: Don't include <inttypes.h>.
2360 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
2361 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
2362 .xmltarget.
2363 * server.c (get_features_xml): Call tdesc_get_features_xml.
2364 * tdesc.c (set_tdesc_architecture): New function.
2365 (set_tdesc_osabi): New function.
2366 (tdesc_get_features_xml): New function.
2367 (tdesc_create_feature): Add an argument.
2368 * tdesc.h (struct target_desc) <features>: New field.
2369 <arch, osabi>: New field.
2370 (~target_desc): xfree features, arch, and osabi.
2371 (target_desc::oerator==): Don't compare .xmltarget.
2372 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
2373 (set_tdesc_osabi): Likewise.
2374 (tdesc_get_features_xml): Likewise.
2375
2376 2017-09-05 Yao Qi <yao.qi@linaro.org>
2377
2378 * linux-x86-tdesc.c: Include selftest.h.
2379 (i386_tdesc_test): New function.
2380 (initialize_low_tdesc): Call selftests::register_test.
2381 * tdesc.h: Include regdef.h.
2382 (target_desc): Override operator == and !=.
2383
2384 2017-09-05 Yao Qi <yao.qi@linaro.org>
2385
2386 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
2387 (ipa_obj): Likewise.
2388 * linux-i386-ipa.c: Include common/x86-xstate.h
2389 (get_ipa_tdesc): Call i386_linux_read_description.
2390 (initialize_low_tracepoint): Don't call init_registers_XXX
2391 functions, call initialize_low_tdesc instead.
2392 * linux-x86-low.c (x86_linux_read_description): Call
2393 i386_linux_read_description.
2394 (initialize_low_arch): Don't call init_registers_i386_XXX
2395 functions, call initialize_low_tdesc.
2396 * linux-x86-tdesc.c: New file.
2397 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
2398 (i386_get_ipa_tdesc_idx): Declare.
2399 (i386_get_ipa_tdesc): Declare.
2400 (initialize_low_tdesc): Declare.
2401
2402 2017-09-05 Yao Qi <yao.qi@linaro.org>
2403
2404 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
2405 instead of 0.
2406
2407 2017-09-05 Yao Qi <yao.qi@linaro.org>
2408
2409 * Makefile.in (IPA_OBJS): Add vec-ipa.o
2410 * regcache.c (get_thread_regcache): Use VEC_length.
2411 (init_register_cache): Likewise.
2412 (regcache_cpy): Likewise.
2413 (registers_to_string): Iterate reg_defs via VEC_iterate.
2414 (find_regno): Likewise.
2415 (find_register_by_number): Use VEC_index.
2416 (register_size): Call find_register_by_number.
2417 (register_data): Call find_register_by_number.
2418 (supply_regblock): Use VEC_length.
2419 (regcache_raw_read_unsigned): Likewise.
2420 * tdesc.c (init_target_desc): Iterate reg_defs via
2421 VEC_iterate.
2422 (default_description): Update initializer.
2423 (copy_target_description): Don't update field num_registers.
2424 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
2425 <num_registers>: Remove.
2426
2427 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2428
2429 * Makefile.in (.SECONDARY): Define target.
2430
2431 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
2432
2433 * linux-low.c (linux_wait_1): Adjust.
2434 * server.c (queue_stop_reply_callback): Adjust.
2435
2436 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
2437
2438 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
2439 QEnvironmentUnset and QEnvironmentReset packets.
2440 (handle_query): Inform remote that QEnvironmentHexEncoded,
2441 QEnvironmentUnset and QEnvironmentReset are supported.
2442
2443 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
2444
2445 * inferiors.h (inferior_target_data): Rename to ...
2446 (thread_target_data): ... this.
2447 (inferior_regcache_data): Rename to ...
2448 (thread_regcache_data): ... this.
2449 (set_inferior_regcache_data): Rename to ...
2450 (set_thread_regcache_data): ... this.
2451 * inferiors.c (inferior_target_data): Rename to ...
2452 (thread_target_data): ... this.
2453 (inferior_regcache_data): Rename to ...
2454 (thread_regcache_data): ... this.
2455 (set_inferior_regcache_data): Rename to ...
2456 (set_thread_regcache_data): ... this.
2457 (free_one_thread): Update.
2458 * linux-low.h (get_thread_lwp): Update.
2459 * regcache.c (get_thread_regcache): Update.
2460 (regcache_invalidate_thread): Update.
2461 (free_register_cache_thread): Update.
2462 * win32-i386-low.c (update_debug_registers_callback): Update.
2463 (win32_get_current_dr): Update.
2464 * win32-low.c (thread_rec): Update.
2465 (delete_thread_info): Update.
2466 (continue_one_thread): Update.
2467 (suspend_one_thread): Update.
2468
2469 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
2470
2471 * inferiors.c (set_inferior_target_data): Remove.
2472 * inferiors.h (set_inferior_target_data): Remove.
2473
2474 2017-08-18 Yao Qi <yao.qi@linaro.org>
2475
2476 * Makefile.in (OBS): Add selftest.o.
2477 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
2478 * configure, config.in: Re-generated.
2479 * server.c: Include common/sefltest.h.
2480 (captured_main): Handle option --selftest.
2481
2482 2017-08-09 Yao Qi <yao.qi@linaro.org>
2483
2484 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
2485 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
2486 i386-avx-mpx.o and i386-mmx.o.
2487 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
2488 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
2489 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
2490 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
2491 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
2492 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
2493 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
2494 i386/amd64-avx-mpx.xml.
2495
2496 2017-08-09 Yao Qi <yao.qi@linaro.org>
2497
2498 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
2499 and x32-avx-avx512.o.
2500 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
2501 i386/x32-avx-avx512.xml.
2502
2503 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
2504
2505 * tracepoint.h (enum class fast_tpoint_collect_result): New
2506 enumeration.
2507 (fast_tracepoint_collecting): Change return type to
2508 fast_tpoint_collect_result.
2509 * tracepoint.c (fast_tracepoint_collecting): Likewise.
2510 * linux-low.h: Include tracepoint.h.
2511 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
2512 fast_tpoint_collect_result.
2513 * linux-low.c (handle_tracepoints): Adjust.
2514 (linux_fast_tracepoint_collecting): Change return type to
2515 fast_tpoint_collect_result.
2516 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
2517 linux_wait_1, stuck_in_jump_pad_callback,
2518 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
2519 proceed_one_lwp): Adjust to type change.
2520
2521 2017-07-10 Yao Qi <yao.qi@linaro.org>
2522
2523 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
2524
2525 2017-06-29 Yao Qi <yao.qi@linaro.org>
2526
2527 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
2528 Remove.
2529 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
2530
2531 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
2532
2533 * Makefile.in (IPA_OBJS): Sort and format one item per line.
2534
2535 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
2536
2537 * linux-low.c (linux_create_inferior): Adjust code to access the
2538 environment information via 'gdb_environ' class.
2539 * lynx-low.c (lynx_create_inferior): Likewise.
2540 * server.c (our_environ): Make it an instance of 'gdb_environ'.
2541 (get_environ): Return a pointer to 'our_environ'.
2542 (captured_main): Initialize 'our_environ'.
2543 * server.h (get_environ): Adjust prototype.
2544 * spu-low.c (spu_create_inferior): Adjust code to access the
2545 environment information via 'gdb_environ' class.
2546
2547 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2548
2549 * linux-low.c (linux_read_memory, linux_write_memory): Remove
2550 usage of "register" keyword.
2551
2552 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2553
2554 * configure: Re-generate.
2555
2556 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2557
2558 * configure: Re-generate.
2559
2560 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2561
2562 * Makefile.in (COMPILE.pre): Add "-x c++".
2563
2564 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
2565
2566 * fork-child.c: Conditionally include <signal.h>.
2567
2568 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2569
2570 * server.c (handle_general_set): Handle new packet
2571 "QStartupWithShell".
2572 (handle_query): Add "QStartupWithShell" to the list of supported
2573 packets.
2574 (gdbserver_usage): Add help text explaining the
2575 new "--startup-with-shell" and "--no-startup-with-shell" CLI
2576 options.
2577 (captured_main): Recognize and act upon the presence of the new
2578 CLI options.
2579
2580 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2581 Pedro Alves <palves@redhat.com>
2582
2583 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
2584 * configure: Regenerate.
2585 * configure.srv (srv_linux_obj): Add "fork-child.o" and
2586 "fork-inferior.o".
2587 (i[34567]86-*-lynxos*): Likewise.
2588 (spu*-*-*): Likewise.
2589 * fork-child.c: New file.
2590 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
2591 and "environ.h".
2592 (linux_ptrace_fun): New function.
2593 (linux_create_inferior): Adjust function prototype to reflect
2594 change on "target.h". Adjust function code to use
2595 "fork_inferior".
2596 (linux_request_interrupt): Delete "signal_pid".
2597 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
2598 (lynx_ptrace_fun): New function.
2599 (lynx_create_inferior): Adjust function prototype to reflect
2600 change on "target.h". Adjust function code to use
2601 "fork_inferior".
2602 * nto-low.c (nto_create_inferior): Adjust function prototype and
2603 code to reflect change on "target.h". Update comments.
2604 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
2605 "common-terminal.h" and "environ.h".
2606 (terminal_fd): Moved to fork-child.c.
2607 (old_foreground_pgrp): Likewise.
2608 (restore_old_foreground_pgrp): Likewise.
2609 (last_status): Make it global.
2610 (last_ptid): Likewise.
2611 (our_environ): New variable.
2612 (startup_with_shell): Likewise.
2613 (program_name): Likewise.
2614 (program_argv): Rename to...
2615 (program_args): ...this.
2616 (wrapper_argv): New variable.
2617 (start_inferior): Delete function.
2618 (get_exec_wrapper): New function.
2619 (get_exec_file): Likewise.
2620 (get_environ): Likewise.
2621 (prefork_hook): Likewise.
2622 (post_fork_inferior): Likewise.
2623 (postfork_hook): Likewise.
2624 (postfork_child_hook): Likewise.
2625 (handle_v_run): Update code to deal with arguments coming from the
2626 remote host. Update calls from "start_inferior" to
2627 "create_inferior".
2628 (captured_main): Likewise. Initialize environment variable. Call
2629 "have_job_control".
2630 * server.h (post_fork_inferior): New prototype.
2631 (get_environ): Likewise.
2632 (last_status): Declare.
2633 (last_ptid): Likewise.
2634 (signal_pid): Likewise.
2635 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
2636 (spu_ptrace_fun): New function.
2637 (spu_create_inferior): Adjust function prototype to reflect change
2638 on "target.h". Adjust function code to use "fork_inferior".
2639 * target.c (target_terminal_init): New function.
2640 (target_terminal_inferior): Likewise.
2641 (target_terminal_ours): Likewise.
2642 * target.h: Include <vector>.
2643 (struct target_ops) <create_inferior>: Update prototype.
2644 (create_inferior): Update macro.
2645 * utils.c (gdb_flush_out_err): New function.
2646 * win32-low.c (win32_create_inferior): Adjust function prototype
2647 and code to reflect change on "target.h".
2648
2649 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2650
2651 * inferiors.c (switch_to_thread): New function.
2652
2653 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2654
2655 * Makefile.in (SFILE): Add "common/job-control.c".
2656 (OBS): Add "job-control.o".
2657
2658 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
2659
2660 * Makefile: Remove "@host_makefile_frag@".
2661
2662 2017-05-05 Pedro Alves <palves@redhat.com>
2663
2664 * configure: Regenerate.
2665
2666 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
2667
2668 * configure: Regenerate.
2669
2670 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
2671
2672 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
2673 software_single_step change of return type to
2674 std::vector<CORE_ADDR>.
2675 * linux-low.c (install_software_single_step_breakpoints):
2676 Likewise.
2677 * linux-low.h (install_software_single_step_breakpoints):
2678 Likewise.
2679
2680 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
2681
2682 * remote-utils.c: Include "gdb_termios.h" instead of
2683 "terminal.h".
2684 * terminal.h: Delete file.
2685
2686 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
2687
2688 * server.c: Include <vector>.
2689 <program_argv, wrapper_argv>: Convert to std::vector.
2690 (start_inferior): Rewrite function to use C++.
2691 (handle_v_run): Likewise. Update code that calculates the argv
2692 based on the vRun packet; use C++.
2693 (captured_main): Likewise.
2694
2695 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
2696
2697 * server.c (handle_v_cont): Initialize thread_resume::thread
2698 with null_ptid.
2699
2700 2017-04-05 Pedro Alves <palves@redhat.com>
2701
2702 * configure: Regenerate.
2703
2704 2017-04-05 Pedro Alves <palves@redhat.com>
2705
2706 * gdbreplay.c (sync_error): Constify.
2707 * linux-x86-low.c (push_opcode): Constify.
2708
2709 2017-04-05 Pedro Alves <palves@redhat.com>
2710
2711 * win32-low.c (get_child_debug_event)
2712 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
2713 Report TARGET_WAITKIND_SPURIOUS instead.
2714
2715 2017-04-05 Pedro Alves <palves@redhat.com>
2716
2717 * remote-utils.c (remote_prepare, remote_open): Constify.
2718 * remote-utils.h (remote_prepare, remote_open): Constify.
2719 * server.c (captured_main): Constify 'port' handling.
2720
2721 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
2722
2723 * Makefile.in (clean): Clear .deps.
2724
2725 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
2726
2727 * .gitignore: Remove generated files, replace with wildcard.
2728 * (clean): Replace removal of generated files with wildcard.
2729 (version.c): Replace with...
2730 (version-generated.c): ...this.
2731 (xml-builtin.c): Replace with...
2732 (xml-builtin-generated.c): ...this.
2733 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
2734 (%.c: *regformats*): Replace with...
2735 (%-generated.c: *regformats*): ...this.
2736
2737 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
2738
2739 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
2740 (xtensa_fill_gregset): Call collect_register_by_name for
2741 threadptr register.
2742 (xtensa_store_gregset): Call supply_register_by_name for
2743 threadptr register.
2744
2745 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
2746
2747 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
2748 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
2749 (xtensa_store_gregset): Call supply_register for all registers in
2750 a0_regnum..a0_regnum + C0_NREGS range.
2751
2752 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2753
2754 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
2755 (ax-ipa.o: ax.c): Remove.
2756 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
2757 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
2758 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
2759 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
2760 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
2761
2762 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2763
2764 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
2765 (print-utils-ipa.o: ../common/print-utils.c): Remove.
2766 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
2767 (errors-ipa.o: ../common/errors.c): Remove.
2768 (format-ipa.o: ../common/format.c): Remove.
2769 (common-utils-ipa.o: ../common/common-utils.c): Remove.
2770
2771 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2772
2773 * Makefile.in (%-ipa.o: %.c): New rule.
2774 (tracepoint-ipa.o: tracepoint.c): Remove.
2775 (utils-ipa.o: utils.c): Remove.
2776 (remote-utils-ipa.o: remote-utils.c): Remove.
2777 (regcache-ipa.o: regcache.c): Remove.
2778 (i386-linux-ipa.o: i386-linux.c): Remove.
2779 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
2780 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
2781 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
2782 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
2783 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
2784 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
2785 (amd64-linux-ipa.o: amd64-linux.c): Remove.
2786 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
2787 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
2788 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
2789 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
2790 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
2791 (aarch64-ipa.o: aarch64.c): Remove.
2792 (s390-linux32-ipa.o: s390-linux32.c): Remove.
2793 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
2794 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
2795 (s390-linux64-ipa.o: s390-linux64.c): Remove.
2796 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
2797 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
2798 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
2799 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
2800 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
2801 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
2802 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
2803 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
2804 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
2805 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
2806 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
2807 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
2808 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
2809 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
2810 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
2811 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
2812 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
2813 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
2814 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
2815 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
2816 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
2817 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
2818 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
2819 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
2820 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
2821 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
2822 (tdesc-ipa.o: tdesc.c): Remove.
2823 (x32-linux-ipa.o: x32-linux.c): Remove.
2824 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
2825 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
2826
2827 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2828
2829 * Makefile.in (%.o: ../arch/%.c): New rule.
2830 (arm.o: ../arch/arm.c): Remove.
2831 (arm-linux.o: ../arch/arm-linux.c): Remove.
2832 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
2833 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
2834
2835 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2836
2837 * Makefile.in (%.o: ../nat/%.c): New rule.
2838 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
2839 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
2840 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
2841 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
2842 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
2843 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
2844 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
2845 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
2846 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
2847 (linux-personality.o: ../nat/linux-personality.c): Remove.
2848 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
2849 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
2850 (x86-linux.o: ../nat/x86-linux.c): Remove.
2851 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
2852 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
2853
2854 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2855
2856 * Makefile.in (%.o: ../common/%.c): New rule.
2857 (signals.o: ../common/signals.c): Remove.
2858 (print-utils.o: ../common/print-utils.c): Remove.
2859 (rsp-low.o: ../common/rsp-low.c): Remove.
2860 (common-utils.o: ../common/common-utils.c): Remove.
2861 (posix-strerror.o: ../common/posix-strerror.c): Remove.
2862 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
2863 (vec.o: ../common/vec.c): Remove.
2864 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
2865 (xml-utils.o: ../common/xml-utils.c): Remove.
2866 (ptid.o: ../common/ptid.c): Remove.
2867 (buffer.o: ../common/buffer.c): Remove.
2868 (format.o: ../common/format.c): Remove.
2869 (filestuff.o: ../common/filestuff.c): Remove.
2870 (agent.o: ../common/agent.c): Remove.
2871 (errors.o: ../common/errors.c): Remove.
2872 (environ.o: ../common/environ.c): Remove.
2873 (common-debug.o: ../common/common-debug.c): Remove.
2874 (cleanups.o: ../common/cleanups.c): Remove.
2875 (common-exceptions.o: ../common/common-exceptions.c): Remove.
2876 (fileio.o: ../common/fileio.c): Remove.
2877 (common-regcache.o: ../common/common-regcache.c): Remove.
2878 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
2879 (new-op.o: ../common/new-op.c): Remove.
2880 (btrace-common.o: ../common/btrace-common.c): Remove.
2881
2882 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2883
2884 * Makefile.in (%.o: ../target/%.c): New rule.
2885 (waitstatus.o: ../target/waitstatus.c): Remove.
2886
2887 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2888
2889 * Makefile.in
2890 (%.c: ../regformats/%.dat,
2891 (%.c: ../regformats/arm/%.dat,
2892 (%.c: ../regformats/i386/%.dat,
2893 (%.c: ../regformats/rs6000/%.dat): New rules.
2894 (aarch64.c): Remove.
2895 (reg-arm.c): Remove.
2896 (arm-with-iwmmxt.c): Remove.
2897 (arm-with-vfpv2.c): Remove.
2898 (arm-with-vfpv3.c): Remove.
2899 (arm-with-neon.c): Remove.
2900 (reg-bfin.c): Remove.
2901 (reg-cris.c): Remove.
2902 (reg-crisv32.c): Remove.
2903 (i386.c): Remove.
2904 (i386-linux.c): Remove.
2905 (i386-avx.c): Remove.
2906 (i386-avx-linux.c): Remove.
2907 (i386-avx-avx512.c): Remove.
2908 (i386-avx-avx512-linux.c): Remove.
2909 (i386-mpx.c): Remove.
2910 (i386-mpx-linux.c): Remove.
2911 (i386-avx-mpx-avx512-pku.c): Remove.
2912 (i386-avx-mpx-avx512-pku-linux.c): Remove.
2913 (i386-avx-mpx.c): Remove.
2914 (i386-avx-mpx-linux.c): Remove.
2915 (i386-mmx.c): Remove.
2916 (i386-mmx-linux.c): Remove.
2917 (reg-ia64.c): Remove.
2918 (reg-m32r.c): Remove.
2919 (reg-m68k.c): Remove.
2920 (reg-cf.c): Remove.
2921 (mips-linux.c): Remove.
2922 (mips-dsp-linux.c): Remove.
2923 (mips64-linux.c): Remove.
2924 (mips64-dsp-linux.c): Remove.
2925 (nios2-linux.c): Remove.
2926 (powerpc-32.c): Remove.
2927 (powerpc-32l.c): Remove.
2928 (powerpc-altivec32l.c): Remove.
2929 (powerpc-cell32l.c): Remove.
2930 (powerpc-vsx32l.c): Remove.
2931 (powerpc-isa205-32l.c): Remove.
2932 (powerpc-isa205-altivec32l.c): Remove.
2933 (powerpc-isa205-vsx32l.c): Remove.
2934 (powerpc-e500l.c): Remove.
2935 (powerpc-64l.c): Remove.
2936 (powerpc-altivec64l.c): Remove.
2937 (powerpc-cell64l.c): Remove.
2938 (powerpc-vsx64l.c): Remove.
2939 (powerpc-isa205-64l.c): Remove.
2940 (powerpc-isa205-altivec64l.c): Remove.
2941 (powerpc-isa205-vsx64l.c): Remove.
2942 (s390-linux32.c): Remove.
2943 (s390-linux32v1.c): Remove.
2944 (s390-linux32v2.c): Remove.
2945 (s390-linux64.c): Remove.
2946 (s390-linux64v1.c): Remove.
2947 (s390-linux64v2.c): Remove.
2948 (s390-te-linux64.c): Remove.
2949 (s390-vx-linux64.c): Remove.
2950 (s390-tevx-linux64.c): Remove.
2951 (s390x-linux64.c): Remove.
2952 (s390x-linux64v1.c): Remove.
2953 (s390x-linux64v2.c): Remove.
2954 (s390x-te-linux64.c): Remove.
2955 (s390x-vx-linux64.c): Remove.
2956 (s390x-tevx-linux64.c): Remove.
2957 (tic6x-c64xp-linux.c): Remove.
2958 (tic6x-c64x-linux.c): Remove.
2959 (tic6x-c62x-linux.c): Remove.
2960 (reg-sh.c): Remove.
2961 (reg-sparc64.c): Remove.
2962 (reg-spu.c): Remove.
2963 (amd64.c): Remove.
2964 (amd64-linux.c): Remove.
2965 (amd64-avx.c): Remove.
2966 (amd64-avx-linux.c): Remove.
2967 (amd64-avx-avx512.c): Remove.
2968 (amd64-avx-avx512-linux.c): Remove.
2969 (amd64-mpx.c): Remove.
2970 (amd64-mpx-linux.c): Remove.
2971 (amd64-avx-mpx-avx512-pku.c): Remove.
2972 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
2973 (amd64-avx-mpx.c): Remove.
2974 (amd64-avx-mpx-linux.c): Remove.
2975 (x32.c): Remove.
2976 (x32-linux.c): Remove.
2977 (x32-avx.c): Remove.
2978 (x32-avx-linux.c): Remove.
2979 (x32-avx-avx512.c): Remove.
2980 (x32-avx-avx512-linux.c): Remove.
2981 (reg-xtensa.c): Remove.
2982 (reg-tilegx.c): Remove.
2983 (reg-tilegx32.c): Remove.
2984
2985 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
2986
2987 * Makefile.in (SFILES): Add "common/environ.c".
2988 (OBJS): Add "common/environ.h".
2989
2990 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
2991
2992 * configure.ac: Check if the fs_base and gs_base members of
2993 `struct user_regs_struct' exist.
2994 * config.in: Regenerated.
2995 * configure: Likewise.
2996
2997 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
2998
2999 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
3000 target_read_memory.
3001 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
3002 (get_next_pcs_syscall_next_pc): Likewise.
3003
3004 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
3005
3006 * win32-i386-low.c: Fix incorrect reference to a couple source files.
3007 * nto-x86-low.c: Likewise.
3008
3009 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
3010
3011 * Makefile.in: Include disable-implicit-rules.mk.
3012
3013 2016-11-23 Pedro Alves <palves@redhat.com>
3014
3015 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
3016 (debug_vprintf): Use std::chrono::steady_clock instead of
3017 gettimeofday. Use '.' instead of ':'.
3018 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
3019 (get_timestamp): Use std::chrono::steady_clock instead of
3020 gettimeofday.
3021
3022 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
3023
3024 * Makefile.in: Fix whitespace formatting.
3025
3026 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
3027
3028 * Makefile.in (SFILES, OBS): Flatten list and order
3029 alphabetically.
3030
3031 2016-11-23 Pedro Alves <palves@redhat.com>
3032
3033 * event-loop.c (handle_file_event): Use warning.
3034 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
3035 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
3036 Use warning.
3037
3038 2016-11-23 Pedro Alves <palves@redhat.com>
3039
3040 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
3041 output.
3042 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
3043 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
3044 debug_printf and debug_flush for debug output.
3045 * server.c (handle_general_set): Likewise.
3046 * thread-db.c (try_thread_db_load): Use debug_printf for debug
3047 output.
3048
3049 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
3050
3051 * Makefile.in (.c.o): Replace rule with ...
3052 (%.o: %.c): ... this one.
3053
3054 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
3055
3056 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
3057 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
3058 make.
3059 * configure.ac: Remove checks for the make program.
3060 * configure: Re-generate.
3061
3062 2016-10-28 Pedro Alves <palves@redhat.com>
3063
3064 * Makefile.in (CXX_DIALECT): Get from configure.
3065 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
3066 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
3067 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
3068 * config.in: Regenerate.
3069 * configure: Regenerate.
3070
3071 2016-10-27 Yao Qi <yao.qi@linaro.org>
3072
3073 * linux-low.c (linux_supports_range_stepping): Return true if
3074 can_software_single_step return true.
3075
3076 2016-10-27 Yao Qi <yao.qi@linaro.org>
3077
3078 * inferiors.c (find_inferior_in_random): New function.
3079 * inferiors.h (find_inferior_in_random): Declare.
3080 * linux-low.c (linux_wait_for_event_filtered): Call
3081 find_inferior_in_random instead of find_inferior.
3082
3083 2016-10-27 Yao Qi <yao.qi@linaro.org>
3084
3085 * linux-low.c (linux_wait_1): If single-step breakpoints are
3086 inserted, remove them.
3087
3088 2016-10-26 Pedro Alves <palves@redhat.com>
3089
3090 * linux-low.c (handle_extended_wait): Link parent/child fork
3091 threads.
3092 (linux_wait_1): Unlink them.
3093 (linux_set_resume_request): Ignore resume requests for
3094 already-resumed and unhandled fork child threads.
3095 * linux-low.h (struct lwp_info) <fork_relative>: New field.
3096 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
3097 New functions.
3098 (handle_v_requests) <vCont>: Don't call require_running.
3099 * server.h (in_queued_stop_replies): New declaration.
3100
3101 2016-10-24 Yao Qi <yao.qi@linaro.org>
3102
3103 PR server/20733
3104 * linux-aarch64-low.c (append_insns): Cast the return value to
3105 'uint32_t *'.
3106
3107 2016-10-10 Yao Qi <yao.qi@linaro.org>
3108
3109 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
3110
3111 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
3112
3113 * target.c (target_supports_multi_process): New function, moved
3114 from...
3115 * target.h (target_supports_multi_process): ... here. Remove
3116 macro.
3117
3118 2016-10-05 Tom Tromey <tom@tromey.com>
3119
3120 PR remote/20655:
3121 * tracepoint.c (handle_tracepoint_bkpts): Check
3122 ipa_error_tracepoint, not ipa_stopping_tracepoint.
3123
3124 2016-10-05 Yao Qi <yao.qi@linaro.org>
3125
3126 * configure.srv: Update the path of arm-*.xml files.
3127
3128 2016-10-05 Terry Guo <terry.guo@arm.com>
3129 Yao Qi <yao.qi@linaro.org>
3130
3131 * Makefile.in: Adjust the path of rules.
3132 * configure.srv: Update the path of xml files.
3133 * regformats/arm-with-iwmmxt.dat: Regenerated.
3134 * regformats/arm-with-neon.dat: Likewise.
3135 * regformats/arm-with-vfpv2.dat: Likewise.
3136 * regformats/arm-with-vfpv3.dat Likewise.
3137
3138 2016-09-30 Yao Qi <yao.qi@linaro.org>
3139
3140 PR gdbserver/20627
3141 * target.c (target_stop_and_wait): Don't call
3142 target_continue_no_signal, use resume_stop instead.
3143
3144 2016-09-26 Yao Qi <yao.qi@linaro.org>
3145
3146 * linux-low.c (linux_wait_1): Call debug_exit.
3147
3148 2016-09-23 Pedro Alves <palves@redhat.com>
3149
3150 * Makefile.in (SFILES): Add common/new-op.c.
3151 (OBS): Add common/new-op.o.
3152 (new-op.o): New rule.
3153
3154 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
3155
3156 * .gitinore: Ignore more files.
3157
3158 2016-09-21 Yao Qi <yao.qi@linaro.org>
3159
3160 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
3161 23.
3162
3163 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
3164
3165 * server.c (start_inferior): Call target_mourn_inferior instead of
3166 mourn_inferior; pass ptid_t argument to it.
3167 (resume): Likewise.
3168 (handle_target_event): Likewise.
3169 * target.c (target_mourn_inferior): New function.
3170 * target.h (mourn_inferior): Delete macro.
3171
3172 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
3173
3174 * linux-low.c (lwp_is_stepping): New function.
3175
3176 2016-09-06 Carl Love <cel@us.ibm.com>
3177
3178 * server.c (start_inferior): Fixed comment, requested comment change
3179 didn't get updated correctly. Removed reference to ptrace () call as
3180 it is only true on Linux systems.
3181
3182 2016-09-06 Carl Love <cel@us.ibm.com>
3183
3184 * server.c (start_inferior): Do not call
3185 function target_post_create_inferior () if the
3186 inferior process has already exited.
3187
3188 2016-09-05 Pedro Alves <palves@redhat.com>
3189
3190 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
3191 (COMPILE.pre, CC_LD): Use CXX directly.
3192 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
3193 * acinclude.m4: Don't include build-with-cxx.m4.
3194 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
3195 * configure: Regenerate.
3196
3197 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
3198
3199 PR gdb/19495
3200 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
3201 call writing data to own_buf.
3202
3203 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
3204
3205 * target.c (mywait): Call target_wait instead of
3206 the_target->wait.
3207 (target_wait): New function.
3208
3209 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
3210
3211 * server.c (start_inferior): New variable 'ptid'. Replace calls
3212 to the_target->resume by target_continue{,_no_signal}, depending
3213 on the case.
3214 * target.c (target_stop_and_wait): Call target_continue_no_signal
3215 instead of the_target->resume.
3216 (target_continue): New function.
3217
3218 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
3219
3220 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
3221
3222 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
3223
3224 PR server/20491
3225 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
3226 ps_prochandle.
3227 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
3228 * linux-arm-low.c (ps_get_thread_area): Likewise.
3229 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
3230 * linux-m68k-low.c (ps_get_thread_area): Likewise.
3231 * linux-mips-low.c (ps_get_thread_area): Likewise.
3232 * linux-nios2-low.c (ps_get_thread_area): Likewise.
3233 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
3234 * linux-x86-low.c (ps_get_thread_area): Likewise.
3235 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
3236
3237 2016-08-19 Pedro Alves <palves@redhat.com>
3238
3239 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
3240
3241 2016-08-19 Pedro Alves <palves@redhat.com>
3242
3243 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
3244 comment. Use memcpy instead of casting through unsigned long.
3245
3246 2016-08-19 Pedro Alves <palves@redhat.com>
3247
3248 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
3249 allocating around 0x80000000.
3250
3251 2016-08-19 Pedro Alves <palves@redhat.com>
3252
3253 PR gdb/20415
3254 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
3255 (x32-avx512-linux-ipa.o): New rules.
3256 * configure.ac (x86_64-*-linux*): New x32 check.
3257 * configure.srv (ipa_x32_linux_regobj): New.
3258 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
3259 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
3260 descriptions.
3261 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
3262 descriptions.
3263 * configure: Regenerate.
3264
3265 2016-08-09 Pedro Alves <palves@redhat.com>
3266
3267 PR gdb/18653
3268 * Makefile.in (OBS): Add signals-state-save-restore.o.
3269 (signals-state-save-restore.o): New rule.
3270 * config.in: Regenerate.
3271 * configure: Regenerate.
3272 * linux-low.c: Include "signals-state-save-restore.h".
3273 (linux_create_inferior): Call
3274 restore_original_signals_state.
3275 * server.c: Include "dispositions-save-restore.h".
3276 (captured_main): Call save_original_signals_state.
3277
3278 2016-08-05 Pedro Alves <palves@redhat.com>
3279
3280 * configure: Regenerate.
3281
3282 2016-08-04 Yao Qi <yao.qi@linaro.org>
3283
3284 * linux-low.c (regsets_fetch_inferior_registers): Check
3285 errno is ESRCH or not.
3286
3287 2016-08-02 Yao Qi <yao.qi@linaro.org>
3288
3289 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
3290 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
3291 (thread_db_load_search): Update.
3292 (try_thread_db_load_1): Don't look for td_ta_event_addr,
3293 td_ta_set_event and td_ta_event_getmsg.
3294
3295 2016-07-26 Pedro Alves <palves@redhat.com>
3296
3297 PR server/20414
3298 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
3299 of unsigned long for 64-bit registers and use uint32_t instead of
3300 unsigned int for 32-bit registers.
3301
3302 2016-07-26 Pedro Alves <palves@redhat.com>
3303
3304 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
3305 to 'ptrace'.
3306
3307 2016-07-21 Tom Tromey <tom@tromey.com>
3308
3309 * configure: Rebuild.
3310
3311 2016-07-21 Yao Qi <yao.qi@linaro.org>
3312
3313 * mem-break.c (find_gdb_breakpoint): Cast bp to
3314 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
3315
3316 2016-07-21 Yao Qi <yao.qi@linaro.org>
3317
3318 * server.c (handle_v_requests): Support s and S actions
3319 if target_supports_software_single_step return true.
3320
3321 2016-07-21 Yao Qi <yao.qi@linaro.org>
3322
3323 * linux-low.c (resume_stopped_resumed_lwps): If resume request
3324 is resume_step, call maybe_hw_step.
3325 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
3326 and unstop them.
3327 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
3328 breakpoints or not.
3329 (proceed_one_lwp): If resume request is resume_step, install
3330 reinsert breakpoints and call maybe_hw_step.
3331
3332 2016-07-21 Yao Qi <yao.qi@linaro.org>
3333
3334 * linux-low.c (proceed_one_lwp): Declare.
3335 (linux_resume_one_thread): Remove local variable 'step'.
3336 Lift code enqueue signal. Call proceed_one_lwp instead of
3337 linux_resume_one_lwp.
3338
3339 2016-07-21 Yao Qi <yao.qi@linaro.org>
3340
3341 * linux-low.c (linux_resume_one_thread): Call
3342 enqueue_pending_signal.
3343
3344 2016-07-21 Yao Qi <yao.qi@linaro.org>
3345
3346 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
3347 * inferiors.c (do_restore_current_thread_cleanup): New function.
3348 (make_cleanup_restore_current_thread): Likewise.
3349 * linux-low.c (install_software_single_step_breakpoints): Call
3350 make_cleanup_restore_current_thread. Switch current_thread to
3351 thread.
3352
3353 2016-07-21 Yao Qi <yao.qi@linaro.org>
3354
3355 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
3356 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
3357 (clone_one_breakpoint): Likewise.
3358 (delete_reinsert_breakpoints): Change parameter to thread.
3359 Callers updated.
3360 (has_reinsert_breakpoints): Likewise.
3361 (uninsert_reinsert_breakpoints): Likewise.
3362 (reinsert_reinsert_breakpoints): Likewise.
3363 * mem-break.h (set_reinsert_breakpoint): Update declaration.
3364 (delete_reinsert_breakpoints): Likewise.
3365 (reinsert_reinsert_breakpoints): Likewise.
3366 (uninsert_reinsert_breakpoints): Likewise.
3367 (has_reinsert_breakpoints): Likewise.
3368
3369 2016-07-21 Yao Qi <yao.qi@linaro.org>
3370
3371 * inferiors.c (get_thread_process): Make parameter const.
3372 * inferiors.h (get_thread_process): Update declaration.
3373 * mem-break.c (clone_all_breakpoints): Remove all parameters.
3374 Add new parameters child_thread and parent_thread. Callers
3375 updated.
3376 * mem-break.h (clone_all_breakpoints): Update declaration.
3377
3378 2016-07-21 Yao Qi <yao.qi@linaro.org>
3379
3380 * mem-break.c (struct breakpoint) <cond_list>: Remove.
3381 <command_list, handler>: Remove.
3382 (struct gdb_breakpoint): New.
3383 (struct other_breakpoint): New.
3384 (struct reinsert_breakpoint): New.
3385 (is_gdb_breakpoint): New function.
3386 (any_persistent_commands): Update command_list if
3387 is_gdb_breakpoint returns true.
3388 (set_breakpoint): Create breakpoints according to their types.
3389 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
3390 (set_gdb_breakpoint_1): Likewise.
3391 (set_gdb_breakpoint): Likewise.
3392 (clear_breakpoint_conditions): Change parameter type to
3393 'struct gdb_breakpoint *'.
3394 (clear_breakpoint_commands): Likewise.
3395 (clear_breakpoint_conditions_and_commands): Likewise.
3396 (add_condition_to_breakpoint): Likewise.
3397 (add_breakpoint_condition): Likewise.
3398 (add_commands_to_breakpoint): Likewise.
3399 (check_breakpoints): Check other_breakpoint.
3400 (clone_one_breakpoint): Clone breakpopint according to its type.
3401 * mem-break.h (struct gdb_breakpoint): Declare.
3402 (set_gdb_breakpoint): Update declaration.
3403 (clear_breakpoint_conditions_and_commands): Likewise.
3404 (add_breakpoint_condition): Likewise.
3405 (add_breakpoint_commands): Likewise.
3406 * server.c (process_point_options): Change parameter type to
3407 'struct gdb_breakpoint *'.
3408
3409 2016-07-21 Yao Qi <yao.qi@linaro.org>
3410
3411 * mem-break.c (set_breakpoint_at): Rename it to ...
3412 (set_breakpoint_type_at): ... it.
3413 (set_breakpoint_at): Call set_breakpoint_type_at.
3414 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
3415 * mem-break.h (set_breakpoint_at): Update comments.
3416
3417 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
3418
3419 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
3420 to buf parameter.
3421 (nios2_store_gregset): Likewise.
3422
3423 2016-07-01 Pedro Alves <palves@redhat.com>
3424 Antoine Tremblay <antoine.tremblay@ericsson.com>
3425
3426 * linux-low.c: Change interface to take the target lwp_info
3427 pointer directly and return void. Handle detaching from a zombie
3428 thread.
3429 (linux_detach_lwp_callback): New function.
3430 (linux_detach): Detach from the leader thread after detaching from
3431 the clone threads.
3432
3433 2016-06-28 Yao Qi <yao.qi@linaro.org>
3434
3435 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
3436 for variable new_offset.
3437 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
3438 (aarch64_ftrace_insn_reloc_cb): Likewise.
3439 (aarch64_ftrace_insn_reloc_tb): Likewise.
3440 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
3441 PRIx64 instead of PRIx32.
3442
3443 2016-06-28 Yao Qi <yao.qi@linaro.org>
3444
3445 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
3446 (the_low_target): Install arm_get_syscall_trapinfo.
3447
3448 2016-06-28 Yao Qi <yao.qi@linaro.org>
3449
3450 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
3451 function.
3452 (the_low_target): Install aarch64_get_syscall_trapinfo.
3453
3454 2016-06-28 Yao Qi <yao.qi@linaro.org>
3455
3456 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
3457 Callers updated.
3458 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
3459 Remove parameter sysno.
3460 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
3461 sysret.
3462
3463 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
3464
3465 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
3466 (s390_emit_ne_goto): Likewise.
3467 (s390_emit_lt_goto): Likewise.
3468 (s390_emit_le_goto): Likewise.
3469 (s390_emit_gt_goto): Likewise.
3470 (s390_emit_ge_goto): Likewise.
3471 (s390x_emit_eq_goto): Likewise.
3472 (s390x_emit_ne_goto): Likewise.
3473 (s390x_emit_lt_goto): Likewise.
3474 (s390x_emit_le_goto): Likewise.
3475 (s390x_emit_gt_goto): Likewise.
3476 (s390x_emit_ge_goto): Likewise.
3477 (s390_emit_ops_impl): Mark variable static.
3478 (s390x_emit_ops): Likewise.
3479
3480 2016-06-17 Yao Qi <yao.qi@linaro.org>
3481
3482 * linux-low.c (handle_extended_wait): Call
3483 uninsert_reinsert_breakpoints for the parent process. Remove
3484 reinsert breakpoints from the child process. Reinsert them to
3485 the parent process when vfork is done.
3486 * mem-break.c (uninsert_reinsert_breakpoints): New function.
3487 (reinsert_reinsert_breakpoints): New function.
3488 * mem-break.h (uninsert_reinsert_breakpoints): Declare
3489 (reinsert_reinsert_breakpoints): Declare.
3490
3491 2016-06-17 Yao Qi <yao.qi@linaro.org>
3492
3493 * linux-low.c (handle_extended_wait): If the parent is doing
3494 step-over, remove the reinsert breakpoints from the forked child.
3495
3496 2016-06-17 Yao Qi <yao.qi@linaro.org>
3497
3498 * linux-low.c (unsuspend_all_lwps): Declare.
3499 (linux_low_filter_event): If thread exited, call finish_step_over.
3500 If step-over is finished, unsuspend other threads.
3501
3502 2016-06-17 Yao Qi <yao.qi@linaro.org>
3503
3504 * linux-low.c (linux_resume_one_lwp_throw): Assert
3505 has_reinsert_breakpoints returns false.
3506 * mem-break.c (delete_disabled_breakpoints): Assert
3507 bp type isn't reinsert_breakpoint.
3508
3509 2016-06-17 Yao Qi <yao.qi@linaro.org>
3510
3511 * linux-low.c (maybe_hw_step): New function.
3512 (linux_resume_one_lwp_throw): Call maybe_hw_step.
3513 (finish_step_over): Switch current_thread to lwp temporarily,
3514 and assert has_reinsert_breakpoints returns true.
3515 (proceed_one_lwp): Call maybe_hw_step.
3516 * mem-break.c (has_reinsert_breakpoints): New function.
3517 * mem-break.h (has_reinsert_breakpoints): Declare.
3518
3519 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
3520
3521 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
3522
3523 2016-05-17 Yao Qi <yao.qi@linaro.org>
3524
3525 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
3526 instead of find_inferior.
3527
3528 2016-05-05 Yao Qi <yao.qi@linaro.org>
3529
3530 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
3531 Initialize res to zero.
3532
3533 2016-05-05 Yao Qi <yao.qi@linaro.org>
3534
3535 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
3536 to uint32_t.
3537
3538 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
3539
3540 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
3541 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
3542 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
3543
3544 2016-04-28 Par Olsson <par.olsson@windriver.com>
3545 Simon Marchi <simon.marchi@ericsson.com>
3546
3547 * tracepoint.c (write_inferior_int8): New function.
3548 (cmd_qtenable_disable): Write enable flag using
3549 write_inferior_int8.
3550
3551 2016-04-25 Yao Qi <yao.qi@linaro.org>
3552
3553 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
3554 (need_step_over_p): Return zero if the LWP has pending signals
3555 can be delivered on software single step target.
3556
3557 2016-04-25 Yao Qi <yao.qi@linaro.org>
3558
3559 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
3560 return instead of error.
3561
3562 2016-04-22 Yao Qi <yao.qi@linaro.org>
3563
3564 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
3565 to 23.
3566
3567 2016-04-22 Yao Qi <yao.qi@linaro.org>
3568
3569 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
3570 signal when stepping over breakpoint with software single
3571 step.
3572
3573 2016-04-21 Pedro Alves <palves@redhat.com>
3574
3575 * linux-s390-low.c (s390_collect_ptrace_register)
3576 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
3577 add casts.
3578 (s390_check_regset): Use void * instead of gdb_byte *.
3579
3580 2016-04-20 Pedro Alves <palves@redhat.com>
3581
3582 * configure: Renegerate.
3583
3584 2016-04-20 Yao Qi <yao.qi@linaro.org>
3585
3586 * linux-aarch32-low.c: Include "arch/arm-linux.h".
3587 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
3588 number 16.
3589 (arm_store_gregset): Likewise.
3590
3591 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
3592
3593 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
3594 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
3595 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
3596 (amd64-avx-mpx-linux.c): New rules.
3597 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
3598 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
3599 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
3600 (srv_amd64_regobj): Add amd64-avx-mpx.o.
3601 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
3602 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
3603 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
3604 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
3605 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
3606 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
3607 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
3608 * linux-x86-low.c (x86_linux_read_description): Add case for
3609 X86_XSTATE_AVX_MPX_MASK.
3610 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
3611 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
3612 init_registers_i386_avx_mpx_linux.
3613 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
3614 (initialize_low_tracepoint): Call
3615 init_registers_i386_avx_mpx_linux.
3616 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
3617 (initialize_low_tracepoint): Call
3618 init_registers_amd64_avx_mpx_linux.
3619 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
3620 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
3621 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
3622 declarations.
3623
3624 2016-04-18 Pedro Alves <palves@redhat.com>
3625
3626 * configure: Regenerate.
3627
3628 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
3629
3630 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
3631 (aarch64_emit_sub): Likewise.
3632
3633 2016-04-12 Pedro Alves <palves@redhat.com>
3634
3635 * utils.c (prepare_to_throw_exception): Delete.
3636
3637 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
3638
3639 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
3640
3641 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
3642
3643 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
3644
3645 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
3646
3647 * linux-aarch64-ipa.c: Add <elf.h> include.
3648 * linux-ppc-ipa.c: Add <elf.h> include.
3649 * linux-s390-ipa.c: Add <elf.h> include.
3650
3651 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
3652
3653 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
3654 (get_raw_reg_ptr): Likewise.
3655 (get_trace_state_variable_value_ptr): Likewise.
3656 (set_trace_state_variable_value_ptr): Likewise.
3657 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
3658 char *.
3659
3660 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
3661 Marcin Kościelnicki <koriakin@0x04.net>
3662
3663 PR/17221
3664 * linux-ppc-low.c (emit_insns): New function.
3665 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
3666 (ppc_emit_prologue): New function.
3667 (ppc_emit_epilogue): New function.
3668 (ppc_emit_add): New function.
3669 (ppc_emit_sub): New function.
3670 (ppc_emit_mul): New function.
3671 (ppc_emit_lsh): New function.
3672 (ppc_emit_rsh_signed): New function.
3673 (ppc_emit_rsh_unsigned): New function.
3674 (ppc_emit_ext): New function.
3675 (ppc_emit_zero_ext): New function.
3676 (ppc_emit_log_not): New function.
3677 (ppc_emit_bit_and): New function.
3678 (ppc_emit_bit_or): New function.
3679 (ppc_emit_bit_xor): New function.
3680 (ppc_emit_bit_not): New function.
3681 (ppc_emit_equal): New function.
3682 (ppc_emit_less_signed): New function.
3683 (ppc_emit_less_unsigned): New function.
3684 (ppc_emit_ref): New function.
3685 (ppc_emit_const): New function.
3686 (ppc_emit_reg): New function.
3687 (ppc_emit_pop): New function.
3688 (ppc_emit_stack_flush): New function.
3689 (ppc_emit_swap): New function.
3690 (ppc_emit_stack_adjust): New function.
3691 (ppc_emit_call): New function.
3692 (ppc_emit_int_call_1): New function.
3693 (ppc_emit_void_call_2): New function.
3694 (ppc_emit_if_goto): New function.
3695 (ppc_emit_goto): New function.
3696 (ppc_emit_eq_goto): New function.
3697 (ppc_emit_ne_goto): New function.
3698 (ppc_emit_lt_goto): New function.
3699 (ppc_emit_le_goto): New function.
3700 (ppc_emit_gt_goto): New function.
3701 (ppc_emit_ge_goto): New function.
3702 (ppc_write_goto_address): New function.
3703 (ppc_emit_ops_impl): New static variable.
3704 (ppc64v1_emit_prologue): New function.
3705 (ppc64v2_emit_prologue): New function.
3706 (ppc64_emit_epilogue): New function.
3707 (ppc64_emit_add): New function.
3708 (ppc64_emit_sub): New function.
3709 (ppc64_emit_mul): New function.
3710 (ppc64_emit_lsh): New function.
3711 (ppc64_emit_rsh_signed): New function.
3712 (ppc64_emit_rsh_unsigned): New function.
3713 (ppc64_emit_ext): New function.
3714 (ppc64_emit_zero_ext): New function.
3715 (ppc64_emit_log_not): New function.
3716 (ppc64_emit_bit_and): New function.
3717 (ppc64_emit_bit_or): New function.
3718 (ppc64_emit_bit_xor): New function.
3719 (ppc64_emit_bit_not): New function.
3720 (ppc64_emit_equal): New function.
3721 (ppc64_emit_less_signed): New function.
3722 (ppc64_emit_less_unsigned): New function.
3723 (ppc64_emit_ref): New function.
3724 (ppc64_emit_const): New function.
3725 (ppc64v1_emit_reg): New function.
3726 (ppc64v2_emit_reg): New function.
3727 (ppc64_emit_pop): New function.
3728 (ppc64_emit_stack_flush): New function.
3729 (ppc64_emit_swap): New function.
3730 (ppc64v1_emit_call): New function.
3731 (ppc64v2_emit_call): New function.
3732 (ppc64v1_emit_int_call_1): New function.
3733 (ppc64v2_emit_int_call_1): New function.
3734 (ppc64v1_emit_void_call_2): New function.
3735 (ppc64v2_emit_void_call_2): New function.
3736 (ppc64_emit_if_goto): New function.
3737 (ppc64_emit_eq_goto): New function.
3738 (ppc64_emit_ne_goto): New function.
3739 (ppc64_emit_lt_goto): New function.
3740 (ppc64_emit_le_goto): New function.
3741 (ppc64_emit_gt_goto): New function.
3742 (ppc64_emit_ge_goto): New function.
3743 (ppc64v1_emit_ops_impl): New static variable.
3744 (ppc64v2_emit_ops_impl): New static variable.
3745 (ppc_emit_ops): New function.
3746 (linux_low_target): Wire in ppc_emit_ops.
3747
3748 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
3749 Marcin Kościelnicki <koriakin@0x04.net>
3750
3751 PR/17221
3752 * Makefile.in: Add powerpc-*-ipa.o
3753 * configure.srv: Add ipa_obj for powerpc*-linux.
3754 * linux-ppc-ipa.c: New file.
3755 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
3756 includes.
3757 (PPC_FIELD): New macro.
3758 (PPC_SEXT): New macro.
3759 (PPC_OP6): New macro.
3760 (PPC_BO): New macro.
3761 (PPC_LI): New macro.
3762 (PPC_BD): New macro.
3763 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
3764 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
3765 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
3766 (ppc_get_thread_area): New function.
3767 (is_elfv2_inferior): New function.
3768 (gen_ds_form): New function.
3769 (GEN_STD): New macro.
3770 (GEN_STDU): New macro.
3771 (GEN_LD): New macro.
3772 (GEN_LDU): New macro.
3773 (gen_d_form): New function.
3774 (GEN_ADDI): New macro.
3775 (GEN_ADDIS): New macro.
3776 (GEN_LI): New macro.
3777 (GEN_LIS): New macro.
3778 (GEN_ORI): New macro.
3779 (GEN_ORIS): New macro.
3780 (GEN_LWZ): New macro.
3781 (GEN_STW): New macro.
3782 (GEN_STWU): New macro.
3783 (gen_xfx_form): New function.
3784 (GEN_MFSPR): New macro.
3785 (GEN_MTSPR): New macro.
3786 (GEN_MFCR): New macro.
3787 (GEN_MTCR): New macro.
3788 (GEN_SYNC): New macro.
3789 (GEN_LWSYNC): New macro.
3790 (gen_x_form): New function.
3791 (GEN_OR): New macro.
3792 (GEN_MR): New macro.
3793 (GEN_LWARX): New macro.
3794 (GEN_STWCX): New macro.
3795 (GEN_CMPW): New macro.
3796 (gen_md_form): New function.
3797 (GEN_RLDICL): New macro.
3798 (GEN_RLDICR): New macro.
3799 (gen_i_form): New function.
3800 (GEN_B): New macro.
3801 (GEN_BL): New macro.
3802 (gen_b_form): New function.
3803 (GEN_BNE): New macro.
3804 (GEN_LOAD): New macro.
3805 (GEN_STORE): New macro.
3806 (gen_limm): New function.
3807 (gen_atomic_xchg): New function.
3808 (gen_call): New function.
3809 (ppc_relocate_instruction): New function.
3810 (ppc_install_fast_tracepoint_jump_pad): New function.
3811 (ppc_get_min_fast_tracepoint_insn_len): New function.
3812 (ppc_get_ipa_tdesc_idx): New function.
3813 (the_low_target): Wire in the new functions.
3814 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
3815 tdescs.
3816 * linux-ppc-tdesc.h: New file.
3817
3818 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
3819
3820 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
3821 (alloc_jump_pad_buffer): New function.
3822 * linux-amd64-ipa.c: Add <sys/mman.h> include.
3823 (alloc_jump_pad_buffer): New function.
3824 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
3825 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
3826 (alloc_jump_pad_buffer): New function.
3827 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
3828 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
3829 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
3830 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
3831
3832 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
3833
3834 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
3835 * linux-amd64-ipa.c: Likewise.
3836 * linux-i386-ipa.c: Likewise.
3837 * linux-s390-ipa.c: Likewise.
3838 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
3839 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
3840 set_trace_state_variable_value_ptr.
3841 (struct ipa_sym_addresses): Likewise.
3842 (symbol_list): Likewise.
3843 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
3844 accessing gdb_collect directly.
3845 (gdb_collect_ptr_type): New typedef.
3846 (get_raw_reg_ptr_type): New typedef.
3847 (get_trace_state_variable_value_ptr_type): New typedef.
3848 (set_trace_state_variable_value_ptr_type): New typedef.
3849 (gdb_collect_ptr): New global.
3850 (get_raw_reg_ptr): New global.
3851 (get_trace_state_variable_value_ptr): New global.
3852 (set_trace_state_variable_value_ptr): New global.
3853 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
3854 accessing get_raw_reg directly.
3855 (get_get_tsv_func_addr): Likewise for
3856 get_trace_state_variable_value_ptr.
3857 (get_set_tsv_func_addr): Likewise for
3858 set_trace_state_variable_value_ptr.
3859 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
3860
3861 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
3862
3863 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
3864
3865 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
3866
3867 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
3868 packets.
3869 (relocate_instruction): Remove own_buf.
3870 * server.c (own_buf): Make global.
3871 (handle_v_requests): Make global.
3872 * server.h (own_buf): New declaration.
3873 (handle_v_requests): New prototype.
3874
3875 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
3876
3877 PR 18377
3878 * linux-s390-low.c (add_insns): New function.
3879 (s390_emit_prologue): New function.
3880 (s390_emit_epilogue): New function.
3881 (s390_emit_add): New function.
3882 (s390_emit_sub): New function.
3883 (s390_emit_mul): New function.
3884 (s390_emit_lsh): New function.
3885 (s390_emit_rsh_signed): New function.
3886 (s390_emit_rsh_unsigned): New function.
3887 (s390_emit_ext): New function.
3888 (s390_emit_log_not): New function.
3889 (s390_emit_bit_and): New function.
3890 (s390_emit_bit_or): New function.
3891 (s390_emit_bit_xor): New function.
3892 (s390_emit_bit_not): New function.
3893 (s390_emit_equal): New function.
3894 (s390_emit_less_signed): New function.
3895 (s390_emit_less_unsigned): New function.
3896 (s390_emit_ref): New function.
3897 (s390_emit_if_goto): New function.
3898 (s390_emit_goto): New function.
3899 (s390_write_goto_address): New function.
3900 (s390_emit_litpool): New function.
3901 (s390_emit_const): New function.
3902 (s390_emit_call): New function.
3903 (s390_emit_reg): New function.
3904 (s390_emit_pop): New function.
3905 (s390_emit_stack_flush): New function.
3906 (s390_emit_zero_ext): New function.
3907 (s390_emit_swap): New function.
3908 (s390_emit_stack_adjust): New function.
3909 (s390_emit_set_r2): New function.
3910 (s390_emit_int_call_1): New function.
3911 (s390_emit_void_call_2): New function.
3912 (s390_emit_eq_goto): New function.
3913 (s390_emit_ne_goto): New function.
3914 (s390_emit_lt_goto): New function.
3915 (s390_emit_le_goto): New function.
3916 (s390_emit_gt_goto): New function.
3917 (s390_emit_ge_goto): New function.
3918 (s390x_emit_prologue): New function.
3919 (s390x_emit_epilogue): New function.
3920 (s390x_emit_add): New function.
3921 (s390x_emit_sub): New function.
3922 (s390x_emit_mul): New function.
3923 (s390x_emit_lsh): New function.
3924 (s390x_emit_rsh_signed): New function.
3925 (s390x_emit_rsh_unsigned): New function.
3926 (s390x_emit_ext): New function.
3927 (s390x_emit_log_not): New function.
3928 (s390x_emit_bit_and): New function.
3929 (s390x_emit_bit_or): New function.
3930 (s390x_emit_bit_xor): New function.
3931 (s390x_emit_bit_not): New function.
3932 (s390x_emit_equal): New function.
3933 (s390x_emit_less_signed): New function.
3934 (s390x_emit_less_unsigned): New function.
3935 (s390x_emit_ref): New function.
3936 (s390x_emit_if_goto): New function.
3937 (s390x_emit_const): New function.
3938 (s390x_emit_call): New function.
3939 (s390x_emit_reg): New function.
3940 (s390x_emit_pop): New function.
3941 (s390x_emit_stack_flush): New function.
3942 (s390x_emit_zero_ext): New function.
3943 (s390x_emit_swap): New function.
3944 (s390x_emit_stack_adjust): New function.
3945 (s390x_emit_int_call_1): New function.
3946 (s390x_emit_void_call_2): New function.
3947 (s390x_emit_eq_goto): New function.
3948 (s390x_emit_ne_goto): New function.
3949 (s390x_emit_lt_goto): New function.
3950 (s390x_emit_le_goto): New function.
3951 (s390x_emit_gt_goto): New function.
3952 (s390x_emit_ge_goto): New function.
3953 (s390_emit_ops): New function.
3954 (struct linux_target_ops): Fill in emit_ops hook.
3955
3956 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
3957
3958 PR 18377
3959 * Makefile.in: Add s390 IPA files.
3960 * configure.srv: Build IPA for s390.
3961 * linux-s390-ipa.c: New file.
3962 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
3963 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
3964 (tdesc_s390_linux32): Likewise.
3965 (init_registers_s390_linux32v1): Likewise.
3966 (tdesc_s390_linux32v1): Likewise.
3967 (init_registers_s390_linux32v2): Likewise.
3968 (tdesc_s390_linux32v2): Likewise.
3969 (init_registers_s390_linux64): Likewise.
3970 (tdesc_s390_linux64): Likewise.
3971 (init_registers_s390_linux64v1): Likewise.
3972 (tdesc_s390_linux64v1): Likewise.
3973 (init_registers_s390_linux64v2): Likewise.
3974 (tdesc_s390_linux64v2): Likewise.
3975 (init_registers_s390_te_linux64): Likewise.
3976 (tdesc_s390_te_linux64): Likewise.
3977 (init_registers_s390_vx_linux64): Likewise.
3978 (tdesc_s390_vx_linux64): Likewise.
3979 (init_registers_s390_tevx_linux64): Likewise.
3980 (tdesc_s390_tevx_linux64): Likewise.
3981 (init_registers_s390x_linux64): Likewise.
3982 (tdesc_s390x_linux64): Likewise.
3983 (init_registers_s390x_linux64v1): Likewise.
3984 (tdesc_s390x_linux64v1): Likewise.
3985 (init_registers_s390x_linux64v2): Likewise.
3986 (tdesc_s390x_linux64v2): Likewise.
3987 (init_registers_s390x_te_linux64): Likewise.
3988 (tdesc_s390x_te_linux64): Likewise.
3989 (init_registers_s390x_vx_linux64): Likewise.
3990 (tdesc_s390x_vx_linux64): Likewise.
3991 (init_registers_s390x_tevx_linux64): Likewise.
3992 (tdesc_s390x_tevx_linux64): Likewise.
3993 (have_hwcap_s390_vx): New static variable.
3994 (s390_arch_setup): Fill have_hwcap_s390_vx.
3995 (s390_get_thread_area): New function.
3996 (s390_ft_entry_gpr_esa): New const.
3997 (s390_ft_entry_gpr_zarch): New const.
3998 (s390_ft_entry_misc): New const.
3999 (s390_ft_entry_fr): New const.
4000 (s390_ft_entry_vr): New const.
4001 (s390_ft_main_31): New const.
4002 (s390_ft_main_64): New const.
4003 (s390_ft_exit_fr): New const.
4004 (s390_ft_exit_vr): New const.
4005 (s390_ft_exit_misc): New const.
4006 (s390_ft_exit_gpr_esa): New const.
4007 (s390_ft_exit_gpr_zarch): New const.
4008 (append_insns): New function.
4009 (s390_relocate_instruction): New function.
4010 (s390_install_fast_tracepoint_jump_pad): New function.
4011 (s390_get_min_fast_tracepoint_insn_len): New function.
4012 (s390_get_ipa_tdesc_idx): New function.
4013 (struct linux_target_ops): Wire in the above functions.
4014 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
4015 * linux-s390-tdesc.h: New file.
4016
4017 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
4018
4019 * linux-s390-low.c (s390_supports_tracepoints): New function.
4020 (struct linux_target_ops): Fill supports_tracepoints hook.
4021
4022 2016-03-18 Yao Qi <yao.qi@linaro.org>
4023
4024 * linux-low.c (lwp_signal_can_be_delivered): New function.
4025 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
4026
4027 2016-03-18 Yao Qi <yao.qi@linaro.org>
4028
4029 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
4030 0 if signal is enqueued. Remove 'signal' from one debugging
4031 message. Move one debugging message to some lines below.
4032 Remove code setting 'signal' to 0.
4033
4034 2016-03-18 Yao Qi <yao.qi@linaro.org>
4035
4036 * linux-low.c (linux_low_filter_event): Remove redundant
4037 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
4038
4039 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
4040
4041 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
4042 (struct linux_target_ops): Wire in the above.
4043
4044 2016-03-03 Yao Qi <yao.qi@linaro.org>
4045
4046 * linux-low.c: Update comments to start_step_over.
4047
4048 2016-03-03 Yao Qi <yao.qi@linaro.org>
4049
4050 PR server/19736
4051 * linux-low.c (handle_extended_wait): Set child suspended
4052 if event_lwp->bp_reinsert isn't zero.
4053
4054 2016-03-02 Yao Qi <yao.qi@linaro.org>
4055
4056 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
4057 enqueue_pending_signal.
4058
4059 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
4060
4061 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
4062 is actually loaded.
4063
4064 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
4065
4066 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
4067 (s390_regmap_3264) [!__s390x__]: New global.
4068 (s390_collect_ptrace_register): Skip map entries containing -1.
4069 (s390_supply_ptrace_register): Ditto.
4070 (s390_fill_gprs_high): New function.
4071 (s390_store_gprs_high): New function.
4072 (s390_regsets): Add NT_S390_HIGH_GPRS.
4073 (s390_get_hwcap): Enable on 31-bit.
4074 (have_hwcap_s390_high_gprs): Enable on 31-bit.
4075 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
4076 Detect NT_S390_HIGH_GPRS.
4077 (s390_usrregs_info_3264): Enable on 31-bit.
4078 (s390_regs_info): Enable regs_info_3264 on 31-bit.
4079 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
4080
4081 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
4082
4083 PR gdb/13808
4084 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
4085 * configure.srv: Ditto.
4086 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
4087 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
4088 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
4089 (init_registers_amd64_linux): Remove prototype.
4090 (tdesc_amd64_linux): Remove declaration.
4091 (get_ipa_tdesc): New function.
4092 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
4093 initialize remaining tdescs.
4094 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
4095 (init_registers_i386_linux): Remove prototype.
4096 (tdesc_i386_linux): Remove declaration.
4097 (get_ipa_tdesc): New function.
4098 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
4099 initialize remaining tdescs.
4100 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
4101 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
4102 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
4103 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
4104 (x86_get_ipa_tdesc_idx): New function.
4105 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
4106 * linux-x86-tdesc.h: New file.
4107 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
4108 (target_get_ipa_tdesc_idx): New macro.
4109 * tracepoint.c (ipa_tdesc_idx): New macro.
4110 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
4111 (symbol_list): Add ipa_tdesc_idx.
4112 (cmd_qtstart): Write ipa_tdesc_idx in the target.
4113 (ipa_tdesc): Remove.
4114 (ipa_tdesc_idx): New variable.
4115 (get_context_regcache): Use get_ipa_tdesc.
4116 (gdb_collect): Ditto.
4117 (gdb_probe): Ditto.
4118 * tracepoint.h (get_ipa_tdesc): New prototype.
4119 (ipa_tdesc): Remove.
4120
4121 2016-02-24 Pedro Alves <palves@redhat.com>
4122
4123 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
4124 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
4125 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
4126 Factor out common code between the USE_SIGTRAP_SIGINFO and
4127 !USE_SIGTRAP_SIGINFO blocks.
4128 (linux_low_filter_event): Call save_stop_reason instead of
4129 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
4130 Update comments.
4131 (linux_wait_1): Update comments.
4132
4133 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
4134
4135 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
4136 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
4137 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
4138 ppc_insert_point, ppc_remove_point.
4139
4140 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
4141
4142 * linux-s390-low.c (s390_supports_z_point_type): New function.
4143 (struct linux_target_ops): Wire s390_supports_z_point_type in.
4144
4145 2016-02-16 Yao Qi <yao.qi@linaro.org>
4146
4147 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
4148 PC. Get pc from regcache_read_pc.
4149
4150 2016-02-12 Yao Qi <yao.qi@linaro.org>
4151
4152 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
4153 or linux_get_pc_32bit.
4154 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
4155
4156 2016-02-12 Yao Qi <yao.qi@linaro.org>
4157
4158 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
4159 arm_linux_get_next_pcs_fixup.
4160
4161 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
4162
4163 * tracepoint.c (x_tracepoint_action_download): Change
4164 write_inferior_data_ptr to write_inferior_data_pointer.
4165 (cmd_qtstart): Likewise.
4166 (write_inferior_data_ptr): Remove.
4167 (download_agent_expr): Change write_inferior_data_ptr to
4168 write_inferior_data_pointer.
4169 (download_tracepoint_1): Likewise.
4170 (download_tracepoint): Likewise.
4171 (download_trace_state_variables): Likewise.
4172
4173 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
4174 Marcin Kościelnicki <koriakin@0x04.net>
4175
4176 * tracepoint.c (struct tracepoint_action_ops): Remove.
4177 (struct tracepoint_action): Remove ops.
4178 (m_tracepoint_action_download, r_tracepoint_action_download)
4179 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
4180 size and offset accordingly.
4181 (m_tracepoint_action_ops, r_tracepoint_action_ops)
4182 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
4183 (tracepoint_action_send, tracepoint_action_download): New functions.
4184 Helpers for trace action handlers.
4185 (add_tracepoint_action): Remove setup actions ops.
4186 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
4187
4188 2016-02-10 Yao Qi <yao.qi@linaro.org>
4189
4190 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
4191
4192 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
4193
4194 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
4195 to AC_OUTPUT.
4196 * configure: Regenerate.
4197
4198 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
4199
4200 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
4201 void * to gdb_byte *.
4202 * linux-low.c (siginfo_fixup): Likewise.
4203 (linux_xfer_siginfo): Likewise.
4204 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
4205 Likewise.
4206 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
4207
4208 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
4209
4210 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
4211 to srv_tgtobj.
4212 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
4213 to srv_tgtobj.
4214 * linux-x86-low.c [__x86_64__]: Include
4215 "nat/amd64-linux-siginfo.h".
4216 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
4217 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
4218 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
4219 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
4220 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
4221 (cpt_si_fd, si_timerid, si_overrun): Move from
4222 nat/amd64-linux-siginfo.c.
4223 * Makefile.in (amd64-linux-siginfo.o:): New rule.
4224
4225 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
4226
4227 * server.c (skip_to_semicolon): Remove.
4228 (process_point_options): Use strchrnul instead of
4229 skip_to_semicolon.
4230
4231 2016-01-26 Yao Qi <yao.qi@linaro.org>
4232
4233 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
4234 * linux-low.c (install_software_single_step_breakpoints): Don't
4235 call regcache_read_pc.
4236 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
4237 argument pc.
4238
4239 2016-01-26 Yao Qi <yao.qi@linaro.org>
4240
4241 * linux-low.c (install_software_single_step_breakpoints): Call
4242 regcache_read_pc instead of get_pc.
4243
4244 2016-01-26 Yao Qi <yao.qi@linaro.org>
4245
4246 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
4247 (unblock_async_io): Rename to ...
4248 (block_unblock_async_io): ... it. New function.
4249 (enable_async_io): Don't install SIGIO handler. Unblock it
4250 instead.
4251 (disable_async_io): Don't ignore SIGIO. Block it instead.
4252 (initialize_async_io): Install SIGIO handler. Don't call
4253 unblock_async_io.
4254
4255 2016-01-26 Yao Qi <yao.qi@linaro.org>
4256
4257 * remote-utils.c (getpkt): If the buffer isn't empty, and the
4258 first character is '\003', call *the_target->request_interrupt.
4259
4260 2016-01-25 Yao Qi <yao.qi@linaro.org>
4261
4262 * remote-utils.c (new_thread_notify): Remove.
4263 (dead_thread_notify): Likewise.
4264 * remote-utils.h (new_thread_notify): Remove declaration.
4265 (dead_thread_notify): Likewise.
4266
4267 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
4268
4269 * gdb.trace/pending.exp: Fix expected message on continue.
4270
4271 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
4272
4273 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
4274 it works properly on big-endian machines where sizeof (CORE_ADDR)
4275 != sizeof (void *).
4276
4277 2016-01-21 Pedro Alves <palves@redhat.com>
4278
4279 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
4280 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
4281 * configure: Regenerate.
4282
4283 2016-01-21 Yao Qi <yao.qi@linaro.org>
4284
4285 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
4286 is_thumb and set it according to CPSR saved on the stack.
4287 (get_next_pcs_syscall_next_pc): Pass is_thumb to
4288 arm_sigreturn_next_pc.
4289
4290 2016-01-18 Yao Qi <yao.qi@linaro.org>
4291
4292 * linux-low.c (linux_set_pc_64bit): New function.
4293 (linux_get_pc_64bit): New function.
4294 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
4295 Declare.
4296 * linux-sparc-low.c (debug_threads): Remove declaration.
4297 (sparc_get_pc): Remove.
4298 (the_low_target): Use linux_get_pc_64bit instead of
4299 sparc_get_pc.
4300 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
4301 (the_low_target): Use linux_get_pc_64bit and
4302 linux_set_pc_64bit.
4303
4304 2016-01-18 Yao Qi <yao.qi@linaro.org>
4305
4306 * linux-arm-low.c (debug_threads): Remove declaration.
4307 (arm_get_pc, arm_set_pc): Remove.
4308 (the_low_target): Use linux_get_pc_32bit and
4309 linux_set_pc_32bit.
4310 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
4311 (the_low_target): Use linux_get_pc_32bit and
4312 linux_set_pc_32bit.
4313 * linux-cris-low.c (debug_threads): Remove declaration.
4314 (cris_get_pc, cris_set_pc,): Remove.
4315 (the_low_target): Use linux_get_pc_32bit and
4316 linux_set_pc_32bit.
4317 * linux-crisv32-low.c (debug_threads): Remove declaration.
4318 (cris_get_pc, cris_set_pc): Remove.
4319 (the_low_target): Use linux_get_pc_32bit and
4320 linux_set_pc_32bit.
4321 * linux-low.c: Include inttypes.h.
4322 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
4323 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
4324 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
4325 (the_low_target): Use linux_get_pc_32bit and
4326 linux_set_pc_32bit.
4327 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
4328 (the_low_target): Use linux_get_pc_32bit and
4329 linux_set_pc_32bit.
4330 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
4331 (the_low_target): Use linux_get_pc_32bit and
4332 linux_set_pc_32bit.
4333 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
4334 (the_low_target): Use linux_get_pc_32bit and
4335 linux_set_pc_32bit.
4336 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
4337 (the_low_target): Use linux_get_pc_32bit and
4338 linux_set_pc_32bit.
4339
4340 2016-01-18 Gary Benson <gbenson@redhat.com>
4341
4342 * configure.ac (AC_FUNC_FORK): New check.
4343 * config.in: Regenerate.
4344 * configure: Likewise.
4345
4346 2016-01-14 Yao Qi <yao.qi@linaro.org>
4347
4348 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
4349 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
4350 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
4351 arm_get_next_pcs_ctor.
4352
4353 2016-01-12 Josh Stone <jistone@redhat.com>
4354 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4355
4356 * inferiors.h: Include "gdb_vecs.h".
4357 (struct process_info): Add syscalls_to_catch.
4358 * inferiors.c (remove_process): Free syscalls_to_catch.
4359 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
4360 syscall_return stops.
4361 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
4362 * server.c (handle_general_set): Handle QCatchSyscalls.
4363 (handle_query): Report support for QCatchSyscalls.
4364 * target.h (struct target_ops): Add supports_catch_syscall.
4365 (target_supports_catch_syscall): New macro.
4366 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
4367 (struct lwp_info): Add syscall_state.
4368 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
4369 Maintain syscall_state and syscalls_to_catch across exec.
4370 (get_syscall_trapinfo): New function, proxy to the_low_target.
4371 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
4372 (linux_low_filter_event): Toggle syscall_state entry/return for
4373 syscall traps, and set it ignored for all others.
4374 (gdb_catching_syscalls_p): New function.
4375 (gdb_catch_this_syscall_p): New function.
4376 (linux_wait_1): Handle SYSCALL_SIGTRAP.
4377 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
4378 (linux_supports_catch_syscall): New function.
4379 (linux_target_ops): Install it.
4380 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
4381 (the_low_target): Install it.
4382
4383 2016-01-12 Mike Frysinger <vapier@gentoo.org>
4384
4385 * acinclude.m4: Include new ../warning.m4 file.
4386 * configure: Regenerated.
4387 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
4388
4389 2016-01-12 Mike Frysinger <vapier@gentoo.org>
4390
4391 * ax.c (is_goto_target): Mark static.
4392 * linux-low.c (register_addr): Likewise.
4393 (linux_fetch_registers, linux_store_registers): Likewise.
4394 * mem-break.c (any_persistent_commands): Fix old prototype.
4395 (add_commands_to_breakpoint): Mark static.
4396 * regcache.c (find_register_by_name): Delete unused func.
4397 * remote-utils.c (hex_or_minus_one): Mark static.
4398 * server.c (monitor_show_help): Mark static.
4399 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
4400 handle_v_requests): Likewise.
4401
4402 2016-01-12 Pedro Alves <palves@redhat.com>
4403
4404 Remove use of the registered trademark symbol throughout.
4405
4406 2016-01-08 Yao Qi <yao.qi@linaro.org>
4407
4408 * remote-utils.c (getpkt): If c is '\003', call target hook
4409 request_interrupt.
4410
4411 2016-01-06 Yao Qi <yao.qi@linaro.org>
4412
4413 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
4414 linux-aarch32-low.c.
4415 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4416 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
4417 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4418 (thumb2_breakpoint): Declare.
4419 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
4420 linux-aarch32-low.h.
4421 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4422 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
4423 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4424
4425 2016-01-01 Joel Brobecker <brobecker@adacore.com>
4426
4427 * gdbreplay.c (gdbreplay_version): Change copyright year in
4428 version message.
4429 * server.c (gdbserver_version): Likewise.
4430
4431 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
4432
4433 * server.c (crc32_table): Delete.
4434 (crc32): Use libiberty's xcrc32 function.
4435
4436 2015-12-22 Joel Brobecker <brobecker@adacore.com>
4437
4438 * lynx-low.c (lynx_delete_thread_callback): New function.
4439 (lynx_mourn): Properly delete our process and all of its
4440 threads. Remove call to clear_inferiors.
4441
4442 2015-12-22 Joel Brobecker <brobecker@adacore.com>
4443
4444 * target.c (thread_search_callback): Add check that
4445 the thread_stopped target callback is not NULL before
4446 calling it.
4447
4448 2015-12-21 Yao Qi <yao.qi@linaro.org>
4449
4450 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
4451 arm breakpoint.
4452
4453 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4454
4455 * server.c (handle_query): Call target_supports_software_single_step.
4456
4457 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4458
4459 * linux-low.c (single_step): New function.
4460 (linux_resume_one_lwp_throw): Call single_step.
4461 (start_step_over): Likewise.
4462
4463 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4464
4465 * Makefile.in (SFILES): Append arch/arm-linux.c,
4466 arch/arm-get-next-pcs.c.
4467 (arm-linux.o): New rule.
4468 (arm-get-next-pcs.o): New rule.
4469 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
4470 arm-linux.o.
4471 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
4472 to linux-aarch32-low.c.
4473 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4474 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4475 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4476 (thumb2_breakpoint_len): Likewise.
4477 (arm_is_thumb_mode): Make non-static.
4478 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
4479 from linux-aarch32-low.c.
4480 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4481 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4482 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4483 (thumb2_breakpoint_len): Likewise.
4484 (arm_is_thumb_mode): New declaration.
4485 * linux-arm-low.c: Include arch/arm-linux.h
4486 aarch/arm-get-next-pcs.h, sys/syscall.h.
4487 (get_next_pcs_ops): New struct.
4488 (get_next_pcs_addr_bits_remove): New function.
4489 (get_next_pcs_is_thumb): New function.
4490 (get_next_pcs_read_memory_unsigned_integer): Likewise.
4491 (arm_sigreturn_next_pc): Likewise.
4492 (get_next_pcs_syscall_next_pc): Likewise.
4493 (arm_gdbserver_get_next_pcs): Likewise.
4494 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
4495 Initialize.
4496 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
4497 * server.h: Include gdb_vecs.h.
4498
4499 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4500
4501 * Makefile.in (SFILES): Append common/common-regcache.c.
4502 (OBS): Append common-regcache.o.
4503 (common-regcache.o): New rule.
4504 * regcache.c (init_register_cache): Initialize cache to
4505 REG_UNAVAILABLE.
4506 (regcache_raw_read_unsigned): New function.
4507 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
4508 register_status enum.
4509
4510 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4511
4512 * linux-aarch64-low.c (the_low_targets): Rename
4513 breakpoint_reinsert_addr to get_next_pcs.
4514 * linux-arm-low.c (the_low_targets): Likewise.
4515 * linux-bfin-low.c (the_low_targets): Likewise.
4516 * linux-cris-low.c (the_low_targets): Likewise.
4517 * linux-crisv32-low.c (the_low_targets): Likewise.
4518 * linux-low.c (can_software_single_step): Likewise.
4519 (install_software_single_step_breakpoints): New function.
4520 (start_step_over): Use install_software_single_step_breakpoints.
4521 * linux-low.h: New CORE_ADDR vector.
4522 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
4523 get_next_pcs.
4524 * linux-mips-low.c (the_low_targets): Likewise.
4525 * linux-nios2-low.c (the_low_targets): Likewise.
4526 * linux-sparc-low.c (the_low_targets): Likewise.
4527
4528 2015-12-17 Pedro Alves <palves@redhat.com>
4529
4530 * linux-low.c (linux_kill_one_lwp): Remove references to
4531 LinuxThreads.
4532 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
4533 to 'kill'.
4534 (linux_init_signals): Delete.
4535 (initialize_low): Adjust.
4536 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
4537
4538 2015-12-16 Pedro Alves <palves@redhat.com>
4539
4540 * configure.ac (compiler warning flags): When testing a
4541 -Wno-foo option, check whether -Wfoo works instead.
4542 * configure: Regenerate.
4543
4544 2015-12-11 Don Breazeal <donb@codesourcery.com>
4545
4546 * server.c (process_serial_event): Don't exit from gdbserver
4547 in remote mode if there are still active inferiors.
4548
4549 2015-12-11 Yao Qi <yao.qi@linaro.org>
4550
4551 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
4552 arm_breakpoint_at if the process is 32-bit.
4553
4554 2015-12-11 Yao Qi <yao.qi@linaro.org>
4555
4556 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
4557 arm breakpoint.
4558
4559 2015-12-07 Yao Qi <yao.qi@linaro.org>
4560
4561 * configure.srv: Append arm.o to srv_tgtobj for
4562 aarch64*-*-linux* target.
4563 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
4564 from linux-arm-low.c.
4565 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4566 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4567 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4568 (thumb2_breakpoint_len): Likewise.
4569 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
4570 (arm_breakpoint_kinds): Likewise.
4571 (arm_breakpoint_kind_from_pc): Likewise.
4572 (arm_sw_breakpoint_from_kind): Likewise.
4573 (arm_breakpoint_kind_from_current_state): Likewise.
4574 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
4575 (arm_sw_breakpoint_from_kind): Declare.
4576 (arm_breakpoint_kind_from_current_state): Declare.
4577 (arm_breakpoint_at): Declare.
4578 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
4579 arm_sw_breakpoint_from_kind if process is 32-bit.
4580 (aarch64_breakpoint_kind_from_pc): New function.
4581 (aarch64_breakpoint_kind_from_current_state): New function.
4582 (the_low_target): Initialize fields breakpoint_kind_from_pc
4583 and breakpoint_kind_from_current_state.
4584 * linux-arm-low.c (arm_breakpoint_kinds): Move to
4585 linux-aarch32-low.c.
4586 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
4587 (arm_breakpoint, arm_breakpoint_len): Likewise.
4588 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
4589 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4590 (arm_is_thumb_mode): Likewise.
4591 (arm_breakpoint_at): Likewise.
4592 (arm_breakpoint_kind_from_pc): Likewise.
4593 (arm_sw_breakpoint_from_kind): Likewise.
4594 (arm_breakpoint_kind_from_current_state): Likewise.
4595
4596 Revert:
4597 2015-08-04 Yao Qi <yao.qi@linaro.org>
4598
4599 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
4600 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
4601 * server.c (extended_protocol): Remove "static".
4602 * server.h (extended_protocol): Declare it.
4603
4604 2015-12-04 Josh Stone <jistone@redhat.com>
4605
4606 * target.h (struct target_ops) <arch_setup>: Rename to ...
4607 (struct target_ops) <post_create_inferior>: ... this.
4608 (target_arch_setup): Rename to ...
4609 (target_post_create_inferior): ... this, calling post_create_inferior.
4610 * server.c (start_inferior): Update target_arch_setup calls to
4611 target_post_create_inferior.
4612 * linux-low.c (linux_low_ptrace_options): Forward declare.
4613 (linux_arch_setup): Update its comment for general use.
4614 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
4615 (struct linux_target_ops): Use linux_post_create_inferior.
4616 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
4617 to post_create_inferior.
4618 * nto-low.c (struct nto_target_ops): Likewise.
4619 * spu-low.c (struct spu_target_ops): Likewise.
4620 * win32-low.c (struct win32_target_ops): Likewise.
4621
4622 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
4623
4624 * linux-arm-low.c: Remove duplicate arch/arm.h include.
4625
4626 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4627
4628 * linux-arm-low.c (arm_reinsert_addr): Remove function.
4629 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
4630 * linux-cris-low.c (cris_reinsert_addr> Remove function.
4631 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4632 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
4633 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4634 * linux-mips-low.c (mips_reinsert_addr): Remove function.
4635 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4636 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
4637 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4638 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
4639 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4640
4641 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4642
4643 * linux-low.c (linux_look_up_symbols): Don't call
4644 linux_supports_traceclone.
4645 * linux-low.h (thread_db_init): Remove use_events argument.
4646 * thread-db.c (thread_db_use_event): Remove global variable.
4647 (struct thread_db) <td_thr_event_enable_p>: Remove field.
4648 (struct thread_db) <td_create_bp>: Remove field.
4649 (thread_db_create_event): Remove function.
4650 (thread_db_enable_reporting): Likewise.
4651 (find_one_thread): Don't check for thread_db_use_events.
4652 (attach_thread): Likewise.
4653 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
4654 (try_thread_db_load_1): Don't check for thread_db_use_events.
4655 (thread_db_init): Remove use_events argument and thread events
4656 handling.
4657 (remove_thread_event_breakpoints): Remove function.
4658 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
4659
4660 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4661
4662 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
4663 New function.
4664 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4665 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
4666 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4667 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
4668 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
4669 Initialize.
4670 * linux-crisv32-low.c (cris_supports_hardware_single_step):
4671 New function.
4672 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4673 * linux-low.c (can_hardware_single_step): Use
4674 supports_hardware_single_step.
4675 (can_software_single_step): New function.
4676 (start_step_over): Call can_software_single_step.
4677 (linux_supports_hardware_single_step): New function.
4678 (struct target_ops) <supports_software_single_step>: Initialize.
4679 * linux-low.h (struct linux_target_ops)
4680 <supports_hardware_single_step>: Initialize.
4681 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
4682 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4683 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
4684 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
4685 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
4686 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4687 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
4688 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4689 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
4690 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
4691 Initialize.
4692 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
4693 (struct linux_target_ops) <tile_supports_hardware_single_step>:
4694 Initialize.
4695 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
4696 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4697 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
4698 New function.
4699 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4700 * target.h (struct target_ops): <supports_software_single_step>:
4701 New field.
4702 (target_supports_software_single_step): New macro.
4703
4704 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4705
4706 * linux-low.c (linux_wait_1): Fix pc advance condition.
4707 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
4708 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
4709
4710 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4711
4712 * linux-arm-low.c (arm_is_thumb_mode): New function.
4713 (arm_breakpoint_at): Use arm_is_thumb_mode.
4714 (arm_breakpoint_kind_from_current_state): New function.
4715 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
4716 Initialize.
4717 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
4718 (linux_breakpoint_kind_from_current_state): New function.
4719 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
4720 * linux-low.h (struct linux_target_ops)
4721 <breakpoint_kind_from_current_state>: New field.
4722 * target.h (struct target_ops): Likewise.
4723 (target_breakpoint_kind_from_current_state): New macro.
4724
4725 2015-11-30 Pedro Alves <palves@redhat.com>
4726
4727 * linux-low.c (linux_resume): Wake up the event loop before
4728 returning.
4729
4730 2015-11-30 Pedro Alves <palves@redhat.com>
4731
4732 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
4733 check.
4734 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
4735 to -1.
4736 * target.c (struct thread_search): New structure.
4737 (thread_search_callback): New function.
4738 (prev_general_thread): New global.
4739 (prepare_to_access_memory, done_accessing_memory): New functions.
4740 * target.h (prepare_to_access_memory, done_accessing_memory):
4741 Replace macros with function declarations.
4742
4743 2015-11-30 Pedro Alves <palves@redhat.com>
4744
4745 PR 14618
4746 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
4747 report TARGET_WAITKIND_NO_RESUMED.
4748 * remote-utils.c (prepare_resume_reply): Handle
4749 TARGET_WAITKIND_NO_RESUMED.
4750 * server.c (report_no_resumed): New global.
4751 (handle_query) <qSupported>: Handle "no-resumed+". Report
4752 "no-resumed+" support.
4753 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
4754 return error if the client doesn't support no-resumed events.
4755 (push_stop_notification): New function.
4756 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
4757 events if the client supports them.
4758
4759 2015-11-30 Pedro Alves <palves@redhat.com>
4760
4761 * linux-low.c (thread_still_has_status_pending_p): Don't check
4762 vCont;t here.
4763 (lwp_resumed): New function.
4764 (status_pending_p_callback): Return early if the LWP is not
4765 supposed to be resumed.
4766
4767 2015-11-30 Pedro Alves <palves@redhat.com>
4768
4769 * linux-low.c (handle_extended_wait): Assert that the LWP's
4770 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
4771 thread create events, leave the new child's status pending.
4772 (linux_low_filter_event): If GDB wants to hear about thread exit
4773 events, leave the LWP marked dead and don't delete it.
4774 (linux_wait_for_event_filtered): Don't check for thread exit.
4775 (filter_exit_event): New function.
4776 (linux_wait_1): Use it, when returning an exit event.
4777 (linux_resume_one_lwp_throw): Assert that the LWP's
4778 waitstatus is TARGET_WAITKIND_IGNORE.
4779 * remote-utils.c (prepare_resume_reply): Handle
4780 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
4781 * server.c (report_thread_events): New global.
4782 (handle_general_set): Handle QThreadEvents.
4783 (handle_query) <qSupported>: Handle and report QThreadEvents+;
4784 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
4785 TARGET_WAITKIND_THREAD_EXITED.
4786 * server.h (report_thread_events): Declare.
4787
4788 2015-11-30 Pedro Alves <palves@redhat.com>
4789
4790 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
4791 the thread's last_resume_kind was resume_stop.
4792
4793 2015-11-30 Pedro Alves <palves@redhat.com>
4794
4795 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
4796 before returning.
4797
4798 2015-11-30 Pedro Alves <palves@redhat.com>
4799
4800 * server.c (handle_v_requests): Handle vCtrlC.
4801
4802 2015-11-30 Pedro Alves <palves@redhat.com>
4803
4804 * gdbthread.h (find_any_thread_of_pid): Declare.
4805 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
4806 functions.
4807 * server.c (handle_query): If current_thread is NULL, look for
4808 another thread of the selected process.
4809
4810 2015-11-26 Daniel Colascione <dancol@dancol.org>
4811 Simon Marchi <simon.marchi@ericsson.com>
4812
4813 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
4814 * server.c (handle_qxfer_threads_worker): Refactor to include thread
4815 name in reply.
4816 * target.h (struct target_ops) <thread_name>: New field.
4817 (target_thread_name): New macro.
4818
4819 2015-11-23 Joel Brobecker <brobecker@adacore.com>
4820
4821 * regcache.h (regcache_invalidate_pid): Add declaration.
4822 * regcache.c (regcache_invalidate_pid): New function, extracted
4823 from regcache_invalidate.
4824 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
4825 Add trivial documentation comment.
4826 * lynx-low.c: Use regcache_invalidate_pid instead of
4827 regcache_invalidate.
4828
4829 2015-11-23 Joel Brobecker <brobecker@adacore.com>
4830
4831 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
4832 and Elf64_auxv_t if the target is Android.
4833
4834 2015-11-22 Doug Evans <xdje42@gmail.com>
4835
4836 * target.h: #include <sys/types.h>.
4837
4838 2015-11-19 Pedro Alves <palves@redhat.com>
4839
4840 * linux-low.c (linux_process_qsupported): Change prototype.
4841 Adjust.
4842 * linux-low.h (struct linux_target_ops) <process_qsupported>:
4843 Change prototype.
4844 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
4845 and adjust to loop over all features.
4846 * server.c (handle_query) <qSupported>: Adjust to call
4847 target_process_qsupported once, passing it a vector of unprocessed
4848 features.
4849 * target.h (struct target_ops) <process_qsupported>: Change
4850 prototype.
4851 (target_process_qsupported): Adjust.
4852
4853 2015-11-19 Pedro Alves <palves@redhat.com>
4854
4855 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
4856 mode.
4857 * configure: Regenerate.
4858
4859 2015-11-19 Pedro Alves <palves@redhat.com>
4860
4861 * configure: Regenerate.
4862
4863 2015-11-19 Yao Qi <yao.qi@linaro.org>
4864
4865 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
4866 type to uint32_t.
4867
4868 2015-11-19 Yao Qi <yao.qi@linaro.org>
4869
4870 * linux-aarch64-low.c (enum aarch64_operand_type): New.
4871 (struct aarch64_operand): Move enum out.
4872
4873 2015-11-19 Yao Qi <yao.qi@linaro.org>
4874
4875 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
4876 struct user_fpsimd_state *.
4877 (aarch64_store_fpregset): Likewise.
4878
4879 2015-11-19 Yao Qi <yao.qi@linaro.org>
4880
4881 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
4882 struct user_pt_regs *.
4883 (aarch64_store_gregset): Likewise.
4884
4885 2015-11-18 Pedro Alves <palves@redhat.com>
4886
4887 * Makefile.in (all_object_files): Add $IPA_OBJS.
4888
4889 2015-11-17 Pedro Alves <palves@redhat.com>
4890
4891 * win32-low.c (win32_resume): Use gdb_signal_from_host,
4892 GDB_SIGNAL_0 and gdb_signal_to_string.
4893
4894 2015-11-17 Pedro Alves <palves@redhat.com>
4895
4896 * win32-low.c (handle_output_debug_string): Remove parameter.
4897 (win32_kill): Remove our_status local and adjust call to
4898 handle_output_debug_string.
4899 (get_child_debug_event): Adjust call to
4900 handle_output_debug_string.
4901
4902 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4903
4904 * linux-mips-low.c (mips_fill_gregset): Add cast.
4905 (mips_store_gregset): Likewise.
4906 (mips_fill_fpregset): Likewise.
4907 (mips_store_fpregset): Likewise.
4908
4909 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4910
4911 * linux-mips-low.c (mips_add_watchpoint): Rename private to
4912 priv.
4913
4914 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4915
4916 * linux-mips-low.c (mips_linux_new_thread): Change type of
4917 watch_type to enum target_hw_bp_type.
4918
4919 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4920
4921 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
4922 Change return type to arm_hwbp_type.
4923
4924 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4925
4926 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
4927 (arm_store_gregset): Likewise.
4928 * linux-arm-low.c (arm_get_hwcap): Likewise.
4929 (arm_read_description): Likewise.
4930
4931 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4932
4933 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
4934
4935 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4936
4937 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
4938 (ppc_fill_vsxregset): Likewise.
4939 (ppc_store_vsxregset): Likewise.
4940 (ppc_fill_vrregset): Likewise.
4941 (ppc_store_vrregset): Likewise.
4942 (ppc_fill_evrregset): Likewise.
4943 (ppc_store_evrregset): Likewise.
4944
4945 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4946
4947 * linux-ppc-low.c (ppc_usrregs_info): Remove
4948 forward-declaration.
4949 (ppc_arch_setup): Move lower in file.
4950
4951 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
4952
4953 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
4954 (ps_pdwrite): Likewise.
4955
4956 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
4957
4958 * linux-arm-low.c (arm_new_thread): Move pointer dereference
4959 to after assert checks.
4960
4961 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
4962
4963 * proc-service.c (ps_pdread): Add/adjust casts.
4964 (ps_pdwrite): Add/adjust casts.
4965
4966 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
4967
4968 * server.c (handle_search_memory_1): Cast return value of
4969 memmem.
4970
4971 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
4972
4973 * server.c (write_qxfer_response): Change type of data to
4974 gdb_byte *.
4975
4976 2015-10-29 Pedro Alves <palves@redhat.com>
4977
4978 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
4979
4980 2015-10-29 Pedro Alves <palves@redhat.com>
4981
4982 * tracepoint.c (clear_installed_tracepoints): Add casts.
4983
4984 2015-10-29 Pedro Alves <palves@redhat.com>
4985
4986 * server.c (handle_v_cont, process_serial_event): Add enum
4987 gdb_signal casts to signal parsing code.
4988
4989 2015-10-29 Pedro Alves <palves@redhat.com>
4990
4991 * linux-low.h (NULL_REGSET): Define.
4992 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
4993 * linux-arm-low.c (arm_regsets): Likewise.
4994 * linux-crisv32-low.c (cris_regsets): Likewise.
4995 * linux-m68k-low.c (m68k_regsets): Likewise.
4996 * linux-mips-low.c (mips_regsets): Likewise.
4997 * linux-nios2-low.c (nios2_regsets): Likewise.
4998 * linux-ppc-low.c (ppc_regsets): Likewise.
4999 * linux-s390-low.c (s390_regsets): Likewise.
5000 * linux-sh-low.c (sh_regsets): Likewise.
5001 * linux-sparc-low.c (sparc_regsets): Likewise.
5002 * linux-tic6x-low.c (tic6x_regsets): Likewise.
5003 * linux-tile-low.c (tile_regsets): Likewise.
5004 * linux-x86-low.c (x86_regsets): Likewise.
5005 * linux-xtensa-low.c (xtensa_regsets): Likewise.
5006
5007 2015-10-29 Pedro Alves <palves@redhat.com>
5008
5009 * linux-low.h (NULL_REGSET): Define.
5010 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
5011 * linux-arm-low.c (arm_regsets): Likewise.
5012 * linux-crisv32-low.c (cris_regsets): Likewise.
5013 * linux-m68k-low.c (m68k_regsets): Likewise.
5014 * linux-mips-low.c (mips_regsets): Likewise.
5015 * linux-nios2-low.c (nios2_regsets): Likewise.
5016 * linux-ppc-low.c (ppc_regsets): Likewise.
5017 * linux-s390-low.c (s390_regsets): Likewise.
5018 * linux-sh-low.c (sh_regsets): Likewise.
5019 * linux-sparc-low.c (sparc_regsets): Likewise.
5020 * linux-tic6x-low.c (tic6x_regsets): Likewise.
5021 * linux-tile-low.c (tile_regsets): Likewise.
5022 * linux-x86-low.c (x86_regsets): Likewise.
5023 * linux-xtensa-low.c (xtensa_regsets): Likewise.
5024
5025 2015-10-26 Doug Evans <dje@google.com>
5026
5027 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
5028
5029 2015-10-26 Doug Evans <dje@google.com>
5030
5031 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
5032
5033 2015-10-26 Doug Evans <dje@google.com>
5034
5035 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
5036 for debug_printf.
5037 (attach_thread, find_new_threads_callback): Ditto.
5038
5039 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5040
5041 * mem-break.h (set_breakpoint_data): Remove.
5042
5043 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5044
5045 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
5046 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
5047 (initialize_low): Remove set_breakpoint_data call.
5048 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
5049 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
5050 (initialize_low): Remove set_breakpoint_data call.
5051 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
5052 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
5053 (initialize_low): Remove set_breakpoint_data call.
5054
5055 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5056
5057 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
5058 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
5059 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
5060 * target.h (target_breakpoint_kind_from_pc): New macro.
5061
5062 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
5063
5064 * linux-low.c (default_breakpoint_kind_from_pc): New function.
5065 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
5066 the default breakpoint kind.
5067
5068 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5069
5070 * linux-arm-low.c (arm_supports_z_point_type): Add software
5071 breakpoint support.
5072
5073 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5074
5075 * linux-arm-low.c: Refactor breakpoint definitions.
5076 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
5077 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
5078
5079 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5080
5081 * Makefile.in: Add arm.c/o.
5082 * configure.srv: Likewise.
5083 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
5084 (arm_breakpoint_kind_from_pc): New function.
5085 (arm_sw_breakpoint_from_kind): Return proper kind.
5086 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
5087
5088 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5089
5090 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
5091 removal.
5092 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
5093 (struct raw_breakpoint) <size>: Remove.
5094 (struct raw_breakpoint) <kind>: Add.
5095 (bp_size): New function.
5096 (bp_opcode): Likewise.
5097 (find_raw_breakpoint_at): Adjust for kind.
5098 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
5099 (remove_memory_breakpoint): Adjust for kind call bp_size.
5100 (set_raw_breakpoint_at): Adjust for kind.
5101 (set_breakpoint): Likewise.
5102 (set_breakpoint_at): Call breakpoint_kind_from_pc.
5103 (delete_raw_breakpoint): Adjust for kind.
5104 (delete_breakpoint): Likewise.
5105 (find_gdb_breakpoint): Likewise.
5106 (set_gdb_breakpoint_1): Likewise.
5107 (set_gdb_breakpoint): Likewise.
5108 (delete_gdb_breakpoint_1): Likewise.
5109 (delete_gdb_breakpoint): Likewise.
5110 (uninsert_raw_breakpoint): Likewise.
5111 (reinsert_raw_breakpoint): Likewise.
5112 (set_breakpoint_data): Remove.
5113 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
5114 (check_mem_read): Adjust for kind call bp_size.
5115 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
5116 (clone_one_breakpoint): Adjust for kind.
5117 * mem-break.h (set_gdb_breakpoint): Likewise.
5118 (delete_gdb_breakpoint): Likewise.
5119 * server.c (process_serial_event): Likewise.
5120
5121 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5122
5123 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
5124 (struct linux_target_ops) <breakpoint>: Remove.
5125 (struct linux_target_ops) <breakpoint_len>: Remove.
5126 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5127 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5128 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
5129 (arm_sw_breakpoint_from_kind): New function.
5130 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
5131 (struct linux_target_ops) <breakpoint>: Remove.
5132 (struct linux_target_ops) <breakpoint_len>: Remove.
5133 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5134 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5135 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
5136 (struct linux_target_ops) <breakpoint>: Remove.
5137 (struct linux_target_ops) <breakpoint_len>: Remove.
5138 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5139 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5140 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
5141 (struct linux_target_ops) <breakpoint>: Remove.
5142 (struct linux_target_ops) <breakpoint_len>: Remove.
5143 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5144 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5145 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
5146 and sw_breakpoint_from_kind to increment the pc.
5147 (linux_breakpoint_kind_from_pc): New function.
5148 (linux_sw_breakpoint_from_kind): New function.
5149 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
5150 (initialize_low): Call breakpoint_kind_from_pc and
5151 sw_breakpoint_from_kind to replace breakpoint_data/len.
5152 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
5153 New field.
5154 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
5155 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
5156 (struct linux_target_ops) <breakpoint>: Remove.
5157 (struct linux_target_ops) <breakpoint_len>: Remove.
5158 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5159 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5160 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
5161 (struct linux_target_ops) <breakpoint>: Remove.
5162 (struct linux_target_ops) <breakpoint_len>: Remove.
5163 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5164 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5165 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
5166 (struct linux_target_ops) <breakpoint>: Remove.
5167 (struct linux_target_ops) <breakpoint_len>: Remove.
5168 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5169 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5170 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
5171 (struct linux_target_ops) <breakpoint>: Remove.
5172 (struct linux_target_ops) <breakpoint_len>: Remove.
5173 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5174 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5175 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
5176 (struct linux_target_ops) <breakpoint>: Remove.
5177 (struct linux_target_ops) <breakpoint_len>: Remove.
5178 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5179 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5180 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
5181 (struct linux_target_ops) <breakpoint>: Remove.
5182 (struct linux_target_ops) <breakpoint_len>: Remove.
5183 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5184 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5185 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
5186 (struct linux_target_ops) <breakpoint>: Remove.
5187 (struct linux_target_ops) <breakpoint_len>: Remove.
5188 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5189 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5190 * linux-sparc-low.c (sparc_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-tic6x-low.c (tic6x_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-tile-low.c (tile_sw_breakpoint_from_kind): New function.
5201 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
5202 (struct linux_target_ops) <breakpoint>: Remove.
5203 (struct linux_target_ops) <breakpoint_len>: Remove.
5204 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5205 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5206 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
5207 (struct linux_target_ops) <breakpoint>: Remove.
5208 (struct linux_target_ops) <breakpoint_len>: Remove.
5209 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5210 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5211
5212 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5213
5214 * linux-cris-low.c (cris_get_pc): Remove void arg.
5215
5216 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
5217
5218 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
5219 variable name.
5220
5221 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
5222
5223 * inferiors.c (thread_pid_matches_callback): New function.
5224 (find_thread_process): New function.
5225 (remove_thread): Reset current_thread.
5226 (remove_process): Assert threads have been removed first.
5227
5228 2015-10-15 Yao Qi <yao.qi@linaro.org>
5229
5230 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
5231 if it is 3.
5232 (aarch64_remove_point): Likewise.
5233 * regcache.c (regcache_register_size): New function.
5234
5235 2015-10-12 Yao Qi <yao.qi@linaro.org>
5236
5237 * linux-aarch64-low.c: Update all callers as emit_load_store
5238 is renamed to aarch64_emit_load_store.
5239
5240 2015-10-12 Yao Qi <yao.qi@linaro.org>
5241
5242 * linux-aarch64-low.c: Update all callers of function renaming
5243 from emit_insn to aarch64_emit_insn.
5244
5245 2015-10-12 Yao Qi <yao.qi@linaro.org>
5246
5247 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
5248 arch/aarch64-insn.h.
5249 (struct aarch64_memory_operand): Likewise.
5250 (ENCODE): Likewise.
5251 (emit_insn): Move to arch/aarch64-insn.c.
5252 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
5253 (emit_load_store): Move to arch/aarch64-insn.c.
5254 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
5255 (can_encode_int32): Remove.
5256
5257 2015-10-12 Yao Qi <yao.qi@linaro.org>
5258
5259 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
5260 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
5261 (aarch64_relocate_instruction): Likewise.
5262 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
5263 (struct aarch64_insn_visitor): Likewise.
5264
5265 2015-10-12 Yao Qi <yao.qi@linaro.org>
5266
5267 * linux-aarch64-low.c (struct aarch64_insn_data): New.
5268 (struct aarch64_insn_visitor): New.
5269 (struct aarch64_insn_relocation_data): New.
5270 (aarch64_ftrace_insn_reloc_b): New function.
5271 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
5272 (aarch64_ftrace_insn_reloc_cb): Likewise.
5273 (aarch64_ftrace_insn_reloc_tb): Likewise.
5274 (aarch64_ftrace_insn_reloc_adr): Likewise.
5275 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
5276 (aarch64_ftrace_insn_reloc_others): Likewise.
5277 (visitor): New.
5278 (aarch64_relocate_instruction): Use visitor.
5279
5280 2015-10-12 Yao Qi <yao.qi@linaro.org>
5281
5282 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
5283 int. Add argument buf.
5284 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
5285 aarch64_relocate_instruction.
5286
5287 2015-10-12 Yao Qi <yao.qi@linaro.org>
5288
5289 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
5290 argument insn. Remove local variable insn. Don't call
5291 target_read_uint32.
5292 (aarch64_install_fast_tracepoint_jump_pad): Call
5293 target_read_uint32.
5294
5295 2015-09-30 Yao Qi <yao.qi@linaro.org>
5296
5297 * linux-aarch64-low.c (emit_movk): Shorten a long line.
5298 (emit_load_store_pair): Likewise.
5299
5300 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
5301
5302 * dll.c (match_dll): Add cast(s).
5303 (unloaded_dll): Likewise.
5304 * linux-low.c (second_thread_of_pid_p): Likewise.
5305 (delete_lwp_callback): Likewise.
5306 (count_events_callback): Likewise.
5307 (select_event_lwp_callback): Likewise.
5308 (linux_set_resume_request): Likewise.
5309 * server.c (accumulate_file_name_length): Likewise.
5310 (emit_dll_description): Likewise.
5311 (handle_qxfer_threads_worker): Likewise.
5312 (visit_actioned_threads): Likewise.
5313 * thread-db.c (any_thread_of): Likewise.
5314 * tracepoint.c (same_process_p): Likewise.
5315 (match_blocktype): Likewise.
5316 (build_traceframe_info_xml): Likewise.
5317
5318 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
5319
5320 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
5321 assignment.
5322 (gdb_unparse_agent_expr): Likewise.
5323 * hostio.c (require_data): Likewise.
5324 (handle_pread): Likewise.
5325 * linux-low.c (disable_regset): Likewise.
5326 (fetch_register): Likewise.
5327 (store_register): Likewise.
5328 (get_dynamic): Likewise.
5329 (linux_qxfer_libraries_svr4): Likewise.
5330 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
5331 (set_fast_tracepoint_jump): Likewise.
5332 (uninsert_fast_tracepoint_jumps_at): Likewise.
5333 (reinsert_fast_tracepoint_jumps_at): Likewise.
5334 (validate_inserted_breakpoint): Likewise.
5335 (clone_agent_expr): Likewise.
5336 * regcache.c (init_register_cache): Likewise.
5337 * remote-utils.c (putpkt_binary_1): Likewise.
5338 (decode_M_packet): Likewise.
5339 (decode_X_packet): Likewise.
5340 (look_up_one_symbol): Likewise.
5341 (relocate_instruction): Likewise.
5342 (monitor_output): Likewise.
5343 * server.c (handle_search_memory): Likewise.
5344 (handle_qxfer_exec_file): Likewise.
5345 (handle_qxfer_libraries): Likewise.
5346 (handle_qxfer): Likewise.
5347 (handle_query): Likewise.
5348 (handle_v_cont): Likewise.
5349 (handle_v_run): Likewise.
5350 (captured_main): Likewise.
5351 * target.c (write_inferior_memory): Likewise.
5352 * thread-db.c (try_thread_db_load_from_dir): Likewise.
5353 * tracepoint.c (init_trace_buffer): Likewise.
5354 (add_tracepoint_action): Likewise.
5355 (add_traceframe): Likewise.
5356 (add_traceframe_block): Likewise.
5357 (cmd_qtdpsrc): Likewise.
5358 (cmd_qtdv): Likewise.
5359 (cmd_qtstatus): Likewise.
5360 (response_source): Likewise.
5361 (response_tsv): Likewise.
5362 (cmd_qtnotes): Likewise.
5363 (gdb_collect): Likewise.
5364 (initialize_tracepoint): Likewise.
5365
5366 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5367
5368 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
5369 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
5370 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
5371 <NOP>: New.
5372 (enum aarch64_condition_codes): New enum.
5373 (w0): New static global.
5374 (fp): Likewise.
5375 (lr): Likewise.
5376 (struct aarch64_memory_operand) <type>: New
5377 MEMORY_OPERAND_POSTINDEX type.
5378 (postindex_memory_operand): New helper function.
5379 (emit_ret): New function.
5380 (emit_load_store_pair): New function, factored out of emit_stp
5381 with support for MEMORY_OPERAND_POSTINDEX.
5382 (emit_stp): Rewrite using emit_load_store_pair.
5383 (emit_ldp): New function.
5384 (emit_load_store): Likewise.
5385 (emit_ldr): Mention post-index instruction in comment.
5386 (emit_ldrh): New function.
5387 (emit_ldrb): New function.
5388 (emit_ldrsw): Mention post-index instruction in comment.
5389 (emit_str): Likewise.
5390 (emit_subs): New function.
5391 (emit_cmp): Likewise.
5392 (emit_and): Likewise.
5393 (emit_orr): Likewise.
5394 (emit_orn): Likewise.
5395 (emit_eor): Likewise.
5396 (emit_mvn): Likewise.
5397 (emit_lslv): Likewise.
5398 (emit_lsrv): Likewise.
5399 (emit_asrv): Likewise.
5400 (emit_mul): Likewise.
5401 (emit_sbfm): Likewise.
5402 (emit_sbfx): Likewise.
5403 (emit_ubfm): Likewise.
5404 (emit_ubfx): Likewise.
5405 (emit_csinc): Likewise.
5406 (emit_cset): Likewise.
5407 (emit_nop): Likewise.
5408 (emit_ops_insns): New helper function.
5409 (emit_pop): Likewise.
5410 (emit_push): Likewise.
5411 (aarch64_emit_prologue): New function.
5412 (aarch64_emit_epilogue): Likewise.
5413 (aarch64_emit_add): Likewise.
5414 (aarch64_emit_sub): Likewise.
5415 (aarch64_emit_mul): Likewise.
5416 (aarch64_emit_lsh): Likewise.
5417 (aarch64_emit_rsh_signed): Likewise.
5418 (aarch64_emit_rsh_unsigned): Likewise.
5419 (aarch64_emit_ext): Likewise.
5420 (aarch64_emit_log_not): Likewise.
5421 (aarch64_emit_bit_and): Likewise.
5422 (aarch64_emit_bit_or): Likewise.
5423 (aarch64_emit_bit_xor): Likewise.
5424 (aarch64_emit_bit_not): Likewise.
5425 (aarch64_emit_equal): Likewise.
5426 (aarch64_emit_less_signed): Likewise.
5427 (aarch64_emit_less_unsigned): Likewise.
5428 (aarch64_emit_ref): Likewise.
5429 (aarch64_emit_if_goto): Likewise.
5430 (aarch64_emit_goto): Likewise.
5431 (aarch64_write_goto_address): Likewise.
5432 (aarch64_emit_const): Likewise.
5433 (aarch64_emit_call): Likewise.
5434 (aarch64_emit_reg): Likewise.
5435 (aarch64_emit_pop): Likewise.
5436 (aarch64_emit_stack_flush): Likewise.
5437 (aarch64_emit_zero_ext): Likewise.
5438 (aarch64_emit_swap): Likewise.
5439 (aarch64_emit_stack_adjust): Likewise.
5440 (aarch64_emit_int_call_1): Likewise.
5441 (aarch64_emit_void_call_2): Likewise.
5442 (aarch64_emit_eq_goto): Likewise.
5443 (aarch64_emit_ne_goto): Likewise.
5444 (aarch64_emit_lt_goto): Likewise.
5445 (aarch64_emit_le_goto): Likewise.
5446 (aarch64_emit_gt_goto): Likewise.
5447 (aarch64_emit_ge_got): Likewise.
5448 (aarch64_emit_ops_impl): New static global variable.
5449 (aarch64_emit_ops): New target function, return
5450 &aarch64_emit_ops_impl.
5451 (struct linux_target_ops): Install it.
5452
5453 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5454
5455 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
5456 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
5457 aarch64-ipa.o.
5458 * linux-aarch64-ipa.c: New file.
5459 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
5460 and endian.h.
5461 (aarch64_get_thread_area): New target method.
5462 (extract_signed_bitfield): New helper function.
5463 (aarch64_decode_ldr_literal): New function.
5464 (enum aarch64_opcodes): New enum.
5465 (struct aarch64_register): New struct.
5466 (struct aarch64_operand): New struct.
5467 (x0): New static global.
5468 (x1): Likewise.
5469 (x2): Likewise.
5470 (x3): Likewise.
5471 (x4): Likewise.
5472 (w2): Likewise.
5473 (ip0): Likewise.
5474 (sp): Likewise.
5475 (xzr): Likewise.
5476 (aarch64_register): New helper function.
5477 (register_operand): Likewise.
5478 (immediate_operand): Likewise.
5479 (struct aarch64_memory_operand): New struct.
5480 (offset_memory_operand): New helper function.
5481 (preindex_memory_operand): Likewise.
5482 (enum aarch64_system_control_registers): New enum.
5483 (ENCODE): New macro.
5484 (emit_insn): New helper function.
5485 (emit_b): New function.
5486 (emit_bcond): Likewise.
5487 (emit_cb): Likewise.
5488 (emit_tb): Likewise.
5489 (emit_blr): Likewise.
5490 (emit_stp): Likewise.
5491 (emit_ldp_q_offset): Likewise.
5492 (emit_stp_q_offset): Likewise.
5493 (emit_load_store): Likewise.
5494 (emit_ldr): Likewise.
5495 (emit_ldrsw): Likewise.
5496 (emit_str): Likewise.
5497 (emit_ldaxr): Likewise.
5498 (emit_stxr): Likewise.
5499 (emit_stlr): Likewise.
5500 (emit_data_processing_reg): Likewise.
5501 (emit_data_processing): Likewise.
5502 (emit_add): Likewise.
5503 (emit_sub): Likewise.
5504 (emit_mov): Likewise.
5505 (emit_movk): Likewise.
5506 (emit_mov_addr): Likewise.
5507 (emit_mrs): Likewise.
5508 (emit_msr): Likewise.
5509 (emit_sevl): Likewise.
5510 (emit_wfe): Likewise.
5511 (append_insns): Likewise.
5512 (can_encode_int32_in): New helper function.
5513 (aarch64_relocate_instruction): New function.
5514 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
5515 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
5516 (struct linux_target_ops): Install aarch64_get_thread_area,
5517 aarch64_install_fast_tracepoint_jump_pad and
5518 aarch64_get_min_fast_tracepoint_insn_len.
5519
5520 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5521
5522 * Makefile.in (aarch64-insn.o): New rule.
5523 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
5524
5525 2015-09-21 Yao Qi <yao.qi@linaro.org>
5526
5527 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
5528
5529 2015-09-21 Yao Qi <yao.qi@linaro.org>
5530
5531 * tracepoint.c (max_jump_pad_size): Remove.
5532
5533 2015-09-18 Yao Qi <yao.qi@linaro.org>
5534
5535 * linux-aarch64-low.c: Don't include sys/uio.h.
5536 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
5537
5538 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
5539
5540 * tracepoint.c (eval_result_type): Change prototype.
5541 (condition_true_at_tracepoint): Fix argument to compiled_cond.
5542
5543 2015-09-15 Pedro Alves <palves@redhat.com>
5544
5545 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
5546 Check whether to report exec events instead of checking whether
5547 multiprocess is enabled.
5548
5549 2015-09-15 Pedro Alves <palves@redhat.com>
5550
5551 PR remote/18965
5552 * remote-utils.c (prepare_resume_reply): Merge
5553 TARGET_WAITKIND_VFORK_DONE switch case with the
5554 TARGET_WAITKIND_FORKED case.
5555
5556 2015-09-15 Yao Qi <yao.qi@linaro.org>
5557
5558 * server.c (handle_query): Check string comparison using
5559 "else if" instead of "if".
5560
5561 2015-09-15 Yao Qi <yao.qi@linaro.org>
5562
5563 * server.c (vCont_supported): New global variable.
5564 (handle_query): Set vCont_supported to 1 if "vContSupported+"
5565 matches. Append ";vContSupported+" to own_buf.
5566 (handle_v_requests): Append ";s;S" to own_buf if target supports
5567 hardware single step or vCont_supported is false.
5568 (capture_main): Set vCont_supported to zero.
5569
5570 2015-09-15 Yao Qi <yao.qi@linaro.org>
5571
5572 * linux-low.c (linux_supports_conditional_breakpoints): Rename
5573 it to ...
5574 (linux_supports_hardware_single_step): ... New function.
5575 (linux_target_ops): Update.
5576 * lynx-low.c (lynx_target_ops): Set field
5577 supports_hardware_single_step to target_can_do_hardware_single_step.
5578 * nto-low.c (nto_target_ops): Likewise.
5579 * spu-low.c (spu_target_ops): Likewise.
5580 * win32-low.c (win32_target_ops): Likewise.
5581 * target.c (target_can_do_hardware_single_step): New function.
5582 * target.h (struct target_ops) <supports_conditional_breakpoints>:
5583 Remove. <supports_hardware_single_step>: New field.
5584 (target_supports_conditional_breakpoints): Remove.
5585 (target_supports_hardware_single_step): New macro.
5586 (target_can_do_hardware_single_step): Declare.
5587 * server.c (handle_query): Use target_supports_hardware_single_step
5588 instead of target_supports_conditional_breakpoints.
5589
5590 2015-09-15 Yao Qi <yao.qi@linaro.org>
5591
5592 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
5593 function.
5594 (struct linux_target_ops the_low_target): Install
5595 aarch64_linux_siginfo_fixup.
5596
5597 2015-09-11 Don Breazeal <donb@codesourcery.com>
5598 Luis Machado <lgustavo@codesourcery.com>
5599
5600 * linux-low.c (linux_mourn): Static declaration.
5601 (linux_arch_setup): Move in front of
5602 handle_extended_wait.
5603 (linux_arch_setup_thread): New function.
5604 (handle_extended_wait): Handle exec events. Call
5605 linux_arch_setup_thread. Make event_lwp argument a
5606 pointer-to-a-pointer.
5607 (check_zombie_leaders): Do not check stopped threads.
5608 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
5609 (linux_low_filter_event): Add lwp and thread for exec'ing
5610 non-leader thread if leader thread has been deleted.
5611 Refactor code into linux_arch_setup_thread and call it.
5612 Pass child lwp pointer by reference to handle_extended_wait.
5613 (linux_wait_for_event_filtered): Update comment.
5614 (linux_wait_1): Prevent clobbering exec event status.
5615 (linux_supports_exec_events): New function.
5616 (linux_target_ops) <supports_exec_events>: Initialize new member.
5617 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
5618 new member.
5619 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
5620 * server.c (report_exec_events): New global variable.
5621 (handle_query): Handle qSupported query for exec-events feature.
5622 (captured_main): Initialize report_exec_events.
5623 * server.h (report_exec_events): Declare new global variable.
5624 * target.h (struct target_ops) <supports_exec_events>: New
5625 member.
5626 (target_supports_exec_events): New macro.
5627 * win32-low.c (win32_target_ops) <supports_exec_events>:
5628 Initialize new member.
5629
5630 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
5631
5632 * linux-low.c (linux_low_enable_btrace): Remove.
5633 (linux_target_ops): Replace linux_low_enable_btrace with
5634 linux_enable_btrace.
5635
5636 2015-09-03 Yao Qi <yao.qi@linaro.org>
5637
5638 * linux-aarch64-low.c (aarch64_insert_point): Call
5639 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
5640 returns true.
5641
5642 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
5643
5644 * linux-low.c (check_stopped_by_breakpoint): Use
5645 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
5646
5647 2015-08-27 Pedro Alves <palves@redhat.com>
5648
5649 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
5650
5651 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
5652
5653 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
5654 the XNEW-family equivalent.
5655 (compile_bytecodes): Likewise.
5656 * dll.c (loaded_dll): Likewise.
5657 * event-loop.c (append_callback_event): Likewise.
5658 (create_file_handler): Likewise.
5659 (create_file_event): Likewise.
5660 * hostio.c (handle_open): Likewise.
5661 * inferiors.c (add_thread): Likewise.
5662 (add_process): Likewise.
5663 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
5664 * linux-arm-low.c (arm_new_process): Likewise.
5665 (arm_new_thread): Likewise.
5666 * linux-low.c (add_to_pid_list): Likewise.
5667 (linux_add_process): Likewise.
5668 (handle_extended_wait): Likewise.
5669 (add_lwp): Likewise.
5670 (enqueue_one_deferred_signal): Likewise.
5671 (enqueue_pending_signal): Likewise.
5672 (linux_resume_one_lwp_throw): Likewise.
5673 (linux_resume_one_thread): Likewise.
5674 (linux_read_memory): Likewise.
5675 (linux_write_memory): Likewise.
5676 * linux-mips-low.c (mips_linux_new_process): Likewise.
5677 (mips_linux_new_thread): Likewise.
5678 (mips_add_watchpoint): Likewise.
5679 * linux-x86-low.c (initialize_low_arch): Likewise.
5680 * lynx-low.c (lynx_add_process): Likewise.
5681 * mem-break.c (set_raw_breakpoint_at): Likewise.
5682 (set_breakpoint): Likewise.
5683 (add_condition_to_breakpoint): Likewise.
5684 (add_commands_to_breakpoint): Likewise.
5685 (clone_agent_expr): Likewise.
5686 (clone_one_breakpoint): Likewise.
5687 * regcache.c (new_register_cache): Likewise.
5688 * remote-utils.c (look_up_one_symbol): Likewise.
5689 * server.c (queue_stop_reply): Likewise.
5690 (start_inferior): Likewise.
5691 (queue_stop_reply_callback): Likewise.
5692 (handle_target_event): Likewise.
5693 * spu-low.c (fetch_ppc_memory): Likewise.
5694 (store_ppc_memory): Likewise.
5695 * target.c (set_target_ops): Likewise.
5696 * thread-db.c (thread_db_load_search): Likewise.
5697 (try_thread_db_load_1): Likewise.
5698 * tracepoint.c (add_tracepoint): Likewise.
5699 (add_tracepoint_action): Likewise.
5700 (create_trace_state_variable): Likewise.
5701 (cmd_qtdpsrc): Likewise.
5702 (cmd_qtro): Likewise.
5703 (add_while_stepping_state): Likewise.
5704 * win32-low.c (child_add_thread): Likewise.
5705 (get_image_name): Likewise.
5706
5707 2015-08-25 Yao Qi <yao.qi@linaro.org>
5708
5709 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
5710
5711 2015-08-25 Yao Qi <yao.qi@linaro.org>
5712
5713 * Makefile.in (aarch64-linux.o): New rule.
5714 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
5715 srv_tgtobj.
5716 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
5717 (aarch64_init_debug_reg_state): Make it extern.
5718 (aarch64_linux_prepare_to_resume): Remove.
5719
5720 2015-08-25 Yao Qi <yao.qi@linaro.org>
5721
5722 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
5723 lwp_arch_private_info and ptid_of_lwp.
5724
5725 2015-08-25 Yao Qi <yao.qi@linaro.org>
5726
5727 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
5728 Find proc_info by find_process_pid. All callers updated.
5729
5730 2015-08-25 Yao Qi <yao.qi@linaro.org>
5731
5732 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
5733 Remove.
5734 (debug_reg_change_callback): Remove.
5735 (aarch64_notify_debug_reg_change): Remove.
5736
5737 2015-08-25 Yao Qi <yao.qi@linaro.org>
5738
5739 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
5740 Call current_lwp_ptid.
5741
5742 2015-08-25 Yao Qi <yao.qi@linaro.org>
5743
5744 * linux-aarch64-low.c (debug_reg_change_callback): Use
5745 debug_printf.
5746
5747 2015-08-25 Yao Qi <yao.qi@linaro.org>
5748
5749 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
5750
5751 2015-08-25 Yao Qi <yao.qi@linaro.org>
5752
5753 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
5754
5755 2015-08-25 Yao Qi <yao.qi@linaro.org>
5756
5757 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
5758 the code.
5759
5760 2015-08-25 Yao Qi <yao.qi@linaro.org>
5761
5762 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
5763 Remove.
5764 (debug_reg_change_callback): Remove argument entry and add argument
5765 lwp. Remove local variable thread. Don't print thread id in the
5766 debugging output. Don't check whether pid of thread equals to pid.
5767 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
5768 iterate_over_lwps instead find_inferior.
5769
5770 2015-08-24 Pedro Alves <palves@redhat.com>
5771
5772 * inferiors.c (get_first_process): New function.
5773 * inferiors.h (get_first_process): New declaration.
5774 * remote-utils.c (read_ptid): Default to the first process in the
5775 list, instead of to the current thread's process.
5776
5777 2015-08-24 Pedro Alves <palves@redhat.com>
5778
5779 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
5780 * event-loop.c: Likewise.
5781 * remote-utils.c: Likewise.
5782 * tracepoint.c: Likewise.
5783
5784 2015-08-24 Pedro Alves <palves@redhat.com>
5785
5786 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
5787 ptid_get_lwp.
5788
5789 2015-08-21 Pedro Alves <palves@redhat.com>
5790
5791 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
5792 instead of literal 1.
5793
5794 2015-08-21 Pedro Alves <palves@redhat.com>
5795
5796 * tdesc.c (default_description): Explicitly zero-initialize.
5797
5798 2015-08-21 Pedro Alves <palves@redhat.com>
5799
5800 PR gdb/18749
5801 * inferiors.c (remove_thread): Discard any pending stop reply for
5802 this thread.
5803 * server.c (remove_all_on_match_pid): Rename to ...
5804 (remove_all_on_match_ptid): ... this. Work with a filter ptid
5805 instead of a pid.
5806 (discard_queued_stop_replies): Change parameter to a ptid. Now
5807 extern.
5808 (handle_v_kill, kill_inferior_callback, captured_main)
5809 (process_serial_event): Adjust.
5810 * server.h (discard_queued_stop_replies): Declare.
5811
5812 2015-08-21 Pedro Alves <palves@redhat.com>
5813
5814 * linux-low.c (wait_for_sigstop): Always switch to no thread
5815 selected if the previously current thread dies.
5816 * lynx-low.c (lynx_request_interrupt): Use the first thread's
5817 process instead of the current thread's.
5818 * remote-utils.c (input_interrupt): Don't check if there's no
5819 current thread.
5820 * server.c (gdb_read_memory, gdb_write_memory): If setting the
5821 current thread to the general thread fails, error out.
5822 (handle_qxfer_auxv, handle_qxfer_libraries)
5823 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
5824 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
5825 (handle_query): Check if there's a thread selected instead of
5826 checking whether there's any thread in the thread list.
5827 (handle_qxfer_threads, handle_qxfer_btrace)
5828 (handle_qxfer_btrace_conf): Don't error out early if there's no
5829 thread in the thread list.
5830 (handle_v_cont, myresume): Don't set the current thread to the
5831 continue thread.
5832 (process_serial_event) <Hg handling>: Also set thread_id if the
5833 previous general thread is still alive.
5834 (process_serial_event) <g/G handling>: If setting the current
5835 thread to the general thread fails, error out.
5836 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
5837 thread's lwp instead of the current thread's.
5838 * target.c (set_desired_thread): If the desired thread was not
5839 found, leave the current thread pointing to NULL. Return an int
5840 (boolean) indicating success.
5841 * target.h (set_desired_thread): Change return type to int.
5842
5843 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
5844
5845 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
5846 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
5847 #includes.
5848 (ps_get_thread_area): New function.
5849
5850 2015-08-19 Gary Benson <gbenson@redhat.com>
5851
5852 * hostio.c (handle_pread): Do not attempt to read more data
5853 than hostio_reply_with_data can fit in a packet.
5854
5855 2015-08-18 Joel Brobecker <brobecker@adacore.com>
5856
5857 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
5858
5859 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
5860
5861 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
5862
5863 2015-08-06 Pedro Alves <palves@redhat.com>
5864
5865 * tracepoint.c (expr_eval_result): Now an int.
5866
5867 2015-08-06 Pedro Alves <palves@redhat.com>
5868
5869 * gdbthread.h (struct regcache): Forward declare.
5870 (struct thread_info) <regcache_data>: Now a struct regcache
5871 pointer.
5872 * inferiors.c (inferior_regcache_data)
5873 (set_inferior_regcache_data): Now work with struct regcache
5874 pointers.
5875 * inferiors.h (struct regcache): Forward declare.
5876 (inferior_regcache_data, set_inferior_regcache_data): Now work
5877 with struct regcache pointers.
5878 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
5879 (free_register_cache_thread): Remove struct regcache pointer
5880 casts.
5881
5882 2015-08-06 Pedro Alves <palves@redhat.com>
5883
5884 * server.c (captured_main): On error, print the exception message
5885 to stderr, and if run_once is set, throw a quit.
5886
5887 2015-08-06 Pedro Alves <palves@redhat.com>
5888
5889 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
5890 the current thread.
5891
5892 2015-08-06 Pedro Alves <palves@redhat.com>
5893
5894 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
5895 reading beyond the passed in buffer length.
5896
5897 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
5898
5899 * tracepoint.c (symbol_list) <required>: Remove.
5900
5901 2015-08-06 Pedro Alves <palves@redhat.com>
5902
5903 * linux-low.c (handle_extended_wait): Set the fork child's suspend
5904 count if stopping and suspending threads.
5905 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
5906 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
5907 (linux_detach): Complete an ongoing step-over.
5908 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
5909 throughout.
5910 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
5911 (linux_wait_1): If passing a signal to the inferior after
5912 finishing a step-over, unsuspend and re-resume all lwps. If we
5913 see a single-step event but the thread should be continuing, don't
5914 pass the trap to gdb.
5915 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
5916 internal_error instead of gdb_assert.
5917 (enqueue_pending_signal): New function.
5918 (check_ptrace_stopped_lwp_gone): Add debug output.
5919 (start_step_over): Use internal_error instead of gdb_assert.
5920 (complete_ongoing_step_over): New function.
5921 (linux_resume_one_thread): Don't resume a suspended thread.
5922 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
5923 it stepping.
5924
5925 2015-08-06 Pedro Alves <palves@redhat.com>
5926
5927 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
5928 (linux_thread_alive): Use lwp_is_marked_dead.
5929 (extended_event_reported): Delete.
5930 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
5931 instead of extended_event_reported.
5932 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
5933 as well.
5934 (lwp_is_marked_dead): New function.
5935 (lwp_running): Use lwp_is_marked_dead.
5936 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
5937 comment.
5938
5939 2015-08-06 Pedro Alves <palves@redhat.com>
5940
5941 * linux-low.c (linux_wait_1): Move fork event output out of the
5942 !report_to_gdb check. Pass event_child->waitstatus to
5943 target_waitstatus_to_string instead of ourstatus.
5944
5945 2015-08-04 Yao Qi <yao.qi@linaro.org>
5946
5947 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
5948 if current_thread is 32 bit.
5949
5950 2015-08-04 Yao Qi <yao.qi@linaro.org>
5951
5952 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
5953 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
5954 * server.c (extended_protocol): Remove "static".
5955 * server.h (extended_protocol): Declare it.
5956
5957 2015-08-04 Yao Qi <yao.qi@linaro.org>
5958
5959 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
5960 both aarch64 and aarch32.
5961 (aarch64_set_pc): Likewise.
5962
5963 2015-08-04 Yao Qi <yao.qi@linaro.org>
5964
5965 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
5966 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
5967 arm-with-neon.xml to srv_xmlfiles.
5968 * linux-aarch64-low.c: Include linux-aarch32-low.h.
5969 (is_64bit_tdesc): New function.
5970 (aarch64_linux_read_description): New function.
5971 (aarch64_arch_setup): Call aarch64_linux_read_description.
5972 (regs_info): Rename to regs_info_aarch64.
5973 (aarch64_regs_info): Return right regs_info.
5974 (initialize_low_arch): Call initialize_low_arch_aarch32.
5975
5976 2015-08-04 Yao Qi <yao.qi@linaro.org>
5977
5978 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
5979 * linux-aarch32-low.c: New file.
5980 * linux-aarch32-low.h: New file.
5981 * linux-arm-low.c (arm_fill_gregset): Move it to
5982 linux-aarch32-low.c.
5983 (arm_store_gregset): Likewise.
5984 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
5985 (arm_store_vfpregset): Call arm_store_vfpregset_num.
5986 (arm_arch_setup): Check if PTRACE_GETREGSET works.
5987 (regs_info): Rename to regs_info_arm.
5988 (arm_regs_info): Return regs_info_aarch32 if
5989 have_ptrace_getregset is 1 and target description is
5990 arm_with_neon or arm_with_vfpv3.
5991 (initialize_low_arch): Don't call init_registers_arm_with_neon.
5992 Call initialize_low_arch_aarch32 instead.
5993
5994 2015-08-04 Yao Qi <yao.qi@linaro.org>
5995
5996 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
5997 * linux-low.c: ... here.
5998 * linux-low.h (have_ptrace_getregset): Declare it.
5999
6000 2015-08-04 Pedro Alves <palves@redhat.com>
6001
6002 * thread-db.c (struct thread_db): Use new typedefs.
6003 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
6004 CHK calls.
6005 (disable_thread_event_reporting): Cast result of dlsym to
6006 destination function pointer type.
6007 (thread_db_mourn): Use td_ta_delete_ftype.
6008
6009 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
6010
6011 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
6012 arch variant.
6013 (CDX_BREAKPOINT): Define for R2.
6014 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
6015 (the_low_target): Add comments.
6016
6017 2015-07-30 Yao Qi <yao.qi@linaro.org>
6018
6019 * linux-arm-low.c (arm_hwcap): Remove it.
6020 (arm_read_description): New local variable arm_hwcap. Don't
6021 set arm_hwcap to zero.
6022
6023 2015-07-30 Yao Qi <yao.qi@linaro.org>
6024
6025 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
6026 Use regcache->tdesc instead.
6027 (arm_store_wmmxregset): Likewise.
6028 (arm_fill_vfpregset): Likewise.
6029 (arm_store_vfpregset): Likewise.
6030
6031 2015-07-30 Yao Qi <yao.qi@linaro.org>
6032
6033 * linux-arm-low.c: Include arch/arm.h.
6034 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
6035 (arm_store_gregset): Likewise.
6036
6037 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
6038
6039 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
6040 ptrace's 4th parameter.
6041
6042 2015-07-27 Yao Qi <yao.qi@linaro.org>
6043
6044 * configure.srv (case aarch64*-*-linux*): Don't set
6045 srv_linux_usrregs.
6046
6047 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
6048
6049 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
6050 sys/ptrace.h.
6051 * linux-arm-low.c: Likewise.
6052 * linux-cris-low.c: Likewise.
6053 * linux-crisv32-low.c: Likewise.
6054 * linux-low.c: Likewise.
6055 * linux-m68k-low.c: Likewise.
6056 * linux-mips-low.c: Likewise.
6057 * linux-nios2-low.c: Likewise.
6058 * linux-s390-low.c: Likewise.
6059 * linux-sparc-low.c: Likewise.
6060 * linux-tic6x-low.c: Likewise.
6061 * linux-tile-low.c: Likewise.
6062 * linux-x86-low.c: Likewise.
6063
6064 2015-07-24 Pedro Alves <palves@redhat.com>
6065
6066 * config.in: Regenerate.
6067 * configure: Regenerate.
6068
6069 2015-07-24 Pedro Alves <palves@redhat.com>
6070
6071 * acinclude.m4: Include ../ptrace.m4.
6072 * configure.ac: Call GDB_AC_PTRACE.
6073 * config.in, configure: Regenerate.
6074
6075 2015-07-24 Yao Qi <yao.qi@linaro.org>
6076
6077 * linux-low.c (linux_create_inferior): Remove setting to
6078 proc->priv->new_inferior.
6079 (linux_attach): Likewise.
6080 (linux_low_filter_event): Likewise.
6081 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
6082
6083 2015-07-24 Yao Qi <yao.qi@linaro.org>
6084
6085 * linux-low.c (linux_arch_setup): New function.
6086 (linux_low_filter_event): If proc->tdesc is NULL and
6087 proc->attached is true, call the_low_target.arch_setup.
6088 Otherwise, keep status pending, and return.
6089 (linux_resume_one_lwp_throw): Don't call get_pc if
6090 thread->while_stepping isn't NULL. Don't call
6091 get_thread_regcache if proc->tdesc is NULL.
6092 (need_step_over_p): Return 0 if proc->tdesc is NULL.
6093 (linux_target_ops): Install arch_setup.
6094 * server.c (start_inferior): Call the_target->arch_setup.
6095 * target.h (struct target_ops) <arch_setup>: New field.
6096 (target_arch_setup): New marco.
6097 * lynx-low.c (lynx_target_ops): Update.
6098 * nto-low.c (nto_target_ops): Update.
6099 * spu-low.c (spu_target_ops): Update.
6100 * win32-low.c (win32_target_ops): Update.
6101
6102 2015-07-24 Yao Qi <yao.qi@linaro.org>
6103
6104 * linux-low.c (linux_add_process): Don't set
6105 proc->priv->new_inferior.
6106 (linux_create_inferior): Set proc->priv->new_inferior to 1.
6107 (linux_attach): Likewise.
6108
6109 2015-07-24 Yao Qi <yao.qi@linaro.org>
6110
6111 * server.c (start_inferior): Code refactor.
6112
6113 2015-07-24 Yao Qi <yao.qi@linaro.org>
6114
6115 * server.c (process_serial_event): Set general_thread.
6116
6117 2015-07-21 Yao Qi <yao.qi@linaro.org>
6118
6119 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
6120 aarch64_linux_get_debug_reg_capacity.
6121
6122 2015-07-17 Yao Qi <yao.qi@linaro.org>
6123
6124 * Makefile.in (aarch64-linux-hw-point.o): New rule.
6125 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
6126 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
6127 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
6128 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
6129 (AARCH64_HWP_ALIGNMENT): Likewise.
6130 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
6131 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
6132 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
6133 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
6134 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
6135 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
6136 (struct aarch64_debug_reg_state): Likewise.
6137 (struct arch_lwp_info): Likewise.
6138 (aarch64_align_watchpoint): Likewise.
6139 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
6140 (aarch64_watchpoint_length): Likewise.
6141 (aarch64_point_encode_ctrl_reg): Likewise
6142 (aarch64_point_is_aligned): Likewise.
6143 (aarch64_align_watchpoint): Likewise.
6144 (aarch64_linux_set_debug_regs):
6145 (aarch64_dr_state_insert_one_point): Likewise.
6146 (aarch64_dr_state_remove_one_point): Likewise.
6147 (aarch64_handle_breakpoint): Likewise.
6148 (aarch64_handle_aligned_watchpoint): Likewise.
6149 (aarch64_handle_unaligned_watchpoint): Likewise.
6150 (aarch64_handle_watchpoint): Likewise.
6151
6152 2015-07-17 Yao Qi <yao.qi@linaro.org>
6153
6154 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
6155 and don't aarch64_get_debug_reg_state. All callers update.
6156 (aarch64_handle_aligned_watchpoint): Likewise.
6157 (aarch64_handle_unaligned_watchpoint): Likewise.
6158 (aarch64_handle_watchpoint): Likewise.
6159 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
6160 (aarch64_remove_point): Likewise.
6161
6162 2015-07-17 Yao Qi <yao.qi@linaro.org>
6163
6164 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
6165 debug_printf.
6166 (aarch64_handle_unaligned_watchpoint): Likewise.
6167
6168 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
6169
6170 Revert the previous 3 commits:
6171 Move gdb_regex* to common/
6172 Move linux_find_memory_regions_full & co.
6173 gdbserver build-id attribute generator
6174
6175 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6176 Jan Kratochvil <jan.kratochvil@redhat.com>
6177
6178 gdbserver build-id attribute generator.
6179 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
6180 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
6181 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
6182 (find_phdr): New.
6183 (get_dynamic): Use find_pdhr to traverse program headers.
6184 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
6185 (compare_mapping_entry_range, struct find_memory_region_callback_data)
6186 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
6187 (get_hex_build_id): New.
6188 (linux_qxfer_libraries_svr4): Add optional build-id attribute
6189 to reply XML document.
6190
6191 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6192 Jan Kratochvil <jan.kratochvil@redhat.com>
6193
6194 * target.c: Include target/target-utils.h and fcntl.h.
6195 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
6196 (target_fileio_read_stralloc): New functions.
6197
6198 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
6199
6200 * Makefile.in (OBS): Add gdb_regex.o.
6201 (gdb_regex.o): New.
6202 * config.in: Rebuilt.
6203 * configure: Rebuilt.
6204
6205 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6206 Jan Kratochvil <jan.kratochvil@redhat.com>
6207
6208 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
6209 * Makefile.in (OBS): Add target-utils.o.
6210 (linux-maps.o, target-utils.o): New.
6211 * configure.srv (srv_linux_obj): Add linux-maps.o.
6212
6213 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
6214
6215 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
6216 function, return 1.
6217 (the_low_target): Install it.
6218
6219 2015-07-14 Pedro Alves <palves@redhat.com>
6220
6221 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
6222 Instead, ignore ECHILD, and throw an error for other errnos.
6223
6224 2015-07-10 Pedro Alves <palves@redhat.com>
6225
6226 * event-loop.c (struct callback_event) <data>: Change type to
6227 gdb_client_data instance instead of gdb_client_data pointer.
6228 (append_callback_event): Adjust.
6229
6230 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
6231
6232 * linux-aarch64-low.c: Add comments for each linux_target_ops
6233 method. Remove comments already covered in target_ops and
6234 linux_target_ops definitions.
6235 (the_low_target): Add comments for each unimplemented method.
6236
6237 2015-07-09 Yao Qi <yao.qi@linaro.org>
6238
6239 * linux-aarch64-low.c (aarch64_regmap): Remove.
6240 (aarch64_usrregs_info): Remove.
6241 (regs_info): Set field usrregs to NULL.
6242
6243 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
6244
6245 * linux-low.c: Include "rsp-low.h"
6246 (linux_low_encode_pt_config, linux_low_encode_raw): New.
6247 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
6248 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
6249 (handle_btrace_enable_pt): New.
6250 (handle_btrace_general_set): Support "pt".
6251 (handle_btrace_conf_general_set): Support "pt:size".
6252
6253 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
6254
6255 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
6256 Z_PACKET_SW_BP.
6257
6258 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
6259
6260 * linux-aarch64-low.c: Remove comment about endianness.
6261 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
6262 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
6263 memcmp.
6264
6265 2015-06-24 Gary Benson <gbenson@redhat.com>
6266
6267 * linux-i386-ipa.c (stdint.h): Do not include.
6268 * lynx-i386-low.c (stdint.h): Likewise.
6269 * lynx-ppc-low.c (stdint.h): Likewise.
6270 * mem-break.c (stdint.h): Likewise.
6271 * thread-db.c (stdint.h): Likewise.
6272 * tracepoint.c (stdint.h): Likewise.
6273 * win32-low.c (stdint.h): Likewise.
6274
6275 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
6276
6277 * server.c (write_qxfer_response): Update call to
6278 remote_escape_output.
6279
6280 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
6281 Jan Kratochvil <jan.kratochvil@redhat.com>
6282
6283 Merge multiple hex conversions.
6284 * gdbreplay.c (tohex): Rename to 'fromhex'.
6285 (logchar): Use fromhex.
6286
6287 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
6288
6289 * server.c (handle_qxfer_libraries): Set `version' attribute for
6290 <library-list>.
6291
6292 2015-06-10 Gary Benson <gbenson@redhat.com>
6293
6294 * target.h (struct target_ops) <multifs_open>: New field.
6295 <multifs_unlink>: Likewise.
6296 <multifs_readlink>: Likewise.
6297 * linux-low.c (nat/linux-namespaces.h): New include.
6298 (linux_target_ops): Initialize the_target->multifs_open,
6299 the_target->multifs_unlink and the_target->multifs_readlink.
6300 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
6301 * hostio.c (hostio_fs_pid): New static variable.
6302 (hostio_handle_new_gdb_connection): New function.
6303 (handle_setfs): Likewise.
6304 (handle_open): Use the_target->multifs_open as appropriate.
6305 (handle_unlink): Use the_target->multifs_unlink as appropriate.
6306 (handle_readlink): Use the_target->multifs_readlink as
6307 appropriate.
6308 (handle_vFile): Handle vFile:setfs packets.
6309 * server.c (handle_query): Call hostio_handle_new_gdb_connection
6310 after target_handle_new_gdb_connection.
6311
6312 2015-06-10 Gary Benson <gbenson@redhat.com>
6313
6314 * configure.ac (AC_CHECK_FUNCS): Add setns.
6315 * config.in: Regenerate.
6316 * configure: Likewise.
6317 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
6318 (linux-namespaces.o): New rule.
6319 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
6320
6321 2015-06-09 Gary Benson <gbenson@redhat.com>
6322
6323 * hostio.c (handle_open): Process mode argument with
6324 fileio_to_host_mode.
6325
6326 2015-06-01 Yao Qi <yao.qi@linaro.org>
6327
6328 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
6329 * linux-x86-low.c: Likewise.
6330
6331 2015-05-28 Don Breazeal <donb@codesourcery.com>
6332
6333 * linux-low.c (handle_extended_wait): Initialize
6334 thread_info.last_resume_kind for new fork children.
6335
6336 2015-05-15 Pedro Alves <palves@redhat.com>
6337
6338 * target.h (target_handle_new_gdb_connection): Rewrite using if
6339 wrapped in do/while.
6340
6341 2015-05-14 Joel Brobecker <brobecker@adacore.com>
6342
6343 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
6344 * configure, config.in: Regenerate.
6345 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
6346 Declare typedef.
6347
6348 2015-05-12 Don Breazeal <donb@codesourcery.com>
6349
6350 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
6351 PTRACE_EVENT_VFORK_DONE.
6352 (linux_low_ptrace_options, extended_event_reported): Add vfork
6353 events.
6354 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
6355 and "vforkdone" for RSP 'T' Stop Reply Packet.
6356 * server.h (report_vfork_events): Declare
6357 global variable.
6358
6359 2015-05-12 Don Breazeal <donb@codesourcery.com>
6360
6361 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
6362 (the_low_target) <new_fork>: Initialize new member.
6363 * linux-arm-low.c (arm_new_fork): New function.
6364 (the_low_target) <new_fork>: Initialize new member.
6365 * linux-low.c (handle_extended_wait): Call new target function
6366 new_fork.
6367 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
6368 * linux-mips-low.c (mips_add_watchpoint): New function
6369 extracted from mips_insert_point.
6370 (the_low_target) <new_fork>: Initialize new member.
6371 (mips_linux_new_fork): New function.
6372 (mips_insert_point): Call mips_add_watchpoint.
6373 * linux-x86-low.c (x86_linux_new_fork): New function.
6374 (the_low_target) <new_fork>: Initialize new member.
6375
6376 2015-05-12 Don Breazeal <donb@codesourcery.com>
6377
6378 * linux-low.c (handle_extended_wait): Implement return value,
6379 rename argument 'event_child' to 'event_lwp', handle
6380 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
6381 (linux_low_ptrace_options): New function.
6382 (linux_low_filter_event): Call linux_low_ptrace_options,
6383 use different argument fo linux_enable_event_reporting,
6384 use return value from handle_extended_wait.
6385 (extended_event_reported): New function.
6386 (linux_wait_1): Call extended_event_reported and set
6387 status to report fork events.
6388 (linux_write_memory): Add pid to debug message.
6389 (reset_lwp_ptrace_options_callback): New function.
6390 (linux_handle_new_gdb_connection): New function.
6391 (linux_target_ops): Initialize new structure member.
6392 * linux-low.h (struct lwp_info) <waitstatus>: New member.
6393 * lynx-low.c: Initialize new structure member.
6394 * remote-utils.c (prepare_resume_reply): Implement stop reason
6395 "fork" for "T" stop message.
6396 * server.c (handle_query): Call handle_new_gdb_connection.
6397 * server.h (report_fork_events): Declare global flag.
6398 * target.h (struct target_ops) <handle_new_gdb_connection>:
6399 New member.
6400 (target_handle_new_gdb_connection): New macro.
6401 * win32-low.c: Initialize new structure member.
6402
6403 2015-05-12 Don Breazeal <donb@codesourcery.com>
6404
6405 * mem-break.c (APPEND_TO_LIST): Define macro.
6406 (clone_agent_expr): New function.
6407 (clone_one_breakpoint): New function.
6408 (clone_all_breakpoints): New function.
6409 * mem-break.h: Declare new functions.
6410
6411 2015-05-12 Don Breazeal <donb@codesourcery.com>
6412
6413 * linux-low.c (linux_supports_fork_events): New function.
6414 (linux_supports_vfork_events): New function.
6415 (linux_target_ops): Initialize new structure members.
6416 (initialize_low): Call linux_check_ptrace_features.
6417 * lynx-low.c (lynx_target_ops): Initialize new structure
6418 members.
6419 * server.c (report_fork_events, report_vfork_events):
6420 New global flags.
6421 (handle_query): Add new features to qSupported packet and
6422 response.
6423 (captured_main): Initialize new global variables.
6424 * target.h (struct target_ops) <supports_fork_events>:
6425 New member.
6426 <supports_vfork_events>: New member.
6427 (target_supports_fork_events): New macro.
6428 (target_supports_vfork_events): New macro.
6429 * win32-low.c (win32_target_ops): Initialize new structure
6430 members.
6431
6432 2015-05-12 Gary Benson <gbenson@redhat.com>
6433
6434 * server.c (handle_qxfer_exec_file): Use current process
6435 if annex is empty.
6436
6437 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
6438
6439 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
6440 Remove HAVE_PTRACE_GETREGS conditionals.
6441 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
6442 instead of PTRACE_GETREGS and PTRACE_SETREGS.
6443
6444 2015-05-08 Yao Qi <yao.qi@linaro.org>
6445
6446 * linux-low.c (linux_supports_conditional_breakpoints): New
6447 function.
6448 (linux_target_ops): Install new target method.
6449 * lynx-low.c (lynx_target_ops): Install NULL hook for
6450 supports_conditional_breakpoints.
6451 * nto-low.c (nto_target_ops): Likewise.
6452 * spu-low.c (spu_target_ops): Likewise.
6453 * win32-low.c (win32_target_ops): Likewise.
6454 * server.c (handle_query): Check
6455 target_supports_conditional_breakpoints.
6456 * target.h (struct target_ops) <supports_conditional_breakpoints>:
6457 New field.
6458 (target_supports_conditional_breakpoints): New macro.
6459
6460 2015-05-06 Pedro Alves <palves@redhat.com>
6461
6462 PR server/18081
6463 * server.c (start_inferior): If the process exits, mourn it.
6464
6465 2015-04-21 Gary Benson <gbenson@redhat.com>
6466
6467 * hostio.c (fileio_open_flags_to_host): Factored out to
6468 fileio_to_host_openflags in common/fileio.c. Single use
6469 updated.
6470
6471 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
6472
6473 * linux-xtensa-low.c (xtensa_fill_gregset)
6474 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
6475 XCHAL_HAVE_LOOP.
6476
6477 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
6478
6479 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
6480 (regs_info): Replace usrregs pointer with NULL.
6481
6482 2015-04-17 Gary Benson <gbenson@redhat.com>
6483
6484 * target.h (struct target_ops) <pid_to_exec_file>: New field.
6485 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
6486 * server.c (handle_qxfer_exec_file): New function.
6487 (qxfer_packets): Add exec-file entry.
6488 (handle_query): Report qXfer:exec-file:read as supported packet.
6489
6490 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
6491
6492 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
6493
6494 2015-04-09 Gary Benson <gbenson@redhat.com>
6495
6496 * hostio-errno.c (errno_to_fileio_error): Remove function.
6497 Update caller to use remote_fileio_to_fio_error.
6498
6499 2015-04-09 Yao Qi <yao.qi@linaro.org>
6500
6501 * linux-low.c (linux_insert_point): Call
6502 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
6503 (linux_remove_point): Call remove_memory_breakpoint if type is
6504 raw_bkpt_type_sw.
6505 * linux-x86-low.c (x86_insert_point): Don't call
6506 insert_memory_breakpoint.
6507 (x86_remove_point): Don't call remove_memory_breakpoint.
6508
6509 2015-04-01 Pedro Alves <palves@redhat.com>
6510 Cleber Rosa <crosa@redhat.com>
6511
6512 * server.c (gdbserver_usage): Reorganize and extend the usage
6513 message.
6514
6515 2015-03-24 Pedro Alves <palves@redhat.com>
6516
6517 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
6518 output. Also dump TRAP_TRACE.
6519 (linux_low_filter_event): In debug output, distinguish a
6520 resume_stop SIGSTOP from a delayed SIGSTOP.
6521
6522 2015-03-24 Gary Benson <gbenson@redhat.com>
6523
6524 * linux-x86-low.c (x86_linux_new_thread): Moved to
6525 nat/x86-linux.c.
6526 (x86_linux_prepare_to_resume): Likewise.
6527
6528 2015-03-24 Gary Benson <gbenson@redhat.com>
6529
6530 * Makefile.in (x86-linux-dregs.o): New rule.
6531 * configure.srv: Add x86-linux-dregs.o to relevant targets.
6532 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
6533 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
6534 (x86_linux_dr_get): Likewise.
6535 (x86_linux_dr_set): Likewise.
6536 (update_debug_registers_callback): Likewise.
6537 (x86_linux_dr_set_addr): Likewise.
6538 (x86_linux_dr_get_addr): Likewise.
6539 (x86_linux_dr_set_control): Likewise.
6540 (x86_linux_dr_get_control): Likewise.
6541 (x86_linux_dr_get_status): Likewise.
6542 (x86_linux_update_debug_registers): Likewise.
6543
6544 2015-03-24 Gary Benson <gbenson@redhat.com>
6545
6546 * linux-x86-low.c (x86_linux_update_debug_registers):
6547 New function, factored out from...
6548 (x86_linux_prepare_to_resume): ...this.
6549
6550 2015-03-24 Gary Benson <gbenson@redhat.com>
6551
6552 * linux-x86-low.c (x86_linux_dr_get): Update comments.
6553 (x86_linux_dr_set): Likewise.
6554 (update_debug_registers_callback): Likewise.
6555 (x86_linux_dr_set_addr): Likewise.
6556 (x86_linux_dr_get_addr): Likewise.
6557 (x86_linux_dr_set_control): Likewise.
6558 (x86_linux_dr_get_control): Likewise.
6559 (x86_linux_dr_get_status): Likewise.
6560 (x86_linux_prepare_to_resume): Likewise.
6561
6562 2015-03-24 Gary Benson <gbenson@redhat.com>
6563
6564 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
6565 Use perror_with_name. Pass string through gettext.
6566 (x86_linux_dr_set): Likewise.
6567
6568 2015-03-24 Gary Benson <gbenson@redhat.com>
6569
6570 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
6571 (x86_linux_dr_set_addr): ...this.
6572 (x86_dr_low_get_addr): Rename to...
6573 (x86_linux_dr_get_addr): ...this.
6574 (x86_dr_low_set_control): Rename to...
6575 (x86_linux_dr_set_control): ...this.
6576 (x86_dr_low_get_control): Rename to...
6577 (x86_linux_dr_get_control): ...this.
6578 (x86_dr_low_get_status): Rename to...
6579 (x86_linux_dr_get_status): ...this.
6580 (x86_dr_low): Update with new function names.
6581
6582 2015-03-24 Gary Benson <gbenson@redhat.com>
6583
6584 * Makefile.in (x86-linux.o): New rule.
6585 * configure.srv: Add x86-linux.o to relevant targets.
6586 * linux-low.c (lwp_set_arch_private_info): New function.
6587 (lwp_arch_private_info): Likewise.
6588 * linux-x86-low.c: Include nat/x86-linux.h.
6589 (arch_lwp_info): Removed structure.
6590 (update_debug_registers_callback):
6591 Use lwp_set_debug_registers_changed.
6592 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
6593 and lwp_set_debug_registers_changed.
6594 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
6595
6596 2015-03-24 Gary Benson <gbenson@redhat.com>
6597
6598 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
6599 * linux-arm-low.c (arm_new_thread): Likewise.
6600 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
6601 * linux-mips-low.c (mips_linux_new_thread): Likewise.
6602 * linux-x86-low.c (x86_linux_new_thread): Likewise.
6603 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
6604
6605 2015-03-24 Gary Benson <gbenson@redhat.com>
6606
6607 * linux-low.c (ptid_of_lwp): New function.
6608 (lwp_is_stopped): Likewise.
6609 (lwp_stop_reason): Likewise.
6610 * linux-x86-low.c (update_debug_registers_callback):
6611 Use lwp_is_stopped.
6612 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
6613 lwp_stop_reason.
6614
6615 2015-03-24 Gary Benson <gbenson@redhat.com>
6616
6617 * linux-low.h (linux_stop_lwp): Remove declaration.
6618
6619 2015-03-24 Gary Benson <gbenson@redhat.com>
6620
6621 * linux-low.h: Include nat/linux-nat.h.
6622 * linux-low.c (iterate_over_lwps_args): New structure.
6623 (iterate_over_lwps_filter): New function.
6624 (iterate_over_lwps): Likewise.
6625 * linux-x86-low.c (update_debug_registers_callback):
6626 Update signature to what iterate_over_lwps expects.
6627 Remove PID check that iterate_over_lwps now performs.
6628 (x86_dr_low_set_addr): Use iterate_over_lwps.
6629 (x86_dr_low_set_control): Likewise.
6630
6631 2015-03-24 Gary Benson <gbenson@redhat.com>
6632
6633 * linux-x86-low.c (x86_debug_reg_state): New function.
6634 (x86_linux_prepare_to_resume): Use the above.
6635
6636 2015-03-24 Gary Benson <gbenson@redhat.com>
6637
6638 * linux-low.c (current_lwp_ptid): New function.
6639 * linux-x86-low.c: Include nat/linux-nat.h.
6640 (x86_dr_low_get_addr): Use current_lwp_ptid.
6641 (x86_dr_low_get_control): Likewise.
6642 (x86_dr_low_get_status): Likewise.
6643
6644 2015-03-20 Pedro Alves <palves@redhat.com>
6645
6646 * tracepoint.c (cmd_qtstatus): Make "str" const.
6647
6648 2015-03-20 Pedro Alves <palves@redhat.com>
6649
6650 * server.c (handle_general_set): Make "req_str" const.
6651
6652 2015-03-19 Pedro Alves <palves@redhat.com>
6653
6654 * linux-low.c (linux_resume_one_lwp): Rename to ...
6655 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
6656 instead call perror_with_name.
6657 (check_ptrace_stopped_lwp_gone): New function.
6658 (linux_resume_one_lwp): Reimplement as wrapper around
6659 linux_resume_one_lwp_throw that swallows errors if the LWP is
6660 gone.
6661
6662 2015-03-19 Pedro Alves <palves@redhat.com>
6663
6664 * linux-low.c (count_events_callback, select_event_lwp_callback):
6665 No longer check whether the thread has resume_stop as last resume
6666 kind.
6667
6668 2015-03-19 Pedro Alves <palves@redhat.com>
6669
6670 * linux-low.c (count_events_callback, select_event_lwp_callback):
6671 Use the lwp's status_pending_p field, not the thread's.
6672
6673 2015-03-19 Pedro Alves <palves@redhat.com>
6674
6675 * linux-low.c (select_event_lwp_callback): Update comments to
6676 no longer mention SIGTRAP.
6677
6678 2015-03-18 Gary Benson <gbenson@redhat.com>
6679
6680 * server.c (handle_query): Do not report vFile:fstat as supported.
6681
6682 2015-03-11 Gary Benson <gbenson@redhat.com>
6683
6684 * hostio.c (sys/types.h): New include.
6685 (sys/stat.h): Likewise.
6686 (common-remote-fileio.h): Likewise.
6687 (handle_fstat): New function.
6688 (handle_vFile): Handle vFile:fstat packets.
6689
6690 2015-03-11 Gary Benson <gbenson@redhat.com>
6691
6692 * configure.ac (AC_CHECK_MEMBERS): Add checks for
6693 struct stat.st_blocks and struct stat.st_blksize.
6694 * configure: Regenerate.
6695 * config.in: Likewise.
6696 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
6697 (OBS): Add common-remote-fileio.o.
6698 (common-remote-fileio.o): New rule.
6699
6700 2015-03-09 Pedro Alves <palves@redhat.com>
6701
6702 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
6703 'struct sockaddr' pointer in 'accept' call.
6704
6705 2015-03-09 Pedro Alves <palves@redhat.com>
6706
6707 Revert:
6708 2015-03-07 Pedro Alves <palves@redhat.com>
6709 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
6710 or <winsock2.h> here. Instead include "gdb_socket.h".
6711 (remote_open): Use union gdb_sockaddr_u.
6712 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
6713 or <winsock2.h> here. Instead include "gdb_socket.h".
6714 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
6715 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
6716 or <sys/un.h>.
6717 (init_named_socket, gdb_agent_helper_thread): Use union
6718 gdb_sockaddr_u.
6719
6720 2015-03-07 Pedro Alves <palves@redhat.com>
6721
6722 * configure.ac (build_warnings): Move
6723 -Wdeclaration-after-statement to the C-specific set.
6724 * configure: Regenerate.
6725
6726 2015-03-07 Pedro Alves <palves@redhat.com>
6727
6728 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
6729 or <winsock2.h> here. Instead include "gdb_socket.h".
6730 (remote_open): Use union gdb_sockaddr_u.
6731 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
6732 or <winsock2.h> here. Instead include "gdb_socket.h".
6733 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
6734 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
6735 or <sys/un.h>.
6736 (init_named_socket, gdb_agent_helper_thread): Use union
6737 gdb_sockaddr_u.
6738
6739 2015-03-07 Pedro Alves <palves@redhat.com>
6740
6741 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
6742 instead.
6743
6744 2015-03-06 Yao Qi <yao.qi@linaro.org>
6745
6746 * linux-aarch64-low.c (aarch64_insert_point): Use
6747 show_debug_regs as a boolean.
6748 (aarch64_remove_point): Likewise.
6749
6750 2015-03-05 Pedro Alves <palves@redhat.com>
6751
6752 * lynx-low.c (lynx_target_ops): Install NULL hooks for
6753 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
6754 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
6755 * nto-low.c (nto_target_ops): Likewise.
6756 * spu-low.c (spu_target_ops): Likewise.
6757 * win32-low.c (win32_target_ops): Likewise.
6758
6759 2015-03-04 Pedro Alves <palves@redhat.com>
6760
6761 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
6762 Decide whether a breakpoint triggered based on the SIGTRAP's
6763 siginfo.si_code.
6764 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
6765 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
6766 (linux_low_filter_event): Check for breakpoints before checking
6767 watchpoints.
6768 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
6769 siginfo.si_code.
6770 (linux_stopped_by_sw_breakpoint)
6771 (linux_supports_stopped_by_sw_breakpoint)
6772 (linux_stopped_by_hw_breakpoint)
6773 (linux_supports_stopped_by_hw_breakpoint): New functions.
6774 (linux_target_ops): Install new target methods.
6775
6776 2015-03-04 Pedro Alves <palves@redhat.com>
6777
6778 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
6779 * server.c (swbreak_feature, hwbreak_feature): New globals.
6780 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
6781 (captured_main): Clear swbreak_feature and hwbreak_feature.
6782 * server.h (swbreak_feature, hwbreak_feature): Declare.
6783 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
6784 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
6785 supports_stopped_by_hw_breakpoint>: New fields.
6786 (target_supports_stopped_by_sw_breakpoint)
6787 (target_stopped_by_sw_breakpoint)
6788 (target_supports_stopped_by_hw_breakpoint)
6789 (target_stopped_by_hw_breakpoint): Declare.
6790
6791 2015-03-04 Pedro Alves <palves@redhat.com>
6792
6793 enum lwp_stop_reason -> enum target_stop_reason
6794 * linux-low.c (check_stopped_by_breakpoint): Adjust.
6795 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
6796 (linux_wait_1, stuck_in_jump_pad_callback)
6797 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
6798 (linux_stopped_by_watchpoint):
6799 * linux-low.h (enum lwp_stop_reason): Delete.
6800 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
6801 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
6802
6803 2015-03-04 Yao Qi <yao.qi@linaro.org>
6804
6805 * Makefile.in (SFILES): Add linux-aarch64-low.c.
6806
6807 2015-03-03 Gary Benson <gbenson@redhat.com>
6808
6809 * hostio.c (handle_vFile): Fix prefix lengths.
6810
6811 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
6812
6813 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
6814 ptr_bits.
6815
6816 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
6817
6818 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
6819 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
6820 (clean): Add "rm -f" for above C files.
6821 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
6822 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
6823 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
6824 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
6825 * linux-s390-low.c (HWCAP_S390_VX): New macro.
6826 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
6827 (init_registers_s390x_vx_linux64)
6828 (init_registers_s390x_tevx_linux64)
6829 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
6830 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
6831 declarations.
6832 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
6833 (s390_store_vxrs_high): New functions.
6834 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
6835 NT_S390_VXRS_HIGH.
6836 (s390_arch_setup): Add logic for selecting one of the new target
6837 descriptions. Activate the new vector regsets if applicable.
6838 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
6839 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
6840 and init_registers_s390x_tevx_linux64.
6841
6842 2015-03-01 Pedro Alves <palves@redhat.com>
6843
6844 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
6845 parameter.
6846
6847 2015-02-27 Pedro Alves <palves@redhat.com>
6848
6849 * linux-x86-low.c (u_debugreg_offset): New function.
6850 (x86_linux_dr_get, x86_linux_dr_set): Use it.
6851
6852 2015-02-27 Pedro Alves <palves@redhat.com>
6853
6854 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
6855 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
6856 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
6857 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
6858 (ps_lsetfpregs, ps_getpid)
6859 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
6860 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
6861 (ps_lsetxregs, ps_plog): Declare.
6862
6863 2015-02-27 Pedro Alves <palves@redhat.com>
6864
6865 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
6866 IP_AGENT_EXPORT_FUNC.
6867 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
6868 IP_AGENT_EXPORT_FUNC.
6869 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
6870 (IP_AGENT_EXPORT): Delete.
6871 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
6872 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
6873 (gdb_trampoline_buffer_error, collecting, gdb_collect)
6874 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
6875 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
6876 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
6877 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
6878 (traceframe_read_count, traceframe_write_count)
6879 (traceframes_created, trace_state_variables, get_raw_reg)
6880 (get_trace_state_variable_value, set_trace_state_variable_value)
6881 (ust_loaded, helper_thread_id, cmd_buf): Use
6882 IPA_SYM_EXPORTED_NAME.
6883 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
6884 (tracepoints) Use IP_AGENT_EXPORT_VAR.
6885 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
6886 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
6887 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
6888 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
6889 EXTERN_C_PUSH/EXTERN_C_POP.
6890 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
6891 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
6892 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
6893 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
6894 (traceframe_write_count, traceframe_read_count)
6895 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
6896 (about_to_request_buffer_space, get_trace_state_variable_value)
6897 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
6898 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
6899 EXTERN_C_PUSH/EXTERN_C_POP.
6900 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
6901 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
6902 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
6903 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
6904 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
6905 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
6906 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
6907 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
6908 Define.
6909 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
6910 (IP_AGENT_EXPORT_VAR_DECL): Define.
6911 (tracing): Declare.
6912 (gdb_agent_get_raw_reg): Declare.
6913
6914 2015-02-27 Tom Tromey <tromey@redhat.com>
6915 Pedro Alves <palves@redhat.com>
6916
6917 Rename symbols whose names are reserved C++ keywords throughout.
6918
6919 2015-02-27 Pedro Alves <palves@redhat.com>
6920
6921 * Makefile.in (COMPILER): New, get it from autoconf.
6922 (CXX): Get from autoconf instead.
6923 (COMPILE.pre): Use COMPILER.
6924 (CC-LD): Rename to ...
6925 (CC_LD): ... this. Use COMPILER.
6926 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
6927 (CXX_FOR_TARGET): Default to g++ instead of gcc.
6928 * acinclude.m4: Include build-with-cxx.m4.
6929 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
6930 Disable -Werror by default if building in C++ mode.
6931 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
6932 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
6933 the C++ compiler. Save/restore CXXFLAGS too.
6934 * configure: Regenerate.
6935
6936 2015-02-27 Pedro Alves <palves@redhat.com>
6937
6938 * acinclude.m4: Include libiberty.m4.
6939 * configure.ac: Call libiberty_INIT.
6940 * config.in, configure: Regenerate.
6941
6942 2015-02-26 Pedro Alves <palves@redhat.com>
6943
6944 * linux-low.c (linux_wait_1): When incrementing the PC past a
6945 program breakpoint always use the_low_target.breakpoint_len as
6946 increment, rather than the maximum between that and
6947 the_low_target.decr_pc_after_break.
6948
6949 2015-02-23 Pedro Alves <palves@redhat.com>
6950
6951 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
6952 thread was doing a step-over; always adjust the PC if
6953 we stepped over a permanent breakpoint.
6954 (linux_wait_1): If we stepped over breakpoint that was on top of a
6955 permanent breakpoint, manually advance the PC past it.
6956
6957 2015-02-23 Pedro Alves <palves@redhat.com>
6958
6959 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
6960 modes.
6961 (x86_fill_gregset, x86_store_gregset): Use it when handling
6962 $orig_eax.
6963
6964 2015-02-20 Pedro Alves <palves@redhat.com>
6965
6966 * thread-db.c: Include "nat/linux-procfs.h".
6967 (thread_db_init): Skip listing new threads if the kernel supports
6968 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
6969
6970 2015-02-20 Pedro Alves <palves@redhat.com>
6971
6972 * linux-low.c (status_pending_p_callback): Use ptid_match.
6973
6974 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
6975
6976 PR breakpoints/16812
6977 * linux-low.c (wstatus_maybe_breakpoint): Remove.
6978 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
6979 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
6980
6981 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
6982
6983 PR breakpoints/15956
6984 * tracepoint.c (cmd_qtinit): Add check for current_thread.
6985
6986 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
6987
6988 * linux-low.c (linux_low_btrace_conf): Print size.
6989 * server.c (handle_btrace_conf_general_set): New.
6990 (hanle_general_set): Call handle_btrace_conf_general_set.
6991 (handle_query): Report Qbtrace-conf:bts:size as supported.
6992
6993 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
6994
6995 * linux-low.c (linux_low_enable_btrace): Update parameters.
6996 (linux_low_btrace_conf): New.
6997 (linux_target_ops)<to_btrace_conf>: Initialize.
6998 * server.c (current_btrace_conf): New.
6999 (handle_btrace_enable): Rename to ...
7000 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
7001 to target_enable_btrace. Update comment. Update users.
7002 (handle_qxfer_btrace_conf): New.
7003 (qxfer_packets): Add btrace-conf entry.
7004 (handle_query): Report qXfer:btrace-conf:read as supported packet.
7005 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
7006 (target_ops)<read_btrace_conf>: New.
7007 (target_enable_btrace): Update parameters.
7008 (target_read_btrace_conf): New.
7009
7010 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7011
7012 * server.c (handle_btrace_general_set): Remove call to
7013 target_supports_btrace.
7014 (supported_btrace_packets): New.
7015 (handle_query): Call supported_btrace_packets.
7016 * target.h: include btrace-common.h.
7017 (btrace_target_info): Removed.
7018 (supports_btrace, target_supports_btrace): Update parameters.
7019
7020 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7021
7022 * Makefile.in (SFILES): Add common/btrace-common.c.
7023 (OBS): Add common/btrace-common.o.
7024 (btrace-common.o): Add build rules.
7025 * linux-low: Include btrace-common.h.
7026 (linux_low_read_btrace): Use struct btrace_data. Call
7027 btrace_data_init and btrace_data_fini.
7028
7029 2015-02-06 Pedro Alves <palves@redhat.com>
7030
7031 * thread-db.c (find_new_threads_callback): Add debug output.
7032
7033 2015-02-04 Pedro Alves <palves@redhat.com>
7034
7035 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
7036 (resume_stopped_resumed_lwps): New function.
7037 (linux_wait_for_event_filtered): Use it.
7038
7039 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
7040
7041 * Makefile.in (SFILES): Add linux-personality.c.
7042 (linux-personality.o): New rule.
7043 * configure.srv (srv_linux_obj): Add linux-personality.o to the
7044 list of objects to be built.
7045 * linux-low.c: Include nat/linux-personality.h.
7046 (linux_create_inferior): Remove code to disable address space
7047 randomization (moved to ../nat/linux-personality.c). Create
7048 cleanup to disable address space randomization.
7049
7050 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
7051
7052 * Makefile.in (posix-strerror.o): New rule.
7053 (mingw-strerror.o): Likewise.
7054 * configure: Regenerated.
7055 * configure.ac: Source file ../common/common.host. Initialize new
7056 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
7057
7058 2015-01-14 Yao Qi <yao@codesourcery.com>
7059
7060 * Makefile.in (SFILES): Add nat/ppc-linux.c.
7061 (ppc-linux.o): New rule.
7062 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
7063 * configure.ac: AC_CHECK_FUNCS(getauxval).
7064 * config.in: Re-generated.
7065 * configure: Re-generated.
7066 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
7067 ppc64_64bit_inferior_p
7068
7069 2015-01-14 Yao Qi <yao@codesourcery.com>
7070
7071 * linux-ppc-low.c: Include "nat/ppc-linux.h".
7072 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
7073 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
7074 (PT_ORIG_R3, PT_TRAP): Likewise.
7075 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
7076 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
7077 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
7078
7079 2015-01-10 Joel Brobecker <brobecker@adacore.com>
7080
7081 * i387-fp.c (i387_cache_to_xsave): In look over
7082 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
7083 zmmh_low_space field by use of zmmh_high_space.
7084
7085 2015-01-09 Pedro Alves <palves@redhat.com>
7086
7087 * linux-low.c (step_over_bkpt): Move higher up in the file.
7088 (handle_extended_wait): Don't store the stop_pc here.
7089 (get_stop_pc): Adjust comments and rename to ...
7090 (check_stopped_by_breakpoint): ... this. Record whether the LWP
7091 stopped for a software breakpoint or hardware breakpoint.
7092 (thread_still_has_status_pending_p): New function.
7093 (status_pending_p_callback): Use
7094 thread_still_has_status_pending_p. If the event is no longer
7095 interesting, resume the LWP.
7096 (handle_tracepoints): Add assert.
7097 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
7098 (wstatus_maybe_breakpoint): New function.
7099 (cancel_breakpoint): Delete function.
7100 (check_stopped_by_watchpoint): New function, factored out from
7101 linux_low_filter_event.
7102 (lp_status_maybe_breakpoint): Delete function.
7103 (linux_low_filter_event): Remove filter_ptid argument.
7104 Leave thread group exits pending here. Store the LWP's stop PC.
7105 Always leave events pending.
7106 (linux_wait_for_event_filtered): Pull all events out of the
7107 kernel, and leave them all pending.
7108 (count_events_callback, select_event_lwp_callback): Consider all
7109 events.
7110 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
7111 (select_event_lwp): Only give preference to the stepping LWP in
7112 all-stop mode. Adjust comments.
7113 (ignore_event): New function.
7114 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
7115 references to cancel_breakpoints. Adjust to renames. Also give
7116 equal priority to all LWPs that have had events in non-stop mode.
7117 If reporting a software breakpoint event, unadjust the LWP's PC.
7118 (linux_wait): If linux_wait_1 returned an ignored event, retry.
7119 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
7120 Adjust.
7121 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
7122 (resume_status_pending_p): Use thread_still_has_status_pending_p.
7123 (linux_stopped_by_watchpoint): Adjust.
7124 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
7125 * linux-low.h (enum lwp_stop_reason): New.
7126 (struct lwp_info) <stop_pc>: Adjust comment.
7127 <stopped_by_watchpoint>: Delete field.
7128 <stop_reason>: New field.
7129 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
7130 * mem-break.c (software_breakpoint_inserted_here)
7131 (hardware_breakpoint_inserted_here): New function.
7132 * mem-break.h (software_breakpoint_inserted_here)
7133 (hardware_breakpoint_inserted_here): Declare.
7134 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
7135 (cancel_breakpoints): Delete.
7136 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
7137 (upload_fast_traceframes): Remove references to
7138 cancel_breakpoints.
7139
7140 2015-01-09 Pedro Alves <palves@redhat.com>
7141
7142 * thread-db.c (find_new_threads_callback): Ignore thread if the
7143 kernel thread ID is -1.
7144
7145 2015-01-09 Pedro Alves <palves@redhat.com>
7146
7147 * linux-low.c (linux_attach_fail_reason_string): Move to
7148 nat/linux-ptrace.c, and rename.
7149 (linux_attach_lwp): Update comment.
7150 (attach_proc_task_lwp_callback): New function.
7151 (linux_attach): Adjust to rename and use
7152 linux_proc_attach_tgid_threads.
7153 (linux_attach_fail_reason_string): Delete declaration.
7154
7155 2015-01-01 Joel Brobecker <brobecker@adacore.com>
7156
7157 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
7158 * server.c (gdbserver_version): Likewise.
7159
7160 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
7161
7162 * remote-utils.c: Include ctype.h.
7163 (input_interrupt): Explicitly handle the case when the char
7164 received is the NUL byte. Improve the printing of non-ASCII
7165 characters.
7166
7167 2014-12-16 Joel Brobecker <brobecker@adacore.com>
7168
7169 * linux-low.c (linux_low_filter_event): Update call to
7170 linux_enable_event_reporting following the addition of
7171 a new parameter to that function.
7172
7173 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
7174
7175 PR server/17457
7176 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
7177 (AARCH64_FPCR_REGNO): Likewise.
7178 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
7179 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
7180 (aarch64_store_fpregset): Likewise.
7181
7182 2014-12-15 Joel Brobecker <brobecker@adacore.com>
7183
7184 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
7185 Remove FIXME comment about assumption about N.
7186
7187 2014-12-13 Joel Brobecker <brobecker@adacore.com>
7188
7189 * configure.ac: If large-file support is disabled in GDBserver,
7190 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
7191 * configure: Regenerate.
7192
7193 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7194
7195 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
7196 warning upon ENODATA from ptrace.
7197 * linux-s390-low.c (s390_store_tdb): New.
7198 (s390_regsets): Add regset for NT_S390_TDB.
7199
7200 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7201
7202 * linux-low.c (regsets_store_inferior_registers): Skip regsets
7203 without a fill_function.
7204 * linux-s390-low.c (s390_fill_last_break): Remove.
7205 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
7206 (s390_arch_setup): Use regset's size instead of fill_function for
7207 loop end condition.
7208
7209 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7210
7211 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
7212 the regset's store function when ptrace returned an error.
7213 * regcache.c (get_thread_regcache): Invalidate register cache
7214 before fetching inferior's registers.
7215
7216 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7217
7218 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
7219 while-loop as for-loop.
7220 (regsets_store_inferior_registers): Likewise.
7221
7222 2014-11-28 Yao Qi <yao@codesourcery.com>
7223
7224 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
7225 * config.in, configure: Re-generate.
7226 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
7227 is defined.
7228
7229 2014-11-21 Yao Qi <yao@codesourcery.com>
7230
7231 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
7232 (AC_CHECK_HEADERS): Remove malloc.h.
7233 * configure: Re-generated.
7234 * config.in: Re-generated.
7235 * server.h: Don't include alloca.h and malloc.h.
7236 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
7237 Don't include malloc.h.
7238
7239 2014-11-17 Joel Brobecker <brobecker@adacore.com>
7240
7241 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
7242 corresponding ERRNO check in same block.
7243
7244 2014-11-12 Pedro Alves <palves@redhat.com>
7245
7246 * server.c (cont_thread): Update comment.
7247 (start_inferior, attach_inferior): No longer clear cont_thread.
7248 (handle_v_cont): No longer set cont_thread.
7249 (captured_main): Clear cont_thread each time a GDB connects.
7250
7251 2014-11-12 Pedro Alves <palves@redhat.com>
7252
7253 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
7254 thread, and don't resume all threads if the Hc thread has exited.
7255
7256 2014-11-12 Pedro Alves <palves@redhat.com>
7257
7258 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
7259 the process group instead of to a specific LWP.
7260
7261 2014-10-15 Pedro Alves <palves@redhat.com>
7262
7263 PR server/17487
7264 * win32-arm-low.c (arm_set_thread_context): Remove current_event
7265 parameter.
7266 (arm_set_thread_context): Delete.
7267 (the_low_target): Adjust.
7268 * win32-i386-low.c (debug_registers_changed)
7269 (debug_registers_used): Delete.
7270 (update_debug_registers_callback): New function.
7271 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
7272 needing to update their debug registers.
7273 (win32_get_current_dr): New function.
7274 (x86_dr_low_get_addr, x86_dr_low_get_control)
7275 (x86_dr_low_get_status): Fetch the debug register from the thread
7276 record's context.
7277 (i386_initial_stuff): Adjust.
7278 (i386_get_thread_context): Remove current_event parameter. Don't
7279 clear debug_registers_changed nor copy DR values to
7280 debug_reg_state.
7281 (i386_set_thread_context): Delete.
7282 (i386_prepare_to_resume): New function.
7283 (i386_thread_added): Mark the thread as needing to update irs
7284 debug registers.
7285 (the_low_target): Remove i386_set_thread_context and install
7286 i386_prepare_to_resume.
7287 * win32-low.c (win32_get_thread_context): Adjust.
7288 (win32_set_thread_context): Use SetThreadContext
7289 directly.
7290 (win32_prepare_to_resume): New function.
7291 (win32_require_context): New function, factored out from ...
7292 (thread_rec): ... this.
7293 (continue_one_thread): Call win32_prepare_to_resume on each thread
7294 we're about to continue.
7295 (win32_resume): Call win32_prepare_to_resume on the event thread.
7296 * win32-low.h (struct win32_thread_info)
7297 <debug_registers_changed>: New field.
7298 (struct win32_target_ops): Change prototype of set_thread_context,
7299 delete set_thread_context and add prepare_to_resume.
7300 (win32_require_context): New declaration.
7301
7302 2014-10-08 Gary Benson <gbenson@redhat.com>
7303
7304 * server.h: Do not include common-exceptions.h.
7305
7306 2014-10-08 Gary Benson <gbenson@redhat.com>
7307
7308 * server.h: Do not include cleanups.h.
7309
7310 2014-09-30 James Hogan <james.hogan@imgtec.com>
7311
7312 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
7313 mips64-dsp-linux.c.
7314
7315 2014-09-23 Yao Qi <yao@codesourcery.com>
7316
7317 * linux-low.c (lp_status_maybe_breakpoint): New function.
7318 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
7319 (count_events_callback): Likewise.
7320 (select_event_lwp_callback): Likewise.
7321 (cancel_breakpoints_callback): Likewise.
7322
7323 2014-09-19 Don Breazeal <donb@codesourcery.com>
7324
7325 * linux-low.c (handle_extended_wait): Call
7326 linux_ptrace_get_extended_event.
7327 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
7328 linux_is_extended_waitstatus.
7329
7330 2014-09-16 Joel Brobecker <brobecker@adacore.com>
7331
7332 * Makefile.in (CPPFLAGS): Define.
7333 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
7334 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
7335
7336 2014-09-16 Gary Benson <gbenson@redhat.com>
7337
7338 * inferiors.h (current_inferior): Renamed as...
7339 (current_thread): New variable. All uses updated.
7340 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
7341 (maybe_move_out_of_jump_pad): Likewise.
7342 (cancel_breakpoint): Likewise.
7343 (linux_low_filter_event): Likewise.
7344 (wait_for_sigstop): Likewise.
7345 (linux_resume_one_lwp): Likewise.
7346 (need_step_over_p): Likewise.
7347 (start_step_over): Likewise.
7348 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
7349 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
7350 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
7351 and save_inferior as saved_thread.
7352 * regcache.c (get_thread_regcache): Renamed saved_inferior as
7353 saved_thread.
7354 (regcache_invalidate_thread): Likewise.
7355 * remote-utils.c (prepare_resume_reply): Likewise.
7356 * thread-db.c (thread_db_get_tls_address): Likewise.
7357 (disable_thread_event_reporting): Likewise.
7358 (remove_thread_event_breakpoints): Likewise.
7359 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
7360 as saved_thread.
7361 * target.h (set_desired_inferior): Renamed as...
7362 (set_desired_thread): New declaration. All uses updated.
7363 * server.c (myresume): Updated comment to reference thread instead
7364 of inferior.
7365 (handle_serial_event): Likewise.
7366 (handle_target_event): Likewise.
7367
7368 2014-09-12 Tom Tromey <tromey@redhat.com>
7369 Gary Benson <gbenson@redhat.com>
7370
7371 * regcache.h: Include common-regcache.h.
7372 (regcache_read_pc): Don't declare.
7373 * regcache.c (get_thread_regcache_for_ptid): New function.
7374
7375 2014-09-11 Tom Tromey <tromey@redhat.com>
7376 Gary Benson <gbenson@redhat.com>
7377
7378 * symbol.c: New file.
7379 * Makefile.in (SFILES): Add symbol.c.
7380 (OBS): Add symbol.o.
7381
7382 2014-09-11 Gary Benson <gbenson@redhat.com>
7383
7384 * target.c (target_stop_ptid, target_continue_ptid): New
7385 functions.
7386
7387 2014-09-11 Tom Tromey <tromey@redhat.com>
7388 Gary Benson <gbenson@redhat.com>
7389
7390 * target.h: Include target/target.h.
7391 * target.c (target_read_memory, target_read_uint32)
7392 (target_write_memory): New functions.
7393
7394 2014-09-11 Gary Benson <gbenson@redhat.com>
7395
7396 * server.h (debug_hw_points): Don't declare.
7397 * server.c (debug_hw_points): Don't define. Replace all uses
7398 with show_debug_regs.
7399 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
7400 all uses with show_debug_regs.
7401
7402 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
7403
7404 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
7405 endianness into account.
7406 (ppc_supply_ptrace_register): Likewise.
7407
7408 2014-09-03 James Hogan <james.hogan@imgtec.com>
7409
7410 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
7411 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
7412
7413 2014-09-03 Gary Benson <gbenson@redhat.com>
7414
7415 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
7416 ALL_DEBUG_ADDRESS_REGISTERS.
7417
7418 2014-09-02 Gary Benson <gbenson@redhat.com>
7419
7420 * i386-low.h: Renamed as...
7421 * x86-low.h: New file. All type, function and variable name
7422 prefixes changed from "i386_" to "x86_". All references updated.
7423 * i386-low.c: Renamed as...
7424 * x86-low.c: New file. All type, function and variable name
7425 prefixes changed from "i386_" to "x86_". All references updated.
7426
7427 2014-09-02 Gary Benson <gbenson@redhat.com>
7428
7429 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
7430 (x86_linux_new_thread): Likewise.
7431
7432 2014-08-29 Gary Benson <gbenson@redhat.com>
7433
7434 * server.h (setjmp.h): Do not include.
7435 (toplevel): Do not declare.
7436 (common-exceptions.h): Include.
7437 (cleanups.h): Likewise.
7438 * server.c (toplevel): Do not define.
7439 (exit_code): New static global.
7440 (detach_or_kill_for_exit_cleanup): New function.
7441 (main): New function. Original main renamed to...
7442 (captured_main): New function.
7443 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
7444
7445 2014-08-29 Gary Benson <gbenson@redhat.com>
7446
7447 * Makefile.in (SFILES): Add common/common-exceptions.c.
7448 (OBS): Add common-exceptions.o.
7449 (common-exceptions.o): New rule.
7450 * utils.c (prepare_to_throw_exception): New function.
7451
7452 2014-08-29 Gary Benson <gbenson@redhat.com>
7453
7454 * config.in: Regenerate.
7455 * configure: Likewise.
7456
7457 2014-08-29 Gary Benson <gbenson@redhat.com>
7458
7459 * Makefile.in (SFILES): Add common/cleanups.c.
7460 (OBS): cleanups.o.
7461 (cleanups.o): New rule.
7462
7463 2014-08-29 Gary Benson <gbenson@redhat.com>
7464
7465 * utils.c (internal_vwarning): New function.
7466
7467 2014-08-28 Gary Benson <gbenson@redhat.com>
7468
7469 * utils.h (fatal): Remove declaration.
7470 * utils.c (fatal): Remove function.
7471
7472 2014-08-28 Gary Benson <gbenson@redhat.com>
7473
7474 * tracepoint.c (gdb_agent_init): Replace fatal with
7475 perror_with_name.
7476 (initialize_tracepoint): Likewise.
7477
7478 2014-08-28 Gary Benson <gbenson@redhat.com>
7479
7480 * remote-utils.c (remote_prepare): Replace fatal with error.
7481
7482 2014-08-28 Gary Benson <gbenson@redhat.com>
7483
7484 * linux-low.c (linux_async): Replace fatal with warning.
7485 Tidy up and return.
7486 (linux_start_non_stop): Return -1 if linux_async failed.
7487
7488 2014-08-28 Gary Benson <gbenson@redhat.com>
7489
7490 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
7491 gdb_assert.
7492 (i386_dr_low_get_addr): Remove vague comment.
7493 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
7494 gdb_assert.
7495
7496 2014-08-28 Gary Benson <gbenson@redhat.com>
7497
7498 * inferiors.c (get_thread_process): Replace check with gdb_assert.
7499 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
7500 internal_error.
7501 (linux_resume_one_lwp): Likewise.
7502 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
7503 gdb_assert.
7504 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
7505 with internal_error.
7506 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
7507 (init_register_cache): Replace fatal with gdb_assert_not_reached.
7508 (find_register_by_name): Replace fatal with internal_error.
7509 (find_regno): Likewise.
7510 * tdesc.c (init_target_desc): Replace check with gdb_assert.
7511 * thread-db.c (thread_db_create_event): Likewise.
7512 (thread_db_load_search): Likewise.
7513 (try_thread_db_load_1): Likewise.
7514 * tracepoint.c (get_jump_space_head): Replace fatal with
7515 internal_error.
7516 (claim_trampoline_space): Likewise.
7517 (have_fast_tracepoint_trampoline_buffer): Likewise.
7518 (cmd_qtstart): Likewise.
7519 (stop_tracing): Likewise.
7520 (fast_tracepoint_collecting): Likewise.
7521 (target_malloc): Likewise.
7522 (download_tracepoint): Likewise.
7523 (download_trace_state_variables): Replace check with gdb_assert.
7524 (upload_fast_traceframes): Replace fatal with internal_error.
7525
7526 2014-08-19 Tom Tromey <tromey@redhat.com>
7527 Gary Benson <gbenson@redhat.com>
7528
7529 * Makefile.in (SFILES): Add common/common-debug.c.
7530 (OBS): Add common-debug.o.
7531 (common-debug.o): New rule.
7532 * debug.h (debug_printf): Don't declare.
7533 * debug.c (debug_printf): Renamed and rewritten as...
7534 (debug_vprintf): New function.
7535
7536 2014-08-19 Gary Benson <gbenson@redhat.com>
7537
7538 * utils.h: Do not include print-utils.h.
7539
7540 2014-08-19 Tom Tromey <tromey@redhat.com>
7541 Gary Benson <gbenson@redhat.com>
7542
7543 * server.h: Add static assertion.
7544 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
7545
7546 2014-08-19 Tom Tromey <tromey@redhat.com>
7547 Gary Benson <gbenson@redhat.com>
7548
7549 * Makefile.in (SFILES): Add common/errors.c.
7550 (OBS): Add errors.o.
7551 (IPA_OBS): Add errors-ipa.o.
7552 (errors.o): New rule.
7553 (errors-ipa.o): Likewise.
7554 * utils.h (perror_with_name, error, warning): Don't declare.
7555 * utils.c (warning): Renamed and rewritten as...
7556 (vwarning): New function.
7557 (error): Renamed and rewritten as...
7558 (verror): New function.
7559 (internal_error): Renamed and rewritten as...
7560 (internal_verror): New function.
7561
7562 2014-08-07 Gary Benson <gbenson@redhat.com>
7563
7564 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
7565 * configure: Regenerate.
7566 * config.in: Likewise.
7567 * server.h: Do not include errno.h.
7568 * event-loop.c: Likewise.
7569 * hostio-errno.c: Likewise.
7570 * linux-low.c: Likewise.
7571 * remote-utils.c: Likewise.
7572 * spu-low.c: Likewise.
7573 * utils.c: Likewise.
7574 * gdbreplay.c: Unconditionally include errno.h.
7575
7576 2014-08-07 Gary Benson <gbenson@redhat.com>
7577
7578 * server.h: Do not include string.h.
7579 * event-loop.c: Likewise.
7580 * linux-low.c: Likewise.
7581 * regcache.c: Likewise.
7582 * remote-utils.c: Likewise.
7583 * spu-low.c: Likewise.
7584 * utils.c: Likewise.
7585
7586 2014-08-07 Gary Benson <gbenson@redhat.com>
7587
7588 * server.h: Do not include gdb_assert.h.
7589
7590 2014-08-07 Gary Benson <gbenson@redhat.com>
7591
7592 * server.h: Do not include common-utils.h.
7593
7594 2014-08-07 Gary Benson <gbenson@redhat.com>
7595
7596 * server.h: Do not include ptid.h.
7597 * notif.h: Likewise.
7598
7599 2014-08-07 Gary Benson <gbenson@redhat.com>
7600
7601 * server.h: Do not include gdb_locale.h.
7602
7603 2014-08-07 Gary Benson <gbenson@redhat.com>
7604
7605 * server.h: Do not include gdb/signals.h.
7606 * win32-low.c: Likewise.
7607
7608 2014-08-07 Gary Benson <gbenson@redhat.com>
7609
7610 * server.h: Do not include pathmax.h.
7611
7612 2014-08-07 Gary Benson <gbenson@redhat.com>
7613
7614 * server.h: Do not include libiberty.h.
7615 * linux-bfin-low.c: Likewise.
7616
7617 2014-08-07 Gary Benson <gbenson@redhat.com>
7618
7619 * server.h: Do not include ansidecl.h.
7620
7621 2014-08-07 Gary Benson <gbenson@redhat.com>
7622
7623 * linux-x86-low.c: Do not include stddef.h.
7624 * lynx-ppc-low.c: Likewise.
7625 * tracepoint.c: Likewise.
7626
7627 2014-08-07 Gary Benson <gbenson@redhat.com>
7628
7629 * server.h: Do not include stdarg.h.
7630 * nto-low.c: Likewise.
7631
7632 2014-08-07 Gary Benson <gbenson@redhat.com>
7633
7634 * server.h: Do not include stdlib.h.
7635 * inferiors.c: Likewise.
7636 * linux-low.c: Likewise.
7637 * regcache.c: Likewise.
7638 * spu-low.c: Likewise.
7639 * tracepoint.c: Likewise.
7640 * utils.c: Likewise.
7641
7642 2014-08-07 Gary Benson <gbenson@redhat.com>
7643
7644 * server.h: Do not include stdio.h.
7645 * linux-low.c: Likewise.
7646 * remote-utils.c: Likewise.
7647 * spu-low.c: Likewise.
7648 * utils.c: Likewise.
7649 * wincecompat.c: Likewise.
7650
7651 2014-08-06 Gary Benson <gbenson@redhat.com>
7652
7653 * regcache.c (init_register_cache): Move conditionals inside if.
7654
7655 2014-08-06 Gary Benson <gbenson@redhat.com>
7656
7657 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
7658
7659 2014-07-31 Gary Benson <gbenson@redhat.com>
7660
7661 * ax.h: Do not include server.h.
7662 * gdbthread.h: Likewise.
7663 * lynx-low.h: Likewise.
7664 * notif.h: Likewise.
7665
7666 2014-07-30 Gary Benson <gbenson@redhat.com>
7667
7668 * server.h: Include common-defs.h.
7669 Do not include config.h or build-gnulib-gdbserver/config.h.
7670
7671 2014-07-30 Gary Benson <gbenson@redhat.com>
7672
7673 * hostio-errno.c: Move server.h to top of includes list.
7674 * inferiors.c: Likewise.
7675 * linux-x86-low.c: Likewise.
7676 * notif.c: Include server.h.
7677
7678 2014-07-24 Tom Tromey <tromey@redhat.com>
7679 Gary Benson <gbenson@redhat.com>
7680
7681 * server.h (CORE_ADDR): Now unsigned.
7682
7683 2014-07-16 Pedro Alves <palves@redhat.com>
7684
7685 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
7686
7687 2014-07-15 Pedro Alves <palves@redhat.com>
7688
7689 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
7690 copy.
7691
7692 2014-07-11 Pedro Alves <palves@redhat.com>
7693
7694 * linux-low.c (kill_wait_lwp): New function, based on
7695 kill_one_lwp_callback, but use my_waitpid directly.
7696 (kill_one_lwp_callback, linux_kill): Use it.
7697
7698 2014-06-23 Pedro Alves <palves@redhat.com>
7699
7700 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
7701 before setting DR0..DR3.
7702
7703 2014-06-20 Gary Benson <gbenson@redhat.com>
7704
7705 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
7706 * configure: Regenerated.
7707 * config.in: Likewise.
7708
7709 2014-06-20 Gary Benson <gbenson@redhat.com>
7710
7711 * Makefile.in (SFILES): Update locations for files moved
7712 from common to nat.
7713 (object file files): Reordered.
7714
7715 2014-06-20 Gary Benson <gbenson@redhat.com>
7716
7717 * i386-low.h (i386_dr_low_can_set_addr): Removed.
7718 (i386_dr_low_set_addr): Likewise.
7719 (i386_dr_low_get_addr): Likewise.
7720 (i386_dr_low_can_set_control): Likewise.
7721 (i386_dr_low_set_control): Likewise.
7722 (i386_dr_low_get_control): Likewise.
7723 (i386_dr_low_get_status): Likewise.
7724 (i386_get_debug_register_length): Likewise.
7725 * linux-x86-low.c (i386_dr_low_set_addr):
7726 Changed signature. Made static.
7727 (i386_dr_low_get_addr): Likewise.
7728 (i386_dr_low_set_control): Likewise.
7729 (i386_dr_low_get_control): Likewise.
7730 (i386_dr_low_get_status): Likewise.
7731 (i386_dr_low): New global variable.
7732 * win32-i386-low.c (i386_dr_low_set_addr):
7733 Changed signature. Made static.
7734 (i386_dr_low_get_addr): Likewise.
7735 (i386_dr_low_set_control): Likewise.
7736 (i386_dr_low_get_control): Likewise.
7737 (i386_dr_low_get_status): Likewise.
7738 (i386_dr_low): New global variable.
7739
7740 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
7741
7742 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
7743 * Makefile.in (AR, AR_FLAGS): Define.
7744 * configure: Regenerate.
7745
7746 2014-06-19 Gary Benson <gbenson@redhat.com>
7747
7748 * Makefile.in (i386-dregs.o): New rule.
7749 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
7750 * i386-low.c (target.h): Remove include.
7751 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
7752 (DR_CONTROL_SHIFT): Likewise.
7753 (DR_CONTROL_SIZE): Likewise.
7754 (DR_RW_EXECUTE): Likewise.
7755 (DR_RW_WRITE): Likewise.
7756 (DR_RW_READ): Likewise.
7757 (DR_RW_IORW): Likewise.
7758 (DR_LEN_1): Likewise.
7759 (DR_LEN_2): Likewise.
7760 (DR_LEN_4): Likewise.
7761 (DR_LEN_8): Likewise.
7762 (DR_LOCAL_ENABLE_SHIFT): Likewise.
7763 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
7764 (DR_ENABLE_SIZE): Likewise.
7765 (DR_LOCAL_SLOWDOWN): Likewise.
7766 (DR_GLOBAL_SLOWDOWN): Likewise.
7767 (DR_CONTROL_RESERVED): Likewise.
7768 (I386_DR_CONTROL_MASK): Likewise.
7769 (I386_DR_VACANT): Likewise.
7770 (I386_DR_LOCAL_ENABLE): Likewise.
7771 (I386_DR_GLOBAL_ENABLE): Likewise.
7772 (I386_DR_DISABLE): Likewise.
7773 (I386_DR_SET_RW_LEN): Likewise.
7774 (I386_DR_GET_RW_LEN): Likewise.
7775 (I386_DR_WATCH_HIT): Likewise.
7776 (i386_wp_op_t): Likewise.
7777 (i386_show_dr): Likewise.
7778 (i386_length_and_rw_bits): Likewise.
7779 (i386_insert_aligned_watchpoint): Likewise.
7780 (i386_remove_aligned_watchpoint): Likewise.
7781 (i386_handle_nonaligned_watchpoint): Likewise.
7782 i386_update_inferior_debug_regs(): Likewise.
7783 (i386_dr_insert_watchpoint): Likewise.
7784 (i386_dr_remove_watchpoint): Likewise.
7785 (i386_dr_region_ok_for_watchpoint): Likewise.
7786 (i386_dr_stopped_data_address): Likewise.
7787 (i386_dr_stopped_by_watchpoint): Likewise.
7788
7789 2014-06-19 Gary Benson <gbenson@redhat.com>
7790
7791 * i386-low.c (i386_dr_show): Renamed to
7792 i386_show_dr and made static. All uses updated.
7793 (i386_dr_length_and_rw_bits): Renamed to
7794 i386_length_and_rw_bits and made static.
7795 All uses updated.
7796 (i386_dr_insert_aligned_watchpoint): Renamed to
7797 i386_insert_aligned_watchpoint and made static.
7798 All uses updated.
7799 (i386_dr_remove_aligned_watchpoint): Renamed to
7800 i386_remove_aligned_watchpoint and made static.
7801 All uses updated.
7802 (i386_dr_update_inferior_debug_regs): Renamed to
7803 i386_update_inferior_debug_regs and made static.
7804 All uses updated.
7805
7806 2014-06-18 Gary Benson <gbenson@redhat.com>
7807
7808 * i386-low.h (i386_dr_low_can_set_addr): New macro.
7809 (i386_dr_low_can_set_control): Likewise.
7810 (i386_get_debug_register_length): Likewise.
7811 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
7812 (i386_dr_low_can_set_control): Likewise.
7813 (i386_get_debug_register_length): Likewise.
7814
7815 2014-06-17 Gary Benson <gbenson@redhat.com>
7816
7817 * i386-low.h (i386-dregs.h): New include.
7818 (DR_FIRSTADDR): Now in i386-dregs.h.
7819 (DR_LASTADDR): Likewise.
7820 (DR_NADDR): Likewise.
7821 (DR_STATUS): Likewise.
7822 (DR_CONTROL): Likewise.
7823 (i386_debug_reg_state): Likewise.
7824 (i386_dr_insert_watchpoint): Likewise.
7825 (i386_dr_remove_watchpoint): Likewise.
7826 (i386_dr_region_ok_for_watchpoint): Likewise.
7827 (i386_dr_stopped_data_address): Likewise.
7828 (i386_dr_stopped_by_watchpoint): Likewise.
7829 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
7830
7831 2014-06-18 Gary Benson <gbenson@redhat.com>
7832
7833 * i386-low.h (i386_low_insert_watchpoint): Renamed to
7834 i386_dr_insert_watchpoint.
7835 (i386_low_remove_watchpoint): Renamed to
7836 i386_dr_remove_watchpoint.
7837 (i386_low_region_ok_for_watchpoint): Renamed to
7838 i386_dr_region_ok_for_watchpoint.
7839 (i386_low_stopped_data_address): Renamed to
7840 i386_dr_stopped_data_address.
7841 (i386_low_stopped_by_watchpoint): Renamed to
7842 i386_dr_stopped_by_watchpoint.
7843 * i386-low.c (i386_show_dr): Renamed to
7844 i386_dr_show and made nonstatic. All uses updated.
7845 (i386_length_and_rw_bits): Renamed to
7846 i386_dr_length_and_rw_bits and made nonstatic.
7847 All uses updated.
7848 (i386_insert_aligned_watchpoint): Renamed to
7849 i386_dr_insert_aligned_watchpoint and made nonstatic.
7850 All uses updated.
7851 (i386_remove_aligned_watchpoint): Renamed to
7852 i386_dr_remove_aligned_watchpoint and made nonstatic.
7853 All uses updated.
7854 (i386_update_inferior_debug_regs): Renamed to
7855 i386_dr_update_inferior_debug_regs and made nonstatic.
7856 All uses updated.
7857 (i386_low_insert_watchpoint): Renamed to
7858 i386_dr_insert_watchpoint. All uses updated.
7859 (i386_low_remove_watchpoint): Renamed to
7860 i386_dr_remove_watchpoint. All uses updated.
7861 (i386_low_region_ok_for_watchpoint): Renamed to
7862 i386_dr_region_ok_for_watchpoint. All uses updated.
7863 (i386_low_stopped_data_address): Renamed to
7864 i386_dr_stopped_data_address. All uses updated.
7865 (i386_low_stopped_by_watchpoint): Renamed to
7866 i386_dr_stopped_by_watchpoint. All uses updated.
7867
7868 2014-06-18 Gary Benson <gbenson@redhat.com>
7869
7870 * i386-low.c (i386_dr_low_can_set_addr): New macro.
7871 (i386_dr_low_can_set_control): Likewise.
7872 (i386_insert_aligned_watchpoint): New check.
7873
7874 2014-06-18 Gary Benson <gbenson@redhat.com>
7875
7876 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
7877 Renamed to state.
7878
7879 2014-06-18 Gary Benson <gbenson@redhat.com>
7880
7881 * i386-low.c (i386_length_and_rw_bits): Use internal_error
7882 instead of fatal and error.
7883 (i386_handle_nonaligned_watchpoint): Likewise.
7884
7885 2014-06-18 Gary Benson <gbenson@redhat.com>
7886
7887 * i386-low.c (i386_get_debug_register_length): New macro.
7888 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
7889 (i386_show_dr): Use debug_printf instead of fprintf. Use
7890 phex to format values.
7891
7892 2014-06-18 Gary Benson <gbenson@redhat.com>
7893
7894 * i386-low.h: Comment changes.
7895 * i386-low.c: Likewise.
7896
7897 2014-06-18 Gary Benson <gbenson@redhat.com>
7898
7899 * i386-low.c: Whitespace changes.
7900
7901 2014-06-12 Tom Tromey <tromey@redhat.com>
7902
7903 * utils.c (freeargv): Remove.
7904
7905 2014-06-12 Tom Tromey <tromey@redhat.com>
7906
7907 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
7908 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
7909 (parse_debug_format_options): Likewise.
7910 (gdbserver_usage): Likewise.
7911 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
7912 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
7913 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
7914 against libiberty.
7915 ($(LIBGNU)): Depend on libiberty.
7916 (all-lib): Recurse into all subdirs.
7917 (install-only): Invoke "install" target in subdirs.
7918 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
7919 targets.
7920 * configure: Rebuild.
7921 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
7922 for vasprintf, vsnprintf, or gettimeofday.
7923 * configure.srv: Don't add safe-ctype.o or lbasename.o to
7924 srv_tgtobj.
7925
7926 2014-06-05 Joel Brobecker <brobecker@adacore.com>
7927
7928 * development.sh: Delete.
7929 * Makefile.in (config.status): Adjust dependency on development.sh.
7930 * configure.ac: Adjust development.sh source call.
7931 * configure: Regenerate.
7932
7933 2014-06-02 Pedro Alves <palves@redhat.com>
7934
7935 * ax.c (gdb_free_agent_expr): New function.
7936 * ax.h (gdb_free_agent_expr): New declaration.
7937 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
7938 list.
7939 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
7940 static.
7941 (clear_breakpoint_conditions_and_commands): New function.
7942 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
7943 (clear_breakpoint_conditions_and_commands): New declaration.
7944
7945 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
7946
7947 * linux-aarch64-low.c (asm/ptrace.h): Include.
7948
7949 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
7950
7951 Fix TLS access for -static -pthread.
7952 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
7953 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
7954 (thread_db_load_search, try_thread_db_load_1): Initialize it.
7955
7956 2014-05-20 Pedro Alves <palves@redhat.com>
7957
7958 * linux-aarch64-low.c (aarch64_insert_point)
7959 (aarch64_remove_point): No longer check whether the type is
7960 supported here. Adjust to new interface.
7961 (the_low_target): Install aarch64_supports_z_point_type as
7962 supports_z_point_type method.
7963 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
7964 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
7965 instead of a Z packet char. Adjust.
7966 (arm_supports_z_point_type): New function.
7967 (arm_insert_point, arm_remove_point): Adjust to new interface.
7968 (the_low_target): Install arm_supports_z_point_type.
7969 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
7970 (cris_insert_point, cris_remove_point): Adjust to new interface.
7971 Don't check whether the type is supported here.
7972 (the_low_target): Install cris_supports_z_point_type.
7973 * linux-low.c (linux_supports_z_point_type): New function.
7974 (linux_insert_point, linux_remove_point): Adjust to new interface.
7975 * linux-low.h (struct linux_target_ops) <insert_point,
7976 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
7977 raw_breakpoint pointer parameter.
7978 <supports_z_point_type>: New method.
7979 * linux-mips-low.c (mips_supports_z_point_type): New function.
7980 (mips_insert_point, mips_remove_point): Adjust to new interface.
7981 Use mips_supports_z_point_type.
7982 (the_low_target): Install mips_supports_z_point_type.
7983 * linux-ppc-low.c (the_low_target): Install NULL as
7984 supports_z_point_type method.
7985 * linux-s390-low.c (the_low_target): Install NULL as
7986 supports_z_point_type method.
7987 * linux-sparc-low.c (the_low_target): Install NULL as
7988 supports_z_point_type method.
7989 * linux-x86-low.c (x86_supports_z_point_type): New function.
7990 (x86_insert_point): Adjust to new insert_point interface. Use
7991 insert_memory_breakpoint. Adjust to new
7992 i386_low_insert_watchpoint interface.
7993 (x86_remove_point): Adjust to remove_point interface. Use
7994 remove_memory_breakpoint. Adjust to new
7995 i386_low_remove_watchpoint interface.
7996 (the_low_target): Install x86_supports_z_point_type.
7997 * lynx-low.c (lynx_target_ops): Install NULL as
7998 supports_z_point_type callback.
7999 * nto-low.c (nto_supports_z_point_type): New.
8000 (nto_insert_point, nto_remove_point): Adjust to new interface.
8001 (nto_target_ops): Install nto_supports_z_point_type.
8002 * mem-break.c: Adjust intro comment.
8003 (struct raw_breakpoint) <raw_type, size>: New fields.
8004 <inserted>: Update comment.
8005 <shlib_disabled>: Delete field.
8006 (enum bkpt_type) <gdb_breakpoint>: Delete value.
8007 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
8008 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
8009 (raw_bkpt_type_to_target_hw_bp_type): New function.
8010 (find_enabled_raw_code_breakpoint_at): New function.
8011 (find_raw_breakpoint_at): New type and size parameters. Use them.
8012 (insert_memory_breakpoint): New function, based off
8013 set_raw_breakpoint_at.
8014 (remove_memory_breakpoint): New function.
8015 (set_raw_breakpoint_at): Reimplement.
8016 (set_breakpoint): New, based on set_breakpoint_at.
8017 (set_breakpoint_at): Reimplement.
8018 (delete_raw_breakpoint): Go through the_target->remove_point
8019 instead of assuming memory breakpoints.
8020 (find_gdb_breakpoint_at): Delete.
8021 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
8022 (find_gdb_breakpoint): New function.
8023 (set_gdb_breakpoint_at): Delete.
8024 (z_type_supported): New function.
8025 (set_gdb_breakpoint_1): New function, loosely based off
8026 set_gdb_breakpoint_at.
8027 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
8028 (delete_gdb_breakpoint_at): Delete.
8029 (delete_gdb_breakpoint_1): New function, loosely based off
8030 delete_gdb_breakpoint_at.
8031 (delete_gdb_breakpoint): New function.
8032 (clear_gdb_breakpoint_conditions): Rename to ...
8033 (clear_breakpoint_conditions): ... this. Don't handle a NULL
8034 breakpoint.
8035 (add_condition_to_breakpoint): Make static.
8036 (add_breakpoint_condition): Take a struct breakpoint pointer
8037 instead of an address. Adjust.
8038 (gdb_condition_true_at_breakpoint): Rename to ...
8039 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
8040 z_type parameter.
8041 (gdb_condition_true_at_breakpoint): Reimplement.
8042 (add_breakpoint_commands): Take a struct breakpoint pointer
8043 instead of an address. Adjust.
8044 (gdb_no_commands_at_breakpoint): Rename to ...
8045 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
8046 parameter. Return true if no breakpoint was found. Change debug
8047 output.
8048 (gdb_no_commands_at_breakpoint): Reimplement.
8049 (run_breakpoint_commands): Rename to ...
8050 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
8051 and change return type to boolean.
8052 (run_breakpoint_commands): New function.
8053 (gdb_breakpoint_here): Also check for Z1 breakpoints.
8054 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
8055 breakpoint. Go through the_target->remove_point instead of
8056 assuming memory breakpoint.
8057 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
8058 software and hardware breakpoints.
8059 (reinsert_raw_breakpoint): Go through the_target->insert_point
8060 instead of assuming memory breakpoint.
8061 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
8062 software and hardware breakpoints.
8063 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
8064 Check both software and hardware breakpoints.
8065 (validate_inserted_breakpoint): Assert the breakpoint is a
8066 software breakpoint. Set the inserted flag to -1 instead of
8067 setting shlib_disabled.
8068 (delete_disabled_breakpoints): Adjust.
8069 (validate_breakpoints): Only validate software breakpoints.
8070 Adjust to inserted flag change.
8071 (check_mem_read, check_mem_write): Skip breakpoint types other
8072 than software breakpoints. Adjust to inserted flag change.
8073 * mem-break.h (enum raw_bkpt_type): New enum.
8074 (raw_breakpoint, struct process_info): Forward declare.
8075 (Z_packet_to_target_hw_bp_type): Delete declaration.
8076 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
8077 (set_gdb_breakpoint, delete_gdb_breakpoint)
8078 (clear_breakpoint_conditions): New declarations.
8079 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
8080 (breakpoint_inserted_here): Update comment.
8081 (add_breakpoint_condition, add_breakpoint_commands): Replace
8082 address parameter with a breakpoint pointer parameter.
8083 (gdb_breakpoint_here): Update comment.
8084 (delete_gdb_breakpoint_at): Delete.
8085 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
8086 * server.c (process_point_options): Take a struct breakpoint
8087 pointer instead of an address. Adjust.
8088 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
8089 delete_gdb_breakpoint.
8090 * spu-low.c (spu_target_ops): Install NULL as
8091 supports_z_point_type method.
8092 * target.h: Include mem-break.h.
8093 (struct target_ops) <prepare_to_access_memory>: Update comment.
8094 <supports_z_point_type>: New field.
8095 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
8096 instead of a char. Also take a raw breakpoint pointer.
8097 * win32-arm-low.c (the_low_target): Install NULL as
8098 supports_z_point_type.
8099 * win32-i386-low.c (i386_supports_z_point_type): New function.
8100 (i386_insert_point, i386_remove_point): Adjust to new interface.
8101 (the_low_target): Install i386_supports_z_point_type.
8102 * win32-low.c (win32_supports_z_point_type): New function.
8103 (win32_insert_point, win32_remove_point): Adjust to new interface.
8104 (win32_target_ops): Install win32_supports_z_point_type.
8105 * win32-low.h (struct win32_target_ops):
8106 <supports_z_point_type>: New method.
8107 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
8108 instead of a char. Also take a raw breakpoint pointer.
8109
8110 2014-05-20 Pedro Alves <palves@redhat.com>
8111
8112 * mem-break.h: Include break-common.h.
8113 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
8114 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
8115 (Z_packet_to_target_hw_bp_type): New declaration.
8116 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
8117 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
8118 (Z_PACKET_ACCESS_WP): Delete macros.
8119 (Z_packet_to_hw_type): Delete function.
8120 * i386-low.h: Don't include break-common.h here.
8121 (Z_packet_to_hw_type): Delete declaration.
8122 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
8123 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
8124 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
8125 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
8126 * linux-aarch64-low.c: Don't include break-common.h here.
8127 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
8128 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
8129 (Z_packet_to_target_hw_bp_type): Delete function.
8130 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
8131 function.
8132 (mips_insert_point, mips_remove_point): Use
8133 Z_packet_to_target_hw_bp_type.
8134
8135 2014-05-20 Pedro Alves <palves@redhat.com>
8136
8137 * linux-aarch64-low.c: Include break-common.h.
8138 (enum target_point_type): Delete.
8139 (Z_packet_to_point_type): Rename to ...
8140 (Z_packet_to_target_hw_bp_type): ... this, and return a
8141 target_hw_bp_type instead.
8142 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
8143 instead of an enum target_point_type.
8144 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
8145 breakpoint type.
8146 (aarch64_dr_state_insert_one_point)
8147 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
8148 (aarch64_handle_aligned_watchpoint)
8149 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
8150 Take an enum target_hw_bp_type instead of an enum
8151 target_point_type.
8152 (aarch64_supports_z_point_type): New function.
8153 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
8154 use Z_packet_to_target_hw_bp_type.
8155
8156 2014-05-20 Joel Brobecker <brobecker@adacore.com>
8157
8158 * configure.ac: Only use -Werror by default when DEVELOPMENT
8159 is true.
8160 * configure: Regenerate.
8161
8162 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
8163
8164 Fix gdbserver qGetTLSAddr for x86_64 -m32.
8165 * linux-x86-low.c (X86_64_USER_REGS): New.
8166 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
8167
8168 2014-04-28 Yao Qi <yao@codesourcery.com>
8169
8170 * Makefile.in (i386-avx512.c): Fix the typo of generated file
8171 name.
8172
8173 2014-04-25 Pedro Alves <palves@redhat.com>
8174
8175 PR server/16255
8176 * linux-low.c (linux_attach_fail_reason_string): New function.
8177 (linux_attach_lwp): Delete.
8178 (linux_attach_lwp_1): Rename to ...
8179 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
8180 argument. Remove "initial" parameter. Return int instead of
8181 void. Don't error or warn here.
8182 (linux_attach): Adjust to call linux_attach_lwp. Call error on
8183 failure to attach to the tgid. Call warning when failing to
8184 attach to an lwp.
8185 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
8186 argument. Remove "initial" parameter. Return int instead of
8187 void. Don't error or warn here.
8188 (linux_attach_fail_reason_string): New declaration.
8189 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
8190 interface change. Use linux_attach_fail_reason_string.
8191
8192 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
8193 Walfred Tedeschi <walfred.tedeschi@intel.com>
8194
8195 * Makefile.in: Added rules to handle new files
8196 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
8197 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
8198 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
8199 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
8200 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
8201 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
8202 x32-avx512-linux.o.
8203 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
8204 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
8205 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
8206 i386/x32-avx512.xml.
8207 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
8208 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
8209 i386/x32-avx512-linux.xml.
8210 * i387-fp.c (num_avx512_k_registers): New constant for number
8211 of K registers.
8212 (num_avx512_zmmh_low_registers): New constant for number of
8213 lower ZMM registers (0-15).
8214 (num_avx512_zmmh_high_registers): New constant for number of
8215 higher ZMM registers (16-31).
8216 (num_avx512_ymmh_registers): New contant for number of higher
8217 YMM registers (ymm16-31 added by avx521 on x86_64).
8218 (num_avx512_xmm_registers): New constant for number of higher
8219 XMM registers (xmm16-31 added by AVX512 on x86_64).
8220 (struct i387_xsave): Add space for AVX512 registers.
8221 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
8222 Add code to handle AVX512 registers.
8223 (i387_xsave_to_cache): Add code to handle AVX512 registers.
8224 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
8225 prototypei from generated file.
8226 (tdesc_amd64_avx512_linux): Likewise.
8227 (init_registers_x32_avx512_linux): Likewise.
8228 (tdesc_x32_avx512_linux): Likewise.
8229 (init_registers_i386_avx512_linux): Likewise.
8230 (tdesc_i386_avx512_linux): Likewise.
8231 (x86_64_regmap): Add AVX512 registers.
8232 (x86_linux_read_description): Add code to handle AVX512 XSTATE
8233 mask.
8234 (initialize_low_arch): Add code to initialize AVX512 registers.
8235
8236 2014-04-23 Pedro Alves <palves@redhat.com>
8237
8238 * mem-break.c (find_gdb_breakpoint_at): Make static.
8239 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
8240
8241 2014-04-23 Pedro Alves <palves@redhat.com>
8242
8243 * i386-low.c: Don't include break-common.h here.
8244 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
8245 prototype to take target_hw_bp_type as argument instead of a Z
8246 packet char.
8247 * i386-low.h: Include break-common.h here.
8248 (Z_packet_to_hw_type): Declare.
8249 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
8250 prototypes.
8251 * linux-x86-low.c (x86_insert_point): Convert the packet number to
8252 a target_hw_bp_type before calling i386_low_insert_watchpoint.
8253 (x86_remove_point): Convert the packet number to a
8254 target_hw_bp_type before calling i386_low_remove_watchpoint.
8255 * win32-i386-low.c (i386_insert_point): Convert the packet number
8256 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
8257 (i386_remove_point): Convert the packet number to a
8258 target_hw_bp_type before calling i386_low_remove_watchpoint.
8259
8260 2014-04-23 Pedro Alves <palves@redhat.com>
8261
8262 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
8263
8264 2014-04-10 Pedro Alves <palves@redhat.com>
8265
8266 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
8267 Check if the condition or command is NULL before checking if the
8268 breakpoint is known. On success, return true.
8269 * mem-break.h (add_breakpoint_condition): Document return.
8270 (add_breakpoint_commands): Add describing comment.
8271 * server.c (skip_to_semicolon): New function.
8272 (process_point_options): Use it.
8273
8274 2014-04-09 Pedro Alves <palves@redhat.com>
8275
8276 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
8277 to lwpid_of.
8278
8279 2014-02-27 Pedro Alves <palves@redhat.com>
8280
8281 PR 12702
8282 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
8283 macros.
8284 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
8285 output.
8286 (last_thread_of_process_p): Take a PID argument instead of a
8287 thread pointer.
8288 (linux_wait_for_lwp): Delete.
8289 (num_lwps, check_zombie_leaders, not_stopped_callback): New
8290 functions.
8291 (linux_low_filter_event): New function, party factored out from
8292 linux_wait_for_event.
8293 (linux_wait_for_event): Rename to ...
8294 (linux_wait_for_event_filtered): ... this. Add new filter ptid
8295 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
8296 sigsuspend. Check for zombie leaders.
8297 (linux_wait_for_event): Reimplement as wrapper around
8298 linux_wait_for_event_filtered.
8299 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
8300 a normal or signal exit is seen, it's the whole process exiting.
8301 (wait_for_sigstop): No longer a for_each_inferior callback.
8302 Rewrite on top of linux_wait_for_event_filtered.
8303 (stop_all_lwps): Call wait_for_sigstop directly.
8304 * server.c (resume, handle_target_event): Handle
8305 TARGET_WAITKIND_NO_RESUMED.
8306
8307 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8308
8309 * win32-low.c (psapi_get_dll_name,
8310 * win32_CreateToolhelp32Snapshot): Delete.
8311 (win32_CreateToolhelp32Snapshot, win32_Module32First)
8312 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
8313 Delete.
8314 (handle_load_dll): Add function description.
8315 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
8316
8317 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8318
8319 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
8320 Add comment.
8321 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
8322 base address when calling win32_add_one_solib.
8323 (handle_load_dll): Delete local variable load_addr.
8324 Remove 0x1000 offset applied to DLL base address when calling
8325 win32_add_one_solib.
8326 (handle_unload_dll): Add comment.
8327
8328 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8329
8330 * win32-low.c (win32_add_all_dlls): Renames
8331 win32_ensure_ntdll_loaded. Rewrite function documentation.
8332 Adjust implementation to always load all DLLs.
8333 Add 0x1000 offset to DLL base address when calling
8334 win32_add_one_solib.
8335 (child_initialization_done): New static global.
8336 (do_initial_child_stuff): Set child_initialization_done to
8337 zero during child initialization, and 1 after. Replace call
8338 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
8339 Add comment.
8340 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
8341 (handle_unload_dll): Add function documentation.
8342 (get_child_debug_event): Ignore load and unload DLL events
8343 during child initialization.
8344
8345 2014-02-20 Doug Evans <dje@google.com>
8346
8347 Remove global all_lwps.
8348 * inferiors.h (ptid_of): Move here from linux-low.h.
8349 (pid_of, lwpid_of): Ditto.
8350 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
8351 parameter is a struct thread_info * now.
8352 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
8353 directly. Pass &all_threads to find_inferior instead of &all_lwps.
8354 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
8355 directly.
8356 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
8357 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
8358 * linux-arm-low.c (update_registers_callback): Update, "entry"
8359 parameter is a struct thread_info * now.
8360 Fetch lwpid from current_inferior directly.
8361 (arm_insert_point): Pass &all_threads to find_inferior instead of
8362 &all_lwps.
8363 (arm_remove_point): Ditto.
8364 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
8365 (arm_prepare_to_resume): Fetch pid from thread.
8366 (arm_read_description): Fetch lwpid from current_inferior directly.
8367 * linux-low.c (all_lwps): Delete.
8368 (delete_lwp): Delete call to remove_inferior.
8369 (handle_extended_wait): Fetch lwpid from thread.
8370 (add_lwp): Don't set lwp->entry.id. Remove call to
8371 add_inferior_to_list.
8372 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
8373 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
8374 (kill_one_lwp_callback): Ditto.
8375 (linux_kill): Don't dereference NULL pointer.
8376 Fetch ptid,lwpid from thread.
8377 (get_detach_signal): Fetch ptid from thread.
8378 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
8379 Simplify call to regcache_invalidate_thread.
8380 (delete_lwp_callback): Update, "entry" parameter is a
8381 struct thread_info * now. Fetch pid from thread.
8382 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
8383 (status_pending_p_callback): Update, "entry" parameter is a
8384 struct thread_info * now. Fetch ptid from thread.
8385 (find_lwp_pid): Update, "entry" parameter is a
8386 struct thread_info * now.
8387 (linux_wait_for_lwp): Fetch pid from thread.
8388 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
8389 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
8390 (enqueue_one_deferred_signal): Fetch lwpid from thread.
8391 (dequeue_one_deferred_signal): Ditto.
8392 (cancel_breakpoint): Fetch ptid from current_inferior.
8393 (linux_wait_for_event): Pass &all_threads to find_inferior,
8394 not &all_lwps. Fetch ptid, lwpid from thread.
8395 (count_events_callback): Update, "entry" parameter is a
8396 struct thread_info * now.
8397 (select_singlestep_lwp_callback): Ditto.
8398 (select_event_lwp_callback): Ditto.
8399 (cancel_breakpoints_callback): Ditto.
8400 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
8401 not &all_lwps.
8402 (select_event_lwp): Ditto. Fetch ptid from event_thread.
8403 (unsuspend_one_lwp): Update, "entry" parameter is a
8404 struct thread_info * now.
8405 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
8406 not &all_lwps.
8407 (linux_stabilize_threads): Ditto. And for for_each_inferior.
8408 Fetch lwpid from thread, not lwp.
8409 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
8410 Pass &all_threads to find_inferior, not &all_lwps.
8411 (send_sigstop): Fetch lwpid from thread, not lwp.
8412 (send_sigstop_callback): Update, "entry" parameter is a
8413 struct thread_info * now.
8414 (suspend_and_send_sigstop_callback): Ditto.
8415 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
8416 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
8417 struct thread_info * now.
8418 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
8419 from thread, lwp.
8420 (lwp_running): Update, "entry" parameter is a
8421 struct thread_info * now.
8422 (stop_all_lwps): Fetch ptid from thread.
8423 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
8424 (linux_resume_one_lwp): Fetch lwpid from thread.
8425 (linux_set_resume_request): Update, "entry" parameter is a
8426 struct thread_info * now. Fetch pid, lwpid from thread.
8427 (resume_status_pending_p): Update, "entry" parameter is a
8428 struct thread_info * now.
8429 (need_step_over_p): Ditto. Fetch lwpid from thread.
8430 (start_step_over): Fetch lwpid from thread.
8431 (linux_resume_one_thread): Update, "entry" parameter is a
8432 struct thread_info * now. Fetch lwpid from thread.
8433 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
8434 (proceed_one_lwp): Update, "entry" parameter is a
8435 struct thread_info * now. Fetch lwpid from thread.
8436 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
8437 struct thread_info * now.
8438 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
8439 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
8440 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
8441 directly.
8442 (regsets_store_inferior_registers): Ditto.
8443 (fetch_register, store_register): Ditto.
8444 (linux_read_memory, linux_write_memory): Ditto.
8445 (linux_request_interrupt): Ditto.
8446 (linux_read_auxv): Ditto.
8447 (linux_xfer_siginfo): Ditto.
8448 (linux_qxfer_spu): Ditto.
8449 (linux_qxfer_libraries_svr4): Ditto.
8450 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
8451 moved to inferiors.h.
8452 (get_lwp): Delete.
8453 (get_thread_lwp): Update.
8454 (struct lwp_info): Delete member "entry". Simplify comment for
8455 member "thread".
8456 (all_lwps): Delete.
8457 * linux-mips-low.c (mips_read_description): Fetch lwpid from
8458 current_inferior directly.
8459 (update_watch_registers_callback): Update, "entry" parameter is a
8460 struct thread_info * now. Fetch pid from thread.
8461 (mips_linux_prepare_to_resume): Fetch ptid from thread.
8462 (mips_insert_point): Fetch lwpid from current_inferior.
8463 Pass &all_threads to find_inferior, not &all_lwps.
8464 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
8465 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
8466 directly.
8467 (mips_stopped_data_address): Ditto.
8468 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
8469 directly.
8470 * linux-tile-low.c (tile_arch_setup): Ditto.
8471 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
8472 (update_debug_registers_callback): Update, "entry" parameter is a
8473 struct thread_info * now. Fetch pid from thread.
8474 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
8475 Pass &all_threads to find_inferior, not &all_lwps.
8476 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
8477 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
8478 Pass &all_threads to find_inferior, not &all_lwps.
8479 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
8480 (i386_dr_low_get_status): Ditto.
8481 (x86_linux_prepare_to_resume): Fetch ptid from thread.
8482 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
8483 (x86_linux_read_description): Ditto.
8484 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
8485
8486 2014-02-20 Doug Evans <dje@google.com>
8487
8488 * inferiors.c (get_first_inferior): Fix buglet.
8489
8490 2014-02-19 Doug Evans <dje@google.com>
8491
8492 * gdbthread.h (add_thread): Change result type to struct thread_info *.
8493 * inferiors.c (add_thread): Change result type to struct thread_info *.
8494 All callers updated.
8495 (add_lwp): Call add_thread here instead of in callers.
8496 All callers updated.
8497 * linux-low.h (get_lwp_thread): Rewrite.
8498 (struct lwp_info): New member "thread".
8499
8500 2014-02-19 Doug Evans <dje@google.com>
8501
8502 * linux-low.c (add_lwp): Change result to struct lwp_info *.
8503 All callers updated.
8504
8505 2014-02-19 Doug Evans <dje@google.com>
8506
8507 * inferiors.c (add_thread): Fix whitespace.
8508
8509 2014-02-19 Doug Evans <dje@google.com>
8510
8511 * dll.c (clear_dlls): Replace accessing list implemention details
8512 with API function.
8513 * gdbthread.h (get_first_thread): Declare.
8514 * inferiors.c (for_each_inferior_with_data): New function.
8515 (get_first_thread): New function.
8516 (find_thread_ptid): Simplify.
8517 (get_first_inferior): New function.
8518 (clear_list): Delete.
8519 (one_inferior_p): New function.
8520 (clear_inferior_list): New function.
8521 (clear_inferiors): Update.
8522 * inferiors.h (for_each_inferior_with_data): Declare.
8523 (clear_inferior_list): Declare.
8524 (one_inferior_p): Declare.
8525 (get_first_inferior): Declare.
8526 * linux-low.c (linux_wait_for_event): Replace accessing list
8527 implemention details with API function.
8528 * server.c (target_running): Ditto.
8529 (accumulate_file_name_length): New function.
8530 (emit_dll_description): New function.
8531 (handle_qxfer_libraries): Replace accessing list implemention
8532 details with API function.
8533 (handle_qxfer_threads_worker): New function.
8534 (handle_qxfer_threads_proper): Replace accessing list implemention
8535 details with API function.
8536 (handle_query): Ditto.
8537 (visit_actioned_threads_callback_ftype): New typedef.
8538 (visit_actioned_threads_data): New struct.
8539 (visit_actioned_threads): Rewrite to be find_inferior callback.
8540 (resume): Call find_inferior.
8541 (handle_status): Replace accessing list implemention
8542 details with API function.
8543 (process_serial_event): Replace accessing list implemention details
8544 with API function.
8545 * target.c (set_desired_inferior): Replace accessing list implemention
8546 details with API function.
8547 * tracepoint.c (same_process_p): New function.
8548 (gdb_agent_about_to_close): Replace accessing list implemention
8549 details with API function.
8550 * win32-low.c (child_delete_thread): Replace accessing list
8551 implemention details with API function.
8552 (match_dll_by_basename): New function.
8553 (dll_is_loaded_by_basename): New function.
8554 (win32_ensure_ntdll_loaded): Replace accessing list implemention
8555 details call to dll_is_loaded_by_basename.
8556
8557 2014-02-19 Doug Evans <dje@google.com>
8558
8559 * dll.h (struct dll_info): Add comment.
8560 * gdbthread.h (struct thread_info): Add comment.
8561 (current_ptid): Simplify.
8562 * inferiors.c (add_process): Update.
8563 (remove_process): Update.
8564 * inferiors.h (struct process_info): Rename member "head" to "entry".
8565 * linux-low.c (delete_lwp): Update.
8566 (add_lwp): Update.
8567 (last_thread_of_process_p): Update.
8568 (kill_one_lwp_callback, linux_kill): Update.
8569 (status_pending_p_callback): Update.
8570 (wait_for_sigstop): Update. Simplify read of ptid.
8571 (start_step_over): Update.
8572 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
8573 (get_lwp_thread): Update.
8574 (struct lwp_info): Rename member "head" to "entry".
8575 * regcache.h (inferior_list_entry): Delete.
8576 * server.c (kill_inferior_callback): Update.
8577 (detach_or_kill_inferior_callback): Update.
8578 (print_started_pid): Update.
8579 (print_attached_pid): Update.
8580 (process_serial_event): Simplify read of ptid.
8581 * thread-db.c (thread_db_create_event): Update.
8582 (thread_db_get_tls_address): Update.
8583 * win32-low.c (current_inferior_ptid): Simplify.
8584
8585 2014-02-19 Tom Tromey <tromey@redhat.com>
8586
8587 * target.h (struct target_ops) <supports_btrace>: Add target_ops
8588 argument.
8589 (target_supports_btrace): Update.
8590
8591 2014-02-14 Yao Qi <yao@codesourcery.com>
8592
8593 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
8594 (rsp-low-ipa.o): New target.
8595
8596 2014-02-12 Tom Tromey <tromey@redhat.com>
8597
8598 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
8599 convert_ascii_to_int.
8600 * regcache.c (registers_to_string): Likewise.
8601 * remote-utils.c (decode_M_packet): Likewise.
8602 * server.c (process_serial_event): Likewise.
8603
8604 2014-02-12 Tom Tromey <tromey@redhat.com>
8605
8606 * server.c (handle_query, handle_v_run): Use hex2bin, not
8607 unhexify.
8608 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
8609
8610 2014-02-12 Tom Tromey <tromey@redhat.com>
8611
8612 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
8613 convert_int_to_ascii.
8614 * regcache.c (registers_to_string, collect_register_as_string):
8615 Likewise.
8616 * remote-utils.c (look_up_one_symbol, relocate_instruction):
8617 Likewise.
8618 * server.c (process_serial_event): Likewise.
8619 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
8620 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
8621
8622 2014-02-12 Tom Tromey <tromey@redhat.com>
8623
8624 * remote-utils.c (look_up_one_symbol, monitor_output): Use
8625 bin2hex, not hexify.
8626 * tracepoint.c (cmd_qtstatus): Likewise.
8627
8628 2014-02-12 Tom Tromey <tromey@redhat.com>
8629
8630 * remote-utils.c (monitor_output): Pass explicit length to
8631 hexify.
8632
8633 2014-02-12 Tom Tromey <tromey@redhat.com>
8634
8635 * tracepoint.c: Include rsp-low.h.
8636 * server.c: Include rsp-low.h.
8637 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
8638 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
8639 declare.
8640 * remote-utils.c: Include rsp-low.h.
8641 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
8642 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
8643 (convert_int_to_ascii, convert_ascii_to_int): Move to
8644 common/rsp-low.c.
8645 * regcache.c: Include rsp-low.h.
8646 * ax.c: Include rsp-low.h.
8647 * Makefile.in (SFILES): Add common/rsp-low.c.
8648 (OBS): Add rsp-low.o.
8649 (rsp-low.o): New target.
8650
8651 2014-02-12 Tom Tromey <tromey@redhat.com>
8652
8653 * utils.h (pulongest, plongest, phex_nz): Don't declare.
8654 Include print-utils.h.
8655 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
8656 (plongest, thirty_two, phex_nz): Remove.
8657 * Makefile.in (SFILES): Add common/print-utils.c.
8658 (OBS): Add print-utils.o.
8659 (print-utils-ipa.o): New target.
8660 (print-utils.o): New target.
8661 (IPA_OBJS): Add print-utils-ipa.o.
8662
8663 2014-02-06 Tom Tromey <tromey@redhat.com>
8664
8665 * Makefile.in (SFILES): Fix indentation.
8666
8667 2014-02-05 Doug Evans <dje@google.com>
8668
8669 * linux-low.c (linux_wait_for_event): Improve comment.
8670 (linux_wait_1): Keep current_inferior in sync with event_child.
8671
8672 2014-01-22 Doug Evans <dje@google.com>
8673
8674 * gdbthread.h (gdb_id_to_thread): Delete, unused.
8675
8676 2014-01-22 Doug Evans <dje@google.com>
8677
8678 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
8679 * configure: Regenerate.
8680 * config.in: Regenerate.
8681 * Makefile.in (SFILES): Add debug.c.
8682 (OBS): Add debug.o.
8683 * debug.c: New file.
8684 * debug.h: New file.
8685 * linux-aarch64-low.c (*): Update all debugging printfs to use
8686 debug_printf instead of fprintf.
8687 * linux-arm-low.c (*): Ditto.
8688 * linux-cris-low.c (*): Ditto.
8689 * linux-crisv32-low.c (*): Ditto.
8690 * linux-m32r-low.c (*): Ditto.
8691 * linux-sparc-low.c (*): Ditto.
8692 * linux-x86.c (*): Ditto.
8693 * linux-low.c (*): Ditto.
8694 (linux_wait_1): Add calls to debug_enter, debug_exit.
8695 (linux_wait): Remove redundant debugging printf.
8696 (stop_all_lwps): Add calls to debug_enter, debug_exit.
8697 (linux_resume, unstop_all_lwps): Ditto.
8698 * mem-break.c (*): Update all debugging printfs to use
8699 debug_printf instead of fprintf.
8700 * remote-utils.c (*): Ditto.
8701 * thread-db.c (*): Ditto.
8702 * server.c #include <ctype.h>, "gdb_vecs.h".
8703 (debug_threads): Moved to debug.c.
8704 (*): Update all debugging printfs to use debug_printf instead of
8705 fprintf.
8706 (start_inferior): Replace call to fflush with call to debug_flush.
8707 (monitor_show_help): Mention set debug-format.
8708 (parse_debug_format_options): New function.
8709 (handle_monitor_command): Handle "monitor set debug-format".
8710 (gdbserver_usage): Mention --debug-format.
8711 (main): Parse --debug-format.
8712 * server.h (debug_threads): Declaration moved to debug.h.
8713 #include "debug.h".
8714 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
8715 trace_debug_1 that uses debug_printf.
8716 (tracepoint_look_up_symbols): Update all debugging printfs to use
8717 debug_printf instead of fprintf.
8718
8719 2014-01-20 Baruch Siach <baruch@tkos.co.il>
8720
8721 * linux-xtensa-low.c: Include asm/ptrace.h instead of
8722 sys/ptrace.h.
8723
8724 2014-01-17 Pedro Alves <palves@redhat.com>
8725
8726 PR build/16445
8727 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
8728 defined after including gdb_proc_service.h.
8729
8730 2014-01-16 Doug Evans <dje@google.com>
8731
8732 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
8733 (match_dll): Use it.
8734
8735 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
8736
8737 * target.h (target_ops) <read_btrace>: Change parameters and
8738 return type to allow error reporting.
8739 * server.c (handle_qxfer_btrace): Support delta reads. Pass
8740 trace reading errors on.
8741 * linux-low.c (linux_low_read_btrace): Pass trace reading
8742 errors on.
8743 (linux_low_disable_btrace): New.
8744
8745 2014-01-15 Doug Evans <dje@google.com>
8746
8747 * inferiors.c (thread_id_to_gdb_id): Delete.
8748 * inferiors.h (thread_id_to_gdb_id): Delete.
8749
8750 2014-01-13 Eli Zaretskii <eliz@gnu.org>
8751
8752 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
8753 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
8754 versions.
8755
8756 2014-01-08 Pedro Alves <palves@redhat.com>
8757
8758 * server.c (handle_status): Don't discard previous queued stop
8759 replies or thread's pending status here.
8760 (main) <disconnection>: Do it here instead.
8761
8762 2014-01-08 Pedro Alves <palves@redhat.com>
8763
8764 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
8765 * server.c (visit_actioned_threads, handle_pending_status): New
8766 function.
8767 (handle_v_cont): Factor out parts to ...
8768 (resume): ... this new function. If in all-stop, and a thread
8769 being resumed has a pending status, report it without actually
8770 resuming.
8771 (myresume): Adjust to use the new 'resume' function.
8772 (clear_pending_status_callback, set_pending_status_callback)
8773 (find_status_pending_thread_callback): New functions.
8774 (handle_status): Handle the case of multiple threads having
8775 interesting statuses to report. Report threads' real last signal
8776 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
8777 with an interesting thread to report the status for, instead of
8778 always reporting the status of the first thread.
8779
8780 2014-01-01 Joel Brobecker <brobecker@adacore.com>
8781
8782 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
8783 * gdbreplay.c (gdbreplay_version): Likewise.
8784
8785 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
8786
8787 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
8788 iov.iov_len with the real length in use.
8789
8790 2013-12-13 Joel Brobecker <brobecker@adacore.com>
8791
8792 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
8793 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
8794 for all targets that use win32-low.c.
8795 * win32-low.c (win32_ensure_ntdll_loaded): New function.
8796 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
8797
8798 2013-12-13 Pedro Alves <palves@redhat.com>
8799
8800 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
8801 if equal to TARGET_WAITKIND_LOADED.
8802 * win32-low.c (cached_status): New static global.
8803 (win32_wait): Add declaration.
8804 (do_initial_child_stuff): Flush all initial pending debug events
8805 up to the initial breakpoint.
8806 (win32_wait): If CACHED_STATUS was set, return that instead
8807 of doing a real wait. Remove the code resuming the execution
8808 of the inferior after receiving a TARGET_WAITKIND_LOADED event
8809 during the initial phase. Also remove the code changing
8810 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
8811 TARGET_WAITKIND_STOPPED.
8812
8813 2013-12-11 Yao Qi <yao@codesourcery.com>
8814
8815 * notif.c (handle_notif_ack): Return 0 if no notification
8816 matches.
8817
8818 2013-11-20 Doug Evans <dje@google.com>
8819
8820 * linux-low.c (linux_set_resume_request): Fix comment.
8821
8822 2013-11-20 Doug Evans <dje@google.com>
8823
8824 * linux-low.c (resume_status_pending_p): Tweak comment.
8825
8826 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
8827
8828 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
8829 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
8830 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
8831 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
8832 (srv_amd64_regobj): Add amd64-mpx.o.
8833 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
8834 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
8835 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
8836 * i387-fp.c (num_pl_bnd_register) Added constant.
8837 (num_pl_bnd_cfg_registers) Added constant.
8838 (struct i387_xsave) Added reserved area and MPX fields.
8839 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
8840 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
8841 function.
8842 (tdesc_i386_mpx_linux): Add MPX amd64 target.
8843 (init_registers_amd64_mpx_linux): Declare new function.
8844 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
8845 (x86_64_regmap): Add MPX registers.
8846 (x86_linux_read_description): Add MPX case.
8847 (initialize_low_arch): Initialize MPX targets.
8848
8849 2013-11-18 Tom Tromey <tromey@redhat.com>
8850
8851 * configure: Rebuild.
8852 * configure.ac: Don't check for stdlib.h.
8853 * gdbreplay.c: Unconditionally include stdlib.h.
8854
8855 2013-11-18 Tom Tromey <tromey@redhat.com>
8856
8857 * config.in: Rebuild.
8858 * configure: Rebuild.
8859 * configure.ac: Don't use AC_HEADER_DIRENT.
8860
8861 2013-11-18 Tom Tromey <tromey@redhat.com>
8862
8863 * server.h: Don't check HAVE_STRING_H.
8864 * gdbreplay.c: Don't check HAVE_STRING_H.
8865 * configure: Rebuild.
8866
8867 2013-11-18 Tom Tromey <tromey@redhat.com>
8868
8869 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
8870 LIBGNU.
8871
8872 2013-11-08 Tom Tromey <tromey@redhat.com>
8873
8874 * configure, config.in: Rebuild.
8875 * configure.ac: Remove unused configury.
8876
8877 2013-11-08 Tom Tromey <tromey@redhat.com>
8878
8879 * acinclude.m4: Include common.m4, codeset.m4.
8880 * configure, config.in: Rebuild.
8881 * configure.ac: Use GDB_AC_COMMON.
8882
8883 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
8884
8885 * linux-s390-low.c (HWCAP_S390_TE): New define.
8886 (s390_arch_setup): Consider the TE field in the HWCAP for
8887 determining 'have_regset_tdb'.
8888
8889 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
8890
8891 PR gdb/16014
8892 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
8893 call to sizeof.
8894
8895 2013-10-02 Pedro Alves <palves@redhat.com>
8896
8897 * server.c (process_serial_event): Don't output "GDBserver
8898 exiting" if GDB is connected through stdio.
8899 * target.c (mywait): Likewise, be silent if GDB is connected
8900 through stdio.
8901
8902 2013-10-01 Joel Brobecker <brobecker@adacore.com>
8903
8904 * lynx-low.c (lynx_add_threads_after_attach): New function.
8905 (lynx_attach): Remove call to add_thread. Add call to
8906 lynx_add_threads_after_attach instead.
8907
8908 2013-09-28 Mike Frysinger <vapier@gentoo.org>
8909
8910 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
8911 * config.in, configure: Regenerated.
8912
8913 2013-09-18 Yao Qi <yao@codesourcery.com>
8914
8915 PR server/15959
8916 * server.c (start_inferior): Clear 'resume_info'.
8917
8918 2013-09-16 Jiong Wang <jiwang@tilera.com>
8919
8920 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
8921 for each register.
8922
8923 2013-09-16 Jiong Wang <jiwang@tilera.com>
8924
8925 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
8926 linux-tile-low.o to srv_tgtobj.
8927
8928 2013-09-16 Will Newton <will.newton@linaro.org>
8929
8930 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
8931 out regs.
8932
8933 2013-09-06 Pedro Alves <palves@redhat.com>
8934
8935 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
8936 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
8937 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
8938 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
8939 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
8940 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
8941
8942 2013-09-06 Pedro Alves <palves@redhat.com>
8943
8944 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
8945 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
8946
8947 2013-09-06 Pedro Alves <palves@redhat.com>
8948
8949 * linux-amd64-ipa.c: Include tracepoint.h.
8950 * linux-i386-ipa.c: Include tracepoint.h.
8951
8952 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
8953
8954 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
8955 (ps_get_thread_area): New function.
8956
8957 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
8958
8959 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
8960 (initialize_low_arch): Call init_registers_crisv32 rather than
8961 init_register_crisv32.
8962
8963 2013-09-05 Pedro Alves <palves@redhat.com>
8964
8965 * server.h (handle_vFile, hostio_last_error_from_errno): Move
8966 to ...
8967 * hostio.h: ... this new file.
8968 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
8969 win32-low.c: Include hostio.h.
8970
8971 2013-09-05 Pedro Alves <palves@redhat.com>
8972
8973 * server.h (gdb_client_data, handler_func, callback_handler_func)
8974 (delete_file_handler, add_file_handler, append_callback_event)
8975 (delete_callback_event, start_event_loop, initialize_event_loop):
8976 Move to event-loop.h and include it.
8977 * event-loop.h: New file.
8978
8979 2013-09-05 Pedro Alves <palves@redhat.com>
8980
8981 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
8982 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
8983 (loaded_dll, unloaded_dll): Move to ...
8984 * dll.h: ... this new file.
8985 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
8986
8987 2013-09-05 Pedro Alves <palves@redhat.com>
8988
8989 * server.h (current_process, get_thread_process, all_processes)
8990 (add_inferior_to_list, for_each_inferior, current_inferior)
8991 (remove_inferior, add_process, remove_process, find_process_pid)
8992 (have_started_inferiors_p, have_attached_inferiors_p)
8993 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
8994 (clear_inferiors, find_inferior, find_inferior_id)
8995 (inferior_target_data, set_inferior_target_data)
8996 (inferior_regcache_data, set_inferior_regcache_data): Move to
8997 inferiors.h, and include it.
8998 * inferiors.h: New file.
8999
9000 2013-09-05 Pedro Alves <palves@redhat.com>
9001
9002 * server.h (struct emit_ops, current_insn_ptr, emit_error):
9003 Move ...
9004 * ax.h: ... here.
9005
9006 2013-09-05 Pedro Alves <palves@redhat.com>
9007
9008 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
9009 tracepoint.h.
9010 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
9011 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
9012 (handle_tracepoint_general_set, handle_tracepoint_query)
9013 (tracepoint_finished_step, tracepoint_was_hit)
9014 (release_while_stepping_state_list, current_traceframe)
9015 (in_readonly_region, traceframe_read_mem)
9016 (fetch_traceframe_registers, traceframe_read_sdata)
9017 (traceframe_read_info, struct fast_tpoint_collect_status)
9018 (fast_tracepoint_collecting, force_unlock_trace_buffer)
9019 (handle_tracepoit_bkpts, initialize_low_tracepoint)
9020 (supply_fast_tracepoint_registers)
9021 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
9022 (ipa_tdesc, claim_trampoline_space)
9023 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
9024 (agent_mem_read, agent_get_trace_state_variable_value)
9025 (agent_set_trace_state_variable_value, agent_tsv_read)
9026 (agent_mem_read_string, get_raw_reg_func_addr)
9027 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
9028 * tracepoint.h: ... this new file.
9029
9030 2013-09-05 Pedro Alves <palves@redhat.com>
9031
9032 * server.h (perror_with_name, error, fatal, warning, paddress)
9033 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
9034 include it.
9035 * utils.h: New file.
9036
9037 2013-09-05 Pedro Alves <palves@redhat.com>
9038
9039 * server.h (remote_debug, noack_mode, transport_is_reliable)
9040 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
9041 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
9042 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
9043 (write_enn, initialize_async_io, enable_async_io)
9044 (disable_async_io, check_remote_input_interrupt_request)
9045 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
9046 (dead_thread_notify, prepare_resume_reply)
9047 (decode_address_to_semicolon, decode_address, decode_m_packet)
9048 (decode_M_packet, decode_X_packet, decode_xfer_write)
9049 (decode_search_memory_packet, unhexify, hexify)
9050 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
9051 (look_up_one_symbol, relocate_instruction)
9052 (monitor_output): Move to remote-utils.h, and include it.
9053 * remote-utils.h: New file.
9054
9055 2013-09-05 Pedro Alves <palves@redhat.com>
9056
9057 * server.h (_): Delete.
9058
9059 2013-09-02 Pedro Alves <palves@redhat.com>
9060
9061 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
9062 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
9063 allocated.
9064 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
9065
9066 2013-09-02 Pierre Muller <muller@sourceware.org>
9067
9068 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
9069 or WriteProcessMemory complete successfully and handle
9070 ERROR_PARTIAL_COPY error.
9071
9072 2013-09-02 Pedro Alves <palves@redhat.com>
9073
9074 * server.c (gdb_read_memory): Return -1 on traceframe memory read
9075 error instead of EIO.
9076
9077 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
9078
9079 PR server/15604
9080 * linux-low.c: Include filestuff.h.
9081 (linux_create_inferior) <pid == 0>: Call close_most_fds.
9082 * lynx-low.c: Include filestuff.h.
9083 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
9084 * server.c: Include filestuff.h.
9085 (main): Call notice_open_fds.
9086 * spu-low.c: Include filestuff.h.
9087 (spu_create_inferior) <pid == 0>: Call close_most_fds.
9088
9089 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
9090
9091 * Makefile.in: Explain why ../target and ../nat are not
9092 listed as include file search paths.
9093 (linux-waitpid.o): New object file rule.
9094 * configure.srv (srv_native_linux_obj): New variable.
9095 Replace all occurrences of linux native object files with
9096 $srv_native_linux_obj.
9097 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
9098 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
9099 (linux_enable_event_reporting): Remove declaration.
9100 (my_waitpid): Moved to common/linux-waitpid.c.
9101 (linux_wait_for_event): Pass ptid when calling
9102 linux_enable_event_reporting.
9103 (linux_supports_tracefork_flag): Remove.
9104 (linux_enable_event_reporting): Likewise.
9105 (linux_tracefork_grandchild): Remove.
9106 (STACK_SIZE): Moved to common/linux-ptrace.c.
9107 (linux_tracefork_child): Remove.
9108 (linux_test_for_tracefork): Remove.
9109 (linux_look_up_symbols): Call linux_supports_traceclone.
9110 (initialize_low): Remove call to linux_test_for_tracefork.
9111 * linux-low.h (PTRACE_TYPE_ARG3): Move to
9112 common/linux-ptrace.h.
9113 (PTRACE_TYPE_ARG4): Likewise.
9114 Include linux-ptrace.h.
9115
9116 2013-08-21 Pedro Alves <palves@redhat.com>
9117
9118 * config.in: Renegerate.
9119
9120 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
9121
9122 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
9123 (SFILES): Remove $(srcdir)/common/target-common.c and
9124 add $(srcdir)/target/waitstatus.c.
9125 (OBS): Remove target-common.o and add waitstatus.o.
9126 (server_h): Remove $(srcdir)/../common/target-common.h and
9127 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
9128 and $(srcdir)/../target/waitstatus.h.
9129 (target-common.o): Remove.
9130 (waitstatus.o): New target object file.
9131 * target.h: Do not include target-common.h and
9132 include target/resume.h, target/wait.h and
9133 target/waitstatus.h.
9134
9135 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
9136
9137 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
9138 to PTRACE_TYPE_ARG3.
9139 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
9140 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
9141 PTRACE_TYPE_ARG4.
9142 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
9143 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
9144
9145 2013-07-27 Jie Zhang <jie@codesourcery.com>
9146 Daniel Jacobowitz <dan@codesourcery.com>
9147 Yao Qi <yao@codesourcery.com>
9148
9149 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
9150 (mips-linux-watch.o): New rule.
9151 (mips_linux_watch_h): New variable.
9152 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
9153 srv_tgtobj.
9154 * linux-mips-low.c: Include mips-linux-watch.h.
9155 (struct arch_process_info, struct arch_lwp_info): New.
9156 (update_watch_registers_callback): New function.
9157 (mips_linux_new_process, mips_linux_new_thread) New functions.
9158 (mips_linux_prepare_to_resume, mips_insert_point): New
9159 functions.
9160 (mips_remove_point, mips_stopped_by_watchpoint): New
9161 functions.
9162 (rsp_bp_type_to_target_hw_bp_type): New function.
9163 (mips_stopped_data_address): New function.
9164 (the_low_target): Add watchpoint support functions.
9165
9166 2013-07-27 Yao Qi <yao@codesourcery.com>
9167
9168 * i386-low.c: Include break-common.h.
9169 (enum target_hw_bp_type): Remove.
9170
9171 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
9172
9173 * Makefile.in (SFILES): /common/target-common.c.
9174 (OBS): Add target-common.o.
9175 (server_h): Add $(srcdir)/../common/target-common.h.
9176 (target-common.o): New target.
9177 * server.c (queue_stop_reply_callback): Free
9178 status string after use.
9179 * target.c (target_waitstatus_to_string): Remove.
9180 * target.h: Include target-common.h.
9181 (resume_kind): Likewise.
9182 (target_waitkind): Likewise.
9183 (target_waitstatus): Likewise.
9184 (TARGET_WNOHANG): Likewise.
9185
9186 2013-07-04 Yao Qi <yao@codesourcery.com>
9187
9188 * Makefile.in (host_alias): Use @host_noncanonical@.
9189 (target_alias): Use @target_noncanonical@.
9190 * configure.ac: Use ACX_NONCANONICAL_TARGET and
9191 ACX_NONCANONICAL_HOST.
9192 * configure: Regenerated.
9193
9194 Revert:
9195 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
9196
9197 * configure.ac (version_host, version_target): Set and AC_SUBST them.
9198 * configure: Rebuild.
9199 * Makefile.in (version_host, version_target): Get from configure.
9200 (version.c): Use $(version_host) and $(version_target).
9201
9202 2013-07-03 Pedro Alves <palves@redhat.com>
9203
9204 * Makefile.in (config.status): Depend on development.sh.
9205 * acinclude.m4: Include libmcheck.m4.
9206 * configure: Regenerate.
9207
9208 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
9209
9210 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
9211 attribute inside the parentheses.
9212 (winapi_DebugSetProcessKillOnExit): Ditto.
9213 (winapi_DebugBreakProcess): Ditto.
9214 (winapi_GenerateConsoleCtrlEvent): Ditto.
9215
9216 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
9217
9218 * notif.h (notif_event): Add a dummy member to avoid compiler
9219 errors.
9220
9221 2013-07-01 Pedro Alves <palves@redhat.com>
9222
9223 * hostio.c (HOSTIO_PATH_MAX): Define.
9224 (require_filename, handle_open, handle_unlink, handle_readlink):
9225 Use it.
9226
9227 2013-07-01 Pedro Alves <palves@redhat.com>
9228
9229 * server.h: Include "pathmax.h".
9230 * linux-low.c: Don't include sys/param.h.
9231 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
9232 MAXPATHLEN.
9233 * win32-low.c: Don't include sys/param.h.
9234 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
9235
9236 2013-07-01 Pedro Alves <palves@redhat.com>
9237
9238 * event-loop.c: Don't check HAVE_UNISTD_H before including
9239 <unistd.h>.
9240 * gdbreplay.c: Likewise.
9241 * remote-utils.c: Likewise.
9242 * server.c: Likewise.
9243 * configure.ac: Don't check for unistd.h.
9244 * configure: Regenerate.
9245
9246 2013-06-28 Tom Tromey <tromey@redhat.com>
9247
9248 * Makefile.in (version.c): Use version.in, not
9249 common/version.in.
9250
9251 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
9252
9253 * configure.ac (version_host, version_target): Set and AC_SUBST them.
9254 * configure: Rebuild.
9255 * Makefile.in (version_host, version_target): Get from configure.
9256 (version.c): Use $(version_host) and $(version_target).
9257
9258 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
9259
9260 Fix trace-status to output user name without trailing colon.
9261 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
9262
9263 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
9264
9265 Fix trace-status to output proper start-time and stop-time.
9266 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
9267 output start time and stop time in hex as gdb expects.
9268
9269 2013-06-26 Pedro Alves <pedro@codesourcery.com>
9270
9271 * tracepoint.c (build_traceframe_info_xml): Output trace state
9272 variables present in the trace buffer.
9273
9274 2013-06-24 Tom Tromey <tromey@redhat.com>
9275
9276 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
9277 create-version.sh.
9278 (version.o): Remove.
9279 * gdbreplay.c: Include version.h.
9280 (version, host_name): Don't declare.
9281 * server.h: Include version.h.
9282 (version, host_name): Don't declare.
9283
9284 2013-06-12 Pedro Alves <palves@redhat.com>
9285
9286 * linux-x86-low.c (linux_is_elf64): Delete global.
9287 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
9288 with local linux_pid_exe_is_elf_64_file use.
9289
9290 2013-06-11 Pedro Alves <palves@redhat.com>
9291
9292 * linux-low.c (regset_disabled, disable_regset): New functions.
9293 (regsets_fetch_inferior_registers)
9294 (regsets_store_inferior_registers): Use them.
9295 (initialize_regsets_info); Don't allocate the disabled_regsets
9296 array here.
9297 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
9298 comment.
9299
9300 2013-06-11 Pedro Alves <palves@redhat.com>
9301
9302 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
9303 xmalloc.
9304
9305 2013-06-11 Pedro Alves <palves@redhat.com>
9306
9307 * linux-x86-low.c (initialize_low_arch): Call
9308 init_registers_x32_avx_linux.
9309
9310 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
9311
9312 Fix compatibility with Android Bionic.
9313 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
9314 it is not empty.
9315
9316 2013-06-07 Pedro Alves <palves@redhat.com>
9317
9318 PR server/14823
9319 * Makefile.in (OBS): Add tdesc.o.
9320 (IPA_OBJS): Add tdesc-ipa.o.
9321 (tdesc-ipa.o): New rule.
9322 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
9323 interface.
9324 * linux-low.c (new_inferior): Delete.
9325 (disabled_regsets, num_regsets): Delete.
9326 (linux_add_process): Adjust to set the new per-process
9327 new_inferior flag.
9328 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
9329 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
9330 was a stop. When calling arch_setup, switch the current inferior
9331 to the thread that got an event.
9332 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
9333 (regsets_fetch_inferior_registers)
9334 (regsets_store_inferior_registers): New regsets_info parameter.
9335 Adjust to use it.
9336 (linux_register_in_regsets): New regs_info parameter. Adjust to
9337 use it.
9338 (register_addr, fetch_register, store_register): New usrregs_info
9339 parameter. Adjust to use it.
9340 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
9341 parameter regs_info. Adjust to use it.
9342 (linux_fetch_registers): Get the current inferior's regs_info, and
9343 adjust to use it.
9344 (linux_store_registers): Ditto.
9345 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
9346 (initialize_low): Don't initialize the target_regsets here. Call
9347 initialize_low_arch.
9348 * linux-low.h (target_regsets): Delete declaration.
9349 (struct regsets_info): New.
9350 (struct usrregs_info): New.
9351 (struct regs_info): New.
9352 (struct process_info_private) <new_inferior>: New field.
9353 (struct linux_target_ops): Delete the num_regs, regmap, and
9354 regset_bitmap fields. New field regs_info.
9355 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
9356 * i387-fp.c (num_xmm_registers): Delete.
9357 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
9358 calls to new interface.
9359 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
9360 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
9361 Infer the number of xmm registers from the regcache's target
9362 description.
9363 * i387-fp.h (num_xmm_registers): Delete.
9364 * inferiors.c (add_thread): Don't install the thread's regcache
9365 here.
9366 * proc-service.c (gregset_info): Fetch the current inferior's
9367 regs_info. Adjust to use it.
9368 * regcache.c: Include tdesc.h.
9369 (register_bytes, reg_defs, num_registers)
9370 (gdbserver_expedite_regs): Delete.
9371 (get_thread_regcache): If the thread doesn't have a regcache yet,
9372 create one, instead of aborting gdbserver.
9373 (regcache_invalidate_one): Rename to ...
9374 (regcache_invalidate_thread): ... this.
9375 (regcache_invalidate_one): New.
9376 (regcache_invalidate): Only invalidate registers of the current
9377 process.
9378 (init_register_cache): Add target_desc parameter, and use it.
9379 (new_register_cache): Ditto. Assert the target description has a
9380 non zero registers_size.
9381 (regcache_cpy): Add assertions. Adjust.
9382 (realloc_register_cache, set_register_cache): Delete.
9383 (registers_to_string, registers_from_string): Adjust.
9384 (find_register_by_name, find_regno, find_register_by_number)
9385 (register_cache_size): Add target_desc parameter, and use it.
9386 (free_register_cache_thread, free_register_cache_thread_one)
9387 (regcache_release, register_cache_size): New.
9388 (register_size): Add target_desc parameter, and use it.
9389 (register_data, supply_register, supply_register_zeroed)
9390 (supply_regblock, supply_register_by_name, collect_register)
9391 (collect_register_as_string, collect_register_by_name): Adjust.
9392 * regcache.h (struct target_desc): Forward declare.
9393 (struct regcache) <tdesc>: New field.
9394 (init_register_cache, new_register_cache): Add target_desc
9395 parameter.
9396 (regcache_invalidate_thread): Declare.
9397 (regcache_invalidate_one): Delete declaration.
9398 (regcache_release): Declare.
9399 (find_register_by_number, register_cache_size, register_size)
9400 (find_regno): Add target_desc parameter.
9401 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
9402 declarations.
9403 * remote-utils.c: Include tdesc.h.
9404 (outreg, prepare_resume_reply): Adjust.
9405 * server.c: Include tdesc.h.
9406 (gdbserver_xmltarget): Delete declaration.
9407 (get_features_xml, process_serial_event): Adjust.
9408 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
9409 declare.
9410 (struct process_info) <tdesc>: New field.
9411 (ipa_tdesc): Declare.
9412 * tdesc.c: New file.
9413 * tdesc.h: New file.
9414 * tracepoint.c: Include tdesc.h.
9415 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
9416 (get_context_regcache): Adjust to pass ipa_tdesc down.
9417 (do_action_at_tracepoint): Adjust to get the register cache size
9418 from the context regcache's description.
9419 (traceframe_walk_blocks): Adjust to get the register cache size
9420 from the current trace frame's description.
9421 (traceframe_get_pc): Adjust to get current trace frame's
9422 description and pass it down.
9423 (gdb_collect): Adjust to get the register cache size from the
9424 IPA's description.
9425 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
9426 (gdbserver_xmltarget): Delete.
9427 (initialize_low_tracepoint): Set the ipa's target description.
9428 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
9429 (initialize_low_tracepoint): Set the ipa's target description.
9430 * linux-x86-low.c: Include tdesc.h.
9431 [__x86_64__] (is_64bit_tdesc): New.
9432 (ps_get_thread_area, x86_get_thread_area): Use it.
9433 (i386_cannot_store_register): Rename to ...
9434 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
9435 (i386_cannot_fetch_register): Rename to ...
9436 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
9437 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
9438 to new interface.
9439 (target_regsets): Rename to ...
9440 (x86_regsets): ... this.
9441 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
9442 interface.
9443 (x86_siginfo_fixup): Use is_64bit_tdesc.
9444 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
9445 (tdesc_x32_avx_linux, tdesc_x32_linux)
9446 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
9447 Declare.
9448 (x86_linux_update_xmltarget): Delete.
9449 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
9450 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
9451 (AMD64_LINUX_USER64_CS): New.
9452 (x86_linux_read_description): New, based on
9453 x86_linux_update_xmltarget.
9454 (same_process_callback): New.
9455 (x86_arch_setup_process_callback): New.
9456 (x86_linux_update_xmltarget): New.
9457 (x86_regsets_info): New.
9458 (amd64_linux_regs_info): New.
9459 (i386_linux_usrregs_info): New.
9460 (i386_linux_regs_info): New.
9461 (x86_linux_regs_info): New.
9462 (x86_arch_setup): Reimplement.
9463 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
9464 (x86_emit_ops): Ditto.
9465 (the_low_target): Adjust. Install x86_linux_regs_info,
9466 x86_cannot_fetch_register, and x86_cannot_store_register.
9467 (initialize_low_arch): New.
9468 * linux-ia64-low.c (tdesc_ia64): Declare.
9469 (ia64_fetch_register): Adjust.
9470 (ia64_usrregs_info, regs_info): New globals.
9471 (ia64_regs_info): New function.
9472 (the_low_target): Adjust.
9473 (initialize_low_arch): New function.
9474 * linux-sparc-low.c (tdesc_sparc64): Declare.
9475 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
9476 Adjust.
9477 (sparc_arch_setup): New function.
9478 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
9479 (the_low_target): Adjust.
9480 (initialize_low_arch): New function.
9481 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
9482 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
9483 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
9484 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
9485 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
9486 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
9487 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
9488 (tdesc_powerpc_isa205_vsx64l): Declare.
9489 (ppc_cannot_store_register, ppc_collect_ptrace_register)
9490 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
9491 (ppc_set_pc, ppc_get_hwcap): Adjust.
9492 (ppc_usrregs_info): Forward declare.
9493 (!__powerpc64__) ppc_regmap_adjusted: New global.
9494 (ppc_arch_setup): Adjust to the current process'es target
9495 description.
9496 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
9497 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
9498 (ppc_store_evrregset): Adjust.
9499 (target_regsets): Rename to ...
9500 (ppc_regsets): ... this, and make static.
9501 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
9502 (ppc_regs_info): New function.
9503 (the_low_target): Adjust.
9504 (initialize_low_arch): New function.
9505 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
9506 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
9507 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
9508 (tdesc_s390x_linux64v2): Declare.
9509 (s390_collect_ptrace_register, s390_supply_ptrace_register)
9510 (s390_fill_gregset, s390_store_last_break): Adjust.
9511 (target_regsets): Rename to ...
9512 (s390_regsets): ... this, and make static.
9513 (s390_get_pc, s390_set_pc): Adjust.
9514 (s390_get_hwcap): New target_desc parameter, and use it.
9515 [__s390x__] (have_hwcap_s390_high_gprs): New global.
9516 (s390_arch_setup): Adjust to set the current process'es target
9517 description. Don't adjust the regmap.
9518 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
9519 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
9520 (regs_info_3264): New globals.
9521 (s390_regs_info): New function.
9522 (the_low_target): Adjust.
9523 (initialize_low_arch): New function.
9524 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
9525 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
9526 [__mips64] (init_registers_mips_linux)
9527 (init_registers_mips_dsp_linux): Delete defines.
9528 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
9529 (have_dsp): New global.
9530 (mips_read_description): New, based on mips_arch_setup.
9531 (mips_arch_setup): Reimplement.
9532 (get_usrregs_info): New function.
9533 (mips_cannot_fetch_register, mips_cannot_store_register)
9534 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
9535 (mips_fill_fpregset, mips_store_fpregset): Adjust.
9536 (target_regsets): Rename to ...
9537 (mips_regsets): ... this, and make static.
9538 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
9539 (dsp_regs_info, regs_info): New globals.
9540 (mips_regs_info): New function.
9541 (the_low_target): Adjust.
9542 (initialize_low_arch): New function.
9543 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
9544 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
9545 Declare.
9546 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
9547 (arm_read_description): New, with bits factored from
9548 arm_arch_setup.
9549 (arm_arch_setup): Reimplement.
9550 (target_regsets): Rename to ...
9551 (arm_regsets): ... this, and make static.
9552 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
9553 (arm_regs_info): New function.
9554 (the_low_target): Adjust.
9555 (initialize_low_arch): New function.
9556 * linux-m68k-low.c (tdesc_m68k): Declare.
9557 (target_regsets): Rename to ...
9558 (m68k_regsets): ... this, and make static.
9559 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
9560 (m68k_regs_info): New function.
9561 (m68k_arch_setup): New function.
9562 (the_low_target): Adjust.
9563 (initialize_low_arch): New function.
9564 * linux-sh-low.c (tdesc_sharch): Declare.
9565 (target_regsets): Rename to ...
9566 (sh_regsets): ... this, and make static.
9567 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
9568 (sh_regs_info, sh_arch_setup): New functions.
9569 (the_low_target): Adjust.
9570 (initialize_low_arch): New function.
9571 * linux-bfin-low.c (tdesc_bfin): Declare.
9572 (bfin_arch_setup): New function.
9573 (bfin_usrregs_info, regs_info): New globals.
9574 (bfin_regs_info): New function.
9575 (the_low_target): Adjust.
9576 (initialize_low_arch): New function.
9577 * linux-cris-low.c (tdesc_cris): Declare.
9578 (cris_arch_setup): New function.
9579 (cris_usrregs_info, regs_info): New globals.
9580 (cris_regs_info): New function.
9581 (the_low_target): Adjust.
9582 (initialize_low_arch): New function.
9583 * linux-cris-low.c (tdesc_crisv32): Declare.
9584 (cris_arch_setup): New function.
9585 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
9586 (cris_regs_info): New function.
9587 (the_low_target): Adjust.
9588 (initialize_low_arch): New function.
9589 * linux-m32r-low.c (tdesc_m32r): Declare.
9590 (m32r_arch_setup): New function.
9591 (m32r_usrregs_info, regs_info): New globals.
9592 (m32r_regs_info): Adjust.
9593 (initialize_low_arch): New function.
9594 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
9595 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
9596 (tic6x_usrregs_info): Forward declare.
9597 (tic6x_read_description): New function, based on ...
9598 (tic6x_arch_setup): ... this. Reimplement.
9599 (target_regsets): Rename to ...
9600 (tic6x_regsets): ... this, and make static.
9601 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
9602 (tic6x_regs_info): New function.
9603 (the_low_target): Adjust.
9604 (initialize_low_arch): New function.
9605 * linux-xtensa-low.c (tdesc_xtensa): Declare.
9606 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
9607 (target_regsets): Rename to ...
9608 (xtensa_regsets): ... this, and make static.
9609 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
9610 globals.
9611 (xtensa_arch_setup, xtensa_regs_info): New functions.
9612 (the_low_target): Adjust.
9613 (initialize_low_arch): New function.
9614 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
9615 (nios2_arch_setup): Set the current process'es tdesc.
9616 (target_regsets): Rename to ...
9617 (nios2_regsets): ... this.
9618 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
9619 (nios2_regs_info): New function.
9620 (the_low_target): Adjust.
9621 (initialize_low_arch): New function.
9622 * linux-aarch64-low.c (tdesc_aarch64): Declare.
9623 (aarch64_arch_setup): Set the current process'es tdesc.
9624 (target_regsets): Rename to ...
9625 (aarch64_regsets): ... this.
9626 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
9627 (aarch64_regs_info): New function.
9628 (the_low_target): Adjust.
9629 (initialize_low_arch): New function.
9630 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
9631 globals.
9632 (target_regsets): Rename to ...
9633 (tile_regsets): ... this.
9634 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
9635 (tile_regs_info): New function.
9636 (tile_arch_setup): Set the current process'es tdesc.
9637 (the_low_target): Adjust.
9638 (initialize_low_arch): New function.
9639 * spu-low.c (tdesc_spu): Declare.
9640 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
9641 * win32-arm-low.c (tdesc_arm): Declare.
9642 (arm_arch_setup): New function.
9643 (the_low_target): Install arm_arch_setup instead of
9644 init_registers_arm.
9645 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
9646 (init_windows_x86): Rename to ...
9647 (i386_arch_setup): ... this. Set `win32_tdesc'.
9648 (the_low_target): Adjust.
9649 * win32-low.c (win32_tdesc): New global.
9650 (child_add_thread): Don't create the thread cache here.
9651 (do_initial_child_stuff): Set the new process'es tdesc.
9652 * win32-low.h (struct target_desc): Forward declare.
9653 (win32_tdesc): Declare.
9654 * lynx-i386-low.c (tdesc_i386): Declare global.
9655 (lynx_i386_arch_setup): Set `lynx_tdesc'.
9656 * lynx-low.c (lynx_tdesc): New global.
9657 (lynx_add_process): Set the new process'es tdesc.
9658 * lynx-low.h (struct target_desc): Forward declare.
9659 (lynx_tdesc): Declare global.
9660 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
9661 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
9662 * nto-low.c (nto_tdesc): New global.
9663 (do_attach): Set the new process'es tdesc.
9664 * nto-low.h (struct target_desc): Forward declare.
9665 (nto_tdesc): Declare.
9666 * nto-x86-low.c (tdesc_i386): Declare.
9667 (nto_x86_arch_setup): Set `nto_tdesc'.
9668
9669 2013-06-04 Gary Benson <gbenson@redhat.com>
9670
9671 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
9672 to qSupported response when appropriate.
9673 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
9674 with nonzero-length annex.
9675 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
9676 arguments supplied in annex.
9677
9678 2013-05-31 Doug Evans <dje@google.com>
9679
9680 PR server/15594
9681 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
9682 64 bits in 64-cross-32 environment.
9683
9684 2013-05-28 Pedro Alves <palves@redhat.com>
9685
9686 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
9687 (aarch64-without-fpu.c): Delete rule.
9688 * configure.srv (aarch64*-*-linux*): Remove references to
9689 aarch64-without-fpu.o and aarch64-without-fpu.xml.
9690 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
9691 declaration.
9692
9693 2013-05-24 Pedro Alves <palves@redhat.com>
9694
9695 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
9696 instead of strchr/decode_address. Error if the range isn't split
9697 with a ','. Don't assume there's be a ':' in the action.
9698
9699 2013-05-23 Yao Qi <yao@codesourcery.com>
9700 Pedro Alves <palves@redhat.com>
9701
9702 * linux-low.c (lwp_in_step_range): New function.
9703 (linux_wait_1): If the thread was range stepping and stopped
9704 outside the stepping range, report the stop to GDB. Otherwise,
9705 continue stepping. Add range stepping debug output.
9706 (linux_set_resume_request): Copy the step range from the resume
9707 request to the lwp.
9708 (linux_supports_range_stepping): New.
9709 (linux_target_ops) <supports_range_stepping>: Set to
9710 linux_supports_range_stepping.
9711 * linux-low.h (struct linux_target_ops)
9712 <supports_range_stepping>: New field.
9713 (struct lwp_info) <step_range_start, step_range_end>: New fields.
9714 * linux-x86-low.c (x86_supports_range_stepping): New.
9715 (the_low_target) <supports_range_stepping>: Set to
9716 x86_supports_range_stepping.
9717 * server.c (handle_v_cont): Handle 'r' action.
9718 (handle_v_requests): Append ";r" if the target supports range
9719 stepping.
9720 * target.h (struct thread_resume) <step_range_start,
9721 step_range_end>: New fields.
9722 (struct target_ops) <supports_range_stepping>:
9723 New field.
9724 (target_supports_range_stepping): New macro.
9725
9726 2013-05-17 Joel Brobecker <brobecker@adacore.com>
9727
9728 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
9729 confusion in comment.
9730
9731 2013-05-17 Joel Brobecker <brobecker@adacore.com>
9732
9733 * lynx-low.c (struct process_info_private): New type.
9734 (lynx_add_process): New function.
9735 (lynx_create_inferior, lynx_attach): Replace calls to
9736 add_process by calls to lynx_add_process.
9737 (lynx_resume): If PTID is null, then try using
9738 current_process()->private->last_wait_event_ptid.
9739 Add comments.
9740 (lynx_clear_inferiors): Delete. The contents of that function
9741 has been inlined in lynx_mourn;
9742 (lynx_wait_1): Save the ptid in the process's private data.
9743 (lynx_mourn): Free the process' private data. Replace call
9744 to lynx_clear_inferiors by call to clear_inferiors.
9745
9746 2013-05-17 Yao Qi <yao@codesourcery.com>
9747
9748 * i386-low.c (i386_length_and_rw_bits): Move the comment to
9749 the right place.
9750
9751 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
9752
9753 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
9754 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
9755 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
9756 PT_TEXT_END_ADDR guards. Update comments.
9757 (linux_target_op) <read_offsets>: Conditionally define to
9758 linux_read_offsets if the target is UCLIBC and if it defines
9759 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
9760
9761 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
9762 Andrew Jenner <andrew@codesourcery.com>
9763
9764 * Makefile.in (SFILES): Add linux-nios2-low.c.
9765 (clean): Add action to delete nios2-linux.c.
9766 (nios2-linux.c): New rule.
9767 * configure.srv: Add nios2*-*-linux*.
9768 * linux-nios2-low.c: New.
9769
9770 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
9771
9772 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
9773
9774 2013-04-25 Hui Zhu <hui@codesourcery.com>
9775
9776 PR gdb/15186
9777 * ax.c (ax_printf): Add fflush.
9778
9779 2013-04-22 Tom Tromey <tromey@redhat.com>
9780
9781 * Makefile.in (SFILES): Add filestuff.c.
9782 (OBS): Add filestuff.o.
9783 (filestuff.o): New target.
9784 * config.in, configure: Rebuild.
9785 * configure.ac: Check for fdwalk, pipe2.
9786
9787 2013-04-17 Pedro Alves <palves@redhat.com>
9788
9789 * configure.ac (USE_THREAD_DB): Delete variable.
9790 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
9791 Don't AC_SUBST USE_THREAD_DB.
9792 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
9793 * config.in, configure: Regenerate.
9794
9795 2013-04-16 Pedro Alves <palves@redhat.com>
9796
9797 * linux-low.h (struct lwp_info) <thread_known>: Move under
9798 the USE_THREAD_DB #ifdef.
9799
9800 2013-04-16 Pedro Alves <palves@redhat.com>
9801
9802 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
9803 (linux-low.o): Delete rule.
9804 * linux-low.h: Always include "gdb_thread_db.h" instead of
9805 conditionally including thread_db.h.
9806 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
9807 HAVE_THREAD_DB_H.
9808
9809 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
9810
9811 * Makefile.in (install-only): Fix make install regression.
9812
9813 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
9814
9815 Convert man pages to texinfo, new gdbinit.5 texinfo page.
9816 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
9817 installation.
9818 * gdbserver.1: Remove.
9819
9820 2013-03-22 Pedro Alves <palves@redhat.com>
9821
9822 * linux-low.c (handle_extended_wait): Don't call
9823 linux_enable_event_reporting.
9824
9825 2013-03-15 Tony Theodore <tonyt@logyst.com>
9826
9827 PR build/9098:
9828 * Makefile.in (SHELL): Use @SHELL@.
9829
9830 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
9831
9832 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
9833 compiler warning.
9834
9835 2013-03-13 Joel Brobecker <brobecker@adacore.com>
9836
9837 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
9838 Remove extraneous NULL element.
9839
9840 2013-03-13 Yao Qi <yao@codesourcery.com>
9841
9842 * tracepoint.c (traceframe_read_tsv): Look for the last matched
9843 'V' block in trace frame.
9844
9845 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9846
9847 * target.h (struct target_ops): Add btrace ops.
9848 (target_supports_btrace): New macro.
9849 (target_enable_btrace): New macro.
9850 (target_disable_btrace): New macro.
9851 (target_read_btrace): New macro.
9852 * gdbthread.h (struct thread_info): Add btrace field.
9853 * server.c: Include btrace-common.h.
9854 (handle_btrace_general_set): New function.
9855 (handle_btrace_enable): New function.
9856 (handle_btrace_disable): New function.
9857 (handle_general_set): Call handle_btrace_general_set.
9858 (handle_qxfer_btrace): New function.
9859 (struct qxfer qxfer_packets[]): Add btrace entry.
9860 * inferiors.c (remove_thread): Disable btrace.
9861 * linux-low: Include linux-btrace.h.
9862 (linux_low_enable_btrace): New function.
9863 (linux_low_read_btrace): New function.
9864 (linux_target_ops): Add btrace ops.
9865 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
9866 Add srv_linux_btrace=yes.
9867 (x86_64-*-linux*): Add linux-btrace.o.
9868 Add srv_linux_btrace=yes.
9869 * configure.ac: Define HAVE_LINUX_BTRACE.
9870 * config.in: Regenerated.
9871 * configure: Regenerated.
9872
9873 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9874
9875 * server.c (handle_qxfer): Preserve error message if -3 is
9876 returned.
9877 (qxfer): Document the -3 return value.
9878
9879 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9880
9881 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
9882 (linux_btrace_h): New variable.
9883 (linux-btrace.o): New rule.
9884
9885 2013-03-08 Stan Shebs <stan@codesourcery.com>
9886 Hafiz Abid Qadeer <abidh@codesourcery.com>
9887
9888 * tracepoint.c (trace_buffer_size): New global.
9889 (DEFAULT_TRACE_BUFFER_SIZE): New define.
9890 (init_trace_buffer): Change to one-argument function. Allocate
9891 trace buffer memory.
9892 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
9893 handle QTBuffer:size packet.
9894 (cmd_bigqtbuffer_size): New function.
9895 (initialize_tracepoint): Call init_trace_buffer with
9896 DEFAULT_TRACE_BUFFER_SIZE.
9897 * server.c (handle_query): Add QTBuffer:size in the
9898 supported packets.
9899
9900 2013-03-07 Yao Qi <yao@codesourcery.com>
9901
9902 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
9903 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
9904 of -1.
9905 (cmd_qtsp): Adjust condition. Do post increment.
9906 Set cur_action and cur_step_action back to 0.
9907
9908 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
9909
9910 PR server/15236
9911 * linux-low.c (linux_write_memory): Return early success if LEN is
9912 zero.
9913
9914 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
9915
9916 * configure.srv: Add x86_64-*-cygwin* as target.
9917
9918 2013-02-28 Tom Tromey <tromey@redhat.com>
9919
9920 * configure.ac: Invoke AC_SYS_LARGEFILE.
9921 * configure, config.in: Rebuild.
9922
9923 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
9924
9925 * win32-low.c: Throughout, fix format strings and casts of
9926 printf-like functions to avoid type related warnings on all
9927 platforms.
9928 (get_child_debug_event): Print dwDebugEventCode as hex since
9929 that's how it's usually documented.
9930
9931 2013-02-28 Yao Qi <yao@codesourcery.com>
9932
9933 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
9934 pulongest.
9935
9936 2013-02-27 Jiong Wang <jiwang@tilera.com>
9937
9938 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
9939 (reg-tilegx32.c): New rule.
9940 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
9941 * linux-tile-low.c (tile_arch_setup): New function. Invoke
9942 different register info initializer according to elf class.
9943 (init_registers_tilgx32): New function. The tilegx32 register info
9944 initializer.
9945 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
9946 (tile_store_gregset): Likewise.
9947
9948 2013-02-27 Yao Qi <yao@codesourcery.com>
9949
9950 * server.c (process_point_options): Print debug message when
9951 debug_threads is true.
9952
9953 2013-02-26 Yao Qi <yao@codesourcery.com>
9954
9955 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
9956
9957 2013-02-19 Pedro Alves <palves@redhat.com>
9958 Kai Tietz <ktietz@redhat.com>
9959
9960 PR gdb/15161
9961
9962 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
9963 instead of strtoul to extract address from packet.
9964 (process_serial_event) <'z'>: Likewise.
9965
9966 2013-02-18 Yao Qi <yao@codesourcery.com>
9967
9968 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
9969
9970 2013-02-14 Pedro Alves <palves@redhat.com>
9971
9972 Plug memory leak.
9973
9974 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
9975 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
9976
9977 2013-02-14 Pedro Alves <palves@redhat.com>
9978
9979 * tracepoint.c (cmd_qtdpsrc): Use savestring.
9980
9981 2013-02-14 Pedro Alves <palves@redhat.com>
9982
9983 * tracepoint.c (save_string): Delete.
9984 (add_tracepoint_action): Use savestring instead of save_string.
9985
9986 2013-02-12 Pedro Alves <palves@redhat.com>
9987
9988 * linux-xtensa-low.c: Ditto.
9989 * xtensa-xtregs.c: Ditto.
9990
9991 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
9992
9993 * thread-db.c (thread_db_get_tls_address): NULL pointer check
9994 thread_db.
9995
9996 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
9997
9998 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
9999 aarch64_num_wp_regs and aarch64_num_bp_regs to
10000 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
10001
10002 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
10003
10004 * linux-aarch64-low.c (ps_get_thread_area): Replace
10005 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
10006
10007 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
10008 Marcus Shawcroft <marcus.shawcroft@arm.com>
10009 Nigel Stephens <nigel.stephens@arm.com>
10010 Yufeng Zhang <yufeng.zhang@arm.com>
10011
10012 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
10013 (aarch64.c, aarch64-without-fpu.c): New targets.
10014 * configure.srv (aarch64*-*-linux*): New.
10015 * linux-aarch64-low.c: New file.
10016
10017 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
10018
10019 * linux-low.c (handle_extended_wait, linux_create_inferior)
10020 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
10021 (dequeue_one_deferred_signal, linux_resume_one_thread)
10022 (fetch_register, linux_write_memory, linux_enable_event_reporting)
10023 (linux_tracefork_grandchild, linux_test_for_tracefork)
10024 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
10025 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
10026 where the argument is 0.
10027
10028 2013-01-25 Yao Qi <yao@codesourcery.com>
10029
10030 * event-loop.c: Include "queue.h".
10031 (gdb_event_p): New typedef.
10032 (struct gdb_event) <next_event>: Remove.
10033 (event_queue): Change to QUEUE(gdb_event_p).
10034 (async_queue_event): Remove.
10035 (gdb_event_xfree): New.
10036 (initialize_event_loop): New.
10037 (process_event): Use API from QUEUE.
10038 (wait_for_event): Likewise.
10039 * server.c (main): Call initialize_event_loop.
10040 * server.h (initialize_event_loop): Declare.
10041
10042 2013-01-18 Yao Qi <yao@codesourcery.com>
10043
10044 * ax.h (struct eval_agent_expr_context): New.
10045 (gdb_eval_agent_expr): Update declaration.
10046 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
10047 TFRAME. Add new argument CTX.
10048 * server.h (struct eval_agent_expr_context): Declare.
10049 (agent_mem_read, agent_tsv_read): Update declaration.
10050 (agent_mem_read_string): Likewise.
10051 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
10052 (add_traceframe_block): Add new argument TPOINT.
10053 Increase TPOINT->traceframe_usage.
10054 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
10055 eval_tracepoint_agent_expr.
10056 (condition_true_at_tracepoint): Likewise.
10057 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
10058 (agent_mem_read_string, agent_tsv_read): Likewise.
10059
10060 2013-01-16 Yao Qi <yao@codesourcery.com>
10061
10062 * linux-low.c (linux_resume_one_lwp): Don't check
10063 'lwp->bp_reinsert != 0'.
10064
10065 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10066 Pedro Alves <palves@redhat.com>
10067
10068 * lynx-low.c (ptrace_request_to_str): Define a temporary
10069 macro and use it to simplify this function's implementation.
10070
10071 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10072
10073 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
10074 sets errno.
10075
10076 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10077
10078 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
10079
10080 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10081
10082 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
10083
10084 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10085
10086 * lynx-low.c (lynx_resume): Use the resume_info parameter
10087 to determine the ptid for the lynx_ptrace call, unless
10088 it is equal to minus_one_ptid, in which case we use the
10089 ptid of the current_inferior.
10090 (lynx_wait_1): After having received a thread create/exit
10091 event, resume the inferior's execution using the signaling
10092 thread's ptid, rather than the old ptid.
10093
10094 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10095
10096 * lynx-low.c (lynx_resume): Delete variable ret.
10097
10098 2013-01-01 Joel Brobecker <brobecker@adacore.com>
10099
10100 * gdbreplay.c (gdbreplay_version): Update copyright year.
10101 * server.c (gdbserver_version): Likewise.
10102
10103 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10104
10105 * lynx-low.c (lynx_wait_1): Add debug trace before adding
10106 new thread.
10107
10108 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10109
10110 * lynx-low.c (ptrace_request_to_str): Add handling for
10111 PTRACE_GETTRACESIG.
10112
10113 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10114
10115 * lynx-low.c (lynx_attach): Delete variable new_process.
10116
10117 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10118
10119 * lynx-low.c (lynx_create_inferior): Delete variable
10120 new_process.
10121
10122 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10123
10124 * lynx-low.c (ptrace_request_to_str): Do not handle
10125 PTRACE_GETTHREADLIST if this macro does not exist.
10126
10127 2012-12-15 Yao Qi <yao@codesourcery.com>
10128
10129 * Makefile.in (OBS): Add notif.o.
10130 * notif.c, notif.h: New.
10131 * server.c: Include "notif.h".
10132 (struct vstop_notif) <next>: Remove.
10133 <base>: New field.
10134 (queue_stop_reply): Update.
10135 (push_event, send_next_stop_reply): Remove.
10136 (discard_queued_stop_replies): Update.
10137 (notif_stop): New variable.
10138 (handle_v_stopped): Remove.
10139 (handle_v_requests): Don't call handle_v_stopped. Call
10140 handle_ack_notif instead.
10141 (queue_stop_reply_callback): Call notif_event_enque instead
10142 of queue_stop_reply.
10143 (handle_status): Don't call send_next_stop_reply, call
10144 notif_write_event instead.
10145 (kill_inferior_callback): Likewise.
10146 (detach_or_kill_inferior_callback): Likewise.
10147 (main): Call initialize_notif.
10148 (process_serial_event): Call QUEUE_is_empty.
10149 (handle_target_event): Call notif_push instead of push event.
10150 * server.h (push_event): Remove declaration.
10151
10152 2012-12-10 Tom Tromey <tromey@redhat.com>
10153
10154 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
10155 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
10156 macros.
10157 (.c.o): Rewrite.
10158 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
10159 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
10160 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
10161 (amd64-linux-ipa.o, ax.o): Rewrite.
10162 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
10163 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
10164 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
10165 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
10166 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
10167 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
10168 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
10169 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
10170 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
10171 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
10172 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
10173 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
10174 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
10175 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
10176 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
10177 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
10178 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
10179 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
10180 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
10181 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
10182 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
10183 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
10184 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
10185 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
10186 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
10187 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
10188 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
10189 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
10190 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
10191 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
10192 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
10193 (reg-tilegx.o): Remove.
10194 (all_object_files): New macro.
10195 Include .deps files.
10196 * aclocal.m4, configure: Rebuild.
10197 * acinclude.m4: Include depstand.m4, lead-dot.m4.
10198 * configure.ac: Invoke ZW_CREATE_DEPDIR,
10199 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
10200
10201 2012-12-05 Tom Tromey <tromey@redhat.com>
10202
10203 PR gdb/14917:
10204 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
10205
10206 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
10207
10208 * configure.ac: Check for linux/perf_event.h.
10209 * config.in: Regenerated.
10210 * configure: Regenerated.
10211
10212 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
10213
10214 * hostio.c (handle_readlink): Decrease buffer size
10215 parameter passed to readlink by one byte.
10216
10217 2012-11-26 Yao Qi <yao@codesourcery.com>
10218
10219 * configure.ac (build_warnings): Append '-Wempty-body'.
10220 * configure: Regenerated.
10221 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
10222 body.
10223
10224 2012-11-15 Pierre Muller <muller@sourceware.org>
10225
10226 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
10227 * config.in: Regenerate.
10228 * configure: Regenerate.
10229 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
10230 Use "gdb_wait.h" header instead of <sys/wait.h> header.
10231 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
10232 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
10233 header.
10234 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
10235 instead of <sys/wait.h> header.
10236 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
10237
10238 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
10239
10240 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
10241 (various make rules): Remove -DGDBSERVER
10242
10243 2012-11-09 Yao Qi <yao@codesourcery.com>
10244
10245 * spu-low.c (current_ptid): Move it to ..
10246 * gdbthread.h: ... here. New.
10247 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
10248 * server.c (myresume, process_serial_event): Likewise.
10249 * thread-db.c (thread_db_find_new_threads): Likewise.
10250 * tracepoint.c (run_inferior_command): Likewise.
10251
10252 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
10253
10254 * server.c (handle_search_memory_1): Include access length in
10255 warning message.
10256
10257 2012-09-05 Michael Brandt <michael.brandt@axis.com>
10258
10259 * linux-crisv32-low.c: Fix compile errors.
10260
10261 2012-09-04 Yao Qi <yao@codesourcery.com>
10262
10263 * tracepoint.c (cmd_qtsv): Adjust debug message.
10264 Don't check CUR_TPOINT.
10265
10266 2012-08-28 Yao Qi <yao@codesourcery.com>
10267
10268 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
10269 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
10270 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
10271 Remove declarations of xmalloc, xreallloc, xstrdup and
10272 freeargv.
10273 * Makefile.in (libiberty_h): New.
10274 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
10275 (linux-bfin-low.o): Append dependency 'libiberty.h'.
10276
10277 2012-08-23 Yao Qi <yao@codesourcery.com>
10278
10279 * server.h: Remove declaration of 'xsnprintf'.
10280
10281 2012-08-22 Keith Seitz <keiths@redhat.com>
10282
10283 * server.h: Include build-gnulib-gbserver/config.h.
10284 * gdbreplay.c: Likewise.
10285
10286 2012-08-08 Doug Evans <dje@google.com>
10287
10288 * Makefile.in (SFILES): Add gdb_vecs.c.
10289 (OBS): Add gdb_vecs.o.
10290 (gdb_vecs_h, host_defs_h): New variables.
10291 (thread-db.o): Add $(gdb_vecs_h) dependency.
10292 (gdb_vecs.o): New rule.
10293 * thread-db.c: #include "gdb_vecs.h".
10294 (thread_db_load_search): Use a vector to iterate over path elements.
10295 Handle text appearing after "$pdir".
10296
10297 * configure.ac: Add check for strstr.
10298 * config.in: Regenerate.
10299 * configure: Regenerate.
10300
10301 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
10302
10303 * hostio.c (handle_pread): If pread fails, fall back to attempting
10304 lseek/read.
10305 (handle_pwrite): Likewise for pwrite.
10306
10307 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
10308
10309 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
10310 between unsupported TYPE and unimplementable ADDR/LEN combination.
10311 (arm_insert_point): Act on new return value.
10312
10313 2012-07-31 Pedro Alves <palves@redhat.com>
10314
10315 * server.c (process_point_options): Only skip tokens if we find
10316 one that is unrecognized. Don't treat 'X' specially while
10317 skipping unrecognized tokens.
10318
10319 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
10320
10321 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
10322 to 4-byte-align HW breakpoint addresses for Thumb.
10323
10324 2012-07-27 Yao Qi <yao@codesourcery.com>
10325
10326 PR remote/14161.
10327
10328 * server.h: Declare gdb_agent_about_to_close.
10329 * target.c (kill_inferior): Include "agent.h".
10330 New. Send command 'kill'.
10331 * target.h (kill_inferior): Removed macro.
10332 * tracepoint.c (gdb_agent_about_to_close): New.
10333 (gdb_agent_helper_thread): Handle command 'close'.
10334 Wait endlessly until the inferior stops.
10335 Install gdb_agent_remove_socket to atexit hook.
10336 (agent_socket_name): New static variable.
10337 (gdb_agent_socket_init): Replace local variable 'name' with
10338 'agent_socket_name'.
10339 (gdb_agent_remove_socket): New.
10340
10341 2012-07-27 Yao Qi <yao@codesourcery.com>
10342
10343 * server.c (process_point_options): Stop at 'X' when parsing.
10344
10345 2012-07-19 Michael Eager <eager@eagercon.com>
10346
10347 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
10348 to hw_execute.
10349 * linux-x86-low.c (x86_insert_point, x86_remove_point):
10350 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
10351 hardware breakpoint.
10352
10353 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
10354
10355 * gdbserver/linux-low.c (initialize_low): Call
10356 linux_ptrace_init_warnings.
10357
10358 2012-07-02 Doug Evans <dje@google.com>
10359
10360 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
10361 pointer to int.
10362
10363 2012-07-02 Stan Shebs <stan@codesourcery.com>
10364
10365 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
10366 (ax.o): Add it to build rule.
10367 (ax-ipa.o): Ditto.
10368 (OBS): Add format.o.
10369 (IPA_OBS): Add format.o.
10370 * server.c (handle_query): Claim support for breakpoint commands.
10371 (process_point_options): Add command case.
10372 (process_serial_event): Leave running if there are printfs in
10373 effect.
10374 * mem-break.h (any_persistent_commands): Declare.
10375 (add_breakpoint_commands): Declare.
10376 (gdb_no_commands_at_breakpoint): Declare.
10377 (run_breakpoint_commands): Declare.
10378 * mem-break.c (struct point_command_list): New struct.
10379 (struct breakpoint): New field command_list.
10380 (any_persistent_commands): New function.
10381 (add_commands_to_breakpoint): New function.
10382 (add_breakpoint_commands): New function.
10383 (gdb_no_commands_at_breakpoint): New function.
10384 (run_breakpoint_commands): New function.
10385 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
10386 locally.
10387 * ax.c: Include format.h.
10388 (ax_printf): New function.
10389 (gdb_eval_agent_expr): Add printf opcode.
10390
10391 2012-06-13 Yao Qi <yao@codesourcery.com>
10392
10393 * server.c (start_inferior): Remove duplicated writes to fields
10394 'last_resume_kind' and 'last_status' of 'current_inferior'.
10395
10396 2012-06-12 Yao Qi <yao@codesourcery.com>
10397 Pedro Alves <palves@redhat.com>
10398
10399 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
10400 comment.
10401 * server.c (handle_v_cont): Extend comment.
10402
10403 2012-06-11 Yao Qi <yao@codesourcery.com>
10404
10405 * linux-low.c (linux_attach): Add 'static'.
10406
10407 2012-06-06 Yao Qi <yao@codesourcery.com>
10408
10409 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
10410
10411 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
10412
10413 Fix gcc -flto compilation warning.
10414 * server.c (main): Make variable multi_mode and attach volatile.
10415
10416 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10417
10418 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
10419 if the platform doesn't know about it.
10420
10421 2012-05-30 Jeff Kenton <jkenton@tilera.com>
10422
10423 * Makefile.in (SFILES): Add linux-tile-low.c.
10424 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
10425 * configure.srv: Handle tilegx-*-linux*.
10426 * linux-tile-low.c: New file.
10427
10428 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
10429
10430 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
10431
10432 2012-05-24 Pedro Alves <palves@redhat.com>
10433
10434 PR gdb/7205
10435
10436 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
10437
10438 2012-05-24 Pedro Alves <palves@redhat.com>
10439
10440 PR gdb/7205
10441
10442 Replace target_signal with gdb_signal throughout.
10443
10444 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
10445
10446 * linux-low.c (linux_store_registers): Avoid the copying sequence
10447 when no data has been retrieved by ptrace.
10448
10449 2012-05-22 Will Deacon <will.deacon@arm.com>
10450
10451 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
10452 Include asm/ptrace.h.
10453 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
10454 already defined.
10455
10456 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
10457
10458 * linux-low.c (linux_store_registers): Don't re-retrieve data
10459 with ptrace that has already been obtained from /proc. Always
10460 copy any data retrieved with ptrace to the buffer supplied.
10461
10462 2012-05-11 Yao Qi <yao@codesourcery.com>
10463 Pedro Alves <palves@redhat.com>
10464
10465 * linux-low.c (enum stopping_threads_kind): New.
10466 (stopping_threads): Change type to `enum stopping_threads_kind'.
10467 (handle_extended_wait): If stopping and suspending threads, leave
10468 the new_lwp suspended too.
10469 (linux_wait_for_event): Adjust.
10470 (stop_all_lwps): Set `stopping_threads' to
10471 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
10472 whether we're suspending threads or just stopping them. Assert no
10473 recursion happens.
10474
10475 2012-04-29 Yao Qi <yao@codesourcery.com>
10476
10477 * server.h: Move some code to ...
10478 * gdbthread.h: ... here. New.
10479 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
10480 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
10481 (nto-low.o, win32-low.o): Likewise.
10482 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
10483 * regcache.c, remote-utils.c, server.c: Likewise.
10484 * target.c, tracepoint.c, win32-low.c: Likewise.
10485
10486 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10487
10488 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
10489 (PTRACE_ARG4_TYPE): Likewise.
10490 (PTRACE_XFER_TYPE): Likewise.
10491 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
10492 ptrace to PTRACE_ARG3_TYPE.
10493 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
10494 (PTRACE_ARG4_TYPE): Likewise.
10495 (PTRACE_XFER_TYPE): Likewise.
10496 (linux_detach_one_lwp): Cast fourth argument of
10497 ptrace to long then PTRACE_ARG4_TYPE.
10498 (regsets_fetch_inferior_registers): Cast third argument of
10499 ptrace to long then PTRACE_ARG3_TYPE.
10500 (regsets_store_inferior_registers): Likewise.
10501
10502 2012-04-20 Pedro Alves <palves@redhat.com>
10503
10504 * configure: Regenerate.
10505
10506 2012-04-19 Pedro Alves <palves@redhat.com>
10507
10508 * Makefile.in (GNULIB_BUILDDIR): New.
10509 (LIBGNU, INCGNU, GNULIB_H): Adjust.
10510 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
10511 (all, install-only, uninstall, clean-info, all-lib, clean): No
10512 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
10513 (maintainer-clean realclean distclean): Use subdir_do.
10514 (subdir_do): New.
10515 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
10516 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
10517 * acinclude.m4: Include acx_configure_dir.m4.
10518 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
10519 calls. Call AC_PROG_RANLIB. Configure gnulib using
10520 ACX_CONFIGURE_DIR.
10521 (GNULIB): New.
10522 (GNULIB_STDINT_H): Adjust.
10523 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
10524 * gdbreplay.c: Include build-gnulib/config.h.
10525 * server.h: Likewise.
10526 * aclocal.m4: Regenerate.
10527 * config.in: Regenerate.
10528 * configure: Regenerate.
10529
10530 2012-04-19 Pedro Alves <palves@redhat.com>
10531
10532 * Makefile.in (LIBGNU, INCGNU): Adjust.
10533 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
10534 (all, install-only, uninstall, clean-info, all-lib, clean)
10535 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
10536 * configure.ac: Adjust AC_OUTPUT output.
10537 * aclocal.m4: Regenerate.
10538 * configure: Regenerate.
10539
10540 2012-04-19 Pedro Alves <palves@redhat.com>
10541
10542 * Makefile.in (generated_files): New.
10543 (server_h): Remove the explicit dependency on config.h, and depend
10544 on $generated_files.
10545
10546 2012-04-19 Pedro Alves <palves@redhat.com>
10547
10548 * Makefile.in (INCGNU): Add -Ignulib.
10549
10550 2012-04-19 Pedro Alves <palves@redhat.com>
10551
10552 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
10553 (INCGNU): ... this, and spell out -I here.
10554 (GNULIB_LIB): Rename to ...
10555 (LIBGNU): ... this.
10556 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
10557
10558 2012-04-19 Pedro Alves <palves@redhat.com>
10559
10560 * config.in: Regenerate.
10561
10562 2012-04-19 Pedro Alves <palves@redhat.com>
10563
10564 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
10565 * server.h (memmem): Remove declaration.
10566 * config.in: Regenerate.
10567 * configure: Regenerate.
10568
10569 2012-04-19 Yao Qi <yao@codesourcery.com>
10570
10571 * Makefile.in (SFILES): Add common/vec.c.
10572 (OBS): Add vec.o.
10573 (vec.o): New rule.
10574
10575 2012-04-19 Yao Qi <yao@codesourcery.com>
10576
10577 * remote-utils.c (prepare_resume_reply): Replace with macro
10578 target_core_of_thread.
10579 * server.c (handle_qxfer_threads_proper): Likewise.
10580 * target.h (traget_core_of_thread): New macro.
10581
10582 2012-04-18 Pedro Alves <palves@redhat.com>
10583
10584 * aclocal.m4: Regenerate.
10585 * configure: Regenerate.
10586
10587 2012-04-16 Yao Qi <yao@codesourcery.com>
10588
10589 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
10590 duplicated on address.
10591
10592 2012-04-16 Yao Qi <yao@codesourcery.com>
10593
10594 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
10595 (struct tracepoint_action_ops) <send>: New field.
10596 (m_tracepoint_action_send, r_tracepoint_action_send): New.
10597 (agent_expr_send, x_tracepoint_action_send): New.
10598 (l_tracepoint_action_send): New.
10599 (cmd_qtdp): Download and install tracepoint
10600 according to `use_agent'.
10601 (run_inferior_command): Add one more parameter `len'.
10602 Update callers.
10603 (tracepoint_send_agent): New.
10604 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
10605
10606 2012-04-16 Yao Qi <yao@codesourcery.com>
10607
10608 * tracepoint.c (download_tracepoints): Moved to ...
10609 (cmd_qtstart): ... here.
10610
10611 2012-04-14 Yao Qi <yao@codesourcery.com>
10612
10613 * tracepoint.c: Include inttypes.h.
10614 (struct collect_memory_action): Use sized types.
10615 (struct tracepoint): Likewise.
10616 (cmd_qtdp, stop_tracing): Update print specifiers.
10617 (cmd_qtp, response_tracepoint): Likewise.
10618 (collect_data_at_tracepoint): Likewise.
10619 (collect_data_at_step): Likewise.
10620
10621 2012-04-14 Yao Qi <yao@codesourcery.com>
10622
10623 Import gnulib module inttypes.
10624 * aclocal.m4, config.in, configure: Regenerated.
10625
10626 2012-04-14 Yao Qi <yao@codesourcery.com>
10627
10628 * Makefile.in (maintainer-clean, realclean, distclean): Remove
10629 Makefile and config.status at last.
10630
10631 2012-04-13 Yao Qi <yao@codesourcery.com>
10632
10633 * tracepoint.c: Include stdint.h unconditionally.
10634
10635 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10636
10637 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
10638 on BFD_HAVE_SYS_PROCFS_TYPE.
10639 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
10640 * configure: Regenerate.
10641 * config.in: Likewise.
10642
10643 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
10644
10645 * Makefile.in (clean): Also remove x32.c x32-linux.c
10646 x32-avx.c x32-avx-linux.c.
10647 (x32.o): New target.
10648 (x32.c): Likewise.
10649 (x32-linux.o): Likewise.
10650 (x32-linux.c): Likewise.
10651 (x32-avx.o): Likewise.
10652 (x32-avx.c): Likewise.
10653 (x32-avx-linux.o): Likewise.
10654 (x32-avx-linux.c): Likewise.
10655
10656 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
10657 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
10658 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
10659 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
10660 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
10661 i386/x32-avx-linux.xml.
10662
10663 * linux-x86-low.c (init_registers_x32_linux): New prototype.
10664 (init_registers_x32_avx_linux): Likwise.
10665 (x86_linux_update_xmltarget): Call init_registers_x32_linux
10666 or init_registers_x32_avx_linux if linux_is_elf64 is false.
10667
10668 2012-04-13 Pedro Alves <palves@redhat.com>
10669
10670 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
10671 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
10672 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
10673 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
10674 the sub-make.
10675
10676 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
10677
10678 * linux-x86-low.c (compat_x32_clock_t): New.
10679 (compat_x32_siginfo_t): Likewise.
10680 (compat_x32_siginfo_from_siginfo): Likewise.
10681 (siginfo_from_compat_x32_siginfo): Likewise.
10682 (linux_is_elf64): Likewise.
10683 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
10684 and siginfo_from_compat_x32_siginfo for x32.
10685 (x86_arch_setup): Set linux_is_elf64.
10686
10687 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
10688
10689 PR gdb/13969
10690 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
10691 e_machine field.
10692 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
10693 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
10694 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
10695 compatible with process.
10696
10697 2012-04-12 Yao Qi <yao@codesourcery.com>
10698
10699 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
10700 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
10701 (install-only, install-info, clean): Handle sub dir gnulib.
10702 (all-lib, am--refresh): New targets.
10703 (memmem.o): Remove target.
10704 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
10705 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
10706 (AC_REPLACE_FUNCS): Remove memmem.
10707 Invoke gl_INIT and AM_INIT_AUTOMAKE.
10708 (AC_OUTPUT): Generate Makefile in gnulib/.
10709 * aclocal.m4, config.in, configure: Regenerated.
10710
10711 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
10712
10713 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
10714
10715 2012-04-05 Pedro Alves <palves@redhat.com>
10716
10717 -Werror=strict-aliasing
10718
10719 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
10720 pointer.
10721
10722 2012-04-04 Pedro Alves <palves@redhat.com>
10723
10724 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
10725 (sparc_store_gregset_from_stack, sparc_store_gregset)
10726 (sparc_breakpoint_at): Fix formatting.
10727
10728 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10729
10730 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
10731 are available.
10732 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
10733 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
10734 * config.in: Regenerate.
10735 * configure: Likewise.
10736
10737 2012-03-29 Pedro Alves <palves@redhat.com>
10738
10739 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
10740 Correct ptrace arguments.
10741
10742 2012-03-28 Pedro Alves <palves@redhat.com>
10743
10744 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
10745 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
10746 (IA64_FR1_REGNUM): New defines.
10747 (ia64_fetch_register): New.
10748 (the_low_target): Install it.
10749 * linux-low.h (struct linux_target_ops) <fetch_register>: New
10750 field.
10751 * linux-low.c (linux_fetch_registers): Try the
10752 the_low_target.fetch_register hook first.
10753
10754 * linux-arm-low.c (the_low_target): Adjust.
10755 * linux-bfin-low.c (the_low_target): Adjust.
10756 * linux-cris-low.c (the_low_target): Adjust.
10757 * linux-crisv32-low.c (the_low_target): Adjust.
10758 * linux-m32r-low.c (the_low_target): Adjust.
10759 * linux-m68k-low.c (the_low_target): Adjust.
10760 * linux-mips-low.c (the_low_target): Adjust.
10761 * linux-ppc-low.c (the_low_target): Adjust.
10762 * linux-s390-low.c (the_low_target): Adjust.
10763 * linux-sh-low.c (the_low_target): Adjust.
10764 * linux-sparc-low.c (the_low_target): Adjust.
10765 * linux-tic6x-low.c (the_low_target): Adjust.
10766 * linux-x86-low.c (the_low_target): Adjust.
10767 * linux-xtensa-low.c (the_low_target): Adjust.
10768
10769 2012-03-26 Pedro Alves <palves@redhat.com>
10770
10771 * server.c (handle_qxfer_libraries): Don't bail early if
10772 the_target->qxfer_libraries_svr4 is not NULL.
10773
10774 2012-03-26 Pedro Alves <palves@redhat.com>
10775
10776 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
10777
10778 2012-03-23 Pedro Alves <palves@redhat.com>
10779
10780 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
10781 "library-list-svr4" element's start tag when the the DSO list is
10782 empty.
10783
10784 2012-03-23 Pedro Alves <palves@redhat.com>
10785
10786 * linux-low.c (read_one_ptr): Read the inferior's pointer through
10787 a variable whose type size is the same as the inferior's pointer
10788 size.
10789
10790 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
10791
10792 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
10793 struct siginfo.
10794 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
10795 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
10796 * linux-low.h: Include <signal.h>.
10797 (struct siginfo): Remove forward declaration.
10798 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
10799 struct siginfo.
10800
10801 2012-03-21 Mike Frysinger <vapier@gentoo.org>
10802
10803 * .gitignore: Ignore more files.
10804
10805 2012-03-19 Pedro Alves <palves@redhat.com>
10806 Jan Kratochvil <jan.kratochvil@redhat.com>
10807
10808 * server.c (cont_thread, general_thread): Add describing comments.
10809 (start_inferior): Clear `cont_thread'.
10810 (handle_v_cont): Don't set `cont_thread' if resuming all threads
10811 of a process.
10812
10813 2012-03-15 Yao Qi <yao@codesourcery.com>
10814
10815 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
10816 handling to ...
10817 (cmd_qtdp): ... here.
10818
10819 2012-03-15 Yao Qi <yao@codesourcery.com>
10820
10821 * tracepoint.c (struct tracepoint_action_ops): New.
10822 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
10823 (m_tracepoint_action_download): New.
10824 (r_tracepoint_action_download): New.
10825 (x_tracepoint_action_download): New.
10826 (l_tracepoint_action_download): New.
10827 (add_tracepoint_action): Install `action->ops' according type.
10828 (download_tracepoint_1): Move code `download' function pointer
10829 of various tracepoint_action_ops.
10830
10831 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
10832
10833 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
10834 linux_ptrace_attach_warnings.
10835
10836 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
10837
10838 * Makefile.in (linux-ptrace.o): New.
10839 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
10840 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
10841 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
10842 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
10843 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
10844 of these targets.
10845 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
10846
10847 2012-03-08 Yao Qi <yao@codesourcery.com>
10848 Pedro Alves <palves@redhat.com>
10849
10850 Fix PR server/13392.
10851 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
10852 offset of JMP insn.
10853 * tracepoint.c (remove_tracepoint): New.
10854 (cmd_qtdp): Call remove_tracepoint when failed to install.
10855
10856 2012-03-07 Pedro Alves <palves@redhat.com>
10857
10858 * linux-low.c (get_detach_signal): New.
10859 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
10860 Pass on pending signals to PTRACE_DETACH. Check the result of the
10861 ptrace call.
10862 * server.c (program_signals, program_signals_p): New.
10863 (handle_general_set): Handle QProgramSignals.
10864 * server.h (program_signals, program_signals_p): Declare.
10865
10866 2012-03-05 Pedro Alves <palves@redhat.com>
10867 Jan Kratochvil <jan.kratochvil@redhat.com>
10868
10869 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
10870 New comment why.
10871
10872 2012-03-03 Yao Qi <yao@codesourcery.com>
10873
10874 * tracepoint.c (tracepoint_look_up_symbols): Update call to
10875 agent_look_up_symbols.
10876
10877 2012-03-03 Yao Qi <yao@codesourcery.com>
10878
10879 * Makefile.in (linux-low.o): Keep dependence on agent.h.
10880 (linux-x86-low.o): Likewise.
10881 * server.h: Remove in_process_agent_loaded.
10882 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
10883 common/agent.c.
10884 Update callers.
10885
10886 2012-03-03 Yao Qi <yao@codesourcery.com>
10887
10888 * tracepoint.c (gdb_agent_capability): New global.
10889 (in_process_agent_loaded_ust): Renamed to
10890 `in_process_agent_supports_ust'.
10891 Update callers.
10892 (in_process_agent_supports_ust): Call agent_capability_check.
10893 (clear_installed_tracepoints): Assert that agent supports
10894 agent.
10895
10896 2012-03-03 Yao Qi <yao@codesourcery.com>
10897
10898 * linux-low.c (linux_supports_agent): New.
10899 (linux_target_ops): Initialize field `supports_agent' with
10900 linux_supports_agent.
10901 * target.h (struct target_ops) <supports_agent>: New.
10902 (target_supports_agent): New macro.
10903 * server.c (handle_general_set): Handle packet 'QAgent'.
10904 (handle_query): Send `QAgent+'.
10905 * Makefile.in (server.o): Depends on agent.h.
10906
10907 2012-03-03 Yao Qi <yao@codesourcery.com>
10908
10909 * Makefile.in (OBS): Add agent.o.
10910 Add new rule for agent.o.
10911 Track dependence of tracepoint.c on agent.h.
10912 * tracepoint.c (run_inferior_command_1):
10913 (run_inferior_command): Call agent_run_command.
10914 (gdb_ust_connect_sync_socket): Deleted. Move it to
10915 common/agent.c.
10916 (resume_thread, stop_thread): Likewise.
10917 (gdb_ust_socket_init): Renamed to ...
10918 (gdb_agent_socket_init): ... New.
10919 (gdb_ust_thread): Renamed to ...
10920 (gdb_agent_helper_thread): ... New.
10921 (gdb_ust_init): Move some code to ...
10922 (gdb_agent_init): ... here. New.
10923 [HAVE_UST]: Call gdb_ust_init.
10924 (initialize_tracepoint_ftlib): Call gdb_agent_init.
10925 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
10926 * config.in, configure: Regenerated.
10927
10928 2012-03-02 Pedro Alves <palves@redhat.com>
10929
10930 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
10931 * linux-low.c (struct simple_pid_list): New.
10932 (stopped_pids): New a struct simple_pid_list pointer.
10933 (add_to_pid_list, pull_pid_from_list): New.
10934 (handle_extended_wait): Don't assume the first signal new children
10935 report is SIGSTOP. Adjust call to pull_pid_from_list.
10936 (linux_wait_for_lwp): Adjust.
10937
10938 2012-03-02 Yao Qi <yao@codesourcery.com>
10939
10940 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
10941 debug log.
10942
10943 2012-03-02 Yao Qi <yao@codesourcery.com>
10944
10945 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
10946 `stop_pc' and `tpoint'. Update caller.
10947
10948 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
10949
10950 * linux-low.h (linux_target_ops): Add regset_bitmap member.
10951 * linux-low.c (use_linux_regsets): New macro.
10952 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
10953 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
10954 (linux_register_in_regsets): New function.
10955 (usr_fetch_inferior_registers): Skip registers covered by
10956 regsets.
10957 (usr_store_inferior_registers): Likewise.
10958 (usr_fetch_inferior_registers): New macro.
10959 (usr_store_inferior_registers): Likewise.
10960 (linux_fetch_registers): Handle mixed regset/non-regset targets.
10961 (linux_store_registers): Likewise.
10962 * linux-mips-low.c (init_registers_mips_dsp_linux): New
10963 prototype.
10964 (init_registers_mips64_dsp_linux): Likewise.
10965 (init_registers_mips_linux): New macro.
10966 (init_registers_mips_dsp_linux): Likewise.
10967 (mips_dsp_num_regs): Likewise.
10968 (DSP_BASE, DSP_CONTROL): New fallback macros.
10969 (mips_base_regs): New macro.
10970 (mips_regmap): Use it. Fix the size.
10971 (mips_dsp_regmap): New variable.
10972 (mips_dsp_regset_bitmap): Likewise.
10973 (mips_arch_setup): New function.
10974 (mips_cannot_fetch_register): Use the_low_target.regmap rather
10975 than mips_regmap.
10976 (mips_cannot_store_register): Likewise.
10977 (the_low_target): Update .arch_setup, .num_regs and .regmap
10978 initializers. Add .regset_bitmap initializer.
10979 * linux-arm-low.c (the_low_target): Add .regset_bitmap
10980 initializer.
10981 * linux-bfin-low.c (the_low_target): Likewise.
10982 * linux-cris-low.c (the_low_target): Likewise.
10983 * linux-crisv32-low.c (the_low_target): Likewise.
10984 * linux-ia64-low.c (the_low_target): Likewise.
10985 * linux-m32r-low.c (the_low_target): Likewise.
10986 * linux-m68k-low.c (the_low_target): Likewise.
10987 * linux-ppc-low.c (the_low_target): Likewise.
10988 * linux-s390-low.c (the_low_target): Likewise.
10989 * linux-sh-low.c (the_low_target): Likewise.
10990 * linux-sparc-low.c (the_low_target): Likewise.
10991 * linux-tic6x-low.c (the_low_target): Likewise.
10992 * linux-x86-low.c (the_low_target): Likewise.
10993 * linux-xtensa-low.c (the_low_target): Likewise.
10994 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
10995 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
10996 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
10997 srv_xmlfiles.
10998 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
10999 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
11000
11001 2012-02-29 Yao Qi <yao@codesourcery.com>
11002 Pedro Alves <palves@redhat.com>
11003
11004 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
11005 `step_over_finished' is true.
11006
11007 2012-02-27 Pedro Alves <palves@redhat.com>
11008
11009 * linux-low.c (pid_is_stopped): Delete, moved to common/.
11010 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
11011
11012 2012-02-27 Pedro Alves <palves@redhat.com>
11013
11014 PR server/9684
11015 * linux-low.c (pid_is_stopped): New.
11016 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
11017
11018 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
11019
11020 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
11021 of conditions.
11022
11023 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
11024
11025 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
11026
11027 2012-02-24 Luis Machado <lgustavo@codesourcery>
11028
11029 * server.c (handle_query): Advertise support for target-side
11030 breakpoint condition evaluation.
11031 (process_point_options): New function.
11032 (process_serial_event): When inserting a breakpoint, check for
11033 a target-side condition that should be evaluated.
11034
11035 * mem-break.c: Include regcache.h and ax.h.
11036 (point_cond_list_t): New data structure.
11037 (breakpoint) <cond_list>: New field.
11038 (find_gdb_breakpoint_at): Make non-static.
11039 (delete_gdb_breakpoint_at): Clear any target-side
11040 conditions.
11041 (clear_gdb_breakpoint_conditions): New function.
11042 (add_condition_to_breakpoint): Likewise.
11043 (add_breakpoint_condition): Likewise.
11044 (gdb_condition_true_at_breakpoint): Likewise.
11045 (gdb_breakpoint_here): Return result directly instead
11046 of going through a local variable.
11047
11048 * mem-break.h (find_gdb_breakpoint_at): New prototype.
11049 (clear_gdb_breakpoint_conditions): Likewise.
11050 (add_breakpoint_condition): Likewise.
11051 (gdb_condition_true_at_breakpoint): Likewise.
11052
11053 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
11054 (need_step_over_p): Take target-side breakpoint condition into
11055 consideration.
11056
11057 2012-02-24 Luis Machado <lgustavo@codesourcery>
11058
11059 * server.h: Include tracepoint.h.
11060 (agent_mem_read, agent_get_trace_state_variable_value,
11061 agent_set_trace_state_variable_value,
11062 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
11063 get_set_tsv_func_addr): New prototypes.
11064
11065 * ax.h: New include file.
11066 * ax.c: New source file.
11067
11068 * tracepoint.c: Include ax.h.
11069 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
11070 agent_expr, eval_result_type): Move to ax.h.
11071 (parse_agent_expr): Rename to ...
11072 (gdb_parse_agent_expr): ... this, make it non-static and move
11073 to ax.h.
11074 (unparse_agent_expr) Rename to ...
11075 (gdb_unparse_agent_expr): ... this, make it non-static and move
11076 to ax.h.
11077 (eval_agent_expr): Rename to ...
11078 (eval_tracepoint_agent_expr): ... this.
11079 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
11080 forward declarations.
11081 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
11082 (agent_get_trace_state_variable_value): New function.
11083 (agent_set_trace_state_variable_value): New function.
11084 (cmd_qtdp): Call gdb_parse_agent_expr (...).
11085 (response_tracepoint): Call gdb_unparse_agent_expr (...).
11086 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
11087 (condition_true_at_tracepoint): Likewise.
11088 (parse_agent_expr): Rename to ...
11089 (gdb_parse_agent_expr): ... this and move to ax.c.
11090 (unparse_agent_expr): Rename to ...
11091 (gdb_unparse_agent_expr): ... this and move to ax.c.
11092 (gdb_agent_op_name): Move to ax.c.
11093 (eval_agent_expr): Rename to ...
11094 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
11095 and move to ax.c.
11096 (eval_tracepoint_agent_expr): New function.
11097 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
11098 non-static.
11099 (current_insn_ptr, emit_error, struct bytecode_address): Move to
11100 ax.c.
11101 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
11102 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
11103 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
11104 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
11105 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
11106 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
11107 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
11108 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
11109 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
11110 (compile_bytecodes): Remove forward declaration.
11111 (is_goto_target): Move to ax.c.
11112 (compile_bytecodes): Move to ax.c and call
11113 agent_get_trace_state_variable_value (...) and
11114 agent_set_trace_state_variable_value (...).
11115
11116 * Makefile.in: Update ax.c and IPA dependencies.
11117
11118 2012-02-24 Pedro Alves <palves@redhat.com>
11119
11120 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
11121 (cmd_bigqtbuffer_circular): ... this. Only handle
11122 'QTBuffer:circular:'.
11123 (handle_tracepoint_general_set): Adjust.
11124
11125 2012-02-16 Yao Qi <yao@codesourcery.com>
11126
11127 * inferiors.c: Move code to ...
11128 * dll.c: .... here. New.
11129 * server.h: Declare clear_dlls.
11130 * Makefile.in (SFILES): Add dll.c.
11131 (OBS): Add dll.o
11132 (dll.o): New rule.
11133
11134 2012-02-11 Yao Qi <yao@codesourcery.com>
11135
11136 * server.c: (handle_monitor_command): Add a new parameter
11137 `own_buf'.
11138 (handle_query): Update caller.
11139
11140 2012-02-09 Joel Brobecker <brobecker@adacore.com>
11141
11142 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
11143 * configure, config.in: Regenerate.
11144 * hostio.c: Provide an alternate implementation if HAVE_READLINK
11145 is not defined.
11146
11147 2012-02-02 Pedro Alves <palves@redhat.com>
11148
11149 Try SIGKILL first, then PTRACE_KILL.
11150 * linux-low.c (linux_kill_one_lwp): New.
11151 (linux_kill_one_lwp): Rename to ...
11152 (kill_one_lwp_callback): ... this. Use the new
11153 linux_kill_one_lwp.
11154
11155 2012-02-02 Pedro Alves <palves@redhat.com>
11156
11157 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
11158 inferior.
11159
11160 2012-01-27 Pedro Alves <palves@redhat.com>
11161
11162 * linux-low.c (linux_child_pid_to_exec_file): Delete.
11163 (elf_64_file_p): Make static.
11164 (linux_pid_exe_is_elf_64_file): New.
11165 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
11166 Delete declarations.
11167 (linux_pid_exe_is_elf_64_file): Declare.
11168 * linux-x86-low.c (x86_arch_setup): Use
11169 linux_pid_exe_is_elf_64_file.
11170
11171 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
11172
11173 * linux-low.c (linux_wait_for_event_1): Rename to ...
11174 (linux_wait_for_event): ... here and merge it with former
11175 linux_wait_for_event - new variable wait_ptid, use it.
11176 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
11177
11178 2012-01-23 Pedro Alves <palves@redhat.com>
11179
11180 * server.c (main): Avoid yet another case of infinite loop while
11181 detaching/killing after a longjmp.
11182
11183 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
11184
11185 Code cleanup.
11186 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
11187
11188 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
11189
11190 * hostio.c (handle_readlink): New function.
11191 (handle_vFile): Call it to handle "vFile:readlink" packets.
11192
11193 2012-01-20 Pedro Alves <palves@redhat.com>
11194 Ulrich Weigand <ulrich.weigand@linaro.org>
11195
11196 * server.c (handle_v_requests): Only support vAttach and vRun to
11197 start multiple processes when in extended protocol mode.
11198
11199 2012-01-17 Pedro Alves <palves@redhat.com>
11200
11201 * tracepoint.c (initialize_tracepoint): Use mmap instead of
11202 memalign plus mprotect to allocate the scratch buffer.
11203
11204 2012-01-13 Pedro Alves <palves@redhat.com>
11205
11206 * server.c (attach_inferior): Clear `cont_thread'.
11207
11208 2012-01-13 Pedro Alves <palves@redhat.com>
11209
11210 * server.c (main): Avoid infinite loop while detaching/killing
11211 after a longjmp.
11212
11213 2012-01-09 Doug Evans <dje@google.com>
11214
11215 * server.c (start_inferior): Set last_ptid in --wrapper case.
11216
11217 2012-01-06 Yao Qi <yao@codesourcery.com>
11218
11219 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
11220 defined.
11221 [IN_PROCESS_AGENT] (debug_agent): New global variable.
11222
11223 2012-01-04 Yao Qi <yao@codesourcery.com>
11224
11225 * tracepoint.c (cmd_qtdp): Print debug message
11226 for static tracepoint.
11227
11228 2012-01-04 Yao Qi <yao@codesourcery.com>
11229
11230 * tracepoint.c (trace_vdebug): Differentiate debug message
11231 between gdbserver and IPA.
11232
11233 2012-01-03 Yao Qi <yao@codesourcery.com>
11234
11235 * tracepoint.c (tracepoint_was_hit): Don't collect for
11236 static tracepoint.
11237
11238 2012-01-02 Joel Brobecker <brobecker@adacore.com>
11239
11240 * terminal.h: Reformat copyright header.
11241
11242 2012-01-02 Joel Brobecker <brobecker@adacore.com>
11243
11244 * server.c (gdbserver_version): Update copyright year.
11245 * gdbreplay.c (gdbreplay_version): Likewise.
11246
11247 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
11248
11249 * linux-low.c (linux_create_inferior): Put empty if clause for write.
11250
11251 Revert:
11252 2011-12-18 Hui Zhu <teawater@gmail.com>
11253 * linux-low.c (linux_create_inferior): Save return value to ret.
11254
11255 2011-12-18 Hui Zhu <teawater@gmail.com>
11256
11257 * linux-low.c (linux_create_inferior): Save return value to ret.
11258
11259 2011-12-16 Doug Evans <dje@google.com>
11260
11261 * linux-low.c (linux_create_inferior): If stdio connection,
11262 redirect stdin from /dev/null, stdout to stderr.
11263 * remote-utils.c (remote_is_stdio): New static global.
11264 (remote_connection_is_stdio): New function.
11265 (remote_prepare): Handle stdio connection.
11266 (remote_open): Ditto.
11267 (remote_close): Don't close stdin for stdio connections.
11268 (read_prim,write_prim): New functions. Replace all calls to
11269 read/write to these.
11270 * server.c (main): Watch for "-" argument. Move call to
11271 remote_prepare before start_inferior.
11272 * server.h (STDIO_CONNECTION_NAME): New macro.
11273 (remote_connection_is_stdio): Declare.
11274
11275 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
11276 in debugging output.
11277
11278 2011-12-15 Yao Qi <yao@codesourcery.com>
11279
11280 * tracepoint.c: Include sys/syscall.h.
11281 (gdb_ust_thread): Remove preprocessor conditional.
11282
11283 2011-12-14 Pedro Alves <pedro@codesourcery.com>
11284
11285 * linux-low.c (linux_detach_one_lwp): Call
11286 the_low_target.prepare_to_resume before detaching.
11287
11288 2011-12-14 Yao Qi <yao@codesourcery.com>
11289
11290 * tracepoint.c (gdb_ust_thread): Don't ignore return value
11291 of write.
11292
11293 2011-12-14 Yao Qi <yao@codesourcery.com>
11294
11295 * i386-low.c (i386_low_stopped_data_address): Initialize local
11296 variable `control'.
11297
11298 2011-12-13 Pedro Alves <pedro@codesourcery.com>
11299
11300 PR remote/13492
11301
11302 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
11303 DR_CONTROL unless necessary. Extend comments.
11304 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
11305 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
11306
11307 2011-12-13 Yao Qi <yao@codesourcery.com>
11308
11309 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
11310 macros.
11311 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
11312
11313 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
11314
11315 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
11316 Print new debug message for such case.
11317
11318 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
11319
11320 Fix overlapping memcpy.
11321 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
11322 the read_inferior_memory transfer.
11323 (delete_fast_tracepoint_jump): New variable buf. Use it for the
11324 write_inferior_memory transfer.
11325 (set_fast_tracepoint_jump): New variable buf. Use it for the
11326 read_inferior_memory and write_inferior_memory transfers.
11327 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
11328 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
11329 Use it for the write_inferior_memory transfer.
11330 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
11331 buffers.
11332
11333 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
11334
11335 * linux-low.c (fetch_register, store_register): Make code
11336 consistent, fix formatting.
11337
11338 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
11339
11340 * linux-low.c (usr_store_inferior_registers): Factor out code
11341 to handle individual registers into...
11342 (store_register): ... this new function.
11343
11344 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
11345
11346 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
11347 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
11348 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
11349 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
11350 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
11351 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
11352 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
11353 (srv_xmlfiles): Add new XML files.
11354
11355 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
11356 and <sys/uio.h>.
11357 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
11358 (init_registers_s390_linux32v1): Add prototype.
11359 (init_registers_s390_linux32v2): Likewise.
11360 (init_registers_s390_linux64v1): Likewise.
11361 (init_registers_s390_linux64v2): Likewise.
11362 (init_registers_s390x_linux64v1): Likewise.
11363 (init_registers_s390x_linux64v2): Likewise.
11364 (s390_num_regs): Increment to 52.
11365 (s390_regmap): Add orig_r2 register.
11366 (s390_num_regs_3264): Increment to 68.
11367 (s390_regmap_3264): Add orig_r2 register.
11368 (s390_collect_ptrace_register): Handle orig_r2 register.
11369 (s390_supply_ptrace_register): Likewise.
11370 (s390_fill_last_break): New function.
11371 (s390_store_last_break): Likewise.
11372 (s390_fill_system_call): New function.
11373 (s390_store_system_call): Likewise.
11374 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
11375 register sets.
11376 (s390_check_regset): New function.
11377 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
11378 NT_S390_SYSTEM_CALL regsets and use appropriate description.
11379 Update target_regsets for available register sets.
11380
11381 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
11382 Jan Kratochvil <jan.kratochvil@redhat.com>
11383
11384 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
11385 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
11386 New.
11387 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
11388 * linux-low.h (struct process_info_private): New member r_debug.
11389 * server.c (handle_qxfer_libraries): Call
11390 the_target->qxfer_libraries_svr4.
11391 (handle_qxfer_libraries_svr4): New function.
11392 (qxfer_packets): New entry "libraries-svr4".
11393 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
11394 * target.h (struct target_ops): New member qxfer_libraries_svr4.
11395 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
11396 PACKET_qXfer_libraries_svr4.
11397
11398 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
11399
11400 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
11401 PSW address/mask between 8-byte and 16-byte formats.
11402 (s390_supply_ptrace_register): Likewise.
11403 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
11404 basic addressing mode bit.
11405
11406 2011-11-24 Stan Shebs <stan@codesourcery.com>
11407
11408 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
11409
11410 2011-11-17 Stan Shebs <stan@codesourcery.com>
11411
11412 * tracepoint.c (struct tracepoint): New field traceframe_usage.
11413 (tracing_start_time): New global.
11414 (tracing_stop_time): New global.
11415 (tracing_user_name): New global.
11416 (tracing_notes): New global.
11417 (tracing_stop_note): New global.
11418 (cmd_qtstart): Set traceframe_usage, start_time.
11419 (stop_tracing): Set stop_time.
11420 (cmd_qtstatus): Report additional status.
11421 (cmd_qtp): New function.
11422 (handle_tracepoint_query): Call it.
11423 (cmd_qtnotes): New function.
11424 (handle_tracepoint_general_set): Call it.
11425 (get_timestamp): Rename from tsv_get_timestamp.
11426
11427 2011-11-14 Stan Shebs <stan@codesourcery.com>
11428 Kwok Cheung Yeung <kcy@codesourcery.com>
11429
11430 * linux-x86-low.c (small_jump_insn): New.
11431 (i386_install_fast_tracepoint_jump_pad): Add arguments for
11432 trampoline and error message, build a trampoline and issue a small
11433 jump instruction to it.
11434 (x86_install_fast_tracepoint_jump_pad): Add arguments for
11435 trampoline and error message.
11436 (x86_get_min_fast_tracepoint_insn_len): New.
11437 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
11438 * linux-low.h (struct linux_target_ops): Add arguments to
11439 install_fast_tracepoint_jump_pad operation, add new operation.
11440 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
11441 arguments.
11442 (linux_get_min_fast_tracepoint_insn_len): New function.
11443 (linux_target_op): Add new operation.
11444 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
11445 (gdb_trampoline_buffer_end): Ditto.
11446 (gdb_trampoline_buffer_error): Ditto.
11447 (struct ipa_sym_addresses): Add fields for new IPA variables.
11448 (symbol_list): Add entries for new IPA variables.
11449 (struct tracepoint): Add fields to hold the address range of the
11450 trampoline used by the tracepoint.
11451 (trampoline_buffer_head): New static variable.
11452 (trampoline_buffer_tail): Ditto.
11453 (claim_trampoline_space): New function.
11454 (have_fast_tracepoint_trampoline_buffer): New function.
11455 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
11456 structure.
11457 (install_fast_tracepoint): Ditto, also add error buffer argument.
11458 (cmd_qtminftpilen): New function.
11459 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
11460 (fast_tracepoint_from_trampoline_address): New function.
11461 (fast_tracepoint_collecting): Handle trampoline as part of jump
11462 pad space.
11463 (set_trampoline_buffer_space): New function.
11464 (initialize_tracepoint): Initialize new IPA variables.
11465 * target.h (struct target_ops): Add arguments to
11466 install_fast_tracepoint_jump_pad operation, add new
11467 get_min_fast_tracepoint_insn_len operation.
11468 (target_get_min_fast_tracepoint_insn_len): New.
11469 (install_fast_tracepoint_jump_pad): Add arguments.
11470 * server.h (IPA_BUFSIZ): Define.
11471 * linux-i386-ipa.c: Include extra header files.
11472 (initialize_fast_tracepoint_trampoline_buffer): New function.
11473 (initialize_low_tracepoint): Call it.
11474 * server.h (set_trampoline_buffer_space): Declare.
11475 (claim_trampoline_space): Ditto.
11476 (have_fast_tracepoint_trampoline_buffer): Ditto.
11477
11478 2011-11-14 Yao Qi <yao@codesourcery.com>
11479
11480 * server.c (handle_query): Handle InstallInTrace for qSupported.
11481 * tracepoint.c (add_tracepoint): Sort list.
11482 (install_tracepoint, download_tracepoint): New.
11483 (cmd_qtdp): Call them to install and download tracepoints.
11484 (sort_tracepoints): Removed.
11485 (cmd_qtstart): Update.
11486
11487 2011-11-14 Yao Qi <yao@codesourcery.com>
11488
11489 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
11490 * mem-break.h: Declare.
11491 * tracepoint.c (cmd_qtstart): Move some code to ...
11492 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
11493 New.
11494 (download_tracepoints): Move some code to ...
11495 (download_tracepoint_1): ... here. New.
11496
11497 2011-11-08 Yao Qi <yao@codesourcery.com>
11498
11499 * remote-utils.c (relocate_instruction): A comment fix.
11500
11501 2011-11-07 Joel Brobecker <brobecker@adacore.com>
11502
11503 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
11504 (i386_dr_low_get_control, i386_dr_low_get_status): Use
11505 dr_status_mirror and dr_control_mirror from debug_reg_state.
11506 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
11507 (i386_initial_stuff): Remove use of deleted globals.
11508 (i386_get_thread_context, i386_set_thread_context,
11509 i386_thread_added): Use dr_status_mirror and dr_control_mirror
11510 from debug_reg_state.
11511
11512 2011-11-05 Yao Qi <yao@codesourcery.com>
11513
11514 * tracepoint.c (gdb_collect): Loop over tracepoints of same
11515 address as TPOINT's.
11516
11517 2011-11-02 Stan Shebs <stan@codesourcery.com>
11518
11519 * tracepoint.c (agent_mem_read_string): New function.
11520 (eval_agent_expr): Call it for tracenz.
11521 * server.c (handle_query): Report support for tracenz.
11522
11523 2011-11-02 Yao Qi <yao@codesourcery.com>
11524
11525 * tracepoint.c (cmd_qtstart): Remove unused local variables.
11526
11527 2011-11-02 Yao Qi <yao@codesourcery.com>
11528
11529 * target.h: Fix a typo in comment.
11530
11531 2011-10-31 Pedro Alves <pedro@codesourcery.com>
11532
11533 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
11534 clobber the breakpoints' shadows with fast tracepoint jumps.
11535 * mem-break.h (check_mem_write): Add `myaddr' parameter.
11536 * target.c (write_inferior_memory): Also pass MYADDR down to
11537 check_mem_write.
11538
11539 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
11540
11541 * configure.ac: Check support for personality routine.
11542 * configure: Regenerate.
11543 * config.in: Likewise.
11544 * linux-low.c: Include <sys/personality.h>.
11545 Define ADDR_NO_RANDOMIZE if necessary.
11546 (linux_create_inferior): Disable address space randomization when
11547 forking inferior, if requested.
11548 (linux_supports_disable_randomization): New function.
11549 (linux_target_ops): Install it.
11550 * server.h (disable_randomization): Declare.
11551 * server.c (disable_randomization): New global variable.
11552 (handle_general_set): Handle QDisableRandomization.
11553 (handle_query): Likewise for qSupported.
11554 (main): Support --disable-randomization and --no-disable-randomization
11555 command line arguments.
11556 * target.h (struct target_ops): Add supports_disable_randomization.
11557 (target_supports_disable_randomization): New macro.
11558
11559 2011-09-29 Mike Frysinger <vapier@gentoo.org>
11560
11561 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
11562 ifdef check.
11563 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
11564 [!PT_GETDSBT] (target_loadmap): New definition.
11565 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
11566 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
11567 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
11568 and PT_GETDSBT to LINUX_LOADMAP.
11569 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
11570 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
11571
11572 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
11573
11574 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
11575 (arm_linux_hwbp_cap): New static variable.
11576 (arm_linux_get_hwbp_cap): Replace by ...
11577 (arm_linux_init_hwbp_cap): ... this new function.
11578 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
11579 (arm_linux_get_hw_watchpoint_count): Likewise.
11580 (arm_linux_get_hw_watchpoint_max_length): Likewise.
11581 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
11582 (arm_prepare_to_resume): Use perror_with_name instead of error.
11583
11584 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
11585
11586 * linux-arm-low.c: Include <signal.h>.
11587 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
11588 (struct arm_linux_hwbp_cap): New data type.
11589 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
11590 (struct arm_linux_hw_breakpoint): New data type.
11591 (MAX_BPTS, MAX_WPTS): Define.
11592 (struct arch_process_info, struct arch_lwp_info): New data types.
11593 (arm_linux_get_hwbp_cap): New function.
11594 (arm_linux_get_hw_breakpoint_count): Likewise.
11595 (arm_linux_get_hw_watchpoint_count): Likewise.
11596 (arm_linux_get_hw_watchpoint_max_length): Likewise.
11597 (arm_hwbp_control_initialize): Likewise.
11598 (arm_hwbp_control_is_enabled): Likewise.
11599 (arm_hwbp_control_is_initialized): Likewise.
11600 (arm_hwbp_control_disable): Likewise.
11601 (arm_linux_hw_breakpoint_equal): Likewise.
11602 (arm_linux_hw_point_initialize): Likewise.
11603 (struct update_registers_data): New data structure.
11604 (update_registers_callback: New function.
11605 (arm_insert_point): Likewise.
11606 (arm_remove_point): Likewise.
11607 (arm_stopped_by_watchpoint): Likewise.
11608 (arm_stopped_data_address): Likewise.
11609 (arm_new_process): Likewise.
11610 (arm_new_thread): Likewise.
11611 (arm_prepare_to_resume): Likewise.
11612 (the_low_target): Register arm_insert_point, arm_remove_point,
11613 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
11614 arm_new_thread, and arm_prepare_to_resume.
11615
11616 2011-09-15 Stan Shebs <stan@codesourcery.com>
11617
11618 * server.h (struct emit_ops): Add compare-goto fields.
11619 * tracepoint.c (gdb_agent_op_sizes): New table.
11620 (emit_eq_goto): New function.
11621 (emit_ne_goto): New function.
11622 (emit_lt_goto): New function.
11623 (emit_le_goto): New function.
11624 (emit_gt_goto): New function.
11625 (emit_ge_goto): New function.
11626 (is_goto_target): New function.
11627 (compile_bytecodes): Recognize special cases of compare-goto
11628 combinations and call specialized emitters for them.
11629 * linux-x86-low.c (amd64_emit_eq_goto): New function.
11630 (amd64_emit_ne_goto): New function.
11631 (amd64_emit_lt_goto): New function.
11632 (amd64_emit_le_goto): New function.
11633 (amd64_emit_gt_goto): New function.
11634 (amd64_emit_ge_goto): New function.
11635 (amd64_emit_ops): Add the new functions.
11636 (i386_emit_eq_goto): New function.
11637 (i386_emit_ne_goto): New function.
11638 (i386_emit_lt_goto): New function.
11639 (i386_emit_le_goto): New function.
11640 (i386_emit_gt_goto): New function.
11641 (i386_emit_ge_goto): New function.
11642 (i386_emit_ops): Add the new functions.
11643
11644 2011-09-08 Stan Shebs <stan@codesourcery.com>
11645
11646 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
11647 (i386_emit_epilogue): Restore %ebx.
11648
11649 2011-08-31 Jie Zhang <jzhang918@gmail.com>
11650
11651 * server.c (step_thread): Remove definition.
11652 (process_serial_event): Don't handle Hs.
11653 * server.h (step_thread): Remove declaration.
11654 * target.c (set_desired_inferior): Remove use of step_thread.
11655
11656 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
11657
11658 * linux-low.c: Include linux-procfs.h.
11659 (linux_attach_lwp_1): Update comments.
11660 (linux_attach): Scan for existing threads when attaching to a
11661 process that is the tgid.
11662 * Makefile.in: Update dependencies.
11663
11664 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
11665
11666 * configure.srv: Add linux-procfs.o dependencies.
11667
11668 2011-08-14 Yao Qi <yao@codesourcery.com>
11669
11670 * target.h (struct target_ops): Fix indent.
11671 * win32-low.c (win32_target_ops): Fix comment.
11672
11673 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
11674 Yao Qi <yao@codesourcery.com>
11675
11676 * Makefile.in (clean): Remove tic6x-*.c files.
11677 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
11678 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
11679 (tic6x-c64xp-linux.c): Likewise.
11680 * configure.srv: Add support for tic6x-*-uclinux.
11681 * linux-tic6x-low.c: New.
11682 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
11683
11684 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
11685 Yao Qi <yao@codesourcery.com>
11686
11687 * target.h (struct target_ops): Add read_loadmap.
11688 * linux-low.c (struct target_loadseg): New type.
11689 (struct target_loadmap): New type.
11690 (linux_read_loadmap): New function.
11691 (linux_target_ops): Add linux_read_loadmap.
11692 * server.c (handle_query): Support qXfer:fdpic:read packet.
11693 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
11694 to NULL.
11695
11696 2011-08-05 Eli Zaretskii <eliz@gnu.org>
11697
11698 * win32-low.c: Include <stdint.h>.
11699
11700 2011-07-22 Pedro Alves <pedro@codesourcery.com>
11701
11702 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
11703 to the inferior here.
11704 (i386_remove_aligned_watchpoint): Ditto.
11705 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
11706 fit part of the watchpoint in the debug registers.
11707 (i386_update_inferior_debug_regs): New.
11708 (i386_low_insert_watchpoint): Work on a local mirror of the debug
11709 registers, and only update the inferior on success.
11710 (i386_low_remove_watchpoint): Ditto.
11711
11712 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
11713
11714 * linux-low.c (compare_ints, unique, list_threads, show_process,
11715 linux_core_of_thread): Delete.
11716 (linux_target_ops): Change linux_core_of_thread to
11717 linux_common_core_of_thread.
11718 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
11719 * utils.c (malloc_failure): Change type of argument.
11720 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
11721 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
11722 common/linux-osdata.c, common/ptid.c and common/buffer.c.
11723 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
11724 (IPA_OBJS): Add common-utils-ipa.o.
11725 (ptid_h, linux_osdata_h): New macros.
11726 (server_h): Add common/common-utils.h, common/xml-utils.h,
11727 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
11728 common/ptid.h.
11729 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
11730 ptid.o, buffer.o): New rules.
11731 (linux-low.o): Add common/linux-osdata.h as a dependency.
11732 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
11733 * configure.ac: Add AC_HEADER_DIRENT check.
11734 * config.in: Regenerate.
11735 * configure: Regenerate.
11736 * remote-utils.c (xml_escape_text): Delete.
11737 (buffer_grow, buffer_free, buffer_init, buffer_finish,
11738 buffer_xml_printf): Move to common/buffer.c.
11739 * server.c (main): Remove call to initialize_inferiors.
11740 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
11741 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
11742 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
11743 internal_error, gdb_assert, gdb_assert_fail): Delete.
11744 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
11745 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
11746 common/buffer.h.
11747 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
11748 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
11749 initialize_inferiors): Delete.
11750
11751 2011-07-20 Pedro Alves <pedro@codesourcery.com>
11752
11753 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
11754 symbol error.
11755
11756 2011-05-31 Pedro Alves <pedro@codesourcery.com>
11757
11758 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
11759 assertion.
11760 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
11761
11762 2011-05-26 Yao Qi <yao@codesourcery.com>
11763
11764 * Makefile.in (thread-db.o): Track dependence to
11765 common/gdb_thread_db.h.
11766 * thread-db.c: include gdb_thread_db.h from right place.
11767
11768 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
11769
11770 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
11771 __FILE__ and __LINE__ to internal_error.
11772
11773 2011-05-13 Doug Evans <dje@google.com>
11774
11775 * thread-db.c (try_thread_db_load_from_sdir): New function.
11776 (try_thread_db_load_from_dir): New function.
11777 (thread_db_load_search): Handle $sdir, ignore $pdir.
11778 Remove trying of system directories if search of
11779 libthread-db-search-path fails, that is now done via $sdir.
11780
11781 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
11782
11783 * server.c (handle_query): Add EnableDisableTracepoints to the list
11784 of supported features.
11785 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
11786 tracepoints.
11787 (cmd_qtenable_disable): New.
11788 (cmd_qtstart): Install tracepoints even if disabled.
11789 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
11790 receiving a QTEnable or QTDisable packet.
11791 (gdb_collect): Skip data collection if fast tracepoint is disabled.
11792 (ust_marker_to_static_tracepoint): Do not ignore disabled static
11793 tracepoints.
11794 (gdb_probe): Skip data collection if static tracepoint is disabled.
11795
11796 2011-05-10 Doug Evans <dje@google.com>
11797
11798 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
11799
11800 2011-05-04 Doug Evans <dje@google.com>
11801
11802 * linux-low.c (linux_join): Skip process lookup.
11803 * spu-low.c (spu_join): Ditto.
11804 * server.c (join_inferiors_callback): Delete.
11805 (process_serial_event): For 'D' packet (detach) call join_inferior
11806 directly.
11807
11808 2011-05-04 Joseph Myers <joseph@codesourcery.com>
11809
11810 * README: Don't mention xscale*-*-linux*.
11811 * configure.srv (xscale*-*-linux*): Don't handle target.
11812
11813 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
11814
11815 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
11816 casting pointers.
11817 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
11818 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
11819 (i386_emit_void_call_2): Likewise.
11820
11821 2011-04-26 Yao Qi <yao@codesourcery.com>
11822
11823 * linux-low.c: Move common macros to linux-ptrace.h.
11824 Include linux-ptrace.h.
11825 * Makefile.in (linux_ptrace_h): New.
11826 (linux-low.o): Depends on linux-ptrace.h.
11827
11828 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
11829
11830 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
11831 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
11832 (remote_prepare): New function with most of the TCP code from ...
11833 (remote_open): ... here. Detect PORT here unconditionally. Move also
11834 setting transport_is_reliable.
11835 * server.c (run_once): New variable.
11836 (gdbserver_usage): Document it.
11837 (main): Set run_once for `--once'. Call remote_prepare. Exit after
11838 the first run if RUN_ONCE.
11839 * server.h (run_once, remote_prepare): New declarations.
11840
11841 2011-04-19 Tom Tromey <tromey@redhat.com>
11842
11843 * win32-low.c (handle_load_dll): Remove duplicate "the".
11844
11845 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
11846
11847 Remove support for old Cygwin 1.5 versions.
11848 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
11849 function to avoid warning.
11850 (win32_add_one_solib): Use cygwin_conv_path function to avoid
11851 warning.
11852
11853 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
11854
11855 * gdbserver/server.h (Macro _): Define it if not available.
11856
11857 2011-03-14 Michael Snyder <msnyder@vmware.com>
11858
11859 * hostio.c (handle_close): Remove unnecessary null test.
11860
11861 2011-03-10 Joel Brobecker <brobecker@adacore.com>
11862
11863 * Makefile.in (maintainer-clean realclean distclean): Remove
11864 "make ... subdir_do" command.
11865
11866 2011-03-10 Michael Snyder <msnyder@vmware.com>
11867
11868 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
11869
11870 * server.c (handle_v_run): Free alloced buffer on early return.
11871
11872 2011-03-09 Yao Qi <yao@codesourcery.com>
11873
11874 Revert:
11875 2011-03-04 Yao Qi <yao@codesourcery.com>
11876
11877 * Makefile.in: Remove GNU make feature --directory.
11878
11879 2011-03-05 Yao Qi <yao@codesourcery.com>
11880
11881 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
11882 (subdir_do): New make target. Copied from gdb/Makefile.
11883 (maintainer-clean, realclean, distclean, clean): Call corresponding
11884 make targets in common/Makefile.
11885
11886 2011-02-11 Yao Qi <yao@codesourcery.com>
11887
11888 * configure.ac: Call AC_PROG_RANLIB.
11889 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
11890 * configure: Regenerate.
11891
11892 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
11893
11894 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
11895
11896 2011-03-06 Yao Qi <yao@codesourcery.com>
11897
11898 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
11899
11900 2011-03-05 Yao Qi <yao@codesourcery.com>
11901
11902 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
11903 (subdir_do): New make target. Copied from gdb/Makefile.
11904 (maintainer-clean, realclean, distclean, clean): Call corresponding
11905 make targets in common/Makefile.
11906
11907 2011-03-04 Yao Qi <yao@codesourcery.com>
11908
11909 * Makefile.in: Remove GNU make feature --directory.
11910
11911 2011-03-04 Michael Snyder <msnyder@vmware.com>
11912
11913 * server.c (queue_stop_reply): Call xmalloc not malloc.
11914
11915 2011-03-02 Michael Snyder <msnyder@vmware.com>
11916
11917 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
11918
11919 2011-02-28 Michael Snyder <msnyder@vmware.com>
11920
11921 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
11922 (cmd_qtframe): Ditto.
11923 (cmd_qtbuffer): Ditto.
11924 (cmd_bigqtbuffer): Ditto.
11925
11926 * utils.c (decimal2str): Initialize 'width' to nine, then
11927 don't mess with it.
11928
11929 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
11930
11931 * hostio.c (require_data): Free *data, not data.
11932
11933 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
11934
11935 * hostio.c (require_data): Use free, not xfree.
11936
11937 2011-02-27 Michael Snyder <msnyder@vmware.com>
11938
11939 * server.c (handle_query): Discard unused value.
11940
11941 * hostio.c (require_data): Free malloc memory before returning
11942 error.
11943
11944 2011-02-26 Michael Snyder <msnyder@vmware.com>
11945
11946 * linux-low.c (list_threads): Call closedir for dirent.
11947
11948 2011-02-27 Michael Snyder <msnyder@vmware.com>
11949
11950 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
11951 a case statement falls through.
11952
11953 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
11954
11955 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
11956 in comparison.
11957
11958 2011-02-26 Michael Snyder <msnyder@vmware.com>
11959
11960 * utils.c (decimal2str): Eliminate dead code and dead param.
11961 (pulongest): Drop dead param from call to decimal2str.
11962 (plongest): Ditto.
11963
11964 2011-02-24 Joel Brobecker <brobecker@adacore.com>
11965
11966 Revert the following patch (not approved yet):
11967 2011-02-21 Hui Zhu <teawater@gmail.com>
11968 * tracepoint.c (tp_printf): New function.
11969 (eval_agent_expr): Handle gdb_agent_op_printf.
11970
11971 2011-02-21 Hui Zhu <teawater@gmail.com>
11972
11973 * tracepoint.c (tp_printf): New function.
11974 (eval_agent_expr): Handle gdb_agent_op_printf.
11975
11976 2011-02-18 Tom Tromey <tromey@redhat.com>
11977
11978 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
11979 (tracepoint.o): Likewise.
11980 * tracepoint.c (enum gdb_agent_op): Use ax.def.
11981 (gdb_agent_op_names): Likewise.
11982
11983 2011-02-18 Tom Tromey <tromey@redhat.com>
11984
11985 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
11986 gdb_agent_op_rot>: New constants.
11987 (gdb_agent_op_names): Add pick and roll.
11988 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
11989 cases.
11990
11991 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
11992
11993 * aclocal.m4: Regenerated with aclocal-1.11.1.
11994
11995 2011-02-14 Pedro Alves <pedro@codesourcery.com>
11996
11997 * server.c (handle_qxfer_traceframe_info): New.
11998 (qxfer_packets): Register "traceframe-info".
11999 (handle_query): Report support for qXfer:traceframe-info:read+.
12000 * tracepoint.c (match_blocktype): New.
12001 (traceframe_find_block_type): Rename to ...
12002 (traceframe_walk_blocks): ... this. Add callback filter argument,
12003 and use it.
12004 (traceframe_find_block_type): New, reimplemented on top of
12005 traceframe_walk_blocks.
12006 (build_traceframe_info_xml): New.
12007 (traceframe_read_info): New.
12008 * server.h (traceframe_read_info): Declare.
12009
12010 2011-02-11 Yao Qi <yao@codesourcery.com>
12011
12012 * configure.ac: Call AC_PROG_RANLIB.
12013 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
12014 * configure: Regenerate.
12015
12016 2011-02-07 Pedro Alves <pedro@codesourcery.com>
12017
12018 * server.c (gdb_read_memory): Change return semantics to allow
12019 partial transfers.
12020 (handle_search_memory_1): Adjust.
12021 (process_serial_event) <'m' packet>: Handle partial transfers.
12022 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
12023
12024 2011-01-28 Pedro Alves <pedro@codesourcery.com>
12025
12026 * regcache.c (init_register_cache): Initialize
12027 regcache->register_status.
12028 (free_register_cache): Release regcache->register_status.
12029 (regcache_cpy): Copy register_status.
12030 (registers_to_string): Print 'x's for unavailable registers.
12031 (supply_register): Mark the register's status valid or
12032 unavailable, depending on whether a buffer was passed in or not.
12033 (supply_register_zeroed): New.
12034 (supply_regblock): Mark the registers' status valid or
12035 unavailable, depending on whether a buffer was passed in or not.
12036 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
12037 (struct regcache): New `register_status' field.
12038 (supply_register_zeroed): Declare.
12039 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
12040 supply_register_zeroed, rather than passing a NULL buffer to
12041 supply_register.
12042 * tracepoint.c (fetch_traceframe_registers): Update comment.
12043
12044 2011-01-28 Pedro Alves <pedro@codesourcery.com>
12045
12046 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
12047 buffer explicit.
12048
12049 2011-01-25 Pedro Alves <pedro@codesourcery.com>
12050
12051 * server.h (decode_xfer_write): Change prototype.
12052 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
12053 and don't extract the annex here.
12054 * server.c (decode_xfer_read): Remove `annex' parameter,
12055 and don't extract the annex here.
12056 (decode_xfer): New.
12057 (struct qxfer): New.
12058 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
12059 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
12060 (handle_qxfer_statictrace): New functions, abstracted out from
12061 handle_query, and made to use the struct qxfer interface.
12062 (handle_threads_qxfer_proper): Rename to ...
12063 (handle_qxfer_threads_proper): ... this.
12064 (handle_threads_qxfer): Rename to ...
12065 (handle_qxfer_threads): ... this. Adjust.
12066 (qxfer_packets): New array.
12067 (handle_qxfer): New function.
12068 (handle_query): Use handle_qxfer.
12069
12070 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
12071
12072 * gdbreplay.c: Shorten lines of >= 80 columns.
12073 * linux-low.c: Ditto.
12074 * linux-ppc-low.c: Ditto.
12075 * linux-s390-low.c: Ditto.
12076 * linux-sparc-low.c: Ditto.
12077 * linux-x86-low.c: Ditto.
12078 * linux-xtensa-low.c: Ditto.
12079 * mem-break.c: Ditto.
12080 * nto-low.c: Ditto.
12081 * regcache.h: Ditto.
12082 * remote-utils.c: Ditto.
12083 * server.c: Ditto.
12084 * server.h: Ditto.
12085 * thread-db.c: Ditto.
12086 * tracepoint.c: Ditto.
12087 * utils.c: Ditto.
12088 * win32-low.h: Ditto.
12089
12090 2011-01-05 Joel Brobecker <brobecker@adacore.com>
12091
12092 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
12093 update.
12094
12095 2011-01-01 Joel Brobecker <brobecker@adacore.com>
12096
12097 * server.c (gdbserver_version): Update copyright year in version
12098 output.
12099 * gdbreplay.c (gdbreplay_version): Ditto.
12100
12101 2010-12-29 Jie Zhang <jie.zhang@analog.com>
12102
12103 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
12104 * linux-bfin-low.c: New file.
12105 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
12106 PT_DATA_ADDR for BFIN targets.
12107 * Makefile.in (SFILES): Add linux-bfin-low.c.
12108 (clean): Remove reg-bfin.c.
12109 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
12110 * README: Mention supported Blackfin targets.
12111
12112 2010-12-23 Mike Frysinger <vapier@gentoo.org>
12113
12114 * .gitignore: New file.
12115
12116 2010-11-16 Mike Frysinger <vapier@gentoo.org>
12117
12118 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
12119
12120 2010-10-22 Jie Zhang <jie@codesourcery.com>
12121
12122 * Makefile.in: Add FLAGS_TO_PASS variable.
12123 (install): Remove dependency of install-only and recursively
12124 invoke make for install-only.
12125
12126 2010-10-04 Doug Evans <dje@google.com>
12127
12128 * Makefile.in (uninstall): Use $(DESTDIR).
12129
12130 2010-09-24 Pedro Alves <pedro@codesourcery.com>
12131
12132 PR gdb/11842
12133
12134 * linux-x86-low.c (compat_siginfo_from_siginfo)
12135 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
12136 si_code is < 0. Check for si_code == SI_TIMER before checking for
12137 si_code < 0.
12138
12139 2010-09-13 Joel Brobecker <brobecker@adacore.com>
12140
12141 * lynx-i386-low.c: New file.
12142 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
12143
12144 2010-09-13 Joel Brobecker <brobecker@adacore.com>
12145
12146 * lynx-low.c (ptrace_request_to_str): Remove handling for
12147 request values that have been removed in LynxOS 5.x.
12148
12149 2010-09-13 Joel Brobecker <brobecker@adacore.com>
12150
12151 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
12152 <ptrace.h>
12153
12154 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
12155
12156 * configure.ac: Add --enable-inprocess-agent option.
12157 * configure: Rebuilt.
12158
12159 2010-09-06 Yao Qi <yao@codesourcery.com>
12160
12161 * linux-low.c (linux_kill): Remove unused variable.
12162 (linux_stabilize_threads): Likewise.
12163 * server.c (start_inferior): Likewise.
12164 (queue_stop_reply_callback): Likewise.
12165 * tracepoint.c (do_action_at_tracepoint): Likewise.
12166
12167 2010-09-06 Yao Qi <yao@codesourcery.com>
12168
12169 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
12170 on return.
12171
12172 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
12173
12174 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
12175
12176 2010-09-06 Pedro Alves <pedro@codesourcery.com>
12177
12178 * Makefile.in (install-only): Replace $IPA_DEPFILES with
12179 "$(IPA_DEPFILES)".
12180
12181 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12182
12183 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
12184 gdbserver/lynx-ppc-low.c: New files.
12185 * Makefile.in (lynx_low_h): New variable.
12186 (lynx-low.o, lynx-ppc-low.o): New rules.
12187 * configure.ac: On LynxOS, link with -lnetinet.
12188 * configure.srv: Add handling of powerpc-*-lynxos* targets.
12189 * configure: regenerate.
12190
12191 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12192
12193 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
12194 * configure.ac: Add check for vasprintf and vsnprintf.
12195 * configure, config.in: Regenerate.
12196 * server.h (vasprintf, vsnprintf): Add conditional declarations.
12197
12198 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12199
12200 * gdbreplay.c: Move include of alloca.h up, next to include of
12201 malloc.h.
12202 * server.h: Add include of malloc.h.
12203 * mem-break.c: Remove include of malloc.h.
12204 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
12205
12206 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12207
12208 * Makefile.in (memmem.o): Build with -Wno-error.
12209
12210 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12211
12212 * utils.c (xsnprintf): Make non-static.
12213 * server.h: Add xsnprintf declaration.
12214 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
12215 replace calls to snprintf by calls to xsnprintf throughout.
12216
12217 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12218
12219 * configure.ac: Add configure check for alloca.
12220 * configure, config.in: Regenerate.
12221 * server.h: Include alloca.h if it exists.
12222 * gdbreplay.c: Include alloca.h if it exists.
12223
12224 2010-08-28 Pedro Alves <pedro@codesourcery.com>
12225
12226 * linux-low.c (__SIGRTMIN): Define if not already defined.
12227 (linux_create_inferior): Check for __ANDROID__ rather than
12228 __SIGRTMIN.
12229 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
12230 are already deferred.
12231 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
12232 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
12233 stopped and already has a pending signal to report.
12234 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
12235 a pending signal to report or is moving out of a jump pad.
12236 (linux_init_signals): Check for __ANDROID__ rather than
12237 __SIGRTMIN.
12238
12239 2010-08-28 Pedro Alves <pedro@codesourcery.com>
12240
12241 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
12242 debug_threads check. Avoid a linear search when not doing debug
12243 output.
12244
12245 2010-08-27 Pedro Alves <pedro@codesourcery.com>
12246
12247 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
12248 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
12249 (struct file_handler) <fd>: Change type to gdb_fildes_t.
12250 (process_event): Change local fd's type to gdb_fildes_t.
12251 (create_file_handler): Adjust prototype.
12252 (delete_file_handler): Adjust prototype.
12253 (handle_file_event): Adjust prototype. Use pfildes.
12254 (create_file_event): Adjsut prototype.
12255 * remote-utils.c (remote_desc, listen_desc): Change type to
12256 gdb_fildes_t.
12257 * server.h: New gdb_fildes_t typedef.
12258 [USE_WIN32API]: Include winsock2.h.
12259 (delete_file_handler, add_file_handler): Adjust prototypes.
12260 (pfildes): Declare.
12261 * utils.c (pfildes): New.
12262
12263 2010-08-27 Pedro Alves <pedro@codesourcery.com>
12264
12265 * configure.ac (build_warnings): Add -Wno-char-subscripts.
12266 * configure: Regenerate.
12267
12268 2010-08-27 Pedro Alves <pedro@codesourcery.com>
12269
12270 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
12271 (linux_done_accessing_memory): ... this.
12272 (linux_target_ops): Adjust.
12273 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
12274 * nto-low.c (nto_target_ops): Adjust comment.
12275 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
12276 * spu-low.c (spu_target_ops): Adjust comment.
12277 * target.h (target_ops): Rename unprepare_to_access_memory field
12278 to done_accessing_memory.
12279 (unprepare_to_access_memory): Rename to ...
12280 (done_accessing_memory): ... this.
12281
12282 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12283
12284 * linux-low.c (linux_prepare_to_access_memory): New.
12285 (linux_unprepare_to_access_memory): New.
12286 (linux_target_ops): Install them.
12287 * server.c (read_memory): Rename to ...
12288 (gdb_read_memory): ... this. Use
12289 prepare_to_access_memory/prepare_to_access_memory.
12290 (write_memory): Rename to ...
12291 (gdb_write_memory): ... this. Use
12292 prepare_to_access_memory/prepare_to_access_memory.
12293 (handle_search_memory_1): Adjust.
12294 (process_serial_event): Adjust.
12295 * target.h (struct target_ops): New fields
12296 prepare_to_access_memory and unprepare_to_access_memory.
12297 (prepare_to_access_memory, unprepare_to_access_memory): New.
12298 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
12299 prepare_to_access_memory/prepare_to_access_memory.
12300 * nto-low.c (nto_target_ops): Adjust.
12301 * spu-low.c (spu_target_ops): Adjust.
12302 * win32-low.c (win32_target_ops): Adjust.
12303
12304 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12305
12306 * Makefile.in (WARN_CFLAGS): Get it from configure.
12307 (WERROR_CFLAGS): New.
12308 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
12309 * configure.ac: Introduce --enable-werror, which adds -Werror to
12310 the compiler command line. Enabled by default. Disable with
12311 --disable-werror. Add -Wdeclaration-after-statement
12312 Wpointer-arith and -Wformat-nonliteral to warning flags.
12313 * configure: Regenerate.
12314
12315 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12316
12317 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
12318
12319 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12320
12321 * gdbreplay.c (remote_error): New.
12322 (gdbchar): New.
12323 (expect): Use gdbchar. Check for error reading from GDB.
12324 Clarify sync error output.
12325 (play): Check for errors writing to GDB.
12326 * linux-low.c (sigchld_handler): Really ignore `write' errors.
12327 * remote-utils.c (getpkt): Check for errors writing to the remote
12328 descriptor.
12329
12330 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12331
12332 * linux-low.c (linux_wait_1): Move non-debugging code out of
12333 `debug_threads' control.
12334
12335 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12336
12337 * linux-low.c (linux_wait_1): Don't set last_status here.
12338 * server.c (push_event, queue_stop_reply_callback): Assert we're
12339 not pushing a TARGET_WAITKIND_IGNORE event.
12340 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
12341 (myresume, handle_target_event): Set the thread's last_resume_kind
12342 and last_status from the target returned status.
12343
12344 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12345
12346 PR threads/10729
12347
12348 * linux-x86-low.c (update_debug_registers_callback): New.
12349 (i386_dr_low_set_addr): Use it.
12350 (i386_dr_low_get_addr): New.
12351 (i386_dr_low_set_control): Use update_debug_registers_callback.
12352 (i386_dr_low_get_control): New.
12353 (i386_dr_low_get_status): Adjust.
12354 * linux-low.c (linux_stop_lwp): New.
12355 * linux-low.h (linux_stop_lwp): Declare.
12356
12357 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
12358 argument instead of a i386_debug_reg_state.
12359 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
12360 a i386_debug_reg_state.
12361 (i386_insert_aligned_watchpoint): Adjust.
12362 (i386_remove_aligned_watchpoint): Adjust.
12363 (i386_low_stopped_data_address): Read the debug registers from the
12364 inferior instead of from the mirrors.
12365 * i386-low.h (struct i386_debug_reg_state): Extend comment.
12366 (i386_dr_low_get_addr): Declare.
12367 (i386_dr_low_get_control): Declare.
12368 (i386_dr_low_get_status): Change prototype.
12369
12370 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
12371 (i386_dr_low_get_addr): New.
12372 (i386_dr_low_get_control): New.
12373 (i386_dr_low_get_status): Adjust prototype. Return
12374 dr_status_mirror.
12375 (i386_initial_stuff): Clear dr_status_mirror and
12376 dr_control_mirror.
12377 (i386_get_thread_context): Adjust.
12378 (i386_set_thread_context): Adjust.
12379 (i386_thread_added): Adjust.
12380
12381 2010-08-24 Pedro Alves <pedro@codesourcery.com>
12382
12383 * linux-low.h (linux_thread_area): Delete declaration.
12384
12385 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
12386
12387 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
12388 after its termination.
12389
12390 2010-08-09 Pedro Alves <pedro@codesourcery.com>
12391
12392 * linux-low.c (gdb_wants_lwp_stopped): Delete.
12393 (gdb_wants_all_stopped): Delete.
12394 (linux_wait_1): Don't call them.
12395 * server.c (handle_v_cont): Tag all threads as want-stopped.
12396 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
12397 stopped as "client-wants-stopped".
12398
12399 2010-07-31 Pedro Alves <pedro@codesourcery.com>
12400
12401 * Makefile.in (signals_h): New.
12402 (server_h): Depend on it.
12403 (server.o): Don't depend on $(signals_def).
12404 (signals.o): Depend on $(signals_def).
12405
12406 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
12407
12408 * Makefile.in (signals_def): New.
12409 (server_h): Append include/gdb/signals.h and signals_def.
12410 (server.o): Append signals_def.
12411
12412 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
12413
12414 * server.c (handle_target_event): Use target_signal_to_host for
12415 resume_info.sig initialization.
12416 * target.h (struct thread_resume) <sig>: New comment.
12417
12418 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
12419
12420 * server.c (handle_query): strcpy() the returned string from paddress()
12421 instead of sprintf().
12422 * utils.c (paddress): Return phex_nz().
12423
12424 2010-07-07 Joel Brobecker <brobecker@adacore.com>
12425
12426 * server.c (handle_v_cont): Call mourn_inferior if process
12427 just exited.
12428 (myresume): Likewise.
12429
12430 2010-07-01 Pedro Alves <pedro@codesourcery.com>
12431
12432 Static tracepoints, and integration with UST.
12433
12434 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
12435 * mem-break.c (uninsert_all_breakpoints)
12436 (reinsert_all_breakpoints): New.
12437 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
12438 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
12439 (gdb_agent_ust_loaded, helper_thread_id)
12440 (gdb_agent_helper_thread_id): New macros.
12441 (struct ipa_sym_addresses): Add addr_ust_loaded,
12442 addr_helper_thread_id, addr_cmd_buf.
12443 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
12444 (in_process_agent_loaded_ust): New.
12445 (write_e_ust_not_loaded): New.
12446 (maybe_write_ipa_ust_not_loaded): New.
12447 (struct collect_static_trace_data_action): New.
12448 (enum tracepoint_type) <static_tracepoint>: New.
12449 (struct tracepoint) <handle>: Mention static tracepoints.
12450 (struct static_tracepoint_ctx): New.
12451 (CMD_BUF_SIZE): New.
12452 (add_tracepoint_action): Handle static tracepoint actions.
12453 (unprobe_marker_at): New.
12454 (clear_installed_tracepoints): Handle static tracepoints.
12455 (cmd_qtdp): Handle static tracepoints.
12456 (probe_marker_at): New.
12457 (cmd_qtstart): Handle static tracepoints.
12458 (response_tracepoint): Handle static tracepoints.
12459 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
12460 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
12461 (get_context_regcache): Handle static tracepoints.
12462 (do_action_at_tracepoint): Handle static tracepoint actions.
12463 (traceframe_find_block_type): Handle static trace data blocks.
12464 (traceframe_read_sdata): New.
12465 (download_tracepoints): Download static tracepoint actions.
12466 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
12467 (GDB_PROBE_NAME): New.
12468 (ust_ops): New.
12469 (GET_UST_SYM): New.
12470 (USTF): New.
12471 (dlsym_ust): New.
12472 (ust_marker_to_static_tracepoint): New.
12473 (gdb_probe): New.
12474 (collect_ust_data_at_tracepoint): New.
12475 (gdb_ust_probe): New.
12476 (UNIX_PATH_MAX, SOCK_DIR): New.
12477 (gdb_ust_connect_sync_socket): New.
12478 (resume_thread, stop_thread): New.
12479 (run_inferior_command): New.
12480 (init_named_socket): New.
12481 (gdb_ust_socket_init): New.
12482 (cstr_to_hexstr): New.
12483 (next_st): New.
12484 (first_marker, next_marker): New.
12485 (response_ust_marker): New.
12486 (cmd_qtfstm, cmd_qtsstm): New.
12487 (unprobe_marker_at, probe_marker_at): New.
12488 (cmd_qtstmat, gdb_ust_thread): New.
12489 (gdb_ust_init): New.
12490 (initialize_tracepoint_ftlib): Call gdb_ust_init.
12491 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
12492 (ST_REGENTRY): New.
12493 (x86_64_st_collect_regmap): New.
12494 (X86_64_NUM_ST_COLLECT_GREGS): New.
12495 (AMD64_RIP_REGNUM): New.
12496 (supply_static_tracepoint_registers): New.
12497 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
12498 (ST_REGENTRY): New.
12499 (i386_st_collect_regmap): New.
12500 (i386_NUM_ST_COLLECT_GREGS): New.
12501 (supply_static_tracepoint_registers): New.
12502 * server.c (handle_query): Handle qXfer:statictrace:read.
12503 <qSupported>: Report support for StaticTracepoints, and
12504 qXfer:statictrace:read features.
12505 * server.h (traceframe_read_sdata)
12506 (supply_static_tracepoint_registers): Declare.
12507 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
12508 (unpack_varlen_hex): Include in IPA build.
12509 * Makefile.in (ustlibs, ustinc): New.
12510 (IPA_OBJS): Add remote-utils-ipa.o.
12511 ($(IPA_LIB)): Link -ldl and -lpthread.
12512 (UST_CFLAGS): New.
12513 (IPAGENT_CFLAGS): Add UST_CFLAGS.
12514 * config.in, configure: Regenerate.
12515
12516 2010-06-20 Ian Lance Taylor <iant@google.com>
12517 Pedro Alves <pedro@codesourcery.com>
12518
12519 * linux-x86-low.c (always_true): Delete.
12520 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
12521 trying to fool the compiler with always_true.
12522
12523 2010-06-20 Pedro Alves <pedro@codesourcery.com>
12524
12525 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
12526 conditions in gdbserver.
12527
12528 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
12529
12530 * spu-low.c (spu_read_memory): Wrap around local store limit.
12531 (spu_write_memory): Likewise.
12532
12533 2010-06-15 Pedro Alves <pedro@codesourcery.com>
12534
12535 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
12536 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
12537 LONGEST uses.
12538 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
12539 uses.
12540 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
12541 uses with LONGEST uses.
12542
12543 2010-06-14 Stan Shebs <stan@codesourcery.com>
12544 Pedro Alves <pedro@codesourcery.com>
12545
12546 Bytecode compiler.
12547
12548 * linux-x86-low.c: Include limits.h.
12549 (add_insns): New.
12550 (always_true): New.
12551 (EMIT_ASM): New.
12552 (EMIT_ASM32): New.
12553 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
12554 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
12555 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
12556 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
12557 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
12558 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
12559 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
12560 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
12561 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
12562 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
12563 (amd64_emit_void_call_2): New.
12564 (amd64_emit_ops): New.
12565 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
12566 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
12567 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
12568 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
12569 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
12570 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
12571 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
12572 (i386_emit_call, i386_emit_reg, i386_emit_pop)
12573 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
12574 (i386_emit_stack_adjust, i386_emit_int_call_1)
12575 (i386_emit_void_call_2): New.
12576 (i386_emit_ops): New.
12577 (x86_emit_ops): New.
12578 (the_low_target): Install x86_emit_ops.
12579 * server.h (struct emit_ops): New.
12580 (get_raw_reg_func_addr): Declare.
12581 (current_insn_ptr, emit_error): Declare.
12582 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
12583 (set_trace_state_variable_value): New defines.
12584 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
12585 addr_get_trace_state_variable_value and
12586 addr_set_trace_state_variable_value.
12587 (symbol_list): New fields for get_raw_reg,
12588 get_trace_state_variable_value and set_trace_state_variable_value.
12589 (condfn): New typedef.
12590 (struct tracepoint): New field `compiled_cond'.
12591 (do_action_at_tracepoint): Clear compiled_cond.
12592 (get_trace_state_variable_value, set_trace_state_variable_value):
12593 Export in the IPA.
12594 (condition_true_at_tracepoint): If there's a compiled condition,
12595 run that.
12596 (current_insn_ptr, emit_error): New globals.
12597 (struct bytecode_address): New.
12598 (get_raw_reg_func_addr): New.
12599 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
12600 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
12601 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
12602 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
12603 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
12604 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
12605 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
12606 (compile_tracepoint_condition, compile_bytecodes): New.
12607 * target.h (emit_ops): Forward declare.
12608 (struct target_ops): New field emit_ops.
12609 (target_emit_ops): New.
12610 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
12611 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
12612 * linux-low.c (linux_emit_ops): New.
12613 (linux_target_ops): Install it.
12614 * linux-low.h (struct linux_target_ops): New field emit_ops.
12615
12616 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
12617
12618 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
12619 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
12620
12621 2010-06-01 Pedro Alves <pedro@codesourcery.com>
12622 Stan Shebs <stan@codesourcery.com>
12623
12624 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
12625 (all): Depend on $(extra_libraries).
12626 (install-only): Install the IPA.
12627 (IPA_OBJS, IPA_LIB): New.
12628 (clean): Remove the IPA lib.
12629 (IPAGENT_CFLAGS): New.
12630 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
12631 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
12632 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
12633 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
12634 * configure.ac: Check for atomic builtins support in the compiler.
12635 (IPA_DEPFILES, extra_libraries): Define.
12636 * configure.srv (ipa_obj): Add description.
12637 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
12638 (i[34567]86-*-linux*): Set ipa_obj.
12639 (x86_64-*-linux*): Set ipa_obj.
12640 * linux-low.c (stabilizing_threads): New.
12641 (supports_fast_tracepoints): New.
12642 (linux_detach): Stabilize threads before detaching.
12643 (handle_tracepoints): Handle internal tracing breakpoints. Assert
12644 the lwp is either not stabilizing, or is moving out of a jump pad.
12645 (linux_fast_tracepoint_collecting): New.
12646 (maybe_move_out_of_jump_pad): New.
12647 (enqueue_one_deferred_signal): New.
12648 (dequeue_one_deferred_signal): New.
12649 (linux_wait_for_event_1): If moving out of a jump pad, defer
12650 pending signals to later.
12651 (linux_stabilize_threads): New.
12652 (linux_wait_1): Check if threads need moving out of jump pads, and
12653 do it if so.
12654 (stuck_in_jump_pad_callback): New.
12655 (move_out_of_jump_pad_callback): New.
12656 (lwp_running): New.
12657 (linux_resume_one_lwp): Handle moving out of jump pads.
12658 (linux_set_resume_request): Dequeue deferred signals.
12659 (need_step_over_p): Also step over fast tracepoint jumps.
12660 (start_step_over): Also uninsert fast tracepoint jumps.
12661 (finish_step_over): Also reinsert fast tracepoint jumps.
12662 (linux_install_fast_tracepoint_jump): New.
12663 (linux_target_ops): Install linux_stabilize_threads and
12664 linux_install_fast_tracepoint_jump_pad.
12665 * linux-low.h (linux_target_ops) <get_thread_area,
12666 install_fast_tracepoint_jump_pad>: New fields.
12667 (struct lwp_info) <collecting_fast_tracepoint,
12668 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
12669 (linux_get_thread_area): Declare.
12670 * linux-x86-low.c (jump_insn): New.
12671 (x86_get_thread_area): New.
12672 (append_insns): New.
12673 (push_opcode): New.
12674 (amd64_install_fast_tracepoint_jump_pad): New.
12675 (i386_install_fast_tracepoint_jump_pad): New.
12676 (x86_install_fast_tracepoint_jump_pad): New.
12677 (the_low_target): Install x86_get_thread_area and
12678 x86_install_fast_tracepoint_jump_pad.
12679 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
12680 (struct fast_tracepoint_jump): New.
12681 (fast_tracepoint_jump_insn): New.
12682 (fast_tracepoint_jump_shadow): New.
12683 (find_fast_tracepoint_jump_at): New.
12684 (fast_tracepoint_jump_here): New.
12685 (delete_fast_tracepoint_jump): New.
12686 (set_fast_tracepoint_jump): New.
12687 (uninsert_fast_tracepoint_jumps_at): New.
12688 (reinsert_fast_tracepoint_jumps_at): New.
12689 (set_breakpoint_at): Use write_inferior_memory.
12690 (uninsert_raw_breakpoint): Use write_inferior_memory.
12691 (check_mem_read): Mask out fast tracepoint jumps.
12692 (check_mem_write): Mask out fast tracepoint jumps.
12693 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
12694 (set_fast_tracepoint_jump): Declare.
12695 (delete_fast_tracepoint_jump)
12696 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
12697 (reinsert_fast_tracepoint_jumps_at): Declare.
12698 * regcache.c: Don't compile many functions when building the
12699 in-process agent library.
12700 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
12701 the register buffer in the heap.
12702 (free_register_cache): If the register buffer isn't owned by the
12703 regcache, don't free it.
12704 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
12705 pre-existing register caches.
12706 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
12707 type.
12708 (convert_ascii_to_int): : Constify `from' parameter type.
12709 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
12710 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
12711 the needed buffer in-place.
12712 (relocate_instruction): New.
12713 * server.c (handle_query) <qSymbols>: If the target supports
12714 tracepoints, give it a chance of looking up symbols. Report
12715 support for fast tracepoints.
12716 (handle_status): Stabilize threads.
12717 (process_serial_event): Adjust.
12718 * server.h (struct fast_tracepoint_jump): Forward declare.
12719 (struct process_info) <fast_tracepoint_jumps>: New field.
12720 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
12721 (decode_X_packet, decode_M_packet): Adjust.
12722 (relocate_instruction): Declare.
12723 (in_process_agent_loaded): Declare.
12724 (tracepoint_look_up_symbols): Declare.
12725 (struct fast_tpoint_collect_status): Declare.
12726 (fast_tracepoint_collecting): Declare.
12727 (force_unlock_trace_buffer): Declare.
12728 (handle_tracepoint_bkpts): Declare.
12729 (initialize_low_tracepoint)
12730 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
12731 * target.h (struct target_ops) <stabilize_threads,
12732 install_fast_tracepoint_jump_pad>: New fields.
12733 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
12734 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
12735 [HAVE_STDINT_H]: Include stdint.h.
12736 (trace_debug_1): Rename to ...
12737 (trace_vdebug): ... this.
12738 (trace_debug): Rename to ...
12739 (trace_debug_1): ... this. Add `level' parameter.
12740 (trace_debug): New.
12741 (ATTR_USED, ATTR_NOINLINE): New.
12742 (IP_AGENT_EXPORT): New.
12743 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
12744 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
12745 (about_to_request_buffer_space, trace_buffer_is_full)
12746 (stopping_tracepoint, expr_eval_result, error_tracepoint)
12747 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
12748 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
12749 (traceframe_write_count, traceframes_created)
12750 (trace_state_variables)
12751 New renaming defines.
12752 (struct ipa_sym_addresses): New.
12753 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
12754 (symbol_list): New.
12755 (ipa_sym_addrs): New.
12756 (all_tracepoint_symbols_looked_up): New.
12757 (in_process_agent_loaded): New.
12758 (write_e_ipa_not_loaded): New.
12759 (maybe_write_ipa_not_loaded): New.
12760 (tracepoint_look_up_symbols): New.
12761 (debug_threads) [IN_PROCESS_AGENT]: New.
12762 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
12763 (UNKNOWN_SIDE_EFFECTS): New.
12764 (stop_tracing): New.
12765 (flush_trace_buffer): New.
12766 (stop_tracing_bkpt): New.
12767 (flush_trace_buffer_bkpt): New.
12768 (read_inferior_integer): New.
12769 (read_inferior_uinteger): New.
12770 (read_inferior_data_pointer): New.
12771 (write_inferior_data_pointer): New.
12772 (write_inferior_integer): New.
12773 (write_inferior_uinteger): New.
12774 (struct collect_static_trace_data_action): Delete.
12775 (enum tracepoint_type): New.
12776 (struct tracepoint) <type>: New field `type'.
12777 <actions_str, step_actions, step_actions_str>: Only include in
12778 GDBserver.
12779 <orig_size, obj_addr_on_target, adjusted_insn_addr>
12780 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
12781 (tracepoints): Use IP_AGENT_EXPORT.
12782 (last_tracepoint): Don't include in the IPA.
12783 (stopping_tracepoint): Use IP_AGENT_EXPORT.
12784 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
12785 (alloced_trace_state_variables): New.
12786 (trace_state_variables): Use IP_AGENT_EXPORT.
12787 (traceframe_t): Delete unused variable.
12788 (circular_trace_buffer): Don't include in the IPA.
12789 (trace_buffer_start): Delete.
12790 (struct trace_buffer_control): New.
12791 (trace_buffer_free): Delete.
12792 (struct ipa_trace_buffer_control): New.
12793 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
12794 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
12795 New.
12796 (trace_buffer_ctrl): New.
12797 (TRACE_BUFFER_CTRL_CURR): New.
12798 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
12799 Reimplement as macros.
12800 (trace_buffer_wrap): Delete.
12801 (traceframe_write_count, traceframe_read_count)
12802 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
12803 (struct tracepoint_hit_ctx) <type>: New field.
12804 (struct fast_tracepoint_ctx): New.
12805 (memory_barrier): New.
12806 (cmpxchg): New.
12807 (record_tracepoint_error): Update atomically in the IPA.
12808 (clear_inferior_trace_buffer): New.
12809 (about_to_request_buffer_space): New.
12810 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
12811 updating the same buffer.
12812 (add_tracepoint): Default the tracepoint's type to trap
12813 tracepoint, and orig_size to -1.
12814 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
12815 internal variables.
12816 (create_trace_state_variable): New parameter `gdb'. Handle it.
12817 (clear_installed_tracepoints): Clear fast tracepoint jumps.
12818 (cmd_qtdp): Handle fast tracepoints.
12819 (cmd_qtdv): Adjust.
12820 (max_jump_pad_size): New.
12821 (gdb_jump_pad_head): New.
12822 (get_jump_space_head): New.
12823 (claim_jump_space): New.
12824 (sort_tracepoints): New.
12825 (MAX_JUMP_SIZE): New.
12826 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
12827 IPA.
12828 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
12829 support. Upload fast traceframes, and delete internal IPA
12830 breakpoints.
12831 (stop_tracing_handler): New.
12832 (flush_trace_buffer_handler): New.
12833 (cmd_qtstop): Upload fast tracepoints.
12834 (response_tracepoint): Handle fast tracepoints.
12835 (tracepoint_finished_step): Upload fast traceframes. Set the
12836 tracepoint hit context's tracepoint type.
12837 (handle_tracepoint_bkpts): New.
12838 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
12839 type. Add comment about fast tracepoints.
12840 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
12841 non-existing action_str field.
12842 (get_context_regcache): Handle fast tracepoints.
12843 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
12844 to the regcache.
12845 (fast_tracepoint_from_jump_pad_address): New.
12846 (fast_tracepoint_from_ipa_tpoint_address): New.
12847 (collecting_t): New.
12848 (force_unlock_trace_buffer): New.
12849 (fast_tracepoint_collecting): New.
12850 (collecting): New.
12851 (gdb_collect): New.
12852 (write_inferior_data_ptr): New.
12853 (target_tp_heap): New.
12854 (target_malloc): New.
12855 (download_agent_expr): New.
12856 (UALIGN): New.
12857 (download_tracepoints): New.
12858 (download_trace_state_variables): New.
12859 (upload_fast_traceframes): New.
12860 (IPA_FIRST_TRACEFRAME): New.
12861 (IPA_NEXT_TRACEFRAME_1): New.
12862 (IPA_NEXT_TRACEFRAME): New.
12863 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
12864 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
12865 (gdb_jump_pad_buffer_end): New.
12866 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
12867 (initialize_tracepoint): Adjust.
12868 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
12869 buffer. Initialize the low module.
12870 * utils.c (PREFIX, TOOLNAME): New.
12871 (malloc_failure): Use PREFIX.
12872 (error): In the IPA, an error causes an exit.
12873 (fatal, warning): Use PREFIX.
12874 (internal_error): Use TOOLNAME.
12875 (NUMCELLS): Increase to 10.
12876 * configure, config.in: Regenerate.
12877
12878 2010-06-01 Pedro Alves <pedro@codesourcery.com>
12879
12880 * server.c (handle_query) <qSupported>: Do two passes over the
12881 qSupported string to avoid nesting strtok.
12882
12883 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12884
12885 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
12886 (CDEPS): New.
12887 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
12888 -Wl,--dynamic-list.
12889 * configure: Regenerate.
12890 * proc-service.list: New.
12891
12892 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12893
12894 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
12895 New comment.
12896
12897 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
12898
12899 * gdbreplay.c (remote_open): Check error return from socket() call by
12900 its equality to -1 not by it being negative.
12901 * remote-utils.c (remote_open): Likewise.
12902
12903 2010-05-23 Pedro Alves <pedro@codesourcery.com>
12904
12905 * config.h: Regenerate.
12906
12907 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
12908
12909 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
12910 doesn't provide PTRACE_GET_THREAD_AREA.
12911
12912 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
12913
12914 * linux-m68k-low.c: Include <asm/ptrace.h>
12915 (ps_get_thread_area): Implement.
12916
12917 2010-05-03 Doug Evans <dje@google.com>
12918
12919 * event-loop.c (struct callback_event): New struct.
12920 (callback_list): New global.
12921 (append_callback_event, delete_callback_event): New functions.
12922 (process_callback): New function.
12923 (start_event_loop): Call it.
12924 * remote-utils.c (NOT_SCHEDULED): Define.
12925 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
12926 moved out of readchar.
12927 (readchar): Rewrite. Call reschedule before returning.
12928 (reset_readchar): New function.
12929 (remote_close): Call it.
12930 (process_remaining, reschedule): New functions.
12931 * server.h (callback_handler_func): New typedef.
12932 (append_callback_event, delete_callback_event): Declare.
12933
12934 2010-05-03 Pedro Alves <pedro@codesourcery.com>
12935
12936 * proc-service.c (ps_pglobal_lookup): Use
12937 thread_db_look_up_one_symbol.
12938 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
12939 parameter. Use it instead of all_symbols_looked_up.
12940 * server.h (struct process_info) <all_symbols_looked_up>: Delete
12941 field.
12942 (all_symbols_looked_up): Don't declare.
12943 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
12944 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
12945 field.
12946 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
12947 Set all_symbols_looked_up here.
12948 (thread_db_look_up_one_symbol): New.
12949 (thread_db_get_tls_address): Adjust.
12950 (thread_db_load_search, try_thread_db_load_1): Always allocate the
12951 thread_db object on the heap, and tentatively set it in the
12952 process structure.
12953 (thread_db_init): Don't set all_symbols_looked_up here.
12954 * linux-low.h (thread_db_look_up_one_symbol): Declare.
12955
12956 2010-05-03 Pedro Alves <pedro@codesourcery.com>
12957
12958 * linux-low.c (linux_kill, linux_detach): Adjust.
12959 (status_pending_p_callback): Remove redundant statement. Check
12960 for !TARGET_WAITIKIND_IGNORE, instead of
12961 TARGET_WAITKIND_STOPPED.
12962 (handle_tracepoints): Make sure LWP is locked. Adjust.
12963 (linux_wait_for_event_1): Adjust.
12964 (linux_cancel_breakpoints): New.
12965 (unsuspend_one_lwp): New.
12966 (unsuspend_all_lwps): New.
12967 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
12968 (send_sigstop_callback): Change return type to int, add new
12969 `except' parameter and handle it.
12970 (suspend_and_send_sigstop_callback): New.
12971 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
12972 pass them down. If SUSPEND, also increment the lwp's suspend
12973 count.
12974 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
12975 (need_step_over_p): Don't consider suspended LWPs.
12976 (start_step_over): Adjust.
12977 (proceed_one_lwp): Change return type to int, add new `except'
12978 parameter and handle it.
12979 (unsuspend_and_proceed_one_lwp): New.
12980 (proceed_all_lwps): Use find_inferior instead of
12981 for_each_inferior.
12982 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
12983 also decrement the suspend count of LWPs. Pass `except' down,
12984 instead of hacking its suspend count.
12985 (linux_pause_all): Add `freeze' parameter. Adjust.
12986 (linux_unpause_all): New.
12987 (linux_target_ops): Install linux_unpause_all.
12988 * server.c (handle_status): Adjust.
12989 * target.h (struct target_ops): New fields `unpause_all' and
12990 `cancel_breakpoints'. Add new parameter to `pause_all'.
12991 (pause_all): Add new `freeze' parameter.
12992 (unpause_all): New.
12993 (cancel_breakpoints): New.
12994 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
12995 cancel breakpoints.
12996 (cmd_qtstart): Pause threads.
12997 (stop_tracing): Pause threads, and cancel breakpoints.
12998 * win32-low.c (win32_target_ops): Adjust.
12999
13000 2010-05-03 Pedro Alves <pedro@codesourcery.com>
13001
13002 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
13003 the inferior right away from here...
13004 (linux_wait_1): ... to here, and adjust to check the thread's
13005 last_resume_kind instead of the lwp's step or stop_expected flags.
13006
13007 2010-05-02 Pedro Alves <pedro@codesourcery.com>
13008
13009 * README: Use consistent `GDB' and `GDBserver' spellings.
13010
13011 2010-05-02 Pedro Alves <pedro@codesourcery.com>
13012
13013 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
13014 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
13015 (linux_detach_one_lwp): Assume the lwp is stopped.
13016 (any_thread_of): Delete.
13017 (linux_detach): Stop all lwps here. Don't blindly delete all
13018 breakpoints.
13019 (delete_lwp_callback): New.
13020 (linux_mourn): Delete all lwps of the process that is gone.
13021 (linux_wait_1): Don't delete the last lwp of the process here.
13022 * mem-break.h (mark_breakpoints_out): Declare.
13023 * mem-break.c (mark_breakpoints_out): New.
13024 (free_all_breakpoints): Use it.
13025 * server.c (handle_target_event): If the process is gone, mark
13026 breakpoints out.
13027 * thread-db.c (struct thread_db) <create_bp>: New field.
13028 (thread_db_enable_reporting): Fix prototype. Store a thread event
13029 breakpoint reference in the thread_db struct.
13030 (thread_db_load_search): Clear the thread_db object.
13031 (try_thread_db_load_1): Ditto.
13032 (switch_to_process): New.
13033 (disable_thread_event_reporting): Use it.
13034 (remove_thread_event_breakpoints): New.
13035 (thread_db_detach, thread_db_mourn): Use it.
13036
13037 2010-05-01 Pedro Alves <pedro@codesourcery.com>
13038
13039 * linux-low.c (linux_enable_event_reporting): New.
13040 (linux_wait_for_event_1, handle_extended_wait): Use it.
13041
13042 2010-04-30 Pedro Alves <pedro@codesourcery.com>
13043
13044 * linux-low.c (linux_kill_one_lwp, linux_kill)
13045 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
13046 (send_sigstop): Take an lwp_info as parameter instead. Queue a
13047 SIGSTOP even if the LWP is stopped.
13048 (send_sigstop_callback): New.
13049 (stop_all_lwps): Use send_sigstop_callback instead.
13050 (linux_resume_one_thread): Adjust.
13051 (proceed_one_lwp): Still proceed an LWP that the client has
13052 requested to stop, if we haven't reported it as stopped yet. Make
13053 sure that LWPs the client want stopped, have a pending SIGSTOP.
13054
13055 2010-04-26 Doug Evans <dje@google.com>
13056
13057 * server.c (handle_general_set): Make static.
13058
13059 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
13060 Print received char after testing for error/eof instead of before.
13061 (input_interrupt): Tweak comment.
13062
13063 2010-04-23 Doug Evans <dje@google.com>
13064
13065 * server.c (start_inferior): Print inferior argv if --debug.
13066
13067 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
13068
13069 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
13070 * nto-x86-low.c: Include server.h
13071
13072 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
13073
13074 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
13075 be consistent with other sources of this directory.
13076 (init_registers_amd64): Correct name of source file of this function
13077 in the comment.
13078
13079 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13080
13081 * configure.srv (x86_64-*-mingw*): New configuration for Windows
13082 64-bit executables.
13083
13084 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13085
13086 * win32-i386-low.c: Add 64-bit support.
13087 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
13088 (init_registers_amd64): Declare.
13089 (mappings): Add 64-bit version of array.
13090 (init_windows_x86): New function.
13091 (the_low_target): Change init_arch field to init_windows_x86.
13092
13093 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13094
13095 * win32-low.c: Adapt to support also 64-bit architecture.
13096 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
13097 (get_image_name): Use SIZE_T type for local variable `done'.
13098 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
13099 (toolhelp_get_dll_name): Idem.
13100 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
13101 Use uintptr_t typecast to avoid warning.
13102 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
13103 (handle_exception): Use phex_nz to avoid warning.
13104 (win32_wait): Remove unused local variable `process'.
13105
13106 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13107
13108 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
13109 `amd64-avx.o'.
13110
13111 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
13112
13113 * configure.ac: Use `ws2_32' library for srv_mingw.
13114 * configure: Regenerate.
13115 * gdbreplay.c: Include winsock2.h instead of winsock.h.
13116 * remote-utils.c: Likewise.
13117
13118 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
13119
13120 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
13121 if __x86_64__ is defined.
13122
13123 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
13124
13125 * configure: Regenerate.
13126
13127 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
13128
13129 * server.c (handle_query): Handle 'qGetTIBAddr' query.
13130 * target.h (target_ops): New get_tib_address field.
13131 * win32-low.h (win32_thread_info): Add thread_local_base field.
13132 * win32-low.c (child_add_thread): Add tlb argument.
13133 Set thread_local_base field to TLB.
13134 (get_child_debug_event): Adapt to child_add_thread change.
13135 (win32_get_tib_address): New function.
13136 (win32_target_ops): Set get_tib_address field to
13137 win32_get_tib_address.
13138 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
13139
13140 2010-04-12 Pedro Alves <pedro@codesourcery.com>
13141
13142 * linux-low.c (linux_mourn): Also remove the process.
13143 * server.c (handle_target_event): Don't remove the process here.
13144 * nto-low.c (nto_mourn): New.
13145 (nto_target_ops): Install it.
13146 * spu-low.c (spu_mourn): New.
13147 (spu_target_ops): Install it.
13148 * win32-low.c (win32_mourn): New.
13149 (win32_target_ops): Install it.
13150
13151 2010-04-12 Pedro Alves <pedro@codesourcery.com>
13152
13153 * server.h (buffer_xml_printf): Remove redundant `;'.
13154
13155 2010-04-12 Pedro Alves <pedro@codesourcery.com>
13156
13157 * regcache.c (set_register_cache): Invalidate regcaches before
13158 changing the register cache layout.
13159 (regcache_invalidate_one): Allow a NULL regcache.
13160 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
13161 regcaches before changing the register cache layout or the target
13162 regsets.
13163
13164 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
13165
13166 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
13167 variable warning on Linux/x86-64.
13168
13169 2010-04-11 Pedro Alves <pedro@codesourcery.com>
13170
13171 GDBserver disconnected tracing support.
13172
13173 * linux-low.c (linux_remove_process): Delete.
13174 (add_lwp): Don't set last_resume_kind here.
13175 (linux_kill): Use `mourn'.
13176 (linux_detach): Use `thread_db_detach', and `mourn'.
13177 (linux_mourn): New.
13178 (linux_attach_lwp_1): Adjust comment.
13179 (linux_attach): last_resume_kind moved the thread_info; adjust.
13180 (status_pending_p_callback): Adjust.
13181 (linux_wait_for_event_1): Adjust.
13182 (count_events_callback, select_singlestep_lwp_callback)
13183 (select_event_lwp_callback, cancel_breakpoints_callback)
13184 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
13185 (proceed_one_lwp): Adjust.
13186 (linux_async): Add debug output.
13187 (linux_thread_stopped): New.
13188 (linux_pause_all): New.
13189 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
13190 linux_pause_all.
13191 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
13192 (thread_db_free): Delete declaration.
13193 (thread_db_detach, thread_db_mourn): Declare.
13194 * thread-db.c (thread_db_init): Use thread_db_mourn.
13195 (thread_db_free): Delete, split in two.
13196 (disable_thread_event_reporting): New.
13197 (thread_db_detach): New.
13198 (thread_db_mourn): New.
13199
13200 * server.h (struct thread_info) <last_resume_kind>: New field.
13201 <attached>: Add comment.
13202 <gdb_detached>: New field.
13203 (handler_func): Change return type to int.
13204 (handle_serial_event, handle_target_event): Ditto.
13205 (gdb_connected): Declare.
13206 (tracing): Delete.
13207 (disconnected_tracing): Declare.
13208 (stop_tracing): Declare.
13209
13210 * server.c (handle_query) <qSupported>: Report support for
13211 disconnected tracing.
13212 (queue_stop_reply_callback): Account for running threads.
13213 (gdb_wants_thread_stopped): New.
13214 (gdb_wants_all_threads_stopped): New.
13215 (gdb_reattached_process): New.
13216 (handle_status): Clear the `gdb_detached' flag of all processes.
13217 In all-stop, stop all threads.
13218 (main): Be sure to leave tfind mode. Handle disconnected tracing.
13219 (process_serial_event): If the remote connection breaks, or if an
13220 exit was forced with "monitor exit", force an event loop exit.
13221 Handle disconnected tracing on detach.
13222 (handle_serial_event): Adjust.
13223 (handle_target_event): If GDB isn't connected, forward events back
13224 to the inferior, unless the last process exited, in which case,
13225 exit gdbserver. Adjust interface.
13226
13227 * remote-utils.c (remote_open): Don't block in accept. Instead
13228 register an event loop source on the listen socket file
13229 descriptor. Refactor bits into ...
13230 (listen_desc): ... this new global.
13231 (gdb_connected): ... this new function.
13232 (enable_async_notification): ... this new function.
13233 (handle_accept_event): ... this new function.
13234 (remote_close): Clear remote_desc.
13235
13236 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
13237
13238 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
13239 New fields.
13240 (mourn_inferior): Define.
13241 (target_process_qsupported): Avoid the dangling else problem.
13242 (thread_stopped): Define.
13243 (pause_all): Define.
13244 (target_waitstatus_to_string): Declare.
13245 * target.c (target_waitstatus_to_string): New.
13246
13247 * tracepoint.c (tracing): Make extern.
13248 (disconnected_tracing): New.
13249 (stop_tracing): Make extern. Handle tracing stops due to GDB
13250 disconnecting.
13251 (cmd_qtdisconnected): New.
13252 (cmd_qtstatus): Report disconnected tracing status in trace reply.
13253 (handle_tracepoint_general_set): Handle QTDisconnected.
13254
13255 * event-loop.c (event_handler_func): Change return type to int.
13256 (process_event): Bail out if the event handler wants the event
13257 loop to stop.
13258 (handle_file_event): Ditto.
13259 (start_event_loop): Bail out if the event handler wants the event
13260 loop to stop.
13261
13262 * nto-low.c (nto_target_ops): Adjust.
13263 * spu-low.c (spu_wait): Don't remove the process here.
13264 (spu_target_ops): Adjust.
13265 * win32-low.c (win32_wait): Don't remove the process here.
13266 (win32_target_ops): Adjust.
13267
13268 2010-04-11 Pedro Alves <pedro@codesourcery.com>
13269
13270 * regcache.c (realloc_register_cache): Invalidate inferior's
13271 regcache before recreating it.
13272
13273 2010-04-09 Pedro Alves <pedro@codesourcery.com>
13274
13275 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
13276
13277 2010-04-09 Stan Shebs <stan@codesourcery.com>
13278 Pedro Alves <pedro@codesourcery.com>
13279
13280 * server.h (LONGEST): New.
13281 (struct thread_info) <while_stepping>: New field.
13282 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
13283 Declare.
13284 (initialize_tracepoint, handle_tracepoint_general_set)
13285 (handle_tracepoint_query, tracepoint_finished_step)
13286 (tracepoint_was_hit, release_while_stepping_state_list):
13287 (current_traceframe): Declare.
13288 * server.c (handle_general_set): Handle tracepoint packets.
13289 (read_memory): New.
13290 (write_memory): New.
13291 (handle_search_memory_1): Use read_memory.
13292 (handle_query): Report support for conditional tracepoints, trace
13293 state variables, and tracepoint sources. Handle tracepoint
13294 queries.
13295 (main): Initialize the tracepoints module.
13296 (process_serial_event): Handle traceframe reads/writes.
13297
13298 * linux-low.c (handle_tracepoints): New.
13299 (linux_wait_1): Call it.
13300 (linux_resume_one_lwp): Handle while-stepping.
13301 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
13302 (linux_target_ops): Install them.
13303 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
13304 New field.
13305 * linux-x86-low.c (x86_supports_tracepoints): New.
13306 (the_low_target). Install it.
13307
13308 * mem-break.h (delete_breakpoint): Declare.
13309 * mem-break.c (delete_breakpoint): Make external.
13310
13311 * target.h (struct target_ops): Add `supports_tracepoints',
13312 `read_pc', and `write_pc' fields.
13313 (target_supports_tracepoints): Define.
13314 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
13315 (phex_nz): New.
13316
13317 * regcache.h (struct regcache) <registers_owned>: New field.
13318 (init_register_cache, regcache_cpy): Declare.
13319 (regcache_read_pc, regcache_write_pc): Declare.
13320 (register_cache_size): Declare.
13321 (supply_regblock): Declare.
13322 * regcache.c (init_register_cache): New.
13323 (new_register_cache): Use it.
13324 (regcache_cpy): New.
13325 (register_cache_size): New.
13326 (supply_regblock): New.
13327 (regcache_read_pc, regcache_write_pc): New.
13328
13329 * tracepoint.c: New.
13330
13331 * Makefile.in (OBS): Add tracepoint.o.
13332 (tracepoint.o): New rule.
13333
13334 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
13335
13336 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
13337 (i386-mmx.o): New.
13338 (i386-mmx.c): Likewise.
13339 (i386-mmx-linux.o): Likewise.
13340 (i386-mmx-linux.c): Likewise.
13341
13342 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
13343 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
13344 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
13345 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
13346
13347 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
13348 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
13349 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
13350
13351 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
13352
13353 * Makefile.in (clean): Updated.
13354 (i386-avx.o): New.
13355 (i386-avx.c): Likewise.
13356 (i386-avx-linux.o): Likewise.
13357 (i386-avx-linux.c): Likewise.
13358 (amd64-avx.o): Likewise.
13359 (amd64-avx.c): Likewise.
13360 (amd64-avx-linux.o): Likewise.
13361 (amd64-avx-linux.c): Likewise.
13362
13363 * configure.srv (srv_i386_regobj): Add i386-avx.o.
13364 (srv_i386_linux_regobj): Add i386-avx-linux.o.
13365 (srv_amd64_regobj): Add amd64-avx.o.
13366 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
13367 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
13368 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
13369 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
13370 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
13371 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
13372 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
13373
13374 * i387-fp.c: Include "i386-xstate.h".
13375 (i387_xsave): New.
13376 (i387_cache_to_xsave): Likewise.
13377 (i387_xsave_to_cache): Likewise.
13378 (x86_xcr0): Likewise.
13379
13380 * i387-fp.h (i387_cache_to_xsave): Likewise.
13381 (i387_xsave_to_cache): Likewise.
13382 (x86_xcr0): Likewise.
13383
13384 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
13385 * linux-crisv32-low.c (target_regsets): Likewise.
13386 * linux-m68k-low.c (target_regsets): Likewise.
13387 * linux-mips-low.c (target_regsets): Likewise.
13388 * linux-ppc-low.c (target_regsets): Likewise.
13389 * linux-s390-low.c (target_regsets): Likewise.
13390 * linux-sh-low.c (target_regsets): Likewise.
13391 * linux-sparc-low.c (target_regsets): Likewise.
13392 * linux-xtensa-low.c (target_regsets): Likewise.
13393
13394 * linux-low.c: Include <sys/uio.h>.
13395 (regsets_fetch_inferior_registers): Support nt_type.
13396 (regsets_store_inferior_registers): Likewise.
13397 (linux_process_qsupported): New.
13398 (linux_target_ops): Add linux_process_qsupported.
13399
13400 * linux-low.h (regset_info): Add nt_type.
13401 (linux_target_ops): Add process_qsupported.
13402
13403 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
13404 and <sys/uio.h>.
13405 (init_registers_i386_avx_linux): New.
13406 (init_registers_amd64_avx_linux): Likewise.
13407 (xmltarget_i386_linux_no_xml): Likewise.
13408 (xmltarget_amd64_linux_no_xml): Likewise.
13409 (PTRACE_GETREGSET): Likewise.
13410 (PTRACE_SETREGSET): Likewise.
13411 (x86_fill_xstateregset): Likewise.
13412 (x86_store_xstateregset): Likewise.
13413 (use_xml): Likewise.
13414 (x86_linux_update_xmltarget): Likewise.
13415 (x86_linux_process_qsupported): Likewise.
13416 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
13417 (x86_arch_setup): Don't call init_registers_amd64_linux nor
13418 init_registers_i386_linux here. Call
13419 x86_linux_update_xmltarget.
13420 (the_low_target): Add x86_linux_process_qsupported.
13421
13422 * server.c (handle_query): Call target_process_qsupported.
13423
13424 * target.h (target_ops): Add process_qsupported.
13425 (target_process_qsupported): New.
13426
13427 2010-04-03 Pedro Alves <pedro@codesourcery.com>
13428
13429 * inferiors.c (add_thread): Set last_status kind to
13430 TARGET_WAITKIND_IGNORE.
13431 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
13432 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
13433 (linux_wait_1): Move `thread' local definition to block that uses
13434 it. Don't NULL initialize `event_child'.
13435 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
13436 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
13437 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
13438
13439 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13440
13441 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
13442 an extended waitstatus, or by a watchpoint.
13443 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
13444 thread was stepping or has been stopped by a watchpoint.
13445
13446 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13447
13448 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
13449 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
13450 of another, then delete the previous, and validate all
13451 breakpoints.
13452 (validate_inserted_breakpoint): New.
13453 (delete_disabled_breakpoints): New.
13454 (validate_breakpoints): New.
13455 (check_mem_read): Validate breakpoints before trusting their
13456 shadow. Delete disabled breakpoints.
13457 (check_mem_write): Validate breakpoints before trusting they
13458 should be inserted. Delete disabled breakpoints.
13459 * mem-break.h (validate_breakpoints):
13460 * server.c (handle_query): Validate breakpoints when we see a
13461 qSymbol query.
13462
13463 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13464
13465 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
13466 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
13467 if we could tell there's a GDB breakpoint at stop_pc.
13468 (need_step_over_p): Don't do a step over if we find a GDB
13469 breakpoint at the resume PC.
13470
13471 * mem-break.c (struct raw_breakpoint): New.
13472 (enum bkpt_type): New type `gdb_breakpoint'.
13473 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
13474 fields. New field `raw'.
13475 (find_raw_breakpoint_at): New.
13476 (set_raw_breakpoint_at): Handle refcounting. Create a raw
13477 breakpoint instead.
13478 (set_breakpoint_at): Adjust.
13479 (delete_raw_breakpoint): New.
13480 (release_breakpoint): New.
13481 (delete_breakpoint): Rename to...
13482 (delete_breakpoint_1): ... this. Add proc parameter. Use
13483 release_breakpoint. Return ENOENT.
13484 (delete_breakpoint): Reimplement.
13485 (find_breakpoint_at): Delete.
13486 (find_gdb_breakpoint_at): New.
13487 (delete_breakpoint_at): Delete.
13488 (set_gdb_breakpoint_at): New.
13489 (delete_gdb_breakpoint_at): New.
13490 (gdb_breakpoint_here): New.
13491 (set_reinsert_breakpoint): Use release_breakpoint.
13492 (uninsert_breakpoint): Rename to ...
13493 (uninsert_raw_breakpoint): ... this.
13494 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
13495 (reinsert_raw_breakpoint): Change parameter type to
13496 raw_breakpoint.
13497 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
13498 instead.
13499 (check_breakpoints): Adjust. Use release_breakpoint.
13500 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
13501 (breakpoint_inserted_here): Ditto.
13502 (check_mem_read): Adjust to iterate over raw breakpoints instead.
13503 Don't trust the breakpoint's shadow if it is not inserted.
13504 (check_mem_write): Adjust to iterate over raw breakpoints instead.
13505 (delete_all_breakpoints): Adjust.
13506 (free_all_breakpoints): Mark all breakpoints as uninserted, and
13507 use delete_breakpoint_1.
13508
13509 * mem-break.h (breakpoints_supported): Delete declaration.
13510 (set_gdb_breakpoint_at): Declare.
13511 (gdb_breakpoint_here): Declare.
13512 (delete_breakpoint_at): Delete.
13513 (delete_gdb_breakpoint_at): Declare.
13514
13515 * server.h (struct raw_breakpoint): Forward declare.
13516 (struct process_info): New field `raw_breakpoints'.
13517
13518 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
13519 breakpoints.
13520
13521 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13522
13523 * linux-low.c (status_pending_p_callback): Fix comment.
13524 (linux_wait_for_event_1): Move most of the internal breakpoint
13525 handling from here...
13526 (linux_wait_1): ... to here.
13527 (count_events_callback): New.
13528 (select_singlestep_lwp_callback): New.
13529 (select_event_lwp_callback): New.
13530 (cancel_breakpoints_callback): New.
13531 (select_event_lwp): New.
13532 (linux_wait_1): Simplify internal breakpoint handling. Give equal
13533 priority to all LWPs that have had events that should be reported
13534 to the client. Cancel breakpoints when about to reporting the
13535 event to the client, not while stopping lwps. No longer cancel
13536 finished single-steps here.
13537 (cancel_finished_single_step): Delete.
13538 (cancel_finished_single_steps): Delete.
13539
13540 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13541
13542 * mem-break.c (enum bkpt_type): New.
13543 (struct breakpoint): New field `type'.
13544 (set_breakpoint_at): Change return type to struct breakpoint
13545 pointer. Set type to `other_breakpoint' by default.
13546 (delete_breakpoint): Rewrite, supporting more than one breakpoint
13547 in the breakpoint list.
13548 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
13549 (reinsert_breakpoint): Rename to ...
13550 (reinsert_raw_breakpoint): ... this.
13551 (reinsert_breakpoints_at): Adjust.
13552 * mem-break.h (struct breakpoint): Declare.
13553 (set_breakpoint_at): Change return type to struct breakpoint
13554 pointer.
13555
13556 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13557
13558 * server.c (handle_query): Assign, not compare.
13559
13560 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13561
13562 Teach linux gdbserver to step-over-breakpoints.
13563
13564 * linux-low.c (can_hardware_single_step): New.
13565 (supports_breakpoints): New.
13566 (handle_extended_wait): If stopping threads, read the stop pc of
13567 the new cloned LWP.
13568 (get_pc): New.
13569 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
13570 low target doesn't support retrieving the PC.
13571 (add_lwp): Set last_resume_kind to resume_continue.
13572 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
13573 (linux_attach): Don't clear stop_expected. Set the lwp's
13574 last_resume_kind to resume_stop.
13575 (linux_detach_one_lwp): Don't check for removed breakpoints.
13576 (check_removed_breakpoint): Delete.
13577 (status_pending_p): Rename to ...
13578 (status_pending_p_callback): ... this. Don't check for removed
13579 breakpoints. Don't consider threads that are stopped from GDB's
13580 perspective.
13581 (linux_wait_for_lwp): Always read the stop_pc here.
13582 (cancel_breakpoint): New.
13583 (step_over_bkpt): New global.
13584 (linux_wait_for_event_1): Implement stepping over breakpoints.
13585 (gdb_wants_lwp_stopped): New.
13586 (gdb_wants_all_stopped): New.
13587 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
13588 single-step traps here. Store the thread's last reported target
13589 wait status.
13590 (send_sigstop): Don't clear stop_expected. Always set it,
13591 instead.
13592 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
13593 (cancel_finished_single_step): New.
13594 (cancel_finished_single_steps): New.
13595 (wait_for_sigstop): Don't cancel finished single-step traps here.
13596 (linux_resume_one_lwp): Don't check for removed breakpoints.
13597 Don't set `step' on non-hardware step archs.
13598 (linux_set_resume_request): Ignore resume_stop requests if already
13599 stopping or stopped. Set the lwp's last_resume_kind.
13600 (resume_status_pending_p): Don't check for removed breakpoints.
13601 (need_step_over_p): New.
13602 (start_step_over): New.
13603 (finish_step_over): New.
13604 (linux_resume_one_thread): Always queue a sigstop for resume_stop
13605 requests. Clear the thread's last reported target waitstatus.
13606 Don't use the `suspended' flag. Don't consider pending breakpoints.
13607 (linux_resume): Start a step-over if necessary.
13608 (proceed_one_lwp): New.
13609 (proceed_all_lwps): New.
13610 (unstop_all_lwps): New.
13611 * linux-low.h (struct lwp_info): Rewrite comment for the
13612 `suspended' flag. Add the `stop_pc' field. Delete the
13613 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
13614 Add `'last_resume_kind' and `need_step_over' fields.
13615 * inferiors.c (struct thread_info): Delete, moved elsewhere.
13616 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
13617 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
13618 (set_raw_breakpoint_at): New.
13619 (set_breakpoint_at): Rewrite to use it.
13620 (reinsert_breakpoint_handler): Delete.
13621 (set_reinsert_breakpoint): New.
13622 (reinsert_breakpoint_by_bp): Delete.
13623 (delete_reinsert_breakpoints): New.
13624 (uninsert_breakpoint): Rewrite.
13625 (uninsert_breakpoints_at): New.
13626 (reinsert_breakpoint): Rewrite.
13627 (reinsert_breakpoints_at): New.
13628 (check_breakpoints): Rewrite.
13629 (breakpoint_here): New.
13630 (breakpoint_inserted_here): New.
13631 (check_mem_read): Adjust.
13632 * mem-break.h (breakpoints_supported, breakpoint_here)
13633 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
13634 (reinsert_breakpoint_by_bp): Delete declaration.
13635 (delete_reinsert_breakpoints): Declare.
13636 (reinsert_breakpoint): Delete declaration.
13637 (reinsert_breakpoints_at): Declare.
13638 (uninsert_breakpoint): Delete declaration.
13639 (uninsert_breakpoints_at): Declare.
13640 (check_breakpoints): Adjust prototype.
13641 * server.h: Adjust include order.
13642 (struct thread_info): Declare here. Add a `last_status' field.
13643
13644 2010-03-23 Michael Snyder <msnyder@vmware.com>
13645
13646 * server.c (crc32): New function.
13647 (handle_query): Add handling for 'qCRC:' request.
13648
13649 2010-03-23 Pedro Alves <pedro@codesourcery.com>
13650
13651 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
13652 lwp had been stopped by a watchpoint.
13653
13654 2010-03-16 Pedro Alves <pedro@codesourcery.com>
13655
13656 * server.h (internal_error): Declare.
13657 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
13658 * utils.c (internal_error): New function.
13659
13660 2010-03-15 Andreas Schwab <schwab@redhat.com>
13661
13662 * configure.srv: Fix typo setting srv_regobj.
13663
13664 2010-03-15 Pedro Alves <pedro@codesourcery.com>
13665
13666 * linux-low.c (fetch_register): Avoid passing a non string literal
13667 format to `error'.
13668 (usr_store_inferior_registers): Ditto.
13669
13670 2010-03-14 Pedro Alves <pedro@codesourcery.com>
13671
13672 * linux-low.c (linux_write_memory): Bail out early if peeking
13673 memory failed.
13674
13675 2010-03-14 Pedro Alves <pedro@codesourcery.com>
13676
13677 * linux-low.h (struct lwp_info): New fields
13678 `stopped_by_watchpoint' and `stopped_data_address'.
13679 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
13680 here, and cache them in the lwp object.
13681 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
13682 directly.
13683 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
13684 field.
13685 (linux_stopped_by_watchpoint): Rewrite.
13686 (linux_stopped_data_address): Rewrite.
13687
13688 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
13689
13690 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
13691 switching the current inferior, not before.
13692
13693 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
13694
13695 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
13696 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
13697 i386-linux.c and amd64-linux.c.
13698 (reg-i386.o): Removed.
13699 (reg-i386.c): Likewise.
13700 (reg-i386-linux.o): Likewise.
13701 (reg-i386-linux.c): Likewise.
13702 (reg-x86-64.o): Likewise.
13703 (reg-x86-64.c): Likewise.
13704 (reg-x86-64-linux.o): Likewise.
13705 (reg-x86-64-linux.c): Likewise.
13706 (i386.o): New.
13707 (i386.c): Likewise.
13708 (i386-linux.o): Likewise.
13709 (i386-linux.c): Likewise.
13710 (amd64.o): Likewise.
13711 (amd64.c): Likewise.
13712 (amd64-linux.o): Likewise.
13713 (amd64-linux.c): Likewise.
13714
13715 * configure.srv (srv_i386_regobj): New.
13716 (srv_i386_linux_regobj): Likewise.
13717 (srv_amd64_regobj): Likewise.
13718 (srv_amd64_linux_regobj): Likewise.
13719 (srv_i386_32bit_xmlfiles): Likewise.
13720 (srv_i386_64bit_xmlfiles): Likewise.
13721 (srv_i386_xmlfiles): Likewise.
13722 (srv_amd64_xmlfiles): Likewise.
13723 (srv_i386_linux_xmlfiles): Likewise.
13724 (srv_amd64_linux_xmlfiles): Likewise.
13725 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
13726 srv_xmlfiles to $srv_i386_xmlfiles.
13727 (i[34567]86-*-mingw32ce*): Likewise.
13728 (i[34567]86-*-mingw*): Likewise.
13729 (i[34567]86-*-nto*): Likewise.
13730 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
13731 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
13732 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
13733 (x86_64-*-linux*): Likewise.
13734
13735 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
13736 (init_registers_amd64_linux): New.
13737 (x86_arch_setup): Replace init_registers_x86_64_linux with
13738 init_registers_amd64_linux.
13739
13740 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
13741
13742 * configure.ac: Check for libdl. If it is not available link against
13743 static libthread_db.
13744 * configure: Regenerate.
13745
13746 2010-02-22 Pedro Alves <pedro@codesourcery.com>
13747
13748 PR9605
13749
13750 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
13751 handing a read watchpoint.
13752 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
13753
13754 2010-02-12 Doug Evans <dje@google.com>
13755
13756 * linux-low.c (linux_supports_tracefork_flag): Document.
13757 (linux_look_up_symbols): Add comment.
13758
13759 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
13760
13761 * regcache.c (supply_register): Clear regcache if buf is NULL.
13762
13763 2010-02-02 Nicolas Roche <roche@sourceware.org>
13764 Joel Brobecker <brobecker@adacore.com>
13765
13766 * inferiors.c (find_inferior): Add function documentation.
13767 (unloaded_dll): Handle the case where the unloaded dll has not
13768 been previously registered in the dll list.
13769
13770 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
13771
13772 * linux-arm-low.c (thumb_breakpoint_len): Delete.
13773 (thumb2_breakpoint): New.
13774 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
13775
13776 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
13777
13778 * linux-low.c (get_stop_pc): Check for SIGTRAP.
13779 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
13780 breakpoints.
13781
13782 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13783
13784 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
13785
13786 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13787
13788 * linux-s390-low.c (s390_collect_ptrace_register)
13789 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
13790
13791 2010-01-21 Doug Evans <dje@google.com>
13792
13793 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
13794 (PTRACE_ARG4_TYPE): New macro.
13795 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
13796 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
13797 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
13798 (usr_store_inferior_registers): Ditto.
13799 (linux_read_memory, linux_write_memory): Ditto.
13800 (linux_test_for_tracefork): Ditto.
13801
13802 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
13803 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
13804
13805 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13806
13807 * proc-service.c (ps_lgetregs): Don't refetch registers from the
13808 target.
13809
13810 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13811
13812 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
13813 prototype to take a regcache. Adjust.
13814
13815 2010-01-20 Pedro Alves <pedro@codesourcery.com>
13816
13817 * regcache.h (struct thread_info): Forward declare.
13818 (struct regcache): New.
13819 (new_register_cache): Adjust prototype.
13820 (get_thread_regcache): Declare.
13821 (free_register_cache): Adjust prototype.
13822 (registers_to_string, registers_from_string): Ditto.
13823 (supply_register, supply_register_by_name, collect_register)
13824 (collect_register_as_string, collect_register_by_name): Ditto.
13825 * regcache.c (struct inferior_regcache_data): Delete.
13826 (get_regcache): Rename to ...
13827 (get_thread_regcache): ... this. Adjust. Switch inferior before
13828 fetching registers.
13829 (regcache_invalidate_one): Adjust.
13830 (regcache_invalidate): Fix prototype.
13831 (new_register_cache): Return the new register cache.
13832 (free_register_cache): Change prototype.
13833 (realloc_register_cache): Adjust.
13834 (registers_to_string): Change prototype to take a regcache. Adjust.
13835 (registers_from_string): Ditto.
13836 (register_data): Ditto.
13837 (supply_register): Ditto.
13838 (supply_register_by_name): Ditto.
13839 (collect_register): Ditto.
13840 (collect_register_as_string): Ditto.
13841 (collect_register_by_name): Ditto.
13842 * server.c (process_serial_event): Adjust.
13843 * linux-low.h (regset_fill_func, regset_store_func): Change
13844 prototype.
13845 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
13846 Change prototype.
13847 * linux-low.c (get_stop_pc): Adjust.
13848 (check_removed_breakpoint): Adjust.
13849 (linux_wait_for_event): Adjust.
13850 (linux_resume_one_lwp): Adjust.
13851 (fetch_register): Add regcache parameter. Adjust.
13852 (usr_store_inferior_registers): Ditto.
13853 (regsets_fetch_inferior_registers): Ditto.
13854 (regsets_store_inferior_registers): Ditto.
13855 (linux_fetch_registers, linux_store_registers): Ditto.
13856 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
13857 regcache. Adjust.
13858 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
13859 Ditto.
13860 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
13861 prototype to take a regcache.
13862 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
13863 * remote-utils.c (convert_ascii_to_int, outreg)
13864 (prepare_resume_reply): Change prototype to take a regcache.
13865 Adjust.
13866 * target.h (struct target_ops) <fetch_registers, store_registers>:
13867 Change prototype to take a regcache.
13868 (fetch_inferior_registers, store_inferior_registers): Change
13869 prototype to take a regcache. Adjust.
13870 * proc-service.c (ps_lgetregs): Adjust.
13871 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
13872 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
13873 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
13874 take a regcache. Adjust.
13875 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
13876 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
13877 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
13878 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
13879 * linux-cris-low.c (cris_get_pc, cris_set_pc)
13880 (cris_cannot_fetch_register):
13881 (cris_breakpoint_at): Change prototype to take a regcache.
13882 Adjust.
13883 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
13884 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
13885 to take a regcache. Adjust.
13886 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
13887 Adjust.
13888 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
13889 take a regcache. Adjust.
13890 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
13891 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
13892 (m68k_set_pc): Change prototype to take a regcache. Adjust.
13893 * linux-mips-low.c (mips_get_pc):
13894 (mips_set_pc): Change prototype to take a regcache. Adjust.
13895 (mips_reinsert_addr): Adjust.
13896 (mips_collect_register): Change prototype to take a regcache.
13897 Adjust.
13898 (mips_supply_register):
13899 (mips_collect_register_32bit, mips_supply_register_32bit)
13900 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
13901 (mips_store_fpregset): Ditto.
13902 * linux-ppc-low.c (ppc_supply_ptrace_register)
13903 (ppc_supply_ptrace_register): Ditto.
13904 (parse_spufs_run): Adjust.
13905 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
13906 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
13907 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
13908 take a regcache. Adjust.
13909 * linux-s390-low.c (s390_collect_ptrace_register)
13910 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
13911 (s390_set_pc): Change prototype to take a regcache. Adjust.
13912 (s390_arch_setup): Adjust.
13913 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
13914 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
13915 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
13916 (sparc_fill_gregset, sparc_store_gregset_from_stack)
13917 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
13918 regcache. Adjust.
13919 (sparc_breakpoint_at): Adjust.
13920 * linux-xtensa-low.c (xtensa_fill_gregset):
13921 (xtensa_store_gregset):
13922 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
13923 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
13924 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
13925 prototype to take a regcache. Adjust.
13926 * win32-arm-low.c (arm_fetch_inferior_register)
13927 (arm_store_inferior_register): Change prototype to take a
13928 regcache. Adjust.
13929 * win32-i386-low.c (i386_fetch_inferior_register)
13930 (i386_store_inferior_register): Change prototype to take a
13931 regcache. Adjust.
13932 * win32-low.c (child_fetch_inferior_registers)
13933 (child_store_inferior_registers): Change prototype to take a
13934 regcache. Adjust.
13935 (win32_wait): Adjust.
13936 (win32_fetch_inferior_registers): Change prototype to take a
13937 regcache. Adjust.
13938 (win32_store_inferior_registers): Adjust.
13939 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
13940 store_inferior_register>: Change prototype to take a regcache.
13941
13942 2010-01-20 Doug Evans <dje@google.com>
13943
13944 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
13945 #ifdef.
13946 (linux_wait_for_event1, linux_init_signals): Ditto.
13947 (W_STOPCODE): Provide definition if missing.
13948
13949 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
13950
13951 * linux-low.c (linux_core_of_thread): New.
13952 (compare_ints, show_process, list_threads): New.
13953 (linux_qxfer_osdata): Report threads and cores.
13954 (linux_target_op): Register linux_core_of_thread.
13955 * remote-utils.c (prepare_resume_reply): Report the core.
13956 (buffer_xml_printf): Support %d specifier.
13957 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
13958 New.
13959 (handle_query): Handle qXfer:threads. Announce availability
13960 thereof.
13961 * target.h (struct target_ops): New field core_of_thread.
13962
13963 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
13964
13965 * Makefile.in (clean): Remove new generated files.
13966 (reg-s390.o, reg-s390.c): Remove rules.
13967 (reg-s390x.o, reg-s390x.c): Likewise.
13968 (s390-linux32.o, s390-linux32.c): Add rules.
13969 (s390-linux64.o, s390-linux64.c): Likewise.
13970 (s390x-linux64.o, s390x-linux64.c): Likewise.
13971 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
13972 * linux-s390-low.c: Include <elf.h>.
13973 (HWCAP_S390_HIGH_GPRS): Define if undefined.
13974 (init_registers_s390): Remove prototype.
13975 (init_registers_s390x): Likewise.
13976 (init_registers_s390_linux32): Add prototype.
13977 (init_registers_s390_linux64): Likewise.
13978 (init_registers_s390x_linux64): Likewise.
13979 (s390_num_regs_3264): New define.
13980 (s390_regmap_3264): New global variable.
13981 (s390_cannot_fetch_register): Remove obsolete check.
13982 (s390_cannot_store_register): Likewise.
13983 (s390_collect_ptrace_register): Handle upper/lower register halves.
13984 (s390_supply_ptrace_register): Likewise.
13985 (s390_fill_gregset): Update to register number changes.
13986 (s390_get_hwcap): New routine.
13987 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
13988 Install appropriate regmap and register set.
13989
13990 2010-01-01 Joel Brobecker <brobecker@adacore.com>
13991
13992 * server.c (gdbserver_version): Update copyright year to 2010.
13993 * gdbreplay.c (gdbreplay_version): Likewise.
13994
13995 2009-12-28 Doug Evans <dje@google.com>
13996
13997 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
13998 elf/external.h. Include <elf.h> instead but only if necessary.
13999
14000 2009-12-28 Pedro Alves <pedro@codesourcery.com>
14001
14002 * linux-low.c (linux_remove_process): Remove `detaching'
14003 parameter. Don't release/detach from thread_db here.
14004 (linux_kill): Release/detach from thread_db here, ...
14005 (linux_detach): ... and here, before actually detaching.
14006 (linux_wait_1): ... and here, when a process exits.
14007 * thread-db.c (any_thread_of): New.
14008 (thread_db_free): Switch the current inferior to a thread of the
14009 passed in process.
14010
14011 2009-12-21 Doug Evans <dje@google.com>
14012
14013 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
14014
14015 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
14016 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
14017 warning ifndef __NR_tkill. Move setting of errno there too.
14018 Delete unnecessary resetting of errno after syscall.
14019 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
14020
14021 * configure.ac: Check for dladdr.
14022 * config.in: Regenerate.
14023 * configure: Regenerate.
14024 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
14025 (try_thread_db_load): Update.
14026
14027 * linux-low.c (my_waitpid): Delete unnecessary prototype.
14028
14029 2009-12-18 Doug Evans <dje@google.com>
14030
14031 * event-loop.c: Include unistd.h if it exists.
14032
14033 * linux-low.c (my_waitpid): Move definition away from being in
14034 between linux_tracefork_child/linux_test_for_tracefork.
14035
14036 * gdb_proc_service.h (psaddr_t): Fix type.
14037 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
14038 signature to match glibc.
14039
14040 2009-12-16 Doug Evans <dje@google.com>
14041
14042 * linux-low.c (linux_read_memory): Fix argument to read.
14043
14044 2009-11-26 Pedro Alves <pedro@codesourcery.com>
14045
14046 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
14047 events, don't leave current_inferior pointing at null.
14048
14049 2009-11-26 Pedro Alves <pedro@codesourcery.com>
14050
14051 * win32-low.c (LOG): Delete.
14052 (OUTMSG): Output to stderr.
14053 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
14054 on compile time LOG macro.
14055 (win32_wait): Fix debug output.
14056
14057 2009-11-26 Pedro Alves <pedro@codesourcery.com>
14058
14059 * win32-low.c (win32_add_one_solib): If the dll name is
14060 "ntdll.dll", prepend the system directory to the dll path.
14061
14062 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
14063
14064 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
14065
14066 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
14067 Vladimir Prus <vladimir@codesourcery.com>
14068
14069 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
14070 * configure.ac: Check for __mcoldfire__ and set
14071 gdb_cv_m68k_is_coldfire.
14072 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
14073 reg-cf.o and reg-m68k.o.
14074 * configure: Regenerated.
14075
14076 2009-11-16 Pedro Alves <pedro@codesourcery.com>
14077
14078 * linux-low.c (linux_remove_process): Add `detaching' parameter.
14079 Pass it to thread_db_free.
14080 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
14081 proper `detaching' argument to linux_remove_process.
14082 * linux-low.h (thread_db_free): Add `detaching' parameter.
14083 * thread-db.c (thread_db_init): Pass false as `detaching' argument
14084 to thread_db_free.
14085 (thread_db_free): Add `detaching' parameter. Only
14086 call td_ta_clear_event if detaching from process.
14087
14088 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
14089
14090 * thread-db.c (thread_db_free): Fix typo.
14091
14092 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
14093
14094 PR gdb/10838
14095 * thread-db.c (thread_db_free): Call td_ta_clear_event.
14096
14097 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
14098
14099 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
14100 with an i686 compiler.
14101 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
14102 needed.
14103 * configure: Rebuilt.
14104
14105 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
14106
14107 PR gdb/10783
14108
14109 * server.c (handle_search_memory_1): Correct read_addr initialization
14110 in loop for searching subsequent chunks.
14111
14112 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
14113
14114 * configure.ac: New --with-libthread-db option.
14115 * thread-db.c: Allow direct dependence on libthread_db.
14116 (thread_db_free): Adjust.
14117 * config.in: Regenerate.
14118 * configure: Likewise.
14119
14120 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
14121
14122 PR gdb/10757
14123 * thread-db.c (attach_thread): New function.
14124 (maybe_attach_thread): Return success/failure.
14125 (find_new_threads_callback): Adjust.
14126 (thread_db_find_new_threads): Loop until no new threads.
14127
14128 2009-10-13 Pedro Alves <pedro@codesourcery.com>
14129
14130 * proc-service.c (ps_lgetregs): Formatting.
14131
14132 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
14133
14134 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
14135 * configure.ac: Adjust.
14136 * linux-low.h (struct process_info_private): Move members to struct
14137 thread_db.
14138 (thread_db_free, thread_db_handle_monitor_command): New prototype.
14139 * linux-low.c (linux_remove_process): Adjust.
14140 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
14141 * server.c (handle_query): Move code ...
14142 (handle_monitor_command): ... here. New function.
14143 * target.h (struct target_ops): New member.
14144 * thread-db.c (struct thread_db): New.
14145 (libthread_db_search_path): New variable.
14146 (thread_db_create_event, thread_db_enable_reporting)
14147 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
14148 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
14149 (try_thread_db_load_1, dladdr_to_soname): New functions.
14150 (try_thread_db_load, thread_db_load_search): New functions.
14151 (thread_db_init): Search for libthread_db.
14152 (thread_db_free): New function.
14153 (thread_db_handle_monitor_command): Likewise.
14154 * config.in: Regenerate.
14155 * configure: Regenerate.
14156
14157 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
14158
14159 * spu-low.c (spu_kill): Wait for inferior to terminate.
14160 Call clear_inferiors.
14161 (spu_detach): Call clear_inferiors.
14162
14163 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
14164
14165 * aclocal.m4: Regenerate.
14166 * config.in: Likewise.
14167 * configure: Likewise.
14168
14169 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14170
14171 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
14172 (parse_spufs_run): New function.
14173 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
14174 (ppc_breakpoint_at): Handle SPU breakpoints.
14175
14176 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14177
14178 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
14179 (SPUFS_MAGIC): Define.
14180 (spu_enumerate_spu_ids): New function.
14181 (linux_qxfer_spu): New function.
14182 (linux_target_ops): Install linux_qxfer_spu.
14183
14184 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14185
14186 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
14187 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
14188 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
14189 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
14190 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
14191 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
14192 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
14193 (init_registers_powerpc_cell32l): Add prototype.
14194 (init_registers_powerpc_cell64l): Likewise.
14195 (ppc_arch_setup): Detect Cell/B.E. architecture.
14196
14197 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
14198
14199 * Makefile.in (datarootdir): New variable.
14200
14201 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
14202
14203 * linux-low.c (linux_write_memory): Update debugging output.
14204 * Makefile.in (clean): Add new descriptions.
14205 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
14206 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
14207 * configure.srv: Add new files for arm*-*-linux*.
14208 * linux-arm-low.c: Add new declarations.
14209 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
14210 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
14211 (HWCAP_VFPv3D16): New.
14212 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
14213 instead of __IWMMXT__.
14214 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
14215 (arm_arch_setup): New.
14216 (target_regsets): Remove #ifdef. Add VFP regset.
14217 (the_low_target): Use arm_arch_setup.
14218
14219 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
14220
14221 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
14222 the main thread again.
14223
14224 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
14225
14226 Adding Neutrino gdbserver.
14227 * configure: Regenerated.
14228 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
14229 * configure.srv (i[34567]86-*-nto*): New target.
14230 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
14231 * remote-utils.c [__QNX__]: Include sys/iomgr.h
14232 (nto_comctrl) [__QNX__]: New function.
14233 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
14234
14235 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
14236
14237 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
14238 srv_tgtobj.
14239
14240 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
14241 Pedro Alves <pedro@codesourcery.com>
14242
14243 * win32-i386-low.c (i386_get_thread_context): Handle systems that
14244 don't support CONTEXT_EXTENDED_REGISTERS.
14245 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
14246 (the_low_target): Install them.
14247 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
14248 failing with ERROR_PIPE_NOT_CONNECTED.
14249
14250 2009-06-30 Doug Evans <dje@google.com>
14251 Pierre Muller <muller@ics.u-strasbg.fr>
14252
14253 Add h/w watchpoint support to x86-linux, win32-i386.
14254 * Makefile.in (SFILES): Add i386-low.c
14255 (i386_low_h): Define.
14256 (i386-low.o): Add dependencies.
14257 (linux-x86-low.o): Add i386-low.h dependency.
14258 (win32-i386-low.o): Ditto.
14259 * i386-low.c: New file.
14260 * i386-low.h: New file.
14261 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
14262 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
14263 * linux-low.c (linux_add_process): Initialize arch_private.
14264 (linux_remove_process): Free arch_private.
14265 (add_lwp): Initialize arch_private.
14266 (delete_lwp): Free arch_private.
14267 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
14268 provided.
14269 * linux-low.h (process_info_private): New member arch_private.
14270 (lwp_info): New member arch_private.
14271 (linux_target_ops): New members new_process, new_thread,
14272 prepare_to_resume.
14273 (ptid_of): New macro.
14274 * linux-x86-low.c: Include stddef.h, i386-low.h.
14275 (arch_process_info): New struct.
14276 (arch_lwp_info): New struct.
14277 (x86_linux_dr_get, x86_linux_dr_set): New functions.
14278 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
14279 (i386_dr_low_get_status): New function.
14280 (x86_insert_point, x86_remove_point): New functions.
14281 (x86_stopped_by_watchpoint): New function.
14282 (x86_stopped_data_address): New function.
14283 (x86_linux_new_process, x86_linux_new_thread): New functions.
14284 (x86_linux_prepare_to_resume): New function.
14285 (the_low_target): Add entries for insert_point, remove_point,
14286 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
14287 prepare_to_resume.
14288 * server.c (debug_hw_points): New global.
14289 (monitor_show_help): Document set debug-hw-points.
14290 (handle_query): Process "set debug-hw-points".
14291 * server.h (debug_hw_points): Declare.
14292 (paddress): Declare.
14293 * utils.c (NUMCELLS, CELLSIZE): New macros.
14294 (get_sell, xsnprintf, paddress): New functions.
14295 * win32-arm-low.c (the_low_target): Add entries for insert_point,
14296 remove_point, stopped_by_watchpoint, stopped_data_address.
14297 * win32-i386-low.c: Include i386-low.h.
14298 (debug_reg_state): Replaces dr.
14299 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
14300 (i386_dr_low_get_status): New function.
14301 (i386_insert_point, i386_remove_point): New functions.
14302 (i386_stopped_by_watchpoint): New function.
14303 (i386_stopped_data_address): New function.
14304 (i386_initial_stuff): Update.
14305 (get_thread_context,set_thread_context,i386_thread_added): Update.
14306 (the_low_target): Add entries for insert_point,
14307 remove_point, stopped_by_watchpoint, stopped_data_address.
14308 * win32-low.c (win32_insert_watchpoint): New function.
14309 (win32_remove_watchpoint): New function.
14310 (win32_stopped_by_watchpoint): New function.
14311 (win32_stopped_data_address): New function.
14312 (win32_target_ops): Add entries for insert_watchpoint,
14313 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
14314 * win32-low.h (win32_target_ops): New members insert_point,
14315 remove_point, stopped_by_watchpoint, stopped_data_address.
14316
14317 2009-06-25 Pedro Alves <pedro@codesourcery.com>
14318
14319 * server.c (process_serial_event): Re-return unsupported, not
14320 error, if the type isn't recognized. Re-allow supporting only
14321 insert or remove packets. Also call require_running for
14322 breakpoints. Add missing break statement to default case. Tidy.
14323 * target.h (struct target_ops): Rename insert_watchpoint to
14324 insert_point, and remove_watchpoint to remove_point.
14325
14326 * linux-low.h (struct linux_target_ops): Likewise.
14327 * linux-low.c (linux_insert_watchpoint): Rename to ...
14328 (linux_insert_point): ... this. Adjust.
14329 (linux_remove_watchpoint): Rename to ...
14330 (linux_remove_point): ... this. Adjust.
14331 (linux_target_ops): Adjust.
14332 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
14333 (cris_insert_point): ... this.
14334 (cris_remove_watchpoint): Rename to ...
14335 (cris_remove_point): ... this.
14336 (the_low_target): Adjust.
14337
14338 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
14339
14340 * server.c (handle_v_kill): Pass signal_pid to
14341 kill_inferior if multi_process is zero.
14342
14343 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
14344
14345 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
14346 * target.h (target_ops): Comment for *_watchpoint to make it clear
14347 the functions can get types '0' and '1'.
14348
14349 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
14350
14351 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
14352 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
14353 * regcache.c (get_regcache): Likewise.
14354 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
14355 * win32-low.c (child_fetch_inferior_registers): Remove check for
14356 regno 0.
14357
14358 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
14359 Pedro Alves <pedro@codesourcery.com>
14360
14361 * target.h (struct target_ops) <supports_multi_process>: New
14362 callback.
14363 (target_supports_multi_process): New.
14364 * server.c (handle_query): Even if GDB reports support, only
14365 enable multi-process if the target also supports it. Report
14366 multi-process support only if the target backend supports it.
14367 * linux-low.c (linux_supports_multi_process): New function.
14368 (linux_target_ops): Install it as target_supports_multi_process
14369 callback.
14370
14371 2009-05-24 Doug Evans <dje@google.com>
14372
14373 Global renaming of find_thread_pid to find_thread_ptid.
14374 * server.h (find_thread_ptid): Renamed from find_thread_pid.
14375 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
14376 All callers updated.
14377
14378 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
14379 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
14380 directly.
14381
14382 * linux-low.c (get_stop_pc): Print pc if debug_threads.
14383 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
14384 (linux_resume_one_lwp): Ditto.
14385
14386 2009-05-23 Doug Evans <dje@google.com>
14387
14388 * linux-low.c (linux_resume_one_lwp): Change type of first arg
14389 from struct inferior_list_entry * to struct lwp_info *.
14390 All callers updated.
14391
14392 2009-05-13 Doug Evans <dje@google.com>
14393
14394 * linux-x86-low.c: Don't include assert.h.
14395 (x86_siginfo_fixup): Use fatal, not assert.
14396 (x86_arch_setup): Fix comment.
14397
14398 2009-05-12 Doug Evans <dje@google.com>
14399
14400 Biarch support for i386/amd64 gdbserver.
14401 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
14402 Add linux-x86-low.c.
14403 (linux-i386-low.o, linux-x86-64-low.o): Delete.
14404 (linux-x86-low.o): Add.
14405 * linux-x86-64-low.c: Delete.
14406 * linux-i386-low.c: Delete.
14407 * linux-x86-low.c: New file.
14408 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
14409 linux-x86-low.o.
14410 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
14411 linux-x86-low.o.
14412 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
14413 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
14414 (linux_child_pid_to_exec_file): New function.
14415 (elf_64_header_p, elf_64_file_p): New functions.
14416 (siginfo_fixup): New function.
14417 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
14418 give target a chance to convert layout.
14419 * linux-low.h (linux_target_ops): New member siginfo_fixup.
14420 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
14421
14422 2009-05-07 Doug Evans <dje@google.com>
14423
14424 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
14425 (regsets_store_inferior_registers): Ditto.
14426
14427 2009-05-06 Pedro Alves <pedro@codesourcery.com>
14428
14429 PR server/10048
14430
14431 * linux-low.c (must_set_ptrace_flags): Delete.
14432 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
14433 of the global.
14434 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
14435 `lwp->must_set_ptrace_flags' instead.
14436 (linux_wait_for_event_1): Set ptrace options here.
14437 (linux_wait_1): ... not here.
14438
14439 2009-04-30 Doug Evans <dje@google.com>
14440
14441 * inferiors.c (started_inferior_callback): New function.
14442 (attached_inferior_callback): New function.
14443 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
14444 * server.c (print_started_pid, print_attached_pid): New functions.
14445 (detach_or_kill_for_exit): New function.
14446 (main): Call it instead of for_each_inferior (kill_inferior_callback).
14447 * server.h (have_started_inferiors_p): Declare.
14448 (have_attached_inferiors_p): Declare.
14449
14450 * inferiors.c (remove_process): Fix memory leak, free process.
14451 * linux-low.c (linux_remove_process): New function.
14452 (linux_kill): Call it instead of remove_process.
14453 (linux_detach, linux_wait_1): Ditto.
14454
14455 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
14456
14457 * configure.srv: Add x86 Windows CE target.
14458
14459 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
14460
14461 * inferiors.c (get_thread_process): Make global.
14462 * server.h (get_thread_process): Add prototype.
14463 * thread-db.c (find_one_thread): Use get_thread_process
14464 instead of current_process.
14465 (thread_db_get_tls_address): Do not crash if called when
14466 thread layer is not yet initialized.
14467
14468 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
14469
14470 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
14471 * spu-low.c (current_tid): Rename to ...
14472 (current_ptid): ... this.
14473 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
14474 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
14475 ptid_get_lwp (current_ptid) instead of current_tid.
14476 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
14477 instead of current_tid. Use find_process_pid to verify pid
14478 argument is valid. Pass proper argument to remove_process.
14479 (spu_thread_alive): Compare current_ptid instead of current_tid.
14480 (spu_resume): Likewise.
14481
14482 2009-04-02 Pedro Alves <pedro@codesourcery.com>
14483
14484 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
14485 variable.
14486
14487 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14488
14489 Implement the multiprocess extensions, and add linux multiprocess
14490 support.
14491
14492 * server.h (ULONGEST): Declare.
14493 (struct ptid, ptid_t): New.
14494 (minus_one_ptid, null_ptid): Declare.
14495 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
14496 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
14497 (struct inferior_list_entry): Change `id' type from unsigned from
14498 to ptid_t.
14499 (struct sym_cache, struct breakpoint, struct
14500 process_info_private): Forward declare.
14501 (struct process_info): Declare.
14502 (current_process): Declare.
14503 (all_processes): Declare.
14504 (initialize_inferiors): Declare.
14505 (add_thread): Adjust to use ptid_t.
14506 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
14507 (add_process, remove_process, find_thread_pid): Declare.
14508 (find_inferior_id): Adjust to use ptid_t.
14509 (cont_thread, general_thread, step_thread): Change type to ptid_t.
14510 (multi_process): Declare.
14511 (push_event): Adjust to use ptid_t.
14512 (read_ptid, write_ptid): Declare.
14513 (prepare_resume_reply): Adjust to use ptid_t.
14514 (clear_symbol_cache): Declare.
14515 * inferiors.c (all_processes): New.
14516 (null_ptid, minus_one_ptid): New.
14517 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
14518 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
14519 (add_thread): Change unsigned long to ptid. Remove gdb_id
14520 parameter. Adjust.
14521 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
14522 (gdb_id_to_thread): Rename to ...
14523 (find_thread_pid): ... this. Change unsigned long to ptid.
14524 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
14525 (loaded_dll, pull_pid_from_list): Adjust.
14526 (add_process, remove_process, find_process_pid)
14527 (get_thread_process, current_process, initialize_inferiors): New.
14528 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
14529 (struct target_waitstatus) <related_pid>: Ditto.
14530 (struct target_ops) <kill, detach>: Add `pid' argument. Change
14531 return type to int.
14532 (struct target_ops) <join>: Add `pid' argument.
14533 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
14534 (struct target_ops) <wait>: Add `ptid' field. Change return type
14535 to ptid.
14536 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
14537 (mywait): Add `ptid' argument. Change return type to ptid_t.
14538 (target_pid_to_str): Declare.
14539 * target.c (set_desired_inferior): Adjust to use ptids.
14540 (mywait): Add new `ptid' argument. Adjust.
14541 (target_pid_to_str): New.
14542 * mem-break.h (free_all_breakpoints): Declare.
14543 * mem-break.c (breakpoints): Delelete.
14544 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
14545 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
14546 to use per-process breakpoint list.
14547 (free_all_breakpoints): New.
14548 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
14549 (symbol_cache, all_symbols_looked_up): Delete.
14550 (hexchars): New.
14551 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
14552 read_ptid): New.
14553 (prepare_resume_reply): Change ptid argument's type from unsigned
14554 long to ptid_t. Adjust. Implement W;process and X;process.
14555 (free_sym_cache, clear_symbol_cache): New.
14556 (look_up_one_symbol): Adjust to per-process symbol cache. *
14557 * server.c (cont_thread, general_thread, step_thread): Change type
14558 to ptid_t.
14559 (attached): Delete.
14560 (multi_process): New.
14561 (last_ptid): Change type to ptid_t.
14562 (struct vstop_notif) <ptid>: Change type to ptid_t.
14563 (queue_stop_reply, push_event): Change `ptid' argument's type to
14564 ptid_t.
14565 (discard_queued_stop_replies): Add `pid' argument.
14566 (start_inferior): Adjust to use ptids. Adjust to mywait interface
14567 changes. Don't reference the `attached' global.
14568 (attach_inferior): Adjust to mywait interface changes.
14569 (handle_query): Adjust to use ptids. Parse GDB's qSupported
14570 features. Handle and report "multiprocess+". Handle
14571 "qAttached:PID".
14572 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
14573 changes.
14574 (handle_v_kill): New.
14575 (handle_v_stopped): Adjust to use target_pid_to_str.
14576 (handle_v_requests): Allow multiple attaches and runs when
14577 multiprocess extensions are in effect. Handle "vKill".
14578 (myresume): Adjust to use ptids.
14579 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
14580 (handle_status): Adjust to discard_queued_stop_replies interface
14581 change.
14582 (first_thread_of, kill_inferior_callback)
14583 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
14584 (main): Call initialize_inferiors. Adjust to use ptids, killing
14585 and detaching from all inferiors. Handle multiprocess packet
14586 variants.
14587 * linux-low.h: Include gdb_proc_service.h.
14588 (struct process_info_private): New.
14589 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
14590 <lwpid_of>: Use ptid_get_lwp.
14591 (get_lwp_thread): Adjust.
14592 (struct lwp_info): Add `dead' member.
14593 (find_lwp_pid): Declare.
14594 * linux-low.c (thread_db_active): Delete.
14595 (new_inferior): Adjust comment.
14596 (inferior_pid): Delete.
14597 (linux_add_process): New.
14598 (handle_extended_wait): Adjust.
14599 (add_lwp): Change unsigned long to ptid.
14600 (linux_create_inferior): Add process to processes table. Adjust
14601 to use ptids. Don't set new_inferior here.
14602 (linux_attach_lwp): Rename to ...
14603 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
14604 it. Adjust to use ptids.
14605 (linux_attach_lwp): New.
14606 (linux_attach): Add process to processes table. Don't set
14607 new_inferior here.
14608 (struct counter): New.
14609 (second_thread_of_pid_p, last_thread_of_process_p): New.
14610 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
14611 multiple processes.
14612 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
14613 processes. Remove process from process table.
14614 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
14615 to multiple processes.
14616 (any_thread_of): New.
14617 (linux_detach): Add `pid' argument, and handle it. Remove process
14618 from processes table.
14619 (linux_join): Add `pid' argument. Handle it.
14620 (linux_thread_alive): Change unsighed long argument to ptid_t.
14621 Consider dead lwps as not being alive.
14622 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
14623 threads we're not interested in.
14624 (same_lwp, find_lwp_pid): New.
14625 (linux_wait_for_lwp): Change `pid' argument's type from int to
14626 ptid_t. Adjust.
14627 (linux_wait_for_event): Rename to ...
14628 (linux_wait_for_event_1): ... this. Change `pid' argument's type
14629 from int to ptid_t. Adjust.
14630 (linux_wait_for_event): New.
14631 (linux_wait_1): Add `ptid' argument. Change return type to
14632 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
14633 that exit from the process table.
14634 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
14635 Adjust.
14636 (mark_lwp_dead): New.
14637 (wait_for_sigstop): Adjust to use ptids. If a process exits while
14638 stopping all threads, mark its main lwp as dead.
14639 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
14640 ptids.
14641 (fetch_register, usr_store_inferior_registers)
14642 (regsets_fetch_inferior_registers)
14643 (regsets_store_inferior_registers, linux_read_memory)
14644 (linux_write_memory): Inline `inferior_pid'.
14645 (linux_look_up_symbols): Adjust to use per-process
14646 `thread_db_active'.
14647 (linux_request_interrupt): Adjust to use ptids.
14648 (linux_read_auxv): Inline `inferior_pid'.
14649 (initialize_low): Don't reference thread_db_active.
14650 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
14651 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
14652 (ps_getpid): Return the pid of the current inferior.
14653 * thread-db.c (proc_handle, thread_agent): Delete.
14654 (thread_db_create_event, thread_db_enable_reporting): Adjust to
14655 per-process data.
14656 (find_one_thread): Change argument type to ptid_t. Adjust to
14657 per-process data.
14658 (maybe_attach_thread): Adjust to per-process data and ptids.
14659 (thread_db_find_new_threads): Ditto.
14660 (thread_db_init): Ditto.
14661 * spu-low.c (spu_create_inferior, spu_attach): Add process to
14662 processes table. Adjust to use ptids.
14663 (spu_kill, spu_detach): Adjust interface. Remove process from
14664 processes table.
14665 (spu_join, spu_thread_alive): Adjust interface.
14666 (spu_wait): Adjust interface. Remove process from processes
14667 table. Adjust to use ptids.
14668 * win32-low.c (current_inferior_tid): Delete.
14669 (current_inferior_ptid): New.
14670 (debug_event_ptid): New.
14671 (thread_rec): Take a ptid. Adjust.
14672 (child_add_thread): Add `pid' argument. Adjust to use ptids.
14673 (child_delete_thread): Ditto.
14674 (do_initial_child_stuff): Add `attached' argument. Add process to
14675 processes table.
14676 (child_fetch_inferior_registers, child_store_inferior_registers):
14677 Adjust.
14678 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
14679 (win32_attach): Pass 1 to do_initial_child_stuff.
14680 (win32_kill): Adjust interface. Remove process from processes
14681 table.
14682 (win32_detach): Ditto.
14683 (win32_join): Adjust interface.
14684 (win32_thread_alive): Take a ptid.
14685 (win32_resume): Adjust to use ptids.
14686 (get_child_debug_event): Ditto.
14687 (win32_wait): Adjust interface. Remove exiting process from
14688 processes table.
14689
14690 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14691
14692 Non-stop mode support.
14693
14694 * server.h (non_stop): Declare.
14695 (gdb_client_data, handler_func): Declare.
14696 (delete_file_handler, add_file_handler, start_event_loop):
14697 Declare.
14698 (handle_serial_event, handle_target_event, push_event)
14699 (putpkt_notif): Declare.
14700 * target.h (enum resume_kind): New.
14701 (struct thread_resume): Replace `step' field by `kind' field.
14702 (TARGET_WNOHANG): Define.
14703 (struct target_ops) <wait>: Add `options' argument.
14704 <supports_non_stop, async, start_non_stop>: New fields.
14705 (target_supports_non_stop, target_async): New.
14706 (start_non_stop): Declare.
14707 (mywait): Add `options' argument.
14708 * target.c (mywait): Add `options' argument. Print child exit
14709 notifications here.
14710 (start_non_stop): New.
14711 * server.c (non_stop, own_buf, mem_buf): New globals.
14712 (struct vstop_notif): New.
14713 (notif_queue): New global.
14714 (queue_stop_reply, push_event, discard_queued_stop_replies)
14715 (send_next_stop_reply): New.
14716 (start_inferior): Adjust to use resume_kind. Adjust to mywait
14717 interface changes.
14718 (attach_inferior): In non-stop mode, don't wait for the target
14719 here.
14720 (handle_general_set): Handle QNonStop.
14721 (handle_query): When handling qC, return the current general
14722 thread, instead of the first thread of the list.
14723 (handle_query): If the backend supports non-stop mode, include
14724 QNonStop+ in the qSupported query response.
14725 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
14726 and non-stop mode.
14727 (handle_v_attach, handle_v_run): Handle non-stop mode.
14728 (handle_v_stopped): New.
14729 (handle_v_requests): Report support for vCont;t. Handle vStopped.
14730 (myresume): Adjust to use resume_kind. Handle non-stop.
14731 (queue_stop_reply_callback): New.
14732 (handle_status): Handle non-stop mode.
14733 (main): Clear non_stop flag on reconnection. Use the event-loop.
14734 Refactor serial protocol handling from here ...
14735 (process_serial_event): ... to this new function. When GDB
14736 selects any thread, select one here. In non-stop mode, wait until
14737 GDB acks all pending events before exiting.
14738 (handle_serial_event, handle_target_event): New.
14739 * remote-utils.c (remote_open): Install remote_desc in the event
14740 loop.
14741 (remote_close): Remove remote_desc from the event loop.
14742 (putpkt_binary): Rename to...
14743 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
14744 (putpkt_binary): New as wrapper around putpkt_binary_1.
14745 (putpkt_notif): New.
14746 (prepare_resume_reply): In non-stop mode, don't change the
14747 general_thread.
14748 * event-loop.c: New.
14749 * Makefile.in (OBJ): Add event-loop.o.
14750 (event-loop.o): New rule.
14751
14752 * linux-low.h (pid_of): Moved here.
14753 (lwpid_of): New.
14754 (get_lwp_thread): Use lwpid_of.
14755 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
14756 * linux-low.c (pid_of): Delete.
14757 (inferior_pid): Use lwpid_of.
14758 (linux_event_pipe): New.
14759 (target_is_async_p): New.
14760 (delete_lwp): New.
14761 (handle_extended_wait): Use lwpid_of.
14762 (add_lwp): Don't set lwpid field.
14763 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
14764 (linux_kill_one_lwp): If killing a running lwp, stop it first.
14765 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
14766 (linux_detach_one_lwp): If detaching from a running lwp, stop it
14767 first. Adjust to linux_wait_for_event interface changes. Use
14768 lwpid_of.
14769 (linux_detach): Don't delete the main lwp here.
14770 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
14771 (status_pending_p): Don't consider explicitly suspended lwps.
14772 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
14773 pointer. Add OPTIONS argument. Change return type to int. Use
14774 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
14775 (linux_wait_for_event): Take an integer pid instead of a lwp_info
14776 pointer. Add status pointer argument. Return a pid instead of a
14777 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
14778 changes. In non-stop mode, don't switch to a random thread.
14779 (linux_wait): Rename to...
14780 (linux_wait_1): ... this. Add target_options argument, and handle
14781 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
14782 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
14783 clean exit and signal exit code. Don't stop all threads in
14784 non-stop mode. In all-stop mode, only stop all threads when
14785 reporting a stop to GDB. Handle explicit thread stop requests.
14786 (async_file_flush, async_file_mark): New.
14787 (linux_wait): New.
14788 (send_sigstop): Use lwpid_of.
14789 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
14790 interface changes. In non-stop mode, don't switch to a random
14791 thread.
14792 (linux_resume_one_lwp): Use lwpid_of.
14793 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
14794 (linux_resume_one_thread): ... this. Handle resume_stop. In
14795 non-stop mode, don't look for pending flag in all threads.
14796 (resume_status_pending_p): Don't consider explicitly suspended
14797 threads.
14798 (my_waitpid): Reimplement. Emulate __WALL.
14799 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
14800 Use lwpid_of.
14801 (sigchld_handler, linux_supports_non_stop, linux_async)
14802 (linux_start_non_stop): New.
14803 (linux_target_ops): Register linux_supports_non_stop, linux_async
14804 and linux_start_non_stop.
14805 (initialize_low): Install SIGCHLD handler.
14806 * thread-db.c (thread_db_create_event, find_one_thread)
14807 (thread_db_get_tls_address): Use lwpid_of.
14808 * win32-low.c (win32_detach): Adjust to use resume_kind.
14809 (win32_wait): Add `options' argument.
14810 * spu-low.c (spu_resume): Adjust to use resume_kind.
14811 (spu_wait): Add `options' argument.
14812
14813 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14814
14815 Decouple target code from remote protocol.
14816
14817 * target.h (enum target_waitkind): New.
14818 (struct target_waitstatus): New.
14819 (struct target_ops) <wait>: Return an unsigned long. Take a
14820 target_waitstatus pointer instead of a char pointer.
14821 (mywait): Likewise.
14822 * target.c (mywait): Change prototype to return an unsigned long.
14823 Take a target_waitstatus pointer instead of a char pointer. Adjust.
14824 * server.h (thread_from_wait, old_thread_from_wait): Delete
14825 declarations.
14826 (prepare_resume_reply): Change prototype to take a
14827 target_waitstatus.
14828 * server.c (thread_from_wait, old_thread_from_wait): Delete.
14829 (last_status, last_ptid): New.
14830 (start_inferior): Remove "statusptr" argument. Adjust. Return a
14831 pid instead of a signal.
14832 (attach_inferior): Remove "status" and "signal" parameters.
14833 Adjust.
14834 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
14835 not as an address.
14836 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
14837 (handle_v_requests, myresume): Remove "status" and "signal"
14838 parameters. Adjust.
14839 (handle_status): New.
14840 (main): Delete local `status'. Adjust.
14841 * remote-utils.c: Include target.h.
14842 (prepare_resume_reply): Change prototype to take a
14843 target_waitstatus. Adjust.
14844
14845 * linux-low.c (linux_wait): Adjust to new target_ops->wait
14846 interface.
14847 * spu-low.c (spu_wait): Adjust.
14848 * win32-low.c (enum target_waitkind, struct target_waitstatus):
14849 Delete.
14850 (win32_wait): Adjust.
14851
14852 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14853
14854 * target.h (struct thread_resume): Delete leave_stopped member.
14855 (struct target_ops): Add a `n' argument to the `resume' callback.
14856 * server.c (start_inferior): Adjust.
14857 (handle_v_cont, myresume): Adjust.
14858 * linux-low.c (check_removed_breakpoint): Adjust to resume
14859 interface change, and to removed leave_stopped field.
14860 (resume_ptr): Delete.
14861 (struct thread_resume_array): New.
14862 (linux_set_resume_request): Add new `arg' parameter. Adjust to
14863 resume interface change.
14864 (linux_continue_one_thread, linux_queue_one_thread)
14865 (resume_status_pending_p): Check if the resume field is NULL
14866 instead of checking the leave_stopped member.
14867 (linux_resume): Adjust to the target resume interface change.
14868 * spu-low.c (spu_resume): Adjust to the target resume interface
14869 change.
14870 * win32-low.c (win32_detach, win32_resume): Ditto.
14871
14872 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14873
14874 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
14875 flag.
14876 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
14877 pending.
14878 (linux_continue_one_thread): Only preserve the stepping flag if
14879 there's a pending breakpoint.
14880
14881 2009-03-31 Pedro Alves <pedro@codesourcery.com>
14882
14883 * server.c (main): After the inferior having exited, call
14884 remote_close before exiting gdbserver.
14885
14886 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
14887
14888 Fix size of FPSCR in Power 7 processors.
14889 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
14890 (PPC_FEATURE_HAS_DFP): New #define.
14891 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
14892 size of the FPSCR.
14893
14894 2009-03-23 Pedro Alves <pedro@codesourcery.com>
14895
14896 * server.c (handle_query) Whitespace and formatting.
14897
14898 2009-03-22 Pedro Alves <pedro@codesourcery.com>
14899
14900 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
14901 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
14902 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
14903 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
14904 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
14905 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
14906 Makefile.in, configure.ac: Fix whitespace throughout.
14907 * configure: Regenerate.
14908
14909 2009-03-22 Pedro Alves <pedro@codesourcery.com>
14910
14911 * inferiors.c (find_inferior): Make it safe for the callback
14912 function to delete the currently iterated inferior.
14913
14914 2009-03-22 Pedro Alves <pedro@codesourcery.com>
14915
14916 * Makefile.in (linuw_low_h): Move higher.
14917 (thread-db.o): Depend on $(linux_low_h).
14918
14919 2009-03-17 Pedro Alves <pedro@codesourcery.com>
14920
14921 Rename "process" to "lwp" throughout.
14922
14923 * linux-low.c (all_processes): Rename to...
14924 (all_lwps): ... this.
14925 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
14926 (add_process): Rename to ...
14927 (add_lwp): ... this. Adjust.
14928 (linux_create_inferior): Adjust.
14929 (linux_attach_lwp): Adjust.
14930 (linux_attach): Adjust.
14931 (linux_kill_one_process): Rename to ...
14932 (linux_kill_one_lwp): ... this. Adjust.
14933 (linux_kill): Adjust.
14934 (linux_detach_one_process): Rename to ...
14935 (linux_detach_one_lwp): ... this. Adjust.
14936 (linux_detach): Adjust.
14937 (check_removed_breakpoint): Adjust.
14938 (status_pending_p): Adjust.
14939 (linux_wait_for_process): Rename to ...
14940 (linux_wait_for_lwp): ... this. Adjust.
14941 (linux_wait_for_event): Adjust.
14942 (send_sigstop): Adjust.
14943 (wait_for_sigstop): Adjust.
14944 (stop_all_processes): Rename to ...
14945 (stop_all_lwps): ... this.
14946 (linux_resume_one_process): Rename to ...
14947 (linux_resume_one_lwp): ... this. Adjust.
14948 (linux_set_resume_request, linux_continue_one_thread)
14949 (linux_queue_one_thread, resume_status_pending_p)
14950 (usr_store_inferior_registers, regsets_store_inferior_registers)
14951 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
14952 Adjust.
14953 * linux-low.h (get_process): Rename to ...
14954 (get_lwp): ... this. Adjust.
14955 (get_thread_process): Rename to ...
14956 (get_thread_lwp): ... this. Adjust.
14957 (get_process_thread): Rename to ...
14958 (get_lwp_thread): ... this. Adjust.
14959 (struct process_info): Rename to ...
14960 (struct lwp_info): ... this.
14961 (all_processes): Rename to ...
14962 (all_lwps): ... this.
14963 * proc-service.c (ps_lgetregs): Adjust.
14964 * thread-db.c (thread_db_create_event, find_one_thread)
14965 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
14966
14967 2009-03-14 Pedro Alves <pedro@codesourcery.com>
14968
14969 * server.c (handle_query): Handle "qAttached".
14970
14971 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
14972
14973 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
14974 GPLv3, update license URL.
14975
14976 2009-03-01 Doug Evans <dje@google.com>
14977
14978 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
14979 (server_h): Add gdb_signals.h.
14980 (signals.o): Update.
14981 * server.h (target_signal_from_host,target_signal_to_host_p)
14982 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
14983
14984 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
14985
14986 * remote-utils.c (getpkt): Also generate remote-debug
14987 information if noack_mode is set.
14988
14989 2009-02-06 Pedro Alves <pedro@codesourcery.com>
14990
14991 * server.c (handle_query): Report qXfer:siginfo:read and
14992 qXfer:siginfo:write as supported and handle them.
14993 * target.h (struct target_ops) <qxfer_siginfo>: New field.
14994 * linux-low.c (linux_xfer_siginfo): New.
14995 (linux_target_ops): Set it.
14996
14997 2009-01-26 Pedro Alves <pedro@codesourcery.com>
14998
14999 * server.c (gdbserver_usage): Mention --remote-debug.
15000 (main): Accept '--remote-debug' switch.
15001
15002 2009-01-18 Doug Evans <dje@google.com>
15003
15004 * regcache.c (new_register_cache): No need to check result of xcalloc.
15005 * server.c (handle_search_memory): Back out calls to xmalloc,
15006 result is checked and error is returned to user upon failure.
15007 (handle_query): Ditto. Add more checks for result of malloc.
15008 (handle_v_cont): Check result of malloc, report error back to
15009 user upon failure.
15010 (handle_v_run): Ditto. Call freeargv.
15011 * server.h (freeargv): Declare.
15012 * utils.c (freeargv): New fn.
15013
15014 2009-01-15 Doug Evans <dje@google.com>
15015
15016 * gdbreplay.c (perror_with_name): Make arg const char *.
15017 * server.h (target_signal_to_name): Make return type const char *.
15018 * thread-db.c (thread_db_err_str): Make return type const char *.
15019 * utils.c (perror_with_name): Make arg const char *.
15020
15021 2009-01-14 Pedro Alves <pedro@codesourcery.com>
15022
15023 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
15024 when handling a EXIT_PROCESS_DEBUG_EVENT.
15025
15026 2009-01-06 Joel Brobecker <brobecker@adacore.com>
15027
15028 * gdbreplay.c (gdbreplay_version): Update copyright year.
15029 * server.c (gdbserver_version): Likewise.
15030
15031 2009-01-05 Doug Evans <dje@google.com>
15032
15033 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
15034 (handle_extended_wait): Improve comment.
15035
15036 2008-12-13 Doug Evans <dje@google.com>
15037
15038 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
15039 * server.h (ATTR_MALLOC): New macro.
15040 (xmalloc,xcalloc,xstrdup): Declare.
15041 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
15042 * inferiors.c: Ditto.
15043 * linux-low.c: Ditto.
15044 * mem-break.c: Ditto.
15045 * regcache.c: Ditto.
15046 * remote-utils.c: Ditto.
15047 * server.c: Ditto.
15048 * target.c: Ditto.
15049 * win32-low.c: Ditto.
15050
15051 2008-12-12 Doug Evans <dje@google.com>
15052
15053 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
15054 in debugging printf.
15055
15056 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
15057
15058 2008-12-09 Doug Evans <dje@google.com>
15059
15060 * linux-low.h (struct process_info): Delete member tid, unused.
15061 * thread-db.c (find_one_thread): Update.
15062 (maybe_attach_thread): Update.
15063
15064 2008-12-02 Pedro Alves <pedro@codesourcery.com>
15065
15066 * target.h (struct target_ops): Add qxfer_osdata member.
15067 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
15068 and dirent.h.
15069 (linux_qxfer_osdata): New functions.
15070 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
15071 callback.
15072 * server.c (handle_query): Handle "qXfer:osdata:read:".
15073 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
15074 (buffer_xml_printf): New functions.
15075 * server.h (struct buffer): New.
15076 (buffer_grow_str, buffer_grow_str0): New macros.
15077 (buffer_grow, buffer_free, buffer_init, buffer_finish)
15078 (buffer_xml_printf): Declare.
15079
15080 2008-11-24 Doug Evans <dje@google.com>
15081
15082 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
15083
15084 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
15085
15086 * server.c (handle_v_run): Always use the supplied argument list.
15087
15088 2008-11-19 Bob Wilson <bob.wilson@acm.org>
15089
15090 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
15091 (xtensa_regmap_table): Add entry for scompare1.
15092
15093 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
15094
15095 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
15096 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
15097 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
15098 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
15099 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
15100 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
15101 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
15102 XML target descriptions.
15103 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
15104 when inferior is running on an ISA 2.05 or later processor. Add
15105 special case to return offset for full 64-bit slot of FPSCR when
15106 in 32-bits.
15107
15108 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
15109
15110 * Makefile.in (SFILES, clean): Added sparc64 files.
15111 (reg-sparc64.o, reg-sparc64.c): New.
15112 * configure.srv (sparc*-*-linux*): New configuration.
15113 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
15114 syscall arguments for SPARC.
15115 (regsets_store_inferior_registers): Likewise.
15116 * linux-sparc-low.c: New file.
15117
15118 2008-10-21 Doug Evans <dje@google.com>
15119
15120 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
15121 (READLINE_DIR,READLINE_DEP): Delete.
15122 (INTERNAL_CFLAGS): Update.
15123 (LINTFLAGS): Update.
15124
15125 2008-10-10 Pedro Alves <pedro@codesourcery.com>
15126
15127 * server.c (handle_v_run): If GDB didn't specify an argv, use the
15128 whole argv from the last run, not just argv[0].
15129
15130 2008-09-08 Pedro Alves <pedro@codesourcery.com>
15131
15132 * regcache.c (new_register_cache): Return NULL if the register
15133 cache size isn't known yet.
15134 (free_register_cache): Avoid dereferencing a NULL regcache.
15135
15136 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
15137
15138 * configure.srv: Merge MIPS and MIPS64.
15139
15140 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
15141
15142 * Makefile.in (uninstall): Apply $(EXEEXT) too.
15143
15144 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
15145
15146 * Makefile.in: Add required vsx dependencies.
15147
15148 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
15149 Declare init_registers_powerpc_vsx32l.
15150 Declare init_registers_powerpc_vsx64l.
15151 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
15152 (ppc_arch_setup): Check for VSX in hwcap.
15153 (ppc_fill_vsxregset): New function.
15154 (ppc_store_vsxregset): New function.
15155 Add new VSX entry in regset_info target_regsets.
15156
15157 * configure.srv: Add new VSX dependencies.
15158
15159 2008-08-12 Pedro Alves <pedro@codesourcery.com>
15160
15161 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
15162 (remote_open): Set or clear transport_is_reliable.
15163 (putpkt_binary): Don't expect acks in noack mode.
15164 (getpkt): Don't send ack/nac in noack mode.
15165 * server.c (handle_general_set): Handle QStartNoAckMode.
15166 (handle_query): If connected by tcp pass QStartNoAckMode+ in
15167 qSupported.
15168 (main): Reset noack_mode on every connection.
15169 * server.h (noack_mode): Declare.
15170
15171 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15172
15173 * Makefile.in (GDBREPLAY_OBS): New variable.
15174 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
15175
15176 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
15177 Daniel Jacobowitz <dan@codesourcery.com>
15178
15179 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
15180 (usr_store_inferior_registers): Likewise.
15181 (regsets_store_inferior_registers): Likewise.
15182
15183 2008-07-31 Rolf Jansen <rj@surtec.com>
15184 Pedro Alves <pedro@codesourcery.com>
15185
15186 * configure.ac: Check for memmem declaration.
15187 * server.c [HAVE_MALLOC_H]: Include malloc.h.
15188 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
15189 (disable_packet_qfThreadInfo): Unconditionally compile.
15190 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
15191 * configure, config.in: Regenerate.
15192
15193 2008-07-28 Doug Kwan <dougkwan@google.com>
15194
15195 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
15196 (linux_write_memory): Remove declaration of errno.
15197
15198 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
15199
15200 * linux-low.c (handle_extended_wait): Do not use "status"
15201 variable uninitialized.
15202
15203 2008-07-07 Pedro Alves <pedro@codesourcery.com>
15204
15205 * server.c (handle_v_attach): Inhibit reporting dll changes.
15206
15207 2008-06-27 Pedro Alves <pedro@codesourcery.com>
15208
15209 * remote-utils.c (prepare_resume_reply): If requested, don't
15210 output "thread:TID" in the T stop reply.
15211
15212 * server.c (disable_packet_vCont, disable_packet_Tthread)
15213 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
15214 (handle_query): If requested, disable support for qC, qfThreadInfo
15215 and qsThreadInfo.
15216 (handle_v_requests): If requested, disable support for vCont.
15217 (gdbserver_show_disableable): New.
15218 (main): Handle --disable-packet and --disable-packet=LIST.
15219
15220 * server.h (disable_packet_vCont, disable_packet_Tthread)
15221 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
15222
15223 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
15224
15225 * server.c (gdbserver_usage): Mention --version.
15226
15227 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
15228
15229 * Makefile.in (gdbreplay.o): New rule.
15230
15231 2008-06-06 Joseph Myers <joseph@codesourcery.com>
15232
15233 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
15234 message, not gdbserver.
15235
15236 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
15237 Nathan Sidwell <nathan@codesourcery.com>
15238 Joseph Myers <joseph@codesourcery.com>
15239
15240 * acinclude.m4: Include ../../config/acx.m4.
15241 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
15242 * configure, config.in: Regenerate.
15243 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
15244 * server.c (gdbserver_version): Print PKGVERSION.
15245 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
15246 (main): Adjust gdbserver_usage calls.
15247 * gdbreplay.c (version, host_name): Add declarations.
15248 (gdbreplay_version, gdbreplay_usage): New.
15249 (main): Accept --version and --help options.
15250
15251 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
15252
15253 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
15254 (arm_breakpoint_at): Handle Thumb.
15255 (the_low_target): Add comment.
15256
15257 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
15258
15259 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
15260
15261 2008-05-09 Doug Evans <dje@google.com>
15262
15263 * server.h (decode_search_memory_packet): Declare.
15264 * remote-utils.c (decode_search_memory_packet): New fn.
15265 * server.c (handle_search_memory_1): New fn.
15266 (handle_search_memory): New fn.
15267 (handle_query): Process qSearch:memory packets.
15268
15269 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
15270
15271 * regcache.c (registers_length): Remove.
15272 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
15273 full register packet.
15274 * regcache.h (registers_length): Remove prototype.
15275 * server.h (PBUFSIZ): Define to 16384.
15276
15277 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
15278
15279 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
15280 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
15281 powerpc-64l.o, and powerpc-altivec64l.o.
15282 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
15283 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
15284 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
15285 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
15286 rs6000/power-linux.xml, and rs6000/power64-linux.xml
15287 to srv_xmlfiles.
15288
15289 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
15290 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
15291 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
15292 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
15293 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
15294 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
15295 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
15296 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
15297 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
15298 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
15299 (clean): Update.
15300
15301 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
15302 (init_registers_powerpc_32l): ... this new prototype.
15303 (init_registers_powerpc_32): Remove, replace by ...
15304 (init_registers_powerpc_altivec32l): ... this new prototype.
15305 (init_registers_powerpc_e500): Remove, replace by ...
15306 (init_registers_powerpc_e500l): ... this new prototype.
15307 (init_registers_ppc64): Remove, replace by ...
15308 (init_registers_powerpc_64l): ... this new prototype.
15309 (init_registers_powerpc_64): Remove, replace by ...
15310 (init_registers_powerpc_altivec64l): ... this new prototype.
15311 (ppc_num_regs): Set to 73.
15312 (PT_ORIG_R3, PT_TRAP): Define if necessary.
15313 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
15314 (ppc_cannot_store_register): Handle orig_r3 and trap.
15315 (ppc_arch_setup): Update init_registers_... calls.
15316 (ppc_fill_gregset): Handle orig_r3 and trap.
15317
15318 * inferiors.c (clear_inferiors): Reset current_inferior.
15319
15320 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
15321
15322 * acinclude.m4: Add override.m4.
15323 * configure: Regenerate.
15324
15325 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
15326
15327 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
15328 initial call to init_register_ppc64.
15329
15330 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
15331
15332 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
15333 single powerpc*-*-linux* case.
15334 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
15335
15336 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
15337
15338 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
15339 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
15340 from reg_xmlfiles.
15341 * linux-ppc-low.c: Include <elf.h>.
15342 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
15343 (ppc_hwcap): New global variable.
15344 (ppc_regmap): Remove __SPE__ #ifdef sections.
15345 (ppc_regmap_e500): New global variable.
15346 (ppc_cannot_store_register): Update __SPE__ special case.
15347 (ppc_get_hwcap): New function.
15348 (ppc_arch_setup): Use it to determine whether inferior supports
15349 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
15350 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
15351 Do not access registers if target does not support AltiVec.
15352 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
15353 Do not access registers if target does not support SPE.
15354 (target_regsets): Unconditionally include AltiVec and SPE regsets.
15355
15356 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
15357
15358 * linux-low.c (disabled_regsets, num_regsets): New.
15359 (use_regsets_p): Delete.
15360 (linux_wait_for_process): Clear disabled_regsets.
15361 (regsets_fetch_inferior_registers): Check and set it.
15362 (regsets_store_inferior_registers): Likewise.
15363 (linux_fetch_registers, linux_store_registers): Do not use
15364 use_regsets_p.
15365 (initialize_low): Allocate disabled_regsets.
15366
15367 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
15368
15369 * Makefile.in (LIBOBJS): New.
15370 (OBS): Use LIBOBJS.
15371 (memmem.o): New rule.
15372 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
15373 * configure: Regenerated.
15374
15375 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
15376
15377 * server.c (handle_query): Never return "unsupported" for
15378 qXfer:features:read queries.
15379
15380 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
15381
15382 * server.c (get_features_xml): Fix inverted condition.
15383 (handle_query): Always support qXfer:feature:read.
15384
15385 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
15386
15387 * server.c (wrapper_argv): New.
15388 (start_inferior): Handle wrapper_argv. If set, expect an extra
15389 trap.
15390 (gdbserver_usage): Document --wrapper.
15391 (main): Parse --wrapper.
15392
15393 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15394
15395 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
15396 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
15397 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
15398 (ppc_set_pc): Likewise.
15399 (ppc_arch_setup): New function.
15400 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
15401 of collect_register.
15402 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
15403
15404 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15405
15406 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
15407 instead of linux-ppc64-low.o.
15408 * linux-ppc64-low.c: Remove file.
15409 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
15410 (linux-ppc64-low.o): Remove rule.
15411
15412 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
15413 (init_registers_powerpc_64): Likewise.
15414 (ppc_regmap): Conditionally define depending on __powerpc64__.
15415 (ppc_cannot_store_register): Do not special-case "fpscr" when
15416 compiled on __powerpc64__.
15417 (ppc_collect_ptrace_register): New function.
15418 (ppc_supply_ptrace_register): New function.
15419 (ppc_breakpoint): Change type to "unsigned int".
15420 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
15421 (the_low_target): Conditionally provide initializers for the
15422 arch_setup member depending on __powerpc64__. Install
15423 collect_ptrace_register and supply_ptrace_register members.
15424
15425 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15426
15427 * regcache.h (gdbserver_xmltarget): Add extern declaration.
15428 * server.c (gdbserver_xmltarget): Define.
15429 (get_features_xml): Use it to replace "target.xml" and arch_string.
15430
15431 * configure.srv: Remove srv_xmltarget. Add XML files that were
15432 mentioned there to srv_xmlfiles instead. Remove conditional tests
15433 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
15434 srv_xmlfiles and srv_regobj to include all possible choices.
15435 * configure.ac (srv_xmltarget): Remove.
15436 (srv_xmlfiles): Do not add "target.xml".
15437 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
15438 checks for supplementary target information.
15439 * configure: Regenerate.
15440 * Makefile.in (XML_TARGET): Remove.
15441 (target.xml): Remove rule.
15442 (clean): Do not clean up target.xml.
15443 (.PRECIOUS): Do not mention target.xml.
15444
15445 * target.h (struct target_ops): Remove arch_string member.
15446 * linux-low.c (linux_arch_string): Remove.
15447 (linux_target_ops): Remove arch_string initializer.
15448 * linux-low.h (struct linux_target_ops): Remove arch_string member.
15449 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
15450 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
15451 * spu-low.c (spu_arch_string): Remove.
15452 (spu_target_ops): Remove arch_string initializer.
15453 * win32-low.c (win32_arch_string): Remove.
15454 (win32_target_ops): Remove arch_string initializer.
15455 * win32-low.h (struct win32_target_ops): Remove arch_string member.
15456 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
15457 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
15458
15459 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15460
15461 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
15462 by collect_ptrace_register and supply_ptrace_register hooks.
15463 * linux-low.c (fetch_register): Use supply_ptrace_register callback
15464 instead of checking for the_low_target.left_pad_xfer.
15465 (usr_store_inferior_registers): Use collect_ptrace_register callback
15466 instead of checking for the_low_target.left_pad_xfer.
15467
15468 * linux-s390-low.c (s390_collect_ptrace_register): New function.
15469 (s390_supply_ptrace_register): Likewise.
15470 (s390_fill_gregset): Call s390_collect_ptrace_register.
15471 (the_low_target): Update.
15472
15473 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
15474 (ppc_supply_ptrace_register): Likewise.
15475 (the_low_target): Update.
15476
15477 * linux-i386-low.c (the_low_target): Update.
15478 * linux-x86-64-low.c (the_low_target): Update.
15479
15480 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15481
15482 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
15483 reg-s390.o and reg-s390x.o.
15484
15485 * linux-low.c (new_inferior): New global variable.
15486 (linux_create_inferior, linux_attach): Set it.
15487 (linux_wait_for_process): Call the_low_target.arch_setup after the
15488 target has stopped for the first time.
15489 (initialize_low): Do not call the_low_target.arch_setup.
15490
15491 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
15492 (s390_set_pc): Likewise.
15493 (s390_arch_setup): New function.
15494 (the_low_target): Use s390_arch_setup as arch_setup routine.
15495
15496 * regcache.c (realloc_register_cache): New function.
15497 (set_register_cache): Call it for each existing regcache.
15498
15499 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15500
15501 * server.h (init_registers): Remove prototype.
15502
15503 * linux-low.h (struct linux_target_ops): Add arch_setup field.
15504 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
15505 instead of init_registers ().
15506 * linux-arm-low.c (init_registers_arm): Add prototype.
15507 (init_registers_arm_with_iwmmxt): Likewise.
15508 (the_low_target): Add initializer for arch_setup field.
15509 * linux-cris-low.c (init_registers_cris): Add prototype.
15510 (the_low_target): Add initializer for arch_setup field.
15511 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
15512 (the_low_target): Add initializer for arch_setup field.
15513 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
15514 (the_low_target): Add initializer for arch_setup field.
15515 * linux-ia64-low.c (init_registers_ia64): Add prototype.
15516 (the_low_target): Add initializer for arch_setup field.
15517 * linux-m32r-low.c (init_registers_m32r): Add prototype.
15518 (the_low_target): Add initializer for arch_setup field.
15519 * linux-m68k-low.c (init_registers_m68k): Add prototype.
15520 (the_low_target): Add initializer for arch_setup field.
15521 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
15522 (init_registers_mips64_linux): Likewise.
15523 (the_low_target): Add initializer for arch_setup field.
15524 * linux-ppc-low.c (init_registers_ppc): Add prototype.
15525 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
15526 (the_low_target): Add initializer for arch_setup field.
15527 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
15528 (init_registers_powerpc_64): Likewise.
15529 (the_low_target): Add initializer for arch_setup field.
15530 * linux-s390-low.c (init_registers_s390): Add prototype.
15531 (init_registers_s390x): Likewise.
15532 (the_low_target): Add initializer for arch_setup field.
15533 * linux-sh-low.c (init_registers_sh): Add prototype.
15534 (the_low_target): Add initializer for arch_setup field.
15535 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
15536 (the_low_target): Add initializer for arch_setup field.
15537 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
15538 (the_low_target): Add initializer for arch_setup field.
15539
15540 * win32-low.h (struct win32_target_ops): Add arch_setup field.
15541 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
15542 instead of init_registers ().
15543 * win32-arm-low.c (init_registers_arm): Add prototype.
15544 (the_low_target): Add initializer for arch_setup field.
15545 * win32-i386-low.c (init_registers_i386): Add prototype.
15546 (the_low_target): Add initializer for arch_setup field.
15547
15548 * spu-low.c (init_registers_spu): Add prototype.
15549 (initialize_low): Call initialie_registers_spu () instead of
15550 initialize_registers ().
15551
15552 2008-02-19 Pedro Alves <pedro@codesourcery.com>
15553
15554 * server.c (handle_v_requests): When handling the vRun and vAttach
15555 packets, if already debugging a process, don't kill it. Return an
15556 error instead.
15557
15558 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
15559
15560 * server.c (handle_query): Correct length check.
15561
15562 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
15563
15564 * win32-low.c (do_initial_child_stuff): Add process handle
15565 parameter. Set current_process_handle and current_process_id from the
15566 parameters. Clear globals.
15567 (win32_create_inferior): Don't set current_process_handle and
15568 current_process_id here. Instead pass them on the call to
15569 do_initial_child_stuff.
15570 (win32_attach): Likewise.
15571 (win32_clear_inferiors): New.
15572 (win32_kill): Don't close the current process handle or the
15573 current thread handle here. Instead call win32_clear_inferiors.
15574 (win32_detach): Don't open a new handle to the process. Call
15575 win32_clear_inferiors.
15576 (win32_join): Don't rely on current_process_handle; open a new
15577 handle using the process id.
15578 (win32_wait): Call win32_clear_inferiors when the inferior process
15579 has exited.
15580
15581 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
15582
15583 * server.c (monitor_show_help): Add "exit".
15584
15585 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
15586
15587 * Makefile.in (SFILES): Add linux-xtensa-low.c.
15588 (clean): Add reg-xtensa.c.
15589 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
15590 * configure.srv (xtensa*-*-linux*) New target.
15591 * linux-xtensa-low.c: New.
15592 * xtensa-xtregs.c: New.
15593
15594 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
15595
15596 * hostio.c: Don't include errno.h.
15597 (errno_to_fileio_errno): Move to hostio-errno.
15598 * hostio.c: (hostio_error): Remove the error parameter. Defer the
15599 error number outputting to the target->hostio_last_error callback.
15600 (hostio_packet_error): Use FILEIO_EINVAL directly.
15601 (handle_open, handle_pread, hostio_error, handle_unlink): Update
15602 calls to hostio_error.
15603 * hostio-errno.c: New.
15604 * server.h (hostio_last_error_from_errno): Declare.
15605 * target.h (target_ops): Add hostio_last_error member.
15606 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
15607 as hostio_last_error handler.
15608 * spu-low.c (spu_target_ops): Likewise.
15609 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
15610 (wince_hostio_last_error): New functions.
15611 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
15612 as hostio_last_error handler.
15613 (win32_target_ops) [!_WIN32_WCE]: Register
15614 hostio_last_error_from_errno as hostio_last_error handler.
15615 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
15616 (hostio-errno.o): New rule.
15617 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
15618 * configure.srv (srv_hostio_err_objs): New variable. Default to
15619 hostio-errno.o.
15620 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
15621 * configure: Regenerate.
15622
15623 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
15624
15625 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
15626 (linux_kill, linux_detach): Clean up the process list.
15627 * remote-utils.c (remote_open): Improve port number parsing.
15628 (putpkt_binary, input_interrupt): Only send interrupts if the target
15629 is running.
15630 * server.c (extended_protocol): Make static.
15631 (attached): Define earlier.
15632 (exit_requested, response_needed, program_argv): New variables.
15633 (target_running): New.
15634 (start_inferior): Clear attached here.
15635 (attach_inferior): Set attached here.
15636 (require_running): Define.
15637 (handle_query): Use require_running and target_running. Implement
15638 "monitor exit".
15639 (handle_v_attach, handle_v_run): New.
15640 (handle_v_requests): Use require_running. Handle vAttach and vRun.
15641 (gdbserver_usage): Update.
15642 (main): Redo argument parsing. Handle --debug and --multi. Handle
15643 --attach along with other options or after the port. Save
15644 program_argv. Support no initial program. Resynchronize
15645 communication with GDB after an error. Handle "monitor exit".
15646 Use require_running and target_running. Always allow the extended
15647 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
15648 restart in extended mode.
15649 * README: Refer to the GDB manual. Update --attach usage.
15650
15651 2007-12-20 Andreas Schwab <schwab@suse.de>
15652
15653 * linux-low.c (STACK_SIZE): Define.
15654 (linux_tracefork_child): Use it. Use __clone2 on ia64.
15655 (linux_test_for_tracefork): Likewise.
15656
15657 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
15658
15659 * linux-low.c (linux_wait_for_event): Update messages. Do not
15660 reinsert auto-delete breakpoints.
15661 * mem-break.c (struct breakpoint): Change return type of handler to
15662 int.
15663 (set_breakpoint_at): Update handler type.
15664 (reinsert_breakpoint_handler): Return 1 instead of calling
15665 delete_breakpoint.
15666 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
15667 setting a new one.
15668 (check_breakpoints): Delete auto-delete breakpoints and return 2.
15669 * mem-break.h (set_breakpoint_at): Update handler type.
15670 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
15671 * win32-low.c (auto_delete_breakpoint): New.
15672 (get_child_debug_event): Use it.
15673
15674 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
15675
15676 * configure.ac: Check for pread and pwrite.
15677 * hostio.c (handle_pread): Fall back to lseek and read.
15678 (handle_pwrite): Fall back to lseek and write.
15679 * config.in, configure: Regenerated.
15680
15681 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
15682
15683 * server.c (myresume): Add own_buf argument.
15684 (main): Update calls.
15685
15686 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
15687
15688 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
15689 * remote-utils.c (remote_open): Do not call disable_async_io.
15690 (block_async_io): Delete.
15691 (unblock_async_io): Make static.
15692 (initialize_async_io): New.
15693 * server.c (handle_v_cont): Handle async I/O here.
15694 (myresume): Likewise. Move other common resume tasks here...
15695 (main): ... from here. Call initialize_async_io. Disable async
15696 I/O before the main loop.
15697 * server.h (initialize_async_io): Declare.
15698 (block_async_io, unblock_async_io): Delete prototypes.
15699 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
15700
15701 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
15702
15703 * remote-utils.c (readchar): Allow binary data in received messages.
15704
15705 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15706
15707 * win32-low.c (attaching): New global.
15708 (win32_create_inferior): Clear the `attaching' global.
15709 (win32_attach): Set the `attaching' global.
15710 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
15711 attaching. Only set a breakpoint at the entry point if not
15712 attaching.
15713
15714 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15715
15716 * server.c (main): Don't report dll events on the initial
15717 connection on attaches.
15718
15719 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15720
15721 * server.c (main): Relax numerical bases supported for the pid of
15722 the --attach command line argument.
15723
15724 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15725
15726 * win32-low.c (win32_attach): Call OpenProcess before
15727 DebugActiveProcess, not after. Add last error output to error
15728 call.
15729
15730 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15731
15732 * win32-low.c (win32_get_thread_context)
15733 (win32_set_thread_context): New functions.
15734 (thread_rec): Use win32_get_thread_context.
15735 (continue_one_thread, win32_resume): Use win32_set_thread_context.
15736 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
15737 field.
15738
15739 2007-12-03 Leo Zayas
15740 Pedro Alves <pedro_alves@portugalmail.pt>
15741
15742 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
15743 global variables.
15744 (child_add_thread): Minor cleanup.
15745 (child_continue): Resume artificially suspended threads before
15746 calling ContinueDebugEvent.
15747 (suspend_one_thread): New.
15748 (fake_breakpoint_event): New.
15749 (get_child_debug_event): Change return type to int. Check here if
15750 gdb sent an interrupt request. If a soft interrupt was requested,
15751 fake a breakpoint event. Return 0 if there is no event to handle,
15752 and 1 otherwise.
15753 (win32_wait): Don't check here if gdb sent an interrupt request.
15754 Ensure there is a valid event to handle.
15755 (win32_request_interrupt): Add soft interruption method as last
15756 resort.
15757
15758 2007-12-03 Leo Zayas
15759 Pedro Alves <pedro_alves@portugalmail.pt>
15760
15761 * win32-low.h (win32_thread_info): Add descriptions to the
15762 structure members. Replace `suspend_count' counter by a
15763 `suspended' flag.
15764 * win32-low.c (thread_rec): Update condition of when to get the
15765 context from the inferior. Rely on ContextFlags being set if it
15766 has already been retrieved. Only suspend the inferior thread if
15767 we haven't already. Warn if that fails.
15768 (continue_one_thread): s/suspend_count/suspended/. Only call
15769 ResumeThread once. Warn if that fails.
15770
15771 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
15772
15773 * win32-low.c (win32_wait): Don't read from the inferior when it
15774 has already exited.
15775
15776 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
15777
15778 * Makefile.in (win32_low_h): New variable.
15779 (win32-low.o): Add dependency on $(win32_low_h).
15780 (win32-arm-low.o, win32-i386-low.o): New rules.
15781
15782 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
15783
15784 * hostio.c: Correct copyright year.
15785
15786 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
15787
15788 * Makefile.in (OBS): Add hostio.o.
15789 (hostio.o): New rule.
15790 * server.h (handle_vFile): Declare.
15791 * hostio.c: New file.
15792 * server.c (handle_v_requests): Take packet_len and new_packet_len
15793 for binary packets. Call handle_vFile.
15794 (main): Update call to handle_v_requests.
15795
15796 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
15797
15798 * linux-low.c: Include <sched.h>.
15799
15800 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
15801
15802 * linux-low.c (linux_tracefork_grandchild): New.
15803 (linux_tracefork_child): Use clone.
15804 (linux_test_for_tracefork): Use clone; allocate and free a stack.
15805
15806 2007-10-31 Joel Brobecker <brobecker@adacore.com>
15807
15808 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
15809
15810 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
15811
15812 * linux-low.c (handle_extended_wait): Handle unexpected signals.
15813
15814 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
15815
15816 * inferiors.c (change_inferior_id): Delete.
15817 (add_pid_to_list, pull_pid_from_list): New.
15818 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
15819 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
15820 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
15821 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
15822 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
15823 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
15824 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
15825 (using_threads): Always set to 1.
15826 (handle_extended_wait): New.
15827 (add_process): Do not set TID.
15828 (linux_create_inferior): Set must_set_ptrace_flags.
15829 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
15830 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
15831 (linux_thread_alive): Rename TID argument to LWPID.
15832 (linux_wait_for_process): Handle unknown processes. Do not use TID.
15833 (linux_wait_for_event): Do not use TID or check using_threads. Update
15834 call to dead_thread_notify. Call handle_extended_wait.
15835 (linux_create_inferior): Use PTRACE_SETOPTIONS.
15836 (send_sigstop): Delete sigstop_sent.
15837 (wait_for_sigstop): Avoid TID.
15838 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
15839 (linux_test_for_tracefork): New.
15840 (linux_lookup_signals): Use thread_db_active and
15841 linux_supports_tracefork_flag.
15842 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
15843 * linux-low.h (get_process_thread): Avoid TID.
15844 (struct process_ifo): Move thread_known and tid to the end. Remove
15845 sigstop_sent.
15846 (linux_attach_lwp, thread_db_init): Update prototypes.
15847 * server.h (change_inferior_id): Delete prototype.
15848 (add_pid_to_list, pull_pid_from_list): New prototypes.
15849 * thread-db.c (thread_db_use_events): New.
15850 (find_first_thread): Rename to...
15851 (find_one_thread): ...this. Update callers and messages. Do not
15852 call fatal. Check thread_db_use_events. Do not call
15853 change_inferior_id or new_thread_notify.
15854 (maybe_attach_thread): Update. Do not call new_thread_notify.
15855 (thread_db_init): Set thread_db_use_events. Check use_events.
15856 * utils.c (fatal, warning): Correct message prefix.
15857
15858 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
15859
15860 * Makefile.in (clean): Remove new files.
15861 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
15862 (powerpc-64.o, powerpc-64.c): New rules.
15863 * configure.srv: Use alternate register sets for powerpc64-*-linux*
15864 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
15865 with SPE.
15866 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
15867 SPE targets.
15868 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
15869 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
15870 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
15871 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
15872 (target_regsets): Add AltiVec and SPE register sets.
15873 * configure.ac: Check for AltiVec and SPE.
15874 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
15875 (ppc_fill_vrregset, ppc_store_vrregset): New.
15876 (target_regsets): Add AltiVec register set.
15877 * configure: Regenerated.
15878
15879 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
15880
15881 * linux-low.c (O_LARGEFILE): Define.
15882 (linux_read_memory): Use /proc/PID/mem.
15883 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
15884 * configure, config.in: Regenerated.
15885
15886 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
15887
15888 * linux-low.c (linux_wait_for_event): Do not pass signals while
15889 single-stepping.
15890
15891 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
15892
15893 * win32-low.c (create_process): New.
15894 (win32_create_inferior): Use create_process instead of
15895 CreateProcess. If create_process failed retry appending an ".exe"
15896 suffix. Store the GetLastError result immediatelly after
15897 create_process calls and use it on the call to error.
15898
15899 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
15900
15901 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
15902
15903 2007-08-23 Joel Brobecker <brobecker@adacore.com>
15904
15905 * configure.ac: Switch license to GPLv3.
15906
15907 2007-08-01 Michael Snyder <msnyder@access-company.com>
15908
15909 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
15910
15911 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
15912
15913 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
15914 typedef.
15915 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
15916 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
15917 CloseToolhelp32Snapshot.
15918 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
15919 CloseToolhelp32Snapshot.
15920
15921 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
15922
15923 * server.c (main): Check for inferior exit before main loop.
15924
15925 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
15926
15927 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
15928 instead of on tmp_desc.
15929
15930 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
15931 Daniel Jacobowitz <dan@codesourcery.com>
15932
15933 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
15934 (add_thread): Minor cleanups.
15935 (clear_inferiors): Move lower in the file. Clear the DLL
15936 list.
15937 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
15938 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
15939 (xml_escape_text): New.
15940 * server.c (handle_query): Handle qXfer:libraries:read. Report it
15941 for qSupported.
15942 (handle_v_cont): Report errors.
15943 (gdbserver_version): Update.
15944 (main): Correct size of own_buf. Do not report initial DLL events.
15945 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
15946 (unloaded_dll, xml_escape_text): New.
15947 * win32-low.c (enum target_waitkind): Update comments.
15948 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
15949 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
15950 (win32_EnumProcessModules, win32_GetModuleInformation)
15951 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
15952 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
15953 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
15954 (win32_Module32First, win32_Module32Next, load_toolhelp)
15955 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
15956 (get_child_debug_event): Handle DLL events.
15957 (win32_wait): Likewise.
15958
15959 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
15960
15961 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
15962 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
15963
15964 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
15965
15966 * win32-low.c (handle_output_debug_string): Ignore event if not
15967 waiting.
15968
15969 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
15970
15971 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
15972
15973 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
15974
15975 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
15976
15977 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
15978
15979 * inferiors.c (change_inferior_id): Add comment.
15980 * linux-low.c (check_removed_breakpoint): Add an early
15981 prototype. Improve debug output.
15982 (linux_attach): Doc update.
15983 (linux_detach_one_process, linux_detach): Clean up before releasing
15984 each process.
15985 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
15986 * linux-low.h (struct process_info): Doc improvement.
15987 * mem-break.c (delete_all_breakpoints): New.
15988 * mem-break.h (delete_all_breakpoints): New prototype.
15989 * thread-db.c (find_first_thread): New.
15990 (thread_db_create_event): Call it instead of
15991 thread_db_find_new_threads. Clean up unused variables.
15992 (maybe_attach_thread): Remove first thread handling.
15993 (thread_db_find_new_threads): Use find_first_thread.
15994 (thread_db_get_tls_address): Likewise.
15995
15996 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
15997
15998 * thread-db.c (thread_db_find_new_threads): Add prototype.
15999 (thread_db_create_event): Check for the main thread before adding
16000 a new thread.
16001 (maybe_attach_thread): Only enable event reporting if TID == 0.
16002 (thread_db_get_tls_address): Check for new threads.
16003
16004 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
16005
16006 * linux-low.c (linux_create_inferior): Try execv before execvp.
16007 * spu-low.c (spu_create_inferior): Likewise.
16008
16009 2007-06-13 Mike Frysinger <vapier@gentoo.org>
16010
16011 * linux-low.c (linux_create_inferior): Change execv to execvp.
16012 * spu-low.c (spu_create_inferior): Likewies.
16013
16014 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
16015
16016 * Makefile.in (clean): Clean new files instead of deleted ones.
16017 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
16018 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
16019 rules.
16020 * configure.srv: Specify XML files and new regformats for MIPS and
16021 MIPS64 GNU/Linux.
16022 * linux-mips-low.c (mips_num_regs): Set to only used registers.
16023 (mips_regmap): Do not fetch $0. Remove unused registers. Add
16024 an entry for the restart register.
16025 (mips_cannot_fetch_register, mips_cannot_store_register)
16026 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
16027 register names to match the XML descriptions.
16028 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
16029 restart register instead of $0.
16030
16031 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
16032 Markus Deuling <deuling@de.ibm.com>
16033
16034 * remote-utils.c (decode_xfer_write): New function.
16035 * server.h (decode_xfer_write): Add prototype.
16036 * server.c (handle_query): Add PACKET_LEN argument. Support
16037 qXfer:spu:read and qXfer:spu:write packets.
16038 (main): Pass packet_len to handle_query.
16039 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
16040 * target.h (target_ops): Add qxfer_spu.
16041
16042 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
16043
16044 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
16045 accessing non-seekable spufs files.
16046
16047 2007-05-16 Markus Deuling <deuling@de.ibm.com>
16048
16049 * server.c (handle_query): Add reply for qC packet.
16050
16051 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16052 Leo Zayas <lerele@champenstudios@com>
16053
16054 * server.h (check_remote_input_interrupt_request): New function.
16055 * remote_utils.c (INVALID_DESCRIPTOR): New define.
16056 (remote_desc): Initialize with INVALID_DESCRIPTOR.
16057 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
16058 (check_remote_input_interrupt_request): New function.
16059 * server.h (check_remote_input_interrupt_request): Declare.
16060 * win32-low.c (winapi_DebugBreakProcess,
16061 winapi_GenerateConsoleCtrlEvent): New typedefs.
16062 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
16063 to 250 ms.
16064 (win32_wait): Check for remote interrupt request
16065 with check_remote_input_interrupt_request.
16066 (win32_request_interrupt): New function.
16067 (win32_target_op): Set request_interrupt to win32_request_interrupt.
16068
16069 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16070
16071 * win32-low.c (debug_registers_changed,
16072 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
16073 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
16074 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
16075 (thread_rec): Get context using the low target.
16076 (child_add_thread): Call thread_added on the low target,
16077 which does the same thing.
16078 (regptr): Delete.
16079 (do_initial_child_stuff): Remove debug registers references.
16080 Set context using the low target. Resume threads after
16081 setting the contexts.
16082 (child_continue): Remove dead variable. Remove debug
16083 registers references.
16084 (child_fetch_inferior_registers): Go through the low target.
16085 (do_child_store_inferior_registers): Remove.
16086 (child_store_inferior_registers): Go through the low target.
16087 (win32_resume): Remove debug registers references.
16088 Set context using the low target.
16089 (handle_exception): Change return type to void. Don't record
16090 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
16091 first chance exception.
16092 (get_child_debug_event): Change return type to void. Remove
16093 goto loop. Always return after waiting for debug event.
16094 (win32_wait): Convert to switch statement. Handle spurious
16095 events.
16096
16097 * win32-i386-low.c (debug_registers_changed,
16098 debug_registers_used): New.
16099 (initial_stuff): Rename to ...
16100 (i386_initial_stuff): ... this. Clear debug registers
16101 state variables.
16102 (store_debug_registers): Delete.
16103 (i386_get_thread_context): New.
16104 (load_debug_registers): Delete.
16105 (i386_set_thread_context): New.
16106 (i386_thread_added): New.
16107 (single_step): Rename to ...
16108 (i386_single_step): ... this.
16109 (do_fetch_inferior_registers): Rename to ...
16110 (i386_fetch_inferior_register): ... this.
16111 (i386_store_inferior_register): New.
16112 (the_low_target): Adapt to new interface.
16113
16114 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
16115 (arm_get_thread_context): New.
16116 (arm_set_thread_context): New.
16117 (regptr): New.
16118 (do_fetch_inferior_registers): Rename to ...
16119 (arm_fetch_inferior_register): ... this.
16120 (arm_store_inferior_register): New.
16121 (arm_wince_breakpoint): Reimplement as unsigned long.
16122 (arm_wince_breakpoint_len): Define.
16123 (the_low_target): Adapt to new interface.
16124
16125 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
16126 load_debug_registers. Add get_thread_context, set_thread_context,
16127 thread_added and store_inferior_register. Rename
16128 fetch_inferior_registers to fetch_inferior_register.
16129 (regptr): Remove declaration.
16130
16131 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16132
16133 * linux-low.c (linux_detach): Change return type to int. Return 0.
16134 * spu-low.c (spu_detach): Likewise.
16135
16136 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16137
16138 * target.h (target_ops): Change return type of detach to int.
16139 Add join.
16140 (join_inferior): New.
16141 * server.c (main): Don't skip detach support on mingw32.
16142 If the inferior doesn't support detaching return error.
16143 Call join_inferior instead of using waitpid.
16144 * linux-low.c (linux_join): New.
16145 (linux_target_op): Add linux_join.
16146 * spu-low.c (spu_join): New.
16147 (spu_target_ops): Add spu_join.
16148 * win32-low.c (win32_detach): Adapt to new interface.
16149 Reopen current_process_handle before detaching. Issue a child
16150 resume before detaching.
16151 (win32_join): New.
16152 (win32_target_op): Add win32_join.
16153
16154 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16155
16156 * win32-low.c (win32-attach): Fix return value.
16157 * target.h (target_ops): Describe ATTACH return values.
16158
16159 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16160
16161 * win32-low.c (GETPROCADDRESS): Define.
16162 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
16163 (winapi_DebugSetProcessKillOnExit): Likewise.
16164 (win32_create_inferior): Force usage of ansi CreateProcessA.
16165 (win32_attach): Use GETPROCADDRESS.
16166 (win32_detach): Likewise.
16167
16168 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16169
16170 * win32-low.c (win32_wait): Don't use WSTOPSIG.
16171
16172 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
16173
16174 * win32-low.c: Commit leftover changes from 2007-03-29.
16175
16176 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
16177
16178 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
16179 fields short instead of int. Add explicit padding.
16180 (i387_cache_to_fsave): Remove unnecessary casts.
16181 (i387_fsave_to_cache): Doc fix.
16182 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
16183
16184 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
16185
16186 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
16187 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
16188
16189 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
16190
16191 * configure.srv (arm*-*-mingw32ce*): Move near the other
16192 arm targets.
16193
16194 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
16195
16196 * configure.ac: Add errno checking.
16197 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
16198 sys/file.h and malloc.h.
16199 (AC_CHECK_DECLS): Add perror.
16200 (srv_mingwce): Handle.
16201 * configure.srv (i[34567]86-*-cygwin*): Add
16202 win32-i386-low.o to srv_tgtobj.
16203 (i[34567]86-*-mingw*): Likewise.
16204 (arm*-*-mingw32ce*): Add case.
16205 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
16206 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
16207 [__MINGW32CE__] (strerror): New function.
16208 [__MINGW32CE__] (errno): Define to GetLastError.
16209 [__MINGW32CE__] (COUNTOF): New macro.
16210 (remote_open): Remove extra close call.
16211 * mem-break.c (delete_breakpoint_at): New function.
16212 * mem-break.h (delete_breakpoint_at): Declare.
16213 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
16214 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
16215 [USE_WIN32API] (read, write): Add char* casts.
16216 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
16217 * server.h: Include wincecompat.h on Windows CE.
16218 [HAVE_ERRNO_H]: Check.
16219 (perror): Declare if not declared.
16220 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
16221 (perror_with_name): Remove errno declaration.
16222 * wincecompat.h: New.
16223 * wincecompat.c: New.
16224 * win32-low.h: New.
16225 * win32-arm-low.c: New.
16226 * win32-i386-low.c: New.
16227 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
16228 (OUTMSG2): Make it safe.
16229 (_T): New macro.
16230 (COUNTOF): New macro.
16231 (NUM_REGS): Get it from the low target.
16232 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
16233 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
16234 (thread_rec): Let low target handle debug registers.
16235 (child_add_thread): Likewise.
16236 (child_init_thread_list): Likewise.
16237 (continue_one_thread): Likewise.
16238 (regptr): New.
16239 (do_child_fetch_inferior_registers): Move to ...
16240 * win32-i386-low.c: ... here, and rename to ...
16241 (do_fetch_inferior_registers): ... this.
16242 * win32-low.c (child_fetch_inferior_registers):
16243 Go through the low target.
16244 (do_child_store_inferior_registers): Use regptr.
16245 (strwinerror): New function.
16246 (win32_create_inferior): Handle Windows CE.
16247 Use strwinerror instead of strerror on Windows error
16248 codes. Add program to the error output.
16249 Don't close the main thread handle on Windows CE.
16250 (win32_attach): Use coredll.dll on Windows CE.
16251 (win32_kill): Close current process and current
16252 thread handles.
16253 (win32_detach): Use coredll.dll on Windows CE.
16254 (win32_resume): Let low target handle debug registers, and
16255 step request.
16256 (handle_exception): Add/Remove initial breakpoint. Avoid
16257 non-existant WSTOPSIG on Windows CE.
16258 (win32_read_inferior_memory): Cast to remove warning.
16259 (win32_arch_string): Go through the low target.
16260 (initialize_low): Call set_breakpoint_data with the low
16261 target's breakpoint.
16262 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
16263 FOP_REGNUM, mappings): Move to ...
16264 * win32-i386-low.c: ... here.
16265 * win32-low.c (win32_thread_info): Move to ...
16266 * win32-low.h: ... here.
16267 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
16268 win32-arm-low.c and wincecompat.c.
16269 (all:): Add $EXEEXT.
16270 (install-only:): Likewise.
16271 (gdbserver:): Likewise.
16272 (gdbreplay:): Likewise.
16273 * config.in: Regenerate.
16274 * configure: Regenerate.
16275
16276 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
16277
16278 * win32-low.c: Rename typedef thread_info to
16279 win32_thread_info throughout.
16280
16281 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
16282
16283 * win32-i386-low.c: Rename to ...
16284 * win32-low.c: ... this.
16285 * configure.srv: Replace win32-i386-low.o with win32-low.o.
16286 * Makefile.in: Likewise.
16287
16288 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
16289
16290 * remote-utils.c (monitor_output): Constify msg parameter.
16291 * server.h (monitor_output): Likewise.
16292 * win32-i386-low.c (handle_output_debug_string): New.
16293 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
16294 handle_output_debug_string.
16295 (get_child_debug_event): Likewise.
16296
16297 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
16298
16299 * server.c (main): Correct strtoul check.
16300
16301 2007-03-27 Jon Ringle <jon@ringle.org>
16302
16303 * linux-low.c: Check __ARCH_HAS_MMU__ also.
16304
16305 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
16306
16307 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
16308
16309 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
16310
16311 * terminal.h: Check HAVE_SGTTY_H.
16312
16313 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
16314
16315 * remote-utils.c (remote_open): Print out the assigned port number.
16316
16317 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
16318
16319 * remote-utils.c (monitor_output): New function.
16320 * server.c (debug_threads): Define here.
16321 (monitor_show_help): New function.
16322 (handle_query): Handle qRcmd.
16323 (main): Do not handle 'd' packet.
16324 * server.h (debug_threads, remote_debug, monitor_output): Declare.
16325 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
16326 of debug_threads.
16327
16328 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16329
16330 * Makefile.in (EXEEXT): New.
16331 (clean): Use $(EXEEXT).
16332
16333 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16334
16335 * target.h (target_ops): Rename send_signal to request_interrupt,
16336 and remove enum target_signal parameter.
16337 * linux-low.c (linux_request_interrupt): Rename from
16338 linux_send_signal, and always send SIGINT.
16339 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
16340 and always send SIGINT.
16341 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
16342 of send_signal.
16343 (input_interrupt): Likewise.
16344
16345 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16346
16347 * server.c (get_features_xml): Check if target implemented
16348 arch_string.
16349 * win32-i386-low.c (win32_arch_string): New.
16350 (win32_target_ops): Add win32_arch_string as arch_string member.
16351
16352 2007-02-22 Markus Deuling <deuling@de.ibm.com>
16353
16354 * spu-low.c (spu_arch_string): New.
16355 (spu_target_ops): Add spu_arch_string.
16356
16357 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
16358
16359 * remote-utils.c: Remove HAVE_TERMINAL_H check.
16360 * configure.ac: Do not check for terminal.h.
16361 * configure, config.in: Regenerated.
16362
16363 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
16364
16365 * Makefile.in (OBS): Add $(XML_BUILTIN).
16366 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
16367 (clean): Update.
16368 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
16369 (arm-with-iwmmxt.c): New.
16370 * config.in, configure: Regenerate.
16371 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
16372 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
16373 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
16374 (arm*-*-linux*): Add iWMMXt and regset support.
16375 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
16376 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
16377 (arm_store_wmmxregset, target_regsets): New.
16378 * server.c (get_features_xml): Take annex argument. Check builtin
16379 XML documents.
16380 (handle_query): Handle multiple annexes.
16381
16382 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
16383
16384 * remote-utils.c [USE_WIN32API] (read, write): Define.
16385 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
16386 write.
16387
16388 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
16389
16390 * linux-i386-low.c (the_low_target): Set arch_string.
16391 * linux-x86-64-low.c (the_low_target): Likewise.
16392 * linux-low.c (linux_arch_string): New.
16393 (linux_target_ops): Add it.
16394 * linux-low.h (struct linux_target_ops): Add arch_string.
16395 * server.c (write_qxfer_response): Use const void * for DATA.
16396 (get_features_xml): New.
16397 (handle_query): Handle qXfer:features:read. Report it for qSupported.
16398 * target.h (struct target_ops): Add arch_string method.
16399
16400 2007-01-03 Denis Pilat <denis.pilat@st.com>
16401 Daniel Jacobowitz <dan@codesourcery.com>
16402
16403 * linux-low.c (linux_kill): Handle being called with no threads.
16404 * win32-i386-low.c (win32_kill): Likewise.
16405 (get_child_debug_event): Clear current_process_handle.
16406
16407 2006-12-30 Denis PILAT <denis.pilat@st.com>
16408 Daniel Jacobowitz <dan@codesourcery.com>
16409
16410 * remote-utils.c (remote_open): Check the type of specified
16411 serial port devices before opening them.
16412 * server.c (main): Kill the inferior if an error occurs during
16413 the first remote_open.
16414
16415 2006-12-05 Markus Deuling <deuling@de.ibm.com>
16416
16417 * README: Update supported targets.
16418
16419 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
16420
16421 * Makefile.in (clean): Remove reg-mips64.c.
16422 (reg-mips64.c, reg-mips64.o): New rules.
16423 * configure.srv: Handle mips64. Include regset support for mips.
16424 * linux-mips-low.c (union mips_register): New.
16425 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
16426 (mips_breakpoint, mips_breakpoint_at): Use int.
16427 (mips_collect_register, mips_supply_register)
16428 (mips_collect_register_32bit, mips_supply_register_32bit)
16429 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
16430 (mips_store_fpregset, target_regsets): New.
16431 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
16432
16433 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
16434
16435 * configure.srv: Add target "spu*-*-*".
16436 * Makefile.in (clean): Remove reg-spu.c.
16437 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
16438 * spu-low.c: New file.
16439
16440 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
16441
16442 * configure.ac: Correct td_thr_tls_get_addr test.
16443 * configure: Regenerated.
16444
16445 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
16446
16447 * linux-low.c (linux_wait_for_event): Reformat. Use the
16448 pass_signals array.
16449 * remote-utils.c (decode_address_to_semicolon): New.
16450 * server.c (pass_signals, handle_general_set): New.
16451 (handle_query): Mention QPassSignals for qSupported.
16452 (main): Call handle_general_set.
16453 * server.h (pass_signals, decode_address_to_semicolon): New.
16454
16455 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
16456
16457 * server.c (handle_query): Correct error handling for read_auxv.
16458
16459 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
16460
16461 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
16462 and srv_linux_thread_db to yes.
16463 * linux-s390-low.c (s390_fill_gregset): New function.
16464 (target_regsets): Define data structure.
16465
16466 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
16467
16468 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
16469 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
16470 * config.in, configure: Regenerated.
16471 * inferiors.c (gdb_id_to_thread): New function.
16472 (gdb_id_to_thread_id): Use it.
16473 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
16474 * linux-low.h (struct process_info): Add th member.
16475 (thread_db_get_tls_address): New prototype.
16476 * remote-utils.c (decode_address): Make non-static.
16477 * server.c (handle_query): Handle qGetTLSAddr.
16478 * server.h (gdb_id_to_thread, decode_address): New prototypes.
16479 * target.h (struct target_ops): Add get_tls_address.
16480 * thread-db.c (maybe_attach_thread): Save the thread handle.
16481 (thread_db_get_tls_address): New.
16482
16483 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
16484
16485 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
16486 (linux_resume_one_process): Take a siginfo_t *. Update all
16487 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
16488 (struct pending_signals): Add a siginfo_t.
16489 (linux_wait_for_process): Always set last_status.
16490 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
16491 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
16492 * linux-low.h (struct process_info): Add last_status.
16493
16494 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
16495
16496 * remote-utils.c (try_rle): New function.
16497 (putpkt_binary): Use it.
16498
16499 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
16500
16501 * Makefile.in (clean): Clean reg-x86-64-linux.c.
16502 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
16503 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
16504 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
16505 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
16506 point registers.
16507
16508 2006-08-08 Richard Sandiford <richard@codesourcery.com>
16509
16510 * server.c (terminal_fd): New variable.
16511 (old_foreground_pgrp): Likewise.
16512 (restore_old_foreground_pgrp): New function.
16513 (start_inferior): Record the terminal file descriptor in terminal_fd
16514 and its original foreground group in old_foreground_pgrp. Register
16515 restore_old_foreground_pgrp with atexit().
16516
16517 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
16518
16519 * server.c (handle_query): Correct qPart to qXfer.
16520
16521 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
16522
16523 * configure.ac: Check for more headers which are missing on
16524 Windows. Automatically supply -lwsock32 and USE_WIN32API.
16525 * configure.srv: Add Cygwin and mingw32.
16526 * remote-utils.c: Don't include headers unconditionally which
16527 are missing on mingw32. Include <winsock.h> for mingw32.
16528 (remote_open): Adjust for mingw32 support. Flush
16529 standard error after writing to it.
16530 (remote_close, putpkt_binary, input_interrupt, block_async_io)
16531 (unblock_async_io, enable_async_io, disable_async_io)
16532 (readchar, getpkt): Update for Winsock support.
16533 (prepare_resume_reply): Expect a protocol signal number.
16534 * server.c: Disable <sys/wait.h> on mingw32.
16535 (start_inferior): Adjust for mingw32 support. Flush
16536 standard error after writing to it.
16537 (attach_inferior): Likewise. Use protocol signal
16538 numbers.
16539 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
16540 and names.
16541 * win32-i386-low.c: New file.
16542 * Makefile.in (XM_CLIBS): Set.
16543 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
16544 (win32-i386-low.o): New dependency rule.
16545 * linux-low.c (linux_wait): Use target signal numbers.
16546 * target.h (struct target_ops): Doc fix.
16547 * server.h (target_signal_to_name): New prototype.
16548 * gdbreplay.c: Don't include headers unconditionally which
16549 are missing on mingw32. Include <winsock.h> for mingw32.
16550 (remote_close, remote_open): Adjust for Winsock support.
16551 * configure, config.in: Regenerated.
16552
16553 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
16554
16555 * server.c (decode_xfer_read, write_qxfer_response): New.
16556 (handle_query): Take a packet length argument. Handle
16557 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
16558 the qSupported response.
16559 (main): Update call to handle_query.
16560
16561 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
16562
16563 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
16564 (putpkt_binary): Renamed from putpkt and adjusted for binary
16565 data.
16566 (putpkt): New wrapper for putpkt_binary.
16567 (readchar): Don't mask off the high bit.
16568 (decode_X_packet): New function.
16569 * server.c (main): Call putpkt_binary if a handler sets the packet
16570 length. Save the length of the incoming packet. Handle 'X'.
16571 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
16572
16573 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
16574
16575 * server.c (handle_query): Handle qSupported.
16576
16577 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
16578
16579 * remote-utils.c (all_symbols_looked_up): New variable.
16580 (look_up_one_symbol): Check it.
16581 * server.h (look_up_one_symbol): New declaration.
16582 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
16583
16584 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
16585
16586 * Makefile.in (linux-arm-low.o): Update dependencies.
16587 * linux-arm-low.c: Include "gdb_proc_service.h".
16588 (PTRACE_GET_THREAD_AREA): Define.
16589 (ps_get_thread_area): New function.
16590
16591 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
16592
16593 * configure.srv (m68k*-*-uclinux*): New target.
16594 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
16595 (linux_resume_one_process): Remove extraneous cast.
16596 (linux_read_offsets): New.
16597 (linux_target_op): Add linux_read_offsets on mmuless systems.
16598 * server.c (handle_query): Add qOffsets logic.
16599 * target.h (struct target_ops): Add read_offsets.
16600
16601 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
16602
16603 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
16604 (PTRACE_GET_THREAD_AREA): Define.
16605 (ps_get_thread_area): New function.
16606 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
16607 (linux-x86-64-low.o): Update.
16608
16609 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
16610
16611 * configure.ac: Remove checks for prfpregset_t.
16612 * gdb_proc_service.h: New file.
16613 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
16614 new "gdb_proc_service.h".
16615 * proc-service.c: Likewise.
16616 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
16617 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
16618 * Makefile.in (gdb_proc_service_h): Updated.
16619 * configure, config.in: Regenerated.
16620
16621 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
16622
16623 * remote-utils.c (prepare_resume_reply): Move declaration
16624 of gdb_id_from_wait to the top of the block.
16625
16626 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
16627
16628 * linux-low.c (regsets_store_inferior_registers): Read the regset
16629 from the target before filling it.
16630
16631 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
16632
16633 * server.c (attach_inferior): Return SIGTRAP for a successful
16634 attach.
16635
16636 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
16637
16638 * Makefile.in (OBS): Add version.o.
16639 (STAGESTUFF): Delete.
16640 (version.o): Add dependencies.
16641 (version.c): Replace rule.
16642 (clean): Remove version.c.
16643 * server.c (gdbserver_version): New.
16644 (gdbserver_usage): Use printf.
16645 (main): Handle --version and --help.
16646 * server.h (version, host_name): Add declarations.
16647
16648 2005-12-23 Eli Zaretskii <eliz@gnu.org>
16649
16650 * linux-arm-low.c:
16651 * linux-arm-low.c:
16652 * inferiors.c:
16653 * i387-fp.h:
16654 * i387-fp.c:
16655 * gdbreplay.c:
16656 * regcache.c:
16657 * proc-service.c:
16658 * mem-break.h:
16659 * mem-break.c:
16660 * linux-x86-64-low.c:
16661 * linux-sh-low.c:
16662 * linux-s390-low.c:
16663 * linux-ppc64-low.c:
16664 * linux-ppc-low.c:
16665 * linux-mips-low.c:
16666 * linux-m68k-low.c:
16667 * linux-m32r-low.c:
16668 * linux-low.h:
16669 * linux-low.c:
16670 * linux-ia64-low.c:
16671 * linux-i386-low.c:
16672 * linux-crisv32-low.c:
16673 * thread-db.c:
16674 * terminal.h:
16675 * target.h:
16676 * target.c:
16677 * server.h:
16678 * server.c:
16679 * remote-utils.c:
16680 * regcache.h:
16681 * utils.c:
16682 * Makefile.in:
16683 * configure.ac:
16684 * gdbserver.1: Add (C) after Copyright. Update the FSF
16685 address.
16686
16687 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
16688
16689 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
16690 (arm_breakpoint_at): Recognize both breakpoints.
16691 (the_low_target): Use the correct breakpoint instruction.
16692
16693 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
16694
16695 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
16696 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
16697 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
16698 (the_low_target): Update.
16699
16700 2005-10-25 Andreas Schwab <schwab@suse.de>
16701
16702 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
16703
16704 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
16705 (ia64_num_regs): Reduce to 462.
16706
16707 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
16708
16709 * acinclude.m4: Correct quoting.
16710 * aclocal.m4: Regenerated.
16711
16712 Suggested by SZOKOVACS Robert <szo@ies.hu>:
16713 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
16714 (thread_db_init): Call thread_db_err_str.
16715 * configure.ac: Check for TD_VERSION.
16716 * config.in, configure: Regenerated.
16717
16718 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16719
16720 * server.h (error, fatal, warning): Add ATTR_FORMAT.
16721
16722 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16723
16724 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
16725 is not available. Define HAVE_PTRACE_GETREGS if it is.
16726 * config.in, configure: Regenerated.
16727 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
16728 * linux-i386-low.c, linux-m68k-low.c: Update to use
16729 HAVE_PTRACE_GETREGS.
16730 * linux-low.c (regsets_fetch_inferior_registers)
16731 (regsets_store_inferior_registers): Only return 0 if we processed
16732 GENERAL_REGS.
16733 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
16734 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
16735
16736 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16737
16738 * inferiors.c (struct thread_info): Add gdb_id.
16739 (add_thread): Add gdb_id argument.
16740 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
16741 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
16742 calls to add_thread.
16743 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
16744 * server.c (handle_query): Use thread_to_gdb_id.
16745 (handle_v_cont, main): Use gdb_id_to_thread_id.
16746 * server.h (add_thread): Update prototype.
16747 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
16748 prototypes.
16749
16750 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16751
16752 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
16753 left-padded registers.
16754 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
16755 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
16756
16757 2005-07-01 Steve Ellcey <sje@cup.hp.com>
16758
16759 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
16760 * configure: Regenerate.
16761 * config.in: Regenerate.
16762 * server.h (NEED_DECLARATION_STRERROR):
16763 Replace with !HAVE_DECL_STRERROR.
16764
16765 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
16766
16767 * linux-low.c (linux_wait, linux_send_signal): Don't test
16768 an unsigned long variable for > 0 if it could be MAX_ULONG.
16769 * server.c (myresume): Likewise.
16770 * target.c (set_desired_inferior): Likewise.
16771
16772 2005-06-13 Mark Kettenis <kettenis@gnu.org>
16773
16774 * configure.ac: Simplify and improve check for socklen_t.
16775 * configure, config.in: Regenerate.
16776
16777 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
16778
16779 * acconfig.h: Remove.
16780 * configure.ac: Add a test for socklen_t. Use three-argument
16781 AC_DEFINE throughout.
16782 * config.in: Regenerated using autoheader 2.59.
16783 * configure: Regenerated.
16784
16785 * gdbreplay.c (socklen_t): Provide a default.
16786 (remote_open): Use socklen_t.
16787 * remote-utils.c (socklen_t): Provide a default.
16788 (remote_open): Use socklen_t.
16789 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
16790 unsigned char.
16791
16792 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
16793 char for buffers.
16794 * linux-low.c (linux_read_memory, linux_write_memory)
16795 (linux_read_auxv): Likewise.
16796 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
16797 (check_mem_write): Likewise.
16798 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
16799 Likewise.
16800 * regcache.c (struct inferior_rgcache_data, registers_to_string)
16801 (registers_from_string, register_data): Likewise.
16802 * server.c (handle_query, main): Likewise.
16803 * server.h (convert_ascii_to_int, convert_int_to_ascii)
16804 (decode_M_packet): Likewise.
16805 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
16806 * target.h (struct target_ops): Update read_memory, write_memory,
16807 and read_auxv.
16808 (read_inferior_memory, write_inferior_memory): Update.
16809 * linux-low.h (struct linux_target_ops): Change type of breakpoint
16810 to unsigned char *.
16811 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
16812 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
16813 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
16814 linux-s390-low.c, linux-sh-low.c: Update for changes in
16815 read_inferior_memory and the_low_target->breakpoint.
16816
16817 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
16818
16819 * Makefile.in (SFILES): Add linux-ppc64-low.c.
16820 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
16821 * configure.srv: Add powerpc64-*-linux*.
16822 * linux-ppc64-low.c: New file.
16823
16824 2005-05-23 Orjan Friberg <orjanf@axis.com>
16825
16826 * linux-cris-low.c: New file with support for CRIS.
16827 * linux-crisv32-low.c: Ditto for CRISv32.
16828 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
16829 (clean): Add reg-cris.c and reg-crisv32.c.
16830 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
16831 reg-crisv32.o, and reg-crisv32.c to make rules.
16832 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
16833 recognized targets.
16834
16835 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
16836
16837 * linux-low.c (fetch_register): Ensure buffer size is a multiple
16838 of sizeof (PTRACE_XFER_TYPE).
16839 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
16840
16841 2005-05-12 Orjan Friberg <orjanf@axis.com>
16842
16843 * target.h (struct target_ops): Add insert_watchpoint,
16844 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
16845 pointers for hardware watchpoint support.
16846 * linux-low.h (struct linux_target_ops): Ditto.
16847 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
16848 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
16849 to linux_target_ops.
16850 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
16851 reply packet.
16852 * server.c (main): Recognize 'Z' and 'z' packets.
16853
16854 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
16855
16856 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
16857 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
16858 (the_low_target): Add new members.
16859
16860 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
16861
16862 * proc-service.c (ps_lgetregs): Search all_processes instead of
16863 all_threads.
16864
16865 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
16866
16867 * server.c (start_inferior): Change return type to int.
16868 (attach_inferior): Change sigptr to int *.
16869 (handle_v_cont, handle_v_requests): Change signal to int *.
16870 (main): Change signal to int.
16871
16872 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
16873
16874 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
16875 * configure.srv: Add m32r*-*-linux*.
16876 * linux-m32r-low.c: New file.
16877
16878 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
16879
16880 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
16881
16882 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
16883
16884 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
16885 Take unsigned long arguments for PIDs.
16886 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
16887 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
16888 (wait_for_sigstop, linux_resume_one_process)
16889 (regsets_fetch_inferior_registers, linux_send_signal)
16890 (linux_read_auxv): Likewise. Update the types of variables holding
16891 PIDs. Update format string specifiers.
16892 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
16893 * remote-utils.c (prepare_resume_reply): Likewise.
16894 * server.c (cont_thread, general_thread, step_thread)
16895 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
16896 unsigned long.
16897 (handle_query): Update format specifiers.
16898 (handle_v_cont, main): Use strtoul for thread IDs.
16899 * server.h (struct inferior_list_entry): Use unsigned long for ID.
16900 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
16901 (general_thread, step_thread, thread_from_wait)
16902 (old_thread_from_wait): Update.
16903 * target.h (struct thread_resume): Use unsigned long for THREAD.
16904 (struct target_ops): Use unsigned long for arguments to attach and
16905 thread_alive.
16906
16907 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
16908
16909 * acinclude.m4: Include bfd/bfd.m4 directly.
16910 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
16911 <agriffis@toolchain.org>.
16912 * aclocal.m4, configure: Regenerated.
16913
16914 2005-01-07 Andrew Cagney <cagney@gnu.org>
16915
16916 * configure.ac: Rename configure.in, require autoconf 2.59.
16917 * configure: Re-generate.
16918
16919 2004-12-08 Daniel Jacobowitz <dan@debian.org>
16920
16921 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
16922 LIBS when finished.
16923 * aclocal.m4: Regenerated.
16924 * configure: Regenerated.
16925
16926 2004-11-21 Andreas Schwab <schwab@suse.de>
16927
16928 * linux-m68k-low.c (m68k_num_gregs): Define.
16929 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
16930 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
16931 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
16932 (m68k_breakpoint_at): New. Add to the_low_target.
16933
16934 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
16935 srv_linux_thread_db to yes.
16936
16937 2004-10-20 Joel Brobecker <brobecker@gnat.com>
16938
16939 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
16940 (ARCH_SET_FS): Likewise.
16941 (ARCH_GET_FS): Likewise.
16942 (ARCH_GET_GS): Likewise.
16943
16944 2004-10-16 Daniel Jacobowitz <dan@debian.org>
16945
16946 * linux-i386-low.c (ps_get_thread_area): New.
16947 * linux-x86-64-low.c (ps_get_thread_area): New.
16948 * linux-low.c: Include <sys/syscall.h>.
16949 (linux_kill_one_process): Don't kill the first thread here.
16950 (linux_kill): Kill the first thread here.
16951 (kill_lwp): New function.
16952 (send_sigstop, linux_send_signal): Use it.
16953 * proc-service.c: Clean up #ifdefs.
16954 (fpregset_info): Delete.
16955 (ps_lgetregs): Update and enable implementation.
16956 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
16957 implementations.
16958 * remote-utils.c (struct sym_cache, symbol_cache): New.
16959 (input_interrupt): Print a clearer message.
16960 (async_io_enabled): New variable.
16961 (enable_async_io, disable_async_io): Use it. Update comments.
16962 (look_up_one_symbol): Use the symbol cache.
16963 * thread-db.c (thread_db_look_up_symbols): New function.
16964 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
16965
16966 2004-10-16 Daniel Jacobowitz <dan@debian.org>
16967
16968 * configure.in: Test for -rdynamic.
16969 * configure: Regenerated.
16970 * Makefile (INTERNAL_LDFLAGS): New.
16971 (gdbserver, gdbreplay): Use it.
16972
16973 2004-09-02 Andrew Cagney <cagney@gnu.org>
16974
16975 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
16976
16977 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
16978
16979 * linux-low.c (linux_wait): Clear all_processes list also.
16980
16981 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
16982
16983 * linux-low.c: Include <errno.h>. Remove extern declaration of
16984 errno.
16985
16986 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
16987
16988 * gdbreplay.c, server.h, utils.c: Update copyright years.
16989
16990 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
16991
16992 * server.c (main): Print child status or termination signal from
16993 variable 'signal', not 'sig'.
16994
16995 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
16996
16997 * linux-low.c (linux_read_memory): Change return type to
16998 int. Check for and return error from ptrace().
16999 * target.c (read_inferior_memory): Change return type to int. Pass
17000 back return status from the_target->read_memory().
17001 * target.h (struct target_ops): Adapt *read_memory() prototype.
17002 Update comment.
17003 (read_inferior_memory): Adapt prototype.
17004 * server.c (main): Return an error packet if
17005 read_inferior_memory() returns an error.
17006
17007 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
17008
17009 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
17010 Unify with other clean targets.
17011
17012 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17013
17014 * server.c (handle_v_cont): Call set_desired_inferior.
17015
17016 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17017
17018 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
17019
17020 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17021
17022 * linux-low.c (linux_wait): Unblock async I/O.
17023 (linux_resume): Block and enable async I/O.
17024 * remote-utils.c (block_async_io, unblock_async_io): New functions.
17025 * server.h (block_async_io, unblock_async_io): Add prototypes.
17026
17027 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17028
17029 * remote-utils.c (remote_open): Print a status notice after
17030 opening a TCP port.
17031 * server.c (attach_inferior): Print a status notice after
17032 attaching.
17033
17034 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17035
17036 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
17037
17038 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
17039
17040 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
17041 error packet.
17042 * server.c, target.h: Update copyright years.
17043
17044 2004-02-25 Roland McGrath <roland@redhat.com>
17045
17046 * target.h (struct target_ops): New member `read_auxv'.
17047 * server.c (handle_query): Handle qPart:auxv:read: query using that.
17048 * linux-low.c (linux_read_auxv): New function.
17049 (linux_target_ops): Initialize `read_auxv' member to that.
17050
17051 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
17052
17053 Committed by Jim Blandy <jimb@redhat.com>.
17054
17055 * linux-s390-low.c (s390_num_regs): Update.
17056 (s390_regmap): Remove control registers. Use __s390x__ predefine
17057 instead of GPR_SIZE to distiguish s390 and s390x targets.
17058
17059 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
17060
17061 * linux-low.c: Update copyright year.
17062 (check_removed_breakpoint): Clear pending_is_breakpoint.
17063 (linux_set_resume_request, linux_queue_one_thread)
17064 (resume_status_pending_p): New functions.
17065 (linux_continue_one_thread): Use process->resume.
17066 (linux_resume): Only resume threads if there are no pending events.
17067 * linux-low.h (struct process_info): Add resume request
17068 pointer.
17069
17070 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
17071
17072 * regcache.c (new_register_cache): Clear the allocated register
17073 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
17074
17075 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
17076
17077 * linux-low.c (linux_resume): Take a struct thread_resume *
17078 argument.
17079 (linux_wait): Update call.
17080 (resume_ptr): New static variable.
17081 (linux_continue_one_thread): Renamed from
17082 linux_continue_one_process. Use resume_ptr.
17083 (linux_resume): Use linux_continue_one_thread.
17084 * server.c (handle_v_cont, handle_v_requests): New functions.
17085 (myresume): New function.
17086 (main): Handle 'v' case.
17087 * target.h (struct thread_resume): New type.
17088 (struct target_ops): Change argument of "resume" to struct
17089 thread_resume *.
17090 (myresume): Delete macro.
17091
17092 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
17093
17094 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
17095 (uninstall): Support DESTDIR.
17096
17097 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
17098
17099 * configure.srv: Add xscale*linux copy of arm*linux entry.
17100
17101 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
17102
17103 * linux-arm-low.c (arm_reinsert_addr): New function.
17104 (the_low_target): Add arm_reinsert_addr.
17105
17106 2003-07-08 Mark Kettenis <kettenis@gnu.org>
17107
17108 * mem-break.c: Remove whitespace at end of file.
17109
17110 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
17111
17112 * configure.in: Check whether we need to prototype strerror.
17113 * server.h: Optionally prototype strerror.
17114 * gdbreplay.c (perror_with_name): Use strerror.
17115 * linux-low.c (linux_attach_lwp): Use strerror.
17116 * utils.c (perror_with_name): Use strerror.
17117 * config.in, configure: Regenerated.
17118
17119 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
17120
17121 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
17122 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
17123
17124 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
17125
17126 * Makefile.in (SFILES): Update.
17127 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
17128 low-sun3.c: Remove files.
17129
17130 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
17131
17132 * linux-low.c: Move comment to linux_thread_alive where it belonged.
17133 (linux_detach_one_process, linux_detach): New functions.
17134 (linux_target_ops): Add linux_detach.
17135 * server.c (main): Handle 'D' packet.
17136 * target.h (struct target_ops): Add "detach" member.
17137 (detach_inferior): Define.
17138
17139 2003-06-13 Mark Kettenis <kettenis@gnu.org>
17140
17141 From Kelley Cook <kelleycook@wideopenwest.com>:
17142 * configure.srv: Accept i[34567]86 variants.
17143
17144 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
17145
17146 * linux-low.c (linux_wait_for_event): Correct comment typos.
17147 (linux_resume_one_process): Call check_removed_breakpoint.
17148 (linux_send_signal): New function.
17149 (linux_target_ops): Add linux_send_signal.
17150 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
17151 of kill.
17152 * target.h (struct target_ops): Add send_signal.
17153
17154 2003-05-29 Jim Blandy <jimb@redhat.com>
17155
17156 * linux-low.c (usr_store_inferior_registers): Transfer buf in
17157 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
17158 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
17159 away part of the register's value.
17160
17161 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
17162
17163 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
17164 (linux_wait_for_event, linux_init_signals): Likewise.
17165
17166 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
17167
17168 * configure.in: Check for stdlib.h.
17169 * configure: Regenerated.
17170 * config.in: Regenerated.
17171
17172 2003-01-04 Andreas Schwab <schwab@suse.de>
17173
17174 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
17175
17176 2003-01-02 Andrew Cagney <ac131313@redhat.com>
17177
17178 * Makefile.in: Remove obsolete code.
17179
17180 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
17181
17182 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
17183 defined(PT_FPR0_HI).
17184
17185 2002-11-17 Stuart Hughes <seh@zee2.com>
17186
17187 * linux-arm-low.c (arm_num_regs): Increase.
17188 (arm_regmap): Include status register.
17189
17190 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
17191
17192 * linux-low.c (register_addr): Remove incorrect -1 check.
17193
17194 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
17195
17196 * linux-low.c (linux_create_inferior): Call setpgid. Return
17197 the new PID.
17198 (unstopped_p, linux_signal_pid): Remove.
17199 (linux_target_ops): Remove linux_signal_pid.
17200 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
17201 global instead of target method.
17202 * target.h (struct target_ops): Remove signal_pid. Update comment
17203 for create_inferior.
17204 * server.c (signal_pid): New variable.
17205 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
17206 gdbserver. Set the child to be the foreground process group.
17207 (attach_inferior): Set signal_pid.
17208
17209 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
17210
17211 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
17212
17213 2002-08-20 Jim Blandy <jimb@redhat.com>
17214
17215 * Makefile.in (LDFLAGS): Allow the configure script to establish a
17216 default for this.
17217
17218 2002-08-01 Andrew Cagney <cagney@redhat.com>
17219
17220 * Makefile.in: Make chill references obsolete.
17221
17222 2002-07-24 Kevin Buettner <kevinb@redhat.com>
17223
17224 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
17225 * configure: Regenerate.
17226 * config.in: Regenerate.
17227
17228 2002-07-09 David O'Brien <obrien@FreeBSD.org>
17229
17230 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
17231 (perror_with_name, remote_close, remote_open, expect, play): Static.
17232
17233 2002-07-04 Michal Ludvig <mludvig@suse.cz>
17234
17235 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
17236 byte offsets instead of an array of indexes.
17237 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
17238
17239 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
17240
17241 * regcache.c: Add comment.
17242
17243 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
17244
17245 * thread-db.c: New file.
17246 * proc-service.c: New file.
17247 * acinclude.m4: New file.
17248 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
17249 proc-service.o, and thread-db.o.
17250 (linux-low.o): Add USE_THREAD_DB.
17251 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
17252 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
17253 * aclocal.m4: Regenerated.
17254 * config.in: Regenerated.
17255 * configure: Regenerated.
17256 * configure.in: Check for proc_service.h, sys/procfs.h,
17257 thread_db.h, and linux/elf.h headrs.
17258 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
17259 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
17260 Check for -lthread_db and thread support.
17261 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
17262 PowerPC, and SuperH.
17263 * i387-fp.c: Constify arguments.
17264 * i387-fp.h: Likewise.
17265 * inferiors.c: (struct thread_info): Renamed from
17266 `struct inferior_info'. Remove PID member. Use generic inferior
17267 list header. All uses updated.
17268 (inferiors, signal_pid): Removed.
17269 (all_threads): New variable.
17270 (get_thread): Define.
17271 (add_inferior_to_list): New function.
17272 (for_each_inferior): New function.
17273 (change_inferior_id): New function.
17274 (add_inferior): Removed.
17275 (remove_inferior): New function.
17276 (add_thread): New function.
17277 (free_one_thread): New function.
17278 (remove_thread): New function.
17279 (clear_inferiors): Use for_each_inferior and free_one_thread.
17280 (find_inferior): New function.
17281 (find_inferior_id): New function.
17282 (inferior_target_data): Update argument type.
17283 (set_inferior_target_data): Likewise.
17284 (inferior_regcache_data): Likewise.
17285 (set_inferior_regcache_data): Likewise.
17286 * linux-low.c (linux_bp_reinsert): Remove.
17287 (all_processes, stopping_threads, using_thrads)
17288 (struct pending_signals, debug_threads, pid_of): New.
17289 (inferior_pid): Replace with macro.
17290 (struct inferior_linux_data): Remove.
17291 (get_stop_pc, add_process): New functions.
17292 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
17293 Use add_process and add_thread.
17294 (linux_attach_lwp): New function, based on old linux_attach. Use
17295 add_process and add_thread. Set stop_expected for new threads.
17296 (linux_attach): New function.
17297 (linux_kill_one_process): New function.
17298 (linux_kill): Kill all LWPs.
17299 (linux_thread_alive): Use find_inferior_id.
17300 (check_removed_breakpoints, status_pending_p): New functions.
17301 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
17302 Update. Use WNOHANG. Wait for cloned processes also. Update process
17303 struct for the found process.
17304 (linux_wait_for_event): New function.
17305 (linux_wait): Use it. Support LWPs.
17306 (send_sigstop, wait_for_sigstop, stop_all_processes)
17307 (linux_resume_one_process, linux_continue_one_process): New functions.
17308 (linux_resume): Support LWPs.
17309 (REGISTER_RAW_SIZE): Remove.
17310 (fetch_register): Use register_size instead. Call supply_register.
17311 (usr_store_inferior_registers): Likewise. Call collect_register.
17312 Fix recursive case.
17313 (regsets_fetch_inferior_registers): Improve error message.
17314 (regsets_store_inferior_registers): Add debugging.
17315 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
17316 (unstopped_p, linux_signal_pid): New functions.
17317 (linux_target_ops): Add linux_signal_pid.
17318 (linux_init_signals): New function.
17319 (initialize_low): Call it. Initialize using_threads.
17320 * regcache.c (inferior_regcache_data): Add valid
17321 flag.
17322 (get_regcache): Fetch registers lazily. Add fetch argument
17323 and update all callers.
17324 (regcache_invalidate_one, regcache_invalidate): New
17325 functions.
17326 (new_register_cache): Renamed from create_register_cache.
17327 Return the new regcache.
17328 (free_register_cache): Change argument to a void *.
17329 (registers_to_string, registers_from_string): Call get_regcache
17330 with fetch flag set.
17331 (register_data): Make static. Pass fetch flag to get_regcache.
17332 (supply_register): Call get_regcache with fetch flag clear.
17333 (collect_register): Call get_regcache with fetch flag set.
17334 (collect_register_as_string): New function.
17335 * regcache.h: Update.
17336 * remote-utils.c (putpkt): Flush after debug output and use
17337 stderr.
17338 Handle input interrupts while waiting for an ACK.
17339 (input_interrupt): Use signal_pid method.
17340 (getpkt): Flush after debug output and use stderr.
17341 (outreg): Use collect_register_as_string.
17342 (new_thread_notify, dead_thread_notify): New functions.
17343 (prepare_resume_reply): Check using_threads. Set thread_from_wait
17344 and general_thread.
17345 (look_up_one_symbol): Flush after debug output.
17346 * server.c (step_thread, server_waiting): New variables.
17347 (start_inferior): Don't use signal_pid. Update call to mywait.
17348 (attach_inferior): Update call to mywait.
17349 (handle_query): Handle qfThreadInfo and qsThreadInfo.
17350 (main): Don't fetch/store registers explicitly. Use
17351 set_desired_inferior. Support proposed ``Hs'' packet. Update
17352 calls to mywait.
17353 * server.h: Update.
17354 (struct inferior_list, struct_inferior_list_entry): New.
17355 * target.c (set_desired_inferior): New.
17356 (write_inferior_memory): Constify.
17357 (mywait): New function.
17358 * target.h: Update.
17359 (struct target_ops): New signal_pid method.
17360 (mywait): Removed macro, added prototype.
17361
17362 * linux-low.h (regset_func): Removed.
17363 (regset_fill_func, regset_store_func): New.
17364 (enum regset_type): New.
17365 (struct regset_info): Add type field. Use new operation types.
17366 (struct linux_target_ops): stop_pc renamed to get_pc.
17367 Add decr_pc_after_break and breakpoint_at.
17368 (get_process, get_thread_proess, get_process_thread)
17369 (strut process_info, all_processes, linux_attach_lwp)
17370 (thread_db_init): New.
17371
17372 * linux-arm-low.c (arm_get_pc, arm_set_pc,
17373 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
17374 (the_low_target): Add new members.
17375 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
17376 (i386_store_fpxregset): Constify.
17377 (target_regsets): Add new kind identifier.
17378 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
17379 (i386_set_pc): Add debugging.
17380 (i386_breakpoint_at): New function.
17381 (the_low_target): Add new members.
17382 * linux-mips-low.c (mips_get_pc, mips_set_pc)
17383 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
17384 (mips_breakpoint_at): New.
17385 (the_low_target): Add new members.
17386 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
17387 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
17388 (the_low_target): Add new members.
17389 * linux-sh-low.c (sh_get_pc, sh_set_pc)
17390 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
17391 (the_low_target): Add new members.
17392 * linux-x86-64-low.c (target_regsets): Add new kind
17393 identifier.
17394
17395 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
17396
17397 From Martin Pool <mbp@samba.org>:
17398 * server.c (gdbserver_usage): New function.
17399 (main): Call it.
17400
17401 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
17402
17403 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
17404 stop_at -> stop_pc.
17405
17406 2002-05-04 Andrew Cagney <ac131313@redhat.com>
17407
17408 * Makefile.in: Remove obsolete code.
17409
17410 2002-04-24 Michal Ludvig <mludvig@suse.cz>
17411
17412 * linux-low.c (regsets_fetch_inferior_registers),
17413 (regsets_store_inferior_registers): Removed cast to int from
17414 ptrace() calls.
17415 * regcache.h: Added declaration of struct inferior_info.
17416
17417 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
17418
17419 * inferiors.c (struct inferior_info): Add regcache_data.
17420 (add_inferior): Call create_register_cache.
17421 (clear_inferiors): Call free_register_cache.
17422 (inferior_regcache_data, set_inferior_regcache_data): New functions.
17423 * regcache.c (struct inferior_regcache_data): New.
17424 (registers): Remove.
17425 (get_regcache): New function.
17426 (create_register_cache, free_register_cache): New functions.
17427 (set_register_cache): Don't initialize the register cache here.
17428 (registers_to_string, registers_from_string, register_data): Call
17429 get_regcache.
17430 * regcache.h: Add prototypes.
17431 * server.h: Likewise.
17432
17433 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
17434
17435 * mem-break.c: New file.
17436 * mem-break.h: New file.
17437 * Makefile.in: Add mem-break.o rule; update server.h
17438 dependencies.
17439 * inferiors.c (struct inferior_info): Add target_data
17440 member.
17441 (clear_inferiors): Free target_data member if set.
17442 (inferior_target_data, set_inferior_target_data): New functions.
17443 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
17444 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
17445 * linux-low.c (linux_bp_reinsert): New variable.
17446 (struct inferior_linux_data): New.
17447 (linux_create_inferior): Use set_inferior_target_data.
17448 (linux_attach): Likewise. Call add_inferior.
17449 (linux_wait_for_one_inferior): New function.
17450 (linux_wait): Call it.
17451 (linux_write_memory): Add const.
17452 (initialize_low): Call set_breakpoint_data.
17453 * linux-low.h (struct linux_target_ops): Add breakpoint
17454 handling members.
17455 * server.c (attach_inferior): Remove extra add_inferior
17456 call.
17457 * server.h: Include mem-break.h. Update inferior.c
17458 prototypes.
17459 * target.c (read_inferior_memory)
17460 (write_inferior_memory): New functions.
17461 * target.h (read_inferior_memory)
17462 (write_inferior_memory): Change macros to prototypes.
17463 (struct target_ops): Update comments. Add const to write_memory
17464 definition.
17465
17466 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
17467
17468 * linux-low.c (usr_store_inferior_registers): Support
17469 registers which are allowed to fail to store.
17470 * linux-low.h (linux_target_ops): Likewise.
17471 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
17472 (ppc_cannot_store_register): FPSCR may not be storable.
17473
17474 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17475
17476 * server.h: Include <string.h> if HAVE_STRING_H.
17477 * ChangeLog: Correct paths in last ChangeLog entry.
17478
17479 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17480
17481 * linux-low.h: Remove obsolete prototypes.
17482 (struct linux_target_ops): New.
17483 (extern the_low_target): New.
17484 * linux-low.c (num_regs, regmap): Remove declarations.
17485 (register_addr): Use the_low_target explicitly.
17486 (fetch_register): Likewise.
17487 (usr_fetch_inferior_registers): Likewise.
17488 (usr_store_inferior_registers): Likewise.
17489 * linux-arm-low.c (num_regs): Remove.
17490 (arm_num_regs): Define.
17491 (arm_regmap): Renamed from regmap, made static.
17492 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
17493 made static.
17494 (arm_cannot_store_register): Renamed from cannot_store_register,
17495 made static.
17496 (the_low_target): New.
17497 * linux-i386-low.c (num_regs): Remove.
17498 (i386_num_regs): Define.
17499 (i386_regmap): Renamed from regmap, made static.
17500 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
17501 made static.
17502 (i386_cannot_store_register): Renamed from cannot_store_register,
17503 made static.
17504 (the_low_target): New.
17505 * linux-ia64-low.c (num_regs): Remove.
17506 (ia64_num_regs): Define.
17507 (ia64_regmap): Renamed from regmap, made static.
17508 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
17509 made static.
17510 (ia64_cannot_store_register): Renamed from cannot_store_register,
17511 made static.
17512 (the_low_target): New.
17513 * linux-m68k-low.c (num_regs): Remove.
17514 (m68k_num_regs): Define.
17515 (m68k_regmap): Renamed from regmap, made static.
17516 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
17517 made static.
17518 (m68k_cannot_store_register): Renamed from cannot_store_register,
17519 made static.
17520 (the_low_target): New.
17521 * linux-mips-low.c (num_regs): Remove.
17522 (mips_num_regs): Define.
17523 (mips_regmap): Renamed from regmap, made static.
17524 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
17525 made static.
17526 (mips_cannot_store_register): Renamed from cannot_store_register,
17527 made static.
17528 (the_low_target): New.
17529 * linux-ppc-low.c (num_regs): Remove.
17530 (ppc_num_regs): Define.
17531 (ppc_regmap): Renamed from regmap, made static.
17532 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
17533 made static.
17534 (ppc_cannot_store_register): Renamed from cannot_store_register,
17535 made static.
17536 (the_low_target): New.
17537 * linux-s390-low.c (num_regs): Remove.
17538 (s390_num_regs): Define.
17539 (s390_regmap): Renamed from regmap, made static.
17540 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
17541 made static.
17542 (s390_cannot_store_register): Renamed from cannot_store_register,
17543 made static.
17544 (the_low_target): New.
17545 * linux-sh-low.c (num_regs): Remove.
17546 (sh_num_regs): Define.
17547 (sh_regmap): Renamed from regmap, made static.
17548 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
17549 made static.
17550 (sh_cannot_store_register): Renamed from cannot_store_register,
17551 made static.
17552 (the_low_target): New.
17553 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
17554 (the_low_target): New.
17555
17556 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17557
17558 * Makefile.in: Add stamp-h target.
17559 * configure.in: Create stamp-h.
17560 * configure: Regenerated.
17561
17562 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17563
17564 * inferiors.c: New file.
17565 * target.c: New file.
17566 * target.h: New file.
17567 * Makefile.in: Add target.o and inferiors.o. Update
17568 dependencies.
17569 * linux-low.c (inferior_pid): New static variable,
17570 moved from server.c.
17571 (linux_create_inferior): Renamed from create_inferior.
17572 Call add_inferior. Return 0 on success instead of a PID.
17573 (linux_attach): Renamed from myattach.
17574 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
17575 (linux_thread_alive): Renamed from mythread_alive.
17576 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
17577 child dies.
17578 (linux_resume): Renamed from myresume. Add missing ``return 0''.
17579 (regsets_store_inferior_registers): Correct error message.
17580 Add missing ``return 0''.
17581 (linux_fetch_registers): Renamed from fetch_inferior_registers.
17582 (linux_store_registers): Renamed from store_inferior_registers.
17583 (linux_read_memory): Renamed from read_inferior_memory.
17584 (linux_write_memory): Renamed from write_inferior_memory.
17585 (linux_target_ops): New structure.
17586 (initialize_low): Call set_target_ops ().
17587 * remote-utils.c (unhexify): New function.
17588 (hexify): New function.
17589 (input_interrupt): Send signals to ``signal_pid''.
17590 * server.c (inferior_pid): Remove.
17591 (start_inferior): Update create_inferior call.
17592 (attach_inferior): Call add_inferior.
17593 (handle_query): New function.
17594 (main): Call handle_query for `q' packets.
17595 * server.h: Include "target.h". Remove obsolete prototypes.
17596 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
17597
17598 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17599
17600 * Makefile.in: Add WARN_CFLAGS. Update configury
17601 dependencies.
17602 * configure.in: Check for <string.h>
17603 * configure: Regenerate.
17604 * config.in: Regenerate.
17605 * gdbreplay.c: Include needed system headers.
17606 (remote_open): Remove strchr prototype.
17607 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
17608 * regcache.c (supply_register): Change buf argument to const void *.
17609 (supply_register_by_name): Likewise.
17610 (collect_register): Change buf argument to void *.
17611 (collect_register_by_name): Likewise.
17612 * regcache.h: Add missing prototypes.
17613 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
17614 * server.c (handle_query): New function.
17615 (attached): New static variable, moved out of main.
17616 (main): Quiet longjmp clobber warnings.
17617 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
17618 * utils.c (error): Remove NORETURN.
17619 (fatal): Likewise.
This page took 0.512589 seconds and 4 git commands to generate.