7eef2c54cba73cd64e1977f42cdbfd7bae2b7a72
[deliverable/binutils-gdb.git] / gdb / gdbserver / ChangeLog
1 2019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
2
3 * linux-low.c (linux_low_read_btrace): Update for change to
4 std::vector.
5
6 2019-09-20 Christian Biesinger <cbiesinger@google.com>
7
8 * debug.c (debug_threads): Remove comment in favor of the header.
9 * debug.h (using_threads): Add declaration.
10 (debug_threads): Add comment.
11 * linux-aarch64-low.c: Include debug.h and remove declaration of
12 debug_threads.
13 * nto-low.c: Likewise.
14 * remote-utils.c: Likewise.
15 * thread-db.c: Likewise.
16
17 2019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
18
19 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
20 and powerpc-cell64l-ipa.o.
21 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
22 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
23 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
24 (spu*-*-*): Remove.
25
26 * spu-low.c: Remove file.
27
28 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
29 (parse_spufs_run): Remove.
30 (ppc_get_pc): Remove Cell/B.E. support.
31 (ppc_set_pc): Likewise.
32 (ppc_breakpoint_at): Likewise.
33 (ppc_arch_setup): Likewise.
34 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
35 tdesc_powerpc_cell32l.
36 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
37 or init_registers_powerpc_cell32l.
38 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
39 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
40 or init_registers_powerpc_cell32l.
41 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
42 (init_registers_powerpc_cell32l): Remove prototype.
43 (init_registers_powerpc_cell64l): Likewise.
44
45 * target.h (struct target_ops): Remove qxfer_spu member.
46 * server.c (handle_qxfer_spu): Remove.
47 (qxfer_packets): Remove entry for "spu".
48 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
49 * linux-low.c (SPUFS_MAGIC): Remove.
50 (spu_enumerate_spu_ids): Remove.
51 (linux_qxfer_spu): Remove.
52 (linux_target_ops): Remove qxfer_spu member.
53 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
54 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
55 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
56
57 2019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
58
59 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
60 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
61 * config.in: Regenerate.
62 * configure: Regenerate.
63
64 2019-08-15 Tom Tromey <tromey@adacore.com>
65
66 * target.c (target_write_memory): Use gdb::byte_vector.
67
68 2019-08-15 Tom Tromey <tromey@adacore.com>
69
70 * tracepoint.c (write_inferior_data_pointer)
71 (write_inferior_integer, write_inferior_int8)
72 (write_inferior_uinteger, m_tracepoint_action_download)
73 (r_tracepoint_action_download, x_tracepoint_action_download)
74 (l_tracepoint_action_download, clear_inferior_trace_buffer)
75 (download_agent_expr, download_tracepoint_1)
76 (download_trace_state_variables, upload_fast_traceframes): Update.
77 * server.c (gdb_write_memory): Update.
78 * remote-utils.c (relocate_instruction): Update.
79 * proc-service.c (ps_pdwrite): Update.
80 * mem-break.c (remove_memory_breakpoint)
81 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
82 (uninsert_fast_tracepoint_jumps_at)
83 (reinsert_fast_tracepoint_jumps_at): Update.
84 * linux-x86-low.c (append_insns)
85 (i386_install_fast_tracepoint_jump_pad)
86 (amd64_write_goto_address, i386_write_goto_address): Update.
87 * linux-s390-low.c (append_insns, s390_write_goto_address):
88 Update.
89 * linux-ppc-low.c (ppc_relocate_instruction)
90 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
91 (ppc_write_goto_address): Update.
92 * linux-aarch64-low.c (append_insns): Update.
93 * target.h (struct target_ops): Update.
94 (write_inferior_memory): Don't declare.
95 * target.c (target_write_memory): Rename from
96 write_inferior_memory. Remove old target_write_memory.
97
98 2019-08-15 Tom Tromey <tromey@adacore.com>
99
100 * target.c (write_inferior_memory): Use std::vector.
101
102 2019-08-06 Frank Ch. Eigler <fche@redhat.com>
103
104 PR build/24886
105 * configure.ac: Drop enable-libmcheck support.
106 * configure, config.in: Rebuild.
107 * acinclude.m4: Don't include it.
108
109 2019-07-19 Alan Hayward <alan.hayward@arm.com>
110
111 * configure.srv: Remove Arm xml files.
112
113 2019-07-19 Alan Hayward <alan.hayward@arm.com>
114
115 * configure.srv: Add new files. Remove xml generated files.
116 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
117 registers.
118 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
119 * linux-aarch32-tdesc.c: New file.
120 * linux-aarch32-tdesc.h: New file.
121 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
122 * linux-arm-low.c (init_registers_arm, tdesc_arm)
123 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
124 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
125 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
126 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
127 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
128 (arm_read_description): Call arm_linux_read_description.
129 (initialize_low_arch): Don't init registers.
130 * linux-arm-tdesc.c: New file.
131 * linux-arm-tdesc.h: New file.
132
133 2019-07-10 Alan Hayward <alan.hayward@arm.com>
134
135 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
136 Move counter inside for.
137 (arm_read_description): Check ptrace earlier.
138 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
139
140 2019-07-09 Tom Tromey <tom@tromey.com>
141
142 * configure: Rebuild.
143 * configure.ac: Change common to gdbsupport.
144 * acinclude.m4: Change common to gdbsupport.
145 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
146 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
147 common to gdbsupport.
148 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
149 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
150 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
151 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
152 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
153 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
154 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
155 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
156 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
157 common to gdbsupport.
158
159 2019-07-04 Alan Hayward <alan.hayward@arm.com>
160
161 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
162 defines.
163 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
164
165 2019-07-04 Alan Hayward <alan.hayward@arm.com>
166
167 * configure.srv: Remove legacy xml.
168 * linux-aarch64-low.c (initialize_low_arch): Remove
169 initialize_low_tdesc call.
170 * linux-aarch64-tdesc-selftest.c: Remove file.
171 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
172 * linux-x86-low.c (initialize_low_arch): Remove
173 initialize_low_tdesc call.
174 * linux-x86-tdesc-selftest.c: Remove file.
175 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
176
177 2019-06-20 Tom de Vries <tdevries@suse.de>
178
179 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
180 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
181
182 2019-06-19 Tom de Vries <tdevries@suse.de>
183
184 * debug.h (debug_write): Change return type to ssize_t.
185 * debug.c (debug_write): Same.
186
187 2019-06-14 Tom Tromey <tom@tromey.com>
188
189 * configure.ac: Use new path to gnulib.
190 * configure: Rebuild.
191 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
192 to gnulib.
193
194 2019-06-11 Tom Tromey <tom@tromey.com>
195
196 * Makefile.in (SFILES): Add alloc.c.
197 (OBS): Add alloc.o.
198 (IPA_OBJS): Add alloc-ipa.o.
199 (alloc-ipa.o): New target.
200 (%.o: ../%.c): New pattern rule.
201
202 2019-06-10 Tom Tromey <tromey@adacore.com>
203
204 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
205 end warning with a newline.
206 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
207 newline.
208 * thread-db.c (attach_thread): Don't end warning with a newline.
209 (thread_db_notice_clone): Likewise.
210 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
211 newline.
212 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
213 end warning with a newline.
214
215 2019-06-04 Pedro Alves <palves@redhat.com>
216
217 * server.c (captured_main): Use make_unique_xstrdup.
218
219 2019-06-02 Tom Tromey <tom@tromey.com>
220
221 * gdbreplay.c (fromhex): Remove.
222 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
223
224 2019-05-29 Tom Tromey <tromey@adacore.com>
225
226 * configure: Rebuild.
227
228 2019-05-06 Kevin Buettner <kevinb@redhat.com>
229
230 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
231 sign extension code on 32-bit builds.
232
233 2019-05-03 Eli Zaretskii <eliz@gnu.org>
234
235 * remote-utils.c:
236 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
237
238 2019-04-19 Tom Tromey <tom@tromey.com>
239
240 * server.c (struct vstop_notif): Derive from notif_event.
241 <base>: Remove.
242 (queue_stop_reply): Update.
243 (remove_all_on_match_ptid): Change type. Rewrite.
244 (discard_queued_stop_replies): Rewrite.
245 (in_queued_stop_replies_ptid): Change type.
246 (in_queued_stop_replies): Rewrite.
247 (notif_stop): Update.
248 (queue_stop_reply_callback): Update.
249 (captured_main): Don't call initialize_notif.
250 (push_stop_notification): Update.
251 * notif.c (notif_write_event, handle_notif_ack)
252 (notif_event_enque, notif_push): Update.
253 (notif_event_xfree, initialize_notif): Remove.
254 * notif.h (struct notif_event): Include <list>, not
255 "common/queue.h".
256 (struct notif_server) <queue>: Now a std::list.
257 (notif_event_p): Remove typedef.
258 (initialize_notif): Don't declare.
259 (struct notif_event): Add virtual destructor.
260
261 2019-04-17 Alan Hayward <alan.hayward@arm.com>
262
263 * ax.c (ax_vdebug): Call debug_printf.
264 * debug.c (debug_write): New function.
265 * debug.h (debug_write): New declaration.
266 * linux-low.c (sigchld_handler): Call debug_write.
267
268 2019-04-17 Alan Hayward <alan.hayward@arm.com>
269
270 * debug.c (debug_set_output): New function.
271 (debug_vprintf): Send output to debug_file.
272 (debug_flush): Likewise.
273 * debug.h (debug_set_output): New declaration.
274 * server.c (handle_monitor_command): Add debug-file option.
275 (captured_main): Likewise.
276
277 2019-04-17 Alan Hayward <alan.hayward@arm.com>
278
279 * debug.c (remote_debug): Add definition.
280 * debug.h (remote_debug): Add declaration.
281 * hostio.c (remote_debug): Remove declaration.
282 * remote-utils.c (struct ui_file): Likewise.
283 (remote_debug): Likewise.
284 * remote-utils.h (remote_debug): Likewise,
285 * server.c (remote_debug): Remove definition.
286
287 2019-04-10 Kevin Buettner <kevinb@redhat.com>
288
289 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
290 when using a 64-bit gdbserver.
291
292 2019-04-09 Tom Tromey <tromey@adacore.com>
293
294 * linux-low.c (select_event_lwp): Use find_thread_in_random.
295
296 2019-04-08 Tom Tromey <tom@tromey.com>
297
298 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
299 throw.
300 (linux_resume_one_lwp): Likewise.
301
302 2019-04-08 Tom Tromey <tom@tromey.com>
303
304 * gdbreplay.c: Update.
305 * linux-low.c: Update.
306 * server.c: Update.
307
308 2019-04-08 Tom Tromey <tom@tromey.com>
309
310 * server.c: Use C++ exception handling.
311 * linux-low.c: Use C++ exception handling.
312 * gdbreplay.c: Use C++ exception handling.
313
314 2019-04-08 Tom Tromey <tom@tromey.com>
315
316 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
317 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
318 (captured_main, main): Update.
319 * gdbreplay.c (main): Update.
320
321 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
322
323 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
324 value in argument pointer, return 1 if the entry is found and 0
325 otherwise. Move comment.
326 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
327 * linux-low.h (linux_get_auxv): Declare.
328 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
329
330 2019-04-05 Tom Tromey <tromey@adacore.com>
331
332 * server.c (gdbserver_usage): Use upper-case for metasyntactic
333 variables.
334
335 2019-03-28 Alan Hayward <alan.hayward@arm.com>
336
337 * linux-low.c (AT_HWCAP2): Add define if not already included.
338
339 2019-03-26 Alan Hayward <alan.hayward@arm.com>
340
341 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
342 (aarch64_arch_setup): Call linux_get_hwcap.
343 * linux-arm-low.c (arm_get_hwcap): Remove function.
344 (arm_read_description): Call linux_get_hwcap.
345 * linux-low.c (linux_get_auxv): New function.
346 (linux_get_hwcap): Likewise.
347 (linux_get_hwcap2): Likewise.
348 * linux-low.h (linux_get_hwcap): New declaration.
349 (linux_get_hwcap2): Likewise.
350 * linux-ppc-low.c (ppc_get_auxv): Remove function.
351 (ppc_arch_setup): Call linux_get_hwcap.
352 * linux-s390-low.c (s390_get_hwcap): Remove function.
353 (s390_arch_setup): Call linux_get_hwcap.
354
355 2019-03-22 Alan Hayward <alan.hayward@arm.com>
356 Jiong Wang <jiong.wang@arm.com>
357
358 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
359 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
360 to fail.
361 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
362
363 2019-03-22 Alan Hayward <alan.hayward@arm.com>
364 Jiong Wang <jiong.wang@arm.com>
365
366 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
367 (aarch64_get_hwcap): New function.
368 (aarch64_arch_setup): Read APIA hwcap.
369
370 2019-03-22 Alan Hayward <alan.hayward@arm.com>
371 Jiong Wang <jiong.wang@arm.com>
372
373 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
374 (initialize_low_tracepoint): Likewise.
375 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
376 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
377 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
378 (aarch64_linux_read_description): Likewise.
379 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
380
381 2019-03-12 John Baldwin <jhb@FreeBSD.org>
382
383 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
384 i386_create_target_description for 'segments' parameter.
385 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
386 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
387 * win32-i386-low.c (i386_arch_setup): Likewise.
388
389 2019-03-12 Tom Tromey <tromey@adacore.com>
390
391 * linux-low.c (iterate_over_lwps): Update.
392
393 2019-03-06 Tom Tromey <tom@tromey.com>
394
395 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
396 (captured_main): Use SCOPE_EXIT.
397
398 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
399
400 * configure.srv: Use '$enable_unittest' instead of '$development'
401 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
402 case.
403
404 2019-02-27 Tom Tromey <tromey@adacore.com>
405
406 * gdbreplay.c (logchar): Handle \r\n.
407
408 2019-02-07 Alan Hayward <alan.hayward@arm.com>
409
410 * linux-low.c (linux_attach): Add process before lwp.
411 * server.c (attach_inferior): Check if already attached.
412
413 2019-02-07 Tom Tromey <tom@tromey.com>
414
415 * x86-tdesc.h: Rename include guard.
416 * x86-low.h: Add include guard.
417 * wincecompat.h: Rename include guard.
418 * win32-low.h: Add include guard.
419 * utils.h: Rename include guard.
420 * tracepoint.h: Rename include guard.
421 * tdesc.h: Rename include guard.
422 * target.h: Rename include guard.
423 * server.h: Rename include guard.
424 * remote-utils.h: Rename include guard.
425 * regcache.h: Rename include guard.
426 * nto-low.h: Rename include guard.
427 * notif.h: Add include guard.
428 * mem-break.h: Rename include guard.
429 * lynx-low.h: Add include guard.
430 * linux-x86-tdesc.h: Add include guard.
431 * linux-s390-tdesc.h: Add include guard.
432 * linux-ppc-tdesc-init.h: Add include guard.
433 * linux-low.h: Add include guard.
434 * linux-aarch64-tdesc.h: Add include guard.
435 * linux-aarch32-low.h: Add include guard.
436 * inferiors.h: Rename include guard.
437 * i387-fp.h: Rename include guard.
438 * hostio.h: Rename include guard.
439 * gdbthread.h: Rename include guard.
440 * gdb_proc_service.h: Rename include guard.
441 * event-loop.h: Rename include guard.
442 * dll.h: Rename include guard.
443 * debug.h: Rename include guard.
444 * ax.h: Rename include guard.
445
446 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
447
448 PR gdb/23985
449 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
450 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
451
452 2019-01-25 Tom Tromey <tom@tromey.com>
453
454 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
455
456 2019-01-25 Tom Tromey <tom@tromey.com>
457
458 * win32-low.c: Fix common/ includes.
459 * win32-i386-low.c: Fix common/ includes.
460 * tracepoint.c: Fix common/ includes.
461 * thread-db.c: Fix common/ includes.
462 * target.h: Fix common/ includes.
463 * symbol.c: Fix common/ includes.
464 * spu-low.c: Fix common/ includes.
465 * server.h: Fix common/ includes.
466 * server.c: Fix common/ includes.
467 * remote-utils.c: Fix common/ includes.
468 * regcache.h: Fix common/ includes.
469 * regcache.c: Fix common/ includes.
470 * nto-x86-low.c: Fix common/ includes.
471 * notif.h: Fix common/ includes.
472 * mem-break.h: Fix common/ includes.
473 * lynx-low.c: Fix common/ includes.
474 * lynx-i386-low.c: Fix common/ includes.
475 * linux-x86-tdesc-selftest.c: Fix common/ includes.
476 * linux-x86-low.c: Fix common/ includes.
477 * linux-low.c: Fix common/ includes.
478 * inferiors.h: Fix common/ includes.
479 * i387-fp.c: Fix common/ includes.
480 * hostio.c: Fix common/ includes.
481 * hostio-errno.c: Fix common/ includes.
482 * gdbthread.h: Fix common/ includes.
483 * gdbreplay.c: Fix common/ includes.
484 * fork-child.c: Fix common/ includes.
485 * event-loop.c: Fix common/ includes.
486 * ax.c:
487 (enum gdb_agent_op): Fix common/ includes.
488
489 2019-01-21 Tom Tromey <tom@tromey.com>
490
491 * tracepoint.c: Fix includes.
492 * remote-utils.c: Fix includes.
493 * linux-x86-low.c: Fix includes.
494
495 2019-01-01 Joel Brobecker <brobecker@adacore.com>
496
497 * gdbreplay.c (gdbreplay_version): Update copyright year in
498 version message.
499 * server.c (gdbserver_version): Likewise.
500
501 2018-12-05 Alan Hayward <alan.hayward@arm.com>
502
503 * linux-low.c (add_lwp): Switch ordering.
504
505 2018-11-29 Tom Tromey <tom@tromey.com>
506
507 * win32-low.c (win32_join): Take pid, not process.
508 * target.h (struct target_ops) <join>: Change argument type.
509 (join_inferior): Change argument name.
510 * spu-low.c (spu_join): Take pid, not process.
511 * server.c (handle_detach): Preserve pid before destroying
512 process.
513 * lynx-low.c (lynx_join): Take pid, not process.
514 * linux-low.c (linux_join): Take pid, not process.
515
516 2018-11-23 Alan Hayward <alan.hayward@arm.com>
517
518 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
519 (aarch64_cannot_fetch_register): Likewise.
520 (struct linux_target_ops): Update references.
521
522 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
523
524 * linux-ppc-low.c: Include nat/linux-ptrace.h.
525
526 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
527
528 * configure.srv (ipa_ppc_linux_regobj): Add
529 powerpc-isa207-htm-vsx32l-ipa.o and
530 powerpc-isa207-htm-vsx64l-ipa.o.
531 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
532 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
533 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
534 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
535 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
536 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
537 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
538 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
539 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
540 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
541 (init_registers_powerpc_isa207_htm_vsx32l)
542 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
543 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
544 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
545 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
546 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
547 (ppc_store_tm_ctarregset): New functions.
548 (ppc_regsets): Add entries for HTM regsets.
549 (ppc_arch_setup): Set htm in features struct when needed. Set
550 sizes for the HTM regsets.
551 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
552 (initialize_low_arch): Call
553 init_registers_powerpc_isa207_htm_vsx32l and
554 init_registers_powerpc_isa207_htm_vsx64l.
555 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
556 PPC_TDESC_ISA207_HTM_VSX.
557 (initialize_low_tracepoint): Call
558 init_registers_powerpc_isa207_htm_vsx32l and
559 init_registers_powerpc_isa207_htm_vsx64l.
560
561 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
562
563 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
564 rs6000/power-linux-pmu.xml to srv_xmlfiles.
565 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
566 (ppc_store_pmuregset): New functions.
567 (ppc_regsets): Add entries for ebb and pmu regsets.
568 (ppc_arch_setup): Set isa207 in features struct if the ebb and
569 pmu regsets are available. Set sizes for these regsets.
570
571 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
572
573 * configure.srv (ipa_ppc_linux_regobj): Add
574 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
575 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
576 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
577 rs6000/powerpc-isa207-vsx32l.xml, and
578 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
579 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
580 <PPC_TDESC_ISA207_VSX>: New enum value.
581 (init_registers_powerpc_isa207_vsx32l): Declare.
582 (init_registers_powerpc_isa207_vsx64l): Declare.
583 * linux-ppc-low.c (ppc_fill_tarregset): New function.
584 (ppc_store_tarregset): New function.
585 (ppc_regsets): Add entry for the TAR regset.
586 (ppc_arch_setup): Set isa207 in features struct when needed. Set
587 size for the TAR regsets.
588 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
589 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
590 and init_registers_powerpc_isa207_vsx64l.
591 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
592 (initialize_low_tracepoint): Call
593 init_registers_powerpc_isa207_vsx32l and
594 init_registers_powerpc_isa207_vsx64l.
595
596 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
597 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
598
599 * configure.srv (ipa_ppc_linux_regobj): Add
600 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
601 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
602 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
603 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
604 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
605 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
606 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
607 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
608 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
609 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
610 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
611 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
612 (ppc_hwcap): Add comment.
613 (ppc_hwcap2): New global.
614 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
615 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
616 (ppc_regsets): Add entries for the DSCR and PPR regsets.
617 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
618 when needed. Set sizes for the the DSCR and PPR regsets.
619 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
620 (initialize_low_arch): Call
621 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
622 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
623 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
624 PPC_TDESC_ISA205_PPR_DSCR_VSX.
625 (initialize_low_tracepoint): Call
626 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
627 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
628
629 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
630
631 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
632
633 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
634 Simon Marchi <simark@simark.ca>
635
636 * acinclude.m4: Include "../selftest.m4".
637 * configure: Regenerate.
638 * configure.ac: Use "GDB_AC_SELFTEST".
639 * configure.srv: Use "$enable_unittests" instead of
640 "$development" when checking whether unit tests have been
641 enabled.
642 * server.c (captured_main): Update message informing that
643 selftests have been disabled.
644
645 2018-10-04 Tom Tromey <tom@tromey.com>
646
647 * configure: Rebuild.
648
649 2018-10-04 Tom Tromey <tom@tromey.com>
650
651 * server.c (handle_status): Rename inner "thread".
652 (process_serial_event): Declare "res" in 'm' case.
653 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
654 (iterate_over_lwps): Rename inner "thread".
655 (linux_qxfer_libraries_svr4): Rename inner "len".
656 * gdbthread.h (find_thread_in_random): Rename inner "thread".
657
658 2018-10-01 Gary Benson <gbenson@redhat.com>
659
660 * gdb_proc_service.h: Moved common code to
661 common/gdb_proc_service.h.
662
663 2018-10-01 Gary Benson <gbenson@redhat.com>
664
665 * gdb_proc_service.h: Synchronize comments and whitespace with
666 GDB's version of this file.
667
668 2018-09-25 Tom Tromey <tom@tromey.com>
669
670 * configure: Rebuild.
671 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
672
673 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
674
675 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
676 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
677 ($(IPA_LIB)): Sort IPA_OBJS.
678
679 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
680
681 * Makefile.in: Remove references to $(ADD_DEPS).
682
683 2018-09-16 Tom Tromey <tom@tromey.com>
684
685 * remote-utils.c (remote_open): Use GNU style for metasyntactic
686 variables.
687 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
688 variables.
689
690 2018-09-05 Tom Tromey <tom@tromey.com>
691
692 * configure: Rebuild.
693
694 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
695
696 PR build/23399
697 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
698
699 2018-08-27 Tom Tromey <tom@tromey.com>
700
701 PR build/23087:
702 * configure: Rebuild.
703
704 2018-08-27 Tom Tromey <tom@tromey.com>
705
706 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
707 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
708 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
709 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
710 (s390x_emit_stack_adjust): Add casts to unsigned char.
711
712 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
713
714 PR gdb/23374
715 PR gdb/23375
716 * server.h (struct client_state) <disable_randomization>:
717 Initialize to 1.
718
719 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
720
721 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
722 variable.
723 (mips_supply_ptrace_register): Likewise.
724
725 2018-07-22 Tom Tromey <tom@tromey.com>
726
727 * configure: Rebuild.
728
729 2018-07-22 Tom Tromey <tom@tromey.com>
730
731 * win32-low.c (win32_create_inferior): Remove unused variables.
732 * gdbreplay.c (remote_open): Remove unused variable.
733 * remote-utils.c (remote_prepare): Remove unused variable.
734 * x86-tdesc.h (X86_TDESC_H): Define.
735 (amd64_expedite_regs): Define conditionally.
736 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
737 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
738 * remote-utils.c (readchar): Remove unused variable.
739
740 2018-07-13 Pedro Alves <palves@redhat.com>
741
742 * linux-low.c (linux_kill): Change parameter to process_info
743 pointer instead of pid. Adjust.
744 * lynx-low.c (lynx_kill): Likewise.
745 * nto-low.c (nto_kill): Likewise.
746 * spu-low.c (spu_kill): Likewise.
747 * win32-low.c (win32_kill): Likewise.
748 * server.c (handle_v_kill, kill_inferior_callback)
749 (detach_or_kill_for_exit): Adjust.
750 * target.c (kill_inferior): Change parameter to process_info
751 pointer instead of pid. Adjust.
752 * target.h (struct target_ops) <kill>: Change parameter to
753 process_info pointer instead of pid. Adjust all implementations
754 and callers.
755 (kill_inferior): Likewise.
756
757 2018-07-13 Pedro Alves <palves@redhat.com>
758
759 * linux-low.c (linux_detach, linux_join): Change parameter to
760 process_info pointer instead of pid. Adjust.
761 * lynx-low.c (lynx_detach, lynx_join): Likewise.
762 * nto-low.c (nto_detach): Likewise.
763 * spu-low.c (spu_detach, spu_join): Likewise.
764 * win32-low.c (win32_detach, win32_join): Likewise.
765 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
766 * target.h (struct target_ops) <detach, join>: Change parameter to
767 process_info pointer instead of pid. Adjust all implementations
768 and callers.
769 (detach_inferior, join_inferior): Rename 'pid' parameter to
770 'proc'.
771
772 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
773 Jan Kratochvil <jan.kratochvil@redhat.com>
774 Paul Fertser <fercerpav@gmail.com>
775 Tsutomu Seki <sekiriki@gmail.com>
776
777 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
778 (OBS): Add 'common/netstuff.o'.
779 (GDBREPLAY_OBS): Likewise.
780 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
781 (remote_open): Implement support for IPv6
782 connections.
783 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
784 and 'wspiapi.h'.
785 (handle_accept_event): Accept connections from IPv6 sources.
786 (remote_prepare): Handle IPv6-style hostnames; implement
787 support for IPv6 connections.
788 (remote_open): Implement support for printing connections from
789 IPv6 sources.
790
791 2018-07-11 Pedro Alves <palves@redhat.com>
792
793 PR gdb/23377
794 * mem-break.c (any_persistent_commands): Add process_info
795 parameter and use it instead of relying on the current process.
796 Change return type to bool.
797 * mem-break.h (any_persistent_commands): Add process_info
798 parameter and change return type to bool.
799 * server.c (handle_detach): Remove require_running_or_return call.
800 Look up the process_info for the process we're about to detach.
801 If not found, return back error to GDB. Adjust
802 any_persistent_commands call to pass down a process pointer.
803
804 2018-07-11 Pedro Alves <palves@redhat.com>
805
806 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
807 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
808 instead of collect_register_by_name.
809 * regcache.c (regcache_raw_get_unsigned_by_name): New.
810 * regcache.h (regcache_raw_get_unsigned_by_name): New.
811
812 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
813 Pedro Alves <palves@redhat.com>
814
815 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
816
817 2018-07-03 Tom Tromey <tom@tromey.com>
818
819 * linux-low.c: Update.
820 * lynx-low.c: Update.
821 * mem-break.c: Update.
822 * nto-low.c: Update.
823 * remote-utils.c: Update.
824 * server.c: Update.
825 * spu-low.c: Update.
826 * target.c: Update.
827 * win32-low.c: Update.
828
829 2018-07-03 Tom Tromey <tom@tromey.com>
830
831 * server.c: Update.
832
833 2018-07-03 Tom Tromey <tom@tromey.com>
834
835 * linux-low.c: Update.
836
837 2018-07-03 Tom Tromey <tom@tromey.com>
838
839 * target.c: Update.
840
841 2018-07-03 Tom Tromey <tom@tromey.com>
842
843 * linux-low.c: Update.
844 * linux-mips-low.c: Update.
845 * lynx-low.c: Update.
846 * nto-low.c: Update.
847 * remote-utils.c: Update.
848 * server.c: Update.
849 * spu-low.c: Update.
850 * target.c: Update.
851 * thread-db.c: Update.
852
853 2018-07-03 Tom Tromey <tom@tromey.com>
854
855 * linux-low.c: Update.
856 * linux-mips-low.c: Update.
857 * lynx-low.c: Update.
858 * mem-break.c: Update.
859 * nto-low.c: Update.
860 * remote-utils.c: Update.
861 * server.c: Update.
862 * spu-low.c: Update.
863 * target.c: Update.
864 * tracepoint.c: Update.
865
866 2018-07-03 Tom Tromey <tom@tromey.com>
867
868 * linux-low.c: Update.
869 * linux-ppc-low.c: Update.
870 * linux-x86-low.c: Update.
871 * proc-service.c: Update.
872 * server.c: Update.
873 * spu-low.c: Update.
874 * thread-db.c: Update.
875 * win32-low.c: Update.
876
877 2018-07-03 Tom Tromey <tom@tromey.com>
878
879 * linux-low.c: Update.
880 * lynx-low.c: Update.
881 * nto-low.c: Update.
882 * remote-utils.c: Update.
883 * spu-low.c: Update.
884 * thread-db.c: Update.
885 * win32-low.c: Update.
886
887 2018-06-29 Joel Brobecker <brobecker@adacore.com>
888
889 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
890 parameter in call to 'amd64_create_target_description'.
891
892 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
893
894 * x86-tdesc.h: Remove executable permission flag.
895
896 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
897
898 * configure.ac: Remove AC_PREREQ, add missing quoting.
899 * configure: Re-generate.
900 * config.in: Re-generate.
901 * aclocal.m4: Re-generate.
902
903 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
904
905 * tracepoint.h (current_traceframe): Remove declaration.
906
907 2018-06-18 Alan Hayward <alan.hayward@arm.com>
908
909 * linux-aarch64-low.c (is_sve_tdesc): New function.
910 (aarch64_sve_regs_copy_to_regcache): Likewise.
911 (aarch64_sve_regs_copy_from_regcache): Likewise.
912 (aarch64_regs_info): Add SVE checks.
913 (initialize_low_arch): Initialize SVE.
914
915 2018-06-18 Alan Hayward <alan.hayward@arm.com>
916
917 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
918
919 2018-06-11 Alan Hayward <alan.hayward@arm.com>
920
921 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
922 (initialize_low_tracepoint): Likewise
923 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
924 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
925 param.
926 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
927 checks.
928 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
929
930 2018-06-11 Alan Hayward <alan.hayward@arm.com>
931
932 * server.h (PBUFSIZ): Increase size
933
934 2018-06-11 Alan Hayward <alan.hayward@arm.com>
935
936 * regcache.c (regcache::raw_compare): New function.
937 * regcache.h (regcache::raw_compare): New declaration.
938
939 2018-06-11 Alan Hayward <alan.hayward@arm.com>
940
941 * regcache.c (new_register_cache): Use new.
942 (free_register_cache): Use delete.
943 (register_data): Use const.
944 (supply_register): Move body inside regcache.
945 (regcache::raw_supply): New override function.
946 (collect_register): Move body inside regcache.
947 (regcache::raw_collect): New override function.
948 (regcache::get_register_status): New override function.
949 * regcache.h (struct regcache): Inherit from reg_buffer_common.
950
951 2018-06-09 Tom Tromey <tom@tromey.com>
952
953 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
954 declare queue.
955 (event_queue): Use std::queue.
956 (gdb_event_xfree): Remove.
957 (initialize_event_loop, process_event, wait_for_event): Update.
958
959 2018-06-08 Stan Cox <scox@redhat.com>
960
961 * win32-low.c (win32_create_inferior): last_ptid and last_status
962 moved to client_state.
963
964 2018-06-08 Pedro Alves <palves@redhat.com>
965
966 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
967 common/common-exceptions.o, common/common-utils.o,
968 common/errors.o, common/print-utils.o and utils.o.
969 * gdbreplay.c: Include "common-defs.h" instead of the two
970 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
971 string.h or alloca.h.
972 (perror_with_name): Delete.
973 (remote_open): Use xstrdup instead of strdup.
974 (main): Rename to ...
975 (captured_main): ... this.
976 (main): New.
977
978 2018-06-08 Tom Tromey <tom@tromey.com>
979
980 * linux-low.c (linux_low_read_btrace): Update.
981
982 2018-06-04 Stan Cox <scox@redhat.com>
983
984 * server.h (struct client_state): New.
985 * server.c (cont_thread, general_thread, multi_process)
986 (report_fork_events, report_vfork_events, report_exec_events)
987 (report_thread_events, swbreak_feature, hwbreak_feature)
988 (vCont_supported, disable_randomization, pass_signals)
989 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
990 Moved to client_state.
991 * remote-utils.c (remote_debug, noack_mode)
992 (transport_is_reliable): Moved to client_state.
993 * tracepoint.c (current_traceframe): Moved to client_state.
994
995 Update all callers.
996 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
997 linux-low.c, remote-utils.h, target.c: Use client_state.
998
999 2018-05-31 Alan Hayward <alan.hayward@arm.com>
1000
1001 * configure.srv: Add new c/h file.
1002
1003 2018-05-31 Alan Hayward <alan.hayward@arm.com>
1004
1005 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
1006 null VQ.
1007
1008 2018-05-25 Maciej W. Rozycki <macro@mips.com>
1009
1010 * gdb.arch/mips-fpregset-core.exp: New test.
1011 * gdb.arch/mips-fpregset-core.c: New test source.
1012
1013 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
1014
1015 PR server/23198
1016 * hostio.c (require_int): Do not report overflow for integers
1017 between 0xfffffff and 0x7fffffff.
1018
1019 2018-05-22 Maciej W. Rozycki <macro@mips.com>
1020
1021 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
1022 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
1023 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
1024 functions.
1025 (the_low_target): Wire them.
1026
1027 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1028
1029 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
1030 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
1031 mode. Call collect_register_by_name with vscr using
1032 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
1033 (ppc_store_vrregset): Add and set vscr_offset variable as in
1034 ppc_fill_vrregset. Call supply_register_by_name with vscr using
1035 vscr_offset.
1036
1037 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1038
1039 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
1040 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
1041 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
1042
1043 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1044
1045 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
1046 (ppc_store_vsxregset): Likewise.
1047 (ppc_fill_vrregset): Likewise.
1048 (ppc_store_vrregset): Likewise.
1049 (ppc_fill_evrregset): Likewise.
1050 (ppc_store_evrregset): Likewise.
1051 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
1052 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
1053 needed.
1054
1055 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1056
1057 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
1058 wordsize of the inferior. Call ppc_linux_target_wordsize.
1059
1060 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1061
1062 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
1063 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
1064 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
1065 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
1066 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
1067 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
1068 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
1069 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
1070 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
1071 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
1072 (tdesc_powerpc_e500l): Remove.
1073 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
1074 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
1075 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
1076 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
1077 linux-ppc-tdesc.h.
1078 (ppc_arch_setup): Remove target description matching code. Fill a
1079 ppc_linux_features struct and call ppc_linux_match_description
1080 with it.
1081
1082 2018-05-22 Maciej W. Rozycki <macro@mips.com>
1083
1084 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
1085 width of the requested register exceeds the width of the
1086 `ptrace' data type.
1087 (mips_cannot_store_register): Likewise.
1088
1089 2018-05-21 Maciej W. Rozycki <macro@mips.com>
1090
1091 * linux-mips-low.c (mips_fetch_register): New function. Update
1092 preceding comment.
1093 (mips_store_gregset): Supply 0 rather than $restart for $zero.
1094 (the_low_target): Wire `mips_fetch_register'.
1095
1096 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1097
1098 * lynx-i386-low.c (LYNXOS_178): New macro.
1099 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
1100 the layout on LynxOS-178.
1101 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
1102 handle floating point registers that are not supported by
1103 LynxOS-178.
1104
1105 2018-05-10 Tom Tromey <tom@tromey.com>
1106
1107 * configure: Rebuild.
1108
1109 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1110
1111 PR server/23158:
1112 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
1113 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
1114 Use it to set the expedite_regs field in the given tdesc.
1115 * x86-tdesc.h: New file.
1116 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
1117 Adjust following the addition of the new expedite_regs parameter
1118 to init_target_desc.
1119 * linux-tic6x-low.c (tic6x_read_description): Likewise.
1120 * linux-x86-tdesc.c: #include "x86-tdesc.h".
1121 (i386_linux_read_description, amd64_linux_read_description):
1122 Adjust following the addition of the new expedite_regs parameter
1123 to init_target_desc.
1124 * lynx-i386-low.c: #include "x86-tdesc.h".
1125 (lynx_i386_arch_setup): Adjust following the addition of the new
1126 expedite_regs parameter to init_target_desc.
1127 * nto-x86-low.c: #include "x86-tdesc.h".
1128 (nto_x86_arch_setup): Adjust following the addition of the new
1129 expedite_regs parameter to init_target_desc.
1130 * win32-i386-low.c: #include "x86-tdesc.h".
1131 (i386_arch_setup): Adjust following the addition of the new
1132 expedite_regs parameter to init_target_desc.
1133
1134 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1135
1136 PR server/23158:
1137 * win32-low.c (win32_create_inferior): Add call to my_wait
1138 setting last_status global.
1139
1140 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1141
1142 PR server/23158:
1143 * win32-low.c (create_process): Only call gdb_tilde_expand if
1144 inferior_cwd is not NULL.
1145
1146 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
1147
1148 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
1149 registers to the cache if their values have changed.
1150 (i387_xsave_to_cache): Provide default values for x87 control
1151 registers when these features are available, but disabled.
1152 * regcache.c (supply_register_by_name_zeroed): New function.
1153 * regcache.h (supply_register_by_name_zeroed): Declare new
1154 function.
1155
1156 2018-05-07 Tom Tromey <tom@tromey.com>
1157
1158 * configure: Rebuild.
1159
1160 2018-05-04 Tom Tromey <tom@tromey.com>
1161
1162 * configure: Rebuild.
1163
1164 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
1165 Pedro Alves <palves@redhat.com>
1166
1167 * linux-aarch64-low.c (aarch64_stopped_data_address):
1168 Likewise.
1169
1170 2018-04-27 Tom Tromey <tom@tromey.com>
1171
1172 * configure: Rebuild.
1173
1174 2018-04-23 Tom Tromey <tom@tromey.com>
1175
1176 * configure: Rebuild.
1177
1178 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
1179
1180 * Makefile.in (depcomp): Add "..".
1181 (all_deps_files): New and use it.
1182
1183 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1184
1185 * configure.srv (aarch64*-*-linux*): Don't include xml.
1186 (i[34567]86-*-cygwin*): Likewise.
1187 (i[34567]86-*-linux*): Likewise.
1188 (i[34567]86-*-lynxos*): Likewise.
1189 (i[34567]86-*-mingw32ce*): Likewise.
1190 (i[34567]86-*-mingw*): Likewise.
1191 (i[34567]86-*-nto*): Likewise.
1192 (tic6x-*-uclinux): Likewise.
1193 (x86_64-*-linux*): Likewise.
1194 (x86_64-*-mingw*): Likewise.
1195 (x86_64-*-cygwin*): Likewise.
1196
1197 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1198
1199 * tdesc.c: Remove xml parameter.
1200
1201 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1202
1203 * server.c (get_features_xml): Remove cast.
1204 * tdesc.c (void target_desc::accept): Fill in function.
1205 (tdesc_get_features_xml): Remove old xml creation.
1206 (print_xml_feature::visit_pre): Add xml vistor.
1207 * tdesc.h (struct target_desc): Make xmltarget mutable.
1208 (tdesc_get_features_xml): Remove declaration.
1209
1210 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1211
1212 * tdesc.c (tdesc_architecture_name): Add new function.
1213 (tdesc_osabi_name): Likewise.
1214 (tdesc_get_features_xml): Use new functions.
1215
1216 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1217
1218 * tdesc.c (tdesc_create_flags): Remove.
1219 (tdesc_add_flag): Likewise.
1220 (tdesc_named_type): Likewise.
1221 (tdesc_create_union): Likewise.
1222 (tdesc_create_struct): Likewise.
1223 (tdesc_create_vector): Likewise.
1224 (tdesc_add_bitfield): Likewise.
1225 (tdesc_add_field): Likewise.
1226 (tdesc_set_struct_size): Likewise.
1227
1228 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1229
1230 * tdesc.c (~target_desc): Remove implictly deleted items.
1231 (init_target_desc): Iterate all features.
1232 (tdesc_get_features_xml): Use vector.
1233 (tdesc_create_feature): Create feature.
1234 * tdesc.h (tdesc_feature) Remove
1235 (target_desc): Add features.
1236
1237 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1238
1239 * Makefile.in: Add common/tdesc.c
1240 * tdesc.c (init_target_desc): init all reg_defs from register
1241 vector.
1242 (tdesc_create_reg): Create tdesc_reg.
1243 * tdesc.h (tdesc_feature): Add register vector.
1244
1245 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
1246
1247 * tdesc.h (struct target_desc) <features>: Change type to
1248 std::vector<std::string>.
1249 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
1250 changes.
1251 (tdesc_get_features_xml): Likewise.
1252 (tdesc_create_feature): Likewise.
1253
1254 2018-03-26 Alan Hayward <alan.hayward@arm.com>
1255
1256 * regcache.c (find_register_by_number): Return a ref.
1257 (find_regno): Use references.
1258 (register_size): Likewise.
1259 (register_data): Likewise.
1260 * tdesc.c (target_desc::~target_desc): Remove free calls.
1261 (target_desc::operator==): Use std::vector compare.
1262 (init_target_desc): Use reference.
1263 (tdesc_create_reg): Use reg constructors.
1264 * tdesc.h (struct target_desc): Replace pointer with object.
1265
1266 2018-03-23 Alan Hayward <alan.hayward@arm.com>
1267
1268 * regcache.c (find_register_by_number): Make static.
1269 (find_regno): Use find_register_by_number
1270 * regcache.h (struct reg): Remove declaration.
1271
1272 2018-03-23 Alan Hayward <alan.hayward@arm.com>
1273
1274 * tdesc.c (target_desc::~target_desc): Move to here.
1275 (target_desc::operator==): Likewise.
1276 * tdesc.h (target_desc::~target_desc): Move from here.
1277 (target_desc::operator==): Likewise.
1278
1279 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
1280
1281 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
1282
1283 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1284
1285 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
1286 S390_TDESC_GS.
1287 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
1288 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
1289 and init_registers_s390_gs_linux64.
1290
1291 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1292
1293 * linux-s390-low.c (s390_fill_gs): Remove function.
1294 (s390_fill_gsbc): Remove function.
1295 (s390_regsets): Set fill functions for the guarded storage regsets
1296 to NULL.
1297
1298 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1299
1300 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
1301 the word size. Add comment.
1302 (s390_get_wordsize): New function.
1303 (s390_arch_setup): No longer select a temporary tdesc to fetch the
1304 pswm with it. Instead, use s390_get_wordsize to determine the
1305 word size first and derive the correct tdesc from that directly.
1306
1307 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
1308
1309 * Makefile.in: Include silent-rules.mk.
1310 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
1311 (COMPILE): Add ECHO_CXX.
1312 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
1313 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
1314 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
1315 (version-generated.c): Add ECHO_GEN.
1316 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
1317 (IPAGENT_COMPILE): Add ECHO_CXX.
1318 (%-generated.c): Add ECHO_REGDAT.
1319
1320 2018-03-14 Tom Tromey <tom@tromey.com>
1321
1322 PR cli/14977:
1323 * ax.c (ax_printf): Special case for NULL.
1324
1325 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1326
1327 * linux-low.c (linux_qxfer_libraries_svr4): Use
1328 xml_escape_text_append.
1329
1330 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1331
1332 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
1333
1334 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1335
1336 * server.c (handle_general_set): Remove unnecessary xstrdup.
1337
1338 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1339
1340 * server.c (parse_debug_format_options): Adjust to
1341 delim_string_to_char_ptr_vec changes.
1342 * thread-db.c (thread_db_load_search): Adjust to
1343 dirnames_to_char_ptr_vec changes.
1344
1345 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
1346
1347 * target.h (target_enable_btrace, target_disable_btrace)
1348 (target_read_btrace, target_read_btrace_conf): Turn macro into
1349 inline function. Throw error if target method is not defined.
1350 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
1351 check for btrace target method. Be prepared to handle exceptions
1352 from btrace target methods.
1353
1354 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1355
1356 * server.c (captured_main): Change order of error message printed
1357 when the current working directory cannot be found.
1358
1359 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1360
1361 * server.c: Include "filenames.h" and "pathstuff.h".
1362 (program_name): Delete variable.
1363 (program_path): New anonymous class.
1364 (get_exec_wrapper): Use "program_path" instead of
1365 "program_name".
1366 (handle_v_run): Likewise.
1367 (captured_main): Likewise.
1368 (process_serial_event): Likewise.
1369
1370 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1371
1372 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
1373 (OBJS): Add "pathstuff.o".
1374 * server.c (current_directory): New global variable.
1375 (captured_main): Initialize "current_directory".
1376
1377 2018-02-26 Alan Hayward <alan.hayward@arm.com>
1378
1379 * tdesc.c: Use common/tdesc.h.
1380 * tdesc.h: Likewise.
1381
1382 2018-02-20 Alan Hayward <alan.hayward@arm.com>
1383 Simon Marchi <simon.marchi@ericsson.com>
1384
1385 * Makefile.in: Switch order of make rules.
1386
1387 2018-02-19 Alan Hayward <alan.hayward@arm.com>
1388
1389 * Makefile.in: Add common directory in build.
1390 * configure.ac: Add common reference.
1391 * configure: Regenerate.
1392
1393 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1394
1395 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
1396 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
1397 * spu-low.c (spu_target_ops): Likewise.
1398 * win32-low.c (win32_target_ops): Likewise.
1399 * server.c (supported_btrace_packets): Report packets unconditionally.
1400 * target.h (target_ops) <supports_btrace>: Remove.
1401 (target_supports_btrace): Remove.
1402
1403 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1404
1405 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
1406 (handle_btrace_disable): Change return type to void. Use exceptions
1407 to report errors.
1408 (handle_btrace_general_set): Catch exception and copy message to
1409 return message.
1410
1411 2018-02-08 Tom Tromey <tom@tromey.com>
1412
1413 * linux-low.c (install_software_single_step_breakpoints): Use
1414 make_scoped_restore.
1415 * inferiors.c (make_cleanup_restore_current_thread): Remove.
1416 (do_restore_current_thread_cleanup): Remove.
1417 * gdbthread.h (make_cleanup_restore_current_thread): Don't
1418 declare.
1419
1420 2018-02-08 Tom Tromey <tom@tromey.com>
1421
1422 * mem-break.c (set_raw_breakpoint_at): Use
1423 gdb::unique_xmalloc_ptr.
1424
1425 2018-01-30 Pedro Alves <palves@redhat.com>
1426
1427 PR gdb/13211
1428 * target.c (target_terminal::terminal_state): Rename to ...
1429 (target_terminal::m_terminal_state): ... this.
1430
1431 2018-01-19 James Clarke <jrtc27@jrtc27.com>
1432
1433 * linux-low.c (handle_extended_wait): Surround call to
1434 thread_db_notice_clone with #ifdef USE_THREAD_DB.
1435
1436 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
1437
1438 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
1439 linux_ptrace_attach_fail_reason_string now returning an
1440 std::string.
1441 (linux_attach): Likewise.
1442 * thread-db.c (attach_thread): Likewise.
1443
1444 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
1445
1446 PR gdb/21559
1447 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
1448 checking for fs_base/gs_base fields in struct user_regs_struct.
1449 * configure: Regenerate.
1450
1451 2018-01-16 Yao Qi <yao.qi@linaro.org>
1452
1453 PR gdb/18749
1454 * linux-low.c (fetch_register): Call supply_register instead of
1455 error.
1456
1457 2018-01-08 Yao Qi <yao.qi@linaro.org>
1458 Simon Marchi <simon.marchi@ericsson.com>
1459
1460 * Makefile.in (OBS): Remove selftest.o.
1461 * configure.ac: Set srv_selftest_objs if $development is true.
1462 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
1463 * configure: Re-generated.
1464 * server.c (captured_main): Wrap variable selftest_filter with
1465 GDB_SELF_TEST.
1466
1467 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
1468
1469 * server.c (parse_debug_format_options): Return std::string.
1470 (handle_monitor_command, captured_main): Adjust.
1471
1472 2018-01-05 Pedro Alves <palves@redhat.com>
1473
1474 PR gdb/18653
1475 * server.c (captured_main): Pass quiet=false to
1476 save_original_signals_state.
1477
1478 2018-01-01 Joel Brobecker <brobecker@adacore.com>
1479
1480 * gdbreplay.c (gdbreplay_version): Update copyright year in
1481 version message.
1482 * server.c (gdbserver_version): Likewise.
1483
1484 2017-12-08 Tom Tromey <tom@tromey.com>
1485
1486 * ax.c (ax_printf): Update.
1487
1488 2017-12-07 Yao Qi <yao.qi@linaro.org>
1489
1490 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
1491 aarch64_linux_read_description.
1492 * linux-amd64-ipa.c (idx2mask): New array.
1493 (get_ipa_tdesc): Move idx2mask out.
1494 (initialize_low_tracepoint): Initialize target descriptions.
1495 * linux-i386-ipa.c (idx2mask): New array.
1496 (get_ipa_tdesc): Move idx2mask out.
1497 (initialize_low_tracepoint): Initialize target descriptions.
1498
1499 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
1500
1501 * tdesc.c (struct tdesc_type): Change return type.
1502 (tdesc_add_flag): Change parameter type.
1503 (tdesc_add_bitfield): Likewise.
1504 (tdesc_add_field): Likewise.
1505 (tdesc_set_struct_size): Likewise.
1506
1507 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
1508
1509 * regcache.c (registers_to_string): Remove unused variable.
1510
1511 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1512
1513 * inferiors.c (for_each_inferior_with_data): Remove.
1514 * inferiors.h (for_each_inferior_with_data): Remove.
1515 * server.c (handle_qxfer_threads_worker): Change parameter type.
1516 (handle_qxfer_threads_proper): Use for_each_thread.
1517
1518 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1519
1520 * inferiors.c (for_each_inferior): Remove.
1521 (clear_inferiors): Use for_each_thread.
1522 * inferiors.h (for_each_inferior): Remove.
1523 * linux-low.c (linux_wait_for_event_filtered): Use
1524 for_each_thread.
1525 (linux_stabilize_threads): Likewise.
1526 * regcache.c (regcache_release): Likewise.
1527 * server.c (gdb_wants_all_threads_stopped): Likewise.
1528 (clear_pending_status_callback): Remove.
1529 (handle_status): Use for_each_thread.
1530 (captured_main): Likewise.
1531 * win32-low.c (child_init_thread_list): Likewise.
1532 (win32_clear_inferiors): Likewise.
1533 (fake_breakpoint_event): Likewise.
1534
1535 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1536
1537 * inferiors.h (find_inferior): Remove.
1538 * inferiors.c (find_inferior): Remove.
1539
1540 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1541
1542 * linux-low.c (resume_status_pending_p): Update comment.
1543 (need_step_over_p): Update comment.
1544
1545 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1546
1547 * linux-low.c (proceed_one_lwp): Return void, change parameter
1548 type.
1549 (unsuspend_and_proceed_one_lwp): Likewise.
1550 (proceed_all_lwps): Use for_each_thread.
1551 (unstop_all_lwps): Likewise.
1552
1553 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1554
1555 * linux-low.c (linux_resume_one_thread): Return void, take
1556 parameter directly.
1557 (linux_resume): Use for_each_thread.
1558
1559 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1560
1561 * linux-low.c (send_sigstop_callback): Return void, change
1562 parameter type. Rename to...
1563 (send_sigstop): ... this.
1564 (suspend_and_send_sigstop_callback): Return void, change parameter
1565 type. Rename to...
1566 (suspend_and_send_sigstop): ... this.
1567 (stop_all_lwps): Use for_each_thread.
1568
1569 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1570
1571 * linux-low.c (lwp_running): Return bool, remove unused
1572 argument.
1573 (linux_stabilize_threads): Use find_thread.
1574
1575 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1576
1577 * linux-low.c (select_singlestep_lwp_callback): Remove.
1578 (count_events_callback): Remove.
1579 (select_event_lwp_callback): Remove.
1580 (select_event_lwp): Use find_thread/for_each_thread.
1581
1582 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1583
1584 * linux-low.c (not_stopped_callback): Return bool, take filter
1585 argument directly.
1586 (linux_wait_for_event_filtered): Use find_thread.
1587 (linux_wait_1): Likewise.
1588
1589 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1590
1591 * linux-low.c (same_lwp): Remove.
1592 (find_lwp_pid): Use find_thread.
1593
1594 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1595
1596 * linux-low.c (delete_lwp_callback): Remove.
1597 (linux_mourn): Use for_each_thread.
1598
1599 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1600
1601 * linux-low.c (linux_detach_lwp_callback): Return void, remove
1602 args parameter, don't check for pid.
1603 (linux_detach): Use for_each_thread.
1604
1605 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1606
1607 * linux-low.c (struct counter): Remove.
1608 (second_thread_of_pid_p): Remove.
1609 (last_thread_of_process_p): Use find_thread.
1610
1611 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1612
1613 * inferiors.c (find_inferior_in_random): Remove.
1614 * inferiors.h (find_inferior_in_random): Remove.
1615 * linux-low.c (status_pending_p_callback): Return bool, accept
1616 parameter ptid directly.
1617 (linux_wait_for_event_filtered): Use find_thread_in_random.
1618 (linux_wait_1): Likewise.
1619
1620 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1621
1622 * inferiors.c (find_inferior_id): Remove.
1623 (find_thread_ptid): Move implemention from find_inferior_id to
1624 here.
1625 * inferiors.h (find_inferior_id): Remove.
1626 * server.c (handle_status): Use find_thread_ptid.
1627 (process_serial_event): Likewise.
1628 * thread-db.c (find_one_thread): Likewise.
1629 (thread_db_thread_handle): Likewise.
1630 * win32-low.c (thread_rec): Likewise.
1631 (child_delete_thread): Likewise.
1632 (win32_thread_alive): Likewise.
1633 (get_child_debug_event): Likewise.
1634
1635 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1636
1637 * linux-mips-low.c (update_watch_registers_callback): Return
1638 void, remove pid_p parameter, don't check for pid.
1639 (mips_insert_point, mips_remove_point): Use for_each_thread.
1640
1641 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1642
1643 * lynx.low (lynx_delete_thread_callback): Remove.
1644 (lynx_mourn): Use for_each_thread.
1645
1646 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1647
1648 * regcache.c (regcache_invalidate_one): Remove.
1649 (regcache_invalidate_pid): use for_each_thread.
1650
1651 2017-11-26 Tom Tromey <tom@tromey.com>
1652
1653 * linux-low.c (linux_create_inferior): Update.
1654
1655 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
1656
1657 * spu-low.c (spu_create_inferior): Fix typo in argument name.
1658
1659 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1660
1661 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
1662 * linux-aarch64-low.c (initialize_low_arch): Call init func.
1663 * linux-aarch64-tdesc-selftest.c: New file.
1664 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
1665
1666 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1667
1668 * configure.srv: Add new file.
1669 * linux-aarch64-low.c (initialize_low_arch): Call init func.
1670 * linux-aarch64-tdesc-selftest.c: New file.
1671 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
1672
1673 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1674
1675 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
1676 * linux-aarch64-low.c (initialize_low_arch): Remove init.
1677 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
1678
1679 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1680
1681 * configure.srv: Add new files.
1682 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
1683 aarch64_linux_read_description.
1684 * linux-aarch64-low.c (aarch64_linux_read_description):
1685 Merge with aarch64_arch_setup.
1686 (aarch64_arch_setup): Call aarch64_linux_read_description.
1687 * linux-aarch64-tdesc.c: New file.
1688 * linux-aarch64-tdesc.h: New file.
1689
1690 2017-11-24 Yao Qi <yao.qi@linaro.org>
1691
1692 * configure.srv: Set $srv_regobj for tic6x-linux.
1693 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
1694 (tic6x_read_description): Move some code to tic6x_arch_setup.
1695 (tic6x_tdesc_test): New function.
1696 (initialize_low_arch): Call selftests::register_test.
1697
1698 2017-11-22 Yao Qi <yao.qi@linaro.org>
1699
1700 * remote-utils.c (prepare_resume_reply): Use memcpy.
1701
1702 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1703
1704 * linux-low.c (kill_one_lwp_callback): Return void, take
1705 argument directly, don't filter on pid.
1706 (linux_kill): Use for_each_thread.
1707
1708 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1709
1710 * linux-low.c (need_step_over_p): Return bool, remove dummy
1711 argument.
1712 (linux_resume, proceed_all_lwps): Use find_thread.
1713
1714 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1715
1716 * linux-low.c (resume_status_pending_p): Return bool, remove
1717 flag_p argument.
1718 (linux_resume): Use find_thread.
1719
1720 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1721
1722 * linux-low.c (struct thread_resume_array): Remove.
1723 (linux_set_resume_request): Return void, take arguments
1724 directly.
1725 (linux_resume): Use for_each_thread.
1726
1727 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1728
1729 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
1730 return bool, remove data argument.
1731 (linux_stabilize_threads): Use find_thread.
1732
1733 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1734
1735 * linux-low.c (unsuspend_one_lwp): Remove.
1736 (unsuspend_all_lwps): Use for_each_thread, inline code from
1737 unsuspend_one_lwp.
1738
1739 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1740
1741 * gdbthread.h (find_thread): Add overload with ptid_t filter.
1742 * linux-low.c (struct iterate_over_lwps_args): Remove.
1743 (iterate_over_lwps_filter): Remove.
1744 (iterate_over_lwps): Use find_thread.
1745
1746 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1747
1748 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
1749 (linux_handle_new_gdb_connection): Use for_each_thread, inline
1750 code from reset_lwp_ptrace_options_callback.
1751
1752 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1753
1754 * linux-arm-low.c (struct update_registers_data): Remove.
1755 (update_registers_callback): Return void, take arguments
1756 directly, don't check thread's pid.
1757 (arm_insert_point, arm_remove_point): Use for_each_thread.
1758
1759 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1760
1761 * win32-low.c (continue_one_thread): Return void, take argument
1762 directly.
1763 (child_continue): Use for_each_thread.
1764
1765 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1766
1767 * win32-i386-low.c (update_debug_registers_callback): Rename
1768 to ...
1769 (update_debug_registers): ... this, return void, remove pid_p arg.
1770 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
1771
1772 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1773
1774 * inferiors.h (struct process_info): Add constructor, initialize
1775 fields..
1776 <syscalls_to_catch>: Change type to std::vector<int>.
1777 * inferiors.c (add_process): Allocate process_info with new.
1778 (remove_process): Free process_info with delete.
1779 * linux-low.c (handle_extended_wait): Adjust.
1780 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
1781 * server.c (handle_general_set): Adjust.
1782
1783 2017-11-16 Pedro Alves <palves@redhat.com>
1784
1785 * remote-utils.c (remote_close): Block SIGIO signals instead of
1786 uninstalling the SIGIO handler.
1787
1788 2017-11-16 Alan Hayward <alan.hayward@arm.com>
1789
1790 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
1791
1792 2017-11-16 Yao Qi <yao.qi@linaro.org>
1793
1794 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
1795 (tic6x_store_gregset): Likewise.
1796 (tic6x_usrregs_info): Move it up.
1797
1798 2017-11-15 Alan Hayward <alan.hayward@arm.com>
1799
1800 * Makefile.in: Update arch rules.
1801 * configure.srv: Explicitly mark arch/ files.
1802
1803 2017-11-13 Andreas Schwab <schwab@suse.de>
1804
1805 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
1806 function.
1807 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
1808
1809 2017-11-06 Pedro Alves <palves@redhat.com>
1810
1811 * config.in, configure: Regenerate.
1812
1813 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1814
1815 * target.c (struct thread_search): Remove.
1816 (thread_search_callback): Remove.
1817 (prepare_to_access_memory): Use for_each_thread instead of
1818 find_inferior. Inline code from thread_search_callback.
1819
1820 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1821
1822 * server.c (struct visit_actioned_threads_data): Remove.
1823 (visit_actioned_threads): Change prototype to take arguments
1824 directly.
1825 (resume): Use find_thread instead of find_inferior.
1826
1827 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1828
1829 * server.c (queue_stop_reply_callback): Change prototype, return
1830 void.
1831 (find_status_pending_thread_callback): Remove.
1832 (handle_status): Replace find_inferior with find_thread and
1833 for_each_thread.
1834
1835 2017-10-25 Alan Hayward <alan.hayward@arm.com>
1836
1837 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
1838 with REGNO.
1839 (aarch64_store_gregset): Likewise.
1840 (aarch64_fill_fpregset): Likewise.
1841 (aarch64_store_fpregset): Likewise.
1842
1843 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
1844
1845 * gdbthread.h (find_thread, for_each_thread): New functions.
1846 * inferiors.c (thread_of_pid): Remove.
1847 (find_any_thread_of_pid): Use find_thread.
1848 * linux-low.c (num_lwps): Use for_each_thread.
1849
1850 2017-10-17 Yao Qi <yao.qi@linaro.org>
1851
1852 * Makefile.in: Remove one rule.
1853 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
1854
1855 2017-10-17 Yao Qi <yao.qi@linaro.org>
1856
1857 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
1858 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
1859
1860 2017-10-17 Yao Qi <yao.qi@linaro.org>
1861
1862 * configure.srv: Rename arm.o with arch/arm.o.
1863
1864 2017-10-17 Yao Qi <yao.qi@linaro.org>
1865
1866 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
1867 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
1868 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
1869 (arch-i386.o, arch-amd64.o): Remove rules.
1870 (arch/%.o): New rule.
1871 Update POSTCOMPILE and COMPILE.pre.
1872 * configure.ac: Invoke AC_CONFIG_COMMANDS.
1873 * configure: Re-generated.
1874 * configure.srv: Replace arch-i386.o with arch/i386.o.
1875 Replace arch-amd64.o with arch/amd64.o.
1876
1877 2017-10-16 Yao Qi <yao.qi@linaro.org>
1878
1879 * configure: Regenerated.
1880
1881 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1882
1883 * inferiors.h: (struct inferior_list): Remove.
1884 (struct inferior_list_entry); Remove.
1885 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
1886 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
1887 get_first_inferior): Remove.
1888 (for_each_inferior, for_each_inferior_with_data, find_inferior,
1889 find_inferior_id, find_inferior_in_random): Change signature.
1890 * inferiors.c (all_threads): Change type to
1891 std::list<thread_info *>.
1892 (get_thread): Remove macro.
1893 (find_inferior, find_inferior_id): Change signature, implement
1894 using find_thread.
1895 (find_inferior_in_random): Change signature, implement using
1896 find_thread_in_random.
1897 (for_each_inferior, for_each_inferior_with_data): Change
1898 signature, implement using for_each_thread.
1899 (add_inferior_to_list, remove_inferior): Remove.
1900 (add_thread, get_first_thread, thread_of_pid,
1901 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
1902 (get_first_inferior, one_inferior_p, clear_inferior_list):
1903 Remove.
1904 (clear_inferiors, get_thread_process): Update.
1905 * gdbthread.h: Include <list>.
1906 (struct thread_info) <entry>: Remove field.
1907 <id>: New field.
1908 (all_threads): Change type to std::list<thread_info *>.
1909 (get_first_inferior): Add doc.
1910 (find_thread, for_each_thread, find_thread_in_random): New
1911 functions.
1912 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
1913 * linux-arm-low.c (update_registers_callback): Update.
1914 * linux-low.c (second_thread_of_pid_p): Update.
1915 (kill_one_lwp_callback, linux_detach_lwp_callback,
1916 delete_lwp_callback, status_pending_p_callback, same_lwp,
1917 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
1918 iterate_over_lwps, not_stopped_callback,
1919 resume_stopped_resumed_lwps, count_events_callback,
1920 select_singlestep_lwp_callback, select_event_lwp_callback,
1921 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
1922 suspend_and_send_sigstop_callback, wait_for_sigstop,
1923 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
1924 lwp_running, linux_set_resume_request, resume_status_pending_p,
1925 need_step_over_p, start_step_over, linux_resume_one_thread,
1926 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
1927 reset_lwp_ptrace_options_callback): Update.
1928 * linux-mips-low.c (update_watch_registers_callback): Update.
1929 * regcache.c (regcache_invalidate_one, regcache_invalidate):
1930 Update.
1931 (free_register_cache_thread_one): Remove.
1932 (regcache_release): Update.
1933 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
1934 handle_qxfer_threads_worker): Update.
1935 (handle_query): Update, use list iterator.
1936 (visit_actioned_threads, handle_pending_status,
1937 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
1938 clear_pending_status_callback, set_pending_status_callback,
1939 find_status_pending_thread_callback, handle_status,
1940 process_serial_event): Update.
1941 * target.c (thread_search_callback): Update.
1942 * thread-db.c (thread_db_get_tls_address): Update.
1943 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
1944 Update.
1945 * win32-i386-low.c (update_debug_registers_callback): Update.
1946 * win32-low.c (delete_thread_info, child_delete_thread,
1947 continue_one_thread, suspend_one_thread,
1948 get_child_debug_event): Adjust.
1949
1950 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1951
1952 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
1953 * inferiors.h: Include <list>.
1954 (struct process_info) <entry>: Remove field.
1955 <pid>: New field.
1956 (pid_of): Change macro to function.
1957 (ptid_of, lwpid_of): Remove macro.
1958 (all_processes): Change type to std::list<process_info *>.
1959 (ALL_PROCESSES): Remove macro.
1960 (for_each_process, find_process): New function.
1961 * inferiors.c (all_processes): Change type to
1962 std::list<process_info *>.
1963 (find_thread_process): Adjust.
1964 (add_process): Likewise.
1965 (remove_process): Likewise.
1966 (find_process_pid): Likewise.
1967 (get_first_process): Likewise.
1968 (started_inferior_callback): Remove.
1969 (have_started_inferiors_p): Adjust.
1970 (attached_inferior_callback): Remove.
1971 (have_attached_inferiors_p): Adjust.
1972 * linux-low.c (check_zombie_leaders): Likewise.
1973 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
1974 (x86_linux_update_xmltarget): Adjust.
1975 * server.c (handle_query): Likewise.
1976 (gdb_reattached_process): Remove.
1977 (handle_status): Adjust.
1978 (kill_inferior_callback): Likewise.
1979 (detach_or_kill_inferior): Remove.
1980 (print_started_pid): Likewise.
1981 (print_attached_pid): Likewise.
1982 (detach_or_kill_for_exit): Update.
1983 (process_serial_event): Likewise.
1984 * linux-arm-low.c (arm_new_fork): Likewise.
1985
1986 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1987
1988 * dll.h: Include <list>.
1989 (struct dll_info): Add constructor.
1990 <entry>: Remove field.
1991 (all_dlls): Change type to std::list<dll_info>.
1992 * dll.c: Include <algorithm>.
1993 (get_dll): Remove macro.
1994 (all_dlls): Change type to std::list<dll_info *>.
1995 (free_one_dll): Remove.
1996 (match_dll): Likewise.
1997 (loaded_dll): Adjust.
1998 (unloaded_dll): Adjust to all_dlls type change, use
1999 std::find_if. Inline code from match_dll.
2000 (clear_dlls): Adjust to all_dlls type change.
2001 * server.c (emit_dll_description): Remove.
2002 (handle_qxfer_libraries): Adjust to all_dlls type change,
2003 integrate emit_dll_description's functionality.
2004
2005 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2006
2007 * linux-low.h (struct linux_target_ops) <delete_process>: New
2008 field.
2009 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
2010 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
2011 (struct linux_target_ops): Add delete_process callback.
2012 * linux-arm-low.c (arm_delete_process): New.
2013 (struct linux_target_ops): Add delete_process callback.
2014 * linux-bfin-low.c (struct linux_target_ops): Likewise.
2015 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
2016 * linux-m32r-low.c (struct linux_target_ops): Likewise.
2017 * linux-mips-low.c (mips_linux_delete_process): New.
2018 (struct linux_target_ops): Add delete_process callback.
2019 * linux-ppc-low.c (struct linux_target_ops): Likewise.
2020 * linux-s390-low.c (struct linux_target_ops): Likewise.
2021 * linux-sh-low.c (struct linux_target_ops): Likewise.
2022 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
2023 * linux-tile-low.c (struct linux_target_ops): Likewise.
2024 * linux-x86-low.c (x86_linux_delete_process): New.
2025 (struct linux_target_ops): Add delete_process callback.
2026 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
2027
2028 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2029
2030 * linux-aarch64-low.c (the_low_target): Add thread delete
2031 callback.
2032 * linux-arm-low.c (arm_delete_thread): New function.
2033 (the_low_target): Add thread delete callback.
2034 * linux-bfin-low.c (the_low_target): Likewise.
2035 * linux-crisv32-low.c (the_low_target): Likewise.
2036 * linux-low.c (delete_lwp): Invoke delete_thread callback if
2037 set.
2038 * linux-low.h (struct linux_target_ops) <delete_thread>: New
2039 field.
2040 * linux-m32r-low.c (the_low_target): Add thread delete callback.
2041 * linux-mips-low.c (mips_linux_delete_thread): New function.
2042 (the_low_target): Add thread delete callback.
2043 * linux-ppc-low.c (the_low_target): Likewise.
2044 * linux-s390-low.c (the_low_target): Likewise.
2045 * linux-sh-low.c (the_low_target): Likewise.
2046 * linux-tic6x-low.c (the_low_target): Likewise.
2047 * linux-tile-low.c (the_low_target): Likewise.
2048 * linux-x86-low.c (the_low_target): Likewise.
2049 * linux-xtensa-low.c (the_low_target): Likewise.
2050
2051 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
2052
2053 * win32-low.c: Include "common-inferior.h".
2054
2055 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2056
2057 * inferiors.c (set_inferior_cwd): New function.
2058 * server.c (handle_general_set): Handle QSetWorkingDir packet.
2059 (handle_query): Inform that QSetWorkingDir is supported.
2060 * win32-low.c (create_process): Pass the inferior's cwd to
2061 CreateProcess.
2062
2063 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2064
2065 * inferiors.c (current_inferior_cwd): New global variable.
2066 (get_inferior_cwd): New function.
2067 * inferiors.h (struct process_info) <cwd>: New field.
2068
2069 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2070
2071 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
2072 (OBS): Add gdb_tilde_expand.o.
2073
2074 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
2075
2076 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
2077 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
2078
2079 2017-09-29 Pedro Alves <palves@redhat.com>
2080
2081 * ax.c (gdb_parse_agent_expr): Constify.
2082 * ax.h (gdb_parse_agent_expr): Constify.
2083 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
2084 Constify.
2085 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
2086 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
2087 * remote-utils.h (read_ptid): Constify.
2088 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
2089 (process_point_options, process_serial_event): Constify.
2090 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
2091 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
2092 (cmd_qtbuffer): Constify.
2093
2094 2017-09-29 Pedro Alves <palves@redhat.com>
2095
2096 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
2097 fails.
2098
2099 2017-09-29 Pedro Alves <palves@redhat.com>
2100
2101 * linux-low.c (handle_extended_wait): Pass parent thread instead
2102 of process to thread_db_notice_clone.
2103 * linux-low.h (thread_db_notice_clone): Replace parent process
2104 parameter with parent thread parameter.
2105 * thread-db.c (find_one_thread): Add comment.
2106 (thread_db_notice_clone): Replace parent process parameter with
2107 parent thread parameter. Temporarily switch to the parent thread.
2108
2109 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
2110
2111 * gdbthread.h: Include "common-gdbthread.h".
2112 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
2113 "if" when validating the ptid.
2114 * remote-utils.c: Include "gdbthread.h".
2115 (prepare_resume_reply): Use "switch_to_thread".
2116 * target.c (done_accessing_memory): Likewise.
2117
2118 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
2119
2120 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
2121 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
2122 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
2123 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
2124 s390x-gs-linux64-ipa.o to ipa_obj.
2125 * linux-s390-low.c (HWCAP_S390_GS): New define.
2126 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
2127 New functions.
2128 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
2129 (s390_arch_setup): Check for guarded-storage support and choose
2130 appropriate tdesc.
2131 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
2132 init_registers_s390x_gs_linux64.
2133 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
2134 enum value.
2135 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
2136 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
2137
2138 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
2139
2140 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
2141
2142 2017-09-21 Kevin Buettner <kevinb@redhat.com>
2143
2144 * linux-low.h (struct lwp_info): Add new field, thread_handle.
2145 (thread_db_thread_handle): Declare.
2146 * linux-low.c (linux_target_ops): Initialize thread_handle.
2147 * server.c (handle_qxfer_threads_worker): Add support for
2148 "handle" attribute.
2149 * target.h (struct target_ops): Add new function pointer,
2150 thread_handle.
2151 (target_thread_handle): Define.
2152 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
2153 field in lwp.
2154 (thread_db_thread_handle): New function.
2155
2156 2017-09-21 Kevin Buettner <kevinb@redhat.com>
2157
2158 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
2159 * linux-low.h (thread_db_notice_clone): Declare.
2160 * thread-db.c (thread_db_notice_clone): New function.
2161
2162 2017-09-21 Pedro Alves <palves@redhat.com>
2163
2164 * server.c (gdb_read_memory, handle_status, process_serial_event)
2165 (handle_serial_event, handle_target_event): Adjust to
2166 set_desired_thread prototype change.
2167 * target.c (set_desired_thread): Remove 'use_general' parameter
2168 and adjust.
2169 * target.h (set_desired_thread): Remove 'use_general' parameter.
2170
2171 2017-09-20 Tom Tromey <tom@tromey.com>
2172
2173 * target.c (target_terminal::terminal_state): Define.
2174 (target_terminal::init): Rename from target_terminal_init.
2175 (target_terminal::inferior): Rename from
2176 target_terminal_inferior.
2177 (target_terminal::ours): Rename from target_terminal_ours.
2178 (target_terminal::ours_for_output, target_terminal::info): New.
2179
2180 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2181
2182 * server.c (accumulate_file_name_length): Remove.
2183 (emit_dll_description): Adjust to std::string change.
2184 (handle_qxfer_libraries): Use std::string to hold document.
2185
2186 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2187
2188 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
2189 return type of xml_escape_text.
2190 * server.c (emit_dll_description): Likewise.
2191
2192 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2193
2194 * server.c (captured_main): Accept argument for --selftest.
2195 Update run_tests call.
2196 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
2197 when registering selftests.
2198
2199 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
2200
2201 * regcache.c (get_thread_regcache): Update code to use "std::vector"
2202 instead of "VEC" for "target_desc.reg_defs".
2203 (regcache_cpy): Likewise.
2204 (registers_to_string): Likewise.
2205 (registers_from_string): Likewise.
2206 (find_regno): Likewise.
2207 (supply_regblock): Likewise.
2208 (regcache_raw_read_unsigned): Likewise.
2209 * tdesc.c (init_target_desc): Likewise.
2210 (tdesc_create_reg): Likewise.
2211 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
2212 (struct target_desc) <reg_defs>: Convert to "std::vector".
2213 (target_desc): Do not initialize "reg_defs".
2214 (~target_desc): Update code to use "std::vector" instead of "VEC"
2215 for "target_desc.reg_defs".
2216 (operator==): Likewise.
2217
2218 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2219
2220 * inferiors.h (thread_to_gdb_id): Remove.
2221 * inferiors.c (thread_to_gdb_id): Remove.
2222 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
2223 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
2224 lynx_store_registers, lynx_read_memory, lynx_write_memory):
2225 Likewise.
2226 * nto-low.c (nto_fetch_registers, nto_store_registers,
2227 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
2228
2229 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2230
2231 * inferiors.h (gdb_id_to_thread_id): Remove.
2232 * inferiors.c (gdb_id_to_thread_id): Remove.
2233 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
2234 removal. Move pid declaration closer to where it's used.
2235
2236 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2237
2238 * server.c (handle_detach): New function.
2239 (process_serial_event): Move code out, call handle_detach.
2240
2241 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2242
2243 * server.c (require_running): Rename to ...
2244 (require_running_or_return): ... this ...
2245 (require_running_or_break): ... and this.
2246 (handle_query, process_serial_event): Adjust.
2247
2248 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2249
2250 * linux-low.c (linux_set_resume_request): Remove unused
2251 variables.
2252
2253 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2254
2255 * server.c (first_thread_of): Remove.
2256 (process_serial_event): Replace usage of first_thread_of with
2257 find_any_thread_of_pid.
2258 * tracepoint.c (same_process_p): Remove.
2259 (gdb_agent_about_to_close): Replace usage of same_process_p with
2260 find_any_thread_of_pid.
2261 * linux-x86-low.c (same_process_callback): Remove.
2262 (x86_arch_setup_process_callback): Replace usage of
2263 same_process_callback with find_any_thread_of_pid.
2264 * thread-db.c (any_thread_of): Remove.
2265 (switch_to_process): Replace usage of any_thread_of with
2266 find_any_thread_of_pid.
2267 * inferiors.c (thread_pid_matches_callback): Remove.
2268 (find_thread_process): Adjust to use find_any_thread_of_pid.
2269
2270 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
2271
2272 * regcache.c (get_thread_regcache): Guard calls to "memset"
2273 with "!VEC_empty".
2274
2275 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
2276
2277 * linux-low.c (handle_extended_wait): Use
2278 "allocate_target_description" instead of "XNEW".
2279 * linux-x86-low.c (initialize_low_arch): Likewise.
2280
2281 2017-09-05 Yao Qi <yao.qi@linaro.org>
2282
2283 * configure.srv (srv_i386_regobj): Remove.
2284 (srv_amd64_regobj): Remove.
2285 (srv_regobj): Set it to "" for x86 non-linux targets.
2286 * linux-x86-tdesc.c (i386_linux_read_description):
2287 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
2288 (init_registers_i386): Remove the declaration.
2289 (tdesc_i386): Remove the declaration.
2290 (lynx_i386_arch_setup): Call i386_create_target_description.
2291 * nto-x86-low.c: Likewise.
2292 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
2293 [!__x86_64__]: include arch/i386.h.
2294 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
2295
2296 2017-09-05 Yao Qi <yao.qi@linaro.org>
2297
2298 * configure.srv (srv_amd64_linux_xmlfiles): Remove
2299 i386/amd64-XXX-linux from it.
2300
2301 2017-09-05 Yao Qi <yao.qi@linaro.org>
2302
2303 * configure.srv: Empty srv_amd64_linux_regobj if $development is
2304 false.
2305 (ipa_amd64_linux_regobj): Remove.
2306 (ipa_x32_linux_regobj): Remove.
2307
2308 2017-09-05 Yao Qi <yao.qi@linaro.org>
2309
2310 * Makefile.in (arch-amd64.o): New rule.
2311 * configure.srv: Append arch-amd64.o.
2312 * linux-amd64-ipa.c: Include common/x86-xstate.h.
2313 (get_ipa_tdesc): Call amd64_linux_read_description.
2314 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
2315 and init_registers_amd64_XXX.
2316 * linux-x86-low.c (x86_linux_read_description): Call
2317 amd64_linux_read_description.
2318 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
2319 (initialize_low_arch): Don't call init_registers_x32_XXX and
2320 init_registers_amd64_XXX.
2321 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
2322 and tdesc_amd64_XXX.
2323 [__x86_64__] (amd64_tdesc_test): New function.
2324 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
2325 and init_registers_amd64_XXX.
2326 * linux-x86-tdesc.c: Include arch/amd64.h.
2327 (xcr0_to_tdesc_idx): New function.
2328 (i386_linux_read_description): New function.
2329 (amd64_get_ipa_tdesc_idx): New function.
2330 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
2331 (amd64_get_ipa_tdesc): Declare.
2332
2333 2017-09-05 Yao Qi <yao.qi@linaro.org>
2334
2335 * configure.srv (srv_i386_linux_xmlfiles): Remove
2336 i386/i386-XXX-linux.xml from it.
2337
2338 2017-09-05 Yao Qi <yao.qi@linaro.org>
2339
2340 * configure.srv: Set srv_i386_linux_regobj empty if $development
2341 is false.
2342 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
2343 initialize_low_tdesc.
2344 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
2345 with #if initialize_low_tdesc.
2346 * linux-x86-tdesc-selftest.c: New file.
2347 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
2348
2349 2017-09-05 Yao Qi <yao.qi@linaro.org>
2350
2351 * Makefile.in (arch-i386.o): New rule.
2352 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
2353 (x86_64-*-linux*): Likewise.
2354 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
2355 include arch/i386.h.
2356 (i386_linux_read_description): Remove code and call
2357 i386_create_target_description.
2358 * tdesc.c (allocate_target_description): New function.
2359 * tdesc.h (set_tdesc_architecture): Remove declaration.
2360 (set_tdesc_osabi): Likewise.
2361
2362 2017-09-05 Yao Qi <yao.qi@linaro.org>
2363
2364 * linux-x86-tdesc.c: Don't include <inttypes.h>.
2365 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
2366 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
2367 .xmltarget.
2368 * server.c (get_features_xml): Call tdesc_get_features_xml.
2369 * tdesc.c (set_tdesc_architecture): New function.
2370 (set_tdesc_osabi): New function.
2371 (tdesc_get_features_xml): New function.
2372 (tdesc_create_feature): Add an argument.
2373 * tdesc.h (struct target_desc) <features>: New field.
2374 <arch, osabi>: New field.
2375 (~target_desc): xfree features, arch, and osabi.
2376 (target_desc::oerator==): Don't compare .xmltarget.
2377 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
2378 (set_tdesc_osabi): Likewise.
2379 (tdesc_get_features_xml): Likewise.
2380
2381 2017-09-05 Yao Qi <yao.qi@linaro.org>
2382
2383 * linux-x86-tdesc.c: Include selftest.h.
2384 (i386_tdesc_test): New function.
2385 (initialize_low_tdesc): Call selftests::register_test.
2386 * tdesc.h: Include regdef.h.
2387 (target_desc): Override operator == and !=.
2388
2389 2017-09-05 Yao Qi <yao.qi@linaro.org>
2390
2391 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
2392 (ipa_obj): Likewise.
2393 * linux-i386-ipa.c: Include common/x86-xstate.h
2394 (get_ipa_tdesc): Call i386_linux_read_description.
2395 (initialize_low_tracepoint): Don't call init_registers_XXX
2396 functions, call initialize_low_tdesc instead.
2397 * linux-x86-low.c (x86_linux_read_description): Call
2398 i386_linux_read_description.
2399 (initialize_low_arch): Don't call init_registers_i386_XXX
2400 functions, call initialize_low_tdesc.
2401 * linux-x86-tdesc.c: New file.
2402 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
2403 (i386_get_ipa_tdesc_idx): Declare.
2404 (i386_get_ipa_tdesc): Declare.
2405 (initialize_low_tdesc): Declare.
2406
2407 2017-09-05 Yao Qi <yao.qi@linaro.org>
2408
2409 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
2410 instead of 0.
2411
2412 2017-09-05 Yao Qi <yao.qi@linaro.org>
2413
2414 * Makefile.in (IPA_OBJS): Add vec-ipa.o
2415 * regcache.c (get_thread_regcache): Use VEC_length.
2416 (init_register_cache): Likewise.
2417 (regcache_cpy): Likewise.
2418 (registers_to_string): Iterate reg_defs via VEC_iterate.
2419 (find_regno): Likewise.
2420 (find_register_by_number): Use VEC_index.
2421 (register_size): Call find_register_by_number.
2422 (register_data): Call find_register_by_number.
2423 (supply_regblock): Use VEC_length.
2424 (regcache_raw_read_unsigned): Likewise.
2425 * tdesc.c (init_target_desc): Iterate reg_defs via
2426 VEC_iterate.
2427 (default_description): Update initializer.
2428 (copy_target_description): Don't update field num_registers.
2429 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
2430 <num_registers>: Remove.
2431
2432 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2433
2434 * Makefile.in (.SECONDARY): Define target.
2435
2436 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
2437
2438 * linux-low.c (linux_wait_1): Adjust.
2439 * server.c (queue_stop_reply_callback): Adjust.
2440
2441 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
2442
2443 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
2444 QEnvironmentUnset and QEnvironmentReset packets.
2445 (handle_query): Inform remote that QEnvironmentHexEncoded,
2446 QEnvironmentUnset and QEnvironmentReset are supported.
2447
2448 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
2449
2450 * inferiors.h (inferior_target_data): Rename to ...
2451 (thread_target_data): ... this.
2452 (inferior_regcache_data): Rename to ...
2453 (thread_regcache_data): ... this.
2454 (set_inferior_regcache_data): Rename to ...
2455 (set_thread_regcache_data): ... this.
2456 * inferiors.c (inferior_target_data): Rename to ...
2457 (thread_target_data): ... this.
2458 (inferior_regcache_data): Rename to ...
2459 (thread_regcache_data): ... this.
2460 (set_inferior_regcache_data): Rename to ...
2461 (set_thread_regcache_data): ... this.
2462 (free_one_thread): Update.
2463 * linux-low.h (get_thread_lwp): Update.
2464 * regcache.c (get_thread_regcache): Update.
2465 (regcache_invalidate_thread): Update.
2466 (free_register_cache_thread): Update.
2467 * win32-i386-low.c (update_debug_registers_callback): Update.
2468 (win32_get_current_dr): Update.
2469 * win32-low.c (thread_rec): Update.
2470 (delete_thread_info): Update.
2471 (continue_one_thread): Update.
2472 (suspend_one_thread): Update.
2473
2474 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
2475
2476 * inferiors.c (set_inferior_target_data): Remove.
2477 * inferiors.h (set_inferior_target_data): Remove.
2478
2479 2017-08-18 Yao Qi <yao.qi@linaro.org>
2480
2481 * Makefile.in (OBS): Add selftest.o.
2482 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
2483 * configure, config.in: Re-generated.
2484 * server.c: Include common/sefltest.h.
2485 (captured_main): Handle option --selftest.
2486
2487 2017-08-09 Yao Qi <yao.qi@linaro.org>
2488
2489 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
2490 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
2491 i386-avx-mpx.o and i386-mmx.o.
2492 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
2493 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
2494 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
2495 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
2496 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
2497 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
2498 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
2499 i386/amd64-avx-mpx.xml.
2500
2501 2017-08-09 Yao Qi <yao.qi@linaro.org>
2502
2503 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
2504 and x32-avx-avx512.o.
2505 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
2506 i386/x32-avx-avx512.xml.
2507
2508 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
2509
2510 * tracepoint.h (enum class fast_tpoint_collect_result): New
2511 enumeration.
2512 (fast_tracepoint_collecting): Change return type to
2513 fast_tpoint_collect_result.
2514 * tracepoint.c (fast_tracepoint_collecting): Likewise.
2515 * linux-low.h: Include tracepoint.h.
2516 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
2517 fast_tpoint_collect_result.
2518 * linux-low.c (handle_tracepoints): Adjust.
2519 (linux_fast_tracepoint_collecting): Change return type to
2520 fast_tpoint_collect_result.
2521 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
2522 linux_wait_1, stuck_in_jump_pad_callback,
2523 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
2524 proceed_one_lwp): Adjust to type change.
2525
2526 2017-07-10 Yao Qi <yao.qi@linaro.org>
2527
2528 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
2529
2530 2017-06-29 Yao Qi <yao.qi@linaro.org>
2531
2532 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
2533 Remove.
2534 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
2535
2536 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
2537
2538 * Makefile.in (IPA_OBJS): Sort and format one item per line.
2539
2540 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
2541
2542 * linux-low.c (linux_create_inferior): Adjust code to access the
2543 environment information via 'gdb_environ' class.
2544 * lynx-low.c (lynx_create_inferior): Likewise.
2545 * server.c (our_environ): Make it an instance of 'gdb_environ'.
2546 (get_environ): Return a pointer to 'our_environ'.
2547 (captured_main): Initialize 'our_environ'.
2548 * server.h (get_environ): Adjust prototype.
2549 * spu-low.c (spu_create_inferior): Adjust code to access the
2550 environment information via 'gdb_environ' class.
2551
2552 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2553
2554 * linux-low.c (linux_read_memory, linux_write_memory): Remove
2555 usage of "register" keyword.
2556
2557 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2558
2559 * configure: Re-generate.
2560
2561 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2562
2563 * configure: Re-generate.
2564
2565 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2566
2567 * Makefile.in (COMPILE.pre): Add "-x c++".
2568
2569 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
2570
2571 * fork-child.c: Conditionally include <signal.h>.
2572
2573 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2574
2575 * server.c (handle_general_set): Handle new packet
2576 "QStartupWithShell".
2577 (handle_query): Add "QStartupWithShell" to the list of supported
2578 packets.
2579 (gdbserver_usage): Add help text explaining the
2580 new "--startup-with-shell" and "--no-startup-with-shell" CLI
2581 options.
2582 (captured_main): Recognize and act upon the presence of the new
2583 CLI options.
2584
2585 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2586 Pedro Alves <palves@redhat.com>
2587
2588 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
2589 * configure: Regenerate.
2590 * configure.srv (srv_linux_obj): Add "fork-child.o" and
2591 "fork-inferior.o".
2592 (i[34567]86-*-lynxos*): Likewise.
2593 (spu*-*-*): Likewise.
2594 * fork-child.c: New file.
2595 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
2596 and "environ.h".
2597 (linux_ptrace_fun): New function.
2598 (linux_create_inferior): Adjust function prototype to reflect
2599 change on "target.h". Adjust function code to use
2600 "fork_inferior".
2601 (linux_request_interrupt): Delete "signal_pid".
2602 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
2603 (lynx_ptrace_fun): New function.
2604 (lynx_create_inferior): Adjust function prototype to reflect
2605 change on "target.h". Adjust function code to use
2606 "fork_inferior".
2607 * nto-low.c (nto_create_inferior): Adjust function prototype and
2608 code to reflect change on "target.h". Update comments.
2609 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
2610 "common-terminal.h" and "environ.h".
2611 (terminal_fd): Moved to fork-child.c.
2612 (old_foreground_pgrp): Likewise.
2613 (restore_old_foreground_pgrp): Likewise.
2614 (last_status): Make it global.
2615 (last_ptid): Likewise.
2616 (our_environ): New variable.
2617 (startup_with_shell): Likewise.
2618 (program_name): Likewise.
2619 (program_argv): Rename to...
2620 (program_args): ...this.
2621 (wrapper_argv): New variable.
2622 (start_inferior): Delete function.
2623 (get_exec_wrapper): New function.
2624 (get_exec_file): Likewise.
2625 (get_environ): Likewise.
2626 (prefork_hook): Likewise.
2627 (post_fork_inferior): Likewise.
2628 (postfork_hook): Likewise.
2629 (postfork_child_hook): Likewise.
2630 (handle_v_run): Update code to deal with arguments coming from the
2631 remote host. Update calls from "start_inferior" to
2632 "create_inferior".
2633 (captured_main): Likewise. Initialize environment variable. Call
2634 "have_job_control".
2635 * server.h (post_fork_inferior): New prototype.
2636 (get_environ): Likewise.
2637 (last_status): Declare.
2638 (last_ptid): Likewise.
2639 (signal_pid): Likewise.
2640 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
2641 (spu_ptrace_fun): New function.
2642 (spu_create_inferior): Adjust function prototype to reflect change
2643 on "target.h". Adjust function code to use "fork_inferior".
2644 * target.c (target_terminal_init): New function.
2645 (target_terminal_inferior): Likewise.
2646 (target_terminal_ours): Likewise.
2647 * target.h: Include <vector>.
2648 (struct target_ops) <create_inferior>: Update prototype.
2649 (create_inferior): Update macro.
2650 * utils.c (gdb_flush_out_err): New function.
2651 * win32-low.c (win32_create_inferior): Adjust function prototype
2652 and code to reflect change on "target.h".
2653
2654 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2655
2656 * inferiors.c (switch_to_thread): New function.
2657
2658 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2659
2660 * Makefile.in (SFILE): Add "common/job-control.c".
2661 (OBS): Add "job-control.o".
2662
2663 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
2664
2665 * Makefile: Remove "@host_makefile_frag@".
2666
2667 2017-05-05 Pedro Alves <palves@redhat.com>
2668
2669 * configure: Regenerate.
2670
2671 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
2672
2673 * configure: Regenerate.
2674
2675 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
2676
2677 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
2678 software_single_step change of return type to
2679 std::vector<CORE_ADDR>.
2680 * linux-low.c (install_software_single_step_breakpoints):
2681 Likewise.
2682 * linux-low.h (install_software_single_step_breakpoints):
2683 Likewise.
2684
2685 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
2686
2687 * remote-utils.c: Include "gdb_termios.h" instead of
2688 "terminal.h".
2689 * terminal.h: Delete file.
2690
2691 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
2692
2693 * server.c: Include <vector>.
2694 <program_argv, wrapper_argv>: Convert to std::vector.
2695 (start_inferior): Rewrite function to use C++.
2696 (handle_v_run): Likewise. Update code that calculates the argv
2697 based on the vRun packet; use C++.
2698 (captured_main): Likewise.
2699
2700 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
2701
2702 * server.c (handle_v_cont): Initialize thread_resume::thread
2703 with null_ptid.
2704
2705 2017-04-05 Pedro Alves <palves@redhat.com>
2706
2707 * configure: Regenerate.
2708
2709 2017-04-05 Pedro Alves <palves@redhat.com>
2710
2711 * gdbreplay.c (sync_error): Constify.
2712 * linux-x86-low.c (push_opcode): Constify.
2713
2714 2017-04-05 Pedro Alves <palves@redhat.com>
2715
2716 * win32-low.c (get_child_debug_event)
2717 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
2718 Report TARGET_WAITKIND_SPURIOUS instead.
2719
2720 2017-04-05 Pedro Alves <palves@redhat.com>
2721
2722 * remote-utils.c (remote_prepare, remote_open): Constify.
2723 * remote-utils.h (remote_prepare, remote_open): Constify.
2724 * server.c (captured_main): Constify 'port' handling.
2725
2726 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
2727
2728 * Makefile.in (clean): Clear .deps.
2729
2730 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
2731
2732 * .gitignore: Remove generated files, replace with wildcard.
2733 * (clean): Replace removal of generated files with wildcard.
2734 (version.c): Replace with...
2735 (version-generated.c): ...this.
2736 (xml-builtin.c): Replace with...
2737 (xml-builtin-generated.c): ...this.
2738 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
2739 (%.c: *regformats*): Replace with...
2740 (%-generated.c: *regformats*): ...this.
2741
2742 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
2743
2744 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
2745 (xtensa_fill_gregset): Call collect_register_by_name for
2746 threadptr register.
2747 (xtensa_store_gregset): Call supply_register_by_name for
2748 threadptr register.
2749
2750 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
2751
2752 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
2753 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
2754 (xtensa_store_gregset): Call supply_register for all registers in
2755 a0_regnum..a0_regnum + C0_NREGS range.
2756
2757 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2758
2759 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
2760 (ax-ipa.o: ax.c): Remove.
2761 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
2762 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
2763 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
2764 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
2765 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
2766
2767 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2768
2769 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
2770 (print-utils-ipa.o: ../common/print-utils.c): Remove.
2771 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
2772 (errors-ipa.o: ../common/errors.c): Remove.
2773 (format-ipa.o: ../common/format.c): Remove.
2774 (common-utils-ipa.o: ../common/common-utils.c): Remove.
2775
2776 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2777
2778 * Makefile.in (%-ipa.o: %.c): New rule.
2779 (tracepoint-ipa.o: tracepoint.c): Remove.
2780 (utils-ipa.o: utils.c): Remove.
2781 (remote-utils-ipa.o: remote-utils.c): Remove.
2782 (regcache-ipa.o: regcache.c): Remove.
2783 (i386-linux-ipa.o: i386-linux.c): Remove.
2784 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
2785 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
2786 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
2787 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
2788 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
2789 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
2790 (amd64-linux-ipa.o: amd64-linux.c): Remove.
2791 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
2792 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
2793 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
2794 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
2795 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
2796 (aarch64-ipa.o: aarch64.c): Remove.
2797 (s390-linux32-ipa.o: s390-linux32.c): Remove.
2798 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
2799 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
2800 (s390-linux64-ipa.o: s390-linux64.c): Remove.
2801 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
2802 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
2803 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
2804 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
2805 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
2806 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
2807 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
2808 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
2809 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
2810 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
2811 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
2812 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
2813 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
2814 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
2815 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
2816 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
2817 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
2818 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
2819 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
2820 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
2821 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
2822 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
2823 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
2824 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
2825 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
2826 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
2827 (tdesc-ipa.o: tdesc.c): Remove.
2828 (x32-linux-ipa.o: x32-linux.c): Remove.
2829 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
2830 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
2831
2832 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2833
2834 * Makefile.in (%.o: ../arch/%.c): New rule.
2835 (arm.o: ../arch/arm.c): Remove.
2836 (arm-linux.o: ../arch/arm-linux.c): Remove.
2837 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
2838 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
2839
2840 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2841
2842 * Makefile.in (%.o: ../nat/%.c): New rule.
2843 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
2844 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
2845 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
2846 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
2847 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
2848 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
2849 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
2850 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
2851 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
2852 (linux-personality.o: ../nat/linux-personality.c): Remove.
2853 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
2854 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
2855 (x86-linux.o: ../nat/x86-linux.c): Remove.
2856 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
2857 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
2858
2859 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2860
2861 * Makefile.in (%.o: ../common/%.c): New rule.
2862 (signals.o: ../common/signals.c): Remove.
2863 (print-utils.o: ../common/print-utils.c): Remove.
2864 (rsp-low.o: ../common/rsp-low.c): Remove.
2865 (common-utils.o: ../common/common-utils.c): Remove.
2866 (posix-strerror.o: ../common/posix-strerror.c): Remove.
2867 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
2868 (vec.o: ../common/vec.c): Remove.
2869 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
2870 (xml-utils.o: ../common/xml-utils.c): Remove.
2871 (ptid.o: ../common/ptid.c): Remove.
2872 (buffer.o: ../common/buffer.c): Remove.
2873 (format.o: ../common/format.c): Remove.
2874 (filestuff.o: ../common/filestuff.c): Remove.
2875 (agent.o: ../common/agent.c): Remove.
2876 (errors.o: ../common/errors.c): Remove.
2877 (environ.o: ../common/environ.c): Remove.
2878 (common-debug.o: ../common/common-debug.c): Remove.
2879 (cleanups.o: ../common/cleanups.c): Remove.
2880 (common-exceptions.o: ../common/common-exceptions.c): Remove.
2881 (fileio.o: ../common/fileio.c): Remove.
2882 (common-regcache.o: ../common/common-regcache.c): Remove.
2883 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
2884 (new-op.o: ../common/new-op.c): Remove.
2885 (btrace-common.o: ../common/btrace-common.c): Remove.
2886
2887 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2888
2889 * Makefile.in (%.o: ../target/%.c): New rule.
2890 (waitstatus.o: ../target/waitstatus.c): Remove.
2891
2892 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2893
2894 * Makefile.in
2895 (%.c: ../regformats/%.dat,
2896 (%.c: ../regformats/arm/%.dat,
2897 (%.c: ../regformats/i386/%.dat,
2898 (%.c: ../regformats/rs6000/%.dat): New rules.
2899 (aarch64.c): Remove.
2900 (reg-arm.c): Remove.
2901 (arm-with-iwmmxt.c): Remove.
2902 (arm-with-vfpv2.c): Remove.
2903 (arm-with-vfpv3.c): Remove.
2904 (arm-with-neon.c): Remove.
2905 (reg-bfin.c): Remove.
2906 (reg-cris.c): Remove.
2907 (reg-crisv32.c): Remove.
2908 (i386.c): Remove.
2909 (i386-linux.c): Remove.
2910 (i386-avx.c): Remove.
2911 (i386-avx-linux.c): Remove.
2912 (i386-avx-avx512.c): Remove.
2913 (i386-avx-avx512-linux.c): Remove.
2914 (i386-mpx.c): Remove.
2915 (i386-mpx-linux.c): Remove.
2916 (i386-avx-mpx-avx512-pku.c): Remove.
2917 (i386-avx-mpx-avx512-pku-linux.c): Remove.
2918 (i386-avx-mpx.c): Remove.
2919 (i386-avx-mpx-linux.c): Remove.
2920 (i386-mmx.c): Remove.
2921 (i386-mmx-linux.c): Remove.
2922 (reg-ia64.c): Remove.
2923 (reg-m32r.c): Remove.
2924 (reg-m68k.c): Remove.
2925 (reg-cf.c): Remove.
2926 (mips-linux.c): Remove.
2927 (mips-dsp-linux.c): Remove.
2928 (mips64-linux.c): Remove.
2929 (mips64-dsp-linux.c): Remove.
2930 (nios2-linux.c): Remove.
2931 (powerpc-32.c): Remove.
2932 (powerpc-32l.c): Remove.
2933 (powerpc-altivec32l.c): Remove.
2934 (powerpc-cell32l.c): Remove.
2935 (powerpc-vsx32l.c): Remove.
2936 (powerpc-isa205-32l.c): Remove.
2937 (powerpc-isa205-altivec32l.c): Remove.
2938 (powerpc-isa205-vsx32l.c): Remove.
2939 (powerpc-e500l.c): Remove.
2940 (powerpc-64l.c): Remove.
2941 (powerpc-altivec64l.c): Remove.
2942 (powerpc-cell64l.c): Remove.
2943 (powerpc-vsx64l.c): Remove.
2944 (powerpc-isa205-64l.c): Remove.
2945 (powerpc-isa205-altivec64l.c): Remove.
2946 (powerpc-isa205-vsx64l.c): Remove.
2947 (s390-linux32.c): Remove.
2948 (s390-linux32v1.c): Remove.
2949 (s390-linux32v2.c): Remove.
2950 (s390-linux64.c): Remove.
2951 (s390-linux64v1.c): Remove.
2952 (s390-linux64v2.c): Remove.
2953 (s390-te-linux64.c): Remove.
2954 (s390-vx-linux64.c): Remove.
2955 (s390-tevx-linux64.c): Remove.
2956 (s390x-linux64.c): Remove.
2957 (s390x-linux64v1.c): Remove.
2958 (s390x-linux64v2.c): Remove.
2959 (s390x-te-linux64.c): Remove.
2960 (s390x-vx-linux64.c): Remove.
2961 (s390x-tevx-linux64.c): Remove.
2962 (tic6x-c64xp-linux.c): Remove.
2963 (tic6x-c64x-linux.c): Remove.
2964 (tic6x-c62x-linux.c): Remove.
2965 (reg-sh.c): Remove.
2966 (reg-sparc64.c): Remove.
2967 (reg-spu.c): Remove.
2968 (amd64.c): Remove.
2969 (amd64-linux.c): Remove.
2970 (amd64-avx.c): Remove.
2971 (amd64-avx-linux.c): Remove.
2972 (amd64-avx-avx512.c): Remove.
2973 (amd64-avx-avx512-linux.c): Remove.
2974 (amd64-mpx.c): Remove.
2975 (amd64-mpx-linux.c): Remove.
2976 (amd64-avx-mpx-avx512-pku.c): Remove.
2977 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
2978 (amd64-avx-mpx.c): Remove.
2979 (amd64-avx-mpx-linux.c): Remove.
2980 (x32.c): Remove.
2981 (x32-linux.c): Remove.
2982 (x32-avx.c): Remove.
2983 (x32-avx-linux.c): Remove.
2984 (x32-avx-avx512.c): Remove.
2985 (x32-avx-avx512-linux.c): Remove.
2986 (reg-xtensa.c): Remove.
2987 (reg-tilegx.c): Remove.
2988 (reg-tilegx32.c): Remove.
2989
2990 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
2991
2992 * Makefile.in (SFILES): Add "common/environ.c".
2993 (OBJS): Add "common/environ.h".
2994
2995 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
2996
2997 * configure.ac: Check if the fs_base and gs_base members of
2998 `struct user_regs_struct' exist.
2999 * config.in: Regenerated.
3000 * configure: Likewise.
3001
3002 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
3003
3004 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
3005 target_read_memory.
3006 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
3007 (get_next_pcs_syscall_next_pc): Likewise.
3008
3009 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
3010
3011 * win32-i386-low.c: Fix incorrect reference to a couple source files.
3012 * nto-x86-low.c: Likewise.
3013
3014 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
3015
3016 * Makefile.in: Include disable-implicit-rules.mk.
3017
3018 2016-11-23 Pedro Alves <palves@redhat.com>
3019
3020 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
3021 (debug_vprintf): Use std::chrono::steady_clock instead of
3022 gettimeofday. Use '.' instead of ':'.
3023 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
3024 (get_timestamp): Use std::chrono::steady_clock instead of
3025 gettimeofday.
3026
3027 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
3028
3029 * Makefile.in: Fix whitespace formatting.
3030
3031 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
3032
3033 * Makefile.in (SFILES, OBS): Flatten list and order
3034 alphabetically.
3035
3036 2016-11-23 Pedro Alves <palves@redhat.com>
3037
3038 * event-loop.c (handle_file_event): Use warning.
3039 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
3040 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
3041 Use warning.
3042
3043 2016-11-23 Pedro Alves <palves@redhat.com>
3044
3045 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
3046 output.
3047 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
3048 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
3049 debug_printf and debug_flush for debug output.
3050 * server.c (handle_general_set): Likewise.
3051 * thread-db.c (try_thread_db_load): Use debug_printf for debug
3052 output.
3053
3054 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
3055
3056 * Makefile.in (.c.o): Replace rule with ...
3057 (%.o: %.c): ... this one.
3058
3059 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
3060
3061 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
3062 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
3063 make.
3064 * configure.ac: Remove checks for the make program.
3065 * configure: Re-generate.
3066
3067 2016-10-28 Pedro Alves <palves@redhat.com>
3068
3069 * Makefile.in (CXX_DIALECT): Get from configure.
3070 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
3071 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
3072 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
3073 * config.in: Regenerate.
3074 * configure: Regenerate.
3075
3076 2016-10-27 Yao Qi <yao.qi@linaro.org>
3077
3078 * linux-low.c (linux_supports_range_stepping): Return true if
3079 can_software_single_step return true.
3080
3081 2016-10-27 Yao Qi <yao.qi@linaro.org>
3082
3083 * inferiors.c (find_inferior_in_random): New function.
3084 * inferiors.h (find_inferior_in_random): Declare.
3085 * linux-low.c (linux_wait_for_event_filtered): Call
3086 find_inferior_in_random instead of find_inferior.
3087
3088 2016-10-27 Yao Qi <yao.qi@linaro.org>
3089
3090 * linux-low.c (linux_wait_1): If single-step breakpoints are
3091 inserted, remove them.
3092
3093 2016-10-26 Pedro Alves <palves@redhat.com>
3094
3095 * linux-low.c (handle_extended_wait): Link parent/child fork
3096 threads.
3097 (linux_wait_1): Unlink them.
3098 (linux_set_resume_request): Ignore resume requests for
3099 already-resumed and unhandled fork child threads.
3100 * linux-low.h (struct lwp_info) <fork_relative>: New field.
3101 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
3102 New functions.
3103 (handle_v_requests) <vCont>: Don't call require_running.
3104 * server.h (in_queued_stop_replies): New declaration.
3105
3106 2016-10-24 Yao Qi <yao.qi@linaro.org>
3107
3108 PR server/20733
3109 * linux-aarch64-low.c (append_insns): Cast the return value to
3110 'uint32_t *'.
3111
3112 2016-10-10 Yao Qi <yao.qi@linaro.org>
3113
3114 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
3115
3116 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
3117
3118 * target.c (target_supports_multi_process): New function, moved
3119 from...
3120 * target.h (target_supports_multi_process): ... here. Remove
3121 macro.
3122
3123 2016-10-05 Tom Tromey <tom@tromey.com>
3124
3125 PR remote/20655:
3126 * tracepoint.c (handle_tracepoint_bkpts): Check
3127 ipa_error_tracepoint, not ipa_stopping_tracepoint.
3128
3129 2016-10-05 Yao Qi <yao.qi@linaro.org>
3130
3131 * configure.srv: Update the path of arm-*.xml files.
3132
3133 2016-10-05 Terry Guo <terry.guo@arm.com>
3134 Yao Qi <yao.qi@linaro.org>
3135
3136 * Makefile.in: Adjust the path of rules.
3137 * configure.srv: Update the path of xml files.
3138 * regformats/arm-with-iwmmxt.dat: Regenerated.
3139 * regformats/arm-with-neon.dat: Likewise.
3140 * regformats/arm-with-vfpv2.dat: Likewise.
3141 * regformats/arm-with-vfpv3.dat Likewise.
3142
3143 2016-09-30 Yao Qi <yao.qi@linaro.org>
3144
3145 PR gdbserver/20627
3146 * target.c (target_stop_and_wait): Don't call
3147 target_continue_no_signal, use resume_stop instead.
3148
3149 2016-09-26 Yao Qi <yao.qi@linaro.org>
3150
3151 * linux-low.c (linux_wait_1): Call debug_exit.
3152
3153 2016-09-23 Pedro Alves <palves@redhat.com>
3154
3155 * Makefile.in (SFILES): Add common/new-op.c.
3156 (OBS): Add common/new-op.o.
3157 (new-op.o): New rule.
3158
3159 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
3160
3161 * .gitinore: Ignore more files.
3162
3163 2016-09-21 Yao Qi <yao.qi@linaro.org>
3164
3165 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
3166 23.
3167
3168 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
3169
3170 * server.c (start_inferior): Call target_mourn_inferior instead of
3171 mourn_inferior; pass ptid_t argument to it.
3172 (resume): Likewise.
3173 (handle_target_event): Likewise.
3174 * target.c (target_mourn_inferior): New function.
3175 * target.h (mourn_inferior): Delete macro.
3176
3177 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
3178
3179 * linux-low.c (lwp_is_stepping): New function.
3180
3181 2016-09-06 Carl Love <cel@us.ibm.com>
3182
3183 * server.c (start_inferior): Fixed comment, requested comment change
3184 didn't get updated correctly. Removed reference to ptrace () call as
3185 it is only true on Linux systems.
3186
3187 2016-09-06 Carl Love <cel@us.ibm.com>
3188
3189 * server.c (start_inferior): Do not call
3190 function target_post_create_inferior () if the
3191 inferior process has already exited.
3192
3193 2016-09-05 Pedro Alves <palves@redhat.com>
3194
3195 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
3196 (COMPILE.pre, CC_LD): Use CXX directly.
3197 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
3198 * acinclude.m4: Don't include build-with-cxx.m4.
3199 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
3200 * configure: Regenerate.
3201
3202 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
3203
3204 PR gdb/19495
3205 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
3206 call writing data to own_buf.
3207
3208 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
3209
3210 * target.c (mywait): Call target_wait instead of
3211 the_target->wait.
3212 (target_wait): New function.
3213
3214 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
3215
3216 * server.c (start_inferior): New variable 'ptid'. Replace calls
3217 to the_target->resume by target_continue{,_no_signal}, depending
3218 on the case.
3219 * target.c (target_stop_and_wait): Call target_continue_no_signal
3220 instead of the_target->resume.
3221 (target_continue): New function.
3222
3223 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
3224
3225 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
3226
3227 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
3228
3229 PR server/20491
3230 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
3231 ps_prochandle.
3232 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
3233 * linux-arm-low.c (ps_get_thread_area): Likewise.
3234 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
3235 * linux-m68k-low.c (ps_get_thread_area): Likewise.
3236 * linux-mips-low.c (ps_get_thread_area): Likewise.
3237 * linux-nios2-low.c (ps_get_thread_area): Likewise.
3238 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
3239 * linux-x86-low.c (ps_get_thread_area): Likewise.
3240 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
3241
3242 2016-08-19 Pedro Alves <palves@redhat.com>
3243
3244 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
3245
3246 2016-08-19 Pedro Alves <palves@redhat.com>
3247
3248 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
3249 comment. Use memcpy instead of casting through unsigned long.
3250
3251 2016-08-19 Pedro Alves <palves@redhat.com>
3252
3253 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
3254 allocating around 0x80000000.
3255
3256 2016-08-19 Pedro Alves <palves@redhat.com>
3257
3258 PR gdb/20415
3259 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
3260 (x32-avx512-linux-ipa.o): New rules.
3261 * configure.ac (x86_64-*-linux*): New x32 check.
3262 * configure.srv (ipa_x32_linux_regobj): New.
3263 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
3264 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
3265 descriptions.
3266 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
3267 descriptions.
3268 * configure: Regenerate.
3269
3270 2016-08-09 Pedro Alves <palves@redhat.com>
3271
3272 PR gdb/18653
3273 * Makefile.in (OBS): Add signals-state-save-restore.o.
3274 (signals-state-save-restore.o): New rule.
3275 * config.in: Regenerate.
3276 * configure: Regenerate.
3277 * linux-low.c: Include "signals-state-save-restore.h".
3278 (linux_create_inferior): Call
3279 restore_original_signals_state.
3280 * server.c: Include "dispositions-save-restore.h".
3281 (captured_main): Call save_original_signals_state.
3282
3283 2016-08-05 Pedro Alves <palves@redhat.com>
3284
3285 * configure: Regenerate.
3286
3287 2016-08-04 Yao Qi <yao.qi@linaro.org>
3288
3289 * linux-low.c (regsets_fetch_inferior_registers): Check
3290 errno is ESRCH or not.
3291
3292 2016-08-02 Yao Qi <yao.qi@linaro.org>
3293
3294 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
3295 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
3296 (thread_db_load_search): Update.
3297 (try_thread_db_load_1): Don't look for td_ta_event_addr,
3298 td_ta_set_event and td_ta_event_getmsg.
3299
3300 2016-07-26 Pedro Alves <palves@redhat.com>
3301
3302 PR server/20414
3303 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
3304 of unsigned long for 64-bit registers and use uint32_t instead of
3305 unsigned int for 32-bit registers.
3306
3307 2016-07-26 Pedro Alves <palves@redhat.com>
3308
3309 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
3310 to 'ptrace'.
3311
3312 2016-07-21 Tom Tromey <tom@tromey.com>
3313
3314 * configure: Rebuild.
3315
3316 2016-07-21 Yao Qi <yao.qi@linaro.org>
3317
3318 * mem-break.c (find_gdb_breakpoint): Cast bp to
3319 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
3320
3321 2016-07-21 Yao Qi <yao.qi@linaro.org>
3322
3323 * server.c (handle_v_requests): Support s and S actions
3324 if target_supports_software_single_step return true.
3325
3326 2016-07-21 Yao Qi <yao.qi@linaro.org>
3327
3328 * linux-low.c (resume_stopped_resumed_lwps): If resume request
3329 is resume_step, call maybe_hw_step.
3330 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
3331 and unstop them.
3332 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
3333 breakpoints or not.
3334 (proceed_one_lwp): If resume request is resume_step, install
3335 reinsert breakpoints and call maybe_hw_step.
3336
3337 2016-07-21 Yao Qi <yao.qi@linaro.org>
3338
3339 * linux-low.c (proceed_one_lwp): Declare.
3340 (linux_resume_one_thread): Remove local variable 'step'.
3341 Lift code enqueue signal. Call proceed_one_lwp instead of
3342 linux_resume_one_lwp.
3343
3344 2016-07-21 Yao Qi <yao.qi@linaro.org>
3345
3346 * linux-low.c (linux_resume_one_thread): Call
3347 enqueue_pending_signal.
3348
3349 2016-07-21 Yao Qi <yao.qi@linaro.org>
3350
3351 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
3352 * inferiors.c (do_restore_current_thread_cleanup): New function.
3353 (make_cleanup_restore_current_thread): Likewise.
3354 * linux-low.c (install_software_single_step_breakpoints): Call
3355 make_cleanup_restore_current_thread. Switch current_thread to
3356 thread.
3357
3358 2016-07-21 Yao Qi <yao.qi@linaro.org>
3359
3360 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
3361 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
3362 (clone_one_breakpoint): Likewise.
3363 (delete_reinsert_breakpoints): Change parameter to thread.
3364 Callers updated.
3365 (has_reinsert_breakpoints): Likewise.
3366 (uninsert_reinsert_breakpoints): Likewise.
3367 (reinsert_reinsert_breakpoints): Likewise.
3368 * mem-break.h (set_reinsert_breakpoint): Update declaration.
3369 (delete_reinsert_breakpoints): Likewise.
3370 (reinsert_reinsert_breakpoints): Likewise.
3371 (uninsert_reinsert_breakpoints): Likewise.
3372 (has_reinsert_breakpoints): Likewise.
3373
3374 2016-07-21 Yao Qi <yao.qi@linaro.org>
3375
3376 * inferiors.c (get_thread_process): Make parameter const.
3377 * inferiors.h (get_thread_process): Update declaration.
3378 * mem-break.c (clone_all_breakpoints): Remove all parameters.
3379 Add new parameters child_thread and parent_thread. Callers
3380 updated.
3381 * mem-break.h (clone_all_breakpoints): Update declaration.
3382
3383 2016-07-21 Yao Qi <yao.qi@linaro.org>
3384
3385 * mem-break.c (struct breakpoint) <cond_list>: Remove.
3386 <command_list, handler>: Remove.
3387 (struct gdb_breakpoint): New.
3388 (struct other_breakpoint): New.
3389 (struct reinsert_breakpoint): New.
3390 (is_gdb_breakpoint): New function.
3391 (any_persistent_commands): Update command_list if
3392 is_gdb_breakpoint returns true.
3393 (set_breakpoint): Create breakpoints according to their types.
3394 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
3395 (set_gdb_breakpoint_1): Likewise.
3396 (set_gdb_breakpoint): Likewise.
3397 (clear_breakpoint_conditions): Change parameter type to
3398 'struct gdb_breakpoint *'.
3399 (clear_breakpoint_commands): Likewise.
3400 (clear_breakpoint_conditions_and_commands): Likewise.
3401 (add_condition_to_breakpoint): Likewise.
3402 (add_breakpoint_condition): Likewise.
3403 (add_commands_to_breakpoint): Likewise.
3404 (check_breakpoints): Check other_breakpoint.
3405 (clone_one_breakpoint): Clone breakpopint according to its type.
3406 * mem-break.h (struct gdb_breakpoint): Declare.
3407 (set_gdb_breakpoint): Update declaration.
3408 (clear_breakpoint_conditions_and_commands): Likewise.
3409 (add_breakpoint_condition): Likewise.
3410 (add_breakpoint_commands): Likewise.
3411 * server.c (process_point_options): Change parameter type to
3412 'struct gdb_breakpoint *'.
3413
3414 2016-07-21 Yao Qi <yao.qi@linaro.org>
3415
3416 * mem-break.c (set_breakpoint_at): Rename it to ...
3417 (set_breakpoint_type_at): ... it.
3418 (set_breakpoint_at): Call set_breakpoint_type_at.
3419 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
3420 * mem-break.h (set_breakpoint_at): Update comments.
3421
3422 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
3423
3424 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
3425 to buf parameter.
3426 (nios2_store_gregset): Likewise.
3427
3428 2016-07-01 Pedro Alves <palves@redhat.com>
3429 Antoine Tremblay <antoine.tremblay@ericsson.com>
3430
3431 * linux-low.c: Change interface to take the target lwp_info
3432 pointer directly and return void. Handle detaching from a zombie
3433 thread.
3434 (linux_detach_lwp_callback): New function.
3435 (linux_detach): Detach from the leader thread after detaching from
3436 the clone threads.
3437
3438 2016-06-28 Yao Qi <yao.qi@linaro.org>
3439
3440 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
3441 for variable new_offset.
3442 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
3443 (aarch64_ftrace_insn_reloc_cb): Likewise.
3444 (aarch64_ftrace_insn_reloc_tb): Likewise.
3445 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
3446 PRIx64 instead of PRIx32.
3447
3448 2016-06-28 Yao Qi <yao.qi@linaro.org>
3449
3450 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
3451 (the_low_target): Install arm_get_syscall_trapinfo.
3452
3453 2016-06-28 Yao Qi <yao.qi@linaro.org>
3454
3455 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
3456 function.
3457 (the_low_target): Install aarch64_get_syscall_trapinfo.
3458
3459 2016-06-28 Yao Qi <yao.qi@linaro.org>
3460
3461 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
3462 Callers updated.
3463 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
3464 Remove parameter sysno.
3465 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
3466 sysret.
3467
3468 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
3469
3470 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
3471 (s390_emit_ne_goto): Likewise.
3472 (s390_emit_lt_goto): Likewise.
3473 (s390_emit_le_goto): Likewise.
3474 (s390_emit_gt_goto): Likewise.
3475 (s390_emit_ge_goto): Likewise.
3476 (s390x_emit_eq_goto): Likewise.
3477 (s390x_emit_ne_goto): Likewise.
3478 (s390x_emit_lt_goto): Likewise.
3479 (s390x_emit_le_goto): Likewise.
3480 (s390x_emit_gt_goto): Likewise.
3481 (s390x_emit_ge_goto): Likewise.
3482 (s390_emit_ops_impl): Mark variable static.
3483 (s390x_emit_ops): Likewise.
3484
3485 2016-06-17 Yao Qi <yao.qi@linaro.org>
3486
3487 * linux-low.c (handle_extended_wait): Call
3488 uninsert_reinsert_breakpoints for the parent process. Remove
3489 reinsert breakpoints from the child process. Reinsert them to
3490 the parent process when vfork is done.
3491 * mem-break.c (uninsert_reinsert_breakpoints): New function.
3492 (reinsert_reinsert_breakpoints): New function.
3493 * mem-break.h (uninsert_reinsert_breakpoints): Declare
3494 (reinsert_reinsert_breakpoints): Declare.
3495
3496 2016-06-17 Yao Qi <yao.qi@linaro.org>
3497
3498 * linux-low.c (handle_extended_wait): If the parent is doing
3499 step-over, remove the reinsert breakpoints from the forked child.
3500
3501 2016-06-17 Yao Qi <yao.qi@linaro.org>
3502
3503 * linux-low.c (unsuspend_all_lwps): Declare.
3504 (linux_low_filter_event): If thread exited, call finish_step_over.
3505 If step-over is finished, unsuspend other threads.
3506
3507 2016-06-17 Yao Qi <yao.qi@linaro.org>
3508
3509 * linux-low.c (linux_resume_one_lwp_throw): Assert
3510 has_reinsert_breakpoints returns false.
3511 * mem-break.c (delete_disabled_breakpoints): Assert
3512 bp type isn't reinsert_breakpoint.
3513
3514 2016-06-17 Yao Qi <yao.qi@linaro.org>
3515
3516 * linux-low.c (maybe_hw_step): New function.
3517 (linux_resume_one_lwp_throw): Call maybe_hw_step.
3518 (finish_step_over): Switch current_thread to lwp temporarily,
3519 and assert has_reinsert_breakpoints returns true.
3520 (proceed_one_lwp): Call maybe_hw_step.
3521 * mem-break.c (has_reinsert_breakpoints): New function.
3522 * mem-break.h (has_reinsert_breakpoints): Declare.
3523
3524 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
3525
3526 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
3527
3528 2016-05-17 Yao Qi <yao.qi@linaro.org>
3529
3530 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
3531 instead of find_inferior.
3532
3533 2016-05-05 Yao Qi <yao.qi@linaro.org>
3534
3535 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
3536 Initialize res to zero.
3537
3538 2016-05-05 Yao Qi <yao.qi@linaro.org>
3539
3540 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
3541 to uint32_t.
3542
3543 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
3544
3545 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
3546 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
3547 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
3548
3549 2016-04-28 Par Olsson <par.olsson@windriver.com>
3550 Simon Marchi <simon.marchi@ericsson.com>
3551
3552 * tracepoint.c (write_inferior_int8): New function.
3553 (cmd_qtenable_disable): Write enable flag using
3554 write_inferior_int8.
3555
3556 2016-04-25 Yao Qi <yao.qi@linaro.org>
3557
3558 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
3559 (need_step_over_p): Return zero if the LWP has pending signals
3560 can be delivered on software single step target.
3561
3562 2016-04-25 Yao Qi <yao.qi@linaro.org>
3563
3564 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
3565 return instead of error.
3566
3567 2016-04-22 Yao Qi <yao.qi@linaro.org>
3568
3569 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
3570 to 23.
3571
3572 2016-04-22 Yao Qi <yao.qi@linaro.org>
3573
3574 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
3575 signal when stepping over breakpoint with software single
3576 step.
3577
3578 2016-04-21 Pedro Alves <palves@redhat.com>
3579
3580 * linux-s390-low.c (s390_collect_ptrace_register)
3581 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
3582 add casts.
3583 (s390_check_regset): Use void * instead of gdb_byte *.
3584
3585 2016-04-20 Pedro Alves <palves@redhat.com>
3586
3587 * configure: Renegerate.
3588
3589 2016-04-20 Yao Qi <yao.qi@linaro.org>
3590
3591 * linux-aarch32-low.c: Include "arch/arm-linux.h".
3592 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
3593 number 16.
3594 (arm_store_gregset): Likewise.
3595
3596 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
3597
3598 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
3599 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
3600 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
3601 (amd64-avx-mpx-linux.c): New rules.
3602 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
3603 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
3604 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
3605 (srv_amd64_regobj): Add amd64-avx-mpx.o.
3606 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
3607 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
3608 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
3609 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
3610 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
3611 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
3612 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
3613 * linux-x86-low.c (x86_linux_read_description): Add case for
3614 X86_XSTATE_AVX_MPX_MASK.
3615 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
3616 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
3617 init_registers_i386_avx_mpx_linux.
3618 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
3619 (initialize_low_tracepoint): Call
3620 init_registers_i386_avx_mpx_linux.
3621 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
3622 (initialize_low_tracepoint): Call
3623 init_registers_amd64_avx_mpx_linux.
3624 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
3625 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
3626 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
3627 declarations.
3628
3629 2016-04-18 Pedro Alves <palves@redhat.com>
3630
3631 * configure: Regenerate.
3632
3633 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
3634
3635 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
3636 (aarch64_emit_sub): Likewise.
3637
3638 2016-04-12 Pedro Alves <palves@redhat.com>
3639
3640 * utils.c (prepare_to_throw_exception): Delete.
3641
3642 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
3643
3644 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
3645
3646 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
3647
3648 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
3649
3650 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
3651
3652 * linux-aarch64-ipa.c: Add <elf.h> include.
3653 * linux-ppc-ipa.c: Add <elf.h> include.
3654 * linux-s390-ipa.c: Add <elf.h> include.
3655
3656 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
3657
3658 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
3659 (get_raw_reg_ptr): Likewise.
3660 (get_trace_state_variable_value_ptr): Likewise.
3661 (set_trace_state_variable_value_ptr): Likewise.
3662 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
3663 char *.
3664
3665 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
3666 Marcin Kościelnicki <koriakin@0x04.net>
3667
3668 PR/17221
3669 * linux-ppc-low.c (emit_insns): New function.
3670 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
3671 (ppc_emit_prologue): New function.
3672 (ppc_emit_epilogue): New function.
3673 (ppc_emit_add): New function.
3674 (ppc_emit_sub): New function.
3675 (ppc_emit_mul): New function.
3676 (ppc_emit_lsh): New function.
3677 (ppc_emit_rsh_signed): New function.
3678 (ppc_emit_rsh_unsigned): New function.
3679 (ppc_emit_ext): New function.
3680 (ppc_emit_zero_ext): New function.
3681 (ppc_emit_log_not): New function.
3682 (ppc_emit_bit_and): New function.
3683 (ppc_emit_bit_or): New function.
3684 (ppc_emit_bit_xor): New function.
3685 (ppc_emit_bit_not): New function.
3686 (ppc_emit_equal): New function.
3687 (ppc_emit_less_signed): New function.
3688 (ppc_emit_less_unsigned): New function.
3689 (ppc_emit_ref): New function.
3690 (ppc_emit_const): New function.
3691 (ppc_emit_reg): New function.
3692 (ppc_emit_pop): New function.
3693 (ppc_emit_stack_flush): New function.
3694 (ppc_emit_swap): New function.
3695 (ppc_emit_stack_adjust): New function.
3696 (ppc_emit_call): New function.
3697 (ppc_emit_int_call_1): New function.
3698 (ppc_emit_void_call_2): New function.
3699 (ppc_emit_if_goto): New function.
3700 (ppc_emit_goto): New function.
3701 (ppc_emit_eq_goto): New function.
3702 (ppc_emit_ne_goto): New function.
3703 (ppc_emit_lt_goto): New function.
3704 (ppc_emit_le_goto): New function.
3705 (ppc_emit_gt_goto): New function.
3706 (ppc_emit_ge_goto): New function.
3707 (ppc_write_goto_address): New function.
3708 (ppc_emit_ops_impl): New static variable.
3709 (ppc64v1_emit_prologue): New function.
3710 (ppc64v2_emit_prologue): New function.
3711 (ppc64_emit_epilogue): New function.
3712 (ppc64_emit_add): New function.
3713 (ppc64_emit_sub): New function.
3714 (ppc64_emit_mul): New function.
3715 (ppc64_emit_lsh): New function.
3716 (ppc64_emit_rsh_signed): New function.
3717 (ppc64_emit_rsh_unsigned): New function.
3718 (ppc64_emit_ext): New function.
3719 (ppc64_emit_zero_ext): New function.
3720 (ppc64_emit_log_not): New function.
3721 (ppc64_emit_bit_and): New function.
3722 (ppc64_emit_bit_or): New function.
3723 (ppc64_emit_bit_xor): New function.
3724 (ppc64_emit_bit_not): New function.
3725 (ppc64_emit_equal): New function.
3726 (ppc64_emit_less_signed): New function.
3727 (ppc64_emit_less_unsigned): New function.
3728 (ppc64_emit_ref): New function.
3729 (ppc64_emit_const): New function.
3730 (ppc64v1_emit_reg): New function.
3731 (ppc64v2_emit_reg): New function.
3732 (ppc64_emit_pop): New function.
3733 (ppc64_emit_stack_flush): New function.
3734 (ppc64_emit_swap): New function.
3735 (ppc64v1_emit_call): New function.
3736 (ppc64v2_emit_call): New function.
3737 (ppc64v1_emit_int_call_1): New function.
3738 (ppc64v2_emit_int_call_1): New function.
3739 (ppc64v1_emit_void_call_2): New function.
3740 (ppc64v2_emit_void_call_2): New function.
3741 (ppc64_emit_if_goto): New function.
3742 (ppc64_emit_eq_goto): New function.
3743 (ppc64_emit_ne_goto): New function.
3744 (ppc64_emit_lt_goto): New function.
3745 (ppc64_emit_le_goto): New function.
3746 (ppc64_emit_gt_goto): New function.
3747 (ppc64_emit_ge_goto): New function.
3748 (ppc64v1_emit_ops_impl): New static variable.
3749 (ppc64v2_emit_ops_impl): New static variable.
3750 (ppc_emit_ops): New function.
3751 (linux_low_target): Wire in ppc_emit_ops.
3752
3753 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
3754 Marcin Kościelnicki <koriakin@0x04.net>
3755
3756 PR/17221
3757 * Makefile.in: Add powerpc-*-ipa.o
3758 * configure.srv: Add ipa_obj for powerpc*-linux.
3759 * linux-ppc-ipa.c: New file.
3760 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
3761 includes.
3762 (PPC_FIELD): New macro.
3763 (PPC_SEXT): New macro.
3764 (PPC_OP6): New macro.
3765 (PPC_BO): New macro.
3766 (PPC_LI): New macro.
3767 (PPC_BD): New macro.
3768 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
3769 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
3770 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
3771 (ppc_get_thread_area): New function.
3772 (is_elfv2_inferior): New function.
3773 (gen_ds_form): New function.
3774 (GEN_STD): New macro.
3775 (GEN_STDU): New macro.
3776 (GEN_LD): New macro.
3777 (GEN_LDU): New macro.
3778 (gen_d_form): New function.
3779 (GEN_ADDI): New macro.
3780 (GEN_ADDIS): New macro.
3781 (GEN_LI): New macro.
3782 (GEN_LIS): New macro.
3783 (GEN_ORI): New macro.
3784 (GEN_ORIS): New macro.
3785 (GEN_LWZ): New macro.
3786 (GEN_STW): New macro.
3787 (GEN_STWU): New macro.
3788 (gen_xfx_form): New function.
3789 (GEN_MFSPR): New macro.
3790 (GEN_MTSPR): New macro.
3791 (GEN_MFCR): New macro.
3792 (GEN_MTCR): New macro.
3793 (GEN_SYNC): New macro.
3794 (GEN_LWSYNC): New macro.
3795 (gen_x_form): New function.
3796 (GEN_OR): New macro.
3797 (GEN_MR): New macro.
3798 (GEN_LWARX): New macro.
3799 (GEN_STWCX): New macro.
3800 (GEN_CMPW): New macro.
3801 (gen_md_form): New function.
3802 (GEN_RLDICL): New macro.
3803 (GEN_RLDICR): New macro.
3804 (gen_i_form): New function.
3805 (GEN_B): New macro.
3806 (GEN_BL): New macro.
3807 (gen_b_form): New function.
3808 (GEN_BNE): New macro.
3809 (GEN_LOAD): New macro.
3810 (GEN_STORE): New macro.
3811 (gen_limm): New function.
3812 (gen_atomic_xchg): New function.
3813 (gen_call): New function.
3814 (ppc_relocate_instruction): New function.
3815 (ppc_install_fast_tracepoint_jump_pad): New function.
3816 (ppc_get_min_fast_tracepoint_insn_len): New function.
3817 (ppc_get_ipa_tdesc_idx): New function.
3818 (the_low_target): Wire in the new functions.
3819 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
3820 tdescs.
3821 * linux-ppc-tdesc.h: New file.
3822
3823 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
3824
3825 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
3826 (alloc_jump_pad_buffer): New function.
3827 * linux-amd64-ipa.c: Add <sys/mman.h> include.
3828 (alloc_jump_pad_buffer): New function.
3829 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
3830 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
3831 (alloc_jump_pad_buffer): New function.
3832 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
3833 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
3834 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
3835 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
3836
3837 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
3838
3839 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
3840 * linux-amd64-ipa.c: Likewise.
3841 * linux-i386-ipa.c: Likewise.
3842 * linux-s390-ipa.c: Likewise.
3843 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
3844 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
3845 set_trace_state_variable_value_ptr.
3846 (struct ipa_sym_addresses): Likewise.
3847 (symbol_list): Likewise.
3848 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
3849 accessing gdb_collect directly.
3850 (gdb_collect_ptr_type): New typedef.
3851 (get_raw_reg_ptr_type): New typedef.
3852 (get_trace_state_variable_value_ptr_type): New typedef.
3853 (set_trace_state_variable_value_ptr_type): New typedef.
3854 (gdb_collect_ptr): New global.
3855 (get_raw_reg_ptr): New global.
3856 (get_trace_state_variable_value_ptr): New global.
3857 (set_trace_state_variable_value_ptr): New global.
3858 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
3859 accessing get_raw_reg directly.
3860 (get_get_tsv_func_addr): Likewise for
3861 get_trace_state_variable_value_ptr.
3862 (get_set_tsv_func_addr): Likewise for
3863 set_trace_state_variable_value_ptr.
3864 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
3865
3866 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
3867
3868 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
3869
3870 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
3871
3872 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
3873 packets.
3874 (relocate_instruction): Remove own_buf.
3875 * server.c (own_buf): Make global.
3876 (handle_v_requests): Make global.
3877 * server.h (own_buf): New declaration.
3878 (handle_v_requests): New prototype.
3879
3880 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
3881
3882 PR 18377
3883 * linux-s390-low.c (add_insns): New function.
3884 (s390_emit_prologue): New function.
3885 (s390_emit_epilogue): New function.
3886 (s390_emit_add): New function.
3887 (s390_emit_sub): New function.
3888 (s390_emit_mul): New function.
3889 (s390_emit_lsh): New function.
3890 (s390_emit_rsh_signed): New function.
3891 (s390_emit_rsh_unsigned): New function.
3892 (s390_emit_ext): New function.
3893 (s390_emit_log_not): New function.
3894 (s390_emit_bit_and): New function.
3895 (s390_emit_bit_or): New function.
3896 (s390_emit_bit_xor): New function.
3897 (s390_emit_bit_not): New function.
3898 (s390_emit_equal): New function.
3899 (s390_emit_less_signed): New function.
3900 (s390_emit_less_unsigned): New function.
3901 (s390_emit_ref): New function.
3902 (s390_emit_if_goto): New function.
3903 (s390_emit_goto): New function.
3904 (s390_write_goto_address): New function.
3905 (s390_emit_litpool): New function.
3906 (s390_emit_const): New function.
3907 (s390_emit_call): New function.
3908 (s390_emit_reg): New function.
3909 (s390_emit_pop): New function.
3910 (s390_emit_stack_flush): New function.
3911 (s390_emit_zero_ext): New function.
3912 (s390_emit_swap): New function.
3913 (s390_emit_stack_adjust): New function.
3914 (s390_emit_set_r2): New function.
3915 (s390_emit_int_call_1): New function.
3916 (s390_emit_void_call_2): New function.
3917 (s390_emit_eq_goto): New function.
3918 (s390_emit_ne_goto): New function.
3919 (s390_emit_lt_goto): New function.
3920 (s390_emit_le_goto): New function.
3921 (s390_emit_gt_goto): New function.
3922 (s390_emit_ge_goto): New function.
3923 (s390x_emit_prologue): New function.
3924 (s390x_emit_epilogue): New function.
3925 (s390x_emit_add): New function.
3926 (s390x_emit_sub): New function.
3927 (s390x_emit_mul): New function.
3928 (s390x_emit_lsh): New function.
3929 (s390x_emit_rsh_signed): New function.
3930 (s390x_emit_rsh_unsigned): New function.
3931 (s390x_emit_ext): New function.
3932 (s390x_emit_log_not): New function.
3933 (s390x_emit_bit_and): New function.
3934 (s390x_emit_bit_or): New function.
3935 (s390x_emit_bit_xor): New function.
3936 (s390x_emit_bit_not): New function.
3937 (s390x_emit_equal): New function.
3938 (s390x_emit_less_signed): New function.
3939 (s390x_emit_less_unsigned): New function.
3940 (s390x_emit_ref): New function.
3941 (s390x_emit_if_goto): New function.
3942 (s390x_emit_const): New function.
3943 (s390x_emit_call): New function.
3944 (s390x_emit_reg): New function.
3945 (s390x_emit_pop): New function.
3946 (s390x_emit_stack_flush): New function.
3947 (s390x_emit_zero_ext): New function.
3948 (s390x_emit_swap): New function.
3949 (s390x_emit_stack_adjust): New function.
3950 (s390x_emit_int_call_1): New function.
3951 (s390x_emit_void_call_2): New function.
3952 (s390x_emit_eq_goto): New function.
3953 (s390x_emit_ne_goto): New function.
3954 (s390x_emit_lt_goto): New function.
3955 (s390x_emit_le_goto): New function.
3956 (s390x_emit_gt_goto): New function.
3957 (s390x_emit_ge_goto): New function.
3958 (s390_emit_ops): New function.
3959 (struct linux_target_ops): Fill in emit_ops hook.
3960
3961 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
3962
3963 PR 18377
3964 * Makefile.in: Add s390 IPA files.
3965 * configure.srv: Build IPA for s390.
3966 * linux-s390-ipa.c: New file.
3967 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
3968 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
3969 (tdesc_s390_linux32): Likewise.
3970 (init_registers_s390_linux32v1): Likewise.
3971 (tdesc_s390_linux32v1): Likewise.
3972 (init_registers_s390_linux32v2): Likewise.
3973 (tdesc_s390_linux32v2): Likewise.
3974 (init_registers_s390_linux64): Likewise.
3975 (tdesc_s390_linux64): Likewise.
3976 (init_registers_s390_linux64v1): Likewise.
3977 (tdesc_s390_linux64v1): Likewise.
3978 (init_registers_s390_linux64v2): Likewise.
3979 (tdesc_s390_linux64v2): Likewise.
3980 (init_registers_s390_te_linux64): Likewise.
3981 (tdesc_s390_te_linux64): Likewise.
3982 (init_registers_s390_vx_linux64): Likewise.
3983 (tdesc_s390_vx_linux64): Likewise.
3984 (init_registers_s390_tevx_linux64): Likewise.
3985 (tdesc_s390_tevx_linux64): Likewise.
3986 (init_registers_s390x_linux64): Likewise.
3987 (tdesc_s390x_linux64): Likewise.
3988 (init_registers_s390x_linux64v1): Likewise.
3989 (tdesc_s390x_linux64v1): Likewise.
3990 (init_registers_s390x_linux64v2): Likewise.
3991 (tdesc_s390x_linux64v2): Likewise.
3992 (init_registers_s390x_te_linux64): Likewise.
3993 (tdesc_s390x_te_linux64): Likewise.
3994 (init_registers_s390x_vx_linux64): Likewise.
3995 (tdesc_s390x_vx_linux64): Likewise.
3996 (init_registers_s390x_tevx_linux64): Likewise.
3997 (tdesc_s390x_tevx_linux64): Likewise.
3998 (have_hwcap_s390_vx): New static variable.
3999 (s390_arch_setup): Fill have_hwcap_s390_vx.
4000 (s390_get_thread_area): New function.
4001 (s390_ft_entry_gpr_esa): New const.
4002 (s390_ft_entry_gpr_zarch): New const.
4003 (s390_ft_entry_misc): New const.
4004 (s390_ft_entry_fr): New const.
4005 (s390_ft_entry_vr): New const.
4006 (s390_ft_main_31): New const.
4007 (s390_ft_main_64): New const.
4008 (s390_ft_exit_fr): New const.
4009 (s390_ft_exit_vr): New const.
4010 (s390_ft_exit_misc): New const.
4011 (s390_ft_exit_gpr_esa): New const.
4012 (s390_ft_exit_gpr_zarch): New const.
4013 (append_insns): New function.
4014 (s390_relocate_instruction): New function.
4015 (s390_install_fast_tracepoint_jump_pad): New function.
4016 (s390_get_min_fast_tracepoint_insn_len): New function.
4017 (s390_get_ipa_tdesc_idx): New function.
4018 (struct linux_target_ops): Wire in the above functions.
4019 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
4020 * linux-s390-tdesc.h: New file.
4021
4022 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
4023
4024 * linux-s390-low.c (s390_supports_tracepoints): New function.
4025 (struct linux_target_ops): Fill supports_tracepoints hook.
4026
4027 2016-03-18 Yao Qi <yao.qi@linaro.org>
4028
4029 * linux-low.c (lwp_signal_can_be_delivered): New function.
4030 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
4031
4032 2016-03-18 Yao Qi <yao.qi@linaro.org>
4033
4034 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
4035 0 if signal is enqueued. Remove 'signal' from one debugging
4036 message. Move one debugging message to some lines below.
4037 Remove code setting 'signal' to 0.
4038
4039 2016-03-18 Yao Qi <yao.qi@linaro.org>
4040
4041 * linux-low.c (linux_low_filter_event): Remove redundant
4042 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
4043
4044 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
4045
4046 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
4047 (struct linux_target_ops): Wire in the above.
4048
4049 2016-03-03 Yao Qi <yao.qi@linaro.org>
4050
4051 * linux-low.c: Update comments to start_step_over.
4052
4053 2016-03-03 Yao Qi <yao.qi@linaro.org>
4054
4055 PR server/19736
4056 * linux-low.c (handle_extended_wait): Set child suspended
4057 if event_lwp->bp_reinsert isn't zero.
4058
4059 2016-03-02 Yao Qi <yao.qi@linaro.org>
4060
4061 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
4062 enqueue_pending_signal.
4063
4064 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
4065
4066 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
4067 is actually loaded.
4068
4069 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
4070
4071 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
4072 (s390_regmap_3264) [!__s390x__]: New global.
4073 (s390_collect_ptrace_register): Skip map entries containing -1.
4074 (s390_supply_ptrace_register): Ditto.
4075 (s390_fill_gprs_high): New function.
4076 (s390_store_gprs_high): New function.
4077 (s390_regsets): Add NT_S390_HIGH_GPRS.
4078 (s390_get_hwcap): Enable on 31-bit.
4079 (have_hwcap_s390_high_gprs): Enable on 31-bit.
4080 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
4081 Detect NT_S390_HIGH_GPRS.
4082 (s390_usrregs_info_3264): Enable on 31-bit.
4083 (s390_regs_info): Enable regs_info_3264 on 31-bit.
4084 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
4085
4086 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
4087
4088 PR gdb/13808
4089 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
4090 * configure.srv: Ditto.
4091 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
4092 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
4093 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
4094 (init_registers_amd64_linux): Remove prototype.
4095 (tdesc_amd64_linux): Remove declaration.
4096 (get_ipa_tdesc): New function.
4097 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
4098 initialize remaining tdescs.
4099 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
4100 (init_registers_i386_linux): Remove prototype.
4101 (tdesc_i386_linux): Remove declaration.
4102 (get_ipa_tdesc): New function.
4103 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
4104 initialize remaining tdescs.
4105 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
4106 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
4107 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
4108 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
4109 (x86_get_ipa_tdesc_idx): New function.
4110 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
4111 * linux-x86-tdesc.h: New file.
4112 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
4113 (target_get_ipa_tdesc_idx): New macro.
4114 * tracepoint.c (ipa_tdesc_idx): New macro.
4115 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
4116 (symbol_list): Add ipa_tdesc_idx.
4117 (cmd_qtstart): Write ipa_tdesc_idx in the target.
4118 (ipa_tdesc): Remove.
4119 (ipa_tdesc_idx): New variable.
4120 (get_context_regcache): Use get_ipa_tdesc.
4121 (gdb_collect): Ditto.
4122 (gdb_probe): Ditto.
4123 * tracepoint.h (get_ipa_tdesc): New prototype.
4124 (ipa_tdesc): Remove.
4125
4126 2016-02-24 Pedro Alves <palves@redhat.com>
4127
4128 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
4129 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
4130 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
4131 Factor out common code between the USE_SIGTRAP_SIGINFO and
4132 !USE_SIGTRAP_SIGINFO blocks.
4133 (linux_low_filter_event): Call save_stop_reason instead of
4134 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
4135 Update comments.
4136 (linux_wait_1): Update comments.
4137
4138 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
4139
4140 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
4141 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
4142 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
4143 ppc_insert_point, ppc_remove_point.
4144
4145 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
4146
4147 * linux-s390-low.c (s390_supports_z_point_type): New function.
4148 (struct linux_target_ops): Wire s390_supports_z_point_type in.
4149
4150 2016-02-16 Yao Qi <yao.qi@linaro.org>
4151
4152 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
4153 PC. Get pc from regcache_read_pc.
4154
4155 2016-02-12 Yao Qi <yao.qi@linaro.org>
4156
4157 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
4158 or linux_get_pc_32bit.
4159 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
4160
4161 2016-02-12 Yao Qi <yao.qi@linaro.org>
4162
4163 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
4164 arm_linux_get_next_pcs_fixup.
4165
4166 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
4167
4168 * tracepoint.c (x_tracepoint_action_download): Change
4169 write_inferior_data_ptr to write_inferior_data_pointer.
4170 (cmd_qtstart): Likewise.
4171 (write_inferior_data_ptr): Remove.
4172 (download_agent_expr): Change write_inferior_data_ptr to
4173 write_inferior_data_pointer.
4174 (download_tracepoint_1): Likewise.
4175 (download_tracepoint): Likewise.
4176 (download_trace_state_variables): Likewise.
4177
4178 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
4179 Marcin Kościelnicki <koriakin@0x04.net>
4180
4181 * tracepoint.c (struct tracepoint_action_ops): Remove.
4182 (struct tracepoint_action): Remove ops.
4183 (m_tracepoint_action_download, r_tracepoint_action_download)
4184 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
4185 size and offset accordingly.
4186 (m_tracepoint_action_ops, r_tracepoint_action_ops)
4187 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
4188 (tracepoint_action_send, tracepoint_action_download): New functions.
4189 Helpers for trace action handlers.
4190 (add_tracepoint_action): Remove setup actions ops.
4191 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
4192
4193 2016-02-10 Yao Qi <yao.qi@linaro.org>
4194
4195 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
4196
4197 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
4198
4199 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
4200 to AC_OUTPUT.
4201 * configure: Regenerate.
4202
4203 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
4204
4205 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
4206 void * to gdb_byte *.
4207 * linux-low.c (siginfo_fixup): Likewise.
4208 (linux_xfer_siginfo): Likewise.
4209 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
4210 Likewise.
4211 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
4212
4213 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
4214
4215 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
4216 to srv_tgtobj.
4217 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
4218 to srv_tgtobj.
4219 * linux-x86-low.c [__x86_64__]: Include
4220 "nat/amd64-linux-siginfo.h".
4221 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
4222 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
4223 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
4224 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
4225 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
4226 (cpt_si_fd, si_timerid, si_overrun): Move from
4227 nat/amd64-linux-siginfo.c.
4228 * Makefile.in (amd64-linux-siginfo.o:): New rule.
4229
4230 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
4231
4232 * server.c (skip_to_semicolon): Remove.
4233 (process_point_options): Use strchrnul instead of
4234 skip_to_semicolon.
4235
4236 2016-01-26 Yao Qi <yao.qi@linaro.org>
4237
4238 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
4239 * linux-low.c (install_software_single_step_breakpoints): Don't
4240 call regcache_read_pc.
4241 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
4242 argument pc.
4243
4244 2016-01-26 Yao Qi <yao.qi@linaro.org>
4245
4246 * linux-low.c (install_software_single_step_breakpoints): Call
4247 regcache_read_pc instead of get_pc.
4248
4249 2016-01-26 Yao Qi <yao.qi@linaro.org>
4250
4251 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
4252 (unblock_async_io): Rename to ...
4253 (block_unblock_async_io): ... it. New function.
4254 (enable_async_io): Don't install SIGIO handler. Unblock it
4255 instead.
4256 (disable_async_io): Don't ignore SIGIO. Block it instead.
4257 (initialize_async_io): Install SIGIO handler. Don't call
4258 unblock_async_io.
4259
4260 2016-01-26 Yao Qi <yao.qi@linaro.org>
4261
4262 * remote-utils.c (getpkt): If the buffer isn't empty, and the
4263 first character is '\003', call *the_target->request_interrupt.
4264
4265 2016-01-25 Yao Qi <yao.qi@linaro.org>
4266
4267 * remote-utils.c (new_thread_notify): Remove.
4268 (dead_thread_notify): Likewise.
4269 * remote-utils.h (new_thread_notify): Remove declaration.
4270 (dead_thread_notify): Likewise.
4271
4272 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
4273
4274 * gdb.trace/pending.exp: Fix expected message on continue.
4275
4276 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
4277
4278 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
4279 it works properly on big-endian machines where sizeof (CORE_ADDR)
4280 != sizeof (void *).
4281
4282 2016-01-21 Pedro Alves <palves@redhat.com>
4283
4284 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
4285 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
4286 * configure: Regenerate.
4287
4288 2016-01-21 Yao Qi <yao.qi@linaro.org>
4289
4290 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
4291 is_thumb and set it according to CPSR saved on the stack.
4292 (get_next_pcs_syscall_next_pc): Pass is_thumb to
4293 arm_sigreturn_next_pc.
4294
4295 2016-01-18 Yao Qi <yao.qi@linaro.org>
4296
4297 * linux-low.c (linux_set_pc_64bit): New function.
4298 (linux_get_pc_64bit): New function.
4299 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
4300 Declare.
4301 * linux-sparc-low.c (debug_threads): Remove declaration.
4302 (sparc_get_pc): Remove.
4303 (the_low_target): Use linux_get_pc_64bit instead of
4304 sparc_get_pc.
4305 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
4306 (the_low_target): Use linux_get_pc_64bit and
4307 linux_set_pc_64bit.
4308
4309 2016-01-18 Yao Qi <yao.qi@linaro.org>
4310
4311 * linux-arm-low.c (debug_threads): Remove declaration.
4312 (arm_get_pc, arm_set_pc): Remove.
4313 (the_low_target): Use linux_get_pc_32bit and
4314 linux_set_pc_32bit.
4315 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
4316 (the_low_target): Use linux_get_pc_32bit and
4317 linux_set_pc_32bit.
4318 * linux-cris-low.c (debug_threads): Remove declaration.
4319 (cris_get_pc, cris_set_pc,): Remove.
4320 (the_low_target): Use linux_get_pc_32bit and
4321 linux_set_pc_32bit.
4322 * linux-crisv32-low.c (debug_threads): Remove declaration.
4323 (cris_get_pc, cris_set_pc): Remove.
4324 (the_low_target): Use linux_get_pc_32bit and
4325 linux_set_pc_32bit.
4326 * linux-low.c: Include inttypes.h.
4327 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
4328 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
4329 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
4330 (the_low_target): Use linux_get_pc_32bit and
4331 linux_set_pc_32bit.
4332 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
4333 (the_low_target): Use linux_get_pc_32bit and
4334 linux_set_pc_32bit.
4335 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
4336 (the_low_target): Use linux_get_pc_32bit and
4337 linux_set_pc_32bit.
4338 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
4339 (the_low_target): Use linux_get_pc_32bit and
4340 linux_set_pc_32bit.
4341 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
4342 (the_low_target): Use linux_get_pc_32bit and
4343 linux_set_pc_32bit.
4344
4345 2016-01-18 Gary Benson <gbenson@redhat.com>
4346
4347 * configure.ac (AC_FUNC_FORK): New check.
4348 * config.in: Regenerate.
4349 * configure: Likewise.
4350
4351 2016-01-14 Yao Qi <yao.qi@linaro.org>
4352
4353 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
4354 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
4355 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
4356 arm_get_next_pcs_ctor.
4357
4358 2016-01-12 Josh Stone <jistone@redhat.com>
4359 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4360
4361 * inferiors.h: Include "gdb_vecs.h".
4362 (struct process_info): Add syscalls_to_catch.
4363 * inferiors.c (remove_process): Free syscalls_to_catch.
4364 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
4365 syscall_return stops.
4366 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
4367 * server.c (handle_general_set): Handle QCatchSyscalls.
4368 (handle_query): Report support for QCatchSyscalls.
4369 * target.h (struct target_ops): Add supports_catch_syscall.
4370 (target_supports_catch_syscall): New macro.
4371 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
4372 (struct lwp_info): Add syscall_state.
4373 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
4374 Maintain syscall_state and syscalls_to_catch across exec.
4375 (get_syscall_trapinfo): New function, proxy to the_low_target.
4376 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
4377 (linux_low_filter_event): Toggle syscall_state entry/return for
4378 syscall traps, and set it ignored for all others.
4379 (gdb_catching_syscalls_p): New function.
4380 (gdb_catch_this_syscall_p): New function.
4381 (linux_wait_1): Handle SYSCALL_SIGTRAP.
4382 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
4383 (linux_supports_catch_syscall): New function.
4384 (linux_target_ops): Install it.
4385 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
4386 (the_low_target): Install it.
4387
4388 2016-01-12 Mike Frysinger <vapier@gentoo.org>
4389
4390 * acinclude.m4: Include new ../warning.m4 file.
4391 * configure: Regenerated.
4392 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
4393
4394 2016-01-12 Mike Frysinger <vapier@gentoo.org>
4395
4396 * ax.c (is_goto_target): Mark static.
4397 * linux-low.c (register_addr): Likewise.
4398 (linux_fetch_registers, linux_store_registers): Likewise.
4399 * mem-break.c (any_persistent_commands): Fix old prototype.
4400 (add_commands_to_breakpoint): Mark static.
4401 * regcache.c (find_register_by_name): Delete unused func.
4402 * remote-utils.c (hex_or_minus_one): Mark static.
4403 * server.c (monitor_show_help): Mark static.
4404 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
4405 handle_v_requests): Likewise.
4406
4407 2016-01-12 Pedro Alves <palves@redhat.com>
4408
4409 Remove use of the registered trademark symbol throughout.
4410
4411 2016-01-08 Yao Qi <yao.qi@linaro.org>
4412
4413 * remote-utils.c (getpkt): If c is '\003', call target hook
4414 request_interrupt.
4415
4416 2016-01-06 Yao Qi <yao.qi@linaro.org>
4417
4418 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
4419 linux-aarch32-low.c.
4420 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4421 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
4422 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4423 (thumb2_breakpoint): Declare.
4424 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
4425 linux-aarch32-low.h.
4426 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4427 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
4428 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4429
4430 2016-01-01 Joel Brobecker <brobecker@adacore.com>
4431
4432 * gdbreplay.c (gdbreplay_version): Change copyright year in
4433 version message.
4434 * server.c (gdbserver_version): Likewise.
4435
4436 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
4437
4438 * server.c (crc32_table): Delete.
4439 (crc32): Use libiberty's xcrc32 function.
4440
4441 2015-12-22 Joel Brobecker <brobecker@adacore.com>
4442
4443 * lynx-low.c (lynx_delete_thread_callback): New function.
4444 (lynx_mourn): Properly delete our process and all of its
4445 threads. Remove call to clear_inferiors.
4446
4447 2015-12-22 Joel Brobecker <brobecker@adacore.com>
4448
4449 * target.c (thread_search_callback): Add check that
4450 the thread_stopped target callback is not NULL before
4451 calling it.
4452
4453 2015-12-21 Yao Qi <yao.qi@linaro.org>
4454
4455 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
4456 arm breakpoint.
4457
4458 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4459
4460 * server.c (handle_query): Call target_supports_software_single_step.
4461
4462 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4463
4464 * linux-low.c (single_step): New function.
4465 (linux_resume_one_lwp_throw): Call single_step.
4466 (start_step_over): Likewise.
4467
4468 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4469
4470 * Makefile.in (SFILES): Append arch/arm-linux.c,
4471 arch/arm-get-next-pcs.c.
4472 (arm-linux.o): New rule.
4473 (arm-get-next-pcs.o): New rule.
4474 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
4475 arm-linux.o.
4476 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
4477 to linux-aarch32-low.c.
4478 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4479 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4480 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4481 (thumb2_breakpoint_len): Likewise.
4482 (arm_is_thumb_mode): Make non-static.
4483 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
4484 from linux-aarch32-low.c.
4485 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4486 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4487 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4488 (thumb2_breakpoint_len): Likewise.
4489 (arm_is_thumb_mode): New declaration.
4490 * linux-arm-low.c: Include arch/arm-linux.h
4491 aarch/arm-get-next-pcs.h, sys/syscall.h.
4492 (get_next_pcs_ops): New struct.
4493 (get_next_pcs_addr_bits_remove): New function.
4494 (get_next_pcs_is_thumb): New function.
4495 (get_next_pcs_read_memory_unsigned_integer): Likewise.
4496 (arm_sigreturn_next_pc): Likewise.
4497 (get_next_pcs_syscall_next_pc): Likewise.
4498 (arm_gdbserver_get_next_pcs): Likewise.
4499 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
4500 Initialize.
4501 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
4502 * server.h: Include gdb_vecs.h.
4503
4504 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4505
4506 * Makefile.in (SFILES): Append common/common-regcache.c.
4507 (OBS): Append common-regcache.o.
4508 (common-regcache.o): New rule.
4509 * regcache.c (init_register_cache): Initialize cache to
4510 REG_UNAVAILABLE.
4511 (regcache_raw_read_unsigned): New function.
4512 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
4513 register_status enum.
4514
4515 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4516
4517 * linux-aarch64-low.c (the_low_targets): Rename
4518 breakpoint_reinsert_addr to get_next_pcs.
4519 * linux-arm-low.c (the_low_targets): Likewise.
4520 * linux-bfin-low.c (the_low_targets): Likewise.
4521 * linux-cris-low.c (the_low_targets): Likewise.
4522 * linux-crisv32-low.c (the_low_targets): Likewise.
4523 * linux-low.c (can_software_single_step): Likewise.
4524 (install_software_single_step_breakpoints): New function.
4525 (start_step_over): Use install_software_single_step_breakpoints.
4526 * linux-low.h: New CORE_ADDR vector.
4527 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
4528 get_next_pcs.
4529 * linux-mips-low.c (the_low_targets): Likewise.
4530 * linux-nios2-low.c (the_low_targets): Likewise.
4531 * linux-sparc-low.c (the_low_targets): Likewise.
4532
4533 2015-12-17 Pedro Alves <palves@redhat.com>
4534
4535 * linux-low.c (linux_kill_one_lwp): Remove references to
4536 LinuxThreads.
4537 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
4538 to 'kill'.
4539 (linux_init_signals): Delete.
4540 (initialize_low): Adjust.
4541 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
4542
4543 2015-12-16 Pedro Alves <palves@redhat.com>
4544
4545 * configure.ac (compiler warning flags): When testing a
4546 -Wno-foo option, check whether -Wfoo works instead.
4547 * configure: Regenerate.
4548
4549 2015-12-11 Don Breazeal <donb@codesourcery.com>
4550
4551 * server.c (process_serial_event): Don't exit from gdbserver
4552 in remote mode if there are still active inferiors.
4553
4554 2015-12-11 Yao Qi <yao.qi@linaro.org>
4555
4556 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
4557 arm_breakpoint_at if the process is 32-bit.
4558
4559 2015-12-11 Yao Qi <yao.qi@linaro.org>
4560
4561 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
4562 arm breakpoint.
4563
4564 2015-12-07 Yao Qi <yao.qi@linaro.org>
4565
4566 * configure.srv: Append arm.o to srv_tgtobj for
4567 aarch64*-*-linux* target.
4568 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
4569 from linux-arm-low.c.
4570 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4571 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4572 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4573 (thumb2_breakpoint_len): Likewise.
4574 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
4575 (arm_breakpoint_kinds): Likewise.
4576 (arm_breakpoint_kind_from_pc): Likewise.
4577 (arm_sw_breakpoint_from_kind): Likewise.
4578 (arm_breakpoint_kind_from_current_state): Likewise.
4579 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
4580 (arm_sw_breakpoint_from_kind): Declare.
4581 (arm_breakpoint_kind_from_current_state): Declare.
4582 (arm_breakpoint_at): Declare.
4583 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
4584 arm_sw_breakpoint_from_kind if process is 32-bit.
4585 (aarch64_breakpoint_kind_from_pc): New function.
4586 (aarch64_breakpoint_kind_from_current_state): New function.
4587 (the_low_target): Initialize fields breakpoint_kind_from_pc
4588 and breakpoint_kind_from_current_state.
4589 * linux-arm-low.c (arm_breakpoint_kinds): Move to
4590 linux-aarch32-low.c.
4591 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
4592 (arm_breakpoint, arm_breakpoint_len): Likewise.
4593 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
4594 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4595 (arm_is_thumb_mode): Likewise.
4596 (arm_breakpoint_at): Likewise.
4597 (arm_breakpoint_kind_from_pc): Likewise.
4598 (arm_sw_breakpoint_from_kind): Likewise.
4599 (arm_breakpoint_kind_from_current_state): Likewise.
4600
4601 Revert:
4602 2015-08-04 Yao Qi <yao.qi@linaro.org>
4603
4604 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
4605 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
4606 * server.c (extended_protocol): Remove "static".
4607 * server.h (extended_protocol): Declare it.
4608
4609 2015-12-04 Josh Stone <jistone@redhat.com>
4610
4611 * target.h (struct target_ops) <arch_setup>: Rename to ...
4612 (struct target_ops) <post_create_inferior>: ... this.
4613 (target_arch_setup): Rename to ...
4614 (target_post_create_inferior): ... this, calling post_create_inferior.
4615 * server.c (start_inferior): Update target_arch_setup calls to
4616 target_post_create_inferior.
4617 * linux-low.c (linux_low_ptrace_options): Forward declare.
4618 (linux_arch_setup): Update its comment for general use.
4619 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
4620 (struct linux_target_ops): Use linux_post_create_inferior.
4621 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
4622 to post_create_inferior.
4623 * nto-low.c (struct nto_target_ops): Likewise.
4624 * spu-low.c (struct spu_target_ops): Likewise.
4625 * win32-low.c (struct win32_target_ops): Likewise.
4626
4627 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
4628
4629 * linux-arm-low.c: Remove duplicate arch/arm.h include.
4630
4631 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4632
4633 * linux-arm-low.c (arm_reinsert_addr): Remove function.
4634 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
4635 * linux-cris-low.c (cris_reinsert_addr> Remove function.
4636 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4637 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
4638 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4639 * linux-mips-low.c (mips_reinsert_addr): Remove function.
4640 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4641 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
4642 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4643 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
4644 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4645
4646 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4647
4648 * linux-low.c (linux_look_up_symbols): Don't call
4649 linux_supports_traceclone.
4650 * linux-low.h (thread_db_init): Remove use_events argument.
4651 * thread-db.c (thread_db_use_event): Remove global variable.
4652 (struct thread_db) <td_thr_event_enable_p>: Remove field.
4653 (struct thread_db) <td_create_bp>: Remove field.
4654 (thread_db_create_event): Remove function.
4655 (thread_db_enable_reporting): Likewise.
4656 (find_one_thread): Don't check for thread_db_use_events.
4657 (attach_thread): Likewise.
4658 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
4659 (try_thread_db_load_1): Don't check for thread_db_use_events.
4660 (thread_db_init): Remove use_events argument and thread events
4661 handling.
4662 (remove_thread_event_breakpoints): Remove function.
4663 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
4664
4665 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4666
4667 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
4668 New function.
4669 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4670 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
4671 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4672 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
4673 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
4674 Initialize.
4675 * linux-crisv32-low.c (cris_supports_hardware_single_step):
4676 New function.
4677 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4678 * linux-low.c (can_hardware_single_step): Use
4679 supports_hardware_single_step.
4680 (can_software_single_step): New function.
4681 (start_step_over): Call can_software_single_step.
4682 (linux_supports_hardware_single_step): New function.
4683 (struct target_ops) <supports_software_single_step>: Initialize.
4684 * linux-low.h (struct linux_target_ops)
4685 <supports_hardware_single_step>: Initialize.
4686 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
4687 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4688 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
4689 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
4690 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
4691 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4692 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
4693 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4694 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
4695 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
4696 Initialize.
4697 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
4698 (struct linux_target_ops) <tile_supports_hardware_single_step>:
4699 Initialize.
4700 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
4701 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4702 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
4703 New function.
4704 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4705 * target.h (struct target_ops): <supports_software_single_step>:
4706 New field.
4707 (target_supports_software_single_step): New macro.
4708
4709 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4710
4711 * linux-low.c (linux_wait_1): Fix pc advance condition.
4712 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
4713 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
4714
4715 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4716
4717 * linux-arm-low.c (arm_is_thumb_mode): New function.
4718 (arm_breakpoint_at): Use arm_is_thumb_mode.
4719 (arm_breakpoint_kind_from_current_state): New function.
4720 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
4721 Initialize.
4722 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
4723 (linux_breakpoint_kind_from_current_state): New function.
4724 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
4725 * linux-low.h (struct linux_target_ops)
4726 <breakpoint_kind_from_current_state>: New field.
4727 * target.h (struct target_ops): Likewise.
4728 (target_breakpoint_kind_from_current_state): New macro.
4729
4730 2015-11-30 Pedro Alves <palves@redhat.com>
4731
4732 * linux-low.c (linux_resume): Wake up the event loop before
4733 returning.
4734
4735 2015-11-30 Pedro Alves <palves@redhat.com>
4736
4737 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
4738 check.
4739 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
4740 to -1.
4741 * target.c (struct thread_search): New structure.
4742 (thread_search_callback): New function.
4743 (prev_general_thread): New global.
4744 (prepare_to_access_memory, done_accessing_memory): New functions.
4745 * target.h (prepare_to_access_memory, done_accessing_memory):
4746 Replace macros with function declarations.
4747
4748 2015-11-30 Pedro Alves <palves@redhat.com>
4749
4750 PR 14618
4751 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
4752 report TARGET_WAITKIND_NO_RESUMED.
4753 * remote-utils.c (prepare_resume_reply): Handle
4754 TARGET_WAITKIND_NO_RESUMED.
4755 * server.c (report_no_resumed): New global.
4756 (handle_query) <qSupported>: Handle "no-resumed+". Report
4757 "no-resumed+" support.
4758 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
4759 return error if the client doesn't support no-resumed events.
4760 (push_stop_notification): New function.
4761 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
4762 events if the client supports them.
4763
4764 2015-11-30 Pedro Alves <palves@redhat.com>
4765
4766 * linux-low.c (thread_still_has_status_pending_p): Don't check
4767 vCont;t here.
4768 (lwp_resumed): New function.
4769 (status_pending_p_callback): Return early if the LWP is not
4770 supposed to be resumed.
4771
4772 2015-11-30 Pedro Alves <palves@redhat.com>
4773
4774 * linux-low.c (handle_extended_wait): Assert that the LWP's
4775 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
4776 thread create events, leave the new child's status pending.
4777 (linux_low_filter_event): If GDB wants to hear about thread exit
4778 events, leave the LWP marked dead and don't delete it.
4779 (linux_wait_for_event_filtered): Don't check for thread exit.
4780 (filter_exit_event): New function.
4781 (linux_wait_1): Use it, when returning an exit event.
4782 (linux_resume_one_lwp_throw): Assert that the LWP's
4783 waitstatus is TARGET_WAITKIND_IGNORE.
4784 * remote-utils.c (prepare_resume_reply): Handle
4785 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
4786 * server.c (report_thread_events): New global.
4787 (handle_general_set): Handle QThreadEvents.
4788 (handle_query) <qSupported>: Handle and report QThreadEvents+;
4789 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
4790 TARGET_WAITKIND_THREAD_EXITED.
4791 * server.h (report_thread_events): Declare.
4792
4793 2015-11-30 Pedro Alves <palves@redhat.com>
4794
4795 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
4796 the thread's last_resume_kind was resume_stop.
4797
4798 2015-11-30 Pedro Alves <palves@redhat.com>
4799
4800 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
4801 before returning.
4802
4803 2015-11-30 Pedro Alves <palves@redhat.com>
4804
4805 * server.c (handle_v_requests): Handle vCtrlC.
4806
4807 2015-11-30 Pedro Alves <palves@redhat.com>
4808
4809 * gdbthread.h (find_any_thread_of_pid): Declare.
4810 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
4811 functions.
4812 * server.c (handle_query): If current_thread is NULL, look for
4813 another thread of the selected process.
4814
4815 2015-11-26 Daniel Colascione <dancol@dancol.org>
4816 Simon Marchi <simon.marchi@ericsson.com>
4817
4818 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
4819 * server.c (handle_qxfer_threads_worker): Refactor to include thread
4820 name in reply.
4821 * target.h (struct target_ops) <thread_name>: New field.
4822 (target_thread_name): New macro.
4823
4824 2015-11-23 Joel Brobecker <brobecker@adacore.com>
4825
4826 * regcache.h (regcache_invalidate_pid): Add declaration.
4827 * regcache.c (regcache_invalidate_pid): New function, extracted
4828 from regcache_invalidate.
4829 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
4830 Add trivial documentation comment.
4831 * lynx-low.c: Use regcache_invalidate_pid instead of
4832 regcache_invalidate.
4833
4834 2015-11-23 Joel Brobecker <brobecker@adacore.com>
4835
4836 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
4837 and Elf64_auxv_t if the target is Android.
4838
4839 2015-11-22 Doug Evans <xdje42@gmail.com>
4840
4841 * target.h: #include <sys/types.h>.
4842
4843 2015-11-19 Pedro Alves <palves@redhat.com>
4844
4845 * linux-low.c (linux_process_qsupported): Change prototype.
4846 Adjust.
4847 * linux-low.h (struct linux_target_ops) <process_qsupported>:
4848 Change prototype.
4849 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
4850 and adjust to loop over all features.
4851 * server.c (handle_query) <qSupported>: Adjust to call
4852 target_process_qsupported once, passing it a vector of unprocessed
4853 features.
4854 * target.h (struct target_ops) <process_qsupported>: Change
4855 prototype.
4856 (target_process_qsupported): Adjust.
4857
4858 2015-11-19 Pedro Alves <palves@redhat.com>
4859
4860 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
4861 mode.
4862 * configure: Regenerate.
4863
4864 2015-11-19 Pedro Alves <palves@redhat.com>
4865
4866 * configure: Regenerate.
4867
4868 2015-11-19 Yao Qi <yao.qi@linaro.org>
4869
4870 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
4871 type to uint32_t.
4872
4873 2015-11-19 Yao Qi <yao.qi@linaro.org>
4874
4875 * linux-aarch64-low.c (enum aarch64_operand_type): New.
4876 (struct aarch64_operand): Move enum out.
4877
4878 2015-11-19 Yao Qi <yao.qi@linaro.org>
4879
4880 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
4881 struct user_fpsimd_state *.
4882 (aarch64_store_fpregset): Likewise.
4883
4884 2015-11-19 Yao Qi <yao.qi@linaro.org>
4885
4886 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
4887 struct user_pt_regs *.
4888 (aarch64_store_gregset): Likewise.
4889
4890 2015-11-18 Pedro Alves <palves@redhat.com>
4891
4892 * Makefile.in (all_object_files): Add $IPA_OBJS.
4893
4894 2015-11-17 Pedro Alves <palves@redhat.com>
4895
4896 * win32-low.c (win32_resume): Use gdb_signal_from_host,
4897 GDB_SIGNAL_0 and gdb_signal_to_string.
4898
4899 2015-11-17 Pedro Alves <palves@redhat.com>
4900
4901 * win32-low.c (handle_output_debug_string): Remove parameter.
4902 (win32_kill): Remove our_status local and adjust call to
4903 handle_output_debug_string.
4904 (get_child_debug_event): Adjust call to
4905 handle_output_debug_string.
4906
4907 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4908
4909 * linux-mips-low.c (mips_fill_gregset): Add cast.
4910 (mips_store_gregset): Likewise.
4911 (mips_fill_fpregset): Likewise.
4912 (mips_store_fpregset): Likewise.
4913
4914 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4915
4916 * linux-mips-low.c (mips_add_watchpoint): Rename private to
4917 priv.
4918
4919 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4920
4921 * linux-mips-low.c (mips_linux_new_thread): Change type of
4922 watch_type to enum target_hw_bp_type.
4923
4924 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4925
4926 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
4927 Change return type to arm_hwbp_type.
4928
4929 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4930
4931 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
4932 (arm_store_gregset): Likewise.
4933 * linux-arm-low.c (arm_get_hwcap): Likewise.
4934 (arm_read_description): Likewise.
4935
4936 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4937
4938 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
4939
4940 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4941
4942 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
4943 (ppc_fill_vsxregset): Likewise.
4944 (ppc_store_vsxregset): Likewise.
4945 (ppc_fill_vrregset): Likewise.
4946 (ppc_store_vrregset): Likewise.
4947 (ppc_fill_evrregset): Likewise.
4948 (ppc_store_evrregset): Likewise.
4949
4950 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4951
4952 * linux-ppc-low.c (ppc_usrregs_info): Remove
4953 forward-declaration.
4954 (ppc_arch_setup): Move lower in file.
4955
4956 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
4957
4958 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
4959 (ps_pdwrite): Likewise.
4960
4961 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
4962
4963 * linux-arm-low.c (arm_new_thread): Move pointer dereference
4964 to after assert checks.
4965
4966 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
4967
4968 * proc-service.c (ps_pdread): Add/adjust casts.
4969 (ps_pdwrite): Add/adjust casts.
4970
4971 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
4972
4973 * server.c (handle_search_memory_1): Cast return value of
4974 memmem.
4975
4976 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
4977
4978 * server.c (write_qxfer_response): Change type of data to
4979 gdb_byte *.
4980
4981 2015-10-29 Pedro Alves <palves@redhat.com>
4982
4983 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
4984
4985 2015-10-29 Pedro Alves <palves@redhat.com>
4986
4987 * tracepoint.c (clear_installed_tracepoints): Add casts.
4988
4989 2015-10-29 Pedro Alves <palves@redhat.com>
4990
4991 * server.c (handle_v_cont, process_serial_event): Add enum
4992 gdb_signal casts to signal parsing code.
4993
4994 2015-10-29 Pedro Alves <palves@redhat.com>
4995
4996 * linux-low.h (NULL_REGSET): Define.
4997 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
4998 * linux-arm-low.c (arm_regsets): Likewise.
4999 * linux-crisv32-low.c (cris_regsets): Likewise.
5000 * linux-m68k-low.c (m68k_regsets): Likewise.
5001 * linux-mips-low.c (mips_regsets): Likewise.
5002 * linux-nios2-low.c (nios2_regsets): Likewise.
5003 * linux-ppc-low.c (ppc_regsets): Likewise.
5004 * linux-s390-low.c (s390_regsets): Likewise.
5005 * linux-sh-low.c (sh_regsets): Likewise.
5006 * linux-sparc-low.c (sparc_regsets): Likewise.
5007 * linux-tic6x-low.c (tic6x_regsets): Likewise.
5008 * linux-tile-low.c (tile_regsets): Likewise.
5009 * linux-x86-low.c (x86_regsets): Likewise.
5010 * linux-xtensa-low.c (xtensa_regsets): Likewise.
5011
5012 2015-10-29 Pedro Alves <palves@redhat.com>
5013
5014 * linux-low.h (NULL_REGSET): Define.
5015 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
5016 * linux-arm-low.c (arm_regsets): Likewise.
5017 * linux-crisv32-low.c (cris_regsets): Likewise.
5018 * linux-m68k-low.c (m68k_regsets): Likewise.
5019 * linux-mips-low.c (mips_regsets): Likewise.
5020 * linux-nios2-low.c (nios2_regsets): Likewise.
5021 * linux-ppc-low.c (ppc_regsets): Likewise.
5022 * linux-s390-low.c (s390_regsets): Likewise.
5023 * linux-sh-low.c (sh_regsets): Likewise.
5024 * linux-sparc-low.c (sparc_regsets): Likewise.
5025 * linux-tic6x-low.c (tic6x_regsets): Likewise.
5026 * linux-tile-low.c (tile_regsets): Likewise.
5027 * linux-x86-low.c (x86_regsets): Likewise.
5028 * linux-xtensa-low.c (xtensa_regsets): Likewise.
5029
5030 2015-10-26 Doug Evans <dje@google.com>
5031
5032 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
5033
5034 2015-10-26 Doug Evans <dje@google.com>
5035
5036 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
5037
5038 2015-10-26 Doug Evans <dje@google.com>
5039
5040 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
5041 for debug_printf.
5042 (attach_thread, find_new_threads_callback): Ditto.
5043
5044 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5045
5046 * mem-break.h (set_breakpoint_data): Remove.
5047
5048 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5049
5050 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
5051 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
5052 (initialize_low): Remove set_breakpoint_data call.
5053 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
5054 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
5055 (initialize_low): Remove set_breakpoint_data call.
5056 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
5057 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
5058 (initialize_low): Remove set_breakpoint_data call.
5059
5060 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5061
5062 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
5063 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
5064 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
5065 * target.h (target_breakpoint_kind_from_pc): New macro.
5066
5067 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
5068
5069 * linux-low.c (default_breakpoint_kind_from_pc): New function.
5070 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
5071 the default breakpoint kind.
5072
5073 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5074
5075 * linux-arm-low.c (arm_supports_z_point_type): Add software
5076 breakpoint support.
5077
5078 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5079
5080 * linux-arm-low.c: Refactor breakpoint definitions.
5081 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
5082 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
5083
5084 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5085
5086 * Makefile.in: Add arm.c/o.
5087 * configure.srv: Likewise.
5088 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
5089 (arm_breakpoint_kind_from_pc): New function.
5090 (arm_sw_breakpoint_from_kind): Return proper kind.
5091 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
5092
5093 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5094
5095 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
5096 removal.
5097 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
5098 (struct raw_breakpoint) <size>: Remove.
5099 (struct raw_breakpoint) <kind>: Add.
5100 (bp_size): New function.
5101 (bp_opcode): Likewise.
5102 (find_raw_breakpoint_at): Adjust for kind.
5103 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
5104 (remove_memory_breakpoint): Adjust for kind call bp_size.
5105 (set_raw_breakpoint_at): Adjust for kind.
5106 (set_breakpoint): Likewise.
5107 (set_breakpoint_at): Call breakpoint_kind_from_pc.
5108 (delete_raw_breakpoint): Adjust for kind.
5109 (delete_breakpoint): Likewise.
5110 (find_gdb_breakpoint): Likewise.
5111 (set_gdb_breakpoint_1): Likewise.
5112 (set_gdb_breakpoint): Likewise.
5113 (delete_gdb_breakpoint_1): Likewise.
5114 (delete_gdb_breakpoint): Likewise.
5115 (uninsert_raw_breakpoint): Likewise.
5116 (reinsert_raw_breakpoint): Likewise.
5117 (set_breakpoint_data): Remove.
5118 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
5119 (check_mem_read): Adjust for kind call bp_size.
5120 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
5121 (clone_one_breakpoint): Adjust for kind.
5122 * mem-break.h (set_gdb_breakpoint): Likewise.
5123 (delete_gdb_breakpoint): Likewise.
5124 * server.c (process_serial_event): Likewise.
5125
5126 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5127
5128 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
5129 (struct linux_target_ops) <breakpoint>: Remove.
5130 (struct linux_target_ops) <breakpoint_len>: Remove.
5131 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5132 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5133 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
5134 (arm_sw_breakpoint_from_kind): New function.
5135 * linux-bfin-low.c (bfin_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-cris-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-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
5146 (struct linux_target_ops) <breakpoint>: Remove.
5147 (struct linux_target_ops) <breakpoint_len>: Remove.
5148 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5149 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5150 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
5151 and sw_breakpoint_from_kind to increment the pc.
5152 (linux_breakpoint_kind_from_pc): New function.
5153 (linux_sw_breakpoint_from_kind): New function.
5154 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
5155 (initialize_low): Call breakpoint_kind_from_pc and
5156 sw_breakpoint_from_kind to replace breakpoint_data/len.
5157 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
5158 New field.
5159 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
5160 * linux-m32r-low.c (m32r_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-m68k-low.c (m68k_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-mips-low.c (mips_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-nios2-low.c (nios2_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-ppc-low.c (ppc_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-s390-low.c (s390_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-sh-low.c (sh_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-sparc-low.c (sparc_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-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
5201 (struct linux_target_ops) <breakpoint>: Remove.
5202 (struct linux_target_ops) <breakpoint_len>: Remove.
5203 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5204 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5205 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
5206 * linux-x86-low.c (x86_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 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
5212 (struct linux_target_ops) <breakpoint>: Remove.
5213 (struct linux_target_ops) <breakpoint_len>: Remove.
5214 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5215 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5216
5217 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5218
5219 * linux-cris-low.c (cris_get_pc): Remove void arg.
5220
5221 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
5222
5223 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
5224 variable name.
5225
5226 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
5227
5228 * inferiors.c (thread_pid_matches_callback): New function.
5229 (find_thread_process): New function.
5230 (remove_thread): Reset current_thread.
5231 (remove_process): Assert threads have been removed first.
5232
5233 2015-10-15 Yao Qi <yao.qi@linaro.org>
5234
5235 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
5236 if it is 3.
5237 (aarch64_remove_point): Likewise.
5238 * regcache.c (regcache_register_size): New function.
5239
5240 2015-10-12 Yao Qi <yao.qi@linaro.org>
5241
5242 * linux-aarch64-low.c: Update all callers as emit_load_store
5243 is renamed to aarch64_emit_load_store.
5244
5245 2015-10-12 Yao Qi <yao.qi@linaro.org>
5246
5247 * linux-aarch64-low.c: Update all callers of function renaming
5248 from emit_insn to aarch64_emit_insn.
5249
5250 2015-10-12 Yao Qi <yao.qi@linaro.org>
5251
5252 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
5253 arch/aarch64-insn.h.
5254 (struct aarch64_memory_operand): Likewise.
5255 (ENCODE): Likewise.
5256 (emit_insn): Move to arch/aarch64-insn.c.
5257 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
5258 (emit_load_store): Move to arch/aarch64-insn.c.
5259 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
5260 (can_encode_int32): Remove.
5261
5262 2015-10-12 Yao Qi <yao.qi@linaro.org>
5263
5264 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
5265 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
5266 (aarch64_relocate_instruction): Likewise.
5267 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
5268 (struct aarch64_insn_visitor): Likewise.
5269
5270 2015-10-12 Yao Qi <yao.qi@linaro.org>
5271
5272 * linux-aarch64-low.c (struct aarch64_insn_data): New.
5273 (struct aarch64_insn_visitor): New.
5274 (struct aarch64_insn_relocation_data): New.
5275 (aarch64_ftrace_insn_reloc_b): New function.
5276 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
5277 (aarch64_ftrace_insn_reloc_cb): Likewise.
5278 (aarch64_ftrace_insn_reloc_tb): Likewise.
5279 (aarch64_ftrace_insn_reloc_adr): Likewise.
5280 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
5281 (aarch64_ftrace_insn_reloc_others): Likewise.
5282 (visitor): New.
5283 (aarch64_relocate_instruction): Use visitor.
5284
5285 2015-10-12 Yao Qi <yao.qi@linaro.org>
5286
5287 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
5288 int. Add argument buf.
5289 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
5290 aarch64_relocate_instruction.
5291
5292 2015-10-12 Yao Qi <yao.qi@linaro.org>
5293
5294 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
5295 argument insn. Remove local variable insn. Don't call
5296 target_read_uint32.
5297 (aarch64_install_fast_tracepoint_jump_pad): Call
5298 target_read_uint32.
5299
5300 2015-09-30 Yao Qi <yao.qi@linaro.org>
5301
5302 * linux-aarch64-low.c (emit_movk): Shorten a long line.
5303 (emit_load_store_pair): Likewise.
5304
5305 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
5306
5307 * dll.c (match_dll): Add cast(s).
5308 (unloaded_dll): Likewise.
5309 * linux-low.c (second_thread_of_pid_p): Likewise.
5310 (delete_lwp_callback): Likewise.
5311 (count_events_callback): Likewise.
5312 (select_event_lwp_callback): Likewise.
5313 (linux_set_resume_request): Likewise.
5314 * server.c (accumulate_file_name_length): Likewise.
5315 (emit_dll_description): Likewise.
5316 (handle_qxfer_threads_worker): Likewise.
5317 (visit_actioned_threads): Likewise.
5318 * thread-db.c (any_thread_of): Likewise.
5319 * tracepoint.c (same_process_p): Likewise.
5320 (match_blocktype): Likewise.
5321 (build_traceframe_info_xml): Likewise.
5322
5323 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
5324
5325 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
5326 assignment.
5327 (gdb_unparse_agent_expr): Likewise.
5328 * hostio.c (require_data): Likewise.
5329 (handle_pread): Likewise.
5330 * linux-low.c (disable_regset): Likewise.
5331 (fetch_register): Likewise.
5332 (store_register): Likewise.
5333 (get_dynamic): Likewise.
5334 (linux_qxfer_libraries_svr4): Likewise.
5335 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
5336 (set_fast_tracepoint_jump): Likewise.
5337 (uninsert_fast_tracepoint_jumps_at): Likewise.
5338 (reinsert_fast_tracepoint_jumps_at): Likewise.
5339 (validate_inserted_breakpoint): Likewise.
5340 (clone_agent_expr): Likewise.
5341 * regcache.c (init_register_cache): Likewise.
5342 * remote-utils.c (putpkt_binary_1): Likewise.
5343 (decode_M_packet): Likewise.
5344 (decode_X_packet): Likewise.
5345 (look_up_one_symbol): Likewise.
5346 (relocate_instruction): Likewise.
5347 (monitor_output): Likewise.
5348 * server.c (handle_search_memory): Likewise.
5349 (handle_qxfer_exec_file): Likewise.
5350 (handle_qxfer_libraries): Likewise.
5351 (handle_qxfer): Likewise.
5352 (handle_query): Likewise.
5353 (handle_v_cont): Likewise.
5354 (handle_v_run): Likewise.
5355 (captured_main): Likewise.
5356 * target.c (write_inferior_memory): Likewise.
5357 * thread-db.c (try_thread_db_load_from_dir): Likewise.
5358 * tracepoint.c (init_trace_buffer): Likewise.
5359 (add_tracepoint_action): Likewise.
5360 (add_traceframe): Likewise.
5361 (add_traceframe_block): Likewise.
5362 (cmd_qtdpsrc): Likewise.
5363 (cmd_qtdv): Likewise.
5364 (cmd_qtstatus): Likewise.
5365 (response_source): Likewise.
5366 (response_tsv): Likewise.
5367 (cmd_qtnotes): Likewise.
5368 (gdb_collect): Likewise.
5369 (initialize_tracepoint): Likewise.
5370
5371 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5372
5373 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
5374 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
5375 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
5376 <NOP>: New.
5377 (enum aarch64_condition_codes): New enum.
5378 (w0): New static global.
5379 (fp): Likewise.
5380 (lr): Likewise.
5381 (struct aarch64_memory_operand) <type>: New
5382 MEMORY_OPERAND_POSTINDEX type.
5383 (postindex_memory_operand): New helper function.
5384 (emit_ret): New function.
5385 (emit_load_store_pair): New function, factored out of emit_stp
5386 with support for MEMORY_OPERAND_POSTINDEX.
5387 (emit_stp): Rewrite using emit_load_store_pair.
5388 (emit_ldp): New function.
5389 (emit_load_store): Likewise.
5390 (emit_ldr): Mention post-index instruction in comment.
5391 (emit_ldrh): New function.
5392 (emit_ldrb): New function.
5393 (emit_ldrsw): Mention post-index instruction in comment.
5394 (emit_str): Likewise.
5395 (emit_subs): New function.
5396 (emit_cmp): Likewise.
5397 (emit_and): Likewise.
5398 (emit_orr): Likewise.
5399 (emit_orn): Likewise.
5400 (emit_eor): Likewise.
5401 (emit_mvn): Likewise.
5402 (emit_lslv): Likewise.
5403 (emit_lsrv): Likewise.
5404 (emit_asrv): Likewise.
5405 (emit_mul): Likewise.
5406 (emit_sbfm): Likewise.
5407 (emit_sbfx): Likewise.
5408 (emit_ubfm): Likewise.
5409 (emit_ubfx): Likewise.
5410 (emit_csinc): Likewise.
5411 (emit_cset): Likewise.
5412 (emit_nop): Likewise.
5413 (emit_ops_insns): New helper function.
5414 (emit_pop): Likewise.
5415 (emit_push): Likewise.
5416 (aarch64_emit_prologue): New function.
5417 (aarch64_emit_epilogue): Likewise.
5418 (aarch64_emit_add): Likewise.
5419 (aarch64_emit_sub): Likewise.
5420 (aarch64_emit_mul): Likewise.
5421 (aarch64_emit_lsh): Likewise.
5422 (aarch64_emit_rsh_signed): Likewise.
5423 (aarch64_emit_rsh_unsigned): Likewise.
5424 (aarch64_emit_ext): Likewise.
5425 (aarch64_emit_log_not): Likewise.
5426 (aarch64_emit_bit_and): Likewise.
5427 (aarch64_emit_bit_or): Likewise.
5428 (aarch64_emit_bit_xor): Likewise.
5429 (aarch64_emit_bit_not): Likewise.
5430 (aarch64_emit_equal): Likewise.
5431 (aarch64_emit_less_signed): Likewise.
5432 (aarch64_emit_less_unsigned): Likewise.
5433 (aarch64_emit_ref): Likewise.
5434 (aarch64_emit_if_goto): Likewise.
5435 (aarch64_emit_goto): Likewise.
5436 (aarch64_write_goto_address): Likewise.
5437 (aarch64_emit_const): Likewise.
5438 (aarch64_emit_call): Likewise.
5439 (aarch64_emit_reg): Likewise.
5440 (aarch64_emit_pop): Likewise.
5441 (aarch64_emit_stack_flush): Likewise.
5442 (aarch64_emit_zero_ext): Likewise.
5443 (aarch64_emit_swap): Likewise.
5444 (aarch64_emit_stack_adjust): Likewise.
5445 (aarch64_emit_int_call_1): Likewise.
5446 (aarch64_emit_void_call_2): Likewise.
5447 (aarch64_emit_eq_goto): Likewise.
5448 (aarch64_emit_ne_goto): Likewise.
5449 (aarch64_emit_lt_goto): Likewise.
5450 (aarch64_emit_le_goto): Likewise.
5451 (aarch64_emit_gt_goto): Likewise.
5452 (aarch64_emit_ge_got): Likewise.
5453 (aarch64_emit_ops_impl): New static global variable.
5454 (aarch64_emit_ops): New target function, return
5455 &aarch64_emit_ops_impl.
5456 (struct linux_target_ops): Install it.
5457
5458 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5459
5460 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
5461 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
5462 aarch64-ipa.o.
5463 * linux-aarch64-ipa.c: New file.
5464 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
5465 and endian.h.
5466 (aarch64_get_thread_area): New target method.
5467 (extract_signed_bitfield): New helper function.
5468 (aarch64_decode_ldr_literal): New function.
5469 (enum aarch64_opcodes): New enum.
5470 (struct aarch64_register): New struct.
5471 (struct aarch64_operand): New struct.
5472 (x0): New static global.
5473 (x1): Likewise.
5474 (x2): Likewise.
5475 (x3): Likewise.
5476 (x4): Likewise.
5477 (w2): Likewise.
5478 (ip0): Likewise.
5479 (sp): Likewise.
5480 (xzr): Likewise.
5481 (aarch64_register): New helper function.
5482 (register_operand): Likewise.
5483 (immediate_operand): Likewise.
5484 (struct aarch64_memory_operand): New struct.
5485 (offset_memory_operand): New helper function.
5486 (preindex_memory_operand): Likewise.
5487 (enum aarch64_system_control_registers): New enum.
5488 (ENCODE): New macro.
5489 (emit_insn): New helper function.
5490 (emit_b): New function.
5491 (emit_bcond): Likewise.
5492 (emit_cb): Likewise.
5493 (emit_tb): Likewise.
5494 (emit_blr): Likewise.
5495 (emit_stp): Likewise.
5496 (emit_ldp_q_offset): Likewise.
5497 (emit_stp_q_offset): Likewise.
5498 (emit_load_store): Likewise.
5499 (emit_ldr): Likewise.
5500 (emit_ldrsw): Likewise.
5501 (emit_str): Likewise.
5502 (emit_ldaxr): Likewise.
5503 (emit_stxr): Likewise.
5504 (emit_stlr): Likewise.
5505 (emit_data_processing_reg): Likewise.
5506 (emit_data_processing): Likewise.
5507 (emit_add): Likewise.
5508 (emit_sub): Likewise.
5509 (emit_mov): Likewise.
5510 (emit_movk): Likewise.
5511 (emit_mov_addr): Likewise.
5512 (emit_mrs): Likewise.
5513 (emit_msr): Likewise.
5514 (emit_sevl): Likewise.
5515 (emit_wfe): Likewise.
5516 (append_insns): Likewise.
5517 (can_encode_int32_in): New helper function.
5518 (aarch64_relocate_instruction): New function.
5519 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
5520 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
5521 (struct linux_target_ops): Install aarch64_get_thread_area,
5522 aarch64_install_fast_tracepoint_jump_pad and
5523 aarch64_get_min_fast_tracepoint_insn_len.
5524
5525 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5526
5527 * Makefile.in (aarch64-insn.o): New rule.
5528 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
5529
5530 2015-09-21 Yao Qi <yao.qi@linaro.org>
5531
5532 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
5533
5534 2015-09-21 Yao Qi <yao.qi@linaro.org>
5535
5536 * tracepoint.c (max_jump_pad_size): Remove.
5537
5538 2015-09-18 Yao Qi <yao.qi@linaro.org>
5539
5540 * linux-aarch64-low.c: Don't include sys/uio.h.
5541 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
5542
5543 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
5544
5545 * tracepoint.c (eval_result_type): Change prototype.
5546 (condition_true_at_tracepoint): Fix argument to compiled_cond.
5547
5548 2015-09-15 Pedro Alves <palves@redhat.com>
5549
5550 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
5551 Check whether to report exec events instead of checking whether
5552 multiprocess is enabled.
5553
5554 2015-09-15 Pedro Alves <palves@redhat.com>
5555
5556 PR remote/18965
5557 * remote-utils.c (prepare_resume_reply): Merge
5558 TARGET_WAITKIND_VFORK_DONE switch case with the
5559 TARGET_WAITKIND_FORKED case.
5560
5561 2015-09-15 Yao Qi <yao.qi@linaro.org>
5562
5563 * server.c (handle_query): Check string comparison using
5564 "else if" instead of "if".
5565
5566 2015-09-15 Yao Qi <yao.qi@linaro.org>
5567
5568 * server.c (vCont_supported): New global variable.
5569 (handle_query): Set vCont_supported to 1 if "vContSupported+"
5570 matches. Append ";vContSupported+" to own_buf.
5571 (handle_v_requests): Append ";s;S" to own_buf if target supports
5572 hardware single step or vCont_supported is false.
5573 (capture_main): Set vCont_supported to zero.
5574
5575 2015-09-15 Yao Qi <yao.qi@linaro.org>
5576
5577 * linux-low.c (linux_supports_conditional_breakpoints): Rename
5578 it to ...
5579 (linux_supports_hardware_single_step): ... New function.
5580 (linux_target_ops): Update.
5581 * lynx-low.c (lynx_target_ops): Set field
5582 supports_hardware_single_step to target_can_do_hardware_single_step.
5583 * nto-low.c (nto_target_ops): Likewise.
5584 * spu-low.c (spu_target_ops): Likewise.
5585 * win32-low.c (win32_target_ops): Likewise.
5586 * target.c (target_can_do_hardware_single_step): New function.
5587 * target.h (struct target_ops) <supports_conditional_breakpoints>:
5588 Remove. <supports_hardware_single_step>: New field.
5589 (target_supports_conditional_breakpoints): Remove.
5590 (target_supports_hardware_single_step): New macro.
5591 (target_can_do_hardware_single_step): Declare.
5592 * server.c (handle_query): Use target_supports_hardware_single_step
5593 instead of target_supports_conditional_breakpoints.
5594
5595 2015-09-15 Yao Qi <yao.qi@linaro.org>
5596
5597 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
5598 function.
5599 (struct linux_target_ops the_low_target): Install
5600 aarch64_linux_siginfo_fixup.
5601
5602 2015-09-11 Don Breazeal <donb@codesourcery.com>
5603 Luis Machado <lgustavo@codesourcery.com>
5604
5605 * linux-low.c (linux_mourn): Static declaration.
5606 (linux_arch_setup): Move in front of
5607 handle_extended_wait.
5608 (linux_arch_setup_thread): New function.
5609 (handle_extended_wait): Handle exec events. Call
5610 linux_arch_setup_thread. Make event_lwp argument a
5611 pointer-to-a-pointer.
5612 (check_zombie_leaders): Do not check stopped threads.
5613 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
5614 (linux_low_filter_event): Add lwp and thread for exec'ing
5615 non-leader thread if leader thread has been deleted.
5616 Refactor code into linux_arch_setup_thread and call it.
5617 Pass child lwp pointer by reference to handle_extended_wait.
5618 (linux_wait_for_event_filtered): Update comment.
5619 (linux_wait_1): Prevent clobbering exec event status.
5620 (linux_supports_exec_events): New function.
5621 (linux_target_ops) <supports_exec_events>: Initialize new member.
5622 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
5623 new member.
5624 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
5625 * server.c (report_exec_events): New global variable.
5626 (handle_query): Handle qSupported query for exec-events feature.
5627 (captured_main): Initialize report_exec_events.
5628 * server.h (report_exec_events): Declare new global variable.
5629 * target.h (struct target_ops) <supports_exec_events>: New
5630 member.
5631 (target_supports_exec_events): New macro.
5632 * win32-low.c (win32_target_ops) <supports_exec_events>:
5633 Initialize new member.
5634
5635 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
5636
5637 * linux-low.c (linux_low_enable_btrace): Remove.
5638 (linux_target_ops): Replace linux_low_enable_btrace with
5639 linux_enable_btrace.
5640
5641 2015-09-03 Yao Qi <yao.qi@linaro.org>
5642
5643 * linux-aarch64-low.c (aarch64_insert_point): Call
5644 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
5645 returns true.
5646
5647 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
5648
5649 * linux-low.c (check_stopped_by_breakpoint): Use
5650 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
5651
5652 2015-08-27 Pedro Alves <palves@redhat.com>
5653
5654 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
5655
5656 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
5657
5658 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
5659 the XNEW-family equivalent.
5660 (compile_bytecodes): Likewise.
5661 * dll.c (loaded_dll): Likewise.
5662 * event-loop.c (append_callback_event): Likewise.
5663 (create_file_handler): Likewise.
5664 (create_file_event): Likewise.
5665 * hostio.c (handle_open): Likewise.
5666 * inferiors.c (add_thread): Likewise.
5667 (add_process): Likewise.
5668 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
5669 * linux-arm-low.c (arm_new_process): Likewise.
5670 (arm_new_thread): Likewise.
5671 * linux-low.c (add_to_pid_list): Likewise.
5672 (linux_add_process): Likewise.
5673 (handle_extended_wait): Likewise.
5674 (add_lwp): Likewise.
5675 (enqueue_one_deferred_signal): Likewise.
5676 (enqueue_pending_signal): Likewise.
5677 (linux_resume_one_lwp_throw): Likewise.
5678 (linux_resume_one_thread): Likewise.
5679 (linux_read_memory): Likewise.
5680 (linux_write_memory): Likewise.
5681 * linux-mips-low.c (mips_linux_new_process): Likewise.
5682 (mips_linux_new_thread): Likewise.
5683 (mips_add_watchpoint): Likewise.
5684 * linux-x86-low.c (initialize_low_arch): Likewise.
5685 * lynx-low.c (lynx_add_process): Likewise.
5686 * mem-break.c (set_raw_breakpoint_at): Likewise.
5687 (set_breakpoint): Likewise.
5688 (add_condition_to_breakpoint): Likewise.
5689 (add_commands_to_breakpoint): Likewise.
5690 (clone_agent_expr): Likewise.
5691 (clone_one_breakpoint): Likewise.
5692 * regcache.c (new_register_cache): Likewise.
5693 * remote-utils.c (look_up_one_symbol): Likewise.
5694 * server.c (queue_stop_reply): Likewise.
5695 (start_inferior): Likewise.
5696 (queue_stop_reply_callback): Likewise.
5697 (handle_target_event): Likewise.
5698 * spu-low.c (fetch_ppc_memory): Likewise.
5699 (store_ppc_memory): Likewise.
5700 * target.c (set_target_ops): Likewise.
5701 * thread-db.c (thread_db_load_search): Likewise.
5702 (try_thread_db_load_1): Likewise.
5703 * tracepoint.c (add_tracepoint): Likewise.
5704 (add_tracepoint_action): Likewise.
5705 (create_trace_state_variable): Likewise.
5706 (cmd_qtdpsrc): Likewise.
5707 (cmd_qtro): Likewise.
5708 (add_while_stepping_state): Likewise.
5709 * win32-low.c (child_add_thread): Likewise.
5710 (get_image_name): Likewise.
5711
5712 2015-08-25 Yao Qi <yao.qi@linaro.org>
5713
5714 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
5715
5716 2015-08-25 Yao Qi <yao.qi@linaro.org>
5717
5718 * Makefile.in (aarch64-linux.o): New rule.
5719 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
5720 srv_tgtobj.
5721 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
5722 (aarch64_init_debug_reg_state): Make it extern.
5723 (aarch64_linux_prepare_to_resume): Remove.
5724
5725 2015-08-25 Yao Qi <yao.qi@linaro.org>
5726
5727 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
5728 lwp_arch_private_info and ptid_of_lwp.
5729
5730 2015-08-25 Yao Qi <yao.qi@linaro.org>
5731
5732 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
5733 Find proc_info by find_process_pid. All callers updated.
5734
5735 2015-08-25 Yao Qi <yao.qi@linaro.org>
5736
5737 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
5738 Remove.
5739 (debug_reg_change_callback): Remove.
5740 (aarch64_notify_debug_reg_change): Remove.
5741
5742 2015-08-25 Yao Qi <yao.qi@linaro.org>
5743
5744 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
5745 Call current_lwp_ptid.
5746
5747 2015-08-25 Yao Qi <yao.qi@linaro.org>
5748
5749 * linux-aarch64-low.c (debug_reg_change_callback): Use
5750 debug_printf.
5751
5752 2015-08-25 Yao Qi <yao.qi@linaro.org>
5753
5754 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
5755
5756 2015-08-25 Yao Qi <yao.qi@linaro.org>
5757
5758 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
5759
5760 2015-08-25 Yao Qi <yao.qi@linaro.org>
5761
5762 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
5763 the code.
5764
5765 2015-08-25 Yao Qi <yao.qi@linaro.org>
5766
5767 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
5768 Remove.
5769 (debug_reg_change_callback): Remove argument entry and add argument
5770 lwp. Remove local variable thread. Don't print thread id in the
5771 debugging output. Don't check whether pid of thread equals to pid.
5772 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
5773 iterate_over_lwps instead find_inferior.
5774
5775 2015-08-24 Pedro Alves <palves@redhat.com>
5776
5777 * inferiors.c (get_first_process): New function.
5778 * inferiors.h (get_first_process): New declaration.
5779 * remote-utils.c (read_ptid): Default to the first process in the
5780 list, instead of to the current thread's process.
5781
5782 2015-08-24 Pedro Alves <palves@redhat.com>
5783
5784 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
5785 * event-loop.c: Likewise.
5786 * remote-utils.c: Likewise.
5787 * tracepoint.c: Likewise.
5788
5789 2015-08-24 Pedro Alves <palves@redhat.com>
5790
5791 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
5792 ptid_get_lwp.
5793
5794 2015-08-21 Pedro Alves <palves@redhat.com>
5795
5796 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
5797 instead of literal 1.
5798
5799 2015-08-21 Pedro Alves <palves@redhat.com>
5800
5801 * tdesc.c (default_description): Explicitly zero-initialize.
5802
5803 2015-08-21 Pedro Alves <palves@redhat.com>
5804
5805 PR gdb/18749
5806 * inferiors.c (remove_thread): Discard any pending stop reply for
5807 this thread.
5808 * server.c (remove_all_on_match_pid): Rename to ...
5809 (remove_all_on_match_ptid): ... this. Work with a filter ptid
5810 instead of a pid.
5811 (discard_queued_stop_replies): Change parameter to a ptid. Now
5812 extern.
5813 (handle_v_kill, kill_inferior_callback, captured_main)
5814 (process_serial_event): Adjust.
5815 * server.h (discard_queued_stop_replies): Declare.
5816
5817 2015-08-21 Pedro Alves <palves@redhat.com>
5818
5819 * linux-low.c (wait_for_sigstop): Always switch to no thread
5820 selected if the previously current thread dies.
5821 * lynx-low.c (lynx_request_interrupt): Use the first thread's
5822 process instead of the current thread's.
5823 * remote-utils.c (input_interrupt): Don't check if there's no
5824 current thread.
5825 * server.c (gdb_read_memory, gdb_write_memory): If setting the
5826 current thread to the general thread fails, error out.
5827 (handle_qxfer_auxv, handle_qxfer_libraries)
5828 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
5829 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
5830 (handle_query): Check if there's a thread selected instead of
5831 checking whether there's any thread in the thread list.
5832 (handle_qxfer_threads, handle_qxfer_btrace)
5833 (handle_qxfer_btrace_conf): Don't error out early if there's no
5834 thread in the thread list.
5835 (handle_v_cont, myresume): Don't set the current thread to the
5836 continue thread.
5837 (process_serial_event) <Hg handling>: Also set thread_id if the
5838 previous general thread is still alive.
5839 (process_serial_event) <g/G handling>: If setting the current
5840 thread to the general thread fails, error out.
5841 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
5842 thread's lwp instead of the current thread's.
5843 * target.c (set_desired_thread): If the desired thread was not
5844 found, leave the current thread pointing to NULL. Return an int
5845 (boolean) indicating success.
5846 * target.h (set_desired_thread): Change return type to int.
5847
5848 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
5849
5850 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
5851 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
5852 #includes.
5853 (ps_get_thread_area): New function.
5854
5855 2015-08-19 Gary Benson <gbenson@redhat.com>
5856
5857 * hostio.c (handle_pread): Do not attempt to read more data
5858 than hostio_reply_with_data can fit in a packet.
5859
5860 2015-08-18 Joel Brobecker <brobecker@adacore.com>
5861
5862 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
5863
5864 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
5865
5866 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
5867
5868 2015-08-06 Pedro Alves <palves@redhat.com>
5869
5870 * tracepoint.c (expr_eval_result): Now an int.
5871
5872 2015-08-06 Pedro Alves <palves@redhat.com>
5873
5874 * gdbthread.h (struct regcache): Forward declare.
5875 (struct thread_info) <regcache_data>: Now a struct regcache
5876 pointer.
5877 * inferiors.c (inferior_regcache_data)
5878 (set_inferior_regcache_data): Now work with struct regcache
5879 pointers.
5880 * inferiors.h (struct regcache): Forward declare.
5881 (inferior_regcache_data, set_inferior_regcache_data): Now work
5882 with struct regcache pointers.
5883 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
5884 (free_register_cache_thread): Remove struct regcache pointer
5885 casts.
5886
5887 2015-08-06 Pedro Alves <palves@redhat.com>
5888
5889 * server.c (captured_main): On error, print the exception message
5890 to stderr, and if run_once is set, throw a quit.
5891
5892 2015-08-06 Pedro Alves <palves@redhat.com>
5893
5894 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
5895 the current thread.
5896
5897 2015-08-06 Pedro Alves <palves@redhat.com>
5898
5899 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
5900 reading beyond the passed in buffer length.
5901
5902 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
5903
5904 * tracepoint.c (symbol_list) <required>: Remove.
5905
5906 2015-08-06 Pedro Alves <palves@redhat.com>
5907
5908 * linux-low.c (handle_extended_wait): Set the fork child's suspend
5909 count if stopping and suspending threads.
5910 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
5911 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
5912 (linux_detach): Complete an ongoing step-over.
5913 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
5914 throughout.
5915 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
5916 (linux_wait_1): If passing a signal to the inferior after
5917 finishing a step-over, unsuspend and re-resume all lwps. If we
5918 see a single-step event but the thread should be continuing, don't
5919 pass the trap to gdb.
5920 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
5921 internal_error instead of gdb_assert.
5922 (enqueue_pending_signal): New function.
5923 (check_ptrace_stopped_lwp_gone): Add debug output.
5924 (start_step_over): Use internal_error instead of gdb_assert.
5925 (complete_ongoing_step_over): New function.
5926 (linux_resume_one_thread): Don't resume a suspended thread.
5927 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
5928 it stepping.
5929
5930 2015-08-06 Pedro Alves <palves@redhat.com>
5931
5932 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
5933 (linux_thread_alive): Use lwp_is_marked_dead.
5934 (extended_event_reported): Delete.
5935 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
5936 instead of extended_event_reported.
5937 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
5938 as well.
5939 (lwp_is_marked_dead): New function.
5940 (lwp_running): Use lwp_is_marked_dead.
5941 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
5942 comment.
5943
5944 2015-08-06 Pedro Alves <palves@redhat.com>
5945
5946 * linux-low.c (linux_wait_1): Move fork event output out of the
5947 !report_to_gdb check. Pass event_child->waitstatus to
5948 target_waitstatus_to_string instead of ourstatus.
5949
5950 2015-08-04 Yao Qi <yao.qi@linaro.org>
5951
5952 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
5953 if current_thread is 32 bit.
5954
5955 2015-08-04 Yao Qi <yao.qi@linaro.org>
5956
5957 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
5958 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
5959 * server.c (extended_protocol): Remove "static".
5960 * server.h (extended_protocol): Declare it.
5961
5962 2015-08-04 Yao Qi <yao.qi@linaro.org>
5963
5964 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
5965 both aarch64 and aarch32.
5966 (aarch64_set_pc): Likewise.
5967
5968 2015-08-04 Yao Qi <yao.qi@linaro.org>
5969
5970 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
5971 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
5972 arm-with-neon.xml to srv_xmlfiles.
5973 * linux-aarch64-low.c: Include linux-aarch32-low.h.
5974 (is_64bit_tdesc): New function.
5975 (aarch64_linux_read_description): New function.
5976 (aarch64_arch_setup): Call aarch64_linux_read_description.
5977 (regs_info): Rename to regs_info_aarch64.
5978 (aarch64_regs_info): Return right regs_info.
5979 (initialize_low_arch): Call initialize_low_arch_aarch32.
5980
5981 2015-08-04 Yao Qi <yao.qi@linaro.org>
5982
5983 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
5984 * linux-aarch32-low.c: New file.
5985 * linux-aarch32-low.h: New file.
5986 * linux-arm-low.c (arm_fill_gregset): Move it to
5987 linux-aarch32-low.c.
5988 (arm_store_gregset): Likewise.
5989 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
5990 (arm_store_vfpregset): Call arm_store_vfpregset_num.
5991 (arm_arch_setup): Check if PTRACE_GETREGSET works.
5992 (regs_info): Rename to regs_info_arm.
5993 (arm_regs_info): Return regs_info_aarch32 if
5994 have_ptrace_getregset is 1 and target description is
5995 arm_with_neon or arm_with_vfpv3.
5996 (initialize_low_arch): Don't call init_registers_arm_with_neon.
5997 Call initialize_low_arch_aarch32 instead.
5998
5999 2015-08-04 Yao Qi <yao.qi@linaro.org>
6000
6001 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
6002 * linux-low.c: ... here.
6003 * linux-low.h (have_ptrace_getregset): Declare it.
6004
6005 2015-08-04 Pedro Alves <palves@redhat.com>
6006
6007 * thread-db.c (struct thread_db): Use new typedefs.
6008 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
6009 CHK calls.
6010 (disable_thread_event_reporting): Cast result of dlsym to
6011 destination function pointer type.
6012 (thread_db_mourn): Use td_ta_delete_ftype.
6013
6014 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
6015
6016 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
6017 arch variant.
6018 (CDX_BREAKPOINT): Define for R2.
6019 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
6020 (the_low_target): Add comments.
6021
6022 2015-07-30 Yao Qi <yao.qi@linaro.org>
6023
6024 * linux-arm-low.c (arm_hwcap): Remove it.
6025 (arm_read_description): New local variable arm_hwcap. Don't
6026 set arm_hwcap to zero.
6027
6028 2015-07-30 Yao Qi <yao.qi@linaro.org>
6029
6030 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
6031 Use regcache->tdesc instead.
6032 (arm_store_wmmxregset): Likewise.
6033 (arm_fill_vfpregset): Likewise.
6034 (arm_store_vfpregset): Likewise.
6035
6036 2015-07-30 Yao Qi <yao.qi@linaro.org>
6037
6038 * linux-arm-low.c: Include arch/arm.h.
6039 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
6040 (arm_store_gregset): Likewise.
6041
6042 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
6043
6044 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
6045 ptrace's 4th parameter.
6046
6047 2015-07-27 Yao Qi <yao.qi@linaro.org>
6048
6049 * configure.srv (case aarch64*-*-linux*): Don't set
6050 srv_linux_usrregs.
6051
6052 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
6053
6054 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
6055 sys/ptrace.h.
6056 * linux-arm-low.c: Likewise.
6057 * linux-cris-low.c: Likewise.
6058 * linux-crisv32-low.c: Likewise.
6059 * linux-low.c: Likewise.
6060 * linux-m68k-low.c: Likewise.
6061 * linux-mips-low.c: Likewise.
6062 * linux-nios2-low.c: Likewise.
6063 * linux-s390-low.c: Likewise.
6064 * linux-sparc-low.c: Likewise.
6065 * linux-tic6x-low.c: Likewise.
6066 * linux-tile-low.c: Likewise.
6067 * linux-x86-low.c: Likewise.
6068
6069 2015-07-24 Pedro Alves <palves@redhat.com>
6070
6071 * config.in: Regenerate.
6072 * configure: Regenerate.
6073
6074 2015-07-24 Pedro Alves <palves@redhat.com>
6075
6076 * acinclude.m4: Include ../ptrace.m4.
6077 * configure.ac: Call GDB_AC_PTRACE.
6078 * config.in, configure: Regenerate.
6079
6080 2015-07-24 Yao Qi <yao.qi@linaro.org>
6081
6082 * linux-low.c (linux_create_inferior): Remove setting to
6083 proc->priv->new_inferior.
6084 (linux_attach): Likewise.
6085 (linux_low_filter_event): Likewise.
6086 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
6087
6088 2015-07-24 Yao Qi <yao.qi@linaro.org>
6089
6090 * linux-low.c (linux_arch_setup): New function.
6091 (linux_low_filter_event): If proc->tdesc is NULL and
6092 proc->attached is true, call the_low_target.arch_setup.
6093 Otherwise, keep status pending, and return.
6094 (linux_resume_one_lwp_throw): Don't call get_pc if
6095 thread->while_stepping isn't NULL. Don't call
6096 get_thread_regcache if proc->tdesc is NULL.
6097 (need_step_over_p): Return 0 if proc->tdesc is NULL.
6098 (linux_target_ops): Install arch_setup.
6099 * server.c (start_inferior): Call the_target->arch_setup.
6100 * target.h (struct target_ops) <arch_setup>: New field.
6101 (target_arch_setup): New marco.
6102 * lynx-low.c (lynx_target_ops): Update.
6103 * nto-low.c (nto_target_ops): Update.
6104 * spu-low.c (spu_target_ops): Update.
6105 * win32-low.c (win32_target_ops): Update.
6106
6107 2015-07-24 Yao Qi <yao.qi@linaro.org>
6108
6109 * linux-low.c (linux_add_process): Don't set
6110 proc->priv->new_inferior.
6111 (linux_create_inferior): Set proc->priv->new_inferior to 1.
6112 (linux_attach): Likewise.
6113
6114 2015-07-24 Yao Qi <yao.qi@linaro.org>
6115
6116 * server.c (start_inferior): Code refactor.
6117
6118 2015-07-24 Yao Qi <yao.qi@linaro.org>
6119
6120 * server.c (process_serial_event): Set general_thread.
6121
6122 2015-07-21 Yao Qi <yao.qi@linaro.org>
6123
6124 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
6125 aarch64_linux_get_debug_reg_capacity.
6126
6127 2015-07-17 Yao Qi <yao.qi@linaro.org>
6128
6129 * Makefile.in (aarch64-linux-hw-point.o): New rule.
6130 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
6131 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
6132 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
6133 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
6134 (AARCH64_HWP_ALIGNMENT): Likewise.
6135 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
6136 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
6137 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
6138 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
6139 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
6140 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
6141 (struct aarch64_debug_reg_state): Likewise.
6142 (struct arch_lwp_info): Likewise.
6143 (aarch64_align_watchpoint): Likewise.
6144 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
6145 (aarch64_watchpoint_length): Likewise.
6146 (aarch64_point_encode_ctrl_reg): Likewise
6147 (aarch64_point_is_aligned): Likewise.
6148 (aarch64_align_watchpoint): Likewise.
6149 (aarch64_linux_set_debug_regs):
6150 (aarch64_dr_state_insert_one_point): Likewise.
6151 (aarch64_dr_state_remove_one_point): Likewise.
6152 (aarch64_handle_breakpoint): Likewise.
6153 (aarch64_handle_aligned_watchpoint): Likewise.
6154 (aarch64_handle_unaligned_watchpoint): Likewise.
6155 (aarch64_handle_watchpoint): Likewise.
6156
6157 2015-07-17 Yao Qi <yao.qi@linaro.org>
6158
6159 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
6160 and don't aarch64_get_debug_reg_state. All callers update.
6161 (aarch64_handle_aligned_watchpoint): Likewise.
6162 (aarch64_handle_unaligned_watchpoint): Likewise.
6163 (aarch64_handle_watchpoint): Likewise.
6164 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
6165 (aarch64_remove_point): Likewise.
6166
6167 2015-07-17 Yao Qi <yao.qi@linaro.org>
6168
6169 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
6170 debug_printf.
6171 (aarch64_handle_unaligned_watchpoint): Likewise.
6172
6173 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
6174
6175 Revert the previous 3 commits:
6176 Move gdb_regex* to common/
6177 Move linux_find_memory_regions_full & co.
6178 gdbserver build-id attribute generator
6179
6180 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6181 Jan Kratochvil <jan.kratochvil@redhat.com>
6182
6183 gdbserver build-id attribute generator.
6184 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
6185 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
6186 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
6187 (find_phdr): New.
6188 (get_dynamic): Use find_pdhr to traverse program headers.
6189 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
6190 (compare_mapping_entry_range, struct find_memory_region_callback_data)
6191 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
6192 (get_hex_build_id): New.
6193 (linux_qxfer_libraries_svr4): Add optional build-id attribute
6194 to reply XML document.
6195
6196 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6197 Jan Kratochvil <jan.kratochvil@redhat.com>
6198
6199 * target.c: Include target/target-utils.h and fcntl.h.
6200 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
6201 (target_fileio_read_stralloc): New functions.
6202
6203 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
6204
6205 * Makefile.in (OBS): Add gdb_regex.o.
6206 (gdb_regex.o): New.
6207 * config.in: Rebuilt.
6208 * configure: Rebuilt.
6209
6210 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6211 Jan Kratochvil <jan.kratochvil@redhat.com>
6212
6213 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
6214 * Makefile.in (OBS): Add target-utils.o.
6215 (linux-maps.o, target-utils.o): New.
6216 * configure.srv (srv_linux_obj): Add linux-maps.o.
6217
6218 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
6219
6220 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
6221 function, return 1.
6222 (the_low_target): Install it.
6223
6224 2015-07-14 Pedro Alves <palves@redhat.com>
6225
6226 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
6227 Instead, ignore ECHILD, and throw an error for other errnos.
6228
6229 2015-07-10 Pedro Alves <palves@redhat.com>
6230
6231 * event-loop.c (struct callback_event) <data>: Change type to
6232 gdb_client_data instance instead of gdb_client_data pointer.
6233 (append_callback_event): Adjust.
6234
6235 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
6236
6237 * linux-aarch64-low.c: Add comments for each linux_target_ops
6238 method. Remove comments already covered in target_ops and
6239 linux_target_ops definitions.
6240 (the_low_target): Add comments for each unimplemented method.
6241
6242 2015-07-09 Yao Qi <yao.qi@linaro.org>
6243
6244 * linux-aarch64-low.c (aarch64_regmap): Remove.
6245 (aarch64_usrregs_info): Remove.
6246 (regs_info): Set field usrregs to NULL.
6247
6248 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
6249
6250 * linux-low.c: Include "rsp-low.h"
6251 (linux_low_encode_pt_config, linux_low_encode_raw): New.
6252 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
6253 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
6254 (handle_btrace_enable_pt): New.
6255 (handle_btrace_general_set): Support "pt".
6256 (handle_btrace_conf_general_set): Support "pt:size".
6257
6258 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
6259
6260 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
6261 Z_PACKET_SW_BP.
6262
6263 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
6264
6265 * linux-aarch64-low.c: Remove comment about endianness.
6266 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
6267 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
6268 memcmp.
6269
6270 2015-06-24 Gary Benson <gbenson@redhat.com>
6271
6272 * linux-i386-ipa.c (stdint.h): Do not include.
6273 * lynx-i386-low.c (stdint.h): Likewise.
6274 * lynx-ppc-low.c (stdint.h): Likewise.
6275 * mem-break.c (stdint.h): Likewise.
6276 * thread-db.c (stdint.h): Likewise.
6277 * tracepoint.c (stdint.h): Likewise.
6278 * win32-low.c (stdint.h): Likewise.
6279
6280 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
6281
6282 * server.c (write_qxfer_response): Update call to
6283 remote_escape_output.
6284
6285 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
6286 Jan Kratochvil <jan.kratochvil@redhat.com>
6287
6288 Merge multiple hex conversions.
6289 * gdbreplay.c (tohex): Rename to 'fromhex'.
6290 (logchar): Use fromhex.
6291
6292 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
6293
6294 * server.c (handle_qxfer_libraries): Set `version' attribute for
6295 <library-list>.
6296
6297 2015-06-10 Gary Benson <gbenson@redhat.com>
6298
6299 * target.h (struct target_ops) <multifs_open>: New field.
6300 <multifs_unlink>: Likewise.
6301 <multifs_readlink>: Likewise.
6302 * linux-low.c (nat/linux-namespaces.h): New include.
6303 (linux_target_ops): Initialize the_target->multifs_open,
6304 the_target->multifs_unlink and the_target->multifs_readlink.
6305 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
6306 * hostio.c (hostio_fs_pid): New static variable.
6307 (hostio_handle_new_gdb_connection): New function.
6308 (handle_setfs): Likewise.
6309 (handle_open): Use the_target->multifs_open as appropriate.
6310 (handle_unlink): Use the_target->multifs_unlink as appropriate.
6311 (handle_readlink): Use the_target->multifs_readlink as
6312 appropriate.
6313 (handle_vFile): Handle vFile:setfs packets.
6314 * server.c (handle_query): Call hostio_handle_new_gdb_connection
6315 after target_handle_new_gdb_connection.
6316
6317 2015-06-10 Gary Benson <gbenson@redhat.com>
6318
6319 * configure.ac (AC_CHECK_FUNCS): Add setns.
6320 * config.in: Regenerate.
6321 * configure: Likewise.
6322 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
6323 (linux-namespaces.o): New rule.
6324 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
6325
6326 2015-06-09 Gary Benson <gbenson@redhat.com>
6327
6328 * hostio.c (handle_open): Process mode argument with
6329 fileio_to_host_mode.
6330
6331 2015-06-01 Yao Qi <yao.qi@linaro.org>
6332
6333 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
6334 * linux-x86-low.c: Likewise.
6335
6336 2015-05-28 Don Breazeal <donb@codesourcery.com>
6337
6338 * linux-low.c (handle_extended_wait): Initialize
6339 thread_info.last_resume_kind for new fork children.
6340
6341 2015-05-15 Pedro Alves <palves@redhat.com>
6342
6343 * target.h (target_handle_new_gdb_connection): Rewrite using if
6344 wrapped in do/while.
6345
6346 2015-05-14 Joel Brobecker <brobecker@adacore.com>
6347
6348 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
6349 * configure, config.in: Regenerate.
6350 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
6351 Declare typedef.
6352
6353 2015-05-12 Don Breazeal <donb@codesourcery.com>
6354
6355 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
6356 PTRACE_EVENT_VFORK_DONE.
6357 (linux_low_ptrace_options, extended_event_reported): Add vfork
6358 events.
6359 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
6360 and "vforkdone" for RSP 'T' Stop Reply Packet.
6361 * server.h (report_vfork_events): Declare
6362 global variable.
6363
6364 2015-05-12 Don Breazeal <donb@codesourcery.com>
6365
6366 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
6367 (the_low_target) <new_fork>: Initialize new member.
6368 * linux-arm-low.c (arm_new_fork): New function.
6369 (the_low_target) <new_fork>: Initialize new member.
6370 * linux-low.c (handle_extended_wait): Call new target function
6371 new_fork.
6372 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
6373 * linux-mips-low.c (mips_add_watchpoint): New function
6374 extracted from mips_insert_point.
6375 (the_low_target) <new_fork>: Initialize new member.
6376 (mips_linux_new_fork): New function.
6377 (mips_insert_point): Call mips_add_watchpoint.
6378 * linux-x86-low.c (x86_linux_new_fork): New function.
6379 (the_low_target) <new_fork>: Initialize new member.
6380
6381 2015-05-12 Don Breazeal <donb@codesourcery.com>
6382
6383 * linux-low.c (handle_extended_wait): Implement return value,
6384 rename argument 'event_child' to 'event_lwp', handle
6385 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
6386 (linux_low_ptrace_options): New function.
6387 (linux_low_filter_event): Call linux_low_ptrace_options,
6388 use different argument fo linux_enable_event_reporting,
6389 use return value from handle_extended_wait.
6390 (extended_event_reported): New function.
6391 (linux_wait_1): Call extended_event_reported and set
6392 status to report fork events.
6393 (linux_write_memory): Add pid to debug message.
6394 (reset_lwp_ptrace_options_callback): New function.
6395 (linux_handle_new_gdb_connection): New function.
6396 (linux_target_ops): Initialize new structure member.
6397 * linux-low.h (struct lwp_info) <waitstatus>: New member.
6398 * lynx-low.c: Initialize new structure member.
6399 * remote-utils.c (prepare_resume_reply): Implement stop reason
6400 "fork" for "T" stop message.
6401 * server.c (handle_query): Call handle_new_gdb_connection.
6402 * server.h (report_fork_events): Declare global flag.
6403 * target.h (struct target_ops) <handle_new_gdb_connection>:
6404 New member.
6405 (target_handle_new_gdb_connection): New macro.
6406 * win32-low.c: Initialize new structure member.
6407
6408 2015-05-12 Don Breazeal <donb@codesourcery.com>
6409
6410 * mem-break.c (APPEND_TO_LIST): Define macro.
6411 (clone_agent_expr): New function.
6412 (clone_one_breakpoint): New function.
6413 (clone_all_breakpoints): New function.
6414 * mem-break.h: Declare new functions.
6415
6416 2015-05-12 Don Breazeal <donb@codesourcery.com>
6417
6418 * linux-low.c (linux_supports_fork_events): New function.
6419 (linux_supports_vfork_events): New function.
6420 (linux_target_ops): Initialize new structure members.
6421 (initialize_low): Call linux_check_ptrace_features.
6422 * lynx-low.c (lynx_target_ops): Initialize new structure
6423 members.
6424 * server.c (report_fork_events, report_vfork_events):
6425 New global flags.
6426 (handle_query): Add new features to qSupported packet and
6427 response.
6428 (captured_main): Initialize new global variables.
6429 * target.h (struct target_ops) <supports_fork_events>:
6430 New member.
6431 <supports_vfork_events>: New member.
6432 (target_supports_fork_events): New macro.
6433 (target_supports_vfork_events): New macro.
6434 * win32-low.c (win32_target_ops): Initialize new structure
6435 members.
6436
6437 2015-05-12 Gary Benson <gbenson@redhat.com>
6438
6439 * server.c (handle_qxfer_exec_file): Use current process
6440 if annex is empty.
6441
6442 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
6443
6444 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
6445 Remove HAVE_PTRACE_GETREGS conditionals.
6446 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
6447 instead of PTRACE_GETREGS and PTRACE_SETREGS.
6448
6449 2015-05-08 Yao Qi <yao.qi@linaro.org>
6450
6451 * linux-low.c (linux_supports_conditional_breakpoints): New
6452 function.
6453 (linux_target_ops): Install new target method.
6454 * lynx-low.c (lynx_target_ops): Install NULL hook for
6455 supports_conditional_breakpoints.
6456 * nto-low.c (nto_target_ops): Likewise.
6457 * spu-low.c (spu_target_ops): Likewise.
6458 * win32-low.c (win32_target_ops): Likewise.
6459 * server.c (handle_query): Check
6460 target_supports_conditional_breakpoints.
6461 * target.h (struct target_ops) <supports_conditional_breakpoints>:
6462 New field.
6463 (target_supports_conditional_breakpoints): New macro.
6464
6465 2015-05-06 Pedro Alves <palves@redhat.com>
6466
6467 PR server/18081
6468 * server.c (start_inferior): If the process exits, mourn it.
6469
6470 2015-04-21 Gary Benson <gbenson@redhat.com>
6471
6472 * hostio.c (fileio_open_flags_to_host): Factored out to
6473 fileio_to_host_openflags in common/fileio.c. Single use
6474 updated.
6475
6476 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
6477
6478 * linux-xtensa-low.c (xtensa_fill_gregset)
6479 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
6480 XCHAL_HAVE_LOOP.
6481
6482 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
6483
6484 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
6485 (regs_info): Replace usrregs pointer with NULL.
6486
6487 2015-04-17 Gary Benson <gbenson@redhat.com>
6488
6489 * target.h (struct target_ops) <pid_to_exec_file>: New field.
6490 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
6491 * server.c (handle_qxfer_exec_file): New function.
6492 (qxfer_packets): Add exec-file entry.
6493 (handle_query): Report qXfer:exec-file:read as supported packet.
6494
6495 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
6496
6497 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
6498
6499 2015-04-09 Gary Benson <gbenson@redhat.com>
6500
6501 * hostio-errno.c (errno_to_fileio_error): Remove function.
6502 Update caller to use remote_fileio_to_fio_error.
6503
6504 2015-04-09 Yao Qi <yao.qi@linaro.org>
6505
6506 * linux-low.c (linux_insert_point): Call
6507 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
6508 (linux_remove_point): Call remove_memory_breakpoint if type is
6509 raw_bkpt_type_sw.
6510 * linux-x86-low.c (x86_insert_point): Don't call
6511 insert_memory_breakpoint.
6512 (x86_remove_point): Don't call remove_memory_breakpoint.
6513
6514 2015-04-01 Pedro Alves <palves@redhat.com>
6515 Cleber Rosa <crosa@redhat.com>
6516
6517 * server.c (gdbserver_usage): Reorganize and extend the usage
6518 message.
6519
6520 2015-03-24 Pedro Alves <palves@redhat.com>
6521
6522 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
6523 output. Also dump TRAP_TRACE.
6524 (linux_low_filter_event): In debug output, distinguish a
6525 resume_stop SIGSTOP from a delayed SIGSTOP.
6526
6527 2015-03-24 Gary Benson <gbenson@redhat.com>
6528
6529 * linux-x86-low.c (x86_linux_new_thread): Moved to
6530 nat/x86-linux.c.
6531 (x86_linux_prepare_to_resume): Likewise.
6532
6533 2015-03-24 Gary Benson <gbenson@redhat.com>
6534
6535 * Makefile.in (x86-linux-dregs.o): New rule.
6536 * configure.srv: Add x86-linux-dregs.o to relevant targets.
6537 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
6538 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
6539 (x86_linux_dr_get): Likewise.
6540 (x86_linux_dr_set): Likewise.
6541 (update_debug_registers_callback): Likewise.
6542 (x86_linux_dr_set_addr): Likewise.
6543 (x86_linux_dr_get_addr): Likewise.
6544 (x86_linux_dr_set_control): Likewise.
6545 (x86_linux_dr_get_control): Likewise.
6546 (x86_linux_dr_get_status): Likewise.
6547 (x86_linux_update_debug_registers): Likewise.
6548
6549 2015-03-24 Gary Benson <gbenson@redhat.com>
6550
6551 * linux-x86-low.c (x86_linux_update_debug_registers):
6552 New function, factored out from...
6553 (x86_linux_prepare_to_resume): ...this.
6554
6555 2015-03-24 Gary Benson <gbenson@redhat.com>
6556
6557 * linux-x86-low.c (x86_linux_dr_get): Update comments.
6558 (x86_linux_dr_set): Likewise.
6559 (update_debug_registers_callback): Likewise.
6560 (x86_linux_dr_set_addr): Likewise.
6561 (x86_linux_dr_get_addr): Likewise.
6562 (x86_linux_dr_set_control): Likewise.
6563 (x86_linux_dr_get_control): Likewise.
6564 (x86_linux_dr_get_status): Likewise.
6565 (x86_linux_prepare_to_resume): Likewise.
6566
6567 2015-03-24 Gary Benson <gbenson@redhat.com>
6568
6569 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
6570 Use perror_with_name. Pass string through gettext.
6571 (x86_linux_dr_set): Likewise.
6572
6573 2015-03-24 Gary Benson <gbenson@redhat.com>
6574
6575 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
6576 (x86_linux_dr_set_addr): ...this.
6577 (x86_dr_low_get_addr): Rename to...
6578 (x86_linux_dr_get_addr): ...this.
6579 (x86_dr_low_set_control): Rename to...
6580 (x86_linux_dr_set_control): ...this.
6581 (x86_dr_low_get_control): Rename to...
6582 (x86_linux_dr_get_control): ...this.
6583 (x86_dr_low_get_status): Rename to...
6584 (x86_linux_dr_get_status): ...this.
6585 (x86_dr_low): Update with new function names.
6586
6587 2015-03-24 Gary Benson <gbenson@redhat.com>
6588
6589 * Makefile.in (x86-linux.o): New rule.
6590 * configure.srv: Add x86-linux.o to relevant targets.
6591 * linux-low.c (lwp_set_arch_private_info): New function.
6592 (lwp_arch_private_info): Likewise.
6593 * linux-x86-low.c: Include nat/x86-linux.h.
6594 (arch_lwp_info): Removed structure.
6595 (update_debug_registers_callback):
6596 Use lwp_set_debug_registers_changed.
6597 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
6598 and lwp_set_debug_registers_changed.
6599 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
6600
6601 2015-03-24 Gary Benson <gbenson@redhat.com>
6602
6603 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
6604 * linux-arm-low.c (arm_new_thread): Likewise.
6605 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
6606 * linux-mips-low.c (mips_linux_new_thread): Likewise.
6607 * linux-x86-low.c (x86_linux_new_thread): Likewise.
6608 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
6609
6610 2015-03-24 Gary Benson <gbenson@redhat.com>
6611
6612 * linux-low.c (ptid_of_lwp): New function.
6613 (lwp_is_stopped): Likewise.
6614 (lwp_stop_reason): Likewise.
6615 * linux-x86-low.c (update_debug_registers_callback):
6616 Use lwp_is_stopped.
6617 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
6618 lwp_stop_reason.
6619
6620 2015-03-24 Gary Benson <gbenson@redhat.com>
6621
6622 * linux-low.h (linux_stop_lwp): Remove declaration.
6623
6624 2015-03-24 Gary Benson <gbenson@redhat.com>
6625
6626 * linux-low.h: Include nat/linux-nat.h.
6627 * linux-low.c (iterate_over_lwps_args): New structure.
6628 (iterate_over_lwps_filter): New function.
6629 (iterate_over_lwps): Likewise.
6630 * linux-x86-low.c (update_debug_registers_callback):
6631 Update signature to what iterate_over_lwps expects.
6632 Remove PID check that iterate_over_lwps now performs.
6633 (x86_dr_low_set_addr): Use iterate_over_lwps.
6634 (x86_dr_low_set_control): Likewise.
6635
6636 2015-03-24 Gary Benson <gbenson@redhat.com>
6637
6638 * linux-x86-low.c (x86_debug_reg_state): New function.
6639 (x86_linux_prepare_to_resume): Use the above.
6640
6641 2015-03-24 Gary Benson <gbenson@redhat.com>
6642
6643 * linux-low.c (current_lwp_ptid): New function.
6644 * linux-x86-low.c: Include nat/linux-nat.h.
6645 (x86_dr_low_get_addr): Use current_lwp_ptid.
6646 (x86_dr_low_get_control): Likewise.
6647 (x86_dr_low_get_status): Likewise.
6648
6649 2015-03-20 Pedro Alves <palves@redhat.com>
6650
6651 * tracepoint.c (cmd_qtstatus): Make "str" const.
6652
6653 2015-03-20 Pedro Alves <palves@redhat.com>
6654
6655 * server.c (handle_general_set): Make "req_str" const.
6656
6657 2015-03-19 Pedro Alves <palves@redhat.com>
6658
6659 * linux-low.c (linux_resume_one_lwp): Rename to ...
6660 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
6661 instead call perror_with_name.
6662 (check_ptrace_stopped_lwp_gone): New function.
6663 (linux_resume_one_lwp): Reimplement as wrapper around
6664 linux_resume_one_lwp_throw that swallows errors if the LWP is
6665 gone.
6666
6667 2015-03-19 Pedro Alves <palves@redhat.com>
6668
6669 * linux-low.c (count_events_callback, select_event_lwp_callback):
6670 No longer check whether the thread has resume_stop as last resume
6671 kind.
6672
6673 2015-03-19 Pedro Alves <palves@redhat.com>
6674
6675 * linux-low.c (count_events_callback, select_event_lwp_callback):
6676 Use the lwp's status_pending_p field, not the thread's.
6677
6678 2015-03-19 Pedro Alves <palves@redhat.com>
6679
6680 * linux-low.c (select_event_lwp_callback): Update comments to
6681 no longer mention SIGTRAP.
6682
6683 2015-03-18 Gary Benson <gbenson@redhat.com>
6684
6685 * server.c (handle_query): Do not report vFile:fstat as supported.
6686
6687 2015-03-11 Gary Benson <gbenson@redhat.com>
6688
6689 * hostio.c (sys/types.h): New include.
6690 (sys/stat.h): Likewise.
6691 (common-remote-fileio.h): Likewise.
6692 (handle_fstat): New function.
6693 (handle_vFile): Handle vFile:fstat packets.
6694
6695 2015-03-11 Gary Benson <gbenson@redhat.com>
6696
6697 * configure.ac (AC_CHECK_MEMBERS): Add checks for
6698 struct stat.st_blocks and struct stat.st_blksize.
6699 * configure: Regenerate.
6700 * config.in: Likewise.
6701 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
6702 (OBS): Add common-remote-fileio.o.
6703 (common-remote-fileio.o): New rule.
6704
6705 2015-03-09 Pedro Alves <palves@redhat.com>
6706
6707 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
6708 'struct sockaddr' pointer in 'accept' call.
6709
6710 2015-03-09 Pedro Alves <palves@redhat.com>
6711
6712 Revert:
6713 2015-03-07 Pedro Alves <palves@redhat.com>
6714 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
6715 or <winsock2.h> here. Instead include "gdb_socket.h".
6716 (remote_open): Use union gdb_sockaddr_u.
6717 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
6718 or <winsock2.h> here. Instead include "gdb_socket.h".
6719 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
6720 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
6721 or <sys/un.h>.
6722 (init_named_socket, gdb_agent_helper_thread): Use union
6723 gdb_sockaddr_u.
6724
6725 2015-03-07 Pedro Alves <palves@redhat.com>
6726
6727 * configure.ac (build_warnings): Move
6728 -Wdeclaration-after-statement to the C-specific set.
6729 * configure: Regenerate.
6730
6731 2015-03-07 Pedro Alves <palves@redhat.com>
6732
6733 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
6734 or <winsock2.h> here. Instead include "gdb_socket.h".
6735 (remote_open): Use union gdb_sockaddr_u.
6736 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
6737 or <winsock2.h> here. Instead include "gdb_socket.h".
6738 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
6739 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
6740 or <sys/un.h>.
6741 (init_named_socket, gdb_agent_helper_thread): Use union
6742 gdb_sockaddr_u.
6743
6744 2015-03-07 Pedro Alves <palves@redhat.com>
6745
6746 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
6747 instead.
6748
6749 2015-03-06 Yao Qi <yao.qi@linaro.org>
6750
6751 * linux-aarch64-low.c (aarch64_insert_point): Use
6752 show_debug_regs as a boolean.
6753 (aarch64_remove_point): Likewise.
6754
6755 2015-03-05 Pedro Alves <palves@redhat.com>
6756
6757 * lynx-low.c (lynx_target_ops): Install NULL hooks for
6758 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
6759 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
6760 * nto-low.c (nto_target_ops): Likewise.
6761 * spu-low.c (spu_target_ops): Likewise.
6762 * win32-low.c (win32_target_ops): Likewise.
6763
6764 2015-03-04 Pedro Alves <palves@redhat.com>
6765
6766 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
6767 Decide whether a breakpoint triggered based on the SIGTRAP's
6768 siginfo.si_code.
6769 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
6770 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
6771 (linux_low_filter_event): Check for breakpoints before checking
6772 watchpoints.
6773 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
6774 siginfo.si_code.
6775 (linux_stopped_by_sw_breakpoint)
6776 (linux_supports_stopped_by_sw_breakpoint)
6777 (linux_stopped_by_hw_breakpoint)
6778 (linux_supports_stopped_by_hw_breakpoint): New functions.
6779 (linux_target_ops): Install new target methods.
6780
6781 2015-03-04 Pedro Alves <palves@redhat.com>
6782
6783 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
6784 * server.c (swbreak_feature, hwbreak_feature): New globals.
6785 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
6786 (captured_main): Clear swbreak_feature and hwbreak_feature.
6787 * server.h (swbreak_feature, hwbreak_feature): Declare.
6788 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
6789 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
6790 supports_stopped_by_hw_breakpoint>: New fields.
6791 (target_supports_stopped_by_sw_breakpoint)
6792 (target_stopped_by_sw_breakpoint)
6793 (target_supports_stopped_by_hw_breakpoint)
6794 (target_stopped_by_hw_breakpoint): Declare.
6795
6796 2015-03-04 Pedro Alves <palves@redhat.com>
6797
6798 enum lwp_stop_reason -> enum target_stop_reason
6799 * linux-low.c (check_stopped_by_breakpoint): Adjust.
6800 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
6801 (linux_wait_1, stuck_in_jump_pad_callback)
6802 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
6803 (linux_stopped_by_watchpoint):
6804 * linux-low.h (enum lwp_stop_reason): Delete.
6805 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
6806 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
6807
6808 2015-03-04 Yao Qi <yao.qi@linaro.org>
6809
6810 * Makefile.in (SFILES): Add linux-aarch64-low.c.
6811
6812 2015-03-03 Gary Benson <gbenson@redhat.com>
6813
6814 * hostio.c (handle_vFile): Fix prefix lengths.
6815
6816 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
6817
6818 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
6819 ptr_bits.
6820
6821 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
6822
6823 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
6824 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
6825 (clean): Add "rm -f" for above C files.
6826 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
6827 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
6828 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
6829 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
6830 * linux-s390-low.c (HWCAP_S390_VX): New macro.
6831 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
6832 (init_registers_s390x_vx_linux64)
6833 (init_registers_s390x_tevx_linux64)
6834 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
6835 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
6836 declarations.
6837 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
6838 (s390_store_vxrs_high): New functions.
6839 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
6840 NT_S390_VXRS_HIGH.
6841 (s390_arch_setup): Add logic for selecting one of the new target
6842 descriptions. Activate the new vector regsets if applicable.
6843 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
6844 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
6845 and init_registers_s390x_tevx_linux64.
6846
6847 2015-03-01 Pedro Alves <palves@redhat.com>
6848
6849 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
6850 parameter.
6851
6852 2015-02-27 Pedro Alves <palves@redhat.com>
6853
6854 * linux-x86-low.c (u_debugreg_offset): New function.
6855 (x86_linux_dr_get, x86_linux_dr_set): Use it.
6856
6857 2015-02-27 Pedro Alves <palves@redhat.com>
6858
6859 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
6860 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
6861 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
6862 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
6863 (ps_lsetfpregs, ps_getpid)
6864 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
6865 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
6866 (ps_lsetxregs, ps_plog): Declare.
6867
6868 2015-02-27 Pedro Alves <palves@redhat.com>
6869
6870 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
6871 IP_AGENT_EXPORT_FUNC.
6872 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
6873 IP_AGENT_EXPORT_FUNC.
6874 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
6875 (IP_AGENT_EXPORT): Delete.
6876 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
6877 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
6878 (gdb_trampoline_buffer_error, collecting, gdb_collect)
6879 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
6880 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
6881 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
6882 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
6883 (traceframe_read_count, traceframe_write_count)
6884 (traceframes_created, trace_state_variables, get_raw_reg)
6885 (get_trace_state_variable_value, set_trace_state_variable_value)
6886 (ust_loaded, helper_thread_id, cmd_buf): Use
6887 IPA_SYM_EXPORTED_NAME.
6888 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
6889 (tracepoints) Use IP_AGENT_EXPORT_VAR.
6890 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
6891 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
6892 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
6893 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
6894 EXTERN_C_PUSH/EXTERN_C_POP.
6895 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
6896 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
6897 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
6898 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
6899 (traceframe_write_count, traceframe_read_count)
6900 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
6901 (about_to_request_buffer_space, get_trace_state_variable_value)
6902 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
6903 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
6904 EXTERN_C_PUSH/EXTERN_C_POP.
6905 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
6906 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
6907 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
6908 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
6909 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
6910 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
6911 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
6912 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
6913 Define.
6914 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
6915 (IP_AGENT_EXPORT_VAR_DECL): Define.
6916 (tracing): Declare.
6917 (gdb_agent_get_raw_reg): Declare.
6918
6919 2015-02-27 Tom Tromey <tromey@redhat.com>
6920 Pedro Alves <palves@redhat.com>
6921
6922 Rename symbols whose names are reserved C++ keywords throughout.
6923
6924 2015-02-27 Pedro Alves <palves@redhat.com>
6925
6926 * Makefile.in (COMPILER): New, get it from autoconf.
6927 (CXX): Get from autoconf instead.
6928 (COMPILE.pre): Use COMPILER.
6929 (CC-LD): Rename to ...
6930 (CC_LD): ... this. Use COMPILER.
6931 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
6932 (CXX_FOR_TARGET): Default to g++ instead of gcc.
6933 * acinclude.m4: Include build-with-cxx.m4.
6934 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
6935 Disable -Werror by default if building in C++ mode.
6936 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
6937 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
6938 the C++ compiler. Save/restore CXXFLAGS too.
6939 * configure: Regenerate.
6940
6941 2015-02-27 Pedro Alves <palves@redhat.com>
6942
6943 * acinclude.m4: Include libiberty.m4.
6944 * configure.ac: Call libiberty_INIT.
6945 * config.in, configure: Regenerate.
6946
6947 2015-02-26 Pedro Alves <palves@redhat.com>
6948
6949 * linux-low.c (linux_wait_1): When incrementing the PC past a
6950 program breakpoint always use the_low_target.breakpoint_len as
6951 increment, rather than the maximum between that and
6952 the_low_target.decr_pc_after_break.
6953
6954 2015-02-23 Pedro Alves <palves@redhat.com>
6955
6956 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
6957 thread was doing a step-over; always adjust the PC if
6958 we stepped over a permanent breakpoint.
6959 (linux_wait_1): If we stepped over breakpoint that was on top of a
6960 permanent breakpoint, manually advance the PC past it.
6961
6962 2015-02-23 Pedro Alves <palves@redhat.com>
6963
6964 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
6965 modes.
6966 (x86_fill_gregset, x86_store_gregset): Use it when handling
6967 $orig_eax.
6968
6969 2015-02-20 Pedro Alves <palves@redhat.com>
6970
6971 * thread-db.c: Include "nat/linux-procfs.h".
6972 (thread_db_init): Skip listing new threads if the kernel supports
6973 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
6974
6975 2015-02-20 Pedro Alves <palves@redhat.com>
6976
6977 * linux-low.c (status_pending_p_callback): Use ptid_match.
6978
6979 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
6980
6981 PR breakpoints/16812
6982 * linux-low.c (wstatus_maybe_breakpoint): Remove.
6983 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
6984 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
6985
6986 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
6987
6988 PR breakpoints/15956
6989 * tracepoint.c (cmd_qtinit): Add check for current_thread.
6990
6991 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
6992
6993 * linux-low.c (linux_low_btrace_conf): Print size.
6994 * server.c (handle_btrace_conf_general_set): New.
6995 (hanle_general_set): Call handle_btrace_conf_general_set.
6996 (handle_query): Report Qbtrace-conf:bts:size as supported.
6997
6998 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
6999
7000 * linux-low.c (linux_low_enable_btrace): Update parameters.
7001 (linux_low_btrace_conf): New.
7002 (linux_target_ops)<to_btrace_conf>: Initialize.
7003 * server.c (current_btrace_conf): New.
7004 (handle_btrace_enable): Rename to ...
7005 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
7006 to target_enable_btrace. Update comment. Update users.
7007 (handle_qxfer_btrace_conf): New.
7008 (qxfer_packets): Add btrace-conf entry.
7009 (handle_query): Report qXfer:btrace-conf:read as supported packet.
7010 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
7011 (target_ops)<read_btrace_conf>: New.
7012 (target_enable_btrace): Update parameters.
7013 (target_read_btrace_conf): New.
7014
7015 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7016
7017 * server.c (handle_btrace_general_set): Remove call to
7018 target_supports_btrace.
7019 (supported_btrace_packets): New.
7020 (handle_query): Call supported_btrace_packets.
7021 * target.h: include btrace-common.h.
7022 (btrace_target_info): Removed.
7023 (supports_btrace, target_supports_btrace): Update parameters.
7024
7025 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7026
7027 * Makefile.in (SFILES): Add common/btrace-common.c.
7028 (OBS): Add common/btrace-common.o.
7029 (btrace-common.o): Add build rules.
7030 * linux-low: Include btrace-common.h.
7031 (linux_low_read_btrace): Use struct btrace_data. Call
7032 btrace_data_init and btrace_data_fini.
7033
7034 2015-02-06 Pedro Alves <palves@redhat.com>
7035
7036 * thread-db.c (find_new_threads_callback): Add debug output.
7037
7038 2015-02-04 Pedro Alves <palves@redhat.com>
7039
7040 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
7041 (resume_stopped_resumed_lwps): New function.
7042 (linux_wait_for_event_filtered): Use it.
7043
7044 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
7045
7046 * Makefile.in (SFILES): Add linux-personality.c.
7047 (linux-personality.o): New rule.
7048 * configure.srv (srv_linux_obj): Add linux-personality.o to the
7049 list of objects to be built.
7050 * linux-low.c: Include nat/linux-personality.h.
7051 (linux_create_inferior): Remove code to disable address space
7052 randomization (moved to ../nat/linux-personality.c). Create
7053 cleanup to disable address space randomization.
7054
7055 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
7056
7057 * Makefile.in (posix-strerror.o): New rule.
7058 (mingw-strerror.o): Likewise.
7059 * configure: Regenerated.
7060 * configure.ac: Source file ../common/common.host. Initialize new
7061 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
7062
7063 2015-01-14 Yao Qi <yao@codesourcery.com>
7064
7065 * Makefile.in (SFILES): Add nat/ppc-linux.c.
7066 (ppc-linux.o): New rule.
7067 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
7068 * configure.ac: AC_CHECK_FUNCS(getauxval).
7069 * config.in: Re-generated.
7070 * configure: Re-generated.
7071 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
7072 ppc64_64bit_inferior_p
7073
7074 2015-01-14 Yao Qi <yao@codesourcery.com>
7075
7076 * linux-ppc-low.c: Include "nat/ppc-linux.h".
7077 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
7078 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
7079 (PT_ORIG_R3, PT_TRAP): Likewise.
7080 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
7081 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
7082 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
7083
7084 2015-01-10 Joel Brobecker <brobecker@adacore.com>
7085
7086 * i387-fp.c (i387_cache_to_xsave): In look over
7087 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
7088 zmmh_low_space field by use of zmmh_high_space.
7089
7090 2015-01-09 Pedro Alves <palves@redhat.com>
7091
7092 * linux-low.c (step_over_bkpt): Move higher up in the file.
7093 (handle_extended_wait): Don't store the stop_pc here.
7094 (get_stop_pc): Adjust comments and rename to ...
7095 (check_stopped_by_breakpoint): ... this. Record whether the LWP
7096 stopped for a software breakpoint or hardware breakpoint.
7097 (thread_still_has_status_pending_p): New function.
7098 (status_pending_p_callback): Use
7099 thread_still_has_status_pending_p. If the event is no longer
7100 interesting, resume the LWP.
7101 (handle_tracepoints): Add assert.
7102 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
7103 (wstatus_maybe_breakpoint): New function.
7104 (cancel_breakpoint): Delete function.
7105 (check_stopped_by_watchpoint): New function, factored out from
7106 linux_low_filter_event.
7107 (lp_status_maybe_breakpoint): Delete function.
7108 (linux_low_filter_event): Remove filter_ptid argument.
7109 Leave thread group exits pending here. Store the LWP's stop PC.
7110 Always leave events pending.
7111 (linux_wait_for_event_filtered): Pull all events out of the
7112 kernel, and leave them all pending.
7113 (count_events_callback, select_event_lwp_callback): Consider all
7114 events.
7115 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
7116 (select_event_lwp): Only give preference to the stepping LWP in
7117 all-stop mode. Adjust comments.
7118 (ignore_event): New function.
7119 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
7120 references to cancel_breakpoints. Adjust to renames. Also give
7121 equal priority to all LWPs that have had events in non-stop mode.
7122 If reporting a software breakpoint event, unadjust the LWP's PC.
7123 (linux_wait): If linux_wait_1 returned an ignored event, retry.
7124 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
7125 Adjust.
7126 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
7127 (resume_status_pending_p): Use thread_still_has_status_pending_p.
7128 (linux_stopped_by_watchpoint): Adjust.
7129 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
7130 * linux-low.h (enum lwp_stop_reason): New.
7131 (struct lwp_info) <stop_pc>: Adjust comment.
7132 <stopped_by_watchpoint>: Delete field.
7133 <stop_reason>: New field.
7134 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
7135 * mem-break.c (software_breakpoint_inserted_here)
7136 (hardware_breakpoint_inserted_here): New function.
7137 * mem-break.h (software_breakpoint_inserted_here)
7138 (hardware_breakpoint_inserted_here): Declare.
7139 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
7140 (cancel_breakpoints): Delete.
7141 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
7142 (upload_fast_traceframes): Remove references to
7143 cancel_breakpoints.
7144
7145 2015-01-09 Pedro Alves <palves@redhat.com>
7146
7147 * thread-db.c (find_new_threads_callback): Ignore thread if the
7148 kernel thread ID is -1.
7149
7150 2015-01-09 Pedro Alves <palves@redhat.com>
7151
7152 * linux-low.c (linux_attach_fail_reason_string): Move to
7153 nat/linux-ptrace.c, and rename.
7154 (linux_attach_lwp): Update comment.
7155 (attach_proc_task_lwp_callback): New function.
7156 (linux_attach): Adjust to rename and use
7157 linux_proc_attach_tgid_threads.
7158 (linux_attach_fail_reason_string): Delete declaration.
7159
7160 2015-01-01 Joel Brobecker <brobecker@adacore.com>
7161
7162 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
7163 * server.c (gdbserver_version): Likewise.
7164
7165 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
7166
7167 * remote-utils.c: Include ctype.h.
7168 (input_interrupt): Explicitly handle the case when the char
7169 received is the NUL byte. Improve the printing of non-ASCII
7170 characters.
7171
7172 2014-12-16 Joel Brobecker <brobecker@adacore.com>
7173
7174 * linux-low.c (linux_low_filter_event): Update call to
7175 linux_enable_event_reporting following the addition of
7176 a new parameter to that function.
7177
7178 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
7179
7180 PR server/17457
7181 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
7182 (AARCH64_FPCR_REGNO): Likewise.
7183 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
7184 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
7185 (aarch64_store_fpregset): Likewise.
7186
7187 2014-12-15 Joel Brobecker <brobecker@adacore.com>
7188
7189 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
7190 Remove FIXME comment about assumption about N.
7191
7192 2014-12-13 Joel Brobecker <brobecker@adacore.com>
7193
7194 * configure.ac: If large-file support is disabled in GDBserver,
7195 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
7196 * configure: Regenerate.
7197
7198 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7199
7200 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
7201 warning upon ENODATA from ptrace.
7202 * linux-s390-low.c (s390_store_tdb): New.
7203 (s390_regsets): Add regset for NT_S390_TDB.
7204
7205 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7206
7207 * linux-low.c (regsets_store_inferior_registers): Skip regsets
7208 without a fill_function.
7209 * linux-s390-low.c (s390_fill_last_break): Remove.
7210 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
7211 (s390_arch_setup): Use regset's size instead of fill_function for
7212 loop end condition.
7213
7214 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7215
7216 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
7217 the regset's store function when ptrace returned an error.
7218 * regcache.c (get_thread_regcache): Invalidate register cache
7219 before fetching inferior's registers.
7220
7221 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7222
7223 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
7224 while-loop as for-loop.
7225 (regsets_store_inferior_registers): Likewise.
7226
7227 2014-11-28 Yao Qi <yao@codesourcery.com>
7228
7229 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
7230 * config.in, configure: Re-generate.
7231 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
7232 is defined.
7233
7234 2014-11-21 Yao Qi <yao@codesourcery.com>
7235
7236 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
7237 (AC_CHECK_HEADERS): Remove malloc.h.
7238 * configure: Re-generated.
7239 * config.in: Re-generated.
7240 * server.h: Don't include alloca.h and malloc.h.
7241 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
7242 Don't include malloc.h.
7243
7244 2014-11-17 Joel Brobecker <brobecker@adacore.com>
7245
7246 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
7247 corresponding ERRNO check in same block.
7248
7249 2014-11-12 Pedro Alves <palves@redhat.com>
7250
7251 * server.c (cont_thread): Update comment.
7252 (start_inferior, attach_inferior): No longer clear cont_thread.
7253 (handle_v_cont): No longer set cont_thread.
7254 (captured_main): Clear cont_thread each time a GDB connects.
7255
7256 2014-11-12 Pedro Alves <palves@redhat.com>
7257
7258 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
7259 thread, and don't resume all threads if the Hc thread has exited.
7260
7261 2014-11-12 Pedro Alves <palves@redhat.com>
7262
7263 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
7264 the process group instead of to a specific LWP.
7265
7266 2014-10-15 Pedro Alves <palves@redhat.com>
7267
7268 PR server/17487
7269 * win32-arm-low.c (arm_set_thread_context): Remove current_event
7270 parameter.
7271 (arm_set_thread_context): Delete.
7272 (the_low_target): Adjust.
7273 * win32-i386-low.c (debug_registers_changed)
7274 (debug_registers_used): Delete.
7275 (update_debug_registers_callback): New function.
7276 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
7277 needing to update their debug registers.
7278 (win32_get_current_dr): New function.
7279 (x86_dr_low_get_addr, x86_dr_low_get_control)
7280 (x86_dr_low_get_status): Fetch the debug register from the thread
7281 record's context.
7282 (i386_initial_stuff): Adjust.
7283 (i386_get_thread_context): Remove current_event parameter. Don't
7284 clear debug_registers_changed nor copy DR values to
7285 debug_reg_state.
7286 (i386_set_thread_context): Delete.
7287 (i386_prepare_to_resume): New function.
7288 (i386_thread_added): Mark the thread as needing to update irs
7289 debug registers.
7290 (the_low_target): Remove i386_set_thread_context and install
7291 i386_prepare_to_resume.
7292 * win32-low.c (win32_get_thread_context): Adjust.
7293 (win32_set_thread_context): Use SetThreadContext
7294 directly.
7295 (win32_prepare_to_resume): New function.
7296 (win32_require_context): New function, factored out from ...
7297 (thread_rec): ... this.
7298 (continue_one_thread): Call win32_prepare_to_resume on each thread
7299 we're about to continue.
7300 (win32_resume): Call win32_prepare_to_resume on the event thread.
7301 * win32-low.h (struct win32_thread_info)
7302 <debug_registers_changed>: New field.
7303 (struct win32_target_ops): Change prototype of set_thread_context,
7304 delete set_thread_context and add prepare_to_resume.
7305 (win32_require_context): New declaration.
7306
7307 2014-10-08 Gary Benson <gbenson@redhat.com>
7308
7309 * server.h: Do not include common-exceptions.h.
7310
7311 2014-10-08 Gary Benson <gbenson@redhat.com>
7312
7313 * server.h: Do not include cleanups.h.
7314
7315 2014-09-30 James Hogan <james.hogan@imgtec.com>
7316
7317 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
7318 mips64-dsp-linux.c.
7319
7320 2014-09-23 Yao Qi <yao@codesourcery.com>
7321
7322 * linux-low.c (lp_status_maybe_breakpoint): New function.
7323 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
7324 (count_events_callback): Likewise.
7325 (select_event_lwp_callback): Likewise.
7326 (cancel_breakpoints_callback): Likewise.
7327
7328 2014-09-19 Don Breazeal <donb@codesourcery.com>
7329
7330 * linux-low.c (handle_extended_wait): Call
7331 linux_ptrace_get_extended_event.
7332 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
7333 linux_is_extended_waitstatus.
7334
7335 2014-09-16 Joel Brobecker <brobecker@adacore.com>
7336
7337 * Makefile.in (CPPFLAGS): Define.
7338 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
7339 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
7340
7341 2014-09-16 Gary Benson <gbenson@redhat.com>
7342
7343 * inferiors.h (current_inferior): Renamed as...
7344 (current_thread): New variable. All uses updated.
7345 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
7346 (maybe_move_out_of_jump_pad): Likewise.
7347 (cancel_breakpoint): Likewise.
7348 (linux_low_filter_event): Likewise.
7349 (wait_for_sigstop): Likewise.
7350 (linux_resume_one_lwp): Likewise.
7351 (need_step_over_p): Likewise.
7352 (start_step_over): Likewise.
7353 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
7354 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
7355 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
7356 and save_inferior as saved_thread.
7357 * regcache.c (get_thread_regcache): Renamed saved_inferior as
7358 saved_thread.
7359 (regcache_invalidate_thread): Likewise.
7360 * remote-utils.c (prepare_resume_reply): Likewise.
7361 * thread-db.c (thread_db_get_tls_address): Likewise.
7362 (disable_thread_event_reporting): Likewise.
7363 (remove_thread_event_breakpoints): Likewise.
7364 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
7365 as saved_thread.
7366 * target.h (set_desired_inferior): Renamed as...
7367 (set_desired_thread): New declaration. All uses updated.
7368 * server.c (myresume): Updated comment to reference thread instead
7369 of inferior.
7370 (handle_serial_event): Likewise.
7371 (handle_target_event): Likewise.
7372
7373 2014-09-12 Tom Tromey <tromey@redhat.com>
7374 Gary Benson <gbenson@redhat.com>
7375
7376 * regcache.h: Include common-regcache.h.
7377 (regcache_read_pc): Don't declare.
7378 * regcache.c (get_thread_regcache_for_ptid): New function.
7379
7380 2014-09-11 Tom Tromey <tromey@redhat.com>
7381 Gary Benson <gbenson@redhat.com>
7382
7383 * symbol.c: New file.
7384 * Makefile.in (SFILES): Add symbol.c.
7385 (OBS): Add symbol.o.
7386
7387 2014-09-11 Gary Benson <gbenson@redhat.com>
7388
7389 * target.c (target_stop_ptid, target_continue_ptid): New
7390 functions.
7391
7392 2014-09-11 Tom Tromey <tromey@redhat.com>
7393 Gary Benson <gbenson@redhat.com>
7394
7395 * target.h: Include target/target.h.
7396 * target.c (target_read_memory, target_read_uint32)
7397 (target_write_memory): New functions.
7398
7399 2014-09-11 Gary Benson <gbenson@redhat.com>
7400
7401 * server.h (debug_hw_points): Don't declare.
7402 * server.c (debug_hw_points): Don't define. Replace all uses
7403 with show_debug_regs.
7404 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
7405 all uses with show_debug_regs.
7406
7407 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
7408
7409 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
7410 endianness into account.
7411 (ppc_supply_ptrace_register): Likewise.
7412
7413 2014-09-03 James Hogan <james.hogan@imgtec.com>
7414
7415 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
7416 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
7417
7418 2014-09-03 Gary Benson <gbenson@redhat.com>
7419
7420 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
7421 ALL_DEBUG_ADDRESS_REGISTERS.
7422
7423 2014-09-02 Gary Benson <gbenson@redhat.com>
7424
7425 * i386-low.h: Renamed as...
7426 * x86-low.h: New file. All type, function and variable name
7427 prefixes changed from "i386_" to "x86_". All references updated.
7428 * i386-low.c: Renamed as...
7429 * x86-low.c: New file. All type, function and variable name
7430 prefixes changed from "i386_" to "x86_". All references updated.
7431
7432 2014-09-02 Gary Benson <gbenson@redhat.com>
7433
7434 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
7435 (x86_linux_new_thread): Likewise.
7436
7437 2014-08-29 Gary Benson <gbenson@redhat.com>
7438
7439 * server.h (setjmp.h): Do not include.
7440 (toplevel): Do not declare.
7441 (common-exceptions.h): Include.
7442 (cleanups.h): Likewise.
7443 * server.c (toplevel): Do not define.
7444 (exit_code): New static global.
7445 (detach_or_kill_for_exit_cleanup): New function.
7446 (main): New function. Original main renamed to...
7447 (captured_main): New function.
7448 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
7449
7450 2014-08-29 Gary Benson <gbenson@redhat.com>
7451
7452 * Makefile.in (SFILES): Add common/common-exceptions.c.
7453 (OBS): Add common-exceptions.o.
7454 (common-exceptions.o): New rule.
7455 * utils.c (prepare_to_throw_exception): New function.
7456
7457 2014-08-29 Gary Benson <gbenson@redhat.com>
7458
7459 * config.in: Regenerate.
7460 * configure: Likewise.
7461
7462 2014-08-29 Gary Benson <gbenson@redhat.com>
7463
7464 * Makefile.in (SFILES): Add common/cleanups.c.
7465 (OBS): cleanups.o.
7466 (cleanups.o): New rule.
7467
7468 2014-08-29 Gary Benson <gbenson@redhat.com>
7469
7470 * utils.c (internal_vwarning): New function.
7471
7472 2014-08-28 Gary Benson <gbenson@redhat.com>
7473
7474 * utils.h (fatal): Remove declaration.
7475 * utils.c (fatal): Remove function.
7476
7477 2014-08-28 Gary Benson <gbenson@redhat.com>
7478
7479 * tracepoint.c (gdb_agent_init): Replace fatal with
7480 perror_with_name.
7481 (initialize_tracepoint): Likewise.
7482
7483 2014-08-28 Gary Benson <gbenson@redhat.com>
7484
7485 * remote-utils.c (remote_prepare): Replace fatal with error.
7486
7487 2014-08-28 Gary Benson <gbenson@redhat.com>
7488
7489 * linux-low.c (linux_async): Replace fatal with warning.
7490 Tidy up and return.
7491 (linux_start_non_stop): Return -1 if linux_async failed.
7492
7493 2014-08-28 Gary Benson <gbenson@redhat.com>
7494
7495 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
7496 gdb_assert.
7497 (i386_dr_low_get_addr): Remove vague comment.
7498 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
7499 gdb_assert.
7500
7501 2014-08-28 Gary Benson <gbenson@redhat.com>
7502
7503 * inferiors.c (get_thread_process): Replace check with gdb_assert.
7504 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
7505 internal_error.
7506 (linux_resume_one_lwp): Likewise.
7507 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
7508 gdb_assert.
7509 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
7510 with internal_error.
7511 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
7512 (init_register_cache): Replace fatal with gdb_assert_not_reached.
7513 (find_register_by_name): Replace fatal with internal_error.
7514 (find_regno): Likewise.
7515 * tdesc.c (init_target_desc): Replace check with gdb_assert.
7516 * thread-db.c (thread_db_create_event): Likewise.
7517 (thread_db_load_search): Likewise.
7518 (try_thread_db_load_1): Likewise.
7519 * tracepoint.c (get_jump_space_head): Replace fatal with
7520 internal_error.
7521 (claim_trampoline_space): Likewise.
7522 (have_fast_tracepoint_trampoline_buffer): Likewise.
7523 (cmd_qtstart): Likewise.
7524 (stop_tracing): Likewise.
7525 (fast_tracepoint_collecting): Likewise.
7526 (target_malloc): Likewise.
7527 (download_tracepoint): Likewise.
7528 (download_trace_state_variables): Replace check with gdb_assert.
7529 (upload_fast_traceframes): Replace fatal with internal_error.
7530
7531 2014-08-19 Tom Tromey <tromey@redhat.com>
7532 Gary Benson <gbenson@redhat.com>
7533
7534 * Makefile.in (SFILES): Add common/common-debug.c.
7535 (OBS): Add common-debug.o.
7536 (common-debug.o): New rule.
7537 * debug.h (debug_printf): Don't declare.
7538 * debug.c (debug_printf): Renamed and rewritten as...
7539 (debug_vprintf): New function.
7540
7541 2014-08-19 Gary Benson <gbenson@redhat.com>
7542
7543 * utils.h: Do not include print-utils.h.
7544
7545 2014-08-19 Tom Tromey <tromey@redhat.com>
7546 Gary Benson <gbenson@redhat.com>
7547
7548 * server.h: Add static assertion.
7549 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
7550
7551 2014-08-19 Tom Tromey <tromey@redhat.com>
7552 Gary Benson <gbenson@redhat.com>
7553
7554 * Makefile.in (SFILES): Add common/errors.c.
7555 (OBS): Add errors.o.
7556 (IPA_OBS): Add errors-ipa.o.
7557 (errors.o): New rule.
7558 (errors-ipa.o): Likewise.
7559 * utils.h (perror_with_name, error, warning): Don't declare.
7560 * utils.c (warning): Renamed and rewritten as...
7561 (vwarning): New function.
7562 (error): Renamed and rewritten as...
7563 (verror): New function.
7564 (internal_error): Renamed and rewritten as...
7565 (internal_verror): New function.
7566
7567 2014-08-07 Gary Benson <gbenson@redhat.com>
7568
7569 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
7570 * configure: Regenerate.
7571 * config.in: Likewise.
7572 * server.h: Do not include errno.h.
7573 * event-loop.c: Likewise.
7574 * hostio-errno.c: Likewise.
7575 * linux-low.c: Likewise.
7576 * remote-utils.c: Likewise.
7577 * spu-low.c: Likewise.
7578 * utils.c: Likewise.
7579 * gdbreplay.c: Unconditionally include errno.h.
7580
7581 2014-08-07 Gary Benson <gbenson@redhat.com>
7582
7583 * server.h: Do not include string.h.
7584 * event-loop.c: Likewise.
7585 * linux-low.c: Likewise.
7586 * regcache.c: Likewise.
7587 * remote-utils.c: Likewise.
7588 * spu-low.c: Likewise.
7589 * utils.c: Likewise.
7590
7591 2014-08-07 Gary Benson <gbenson@redhat.com>
7592
7593 * server.h: Do not include gdb_assert.h.
7594
7595 2014-08-07 Gary Benson <gbenson@redhat.com>
7596
7597 * server.h: Do not include common-utils.h.
7598
7599 2014-08-07 Gary Benson <gbenson@redhat.com>
7600
7601 * server.h: Do not include ptid.h.
7602 * notif.h: Likewise.
7603
7604 2014-08-07 Gary Benson <gbenson@redhat.com>
7605
7606 * server.h: Do not include gdb_locale.h.
7607
7608 2014-08-07 Gary Benson <gbenson@redhat.com>
7609
7610 * server.h: Do not include gdb/signals.h.
7611 * win32-low.c: Likewise.
7612
7613 2014-08-07 Gary Benson <gbenson@redhat.com>
7614
7615 * server.h: Do not include pathmax.h.
7616
7617 2014-08-07 Gary Benson <gbenson@redhat.com>
7618
7619 * server.h: Do not include libiberty.h.
7620 * linux-bfin-low.c: Likewise.
7621
7622 2014-08-07 Gary Benson <gbenson@redhat.com>
7623
7624 * server.h: Do not include ansidecl.h.
7625
7626 2014-08-07 Gary Benson <gbenson@redhat.com>
7627
7628 * linux-x86-low.c: Do not include stddef.h.
7629 * lynx-ppc-low.c: Likewise.
7630 * tracepoint.c: Likewise.
7631
7632 2014-08-07 Gary Benson <gbenson@redhat.com>
7633
7634 * server.h: Do not include stdarg.h.
7635 * nto-low.c: Likewise.
7636
7637 2014-08-07 Gary Benson <gbenson@redhat.com>
7638
7639 * server.h: Do not include stdlib.h.
7640 * inferiors.c: Likewise.
7641 * linux-low.c: Likewise.
7642 * regcache.c: Likewise.
7643 * spu-low.c: Likewise.
7644 * tracepoint.c: Likewise.
7645 * utils.c: Likewise.
7646
7647 2014-08-07 Gary Benson <gbenson@redhat.com>
7648
7649 * server.h: Do not include stdio.h.
7650 * linux-low.c: Likewise.
7651 * remote-utils.c: Likewise.
7652 * spu-low.c: Likewise.
7653 * utils.c: Likewise.
7654 * wincecompat.c: Likewise.
7655
7656 2014-08-06 Gary Benson <gbenson@redhat.com>
7657
7658 * regcache.c (init_register_cache): Move conditionals inside if.
7659
7660 2014-08-06 Gary Benson <gbenson@redhat.com>
7661
7662 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
7663
7664 2014-07-31 Gary Benson <gbenson@redhat.com>
7665
7666 * ax.h: Do not include server.h.
7667 * gdbthread.h: Likewise.
7668 * lynx-low.h: Likewise.
7669 * notif.h: Likewise.
7670
7671 2014-07-30 Gary Benson <gbenson@redhat.com>
7672
7673 * server.h: Include common-defs.h.
7674 Do not include config.h or build-gnulib-gdbserver/config.h.
7675
7676 2014-07-30 Gary Benson <gbenson@redhat.com>
7677
7678 * hostio-errno.c: Move server.h to top of includes list.
7679 * inferiors.c: Likewise.
7680 * linux-x86-low.c: Likewise.
7681 * notif.c: Include server.h.
7682
7683 2014-07-24 Tom Tromey <tromey@redhat.com>
7684 Gary Benson <gbenson@redhat.com>
7685
7686 * server.h (CORE_ADDR): Now unsigned.
7687
7688 2014-07-16 Pedro Alves <palves@redhat.com>
7689
7690 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
7691
7692 2014-07-15 Pedro Alves <palves@redhat.com>
7693
7694 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
7695 copy.
7696
7697 2014-07-11 Pedro Alves <palves@redhat.com>
7698
7699 * linux-low.c (kill_wait_lwp): New function, based on
7700 kill_one_lwp_callback, but use my_waitpid directly.
7701 (kill_one_lwp_callback, linux_kill): Use it.
7702
7703 2014-06-23 Pedro Alves <palves@redhat.com>
7704
7705 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
7706 before setting DR0..DR3.
7707
7708 2014-06-20 Gary Benson <gbenson@redhat.com>
7709
7710 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
7711 * configure: Regenerated.
7712 * config.in: Likewise.
7713
7714 2014-06-20 Gary Benson <gbenson@redhat.com>
7715
7716 * Makefile.in (SFILES): Update locations for files moved
7717 from common to nat.
7718 (object file files): Reordered.
7719
7720 2014-06-20 Gary Benson <gbenson@redhat.com>
7721
7722 * i386-low.h (i386_dr_low_can_set_addr): Removed.
7723 (i386_dr_low_set_addr): Likewise.
7724 (i386_dr_low_get_addr): Likewise.
7725 (i386_dr_low_can_set_control): Likewise.
7726 (i386_dr_low_set_control): Likewise.
7727 (i386_dr_low_get_control): Likewise.
7728 (i386_dr_low_get_status): Likewise.
7729 (i386_get_debug_register_length): Likewise.
7730 * linux-x86-low.c (i386_dr_low_set_addr):
7731 Changed signature. Made static.
7732 (i386_dr_low_get_addr): Likewise.
7733 (i386_dr_low_set_control): Likewise.
7734 (i386_dr_low_get_control): Likewise.
7735 (i386_dr_low_get_status): Likewise.
7736 (i386_dr_low): New global variable.
7737 * win32-i386-low.c (i386_dr_low_set_addr):
7738 Changed signature. Made static.
7739 (i386_dr_low_get_addr): Likewise.
7740 (i386_dr_low_set_control): Likewise.
7741 (i386_dr_low_get_control): Likewise.
7742 (i386_dr_low_get_status): Likewise.
7743 (i386_dr_low): New global variable.
7744
7745 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
7746
7747 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
7748 * Makefile.in (AR, AR_FLAGS): Define.
7749 * configure: Regenerate.
7750
7751 2014-06-19 Gary Benson <gbenson@redhat.com>
7752
7753 * Makefile.in (i386-dregs.o): New rule.
7754 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
7755 * i386-low.c (target.h): Remove include.
7756 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
7757 (DR_CONTROL_SHIFT): Likewise.
7758 (DR_CONTROL_SIZE): Likewise.
7759 (DR_RW_EXECUTE): Likewise.
7760 (DR_RW_WRITE): Likewise.
7761 (DR_RW_READ): Likewise.
7762 (DR_RW_IORW): Likewise.
7763 (DR_LEN_1): Likewise.
7764 (DR_LEN_2): Likewise.
7765 (DR_LEN_4): Likewise.
7766 (DR_LEN_8): Likewise.
7767 (DR_LOCAL_ENABLE_SHIFT): Likewise.
7768 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
7769 (DR_ENABLE_SIZE): Likewise.
7770 (DR_LOCAL_SLOWDOWN): Likewise.
7771 (DR_GLOBAL_SLOWDOWN): Likewise.
7772 (DR_CONTROL_RESERVED): Likewise.
7773 (I386_DR_CONTROL_MASK): Likewise.
7774 (I386_DR_VACANT): Likewise.
7775 (I386_DR_LOCAL_ENABLE): Likewise.
7776 (I386_DR_GLOBAL_ENABLE): Likewise.
7777 (I386_DR_DISABLE): Likewise.
7778 (I386_DR_SET_RW_LEN): Likewise.
7779 (I386_DR_GET_RW_LEN): Likewise.
7780 (I386_DR_WATCH_HIT): Likewise.
7781 (i386_wp_op_t): Likewise.
7782 (i386_show_dr): Likewise.
7783 (i386_length_and_rw_bits): Likewise.
7784 (i386_insert_aligned_watchpoint): Likewise.
7785 (i386_remove_aligned_watchpoint): Likewise.
7786 (i386_handle_nonaligned_watchpoint): Likewise.
7787 i386_update_inferior_debug_regs(): Likewise.
7788 (i386_dr_insert_watchpoint): Likewise.
7789 (i386_dr_remove_watchpoint): Likewise.
7790 (i386_dr_region_ok_for_watchpoint): Likewise.
7791 (i386_dr_stopped_data_address): Likewise.
7792 (i386_dr_stopped_by_watchpoint): Likewise.
7793
7794 2014-06-19 Gary Benson <gbenson@redhat.com>
7795
7796 * i386-low.c (i386_dr_show): Renamed to
7797 i386_show_dr and made static. All uses updated.
7798 (i386_dr_length_and_rw_bits): Renamed to
7799 i386_length_and_rw_bits and made static.
7800 All uses updated.
7801 (i386_dr_insert_aligned_watchpoint): Renamed to
7802 i386_insert_aligned_watchpoint and made static.
7803 All uses updated.
7804 (i386_dr_remove_aligned_watchpoint): Renamed to
7805 i386_remove_aligned_watchpoint and made static.
7806 All uses updated.
7807 (i386_dr_update_inferior_debug_regs): Renamed to
7808 i386_update_inferior_debug_regs and made static.
7809 All uses updated.
7810
7811 2014-06-18 Gary Benson <gbenson@redhat.com>
7812
7813 * i386-low.h (i386_dr_low_can_set_addr): New macro.
7814 (i386_dr_low_can_set_control): Likewise.
7815 (i386_get_debug_register_length): Likewise.
7816 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
7817 (i386_dr_low_can_set_control): Likewise.
7818 (i386_get_debug_register_length): Likewise.
7819
7820 2014-06-17 Gary Benson <gbenson@redhat.com>
7821
7822 * i386-low.h (i386-dregs.h): New include.
7823 (DR_FIRSTADDR): Now in i386-dregs.h.
7824 (DR_LASTADDR): Likewise.
7825 (DR_NADDR): Likewise.
7826 (DR_STATUS): Likewise.
7827 (DR_CONTROL): Likewise.
7828 (i386_debug_reg_state): Likewise.
7829 (i386_dr_insert_watchpoint): Likewise.
7830 (i386_dr_remove_watchpoint): Likewise.
7831 (i386_dr_region_ok_for_watchpoint): Likewise.
7832 (i386_dr_stopped_data_address): Likewise.
7833 (i386_dr_stopped_by_watchpoint): Likewise.
7834 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
7835
7836 2014-06-18 Gary Benson <gbenson@redhat.com>
7837
7838 * i386-low.h (i386_low_insert_watchpoint): Renamed to
7839 i386_dr_insert_watchpoint.
7840 (i386_low_remove_watchpoint): Renamed to
7841 i386_dr_remove_watchpoint.
7842 (i386_low_region_ok_for_watchpoint): Renamed to
7843 i386_dr_region_ok_for_watchpoint.
7844 (i386_low_stopped_data_address): Renamed to
7845 i386_dr_stopped_data_address.
7846 (i386_low_stopped_by_watchpoint): Renamed to
7847 i386_dr_stopped_by_watchpoint.
7848 * i386-low.c (i386_show_dr): Renamed to
7849 i386_dr_show and made nonstatic. All uses updated.
7850 (i386_length_and_rw_bits): Renamed to
7851 i386_dr_length_and_rw_bits and made nonstatic.
7852 All uses updated.
7853 (i386_insert_aligned_watchpoint): Renamed to
7854 i386_dr_insert_aligned_watchpoint and made nonstatic.
7855 All uses updated.
7856 (i386_remove_aligned_watchpoint): Renamed to
7857 i386_dr_remove_aligned_watchpoint and made nonstatic.
7858 All uses updated.
7859 (i386_update_inferior_debug_regs): Renamed to
7860 i386_dr_update_inferior_debug_regs and made nonstatic.
7861 All uses updated.
7862 (i386_low_insert_watchpoint): Renamed to
7863 i386_dr_insert_watchpoint. All uses updated.
7864 (i386_low_remove_watchpoint): Renamed to
7865 i386_dr_remove_watchpoint. All uses updated.
7866 (i386_low_region_ok_for_watchpoint): Renamed to
7867 i386_dr_region_ok_for_watchpoint. All uses updated.
7868 (i386_low_stopped_data_address): Renamed to
7869 i386_dr_stopped_data_address. All uses updated.
7870 (i386_low_stopped_by_watchpoint): Renamed to
7871 i386_dr_stopped_by_watchpoint. All uses updated.
7872
7873 2014-06-18 Gary Benson <gbenson@redhat.com>
7874
7875 * i386-low.c (i386_dr_low_can_set_addr): New macro.
7876 (i386_dr_low_can_set_control): Likewise.
7877 (i386_insert_aligned_watchpoint): New check.
7878
7879 2014-06-18 Gary Benson <gbenson@redhat.com>
7880
7881 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
7882 Renamed to state.
7883
7884 2014-06-18 Gary Benson <gbenson@redhat.com>
7885
7886 * i386-low.c (i386_length_and_rw_bits): Use internal_error
7887 instead of fatal and error.
7888 (i386_handle_nonaligned_watchpoint): Likewise.
7889
7890 2014-06-18 Gary Benson <gbenson@redhat.com>
7891
7892 * i386-low.c (i386_get_debug_register_length): New macro.
7893 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
7894 (i386_show_dr): Use debug_printf instead of fprintf. Use
7895 phex to format values.
7896
7897 2014-06-18 Gary Benson <gbenson@redhat.com>
7898
7899 * i386-low.h: Comment changes.
7900 * i386-low.c: Likewise.
7901
7902 2014-06-18 Gary Benson <gbenson@redhat.com>
7903
7904 * i386-low.c: Whitespace changes.
7905
7906 2014-06-12 Tom Tromey <tromey@redhat.com>
7907
7908 * utils.c (freeargv): Remove.
7909
7910 2014-06-12 Tom Tromey <tromey@redhat.com>
7911
7912 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
7913 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
7914 (parse_debug_format_options): Likewise.
7915 (gdbserver_usage): Likewise.
7916 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
7917 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
7918 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
7919 against libiberty.
7920 ($(LIBGNU)): Depend on libiberty.
7921 (all-lib): Recurse into all subdirs.
7922 (install-only): Invoke "install" target in subdirs.
7923 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
7924 targets.
7925 * configure: Rebuild.
7926 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
7927 for vasprintf, vsnprintf, or gettimeofday.
7928 * configure.srv: Don't add safe-ctype.o or lbasename.o to
7929 srv_tgtobj.
7930
7931 2014-06-05 Joel Brobecker <brobecker@adacore.com>
7932
7933 * development.sh: Delete.
7934 * Makefile.in (config.status): Adjust dependency on development.sh.
7935 * configure.ac: Adjust development.sh source call.
7936 * configure: Regenerate.
7937
7938 2014-06-02 Pedro Alves <palves@redhat.com>
7939
7940 * ax.c (gdb_free_agent_expr): New function.
7941 * ax.h (gdb_free_agent_expr): New declaration.
7942 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
7943 list.
7944 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
7945 static.
7946 (clear_breakpoint_conditions_and_commands): New function.
7947 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
7948 (clear_breakpoint_conditions_and_commands): New declaration.
7949
7950 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
7951
7952 * linux-aarch64-low.c (asm/ptrace.h): Include.
7953
7954 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
7955
7956 Fix TLS access for -static -pthread.
7957 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
7958 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
7959 (thread_db_load_search, try_thread_db_load_1): Initialize it.
7960
7961 2014-05-20 Pedro Alves <palves@redhat.com>
7962
7963 * linux-aarch64-low.c (aarch64_insert_point)
7964 (aarch64_remove_point): No longer check whether the type is
7965 supported here. Adjust to new interface.
7966 (the_low_target): Install aarch64_supports_z_point_type as
7967 supports_z_point_type method.
7968 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
7969 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
7970 instead of a Z packet char. Adjust.
7971 (arm_supports_z_point_type): New function.
7972 (arm_insert_point, arm_remove_point): Adjust to new interface.
7973 (the_low_target): Install arm_supports_z_point_type.
7974 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
7975 (cris_insert_point, cris_remove_point): Adjust to new interface.
7976 Don't check whether the type is supported here.
7977 (the_low_target): Install cris_supports_z_point_type.
7978 * linux-low.c (linux_supports_z_point_type): New function.
7979 (linux_insert_point, linux_remove_point): Adjust to new interface.
7980 * linux-low.h (struct linux_target_ops) <insert_point,
7981 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
7982 raw_breakpoint pointer parameter.
7983 <supports_z_point_type>: New method.
7984 * linux-mips-low.c (mips_supports_z_point_type): New function.
7985 (mips_insert_point, mips_remove_point): Adjust to new interface.
7986 Use mips_supports_z_point_type.
7987 (the_low_target): Install mips_supports_z_point_type.
7988 * linux-ppc-low.c (the_low_target): Install NULL as
7989 supports_z_point_type method.
7990 * linux-s390-low.c (the_low_target): Install NULL as
7991 supports_z_point_type method.
7992 * linux-sparc-low.c (the_low_target): Install NULL as
7993 supports_z_point_type method.
7994 * linux-x86-low.c (x86_supports_z_point_type): New function.
7995 (x86_insert_point): Adjust to new insert_point interface. Use
7996 insert_memory_breakpoint. Adjust to new
7997 i386_low_insert_watchpoint interface.
7998 (x86_remove_point): Adjust to remove_point interface. Use
7999 remove_memory_breakpoint. Adjust to new
8000 i386_low_remove_watchpoint interface.
8001 (the_low_target): Install x86_supports_z_point_type.
8002 * lynx-low.c (lynx_target_ops): Install NULL as
8003 supports_z_point_type callback.
8004 * nto-low.c (nto_supports_z_point_type): New.
8005 (nto_insert_point, nto_remove_point): Adjust to new interface.
8006 (nto_target_ops): Install nto_supports_z_point_type.
8007 * mem-break.c: Adjust intro comment.
8008 (struct raw_breakpoint) <raw_type, size>: New fields.
8009 <inserted>: Update comment.
8010 <shlib_disabled>: Delete field.
8011 (enum bkpt_type) <gdb_breakpoint>: Delete value.
8012 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
8013 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
8014 (raw_bkpt_type_to_target_hw_bp_type): New function.
8015 (find_enabled_raw_code_breakpoint_at): New function.
8016 (find_raw_breakpoint_at): New type and size parameters. Use them.
8017 (insert_memory_breakpoint): New function, based off
8018 set_raw_breakpoint_at.
8019 (remove_memory_breakpoint): New function.
8020 (set_raw_breakpoint_at): Reimplement.
8021 (set_breakpoint): New, based on set_breakpoint_at.
8022 (set_breakpoint_at): Reimplement.
8023 (delete_raw_breakpoint): Go through the_target->remove_point
8024 instead of assuming memory breakpoints.
8025 (find_gdb_breakpoint_at): Delete.
8026 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
8027 (find_gdb_breakpoint): New function.
8028 (set_gdb_breakpoint_at): Delete.
8029 (z_type_supported): New function.
8030 (set_gdb_breakpoint_1): New function, loosely based off
8031 set_gdb_breakpoint_at.
8032 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
8033 (delete_gdb_breakpoint_at): Delete.
8034 (delete_gdb_breakpoint_1): New function, loosely based off
8035 delete_gdb_breakpoint_at.
8036 (delete_gdb_breakpoint): New function.
8037 (clear_gdb_breakpoint_conditions): Rename to ...
8038 (clear_breakpoint_conditions): ... this. Don't handle a NULL
8039 breakpoint.
8040 (add_condition_to_breakpoint): Make static.
8041 (add_breakpoint_condition): Take a struct breakpoint pointer
8042 instead of an address. Adjust.
8043 (gdb_condition_true_at_breakpoint): Rename to ...
8044 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
8045 z_type parameter.
8046 (gdb_condition_true_at_breakpoint): Reimplement.
8047 (add_breakpoint_commands): Take a struct breakpoint pointer
8048 instead of an address. Adjust.
8049 (gdb_no_commands_at_breakpoint): Rename to ...
8050 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
8051 parameter. Return true if no breakpoint was found. Change debug
8052 output.
8053 (gdb_no_commands_at_breakpoint): Reimplement.
8054 (run_breakpoint_commands): Rename to ...
8055 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
8056 and change return type to boolean.
8057 (run_breakpoint_commands): New function.
8058 (gdb_breakpoint_here): Also check for Z1 breakpoints.
8059 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
8060 breakpoint. Go through the_target->remove_point instead of
8061 assuming memory breakpoint.
8062 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
8063 software and hardware breakpoints.
8064 (reinsert_raw_breakpoint): Go through the_target->insert_point
8065 instead of assuming memory breakpoint.
8066 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
8067 software and hardware breakpoints.
8068 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
8069 Check both software and hardware breakpoints.
8070 (validate_inserted_breakpoint): Assert the breakpoint is a
8071 software breakpoint. Set the inserted flag to -1 instead of
8072 setting shlib_disabled.
8073 (delete_disabled_breakpoints): Adjust.
8074 (validate_breakpoints): Only validate software breakpoints.
8075 Adjust to inserted flag change.
8076 (check_mem_read, check_mem_write): Skip breakpoint types other
8077 than software breakpoints. Adjust to inserted flag change.
8078 * mem-break.h (enum raw_bkpt_type): New enum.
8079 (raw_breakpoint, struct process_info): Forward declare.
8080 (Z_packet_to_target_hw_bp_type): Delete declaration.
8081 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
8082 (set_gdb_breakpoint, delete_gdb_breakpoint)
8083 (clear_breakpoint_conditions): New declarations.
8084 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
8085 (breakpoint_inserted_here): Update comment.
8086 (add_breakpoint_condition, add_breakpoint_commands): Replace
8087 address parameter with a breakpoint pointer parameter.
8088 (gdb_breakpoint_here): Update comment.
8089 (delete_gdb_breakpoint_at): Delete.
8090 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
8091 * server.c (process_point_options): Take a struct breakpoint
8092 pointer instead of an address. Adjust.
8093 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
8094 delete_gdb_breakpoint.
8095 * spu-low.c (spu_target_ops): Install NULL as
8096 supports_z_point_type method.
8097 * target.h: Include mem-break.h.
8098 (struct target_ops) <prepare_to_access_memory>: Update comment.
8099 <supports_z_point_type>: New field.
8100 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
8101 instead of a char. Also take a raw breakpoint pointer.
8102 * win32-arm-low.c (the_low_target): Install NULL as
8103 supports_z_point_type.
8104 * win32-i386-low.c (i386_supports_z_point_type): New function.
8105 (i386_insert_point, i386_remove_point): Adjust to new interface.
8106 (the_low_target): Install i386_supports_z_point_type.
8107 * win32-low.c (win32_supports_z_point_type): New function.
8108 (win32_insert_point, win32_remove_point): Adjust to new interface.
8109 (win32_target_ops): Install win32_supports_z_point_type.
8110 * win32-low.h (struct win32_target_ops):
8111 <supports_z_point_type>: New method.
8112 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
8113 instead of a char. Also take a raw breakpoint pointer.
8114
8115 2014-05-20 Pedro Alves <palves@redhat.com>
8116
8117 * mem-break.h: Include break-common.h.
8118 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
8119 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
8120 (Z_packet_to_target_hw_bp_type): New declaration.
8121 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
8122 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
8123 (Z_PACKET_ACCESS_WP): Delete macros.
8124 (Z_packet_to_hw_type): Delete function.
8125 * i386-low.h: Don't include break-common.h here.
8126 (Z_packet_to_hw_type): Delete declaration.
8127 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
8128 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
8129 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
8130 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
8131 * linux-aarch64-low.c: Don't include break-common.h here.
8132 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
8133 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
8134 (Z_packet_to_target_hw_bp_type): Delete function.
8135 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
8136 function.
8137 (mips_insert_point, mips_remove_point): Use
8138 Z_packet_to_target_hw_bp_type.
8139
8140 2014-05-20 Pedro Alves <palves@redhat.com>
8141
8142 * linux-aarch64-low.c: Include break-common.h.
8143 (enum target_point_type): Delete.
8144 (Z_packet_to_point_type): Rename to ...
8145 (Z_packet_to_target_hw_bp_type): ... this, and return a
8146 target_hw_bp_type instead.
8147 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
8148 instead of an enum target_point_type.
8149 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
8150 breakpoint type.
8151 (aarch64_dr_state_insert_one_point)
8152 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
8153 (aarch64_handle_aligned_watchpoint)
8154 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
8155 Take an enum target_hw_bp_type instead of an enum
8156 target_point_type.
8157 (aarch64_supports_z_point_type): New function.
8158 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
8159 use Z_packet_to_target_hw_bp_type.
8160
8161 2014-05-20 Joel Brobecker <brobecker@adacore.com>
8162
8163 * configure.ac: Only use -Werror by default when DEVELOPMENT
8164 is true.
8165 * configure: Regenerate.
8166
8167 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
8168
8169 Fix gdbserver qGetTLSAddr for x86_64 -m32.
8170 * linux-x86-low.c (X86_64_USER_REGS): New.
8171 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
8172
8173 2014-04-28 Yao Qi <yao@codesourcery.com>
8174
8175 * Makefile.in (i386-avx512.c): Fix the typo of generated file
8176 name.
8177
8178 2014-04-25 Pedro Alves <palves@redhat.com>
8179
8180 PR server/16255
8181 * linux-low.c (linux_attach_fail_reason_string): New function.
8182 (linux_attach_lwp): Delete.
8183 (linux_attach_lwp_1): Rename to ...
8184 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
8185 argument. Remove "initial" parameter. Return int instead of
8186 void. Don't error or warn here.
8187 (linux_attach): Adjust to call linux_attach_lwp. Call error on
8188 failure to attach to the tgid. Call warning when failing to
8189 attach to an lwp.
8190 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
8191 argument. Remove "initial" parameter. Return int instead of
8192 void. Don't error or warn here.
8193 (linux_attach_fail_reason_string): New declaration.
8194 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
8195 interface change. Use linux_attach_fail_reason_string.
8196
8197 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
8198 Walfred Tedeschi <walfred.tedeschi@intel.com>
8199
8200 * Makefile.in: Added rules to handle new files
8201 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
8202 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
8203 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
8204 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
8205 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
8206 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
8207 x32-avx512-linux.o.
8208 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
8209 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
8210 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
8211 i386/x32-avx512.xml.
8212 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
8213 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
8214 i386/x32-avx512-linux.xml.
8215 * i387-fp.c (num_avx512_k_registers): New constant for number
8216 of K registers.
8217 (num_avx512_zmmh_low_registers): New constant for number of
8218 lower ZMM registers (0-15).
8219 (num_avx512_zmmh_high_registers): New constant for number of
8220 higher ZMM registers (16-31).
8221 (num_avx512_ymmh_registers): New contant for number of higher
8222 YMM registers (ymm16-31 added by avx521 on x86_64).
8223 (num_avx512_xmm_registers): New constant for number of higher
8224 XMM registers (xmm16-31 added by AVX512 on x86_64).
8225 (struct i387_xsave): Add space for AVX512 registers.
8226 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
8227 Add code to handle AVX512 registers.
8228 (i387_xsave_to_cache): Add code to handle AVX512 registers.
8229 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
8230 prototypei from generated file.
8231 (tdesc_amd64_avx512_linux): Likewise.
8232 (init_registers_x32_avx512_linux): Likewise.
8233 (tdesc_x32_avx512_linux): Likewise.
8234 (init_registers_i386_avx512_linux): Likewise.
8235 (tdesc_i386_avx512_linux): Likewise.
8236 (x86_64_regmap): Add AVX512 registers.
8237 (x86_linux_read_description): Add code to handle AVX512 XSTATE
8238 mask.
8239 (initialize_low_arch): Add code to initialize AVX512 registers.
8240
8241 2014-04-23 Pedro Alves <palves@redhat.com>
8242
8243 * mem-break.c (find_gdb_breakpoint_at): Make static.
8244 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
8245
8246 2014-04-23 Pedro Alves <palves@redhat.com>
8247
8248 * i386-low.c: Don't include break-common.h here.
8249 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
8250 prototype to take target_hw_bp_type as argument instead of a Z
8251 packet char.
8252 * i386-low.h: Include break-common.h here.
8253 (Z_packet_to_hw_type): Declare.
8254 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
8255 prototypes.
8256 * linux-x86-low.c (x86_insert_point): Convert the packet number to
8257 a target_hw_bp_type before calling i386_low_insert_watchpoint.
8258 (x86_remove_point): Convert the packet number to a
8259 target_hw_bp_type before calling i386_low_remove_watchpoint.
8260 * win32-i386-low.c (i386_insert_point): Convert the packet number
8261 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
8262 (i386_remove_point): Convert the packet number to a
8263 target_hw_bp_type before calling i386_low_remove_watchpoint.
8264
8265 2014-04-23 Pedro Alves <palves@redhat.com>
8266
8267 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
8268
8269 2014-04-10 Pedro Alves <palves@redhat.com>
8270
8271 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
8272 Check if the condition or command is NULL before checking if the
8273 breakpoint is known. On success, return true.
8274 * mem-break.h (add_breakpoint_condition): Document return.
8275 (add_breakpoint_commands): Add describing comment.
8276 * server.c (skip_to_semicolon): New function.
8277 (process_point_options): Use it.
8278
8279 2014-04-09 Pedro Alves <palves@redhat.com>
8280
8281 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
8282 to lwpid_of.
8283
8284 2014-02-27 Pedro Alves <palves@redhat.com>
8285
8286 PR 12702
8287 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
8288 macros.
8289 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
8290 output.
8291 (last_thread_of_process_p): Take a PID argument instead of a
8292 thread pointer.
8293 (linux_wait_for_lwp): Delete.
8294 (num_lwps, check_zombie_leaders, not_stopped_callback): New
8295 functions.
8296 (linux_low_filter_event): New function, party factored out from
8297 linux_wait_for_event.
8298 (linux_wait_for_event): Rename to ...
8299 (linux_wait_for_event_filtered): ... this. Add new filter ptid
8300 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
8301 sigsuspend. Check for zombie leaders.
8302 (linux_wait_for_event): Reimplement as wrapper around
8303 linux_wait_for_event_filtered.
8304 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
8305 a normal or signal exit is seen, it's the whole process exiting.
8306 (wait_for_sigstop): No longer a for_each_inferior callback.
8307 Rewrite on top of linux_wait_for_event_filtered.
8308 (stop_all_lwps): Call wait_for_sigstop directly.
8309 * server.c (resume, handle_target_event): Handle
8310 TARGET_WAITKIND_NO_RESUMED.
8311
8312 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8313
8314 * win32-low.c (psapi_get_dll_name,
8315 * win32_CreateToolhelp32Snapshot): Delete.
8316 (win32_CreateToolhelp32Snapshot, win32_Module32First)
8317 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
8318 Delete.
8319 (handle_load_dll): Add function description.
8320 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
8321
8322 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8323
8324 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
8325 Add comment.
8326 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
8327 base address when calling win32_add_one_solib.
8328 (handle_load_dll): Delete local variable load_addr.
8329 Remove 0x1000 offset applied to DLL base address when calling
8330 win32_add_one_solib.
8331 (handle_unload_dll): Add comment.
8332
8333 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8334
8335 * win32-low.c (win32_add_all_dlls): Renames
8336 win32_ensure_ntdll_loaded. Rewrite function documentation.
8337 Adjust implementation to always load all DLLs.
8338 Add 0x1000 offset to DLL base address when calling
8339 win32_add_one_solib.
8340 (child_initialization_done): New static global.
8341 (do_initial_child_stuff): Set child_initialization_done to
8342 zero during child initialization, and 1 after. Replace call
8343 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
8344 Add comment.
8345 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
8346 (handle_unload_dll): Add function documentation.
8347 (get_child_debug_event): Ignore load and unload DLL events
8348 during child initialization.
8349
8350 2014-02-20 Doug Evans <dje@google.com>
8351
8352 Remove global all_lwps.
8353 * inferiors.h (ptid_of): Move here from linux-low.h.
8354 (pid_of, lwpid_of): Ditto.
8355 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
8356 parameter is a struct thread_info * now.
8357 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
8358 directly. Pass &all_threads to find_inferior instead of &all_lwps.
8359 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
8360 directly.
8361 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
8362 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
8363 * linux-arm-low.c (update_registers_callback): Update, "entry"
8364 parameter is a struct thread_info * now.
8365 Fetch lwpid from current_inferior directly.
8366 (arm_insert_point): Pass &all_threads to find_inferior instead of
8367 &all_lwps.
8368 (arm_remove_point): Ditto.
8369 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
8370 (arm_prepare_to_resume): Fetch pid from thread.
8371 (arm_read_description): Fetch lwpid from current_inferior directly.
8372 * linux-low.c (all_lwps): Delete.
8373 (delete_lwp): Delete call to remove_inferior.
8374 (handle_extended_wait): Fetch lwpid from thread.
8375 (add_lwp): Don't set lwp->entry.id. Remove call to
8376 add_inferior_to_list.
8377 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
8378 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
8379 (kill_one_lwp_callback): Ditto.
8380 (linux_kill): Don't dereference NULL pointer.
8381 Fetch ptid,lwpid from thread.
8382 (get_detach_signal): Fetch ptid from thread.
8383 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
8384 Simplify call to regcache_invalidate_thread.
8385 (delete_lwp_callback): Update, "entry" parameter is a
8386 struct thread_info * now. Fetch pid from thread.
8387 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
8388 (status_pending_p_callback): Update, "entry" parameter is a
8389 struct thread_info * now. Fetch ptid from thread.
8390 (find_lwp_pid): Update, "entry" parameter is a
8391 struct thread_info * now.
8392 (linux_wait_for_lwp): Fetch pid from thread.
8393 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
8394 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
8395 (enqueue_one_deferred_signal): Fetch lwpid from thread.
8396 (dequeue_one_deferred_signal): Ditto.
8397 (cancel_breakpoint): Fetch ptid from current_inferior.
8398 (linux_wait_for_event): Pass &all_threads to find_inferior,
8399 not &all_lwps. Fetch ptid, lwpid from thread.
8400 (count_events_callback): Update, "entry" parameter is a
8401 struct thread_info * now.
8402 (select_singlestep_lwp_callback): Ditto.
8403 (select_event_lwp_callback): Ditto.
8404 (cancel_breakpoints_callback): Ditto.
8405 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
8406 not &all_lwps.
8407 (select_event_lwp): Ditto. Fetch ptid from event_thread.
8408 (unsuspend_one_lwp): Update, "entry" parameter is a
8409 struct thread_info * now.
8410 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
8411 not &all_lwps.
8412 (linux_stabilize_threads): Ditto. And for for_each_inferior.
8413 Fetch lwpid from thread, not lwp.
8414 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
8415 Pass &all_threads to find_inferior, not &all_lwps.
8416 (send_sigstop): Fetch lwpid from thread, not lwp.
8417 (send_sigstop_callback): Update, "entry" parameter is a
8418 struct thread_info * now.
8419 (suspend_and_send_sigstop_callback): Ditto.
8420 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
8421 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
8422 struct thread_info * now.
8423 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
8424 from thread, lwp.
8425 (lwp_running): Update, "entry" parameter is a
8426 struct thread_info * now.
8427 (stop_all_lwps): Fetch ptid from thread.
8428 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
8429 (linux_resume_one_lwp): Fetch lwpid from thread.
8430 (linux_set_resume_request): Update, "entry" parameter is a
8431 struct thread_info * now. Fetch pid, lwpid from thread.
8432 (resume_status_pending_p): Update, "entry" parameter is a
8433 struct thread_info * now.
8434 (need_step_over_p): Ditto. Fetch lwpid from thread.
8435 (start_step_over): Fetch lwpid from thread.
8436 (linux_resume_one_thread): Update, "entry" parameter is a
8437 struct thread_info * now. Fetch lwpid from thread.
8438 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
8439 (proceed_one_lwp): Update, "entry" parameter is a
8440 struct thread_info * now. Fetch lwpid from thread.
8441 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
8442 struct thread_info * now.
8443 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
8444 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
8445 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
8446 directly.
8447 (regsets_store_inferior_registers): Ditto.
8448 (fetch_register, store_register): Ditto.
8449 (linux_read_memory, linux_write_memory): Ditto.
8450 (linux_request_interrupt): Ditto.
8451 (linux_read_auxv): Ditto.
8452 (linux_xfer_siginfo): Ditto.
8453 (linux_qxfer_spu): Ditto.
8454 (linux_qxfer_libraries_svr4): Ditto.
8455 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
8456 moved to inferiors.h.
8457 (get_lwp): Delete.
8458 (get_thread_lwp): Update.
8459 (struct lwp_info): Delete member "entry". Simplify comment for
8460 member "thread".
8461 (all_lwps): Delete.
8462 * linux-mips-low.c (mips_read_description): Fetch lwpid from
8463 current_inferior directly.
8464 (update_watch_registers_callback): Update, "entry" parameter is a
8465 struct thread_info * now. Fetch pid from thread.
8466 (mips_linux_prepare_to_resume): Fetch ptid from thread.
8467 (mips_insert_point): Fetch lwpid from current_inferior.
8468 Pass &all_threads to find_inferior, not &all_lwps.
8469 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
8470 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
8471 directly.
8472 (mips_stopped_data_address): Ditto.
8473 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
8474 directly.
8475 * linux-tile-low.c (tile_arch_setup): Ditto.
8476 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
8477 (update_debug_registers_callback): Update, "entry" parameter is a
8478 struct thread_info * now. Fetch pid from thread.
8479 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
8480 Pass &all_threads to find_inferior, not &all_lwps.
8481 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
8482 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
8483 Pass &all_threads to find_inferior, not &all_lwps.
8484 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
8485 (i386_dr_low_get_status): Ditto.
8486 (x86_linux_prepare_to_resume): Fetch ptid from thread.
8487 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
8488 (x86_linux_read_description): Ditto.
8489 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
8490
8491 2014-02-20 Doug Evans <dje@google.com>
8492
8493 * inferiors.c (get_first_inferior): Fix buglet.
8494
8495 2014-02-19 Doug Evans <dje@google.com>
8496
8497 * gdbthread.h (add_thread): Change result type to struct thread_info *.
8498 * inferiors.c (add_thread): Change result type to struct thread_info *.
8499 All callers updated.
8500 (add_lwp): Call add_thread here instead of in callers.
8501 All callers updated.
8502 * linux-low.h (get_lwp_thread): Rewrite.
8503 (struct lwp_info): New member "thread".
8504
8505 2014-02-19 Doug Evans <dje@google.com>
8506
8507 * linux-low.c (add_lwp): Change result to struct lwp_info *.
8508 All callers updated.
8509
8510 2014-02-19 Doug Evans <dje@google.com>
8511
8512 * inferiors.c (add_thread): Fix whitespace.
8513
8514 2014-02-19 Doug Evans <dje@google.com>
8515
8516 * dll.c (clear_dlls): Replace accessing list implemention details
8517 with API function.
8518 * gdbthread.h (get_first_thread): Declare.
8519 * inferiors.c (for_each_inferior_with_data): New function.
8520 (get_first_thread): New function.
8521 (find_thread_ptid): Simplify.
8522 (get_first_inferior): New function.
8523 (clear_list): Delete.
8524 (one_inferior_p): New function.
8525 (clear_inferior_list): New function.
8526 (clear_inferiors): Update.
8527 * inferiors.h (for_each_inferior_with_data): Declare.
8528 (clear_inferior_list): Declare.
8529 (one_inferior_p): Declare.
8530 (get_first_inferior): Declare.
8531 * linux-low.c (linux_wait_for_event): Replace accessing list
8532 implemention details with API function.
8533 * server.c (target_running): Ditto.
8534 (accumulate_file_name_length): New function.
8535 (emit_dll_description): New function.
8536 (handle_qxfer_libraries): Replace accessing list implemention
8537 details with API function.
8538 (handle_qxfer_threads_worker): New function.
8539 (handle_qxfer_threads_proper): Replace accessing list implemention
8540 details with API function.
8541 (handle_query): Ditto.
8542 (visit_actioned_threads_callback_ftype): New typedef.
8543 (visit_actioned_threads_data): New struct.
8544 (visit_actioned_threads): Rewrite to be find_inferior callback.
8545 (resume): Call find_inferior.
8546 (handle_status): Replace accessing list implemention
8547 details with API function.
8548 (process_serial_event): Replace accessing list implemention details
8549 with API function.
8550 * target.c (set_desired_inferior): Replace accessing list implemention
8551 details with API function.
8552 * tracepoint.c (same_process_p): New function.
8553 (gdb_agent_about_to_close): Replace accessing list implemention
8554 details with API function.
8555 * win32-low.c (child_delete_thread): Replace accessing list
8556 implemention details with API function.
8557 (match_dll_by_basename): New function.
8558 (dll_is_loaded_by_basename): New function.
8559 (win32_ensure_ntdll_loaded): Replace accessing list implemention
8560 details call to dll_is_loaded_by_basename.
8561
8562 2014-02-19 Doug Evans <dje@google.com>
8563
8564 * dll.h (struct dll_info): Add comment.
8565 * gdbthread.h (struct thread_info): Add comment.
8566 (current_ptid): Simplify.
8567 * inferiors.c (add_process): Update.
8568 (remove_process): Update.
8569 * inferiors.h (struct process_info): Rename member "head" to "entry".
8570 * linux-low.c (delete_lwp): Update.
8571 (add_lwp): Update.
8572 (last_thread_of_process_p): Update.
8573 (kill_one_lwp_callback, linux_kill): Update.
8574 (status_pending_p_callback): Update.
8575 (wait_for_sigstop): Update. Simplify read of ptid.
8576 (start_step_over): Update.
8577 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
8578 (get_lwp_thread): Update.
8579 (struct lwp_info): Rename member "head" to "entry".
8580 * regcache.h (inferior_list_entry): Delete.
8581 * server.c (kill_inferior_callback): Update.
8582 (detach_or_kill_inferior_callback): Update.
8583 (print_started_pid): Update.
8584 (print_attached_pid): Update.
8585 (process_serial_event): Simplify read of ptid.
8586 * thread-db.c (thread_db_create_event): Update.
8587 (thread_db_get_tls_address): Update.
8588 * win32-low.c (current_inferior_ptid): Simplify.
8589
8590 2014-02-19 Tom Tromey <tromey@redhat.com>
8591
8592 * target.h (struct target_ops) <supports_btrace>: Add target_ops
8593 argument.
8594 (target_supports_btrace): Update.
8595
8596 2014-02-14 Yao Qi <yao@codesourcery.com>
8597
8598 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
8599 (rsp-low-ipa.o): New target.
8600
8601 2014-02-12 Tom Tromey <tromey@redhat.com>
8602
8603 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
8604 convert_ascii_to_int.
8605 * regcache.c (registers_to_string): Likewise.
8606 * remote-utils.c (decode_M_packet): Likewise.
8607 * server.c (process_serial_event): Likewise.
8608
8609 2014-02-12 Tom Tromey <tromey@redhat.com>
8610
8611 * server.c (handle_query, handle_v_run): Use hex2bin, not
8612 unhexify.
8613 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
8614
8615 2014-02-12 Tom Tromey <tromey@redhat.com>
8616
8617 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
8618 convert_int_to_ascii.
8619 * regcache.c (registers_to_string, collect_register_as_string):
8620 Likewise.
8621 * remote-utils.c (look_up_one_symbol, relocate_instruction):
8622 Likewise.
8623 * server.c (process_serial_event): Likewise.
8624 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
8625 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
8626
8627 2014-02-12 Tom Tromey <tromey@redhat.com>
8628
8629 * remote-utils.c (look_up_one_symbol, monitor_output): Use
8630 bin2hex, not hexify.
8631 * tracepoint.c (cmd_qtstatus): Likewise.
8632
8633 2014-02-12 Tom Tromey <tromey@redhat.com>
8634
8635 * remote-utils.c (monitor_output): Pass explicit length to
8636 hexify.
8637
8638 2014-02-12 Tom Tromey <tromey@redhat.com>
8639
8640 * tracepoint.c: Include rsp-low.h.
8641 * server.c: Include rsp-low.h.
8642 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
8643 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
8644 declare.
8645 * remote-utils.c: Include rsp-low.h.
8646 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
8647 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
8648 (convert_int_to_ascii, convert_ascii_to_int): Move to
8649 common/rsp-low.c.
8650 * regcache.c: Include rsp-low.h.
8651 * ax.c: Include rsp-low.h.
8652 * Makefile.in (SFILES): Add common/rsp-low.c.
8653 (OBS): Add rsp-low.o.
8654 (rsp-low.o): New target.
8655
8656 2014-02-12 Tom Tromey <tromey@redhat.com>
8657
8658 * utils.h (pulongest, plongest, phex_nz): Don't declare.
8659 Include print-utils.h.
8660 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
8661 (plongest, thirty_two, phex_nz): Remove.
8662 * Makefile.in (SFILES): Add common/print-utils.c.
8663 (OBS): Add print-utils.o.
8664 (print-utils-ipa.o): New target.
8665 (print-utils.o): New target.
8666 (IPA_OBJS): Add print-utils-ipa.o.
8667
8668 2014-02-06 Tom Tromey <tromey@redhat.com>
8669
8670 * Makefile.in (SFILES): Fix indentation.
8671
8672 2014-02-05 Doug Evans <dje@google.com>
8673
8674 * linux-low.c (linux_wait_for_event): Improve comment.
8675 (linux_wait_1): Keep current_inferior in sync with event_child.
8676
8677 2014-01-22 Doug Evans <dje@google.com>
8678
8679 * gdbthread.h (gdb_id_to_thread): Delete, unused.
8680
8681 2014-01-22 Doug Evans <dje@google.com>
8682
8683 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
8684 * configure: Regenerate.
8685 * config.in: Regenerate.
8686 * Makefile.in (SFILES): Add debug.c.
8687 (OBS): Add debug.o.
8688 * debug.c: New file.
8689 * debug.h: New file.
8690 * linux-aarch64-low.c (*): Update all debugging printfs to use
8691 debug_printf instead of fprintf.
8692 * linux-arm-low.c (*): Ditto.
8693 * linux-cris-low.c (*): Ditto.
8694 * linux-crisv32-low.c (*): Ditto.
8695 * linux-m32r-low.c (*): Ditto.
8696 * linux-sparc-low.c (*): Ditto.
8697 * linux-x86.c (*): Ditto.
8698 * linux-low.c (*): Ditto.
8699 (linux_wait_1): Add calls to debug_enter, debug_exit.
8700 (linux_wait): Remove redundant debugging printf.
8701 (stop_all_lwps): Add calls to debug_enter, debug_exit.
8702 (linux_resume, unstop_all_lwps): Ditto.
8703 * mem-break.c (*): Update all debugging printfs to use
8704 debug_printf instead of fprintf.
8705 * remote-utils.c (*): Ditto.
8706 * thread-db.c (*): Ditto.
8707 * server.c #include <ctype.h>, "gdb_vecs.h".
8708 (debug_threads): Moved to debug.c.
8709 (*): Update all debugging printfs to use debug_printf instead of
8710 fprintf.
8711 (start_inferior): Replace call to fflush with call to debug_flush.
8712 (monitor_show_help): Mention set debug-format.
8713 (parse_debug_format_options): New function.
8714 (handle_monitor_command): Handle "monitor set debug-format".
8715 (gdbserver_usage): Mention --debug-format.
8716 (main): Parse --debug-format.
8717 * server.h (debug_threads): Declaration moved to debug.h.
8718 #include "debug.h".
8719 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
8720 trace_debug_1 that uses debug_printf.
8721 (tracepoint_look_up_symbols): Update all debugging printfs to use
8722 debug_printf instead of fprintf.
8723
8724 2014-01-20 Baruch Siach <baruch@tkos.co.il>
8725
8726 * linux-xtensa-low.c: Include asm/ptrace.h instead of
8727 sys/ptrace.h.
8728
8729 2014-01-17 Pedro Alves <palves@redhat.com>
8730
8731 PR build/16445
8732 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
8733 defined after including gdb_proc_service.h.
8734
8735 2014-01-16 Doug Evans <dje@google.com>
8736
8737 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
8738 (match_dll): Use it.
8739
8740 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
8741
8742 * target.h (target_ops) <read_btrace>: Change parameters and
8743 return type to allow error reporting.
8744 * server.c (handle_qxfer_btrace): Support delta reads. Pass
8745 trace reading errors on.
8746 * linux-low.c (linux_low_read_btrace): Pass trace reading
8747 errors on.
8748 (linux_low_disable_btrace): New.
8749
8750 2014-01-15 Doug Evans <dje@google.com>
8751
8752 * inferiors.c (thread_id_to_gdb_id): Delete.
8753 * inferiors.h (thread_id_to_gdb_id): Delete.
8754
8755 2014-01-13 Eli Zaretskii <eliz@gnu.org>
8756
8757 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
8758 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
8759 versions.
8760
8761 2014-01-08 Pedro Alves <palves@redhat.com>
8762
8763 * server.c (handle_status): Don't discard previous queued stop
8764 replies or thread's pending status here.
8765 (main) <disconnection>: Do it here instead.
8766
8767 2014-01-08 Pedro Alves <palves@redhat.com>
8768
8769 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
8770 * server.c (visit_actioned_threads, handle_pending_status): New
8771 function.
8772 (handle_v_cont): Factor out parts to ...
8773 (resume): ... this new function. If in all-stop, and a thread
8774 being resumed has a pending status, report it without actually
8775 resuming.
8776 (myresume): Adjust to use the new 'resume' function.
8777 (clear_pending_status_callback, set_pending_status_callback)
8778 (find_status_pending_thread_callback): New functions.
8779 (handle_status): Handle the case of multiple threads having
8780 interesting statuses to report. Report threads' real last signal
8781 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
8782 with an interesting thread to report the status for, instead of
8783 always reporting the status of the first thread.
8784
8785 2014-01-01 Joel Brobecker <brobecker@adacore.com>
8786
8787 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
8788 * gdbreplay.c (gdbreplay_version): Likewise.
8789
8790 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
8791
8792 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
8793 iov.iov_len with the real length in use.
8794
8795 2013-12-13 Joel Brobecker <brobecker@adacore.com>
8796
8797 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
8798 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
8799 for all targets that use win32-low.c.
8800 * win32-low.c (win32_ensure_ntdll_loaded): New function.
8801 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
8802
8803 2013-12-13 Pedro Alves <palves@redhat.com>
8804
8805 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
8806 if equal to TARGET_WAITKIND_LOADED.
8807 * win32-low.c (cached_status): New static global.
8808 (win32_wait): Add declaration.
8809 (do_initial_child_stuff): Flush all initial pending debug events
8810 up to the initial breakpoint.
8811 (win32_wait): If CACHED_STATUS was set, return that instead
8812 of doing a real wait. Remove the code resuming the execution
8813 of the inferior after receiving a TARGET_WAITKIND_LOADED event
8814 during the initial phase. Also remove the code changing
8815 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
8816 TARGET_WAITKIND_STOPPED.
8817
8818 2013-12-11 Yao Qi <yao@codesourcery.com>
8819
8820 * notif.c (handle_notif_ack): Return 0 if no notification
8821 matches.
8822
8823 2013-11-20 Doug Evans <dje@google.com>
8824
8825 * linux-low.c (linux_set_resume_request): Fix comment.
8826
8827 2013-11-20 Doug Evans <dje@google.com>
8828
8829 * linux-low.c (resume_status_pending_p): Tweak comment.
8830
8831 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
8832
8833 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
8834 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
8835 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
8836 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
8837 (srv_amd64_regobj): Add amd64-mpx.o.
8838 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
8839 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
8840 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
8841 * i387-fp.c (num_pl_bnd_register) Added constant.
8842 (num_pl_bnd_cfg_registers) Added constant.
8843 (struct i387_xsave) Added reserved area and MPX fields.
8844 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
8845 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
8846 function.
8847 (tdesc_i386_mpx_linux): Add MPX amd64 target.
8848 (init_registers_amd64_mpx_linux): Declare new function.
8849 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
8850 (x86_64_regmap): Add MPX registers.
8851 (x86_linux_read_description): Add MPX case.
8852 (initialize_low_arch): Initialize MPX targets.
8853
8854 2013-11-18 Tom Tromey <tromey@redhat.com>
8855
8856 * configure: Rebuild.
8857 * configure.ac: Don't check for stdlib.h.
8858 * gdbreplay.c: Unconditionally include stdlib.h.
8859
8860 2013-11-18 Tom Tromey <tromey@redhat.com>
8861
8862 * config.in: Rebuild.
8863 * configure: Rebuild.
8864 * configure.ac: Don't use AC_HEADER_DIRENT.
8865
8866 2013-11-18 Tom Tromey <tromey@redhat.com>
8867
8868 * server.h: Don't check HAVE_STRING_H.
8869 * gdbreplay.c: Don't check HAVE_STRING_H.
8870 * configure: Rebuild.
8871
8872 2013-11-18 Tom Tromey <tromey@redhat.com>
8873
8874 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
8875 LIBGNU.
8876
8877 2013-11-08 Tom Tromey <tromey@redhat.com>
8878
8879 * configure, config.in: Rebuild.
8880 * configure.ac: Remove unused configury.
8881
8882 2013-11-08 Tom Tromey <tromey@redhat.com>
8883
8884 * acinclude.m4: Include common.m4, codeset.m4.
8885 * configure, config.in: Rebuild.
8886 * configure.ac: Use GDB_AC_COMMON.
8887
8888 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
8889
8890 * linux-s390-low.c (HWCAP_S390_TE): New define.
8891 (s390_arch_setup): Consider the TE field in the HWCAP for
8892 determining 'have_regset_tdb'.
8893
8894 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
8895
8896 PR gdb/16014
8897 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
8898 call to sizeof.
8899
8900 2013-10-02 Pedro Alves <palves@redhat.com>
8901
8902 * server.c (process_serial_event): Don't output "GDBserver
8903 exiting" if GDB is connected through stdio.
8904 * target.c (mywait): Likewise, be silent if GDB is connected
8905 through stdio.
8906
8907 2013-10-01 Joel Brobecker <brobecker@adacore.com>
8908
8909 * lynx-low.c (lynx_add_threads_after_attach): New function.
8910 (lynx_attach): Remove call to add_thread. Add call to
8911 lynx_add_threads_after_attach instead.
8912
8913 2013-09-28 Mike Frysinger <vapier@gentoo.org>
8914
8915 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
8916 * config.in, configure: Regenerated.
8917
8918 2013-09-18 Yao Qi <yao@codesourcery.com>
8919
8920 PR server/15959
8921 * server.c (start_inferior): Clear 'resume_info'.
8922
8923 2013-09-16 Jiong Wang <jiwang@tilera.com>
8924
8925 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
8926 for each register.
8927
8928 2013-09-16 Jiong Wang <jiwang@tilera.com>
8929
8930 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
8931 linux-tile-low.o to srv_tgtobj.
8932
8933 2013-09-16 Will Newton <will.newton@linaro.org>
8934
8935 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
8936 out regs.
8937
8938 2013-09-06 Pedro Alves <palves@redhat.com>
8939
8940 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
8941 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
8942 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
8943 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
8944 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
8945 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
8946
8947 2013-09-06 Pedro Alves <palves@redhat.com>
8948
8949 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
8950 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
8951
8952 2013-09-06 Pedro Alves <palves@redhat.com>
8953
8954 * linux-amd64-ipa.c: Include tracepoint.h.
8955 * linux-i386-ipa.c: Include tracepoint.h.
8956
8957 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
8958
8959 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
8960 (ps_get_thread_area): New function.
8961
8962 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
8963
8964 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
8965 (initialize_low_arch): Call init_registers_crisv32 rather than
8966 init_register_crisv32.
8967
8968 2013-09-05 Pedro Alves <palves@redhat.com>
8969
8970 * server.h (handle_vFile, hostio_last_error_from_errno): Move
8971 to ...
8972 * hostio.h: ... this new file.
8973 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
8974 win32-low.c: Include hostio.h.
8975
8976 2013-09-05 Pedro Alves <palves@redhat.com>
8977
8978 * server.h (gdb_client_data, handler_func, callback_handler_func)
8979 (delete_file_handler, add_file_handler, append_callback_event)
8980 (delete_callback_event, start_event_loop, initialize_event_loop):
8981 Move to event-loop.h and include it.
8982 * event-loop.h: New file.
8983
8984 2013-09-05 Pedro Alves <palves@redhat.com>
8985
8986 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
8987 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
8988 (loaded_dll, unloaded_dll): Move to ...
8989 * dll.h: ... this new file.
8990 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
8991
8992 2013-09-05 Pedro Alves <palves@redhat.com>
8993
8994 * server.h (current_process, get_thread_process, all_processes)
8995 (add_inferior_to_list, for_each_inferior, current_inferior)
8996 (remove_inferior, add_process, remove_process, find_process_pid)
8997 (have_started_inferiors_p, have_attached_inferiors_p)
8998 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
8999 (clear_inferiors, find_inferior, find_inferior_id)
9000 (inferior_target_data, set_inferior_target_data)
9001 (inferior_regcache_data, set_inferior_regcache_data): Move to
9002 inferiors.h, and include it.
9003 * inferiors.h: New file.
9004
9005 2013-09-05 Pedro Alves <palves@redhat.com>
9006
9007 * server.h (struct emit_ops, current_insn_ptr, emit_error):
9008 Move ...
9009 * ax.h: ... here.
9010
9011 2013-09-05 Pedro Alves <palves@redhat.com>
9012
9013 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
9014 tracepoint.h.
9015 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
9016 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
9017 (handle_tracepoint_general_set, handle_tracepoint_query)
9018 (tracepoint_finished_step, tracepoint_was_hit)
9019 (release_while_stepping_state_list, current_traceframe)
9020 (in_readonly_region, traceframe_read_mem)
9021 (fetch_traceframe_registers, traceframe_read_sdata)
9022 (traceframe_read_info, struct fast_tpoint_collect_status)
9023 (fast_tracepoint_collecting, force_unlock_trace_buffer)
9024 (handle_tracepoit_bkpts, initialize_low_tracepoint)
9025 (supply_fast_tracepoint_registers)
9026 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
9027 (ipa_tdesc, claim_trampoline_space)
9028 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
9029 (agent_mem_read, agent_get_trace_state_variable_value)
9030 (agent_set_trace_state_variable_value, agent_tsv_read)
9031 (agent_mem_read_string, get_raw_reg_func_addr)
9032 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
9033 * tracepoint.h: ... this new file.
9034
9035 2013-09-05 Pedro Alves <palves@redhat.com>
9036
9037 * server.h (perror_with_name, error, fatal, warning, paddress)
9038 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
9039 include it.
9040 * utils.h: New file.
9041
9042 2013-09-05 Pedro Alves <palves@redhat.com>
9043
9044 * server.h (remote_debug, noack_mode, transport_is_reliable)
9045 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
9046 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
9047 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
9048 (write_enn, initialize_async_io, enable_async_io)
9049 (disable_async_io, check_remote_input_interrupt_request)
9050 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
9051 (dead_thread_notify, prepare_resume_reply)
9052 (decode_address_to_semicolon, decode_address, decode_m_packet)
9053 (decode_M_packet, decode_X_packet, decode_xfer_write)
9054 (decode_search_memory_packet, unhexify, hexify)
9055 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
9056 (look_up_one_symbol, relocate_instruction)
9057 (monitor_output): Move to remote-utils.h, and include it.
9058 * remote-utils.h: New file.
9059
9060 2013-09-05 Pedro Alves <palves@redhat.com>
9061
9062 * server.h (_): Delete.
9063
9064 2013-09-02 Pedro Alves <palves@redhat.com>
9065
9066 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
9067 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
9068 allocated.
9069 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
9070
9071 2013-09-02 Pierre Muller <muller@sourceware.org>
9072
9073 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
9074 or WriteProcessMemory complete successfully and handle
9075 ERROR_PARTIAL_COPY error.
9076
9077 2013-09-02 Pedro Alves <palves@redhat.com>
9078
9079 * server.c (gdb_read_memory): Return -1 on traceframe memory read
9080 error instead of EIO.
9081
9082 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
9083
9084 PR server/15604
9085 * linux-low.c: Include filestuff.h.
9086 (linux_create_inferior) <pid == 0>: Call close_most_fds.
9087 * lynx-low.c: Include filestuff.h.
9088 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
9089 * server.c: Include filestuff.h.
9090 (main): Call notice_open_fds.
9091 * spu-low.c: Include filestuff.h.
9092 (spu_create_inferior) <pid == 0>: Call close_most_fds.
9093
9094 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
9095
9096 * Makefile.in: Explain why ../target and ../nat are not
9097 listed as include file search paths.
9098 (linux-waitpid.o): New object file rule.
9099 * configure.srv (srv_native_linux_obj): New variable.
9100 Replace all occurrences of linux native object files with
9101 $srv_native_linux_obj.
9102 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
9103 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
9104 (linux_enable_event_reporting): Remove declaration.
9105 (my_waitpid): Moved to common/linux-waitpid.c.
9106 (linux_wait_for_event): Pass ptid when calling
9107 linux_enable_event_reporting.
9108 (linux_supports_tracefork_flag): Remove.
9109 (linux_enable_event_reporting): Likewise.
9110 (linux_tracefork_grandchild): Remove.
9111 (STACK_SIZE): Moved to common/linux-ptrace.c.
9112 (linux_tracefork_child): Remove.
9113 (linux_test_for_tracefork): Remove.
9114 (linux_look_up_symbols): Call linux_supports_traceclone.
9115 (initialize_low): Remove call to linux_test_for_tracefork.
9116 * linux-low.h (PTRACE_TYPE_ARG3): Move to
9117 common/linux-ptrace.h.
9118 (PTRACE_TYPE_ARG4): Likewise.
9119 Include linux-ptrace.h.
9120
9121 2013-08-21 Pedro Alves <palves@redhat.com>
9122
9123 * config.in: Renegerate.
9124
9125 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
9126
9127 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
9128 (SFILES): Remove $(srcdir)/common/target-common.c and
9129 add $(srcdir)/target/waitstatus.c.
9130 (OBS): Remove target-common.o and add waitstatus.o.
9131 (server_h): Remove $(srcdir)/../common/target-common.h and
9132 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
9133 and $(srcdir)/../target/waitstatus.h.
9134 (target-common.o): Remove.
9135 (waitstatus.o): New target object file.
9136 * target.h: Do not include target-common.h and
9137 include target/resume.h, target/wait.h and
9138 target/waitstatus.h.
9139
9140 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
9141
9142 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
9143 to PTRACE_TYPE_ARG3.
9144 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
9145 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
9146 PTRACE_TYPE_ARG4.
9147 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
9148 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
9149
9150 2013-07-27 Jie Zhang <jie@codesourcery.com>
9151 Daniel Jacobowitz <dan@codesourcery.com>
9152 Yao Qi <yao@codesourcery.com>
9153
9154 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
9155 (mips-linux-watch.o): New rule.
9156 (mips_linux_watch_h): New variable.
9157 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
9158 srv_tgtobj.
9159 * linux-mips-low.c: Include mips-linux-watch.h.
9160 (struct arch_process_info, struct arch_lwp_info): New.
9161 (update_watch_registers_callback): New function.
9162 (mips_linux_new_process, mips_linux_new_thread) New functions.
9163 (mips_linux_prepare_to_resume, mips_insert_point): New
9164 functions.
9165 (mips_remove_point, mips_stopped_by_watchpoint): New
9166 functions.
9167 (rsp_bp_type_to_target_hw_bp_type): New function.
9168 (mips_stopped_data_address): New function.
9169 (the_low_target): Add watchpoint support functions.
9170
9171 2013-07-27 Yao Qi <yao@codesourcery.com>
9172
9173 * i386-low.c: Include break-common.h.
9174 (enum target_hw_bp_type): Remove.
9175
9176 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
9177
9178 * Makefile.in (SFILES): /common/target-common.c.
9179 (OBS): Add target-common.o.
9180 (server_h): Add $(srcdir)/../common/target-common.h.
9181 (target-common.o): New target.
9182 * server.c (queue_stop_reply_callback): Free
9183 status string after use.
9184 * target.c (target_waitstatus_to_string): Remove.
9185 * target.h: Include target-common.h.
9186 (resume_kind): Likewise.
9187 (target_waitkind): Likewise.
9188 (target_waitstatus): Likewise.
9189 (TARGET_WNOHANG): Likewise.
9190
9191 2013-07-04 Yao Qi <yao@codesourcery.com>
9192
9193 * Makefile.in (host_alias): Use @host_noncanonical@.
9194 (target_alias): Use @target_noncanonical@.
9195 * configure.ac: Use ACX_NONCANONICAL_TARGET and
9196 ACX_NONCANONICAL_HOST.
9197 * configure: Regenerated.
9198
9199 Revert:
9200 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
9201
9202 * configure.ac (version_host, version_target): Set and AC_SUBST them.
9203 * configure: Rebuild.
9204 * Makefile.in (version_host, version_target): Get from configure.
9205 (version.c): Use $(version_host) and $(version_target).
9206
9207 2013-07-03 Pedro Alves <palves@redhat.com>
9208
9209 * Makefile.in (config.status): Depend on development.sh.
9210 * acinclude.m4: Include libmcheck.m4.
9211 * configure: Regenerate.
9212
9213 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
9214
9215 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
9216 attribute inside the parentheses.
9217 (winapi_DebugSetProcessKillOnExit): Ditto.
9218 (winapi_DebugBreakProcess): Ditto.
9219 (winapi_GenerateConsoleCtrlEvent): Ditto.
9220
9221 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
9222
9223 * notif.h (notif_event): Add a dummy member to avoid compiler
9224 errors.
9225
9226 2013-07-01 Pedro Alves <palves@redhat.com>
9227
9228 * hostio.c (HOSTIO_PATH_MAX): Define.
9229 (require_filename, handle_open, handle_unlink, handle_readlink):
9230 Use it.
9231
9232 2013-07-01 Pedro Alves <palves@redhat.com>
9233
9234 * server.h: Include "pathmax.h".
9235 * linux-low.c: Don't include sys/param.h.
9236 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
9237 MAXPATHLEN.
9238 * win32-low.c: Don't include sys/param.h.
9239 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
9240
9241 2013-07-01 Pedro Alves <palves@redhat.com>
9242
9243 * event-loop.c: Don't check HAVE_UNISTD_H before including
9244 <unistd.h>.
9245 * gdbreplay.c: Likewise.
9246 * remote-utils.c: Likewise.
9247 * server.c: Likewise.
9248 * configure.ac: Don't check for unistd.h.
9249 * configure: Regenerate.
9250
9251 2013-06-28 Tom Tromey <tromey@redhat.com>
9252
9253 * Makefile.in (version.c): Use version.in, not
9254 common/version.in.
9255
9256 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
9257
9258 * configure.ac (version_host, version_target): Set and AC_SUBST them.
9259 * configure: Rebuild.
9260 * Makefile.in (version_host, version_target): Get from configure.
9261 (version.c): Use $(version_host) and $(version_target).
9262
9263 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
9264
9265 Fix trace-status to output user name without trailing colon.
9266 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
9267
9268 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
9269
9270 Fix trace-status to output proper start-time and stop-time.
9271 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
9272 output start time and stop time in hex as gdb expects.
9273
9274 2013-06-26 Pedro Alves <pedro@codesourcery.com>
9275
9276 * tracepoint.c (build_traceframe_info_xml): Output trace state
9277 variables present in the trace buffer.
9278
9279 2013-06-24 Tom Tromey <tromey@redhat.com>
9280
9281 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
9282 create-version.sh.
9283 (version.o): Remove.
9284 * gdbreplay.c: Include version.h.
9285 (version, host_name): Don't declare.
9286 * server.h: Include version.h.
9287 (version, host_name): Don't declare.
9288
9289 2013-06-12 Pedro Alves <palves@redhat.com>
9290
9291 * linux-x86-low.c (linux_is_elf64): Delete global.
9292 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
9293 with local linux_pid_exe_is_elf_64_file use.
9294
9295 2013-06-11 Pedro Alves <palves@redhat.com>
9296
9297 * linux-low.c (regset_disabled, disable_regset): New functions.
9298 (regsets_fetch_inferior_registers)
9299 (regsets_store_inferior_registers): Use them.
9300 (initialize_regsets_info); Don't allocate the disabled_regsets
9301 array here.
9302 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
9303 comment.
9304
9305 2013-06-11 Pedro Alves <palves@redhat.com>
9306
9307 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
9308 xmalloc.
9309
9310 2013-06-11 Pedro Alves <palves@redhat.com>
9311
9312 * linux-x86-low.c (initialize_low_arch): Call
9313 init_registers_x32_avx_linux.
9314
9315 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
9316
9317 Fix compatibility with Android Bionic.
9318 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
9319 it is not empty.
9320
9321 2013-06-07 Pedro Alves <palves@redhat.com>
9322
9323 PR server/14823
9324 * Makefile.in (OBS): Add tdesc.o.
9325 (IPA_OBJS): Add tdesc-ipa.o.
9326 (tdesc-ipa.o): New rule.
9327 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
9328 interface.
9329 * linux-low.c (new_inferior): Delete.
9330 (disabled_regsets, num_regsets): Delete.
9331 (linux_add_process): Adjust to set the new per-process
9332 new_inferior flag.
9333 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
9334 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
9335 was a stop. When calling arch_setup, switch the current inferior
9336 to the thread that got an event.
9337 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
9338 (regsets_fetch_inferior_registers)
9339 (regsets_store_inferior_registers): New regsets_info parameter.
9340 Adjust to use it.
9341 (linux_register_in_regsets): New regs_info parameter. Adjust to
9342 use it.
9343 (register_addr, fetch_register, store_register): New usrregs_info
9344 parameter. Adjust to use it.
9345 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
9346 parameter regs_info. Adjust to use it.
9347 (linux_fetch_registers): Get the current inferior's regs_info, and
9348 adjust to use it.
9349 (linux_store_registers): Ditto.
9350 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
9351 (initialize_low): Don't initialize the target_regsets here. Call
9352 initialize_low_arch.
9353 * linux-low.h (target_regsets): Delete declaration.
9354 (struct regsets_info): New.
9355 (struct usrregs_info): New.
9356 (struct regs_info): New.
9357 (struct process_info_private) <new_inferior>: New field.
9358 (struct linux_target_ops): Delete the num_regs, regmap, and
9359 regset_bitmap fields. New field regs_info.
9360 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
9361 * i387-fp.c (num_xmm_registers): Delete.
9362 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
9363 calls to new interface.
9364 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
9365 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
9366 Infer the number of xmm registers from the regcache's target
9367 description.
9368 * i387-fp.h (num_xmm_registers): Delete.
9369 * inferiors.c (add_thread): Don't install the thread's regcache
9370 here.
9371 * proc-service.c (gregset_info): Fetch the current inferior's
9372 regs_info. Adjust to use it.
9373 * regcache.c: Include tdesc.h.
9374 (register_bytes, reg_defs, num_registers)
9375 (gdbserver_expedite_regs): Delete.
9376 (get_thread_regcache): If the thread doesn't have a regcache yet,
9377 create one, instead of aborting gdbserver.
9378 (regcache_invalidate_one): Rename to ...
9379 (regcache_invalidate_thread): ... this.
9380 (regcache_invalidate_one): New.
9381 (regcache_invalidate): Only invalidate registers of the current
9382 process.
9383 (init_register_cache): Add target_desc parameter, and use it.
9384 (new_register_cache): Ditto. Assert the target description has a
9385 non zero registers_size.
9386 (regcache_cpy): Add assertions. Adjust.
9387 (realloc_register_cache, set_register_cache): Delete.
9388 (registers_to_string, registers_from_string): Adjust.
9389 (find_register_by_name, find_regno, find_register_by_number)
9390 (register_cache_size): Add target_desc parameter, and use it.
9391 (free_register_cache_thread, free_register_cache_thread_one)
9392 (regcache_release, register_cache_size): New.
9393 (register_size): Add target_desc parameter, and use it.
9394 (register_data, supply_register, supply_register_zeroed)
9395 (supply_regblock, supply_register_by_name, collect_register)
9396 (collect_register_as_string, collect_register_by_name): Adjust.
9397 * regcache.h (struct target_desc): Forward declare.
9398 (struct regcache) <tdesc>: New field.
9399 (init_register_cache, new_register_cache): Add target_desc
9400 parameter.
9401 (regcache_invalidate_thread): Declare.
9402 (regcache_invalidate_one): Delete declaration.
9403 (regcache_release): Declare.
9404 (find_register_by_number, register_cache_size, register_size)
9405 (find_regno): Add target_desc parameter.
9406 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
9407 declarations.
9408 * remote-utils.c: Include tdesc.h.
9409 (outreg, prepare_resume_reply): Adjust.
9410 * server.c: Include tdesc.h.
9411 (gdbserver_xmltarget): Delete declaration.
9412 (get_features_xml, process_serial_event): Adjust.
9413 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
9414 declare.
9415 (struct process_info) <tdesc>: New field.
9416 (ipa_tdesc): Declare.
9417 * tdesc.c: New file.
9418 * tdesc.h: New file.
9419 * tracepoint.c: Include tdesc.h.
9420 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
9421 (get_context_regcache): Adjust to pass ipa_tdesc down.
9422 (do_action_at_tracepoint): Adjust to get the register cache size
9423 from the context regcache's description.
9424 (traceframe_walk_blocks): Adjust to get the register cache size
9425 from the current trace frame's description.
9426 (traceframe_get_pc): Adjust to get current trace frame's
9427 description and pass it down.
9428 (gdb_collect): Adjust to get the register cache size from the
9429 IPA's description.
9430 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
9431 (gdbserver_xmltarget): Delete.
9432 (initialize_low_tracepoint): Set the ipa's target description.
9433 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
9434 (initialize_low_tracepoint): Set the ipa's target description.
9435 * linux-x86-low.c: Include tdesc.h.
9436 [__x86_64__] (is_64bit_tdesc): New.
9437 (ps_get_thread_area, x86_get_thread_area): Use it.
9438 (i386_cannot_store_register): Rename to ...
9439 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
9440 (i386_cannot_fetch_register): Rename to ...
9441 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
9442 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
9443 to new interface.
9444 (target_regsets): Rename to ...
9445 (x86_regsets): ... this.
9446 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
9447 interface.
9448 (x86_siginfo_fixup): Use is_64bit_tdesc.
9449 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
9450 (tdesc_x32_avx_linux, tdesc_x32_linux)
9451 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
9452 Declare.
9453 (x86_linux_update_xmltarget): Delete.
9454 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
9455 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
9456 (AMD64_LINUX_USER64_CS): New.
9457 (x86_linux_read_description): New, based on
9458 x86_linux_update_xmltarget.
9459 (same_process_callback): New.
9460 (x86_arch_setup_process_callback): New.
9461 (x86_linux_update_xmltarget): New.
9462 (x86_regsets_info): New.
9463 (amd64_linux_regs_info): New.
9464 (i386_linux_usrregs_info): New.
9465 (i386_linux_regs_info): New.
9466 (x86_linux_regs_info): New.
9467 (x86_arch_setup): Reimplement.
9468 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
9469 (x86_emit_ops): Ditto.
9470 (the_low_target): Adjust. Install x86_linux_regs_info,
9471 x86_cannot_fetch_register, and x86_cannot_store_register.
9472 (initialize_low_arch): New.
9473 * linux-ia64-low.c (tdesc_ia64): Declare.
9474 (ia64_fetch_register): Adjust.
9475 (ia64_usrregs_info, regs_info): New globals.
9476 (ia64_regs_info): New function.
9477 (the_low_target): Adjust.
9478 (initialize_low_arch): New function.
9479 * linux-sparc-low.c (tdesc_sparc64): Declare.
9480 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
9481 Adjust.
9482 (sparc_arch_setup): New function.
9483 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
9484 (the_low_target): Adjust.
9485 (initialize_low_arch): New function.
9486 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
9487 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
9488 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
9489 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
9490 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
9491 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
9492 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
9493 (tdesc_powerpc_isa205_vsx64l): Declare.
9494 (ppc_cannot_store_register, ppc_collect_ptrace_register)
9495 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
9496 (ppc_set_pc, ppc_get_hwcap): Adjust.
9497 (ppc_usrregs_info): Forward declare.
9498 (!__powerpc64__) ppc_regmap_adjusted: New global.
9499 (ppc_arch_setup): Adjust to the current process'es target
9500 description.
9501 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
9502 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
9503 (ppc_store_evrregset): Adjust.
9504 (target_regsets): Rename to ...
9505 (ppc_regsets): ... this, and make static.
9506 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
9507 (ppc_regs_info): New function.
9508 (the_low_target): Adjust.
9509 (initialize_low_arch): New function.
9510 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
9511 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
9512 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
9513 (tdesc_s390x_linux64v2): Declare.
9514 (s390_collect_ptrace_register, s390_supply_ptrace_register)
9515 (s390_fill_gregset, s390_store_last_break): Adjust.
9516 (target_regsets): Rename to ...
9517 (s390_regsets): ... this, and make static.
9518 (s390_get_pc, s390_set_pc): Adjust.
9519 (s390_get_hwcap): New target_desc parameter, and use it.
9520 [__s390x__] (have_hwcap_s390_high_gprs): New global.
9521 (s390_arch_setup): Adjust to set the current process'es target
9522 description. Don't adjust the regmap.
9523 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
9524 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
9525 (regs_info_3264): New globals.
9526 (s390_regs_info): New function.
9527 (the_low_target): Adjust.
9528 (initialize_low_arch): New function.
9529 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
9530 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
9531 [__mips64] (init_registers_mips_linux)
9532 (init_registers_mips_dsp_linux): Delete defines.
9533 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
9534 (have_dsp): New global.
9535 (mips_read_description): New, based on mips_arch_setup.
9536 (mips_arch_setup): Reimplement.
9537 (get_usrregs_info): New function.
9538 (mips_cannot_fetch_register, mips_cannot_store_register)
9539 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
9540 (mips_fill_fpregset, mips_store_fpregset): Adjust.
9541 (target_regsets): Rename to ...
9542 (mips_regsets): ... this, and make static.
9543 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
9544 (dsp_regs_info, regs_info): New globals.
9545 (mips_regs_info): New function.
9546 (the_low_target): Adjust.
9547 (initialize_low_arch): New function.
9548 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
9549 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
9550 Declare.
9551 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
9552 (arm_read_description): New, with bits factored from
9553 arm_arch_setup.
9554 (arm_arch_setup): Reimplement.
9555 (target_regsets): Rename to ...
9556 (arm_regsets): ... this, and make static.
9557 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
9558 (arm_regs_info): New function.
9559 (the_low_target): Adjust.
9560 (initialize_low_arch): New function.
9561 * linux-m68k-low.c (tdesc_m68k): Declare.
9562 (target_regsets): Rename to ...
9563 (m68k_regsets): ... this, and make static.
9564 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
9565 (m68k_regs_info): New function.
9566 (m68k_arch_setup): New function.
9567 (the_low_target): Adjust.
9568 (initialize_low_arch): New function.
9569 * linux-sh-low.c (tdesc_sharch): Declare.
9570 (target_regsets): Rename to ...
9571 (sh_regsets): ... this, and make static.
9572 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
9573 (sh_regs_info, sh_arch_setup): New functions.
9574 (the_low_target): Adjust.
9575 (initialize_low_arch): New function.
9576 * linux-bfin-low.c (tdesc_bfin): Declare.
9577 (bfin_arch_setup): New function.
9578 (bfin_usrregs_info, regs_info): New globals.
9579 (bfin_regs_info): New function.
9580 (the_low_target): Adjust.
9581 (initialize_low_arch): New function.
9582 * linux-cris-low.c (tdesc_cris): Declare.
9583 (cris_arch_setup): New function.
9584 (cris_usrregs_info, regs_info): New globals.
9585 (cris_regs_info): New function.
9586 (the_low_target): Adjust.
9587 (initialize_low_arch): New function.
9588 * linux-cris-low.c (tdesc_crisv32): Declare.
9589 (cris_arch_setup): New function.
9590 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
9591 (cris_regs_info): New function.
9592 (the_low_target): Adjust.
9593 (initialize_low_arch): New function.
9594 * linux-m32r-low.c (tdesc_m32r): Declare.
9595 (m32r_arch_setup): New function.
9596 (m32r_usrregs_info, regs_info): New globals.
9597 (m32r_regs_info): Adjust.
9598 (initialize_low_arch): New function.
9599 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
9600 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
9601 (tic6x_usrregs_info): Forward declare.
9602 (tic6x_read_description): New function, based on ...
9603 (tic6x_arch_setup): ... this. Reimplement.
9604 (target_regsets): Rename to ...
9605 (tic6x_regsets): ... this, and make static.
9606 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
9607 (tic6x_regs_info): New function.
9608 (the_low_target): Adjust.
9609 (initialize_low_arch): New function.
9610 * linux-xtensa-low.c (tdesc_xtensa): Declare.
9611 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
9612 (target_regsets): Rename to ...
9613 (xtensa_regsets): ... this, and make static.
9614 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
9615 globals.
9616 (xtensa_arch_setup, xtensa_regs_info): New functions.
9617 (the_low_target): Adjust.
9618 (initialize_low_arch): New function.
9619 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
9620 (nios2_arch_setup): Set the current process'es tdesc.
9621 (target_regsets): Rename to ...
9622 (nios2_regsets): ... this.
9623 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
9624 (nios2_regs_info): New function.
9625 (the_low_target): Adjust.
9626 (initialize_low_arch): New function.
9627 * linux-aarch64-low.c (tdesc_aarch64): Declare.
9628 (aarch64_arch_setup): Set the current process'es tdesc.
9629 (target_regsets): Rename to ...
9630 (aarch64_regsets): ... this.
9631 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
9632 (aarch64_regs_info): New function.
9633 (the_low_target): Adjust.
9634 (initialize_low_arch): New function.
9635 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
9636 globals.
9637 (target_regsets): Rename to ...
9638 (tile_regsets): ... this.
9639 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
9640 (tile_regs_info): New function.
9641 (tile_arch_setup): Set the current process'es tdesc.
9642 (the_low_target): Adjust.
9643 (initialize_low_arch): New function.
9644 * spu-low.c (tdesc_spu): Declare.
9645 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
9646 * win32-arm-low.c (tdesc_arm): Declare.
9647 (arm_arch_setup): New function.
9648 (the_low_target): Install arm_arch_setup instead of
9649 init_registers_arm.
9650 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
9651 (init_windows_x86): Rename to ...
9652 (i386_arch_setup): ... this. Set `win32_tdesc'.
9653 (the_low_target): Adjust.
9654 * win32-low.c (win32_tdesc): New global.
9655 (child_add_thread): Don't create the thread cache here.
9656 (do_initial_child_stuff): Set the new process'es tdesc.
9657 * win32-low.h (struct target_desc): Forward declare.
9658 (win32_tdesc): Declare.
9659 * lynx-i386-low.c (tdesc_i386): Declare global.
9660 (lynx_i386_arch_setup): Set `lynx_tdesc'.
9661 * lynx-low.c (lynx_tdesc): New global.
9662 (lynx_add_process): Set the new process'es tdesc.
9663 * lynx-low.h (struct target_desc): Forward declare.
9664 (lynx_tdesc): Declare global.
9665 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
9666 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
9667 * nto-low.c (nto_tdesc): New global.
9668 (do_attach): Set the new process'es tdesc.
9669 * nto-low.h (struct target_desc): Forward declare.
9670 (nto_tdesc): Declare.
9671 * nto-x86-low.c (tdesc_i386): Declare.
9672 (nto_x86_arch_setup): Set `nto_tdesc'.
9673
9674 2013-06-04 Gary Benson <gbenson@redhat.com>
9675
9676 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
9677 to qSupported response when appropriate.
9678 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
9679 with nonzero-length annex.
9680 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
9681 arguments supplied in annex.
9682
9683 2013-05-31 Doug Evans <dje@google.com>
9684
9685 PR server/15594
9686 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
9687 64 bits in 64-cross-32 environment.
9688
9689 2013-05-28 Pedro Alves <palves@redhat.com>
9690
9691 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
9692 (aarch64-without-fpu.c): Delete rule.
9693 * configure.srv (aarch64*-*-linux*): Remove references to
9694 aarch64-without-fpu.o and aarch64-without-fpu.xml.
9695 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
9696 declaration.
9697
9698 2013-05-24 Pedro Alves <palves@redhat.com>
9699
9700 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
9701 instead of strchr/decode_address. Error if the range isn't split
9702 with a ','. Don't assume there's be a ':' in the action.
9703
9704 2013-05-23 Yao Qi <yao@codesourcery.com>
9705 Pedro Alves <palves@redhat.com>
9706
9707 * linux-low.c (lwp_in_step_range): New function.
9708 (linux_wait_1): If the thread was range stepping and stopped
9709 outside the stepping range, report the stop to GDB. Otherwise,
9710 continue stepping. Add range stepping debug output.
9711 (linux_set_resume_request): Copy the step range from the resume
9712 request to the lwp.
9713 (linux_supports_range_stepping): New.
9714 (linux_target_ops) <supports_range_stepping>: Set to
9715 linux_supports_range_stepping.
9716 * linux-low.h (struct linux_target_ops)
9717 <supports_range_stepping>: New field.
9718 (struct lwp_info) <step_range_start, step_range_end>: New fields.
9719 * linux-x86-low.c (x86_supports_range_stepping): New.
9720 (the_low_target) <supports_range_stepping>: Set to
9721 x86_supports_range_stepping.
9722 * server.c (handle_v_cont): Handle 'r' action.
9723 (handle_v_requests): Append ";r" if the target supports range
9724 stepping.
9725 * target.h (struct thread_resume) <step_range_start,
9726 step_range_end>: New fields.
9727 (struct target_ops) <supports_range_stepping>:
9728 New field.
9729 (target_supports_range_stepping): New macro.
9730
9731 2013-05-17 Joel Brobecker <brobecker@adacore.com>
9732
9733 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
9734 confusion in comment.
9735
9736 2013-05-17 Joel Brobecker <brobecker@adacore.com>
9737
9738 * lynx-low.c (struct process_info_private): New type.
9739 (lynx_add_process): New function.
9740 (lynx_create_inferior, lynx_attach): Replace calls to
9741 add_process by calls to lynx_add_process.
9742 (lynx_resume): If PTID is null, then try using
9743 current_process()->private->last_wait_event_ptid.
9744 Add comments.
9745 (lynx_clear_inferiors): Delete. The contents of that function
9746 has been inlined in lynx_mourn;
9747 (lynx_wait_1): Save the ptid in the process's private data.
9748 (lynx_mourn): Free the process' private data. Replace call
9749 to lynx_clear_inferiors by call to clear_inferiors.
9750
9751 2013-05-17 Yao Qi <yao@codesourcery.com>
9752
9753 * i386-low.c (i386_length_and_rw_bits): Move the comment to
9754 the right place.
9755
9756 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
9757
9758 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
9759 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
9760 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
9761 PT_TEXT_END_ADDR guards. Update comments.
9762 (linux_target_op) <read_offsets>: Conditionally define to
9763 linux_read_offsets if the target is UCLIBC and if it defines
9764 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
9765
9766 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
9767 Andrew Jenner <andrew@codesourcery.com>
9768
9769 * Makefile.in (SFILES): Add linux-nios2-low.c.
9770 (clean): Add action to delete nios2-linux.c.
9771 (nios2-linux.c): New rule.
9772 * configure.srv: Add nios2*-*-linux*.
9773 * linux-nios2-low.c: New.
9774
9775 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
9776
9777 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
9778
9779 2013-04-25 Hui Zhu <hui@codesourcery.com>
9780
9781 PR gdb/15186
9782 * ax.c (ax_printf): Add fflush.
9783
9784 2013-04-22 Tom Tromey <tromey@redhat.com>
9785
9786 * Makefile.in (SFILES): Add filestuff.c.
9787 (OBS): Add filestuff.o.
9788 (filestuff.o): New target.
9789 * config.in, configure: Rebuild.
9790 * configure.ac: Check for fdwalk, pipe2.
9791
9792 2013-04-17 Pedro Alves <palves@redhat.com>
9793
9794 * configure.ac (USE_THREAD_DB): Delete variable.
9795 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
9796 Don't AC_SUBST USE_THREAD_DB.
9797 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
9798 * config.in, configure: Regenerate.
9799
9800 2013-04-16 Pedro Alves <palves@redhat.com>
9801
9802 * linux-low.h (struct lwp_info) <thread_known>: Move under
9803 the USE_THREAD_DB #ifdef.
9804
9805 2013-04-16 Pedro Alves <palves@redhat.com>
9806
9807 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
9808 (linux-low.o): Delete rule.
9809 * linux-low.h: Always include "gdb_thread_db.h" instead of
9810 conditionally including thread_db.h.
9811 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
9812 HAVE_THREAD_DB_H.
9813
9814 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
9815
9816 * Makefile.in (install-only): Fix make install regression.
9817
9818 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
9819
9820 Convert man pages to texinfo, new gdbinit.5 texinfo page.
9821 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
9822 installation.
9823 * gdbserver.1: Remove.
9824
9825 2013-03-22 Pedro Alves <palves@redhat.com>
9826
9827 * linux-low.c (handle_extended_wait): Don't call
9828 linux_enable_event_reporting.
9829
9830 2013-03-15 Tony Theodore <tonyt@logyst.com>
9831
9832 PR build/9098:
9833 * Makefile.in (SHELL): Use @SHELL@.
9834
9835 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
9836
9837 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
9838 compiler warning.
9839
9840 2013-03-13 Joel Brobecker <brobecker@adacore.com>
9841
9842 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
9843 Remove extraneous NULL element.
9844
9845 2013-03-13 Yao Qi <yao@codesourcery.com>
9846
9847 * tracepoint.c (traceframe_read_tsv): Look for the last matched
9848 'V' block in trace frame.
9849
9850 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9851
9852 * target.h (struct target_ops): Add btrace ops.
9853 (target_supports_btrace): New macro.
9854 (target_enable_btrace): New macro.
9855 (target_disable_btrace): New macro.
9856 (target_read_btrace): New macro.
9857 * gdbthread.h (struct thread_info): Add btrace field.
9858 * server.c: Include btrace-common.h.
9859 (handle_btrace_general_set): New function.
9860 (handle_btrace_enable): New function.
9861 (handle_btrace_disable): New function.
9862 (handle_general_set): Call handle_btrace_general_set.
9863 (handle_qxfer_btrace): New function.
9864 (struct qxfer qxfer_packets[]): Add btrace entry.
9865 * inferiors.c (remove_thread): Disable btrace.
9866 * linux-low: Include linux-btrace.h.
9867 (linux_low_enable_btrace): New function.
9868 (linux_low_read_btrace): New function.
9869 (linux_target_ops): Add btrace ops.
9870 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
9871 Add srv_linux_btrace=yes.
9872 (x86_64-*-linux*): Add linux-btrace.o.
9873 Add srv_linux_btrace=yes.
9874 * configure.ac: Define HAVE_LINUX_BTRACE.
9875 * config.in: Regenerated.
9876 * configure: Regenerated.
9877
9878 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9879
9880 * server.c (handle_qxfer): Preserve error message if -3 is
9881 returned.
9882 (qxfer): Document the -3 return value.
9883
9884 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9885
9886 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
9887 (linux_btrace_h): New variable.
9888 (linux-btrace.o): New rule.
9889
9890 2013-03-08 Stan Shebs <stan@codesourcery.com>
9891 Hafiz Abid Qadeer <abidh@codesourcery.com>
9892
9893 * tracepoint.c (trace_buffer_size): New global.
9894 (DEFAULT_TRACE_BUFFER_SIZE): New define.
9895 (init_trace_buffer): Change to one-argument function. Allocate
9896 trace buffer memory.
9897 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
9898 handle QTBuffer:size packet.
9899 (cmd_bigqtbuffer_size): New function.
9900 (initialize_tracepoint): Call init_trace_buffer with
9901 DEFAULT_TRACE_BUFFER_SIZE.
9902 * server.c (handle_query): Add QTBuffer:size in the
9903 supported packets.
9904
9905 2013-03-07 Yao Qi <yao@codesourcery.com>
9906
9907 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
9908 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
9909 of -1.
9910 (cmd_qtsp): Adjust condition. Do post increment.
9911 Set cur_action and cur_step_action back to 0.
9912
9913 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
9914
9915 PR server/15236
9916 * linux-low.c (linux_write_memory): Return early success if LEN is
9917 zero.
9918
9919 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
9920
9921 * configure.srv: Add x86_64-*-cygwin* as target.
9922
9923 2013-02-28 Tom Tromey <tromey@redhat.com>
9924
9925 * configure.ac: Invoke AC_SYS_LARGEFILE.
9926 * configure, config.in: Rebuild.
9927
9928 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
9929
9930 * win32-low.c: Throughout, fix format strings and casts of
9931 printf-like functions to avoid type related warnings on all
9932 platforms.
9933 (get_child_debug_event): Print dwDebugEventCode as hex since
9934 that's how it's usually documented.
9935
9936 2013-02-28 Yao Qi <yao@codesourcery.com>
9937
9938 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
9939 pulongest.
9940
9941 2013-02-27 Jiong Wang <jiwang@tilera.com>
9942
9943 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
9944 (reg-tilegx32.c): New rule.
9945 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
9946 * linux-tile-low.c (tile_arch_setup): New function. Invoke
9947 different register info initializer according to elf class.
9948 (init_registers_tilgx32): New function. The tilegx32 register info
9949 initializer.
9950 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
9951 (tile_store_gregset): Likewise.
9952
9953 2013-02-27 Yao Qi <yao@codesourcery.com>
9954
9955 * server.c (process_point_options): Print debug message when
9956 debug_threads is true.
9957
9958 2013-02-26 Yao Qi <yao@codesourcery.com>
9959
9960 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
9961
9962 2013-02-19 Pedro Alves <palves@redhat.com>
9963 Kai Tietz <ktietz@redhat.com>
9964
9965 PR gdb/15161
9966
9967 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
9968 instead of strtoul to extract address from packet.
9969 (process_serial_event) <'z'>: Likewise.
9970
9971 2013-02-18 Yao Qi <yao@codesourcery.com>
9972
9973 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
9974
9975 2013-02-14 Pedro Alves <palves@redhat.com>
9976
9977 Plug memory leak.
9978
9979 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
9980 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
9981
9982 2013-02-14 Pedro Alves <palves@redhat.com>
9983
9984 * tracepoint.c (cmd_qtdpsrc): Use savestring.
9985
9986 2013-02-14 Pedro Alves <palves@redhat.com>
9987
9988 * tracepoint.c (save_string): Delete.
9989 (add_tracepoint_action): Use savestring instead of save_string.
9990
9991 2013-02-12 Pedro Alves <palves@redhat.com>
9992
9993 * linux-xtensa-low.c: Ditto.
9994 * xtensa-xtregs.c: Ditto.
9995
9996 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
9997
9998 * thread-db.c (thread_db_get_tls_address): NULL pointer check
9999 thread_db.
10000
10001 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
10002
10003 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
10004 aarch64_num_wp_regs and aarch64_num_bp_regs to
10005 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
10006
10007 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
10008
10009 * linux-aarch64-low.c (ps_get_thread_area): Replace
10010 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
10011
10012 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
10013 Marcus Shawcroft <marcus.shawcroft@arm.com>
10014 Nigel Stephens <nigel.stephens@arm.com>
10015 Yufeng Zhang <yufeng.zhang@arm.com>
10016
10017 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
10018 (aarch64.c, aarch64-without-fpu.c): New targets.
10019 * configure.srv (aarch64*-*-linux*): New.
10020 * linux-aarch64-low.c: New file.
10021
10022 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
10023
10024 * linux-low.c (handle_extended_wait, linux_create_inferior)
10025 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
10026 (dequeue_one_deferred_signal, linux_resume_one_thread)
10027 (fetch_register, linux_write_memory, linux_enable_event_reporting)
10028 (linux_tracefork_grandchild, linux_test_for_tracefork)
10029 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
10030 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
10031 where the argument is 0.
10032
10033 2013-01-25 Yao Qi <yao@codesourcery.com>
10034
10035 * event-loop.c: Include "queue.h".
10036 (gdb_event_p): New typedef.
10037 (struct gdb_event) <next_event>: Remove.
10038 (event_queue): Change to QUEUE(gdb_event_p).
10039 (async_queue_event): Remove.
10040 (gdb_event_xfree): New.
10041 (initialize_event_loop): New.
10042 (process_event): Use API from QUEUE.
10043 (wait_for_event): Likewise.
10044 * server.c (main): Call initialize_event_loop.
10045 * server.h (initialize_event_loop): Declare.
10046
10047 2013-01-18 Yao Qi <yao@codesourcery.com>
10048
10049 * ax.h (struct eval_agent_expr_context): New.
10050 (gdb_eval_agent_expr): Update declaration.
10051 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
10052 TFRAME. Add new argument CTX.
10053 * server.h (struct eval_agent_expr_context): Declare.
10054 (agent_mem_read, agent_tsv_read): Update declaration.
10055 (agent_mem_read_string): Likewise.
10056 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
10057 (add_traceframe_block): Add new argument TPOINT.
10058 Increase TPOINT->traceframe_usage.
10059 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
10060 eval_tracepoint_agent_expr.
10061 (condition_true_at_tracepoint): Likewise.
10062 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
10063 (agent_mem_read_string, agent_tsv_read): Likewise.
10064
10065 2013-01-16 Yao Qi <yao@codesourcery.com>
10066
10067 * linux-low.c (linux_resume_one_lwp): Don't check
10068 'lwp->bp_reinsert != 0'.
10069
10070 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10071 Pedro Alves <palves@redhat.com>
10072
10073 * lynx-low.c (ptrace_request_to_str): Define a temporary
10074 macro and use it to simplify this function's implementation.
10075
10076 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10077
10078 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
10079 sets errno.
10080
10081 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10082
10083 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
10084
10085 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10086
10087 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
10088
10089 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10090
10091 * lynx-low.c (lynx_resume): Use the resume_info parameter
10092 to determine the ptid for the lynx_ptrace call, unless
10093 it is equal to minus_one_ptid, in which case we use the
10094 ptid of the current_inferior.
10095 (lynx_wait_1): After having received a thread create/exit
10096 event, resume the inferior's execution using the signaling
10097 thread's ptid, rather than the old ptid.
10098
10099 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10100
10101 * lynx-low.c (lynx_resume): Delete variable ret.
10102
10103 2013-01-01 Joel Brobecker <brobecker@adacore.com>
10104
10105 * gdbreplay.c (gdbreplay_version): Update copyright year.
10106 * server.c (gdbserver_version): Likewise.
10107
10108 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10109
10110 * lynx-low.c (lynx_wait_1): Add debug trace before adding
10111 new thread.
10112
10113 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10114
10115 * lynx-low.c (ptrace_request_to_str): Add handling for
10116 PTRACE_GETTRACESIG.
10117
10118 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10119
10120 * lynx-low.c (lynx_attach): Delete variable new_process.
10121
10122 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10123
10124 * lynx-low.c (lynx_create_inferior): Delete variable
10125 new_process.
10126
10127 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10128
10129 * lynx-low.c (ptrace_request_to_str): Do not handle
10130 PTRACE_GETTHREADLIST if this macro does not exist.
10131
10132 2012-12-15 Yao Qi <yao@codesourcery.com>
10133
10134 * Makefile.in (OBS): Add notif.o.
10135 * notif.c, notif.h: New.
10136 * server.c: Include "notif.h".
10137 (struct vstop_notif) <next>: Remove.
10138 <base>: New field.
10139 (queue_stop_reply): Update.
10140 (push_event, send_next_stop_reply): Remove.
10141 (discard_queued_stop_replies): Update.
10142 (notif_stop): New variable.
10143 (handle_v_stopped): Remove.
10144 (handle_v_requests): Don't call handle_v_stopped. Call
10145 handle_ack_notif instead.
10146 (queue_stop_reply_callback): Call notif_event_enque instead
10147 of queue_stop_reply.
10148 (handle_status): Don't call send_next_stop_reply, call
10149 notif_write_event instead.
10150 (kill_inferior_callback): Likewise.
10151 (detach_or_kill_inferior_callback): Likewise.
10152 (main): Call initialize_notif.
10153 (process_serial_event): Call QUEUE_is_empty.
10154 (handle_target_event): Call notif_push instead of push event.
10155 * server.h (push_event): Remove declaration.
10156
10157 2012-12-10 Tom Tromey <tromey@redhat.com>
10158
10159 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
10160 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
10161 macros.
10162 (.c.o): Rewrite.
10163 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
10164 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
10165 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
10166 (amd64-linux-ipa.o, ax.o): Rewrite.
10167 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
10168 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
10169 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
10170 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
10171 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
10172 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
10173 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
10174 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
10175 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
10176 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
10177 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
10178 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
10179 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
10180 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
10181 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
10182 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
10183 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
10184 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
10185 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
10186 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
10187 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
10188 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
10189 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
10190 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
10191 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
10192 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
10193 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
10194 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
10195 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
10196 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
10197 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
10198 (reg-tilegx.o): Remove.
10199 (all_object_files): New macro.
10200 Include .deps files.
10201 * aclocal.m4, configure: Rebuild.
10202 * acinclude.m4: Include depstand.m4, lead-dot.m4.
10203 * configure.ac: Invoke ZW_CREATE_DEPDIR,
10204 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
10205
10206 2012-12-05 Tom Tromey <tromey@redhat.com>
10207
10208 PR gdb/14917:
10209 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
10210
10211 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
10212
10213 * configure.ac: Check for linux/perf_event.h.
10214 * config.in: Regenerated.
10215 * configure: Regenerated.
10216
10217 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
10218
10219 * hostio.c (handle_readlink): Decrease buffer size
10220 parameter passed to readlink by one byte.
10221
10222 2012-11-26 Yao Qi <yao@codesourcery.com>
10223
10224 * configure.ac (build_warnings): Append '-Wempty-body'.
10225 * configure: Regenerated.
10226 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
10227 body.
10228
10229 2012-11-15 Pierre Muller <muller@sourceware.org>
10230
10231 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
10232 * config.in: Regenerate.
10233 * configure: Regenerate.
10234 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
10235 Use "gdb_wait.h" header instead of <sys/wait.h> header.
10236 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
10237 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
10238 header.
10239 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
10240 instead of <sys/wait.h> header.
10241 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
10242
10243 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
10244
10245 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
10246 (various make rules): Remove -DGDBSERVER
10247
10248 2012-11-09 Yao Qi <yao@codesourcery.com>
10249
10250 * spu-low.c (current_ptid): Move it to ..
10251 * gdbthread.h: ... here. New.
10252 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
10253 * server.c (myresume, process_serial_event): Likewise.
10254 * thread-db.c (thread_db_find_new_threads): Likewise.
10255 * tracepoint.c (run_inferior_command): Likewise.
10256
10257 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
10258
10259 * server.c (handle_search_memory_1): Include access length in
10260 warning message.
10261
10262 2012-09-05 Michael Brandt <michael.brandt@axis.com>
10263
10264 * linux-crisv32-low.c: Fix compile errors.
10265
10266 2012-09-04 Yao Qi <yao@codesourcery.com>
10267
10268 * tracepoint.c (cmd_qtsv): Adjust debug message.
10269 Don't check CUR_TPOINT.
10270
10271 2012-08-28 Yao Qi <yao@codesourcery.com>
10272
10273 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
10274 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
10275 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
10276 Remove declarations of xmalloc, xreallloc, xstrdup and
10277 freeargv.
10278 * Makefile.in (libiberty_h): New.
10279 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
10280 (linux-bfin-low.o): Append dependency 'libiberty.h'.
10281
10282 2012-08-23 Yao Qi <yao@codesourcery.com>
10283
10284 * server.h: Remove declaration of 'xsnprintf'.
10285
10286 2012-08-22 Keith Seitz <keiths@redhat.com>
10287
10288 * server.h: Include build-gnulib-gbserver/config.h.
10289 * gdbreplay.c: Likewise.
10290
10291 2012-08-08 Doug Evans <dje@google.com>
10292
10293 * Makefile.in (SFILES): Add gdb_vecs.c.
10294 (OBS): Add gdb_vecs.o.
10295 (gdb_vecs_h, host_defs_h): New variables.
10296 (thread-db.o): Add $(gdb_vecs_h) dependency.
10297 (gdb_vecs.o): New rule.
10298 * thread-db.c: #include "gdb_vecs.h".
10299 (thread_db_load_search): Use a vector to iterate over path elements.
10300 Handle text appearing after "$pdir".
10301
10302 * configure.ac: Add check for strstr.
10303 * config.in: Regenerate.
10304 * configure: Regenerate.
10305
10306 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
10307
10308 * hostio.c (handle_pread): If pread fails, fall back to attempting
10309 lseek/read.
10310 (handle_pwrite): Likewise for pwrite.
10311
10312 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
10313
10314 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
10315 between unsupported TYPE and unimplementable ADDR/LEN combination.
10316 (arm_insert_point): Act on new return value.
10317
10318 2012-07-31 Pedro Alves <palves@redhat.com>
10319
10320 * server.c (process_point_options): Only skip tokens if we find
10321 one that is unrecognized. Don't treat 'X' specially while
10322 skipping unrecognized tokens.
10323
10324 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
10325
10326 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
10327 to 4-byte-align HW breakpoint addresses for Thumb.
10328
10329 2012-07-27 Yao Qi <yao@codesourcery.com>
10330
10331 PR remote/14161.
10332
10333 * server.h: Declare gdb_agent_about_to_close.
10334 * target.c (kill_inferior): Include "agent.h".
10335 New. Send command 'kill'.
10336 * target.h (kill_inferior): Removed macro.
10337 * tracepoint.c (gdb_agent_about_to_close): New.
10338 (gdb_agent_helper_thread): Handle command 'close'.
10339 Wait endlessly until the inferior stops.
10340 Install gdb_agent_remove_socket to atexit hook.
10341 (agent_socket_name): New static variable.
10342 (gdb_agent_socket_init): Replace local variable 'name' with
10343 'agent_socket_name'.
10344 (gdb_agent_remove_socket): New.
10345
10346 2012-07-27 Yao Qi <yao@codesourcery.com>
10347
10348 * server.c (process_point_options): Stop at 'X' when parsing.
10349
10350 2012-07-19 Michael Eager <eager@eagercon.com>
10351
10352 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
10353 to hw_execute.
10354 * linux-x86-low.c (x86_insert_point, x86_remove_point):
10355 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
10356 hardware breakpoint.
10357
10358 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
10359
10360 * gdbserver/linux-low.c (initialize_low): Call
10361 linux_ptrace_init_warnings.
10362
10363 2012-07-02 Doug Evans <dje@google.com>
10364
10365 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
10366 pointer to int.
10367
10368 2012-07-02 Stan Shebs <stan@codesourcery.com>
10369
10370 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
10371 (ax.o): Add it to build rule.
10372 (ax-ipa.o): Ditto.
10373 (OBS): Add format.o.
10374 (IPA_OBS): Add format.o.
10375 * server.c (handle_query): Claim support for breakpoint commands.
10376 (process_point_options): Add command case.
10377 (process_serial_event): Leave running if there are printfs in
10378 effect.
10379 * mem-break.h (any_persistent_commands): Declare.
10380 (add_breakpoint_commands): Declare.
10381 (gdb_no_commands_at_breakpoint): Declare.
10382 (run_breakpoint_commands): Declare.
10383 * mem-break.c (struct point_command_list): New struct.
10384 (struct breakpoint): New field command_list.
10385 (any_persistent_commands): New function.
10386 (add_commands_to_breakpoint): New function.
10387 (add_breakpoint_commands): New function.
10388 (gdb_no_commands_at_breakpoint): New function.
10389 (run_breakpoint_commands): New function.
10390 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
10391 locally.
10392 * ax.c: Include format.h.
10393 (ax_printf): New function.
10394 (gdb_eval_agent_expr): Add printf opcode.
10395
10396 2012-06-13 Yao Qi <yao@codesourcery.com>
10397
10398 * server.c (start_inferior): Remove duplicated writes to fields
10399 'last_resume_kind' and 'last_status' of 'current_inferior'.
10400
10401 2012-06-12 Yao Qi <yao@codesourcery.com>
10402 Pedro Alves <palves@redhat.com>
10403
10404 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
10405 comment.
10406 * server.c (handle_v_cont): Extend comment.
10407
10408 2012-06-11 Yao Qi <yao@codesourcery.com>
10409
10410 * linux-low.c (linux_attach): Add 'static'.
10411
10412 2012-06-06 Yao Qi <yao@codesourcery.com>
10413
10414 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
10415
10416 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
10417
10418 Fix gcc -flto compilation warning.
10419 * server.c (main): Make variable multi_mode and attach volatile.
10420
10421 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10422
10423 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
10424 if the platform doesn't know about it.
10425
10426 2012-05-30 Jeff Kenton <jkenton@tilera.com>
10427
10428 * Makefile.in (SFILES): Add linux-tile-low.c.
10429 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
10430 * configure.srv: Handle tilegx-*-linux*.
10431 * linux-tile-low.c: New file.
10432
10433 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
10434
10435 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
10436
10437 2012-05-24 Pedro Alves <palves@redhat.com>
10438
10439 PR gdb/7205
10440
10441 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
10442
10443 2012-05-24 Pedro Alves <palves@redhat.com>
10444
10445 PR gdb/7205
10446
10447 Replace target_signal with gdb_signal throughout.
10448
10449 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
10450
10451 * linux-low.c (linux_store_registers): Avoid the copying sequence
10452 when no data has been retrieved by ptrace.
10453
10454 2012-05-22 Will Deacon <will.deacon@arm.com>
10455
10456 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
10457 Include asm/ptrace.h.
10458 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
10459 already defined.
10460
10461 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
10462
10463 * linux-low.c (linux_store_registers): Don't re-retrieve data
10464 with ptrace that has already been obtained from /proc. Always
10465 copy any data retrieved with ptrace to the buffer supplied.
10466
10467 2012-05-11 Yao Qi <yao@codesourcery.com>
10468 Pedro Alves <palves@redhat.com>
10469
10470 * linux-low.c (enum stopping_threads_kind): New.
10471 (stopping_threads): Change type to `enum stopping_threads_kind'.
10472 (handle_extended_wait): If stopping and suspending threads, leave
10473 the new_lwp suspended too.
10474 (linux_wait_for_event): Adjust.
10475 (stop_all_lwps): Set `stopping_threads' to
10476 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
10477 whether we're suspending threads or just stopping them. Assert no
10478 recursion happens.
10479
10480 2012-04-29 Yao Qi <yao@codesourcery.com>
10481
10482 * server.h: Move some code to ...
10483 * gdbthread.h: ... here. New.
10484 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
10485 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
10486 (nto-low.o, win32-low.o): Likewise.
10487 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
10488 * regcache.c, remote-utils.c, server.c: Likewise.
10489 * target.c, tracepoint.c, win32-low.c: Likewise.
10490
10491 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10492
10493 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
10494 (PTRACE_ARG4_TYPE): Likewise.
10495 (PTRACE_XFER_TYPE): Likewise.
10496 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
10497 ptrace to PTRACE_ARG3_TYPE.
10498 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
10499 (PTRACE_ARG4_TYPE): Likewise.
10500 (PTRACE_XFER_TYPE): Likewise.
10501 (linux_detach_one_lwp): Cast fourth argument of
10502 ptrace to long then PTRACE_ARG4_TYPE.
10503 (regsets_fetch_inferior_registers): Cast third argument of
10504 ptrace to long then PTRACE_ARG3_TYPE.
10505 (regsets_store_inferior_registers): Likewise.
10506
10507 2012-04-20 Pedro Alves <palves@redhat.com>
10508
10509 * configure: Regenerate.
10510
10511 2012-04-19 Pedro Alves <palves@redhat.com>
10512
10513 * Makefile.in (GNULIB_BUILDDIR): New.
10514 (LIBGNU, INCGNU, GNULIB_H): Adjust.
10515 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
10516 (all, install-only, uninstall, clean-info, all-lib, clean): No
10517 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
10518 (maintainer-clean realclean distclean): Use subdir_do.
10519 (subdir_do): New.
10520 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
10521 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
10522 * acinclude.m4: Include acx_configure_dir.m4.
10523 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
10524 calls. Call AC_PROG_RANLIB. Configure gnulib using
10525 ACX_CONFIGURE_DIR.
10526 (GNULIB): New.
10527 (GNULIB_STDINT_H): Adjust.
10528 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
10529 * gdbreplay.c: Include build-gnulib/config.h.
10530 * server.h: Likewise.
10531 * aclocal.m4: Regenerate.
10532 * config.in: Regenerate.
10533 * configure: Regenerate.
10534
10535 2012-04-19 Pedro Alves <palves@redhat.com>
10536
10537 * Makefile.in (LIBGNU, INCGNU): Adjust.
10538 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
10539 (all, install-only, uninstall, clean-info, all-lib, clean)
10540 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
10541 * configure.ac: Adjust AC_OUTPUT output.
10542 * aclocal.m4: Regenerate.
10543 * configure: Regenerate.
10544
10545 2012-04-19 Pedro Alves <palves@redhat.com>
10546
10547 * Makefile.in (generated_files): New.
10548 (server_h): Remove the explicit dependency on config.h, and depend
10549 on $generated_files.
10550
10551 2012-04-19 Pedro Alves <palves@redhat.com>
10552
10553 * Makefile.in (INCGNU): Add -Ignulib.
10554
10555 2012-04-19 Pedro Alves <palves@redhat.com>
10556
10557 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
10558 (INCGNU): ... this, and spell out -I here.
10559 (GNULIB_LIB): Rename to ...
10560 (LIBGNU): ... this.
10561 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
10562
10563 2012-04-19 Pedro Alves <palves@redhat.com>
10564
10565 * config.in: Regenerate.
10566
10567 2012-04-19 Pedro Alves <palves@redhat.com>
10568
10569 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
10570 * server.h (memmem): Remove declaration.
10571 * config.in: Regenerate.
10572 * configure: Regenerate.
10573
10574 2012-04-19 Yao Qi <yao@codesourcery.com>
10575
10576 * Makefile.in (SFILES): Add common/vec.c.
10577 (OBS): Add vec.o.
10578 (vec.o): New rule.
10579
10580 2012-04-19 Yao Qi <yao@codesourcery.com>
10581
10582 * remote-utils.c (prepare_resume_reply): Replace with macro
10583 target_core_of_thread.
10584 * server.c (handle_qxfer_threads_proper): Likewise.
10585 * target.h (traget_core_of_thread): New macro.
10586
10587 2012-04-18 Pedro Alves <palves@redhat.com>
10588
10589 * aclocal.m4: Regenerate.
10590 * configure: Regenerate.
10591
10592 2012-04-16 Yao Qi <yao@codesourcery.com>
10593
10594 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
10595 duplicated on address.
10596
10597 2012-04-16 Yao Qi <yao@codesourcery.com>
10598
10599 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
10600 (struct tracepoint_action_ops) <send>: New field.
10601 (m_tracepoint_action_send, r_tracepoint_action_send): New.
10602 (agent_expr_send, x_tracepoint_action_send): New.
10603 (l_tracepoint_action_send): New.
10604 (cmd_qtdp): Download and install tracepoint
10605 according to `use_agent'.
10606 (run_inferior_command): Add one more parameter `len'.
10607 Update callers.
10608 (tracepoint_send_agent): New.
10609 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
10610
10611 2012-04-16 Yao Qi <yao@codesourcery.com>
10612
10613 * tracepoint.c (download_tracepoints): Moved to ...
10614 (cmd_qtstart): ... here.
10615
10616 2012-04-14 Yao Qi <yao@codesourcery.com>
10617
10618 * tracepoint.c: Include inttypes.h.
10619 (struct collect_memory_action): Use sized types.
10620 (struct tracepoint): Likewise.
10621 (cmd_qtdp, stop_tracing): Update print specifiers.
10622 (cmd_qtp, response_tracepoint): Likewise.
10623 (collect_data_at_tracepoint): Likewise.
10624 (collect_data_at_step): Likewise.
10625
10626 2012-04-14 Yao Qi <yao@codesourcery.com>
10627
10628 Import gnulib module inttypes.
10629 * aclocal.m4, config.in, configure: Regenerated.
10630
10631 2012-04-14 Yao Qi <yao@codesourcery.com>
10632
10633 * Makefile.in (maintainer-clean, realclean, distclean): Remove
10634 Makefile and config.status at last.
10635
10636 2012-04-13 Yao Qi <yao@codesourcery.com>
10637
10638 * tracepoint.c: Include stdint.h unconditionally.
10639
10640 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10641
10642 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
10643 on BFD_HAVE_SYS_PROCFS_TYPE.
10644 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
10645 * configure: Regenerate.
10646 * config.in: Likewise.
10647
10648 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
10649
10650 * Makefile.in (clean): Also remove x32.c x32-linux.c
10651 x32-avx.c x32-avx-linux.c.
10652 (x32.o): New target.
10653 (x32.c): Likewise.
10654 (x32-linux.o): Likewise.
10655 (x32-linux.c): Likewise.
10656 (x32-avx.o): Likewise.
10657 (x32-avx.c): Likewise.
10658 (x32-avx-linux.o): Likewise.
10659 (x32-avx-linux.c): Likewise.
10660
10661 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
10662 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
10663 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
10664 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
10665 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
10666 i386/x32-avx-linux.xml.
10667
10668 * linux-x86-low.c (init_registers_x32_linux): New prototype.
10669 (init_registers_x32_avx_linux): Likwise.
10670 (x86_linux_update_xmltarget): Call init_registers_x32_linux
10671 or init_registers_x32_avx_linux if linux_is_elf64 is false.
10672
10673 2012-04-13 Pedro Alves <palves@redhat.com>
10674
10675 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
10676 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
10677 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
10678 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
10679 the sub-make.
10680
10681 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
10682
10683 * linux-x86-low.c (compat_x32_clock_t): New.
10684 (compat_x32_siginfo_t): Likewise.
10685 (compat_x32_siginfo_from_siginfo): Likewise.
10686 (siginfo_from_compat_x32_siginfo): Likewise.
10687 (linux_is_elf64): Likewise.
10688 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
10689 and siginfo_from_compat_x32_siginfo for x32.
10690 (x86_arch_setup): Set linux_is_elf64.
10691
10692 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
10693
10694 PR gdb/13969
10695 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
10696 e_machine field.
10697 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
10698 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
10699 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
10700 compatible with process.
10701
10702 2012-04-12 Yao Qi <yao@codesourcery.com>
10703
10704 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
10705 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
10706 (install-only, install-info, clean): Handle sub dir gnulib.
10707 (all-lib, am--refresh): New targets.
10708 (memmem.o): Remove target.
10709 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
10710 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
10711 (AC_REPLACE_FUNCS): Remove memmem.
10712 Invoke gl_INIT and AM_INIT_AUTOMAKE.
10713 (AC_OUTPUT): Generate Makefile in gnulib/.
10714 * aclocal.m4, config.in, configure: Regenerated.
10715
10716 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
10717
10718 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
10719
10720 2012-04-05 Pedro Alves <palves@redhat.com>
10721
10722 -Werror=strict-aliasing
10723
10724 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
10725 pointer.
10726
10727 2012-04-04 Pedro Alves <palves@redhat.com>
10728
10729 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
10730 (sparc_store_gregset_from_stack, sparc_store_gregset)
10731 (sparc_breakpoint_at): Fix formatting.
10732
10733 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10734
10735 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
10736 are available.
10737 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
10738 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
10739 * config.in: Regenerate.
10740 * configure: Likewise.
10741
10742 2012-03-29 Pedro Alves <palves@redhat.com>
10743
10744 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
10745 Correct ptrace arguments.
10746
10747 2012-03-28 Pedro Alves <palves@redhat.com>
10748
10749 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
10750 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
10751 (IA64_FR1_REGNUM): New defines.
10752 (ia64_fetch_register): New.
10753 (the_low_target): Install it.
10754 * linux-low.h (struct linux_target_ops) <fetch_register>: New
10755 field.
10756 * linux-low.c (linux_fetch_registers): Try the
10757 the_low_target.fetch_register hook first.
10758
10759 * linux-arm-low.c (the_low_target): Adjust.
10760 * linux-bfin-low.c (the_low_target): Adjust.
10761 * linux-cris-low.c (the_low_target): Adjust.
10762 * linux-crisv32-low.c (the_low_target): Adjust.
10763 * linux-m32r-low.c (the_low_target): Adjust.
10764 * linux-m68k-low.c (the_low_target): Adjust.
10765 * linux-mips-low.c (the_low_target): Adjust.
10766 * linux-ppc-low.c (the_low_target): Adjust.
10767 * linux-s390-low.c (the_low_target): Adjust.
10768 * linux-sh-low.c (the_low_target): Adjust.
10769 * linux-sparc-low.c (the_low_target): Adjust.
10770 * linux-tic6x-low.c (the_low_target): Adjust.
10771 * linux-x86-low.c (the_low_target): Adjust.
10772 * linux-xtensa-low.c (the_low_target): Adjust.
10773
10774 2012-03-26 Pedro Alves <palves@redhat.com>
10775
10776 * server.c (handle_qxfer_libraries): Don't bail early if
10777 the_target->qxfer_libraries_svr4 is not NULL.
10778
10779 2012-03-26 Pedro Alves <palves@redhat.com>
10780
10781 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
10782
10783 2012-03-23 Pedro Alves <palves@redhat.com>
10784
10785 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
10786 "library-list-svr4" element's start tag when the the DSO list is
10787 empty.
10788
10789 2012-03-23 Pedro Alves <palves@redhat.com>
10790
10791 * linux-low.c (read_one_ptr): Read the inferior's pointer through
10792 a variable whose type size is the same as the inferior's pointer
10793 size.
10794
10795 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
10796
10797 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
10798 struct siginfo.
10799 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
10800 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
10801 * linux-low.h: Include <signal.h>.
10802 (struct siginfo): Remove forward declaration.
10803 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
10804 struct siginfo.
10805
10806 2012-03-21 Mike Frysinger <vapier@gentoo.org>
10807
10808 * .gitignore: Ignore more files.
10809
10810 2012-03-19 Pedro Alves <palves@redhat.com>
10811 Jan Kratochvil <jan.kratochvil@redhat.com>
10812
10813 * server.c (cont_thread, general_thread): Add describing comments.
10814 (start_inferior): Clear `cont_thread'.
10815 (handle_v_cont): Don't set `cont_thread' if resuming all threads
10816 of a process.
10817
10818 2012-03-15 Yao Qi <yao@codesourcery.com>
10819
10820 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
10821 handling to ...
10822 (cmd_qtdp): ... here.
10823
10824 2012-03-15 Yao Qi <yao@codesourcery.com>
10825
10826 * tracepoint.c (struct tracepoint_action_ops): New.
10827 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
10828 (m_tracepoint_action_download): New.
10829 (r_tracepoint_action_download): New.
10830 (x_tracepoint_action_download): New.
10831 (l_tracepoint_action_download): New.
10832 (add_tracepoint_action): Install `action->ops' according type.
10833 (download_tracepoint_1): Move code `download' function pointer
10834 of various tracepoint_action_ops.
10835
10836 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
10837
10838 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
10839 linux_ptrace_attach_warnings.
10840
10841 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
10842
10843 * Makefile.in (linux-ptrace.o): New.
10844 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
10845 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
10846 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
10847 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
10848 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
10849 of these targets.
10850 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
10851
10852 2012-03-08 Yao Qi <yao@codesourcery.com>
10853 Pedro Alves <palves@redhat.com>
10854
10855 Fix PR server/13392.
10856 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
10857 offset of JMP insn.
10858 * tracepoint.c (remove_tracepoint): New.
10859 (cmd_qtdp): Call remove_tracepoint when failed to install.
10860
10861 2012-03-07 Pedro Alves <palves@redhat.com>
10862
10863 * linux-low.c (get_detach_signal): New.
10864 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
10865 Pass on pending signals to PTRACE_DETACH. Check the result of the
10866 ptrace call.
10867 * server.c (program_signals, program_signals_p): New.
10868 (handle_general_set): Handle QProgramSignals.
10869 * server.h (program_signals, program_signals_p): Declare.
10870
10871 2012-03-05 Pedro Alves <palves@redhat.com>
10872 Jan Kratochvil <jan.kratochvil@redhat.com>
10873
10874 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
10875 New comment why.
10876
10877 2012-03-03 Yao Qi <yao@codesourcery.com>
10878
10879 * tracepoint.c (tracepoint_look_up_symbols): Update call to
10880 agent_look_up_symbols.
10881
10882 2012-03-03 Yao Qi <yao@codesourcery.com>
10883
10884 * Makefile.in (linux-low.o): Keep dependence on agent.h.
10885 (linux-x86-low.o): Likewise.
10886 * server.h: Remove in_process_agent_loaded.
10887 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
10888 common/agent.c.
10889 Update callers.
10890
10891 2012-03-03 Yao Qi <yao@codesourcery.com>
10892
10893 * tracepoint.c (gdb_agent_capability): New global.
10894 (in_process_agent_loaded_ust): Renamed to
10895 `in_process_agent_supports_ust'.
10896 Update callers.
10897 (in_process_agent_supports_ust): Call agent_capability_check.
10898 (clear_installed_tracepoints): Assert that agent supports
10899 agent.
10900
10901 2012-03-03 Yao Qi <yao@codesourcery.com>
10902
10903 * linux-low.c (linux_supports_agent): New.
10904 (linux_target_ops): Initialize field `supports_agent' with
10905 linux_supports_agent.
10906 * target.h (struct target_ops) <supports_agent>: New.
10907 (target_supports_agent): New macro.
10908 * server.c (handle_general_set): Handle packet 'QAgent'.
10909 (handle_query): Send `QAgent+'.
10910 * Makefile.in (server.o): Depends on agent.h.
10911
10912 2012-03-03 Yao Qi <yao@codesourcery.com>
10913
10914 * Makefile.in (OBS): Add agent.o.
10915 Add new rule for agent.o.
10916 Track dependence of tracepoint.c on agent.h.
10917 * tracepoint.c (run_inferior_command_1):
10918 (run_inferior_command): Call agent_run_command.
10919 (gdb_ust_connect_sync_socket): Deleted. Move it to
10920 common/agent.c.
10921 (resume_thread, stop_thread): Likewise.
10922 (gdb_ust_socket_init): Renamed to ...
10923 (gdb_agent_socket_init): ... New.
10924 (gdb_ust_thread): Renamed to ...
10925 (gdb_agent_helper_thread): ... New.
10926 (gdb_ust_init): Move some code to ...
10927 (gdb_agent_init): ... here. New.
10928 [HAVE_UST]: Call gdb_ust_init.
10929 (initialize_tracepoint_ftlib): Call gdb_agent_init.
10930 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
10931 * config.in, configure: Regenerated.
10932
10933 2012-03-02 Pedro Alves <palves@redhat.com>
10934
10935 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
10936 * linux-low.c (struct simple_pid_list): New.
10937 (stopped_pids): New a struct simple_pid_list pointer.
10938 (add_to_pid_list, pull_pid_from_list): New.
10939 (handle_extended_wait): Don't assume the first signal new children
10940 report is SIGSTOP. Adjust call to pull_pid_from_list.
10941 (linux_wait_for_lwp): Adjust.
10942
10943 2012-03-02 Yao Qi <yao@codesourcery.com>
10944
10945 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
10946 debug log.
10947
10948 2012-03-02 Yao Qi <yao@codesourcery.com>
10949
10950 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
10951 `stop_pc' and `tpoint'. Update caller.
10952
10953 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
10954
10955 * linux-low.h (linux_target_ops): Add regset_bitmap member.
10956 * linux-low.c (use_linux_regsets): New macro.
10957 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
10958 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
10959 (linux_register_in_regsets): New function.
10960 (usr_fetch_inferior_registers): Skip registers covered by
10961 regsets.
10962 (usr_store_inferior_registers): Likewise.
10963 (usr_fetch_inferior_registers): New macro.
10964 (usr_store_inferior_registers): Likewise.
10965 (linux_fetch_registers): Handle mixed regset/non-regset targets.
10966 (linux_store_registers): Likewise.
10967 * linux-mips-low.c (init_registers_mips_dsp_linux): New
10968 prototype.
10969 (init_registers_mips64_dsp_linux): Likewise.
10970 (init_registers_mips_linux): New macro.
10971 (init_registers_mips_dsp_linux): Likewise.
10972 (mips_dsp_num_regs): Likewise.
10973 (DSP_BASE, DSP_CONTROL): New fallback macros.
10974 (mips_base_regs): New macro.
10975 (mips_regmap): Use it. Fix the size.
10976 (mips_dsp_regmap): New variable.
10977 (mips_dsp_regset_bitmap): Likewise.
10978 (mips_arch_setup): New function.
10979 (mips_cannot_fetch_register): Use the_low_target.regmap rather
10980 than mips_regmap.
10981 (mips_cannot_store_register): Likewise.
10982 (the_low_target): Update .arch_setup, .num_regs and .regmap
10983 initializers. Add .regset_bitmap initializer.
10984 * linux-arm-low.c (the_low_target): Add .regset_bitmap
10985 initializer.
10986 * linux-bfin-low.c (the_low_target): Likewise.
10987 * linux-cris-low.c (the_low_target): Likewise.
10988 * linux-crisv32-low.c (the_low_target): Likewise.
10989 * linux-ia64-low.c (the_low_target): Likewise.
10990 * linux-m32r-low.c (the_low_target): Likewise.
10991 * linux-m68k-low.c (the_low_target): Likewise.
10992 * linux-ppc-low.c (the_low_target): Likewise.
10993 * linux-s390-low.c (the_low_target): Likewise.
10994 * linux-sh-low.c (the_low_target): Likewise.
10995 * linux-sparc-low.c (the_low_target): Likewise.
10996 * linux-tic6x-low.c (the_low_target): Likewise.
10997 * linux-x86-low.c (the_low_target): Likewise.
10998 * linux-xtensa-low.c (the_low_target): Likewise.
10999 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
11000 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
11001 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
11002 srv_xmlfiles.
11003 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
11004 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
11005
11006 2012-02-29 Yao Qi <yao@codesourcery.com>
11007 Pedro Alves <palves@redhat.com>
11008
11009 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
11010 `step_over_finished' is true.
11011
11012 2012-02-27 Pedro Alves <palves@redhat.com>
11013
11014 * linux-low.c (pid_is_stopped): Delete, moved to common/.
11015 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
11016
11017 2012-02-27 Pedro Alves <palves@redhat.com>
11018
11019 PR server/9684
11020 * linux-low.c (pid_is_stopped): New.
11021 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
11022
11023 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
11024
11025 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
11026 of conditions.
11027
11028 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
11029
11030 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
11031
11032 2012-02-24 Luis Machado <lgustavo@codesourcery>
11033
11034 * server.c (handle_query): Advertise support for target-side
11035 breakpoint condition evaluation.
11036 (process_point_options): New function.
11037 (process_serial_event): When inserting a breakpoint, check for
11038 a target-side condition that should be evaluated.
11039
11040 * mem-break.c: Include regcache.h and ax.h.
11041 (point_cond_list_t): New data structure.
11042 (breakpoint) <cond_list>: New field.
11043 (find_gdb_breakpoint_at): Make non-static.
11044 (delete_gdb_breakpoint_at): Clear any target-side
11045 conditions.
11046 (clear_gdb_breakpoint_conditions): New function.
11047 (add_condition_to_breakpoint): Likewise.
11048 (add_breakpoint_condition): Likewise.
11049 (gdb_condition_true_at_breakpoint): Likewise.
11050 (gdb_breakpoint_here): Return result directly instead
11051 of going through a local variable.
11052
11053 * mem-break.h (find_gdb_breakpoint_at): New prototype.
11054 (clear_gdb_breakpoint_conditions): Likewise.
11055 (add_breakpoint_condition): Likewise.
11056 (gdb_condition_true_at_breakpoint): Likewise.
11057
11058 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
11059 (need_step_over_p): Take target-side breakpoint condition into
11060 consideration.
11061
11062 2012-02-24 Luis Machado <lgustavo@codesourcery>
11063
11064 * server.h: Include tracepoint.h.
11065 (agent_mem_read, agent_get_trace_state_variable_value,
11066 agent_set_trace_state_variable_value,
11067 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
11068 get_set_tsv_func_addr): New prototypes.
11069
11070 * ax.h: New include file.
11071 * ax.c: New source file.
11072
11073 * tracepoint.c: Include ax.h.
11074 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
11075 agent_expr, eval_result_type): Move to ax.h.
11076 (parse_agent_expr): Rename to ...
11077 (gdb_parse_agent_expr): ... this, make it non-static and move
11078 to ax.h.
11079 (unparse_agent_expr) Rename to ...
11080 (gdb_unparse_agent_expr): ... this, make it non-static and move
11081 to ax.h.
11082 (eval_agent_expr): Rename to ...
11083 (eval_tracepoint_agent_expr): ... this.
11084 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
11085 forward declarations.
11086 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
11087 (agent_get_trace_state_variable_value): New function.
11088 (agent_set_trace_state_variable_value): New function.
11089 (cmd_qtdp): Call gdb_parse_agent_expr (...).
11090 (response_tracepoint): Call gdb_unparse_agent_expr (...).
11091 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
11092 (condition_true_at_tracepoint): Likewise.
11093 (parse_agent_expr): Rename to ...
11094 (gdb_parse_agent_expr): ... this and move to ax.c.
11095 (unparse_agent_expr): Rename to ...
11096 (gdb_unparse_agent_expr): ... this and move to ax.c.
11097 (gdb_agent_op_name): Move to ax.c.
11098 (eval_agent_expr): Rename to ...
11099 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
11100 and move to ax.c.
11101 (eval_tracepoint_agent_expr): New function.
11102 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
11103 non-static.
11104 (current_insn_ptr, emit_error, struct bytecode_address): Move to
11105 ax.c.
11106 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
11107 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
11108 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
11109 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
11110 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
11111 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
11112 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
11113 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
11114 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
11115 (compile_bytecodes): Remove forward declaration.
11116 (is_goto_target): Move to ax.c.
11117 (compile_bytecodes): Move to ax.c and call
11118 agent_get_trace_state_variable_value (...) and
11119 agent_set_trace_state_variable_value (...).
11120
11121 * Makefile.in: Update ax.c and IPA dependencies.
11122
11123 2012-02-24 Pedro Alves <palves@redhat.com>
11124
11125 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
11126 (cmd_bigqtbuffer_circular): ... this. Only handle
11127 'QTBuffer:circular:'.
11128 (handle_tracepoint_general_set): Adjust.
11129
11130 2012-02-16 Yao Qi <yao@codesourcery.com>
11131
11132 * inferiors.c: Move code to ...
11133 * dll.c: .... here. New.
11134 * server.h: Declare clear_dlls.
11135 * Makefile.in (SFILES): Add dll.c.
11136 (OBS): Add dll.o
11137 (dll.o): New rule.
11138
11139 2012-02-11 Yao Qi <yao@codesourcery.com>
11140
11141 * server.c: (handle_monitor_command): Add a new parameter
11142 `own_buf'.
11143 (handle_query): Update caller.
11144
11145 2012-02-09 Joel Brobecker <brobecker@adacore.com>
11146
11147 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
11148 * configure, config.in: Regenerate.
11149 * hostio.c: Provide an alternate implementation if HAVE_READLINK
11150 is not defined.
11151
11152 2012-02-02 Pedro Alves <palves@redhat.com>
11153
11154 Try SIGKILL first, then PTRACE_KILL.
11155 * linux-low.c (linux_kill_one_lwp): New.
11156 (linux_kill_one_lwp): Rename to ...
11157 (kill_one_lwp_callback): ... this. Use the new
11158 linux_kill_one_lwp.
11159
11160 2012-02-02 Pedro Alves <palves@redhat.com>
11161
11162 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
11163 inferior.
11164
11165 2012-01-27 Pedro Alves <palves@redhat.com>
11166
11167 * linux-low.c (linux_child_pid_to_exec_file): Delete.
11168 (elf_64_file_p): Make static.
11169 (linux_pid_exe_is_elf_64_file): New.
11170 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
11171 Delete declarations.
11172 (linux_pid_exe_is_elf_64_file): Declare.
11173 * linux-x86-low.c (x86_arch_setup): Use
11174 linux_pid_exe_is_elf_64_file.
11175
11176 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
11177
11178 * linux-low.c (linux_wait_for_event_1): Rename to ...
11179 (linux_wait_for_event): ... here and merge it with former
11180 linux_wait_for_event - new variable wait_ptid, use it.
11181 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
11182
11183 2012-01-23 Pedro Alves <palves@redhat.com>
11184
11185 * server.c (main): Avoid yet another case of infinite loop while
11186 detaching/killing after a longjmp.
11187
11188 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
11189
11190 Code cleanup.
11191 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
11192
11193 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
11194
11195 * hostio.c (handle_readlink): New function.
11196 (handle_vFile): Call it to handle "vFile:readlink" packets.
11197
11198 2012-01-20 Pedro Alves <palves@redhat.com>
11199 Ulrich Weigand <ulrich.weigand@linaro.org>
11200
11201 * server.c (handle_v_requests): Only support vAttach and vRun to
11202 start multiple processes when in extended protocol mode.
11203
11204 2012-01-17 Pedro Alves <palves@redhat.com>
11205
11206 * tracepoint.c (initialize_tracepoint): Use mmap instead of
11207 memalign plus mprotect to allocate the scratch buffer.
11208
11209 2012-01-13 Pedro Alves <palves@redhat.com>
11210
11211 * server.c (attach_inferior): Clear `cont_thread'.
11212
11213 2012-01-13 Pedro Alves <palves@redhat.com>
11214
11215 * server.c (main): Avoid infinite loop while detaching/killing
11216 after a longjmp.
11217
11218 2012-01-09 Doug Evans <dje@google.com>
11219
11220 * server.c (start_inferior): Set last_ptid in --wrapper case.
11221
11222 2012-01-06 Yao Qi <yao@codesourcery.com>
11223
11224 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
11225 defined.
11226 [IN_PROCESS_AGENT] (debug_agent): New global variable.
11227
11228 2012-01-04 Yao Qi <yao@codesourcery.com>
11229
11230 * tracepoint.c (cmd_qtdp): Print debug message
11231 for static tracepoint.
11232
11233 2012-01-04 Yao Qi <yao@codesourcery.com>
11234
11235 * tracepoint.c (trace_vdebug): Differentiate debug message
11236 between gdbserver and IPA.
11237
11238 2012-01-03 Yao Qi <yao@codesourcery.com>
11239
11240 * tracepoint.c (tracepoint_was_hit): Don't collect for
11241 static tracepoint.
11242
11243 2012-01-02 Joel Brobecker <brobecker@adacore.com>
11244
11245 * terminal.h: Reformat copyright header.
11246
11247 2012-01-02 Joel Brobecker <brobecker@adacore.com>
11248
11249 * server.c (gdbserver_version): Update copyright year.
11250 * gdbreplay.c (gdbreplay_version): Likewise.
11251
11252 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
11253
11254 * linux-low.c (linux_create_inferior): Put empty if clause for write.
11255
11256 Revert:
11257 2011-12-18 Hui Zhu <teawater@gmail.com>
11258 * linux-low.c (linux_create_inferior): Save return value to ret.
11259
11260 2011-12-18 Hui Zhu <teawater@gmail.com>
11261
11262 * linux-low.c (linux_create_inferior): Save return value to ret.
11263
11264 2011-12-16 Doug Evans <dje@google.com>
11265
11266 * linux-low.c (linux_create_inferior): If stdio connection,
11267 redirect stdin from /dev/null, stdout to stderr.
11268 * remote-utils.c (remote_is_stdio): New static global.
11269 (remote_connection_is_stdio): New function.
11270 (remote_prepare): Handle stdio connection.
11271 (remote_open): Ditto.
11272 (remote_close): Don't close stdin for stdio connections.
11273 (read_prim,write_prim): New functions. Replace all calls to
11274 read/write to these.
11275 * server.c (main): Watch for "-" argument. Move call to
11276 remote_prepare before start_inferior.
11277 * server.h (STDIO_CONNECTION_NAME): New macro.
11278 (remote_connection_is_stdio): Declare.
11279
11280 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
11281 in debugging output.
11282
11283 2011-12-15 Yao Qi <yao@codesourcery.com>
11284
11285 * tracepoint.c: Include sys/syscall.h.
11286 (gdb_ust_thread): Remove preprocessor conditional.
11287
11288 2011-12-14 Pedro Alves <pedro@codesourcery.com>
11289
11290 * linux-low.c (linux_detach_one_lwp): Call
11291 the_low_target.prepare_to_resume before detaching.
11292
11293 2011-12-14 Yao Qi <yao@codesourcery.com>
11294
11295 * tracepoint.c (gdb_ust_thread): Don't ignore return value
11296 of write.
11297
11298 2011-12-14 Yao Qi <yao@codesourcery.com>
11299
11300 * i386-low.c (i386_low_stopped_data_address): Initialize local
11301 variable `control'.
11302
11303 2011-12-13 Pedro Alves <pedro@codesourcery.com>
11304
11305 PR remote/13492
11306
11307 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
11308 DR_CONTROL unless necessary. Extend comments.
11309 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
11310 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
11311
11312 2011-12-13 Yao Qi <yao@codesourcery.com>
11313
11314 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
11315 macros.
11316 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
11317
11318 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
11319
11320 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
11321 Print new debug message for such case.
11322
11323 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
11324
11325 Fix overlapping memcpy.
11326 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
11327 the read_inferior_memory transfer.
11328 (delete_fast_tracepoint_jump): New variable buf. Use it for the
11329 write_inferior_memory transfer.
11330 (set_fast_tracepoint_jump): New variable buf. Use it for the
11331 read_inferior_memory and write_inferior_memory transfers.
11332 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
11333 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
11334 Use it for the write_inferior_memory transfer.
11335 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
11336 buffers.
11337
11338 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
11339
11340 * linux-low.c (fetch_register, store_register): Make code
11341 consistent, fix formatting.
11342
11343 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
11344
11345 * linux-low.c (usr_store_inferior_registers): Factor out code
11346 to handle individual registers into...
11347 (store_register): ... this new function.
11348
11349 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
11350
11351 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
11352 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
11353 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
11354 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
11355 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
11356 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
11357 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
11358 (srv_xmlfiles): Add new XML files.
11359
11360 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
11361 and <sys/uio.h>.
11362 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
11363 (init_registers_s390_linux32v1): Add prototype.
11364 (init_registers_s390_linux32v2): Likewise.
11365 (init_registers_s390_linux64v1): Likewise.
11366 (init_registers_s390_linux64v2): Likewise.
11367 (init_registers_s390x_linux64v1): Likewise.
11368 (init_registers_s390x_linux64v2): Likewise.
11369 (s390_num_regs): Increment to 52.
11370 (s390_regmap): Add orig_r2 register.
11371 (s390_num_regs_3264): Increment to 68.
11372 (s390_regmap_3264): Add orig_r2 register.
11373 (s390_collect_ptrace_register): Handle orig_r2 register.
11374 (s390_supply_ptrace_register): Likewise.
11375 (s390_fill_last_break): New function.
11376 (s390_store_last_break): Likewise.
11377 (s390_fill_system_call): New function.
11378 (s390_store_system_call): Likewise.
11379 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
11380 register sets.
11381 (s390_check_regset): New function.
11382 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
11383 NT_S390_SYSTEM_CALL regsets and use appropriate description.
11384 Update target_regsets for available register sets.
11385
11386 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
11387 Jan Kratochvil <jan.kratochvil@redhat.com>
11388
11389 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
11390 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
11391 New.
11392 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
11393 * linux-low.h (struct process_info_private): New member r_debug.
11394 * server.c (handle_qxfer_libraries): Call
11395 the_target->qxfer_libraries_svr4.
11396 (handle_qxfer_libraries_svr4): New function.
11397 (qxfer_packets): New entry "libraries-svr4".
11398 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
11399 * target.h (struct target_ops): New member qxfer_libraries_svr4.
11400 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
11401 PACKET_qXfer_libraries_svr4.
11402
11403 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
11404
11405 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
11406 PSW address/mask between 8-byte and 16-byte formats.
11407 (s390_supply_ptrace_register): Likewise.
11408 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
11409 basic addressing mode bit.
11410
11411 2011-11-24 Stan Shebs <stan@codesourcery.com>
11412
11413 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
11414
11415 2011-11-17 Stan Shebs <stan@codesourcery.com>
11416
11417 * tracepoint.c (struct tracepoint): New field traceframe_usage.
11418 (tracing_start_time): New global.
11419 (tracing_stop_time): New global.
11420 (tracing_user_name): New global.
11421 (tracing_notes): New global.
11422 (tracing_stop_note): New global.
11423 (cmd_qtstart): Set traceframe_usage, start_time.
11424 (stop_tracing): Set stop_time.
11425 (cmd_qtstatus): Report additional status.
11426 (cmd_qtp): New function.
11427 (handle_tracepoint_query): Call it.
11428 (cmd_qtnotes): New function.
11429 (handle_tracepoint_general_set): Call it.
11430 (get_timestamp): Rename from tsv_get_timestamp.
11431
11432 2011-11-14 Stan Shebs <stan@codesourcery.com>
11433 Kwok Cheung Yeung <kcy@codesourcery.com>
11434
11435 * linux-x86-low.c (small_jump_insn): New.
11436 (i386_install_fast_tracepoint_jump_pad): Add arguments for
11437 trampoline and error message, build a trampoline and issue a small
11438 jump instruction to it.
11439 (x86_install_fast_tracepoint_jump_pad): Add arguments for
11440 trampoline and error message.
11441 (x86_get_min_fast_tracepoint_insn_len): New.
11442 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
11443 * linux-low.h (struct linux_target_ops): Add arguments to
11444 install_fast_tracepoint_jump_pad operation, add new operation.
11445 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
11446 arguments.
11447 (linux_get_min_fast_tracepoint_insn_len): New function.
11448 (linux_target_op): Add new operation.
11449 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
11450 (gdb_trampoline_buffer_end): Ditto.
11451 (gdb_trampoline_buffer_error): Ditto.
11452 (struct ipa_sym_addresses): Add fields for new IPA variables.
11453 (symbol_list): Add entries for new IPA variables.
11454 (struct tracepoint): Add fields to hold the address range of the
11455 trampoline used by the tracepoint.
11456 (trampoline_buffer_head): New static variable.
11457 (trampoline_buffer_tail): Ditto.
11458 (claim_trampoline_space): New function.
11459 (have_fast_tracepoint_trampoline_buffer): New function.
11460 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
11461 structure.
11462 (install_fast_tracepoint): Ditto, also add error buffer argument.
11463 (cmd_qtminftpilen): New function.
11464 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
11465 (fast_tracepoint_from_trampoline_address): New function.
11466 (fast_tracepoint_collecting): Handle trampoline as part of jump
11467 pad space.
11468 (set_trampoline_buffer_space): New function.
11469 (initialize_tracepoint): Initialize new IPA variables.
11470 * target.h (struct target_ops): Add arguments to
11471 install_fast_tracepoint_jump_pad operation, add new
11472 get_min_fast_tracepoint_insn_len operation.
11473 (target_get_min_fast_tracepoint_insn_len): New.
11474 (install_fast_tracepoint_jump_pad): Add arguments.
11475 * server.h (IPA_BUFSIZ): Define.
11476 * linux-i386-ipa.c: Include extra header files.
11477 (initialize_fast_tracepoint_trampoline_buffer): New function.
11478 (initialize_low_tracepoint): Call it.
11479 * server.h (set_trampoline_buffer_space): Declare.
11480 (claim_trampoline_space): Ditto.
11481 (have_fast_tracepoint_trampoline_buffer): Ditto.
11482
11483 2011-11-14 Yao Qi <yao@codesourcery.com>
11484
11485 * server.c (handle_query): Handle InstallInTrace for qSupported.
11486 * tracepoint.c (add_tracepoint): Sort list.
11487 (install_tracepoint, download_tracepoint): New.
11488 (cmd_qtdp): Call them to install and download tracepoints.
11489 (sort_tracepoints): Removed.
11490 (cmd_qtstart): Update.
11491
11492 2011-11-14 Yao Qi <yao@codesourcery.com>
11493
11494 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
11495 * mem-break.h: Declare.
11496 * tracepoint.c (cmd_qtstart): Move some code to ...
11497 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
11498 New.
11499 (download_tracepoints): Move some code to ...
11500 (download_tracepoint_1): ... here. New.
11501
11502 2011-11-08 Yao Qi <yao@codesourcery.com>
11503
11504 * remote-utils.c (relocate_instruction): A comment fix.
11505
11506 2011-11-07 Joel Brobecker <brobecker@adacore.com>
11507
11508 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
11509 (i386_dr_low_get_control, i386_dr_low_get_status): Use
11510 dr_status_mirror and dr_control_mirror from debug_reg_state.
11511 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
11512 (i386_initial_stuff): Remove use of deleted globals.
11513 (i386_get_thread_context, i386_set_thread_context,
11514 i386_thread_added): Use dr_status_mirror and dr_control_mirror
11515 from debug_reg_state.
11516
11517 2011-11-05 Yao Qi <yao@codesourcery.com>
11518
11519 * tracepoint.c (gdb_collect): Loop over tracepoints of same
11520 address as TPOINT's.
11521
11522 2011-11-02 Stan Shebs <stan@codesourcery.com>
11523
11524 * tracepoint.c (agent_mem_read_string): New function.
11525 (eval_agent_expr): Call it for tracenz.
11526 * server.c (handle_query): Report support for tracenz.
11527
11528 2011-11-02 Yao Qi <yao@codesourcery.com>
11529
11530 * tracepoint.c (cmd_qtstart): Remove unused local variables.
11531
11532 2011-11-02 Yao Qi <yao@codesourcery.com>
11533
11534 * target.h: Fix a typo in comment.
11535
11536 2011-10-31 Pedro Alves <pedro@codesourcery.com>
11537
11538 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
11539 clobber the breakpoints' shadows with fast tracepoint jumps.
11540 * mem-break.h (check_mem_write): Add `myaddr' parameter.
11541 * target.c (write_inferior_memory): Also pass MYADDR down to
11542 check_mem_write.
11543
11544 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
11545
11546 * configure.ac: Check support for personality routine.
11547 * configure: Regenerate.
11548 * config.in: Likewise.
11549 * linux-low.c: Include <sys/personality.h>.
11550 Define ADDR_NO_RANDOMIZE if necessary.
11551 (linux_create_inferior): Disable address space randomization when
11552 forking inferior, if requested.
11553 (linux_supports_disable_randomization): New function.
11554 (linux_target_ops): Install it.
11555 * server.h (disable_randomization): Declare.
11556 * server.c (disable_randomization): New global variable.
11557 (handle_general_set): Handle QDisableRandomization.
11558 (handle_query): Likewise for qSupported.
11559 (main): Support --disable-randomization and --no-disable-randomization
11560 command line arguments.
11561 * target.h (struct target_ops): Add supports_disable_randomization.
11562 (target_supports_disable_randomization): New macro.
11563
11564 2011-09-29 Mike Frysinger <vapier@gentoo.org>
11565
11566 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
11567 ifdef check.
11568 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
11569 [!PT_GETDSBT] (target_loadmap): New definition.
11570 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
11571 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
11572 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
11573 and PT_GETDSBT to LINUX_LOADMAP.
11574 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
11575 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
11576
11577 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
11578
11579 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
11580 (arm_linux_hwbp_cap): New static variable.
11581 (arm_linux_get_hwbp_cap): Replace by ...
11582 (arm_linux_init_hwbp_cap): ... this new function.
11583 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
11584 (arm_linux_get_hw_watchpoint_count): Likewise.
11585 (arm_linux_get_hw_watchpoint_max_length): Likewise.
11586 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
11587 (arm_prepare_to_resume): Use perror_with_name instead of error.
11588
11589 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
11590
11591 * linux-arm-low.c: Include <signal.h>.
11592 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
11593 (struct arm_linux_hwbp_cap): New data type.
11594 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
11595 (struct arm_linux_hw_breakpoint): New data type.
11596 (MAX_BPTS, MAX_WPTS): Define.
11597 (struct arch_process_info, struct arch_lwp_info): New data types.
11598 (arm_linux_get_hwbp_cap): New function.
11599 (arm_linux_get_hw_breakpoint_count): Likewise.
11600 (arm_linux_get_hw_watchpoint_count): Likewise.
11601 (arm_linux_get_hw_watchpoint_max_length): Likewise.
11602 (arm_hwbp_control_initialize): Likewise.
11603 (arm_hwbp_control_is_enabled): Likewise.
11604 (arm_hwbp_control_is_initialized): Likewise.
11605 (arm_hwbp_control_disable): Likewise.
11606 (arm_linux_hw_breakpoint_equal): Likewise.
11607 (arm_linux_hw_point_initialize): Likewise.
11608 (struct update_registers_data): New data structure.
11609 (update_registers_callback: New function.
11610 (arm_insert_point): Likewise.
11611 (arm_remove_point): Likewise.
11612 (arm_stopped_by_watchpoint): Likewise.
11613 (arm_stopped_data_address): Likewise.
11614 (arm_new_process): Likewise.
11615 (arm_new_thread): Likewise.
11616 (arm_prepare_to_resume): Likewise.
11617 (the_low_target): Register arm_insert_point, arm_remove_point,
11618 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
11619 arm_new_thread, and arm_prepare_to_resume.
11620
11621 2011-09-15 Stan Shebs <stan@codesourcery.com>
11622
11623 * server.h (struct emit_ops): Add compare-goto fields.
11624 * tracepoint.c (gdb_agent_op_sizes): New table.
11625 (emit_eq_goto): New function.
11626 (emit_ne_goto): New function.
11627 (emit_lt_goto): New function.
11628 (emit_le_goto): New function.
11629 (emit_gt_goto): New function.
11630 (emit_ge_goto): New function.
11631 (is_goto_target): New function.
11632 (compile_bytecodes): Recognize special cases of compare-goto
11633 combinations and call specialized emitters for them.
11634 * linux-x86-low.c (amd64_emit_eq_goto): New function.
11635 (amd64_emit_ne_goto): New function.
11636 (amd64_emit_lt_goto): New function.
11637 (amd64_emit_le_goto): New function.
11638 (amd64_emit_gt_goto): New function.
11639 (amd64_emit_ge_goto): New function.
11640 (amd64_emit_ops): Add the new functions.
11641 (i386_emit_eq_goto): New function.
11642 (i386_emit_ne_goto): New function.
11643 (i386_emit_lt_goto): New function.
11644 (i386_emit_le_goto): New function.
11645 (i386_emit_gt_goto): New function.
11646 (i386_emit_ge_goto): New function.
11647 (i386_emit_ops): Add the new functions.
11648
11649 2011-09-08 Stan Shebs <stan@codesourcery.com>
11650
11651 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
11652 (i386_emit_epilogue): Restore %ebx.
11653
11654 2011-08-31 Jie Zhang <jzhang918@gmail.com>
11655
11656 * server.c (step_thread): Remove definition.
11657 (process_serial_event): Don't handle Hs.
11658 * server.h (step_thread): Remove declaration.
11659 * target.c (set_desired_inferior): Remove use of step_thread.
11660
11661 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
11662
11663 * linux-low.c: Include linux-procfs.h.
11664 (linux_attach_lwp_1): Update comments.
11665 (linux_attach): Scan for existing threads when attaching to a
11666 process that is the tgid.
11667 * Makefile.in: Update dependencies.
11668
11669 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
11670
11671 * configure.srv: Add linux-procfs.o dependencies.
11672
11673 2011-08-14 Yao Qi <yao@codesourcery.com>
11674
11675 * target.h (struct target_ops): Fix indent.
11676 * win32-low.c (win32_target_ops): Fix comment.
11677
11678 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
11679 Yao Qi <yao@codesourcery.com>
11680
11681 * Makefile.in (clean): Remove tic6x-*.c files.
11682 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
11683 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
11684 (tic6x-c64xp-linux.c): Likewise.
11685 * configure.srv: Add support for tic6x-*-uclinux.
11686 * linux-tic6x-low.c: New.
11687 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
11688
11689 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
11690 Yao Qi <yao@codesourcery.com>
11691
11692 * target.h (struct target_ops): Add read_loadmap.
11693 * linux-low.c (struct target_loadseg): New type.
11694 (struct target_loadmap): New type.
11695 (linux_read_loadmap): New function.
11696 (linux_target_ops): Add linux_read_loadmap.
11697 * server.c (handle_query): Support qXfer:fdpic:read packet.
11698 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
11699 to NULL.
11700
11701 2011-08-05 Eli Zaretskii <eliz@gnu.org>
11702
11703 * win32-low.c: Include <stdint.h>.
11704
11705 2011-07-22 Pedro Alves <pedro@codesourcery.com>
11706
11707 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
11708 to the inferior here.
11709 (i386_remove_aligned_watchpoint): Ditto.
11710 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
11711 fit part of the watchpoint in the debug registers.
11712 (i386_update_inferior_debug_regs): New.
11713 (i386_low_insert_watchpoint): Work on a local mirror of the debug
11714 registers, and only update the inferior on success.
11715 (i386_low_remove_watchpoint): Ditto.
11716
11717 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
11718
11719 * linux-low.c (compare_ints, unique, list_threads, show_process,
11720 linux_core_of_thread): Delete.
11721 (linux_target_ops): Change linux_core_of_thread to
11722 linux_common_core_of_thread.
11723 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
11724 * utils.c (malloc_failure): Change type of argument.
11725 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
11726 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
11727 common/linux-osdata.c, common/ptid.c and common/buffer.c.
11728 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
11729 (IPA_OBJS): Add common-utils-ipa.o.
11730 (ptid_h, linux_osdata_h): New macros.
11731 (server_h): Add common/common-utils.h, common/xml-utils.h,
11732 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
11733 common/ptid.h.
11734 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
11735 ptid.o, buffer.o): New rules.
11736 (linux-low.o): Add common/linux-osdata.h as a dependency.
11737 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
11738 * configure.ac: Add AC_HEADER_DIRENT check.
11739 * config.in: Regenerate.
11740 * configure: Regenerate.
11741 * remote-utils.c (xml_escape_text): Delete.
11742 (buffer_grow, buffer_free, buffer_init, buffer_finish,
11743 buffer_xml_printf): Move to common/buffer.c.
11744 * server.c (main): Remove call to initialize_inferiors.
11745 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
11746 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
11747 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
11748 internal_error, gdb_assert, gdb_assert_fail): Delete.
11749 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
11750 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
11751 common/buffer.h.
11752 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
11753 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
11754 initialize_inferiors): Delete.
11755
11756 2011-07-20 Pedro Alves <pedro@codesourcery.com>
11757
11758 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
11759 symbol error.
11760
11761 2011-05-31 Pedro Alves <pedro@codesourcery.com>
11762
11763 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
11764 assertion.
11765 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
11766
11767 2011-05-26 Yao Qi <yao@codesourcery.com>
11768
11769 * Makefile.in (thread-db.o): Track dependence to
11770 common/gdb_thread_db.h.
11771 * thread-db.c: include gdb_thread_db.h from right place.
11772
11773 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
11774
11775 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
11776 __FILE__ and __LINE__ to internal_error.
11777
11778 2011-05-13 Doug Evans <dje@google.com>
11779
11780 * thread-db.c (try_thread_db_load_from_sdir): New function.
11781 (try_thread_db_load_from_dir): New function.
11782 (thread_db_load_search): Handle $sdir, ignore $pdir.
11783 Remove trying of system directories if search of
11784 libthread-db-search-path fails, that is now done via $sdir.
11785
11786 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
11787
11788 * server.c (handle_query): Add EnableDisableTracepoints to the list
11789 of supported features.
11790 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
11791 tracepoints.
11792 (cmd_qtenable_disable): New.
11793 (cmd_qtstart): Install tracepoints even if disabled.
11794 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
11795 receiving a QTEnable or QTDisable packet.
11796 (gdb_collect): Skip data collection if fast tracepoint is disabled.
11797 (ust_marker_to_static_tracepoint): Do not ignore disabled static
11798 tracepoints.
11799 (gdb_probe): Skip data collection if static tracepoint is disabled.
11800
11801 2011-05-10 Doug Evans <dje@google.com>
11802
11803 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
11804
11805 2011-05-04 Doug Evans <dje@google.com>
11806
11807 * linux-low.c (linux_join): Skip process lookup.
11808 * spu-low.c (spu_join): Ditto.
11809 * server.c (join_inferiors_callback): Delete.
11810 (process_serial_event): For 'D' packet (detach) call join_inferior
11811 directly.
11812
11813 2011-05-04 Joseph Myers <joseph@codesourcery.com>
11814
11815 * README: Don't mention xscale*-*-linux*.
11816 * configure.srv (xscale*-*-linux*): Don't handle target.
11817
11818 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
11819
11820 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
11821 casting pointers.
11822 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
11823 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
11824 (i386_emit_void_call_2): Likewise.
11825
11826 2011-04-26 Yao Qi <yao@codesourcery.com>
11827
11828 * linux-low.c: Move common macros to linux-ptrace.h.
11829 Include linux-ptrace.h.
11830 * Makefile.in (linux_ptrace_h): New.
11831 (linux-low.o): Depends on linux-ptrace.h.
11832
11833 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
11834
11835 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
11836 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
11837 (remote_prepare): New function with most of the TCP code from ...
11838 (remote_open): ... here. Detect PORT here unconditionally. Move also
11839 setting transport_is_reliable.
11840 * server.c (run_once): New variable.
11841 (gdbserver_usage): Document it.
11842 (main): Set run_once for `--once'. Call remote_prepare. Exit after
11843 the first run if RUN_ONCE.
11844 * server.h (run_once, remote_prepare): New declarations.
11845
11846 2011-04-19 Tom Tromey <tromey@redhat.com>
11847
11848 * win32-low.c (handle_load_dll): Remove duplicate "the".
11849
11850 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
11851
11852 Remove support for old Cygwin 1.5 versions.
11853 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
11854 function to avoid warning.
11855 (win32_add_one_solib): Use cygwin_conv_path function to avoid
11856 warning.
11857
11858 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
11859
11860 * gdbserver/server.h (Macro _): Define it if not available.
11861
11862 2011-03-14 Michael Snyder <msnyder@vmware.com>
11863
11864 * hostio.c (handle_close): Remove unnecessary null test.
11865
11866 2011-03-10 Joel Brobecker <brobecker@adacore.com>
11867
11868 * Makefile.in (maintainer-clean realclean distclean): Remove
11869 "make ... subdir_do" command.
11870
11871 2011-03-10 Michael Snyder <msnyder@vmware.com>
11872
11873 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
11874
11875 * server.c (handle_v_run): Free alloced buffer on early return.
11876
11877 2011-03-09 Yao Qi <yao@codesourcery.com>
11878
11879 Revert:
11880 2011-03-04 Yao Qi <yao@codesourcery.com>
11881
11882 * Makefile.in: Remove GNU make feature --directory.
11883
11884 2011-03-05 Yao Qi <yao@codesourcery.com>
11885
11886 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
11887 (subdir_do): New make target. Copied from gdb/Makefile.
11888 (maintainer-clean, realclean, distclean, clean): Call corresponding
11889 make targets in common/Makefile.
11890
11891 2011-02-11 Yao Qi <yao@codesourcery.com>
11892
11893 * configure.ac: Call AC_PROG_RANLIB.
11894 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
11895 * configure: Regenerate.
11896
11897 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
11898
11899 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
11900
11901 2011-03-06 Yao Qi <yao@codesourcery.com>
11902
11903 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
11904
11905 2011-03-05 Yao Qi <yao@codesourcery.com>
11906
11907 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
11908 (subdir_do): New make target. Copied from gdb/Makefile.
11909 (maintainer-clean, realclean, distclean, clean): Call corresponding
11910 make targets in common/Makefile.
11911
11912 2011-03-04 Yao Qi <yao@codesourcery.com>
11913
11914 * Makefile.in: Remove GNU make feature --directory.
11915
11916 2011-03-04 Michael Snyder <msnyder@vmware.com>
11917
11918 * server.c (queue_stop_reply): Call xmalloc not malloc.
11919
11920 2011-03-02 Michael Snyder <msnyder@vmware.com>
11921
11922 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
11923
11924 2011-02-28 Michael Snyder <msnyder@vmware.com>
11925
11926 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
11927 (cmd_qtframe): Ditto.
11928 (cmd_qtbuffer): Ditto.
11929 (cmd_bigqtbuffer): Ditto.
11930
11931 * utils.c (decimal2str): Initialize 'width' to nine, then
11932 don't mess with it.
11933
11934 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
11935
11936 * hostio.c (require_data): Free *data, not data.
11937
11938 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
11939
11940 * hostio.c (require_data): Use free, not xfree.
11941
11942 2011-02-27 Michael Snyder <msnyder@vmware.com>
11943
11944 * server.c (handle_query): Discard unused value.
11945
11946 * hostio.c (require_data): Free malloc memory before returning
11947 error.
11948
11949 2011-02-26 Michael Snyder <msnyder@vmware.com>
11950
11951 * linux-low.c (list_threads): Call closedir for dirent.
11952
11953 2011-02-27 Michael Snyder <msnyder@vmware.com>
11954
11955 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
11956 a case statement falls through.
11957
11958 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
11959
11960 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
11961 in comparison.
11962
11963 2011-02-26 Michael Snyder <msnyder@vmware.com>
11964
11965 * utils.c (decimal2str): Eliminate dead code and dead param.
11966 (pulongest): Drop dead param from call to decimal2str.
11967 (plongest): Ditto.
11968
11969 2011-02-24 Joel Brobecker <brobecker@adacore.com>
11970
11971 Revert the following patch (not approved yet):
11972 2011-02-21 Hui Zhu <teawater@gmail.com>
11973 * tracepoint.c (tp_printf): New function.
11974 (eval_agent_expr): Handle gdb_agent_op_printf.
11975
11976 2011-02-21 Hui Zhu <teawater@gmail.com>
11977
11978 * tracepoint.c (tp_printf): New function.
11979 (eval_agent_expr): Handle gdb_agent_op_printf.
11980
11981 2011-02-18 Tom Tromey <tromey@redhat.com>
11982
11983 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
11984 (tracepoint.o): Likewise.
11985 * tracepoint.c (enum gdb_agent_op): Use ax.def.
11986 (gdb_agent_op_names): Likewise.
11987
11988 2011-02-18 Tom Tromey <tromey@redhat.com>
11989
11990 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
11991 gdb_agent_op_rot>: New constants.
11992 (gdb_agent_op_names): Add pick and roll.
11993 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
11994 cases.
11995
11996 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
11997
11998 * aclocal.m4: Regenerated with aclocal-1.11.1.
11999
12000 2011-02-14 Pedro Alves <pedro@codesourcery.com>
12001
12002 * server.c (handle_qxfer_traceframe_info): New.
12003 (qxfer_packets): Register "traceframe-info".
12004 (handle_query): Report support for qXfer:traceframe-info:read+.
12005 * tracepoint.c (match_blocktype): New.
12006 (traceframe_find_block_type): Rename to ...
12007 (traceframe_walk_blocks): ... this. Add callback filter argument,
12008 and use it.
12009 (traceframe_find_block_type): New, reimplemented on top of
12010 traceframe_walk_blocks.
12011 (build_traceframe_info_xml): New.
12012 (traceframe_read_info): New.
12013 * server.h (traceframe_read_info): Declare.
12014
12015 2011-02-11 Yao Qi <yao@codesourcery.com>
12016
12017 * configure.ac: Call AC_PROG_RANLIB.
12018 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
12019 * configure: Regenerate.
12020
12021 2011-02-07 Pedro Alves <pedro@codesourcery.com>
12022
12023 * server.c (gdb_read_memory): Change return semantics to allow
12024 partial transfers.
12025 (handle_search_memory_1): Adjust.
12026 (process_serial_event) <'m' packet>: Handle partial transfers.
12027 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
12028
12029 2011-01-28 Pedro Alves <pedro@codesourcery.com>
12030
12031 * regcache.c (init_register_cache): Initialize
12032 regcache->register_status.
12033 (free_register_cache): Release regcache->register_status.
12034 (regcache_cpy): Copy register_status.
12035 (registers_to_string): Print 'x's for unavailable registers.
12036 (supply_register): Mark the register's status valid or
12037 unavailable, depending on whether a buffer was passed in or not.
12038 (supply_register_zeroed): New.
12039 (supply_regblock): Mark the registers' status valid or
12040 unavailable, depending on whether a buffer was passed in or not.
12041 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
12042 (struct regcache): New `register_status' field.
12043 (supply_register_zeroed): Declare.
12044 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
12045 supply_register_zeroed, rather than passing a NULL buffer to
12046 supply_register.
12047 * tracepoint.c (fetch_traceframe_registers): Update comment.
12048
12049 2011-01-28 Pedro Alves <pedro@codesourcery.com>
12050
12051 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
12052 buffer explicit.
12053
12054 2011-01-25 Pedro Alves <pedro@codesourcery.com>
12055
12056 * server.h (decode_xfer_write): Change prototype.
12057 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
12058 and don't extract the annex here.
12059 * server.c (decode_xfer_read): Remove `annex' parameter,
12060 and don't extract the annex here.
12061 (decode_xfer): New.
12062 (struct qxfer): New.
12063 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
12064 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
12065 (handle_qxfer_statictrace): New functions, abstracted out from
12066 handle_query, and made to use the struct qxfer interface.
12067 (handle_threads_qxfer_proper): Rename to ...
12068 (handle_qxfer_threads_proper): ... this.
12069 (handle_threads_qxfer): Rename to ...
12070 (handle_qxfer_threads): ... this. Adjust.
12071 (qxfer_packets): New array.
12072 (handle_qxfer): New function.
12073 (handle_query): Use handle_qxfer.
12074
12075 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
12076
12077 * gdbreplay.c: Shorten lines of >= 80 columns.
12078 * linux-low.c: Ditto.
12079 * linux-ppc-low.c: Ditto.
12080 * linux-s390-low.c: Ditto.
12081 * linux-sparc-low.c: Ditto.
12082 * linux-x86-low.c: Ditto.
12083 * linux-xtensa-low.c: Ditto.
12084 * mem-break.c: Ditto.
12085 * nto-low.c: Ditto.
12086 * regcache.h: Ditto.
12087 * remote-utils.c: Ditto.
12088 * server.c: Ditto.
12089 * server.h: Ditto.
12090 * thread-db.c: Ditto.
12091 * tracepoint.c: Ditto.
12092 * utils.c: Ditto.
12093 * win32-low.h: Ditto.
12094
12095 2011-01-05 Joel Brobecker <brobecker@adacore.com>
12096
12097 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
12098 update.
12099
12100 2011-01-01 Joel Brobecker <brobecker@adacore.com>
12101
12102 * server.c (gdbserver_version): Update copyright year in version
12103 output.
12104 * gdbreplay.c (gdbreplay_version): Ditto.
12105
12106 2010-12-29 Jie Zhang <jie.zhang@analog.com>
12107
12108 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
12109 * linux-bfin-low.c: New file.
12110 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
12111 PT_DATA_ADDR for BFIN targets.
12112 * Makefile.in (SFILES): Add linux-bfin-low.c.
12113 (clean): Remove reg-bfin.c.
12114 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
12115 * README: Mention supported Blackfin targets.
12116
12117 2010-12-23 Mike Frysinger <vapier@gentoo.org>
12118
12119 * .gitignore: New file.
12120
12121 2010-11-16 Mike Frysinger <vapier@gentoo.org>
12122
12123 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
12124
12125 2010-10-22 Jie Zhang <jie@codesourcery.com>
12126
12127 * Makefile.in: Add FLAGS_TO_PASS variable.
12128 (install): Remove dependency of install-only and recursively
12129 invoke make for install-only.
12130
12131 2010-10-04 Doug Evans <dje@google.com>
12132
12133 * Makefile.in (uninstall): Use $(DESTDIR).
12134
12135 2010-09-24 Pedro Alves <pedro@codesourcery.com>
12136
12137 PR gdb/11842
12138
12139 * linux-x86-low.c (compat_siginfo_from_siginfo)
12140 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
12141 si_code is < 0. Check for si_code == SI_TIMER before checking for
12142 si_code < 0.
12143
12144 2010-09-13 Joel Brobecker <brobecker@adacore.com>
12145
12146 * lynx-i386-low.c: New file.
12147 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
12148
12149 2010-09-13 Joel Brobecker <brobecker@adacore.com>
12150
12151 * lynx-low.c (ptrace_request_to_str): Remove handling for
12152 request values that have been removed in LynxOS 5.x.
12153
12154 2010-09-13 Joel Brobecker <brobecker@adacore.com>
12155
12156 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
12157 <ptrace.h>
12158
12159 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
12160
12161 * configure.ac: Add --enable-inprocess-agent option.
12162 * configure: Rebuilt.
12163
12164 2010-09-06 Yao Qi <yao@codesourcery.com>
12165
12166 * linux-low.c (linux_kill): Remove unused variable.
12167 (linux_stabilize_threads): Likewise.
12168 * server.c (start_inferior): Likewise.
12169 (queue_stop_reply_callback): Likewise.
12170 * tracepoint.c (do_action_at_tracepoint): Likewise.
12171
12172 2010-09-06 Yao Qi <yao@codesourcery.com>
12173
12174 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
12175 on return.
12176
12177 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
12178
12179 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
12180
12181 2010-09-06 Pedro Alves <pedro@codesourcery.com>
12182
12183 * Makefile.in (install-only): Replace $IPA_DEPFILES with
12184 "$(IPA_DEPFILES)".
12185
12186 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12187
12188 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
12189 gdbserver/lynx-ppc-low.c: New files.
12190 * Makefile.in (lynx_low_h): New variable.
12191 (lynx-low.o, lynx-ppc-low.o): New rules.
12192 * configure.ac: On LynxOS, link with -lnetinet.
12193 * configure.srv: Add handling of powerpc-*-lynxos* targets.
12194 * configure: regenerate.
12195
12196 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12197
12198 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
12199 * configure.ac: Add check for vasprintf and vsnprintf.
12200 * configure, config.in: Regenerate.
12201 * server.h (vasprintf, vsnprintf): Add conditional declarations.
12202
12203 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12204
12205 * gdbreplay.c: Move include of alloca.h up, next to include of
12206 malloc.h.
12207 * server.h: Add include of malloc.h.
12208 * mem-break.c: Remove include of malloc.h.
12209 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
12210
12211 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12212
12213 * Makefile.in (memmem.o): Build with -Wno-error.
12214
12215 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12216
12217 * utils.c (xsnprintf): Make non-static.
12218 * server.h: Add xsnprintf declaration.
12219 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
12220 replace calls to snprintf by calls to xsnprintf throughout.
12221
12222 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12223
12224 * configure.ac: Add configure check for alloca.
12225 * configure, config.in: Regenerate.
12226 * server.h: Include alloca.h if it exists.
12227 * gdbreplay.c: Include alloca.h if it exists.
12228
12229 2010-08-28 Pedro Alves <pedro@codesourcery.com>
12230
12231 * linux-low.c (__SIGRTMIN): Define if not already defined.
12232 (linux_create_inferior): Check for __ANDROID__ rather than
12233 __SIGRTMIN.
12234 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
12235 are already deferred.
12236 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
12237 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
12238 stopped and already has a pending signal to report.
12239 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
12240 a pending signal to report or is moving out of a jump pad.
12241 (linux_init_signals): Check for __ANDROID__ rather than
12242 __SIGRTMIN.
12243
12244 2010-08-28 Pedro Alves <pedro@codesourcery.com>
12245
12246 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
12247 debug_threads check. Avoid a linear search when not doing debug
12248 output.
12249
12250 2010-08-27 Pedro Alves <pedro@codesourcery.com>
12251
12252 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
12253 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
12254 (struct file_handler) <fd>: Change type to gdb_fildes_t.
12255 (process_event): Change local fd's type to gdb_fildes_t.
12256 (create_file_handler): Adjust prototype.
12257 (delete_file_handler): Adjust prototype.
12258 (handle_file_event): Adjust prototype. Use pfildes.
12259 (create_file_event): Adjsut prototype.
12260 * remote-utils.c (remote_desc, listen_desc): Change type to
12261 gdb_fildes_t.
12262 * server.h: New gdb_fildes_t typedef.
12263 [USE_WIN32API]: Include winsock2.h.
12264 (delete_file_handler, add_file_handler): Adjust prototypes.
12265 (pfildes): Declare.
12266 * utils.c (pfildes): New.
12267
12268 2010-08-27 Pedro Alves <pedro@codesourcery.com>
12269
12270 * configure.ac (build_warnings): Add -Wno-char-subscripts.
12271 * configure: Regenerate.
12272
12273 2010-08-27 Pedro Alves <pedro@codesourcery.com>
12274
12275 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
12276 (linux_done_accessing_memory): ... this.
12277 (linux_target_ops): Adjust.
12278 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
12279 * nto-low.c (nto_target_ops): Adjust comment.
12280 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
12281 * spu-low.c (spu_target_ops): Adjust comment.
12282 * target.h (target_ops): Rename unprepare_to_access_memory field
12283 to done_accessing_memory.
12284 (unprepare_to_access_memory): Rename to ...
12285 (done_accessing_memory): ... this.
12286
12287 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12288
12289 * linux-low.c (linux_prepare_to_access_memory): New.
12290 (linux_unprepare_to_access_memory): New.
12291 (linux_target_ops): Install them.
12292 * server.c (read_memory): Rename to ...
12293 (gdb_read_memory): ... this. Use
12294 prepare_to_access_memory/prepare_to_access_memory.
12295 (write_memory): Rename to ...
12296 (gdb_write_memory): ... this. Use
12297 prepare_to_access_memory/prepare_to_access_memory.
12298 (handle_search_memory_1): Adjust.
12299 (process_serial_event): Adjust.
12300 * target.h (struct target_ops): New fields
12301 prepare_to_access_memory and unprepare_to_access_memory.
12302 (prepare_to_access_memory, unprepare_to_access_memory): New.
12303 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
12304 prepare_to_access_memory/prepare_to_access_memory.
12305 * nto-low.c (nto_target_ops): Adjust.
12306 * spu-low.c (spu_target_ops): Adjust.
12307 * win32-low.c (win32_target_ops): Adjust.
12308
12309 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12310
12311 * Makefile.in (WARN_CFLAGS): Get it from configure.
12312 (WERROR_CFLAGS): New.
12313 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
12314 * configure.ac: Introduce --enable-werror, which adds -Werror to
12315 the compiler command line. Enabled by default. Disable with
12316 --disable-werror. Add -Wdeclaration-after-statement
12317 Wpointer-arith and -Wformat-nonliteral to warning flags.
12318 * configure: Regenerate.
12319
12320 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12321
12322 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
12323
12324 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12325
12326 * gdbreplay.c (remote_error): New.
12327 (gdbchar): New.
12328 (expect): Use gdbchar. Check for error reading from GDB.
12329 Clarify sync error output.
12330 (play): Check for errors writing to GDB.
12331 * linux-low.c (sigchld_handler): Really ignore `write' errors.
12332 * remote-utils.c (getpkt): Check for errors writing to the remote
12333 descriptor.
12334
12335 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12336
12337 * linux-low.c (linux_wait_1): Move non-debugging code out of
12338 `debug_threads' control.
12339
12340 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12341
12342 * linux-low.c (linux_wait_1): Don't set last_status here.
12343 * server.c (push_event, queue_stop_reply_callback): Assert we're
12344 not pushing a TARGET_WAITKIND_IGNORE event.
12345 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
12346 (myresume, handle_target_event): Set the thread's last_resume_kind
12347 and last_status from the target returned status.
12348
12349 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12350
12351 PR threads/10729
12352
12353 * linux-x86-low.c (update_debug_registers_callback): New.
12354 (i386_dr_low_set_addr): Use it.
12355 (i386_dr_low_get_addr): New.
12356 (i386_dr_low_set_control): Use update_debug_registers_callback.
12357 (i386_dr_low_get_control): New.
12358 (i386_dr_low_get_status): Adjust.
12359 * linux-low.c (linux_stop_lwp): New.
12360 * linux-low.h (linux_stop_lwp): Declare.
12361
12362 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
12363 argument instead of a i386_debug_reg_state.
12364 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
12365 a i386_debug_reg_state.
12366 (i386_insert_aligned_watchpoint): Adjust.
12367 (i386_remove_aligned_watchpoint): Adjust.
12368 (i386_low_stopped_data_address): Read the debug registers from the
12369 inferior instead of from the mirrors.
12370 * i386-low.h (struct i386_debug_reg_state): Extend comment.
12371 (i386_dr_low_get_addr): Declare.
12372 (i386_dr_low_get_control): Declare.
12373 (i386_dr_low_get_status): Change prototype.
12374
12375 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
12376 (i386_dr_low_get_addr): New.
12377 (i386_dr_low_get_control): New.
12378 (i386_dr_low_get_status): Adjust prototype. Return
12379 dr_status_mirror.
12380 (i386_initial_stuff): Clear dr_status_mirror and
12381 dr_control_mirror.
12382 (i386_get_thread_context): Adjust.
12383 (i386_set_thread_context): Adjust.
12384 (i386_thread_added): Adjust.
12385
12386 2010-08-24 Pedro Alves <pedro@codesourcery.com>
12387
12388 * linux-low.h (linux_thread_area): Delete declaration.
12389
12390 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
12391
12392 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
12393 after its termination.
12394
12395 2010-08-09 Pedro Alves <pedro@codesourcery.com>
12396
12397 * linux-low.c (gdb_wants_lwp_stopped): Delete.
12398 (gdb_wants_all_stopped): Delete.
12399 (linux_wait_1): Don't call them.
12400 * server.c (handle_v_cont): Tag all threads as want-stopped.
12401 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
12402 stopped as "client-wants-stopped".
12403
12404 2010-07-31 Pedro Alves <pedro@codesourcery.com>
12405
12406 * Makefile.in (signals_h): New.
12407 (server_h): Depend on it.
12408 (server.o): Don't depend on $(signals_def).
12409 (signals.o): Depend on $(signals_def).
12410
12411 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
12412
12413 * Makefile.in (signals_def): New.
12414 (server_h): Append include/gdb/signals.h and signals_def.
12415 (server.o): Append signals_def.
12416
12417 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
12418
12419 * server.c (handle_target_event): Use target_signal_to_host for
12420 resume_info.sig initialization.
12421 * target.h (struct thread_resume) <sig>: New comment.
12422
12423 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
12424
12425 * server.c (handle_query): strcpy() the returned string from paddress()
12426 instead of sprintf().
12427 * utils.c (paddress): Return phex_nz().
12428
12429 2010-07-07 Joel Brobecker <brobecker@adacore.com>
12430
12431 * server.c (handle_v_cont): Call mourn_inferior if process
12432 just exited.
12433 (myresume): Likewise.
12434
12435 2010-07-01 Pedro Alves <pedro@codesourcery.com>
12436
12437 Static tracepoints, and integration with UST.
12438
12439 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
12440 * mem-break.c (uninsert_all_breakpoints)
12441 (reinsert_all_breakpoints): New.
12442 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
12443 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
12444 (gdb_agent_ust_loaded, helper_thread_id)
12445 (gdb_agent_helper_thread_id): New macros.
12446 (struct ipa_sym_addresses): Add addr_ust_loaded,
12447 addr_helper_thread_id, addr_cmd_buf.
12448 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
12449 (in_process_agent_loaded_ust): New.
12450 (write_e_ust_not_loaded): New.
12451 (maybe_write_ipa_ust_not_loaded): New.
12452 (struct collect_static_trace_data_action): New.
12453 (enum tracepoint_type) <static_tracepoint>: New.
12454 (struct tracepoint) <handle>: Mention static tracepoints.
12455 (struct static_tracepoint_ctx): New.
12456 (CMD_BUF_SIZE): New.
12457 (add_tracepoint_action): Handle static tracepoint actions.
12458 (unprobe_marker_at): New.
12459 (clear_installed_tracepoints): Handle static tracepoints.
12460 (cmd_qtdp): Handle static tracepoints.
12461 (probe_marker_at): New.
12462 (cmd_qtstart): Handle static tracepoints.
12463 (response_tracepoint): Handle static tracepoints.
12464 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
12465 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
12466 (get_context_regcache): Handle static tracepoints.
12467 (do_action_at_tracepoint): Handle static tracepoint actions.
12468 (traceframe_find_block_type): Handle static trace data blocks.
12469 (traceframe_read_sdata): New.
12470 (download_tracepoints): Download static tracepoint actions.
12471 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
12472 (GDB_PROBE_NAME): New.
12473 (ust_ops): New.
12474 (GET_UST_SYM): New.
12475 (USTF): New.
12476 (dlsym_ust): New.
12477 (ust_marker_to_static_tracepoint): New.
12478 (gdb_probe): New.
12479 (collect_ust_data_at_tracepoint): New.
12480 (gdb_ust_probe): New.
12481 (UNIX_PATH_MAX, SOCK_DIR): New.
12482 (gdb_ust_connect_sync_socket): New.
12483 (resume_thread, stop_thread): New.
12484 (run_inferior_command): New.
12485 (init_named_socket): New.
12486 (gdb_ust_socket_init): New.
12487 (cstr_to_hexstr): New.
12488 (next_st): New.
12489 (first_marker, next_marker): New.
12490 (response_ust_marker): New.
12491 (cmd_qtfstm, cmd_qtsstm): New.
12492 (unprobe_marker_at, probe_marker_at): New.
12493 (cmd_qtstmat, gdb_ust_thread): New.
12494 (gdb_ust_init): New.
12495 (initialize_tracepoint_ftlib): Call gdb_ust_init.
12496 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
12497 (ST_REGENTRY): New.
12498 (x86_64_st_collect_regmap): New.
12499 (X86_64_NUM_ST_COLLECT_GREGS): New.
12500 (AMD64_RIP_REGNUM): New.
12501 (supply_static_tracepoint_registers): New.
12502 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
12503 (ST_REGENTRY): New.
12504 (i386_st_collect_regmap): New.
12505 (i386_NUM_ST_COLLECT_GREGS): New.
12506 (supply_static_tracepoint_registers): New.
12507 * server.c (handle_query): Handle qXfer:statictrace:read.
12508 <qSupported>: Report support for StaticTracepoints, and
12509 qXfer:statictrace:read features.
12510 * server.h (traceframe_read_sdata)
12511 (supply_static_tracepoint_registers): Declare.
12512 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
12513 (unpack_varlen_hex): Include in IPA build.
12514 * Makefile.in (ustlibs, ustinc): New.
12515 (IPA_OBJS): Add remote-utils-ipa.o.
12516 ($(IPA_LIB)): Link -ldl and -lpthread.
12517 (UST_CFLAGS): New.
12518 (IPAGENT_CFLAGS): Add UST_CFLAGS.
12519 * config.in, configure: Regenerate.
12520
12521 2010-06-20 Ian Lance Taylor <iant@google.com>
12522 Pedro Alves <pedro@codesourcery.com>
12523
12524 * linux-x86-low.c (always_true): Delete.
12525 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
12526 trying to fool the compiler with always_true.
12527
12528 2010-06-20 Pedro Alves <pedro@codesourcery.com>
12529
12530 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
12531 conditions in gdbserver.
12532
12533 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
12534
12535 * spu-low.c (spu_read_memory): Wrap around local store limit.
12536 (spu_write_memory): Likewise.
12537
12538 2010-06-15 Pedro Alves <pedro@codesourcery.com>
12539
12540 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
12541 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
12542 LONGEST uses.
12543 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
12544 uses.
12545 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
12546 uses with LONGEST uses.
12547
12548 2010-06-14 Stan Shebs <stan@codesourcery.com>
12549 Pedro Alves <pedro@codesourcery.com>
12550
12551 Bytecode compiler.
12552
12553 * linux-x86-low.c: Include limits.h.
12554 (add_insns): New.
12555 (always_true): New.
12556 (EMIT_ASM): New.
12557 (EMIT_ASM32): New.
12558 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
12559 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
12560 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
12561 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
12562 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
12563 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
12564 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
12565 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
12566 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
12567 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
12568 (amd64_emit_void_call_2): New.
12569 (amd64_emit_ops): New.
12570 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
12571 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
12572 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
12573 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
12574 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
12575 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
12576 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
12577 (i386_emit_call, i386_emit_reg, i386_emit_pop)
12578 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
12579 (i386_emit_stack_adjust, i386_emit_int_call_1)
12580 (i386_emit_void_call_2): New.
12581 (i386_emit_ops): New.
12582 (x86_emit_ops): New.
12583 (the_low_target): Install x86_emit_ops.
12584 * server.h (struct emit_ops): New.
12585 (get_raw_reg_func_addr): Declare.
12586 (current_insn_ptr, emit_error): Declare.
12587 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
12588 (set_trace_state_variable_value): New defines.
12589 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
12590 addr_get_trace_state_variable_value and
12591 addr_set_trace_state_variable_value.
12592 (symbol_list): New fields for get_raw_reg,
12593 get_trace_state_variable_value and set_trace_state_variable_value.
12594 (condfn): New typedef.
12595 (struct tracepoint): New field `compiled_cond'.
12596 (do_action_at_tracepoint): Clear compiled_cond.
12597 (get_trace_state_variable_value, set_trace_state_variable_value):
12598 Export in the IPA.
12599 (condition_true_at_tracepoint): If there's a compiled condition,
12600 run that.
12601 (current_insn_ptr, emit_error): New globals.
12602 (struct bytecode_address): New.
12603 (get_raw_reg_func_addr): New.
12604 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
12605 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
12606 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
12607 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
12608 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
12609 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
12610 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
12611 (compile_tracepoint_condition, compile_bytecodes): New.
12612 * target.h (emit_ops): Forward declare.
12613 (struct target_ops): New field emit_ops.
12614 (target_emit_ops): New.
12615 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
12616 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
12617 * linux-low.c (linux_emit_ops): New.
12618 (linux_target_ops): Install it.
12619 * linux-low.h (struct linux_target_ops): New field emit_ops.
12620
12621 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
12622
12623 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
12624 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
12625
12626 2010-06-01 Pedro Alves <pedro@codesourcery.com>
12627 Stan Shebs <stan@codesourcery.com>
12628
12629 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
12630 (all): Depend on $(extra_libraries).
12631 (install-only): Install the IPA.
12632 (IPA_OBJS, IPA_LIB): New.
12633 (clean): Remove the IPA lib.
12634 (IPAGENT_CFLAGS): New.
12635 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
12636 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
12637 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
12638 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
12639 * configure.ac: Check for atomic builtins support in the compiler.
12640 (IPA_DEPFILES, extra_libraries): Define.
12641 * configure.srv (ipa_obj): Add description.
12642 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
12643 (i[34567]86-*-linux*): Set ipa_obj.
12644 (x86_64-*-linux*): Set ipa_obj.
12645 * linux-low.c (stabilizing_threads): New.
12646 (supports_fast_tracepoints): New.
12647 (linux_detach): Stabilize threads before detaching.
12648 (handle_tracepoints): Handle internal tracing breakpoints. Assert
12649 the lwp is either not stabilizing, or is moving out of a jump pad.
12650 (linux_fast_tracepoint_collecting): New.
12651 (maybe_move_out_of_jump_pad): New.
12652 (enqueue_one_deferred_signal): New.
12653 (dequeue_one_deferred_signal): New.
12654 (linux_wait_for_event_1): If moving out of a jump pad, defer
12655 pending signals to later.
12656 (linux_stabilize_threads): New.
12657 (linux_wait_1): Check if threads need moving out of jump pads, and
12658 do it if so.
12659 (stuck_in_jump_pad_callback): New.
12660 (move_out_of_jump_pad_callback): New.
12661 (lwp_running): New.
12662 (linux_resume_one_lwp): Handle moving out of jump pads.
12663 (linux_set_resume_request): Dequeue deferred signals.
12664 (need_step_over_p): Also step over fast tracepoint jumps.
12665 (start_step_over): Also uninsert fast tracepoint jumps.
12666 (finish_step_over): Also reinsert fast tracepoint jumps.
12667 (linux_install_fast_tracepoint_jump): New.
12668 (linux_target_ops): Install linux_stabilize_threads and
12669 linux_install_fast_tracepoint_jump_pad.
12670 * linux-low.h (linux_target_ops) <get_thread_area,
12671 install_fast_tracepoint_jump_pad>: New fields.
12672 (struct lwp_info) <collecting_fast_tracepoint,
12673 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
12674 (linux_get_thread_area): Declare.
12675 * linux-x86-low.c (jump_insn): New.
12676 (x86_get_thread_area): New.
12677 (append_insns): New.
12678 (push_opcode): New.
12679 (amd64_install_fast_tracepoint_jump_pad): New.
12680 (i386_install_fast_tracepoint_jump_pad): New.
12681 (x86_install_fast_tracepoint_jump_pad): New.
12682 (the_low_target): Install x86_get_thread_area and
12683 x86_install_fast_tracepoint_jump_pad.
12684 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
12685 (struct fast_tracepoint_jump): New.
12686 (fast_tracepoint_jump_insn): New.
12687 (fast_tracepoint_jump_shadow): New.
12688 (find_fast_tracepoint_jump_at): New.
12689 (fast_tracepoint_jump_here): New.
12690 (delete_fast_tracepoint_jump): New.
12691 (set_fast_tracepoint_jump): New.
12692 (uninsert_fast_tracepoint_jumps_at): New.
12693 (reinsert_fast_tracepoint_jumps_at): New.
12694 (set_breakpoint_at): Use write_inferior_memory.
12695 (uninsert_raw_breakpoint): Use write_inferior_memory.
12696 (check_mem_read): Mask out fast tracepoint jumps.
12697 (check_mem_write): Mask out fast tracepoint jumps.
12698 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
12699 (set_fast_tracepoint_jump): Declare.
12700 (delete_fast_tracepoint_jump)
12701 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
12702 (reinsert_fast_tracepoint_jumps_at): Declare.
12703 * regcache.c: Don't compile many functions when building the
12704 in-process agent library.
12705 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
12706 the register buffer in the heap.
12707 (free_register_cache): If the register buffer isn't owned by the
12708 regcache, don't free it.
12709 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
12710 pre-existing register caches.
12711 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
12712 type.
12713 (convert_ascii_to_int): : Constify `from' parameter type.
12714 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
12715 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
12716 the needed buffer in-place.
12717 (relocate_instruction): New.
12718 * server.c (handle_query) <qSymbols>: If the target supports
12719 tracepoints, give it a chance of looking up symbols. Report
12720 support for fast tracepoints.
12721 (handle_status): Stabilize threads.
12722 (process_serial_event): Adjust.
12723 * server.h (struct fast_tracepoint_jump): Forward declare.
12724 (struct process_info) <fast_tracepoint_jumps>: New field.
12725 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
12726 (decode_X_packet, decode_M_packet): Adjust.
12727 (relocate_instruction): Declare.
12728 (in_process_agent_loaded): Declare.
12729 (tracepoint_look_up_symbols): Declare.
12730 (struct fast_tpoint_collect_status): Declare.
12731 (fast_tracepoint_collecting): Declare.
12732 (force_unlock_trace_buffer): Declare.
12733 (handle_tracepoint_bkpts): Declare.
12734 (initialize_low_tracepoint)
12735 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
12736 * target.h (struct target_ops) <stabilize_threads,
12737 install_fast_tracepoint_jump_pad>: New fields.
12738 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
12739 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
12740 [HAVE_STDINT_H]: Include stdint.h.
12741 (trace_debug_1): Rename to ...
12742 (trace_vdebug): ... this.
12743 (trace_debug): Rename to ...
12744 (trace_debug_1): ... this. Add `level' parameter.
12745 (trace_debug): New.
12746 (ATTR_USED, ATTR_NOINLINE): New.
12747 (IP_AGENT_EXPORT): New.
12748 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
12749 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
12750 (about_to_request_buffer_space, trace_buffer_is_full)
12751 (stopping_tracepoint, expr_eval_result, error_tracepoint)
12752 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
12753 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
12754 (traceframe_write_count, traceframes_created)
12755 (trace_state_variables)
12756 New renaming defines.
12757 (struct ipa_sym_addresses): New.
12758 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
12759 (symbol_list): New.
12760 (ipa_sym_addrs): New.
12761 (all_tracepoint_symbols_looked_up): New.
12762 (in_process_agent_loaded): New.
12763 (write_e_ipa_not_loaded): New.
12764 (maybe_write_ipa_not_loaded): New.
12765 (tracepoint_look_up_symbols): New.
12766 (debug_threads) [IN_PROCESS_AGENT]: New.
12767 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
12768 (UNKNOWN_SIDE_EFFECTS): New.
12769 (stop_tracing): New.
12770 (flush_trace_buffer): New.
12771 (stop_tracing_bkpt): New.
12772 (flush_trace_buffer_bkpt): New.
12773 (read_inferior_integer): New.
12774 (read_inferior_uinteger): New.
12775 (read_inferior_data_pointer): New.
12776 (write_inferior_data_pointer): New.
12777 (write_inferior_integer): New.
12778 (write_inferior_uinteger): New.
12779 (struct collect_static_trace_data_action): Delete.
12780 (enum tracepoint_type): New.
12781 (struct tracepoint) <type>: New field `type'.
12782 <actions_str, step_actions, step_actions_str>: Only include in
12783 GDBserver.
12784 <orig_size, obj_addr_on_target, adjusted_insn_addr>
12785 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
12786 (tracepoints): Use IP_AGENT_EXPORT.
12787 (last_tracepoint): Don't include in the IPA.
12788 (stopping_tracepoint): Use IP_AGENT_EXPORT.
12789 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
12790 (alloced_trace_state_variables): New.
12791 (trace_state_variables): Use IP_AGENT_EXPORT.
12792 (traceframe_t): Delete unused variable.
12793 (circular_trace_buffer): Don't include in the IPA.
12794 (trace_buffer_start): Delete.
12795 (struct trace_buffer_control): New.
12796 (trace_buffer_free): Delete.
12797 (struct ipa_trace_buffer_control): New.
12798 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
12799 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
12800 New.
12801 (trace_buffer_ctrl): New.
12802 (TRACE_BUFFER_CTRL_CURR): New.
12803 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
12804 Reimplement as macros.
12805 (trace_buffer_wrap): Delete.
12806 (traceframe_write_count, traceframe_read_count)
12807 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
12808 (struct tracepoint_hit_ctx) <type>: New field.
12809 (struct fast_tracepoint_ctx): New.
12810 (memory_barrier): New.
12811 (cmpxchg): New.
12812 (record_tracepoint_error): Update atomically in the IPA.
12813 (clear_inferior_trace_buffer): New.
12814 (about_to_request_buffer_space): New.
12815 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
12816 updating the same buffer.
12817 (add_tracepoint): Default the tracepoint's type to trap
12818 tracepoint, and orig_size to -1.
12819 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
12820 internal variables.
12821 (create_trace_state_variable): New parameter `gdb'. Handle it.
12822 (clear_installed_tracepoints): Clear fast tracepoint jumps.
12823 (cmd_qtdp): Handle fast tracepoints.
12824 (cmd_qtdv): Adjust.
12825 (max_jump_pad_size): New.
12826 (gdb_jump_pad_head): New.
12827 (get_jump_space_head): New.
12828 (claim_jump_space): New.
12829 (sort_tracepoints): New.
12830 (MAX_JUMP_SIZE): New.
12831 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
12832 IPA.
12833 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
12834 support. Upload fast traceframes, and delete internal IPA
12835 breakpoints.
12836 (stop_tracing_handler): New.
12837 (flush_trace_buffer_handler): New.
12838 (cmd_qtstop): Upload fast tracepoints.
12839 (response_tracepoint): Handle fast tracepoints.
12840 (tracepoint_finished_step): Upload fast traceframes. Set the
12841 tracepoint hit context's tracepoint type.
12842 (handle_tracepoint_bkpts): New.
12843 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
12844 type. Add comment about fast tracepoints.
12845 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
12846 non-existing action_str field.
12847 (get_context_regcache): Handle fast tracepoints.
12848 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
12849 to the regcache.
12850 (fast_tracepoint_from_jump_pad_address): New.
12851 (fast_tracepoint_from_ipa_tpoint_address): New.
12852 (collecting_t): New.
12853 (force_unlock_trace_buffer): New.
12854 (fast_tracepoint_collecting): New.
12855 (collecting): New.
12856 (gdb_collect): New.
12857 (write_inferior_data_ptr): New.
12858 (target_tp_heap): New.
12859 (target_malloc): New.
12860 (download_agent_expr): New.
12861 (UALIGN): New.
12862 (download_tracepoints): New.
12863 (download_trace_state_variables): New.
12864 (upload_fast_traceframes): New.
12865 (IPA_FIRST_TRACEFRAME): New.
12866 (IPA_NEXT_TRACEFRAME_1): New.
12867 (IPA_NEXT_TRACEFRAME): New.
12868 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
12869 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
12870 (gdb_jump_pad_buffer_end): New.
12871 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
12872 (initialize_tracepoint): Adjust.
12873 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
12874 buffer. Initialize the low module.
12875 * utils.c (PREFIX, TOOLNAME): New.
12876 (malloc_failure): Use PREFIX.
12877 (error): In the IPA, an error causes an exit.
12878 (fatal, warning): Use PREFIX.
12879 (internal_error): Use TOOLNAME.
12880 (NUMCELLS): Increase to 10.
12881 * configure, config.in: Regenerate.
12882
12883 2010-06-01 Pedro Alves <pedro@codesourcery.com>
12884
12885 * server.c (handle_query) <qSupported>: Do two passes over the
12886 qSupported string to avoid nesting strtok.
12887
12888 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12889
12890 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
12891 (CDEPS): New.
12892 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
12893 -Wl,--dynamic-list.
12894 * configure: Regenerate.
12895 * proc-service.list: New.
12896
12897 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12898
12899 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
12900 New comment.
12901
12902 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
12903
12904 * gdbreplay.c (remote_open): Check error return from socket() call by
12905 its equality to -1 not by it being negative.
12906 * remote-utils.c (remote_open): Likewise.
12907
12908 2010-05-23 Pedro Alves <pedro@codesourcery.com>
12909
12910 * config.h: Regenerate.
12911
12912 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
12913
12914 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
12915 doesn't provide PTRACE_GET_THREAD_AREA.
12916
12917 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
12918
12919 * linux-m68k-low.c: Include <asm/ptrace.h>
12920 (ps_get_thread_area): Implement.
12921
12922 2010-05-03 Doug Evans <dje@google.com>
12923
12924 * event-loop.c (struct callback_event): New struct.
12925 (callback_list): New global.
12926 (append_callback_event, delete_callback_event): New functions.
12927 (process_callback): New function.
12928 (start_event_loop): Call it.
12929 * remote-utils.c (NOT_SCHEDULED): Define.
12930 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
12931 moved out of readchar.
12932 (readchar): Rewrite. Call reschedule before returning.
12933 (reset_readchar): New function.
12934 (remote_close): Call it.
12935 (process_remaining, reschedule): New functions.
12936 * server.h (callback_handler_func): New typedef.
12937 (append_callback_event, delete_callback_event): Declare.
12938
12939 2010-05-03 Pedro Alves <pedro@codesourcery.com>
12940
12941 * proc-service.c (ps_pglobal_lookup): Use
12942 thread_db_look_up_one_symbol.
12943 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
12944 parameter. Use it instead of all_symbols_looked_up.
12945 * server.h (struct process_info) <all_symbols_looked_up>: Delete
12946 field.
12947 (all_symbols_looked_up): Don't declare.
12948 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
12949 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
12950 field.
12951 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
12952 Set all_symbols_looked_up here.
12953 (thread_db_look_up_one_symbol): New.
12954 (thread_db_get_tls_address): Adjust.
12955 (thread_db_load_search, try_thread_db_load_1): Always allocate the
12956 thread_db object on the heap, and tentatively set it in the
12957 process structure.
12958 (thread_db_init): Don't set all_symbols_looked_up here.
12959 * linux-low.h (thread_db_look_up_one_symbol): Declare.
12960
12961 2010-05-03 Pedro Alves <pedro@codesourcery.com>
12962
12963 * linux-low.c (linux_kill, linux_detach): Adjust.
12964 (status_pending_p_callback): Remove redundant statement. Check
12965 for !TARGET_WAITIKIND_IGNORE, instead of
12966 TARGET_WAITKIND_STOPPED.
12967 (handle_tracepoints): Make sure LWP is locked. Adjust.
12968 (linux_wait_for_event_1): Adjust.
12969 (linux_cancel_breakpoints): New.
12970 (unsuspend_one_lwp): New.
12971 (unsuspend_all_lwps): New.
12972 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
12973 (send_sigstop_callback): Change return type to int, add new
12974 `except' parameter and handle it.
12975 (suspend_and_send_sigstop_callback): New.
12976 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
12977 pass them down. If SUSPEND, also increment the lwp's suspend
12978 count.
12979 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
12980 (need_step_over_p): Don't consider suspended LWPs.
12981 (start_step_over): Adjust.
12982 (proceed_one_lwp): Change return type to int, add new `except'
12983 parameter and handle it.
12984 (unsuspend_and_proceed_one_lwp): New.
12985 (proceed_all_lwps): Use find_inferior instead of
12986 for_each_inferior.
12987 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
12988 also decrement the suspend count of LWPs. Pass `except' down,
12989 instead of hacking its suspend count.
12990 (linux_pause_all): Add `freeze' parameter. Adjust.
12991 (linux_unpause_all): New.
12992 (linux_target_ops): Install linux_unpause_all.
12993 * server.c (handle_status): Adjust.
12994 * target.h (struct target_ops): New fields `unpause_all' and
12995 `cancel_breakpoints'. Add new parameter to `pause_all'.
12996 (pause_all): Add new `freeze' parameter.
12997 (unpause_all): New.
12998 (cancel_breakpoints): New.
12999 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
13000 cancel breakpoints.
13001 (cmd_qtstart): Pause threads.
13002 (stop_tracing): Pause threads, and cancel breakpoints.
13003 * win32-low.c (win32_target_ops): Adjust.
13004
13005 2010-05-03 Pedro Alves <pedro@codesourcery.com>
13006
13007 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
13008 the inferior right away from here...
13009 (linux_wait_1): ... to here, and adjust to check the thread's
13010 last_resume_kind instead of the lwp's step or stop_expected flags.
13011
13012 2010-05-02 Pedro Alves <pedro@codesourcery.com>
13013
13014 * README: Use consistent `GDB' and `GDBserver' spellings.
13015
13016 2010-05-02 Pedro Alves <pedro@codesourcery.com>
13017
13018 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
13019 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
13020 (linux_detach_one_lwp): Assume the lwp is stopped.
13021 (any_thread_of): Delete.
13022 (linux_detach): Stop all lwps here. Don't blindly delete all
13023 breakpoints.
13024 (delete_lwp_callback): New.
13025 (linux_mourn): Delete all lwps of the process that is gone.
13026 (linux_wait_1): Don't delete the last lwp of the process here.
13027 * mem-break.h (mark_breakpoints_out): Declare.
13028 * mem-break.c (mark_breakpoints_out): New.
13029 (free_all_breakpoints): Use it.
13030 * server.c (handle_target_event): If the process is gone, mark
13031 breakpoints out.
13032 * thread-db.c (struct thread_db) <create_bp>: New field.
13033 (thread_db_enable_reporting): Fix prototype. Store a thread event
13034 breakpoint reference in the thread_db struct.
13035 (thread_db_load_search): Clear the thread_db object.
13036 (try_thread_db_load_1): Ditto.
13037 (switch_to_process): New.
13038 (disable_thread_event_reporting): Use it.
13039 (remove_thread_event_breakpoints): New.
13040 (thread_db_detach, thread_db_mourn): Use it.
13041
13042 2010-05-01 Pedro Alves <pedro@codesourcery.com>
13043
13044 * linux-low.c (linux_enable_event_reporting): New.
13045 (linux_wait_for_event_1, handle_extended_wait): Use it.
13046
13047 2010-04-30 Pedro Alves <pedro@codesourcery.com>
13048
13049 * linux-low.c (linux_kill_one_lwp, linux_kill)
13050 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
13051 (send_sigstop): Take an lwp_info as parameter instead. Queue a
13052 SIGSTOP even if the LWP is stopped.
13053 (send_sigstop_callback): New.
13054 (stop_all_lwps): Use send_sigstop_callback instead.
13055 (linux_resume_one_thread): Adjust.
13056 (proceed_one_lwp): Still proceed an LWP that the client has
13057 requested to stop, if we haven't reported it as stopped yet. Make
13058 sure that LWPs the client want stopped, have a pending SIGSTOP.
13059
13060 2010-04-26 Doug Evans <dje@google.com>
13061
13062 * server.c (handle_general_set): Make static.
13063
13064 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
13065 Print received char after testing for error/eof instead of before.
13066 (input_interrupt): Tweak comment.
13067
13068 2010-04-23 Doug Evans <dje@google.com>
13069
13070 * server.c (start_inferior): Print inferior argv if --debug.
13071
13072 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
13073
13074 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
13075 * nto-x86-low.c: Include server.h
13076
13077 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
13078
13079 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
13080 be consistent with other sources of this directory.
13081 (init_registers_amd64): Correct name of source file of this function
13082 in the comment.
13083
13084 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13085
13086 * configure.srv (x86_64-*-mingw*): New configuration for Windows
13087 64-bit executables.
13088
13089 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13090
13091 * win32-i386-low.c: Add 64-bit support.
13092 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
13093 (init_registers_amd64): Declare.
13094 (mappings): Add 64-bit version of array.
13095 (init_windows_x86): New function.
13096 (the_low_target): Change init_arch field to init_windows_x86.
13097
13098 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13099
13100 * win32-low.c: Adapt to support also 64-bit architecture.
13101 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
13102 (get_image_name): Use SIZE_T type for local variable `done'.
13103 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
13104 (toolhelp_get_dll_name): Idem.
13105 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
13106 Use uintptr_t typecast to avoid warning.
13107 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
13108 (handle_exception): Use phex_nz to avoid warning.
13109 (win32_wait): Remove unused local variable `process'.
13110
13111 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13112
13113 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
13114 `amd64-avx.o'.
13115
13116 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
13117
13118 * configure.ac: Use `ws2_32' library for srv_mingw.
13119 * configure: Regenerate.
13120 * gdbreplay.c: Include winsock2.h instead of winsock.h.
13121 * remote-utils.c: Likewise.
13122
13123 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
13124
13125 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
13126 if __x86_64__ is defined.
13127
13128 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
13129
13130 * configure: Regenerate.
13131
13132 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
13133
13134 * server.c (handle_query): Handle 'qGetTIBAddr' query.
13135 * target.h (target_ops): New get_tib_address field.
13136 * win32-low.h (win32_thread_info): Add thread_local_base field.
13137 * win32-low.c (child_add_thread): Add tlb argument.
13138 Set thread_local_base field to TLB.
13139 (get_child_debug_event): Adapt to child_add_thread change.
13140 (win32_get_tib_address): New function.
13141 (win32_target_ops): Set get_tib_address field to
13142 win32_get_tib_address.
13143 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
13144
13145 2010-04-12 Pedro Alves <pedro@codesourcery.com>
13146
13147 * linux-low.c (linux_mourn): Also remove the process.
13148 * server.c (handle_target_event): Don't remove the process here.
13149 * nto-low.c (nto_mourn): New.
13150 (nto_target_ops): Install it.
13151 * spu-low.c (spu_mourn): New.
13152 (spu_target_ops): Install it.
13153 * win32-low.c (win32_mourn): New.
13154 (win32_target_ops): Install it.
13155
13156 2010-04-12 Pedro Alves <pedro@codesourcery.com>
13157
13158 * server.h (buffer_xml_printf): Remove redundant `;'.
13159
13160 2010-04-12 Pedro Alves <pedro@codesourcery.com>
13161
13162 * regcache.c (set_register_cache): Invalidate regcaches before
13163 changing the register cache layout.
13164 (regcache_invalidate_one): Allow a NULL regcache.
13165 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
13166 regcaches before changing the register cache layout or the target
13167 regsets.
13168
13169 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
13170
13171 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
13172 variable warning on Linux/x86-64.
13173
13174 2010-04-11 Pedro Alves <pedro@codesourcery.com>
13175
13176 GDBserver disconnected tracing support.
13177
13178 * linux-low.c (linux_remove_process): Delete.
13179 (add_lwp): Don't set last_resume_kind here.
13180 (linux_kill): Use `mourn'.
13181 (linux_detach): Use `thread_db_detach', and `mourn'.
13182 (linux_mourn): New.
13183 (linux_attach_lwp_1): Adjust comment.
13184 (linux_attach): last_resume_kind moved the thread_info; adjust.
13185 (status_pending_p_callback): Adjust.
13186 (linux_wait_for_event_1): Adjust.
13187 (count_events_callback, select_singlestep_lwp_callback)
13188 (select_event_lwp_callback, cancel_breakpoints_callback)
13189 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
13190 (proceed_one_lwp): Adjust.
13191 (linux_async): Add debug output.
13192 (linux_thread_stopped): New.
13193 (linux_pause_all): New.
13194 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
13195 linux_pause_all.
13196 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
13197 (thread_db_free): Delete declaration.
13198 (thread_db_detach, thread_db_mourn): Declare.
13199 * thread-db.c (thread_db_init): Use thread_db_mourn.
13200 (thread_db_free): Delete, split in two.
13201 (disable_thread_event_reporting): New.
13202 (thread_db_detach): New.
13203 (thread_db_mourn): New.
13204
13205 * server.h (struct thread_info) <last_resume_kind>: New field.
13206 <attached>: Add comment.
13207 <gdb_detached>: New field.
13208 (handler_func): Change return type to int.
13209 (handle_serial_event, handle_target_event): Ditto.
13210 (gdb_connected): Declare.
13211 (tracing): Delete.
13212 (disconnected_tracing): Declare.
13213 (stop_tracing): Declare.
13214
13215 * server.c (handle_query) <qSupported>: Report support for
13216 disconnected tracing.
13217 (queue_stop_reply_callback): Account for running threads.
13218 (gdb_wants_thread_stopped): New.
13219 (gdb_wants_all_threads_stopped): New.
13220 (gdb_reattached_process): New.
13221 (handle_status): Clear the `gdb_detached' flag of all processes.
13222 In all-stop, stop all threads.
13223 (main): Be sure to leave tfind mode. Handle disconnected tracing.
13224 (process_serial_event): If the remote connection breaks, or if an
13225 exit was forced with "monitor exit", force an event loop exit.
13226 Handle disconnected tracing on detach.
13227 (handle_serial_event): Adjust.
13228 (handle_target_event): If GDB isn't connected, forward events back
13229 to the inferior, unless the last process exited, in which case,
13230 exit gdbserver. Adjust interface.
13231
13232 * remote-utils.c (remote_open): Don't block in accept. Instead
13233 register an event loop source on the listen socket file
13234 descriptor. Refactor bits into ...
13235 (listen_desc): ... this new global.
13236 (gdb_connected): ... this new function.
13237 (enable_async_notification): ... this new function.
13238 (handle_accept_event): ... this new function.
13239 (remote_close): Clear remote_desc.
13240
13241 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
13242
13243 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
13244 New fields.
13245 (mourn_inferior): Define.
13246 (target_process_qsupported): Avoid the dangling else problem.
13247 (thread_stopped): Define.
13248 (pause_all): Define.
13249 (target_waitstatus_to_string): Declare.
13250 * target.c (target_waitstatus_to_string): New.
13251
13252 * tracepoint.c (tracing): Make extern.
13253 (disconnected_tracing): New.
13254 (stop_tracing): Make extern. Handle tracing stops due to GDB
13255 disconnecting.
13256 (cmd_qtdisconnected): New.
13257 (cmd_qtstatus): Report disconnected tracing status in trace reply.
13258 (handle_tracepoint_general_set): Handle QTDisconnected.
13259
13260 * event-loop.c (event_handler_func): Change return type to int.
13261 (process_event): Bail out if the event handler wants the event
13262 loop to stop.
13263 (handle_file_event): Ditto.
13264 (start_event_loop): Bail out if the event handler wants the event
13265 loop to stop.
13266
13267 * nto-low.c (nto_target_ops): Adjust.
13268 * spu-low.c (spu_wait): Don't remove the process here.
13269 (spu_target_ops): Adjust.
13270 * win32-low.c (win32_wait): Don't remove the process here.
13271 (win32_target_ops): Adjust.
13272
13273 2010-04-11 Pedro Alves <pedro@codesourcery.com>
13274
13275 * regcache.c (realloc_register_cache): Invalidate inferior's
13276 regcache before recreating it.
13277
13278 2010-04-09 Pedro Alves <pedro@codesourcery.com>
13279
13280 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
13281
13282 2010-04-09 Stan Shebs <stan@codesourcery.com>
13283 Pedro Alves <pedro@codesourcery.com>
13284
13285 * server.h (LONGEST): New.
13286 (struct thread_info) <while_stepping>: New field.
13287 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
13288 Declare.
13289 (initialize_tracepoint, handle_tracepoint_general_set)
13290 (handle_tracepoint_query, tracepoint_finished_step)
13291 (tracepoint_was_hit, release_while_stepping_state_list):
13292 (current_traceframe): Declare.
13293 * server.c (handle_general_set): Handle tracepoint packets.
13294 (read_memory): New.
13295 (write_memory): New.
13296 (handle_search_memory_1): Use read_memory.
13297 (handle_query): Report support for conditional tracepoints, trace
13298 state variables, and tracepoint sources. Handle tracepoint
13299 queries.
13300 (main): Initialize the tracepoints module.
13301 (process_serial_event): Handle traceframe reads/writes.
13302
13303 * linux-low.c (handle_tracepoints): New.
13304 (linux_wait_1): Call it.
13305 (linux_resume_one_lwp): Handle while-stepping.
13306 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
13307 (linux_target_ops): Install them.
13308 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
13309 New field.
13310 * linux-x86-low.c (x86_supports_tracepoints): New.
13311 (the_low_target). Install it.
13312
13313 * mem-break.h (delete_breakpoint): Declare.
13314 * mem-break.c (delete_breakpoint): Make external.
13315
13316 * target.h (struct target_ops): Add `supports_tracepoints',
13317 `read_pc', and `write_pc' fields.
13318 (target_supports_tracepoints): Define.
13319 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
13320 (phex_nz): New.
13321
13322 * regcache.h (struct regcache) <registers_owned>: New field.
13323 (init_register_cache, regcache_cpy): Declare.
13324 (regcache_read_pc, regcache_write_pc): Declare.
13325 (register_cache_size): Declare.
13326 (supply_regblock): Declare.
13327 * regcache.c (init_register_cache): New.
13328 (new_register_cache): Use it.
13329 (regcache_cpy): New.
13330 (register_cache_size): New.
13331 (supply_regblock): New.
13332 (regcache_read_pc, regcache_write_pc): New.
13333
13334 * tracepoint.c: New.
13335
13336 * Makefile.in (OBS): Add tracepoint.o.
13337 (tracepoint.o): New rule.
13338
13339 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
13340
13341 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
13342 (i386-mmx.o): New.
13343 (i386-mmx.c): Likewise.
13344 (i386-mmx-linux.o): Likewise.
13345 (i386-mmx-linux.c): Likewise.
13346
13347 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
13348 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
13349 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
13350 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
13351
13352 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
13353 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
13354 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
13355
13356 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
13357
13358 * Makefile.in (clean): Updated.
13359 (i386-avx.o): New.
13360 (i386-avx.c): Likewise.
13361 (i386-avx-linux.o): Likewise.
13362 (i386-avx-linux.c): Likewise.
13363 (amd64-avx.o): Likewise.
13364 (amd64-avx.c): Likewise.
13365 (amd64-avx-linux.o): Likewise.
13366 (amd64-avx-linux.c): Likewise.
13367
13368 * configure.srv (srv_i386_regobj): Add i386-avx.o.
13369 (srv_i386_linux_regobj): Add i386-avx-linux.o.
13370 (srv_amd64_regobj): Add amd64-avx.o.
13371 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
13372 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
13373 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
13374 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
13375 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
13376 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
13377 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
13378
13379 * i387-fp.c: Include "i386-xstate.h".
13380 (i387_xsave): New.
13381 (i387_cache_to_xsave): Likewise.
13382 (i387_xsave_to_cache): Likewise.
13383 (x86_xcr0): Likewise.
13384
13385 * i387-fp.h (i387_cache_to_xsave): Likewise.
13386 (i387_xsave_to_cache): Likewise.
13387 (x86_xcr0): Likewise.
13388
13389 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
13390 * linux-crisv32-low.c (target_regsets): Likewise.
13391 * linux-m68k-low.c (target_regsets): Likewise.
13392 * linux-mips-low.c (target_regsets): Likewise.
13393 * linux-ppc-low.c (target_regsets): Likewise.
13394 * linux-s390-low.c (target_regsets): Likewise.
13395 * linux-sh-low.c (target_regsets): Likewise.
13396 * linux-sparc-low.c (target_regsets): Likewise.
13397 * linux-xtensa-low.c (target_regsets): Likewise.
13398
13399 * linux-low.c: Include <sys/uio.h>.
13400 (regsets_fetch_inferior_registers): Support nt_type.
13401 (regsets_store_inferior_registers): Likewise.
13402 (linux_process_qsupported): New.
13403 (linux_target_ops): Add linux_process_qsupported.
13404
13405 * linux-low.h (regset_info): Add nt_type.
13406 (linux_target_ops): Add process_qsupported.
13407
13408 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
13409 and <sys/uio.h>.
13410 (init_registers_i386_avx_linux): New.
13411 (init_registers_amd64_avx_linux): Likewise.
13412 (xmltarget_i386_linux_no_xml): Likewise.
13413 (xmltarget_amd64_linux_no_xml): Likewise.
13414 (PTRACE_GETREGSET): Likewise.
13415 (PTRACE_SETREGSET): Likewise.
13416 (x86_fill_xstateregset): Likewise.
13417 (x86_store_xstateregset): Likewise.
13418 (use_xml): Likewise.
13419 (x86_linux_update_xmltarget): Likewise.
13420 (x86_linux_process_qsupported): Likewise.
13421 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
13422 (x86_arch_setup): Don't call init_registers_amd64_linux nor
13423 init_registers_i386_linux here. Call
13424 x86_linux_update_xmltarget.
13425 (the_low_target): Add x86_linux_process_qsupported.
13426
13427 * server.c (handle_query): Call target_process_qsupported.
13428
13429 * target.h (target_ops): Add process_qsupported.
13430 (target_process_qsupported): New.
13431
13432 2010-04-03 Pedro Alves <pedro@codesourcery.com>
13433
13434 * inferiors.c (add_thread): Set last_status kind to
13435 TARGET_WAITKIND_IGNORE.
13436 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
13437 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
13438 (linux_wait_1): Move `thread' local definition to block that uses
13439 it. Don't NULL initialize `event_child'.
13440 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
13441 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
13442 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
13443
13444 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13445
13446 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
13447 an extended waitstatus, or by a watchpoint.
13448 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
13449 thread was stepping or has been stopped by a watchpoint.
13450
13451 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13452
13453 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
13454 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
13455 of another, then delete the previous, and validate all
13456 breakpoints.
13457 (validate_inserted_breakpoint): New.
13458 (delete_disabled_breakpoints): New.
13459 (validate_breakpoints): New.
13460 (check_mem_read): Validate breakpoints before trusting their
13461 shadow. Delete disabled breakpoints.
13462 (check_mem_write): Validate breakpoints before trusting they
13463 should be inserted. Delete disabled breakpoints.
13464 * mem-break.h (validate_breakpoints):
13465 * server.c (handle_query): Validate breakpoints when we see a
13466 qSymbol query.
13467
13468 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13469
13470 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
13471 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
13472 if we could tell there's a GDB breakpoint at stop_pc.
13473 (need_step_over_p): Don't do a step over if we find a GDB
13474 breakpoint at the resume PC.
13475
13476 * mem-break.c (struct raw_breakpoint): New.
13477 (enum bkpt_type): New type `gdb_breakpoint'.
13478 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
13479 fields. New field `raw'.
13480 (find_raw_breakpoint_at): New.
13481 (set_raw_breakpoint_at): Handle refcounting. Create a raw
13482 breakpoint instead.
13483 (set_breakpoint_at): Adjust.
13484 (delete_raw_breakpoint): New.
13485 (release_breakpoint): New.
13486 (delete_breakpoint): Rename to...
13487 (delete_breakpoint_1): ... this. Add proc parameter. Use
13488 release_breakpoint. Return ENOENT.
13489 (delete_breakpoint): Reimplement.
13490 (find_breakpoint_at): Delete.
13491 (find_gdb_breakpoint_at): New.
13492 (delete_breakpoint_at): Delete.
13493 (set_gdb_breakpoint_at): New.
13494 (delete_gdb_breakpoint_at): New.
13495 (gdb_breakpoint_here): New.
13496 (set_reinsert_breakpoint): Use release_breakpoint.
13497 (uninsert_breakpoint): Rename to ...
13498 (uninsert_raw_breakpoint): ... this.
13499 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
13500 (reinsert_raw_breakpoint): Change parameter type to
13501 raw_breakpoint.
13502 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
13503 instead.
13504 (check_breakpoints): Adjust. Use release_breakpoint.
13505 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
13506 (breakpoint_inserted_here): Ditto.
13507 (check_mem_read): Adjust to iterate over raw breakpoints instead.
13508 Don't trust the breakpoint's shadow if it is not inserted.
13509 (check_mem_write): Adjust to iterate over raw breakpoints instead.
13510 (delete_all_breakpoints): Adjust.
13511 (free_all_breakpoints): Mark all breakpoints as uninserted, and
13512 use delete_breakpoint_1.
13513
13514 * mem-break.h (breakpoints_supported): Delete declaration.
13515 (set_gdb_breakpoint_at): Declare.
13516 (gdb_breakpoint_here): Declare.
13517 (delete_breakpoint_at): Delete.
13518 (delete_gdb_breakpoint_at): Declare.
13519
13520 * server.h (struct raw_breakpoint): Forward declare.
13521 (struct process_info): New field `raw_breakpoints'.
13522
13523 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
13524 breakpoints.
13525
13526 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13527
13528 * linux-low.c (status_pending_p_callback): Fix comment.
13529 (linux_wait_for_event_1): Move most of the internal breakpoint
13530 handling from here...
13531 (linux_wait_1): ... to here.
13532 (count_events_callback): New.
13533 (select_singlestep_lwp_callback): New.
13534 (select_event_lwp_callback): New.
13535 (cancel_breakpoints_callback): New.
13536 (select_event_lwp): New.
13537 (linux_wait_1): Simplify internal breakpoint handling. Give equal
13538 priority to all LWPs that have had events that should be reported
13539 to the client. Cancel breakpoints when about to reporting the
13540 event to the client, not while stopping lwps. No longer cancel
13541 finished single-steps here.
13542 (cancel_finished_single_step): Delete.
13543 (cancel_finished_single_steps): Delete.
13544
13545 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13546
13547 * mem-break.c (enum bkpt_type): New.
13548 (struct breakpoint): New field `type'.
13549 (set_breakpoint_at): Change return type to struct breakpoint
13550 pointer. Set type to `other_breakpoint' by default.
13551 (delete_breakpoint): Rewrite, supporting more than one breakpoint
13552 in the breakpoint list.
13553 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
13554 (reinsert_breakpoint): Rename to ...
13555 (reinsert_raw_breakpoint): ... this.
13556 (reinsert_breakpoints_at): Adjust.
13557 * mem-break.h (struct breakpoint): Declare.
13558 (set_breakpoint_at): Change return type to struct breakpoint
13559 pointer.
13560
13561 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13562
13563 * server.c (handle_query): Assign, not compare.
13564
13565 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13566
13567 Teach linux gdbserver to step-over-breakpoints.
13568
13569 * linux-low.c (can_hardware_single_step): New.
13570 (supports_breakpoints): New.
13571 (handle_extended_wait): If stopping threads, read the stop pc of
13572 the new cloned LWP.
13573 (get_pc): New.
13574 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
13575 low target doesn't support retrieving the PC.
13576 (add_lwp): Set last_resume_kind to resume_continue.
13577 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
13578 (linux_attach): Don't clear stop_expected. Set the lwp's
13579 last_resume_kind to resume_stop.
13580 (linux_detach_one_lwp): Don't check for removed breakpoints.
13581 (check_removed_breakpoint): Delete.
13582 (status_pending_p): Rename to ...
13583 (status_pending_p_callback): ... this. Don't check for removed
13584 breakpoints. Don't consider threads that are stopped from GDB's
13585 perspective.
13586 (linux_wait_for_lwp): Always read the stop_pc here.
13587 (cancel_breakpoint): New.
13588 (step_over_bkpt): New global.
13589 (linux_wait_for_event_1): Implement stepping over breakpoints.
13590 (gdb_wants_lwp_stopped): New.
13591 (gdb_wants_all_stopped): New.
13592 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
13593 single-step traps here. Store the thread's last reported target
13594 wait status.
13595 (send_sigstop): Don't clear stop_expected. Always set it,
13596 instead.
13597 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
13598 (cancel_finished_single_step): New.
13599 (cancel_finished_single_steps): New.
13600 (wait_for_sigstop): Don't cancel finished single-step traps here.
13601 (linux_resume_one_lwp): Don't check for removed breakpoints.
13602 Don't set `step' on non-hardware step archs.
13603 (linux_set_resume_request): Ignore resume_stop requests if already
13604 stopping or stopped. Set the lwp's last_resume_kind.
13605 (resume_status_pending_p): Don't check for removed breakpoints.
13606 (need_step_over_p): New.
13607 (start_step_over): New.
13608 (finish_step_over): New.
13609 (linux_resume_one_thread): Always queue a sigstop for resume_stop
13610 requests. Clear the thread's last reported target waitstatus.
13611 Don't use the `suspended' flag. Don't consider pending breakpoints.
13612 (linux_resume): Start a step-over if necessary.
13613 (proceed_one_lwp): New.
13614 (proceed_all_lwps): New.
13615 (unstop_all_lwps): New.
13616 * linux-low.h (struct lwp_info): Rewrite comment for the
13617 `suspended' flag. Add the `stop_pc' field. Delete the
13618 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
13619 Add `'last_resume_kind' and `need_step_over' fields.
13620 * inferiors.c (struct thread_info): Delete, moved elsewhere.
13621 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
13622 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
13623 (set_raw_breakpoint_at): New.
13624 (set_breakpoint_at): Rewrite to use it.
13625 (reinsert_breakpoint_handler): Delete.
13626 (set_reinsert_breakpoint): New.
13627 (reinsert_breakpoint_by_bp): Delete.
13628 (delete_reinsert_breakpoints): New.
13629 (uninsert_breakpoint): Rewrite.
13630 (uninsert_breakpoints_at): New.
13631 (reinsert_breakpoint): Rewrite.
13632 (reinsert_breakpoints_at): New.
13633 (check_breakpoints): Rewrite.
13634 (breakpoint_here): New.
13635 (breakpoint_inserted_here): New.
13636 (check_mem_read): Adjust.
13637 * mem-break.h (breakpoints_supported, breakpoint_here)
13638 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
13639 (reinsert_breakpoint_by_bp): Delete declaration.
13640 (delete_reinsert_breakpoints): Declare.
13641 (reinsert_breakpoint): Delete declaration.
13642 (reinsert_breakpoints_at): Declare.
13643 (uninsert_breakpoint): Delete declaration.
13644 (uninsert_breakpoints_at): Declare.
13645 (check_breakpoints): Adjust prototype.
13646 * server.h: Adjust include order.
13647 (struct thread_info): Declare here. Add a `last_status' field.
13648
13649 2010-03-23 Michael Snyder <msnyder@vmware.com>
13650
13651 * server.c (crc32): New function.
13652 (handle_query): Add handling for 'qCRC:' request.
13653
13654 2010-03-23 Pedro Alves <pedro@codesourcery.com>
13655
13656 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
13657 lwp had been stopped by a watchpoint.
13658
13659 2010-03-16 Pedro Alves <pedro@codesourcery.com>
13660
13661 * server.h (internal_error): Declare.
13662 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
13663 * utils.c (internal_error): New function.
13664
13665 2010-03-15 Andreas Schwab <schwab@redhat.com>
13666
13667 * configure.srv: Fix typo setting srv_regobj.
13668
13669 2010-03-15 Pedro Alves <pedro@codesourcery.com>
13670
13671 * linux-low.c (fetch_register): Avoid passing a non string literal
13672 format to `error'.
13673 (usr_store_inferior_registers): Ditto.
13674
13675 2010-03-14 Pedro Alves <pedro@codesourcery.com>
13676
13677 * linux-low.c (linux_write_memory): Bail out early if peeking
13678 memory failed.
13679
13680 2010-03-14 Pedro Alves <pedro@codesourcery.com>
13681
13682 * linux-low.h (struct lwp_info): New fields
13683 `stopped_by_watchpoint' and `stopped_data_address'.
13684 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
13685 here, and cache them in the lwp object.
13686 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
13687 directly.
13688 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
13689 field.
13690 (linux_stopped_by_watchpoint): Rewrite.
13691 (linux_stopped_data_address): Rewrite.
13692
13693 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
13694
13695 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
13696 switching the current inferior, not before.
13697
13698 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
13699
13700 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
13701 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
13702 i386-linux.c and amd64-linux.c.
13703 (reg-i386.o): Removed.
13704 (reg-i386.c): Likewise.
13705 (reg-i386-linux.o): Likewise.
13706 (reg-i386-linux.c): Likewise.
13707 (reg-x86-64.o): Likewise.
13708 (reg-x86-64.c): Likewise.
13709 (reg-x86-64-linux.o): Likewise.
13710 (reg-x86-64-linux.c): Likewise.
13711 (i386.o): New.
13712 (i386.c): Likewise.
13713 (i386-linux.o): Likewise.
13714 (i386-linux.c): Likewise.
13715 (amd64.o): Likewise.
13716 (amd64.c): Likewise.
13717 (amd64-linux.o): Likewise.
13718 (amd64-linux.c): Likewise.
13719
13720 * configure.srv (srv_i386_regobj): New.
13721 (srv_i386_linux_regobj): Likewise.
13722 (srv_amd64_regobj): Likewise.
13723 (srv_amd64_linux_regobj): Likewise.
13724 (srv_i386_32bit_xmlfiles): Likewise.
13725 (srv_i386_64bit_xmlfiles): Likewise.
13726 (srv_i386_xmlfiles): Likewise.
13727 (srv_amd64_xmlfiles): Likewise.
13728 (srv_i386_linux_xmlfiles): Likewise.
13729 (srv_amd64_linux_xmlfiles): Likewise.
13730 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
13731 srv_xmlfiles to $srv_i386_xmlfiles.
13732 (i[34567]86-*-mingw32ce*): Likewise.
13733 (i[34567]86-*-mingw*): Likewise.
13734 (i[34567]86-*-nto*): Likewise.
13735 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
13736 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
13737 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
13738 (x86_64-*-linux*): Likewise.
13739
13740 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
13741 (init_registers_amd64_linux): New.
13742 (x86_arch_setup): Replace init_registers_x86_64_linux with
13743 init_registers_amd64_linux.
13744
13745 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
13746
13747 * configure.ac: Check for libdl. If it is not available link against
13748 static libthread_db.
13749 * configure: Regenerate.
13750
13751 2010-02-22 Pedro Alves <pedro@codesourcery.com>
13752
13753 PR9605
13754
13755 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
13756 handing a read watchpoint.
13757 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
13758
13759 2010-02-12 Doug Evans <dje@google.com>
13760
13761 * linux-low.c (linux_supports_tracefork_flag): Document.
13762 (linux_look_up_symbols): Add comment.
13763
13764 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
13765
13766 * regcache.c (supply_register): Clear regcache if buf is NULL.
13767
13768 2010-02-02 Nicolas Roche <roche@sourceware.org>
13769 Joel Brobecker <brobecker@adacore.com>
13770
13771 * inferiors.c (find_inferior): Add function documentation.
13772 (unloaded_dll): Handle the case where the unloaded dll has not
13773 been previously registered in the dll list.
13774
13775 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
13776
13777 * linux-arm-low.c (thumb_breakpoint_len): Delete.
13778 (thumb2_breakpoint): New.
13779 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
13780
13781 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
13782
13783 * linux-low.c (get_stop_pc): Check for SIGTRAP.
13784 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
13785 breakpoints.
13786
13787 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13788
13789 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
13790
13791 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13792
13793 * linux-s390-low.c (s390_collect_ptrace_register)
13794 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
13795
13796 2010-01-21 Doug Evans <dje@google.com>
13797
13798 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
13799 (PTRACE_ARG4_TYPE): New macro.
13800 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
13801 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
13802 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
13803 (usr_store_inferior_registers): Ditto.
13804 (linux_read_memory, linux_write_memory): Ditto.
13805 (linux_test_for_tracefork): Ditto.
13806
13807 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
13808 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
13809
13810 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13811
13812 * proc-service.c (ps_lgetregs): Don't refetch registers from the
13813 target.
13814
13815 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13816
13817 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
13818 prototype to take a regcache. Adjust.
13819
13820 2010-01-20 Pedro Alves <pedro@codesourcery.com>
13821
13822 * regcache.h (struct thread_info): Forward declare.
13823 (struct regcache): New.
13824 (new_register_cache): Adjust prototype.
13825 (get_thread_regcache): Declare.
13826 (free_register_cache): Adjust prototype.
13827 (registers_to_string, registers_from_string): Ditto.
13828 (supply_register, supply_register_by_name, collect_register)
13829 (collect_register_as_string, collect_register_by_name): Ditto.
13830 * regcache.c (struct inferior_regcache_data): Delete.
13831 (get_regcache): Rename to ...
13832 (get_thread_regcache): ... this. Adjust. Switch inferior before
13833 fetching registers.
13834 (regcache_invalidate_one): Adjust.
13835 (regcache_invalidate): Fix prototype.
13836 (new_register_cache): Return the new register cache.
13837 (free_register_cache): Change prototype.
13838 (realloc_register_cache): Adjust.
13839 (registers_to_string): Change prototype to take a regcache. Adjust.
13840 (registers_from_string): Ditto.
13841 (register_data): Ditto.
13842 (supply_register): Ditto.
13843 (supply_register_by_name): Ditto.
13844 (collect_register): Ditto.
13845 (collect_register_as_string): Ditto.
13846 (collect_register_by_name): Ditto.
13847 * server.c (process_serial_event): Adjust.
13848 * linux-low.h (regset_fill_func, regset_store_func): Change
13849 prototype.
13850 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
13851 Change prototype.
13852 * linux-low.c (get_stop_pc): Adjust.
13853 (check_removed_breakpoint): Adjust.
13854 (linux_wait_for_event): Adjust.
13855 (linux_resume_one_lwp): Adjust.
13856 (fetch_register): Add regcache parameter. Adjust.
13857 (usr_store_inferior_registers): Ditto.
13858 (regsets_fetch_inferior_registers): Ditto.
13859 (regsets_store_inferior_registers): Ditto.
13860 (linux_fetch_registers, linux_store_registers): Ditto.
13861 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
13862 regcache. Adjust.
13863 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
13864 Ditto.
13865 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
13866 prototype to take a regcache.
13867 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
13868 * remote-utils.c (convert_ascii_to_int, outreg)
13869 (prepare_resume_reply): Change prototype to take a regcache.
13870 Adjust.
13871 * target.h (struct target_ops) <fetch_registers, store_registers>:
13872 Change prototype to take a regcache.
13873 (fetch_inferior_registers, store_inferior_registers): Change
13874 prototype to take a regcache. Adjust.
13875 * proc-service.c (ps_lgetregs): Adjust.
13876 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
13877 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
13878 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
13879 take a regcache. Adjust.
13880 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
13881 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
13882 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
13883 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
13884 * linux-cris-low.c (cris_get_pc, cris_set_pc)
13885 (cris_cannot_fetch_register):
13886 (cris_breakpoint_at): Change prototype to take a regcache.
13887 Adjust.
13888 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
13889 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
13890 to take a regcache. Adjust.
13891 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
13892 Adjust.
13893 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
13894 take a regcache. Adjust.
13895 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
13896 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
13897 (m68k_set_pc): Change prototype to take a regcache. Adjust.
13898 * linux-mips-low.c (mips_get_pc):
13899 (mips_set_pc): Change prototype to take a regcache. Adjust.
13900 (mips_reinsert_addr): Adjust.
13901 (mips_collect_register): Change prototype to take a regcache.
13902 Adjust.
13903 (mips_supply_register):
13904 (mips_collect_register_32bit, mips_supply_register_32bit)
13905 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
13906 (mips_store_fpregset): Ditto.
13907 * linux-ppc-low.c (ppc_supply_ptrace_register)
13908 (ppc_supply_ptrace_register): Ditto.
13909 (parse_spufs_run): Adjust.
13910 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
13911 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
13912 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
13913 take a regcache. Adjust.
13914 * linux-s390-low.c (s390_collect_ptrace_register)
13915 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
13916 (s390_set_pc): Change prototype to take a regcache. Adjust.
13917 (s390_arch_setup): Adjust.
13918 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
13919 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
13920 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
13921 (sparc_fill_gregset, sparc_store_gregset_from_stack)
13922 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
13923 regcache. Adjust.
13924 (sparc_breakpoint_at): Adjust.
13925 * linux-xtensa-low.c (xtensa_fill_gregset):
13926 (xtensa_store_gregset):
13927 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
13928 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
13929 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
13930 prototype to take a regcache. Adjust.
13931 * win32-arm-low.c (arm_fetch_inferior_register)
13932 (arm_store_inferior_register): Change prototype to take a
13933 regcache. Adjust.
13934 * win32-i386-low.c (i386_fetch_inferior_register)
13935 (i386_store_inferior_register): Change prototype to take a
13936 regcache. Adjust.
13937 * win32-low.c (child_fetch_inferior_registers)
13938 (child_store_inferior_registers): Change prototype to take a
13939 regcache. Adjust.
13940 (win32_wait): Adjust.
13941 (win32_fetch_inferior_registers): Change prototype to take a
13942 regcache. Adjust.
13943 (win32_store_inferior_registers): Adjust.
13944 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
13945 store_inferior_register>: Change prototype to take a regcache.
13946
13947 2010-01-20 Doug Evans <dje@google.com>
13948
13949 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
13950 #ifdef.
13951 (linux_wait_for_event1, linux_init_signals): Ditto.
13952 (W_STOPCODE): Provide definition if missing.
13953
13954 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
13955
13956 * linux-low.c (linux_core_of_thread): New.
13957 (compare_ints, show_process, list_threads): New.
13958 (linux_qxfer_osdata): Report threads and cores.
13959 (linux_target_op): Register linux_core_of_thread.
13960 * remote-utils.c (prepare_resume_reply): Report the core.
13961 (buffer_xml_printf): Support %d specifier.
13962 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
13963 New.
13964 (handle_query): Handle qXfer:threads. Announce availability
13965 thereof.
13966 * target.h (struct target_ops): New field core_of_thread.
13967
13968 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
13969
13970 * Makefile.in (clean): Remove new generated files.
13971 (reg-s390.o, reg-s390.c): Remove rules.
13972 (reg-s390x.o, reg-s390x.c): Likewise.
13973 (s390-linux32.o, s390-linux32.c): Add rules.
13974 (s390-linux64.o, s390-linux64.c): Likewise.
13975 (s390x-linux64.o, s390x-linux64.c): Likewise.
13976 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
13977 * linux-s390-low.c: Include <elf.h>.
13978 (HWCAP_S390_HIGH_GPRS): Define if undefined.
13979 (init_registers_s390): Remove prototype.
13980 (init_registers_s390x): Likewise.
13981 (init_registers_s390_linux32): Add prototype.
13982 (init_registers_s390_linux64): Likewise.
13983 (init_registers_s390x_linux64): Likewise.
13984 (s390_num_regs_3264): New define.
13985 (s390_regmap_3264): New global variable.
13986 (s390_cannot_fetch_register): Remove obsolete check.
13987 (s390_cannot_store_register): Likewise.
13988 (s390_collect_ptrace_register): Handle upper/lower register halves.
13989 (s390_supply_ptrace_register): Likewise.
13990 (s390_fill_gregset): Update to register number changes.
13991 (s390_get_hwcap): New routine.
13992 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
13993 Install appropriate regmap and register set.
13994
13995 2010-01-01 Joel Brobecker <brobecker@adacore.com>
13996
13997 * server.c (gdbserver_version): Update copyright year to 2010.
13998 * gdbreplay.c (gdbreplay_version): Likewise.
13999
14000 2009-12-28 Doug Evans <dje@google.com>
14001
14002 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
14003 elf/external.h. Include <elf.h> instead but only if necessary.
14004
14005 2009-12-28 Pedro Alves <pedro@codesourcery.com>
14006
14007 * linux-low.c (linux_remove_process): Remove `detaching'
14008 parameter. Don't release/detach from thread_db here.
14009 (linux_kill): Release/detach from thread_db here, ...
14010 (linux_detach): ... and here, before actually detaching.
14011 (linux_wait_1): ... and here, when a process exits.
14012 * thread-db.c (any_thread_of): New.
14013 (thread_db_free): Switch the current inferior to a thread of the
14014 passed in process.
14015
14016 2009-12-21 Doug Evans <dje@google.com>
14017
14018 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
14019
14020 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
14021 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
14022 warning ifndef __NR_tkill. Move setting of errno there too.
14023 Delete unnecessary resetting of errno after syscall.
14024 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
14025
14026 * configure.ac: Check for dladdr.
14027 * config.in: Regenerate.
14028 * configure: Regenerate.
14029 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
14030 (try_thread_db_load): Update.
14031
14032 * linux-low.c (my_waitpid): Delete unnecessary prototype.
14033
14034 2009-12-18 Doug Evans <dje@google.com>
14035
14036 * event-loop.c: Include unistd.h if it exists.
14037
14038 * linux-low.c (my_waitpid): Move definition away from being in
14039 between linux_tracefork_child/linux_test_for_tracefork.
14040
14041 * gdb_proc_service.h (psaddr_t): Fix type.
14042 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
14043 signature to match glibc.
14044
14045 2009-12-16 Doug Evans <dje@google.com>
14046
14047 * linux-low.c (linux_read_memory): Fix argument to read.
14048
14049 2009-11-26 Pedro Alves <pedro@codesourcery.com>
14050
14051 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
14052 events, don't leave current_inferior pointing at null.
14053
14054 2009-11-26 Pedro Alves <pedro@codesourcery.com>
14055
14056 * win32-low.c (LOG): Delete.
14057 (OUTMSG): Output to stderr.
14058 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
14059 on compile time LOG macro.
14060 (win32_wait): Fix debug output.
14061
14062 2009-11-26 Pedro Alves <pedro@codesourcery.com>
14063
14064 * win32-low.c (win32_add_one_solib): If the dll name is
14065 "ntdll.dll", prepend the system directory to the dll path.
14066
14067 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
14068
14069 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
14070
14071 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
14072 Vladimir Prus <vladimir@codesourcery.com>
14073
14074 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
14075 * configure.ac: Check for __mcoldfire__ and set
14076 gdb_cv_m68k_is_coldfire.
14077 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
14078 reg-cf.o and reg-m68k.o.
14079 * configure: Regenerated.
14080
14081 2009-11-16 Pedro Alves <pedro@codesourcery.com>
14082
14083 * linux-low.c (linux_remove_process): Add `detaching' parameter.
14084 Pass it to thread_db_free.
14085 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
14086 proper `detaching' argument to linux_remove_process.
14087 * linux-low.h (thread_db_free): Add `detaching' parameter.
14088 * thread-db.c (thread_db_init): Pass false as `detaching' argument
14089 to thread_db_free.
14090 (thread_db_free): Add `detaching' parameter. Only
14091 call td_ta_clear_event if detaching from process.
14092
14093 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
14094
14095 * thread-db.c (thread_db_free): Fix typo.
14096
14097 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
14098
14099 PR gdb/10838
14100 * thread-db.c (thread_db_free): Call td_ta_clear_event.
14101
14102 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
14103
14104 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
14105 with an i686 compiler.
14106 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
14107 needed.
14108 * configure: Rebuilt.
14109
14110 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
14111
14112 PR gdb/10783
14113
14114 * server.c (handle_search_memory_1): Correct read_addr initialization
14115 in loop for searching subsequent chunks.
14116
14117 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
14118
14119 * configure.ac: New --with-libthread-db option.
14120 * thread-db.c: Allow direct dependence on libthread_db.
14121 (thread_db_free): Adjust.
14122 * config.in: Regenerate.
14123 * configure: Likewise.
14124
14125 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
14126
14127 PR gdb/10757
14128 * thread-db.c (attach_thread): New function.
14129 (maybe_attach_thread): Return success/failure.
14130 (find_new_threads_callback): Adjust.
14131 (thread_db_find_new_threads): Loop until no new threads.
14132
14133 2009-10-13 Pedro Alves <pedro@codesourcery.com>
14134
14135 * proc-service.c (ps_lgetregs): Formatting.
14136
14137 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
14138
14139 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
14140 * configure.ac: Adjust.
14141 * linux-low.h (struct process_info_private): Move members to struct
14142 thread_db.
14143 (thread_db_free, thread_db_handle_monitor_command): New prototype.
14144 * linux-low.c (linux_remove_process): Adjust.
14145 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
14146 * server.c (handle_query): Move code ...
14147 (handle_monitor_command): ... here. New function.
14148 * target.h (struct target_ops): New member.
14149 * thread-db.c (struct thread_db): New.
14150 (libthread_db_search_path): New variable.
14151 (thread_db_create_event, thread_db_enable_reporting)
14152 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
14153 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
14154 (try_thread_db_load_1, dladdr_to_soname): New functions.
14155 (try_thread_db_load, thread_db_load_search): New functions.
14156 (thread_db_init): Search for libthread_db.
14157 (thread_db_free): New function.
14158 (thread_db_handle_monitor_command): Likewise.
14159 * config.in: Regenerate.
14160 * configure: Regenerate.
14161
14162 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
14163
14164 * spu-low.c (spu_kill): Wait for inferior to terminate.
14165 Call clear_inferiors.
14166 (spu_detach): Call clear_inferiors.
14167
14168 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
14169
14170 * aclocal.m4: Regenerate.
14171 * config.in: Likewise.
14172 * configure: Likewise.
14173
14174 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14175
14176 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
14177 (parse_spufs_run): New function.
14178 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
14179 (ppc_breakpoint_at): Handle SPU breakpoints.
14180
14181 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14182
14183 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
14184 (SPUFS_MAGIC): Define.
14185 (spu_enumerate_spu_ids): New function.
14186 (linux_qxfer_spu): New function.
14187 (linux_target_ops): Install linux_qxfer_spu.
14188
14189 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14190
14191 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
14192 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
14193 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
14194 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
14195 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
14196 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
14197 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
14198 (init_registers_powerpc_cell32l): Add prototype.
14199 (init_registers_powerpc_cell64l): Likewise.
14200 (ppc_arch_setup): Detect Cell/B.E. architecture.
14201
14202 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
14203
14204 * Makefile.in (datarootdir): New variable.
14205
14206 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
14207
14208 * linux-low.c (linux_write_memory): Update debugging output.
14209 * Makefile.in (clean): Add new descriptions.
14210 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
14211 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
14212 * configure.srv: Add new files for arm*-*-linux*.
14213 * linux-arm-low.c: Add new declarations.
14214 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
14215 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
14216 (HWCAP_VFPv3D16): New.
14217 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
14218 instead of __IWMMXT__.
14219 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
14220 (arm_arch_setup): New.
14221 (target_regsets): Remove #ifdef. Add VFP regset.
14222 (the_low_target): Use arm_arch_setup.
14223
14224 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
14225
14226 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
14227 the main thread again.
14228
14229 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
14230
14231 Adding Neutrino gdbserver.
14232 * configure: Regenerated.
14233 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
14234 * configure.srv (i[34567]86-*-nto*): New target.
14235 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
14236 * remote-utils.c [__QNX__]: Include sys/iomgr.h
14237 (nto_comctrl) [__QNX__]: New function.
14238 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
14239
14240 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
14241
14242 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
14243 srv_tgtobj.
14244
14245 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
14246 Pedro Alves <pedro@codesourcery.com>
14247
14248 * win32-i386-low.c (i386_get_thread_context): Handle systems that
14249 don't support CONTEXT_EXTENDED_REGISTERS.
14250 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
14251 (the_low_target): Install them.
14252 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
14253 failing with ERROR_PIPE_NOT_CONNECTED.
14254
14255 2009-06-30 Doug Evans <dje@google.com>
14256 Pierre Muller <muller@ics.u-strasbg.fr>
14257
14258 Add h/w watchpoint support to x86-linux, win32-i386.
14259 * Makefile.in (SFILES): Add i386-low.c
14260 (i386_low_h): Define.
14261 (i386-low.o): Add dependencies.
14262 (linux-x86-low.o): Add i386-low.h dependency.
14263 (win32-i386-low.o): Ditto.
14264 * i386-low.c: New file.
14265 * i386-low.h: New file.
14266 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
14267 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
14268 * linux-low.c (linux_add_process): Initialize arch_private.
14269 (linux_remove_process): Free arch_private.
14270 (add_lwp): Initialize arch_private.
14271 (delete_lwp): Free arch_private.
14272 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
14273 provided.
14274 * linux-low.h (process_info_private): New member arch_private.
14275 (lwp_info): New member arch_private.
14276 (linux_target_ops): New members new_process, new_thread,
14277 prepare_to_resume.
14278 (ptid_of): New macro.
14279 * linux-x86-low.c: Include stddef.h, i386-low.h.
14280 (arch_process_info): New struct.
14281 (arch_lwp_info): New struct.
14282 (x86_linux_dr_get, x86_linux_dr_set): New functions.
14283 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
14284 (i386_dr_low_get_status): New function.
14285 (x86_insert_point, x86_remove_point): New functions.
14286 (x86_stopped_by_watchpoint): New function.
14287 (x86_stopped_data_address): New function.
14288 (x86_linux_new_process, x86_linux_new_thread): New functions.
14289 (x86_linux_prepare_to_resume): New function.
14290 (the_low_target): Add entries for insert_point, remove_point,
14291 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
14292 prepare_to_resume.
14293 * server.c (debug_hw_points): New global.
14294 (monitor_show_help): Document set debug-hw-points.
14295 (handle_query): Process "set debug-hw-points".
14296 * server.h (debug_hw_points): Declare.
14297 (paddress): Declare.
14298 * utils.c (NUMCELLS, CELLSIZE): New macros.
14299 (get_sell, xsnprintf, paddress): New functions.
14300 * win32-arm-low.c (the_low_target): Add entries for insert_point,
14301 remove_point, stopped_by_watchpoint, stopped_data_address.
14302 * win32-i386-low.c: Include i386-low.h.
14303 (debug_reg_state): Replaces dr.
14304 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
14305 (i386_dr_low_get_status): New function.
14306 (i386_insert_point, i386_remove_point): New functions.
14307 (i386_stopped_by_watchpoint): New function.
14308 (i386_stopped_data_address): New function.
14309 (i386_initial_stuff): Update.
14310 (get_thread_context,set_thread_context,i386_thread_added): Update.
14311 (the_low_target): Add entries for insert_point,
14312 remove_point, stopped_by_watchpoint, stopped_data_address.
14313 * win32-low.c (win32_insert_watchpoint): New function.
14314 (win32_remove_watchpoint): New function.
14315 (win32_stopped_by_watchpoint): New function.
14316 (win32_stopped_data_address): New function.
14317 (win32_target_ops): Add entries for insert_watchpoint,
14318 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
14319 * win32-low.h (win32_target_ops): New members insert_point,
14320 remove_point, stopped_by_watchpoint, stopped_data_address.
14321
14322 2009-06-25 Pedro Alves <pedro@codesourcery.com>
14323
14324 * server.c (process_serial_event): Re-return unsupported, not
14325 error, if the type isn't recognized. Re-allow supporting only
14326 insert or remove packets. Also call require_running for
14327 breakpoints. Add missing break statement to default case. Tidy.
14328 * target.h (struct target_ops): Rename insert_watchpoint to
14329 insert_point, and remove_watchpoint to remove_point.
14330
14331 * linux-low.h (struct linux_target_ops): Likewise.
14332 * linux-low.c (linux_insert_watchpoint): Rename to ...
14333 (linux_insert_point): ... this. Adjust.
14334 (linux_remove_watchpoint): Rename to ...
14335 (linux_remove_point): ... this. Adjust.
14336 (linux_target_ops): Adjust.
14337 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
14338 (cris_insert_point): ... this.
14339 (cris_remove_watchpoint): Rename to ...
14340 (cris_remove_point): ... this.
14341 (the_low_target): Adjust.
14342
14343 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
14344
14345 * server.c (handle_v_kill): Pass signal_pid to
14346 kill_inferior if multi_process is zero.
14347
14348 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
14349
14350 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
14351 * target.h (target_ops): Comment for *_watchpoint to make it clear
14352 the functions can get types '0' and '1'.
14353
14354 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
14355
14356 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
14357 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
14358 * regcache.c (get_regcache): Likewise.
14359 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
14360 * win32-low.c (child_fetch_inferior_registers): Remove check for
14361 regno 0.
14362
14363 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
14364 Pedro Alves <pedro@codesourcery.com>
14365
14366 * target.h (struct target_ops) <supports_multi_process>: New
14367 callback.
14368 (target_supports_multi_process): New.
14369 * server.c (handle_query): Even if GDB reports support, only
14370 enable multi-process if the target also supports it. Report
14371 multi-process support only if the target backend supports it.
14372 * linux-low.c (linux_supports_multi_process): New function.
14373 (linux_target_ops): Install it as target_supports_multi_process
14374 callback.
14375
14376 2009-05-24 Doug Evans <dje@google.com>
14377
14378 Global renaming of find_thread_pid to find_thread_ptid.
14379 * server.h (find_thread_ptid): Renamed from find_thread_pid.
14380 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
14381 All callers updated.
14382
14383 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
14384 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
14385 directly.
14386
14387 * linux-low.c (get_stop_pc): Print pc if debug_threads.
14388 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
14389 (linux_resume_one_lwp): Ditto.
14390
14391 2009-05-23 Doug Evans <dje@google.com>
14392
14393 * linux-low.c (linux_resume_one_lwp): Change type of first arg
14394 from struct inferior_list_entry * to struct lwp_info *.
14395 All callers updated.
14396
14397 2009-05-13 Doug Evans <dje@google.com>
14398
14399 * linux-x86-low.c: Don't include assert.h.
14400 (x86_siginfo_fixup): Use fatal, not assert.
14401 (x86_arch_setup): Fix comment.
14402
14403 2009-05-12 Doug Evans <dje@google.com>
14404
14405 Biarch support for i386/amd64 gdbserver.
14406 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
14407 Add linux-x86-low.c.
14408 (linux-i386-low.o, linux-x86-64-low.o): Delete.
14409 (linux-x86-low.o): Add.
14410 * linux-x86-64-low.c: Delete.
14411 * linux-i386-low.c: Delete.
14412 * linux-x86-low.c: New file.
14413 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
14414 linux-x86-low.o.
14415 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
14416 linux-x86-low.o.
14417 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
14418 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
14419 (linux_child_pid_to_exec_file): New function.
14420 (elf_64_header_p, elf_64_file_p): New functions.
14421 (siginfo_fixup): New function.
14422 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
14423 give target a chance to convert layout.
14424 * linux-low.h (linux_target_ops): New member siginfo_fixup.
14425 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
14426
14427 2009-05-07 Doug Evans <dje@google.com>
14428
14429 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
14430 (regsets_store_inferior_registers): Ditto.
14431
14432 2009-05-06 Pedro Alves <pedro@codesourcery.com>
14433
14434 PR server/10048
14435
14436 * linux-low.c (must_set_ptrace_flags): Delete.
14437 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
14438 of the global.
14439 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
14440 `lwp->must_set_ptrace_flags' instead.
14441 (linux_wait_for_event_1): Set ptrace options here.
14442 (linux_wait_1): ... not here.
14443
14444 2009-04-30 Doug Evans <dje@google.com>
14445
14446 * inferiors.c (started_inferior_callback): New function.
14447 (attached_inferior_callback): New function.
14448 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
14449 * server.c (print_started_pid, print_attached_pid): New functions.
14450 (detach_or_kill_for_exit): New function.
14451 (main): Call it instead of for_each_inferior (kill_inferior_callback).
14452 * server.h (have_started_inferiors_p): Declare.
14453 (have_attached_inferiors_p): Declare.
14454
14455 * inferiors.c (remove_process): Fix memory leak, free process.
14456 * linux-low.c (linux_remove_process): New function.
14457 (linux_kill): Call it instead of remove_process.
14458 (linux_detach, linux_wait_1): Ditto.
14459
14460 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
14461
14462 * configure.srv: Add x86 Windows CE target.
14463
14464 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
14465
14466 * inferiors.c (get_thread_process): Make global.
14467 * server.h (get_thread_process): Add prototype.
14468 * thread-db.c (find_one_thread): Use get_thread_process
14469 instead of current_process.
14470 (thread_db_get_tls_address): Do not crash if called when
14471 thread layer is not yet initialized.
14472
14473 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
14474
14475 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
14476 * spu-low.c (current_tid): Rename to ...
14477 (current_ptid): ... this.
14478 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
14479 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
14480 ptid_get_lwp (current_ptid) instead of current_tid.
14481 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
14482 instead of current_tid. Use find_process_pid to verify pid
14483 argument is valid. Pass proper argument to remove_process.
14484 (spu_thread_alive): Compare current_ptid instead of current_tid.
14485 (spu_resume): Likewise.
14486
14487 2009-04-02 Pedro Alves <pedro@codesourcery.com>
14488
14489 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
14490 variable.
14491
14492 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14493
14494 Implement the multiprocess extensions, and add linux multiprocess
14495 support.
14496
14497 * server.h (ULONGEST): Declare.
14498 (struct ptid, ptid_t): New.
14499 (minus_one_ptid, null_ptid): Declare.
14500 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
14501 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
14502 (struct inferior_list_entry): Change `id' type from unsigned from
14503 to ptid_t.
14504 (struct sym_cache, struct breakpoint, struct
14505 process_info_private): Forward declare.
14506 (struct process_info): Declare.
14507 (current_process): Declare.
14508 (all_processes): Declare.
14509 (initialize_inferiors): Declare.
14510 (add_thread): Adjust to use ptid_t.
14511 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
14512 (add_process, remove_process, find_thread_pid): Declare.
14513 (find_inferior_id): Adjust to use ptid_t.
14514 (cont_thread, general_thread, step_thread): Change type to ptid_t.
14515 (multi_process): Declare.
14516 (push_event): Adjust to use ptid_t.
14517 (read_ptid, write_ptid): Declare.
14518 (prepare_resume_reply): Adjust to use ptid_t.
14519 (clear_symbol_cache): Declare.
14520 * inferiors.c (all_processes): New.
14521 (null_ptid, minus_one_ptid): New.
14522 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
14523 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
14524 (add_thread): Change unsigned long to ptid. Remove gdb_id
14525 parameter. Adjust.
14526 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
14527 (gdb_id_to_thread): Rename to ...
14528 (find_thread_pid): ... this. Change unsigned long to ptid.
14529 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
14530 (loaded_dll, pull_pid_from_list): Adjust.
14531 (add_process, remove_process, find_process_pid)
14532 (get_thread_process, current_process, initialize_inferiors): New.
14533 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
14534 (struct target_waitstatus) <related_pid>: Ditto.
14535 (struct target_ops) <kill, detach>: Add `pid' argument. Change
14536 return type to int.
14537 (struct target_ops) <join>: Add `pid' argument.
14538 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
14539 (struct target_ops) <wait>: Add `ptid' field. Change return type
14540 to ptid.
14541 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
14542 (mywait): Add `ptid' argument. Change return type to ptid_t.
14543 (target_pid_to_str): Declare.
14544 * target.c (set_desired_inferior): Adjust to use ptids.
14545 (mywait): Add new `ptid' argument. Adjust.
14546 (target_pid_to_str): New.
14547 * mem-break.h (free_all_breakpoints): Declare.
14548 * mem-break.c (breakpoints): Delelete.
14549 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
14550 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
14551 to use per-process breakpoint list.
14552 (free_all_breakpoints): New.
14553 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
14554 (symbol_cache, all_symbols_looked_up): Delete.
14555 (hexchars): New.
14556 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
14557 read_ptid): New.
14558 (prepare_resume_reply): Change ptid argument's type from unsigned
14559 long to ptid_t. Adjust. Implement W;process and X;process.
14560 (free_sym_cache, clear_symbol_cache): New.
14561 (look_up_one_symbol): Adjust to per-process symbol cache. *
14562 * server.c (cont_thread, general_thread, step_thread): Change type
14563 to ptid_t.
14564 (attached): Delete.
14565 (multi_process): New.
14566 (last_ptid): Change type to ptid_t.
14567 (struct vstop_notif) <ptid>: Change type to ptid_t.
14568 (queue_stop_reply, push_event): Change `ptid' argument's type to
14569 ptid_t.
14570 (discard_queued_stop_replies): Add `pid' argument.
14571 (start_inferior): Adjust to use ptids. Adjust to mywait interface
14572 changes. Don't reference the `attached' global.
14573 (attach_inferior): Adjust to mywait interface changes.
14574 (handle_query): Adjust to use ptids. Parse GDB's qSupported
14575 features. Handle and report "multiprocess+". Handle
14576 "qAttached:PID".
14577 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
14578 changes.
14579 (handle_v_kill): New.
14580 (handle_v_stopped): Adjust to use target_pid_to_str.
14581 (handle_v_requests): Allow multiple attaches and runs when
14582 multiprocess extensions are in effect. Handle "vKill".
14583 (myresume): Adjust to use ptids.
14584 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
14585 (handle_status): Adjust to discard_queued_stop_replies interface
14586 change.
14587 (first_thread_of, kill_inferior_callback)
14588 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
14589 (main): Call initialize_inferiors. Adjust to use ptids, killing
14590 and detaching from all inferiors. Handle multiprocess packet
14591 variants.
14592 * linux-low.h: Include gdb_proc_service.h.
14593 (struct process_info_private): New.
14594 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
14595 <lwpid_of>: Use ptid_get_lwp.
14596 (get_lwp_thread): Adjust.
14597 (struct lwp_info): Add `dead' member.
14598 (find_lwp_pid): Declare.
14599 * linux-low.c (thread_db_active): Delete.
14600 (new_inferior): Adjust comment.
14601 (inferior_pid): Delete.
14602 (linux_add_process): New.
14603 (handle_extended_wait): Adjust.
14604 (add_lwp): Change unsigned long to ptid.
14605 (linux_create_inferior): Add process to processes table. Adjust
14606 to use ptids. Don't set new_inferior here.
14607 (linux_attach_lwp): Rename to ...
14608 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
14609 it. Adjust to use ptids.
14610 (linux_attach_lwp): New.
14611 (linux_attach): Add process to processes table. Don't set
14612 new_inferior here.
14613 (struct counter): New.
14614 (second_thread_of_pid_p, last_thread_of_process_p): New.
14615 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
14616 multiple processes.
14617 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
14618 processes. Remove process from process table.
14619 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
14620 to multiple processes.
14621 (any_thread_of): New.
14622 (linux_detach): Add `pid' argument, and handle it. Remove process
14623 from processes table.
14624 (linux_join): Add `pid' argument. Handle it.
14625 (linux_thread_alive): Change unsighed long argument to ptid_t.
14626 Consider dead lwps as not being alive.
14627 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
14628 threads we're not interested in.
14629 (same_lwp, find_lwp_pid): New.
14630 (linux_wait_for_lwp): Change `pid' argument's type from int to
14631 ptid_t. Adjust.
14632 (linux_wait_for_event): Rename to ...
14633 (linux_wait_for_event_1): ... this. Change `pid' argument's type
14634 from int to ptid_t. Adjust.
14635 (linux_wait_for_event): New.
14636 (linux_wait_1): Add `ptid' argument. Change return type to
14637 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
14638 that exit from the process table.
14639 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
14640 Adjust.
14641 (mark_lwp_dead): New.
14642 (wait_for_sigstop): Adjust to use ptids. If a process exits while
14643 stopping all threads, mark its main lwp as dead.
14644 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
14645 ptids.
14646 (fetch_register, usr_store_inferior_registers)
14647 (regsets_fetch_inferior_registers)
14648 (regsets_store_inferior_registers, linux_read_memory)
14649 (linux_write_memory): Inline `inferior_pid'.
14650 (linux_look_up_symbols): Adjust to use per-process
14651 `thread_db_active'.
14652 (linux_request_interrupt): Adjust to use ptids.
14653 (linux_read_auxv): Inline `inferior_pid'.
14654 (initialize_low): Don't reference thread_db_active.
14655 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
14656 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
14657 (ps_getpid): Return the pid of the current inferior.
14658 * thread-db.c (proc_handle, thread_agent): Delete.
14659 (thread_db_create_event, thread_db_enable_reporting): Adjust to
14660 per-process data.
14661 (find_one_thread): Change argument type to ptid_t. Adjust to
14662 per-process data.
14663 (maybe_attach_thread): Adjust to per-process data and ptids.
14664 (thread_db_find_new_threads): Ditto.
14665 (thread_db_init): Ditto.
14666 * spu-low.c (spu_create_inferior, spu_attach): Add process to
14667 processes table. Adjust to use ptids.
14668 (spu_kill, spu_detach): Adjust interface. Remove process from
14669 processes table.
14670 (spu_join, spu_thread_alive): Adjust interface.
14671 (spu_wait): Adjust interface. Remove process from processes
14672 table. Adjust to use ptids.
14673 * win32-low.c (current_inferior_tid): Delete.
14674 (current_inferior_ptid): New.
14675 (debug_event_ptid): New.
14676 (thread_rec): Take a ptid. Adjust.
14677 (child_add_thread): Add `pid' argument. Adjust to use ptids.
14678 (child_delete_thread): Ditto.
14679 (do_initial_child_stuff): Add `attached' argument. Add process to
14680 processes table.
14681 (child_fetch_inferior_registers, child_store_inferior_registers):
14682 Adjust.
14683 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
14684 (win32_attach): Pass 1 to do_initial_child_stuff.
14685 (win32_kill): Adjust interface. Remove process from processes
14686 table.
14687 (win32_detach): Ditto.
14688 (win32_join): Adjust interface.
14689 (win32_thread_alive): Take a ptid.
14690 (win32_resume): Adjust to use ptids.
14691 (get_child_debug_event): Ditto.
14692 (win32_wait): Adjust interface. Remove exiting process from
14693 processes table.
14694
14695 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14696
14697 Non-stop mode support.
14698
14699 * server.h (non_stop): Declare.
14700 (gdb_client_data, handler_func): Declare.
14701 (delete_file_handler, add_file_handler, start_event_loop):
14702 Declare.
14703 (handle_serial_event, handle_target_event, push_event)
14704 (putpkt_notif): Declare.
14705 * target.h (enum resume_kind): New.
14706 (struct thread_resume): Replace `step' field by `kind' field.
14707 (TARGET_WNOHANG): Define.
14708 (struct target_ops) <wait>: Add `options' argument.
14709 <supports_non_stop, async, start_non_stop>: New fields.
14710 (target_supports_non_stop, target_async): New.
14711 (start_non_stop): Declare.
14712 (mywait): Add `options' argument.
14713 * target.c (mywait): Add `options' argument. Print child exit
14714 notifications here.
14715 (start_non_stop): New.
14716 * server.c (non_stop, own_buf, mem_buf): New globals.
14717 (struct vstop_notif): New.
14718 (notif_queue): New global.
14719 (queue_stop_reply, push_event, discard_queued_stop_replies)
14720 (send_next_stop_reply): New.
14721 (start_inferior): Adjust to use resume_kind. Adjust to mywait
14722 interface changes.
14723 (attach_inferior): In non-stop mode, don't wait for the target
14724 here.
14725 (handle_general_set): Handle QNonStop.
14726 (handle_query): When handling qC, return the current general
14727 thread, instead of the first thread of the list.
14728 (handle_query): If the backend supports non-stop mode, include
14729 QNonStop+ in the qSupported query response.
14730 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
14731 and non-stop mode.
14732 (handle_v_attach, handle_v_run): Handle non-stop mode.
14733 (handle_v_stopped): New.
14734 (handle_v_requests): Report support for vCont;t. Handle vStopped.
14735 (myresume): Adjust to use resume_kind. Handle non-stop.
14736 (queue_stop_reply_callback): New.
14737 (handle_status): Handle non-stop mode.
14738 (main): Clear non_stop flag on reconnection. Use the event-loop.
14739 Refactor serial protocol handling from here ...
14740 (process_serial_event): ... to this new function. When GDB
14741 selects any thread, select one here. In non-stop mode, wait until
14742 GDB acks all pending events before exiting.
14743 (handle_serial_event, handle_target_event): New.
14744 * remote-utils.c (remote_open): Install remote_desc in the event
14745 loop.
14746 (remote_close): Remove remote_desc from the event loop.
14747 (putpkt_binary): Rename to...
14748 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
14749 (putpkt_binary): New as wrapper around putpkt_binary_1.
14750 (putpkt_notif): New.
14751 (prepare_resume_reply): In non-stop mode, don't change the
14752 general_thread.
14753 * event-loop.c: New.
14754 * Makefile.in (OBJ): Add event-loop.o.
14755 (event-loop.o): New rule.
14756
14757 * linux-low.h (pid_of): Moved here.
14758 (lwpid_of): New.
14759 (get_lwp_thread): Use lwpid_of.
14760 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
14761 * linux-low.c (pid_of): Delete.
14762 (inferior_pid): Use lwpid_of.
14763 (linux_event_pipe): New.
14764 (target_is_async_p): New.
14765 (delete_lwp): New.
14766 (handle_extended_wait): Use lwpid_of.
14767 (add_lwp): Don't set lwpid field.
14768 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
14769 (linux_kill_one_lwp): If killing a running lwp, stop it first.
14770 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
14771 (linux_detach_one_lwp): If detaching from a running lwp, stop it
14772 first. Adjust to linux_wait_for_event interface changes. Use
14773 lwpid_of.
14774 (linux_detach): Don't delete the main lwp here.
14775 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
14776 (status_pending_p): Don't consider explicitly suspended lwps.
14777 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
14778 pointer. Add OPTIONS argument. Change return type to int. Use
14779 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
14780 (linux_wait_for_event): Take an integer pid instead of a lwp_info
14781 pointer. Add status pointer argument. Return a pid instead of a
14782 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
14783 changes. In non-stop mode, don't switch to a random thread.
14784 (linux_wait): Rename to...
14785 (linux_wait_1): ... this. Add target_options argument, and handle
14786 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
14787 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
14788 clean exit and signal exit code. Don't stop all threads in
14789 non-stop mode. In all-stop mode, only stop all threads when
14790 reporting a stop to GDB. Handle explicit thread stop requests.
14791 (async_file_flush, async_file_mark): New.
14792 (linux_wait): New.
14793 (send_sigstop): Use lwpid_of.
14794 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
14795 interface changes. In non-stop mode, don't switch to a random
14796 thread.
14797 (linux_resume_one_lwp): Use lwpid_of.
14798 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
14799 (linux_resume_one_thread): ... this. Handle resume_stop. In
14800 non-stop mode, don't look for pending flag in all threads.
14801 (resume_status_pending_p): Don't consider explicitly suspended
14802 threads.
14803 (my_waitpid): Reimplement. Emulate __WALL.
14804 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
14805 Use lwpid_of.
14806 (sigchld_handler, linux_supports_non_stop, linux_async)
14807 (linux_start_non_stop): New.
14808 (linux_target_ops): Register linux_supports_non_stop, linux_async
14809 and linux_start_non_stop.
14810 (initialize_low): Install SIGCHLD handler.
14811 * thread-db.c (thread_db_create_event, find_one_thread)
14812 (thread_db_get_tls_address): Use lwpid_of.
14813 * win32-low.c (win32_detach): Adjust to use resume_kind.
14814 (win32_wait): Add `options' argument.
14815 * spu-low.c (spu_resume): Adjust to use resume_kind.
14816 (spu_wait): Add `options' argument.
14817
14818 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14819
14820 Decouple target code from remote protocol.
14821
14822 * target.h (enum target_waitkind): New.
14823 (struct target_waitstatus): New.
14824 (struct target_ops) <wait>: Return an unsigned long. Take a
14825 target_waitstatus pointer instead of a char pointer.
14826 (mywait): Likewise.
14827 * target.c (mywait): Change prototype to return an unsigned long.
14828 Take a target_waitstatus pointer instead of a char pointer. Adjust.
14829 * server.h (thread_from_wait, old_thread_from_wait): Delete
14830 declarations.
14831 (prepare_resume_reply): Change prototype to take a
14832 target_waitstatus.
14833 * server.c (thread_from_wait, old_thread_from_wait): Delete.
14834 (last_status, last_ptid): New.
14835 (start_inferior): Remove "statusptr" argument. Adjust. Return a
14836 pid instead of a signal.
14837 (attach_inferior): Remove "status" and "signal" parameters.
14838 Adjust.
14839 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
14840 not as an address.
14841 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
14842 (handle_v_requests, myresume): Remove "status" and "signal"
14843 parameters. Adjust.
14844 (handle_status): New.
14845 (main): Delete local `status'. Adjust.
14846 * remote-utils.c: Include target.h.
14847 (prepare_resume_reply): Change prototype to take a
14848 target_waitstatus. Adjust.
14849
14850 * linux-low.c (linux_wait): Adjust to new target_ops->wait
14851 interface.
14852 * spu-low.c (spu_wait): Adjust.
14853 * win32-low.c (enum target_waitkind, struct target_waitstatus):
14854 Delete.
14855 (win32_wait): Adjust.
14856
14857 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14858
14859 * target.h (struct thread_resume): Delete leave_stopped member.
14860 (struct target_ops): Add a `n' argument to the `resume' callback.
14861 * server.c (start_inferior): Adjust.
14862 (handle_v_cont, myresume): Adjust.
14863 * linux-low.c (check_removed_breakpoint): Adjust to resume
14864 interface change, and to removed leave_stopped field.
14865 (resume_ptr): Delete.
14866 (struct thread_resume_array): New.
14867 (linux_set_resume_request): Add new `arg' parameter. Adjust to
14868 resume interface change.
14869 (linux_continue_one_thread, linux_queue_one_thread)
14870 (resume_status_pending_p): Check if the resume field is NULL
14871 instead of checking the leave_stopped member.
14872 (linux_resume): Adjust to the target resume interface change.
14873 * spu-low.c (spu_resume): Adjust to the target resume interface
14874 change.
14875 * win32-low.c (win32_detach, win32_resume): Ditto.
14876
14877 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14878
14879 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
14880 flag.
14881 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
14882 pending.
14883 (linux_continue_one_thread): Only preserve the stepping flag if
14884 there's a pending breakpoint.
14885
14886 2009-03-31 Pedro Alves <pedro@codesourcery.com>
14887
14888 * server.c (main): After the inferior having exited, call
14889 remote_close before exiting gdbserver.
14890
14891 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
14892
14893 Fix size of FPSCR in Power 7 processors.
14894 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
14895 (PPC_FEATURE_HAS_DFP): New #define.
14896 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
14897 size of the FPSCR.
14898
14899 2009-03-23 Pedro Alves <pedro@codesourcery.com>
14900
14901 * server.c (handle_query) Whitespace and formatting.
14902
14903 2009-03-22 Pedro Alves <pedro@codesourcery.com>
14904
14905 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
14906 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
14907 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
14908 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
14909 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
14910 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
14911 Makefile.in, configure.ac: Fix whitespace throughout.
14912 * configure: Regenerate.
14913
14914 2009-03-22 Pedro Alves <pedro@codesourcery.com>
14915
14916 * inferiors.c (find_inferior): Make it safe for the callback
14917 function to delete the currently iterated inferior.
14918
14919 2009-03-22 Pedro Alves <pedro@codesourcery.com>
14920
14921 * Makefile.in (linuw_low_h): Move higher.
14922 (thread-db.o): Depend on $(linux_low_h).
14923
14924 2009-03-17 Pedro Alves <pedro@codesourcery.com>
14925
14926 Rename "process" to "lwp" throughout.
14927
14928 * linux-low.c (all_processes): Rename to...
14929 (all_lwps): ... this.
14930 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
14931 (add_process): Rename to ...
14932 (add_lwp): ... this. Adjust.
14933 (linux_create_inferior): Adjust.
14934 (linux_attach_lwp): Adjust.
14935 (linux_attach): Adjust.
14936 (linux_kill_one_process): Rename to ...
14937 (linux_kill_one_lwp): ... this. Adjust.
14938 (linux_kill): Adjust.
14939 (linux_detach_one_process): Rename to ...
14940 (linux_detach_one_lwp): ... this. Adjust.
14941 (linux_detach): Adjust.
14942 (check_removed_breakpoint): Adjust.
14943 (status_pending_p): Adjust.
14944 (linux_wait_for_process): Rename to ...
14945 (linux_wait_for_lwp): ... this. Adjust.
14946 (linux_wait_for_event): Adjust.
14947 (send_sigstop): Adjust.
14948 (wait_for_sigstop): Adjust.
14949 (stop_all_processes): Rename to ...
14950 (stop_all_lwps): ... this.
14951 (linux_resume_one_process): Rename to ...
14952 (linux_resume_one_lwp): ... this. Adjust.
14953 (linux_set_resume_request, linux_continue_one_thread)
14954 (linux_queue_one_thread, resume_status_pending_p)
14955 (usr_store_inferior_registers, regsets_store_inferior_registers)
14956 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
14957 Adjust.
14958 * linux-low.h (get_process): Rename to ...
14959 (get_lwp): ... this. Adjust.
14960 (get_thread_process): Rename to ...
14961 (get_thread_lwp): ... this. Adjust.
14962 (get_process_thread): Rename to ...
14963 (get_lwp_thread): ... this. Adjust.
14964 (struct process_info): Rename to ...
14965 (struct lwp_info): ... this.
14966 (all_processes): Rename to ...
14967 (all_lwps): ... this.
14968 * proc-service.c (ps_lgetregs): Adjust.
14969 * thread-db.c (thread_db_create_event, find_one_thread)
14970 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
14971
14972 2009-03-14 Pedro Alves <pedro@codesourcery.com>
14973
14974 * server.c (handle_query): Handle "qAttached".
14975
14976 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
14977
14978 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
14979 GPLv3, update license URL.
14980
14981 2009-03-01 Doug Evans <dje@google.com>
14982
14983 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
14984 (server_h): Add gdb_signals.h.
14985 (signals.o): Update.
14986 * server.h (target_signal_from_host,target_signal_to_host_p)
14987 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
14988
14989 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
14990
14991 * remote-utils.c (getpkt): Also generate remote-debug
14992 information if noack_mode is set.
14993
14994 2009-02-06 Pedro Alves <pedro@codesourcery.com>
14995
14996 * server.c (handle_query): Report qXfer:siginfo:read and
14997 qXfer:siginfo:write as supported and handle them.
14998 * target.h (struct target_ops) <qxfer_siginfo>: New field.
14999 * linux-low.c (linux_xfer_siginfo): New.
15000 (linux_target_ops): Set it.
15001
15002 2009-01-26 Pedro Alves <pedro@codesourcery.com>
15003
15004 * server.c (gdbserver_usage): Mention --remote-debug.
15005 (main): Accept '--remote-debug' switch.
15006
15007 2009-01-18 Doug Evans <dje@google.com>
15008
15009 * regcache.c (new_register_cache): No need to check result of xcalloc.
15010 * server.c (handle_search_memory): Back out calls to xmalloc,
15011 result is checked and error is returned to user upon failure.
15012 (handle_query): Ditto. Add more checks for result of malloc.
15013 (handle_v_cont): Check result of malloc, report error back to
15014 user upon failure.
15015 (handle_v_run): Ditto. Call freeargv.
15016 * server.h (freeargv): Declare.
15017 * utils.c (freeargv): New fn.
15018
15019 2009-01-15 Doug Evans <dje@google.com>
15020
15021 * gdbreplay.c (perror_with_name): Make arg const char *.
15022 * server.h (target_signal_to_name): Make return type const char *.
15023 * thread-db.c (thread_db_err_str): Make return type const char *.
15024 * utils.c (perror_with_name): Make arg const char *.
15025
15026 2009-01-14 Pedro Alves <pedro@codesourcery.com>
15027
15028 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
15029 when handling a EXIT_PROCESS_DEBUG_EVENT.
15030
15031 2009-01-06 Joel Brobecker <brobecker@adacore.com>
15032
15033 * gdbreplay.c (gdbreplay_version): Update copyright year.
15034 * server.c (gdbserver_version): Likewise.
15035
15036 2009-01-05 Doug Evans <dje@google.com>
15037
15038 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
15039 (handle_extended_wait): Improve comment.
15040
15041 2008-12-13 Doug Evans <dje@google.com>
15042
15043 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
15044 * server.h (ATTR_MALLOC): New macro.
15045 (xmalloc,xcalloc,xstrdup): Declare.
15046 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
15047 * inferiors.c: Ditto.
15048 * linux-low.c: Ditto.
15049 * mem-break.c: Ditto.
15050 * regcache.c: Ditto.
15051 * remote-utils.c: Ditto.
15052 * server.c: Ditto.
15053 * target.c: Ditto.
15054 * win32-low.c: Ditto.
15055
15056 2008-12-12 Doug Evans <dje@google.com>
15057
15058 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
15059 in debugging printf.
15060
15061 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
15062
15063 2008-12-09 Doug Evans <dje@google.com>
15064
15065 * linux-low.h (struct process_info): Delete member tid, unused.
15066 * thread-db.c (find_one_thread): Update.
15067 (maybe_attach_thread): Update.
15068
15069 2008-12-02 Pedro Alves <pedro@codesourcery.com>
15070
15071 * target.h (struct target_ops): Add qxfer_osdata member.
15072 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
15073 and dirent.h.
15074 (linux_qxfer_osdata): New functions.
15075 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
15076 callback.
15077 * server.c (handle_query): Handle "qXfer:osdata:read:".
15078 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
15079 (buffer_xml_printf): New functions.
15080 * server.h (struct buffer): New.
15081 (buffer_grow_str, buffer_grow_str0): New macros.
15082 (buffer_grow, buffer_free, buffer_init, buffer_finish)
15083 (buffer_xml_printf): Declare.
15084
15085 2008-11-24 Doug Evans <dje@google.com>
15086
15087 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
15088
15089 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
15090
15091 * server.c (handle_v_run): Always use the supplied argument list.
15092
15093 2008-11-19 Bob Wilson <bob.wilson@acm.org>
15094
15095 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
15096 (xtensa_regmap_table): Add entry for scompare1.
15097
15098 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
15099
15100 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
15101 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
15102 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
15103 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
15104 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
15105 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
15106 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
15107 XML target descriptions.
15108 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
15109 when inferior is running on an ISA 2.05 or later processor. Add
15110 special case to return offset for full 64-bit slot of FPSCR when
15111 in 32-bits.
15112
15113 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
15114
15115 * Makefile.in (SFILES, clean): Added sparc64 files.
15116 (reg-sparc64.o, reg-sparc64.c): New.
15117 * configure.srv (sparc*-*-linux*): New configuration.
15118 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
15119 syscall arguments for SPARC.
15120 (regsets_store_inferior_registers): Likewise.
15121 * linux-sparc-low.c: New file.
15122
15123 2008-10-21 Doug Evans <dje@google.com>
15124
15125 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
15126 (READLINE_DIR,READLINE_DEP): Delete.
15127 (INTERNAL_CFLAGS): Update.
15128 (LINTFLAGS): Update.
15129
15130 2008-10-10 Pedro Alves <pedro@codesourcery.com>
15131
15132 * server.c (handle_v_run): If GDB didn't specify an argv, use the
15133 whole argv from the last run, not just argv[0].
15134
15135 2008-09-08 Pedro Alves <pedro@codesourcery.com>
15136
15137 * regcache.c (new_register_cache): Return NULL if the register
15138 cache size isn't known yet.
15139 (free_register_cache): Avoid dereferencing a NULL regcache.
15140
15141 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
15142
15143 * configure.srv: Merge MIPS and MIPS64.
15144
15145 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
15146
15147 * Makefile.in (uninstall): Apply $(EXEEXT) too.
15148
15149 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
15150
15151 * Makefile.in: Add required vsx dependencies.
15152
15153 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
15154 Declare init_registers_powerpc_vsx32l.
15155 Declare init_registers_powerpc_vsx64l.
15156 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
15157 (ppc_arch_setup): Check for VSX in hwcap.
15158 (ppc_fill_vsxregset): New function.
15159 (ppc_store_vsxregset): New function.
15160 Add new VSX entry in regset_info target_regsets.
15161
15162 * configure.srv: Add new VSX dependencies.
15163
15164 2008-08-12 Pedro Alves <pedro@codesourcery.com>
15165
15166 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
15167 (remote_open): Set or clear transport_is_reliable.
15168 (putpkt_binary): Don't expect acks in noack mode.
15169 (getpkt): Don't send ack/nac in noack mode.
15170 * server.c (handle_general_set): Handle QStartNoAckMode.
15171 (handle_query): If connected by tcp pass QStartNoAckMode+ in
15172 qSupported.
15173 (main): Reset noack_mode on every connection.
15174 * server.h (noack_mode): Declare.
15175
15176 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15177
15178 * Makefile.in (GDBREPLAY_OBS): New variable.
15179 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
15180
15181 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
15182 Daniel Jacobowitz <dan@codesourcery.com>
15183
15184 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
15185 (usr_store_inferior_registers): Likewise.
15186 (regsets_store_inferior_registers): Likewise.
15187
15188 2008-07-31 Rolf Jansen <rj@surtec.com>
15189 Pedro Alves <pedro@codesourcery.com>
15190
15191 * configure.ac: Check for memmem declaration.
15192 * server.c [HAVE_MALLOC_H]: Include malloc.h.
15193 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
15194 (disable_packet_qfThreadInfo): Unconditionally compile.
15195 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
15196 * configure, config.in: Regenerate.
15197
15198 2008-07-28 Doug Kwan <dougkwan@google.com>
15199
15200 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
15201 (linux_write_memory): Remove declaration of errno.
15202
15203 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
15204
15205 * linux-low.c (handle_extended_wait): Do not use "status"
15206 variable uninitialized.
15207
15208 2008-07-07 Pedro Alves <pedro@codesourcery.com>
15209
15210 * server.c (handle_v_attach): Inhibit reporting dll changes.
15211
15212 2008-06-27 Pedro Alves <pedro@codesourcery.com>
15213
15214 * remote-utils.c (prepare_resume_reply): If requested, don't
15215 output "thread:TID" in the T stop reply.
15216
15217 * server.c (disable_packet_vCont, disable_packet_Tthread)
15218 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
15219 (handle_query): If requested, disable support for qC, qfThreadInfo
15220 and qsThreadInfo.
15221 (handle_v_requests): If requested, disable support for vCont.
15222 (gdbserver_show_disableable): New.
15223 (main): Handle --disable-packet and --disable-packet=LIST.
15224
15225 * server.h (disable_packet_vCont, disable_packet_Tthread)
15226 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
15227
15228 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
15229
15230 * server.c (gdbserver_usage): Mention --version.
15231
15232 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
15233
15234 * Makefile.in (gdbreplay.o): New rule.
15235
15236 2008-06-06 Joseph Myers <joseph@codesourcery.com>
15237
15238 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
15239 message, not gdbserver.
15240
15241 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
15242 Nathan Sidwell <nathan@codesourcery.com>
15243 Joseph Myers <joseph@codesourcery.com>
15244
15245 * acinclude.m4: Include ../../config/acx.m4.
15246 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
15247 * configure, config.in: Regenerate.
15248 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
15249 * server.c (gdbserver_version): Print PKGVERSION.
15250 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
15251 (main): Adjust gdbserver_usage calls.
15252 * gdbreplay.c (version, host_name): Add declarations.
15253 (gdbreplay_version, gdbreplay_usage): New.
15254 (main): Accept --version and --help options.
15255
15256 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
15257
15258 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
15259 (arm_breakpoint_at): Handle Thumb.
15260 (the_low_target): Add comment.
15261
15262 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
15263
15264 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
15265
15266 2008-05-09 Doug Evans <dje@google.com>
15267
15268 * server.h (decode_search_memory_packet): Declare.
15269 * remote-utils.c (decode_search_memory_packet): New fn.
15270 * server.c (handle_search_memory_1): New fn.
15271 (handle_search_memory): New fn.
15272 (handle_query): Process qSearch:memory packets.
15273
15274 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
15275
15276 * regcache.c (registers_length): Remove.
15277 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
15278 full register packet.
15279 * regcache.h (registers_length): Remove prototype.
15280 * server.h (PBUFSIZ): Define to 16384.
15281
15282 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
15283
15284 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
15285 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
15286 powerpc-64l.o, and powerpc-altivec64l.o.
15287 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
15288 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
15289 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
15290 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
15291 rs6000/power-linux.xml, and rs6000/power64-linux.xml
15292 to srv_xmlfiles.
15293
15294 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
15295 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
15296 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
15297 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
15298 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
15299 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
15300 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
15301 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
15302 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
15303 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
15304 (clean): Update.
15305
15306 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
15307 (init_registers_powerpc_32l): ... this new prototype.
15308 (init_registers_powerpc_32): Remove, replace by ...
15309 (init_registers_powerpc_altivec32l): ... this new prototype.
15310 (init_registers_powerpc_e500): Remove, replace by ...
15311 (init_registers_powerpc_e500l): ... this new prototype.
15312 (init_registers_ppc64): Remove, replace by ...
15313 (init_registers_powerpc_64l): ... this new prototype.
15314 (init_registers_powerpc_64): Remove, replace by ...
15315 (init_registers_powerpc_altivec64l): ... this new prototype.
15316 (ppc_num_regs): Set to 73.
15317 (PT_ORIG_R3, PT_TRAP): Define if necessary.
15318 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
15319 (ppc_cannot_store_register): Handle orig_r3 and trap.
15320 (ppc_arch_setup): Update init_registers_... calls.
15321 (ppc_fill_gregset): Handle orig_r3 and trap.
15322
15323 * inferiors.c (clear_inferiors): Reset current_inferior.
15324
15325 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
15326
15327 * acinclude.m4: Add override.m4.
15328 * configure: Regenerate.
15329
15330 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
15331
15332 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
15333 initial call to init_register_ppc64.
15334
15335 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
15336
15337 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
15338 single powerpc*-*-linux* case.
15339 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
15340
15341 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
15342
15343 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
15344 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
15345 from reg_xmlfiles.
15346 * linux-ppc-low.c: Include <elf.h>.
15347 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
15348 (ppc_hwcap): New global variable.
15349 (ppc_regmap): Remove __SPE__ #ifdef sections.
15350 (ppc_regmap_e500): New global variable.
15351 (ppc_cannot_store_register): Update __SPE__ special case.
15352 (ppc_get_hwcap): New function.
15353 (ppc_arch_setup): Use it to determine whether inferior supports
15354 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
15355 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
15356 Do not access registers if target does not support AltiVec.
15357 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
15358 Do not access registers if target does not support SPE.
15359 (target_regsets): Unconditionally include AltiVec and SPE regsets.
15360
15361 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
15362
15363 * linux-low.c (disabled_regsets, num_regsets): New.
15364 (use_regsets_p): Delete.
15365 (linux_wait_for_process): Clear disabled_regsets.
15366 (regsets_fetch_inferior_registers): Check and set it.
15367 (regsets_store_inferior_registers): Likewise.
15368 (linux_fetch_registers, linux_store_registers): Do not use
15369 use_regsets_p.
15370 (initialize_low): Allocate disabled_regsets.
15371
15372 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
15373
15374 * Makefile.in (LIBOBJS): New.
15375 (OBS): Use LIBOBJS.
15376 (memmem.o): New rule.
15377 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
15378 * configure: Regenerated.
15379
15380 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
15381
15382 * server.c (handle_query): Never return "unsupported" for
15383 qXfer:features:read queries.
15384
15385 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
15386
15387 * server.c (get_features_xml): Fix inverted condition.
15388 (handle_query): Always support qXfer:feature:read.
15389
15390 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
15391
15392 * server.c (wrapper_argv): New.
15393 (start_inferior): Handle wrapper_argv. If set, expect an extra
15394 trap.
15395 (gdbserver_usage): Document --wrapper.
15396 (main): Parse --wrapper.
15397
15398 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15399
15400 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
15401 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
15402 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
15403 (ppc_set_pc): Likewise.
15404 (ppc_arch_setup): New function.
15405 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
15406 of collect_register.
15407 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
15408
15409 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15410
15411 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
15412 instead of linux-ppc64-low.o.
15413 * linux-ppc64-low.c: Remove file.
15414 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
15415 (linux-ppc64-low.o): Remove rule.
15416
15417 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
15418 (init_registers_powerpc_64): Likewise.
15419 (ppc_regmap): Conditionally define depending on __powerpc64__.
15420 (ppc_cannot_store_register): Do not special-case "fpscr" when
15421 compiled on __powerpc64__.
15422 (ppc_collect_ptrace_register): New function.
15423 (ppc_supply_ptrace_register): New function.
15424 (ppc_breakpoint): Change type to "unsigned int".
15425 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
15426 (the_low_target): Conditionally provide initializers for the
15427 arch_setup member depending on __powerpc64__. Install
15428 collect_ptrace_register and supply_ptrace_register members.
15429
15430 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15431
15432 * regcache.h (gdbserver_xmltarget): Add extern declaration.
15433 * server.c (gdbserver_xmltarget): Define.
15434 (get_features_xml): Use it to replace "target.xml" and arch_string.
15435
15436 * configure.srv: Remove srv_xmltarget. Add XML files that were
15437 mentioned there to srv_xmlfiles instead. Remove conditional tests
15438 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
15439 srv_xmlfiles and srv_regobj to include all possible choices.
15440 * configure.ac (srv_xmltarget): Remove.
15441 (srv_xmlfiles): Do not add "target.xml".
15442 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
15443 checks for supplementary target information.
15444 * configure: Regenerate.
15445 * Makefile.in (XML_TARGET): Remove.
15446 (target.xml): Remove rule.
15447 (clean): Do not clean up target.xml.
15448 (.PRECIOUS): Do not mention target.xml.
15449
15450 * target.h (struct target_ops): Remove arch_string member.
15451 * linux-low.c (linux_arch_string): Remove.
15452 (linux_target_ops): Remove arch_string initializer.
15453 * linux-low.h (struct linux_target_ops): Remove arch_string member.
15454 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
15455 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
15456 * spu-low.c (spu_arch_string): Remove.
15457 (spu_target_ops): Remove arch_string initializer.
15458 * win32-low.c (win32_arch_string): Remove.
15459 (win32_target_ops): Remove arch_string initializer.
15460 * win32-low.h (struct win32_target_ops): Remove arch_string member.
15461 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
15462 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
15463
15464 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15465
15466 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
15467 by collect_ptrace_register and supply_ptrace_register hooks.
15468 * linux-low.c (fetch_register): Use supply_ptrace_register callback
15469 instead of checking for the_low_target.left_pad_xfer.
15470 (usr_store_inferior_registers): Use collect_ptrace_register callback
15471 instead of checking for the_low_target.left_pad_xfer.
15472
15473 * linux-s390-low.c (s390_collect_ptrace_register): New function.
15474 (s390_supply_ptrace_register): Likewise.
15475 (s390_fill_gregset): Call s390_collect_ptrace_register.
15476 (the_low_target): Update.
15477
15478 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
15479 (ppc_supply_ptrace_register): Likewise.
15480 (the_low_target): Update.
15481
15482 * linux-i386-low.c (the_low_target): Update.
15483 * linux-x86-64-low.c (the_low_target): Update.
15484
15485 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15486
15487 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
15488 reg-s390.o and reg-s390x.o.
15489
15490 * linux-low.c (new_inferior): New global variable.
15491 (linux_create_inferior, linux_attach): Set it.
15492 (linux_wait_for_process): Call the_low_target.arch_setup after the
15493 target has stopped for the first time.
15494 (initialize_low): Do not call the_low_target.arch_setup.
15495
15496 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
15497 (s390_set_pc): Likewise.
15498 (s390_arch_setup): New function.
15499 (the_low_target): Use s390_arch_setup as arch_setup routine.
15500
15501 * regcache.c (realloc_register_cache): New function.
15502 (set_register_cache): Call it for each existing regcache.
15503
15504 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15505
15506 * server.h (init_registers): Remove prototype.
15507
15508 * linux-low.h (struct linux_target_ops): Add arch_setup field.
15509 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
15510 instead of init_registers ().
15511 * linux-arm-low.c (init_registers_arm): Add prototype.
15512 (init_registers_arm_with_iwmmxt): Likewise.
15513 (the_low_target): Add initializer for arch_setup field.
15514 * linux-cris-low.c (init_registers_cris): Add prototype.
15515 (the_low_target): Add initializer for arch_setup field.
15516 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
15517 (the_low_target): Add initializer for arch_setup field.
15518 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
15519 (the_low_target): Add initializer for arch_setup field.
15520 * linux-ia64-low.c (init_registers_ia64): Add prototype.
15521 (the_low_target): Add initializer for arch_setup field.
15522 * linux-m32r-low.c (init_registers_m32r): Add prototype.
15523 (the_low_target): Add initializer for arch_setup field.
15524 * linux-m68k-low.c (init_registers_m68k): Add prototype.
15525 (the_low_target): Add initializer for arch_setup field.
15526 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
15527 (init_registers_mips64_linux): Likewise.
15528 (the_low_target): Add initializer for arch_setup field.
15529 * linux-ppc-low.c (init_registers_ppc): Add prototype.
15530 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
15531 (the_low_target): Add initializer for arch_setup field.
15532 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
15533 (init_registers_powerpc_64): Likewise.
15534 (the_low_target): Add initializer for arch_setup field.
15535 * linux-s390-low.c (init_registers_s390): Add prototype.
15536 (init_registers_s390x): Likewise.
15537 (the_low_target): Add initializer for arch_setup field.
15538 * linux-sh-low.c (init_registers_sh): Add prototype.
15539 (the_low_target): Add initializer for arch_setup field.
15540 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
15541 (the_low_target): Add initializer for arch_setup field.
15542 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
15543 (the_low_target): Add initializer for arch_setup field.
15544
15545 * win32-low.h (struct win32_target_ops): Add arch_setup field.
15546 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
15547 instead of init_registers ().
15548 * win32-arm-low.c (init_registers_arm): Add prototype.
15549 (the_low_target): Add initializer for arch_setup field.
15550 * win32-i386-low.c (init_registers_i386): Add prototype.
15551 (the_low_target): Add initializer for arch_setup field.
15552
15553 * spu-low.c (init_registers_spu): Add prototype.
15554 (initialize_low): Call initialie_registers_spu () instead of
15555 initialize_registers ().
15556
15557 2008-02-19 Pedro Alves <pedro@codesourcery.com>
15558
15559 * server.c (handle_v_requests): When handling the vRun and vAttach
15560 packets, if already debugging a process, don't kill it. Return an
15561 error instead.
15562
15563 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
15564
15565 * server.c (handle_query): Correct length check.
15566
15567 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
15568
15569 * win32-low.c (do_initial_child_stuff): Add process handle
15570 parameter. Set current_process_handle and current_process_id from the
15571 parameters. Clear globals.
15572 (win32_create_inferior): Don't set current_process_handle and
15573 current_process_id here. Instead pass them on the call to
15574 do_initial_child_stuff.
15575 (win32_attach): Likewise.
15576 (win32_clear_inferiors): New.
15577 (win32_kill): Don't close the current process handle or the
15578 current thread handle here. Instead call win32_clear_inferiors.
15579 (win32_detach): Don't open a new handle to the process. Call
15580 win32_clear_inferiors.
15581 (win32_join): Don't rely on current_process_handle; open a new
15582 handle using the process id.
15583 (win32_wait): Call win32_clear_inferiors when the inferior process
15584 has exited.
15585
15586 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
15587
15588 * server.c (monitor_show_help): Add "exit".
15589
15590 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
15591
15592 * Makefile.in (SFILES): Add linux-xtensa-low.c.
15593 (clean): Add reg-xtensa.c.
15594 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
15595 * configure.srv (xtensa*-*-linux*) New target.
15596 * linux-xtensa-low.c: New.
15597 * xtensa-xtregs.c: New.
15598
15599 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
15600
15601 * hostio.c: Don't include errno.h.
15602 (errno_to_fileio_errno): Move to hostio-errno.
15603 * hostio.c: (hostio_error): Remove the error parameter. Defer the
15604 error number outputting to the target->hostio_last_error callback.
15605 (hostio_packet_error): Use FILEIO_EINVAL directly.
15606 (handle_open, handle_pread, hostio_error, handle_unlink): Update
15607 calls to hostio_error.
15608 * hostio-errno.c: New.
15609 * server.h (hostio_last_error_from_errno): Declare.
15610 * target.h (target_ops): Add hostio_last_error member.
15611 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
15612 as hostio_last_error handler.
15613 * spu-low.c (spu_target_ops): Likewise.
15614 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
15615 (wince_hostio_last_error): New functions.
15616 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
15617 as hostio_last_error handler.
15618 (win32_target_ops) [!_WIN32_WCE]: Register
15619 hostio_last_error_from_errno as hostio_last_error handler.
15620 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
15621 (hostio-errno.o): New rule.
15622 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
15623 * configure.srv (srv_hostio_err_objs): New variable. Default to
15624 hostio-errno.o.
15625 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
15626 * configure: Regenerate.
15627
15628 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
15629
15630 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
15631 (linux_kill, linux_detach): Clean up the process list.
15632 * remote-utils.c (remote_open): Improve port number parsing.
15633 (putpkt_binary, input_interrupt): Only send interrupts if the target
15634 is running.
15635 * server.c (extended_protocol): Make static.
15636 (attached): Define earlier.
15637 (exit_requested, response_needed, program_argv): New variables.
15638 (target_running): New.
15639 (start_inferior): Clear attached here.
15640 (attach_inferior): Set attached here.
15641 (require_running): Define.
15642 (handle_query): Use require_running and target_running. Implement
15643 "monitor exit".
15644 (handle_v_attach, handle_v_run): New.
15645 (handle_v_requests): Use require_running. Handle vAttach and vRun.
15646 (gdbserver_usage): Update.
15647 (main): Redo argument parsing. Handle --debug and --multi. Handle
15648 --attach along with other options or after the port. Save
15649 program_argv. Support no initial program. Resynchronize
15650 communication with GDB after an error. Handle "monitor exit".
15651 Use require_running and target_running. Always allow the extended
15652 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
15653 restart in extended mode.
15654 * README: Refer to the GDB manual. Update --attach usage.
15655
15656 2007-12-20 Andreas Schwab <schwab@suse.de>
15657
15658 * linux-low.c (STACK_SIZE): Define.
15659 (linux_tracefork_child): Use it. Use __clone2 on ia64.
15660 (linux_test_for_tracefork): Likewise.
15661
15662 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
15663
15664 * linux-low.c (linux_wait_for_event): Update messages. Do not
15665 reinsert auto-delete breakpoints.
15666 * mem-break.c (struct breakpoint): Change return type of handler to
15667 int.
15668 (set_breakpoint_at): Update handler type.
15669 (reinsert_breakpoint_handler): Return 1 instead of calling
15670 delete_breakpoint.
15671 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
15672 setting a new one.
15673 (check_breakpoints): Delete auto-delete breakpoints and return 2.
15674 * mem-break.h (set_breakpoint_at): Update handler type.
15675 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
15676 * win32-low.c (auto_delete_breakpoint): New.
15677 (get_child_debug_event): Use it.
15678
15679 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
15680
15681 * configure.ac: Check for pread and pwrite.
15682 * hostio.c (handle_pread): Fall back to lseek and read.
15683 (handle_pwrite): Fall back to lseek and write.
15684 * config.in, configure: Regenerated.
15685
15686 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
15687
15688 * server.c (myresume): Add own_buf argument.
15689 (main): Update calls.
15690
15691 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
15692
15693 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
15694 * remote-utils.c (remote_open): Do not call disable_async_io.
15695 (block_async_io): Delete.
15696 (unblock_async_io): Make static.
15697 (initialize_async_io): New.
15698 * server.c (handle_v_cont): Handle async I/O here.
15699 (myresume): Likewise. Move other common resume tasks here...
15700 (main): ... from here. Call initialize_async_io. Disable async
15701 I/O before the main loop.
15702 * server.h (initialize_async_io): Declare.
15703 (block_async_io, unblock_async_io): Delete prototypes.
15704 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
15705
15706 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
15707
15708 * remote-utils.c (readchar): Allow binary data in received messages.
15709
15710 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15711
15712 * win32-low.c (attaching): New global.
15713 (win32_create_inferior): Clear the `attaching' global.
15714 (win32_attach): Set the `attaching' global.
15715 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
15716 attaching. Only set a breakpoint at the entry point if not
15717 attaching.
15718
15719 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15720
15721 * server.c (main): Don't report dll events on the initial
15722 connection on attaches.
15723
15724 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15725
15726 * server.c (main): Relax numerical bases supported for the pid of
15727 the --attach command line argument.
15728
15729 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15730
15731 * win32-low.c (win32_attach): Call OpenProcess before
15732 DebugActiveProcess, not after. Add last error output to error
15733 call.
15734
15735 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15736
15737 * win32-low.c (win32_get_thread_context)
15738 (win32_set_thread_context): New functions.
15739 (thread_rec): Use win32_get_thread_context.
15740 (continue_one_thread, win32_resume): Use win32_set_thread_context.
15741 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
15742 field.
15743
15744 2007-12-03 Leo Zayas
15745 Pedro Alves <pedro_alves@portugalmail.pt>
15746
15747 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
15748 global variables.
15749 (child_add_thread): Minor cleanup.
15750 (child_continue): Resume artificially suspended threads before
15751 calling ContinueDebugEvent.
15752 (suspend_one_thread): New.
15753 (fake_breakpoint_event): New.
15754 (get_child_debug_event): Change return type to int. Check here if
15755 gdb sent an interrupt request. If a soft interrupt was requested,
15756 fake a breakpoint event. Return 0 if there is no event to handle,
15757 and 1 otherwise.
15758 (win32_wait): Don't check here if gdb sent an interrupt request.
15759 Ensure there is a valid event to handle.
15760 (win32_request_interrupt): Add soft interruption method as last
15761 resort.
15762
15763 2007-12-03 Leo Zayas
15764 Pedro Alves <pedro_alves@portugalmail.pt>
15765
15766 * win32-low.h (win32_thread_info): Add descriptions to the
15767 structure members. Replace `suspend_count' counter by a
15768 `suspended' flag.
15769 * win32-low.c (thread_rec): Update condition of when to get the
15770 context from the inferior. Rely on ContextFlags being set if it
15771 has already been retrieved. Only suspend the inferior thread if
15772 we haven't already. Warn if that fails.
15773 (continue_one_thread): s/suspend_count/suspended/. Only call
15774 ResumeThread once. Warn if that fails.
15775
15776 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
15777
15778 * win32-low.c (win32_wait): Don't read from the inferior when it
15779 has already exited.
15780
15781 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
15782
15783 * Makefile.in (win32_low_h): New variable.
15784 (win32-low.o): Add dependency on $(win32_low_h).
15785 (win32-arm-low.o, win32-i386-low.o): New rules.
15786
15787 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
15788
15789 * hostio.c: Correct copyright year.
15790
15791 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
15792
15793 * Makefile.in (OBS): Add hostio.o.
15794 (hostio.o): New rule.
15795 * server.h (handle_vFile): Declare.
15796 * hostio.c: New file.
15797 * server.c (handle_v_requests): Take packet_len and new_packet_len
15798 for binary packets. Call handle_vFile.
15799 (main): Update call to handle_v_requests.
15800
15801 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
15802
15803 * linux-low.c: Include <sched.h>.
15804
15805 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
15806
15807 * linux-low.c (linux_tracefork_grandchild): New.
15808 (linux_tracefork_child): Use clone.
15809 (linux_test_for_tracefork): Use clone; allocate and free a stack.
15810
15811 2007-10-31 Joel Brobecker <brobecker@adacore.com>
15812
15813 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
15814
15815 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
15816
15817 * linux-low.c (handle_extended_wait): Handle unexpected signals.
15818
15819 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
15820
15821 * inferiors.c (change_inferior_id): Delete.
15822 (add_pid_to_list, pull_pid_from_list): New.
15823 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
15824 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
15825 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
15826 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
15827 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
15828 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
15829 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
15830 (using_threads): Always set to 1.
15831 (handle_extended_wait): New.
15832 (add_process): Do not set TID.
15833 (linux_create_inferior): Set must_set_ptrace_flags.
15834 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
15835 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
15836 (linux_thread_alive): Rename TID argument to LWPID.
15837 (linux_wait_for_process): Handle unknown processes. Do not use TID.
15838 (linux_wait_for_event): Do not use TID or check using_threads. Update
15839 call to dead_thread_notify. Call handle_extended_wait.
15840 (linux_create_inferior): Use PTRACE_SETOPTIONS.
15841 (send_sigstop): Delete sigstop_sent.
15842 (wait_for_sigstop): Avoid TID.
15843 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
15844 (linux_test_for_tracefork): New.
15845 (linux_lookup_signals): Use thread_db_active and
15846 linux_supports_tracefork_flag.
15847 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
15848 * linux-low.h (get_process_thread): Avoid TID.
15849 (struct process_ifo): Move thread_known and tid to the end. Remove
15850 sigstop_sent.
15851 (linux_attach_lwp, thread_db_init): Update prototypes.
15852 * server.h (change_inferior_id): Delete prototype.
15853 (add_pid_to_list, pull_pid_from_list): New prototypes.
15854 * thread-db.c (thread_db_use_events): New.
15855 (find_first_thread): Rename to...
15856 (find_one_thread): ...this. Update callers and messages. Do not
15857 call fatal. Check thread_db_use_events. Do not call
15858 change_inferior_id or new_thread_notify.
15859 (maybe_attach_thread): Update. Do not call new_thread_notify.
15860 (thread_db_init): Set thread_db_use_events. Check use_events.
15861 * utils.c (fatal, warning): Correct message prefix.
15862
15863 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
15864
15865 * Makefile.in (clean): Remove new files.
15866 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
15867 (powerpc-64.o, powerpc-64.c): New rules.
15868 * configure.srv: Use alternate register sets for powerpc64-*-linux*
15869 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
15870 with SPE.
15871 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
15872 SPE targets.
15873 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
15874 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
15875 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
15876 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
15877 (target_regsets): Add AltiVec and SPE register sets.
15878 * configure.ac: Check for AltiVec and SPE.
15879 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
15880 (ppc_fill_vrregset, ppc_store_vrregset): New.
15881 (target_regsets): Add AltiVec register set.
15882 * configure: Regenerated.
15883
15884 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
15885
15886 * linux-low.c (O_LARGEFILE): Define.
15887 (linux_read_memory): Use /proc/PID/mem.
15888 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
15889 * configure, config.in: Regenerated.
15890
15891 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
15892
15893 * linux-low.c (linux_wait_for_event): Do not pass signals while
15894 single-stepping.
15895
15896 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
15897
15898 * win32-low.c (create_process): New.
15899 (win32_create_inferior): Use create_process instead of
15900 CreateProcess. If create_process failed retry appending an ".exe"
15901 suffix. Store the GetLastError result immediatelly after
15902 create_process calls and use it on the call to error.
15903
15904 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
15905
15906 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
15907
15908 2007-08-23 Joel Brobecker <brobecker@adacore.com>
15909
15910 * configure.ac: Switch license to GPLv3.
15911
15912 2007-08-01 Michael Snyder <msnyder@access-company.com>
15913
15914 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
15915
15916 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
15917
15918 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
15919 typedef.
15920 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
15921 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
15922 CloseToolhelp32Snapshot.
15923 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
15924 CloseToolhelp32Snapshot.
15925
15926 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
15927
15928 * server.c (main): Check for inferior exit before main loop.
15929
15930 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
15931
15932 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
15933 instead of on tmp_desc.
15934
15935 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
15936 Daniel Jacobowitz <dan@codesourcery.com>
15937
15938 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
15939 (add_thread): Minor cleanups.
15940 (clear_inferiors): Move lower in the file. Clear the DLL
15941 list.
15942 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
15943 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
15944 (xml_escape_text): New.
15945 * server.c (handle_query): Handle qXfer:libraries:read. Report it
15946 for qSupported.
15947 (handle_v_cont): Report errors.
15948 (gdbserver_version): Update.
15949 (main): Correct size of own_buf. Do not report initial DLL events.
15950 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
15951 (unloaded_dll, xml_escape_text): New.
15952 * win32-low.c (enum target_waitkind): Update comments.
15953 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
15954 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
15955 (win32_EnumProcessModules, win32_GetModuleInformation)
15956 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
15957 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
15958 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
15959 (win32_Module32First, win32_Module32Next, load_toolhelp)
15960 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
15961 (get_child_debug_event): Handle DLL events.
15962 (win32_wait): Likewise.
15963
15964 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
15965
15966 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
15967 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
15968
15969 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
15970
15971 * win32-low.c (handle_output_debug_string): Ignore event if not
15972 waiting.
15973
15974 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
15975
15976 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
15977
15978 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
15979
15980 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
15981
15982 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
15983
15984 * inferiors.c (change_inferior_id): Add comment.
15985 * linux-low.c (check_removed_breakpoint): Add an early
15986 prototype. Improve debug output.
15987 (linux_attach): Doc update.
15988 (linux_detach_one_process, linux_detach): Clean up before releasing
15989 each process.
15990 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
15991 * linux-low.h (struct process_info): Doc improvement.
15992 * mem-break.c (delete_all_breakpoints): New.
15993 * mem-break.h (delete_all_breakpoints): New prototype.
15994 * thread-db.c (find_first_thread): New.
15995 (thread_db_create_event): Call it instead of
15996 thread_db_find_new_threads. Clean up unused variables.
15997 (maybe_attach_thread): Remove first thread handling.
15998 (thread_db_find_new_threads): Use find_first_thread.
15999 (thread_db_get_tls_address): Likewise.
16000
16001 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
16002
16003 * thread-db.c (thread_db_find_new_threads): Add prototype.
16004 (thread_db_create_event): Check for the main thread before adding
16005 a new thread.
16006 (maybe_attach_thread): Only enable event reporting if TID == 0.
16007 (thread_db_get_tls_address): Check for new threads.
16008
16009 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
16010
16011 * linux-low.c (linux_create_inferior): Try execv before execvp.
16012 * spu-low.c (spu_create_inferior): Likewise.
16013
16014 2007-06-13 Mike Frysinger <vapier@gentoo.org>
16015
16016 * linux-low.c (linux_create_inferior): Change execv to execvp.
16017 * spu-low.c (spu_create_inferior): Likewies.
16018
16019 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
16020
16021 * Makefile.in (clean): Clean new files instead of deleted ones.
16022 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
16023 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
16024 rules.
16025 * configure.srv: Specify XML files and new regformats for MIPS and
16026 MIPS64 GNU/Linux.
16027 * linux-mips-low.c (mips_num_regs): Set to only used registers.
16028 (mips_regmap): Do not fetch $0. Remove unused registers. Add
16029 an entry for the restart register.
16030 (mips_cannot_fetch_register, mips_cannot_store_register)
16031 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
16032 register names to match the XML descriptions.
16033 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
16034 restart register instead of $0.
16035
16036 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
16037 Markus Deuling <deuling@de.ibm.com>
16038
16039 * remote-utils.c (decode_xfer_write): New function.
16040 * server.h (decode_xfer_write): Add prototype.
16041 * server.c (handle_query): Add PACKET_LEN argument. Support
16042 qXfer:spu:read and qXfer:spu:write packets.
16043 (main): Pass packet_len to handle_query.
16044 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
16045 * target.h (target_ops): Add qxfer_spu.
16046
16047 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
16048
16049 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
16050 accessing non-seekable spufs files.
16051
16052 2007-05-16 Markus Deuling <deuling@de.ibm.com>
16053
16054 * server.c (handle_query): Add reply for qC packet.
16055
16056 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16057 Leo Zayas <lerele@champenstudios@com>
16058
16059 * server.h (check_remote_input_interrupt_request): New function.
16060 * remote_utils.c (INVALID_DESCRIPTOR): New define.
16061 (remote_desc): Initialize with INVALID_DESCRIPTOR.
16062 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
16063 (check_remote_input_interrupt_request): New function.
16064 * server.h (check_remote_input_interrupt_request): Declare.
16065 * win32-low.c (winapi_DebugBreakProcess,
16066 winapi_GenerateConsoleCtrlEvent): New typedefs.
16067 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
16068 to 250 ms.
16069 (win32_wait): Check for remote interrupt request
16070 with check_remote_input_interrupt_request.
16071 (win32_request_interrupt): New function.
16072 (win32_target_op): Set request_interrupt to win32_request_interrupt.
16073
16074 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16075
16076 * win32-low.c (debug_registers_changed,
16077 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
16078 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
16079 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
16080 (thread_rec): Get context using the low target.
16081 (child_add_thread): Call thread_added on the low target,
16082 which does the same thing.
16083 (regptr): Delete.
16084 (do_initial_child_stuff): Remove debug registers references.
16085 Set context using the low target. Resume threads after
16086 setting the contexts.
16087 (child_continue): Remove dead variable. Remove debug
16088 registers references.
16089 (child_fetch_inferior_registers): Go through the low target.
16090 (do_child_store_inferior_registers): Remove.
16091 (child_store_inferior_registers): Go through the low target.
16092 (win32_resume): Remove debug registers references.
16093 Set context using the low target.
16094 (handle_exception): Change return type to void. Don't record
16095 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
16096 first chance exception.
16097 (get_child_debug_event): Change return type to void. Remove
16098 goto loop. Always return after waiting for debug event.
16099 (win32_wait): Convert to switch statement. Handle spurious
16100 events.
16101
16102 * win32-i386-low.c (debug_registers_changed,
16103 debug_registers_used): New.
16104 (initial_stuff): Rename to ...
16105 (i386_initial_stuff): ... this. Clear debug registers
16106 state variables.
16107 (store_debug_registers): Delete.
16108 (i386_get_thread_context): New.
16109 (load_debug_registers): Delete.
16110 (i386_set_thread_context): New.
16111 (i386_thread_added): New.
16112 (single_step): Rename to ...
16113 (i386_single_step): ... this.
16114 (do_fetch_inferior_registers): Rename to ...
16115 (i386_fetch_inferior_register): ... this.
16116 (i386_store_inferior_register): New.
16117 (the_low_target): Adapt to new interface.
16118
16119 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
16120 (arm_get_thread_context): New.
16121 (arm_set_thread_context): New.
16122 (regptr): New.
16123 (do_fetch_inferior_registers): Rename to ...
16124 (arm_fetch_inferior_register): ... this.
16125 (arm_store_inferior_register): New.
16126 (arm_wince_breakpoint): Reimplement as unsigned long.
16127 (arm_wince_breakpoint_len): Define.
16128 (the_low_target): Adapt to new interface.
16129
16130 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
16131 load_debug_registers. Add get_thread_context, set_thread_context,
16132 thread_added and store_inferior_register. Rename
16133 fetch_inferior_registers to fetch_inferior_register.
16134 (regptr): Remove declaration.
16135
16136 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16137
16138 * linux-low.c (linux_detach): Change return type to int. Return 0.
16139 * spu-low.c (spu_detach): Likewise.
16140
16141 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16142
16143 * target.h (target_ops): Change return type of detach to int.
16144 Add join.
16145 (join_inferior): New.
16146 * server.c (main): Don't skip detach support on mingw32.
16147 If the inferior doesn't support detaching return error.
16148 Call join_inferior instead of using waitpid.
16149 * linux-low.c (linux_join): New.
16150 (linux_target_op): Add linux_join.
16151 * spu-low.c (spu_join): New.
16152 (spu_target_ops): Add spu_join.
16153 * win32-low.c (win32_detach): Adapt to new interface.
16154 Reopen current_process_handle before detaching. Issue a child
16155 resume before detaching.
16156 (win32_join): New.
16157 (win32_target_op): Add win32_join.
16158
16159 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16160
16161 * win32-low.c (win32-attach): Fix return value.
16162 * target.h (target_ops): Describe ATTACH return values.
16163
16164 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16165
16166 * win32-low.c (GETPROCADDRESS): Define.
16167 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
16168 (winapi_DebugSetProcessKillOnExit): Likewise.
16169 (win32_create_inferior): Force usage of ansi CreateProcessA.
16170 (win32_attach): Use GETPROCADDRESS.
16171 (win32_detach): Likewise.
16172
16173 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16174
16175 * win32-low.c (win32_wait): Don't use WSTOPSIG.
16176
16177 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
16178
16179 * win32-low.c: Commit leftover changes from 2007-03-29.
16180
16181 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
16182
16183 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
16184 fields short instead of int. Add explicit padding.
16185 (i387_cache_to_fsave): Remove unnecessary casts.
16186 (i387_fsave_to_cache): Doc fix.
16187 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
16188
16189 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
16190
16191 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
16192 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
16193
16194 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
16195
16196 * configure.srv (arm*-*-mingw32ce*): Move near the other
16197 arm targets.
16198
16199 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
16200
16201 * configure.ac: Add errno checking.
16202 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
16203 sys/file.h and malloc.h.
16204 (AC_CHECK_DECLS): Add perror.
16205 (srv_mingwce): Handle.
16206 * configure.srv (i[34567]86-*-cygwin*): Add
16207 win32-i386-low.o to srv_tgtobj.
16208 (i[34567]86-*-mingw*): Likewise.
16209 (arm*-*-mingw32ce*): Add case.
16210 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
16211 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
16212 [__MINGW32CE__] (strerror): New function.
16213 [__MINGW32CE__] (errno): Define to GetLastError.
16214 [__MINGW32CE__] (COUNTOF): New macro.
16215 (remote_open): Remove extra close call.
16216 * mem-break.c (delete_breakpoint_at): New function.
16217 * mem-break.h (delete_breakpoint_at): Declare.
16218 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
16219 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
16220 [USE_WIN32API] (read, write): Add char* casts.
16221 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
16222 * server.h: Include wincecompat.h on Windows CE.
16223 [HAVE_ERRNO_H]: Check.
16224 (perror): Declare if not declared.
16225 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
16226 (perror_with_name): Remove errno declaration.
16227 * wincecompat.h: New.
16228 * wincecompat.c: New.
16229 * win32-low.h: New.
16230 * win32-arm-low.c: New.
16231 * win32-i386-low.c: New.
16232 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
16233 (OUTMSG2): Make it safe.
16234 (_T): New macro.
16235 (COUNTOF): New macro.
16236 (NUM_REGS): Get it from the low target.
16237 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
16238 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
16239 (thread_rec): Let low target handle debug registers.
16240 (child_add_thread): Likewise.
16241 (child_init_thread_list): Likewise.
16242 (continue_one_thread): Likewise.
16243 (regptr): New.
16244 (do_child_fetch_inferior_registers): Move to ...
16245 * win32-i386-low.c: ... here, and rename to ...
16246 (do_fetch_inferior_registers): ... this.
16247 * win32-low.c (child_fetch_inferior_registers):
16248 Go through the low target.
16249 (do_child_store_inferior_registers): Use regptr.
16250 (strwinerror): New function.
16251 (win32_create_inferior): Handle Windows CE.
16252 Use strwinerror instead of strerror on Windows error
16253 codes. Add program to the error output.
16254 Don't close the main thread handle on Windows CE.
16255 (win32_attach): Use coredll.dll on Windows CE.
16256 (win32_kill): Close current process and current
16257 thread handles.
16258 (win32_detach): Use coredll.dll on Windows CE.
16259 (win32_resume): Let low target handle debug registers, and
16260 step request.
16261 (handle_exception): Add/Remove initial breakpoint. Avoid
16262 non-existant WSTOPSIG on Windows CE.
16263 (win32_read_inferior_memory): Cast to remove warning.
16264 (win32_arch_string): Go through the low target.
16265 (initialize_low): Call set_breakpoint_data with the low
16266 target's breakpoint.
16267 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
16268 FOP_REGNUM, mappings): Move to ...
16269 * win32-i386-low.c: ... here.
16270 * win32-low.c (win32_thread_info): Move to ...
16271 * win32-low.h: ... here.
16272 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
16273 win32-arm-low.c and wincecompat.c.
16274 (all:): Add $EXEEXT.
16275 (install-only:): Likewise.
16276 (gdbserver:): Likewise.
16277 (gdbreplay:): Likewise.
16278 * config.in: Regenerate.
16279 * configure: Regenerate.
16280
16281 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
16282
16283 * win32-low.c: Rename typedef thread_info to
16284 win32_thread_info throughout.
16285
16286 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
16287
16288 * win32-i386-low.c: Rename to ...
16289 * win32-low.c: ... this.
16290 * configure.srv: Replace win32-i386-low.o with win32-low.o.
16291 * Makefile.in: Likewise.
16292
16293 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
16294
16295 * remote-utils.c (monitor_output): Constify msg parameter.
16296 * server.h (monitor_output): Likewise.
16297 * win32-i386-low.c (handle_output_debug_string): New.
16298 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
16299 handle_output_debug_string.
16300 (get_child_debug_event): Likewise.
16301
16302 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
16303
16304 * server.c (main): Correct strtoul check.
16305
16306 2007-03-27 Jon Ringle <jon@ringle.org>
16307
16308 * linux-low.c: Check __ARCH_HAS_MMU__ also.
16309
16310 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
16311
16312 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
16313
16314 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
16315
16316 * terminal.h: Check HAVE_SGTTY_H.
16317
16318 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
16319
16320 * remote-utils.c (remote_open): Print out the assigned port number.
16321
16322 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
16323
16324 * remote-utils.c (monitor_output): New function.
16325 * server.c (debug_threads): Define here.
16326 (monitor_show_help): New function.
16327 (handle_query): Handle qRcmd.
16328 (main): Do not handle 'd' packet.
16329 * server.h (debug_threads, remote_debug, monitor_output): Declare.
16330 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
16331 of debug_threads.
16332
16333 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16334
16335 * Makefile.in (EXEEXT): New.
16336 (clean): Use $(EXEEXT).
16337
16338 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16339
16340 * target.h (target_ops): Rename send_signal to request_interrupt,
16341 and remove enum target_signal parameter.
16342 * linux-low.c (linux_request_interrupt): Rename from
16343 linux_send_signal, and always send SIGINT.
16344 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
16345 and always send SIGINT.
16346 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
16347 of send_signal.
16348 (input_interrupt): Likewise.
16349
16350 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16351
16352 * server.c (get_features_xml): Check if target implemented
16353 arch_string.
16354 * win32-i386-low.c (win32_arch_string): New.
16355 (win32_target_ops): Add win32_arch_string as arch_string member.
16356
16357 2007-02-22 Markus Deuling <deuling@de.ibm.com>
16358
16359 * spu-low.c (spu_arch_string): New.
16360 (spu_target_ops): Add spu_arch_string.
16361
16362 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
16363
16364 * remote-utils.c: Remove HAVE_TERMINAL_H check.
16365 * configure.ac: Do not check for terminal.h.
16366 * configure, config.in: Regenerated.
16367
16368 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
16369
16370 * Makefile.in (OBS): Add $(XML_BUILTIN).
16371 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
16372 (clean): Update.
16373 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
16374 (arm-with-iwmmxt.c): New.
16375 * config.in, configure: Regenerate.
16376 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
16377 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
16378 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
16379 (arm*-*-linux*): Add iWMMXt and regset support.
16380 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
16381 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
16382 (arm_store_wmmxregset, target_regsets): New.
16383 * server.c (get_features_xml): Take annex argument. Check builtin
16384 XML documents.
16385 (handle_query): Handle multiple annexes.
16386
16387 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
16388
16389 * remote-utils.c [USE_WIN32API] (read, write): Define.
16390 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
16391 write.
16392
16393 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
16394
16395 * linux-i386-low.c (the_low_target): Set arch_string.
16396 * linux-x86-64-low.c (the_low_target): Likewise.
16397 * linux-low.c (linux_arch_string): New.
16398 (linux_target_ops): Add it.
16399 * linux-low.h (struct linux_target_ops): Add arch_string.
16400 * server.c (write_qxfer_response): Use const void * for DATA.
16401 (get_features_xml): New.
16402 (handle_query): Handle qXfer:features:read. Report it for qSupported.
16403 * target.h (struct target_ops): Add arch_string method.
16404
16405 2007-01-03 Denis Pilat <denis.pilat@st.com>
16406 Daniel Jacobowitz <dan@codesourcery.com>
16407
16408 * linux-low.c (linux_kill): Handle being called with no threads.
16409 * win32-i386-low.c (win32_kill): Likewise.
16410 (get_child_debug_event): Clear current_process_handle.
16411
16412 2006-12-30 Denis PILAT <denis.pilat@st.com>
16413 Daniel Jacobowitz <dan@codesourcery.com>
16414
16415 * remote-utils.c (remote_open): Check the type of specified
16416 serial port devices before opening them.
16417 * server.c (main): Kill the inferior if an error occurs during
16418 the first remote_open.
16419
16420 2006-12-05 Markus Deuling <deuling@de.ibm.com>
16421
16422 * README: Update supported targets.
16423
16424 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
16425
16426 * Makefile.in (clean): Remove reg-mips64.c.
16427 (reg-mips64.c, reg-mips64.o): New rules.
16428 * configure.srv: Handle mips64. Include regset support for mips.
16429 * linux-mips-low.c (union mips_register): New.
16430 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
16431 (mips_breakpoint, mips_breakpoint_at): Use int.
16432 (mips_collect_register, mips_supply_register)
16433 (mips_collect_register_32bit, mips_supply_register_32bit)
16434 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
16435 (mips_store_fpregset, target_regsets): New.
16436 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
16437
16438 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
16439
16440 * configure.srv: Add target "spu*-*-*".
16441 * Makefile.in (clean): Remove reg-spu.c.
16442 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
16443 * spu-low.c: New file.
16444
16445 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
16446
16447 * configure.ac: Correct td_thr_tls_get_addr test.
16448 * configure: Regenerated.
16449
16450 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
16451
16452 * linux-low.c (linux_wait_for_event): Reformat. Use the
16453 pass_signals array.
16454 * remote-utils.c (decode_address_to_semicolon): New.
16455 * server.c (pass_signals, handle_general_set): New.
16456 (handle_query): Mention QPassSignals for qSupported.
16457 (main): Call handle_general_set.
16458 * server.h (pass_signals, decode_address_to_semicolon): New.
16459
16460 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
16461
16462 * server.c (handle_query): Correct error handling for read_auxv.
16463
16464 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
16465
16466 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
16467 and srv_linux_thread_db to yes.
16468 * linux-s390-low.c (s390_fill_gregset): New function.
16469 (target_regsets): Define data structure.
16470
16471 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
16472
16473 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
16474 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
16475 * config.in, configure: Regenerated.
16476 * inferiors.c (gdb_id_to_thread): New function.
16477 (gdb_id_to_thread_id): Use it.
16478 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
16479 * linux-low.h (struct process_info): Add th member.
16480 (thread_db_get_tls_address): New prototype.
16481 * remote-utils.c (decode_address): Make non-static.
16482 * server.c (handle_query): Handle qGetTLSAddr.
16483 * server.h (gdb_id_to_thread, decode_address): New prototypes.
16484 * target.h (struct target_ops): Add get_tls_address.
16485 * thread-db.c (maybe_attach_thread): Save the thread handle.
16486 (thread_db_get_tls_address): New.
16487
16488 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
16489
16490 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
16491 (linux_resume_one_process): Take a siginfo_t *. Update all
16492 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
16493 (struct pending_signals): Add a siginfo_t.
16494 (linux_wait_for_process): Always set last_status.
16495 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
16496 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
16497 * linux-low.h (struct process_info): Add last_status.
16498
16499 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
16500
16501 * remote-utils.c (try_rle): New function.
16502 (putpkt_binary): Use it.
16503
16504 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
16505
16506 * Makefile.in (clean): Clean reg-x86-64-linux.c.
16507 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
16508 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
16509 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
16510 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
16511 point registers.
16512
16513 2006-08-08 Richard Sandiford <richard@codesourcery.com>
16514
16515 * server.c (terminal_fd): New variable.
16516 (old_foreground_pgrp): Likewise.
16517 (restore_old_foreground_pgrp): New function.
16518 (start_inferior): Record the terminal file descriptor in terminal_fd
16519 and its original foreground group in old_foreground_pgrp. Register
16520 restore_old_foreground_pgrp with atexit().
16521
16522 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
16523
16524 * server.c (handle_query): Correct qPart to qXfer.
16525
16526 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
16527
16528 * configure.ac: Check for more headers which are missing on
16529 Windows. Automatically supply -lwsock32 and USE_WIN32API.
16530 * configure.srv: Add Cygwin and mingw32.
16531 * remote-utils.c: Don't include headers unconditionally which
16532 are missing on mingw32. Include <winsock.h> for mingw32.
16533 (remote_open): Adjust for mingw32 support. Flush
16534 standard error after writing to it.
16535 (remote_close, putpkt_binary, input_interrupt, block_async_io)
16536 (unblock_async_io, enable_async_io, disable_async_io)
16537 (readchar, getpkt): Update for Winsock support.
16538 (prepare_resume_reply): Expect a protocol signal number.
16539 * server.c: Disable <sys/wait.h> on mingw32.
16540 (start_inferior): Adjust for mingw32 support. Flush
16541 standard error after writing to it.
16542 (attach_inferior): Likewise. Use protocol signal
16543 numbers.
16544 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
16545 and names.
16546 * win32-i386-low.c: New file.
16547 * Makefile.in (XM_CLIBS): Set.
16548 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
16549 (win32-i386-low.o): New dependency rule.
16550 * linux-low.c (linux_wait): Use target signal numbers.
16551 * target.h (struct target_ops): Doc fix.
16552 * server.h (target_signal_to_name): New prototype.
16553 * gdbreplay.c: Don't include headers unconditionally which
16554 are missing on mingw32. Include <winsock.h> for mingw32.
16555 (remote_close, remote_open): Adjust for Winsock support.
16556 * configure, config.in: Regenerated.
16557
16558 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
16559
16560 * server.c (decode_xfer_read, write_qxfer_response): New.
16561 (handle_query): Take a packet length argument. Handle
16562 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
16563 the qSupported response.
16564 (main): Update call to handle_query.
16565
16566 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
16567
16568 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
16569 (putpkt_binary): Renamed from putpkt and adjusted for binary
16570 data.
16571 (putpkt): New wrapper for putpkt_binary.
16572 (readchar): Don't mask off the high bit.
16573 (decode_X_packet): New function.
16574 * server.c (main): Call putpkt_binary if a handler sets the packet
16575 length. Save the length of the incoming packet. Handle 'X'.
16576 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
16577
16578 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
16579
16580 * server.c (handle_query): Handle qSupported.
16581
16582 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
16583
16584 * remote-utils.c (all_symbols_looked_up): New variable.
16585 (look_up_one_symbol): Check it.
16586 * server.h (look_up_one_symbol): New declaration.
16587 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
16588
16589 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
16590
16591 * Makefile.in (linux-arm-low.o): Update dependencies.
16592 * linux-arm-low.c: Include "gdb_proc_service.h".
16593 (PTRACE_GET_THREAD_AREA): Define.
16594 (ps_get_thread_area): New function.
16595
16596 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
16597
16598 * configure.srv (m68k*-*-uclinux*): New target.
16599 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
16600 (linux_resume_one_process): Remove extraneous cast.
16601 (linux_read_offsets): New.
16602 (linux_target_op): Add linux_read_offsets on mmuless systems.
16603 * server.c (handle_query): Add qOffsets logic.
16604 * target.h (struct target_ops): Add read_offsets.
16605
16606 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
16607
16608 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
16609 (PTRACE_GET_THREAD_AREA): Define.
16610 (ps_get_thread_area): New function.
16611 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
16612 (linux-x86-64-low.o): Update.
16613
16614 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
16615
16616 * configure.ac: Remove checks for prfpregset_t.
16617 * gdb_proc_service.h: New file.
16618 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
16619 new "gdb_proc_service.h".
16620 * proc-service.c: Likewise.
16621 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
16622 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
16623 * Makefile.in (gdb_proc_service_h): Updated.
16624 * configure, config.in: Regenerated.
16625
16626 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
16627
16628 * remote-utils.c (prepare_resume_reply): Move declaration
16629 of gdb_id_from_wait to the top of the block.
16630
16631 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
16632
16633 * linux-low.c (regsets_store_inferior_registers): Read the regset
16634 from the target before filling it.
16635
16636 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
16637
16638 * server.c (attach_inferior): Return SIGTRAP for a successful
16639 attach.
16640
16641 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
16642
16643 * Makefile.in (OBS): Add version.o.
16644 (STAGESTUFF): Delete.
16645 (version.o): Add dependencies.
16646 (version.c): Replace rule.
16647 (clean): Remove version.c.
16648 * server.c (gdbserver_version): New.
16649 (gdbserver_usage): Use printf.
16650 (main): Handle --version and --help.
16651 * server.h (version, host_name): Add declarations.
16652
16653 2005-12-23 Eli Zaretskii <eliz@gnu.org>
16654
16655 * linux-arm-low.c:
16656 * linux-arm-low.c:
16657 * inferiors.c:
16658 * i387-fp.h:
16659 * i387-fp.c:
16660 * gdbreplay.c:
16661 * regcache.c:
16662 * proc-service.c:
16663 * mem-break.h:
16664 * mem-break.c:
16665 * linux-x86-64-low.c:
16666 * linux-sh-low.c:
16667 * linux-s390-low.c:
16668 * linux-ppc64-low.c:
16669 * linux-ppc-low.c:
16670 * linux-mips-low.c:
16671 * linux-m68k-low.c:
16672 * linux-m32r-low.c:
16673 * linux-low.h:
16674 * linux-low.c:
16675 * linux-ia64-low.c:
16676 * linux-i386-low.c:
16677 * linux-crisv32-low.c:
16678 * thread-db.c:
16679 * terminal.h:
16680 * target.h:
16681 * target.c:
16682 * server.h:
16683 * server.c:
16684 * remote-utils.c:
16685 * regcache.h:
16686 * utils.c:
16687 * Makefile.in:
16688 * configure.ac:
16689 * gdbserver.1: Add (C) after Copyright. Update the FSF
16690 address.
16691
16692 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
16693
16694 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
16695 (arm_breakpoint_at): Recognize both breakpoints.
16696 (the_low_target): Use the correct breakpoint instruction.
16697
16698 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
16699
16700 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
16701 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
16702 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
16703 (the_low_target): Update.
16704
16705 2005-10-25 Andreas Schwab <schwab@suse.de>
16706
16707 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
16708
16709 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
16710 (ia64_num_regs): Reduce to 462.
16711
16712 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
16713
16714 * acinclude.m4: Correct quoting.
16715 * aclocal.m4: Regenerated.
16716
16717 Suggested by SZOKOVACS Robert <szo@ies.hu>:
16718 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
16719 (thread_db_init): Call thread_db_err_str.
16720 * configure.ac: Check for TD_VERSION.
16721 * config.in, configure: Regenerated.
16722
16723 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16724
16725 * server.h (error, fatal, warning): Add ATTR_FORMAT.
16726
16727 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16728
16729 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
16730 is not available. Define HAVE_PTRACE_GETREGS if it is.
16731 * config.in, configure: Regenerated.
16732 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
16733 * linux-i386-low.c, linux-m68k-low.c: Update to use
16734 HAVE_PTRACE_GETREGS.
16735 * linux-low.c (regsets_fetch_inferior_registers)
16736 (regsets_store_inferior_registers): Only return 0 if we processed
16737 GENERAL_REGS.
16738 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
16739 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
16740
16741 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16742
16743 * inferiors.c (struct thread_info): Add gdb_id.
16744 (add_thread): Add gdb_id argument.
16745 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
16746 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
16747 calls to add_thread.
16748 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
16749 * server.c (handle_query): Use thread_to_gdb_id.
16750 (handle_v_cont, main): Use gdb_id_to_thread_id.
16751 * server.h (add_thread): Update prototype.
16752 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
16753 prototypes.
16754
16755 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16756
16757 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
16758 left-padded registers.
16759 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
16760 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
16761
16762 2005-07-01 Steve Ellcey <sje@cup.hp.com>
16763
16764 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
16765 * configure: Regenerate.
16766 * config.in: Regenerate.
16767 * server.h (NEED_DECLARATION_STRERROR):
16768 Replace with !HAVE_DECL_STRERROR.
16769
16770 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
16771
16772 * linux-low.c (linux_wait, linux_send_signal): Don't test
16773 an unsigned long variable for > 0 if it could be MAX_ULONG.
16774 * server.c (myresume): Likewise.
16775 * target.c (set_desired_inferior): Likewise.
16776
16777 2005-06-13 Mark Kettenis <kettenis@gnu.org>
16778
16779 * configure.ac: Simplify and improve check for socklen_t.
16780 * configure, config.in: Regenerate.
16781
16782 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
16783
16784 * acconfig.h: Remove.
16785 * configure.ac: Add a test for socklen_t. Use three-argument
16786 AC_DEFINE throughout.
16787 * config.in: Regenerated using autoheader 2.59.
16788 * configure: Regenerated.
16789
16790 * gdbreplay.c (socklen_t): Provide a default.
16791 (remote_open): Use socklen_t.
16792 * remote-utils.c (socklen_t): Provide a default.
16793 (remote_open): Use socklen_t.
16794 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
16795 unsigned char.
16796
16797 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
16798 char for buffers.
16799 * linux-low.c (linux_read_memory, linux_write_memory)
16800 (linux_read_auxv): Likewise.
16801 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
16802 (check_mem_write): Likewise.
16803 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
16804 Likewise.
16805 * regcache.c (struct inferior_rgcache_data, registers_to_string)
16806 (registers_from_string, register_data): Likewise.
16807 * server.c (handle_query, main): Likewise.
16808 * server.h (convert_ascii_to_int, convert_int_to_ascii)
16809 (decode_M_packet): Likewise.
16810 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
16811 * target.h (struct target_ops): Update read_memory, write_memory,
16812 and read_auxv.
16813 (read_inferior_memory, write_inferior_memory): Update.
16814 * linux-low.h (struct linux_target_ops): Change type of breakpoint
16815 to unsigned char *.
16816 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
16817 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
16818 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
16819 linux-s390-low.c, linux-sh-low.c: Update for changes in
16820 read_inferior_memory and the_low_target->breakpoint.
16821
16822 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
16823
16824 * Makefile.in (SFILES): Add linux-ppc64-low.c.
16825 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
16826 * configure.srv: Add powerpc64-*-linux*.
16827 * linux-ppc64-low.c: New file.
16828
16829 2005-05-23 Orjan Friberg <orjanf@axis.com>
16830
16831 * linux-cris-low.c: New file with support for CRIS.
16832 * linux-crisv32-low.c: Ditto for CRISv32.
16833 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
16834 (clean): Add reg-cris.c and reg-crisv32.c.
16835 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
16836 reg-crisv32.o, and reg-crisv32.c to make rules.
16837 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
16838 recognized targets.
16839
16840 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
16841
16842 * linux-low.c (fetch_register): Ensure buffer size is a multiple
16843 of sizeof (PTRACE_XFER_TYPE).
16844 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
16845
16846 2005-05-12 Orjan Friberg <orjanf@axis.com>
16847
16848 * target.h (struct target_ops): Add insert_watchpoint,
16849 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
16850 pointers for hardware watchpoint support.
16851 * linux-low.h (struct linux_target_ops): Ditto.
16852 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
16853 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
16854 to linux_target_ops.
16855 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
16856 reply packet.
16857 * server.c (main): Recognize 'Z' and 'z' packets.
16858
16859 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
16860
16861 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
16862 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
16863 (the_low_target): Add new members.
16864
16865 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
16866
16867 * proc-service.c (ps_lgetregs): Search all_processes instead of
16868 all_threads.
16869
16870 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
16871
16872 * server.c (start_inferior): Change return type to int.
16873 (attach_inferior): Change sigptr to int *.
16874 (handle_v_cont, handle_v_requests): Change signal to int *.
16875 (main): Change signal to int.
16876
16877 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
16878
16879 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
16880 * configure.srv: Add m32r*-*-linux*.
16881 * linux-m32r-low.c: New file.
16882
16883 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
16884
16885 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
16886
16887 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
16888
16889 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
16890 Take unsigned long arguments for PIDs.
16891 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
16892 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
16893 (wait_for_sigstop, linux_resume_one_process)
16894 (regsets_fetch_inferior_registers, linux_send_signal)
16895 (linux_read_auxv): Likewise. Update the types of variables holding
16896 PIDs. Update format string specifiers.
16897 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
16898 * remote-utils.c (prepare_resume_reply): Likewise.
16899 * server.c (cont_thread, general_thread, step_thread)
16900 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
16901 unsigned long.
16902 (handle_query): Update format specifiers.
16903 (handle_v_cont, main): Use strtoul for thread IDs.
16904 * server.h (struct inferior_list_entry): Use unsigned long for ID.
16905 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
16906 (general_thread, step_thread, thread_from_wait)
16907 (old_thread_from_wait): Update.
16908 * target.h (struct thread_resume): Use unsigned long for THREAD.
16909 (struct target_ops): Use unsigned long for arguments to attach and
16910 thread_alive.
16911
16912 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
16913
16914 * acinclude.m4: Include bfd/bfd.m4 directly.
16915 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
16916 <agriffis@toolchain.org>.
16917 * aclocal.m4, configure: Regenerated.
16918
16919 2005-01-07 Andrew Cagney <cagney@gnu.org>
16920
16921 * configure.ac: Rename configure.in, require autoconf 2.59.
16922 * configure: Re-generate.
16923
16924 2004-12-08 Daniel Jacobowitz <dan@debian.org>
16925
16926 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
16927 LIBS when finished.
16928 * aclocal.m4: Regenerated.
16929 * configure: Regenerated.
16930
16931 2004-11-21 Andreas Schwab <schwab@suse.de>
16932
16933 * linux-m68k-low.c (m68k_num_gregs): Define.
16934 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
16935 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
16936 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
16937 (m68k_breakpoint_at): New. Add to the_low_target.
16938
16939 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
16940 srv_linux_thread_db to yes.
16941
16942 2004-10-20 Joel Brobecker <brobecker@gnat.com>
16943
16944 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
16945 (ARCH_SET_FS): Likewise.
16946 (ARCH_GET_FS): Likewise.
16947 (ARCH_GET_GS): Likewise.
16948
16949 2004-10-16 Daniel Jacobowitz <dan@debian.org>
16950
16951 * linux-i386-low.c (ps_get_thread_area): New.
16952 * linux-x86-64-low.c (ps_get_thread_area): New.
16953 * linux-low.c: Include <sys/syscall.h>.
16954 (linux_kill_one_process): Don't kill the first thread here.
16955 (linux_kill): Kill the first thread here.
16956 (kill_lwp): New function.
16957 (send_sigstop, linux_send_signal): Use it.
16958 * proc-service.c: Clean up #ifdefs.
16959 (fpregset_info): Delete.
16960 (ps_lgetregs): Update and enable implementation.
16961 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
16962 implementations.
16963 * remote-utils.c (struct sym_cache, symbol_cache): New.
16964 (input_interrupt): Print a clearer message.
16965 (async_io_enabled): New variable.
16966 (enable_async_io, disable_async_io): Use it. Update comments.
16967 (look_up_one_symbol): Use the symbol cache.
16968 * thread-db.c (thread_db_look_up_symbols): New function.
16969 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
16970
16971 2004-10-16 Daniel Jacobowitz <dan@debian.org>
16972
16973 * configure.in: Test for -rdynamic.
16974 * configure: Regenerated.
16975 * Makefile (INTERNAL_LDFLAGS): New.
16976 (gdbserver, gdbreplay): Use it.
16977
16978 2004-09-02 Andrew Cagney <cagney@gnu.org>
16979
16980 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
16981
16982 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
16983
16984 * linux-low.c (linux_wait): Clear all_processes list also.
16985
16986 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
16987
16988 * linux-low.c: Include <errno.h>. Remove extern declaration of
16989 errno.
16990
16991 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
16992
16993 * gdbreplay.c, server.h, utils.c: Update copyright years.
16994
16995 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
16996
16997 * server.c (main): Print child status or termination signal from
16998 variable 'signal', not 'sig'.
16999
17000 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
17001
17002 * linux-low.c (linux_read_memory): Change return type to
17003 int. Check for and return error from ptrace().
17004 * target.c (read_inferior_memory): Change return type to int. Pass
17005 back return status from the_target->read_memory().
17006 * target.h (struct target_ops): Adapt *read_memory() prototype.
17007 Update comment.
17008 (read_inferior_memory): Adapt prototype.
17009 * server.c (main): Return an error packet if
17010 read_inferior_memory() returns an error.
17011
17012 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
17013
17014 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
17015 Unify with other clean targets.
17016
17017 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17018
17019 * server.c (handle_v_cont): Call set_desired_inferior.
17020
17021 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17022
17023 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
17024
17025 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17026
17027 * linux-low.c (linux_wait): Unblock async I/O.
17028 (linux_resume): Block and enable async I/O.
17029 * remote-utils.c (block_async_io, unblock_async_io): New functions.
17030 * server.h (block_async_io, unblock_async_io): Add prototypes.
17031
17032 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17033
17034 * remote-utils.c (remote_open): Print a status notice after
17035 opening a TCP port.
17036 * server.c (attach_inferior): Print a status notice after
17037 attaching.
17038
17039 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17040
17041 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
17042
17043 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
17044
17045 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
17046 error packet.
17047 * server.c, target.h: Update copyright years.
17048
17049 2004-02-25 Roland McGrath <roland@redhat.com>
17050
17051 * target.h (struct target_ops): New member `read_auxv'.
17052 * server.c (handle_query): Handle qPart:auxv:read: query using that.
17053 * linux-low.c (linux_read_auxv): New function.
17054 (linux_target_ops): Initialize `read_auxv' member to that.
17055
17056 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
17057
17058 Committed by Jim Blandy <jimb@redhat.com>.
17059
17060 * linux-s390-low.c (s390_num_regs): Update.
17061 (s390_regmap): Remove control registers. Use __s390x__ predefine
17062 instead of GPR_SIZE to distiguish s390 and s390x targets.
17063
17064 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
17065
17066 * linux-low.c: Update copyright year.
17067 (check_removed_breakpoint): Clear pending_is_breakpoint.
17068 (linux_set_resume_request, linux_queue_one_thread)
17069 (resume_status_pending_p): New functions.
17070 (linux_continue_one_thread): Use process->resume.
17071 (linux_resume): Only resume threads if there are no pending events.
17072 * linux-low.h (struct process_info): Add resume request
17073 pointer.
17074
17075 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
17076
17077 * regcache.c (new_register_cache): Clear the allocated register
17078 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
17079
17080 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
17081
17082 * linux-low.c (linux_resume): Take a struct thread_resume *
17083 argument.
17084 (linux_wait): Update call.
17085 (resume_ptr): New static variable.
17086 (linux_continue_one_thread): Renamed from
17087 linux_continue_one_process. Use resume_ptr.
17088 (linux_resume): Use linux_continue_one_thread.
17089 * server.c (handle_v_cont, handle_v_requests): New functions.
17090 (myresume): New function.
17091 (main): Handle 'v' case.
17092 * target.h (struct thread_resume): New type.
17093 (struct target_ops): Change argument of "resume" to struct
17094 thread_resume *.
17095 (myresume): Delete macro.
17096
17097 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
17098
17099 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
17100 (uninstall): Support DESTDIR.
17101
17102 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
17103
17104 * configure.srv: Add xscale*linux copy of arm*linux entry.
17105
17106 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
17107
17108 * linux-arm-low.c (arm_reinsert_addr): New function.
17109 (the_low_target): Add arm_reinsert_addr.
17110
17111 2003-07-08 Mark Kettenis <kettenis@gnu.org>
17112
17113 * mem-break.c: Remove whitespace at end of file.
17114
17115 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
17116
17117 * configure.in: Check whether we need to prototype strerror.
17118 * server.h: Optionally prototype strerror.
17119 * gdbreplay.c (perror_with_name): Use strerror.
17120 * linux-low.c (linux_attach_lwp): Use strerror.
17121 * utils.c (perror_with_name): Use strerror.
17122 * config.in, configure: Regenerated.
17123
17124 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
17125
17126 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
17127 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
17128
17129 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
17130
17131 * Makefile.in (SFILES): Update.
17132 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
17133 low-sun3.c: Remove files.
17134
17135 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
17136
17137 * linux-low.c: Move comment to linux_thread_alive where it belonged.
17138 (linux_detach_one_process, linux_detach): New functions.
17139 (linux_target_ops): Add linux_detach.
17140 * server.c (main): Handle 'D' packet.
17141 * target.h (struct target_ops): Add "detach" member.
17142 (detach_inferior): Define.
17143
17144 2003-06-13 Mark Kettenis <kettenis@gnu.org>
17145
17146 From Kelley Cook <kelleycook@wideopenwest.com>:
17147 * configure.srv: Accept i[34567]86 variants.
17148
17149 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
17150
17151 * linux-low.c (linux_wait_for_event): Correct comment typos.
17152 (linux_resume_one_process): Call check_removed_breakpoint.
17153 (linux_send_signal): New function.
17154 (linux_target_ops): Add linux_send_signal.
17155 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
17156 of kill.
17157 * target.h (struct target_ops): Add send_signal.
17158
17159 2003-05-29 Jim Blandy <jimb@redhat.com>
17160
17161 * linux-low.c (usr_store_inferior_registers): Transfer buf in
17162 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
17163 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
17164 away part of the register's value.
17165
17166 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
17167
17168 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
17169 (linux_wait_for_event, linux_init_signals): Likewise.
17170
17171 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
17172
17173 * configure.in: Check for stdlib.h.
17174 * configure: Regenerated.
17175 * config.in: Regenerated.
17176
17177 2003-01-04 Andreas Schwab <schwab@suse.de>
17178
17179 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
17180
17181 2003-01-02 Andrew Cagney <ac131313@redhat.com>
17182
17183 * Makefile.in: Remove obsolete code.
17184
17185 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
17186
17187 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
17188 defined(PT_FPR0_HI).
17189
17190 2002-11-17 Stuart Hughes <seh@zee2.com>
17191
17192 * linux-arm-low.c (arm_num_regs): Increase.
17193 (arm_regmap): Include status register.
17194
17195 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
17196
17197 * linux-low.c (register_addr): Remove incorrect -1 check.
17198
17199 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
17200
17201 * linux-low.c (linux_create_inferior): Call setpgid. Return
17202 the new PID.
17203 (unstopped_p, linux_signal_pid): Remove.
17204 (linux_target_ops): Remove linux_signal_pid.
17205 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
17206 global instead of target method.
17207 * target.h (struct target_ops): Remove signal_pid. Update comment
17208 for create_inferior.
17209 * server.c (signal_pid): New variable.
17210 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
17211 gdbserver. Set the child to be the foreground process group.
17212 (attach_inferior): Set signal_pid.
17213
17214 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
17215
17216 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
17217
17218 2002-08-20 Jim Blandy <jimb@redhat.com>
17219
17220 * Makefile.in (LDFLAGS): Allow the configure script to establish a
17221 default for this.
17222
17223 2002-08-01 Andrew Cagney <cagney@redhat.com>
17224
17225 * Makefile.in: Make chill references obsolete.
17226
17227 2002-07-24 Kevin Buettner <kevinb@redhat.com>
17228
17229 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
17230 * configure: Regenerate.
17231 * config.in: Regenerate.
17232
17233 2002-07-09 David O'Brien <obrien@FreeBSD.org>
17234
17235 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
17236 (perror_with_name, remote_close, remote_open, expect, play): Static.
17237
17238 2002-07-04 Michal Ludvig <mludvig@suse.cz>
17239
17240 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
17241 byte offsets instead of an array of indexes.
17242 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
17243
17244 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
17245
17246 * regcache.c: Add comment.
17247
17248 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
17249
17250 * thread-db.c: New file.
17251 * proc-service.c: New file.
17252 * acinclude.m4: New file.
17253 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
17254 proc-service.o, and thread-db.o.
17255 (linux-low.o): Add USE_THREAD_DB.
17256 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
17257 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
17258 * aclocal.m4: Regenerated.
17259 * config.in: Regenerated.
17260 * configure: Regenerated.
17261 * configure.in: Check for proc_service.h, sys/procfs.h,
17262 thread_db.h, and linux/elf.h headrs.
17263 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
17264 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
17265 Check for -lthread_db and thread support.
17266 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
17267 PowerPC, and SuperH.
17268 * i387-fp.c: Constify arguments.
17269 * i387-fp.h: Likewise.
17270 * inferiors.c: (struct thread_info): Renamed from
17271 `struct inferior_info'. Remove PID member. Use generic inferior
17272 list header. All uses updated.
17273 (inferiors, signal_pid): Removed.
17274 (all_threads): New variable.
17275 (get_thread): Define.
17276 (add_inferior_to_list): New function.
17277 (for_each_inferior): New function.
17278 (change_inferior_id): New function.
17279 (add_inferior): Removed.
17280 (remove_inferior): New function.
17281 (add_thread): New function.
17282 (free_one_thread): New function.
17283 (remove_thread): New function.
17284 (clear_inferiors): Use for_each_inferior and free_one_thread.
17285 (find_inferior): New function.
17286 (find_inferior_id): New function.
17287 (inferior_target_data): Update argument type.
17288 (set_inferior_target_data): Likewise.
17289 (inferior_regcache_data): Likewise.
17290 (set_inferior_regcache_data): Likewise.
17291 * linux-low.c (linux_bp_reinsert): Remove.
17292 (all_processes, stopping_threads, using_thrads)
17293 (struct pending_signals, debug_threads, pid_of): New.
17294 (inferior_pid): Replace with macro.
17295 (struct inferior_linux_data): Remove.
17296 (get_stop_pc, add_process): New functions.
17297 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
17298 Use add_process and add_thread.
17299 (linux_attach_lwp): New function, based on old linux_attach. Use
17300 add_process and add_thread. Set stop_expected for new threads.
17301 (linux_attach): New function.
17302 (linux_kill_one_process): New function.
17303 (linux_kill): Kill all LWPs.
17304 (linux_thread_alive): Use find_inferior_id.
17305 (check_removed_breakpoints, status_pending_p): New functions.
17306 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
17307 Update. Use WNOHANG. Wait for cloned processes also. Update process
17308 struct for the found process.
17309 (linux_wait_for_event): New function.
17310 (linux_wait): Use it. Support LWPs.
17311 (send_sigstop, wait_for_sigstop, stop_all_processes)
17312 (linux_resume_one_process, linux_continue_one_process): New functions.
17313 (linux_resume): Support LWPs.
17314 (REGISTER_RAW_SIZE): Remove.
17315 (fetch_register): Use register_size instead. Call supply_register.
17316 (usr_store_inferior_registers): Likewise. Call collect_register.
17317 Fix recursive case.
17318 (regsets_fetch_inferior_registers): Improve error message.
17319 (regsets_store_inferior_registers): Add debugging.
17320 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
17321 (unstopped_p, linux_signal_pid): New functions.
17322 (linux_target_ops): Add linux_signal_pid.
17323 (linux_init_signals): New function.
17324 (initialize_low): Call it. Initialize using_threads.
17325 * regcache.c (inferior_regcache_data): Add valid
17326 flag.
17327 (get_regcache): Fetch registers lazily. Add fetch argument
17328 and update all callers.
17329 (regcache_invalidate_one, regcache_invalidate): New
17330 functions.
17331 (new_register_cache): Renamed from create_register_cache.
17332 Return the new regcache.
17333 (free_register_cache): Change argument to a void *.
17334 (registers_to_string, registers_from_string): Call get_regcache
17335 with fetch flag set.
17336 (register_data): Make static. Pass fetch flag to get_regcache.
17337 (supply_register): Call get_regcache with fetch flag clear.
17338 (collect_register): Call get_regcache with fetch flag set.
17339 (collect_register_as_string): New function.
17340 * regcache.h: Update.
17341 * remote-utils.c (putpkt): Flush after debug output and use
17342 stderr.
17343 Handle input interrupts while waiting for an ACK.
17344 (input_interrupt): Use signal_pid method.
17345 (getpkt): Flush after debug output and use stderr.
17346 (outreg): Use collect_register_as_string.
17347 (new_thread_notify, dead_thread_notify): New functions.
17348 (prepare_resume_reply): Check using_threads. Set thread_from_wait
17349 and general_thread.
17350 (look_up_one_symbol): Flush after debug output.
17351 * server.c (step_thread, server_waiting): New variables.
17352 (start_inferior): Don't use signal_pid. Update call to mywait.
17353 (attach_inferior): Update call to mywait.
17354 (handle_query): Handle qfThreadInfo and qsThreadInfo.
17355 (main): Don't fetch/store registers explicitly. Use
17356 set_desired_inferior. Support proposed ``Hs'' packet. Update
17357 calls to mywait.
17358 * server.h: Update.
17359 (struct inferior_list, struct_inferior_list_entry): New.
17360 * target.c (set_desired_inferior): New.
17361 (write_inferior_memory): Constify.
17362 (mywait): New function.
17363 * target.h: Update.
17364 (struct target_ops): New signal_pid method.
17365 (mywait): Removed macro, added prototype.
17366
17367 * linux-low.h (regset_func): Removed.
17368 (regset_fill_func, regset_store_func): New.
17369 (enum regset_type): New.
17370 (struct regset_info): Add type field. Use new operation types.
17371 (struct linux_target_ops): stop_pc renamed to get_pc.
17372 Add decr_pc_after_break and breakpoint_at.
17373 (get_process, get_thread_proess, get_process_thread)
17374 (strut process_info, all_processes, linux_attach_lwp)
17375 (thread_db_init): New.
17376
17377 * linux-arm-low.c (arm_get_pc, arm_set_pc,
17378 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
17379 (the_low_target): Add new members.
17380 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
17381 (i386_store_fpxregset): Constify.
17382 (target_regsets): Add new kind identifier.
17383 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
17384 (i386_set_pc): Add debugging.
17385 (i386_breakpoint_at): New function.
17386 (the_low_target): Add new members.
17387 * linux-mips-low.c (mips_get_pc, mips_set_pc)
17388 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
17389 (mips_breakpoint_at): New.
17390 (the_low_target): Add new members.
17391 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
17392 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
17393 (the_low_target): Add new members.
17394 * linux-sh-low.c (sh_get_pc, sh_set_pc)
17395 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
17396 (the_low_target): Add new members.
17397 * linux-x86-64-low.c (target_regsets): Add new kind
17398 identifier.
17399
17400 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
17401
17402 From Martin Pool <mbp@samba.org>:
17403 * server.c (gdbserver_usage): New function.
17404 (main): Call it.
17405
17406 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
17407
17408 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
17409 stop_at -> stop_pc.
17410
17411 2002-05-04 Andrew Cagney <ac131313@redhat.com>
17412
17413 * Makefile.in: Remove obsolete code.
17414
17415 2002-04-24 Michal Ludvig <mludvig@suse.cz>
17416
17417 * linux-low.c (regsets_fetch_inferior_registers),
17418 (regsets_store_inferior_registers): Removed cast to int from
17419 ptrace() calls.
17420 * regcache.h: Added declaration of struct inferior_info.
17421
17422 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
17423
17424 * inferiors.c (struct inferior_info): Add regcache_data.
17425 (add_inferior): Call create_register_cache.
17426 (clear_inferiors): Call free_register_cache.
17427 (inferior_regcache_data, set_inferior_regcache_data): New functions.
17428 * regcache.c (struct inferior_regcache_data): New.
17429 (registers): Remove.
17430 (get_regcache): New function.
17431 (create_register_cache, free_register_cache): New functions.
17432 (set_register_cache): Don't initialize the register cache here.
17433 (registers_to_string, registers_from_string, register_data): Call
17434 get_regcache.
17435 * regcache.h: Add prototypes.
17436 * server.h: Likewise.
17437
17438 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
17439
17440 * mem-break.c: New file.
17441 * mem-break.h: New file.
17442 * Makefile.in: Add mem-break.o rule; update server.h
17443 dependencies.
17444 * inferiors.c (struct inferior_info): Add target_data
17445 member.
17446 (clear_inferiors): Free target_data member if set.
17447 (inferior_target_data, set_inferior_target_data): New functions.
17448 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
17449 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
17450 * linux-low.c (linux_bp_reinsert): New variable.
17451 (struct inferior_linux_data): New.
17452 (linux_create_inferior): Use set_inferior_target_data.
17453 (linux_attach): Likewise. Call add_inferior.
17454 (linux_wait_for_one_inferior): New function.
17455 (linux_wait): Call it.
17456 (linux_write_memory): Add const.
17457 (initialize_low): Call set_breakpoint_data.
17458 * linux-low.h (struct linux_target_ops): Add breakpoint
17459 handling members.
17460 * server.c (attach_inferior): Remove extra add_inferior
17461 call.
17462 * server.h: Include mem-break.h. Update inferior.c
17463 prototypes.
17464 * target.c (read_inferior_memory)
17465 (write_inferior_memory): New functions.
17466 * target.h (read_inferior_memory)
17467 (write_inferior_memory): Change macros to prototypes.
17468 (struct target_ops): Update comments. Add const to write_memory
17469 definition.
17470
17471 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
17472
17473 * linux-low.c (usr_store_inferior_registers): Support
17474 registers which are allowed to fail to store.
17475 * linux-low.h (linux_target_ops): Likewise.
17476 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
17477 (ppc_cannot_store_register): FPSCR may not be storable.
17478
17479 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17480
17481 * server.h: Include <string.h> if HAVE_STRING_H.
17482 * ChangeLog: Correct paths in last ChangeLog entry.
17483
17484 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17485
17486 * linux-low.h: Remove obsolete prototypes.
17487 (struct linux_target_ops): New.
17488 (extern the_low_target): New.
17489 * linux-low.c (num_regs, regmap): Remove declarations.
17490 (register_addr): Use the_low_target explicitly.
17491 (fetch_register): Likewise.
17492 (usr_fetch_inferior_registers): Likewise.
17493 (usr_store_inferior_registers): Likewise.
17494 * linux-arm-low.c (num_regs): Remove.
17495 (arm_num_regs): Define.
17496 (arm_regmap): Renamed from regmap, made static.
17497 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
17498 made static.
17499 (arm_cannot_store_register): Renamed from cannot_store_register,
17500 made static.
17501 (the_low_target): New.
17502 * linux-i386-low.c (num_regs): Remove.
17503 (i386_num_regs): Define.
17504 (i386_regmap): Renamed from regmap, made static.
17505 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
17506 made static.
17507 (i386_cannot_store_register): Renamed from cannot_store_register,
17508 made static.
17509 (the_low_target): New.
17510 * linux-ia64-low.c (num_regs): Remove.
17511 (ia64_num_regs): Define.
17512 (ia64_regmap): Renamed from regmap, made static.
17513 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
17514 made static.
17515 (ia64_cannot_store_register): Renamed from cannot_store_register,
17516 made static.
17517 (the_low_target): New.
17518 * linux-m68k-low.c (num_regs): Remove.
17519 (m68k_num_regs): Define.
17520 (m68k_regmap): Renamed from regmap, made static.
17521 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
17522 made static.
17523 (m68k_cannot_store_register): Renamed from cannot_store_register,
17524 made static.
17525 (the_low_target): New.
17526 * linux-mips-low.c (num_regs): Remove.
17527 (mips_num_regs): Define.
17528 (mips_regmap): Renamed from regmap, made static.
17529 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
17530 made static.
17531 (mips_cannot_store_register): Renamed from cannot_store_register,
17532 made static.
17533 (the_low_target): New.
17534 * linux-ppc-low.c (num_regs): Remove.
17535 (ppc_num_regs): Define.
17536 (ppc_regmap): Renamed from regmap, made static.
17537 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
17538 made static.
17539 (ppc_cannot_store_register): Renamed from cannot_store_register,
17540 made static.
17541 (the_low_target): New.
17542 * linux-s390-low.c (num_regs): Remove.
17543 (s390_num_regs): Define.
17544 (s390_regmap): Renamed from regmap, made static.
17545 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
17546 made static.
17547 (s390_cannot_store_register): Renamed from cannot_store_register,
17548 made static.
17549 (the_low_target): New.
17550 * linux-sh-low.c (num_regs): Remove.
17551 (sh_num_regs): Define.
17552 (sh_regmap): Renamed from regmap, made static.
17553 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
17554 made static.
17555 (sh_cannot_store_register): Renamed from cannot_store_register,
17556 made static.
17557 (the_low_target): New.
17558 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
17559 (the_low_target): New.
17560
17561 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17562
17563 * Makefile.in: Add stamp-h target.
17564 * configure.in: Create stamp-h.
17565 * configure: Regenerated.
17566
17567 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17568
17569 * inferiors.c: New file.
17570 * target.c: New file.
17571 * target.h: New file.
17572 * Makefile.in: Add target.o and inferiors.o. Update
17573 dependencies.
17574 * linux-low.c (inferior_pid): New static variable,
17575 moved from server.c.
17576 (linux_create_inferior): Renamed from create_inferior.
17577 Call add_inferior. Return 0 on success instead of a PID.
17578 (linux_attach): Renamed from myattach.
17579 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
17580 (linux_thread_alive): Renamed from mythread_alive.
17581 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
17582 child dies.
17583 (linux_resume): Renamed from myresume. Add missing ``return 0''.
17584 (regsets_store_inferior_registers): Correct error message.
17585 Add missing ``return 0''.
17586 (linux_fetch_registers): Renamed from fetch_inferior_registers.
17587 (linux_store_registers): Renamed from store_inferior_registers.
17588 (linux_read_memory): Renamed from read_inferior_memory.
17589 (linux_write_memory): Renamed from write_inferior_memory.
17590 (linux_target_ops): New structure.
17591 (initialize_low): Call set_target_ops ().
17592 * remote-utils.c (unhexify): New function.
17593 (hexify): New function.
17594 (input_interrupt): Send signals to ``signal_pid''.
17595 * server.c (inferior_pid): Remove.
17596 (start_inferior): Update create_inferior call.
17597 (attach_inferior): Call add_inferior.
17598 (handle_query): New function.
17599 (main): Call handle_query for `q' packets.
17600 * server.h: Include "target.h". Remove obsolete prototypes.
17601 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
17602
17603 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17604
17605 * Makefile.in: Add WARN_CFLAGS. Update configury
17606 dependencies.
17607 * configure.in: Check for <string.h>
17608 * configure: Regenerate.
17609 * config.in: Regenerate.
17610 * gdbreplay.c: Include needed system headers.
17611 (remote_open): Remove strchr prototype.
17612 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
17613 * regcache.c (supply_register): Change buf argument to const void *.
17614 (supply_register_by_name): Likewise.
17615 (collect_register): Change buf argument to void *.
17616 (collect_register_by_name): Likewise.
17617 * regcache.h: Add missing prototypes.
17618 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
17619 * server.c (handle_query): New function.
17620 (attached): New static variable, moved out of main.
17621 (main): Quiet longjmp clobber warnings.
17622 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
17623 * utils.c (error): Remove NORETURN.
17624 (fatal): Likewise.
This page took 0.412088 seconds and 4 git commands to generate.