Fix build with GNU Make 3.81
[deliverable/binutils-gdb.git] / gdb / gdbserver / ChangeLog
CommitLineData
1ee7b812
BE
12019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
2
3 * Makefile.in: Fix build with GNU Make 3.81
4
d9fa87f4
TT
52019-12-16 Tom Tromey <tromey@adacore.com>
6
7 * server.c (get_exec_file): Constify result.
8
ab7d13f0
CB
92019-12-10 Christian Biesinger <cbiesinger@google.com>
10
11 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
12 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
13 * config.in: Regenerate.
14 * configure: Regenerate.
15 * configure.ac: Don't check for strerror.
16 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
17 Call safe_strerror instead of strerror.
18 * server.h (strerror): Remove this now-unnecessary declaration.
19 * tracepoint.c (init_named_socket): Call safe_strerror instead of
20 strerror.
21 (gdb_agent_helper_thread): Likewise.
22 * utils.c (perror_with_name): Likewise.
23
4da8c3a8
TT
242019-11-26 Tom Tromey <tom@tromey.com>
25
26 * configure, config.in: Rebuild.
27
21987b9c
TT
282019-11-26 Tom Tromey <tom@tromey.com>
29
30 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
31 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
32 gdb_sigmask.
33 * configure, config.in: Rebuild.
34
5e030278
TT
352019-11-26 Tom Tromey <tom@tromey.com>
36
37 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
38 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
39 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
40 * acinclude.m4: Include ax_pthread.m4.
41 * config.in, configure: Rebuild.
42
6d91ce9a
CB
432019-11-26 Christian Biesinger <cbiesinger@google.com>
44
45 * debug.c (debug_set_output): Call safe_strerror instead of
46 strerror.
47 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
48 (linux_kill_one_lwp): Likewise.
49 (linux_detach_one_lwp): Likewise.
50 (linux_wait_for_event_filtered): Likewise.
51 (store_register): Likewise.
52 * lynx-low.c (lynx_attach): Likewise.
53 * mem-break.c (insert_memory_breakpoint): Likewise.
54 (remove_memory_breakpoint): Likewise.
55 (delete_fast_tracepoint_jump): Likewise.
56 (set_fast_tracepoint_jump): Likewise.
57 (uninsert_fast_tracepoint_jumps_at): Likewise.
58 (reinsert_fast_tracepoint_jumps_at): Likewise.
59 * nto-low.c (nto_xfer_memory): Likewise.
60 (nto_resume): Likewise.
61
6cdd651f
LM
622019-11-20 Luis Machado <luis.machado@linaro.org>
63
64 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
65 instead of register count.
66 * tdesc.c (tdesc_contains_feature): New function.
67 * tdesc.h (tdesc_contains_feature): New prototype.
68
cd850b40
CB
692019-11-15 Christian Biesinger <cbiesinger@google.com>
70
71 * Makefile.in: Add safe-strerror.c.
72 * configure: Regenerate.
73 * configure.ac: Don't source common.host.
74
5abebf3c
CB
752019-11-15 Christian Biesinger <cbiesinger@google.com>
76
77 * config.in: Regenerate.
78 * configure: Regenerate.
79
e06f3d6e
AB
802019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
81
82 * ax.c (ax_printf): Handle size_t_arg.
83
ca3a04f6
CB
842019-11-06 Christian Biesinger <cbiesinger@google.com>
85
86 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
87 * mi/mi-main.c (output_cores): Likewise.
88 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
89 (linux_xfer_osdata_modules): Likewise.
90 * remote.c (register_remote_support_xml): Likewise.
91 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
92 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
93
e48f6033
CB
942019-11-01 Christian Biesinger <cbiesinger@google.com>
95
96 * configure: Regenerate.
97 * configure.ac: Remove check for strerror_r.
98
e7e97a2e
CB
992019-10-31 Christian Biesinger <cbiesinger@google.com>
100
101 * config.in: Regenerate.
102 * configure: Regenerate.
103 * configure.ac: Also check for strerror_r.
104
75cafaa6
CB
1052019-10-31 Christian Biesinger <cbiesinger@google.com>
106
107 * ax.h (debug_agent): Remove duplicate declaration.
108
30baf67b
TV
1092019-10-26 Tom de Vries <tdevries@suse.de>
110
111 * linux-aarch64-low.c: Fix typos in comments.
112 * linux-arm-low.c: Same.
113 * linux-low.c: Same.
114 * linux-ppc-low.c: Same.
115 * proc-service.c: Same.
116 * regcache.h: Same.
117 * server.c: Same.
118 * tracepoint.c: Same.
119 * win32-low.c: Same.
120
52c64cf7
TT
1212019-10-25 Tom Tromey <tromey@adacore.com>
122
123 * utils.c (xstrdup): Remove.
124
c12d372d
TT
1252019-10-23 Tom Tromey <tom@tromey.com>
126
127 * configure, config.in: Rebuild.
128
4d0b984b
TT
1292019-10-23 Tom Tromey <tom@tromey.com>
130
131 * configure: Rebuild.
132 * acinclude.m4: Use m4_include, not sinclude.
133
c5adaa19
TT
1342019-10-17 Tom Tromey <tromey@adacore.com>
135
136 * configure: Rebuild.
137 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
138 in AC_CONFIG_FILES invocation.
139 * Makefile.in (stamp-h, Makefile): Use new-style config.status
140 invocation.
141
fec4e896
CB
1422019-10-16 Christian Biesinger <cbiesinger@google.com>
143
144 * server.c: Include xml-builtin.h.
145 (get_xml_features): Don't declare xml_builtins here.
146
00975ff6
AB
1472019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
148
149 * Makefile.in: Remove references to vec-ipa.o.
150
0dc32745
AB
1512019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
152
153 * Makefile.in: Remove references to vec.c.
154
3e6ec53a
CB
1552019-10-02 Christian Biesinger <cbiesinger@google.com>
156
157 * server.c (server_waiting): Change to bool.
158 (extended_protocol): Likewise.
159 (response_needed): Likewise.
160 (exit_requested): Likewise.
161 (run_once): Likewise.
162 (report_no_resumed): Likewise.
163 (non_stop): Likewise.
164 (disable_packet_vCont): Likewise.
165 (disable_packet_Tthread): Likewise.
166 (disable_packet_qC): Likewise.
167 (disable_packet_qfThreadInfo): Likewise.
168 (handle_general_set): Update.
169 (handle_detach): Update.
170 (handle_monitor_command): Update.
171 (handle_query): Update.
172 (captured_main): Update.
173 (process_serial_event): Update.
174 * server.h (server_waiting): Change to bool.
175 (disable_packet_vCont): Likewise.
176 (disable_packet_Tthread): Likewise.
177 (disable_packet_qC): Likewise.
178 (disable_packet_qfThreadInfo): Likewise.
179 (run_once): Likewise.
180 (non_stop): Likewise.
181 * target.c (target_stop_and_wait): Update.
182
80fd2826
TT
1832019-10-02 Tom Tromey <tromey@adacore.com>
184
185 * Makefile.in (SFILES): Add common-inferior.c.
186 (OBS): Add common-inferior.o.
187 * server.c (startup_with_shell): Don't define.
188
46f29a9a
AB
1892019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
190
191 * linux-low.c (linux_low_read_btrace): Update for change to
192 std::vector.
193
f9d949fb
CB
1942019-09-20 Christian Biesinger <cbiesinger@google.com>
195
196 * debug.c (debug_threads): Remove comment in favor of the header.
197 * debug.h (using_threads): Add declaration.
198 (debug_threads): Add comment.
199 * linux-aarch64-low.c: Include debug.h and remove declaration of
200 debug_threads.
201 * nto-low.c: Likewise.
202 * remote-utils.c: Likewise.
203 * thread-db.c: Likewise.
204
abf516c6
UW
2052019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
206
207 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
208 and powerpc-cell64l-ipa.o.
209 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
210 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
211 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
212 (spu*-*-*): Remove.
213
214 * spu-low.c: Remove file.
215
216 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
217 (parse_spufs_run): Remove.
218 (ppc_get_pc): Remove Cell/B.E. support.
219 (ppc_set_pc): Likewise.
220 (ppc_breakpoint_at): Likewise.
221 (ppc_arch_setup): Likewise.
222 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
223 tdesc_powerpc_cell32l.
224 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
225 or init_registers_powerpc_cell32l.
226 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
227 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
228 or init_registers_powerpc_cell32l.
229 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
230 (init_registers_powerpc_cell32l): Remove prototype.
231 (init_registers_powerpc_cell64l): Likewise.
232
233 * target.h (struct target_ops): Remove qxfer_spu member.
234 * server.c (handle_qxfer_spu): Remove.
235 (qxfer_packets): Remove entry for "spu".
236 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
237 * linux-low.c (SPUFS_MAGIC): Remove.
238 (spu_enumerate_spu_ids): Remove.
239 (linux_qxfer_spu): Remove.
240 (linux_target_ops): Remove qxfer_spu member.
241 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
242 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
243 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
244
2d41fa11
SDJ
2452019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
246
247 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
248 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
249 * config.in: Regenerate.
250 * configure: Regenerate.
251
d59b55f0
TT
2522019-08-15 Tom Tromey <tromey@adacore.com>
253
254 * target.c (target_write_memory): Use gdb::byte_vector.
255
4196ab2a
TT
2562019-08-15 Tom Tromey <tromey@adacore.com>
257
258 * tracepoint.c (write_inferior_data_pointer)
259 (write_inferior_integer, write_inferior_int8)
260 (write_inferior_uinteger, m_tracepoint_action_download)
261 (r_tracepoint_action_download, x_tracepoint_action_download)
262 (l_tracepoint_action_download, clear_inferior_trace_buffer)
263 (download_agent_expr, download_tracepoint_1)
264 (download_trace_state_variables, upload_fast_traceframes): Update.
265 * server.c (gdb_write_memory): Update.
266 * remote-utils.c (relocate_instruction): Update.
267 * proc-service.c (ps_pdwrite): Update.
268 * mem-break.c (remove_memory_breakpoint)
269 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
270 (uninsert_fast_tracepoint_jumps_at)
271 (reinsert_fast_tracepoint_jumps_at): Update.
272 * linux-x86-low.c (append_insns)
273 (i386_install_fast_tracepoint_jump_pad)
274 (amd64_write_goto_address, i386_write_goto_address): Update.
275 * linux-s390-low.c (append_insns, s390_write_goto_address):
276 Update.
277 * linux-ppc-low.c (ppc_relocate_instruction)
278 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
279 (ppc_write_goto_address): Update.
280 * linux-aarch64-low.c (append_insns): Update.
281 * target.h (struct target_ops): Update.
282 (write_inferior_memory): Don't declare.
283 * target.c (target_write_memory): Rename from
284 write_inferior_memory. Remove old target_write_memory.
285
c6778d00
TT
2862019-08-15 Tom Tromey <tromey@adacore.com>
287
288 * target.c (write_inferior_memory): Use std::vector.
289
404f2902
FCE
2902019-08-06 Frank Ch. Eigler <fche@redhat.com>
291
292 PR build/24886
293 * configure.ac: Drop enable-libmcheck support.
294 * configure, config.in: Rebuild.
295 * acinclude.m4: Don't include it.
296
4c5aa8e0
AH
2972019-07-19 Alan Hayward <alan.hayward@arm.com>
298
299 * configure.srv: Remove Arm xml files.
300
7cc17433
AH
3012019-07-19 Alan Hayward <alan.hayward@arm.com>
302
303 * configure.srv: Add new files. Remove xml generated files.
304 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
305 registers.
306 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
307 * linux-aarch32-tdesc.c: New file.
308 * linux-aarch32-tdesc.h: New file.
309 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
310 * linux-arm-low.c (init_registers_arm, tdesc_arm)
311 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
312 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
313 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
314 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
315 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
316 (arm_read_description): Call arm_linux_read_description.
317 (initialize_low_arch): Don't init registers.
318 * linux-arm-tdesc.c: New file.
319 * linux-arm-tdesc.h: New file.
320
166a82be
AH
3212019-07-10 Alan Hayward <alan.hayward@arm.com>
322
323 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
324 Move counter inside for.
325 (arm_read_description): Check ptrace earlier.
326 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
327
268a13a5
TT
3282019-07-09 Tom Tromey <tom@tromey.com>
329
330 * configure: Rebuild.
331 * configure.ac: Change common to gdbsupport.
332 * acinclude.m4: Change common to gdbsupport.
333 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
334 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
335 common to gdbsupport.
336 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
337 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
338 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
339 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
340 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
341 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
342 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
343 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
344 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
345 common to gdbsupport.
346
350fab54
AH
3472019-07-04 Alan Hayward <alan.hayward@arm.com>
348
349 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
350 defines.
351 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
352
2b40fda7
AH
3532019-07-04 Alan Hayward <alan.hayward@arm.com>
354
355 * configure.srv: Remove legacy xml.
356 * linux-aarch64-low.c (initialize_low_arch): Remove
357 initialize_low_tdesc call.
358 * linux-aarch64-tdesc-selftest.c: Remove file.
359 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
360 * linux-x86-low.c (initialize_low_arch): Remove
361 initialize_low_tdesc call.
362 * linux-x86-tdesc-selftest.c: Remove file.
363 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
364
7d10623d
TV
3652019-06-20 Tom de Vries <tdevries@suse.de>
366
367 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
368 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
369
8d6a48df
TV
3702019-06-19 Tom de Vries <tdevries@suse.de>
371
372 * debug.h (debug_write): Change return type to ssize_t.
373 * debug.c (debug_write): Same.
374
73cc7272
TT
3752019-06-14 Tom Tromey <tom@tromey.com>
376
377 * configure.ac: Use new path to gnulib.
378 * configure: Rebuild.
379 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
380 to gnulib.
381
08f10e02
TT
3822019-06-11 Tom Tromey <tom@tromey.com>
383
384 * Makefile.in (SFILES): Add alloc.c.
385 (OBS): Add alloc.o.
386 (IPA_OBJS): Add alloc-ipa.o.
387 (alloc-ipa.o): New target.
388 (%.o: ../%.c): New pattern rule.
389
422186a9
TT
3902019-06-10 Tom Tromey <tromey@adacore.com>
391
392 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
393 end warning with a newline.
394 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
395 newline.
396 * thread-db.c (attach_thread): Don't end warning with a newline.
397 (thread_db_notice_clone): Likewise.
398 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
399 newline.
400 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
401 end warning with a newline.
402
b02f78f9
PA
4032019-06-04 Pedro Alves <palves@redhat.com>
404
405 * server.c (captured_main): Use make_unique_xstrdup.
406
88ed7edb
TT
4072019-06-02 Tom Tromey <tom@tromey.com>
408
409 * gdbreplay.c (fromhex): Remove.
410 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
411
33a6bc35
TT
4122019-05-29 Tom Tromey <tromey@adacore.com>
413
414 * configure: Rebuild.
415
e90a813d
KB
4162019-05-06 Kevin Buettner <kevinb@redhat.com>
417
418 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
419 sign extension code on 32-bit builds.
420
353ea2d1
EZ
4212019-05-03 Eli Zaretskii <eliz@gnu.org>
422
423 * remote-utils.c:
424 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
425
b494cdff
TT
4262019-04-19 Tom Tromey <tom@tromey.com>
427
428 * server.c (struct vstop_notif): Derive from notif_event.
429 <base>: Remove.
430 (queue_stop_reply): Update.
431 (remove_all_on_match_ptid): Change type. Rewrite.
432 (discard_queued_stop_replies): Rewrite.
433 (in_queued_stop_replies_ptid): Change type.
434 (in_queued_stop_replies): Rewrite.
435 (notif_stop): Update.
436 (queue_stop_reply_callback): Update.
437 (captured_main): Don't call initialize_notif.
438 (push_stop_notification): Update.
439 * notif.c (notif_write_event, handle_notif_ack)
440 (notif_event_enque, notif_push): Update.
441 (notif_event_xfree, initialize_notif): Remove.
442 * notif.h (struct notif_event): Include <list>, not
443 "common/queue.h".
444 (struct notif_server) <queue>: Now a std::list.
445 (notif_event_p): Remove typedef.
446 (initialize_notif): Don't declare.
447 (struct notif_event): Add virtual destructor.
448
a7e559cc
AH
4492019-04-17 Alan Hayward <alan.hayward@arm.com>
450
451 * ax.c (ax_vdebug): Call debug_printf.
452 * debug.c (debug_write): New function.
453 * debug.h (debug_write): New declaration.
454 * linux-low.c (sigchld_handler): Call debug_write.
455
aeb2e706
AH
4562019-04-17 Alan Hayward <alan.hayward@arm.com>
457
458 * debug.c (debug_set_output): New function.
459 (debug_vprintf): Send output to debug_file.
460 (debug_flush): Likewise.
461 * debug.h (debug_set_output): New declaration.
462 * server.c (handle_monitor_command): Add debug-file option.
463 (captured_main): Likewise.
464
c1bc0935
AH
4652019-04-17 Alan Hayward <alan.hayward@arm.com>
466
467 * debug.c (remote_debug): Add definition.
468 * debug.h (remote_debug): Add declaration.
469 * hostio.c (remote_debug): Remove declaration.
470 * remote-utils.c (struct ui_file): Likewise.
471 (remote_debug): Likewise.
472 * remote-utils.h (remote_debug): Likewise,
473 * server.c (remote_debug): Remove definition.
474
3f52fdbc
KB
4752019-04-10 Kevin Buettner <kevinb@redhat.com>
476
477 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
478 when using a 64-bit gdbserver.
479
b0319eaa
TT
4802019-04-09 Tom Tromey <tromey@adacore.com>
481
482 * linux-low.c (select_event_lwp): Use find_thread_in_random.
483
eedc3f4f
TT
4842019-04-08 Tom Tromey <tom@tromey.com>
485
486 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
487 throw.
488 (linux_resume_one_lwp): Likewise.
489
230d2906
TT
4902019-04-08 Tom Tromey <tom@tromey.com>
491
492 * gdbreplay.c: Update.
493 * linux-low.c: Update.
494 * server.c: Update.
495
a70b8144
TT
4962019-04-08 Tom Tromey <tom@tromey.com>
497
498 * server.c: Use C++ exception handling.
499 * linux-low.c: Use C++ exception handling.
500 * gdbreplay.c: Use C++ exception handling.
501
3d6e9d23
TT
5022019-04-08 Tom Tromey <tom@tromey.com>
503
504 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
505 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
506 (captured_main, main): Update.
507 * gdbreplay.c (main): Update.
508
0570503d
PFC
5092019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
510
511 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
512 value in argument pointer, return 1 if the entry is found and 0
513 otherwise. Move comment.
514 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
515 * linux-low.h (linux_get_auxv): Declare.
516 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
517
227a9e65
TT
5182019-04-05 Tom Tromey <tromey@adacore.com>
519
520 * server.c (gdbserver_usage): Use upper-case for metasyntactic
521 variables.
522
69f4c9cc
AH
5232019-03-28 Alan Hayward <alan.hayward@arm.com>
524
525 * linux-low.c (AT_HWCAP2): Add define if not already included.
526
974c89e0
AH
5272019-03-26 Alan Hayward <alan.hayward@arm.com>
528
529 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
530 (aarch64_arch_setup): Call linux_get_hwcap.
531 * linux-arm-low.c (arm_get_hwcap): Remove function.
532 (arm_read_description): Call linux_get_hwcap.
533 * linux-low.c (linux_get_auxv): New function.
534 (linux_get_hwcap): Likewise.
535 (linux_get_hwcap2): Likewise.
536 * linux-low.h (linux_get_hwcap): New declaration.
537 (linux_get_hwcap2): Likewise.
538 * linux-ppc-low.c (ppc_get_auxv): Remove function.
539 (ppc_arch_setup): Call linux_get_hwcap.
540 * linux-s390-low.c (s390_get_hwcap): Remove function.
541 (s390_arch_setup): Call linux_get_hwcap.
542
1ef53e6b
AH
5432019-03-22 Alan Hayward <alan.hayward@arm.com>
544 Jiong Wang <jiong.wang@arm.com>
545
546 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
547 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
548 to fail.
549 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
550
ee4fbcfa
AH
5512019-03-22 Alan Hayward <alan.hayward@arm.com>
552 Jiong Wang <jiong.wang@arm.com>
553
554 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
555 (aarch64_get_hwcap): New function.
556 (aarch64_arch_setup): Read APIA hwcap.
557
6dc0ebde
AH
5582019-03-22 Alan Hayward <alan.hayward@arm.com>
559 Jiong Wang <jiong.wang@arm.com>
560
561 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
562 (initialize_low_tracepoint): Likewise.
563 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
564 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
565 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
566 (aarch64_linux_read_description): Likewise.
567 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
568
1163a4b7
JB
5692019-03-12 John Baldwin <jhb@FreeBSD.org>
570
571 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
572 i386_create_target_description for 'segments' parameter.
573 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
574 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
575 * win32-i386-low.c (i386_arch_setup): Likewise.
576
d3a70e03
TT
5772019-03-12 Tom Tromey <tromey@adacore.com>
578
579 * linux-low.c (iterate_over_lwps): Update.
580
37991b4f
TT
5812019-03-06 Tom Tromey <tom@tromey.com>
582
583 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
584 (captured_main): Use SCOPE_EXIT.
585
45950eb6
SDJ
5862019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
587
588 * configure.srv: Use '$enable_unittest' instead of '$development'
589 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
590 case.
591
43ac54fc
TT
5922019-02-27 Tom Tromey <tromey@adacore.com>
593
594 * gdbreplay.c (logchar): Handle \r\n.
595
df0da8a2
AH
5962019-02-07 Alan Hayward <alan.hayward@arm.com>
597
598 * linux-low.c (linux_attach): Add process before lwp.
599 * server.c (attach_inferior): Check if already attached.
600
1a5c2598
TT
6012019-02-07 Tom Tromey <tom@tromey.com>
602
603 * x86-tdesc.h: Rename include guard.
604 * x86-low.h: Add include guard.
605 * wincecompat.h: Rename include guard.
606 * win32-low.h: Add include guard.
607 * utils.h: Rename include guard.
608 * tracepoint.h: Rename include guard.
609 * tdesc.h: Rename include guard.
610 * target.h: Rename include guard.
611 * server.h: Rename include guard.
612 * remote-utils.h: Rename include guard.
613 * regcache.h: Rename include guard.
614 * nto-low.h: Rename include guard.
615 * notif.h: Add include guard.
616 * mem-break.h: Rename include guard.
617 * lynx-low.h: Add include guard.
618 * linux-x86-tdesc.h: Add include guard.
619 * linux-s390-tdesc.h: Add include guard.
620 * linux-ppc-tdesc-init.h: Add include guard.
621 * linux-low.h: Add include guard.
622 * linux-aarch64-tdesc.h: Add include guard.
623 * linux-aarch32-low.h: Add include guard.
624 * inferiors.h: Rename include guard.
625 * i387-fp.h: Rename include guard.
626 * hostio.h: Rename include guard.
627 * gdbthread.h: Rename include guard.
628 * gdb_proc_service.h: Rename include guard.
629 * event-loop.h: Rename include guard.
630 * dll.h: Rename include guard.
631 * debug.h: Rename include guard.
632 * ax.h: Rename include guard.
633
956cc47c
SN
6342018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
635
636 PR gdb/23985
637 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
638 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
639
a0707f3c
TT
6402019-01-25 Tom Tromey <tom@tromey.com>
641
642 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
643
0747795c
TT
6442019-01-25 Tom Tromey <tom@tromey.com>
645
646 * win32-low.c: Fix common/ includes.
647 * win32-i386-low.c: Fix common/ includes.
648 * tracepoint.c: Fix common/ includes.
649 * thread-db.c: Fix common/ includes.
650 * target.h: Fix common/ includes.
651 * symbol.c: Fix common/ includes.
652 * spu-low.c: Fix common/ includes.
653 * server.h: Fix common/ includes.
654 * server.c: Fix common/ includes.
655 * remote-utils.c: Fix common/ includes.
656 * regcache.h: Fix common/ includes.
657 * regcache.c: Fix common/ includes.
658 * nto-x86-low.c: Fix common/ includes.
659 * notif.h: Fix common/ includes.
660 * mem-break.h: Fix common/ includes.
661 * lynx-low.c: Fix common/ includes.
662 * lynx-i386-low.c: Fix common/ includes.
663 * linux-x86-tdesc-selftest.c: Fix common/ includes.
664 * linux-x86-low.c: Fix common/ includes.
665 * linux-low.c: Fix common/ includes.
666 * inferiors.h: Fix common/ includes.
667 * i387-fp.c: Fix common/ includes.
668 * hostio.c: Fix common/ includes.
669 * hostio-errno.c: Fix common/ includes.
670 * gdbthread.h: Fix common/ includes.
671 * gdbreplay.c: Fix common/ includes.
672 * fork-child.c: Fix common/ includes.
673 * event-loop.c: Fix common/ includes.
674 * ax.c:
675 (enum gdb_agent_op): Fix common/ includes.
676
be6d4f74
TT
6772019-01-21 Tom Tromey <tom@tromey.com>
678
679 * tracepoint.c: Fix includes.
680 * remote-utils.c: Fix includes.
681 * linux-x86-low.c: Fix includes.
682
66d91b39
JB
6832019-01-01 Joel Brobecker <brobecker@adacore.com>
684
685 * gdbreplay.c (gdbreplay_version): Update copyright year in
686 version message.
687 * server.c (gdbserver_version): Likewise.
688
754e3168
AH
6892018-12-05 Alan Hayward <alan.hayward@arm.com>
690
691 * linux-low.c (add_lwp): Switch ordering.
692
d105de22
TT
6932018-11-29 Tom Tromey <tom@tromey.com>
694
695 * win32-low.c (win32_join): Take pid, not process.
696 * target.h (struct target_ops) <join>: Change argument type.
697 (join_inferior): Change argument name.
698 * spu-low.c (spu_join): Take pid, not process.
699 * server.c (handle_detach): Preserve pid before destroying
700 process.
701 * lynx-low.c (lynx_join): Take pid, not process.
702 * linux-low.c (linux_join): Take pid, not process.
703
50138245
AH
7042018-11-23 Alan Hayward <alan.hayward@arm.com>
705
706 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
707 (aarch64_cannot_fetch_register): Likewise.
708 (struct linux_target_ops): Update references.
709
64f57f3d
PFC
7102018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
711
712 * linux-ppc-low.c: Include nat/linux-ptrace.h.
713
8d619c01
EBM
7142018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
715
716 * configure.srv (ipa_ppc_linux_regobj): Add
717 powerpc-isa207-htm-vsx32l-ipa.o and
718 powerpc-isa207-htm-vsx64l-ipa.o.
719 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
720 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
721 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
722 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
723 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
724 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
725 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
726 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
727 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
728 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
729 (init_registers_powerpc_isa207_htm_vsx32l)
730 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
731 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
732 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
733 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
734 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
735 (ppc_store_tm_ctarregset): New functions.
736 (ppc_regsets): Add entries for HTM regsets.
737 (ppc_arch_setup): Set htm in features struct when needed. Set
738 sizes for the HTM regsets.
739 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
740 (initialize_low_arch): Call
741 init_registers_powerpc_isa207_htm_vsx32l and
742 init_registers_powerpc_isa207_htm_vsx64l.
743 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
744 PPC_TDESC_ISA207_HTM_VSX.
745 (initialize_low_tracepoint): Call
746 init_registers_powerpc_isa207_htm_vsx32l and
747 init_registers_powerpc_isa207_htm_vsx64l.
748
232bfb86
EBM
7492018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
750
751 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
752 rs6000/power-linux-pmu.xml to srv_xmlfiles.
753 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
754 (ppc_store_pmuregset): New functions.
755 (ppc_regsets): Add entries for ebb and pmu regsets.
756 (ppc_arch_setup): Set isa207 in features struct if the ebb and
757 pmu regsets are available. Set sizes for these regsets.
758
f2cf6173
EBM
7592018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
760
761 * configure.srv (ipa_ppc_linux_regobj): Add
762 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
763 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
764 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
765 rs6000/powerpc-isa207-vsx32l.xml, and
766 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
767 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
768 <PPC_TDESC_ISA207_VSX>: New enum value.
769 (init_registers_powerpc_isa207_vsx32l): Declare.
770 (init_registers_powerpc_isa207_vsx64l): Declare.
771 * linux-ppc-low.c (ppc_fill_tarregset): New function.
772 (ppc_store_tarregset): New function.
773 (ppc_regsets): Add entry for the TAR regset.
774 (ppc_arch_setup): Set isa207 in features struct when needed. Set
775 size for the TAR regsets.
776 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
777 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
778 and init_registers_powerpc_isa207_vsx64l.
779 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
780 (initialize_low_tracepoint): Call
781 init_registers_powerpc_isa207_vsx32l and
782 init_registers_powerpc_isa207_vsx64l.
783
7ca18ed6
EBM
7842018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
785 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
786
787 * configure.srv (ipa_ppc_linux_regobj): Add
788 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
789 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
790 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
791 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
792 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
793 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
794 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
795 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
796 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
797 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
798 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
799 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
800 (ppc_hwcap): Add comment.
801 (ppc_hwcap2): New global.
802 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
803 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
804 (ppc_regsets): Add entries for the DSCR and PPR regsets.
805 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
806 when needed. Set sizes for the the DSCR and PPR regsets.
807 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
808 (initialize_low_arch): Call
809 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
810 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
811 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
812 PPC_TDESC_ISA205_PPR_DSCR_VSX.
813 (initialize_low_tracepoint): Call
814 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
815 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
816
5c849b22
PFC
8172018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
818
819 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
820
8ecfd7bd
SDJ
8212018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
822 Simon Marchi <simark@simark.ca>
823
824 * acinclude.m4: Include "../selftest.m4".
825 * configure: Regenerate.
826 * configure.ac: Use "GDB_AC_SELFTEST".
827 * configure.srv: Use "$enable_unittests" instead of
828 "$development" when checking whether unit tests have been
829 enabled.
830 * server.c (captured_main): Update message informing that
831 selftests have been disabled.
832
96643e35
TT
8332018-10-04 Tom Tromey <tom@tromey.com>
834
835 * configure: Rebuild.
836
da4ae14a
TT
8372018-10-04 Tom Tromey <tom@tromey.com>
838
839 * server.c (handle_status): Rename inner "thread".
840 (process_serial_event): Declare "res" in 'm' case.
841 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
842 (iterate_over_lwps): Rename inner "thread".
843 (linux_qxfer_libraries_svr4): Rename inner "len".
844 * gdbthread.h (find_thread_in_random): Rename inner "thread".
845
7c619dbd
GB
8462018-10-01 Gary Benson <gbenson@redhat.com>
847
848 * gdb_proc_service.h: Moved common code to
849 common/gdb_proc_service.h.
850
3795e814
GB
8512018-10-01 Gary Benson <gbenson@redhat.com>
852
853 * gdb_proc_service.h: Synchronize comments and whitespace with
854 GDB's version of this file.
855
49b036f1
TT
8562018-09-25 Tom Tromey <tom@tromey.com>
857
858 * configure: Rebuild.
859 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
860
8ff03f0b
SM
8612018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
862
863 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
864 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
865 ($(IPA_LIB)): Sort IPA_OBJS.
866
a1cd91dc
SM
8672018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
868
869 * Makefile.in: Remove references to $(ADD_DEPS).
870
752312ba
TT
8712018-09-16 Tom Tromey <tom@tromey.com>
872
873 * remote-utils.c (remote_open): Use GNU style for metasyntactic
874 variables.
875 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
876 variables.
877
f1628857
TT
8782018-09-05 Tom Tromey <tom@tromey.com>
879
880 * configure: Rebuild.
881
ad202fcc
SM
8822018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
883
884 PR build/23399
885 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
886
d3d8724a
TT
8872018-08-27 Tom Tromey <tom@tromey.com>
888
889 PR build/23087:
890 * configure: Rebuild.
891
b4f183d2
TT
8922018-08-27 Tom Tromey <tom@tromey.com>
893
894 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
895 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
896 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
897 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
898 (s390x_emit_stack_adjust): Add casts to unsigned char.
899
4e2aa472
SM
9002018-08-22 Simon Marchi <simon.marchi@ericsson.com>
901
902 PR gdb/23374
903 PR gdb/23375
904 * server.h (struct client_state) <disable_randomization>:
905 Initialize to 1.
906
cf4088a9
SM
9072018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
908
909 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
910 variable.
911 (mips_supply_ptrace_register): Likewise.
912
a0de763e
TT
9132018-07-22 Tom Tromey <tom@tromey.com>
914
915 * configure: Rebuild.
916
b0a7723d
TT
9172018-07-22 Tom Tromey <tom@tromey.com>
918
919 * win32-low.c (win32_create_inferior): Remove unused variables.
920 * gdbreplay.c (remote_open): Remove unused variable.
921 * remote-utils.c (remote_prepare): Remove unused variable.
922 * x86-tdesc.h (X86_TDESC_H): Define.
923 (amd64_expedite_regs): Define conditionally.
924 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
925 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
926 * remote-utils.c (readchar): Remove unused variable.
927
a780ef4f
PA
9282018-07-13 Pedro Alves <palves@redhat.com>
929
930 * linux-low.c (linux_kill): Change parameter to process_info
931 pointer instead of pid. Adjust.
932 * lynx-low.c (lynx_kill): Likewise.
933 * nto-low.c (nto_kill): Likewise.
934 * spu-low.c (spu_kill): Likewise.
935 * win32-low.c (win32_kill): Likewise.
936 * server.c (handle_v_kill, kill_inferior_callback)
937 (detach_or_kill_for_exit): Adjust.
938 * target.c (kill_inferior): Change parameter to process_info
939 pointer instead of pid. Adjust.
940 * target.h (struct target_ops) <kill>: Change parameter to
941 process_info pointer instead of pid. Adjust all implementations
942 and callers.
943 (kill_inferior): Likewise.
944
ef2ddb33
PA
9452018-07-13 Pedro Alves <palves@redhat.com>
946
947 * linux-low.c (linux_detach, linux_join): Change parameter to
948 process_info pointer instead of pid. Adjust.
949 * lynx-low.c (lynx_detach, lynx_join): Likewise.
950 * nto-low.c (nto_detach): Likewise.
951 * spu-low.c (spu_detach, spu_join): Likewise.
952 * win32-low.c (win32_detach, win32_join): Likewise.
953 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
954 * target.h (struct target_ops) <detach, join>: Change parameter to
955 process_info pointer instead of pid. Adjust all implementations
956 and callers.
957 (detach_inferior, join_inferior): Rename 'pid' parameter to
958 'proc'.
959
c7ab0aef
SDJ
9602018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
961 Jan Kratochvil <jan.kratochvil@redhat.com>
962 Paul Fertser <fercerpav@gmail.com>
963 Tsutomu Seki <sekiriki@gmail.com>
964
965 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
966 (OBS): Add 'common/netstuff.o'.
967 (GDBREPLAY_OBS): Likewise.
968 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
969 (remote_open): Implement support for IPv6
970 connections.
971 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
972 and 'wspiapi.h'.
973 (handle_accept_event): Accept connections from IPv6 sources.
974 (remote_prepare): Handle IPv6-style hostnames; implement
975 support for IPv6 connections.
976 (remote_open): Implement support for printing connections from
977 IPv6 sources.
978
31445d10
PA
9792018-07-11 Pedro Alves <palves@redhat.com>
980
981 PR gdb/23377
982 * mem-break.c (any_persistent_commands): Add process_info
983 parameter and use it instead of relying on the current process.
984 Change return type to bool.
985 * mem-break.h (any_persistent_commands): Add process_info
986 parameter and change return type to bool.
987 * server.c (handle_detach): Remove require_running_or_return call.
988 Look up the process_info for the process we're about to detach.
989 If not found, return back error to GDB. Adjust
990 any_persistent_commands call to pass down a process pointer.
991
cb197132
PA
9922018-07-11 Pedro Alves <palves@redhat.com>
993
994 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
995 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
996 instead of collect_register_by_name.
997 * regcache.c (regcache_raw_get_unsigned_by_name): New.
998 * regcache.h (regcache_raw_get_unsigned_by_name): New.
999
1b919490
VB
10002018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
1001 Pedro Alves <palves@redhat.com>
1002
1003 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
1004
d7e15655
TT
10052018-07-03 Tom Tromey <tom@tromey.com>
1006
1007 * linux-low.c: Update.
1008 * lynx-low.c: Update.
1009 * mem-break.c: Update.
1010 * nto-low.c: Update.
1011 * remote-utils.c: Update.
1012 * server.c: Update.
1013 * spu-low.c: Update.
1014 * target.c: Update.
1015 * win32-low.c: Update.
1016
26a57c92
TT
10172018-07-03 Tom Tromey <tom@tromey.com>
1018
1019 * server.c: Update.
1020
0e998d96
TT
10212018-07-03 Tom Tromey <tom@tromey.com>
1022
1023 * linux-low.c: Update.
1024
cc6bcb54
TT
10252018-07-03 Tom Tromey <tom@tromey.com>
1026
1027 * target.c: Update.
1028
e38504b3
TT
10292018-07-03 Tom Tromey <tom@tromey.com>
1030
1031 * linux-low.c: Update.
1032 * linux-mips-low.c: Update.
1033 * lynx-low.c: Update.
1034 * nto-low.c: Update.
1035 * remote-utils.c: Update.
1036 * server.c: Update.
1037 * spu-low.c: Update.
1038 * target.c: Update.
1039 * thread-db.c: Update.
1040
e99b03dc
TT
10412018-07-03 Tom Tromey <tom@tromey.com>
1042
1043 * linux-low.c: Update.
1044 * linux-mips-low.c: Update.
1045 * lynx-low.c: Update.
1046 * mem-break.c: Update.
1047 * nto-low.c: Update.
1048 * remote-utils.c: Update.
1049 * server.c: Update.
1050 * spu-low.c: Update.
1051 * target.c: Update.
1052 * tracepoint.c: Update.
1053
f2907e49
TT
10542018-07-03 Tom Tromey <tom@tromey.com>
1055
1056 * linux-low.c: Update.
1057 * linux-ppc-low.c: Update.
1058 * linux-x86-low.c: Update.
1059 * proc-service.c: Update.
1060 * server.c: Update.
1061 * spu-low.c: Update.
1062 * thread-db.c: Update.
1063 * win32-low.c: Update.
1064
fd79271b
TT
10652018-07-03 Tom Tromey <tom@tromey.com>
1066
1067 * linux-low.c: Update.
1068 * lynx-low.c: Update.
1069 * nto-low.c: Update.
1070 * remote-utils.c: Update.
1071 * spu-low.c: Update.
1072 * thread-db.c: Update.
1073 * win32-low.c: Update.
1074
c0867626
SDJ
10752018-06-29 Joel Brobecker <brobecker@adacore.com>
1076
1077 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
1078 parameter in call to 'amd64_create_target_description'.
1079
2512d7ef
JK
10802018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
1081
1082 * x86-tdesc.h: Remove executable permission flag.
1083
d0ac1c44
SM
10842018-06-19 Simon Marchi <simon.marchi@ericsson.com>
1085
1086 * configure.ac: Remove AC_PREREQ, add missing quoting.
1087 * configure: Re-generate.
1088 * config.in: Re-generate.
1089 * aclocal.m4: Re-generate.
1090
c4eb05ff
SM
10912018-06-18 Simon Marchi <simon.marchi@ericsson.com>
1092
1093 * tracepoint.h (current_traceframe): Remove declaration.
1094
02895270
AH
10952018-06-18 Alan Hayward <alan.hayward@arm.com>
1096
1097 * linux-aarch64-low.c (is_sve_tdesc): New function.
1098 (aarch64_sve_regs_copy_to_regcache): Likewise.
1099 (aarch64_sve_regs_copy_from_regcache): Likewise.
1100 (aarch64_regs_info): Add SVE checks.
1101 (initialize_low_arch): Initialize SVE.
1102
e9902bfc
AH
11032018-06-18 Alan Hayward <alan.hayward@arm.com>
1104
1105 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
1106
fefa175e
AH
11072018-06-11 Alan Hayward <alan.hayward@arm.com>
1108
1109 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
1110 (initialize_low_tracepoint): Likewise
1111 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
1112 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
1113 param.
1114 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
1115 checks.
1116 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
1117
b91ad3ff
AH
11182018-06-11 Alan Hayward <alan.hayward@arm.com>
1119
1120 * server.h (PBUFSIZ): Increase size
1121
f868386e
AH
11222018-06-11 Alan Hayward <alan.hayward@arm.com>
1123
1124 * regcache.c (regcache::raw_compare): New function.
1125 * regcache.h (regcache::raw_compare): New declaration.
1126
9c861883
AH
11272018-06-11 Alan Hayward <alan.hayward@arm.com>
1128
1129 * regcache.c (new_register_cache): Use new.
1130 (free_register_cache): Use delete.
1131 (register_data): Use const.
1132 (supply_register): Move body inside regcache.
1133 (regcache::raw_supply): New override function.
1134 (collect_register): Move body inside regcache.
1135 (regcache::raw_collect): New override function.
1136 (regcache::get_register_status): New override function.
1137 * regcache.h (struct regcache): Inherit from reg_buffer_common.
1138
40591844
TT
11392018-06-09 Tom Tromey <tom@tromey.com>
1140
1141 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
1142 declare queue.
1143 (event_queue): Use std::queue.
1144 (gdb_event_xfree): Remove.
1145 (initialize_event_loop, process_event, wait_for_event): Update.
1146
6341380d
SC
11472018-06-08 Stan Cox <scox@redhat.com>
1148
1149 * win32-low.c (win32_create_inferior): last_ptid and last_status
1150 moved to client_state.
1151
03349c93
PA
11522018-06-08 Pedro Alves <palves@redhat.com>
1153
1154 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
1155 common/common-exceptions.o, common/common-utils.o,
1156 common/errors.o, common/print-utils.o and utils.o.
1157 * gdbreplay.c: Include "common-defs.h" instead of the two
1158 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
1159 string.h or alloca.h.
1160 (perror_with_name): Delete.
1161 (remote_open): Use xstrdup instead of strdup.
1162 (main): Rename to ...
1163 (captured_main): ... this.
1164 (main): New.
1165
8dcc53b3
TT
11662018-06-08 Tom Tromey <tom@tromey.com>
1167
1168 * linux-low.c (linux_low_read_btrace): Update.
1169
c12a5089
SC
11702018-06-04 Stan Cox <scox@redhat.com>
1171
1172 * server.h (struct client_state): New.
1173 * server.c (cont_thread, general_thread, multi_process)
1174 (report_fork_events, report_vfork_events, report_exec_events)
1175 (report_thread_events, swbreak_feature, hwbreak_feature)
1176 (vCont_supported, disable_randomization, pass_signals)
1177 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
1178 Moved to client_state.
1179 * remote-utils.c (remote_debug, noack_mode)
1180 (transport_is_reliable): Moved to client_state.
1181 * tracepoint.c (current_traceframe): Moved to client_state.
1182
1183 Update all callers.
1184 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
1185 linux-low.c, remote-utils.h, target.c: Use client_state.
1186
122394f1
AH
11872018-05-31 Alan Hayward <alan.hayward@arm.com>
1188
1189 * configure.srv: Add new c/h file.
1190
95228a0d
AH
11912018-05-31 Alan Hayward <alan.hayward@arm.com>
1192
1193 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
1194 null VQ.
1195
d8dab6c3
MR
11962018-05-25 Maciej W. Rozycki <macro@mips.com>
1197
1198 * gdb.arch/mips-fpregset-core.exp: New test.
1199 * gdb.arch/mips-fpregset-core.c: New test source.
1200
81e25b7c
EK
12012018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
1202
1203 PR server/23198
1204 * hostio.c (require_int): Do not report overflow for integers
1205 between 0xfffffff and 0x7fffffff.
1206
7e947ad3
MR
12072018-05-22 Maciej W. Rozycki <macro@mips.com>
1208
1209 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
1210 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
1211 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
1212 functions.
1213 (the_low_target): Wire them.
1214
1d75a658
PFC
12152018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1216
1217 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
1218 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
1219 mode. Call collect_register_by_name with vscr using
1220 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
1221 (ppc_store_vrregset): Add and set vscr_offset variable as in
1222 ppc_fill_vrregset. Call supply_register_by_name with vscr using
1223 vscr_offset.
1224
d078308a
PFC
12252018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1226
1227 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
1228 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
1229 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
1230
7273b5fc
PFC
12312018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1232
1233 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
1234 (ppc_store_vsxregset): Likewise.
1235 (ppc_fill_vrregset): Likewise.
1236 (ppc_store_vrregset): Likewise.
1237 (ppc_fill_evrregset): Likewise.
1238 (ppc_store_evrregset): Likewise.
1239 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
1240 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
1241 needed.
1242
2e077f5e
PFC
12432018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1244
1245 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
1246 wordsize of the inferior. Call ppc_linux_target_wordsize.
1247
bd64614e
PFC
12482018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1249
1250 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
1251 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
1252 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
1253 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
1254 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
1255 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
1256 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
1257 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
1258 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
1259 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
1260 (tdesc_powerpc_e500l): Remove.
1261 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
1262 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
1263 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
1264 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
1265 linux-ppc-tdesc.h.
1266 (ppc_arch_setup): Remove target description matching code. Fill a
1267 ppc_linux_features struct and call ppc_linux_match_description
1268 with it.
1269
75d74cca
MR
12702018-05-22 Maciej W. Rozycki <macro@mips.com>
1271
1272 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
1273 width of the requested register exceeds the width of the
1274 `ptrace' data type.
1275 (mips_cannot_store_register): Likewise.
1276
e4439e43
MR
12772018-05-21 Maciej W. Rozycki <macro@mips.com>
1278
1279 * linux-mips-low.c (mips_fetch_register): New function. Update
1280 preceding comment.
1281 (mips_store_gregset): Supply 0 rather than $restart for $zero.
1282 (the_low_target): Wire `mips_fetch_register'.
1283
55271bf9
JB
12842018-05-10 Joel Brobecker <brobecker@adacore.com>
1285
1286 * lynx-i386-low.c (LYNXOS_178): New macro.
1287 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
1288 the layout on LynxOS-178.
1289 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
1290 handle floating point registers that are not supported by
1291 LynxOS-178.
1292
1a34f210
TT
12932018-05-10 Tom Tromey <tom@tromey.com>
1294
1295 * configure: Rebuild.
1296
190852c8
JB
12972018-05-10 Joel Brobecker <brobecker@adacore.com>
1298
1299 PR server/23158:
1300 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
1301 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
1302 Use it to set the expedite_regs field in the given tdesc.
1303 * x86-tdesc.h: New file.
1304 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
1305 Adjust following the addition of the new expedite_regs parameter
1306 to init_target_desc.
1307 * linux-tic6x-low.c (tic6x_read_description): Likewise.
1308 * linux-x86-tdesc.c: #include "x86-tdesc.h".
1309 (i386_linux_read_description, amd64_linux_read_description):
1310 Adjust following the addition of the new expedite_regs parameter
1311 to init_target_desc.
1312 * lynx-i386-low.c: #include "x86-tdesc.h".
1313 (lynx_i386_arch_setup): Adjust following the addition of the new
1314 expedite_regs parameter to init_target_desc.
1315 * nto-x86-low.c: #include "x86-tdesc.h".
1316 (nto_x86_arch_setup): Adjust following the addition of the new
1317 expedite_regs parameter to init_target_desc.
1318 * win32-i386-low.c: #include "x86-tdesc.h".
1319 (i386_arch_setup): Adjust following the addition of the new
1320 expedite_regs parameter to init_target_desc.
1321
7dbac825
JB
13222018-05-10 Joel Brobecker <brobecker@adacore.com>
1323
1324 PR server/23158:
1325 * win32-low.c (win32_create_inferior): Add call to my_wait
1326 setting last_status global.
1327
906994d9
JB
13282018-05-10 Joel Brobecker <brobecker@adacore.com>
1329
1330 PR server/23158:
1331 * win32-low.c (create_process): Only call gdb_tilde_expand if
1332 inferior_cwd is not NULL.
1333
8ee22052
AB
13342018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
1335
1336 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
1337 registers to the cache if their values have changed.
1338 (i387_xsave_to_cache): Provide default values for x87 control
1339 registers when these features are available, but disabled.
1340 * regcache.c (supply_register_by_name_zeroed): New function.
1341 * regcache.h (supply_register_by_name_zeroed): Declare new
1342 function.
1343
aff689d3
TT
13442018-05-07 Tom Tromey <tom@tromey.com>
1345
1346 * configure: Rebuild.
1347
85e26832
TT
13482018-05-04 Tom Tromey <tom@tromey.com>
1349
1350 * configure: Rebuild.
1351
a3b60e45
JK
13522018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
1353 Pedro Alves <palves@redhat.com>
1354
1355 * linux-aarch64-low.c (aarch64_stopped_data_address):
1356 Likewise.
1357
632e107b
TT
13582018-04-27 Tom Tromey <tom@tromey.com>
1359
1360 * configure: Rebuild.
1361
458412c3
TT
13622018-04-23 Tom Tromey <tom@tromey.com>
1363
1364 * configure: Rebuild.
1365
f31c089e
SM
13662018-04-19 Simon Marchi <simon.marchi@ericsson.com>
1367
1368 * Makefile.in (depcomp): Add "..".
1369 (all_deps_files): New and use it.
1370
b319b098
AH
13712018-04-18 Alan Hayward <alan.hayward@arm.com>
1372
1373 * configure.srv (aarch64*-*-linux*): Don't include xml.
1374 (i[34567]86-*-cygwin*): Likewise.
1375 (i[34567]86-*-linux*): Likewise.
1376 (i[34567]86-*-lynxos*): Likewise.
1377 (i[34567]86-*-mingw32ce*): Likewise.
1378 (i[34567]86-*-mingw*): Likewise.
1379 (i[34567]86-*-nto*): Likewise.
1380 (tic6x-*-uclinux): Likewise.
1381 (x86_64-*-linux*): Likewise.
1382 (x86_64-*-mingw*): Likewise.
1383 (x86_64-*-cygwin*): Likewise.
1384
3b74854b
AH
13852018-04-18 Alan Hayward <alan.hayward@arm.com>
1386
1387 * tdesc.c: Remove xml parameter.
1388
e98577a9
AH
13892018-04-18 Alan Hayward <alan.hayward@arm.com>
1390
1391 * server.c (get_features_xml): Remove cast.
1392 * tdesc.c (void target_desc::accept): Fill in function.
1393 (tdesc_get_features_xml): Remove old xml creation.
1394 (print_xml_feature::visit_pre): Add xml vistor.
1395 * tdesc.h (struct target_desc): Make xmltarget mutable.
1396 (tdesc_get_features_xml): Remove declaration.
1397
d278f585
AH
13982018-04-18 Alan Hayward <alan.hayward@arm.com>
1399
1400 * tdesc.c (tdesc_architecture_name): Add new function.
1401 (tdesc_osabi_name): Likewise.
1402 (tdesc_get_features_xml): Use new functions.
1403
eee8a18d
AH
14042018-04-18 Alan Hayward <alan.hayward@arm.com>
1405
1406 * tdesc.c (tdesc_create_flags): Remove.
1407 (tdesc_add_flag): Likewise.
1408 (tdesc_named_type): Likewise.
1409 (tdesc_create_union): Likewise.
1410 (tdesc_create_struct): Likewise.
1411 (tdesc_create_vector): Likewise.
1412 (tdesc_add_bitfield): Likewise.
1413 (tdesc_add_field): Likewise.
1414 (tdesc_set_struct_size): Likewise.
1415
82ec9bc7
AH
14162018-04-18 Alan Hayward <alan.hayward@arm.com>
1417
1418 * tdesc.c (~target_desc): Remove implictly deleted items.
1419 (init_target_desc): Iterate all features.
1420 (tdesc_get_features_xml): Use vector.
1421 (tdesc_create_feature): Create feature.
1422 * tdesc.h (tdesc_feature) Remove
1423 (target_desc): Add features.
1424
ea3e7d71
AH
14252018-04-18 Alan Hayward <alan.hayward@arm.com>
1426
1427 * Makefile.in: Add common/tdesc.c
1428 * tdesc.c (init_target_desc): init all reg_defs from register
1429 vector.
1430 (tdesc_create_reg): Create tdesc_reg.
1431 * tdesc.h (tdesc_feature): Add register vector.
1432
17d08cd4
SM
14332018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
1434
1435 * tdesc.h (struct target_desc) <features>: Change type to
1436 std::vector<std::string>.
1437 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
1438 changes.
1439 (tdesc_get_features_xml): Likewise.
1440 (tdesc_create_feature): Likewise.
1441
5cd3e386
AH
14422018-03-26 Alan Hayward <alan.hayward@arm.com>
1443
1444 * regcache.c (find_register_by_number): Return a ref.
1445 (find_regno): Use references.
1446 (register_size): Likewise.
1447 (register_data): Likewise.
1448 * tdesc.c (target_desc::~target_desc): Remove free calls.
1449 (target_desc::operator==): Use std::vector compare.
1450 (init_target_desc): Use reference.
1451 (tdesc_create_reg): Use reg constructors.
1452 * tdesc.h (struct target_desc): Replace pointer with object.
1453
dff7492c
AH
14542018-03-23 Alan Hayward <alan.hayward@arm.com>
1455
1456 * regcache.c (find_register_by_number): Make static.
1457 (find_regno): Use find_register_by_number
1458 * regcache.h (struct reg): Remove declaration.
1459
d80e5242
AH
14602018-03-23 Alan Hayward <alan.hayward@arm.com>
1461
1462 * tdesc.c (target_desc::~target_desc): Move to here.
1463 (target_desc::operator==): Likewise.
1464 * tdesc.h (target_desc::~target_desc): Move from here.
1465 (target_desc::operator==): Likewise.
1466
f69c5afb
AA
14672018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
1468
1469 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
1470
ce29f843
AA
14712018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1472
1473 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
1474 S390_TDESC_GS.
1475 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
1476 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
1477 and init_registers_s390_gs_linux64.
1478
c49bd90b
AA
14792018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1480
1481 * linux-s390-low.c (s390_fill_gs): Remove function.
1482 (s390_fill_gsbc): Remove function.
1483 (s390_regsets): Set fill functions for the guarded storage regsets
1484 to NULL.
1485
7edb9bd3
AA
14862018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1487
1488 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
1489 the word size. Add comment.
1490 (s390_get_wordsize): New function.
1491 (s390_arch_setup): No longer select a temporary tdesc to fetch the
1492 pswm with it. Instead, use s390_get_wordsize to determine the
1493 word size first and derive the correct tdesc from that directly.
1494
39be3c7e
SM
14952018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
1496
1497 * Makefile.in: Include silent-rules.mk.
1498 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
1499 (COMPILE): Add ECHO_CXX.
1500 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
1501 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
1502 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
1503 (version-generated.c): Add ECHO_GEN.
1504 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
1505 (IPAGENT_COMPILE): Add ECHO_CXX.
1506 (%-generated.c): Add ECHO_REGDAT.
1507
3ae9ce5d
TT
15082018-03-14 Tom Tromey <tom@tromey.com>
1509
1510 PR cli/14977:
1511 * ax.c (ax_printf): Special case for NULL.
1512
e6a58aa8
SM
15132018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1514
1515 * linux-low.c (linux_qxfer_libraries_svr4): Use
1516 xml_escape_text_append.
1517
f6e8a41e
SM
15182018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1519
1520 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
1521
b9671caf
SM
15222018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1523
1524 * server.c (handle_general_set): Remove unnecessary xstrdup.
1525
e80aaf61
SM
15262018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1527
1528 * server.c (parse_debug_format_options): Adjust to
1529 delim_string_to_char_ptr_vec changes.
1530 * thread-db.c (thread_db_load_search): Adjust to
1531 dirnames_to_char_ptr_vec changes.
1532
b1223e78
MM
15332018-03-01 Markus Metzger <markus.t.metzger@intel.com>
1534
1535 * target.h (target_enable_btrace, target_disable_btrace)
1536 (target_read_btrace, target_read_btrace_conf): Turn macro into
1537 inline function. Throw error if target method is not defined.
1538 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
1539 check for btrace target method. Be prepared to handle exceptions
1540 from btrace target methods.
1541
81561546
SDJ
15422018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1543
1544 * server.c (captured_main): Change order of error message printed
1545 when the current working directory cannot be found.
1546
25e3c82c
SDJ
15472018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1548
1549 * server.c: Include "filenames.h" and "pathstuff.h".
1550 (program_name): Delete variable.
1551 (program_path): New anonymous class.
1552 (get_exec_wrapper): Use "program_path" instead of
1553 "program_name".
1554 (handle_v_run): Likewise.
1555 (captured_main): Likewise.
1556 (process_serial_event): Likewise.
1557
b4987c95
SDJ
15582018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1559
1560 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
1561 (OBJS): Add "pathstuff.o".
1562 * server.c (current_directory): New global variable.
1563 (captured_main): Initialize "current_directory".
1564
f46cd62a
AH
15652018-02-26 Alan Hayward <alan.hayward@arm.com>
1566
1567 * tdesc.c: Use common/tdesc.h.
1568 * tdesc.h: Likewise.
1569
a543c5ca
AH
15702018-02-20 Alan Hayward <alan.hayward@arm.com>
1571 Simon Marchi <simon.marchi@ericsson.com>
1572
1573 * Makefile.in: Switch order of make rules.
1574
b5884fa7
AH
15752018-02-19 Alan Hayward <alan.hayward@arm.com>
1576
1577 * Makefile.in: Add common directory in build.
1578 * configure.ac: Add common reference.
1579 * configure: Regenerate.
1580
de6242d3
MM
15812018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1582
1583 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
1584 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
1585 * spu-low.c (spu_target_ops): Likewise.
1586 * win32-low.c (win32_target_ops): Likewise.
1587 * server.c (supported_btrace_packets): Report packets unconditionally.
1588 * target.h (target_ops) <supports_btrace>: Remove.
1589 (target_supports_btrace): Remove.
1590
9ee23a85
MM
15912018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1592
1593 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
1594 (handle_btrace_disable): Change return type to void. Use exceptions
1595 to report errors.
1596 (handle_btrace_general_set): Catch exception and copy message to
1597 return message.
1598
8ce47547
TT
15992018-02-08 Tom Tromey <tom@tromey.com>
1600
1601 * linux-low.c (install_software_single_step_breakpoints): Use
1602 make_scoped_restore.
1603 * inferiors.c (make_cleanup_restore_current_thread): Remove.
1604 (do_restore_current_thread_cleanup): Remove.
1605 * gdbthread.h (make_cleanup_restore_current_thread): Don't
1606 declare.
1607
45dd3607
TT
16082018-02-08 Tom Tromey <tom@tromey.com>
1609
1610 * mem-break.c (set_raw_breakpoint_at): Use
1611 gdb::unique_xmalloc_ptr.
1612
e671cd59
PA
16132018-01-30 Pedro Alves <palves@redhat.com>
1614
1615 PR gdb/13211
1616 * target.c (target_terminal::terminal_state): Rename to ...
1617 (target_terminal::m_terminal_state): ... this.
1618
a0aad537
JC
16192018-01-19 James Clarke <jrtc27@jrtc27.com>
1620
1621 * linux-low.c (handle_extended_wait): Surround call to
1622 thread_db_notice_clone with #ifdef USE_THREAD_DB.
1623
4d9b86e1
SM
16242018-01-17 Simon Marchi <simon.marchi@ericsson.com>
1625
1626 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
1627 linux_ptrace_attach_fail_reason_string now returning an
1628 std::string.
1629 (linux_attach): Likewise.
1630 * thread-db.c (attach_thread): Likewise.
1631
f517c180
EA
16322018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
1633
1634 PR gdb/21559
1635 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
1636 checking for fs_base/gs_base fields in struct user_regs_struct.
1637 * configure: Regenerate.
1638
9a70f35c
YQ
16392018-01-16 Yao Qi <yao.qi@linaro.org>
1640
1641 PR gdb/18749
1642 * linux-low.c (fetch_register): Call supply_register instead of
1643 error.
1644
605fd3c6
YQ
16452018-01-08 Yao Qi <yao.qi@linaro.org>
1646 Simon Marchi <simon.marchi@ericsson.com>
1647
1648 * Makefile.in (OBS): Remove selftest.o.
1649 * configure.ac: Set srv_selftest_objs if $development is true.
1650 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
1651 * configure: Re-generated.
1652 * server.c (captured_main): Wrap variable selftest_filter with
1653 GDB_SELF_TEST.
1654
2cc05030
SM
16552018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
1656
1657 * server.c (parse_debug_format_options): Return std::string.
1658 (handle_monitor_command, captured_main): Adjust.
1659
e379cee6
PA
16602018-01-05 Pedro Alves <palves@redhat.com>
1661
1662 PR gdb/18653
1663 * server.c (captured_main): Pass quiet=false to
1664 save_original_signals_state.
1665
82e1e79a
JB
16662018-01-01 Joel Brobecker <brobecker@adacore.com>
1667
1668 * gdbreplay.c (gdbreplay_version): Update copyright year in
1669 version message.
1670 * server.c (gdbserver_version): Likewise.
1671
8e481c3b
TT
16722017-12-08 Tom Tromey <tom@tromey.com>
1673
1674 * ax.c (ax_printf): Update.
1675
a8806230
YQ
16762017-12-07 Yao Qi <yao.qi@linaro.org>
1677
1678 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
1679 aarch64_linux_read_description.
1680 * linux-amd64-ipa.c (idx2mask): New array.
1681 (get_ipa_tdesc): Move idx2mask out.
1682 (initialize_low_tracepoint): Initialize target descriptions.
1683 * linux-i386-ipa.c (idx2mask): New array.
1684 (get_ipa_tdesc): Move idx2mask out.
1685 (initialize_low_tracepoint): Initialize target descriptions.
1686
d4a0e8b5
SM
16872017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
1688
1689 * tdesc.c (struct tdesc_type): Change return type.
1690 (tdesc_add_flag): Change parameter type.
1691 (tdesc_add_bitfield): Likewise.
1692 (tdesc_add_field): Likewise.
1693 (tdesc_set_struct_size): Likewise.
1694
798a7429
SM
16952017-12-05 Simon Marchi <simon.marchi@ericsson.com>
1696
1697 * regcache.c (registers_to_string): Remove unused variable.
1698
c0e15c9b
SM
16992017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1700
1701 * inferiors.c (for_each_inferior_with_data): Remove.
1702 * inferiors.h (for_each_inferior_with_data): Remove.
1703 * server.c (handle_qxfer_threads_worker): Change parameter type.
1704 (handle_qxfer_threads_proper): Use for_each_thread.
1705
f0045347
SM
17062017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1707
1708 * inferiors.c (for_each_inferior): Remove.
1709 (clear_inferiors): Use for_each_thread.
1710 * inferiors.h (for_each_inferior): Remove.
1711 * linux-low.c (linux_wait_for_event_filtered): Use
1712 for_each_thread.
1713 (linux_stabilize_threads): Likewise.
1714 * regcache.c (regcache_release): Likewise.
1715 * server.c (gdb_wants_all_threads_stopped): Likewise.
1716 (clear_pending_status_callback): Remove.
1717 (handle_status): Use for_each_thread.
1718 (captured_main): Likewise.
1719 * win32-low.c (child_init_thread_list): Likewise.
1720 (win32_clear_inferiors): Likewise.
1721 (fake_breakpoint_event): Likewise.
1722
9521758b
SM
17232017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1724
1725 * inferiors.h (find_inferior): Remove.
1726 * inferiors.c (find_inferior): Remove.
1727
8f86d7aa
SM
17282017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1729
1730 * linux-low.c (resume_status_pending_p): Update comment.
1731 (need_step_over_p): Update comment.
1732
e2b44075
SM
17332017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1734
1735 * linux-low.c (proceed_one_lwp): Return void, change parameter
1736 type.
1737 (unsuspend_and_proceed_one_lwp): Likewise.
1738 (proceed_all_lwps): Use for_each_thread.
1739 (unstop_all_lwps): Likewise.
1740
c80825ff
SM
17412017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1742
1743 * linux-low.c (linux_resume_one_thread): Return void, take
1744 parameter directly.
1745 (linux_resume): Use for_each_thread.
1746
df3e4dbe
SM
17472017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1748
1749 * linux-low.c (send_sigstop_callback): Return void, change
1750 parameter type. Rename to...
1751 (send_sigstop): ... this.
1752 (suspend_and_send_sigstop_callback): Return void, change parameter
1753 type. Rename to...
1754 (suspend_and_send_sigstop): ... this.
1755 (stop_all_lwps): Use for_each_thread.
1756
5a6b0a41
SM
17572017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1758
1759 * linux-low.c (lwp_running): Return bool, remove unused
1760 argument.
1761 (linux_stabilize_threads): Use find_thread.
1762
39a64da5
SM
17632017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1764
1765 * linux-low.c (select_singlestep_lwp_callback): Remove.
1766 (count_events_callback): Remove.
1767 (select_event_lwp_callback): Remove.
1768 (select_event_lwp): Use find_thread/for_each_thread.
1769
a1385b7b
SM
17702017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1771
1772 * linux-low.c (not_stopped_callback): Return bool, take filter
1773 argument directly.
1774 (linux_wait_for_event_filtered): Use find_thread.
1775 (linux_wait_1): Likewise.
1776
454296a2
SM
17772017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1778
1779 * linux-low.c (same_lwp): Remove.
1780 (find_lwp_pid): Use find_thread.
1781
6b2a85da
SM
17822017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1783
1784 * linux-low.c (delete_lwp_callback): Remove.
1785 (linux_mourn): Use for_each_thread.
1786
798a38e8
SM
17872017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1788
1789 * linux-low.c (linux_detach_lwp_callback): Return void, remove
1790 args parameter, don't check for pid.
1791 (linux_detach): Use for_each_thread.
1792
e4eb0dec
SM
17932017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1794
1795 * linux-low.c (struct counter): Remove.
1796 (second_thread_of_pid_p): Remove.
1797 (last_thread_of_process_p): Use find_thread.
1798
83e1b6c1
SM
17992017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1800
1801 * inferiors.c (find_inferior_in_random): Remove.
1802 * inferiors.h (find_inferior_in_random): Remove.
1803 * linux-low.c (status_pending_p_callback): Return bool, accept
1804 parameter ptid directly.
1805 (linux_wait_for_event_filtered): Use find_thread_in_random.
1806 (linux_wait_1): Likewise.
1807
8dc7b443
SM
18082017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1809
1810 * inferiors.c (find_inferior_id): Remove.
1811 (find_thread_ptid): Move implemention from find_inferior_id to
1812 here.
1813 * inferiors.h (find_inferior_id): Remove.
1814 * server.c (handle_status): Use find_thread_ptid.
1815 (process_serial_event): Likewise.
1816 * thread-db.c (find_one_thread): Likewise.
1817 (thread_db_thread_handle): Likewise.
1818 * win32-low.c (thread_rec): Likewise.
1819 (child_delete_thread): Likewise.
1820 (win32_thread_alive): Likewise.
1821 (get_child_debug_event): Likewise.
1822
da25033c
SM
18232017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1824
1825 * linux-mips-low.c (update_watch_registers_callback): Return
1826 void, remove pid_p parameter, don't check for pid.
1827 (mips_insert_point, mips_remove_point): Use for_each_thread.
1828
c91bb56b
SM
18292017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1830
1831 * lynx.low (lynx_delete_thread_callback): Remove.
1832 (lynx_mourn): Use for_each_thread.
1833
634a3254
SM
18342017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1835
1836 * regcache.c (regcache_invalidate_one): Remove.
1837 (regcache_invalidate_pid): use for_each_thread.
1838
41272101
TT
18392017-11-26 Tom Tromey <tom@tromey.com>
1840
1841 * linux-low.c (linux_create_inferior): Update.
1842
f5291a6f
UW
18432017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
1844
1845 * spu-low.c (spu_create_inferior): Fix typo in argument name.
1846
6654d750
AH
18472017-11-24 Alan Hayward <alan.hayward@arm.com>
1848
1849 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
1850 * linux-aarch64-low.c (initialize_low_arch): Call init func.
1851 * linux-aarch64-tdesc-selftest.c: New file.
1852 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
1853
18542017-11-24 Alan Hayward <alan.hayward@arm.com>
1855
1856 * configure.srv: Add new file.
1857 * linux-aarch64-low.c (initialize_low_arch): Call init func.
1858 * linux-aarch64-tdesc-selftest.c: New file.
1859 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
1860
49bdb7ee
AH
18612017-11-24 Alan Hayward <alan.hayward@arm.com>
1862
1863 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
1864 * linux-aarch64-low.c (initialize_low_arch): Remove init.
1865 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
1866
d6d7ce56
AH
18672017-11-24 Alan Hayward <alan.hayward@arm.com>
1868
1869 * configure.srv: Add new files.
1870 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
1871 aarch64_linux_read_description.
1872 * linux-aarch64-low.c (aarch64_linux_read_description):
1873 Merge with aarch64_arch_setup.
1874 (aarch64_arch_setup): Call aarch64_linux_read_description.
1875 * linux-aarch64-tdesc.c: New file.
1876 * linux-aarch64-tdesc.h: New file.
1877
506fe5f4
YQ
18782017-11-24 Yao Qi <yao.qi@linaro.org>
1879
1880 * configure.srv: Set $srv_regobj for tic6x-linux.
1881 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
1882 (tic6x_read_description): Move some code to tic6x_arch_setup.
1883 (tic6x_tdesc_test): New function.
1884 (initialize_low_arch): Call selftests::register_test.
1885
29f9a567
YQ
18862017-11-22 Yao Qi <yao.qi@linaro.org>
1887
1888 * remote-utils.c (prepare_resume_reply): Use memcpy.
1889
578290ec
SM
18902017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1891
1892 * linux-low.c (kill_one_lwp_callback): Return void, take
1893 argument directly, don't filter on pid.
1894 (linux_kill): Use for_each_thread.
1895
eca55aec
SM
18962017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1897
1898 * linux-low.c (need_step_over_p): Return bool, remove dummy
1899 argument.
1900 (linux_resume, proceed_all_lwps): Use find_thread.
1901
25c28b4d
SM
19022017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1903
1904 * linux-low.c (resume_status_pending_p): Return bool, remove
1905 flag_p argument.
1906 (linux_resume): Use find_thread.
1907
5fdda392
SM
19082017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1909
1910 * linux-low.c (struct thread_resume_array): Remove.
1911 (linux_set_resume_request): Return void, take arguments
1912 directly.
1913 (linux_resume): Use for_each_thread.
1914
fcb056a5
SM
19152017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1916
1917 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
1918 return bool, remove data argument.
1919 (linux_stabilize_threads): Use find_thread.
1920
139720c5
SM
19212017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1922
1923 * linux-low.c (unsuspend_one_lwp): Remove.
1924 (unsuspend_all_lwps): Use for_each_thread, inline code from
1925 unsuspend_one_lwp.
1926
6d1e5673
SM
19272017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1928
1929 * gdbthread.h (find_thread): Add overload with ptid_t filter.
1930 * linux-low.c (struct iterate_over_lwps_args): Remove.
1931 (iterate_over_lwps_filter): Remove.
1932 (iterate_over_lwps): Use find_thread.
1933
bbf550d5
SM
19342017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1935
1936 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
1937 (linux_handle_new_gdb_connection): Use for_each_thread, inline
1938 code from reset_lwp_ptrace_options_callback.
1939
00192f77
SM
19402017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1941
1942 * linux-arm-low.c (struct update_registers_data): Remove.
1943 (update_registers_callback): Return void, take arguments
1944 directly, don't check thread's pid.
1945 (arm_insert_point, arm_remove_point): Use for_each_thread.
1946
2bee2b6c
SM
19472017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1948
1949 * win32-low.c (continue_one_thread): Return void, take argument
1950 directly.
1951 (child_continue): Use for_each_thread.
1952
0b360f19
SM
19532017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1954
1955 * win32-i386-low.c (update_debug_registers_callback): Rename
1956 to ...
1957 (update_debug_registers): ... this, return void, remove pid_p arg.
1958 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
1959
f27866ba
SM
19602017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1961
1962 * inferiors.h (struct process_info): Add constructor, initialize
1963 fields..
1964 <syscalls_to_catch>: Change type to std::vector<int>.
1965 * inferiors.c (add_process): Allocate process_info with new.
1966 (remove_process): Free process_info with delete.
1967 * linux-low.c (handle_extended_wait): Adjust.
1968 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
1969 * server.c (handle_general_set): Adjust.
1970
e849ea89
PA
19712017-11-16 Pedro Alves <palves@redhat.com>
1972
1973 * remote-utils.c (remote_close): Block SIGIO signals instead of
1974 uninstalling the SIGIO handler.
1975
1d0aa65c
AH
19762017-11-16 Alan Hayward <alan.hayward@arm.com>
1977
1978 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
1979
3491a34c
YQ
19802017-11-16 Yao Qi <yao.qi@linaro.org>
1981
1982 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
1983 (tic6x_store_gregset): Likewise.
1984 (tic6x_usrregs_info): Move it up.
1985
a602f924
AH
19862017-11-15 Alan Hayward <alan.hayward@arm.com>
1987
1988 * Makefile.in: Update arch rules.
1989 * configure.srv: Explicitly mark arch/ files.
1990
5616b6c3
AS
19912017-11-13 Andreas Schwab <schwab@suse.de>
1992
1993 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
1994 function.
1995 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
1996
d1928160
PA
19972017-11-06 Pedro Alves <palves@redhat.com>
1998
1999 * config.in, configure: Regenerate.
2000
bac608e7
SM
20012017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2002
2003 * target.c (struct thread_search): Remove.
2004 (thread_search_callback): Remove.
2005 (prepare_to_access_memory): Use for_each_thread instead of
2006 find_inferior. Inline code from thread_search_callback.
2007
eaddb425
SM
20082017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2009
2010 * server.c (struct visit_actioned_threads_data): Remove.
2011 (visit_actioned_threads): Change prototype to take arguments
2012 directly.
2013 (resume): Use find_thread instead of find_inferior.
2014
99078d34
SM
20152017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2016
2017 * server.c (queue_stop_reply_callback): Change prototype, return
2018 void.
2019 (find_status_pending_thread_callback): Remove.
2020 (handle_status): Replace find_inferior with find_thread and
2021 for_each_thread.
2022
cc628f3d
AH
20232017-10-25 Alan Hayward <alan.hayward@arm.com>
2024
2025 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
2026 with REGNO.
2027 (aarch64_store_gregset): Likewise.
2028 (aarch64_fill_fpregset): Likewise.
2029 (aarch64_store_fpregset): Likewise.
2030
4d3bb80e
SM
20312017-10-21 Simon Marchi <simon.marchi@ericsson.com>
2032
2033 * gdbthread.h (find_thread, for_each_thread): New functions.
2034 * inferiors.c (thread_of_pid): Remove.
2035 (find_any_thread_of_pid): Use find_thread.
2036 * linux-low.c (num_lwps): Use for_each_thread.
2037
7a7cdfa0
YQ
20382017-10-17 Yao Qi <yao.qi@linaro.org>
2039
2040 * Makefile.in: Remove one rule.
2041 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
2042
e675d170
YQ
20432017-10-17 Yao Qi <yao.qi@linaro.org>
2044
2045 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
2046 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
2047
7eb4e0f9
YQ
20482017-10-17 Yao Qi <yao.qi@linaro.org>
2049
2050 * configure.srv: Rename arm.o with arch/arm.o.
2051
60d6cfc9
YQ
20522017-10-17 Yao Qi <yao.qi@linaro.org>
2053
2054 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
2055 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
2056 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
2057 (arch-i386.o, arch-amd64.o): Remove rules.
2058 (arch/%.o): New rule.
2059 Update POSTCOMPILE and COMPILE.pre.
2060 * configure.ac: Invoke AC_CONFIG_COMMANDS.
2061 * configure: Re-generated.
2062 * configure.srv: Replace arch-i386.o with arch/i386.o.
2063 Replace arch-amd64.o with arch/amd64.o.
2064
5bfda255
YQ
20652017-10-16 Yao Qi <yao.qi@linaro.org>
2066
2067 * configure: Regenerated.
2068
9c80ecd6
SM
20692017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2070
2071 * inferiors.h: (struct inferior_list): Remove.
2072 (struct inferior_list_entry); Remove.
2073 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
2074 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
2075 get_first_inferior): Remove.
2076 (for_each_inferior, for_each_inferior_with_data, find_inferior,
2077 find_inferior_id, find_inferior_in_random): Change signature.
2078 * inferiors.c (all_threads): Change type to
2079 std::list<thread_info *>.
2080 (get_thread): Remove macro.
2081 (find_inferior, find_inferior_id): Change signature, implement
2082 using find_thread.
2083 (find_inferior_in_random): Change signature, implement using
2084 find_thread_in_random.
2085 (for_each_inferior, for_each_inferior_with_data): Change
2086 signature, implement using for_each_thread.
2087 (add_inferior_to_list, remove_inferior): Remove.
2088 (add_thread, get_first_thread, thread_of_pid,
2089 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
2090 (get_first_inferior, one_inferior_p, clear_inferior_list):
2091 Remove.
2092 (clear_inferiors, get_thread_process): Update.
2093 * gdbthread.h: Include <list>.
2094 (struct thread_info) <entry>: Remove field.
2095 <id>: New field.
2096 (all_threads): Change type to std::list<thread_info *>.
2097 (get_first_inferior): Add doc.
2098 (find_thread, for_each_thread, find_thread_in_random): New
2099 functions.
2100 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
2101 * linux-arm-low.c (update_registers_callback): Update.
2102 * linux-low.c (second_thread_of_pid_p): Update.
2103 (kill_one_lwp_callback, linux_detach_lwp_callback,
2104 delete_lwp_callback, status_pending_p_callback, same_lwp,
2105 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
2106 iterate_over_lwps, not_stopped_callback,
2107 resume_stopped_resumed_lwps, count_events_callback,
2108 select_singlestep_lwp_callback, select_event_lwp_callback,
2109 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
2110 suspend_and_send_sigstop_callback, wait_for_sigstop,
2111 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
2112 lwp_running, linux_set_resume_request, resume_status_pending_p,
2113 need_step_over_p, start_step_over, linux_resume_one_thread,
2114 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
2115 reset_lwp_ptrace_options_callback): Update.
2116 * linux-mips-low.c (update_watch_registers_callback): Update.
2117 * regcache.c (regcache_invalidate_one, regcache_invalidate):
2118 Update.
2119 (free_register_cache_thread_one): Remove.
2120 (regcache_release): Update.
2121 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
2122 handle_qxfer_threads_worker): Update.
2123 (handle_query): Update, use list iterator.
2124 (visit_actioned_threads, handle_pending_status,
2125 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
2126 clear_pending_status_callback, set_pending_status_callback,
2127 find_status_pending_thread_callback, handle_status,
2128 process_serial_event): Update.
2129 * target.c (thread_search_callback): Update.
2130 * thread-db.c (thread_db_get_tls_address): Update.
2131 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
2132 Update.
2133 * win32-i386-low.c (update_debug_registers_callback): Update.
2134 * win32-low.c (delete_thread_info, child_delete_thread,
2135 continue_one_thread, suspend_one_thread,
2136 get_child_debug_event): Adjust.
2137
9179355e
SM
21382017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2139
2140 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
2141 * inferiors.h: Include <list>.
2142 (struct process_info) <entry>: Remove field.
2143 <pid>: New field.
2144 (pid_of): Change macro to function.
2145 (ptid_of, lwpid_of): Remove macro.
2146 (all_processes): Change type to std::list<process_info *>.
2147 (ALL_PROCESSES): Remove macro.
2148 (for_each_process, find_process): New function.
2149 * inferiors.c (all_processes): Change type to
2150 std::list<process_info *>.
2151 (find_thread_process): Adjust.
2152 (add_process): Likewise.
2153 (remove_process): Likewise.
2154 (find_process_pid): Likewise.
2155 (get_first_process): Likewise.
2156 (started_inferior_callback): Remove.
2157 (have_started_inferiors_p): Adjust.
2158 (attached_inferior_callback): Remove.
2159 (have_attached_inferiors_p): Adjust.
2160 * linux-low.c (check_zombie_leaders): Likewise.
2161 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
2162 (x86_linux_update_xmltarget): Adjust.
2163 * server.c (handle_query): Likewise.
2164 (gdb_reattached_process): Remove.
2165 (handle_status): Adjust.
2166 (kill_inferior_callback): Likewise.
2167 (detach_or_kill_inferior): Remove.
2168 (print_started_pid): Likewise.
2169 (print_attached_pid): Likewise.
2170 (detach_or_kill_for_exit): Update.
2171 (process_serial_event): Likewise.
2172 * linux-arm-low.c (arm_new_fork): Likewise.
2173
c9cb8905
SM
21742017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2175
2176 * dll.h: Include <list>.
2177 (struct dll_info): Add constructor.
2178 <entry>: Remove field.
2179 (all_dlls): Change type to std::list<dll_info>.
2180 * dll.c: Include <algorithm>.
2181 (get_dll): Remove macro.
2182 (all_dlls): Change type to std::list<dll_info *>.
2183 (free_one_dll): Remove.
2184 (match_dll): Likewise.
2185 (loaded_dll): Adjust.
2186 (unloaded_dll): Adjust to all_dlls type change, use
2187 std::find_if. Inline code from match_dll.
2188 (clear_dlls): Adjust to all_dlls type change.
2189 * server.c (emit_dll_description): Remove.
2190 (handle_qxfer_libraries): Adjust to all_dlls type change,
2191 integrate emit_dll_description's functionality.
2192
04ec7890
SM
21932017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2194
2195 * linux-low.h (struct linux_target_ops) <delete_process>: New
2196 field.
2197 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
2198 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
2199 (struct linux_target_ops): Add delete_process callback.
2200 * linux-arm-low.c (arm_delete_process): New.
2201 (struct linux_target_ops): Add delete_process callback.
2202 * linux-bfin-low.c (struct linux_target_ops): Likewise.
2203 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
2204 * linux-m32r-low.c (struct linux_target_ops): Likewise.
2205 * linux-mips-low.c (mips_linux_delete_process): New.
2206 (struct linux_target_ops): Add delete_process callback.
2207 * linux-ppc-low.c (struct linux_target_ops): Likewise.
2208 * linux-s390-low.c (struct linux_target_ops): Likewise.
2209 * linux-sh-low.c (struct linux_target_ops): Likewise.
2210 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
2211 * linux-tile-low.c (struct linux_target_ops): Likewise.
2212 * linux-x86-low.c (x86_linux_delete_process): New.
2213 (struct linux_target_ops): Add delete_process callback.
2214 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
2215
466eecee
SM
22162017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2217
2218 * linux-aarch64-low.c (the_low_target): Add thread delete
2219 callback.
2220 * linux-arm-low.c (arm_delete_thread): New function.
2221 (the_low_target): Add thread delete callback.
2222 * linux-bfin-low.c (the_low_target): Likewise.
2223 * linux-crisv32-low.c (the_low_target): Likewise.
2224 * linux-low.c (delete_lwp): Invoke delete_thread callback if
2225 set.
2226 * linux-low.h (struct linux_target_ops) <delete_thread>: New
2227 field.
2228 * linux-m32r-low.c (the_low_target): Add thread delete callback.
2229 * linux-mips-low.c (mips_linux_delete_thread): New function.
2230 (the_low_target): Add thread delete callback.
2231 * linux-ppc-low.c (the_low_target): Likewise.
2232 * linux-s390-low.c (the_low_target): Likewise.
2233 * linux-sh-low.c (the_low_target): Likewise.
2234 * linux-tic6x-low.c (the_low_target): Likewise.
2235 * linux-tile-low.c (the_low_target): Likewise.
2236 * linux-x86-low.c (the_low_target): Likewise.
2237 * linux-xtensa-low.c (the_low_target): Likewise.
2238
b79f7801
YZ
22392017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
2240
2241 * win32-low.c: Include "common-inferior.h".
2242
bc3b087d
SDJ
22432017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2244
2245 * inferiors.c (set_inferior_cwd): New function.
2246 * server.c (handle_general_set): Handle QSetWorkingDir packet.
2247 (handle_query): Inform that QSetWorkingDir is supported.
2248 * win32-low.c (create_process): Pass the inferior's cwd to
2249 CreateProcess.
2250
d092c5a2
SDJ
22512017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2252
2253 * inferiors.c (current_inferior_cwd): New global variable.
2254 (get_inferior_cwd): New function.
2255 * inferiors.h (struct process_info) <cwd>: New field.
2256
7da0a886
SDJ
22572017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2258
2259 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
2260 (OBS): Add gdb_tilde_expand.o.
2261
289a6840
SM
22622017-10-02 Simon Marchi <simon.marchi@ericsson.com>
2263
2264 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
2265 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
2266
256642e8
PA
22672017-09-29 Pedro Alves <palves@redhat.com>
2268
2269 * ax.c (gdb_parse_agent_expr): Constify.
2270 * ax.h (gdb_parse_agent_expr): Constify.
2271 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
2272 Constify.
2273 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
2274 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
2275 * remote-utils.h (read_ptid): Constify.
2276 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
2277 (process_point_options, process_serial_event): Constify.
2278 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
2279 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
2280 (cmd_qtbuffer): Constify.
2281
5b9ca4d4
PA
22822017-09-29 Pedro Alves <palves@redhat.com>
2283
2284 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
2285 fails.
2286
94c207e0
PA
22872017-09-29 Pedro Alves <palves@redhat.com>
2288
2289 * linux-low.c (handle_extended_wait): Pass parent thread instead
2290 of process to thread_db_notice_clone.
2291 * linux-low.h (thread_db_notice_clone): Replace parent process
2292 parameter with parent thread parameter.
2293 * thread-db.c (find_one_thread): Add comment.
2294 (thread_db_notice_clone): Replace parent process parameter with
2295 parent thread parameter. Temporarily switch to the parent thread.
2296
75352e28
SDJ
22972017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
2298
2299 * gdbthread.h: Include "common-gdbthread.h".
2300 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
2301 "if" when validating the ptid.
2302 * remote-utils.c: Include "gdbthread.h".
2303 (prepare_resume_reply): Use "switch_to_thread".
2304 * target.c (done_accessing_memory): Likewise.
2305
ad339634
AA
23062017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
2307
2308 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
2309 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
2310 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
2311 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
2312 s390x-gs-linux64-ipa.o to ipa_obj.
2313 * linux-s390-low.c (HWCAP_S390_GS): New define.
2314 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
2315 New functions.
2316 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
2317 (s390_arch_setup): Check for guarded-storage support and choose
2318 appropriate tdesc.
2319 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
2320 init_registers_s390x_gs_linux64.
2321 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
2322 enum value.
2323 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
2324 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
2325
cc4d742f
SM
23262017-09-22 Simon Marchi <simon.marchi@ericsson.com>
2327
2328 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
2329
f6327dcb
KB
23302017-09-21 Kevin Buettner <kevinb@redhat.com>
2331
2332 * linux-low.h (struct lwp_info): Add new field, thread_handle.
2333 (thread_db_thread_handle): Declare.
2334 * linux-low.c (linux_target_ops): Initialize thread_handle.
2335 * server.c (handle_qxfer_threads_worker): Add support for
2336 "handle" attribute.
2337 * target.h (struct target_ops): Add new function pointer,
2338 thread_handle.
2339 (target_thread_handle): Define.
2340 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
2341 field in lwp.
2342 (thread_db_thread_handle): New function.
2343
86299109
KB
23442017-09-21 Kevin Buettner <kevinb@redhat.com>
2345
2346 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
2347 * linux-low.h (thread_db_notice_clone): Declare.
2348 * thread-db.c (thread_db_notice_clone): New function.
2349
f557a88a
PA
23502017-09-21 Pedro Alves <palves@redhat.com>
2351
2352 * server.c (gdb_read_memory, handle_status, process_serial_event)
2353 (handle_serial_event, handle_target_event): Adjust to
2354 set_desired_thread prototype change.
2355 * target.c (set_desired_thread): Remove 'use_general' parameter
2356 and adjust.
2357 * target.h (set_desired_thread): Remove 'use_general' parameter.
2358
223ffa71
TT
23592017-09-20 Tom Tromey <tom@tromey.com>
2360
2361 * target.c (target_terminal::terminal_state): Define.
2362 (target_terminal::init): Rename from target_terminal_init.
2363 (target_terminal::inferior): Rename from
2364 target_terminal_inferior.
2365 (target_terminal::ours): Rename from target_terminal_ours.
2366 (target_terminal::ours_for_output, target_terminal::info): New.
2367
04fd3ba9
SM
23682017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2369
2370 * server.c (accumulate_file_name_length): Remove.
2371 (emit_dll_description): Adjust to std::string change.
2372 (handle_qxfer_libraries): Use std::string to hold document.
2373
5e187554
SM
23742017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2375
2376 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
2377 return type of xml_escape_text.
2378 * server.c (emit_dll_description): Likewise.
2379
1526853e
SM
23802017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2381
2382 * server.c (captured_main): Accept argument for --selftest.
2383 Update run_tests call.
2384 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
2385 when registering selftests.
2386
c4dfafab
SDJ
23872017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
2388
2389 * regcache.c (get_thread_regcache): Update code to use "std::vector"
2390 instead of "VEC" for "target_desc.reg_defs".
2391 (regcache_cpy): Likewise.
2392 (registers_to_string): Likewise.
2393 (registers_from_string): Likewise.
2394 (find_regno): Likewise.
2395 (supply_regblock): Likewise.
2396 (regcache_raw_read_unsigned): Likewise.
2397 * tdesc.c (init_target_desc): Likewise.
2398 (tdesc_create_reg): Likewise.
2399 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
2400 (struct target_desc) <reg_defs>: Convert to "std::vector".
2401 (target_desc): Do not initialize "reg_defs".
2402 (~target_desc): Update code to use "std::vector" instead of "VEC"
2403 for "target_desc.reg_defs".
2404 (operator==): Likewise.
2405
124aceb4
SM
24062017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2407
2408 * inferiors.h (thread_to_gdb_id): Remove.
2409 * inferiors.c (thread_to_gdb_id): Remove.
2410 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
2411 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
2412 lynx_store_registers, lynx_read_memory, lynx_write_memory):
2413 Likewise.
2414 * nto-low.c (nto_fetch_registers, nto_store_registers,
2415 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
2416
96cde54f
SM
24172017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2418
2419 * inferiors.h (gdb_id_to_thread_id): Remove.
2420 * inferiors.c (gdb_id_to_thread_id): Remove.
2421 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
2422 removal. Move pid declaration closer to where it's used.
2423
e8ca139e
SM
24242017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2425
2426 * server.c (handle_detach): New function.
2427 (process_serial_event): Move code out, call handle_detach.
2428
f8a4e119
SM
24292017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2430
2431 * server.c (require_running): Rename to ...
2432 (require_running_or_return): ... this ...
2433 (require_running_or_break): ... and this.
2434 (handle_query, process_serial_event): Adjust.
2435
0eb0a407
SM
24362017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2437
2438 * linux-low.c (linux_set_resume_request): Remove unused
2439 variables.
2440
785922a5
SM
24412017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2442
2443 * server.c (first_thread_of): Remove.
2444 (process_serial_event): Replace usage of first_thread_of with
2445 find_any_thread_of_pid.
2446 * tracepoint.c (same_process_p): Remove.
2447 (gdb_agent_about_to_close): Replace usage of same_process_p with
2448 find_any_thread_of_pid.
2449 * linux-x86-low.c (same_process_callback): Remove.
2450 (x86_arch_setup_process_callback): Replace usage of
2451 same_process_callback with find_any_thread_of_pid.
2452 * thread-db.c (any_thread_of): Remove.
2453 (switch_to_process): Replace usage of any_thread_of with
2454 find_any_thread_of_pid.
2455 * inferiors.c (thread_pid_matches_callback): Remove.
2456 (find_thread_process): Adjust to use find_any_thread_of_pid.
2457
a059f00c
SDJ
24582017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
2459
2460 * regcache.c (get_thread_regcache): Guard calls to "memset"
e79be6e5 2461 with "!VEC_empty".
a059f00c 2462
cc397f3a
SDJ
24632017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
2464
2465 * linux-low.c (handle_extended_wait): Use
2466 "allocate_target_description" instead of "XNEW".
2467 * linux-x86-low.c (initialize_low_arch): Likewise.
2468
22916b07
YQ
24692017-09-05 Yao Qi <yao.qi@linaro.org>
2470
2471 * configure.srv (srv_i386_regobj): Remove.
2472 (srv_amd64_regobj): Remove.
2473 (srv_regobj): Set it to "" for x86 non-linux targets.
2474 * linux-x86-tdesc.c (i386_linux_read_description):
2475 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
2476 (init_registers_i386): Remove the declaration.
2477 (tdesc_i386): Remove the declaration.
2478 (lynx_i386_arch_setup): Call i386_create_target_description.
2479 * nto-x86-low.c: Likewise.
2480 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
2481 [!__x86_64__]: include arch/i386.h.
2482 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
2483
38602d55
YQ
24842017-09-05 Yao Qi <yao.qi@linaro.org>
2485
2486 * configure.srv (srv_amd64_linux_xmlfiles): Remove
2487 i386/amd64-XXX-linux from it.
2488
44b886ff
YQ
24892017-09-05 Yao Qi <yao.qi@linaro.org>
2490
2491 * configure.srv: Empty srv_amd64_linux_regobj if $development is
2492 false.
2493 (ipa_amd64_linux_regobj): Remove.
2494 (ipa_x32_linux_regobj): Remove.
2495
b4570e4b
YQ
24962017-09-05 Yao Qi <yao.qi@linaro.org>
2497
2498 * Makefile.in (arch-amd64.o): New rule.
2499 * configure.srv: Append arch-amd64.o.
2500 * linux-amd64-ipa.c: Include common/x86-xstate.h.
2501 (get_ipa_tdesc): Call amd64_linux_read_description.
2502 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
2503 and init_registers_amd64_XXX.
2504 * linux-x86-low.c (x86_linux_read_description): Call
2505 amd64_linux_read_description.
2506 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
2507 (initialize_low_arch): Don't call init_registers_x32_XXX and
2508 init_registers_amd64_XXX.
2509 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
2510 and tdesc_amd64_XXX.
2511 [__x86_64__] (amd64_tdesc_test): New function.
2512 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
2513 and init_registers_amd64_XXX.
2514 * linux-x86-tdesc.c: Include arch/amd64.h.
2515 (xcr0_to_tdesc_idx): New function.
2516 (i386_linux_read_description): New function.
2517 (amd64_get_ipa_tdesc_idx): New function.
2518 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
2519 (amd64_get_ipa_tdesc): Declare.
2520
d1f28ea2
YQ
25212017-09-05 Yao Qi <yao.qi@linaro.org>
2522
2523 * configure.srv (srv_i386_linux_xmlfiles): Remove
2524 i386/i386-XXX-linux.xml from it.
2525
25a93583
YQ
25262017-09-05 Yao Qi <yao.qi@linaro.org>
2527
2528 * configure.srv: Set srv_i386_linux_regobj empty if $development
2529 is false.
2530 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
2531 initialize_low_tdesc.
2532 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
2533 with #if initialize_low_tdesc.
2534 * linux-x86-tdesc-selftest.c: New file.
2535 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
2536
5f035c07
YQ
25372017-09-05 Yao Qi <yao.qi@linaro.org>
2538
2539 * Makefile.in (arch-i386.o): New rule.
2540 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
2541 (x86_64-*-linux*): Likewise.
2542 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
2543 include arch/i386.h.
2544 (i386_linux_read_description): Remove code and call
2545 i386_create_target_description.
2546 * tdesc.c (allocate_target_description): New function.
2547 * tdesc.h (set_tdesc_architecture): Remove declaration.
2548 (set_tdesc_osabi): Likewise.
2549
0abe8a89
YQ
25502017-09-05 Yao Qi <yao.qi@linaro.org>
2551
2552 * linux-x86-tdesc.c: Don't include <inttypes.h>.
2553 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
2554 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
2555 .xmltarget.
2556 * server.c (get_features_xml): Call tdesc_get_features_xml.
2557 * tdesc.c (set_tdesc_architecture): New function.
2558 (set_tdesc_osabi): New function.
2559 (tdesc_get_features_xml): New function.
2560 (tdesc_create_feature): Add an argument.
2561 * tdesc.h (struct target_desc) <features>: New field.
2562 <arch, osabi>: New field.
2563 (~target_desc): xfree features, arch, and osabi.
2564 (target_desc::oerator==): Don't compare .xmltarget.
2565 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
2566 (set_tdesc_osabi): Likewise.
2567 (tdesc_get_features_xml): Likewise.
2568
0a188386
YQ
25692017-09-05 Yao Qi <yao.qi@linaro.org>
2570
2571 * linux-x86-tdesc.c: Include selftest.h.
2572 (i386_tdesc_test): New function.
2573 (initialize_low_tdesc): Call selftests::register_test.
2574 * tdesc.h: Include regdef.h.
2575 (target_desc): Override operator == and !=.
2576
f49ff000
YQ
25772017-09-05 Yao Qi <yao.qi@linaro.org>
2578
2579 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
2580 (ipa_obj): Likewise.
2581 * linux-i386-ipa.c: Include common/x86-xstate.h
2582 (get_ipa_tdesc): Call i386_linux_read_description.
2583 (initialize_low_tracepoint): Don't call init_registers_XXX
2584 functions, call initialize_low_tdesc instead.
2585 * linux-x86-low.c (x86_linux_read_description): Call
2586 i386_linux_read_description.
2587 (initialize_low_arch): Don't call init_registers_i386_XXX
2588 functions, call initialize_low_tdesc.
2589 * linux-x86-tdesc.c: New file.
2590 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
2591 (i386_get_ipa_tdesc_idx): Declare.
2592 (i386_get_ipa_tdesc): Declare.
2593 (initialize_low_tdesc): Declare.
2594
2b68ef2f
YQ
25952017-09-05 Yao Qi <yao.qi@linaro.org>
2596
2597 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
2598 instead of 0.
2599
f7000548
YQ
26002017-09-05 Yao Qi <yao.qi@linaro.org>
2601
2602 * Makefile.in (IPA_OBJS): Add vec-ipa.o
2603 * regcache.c (get_thread_regcache): Use VEC_length.
2604 (init_register_cache): Likewise.
2605 (regcache_cpy): Likewise.
2606 (registers_to_string): Iterate reg_defs via VEC_iterate.
2607 (find_regno): Likewise.
2608 (find_register_by_number): Use VEC_index.
2609 (register_size): Call find_register_by_number.
2610 (register_data): Call find_register_by_number.
2611 (supply_regblock): Use VEC_length.
2612 (regcache_raw_read_unsigned): Likewise.
2613 * tdesc.c (init_target_desc): Iterate reg_defs via
2614 VEC_iterate.
2615 (default_description): Update initializer.
2616 (copy_target_description): Don't update field num_registers.
2617 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
2618 <num_registers>: Remove.
2619
50a421ac
SM
26202017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2621
2622 * Makefile.in (.SECONDARY): Define target.
2623
23fdd69e
SM
26242017-09-03 Simon Marchi <simon.marchi@ericsson.com>
2625
2626 * linux-low.c (linux_wait_1): Adjust.
2627 * server.c (queue_stop_reply_callback): Adjust.
2628
0a2dde4a
SDJ
26292017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
2630
2631 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
2632 QEnvironmentUnset and QEnvironmentReset packets.
2633 (handle_query): Inform remote that QEnvironmentHexEncoded,
2634 QEnvironmentUnset and QEnvironmentReset are supported.
2635
6afd337d
SM
26362017-08-25 Simon Marchi <simon.marchi@ericsson.com>
2637
2638 * inferiors.h (inferior_target_data): Rename to ...
2639 (thread_target_data): ... this.
2640 (inferior_regcache_data): Rename to ...
2641 (thread_regcache_data): ... this.
2642 (set_inferior_regcache_data): Rename to ...
2643 (set_thread_regcache_data): ... this.
2644 * inferiors.c (inferior_target_data): Rename to ...
2645 (thread_target_data): ... this.
2646 (inferior_regcache_data): Rename to ...
2647 (thread_regcache_data): ... this.
2648 (set_inferior_regcache_data): Rename to ...
2649 (set_thread_regcache_data): ... this.
2650 (free_one_thread): Update.
2651 * linux-low.h (get_thread_lwp): Update.
2652 * regcache.c (get_thread_regcache): Update.
2653 (regcache_invalidate_thread): Update.
2654 (free_register_cache_thread): Update.
2655 * win32-i386-low.c (update_debug_registers_callback): Update.
2656 (win32_get_current_dr): Update.
2657 * win32-low.c (thread_rec): Update.
2658 (delete_thread_info): Update.
2659 (continue_one_thread): Update.
2660 (suspend_one_thread): Update.
2661
a160cc46
SM
26622017-08-24 Simon Marchi <simon.marchi@ericsson.com>
2663
2664 * inferiors.c (set_inferior_target_data): Remove.
2665 * inferiors.h (set_inferior_target_data): Remove.
2666
6d580b63
YQ
26672017-08-18 Yao Qi <yao.qi@linaro.org>
2668
2669 * Makefile.in (OBS): Add selftest.o.
2670 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
2671 * configure, config.in: Re-generated.
2672 * server.c: Include common/sefltest.h.
2673 (captured_main): Handle option --selftest.
2674
f5a29eb0
YQ
26752017-08-09 Yao Qi <yao.qi@linaro.org>
2676
2677 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
2678 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
2679 i386-avx-mpx.o and i386-mmx.o.
2680 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
2681 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
2682 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
2683 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
2684 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
2685 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
2686 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
2687 i386/amd64-avx-mpx.xml.
2688
57757c2f
YQ
26892017-08-09 Yao Qi <yao.qi@linaro.org>
2690
2691 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
2692 and x32-avx-avx512.o.
2693 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
2694 i386/x32-avx-avx512.xml.
2695
229d26fc
SM
26962017-07-26 Simon Marchi <simon.marchi@ericsson.com>
2697
2698 * tracepoint.h (enum class fast_tpoint_collect_result): New
2699 enumeration.
2700 (fast_tracepoint_collecting): Change return type to
2701 fast_tpoint_collect_result.
2702 * tracepoint.c (fast_tracepoint_collecting): Likewise.
2703 * linux-low.h: Include tracepoint.h.
2704 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
2705 fast_tpoint_collect_result.
2706 * linux-low.c (handle_tracepoints): Adjust.
2707 (linux_fast_tracepoint_collecting): Change return type to
2708 fast_tpoint_collect_result.
2709 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
2710 linux_wait_1, stuck_in_jump_pad_callback,
2711 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
2712 proceed_one_lwp): Adjust to type change.
2713
2e1e43e1
YQ
27142017-07-10 Yao Qi <yao.qi@linaro.org>
2715
2716 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
2717
adc764e7
YQ
27182017-06-29 Yao Qi <yao.qi@linaro.org>
2719
2720 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
2721 Remove.
2722 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
2723
a206891a
SM
27242017-06-20 Simon Marchi <simon.marchi@ericsson.com>
2725
2726 * Makefile.in (IPA_OBJS): Sort and format one item per line.
2727
9a6c7d9c
SDJ
27282017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
2729
2730 * linux-low.c (linux_create_inferior): Adjust code to access the
2731 environment information via 'gdb_environ' class.
2732 * lynx-low.c (lynx_create_inferior): Likewise.
2733 * server.c (our_environ): Make it an instance of 'gdb_environ'.
2734 (get_environ): Return a pointer to 'our_environ'.
2735 (captured_main): Initialize 'our_environ'.
2736 * server.h (get_environ): Adjust prototype.
2737 * spu-low.c (spu_create_inferior): Adjust code to access the
2738 environment information via 'gdb_environ' class.
2739
ae3e2ccf
SM
27402017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2741
2742 * linux-low.c (linux_read_memory, linux_write_memory): Remove
2743 usage of "register" keyword.
2744
3e019bdc
SM
27452017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2746
2747 * configure: Re-generate.
2748
8465943a
SM
27492017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2750
2751 * configure: Re-generate.
2752
cf0dd6f0
SM
27532017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2754
2755 * Makefile.in (COMPILE.pre): Add "-x c++".
2756
9845682b
SDJ
27572017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
2758
2759 * fork-child.c: Conditionally include <signal.h>.
2760
aefd8b33
SDJ
27612017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2762
2763 * server.c (handle_general_set): Handle new packet
2764 "QStartupWithShell".
2765 (handle_query): Add "QStartupWithShell" to the list of supported
2766 packets.
2767 (gdbserver_usage): Add help text explaining the
2768 new "--startup-with-shell" and "--no-startup-with-shell" CLI
2769 options.
2770 (captured_main): Recognize and act upon the presence of the new
2771 CLI options.
2772
2090129c
SDJ
27732017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2774 Pedro Alves <palves@redhat.com>
2775
2776 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
2777 * configure: Regenerate.
2778 * configure.srv (srv_linux_obj): Add "fork-child.o" and
2779 "fork-inferior.o".
2780 (i[34567]86-*-lynxos*): Likewise.
2781 (spu*-*-*): Likewise.
2782 * fork-child.c: New file.
2783 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
2784 and "environ.h".
2785 (linux_ptrace_fun): New function.
2786 (linux_create_inferior): Adjust function prototype to reflect
2787 change on "target.h". Adjust function code to use
2788 "fork_inferior".
2789 (linux_request_interrupt): Delete "signal_pid".
2790 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
2791 (lynx_ptrace_fun): New function.
2792 (lynx_create_inferior): Adjust function prototype to reflect
2793 change on "target.h". Adjust function code to use
2794 "fork_inferior".
2795 * nto-low.c (nto_create_inferior): Adjust function prototype and
2796 code to reflect change on "target.h". Update comments.
2797 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
2798 "common-terminal.h" and "environ.h".
2799 (terminal_fd): Moved to fork-child.c.
2800 (old_foreground_pgrp): Likewise.
2801 (restore_old_foreground_pgrp): Likewise.
2802 (last_status): Make it global.
2803 (last_ptid): Likewise.
2804 (our_environ): New variable.
2805 (startup_with_shell): Likewise.
2806 (program_name): Likewise.
2807 (program_argv): Rename to...
2808 (program_args): ...this.
2809 (wrapper_argv): New variable.
2810 (start_inferior): Delete function.
2811 (get_exec_wrapper): New function.
2812 (get_exec_file): Likewise.
2813 (get_environ): Likewise.
2814 (prefork_hook): Likewise.
2815 (post_fork_inferior): Likewise.
2816 (postfork_hook): Likewise.
2817 (postfork_child_hook): Likewise.
2818 (handle_v_run): Update code to deal with arguments coming from the
2819 remote host. Update calls from "start_inferior" to
2820 "create_inferior".
2821 (captured_main): Likewise. Initialize environment variable. Call
2822 "have_job_control".
2823 * server.h (post_fork_inferior): New prototype.
2824 (get_environ): Likewise.
2825 (last_status): Declare.
2826 (last_ptid): Likewise.
2827 (signal_pid): Likewise.
2828 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
2829 (spu_ptrace_fun): New function.
2830 (spu_create_inferior): Adjust function prototype to reflect change
2831 on "target.h". Adjust function code to use "fork_inferior".
2832 * target.c (target_terminal_init): New function.
2833 (target_terminal_inferior): Likewise.
2834 (target_terminal_ours): Likewise.
2835 * target.h: Include <vector>.
2836 (struct target_ops) <create_inferior>: Update prototype.
2837 (create_inferior): Update macro.
2838 * utils.c (gdb_flush_out_err): New function.
2839 * win32-low.c (win32_create_inferior): Adjust function prototype
2840 and code to reflect change on "target.h".
2841
043a4934
SDJ
28422017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2843
2844 * inferiors.c (switch_to_thread): New function.
2845
15652511
SDJ
28462017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2847
2848 * Makefile.in (SFILE): Add "common/job-control.c".
2849 (OBS): Add "job-control.o".
2850
21ea5acd
SDJ
28512017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
2852
2853 * Makefile: Remove "@host_makefile_frag@".
2854
e13cb306
PA
28552017-05-05 Pedro Alves <palves@redhat.com>
2856
2857 * configure: Regenerate.
2858
c94fee56
SDJ
28592017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
2860
2861 * configure: Regenerate.
2862
a0ff9e1a
SM
28632017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
2864
2865 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
2866 software_single_step change of return type to
2867 std::vector<CORE_ADDR>.
2868 * linux-low.c (install_software_single_step_breakpoints):
2869 Likewise.
2870 * linux-low.h (install_software_single_step_breakpoints):
2871 Likewise.
2872
be628ab8
SDJ
28732017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
2874
2875 * remote-utils.c: Include "gdb_termios.h" instead of
2876 "terminal.h".
2877 * terminal.h: Delete file.
2878
7c5ded6a
SDJ
28792017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
2880
2881 * server.c: Include <vector>.
2882 <program_argv, wrapper_argv>: Convert to std::vector.
2883 (start_inferior): Rewrite function to use C++.
2884 (handle_v_run): Likewise. Update code that calculates the argv
2885 based on the vRun packet; use C++.
2886 (captured_main): Likewise.
2887
436252de
SM
28882017-04-06 Simon Marchi <simon.marchi@ericsson.com>
2889
2890 * server.c (handle_v_cont): Initialize thread_resume::thread
2891 with null_ptid.
2892
9bf2a700
PA
28932017-04-05 Pedro Alves <palves@redhat.com>
2894
2895 * configure: Regenerate.
2896
a121b7c1
PA
28972017-04-05 Pedro Alves <palves@redhat.com>
2898
2899 * gdbreplay.c (sync_error): Constify.
2900 * linux-x86-low.c (push_opcode): Constify.
2901
21c8a587
PA
29022017-04-05 Pedro Alves <palves@redhat.com>
2903
2904 * win32-low.c (get_child_debug_event)
2905 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
2906 Report TARGET_WAITKIND_SPURIOUS instead.
2907
fb32b4f7
PA
29082017-04-05 Pedro Alves <palves@redhat.com>
2909
e79be6e5
SM
2910 * remote-utils.c (remote_prepare, remote_open): Constify.
2911 * remote-utils.h (remote_prepare, remote_open): Constify.
2912 * server.c (captured_main): Constify 'port' handling.
fb32b4f7 2913
65dd1e59
SM
29142017-04-04 Simon Marchi <simon.marchi@ericsson.com>
2915
2916 * Makefile.in (clean): Clear .deps.
2917
8fa5b777
SM
29182017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
2919
2920 * .gitignore: Remove generated files, replace with wildcard.
2921 * (clean): Replace removal of generated files with wildcard.
2922 (version.c): Replace with...
2923 (version-generated.c): ...this.
2924 (xml-builtin.c): Replace with...
2925 (xml-builtin-generated.c): ...this.
2926 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
2927 (%.c: *regformats*): Replace with...
2928 (%-generated.c: *regformats*): ...this.
2929
a12e714b
MF
29302017-03-27 Max Filippov <jcmvbkbc@gmail.com>
2931
2932 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
2933 (xtensa_fill_gregset): Call collect_register_by_name for
2934 threadptr register.
2935 (xtensa_store_gregset): Call supply_register_by_name for
2936 threadptr register.
2937
1a09b50a
MF
29382017-03-27 Max Filippov <jcmvbkbc@gmail.com>
2939
2940 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
2941 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
2942 (xtensa_store_gregset): Call supply_register for all registers in
2943 a0_regnum..a0_regnum + C0_NREGS range.
2944
1a01e7c6
SM
29452017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2946
2947 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
2948 (ax-ipa.o: ax.c): Remove.
2949 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
2950 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
2951 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
2952 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
2953 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
2954
36bc18a8
SM
29552017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2956
2957 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
2958 (print-utils-ipa.o: ../common/print-utils.c): Remove.
2959 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
2960 (errors-ipa.o: ../common/errors.c): Remove.
2961 (format-ipa.o: ../common/format.c): Remove.
2962 (common-utils-ipa.o: ../common/common-utils.c): Remove.
2963
a8ebe3d5
SM
29642017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2965
2966 * Makefile.in (%-ipa.o: %.c): New rule.
2967 (tracepoint-ipa.o: tracepoint.c): Remove.
2968 (utils-ipa.o: utils.c): Remove.
2969 (remote-utils-ipa.o: remote-utils.c): Remove.
2970 (regcache-ipa.o: regcache.c): Remove.
2971 (i386-linux-ipa.o: i386-linux.c): Remove.
2972 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
2973 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
2974 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
2975 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
2976 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
2977 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
2978 (amd64-linux-ipa.o: amd64-linux.c): Remove.
2979 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
2980 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
2981 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
2982 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
2983 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
2984 (aarch64-ipa.o: aarch64.c): Remove.
2985 (s390-linux32-ipa.o: s390-linux32.c): Remove.
2986 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
2987 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
2988 (s390-linux64-ipa.o: s390-linux64.c): Remove.
2989 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
2990 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
2991 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
2992 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
2993 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
2994 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
2995 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
2996 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
2997 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
2998 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
2999 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
3000 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
3001 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
3002 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
3003 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
3004 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
3005 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
3006 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
3007 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
3008 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
3009 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
3010 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
3011 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
3012 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
3013 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
3014 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
3015 (tdesc-ipa.o: tdesc.c): Remove.
3016 (x32-linux-ipa.o: x32-linux.c): Remove.
3017 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
3018 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
3019
50cfacb7
SM
30202017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3021
3022 * Makefile.in (%.o: ../arch/%.c): New rule.
3023 (arm.o: ../arch/arm.c): Remove.
3024 (arm-linux.o: ../arch/arm-linux.c): Remove.
3025 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
3026 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
3027
c5a22423
SM
30282017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3029
3030 * Makefile.in (%.o: ../nat/%.c): New rule.
3031 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
3032 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
3033 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
3034 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
3035 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
3036 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
3037 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
3038 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
3039 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
3040 (linux-personality.o: ../nat/linux-personality.c): Remove.
3041 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
3042 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
3043 (x86-linux.o: ../nat/x86-linux.c): Remove.
3044 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
3045 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
3046
6bda016b
SM
30472017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3048
3049 * Makefile.in (%.o: ../common/%.c): New rule.
3050 (signals.o: ../common/signals.c): Remove.
3051 (print-utils.o: ../common/print-utils.c): Remove.
3052 (rsp-low.o: ../common/rsp-low.c): Remove.
3053 (common-utils.o: ../common/common-utils.c): Remove.
3054 (posix-strerror.o: ../common/posix-strerror.c): Remove.
3055 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
3056 (vec.o: ../common/vec.c): Remove.
3057 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
3058 (xml-utils.o: ../common/xml-utils.c): Remove.
3059 (ptid.o: ../common/ptid.c): Remove.
3060 (buffer.o: ../common/buffer.c): Remove.
3061 (format.o: ../common/format.c): Remove.
3062 (filestuff.o: ../common/filestuff.c): Remove.
3063 (agent.o: ../common/agent.c): Remove.
3064 (errors.o: ../common/errors.c): Remove.
3065 (environ.o: ../common/environ.c): Remove.
3066 (common-debug.o: ../common/common-debug.c): Remove.
3067 (cleanups.o: ../common/cleanups.c): Remove.
3068 (common-exceptions.o: ../common/common-exceptions.c): Remove.
3069 (fileio.o: ../common/fileio.c): Remove.
3070 (common-regcache.o: ../common/common-regcache.c): Remove.
3071 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
3072 (new-op.o: ../common/new-op.c): Remove.
3073 (btrace-common.o: ../common/btrace-common.c): Remove.
3074
21122961
SM
30752017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3076
3077 * Makefile.in (%.o: ../target/%.c): New rule.
3078 (waitstatus.o: ../target/waitstatus.c): Remove.
3079
c362e621
SM
30802017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3081
3082 * Makefile.in
3083 (%.c: ../regformats/%.dat,
3084 (%.c: ../regformats/arm/%.dat,
3085 (%.c: ../regformats/i386/%.dat,
3086 (%.c: ../regformats/rs6000/%.dat): New rules.
3087 (aarch64.c): Remove.
3088 (reg-arm.c): Remove.
3089 (arm-with-iwmmxt.c): Remove.
3090 (arm-with-vfpv2.c): Remove.
3091 (arm-with-vfpv3.c): Remove.
3092 (arm-with-neon.c): Remove.
3093 (reg-bfin.c): Remove.
3094 (reg-cris.c): Remove.
3095 (reg-crisv32.c): Remove.
3096 (i386.c): Remove.
3097 (i386-linux.c): Remove.
3098 (i386-avx.c): Remove.
3099 (i386-avx-linux.c): Remove.
3100 (i386-avx-avx512.c): Remove.
3101 (i386-avx-avx512-linux.c): Remove.
3102 (i386-mpx.c): Remove.
3103 (i386-mpx-linux.c): Remove.
3104 (i386-avx-mpx-avx512-pku.c): Remove.
3105 (i386-avx-mpx-avx512-pku-linux.c): Remove.
3106 (i386-avx-mpx.c): Remove.
3107 (i386-avx-mpx-linux.c): Remove.
3108 (i386-mmx.c): Remove.
3109 (i386-mmx-linux.c): Remove.
3110 (reg-ia64.c): Remove.
3111 (reg-m32r.c): Remove.
3112 (reg-m68k.c): Remove.
3113 (reg-cf.c): Remove.
3114 (mips-linux.c): Remove.
3115 (mips-dsp-linux.c): Remove.
3116 (mips64-linux.c): Remove.
3117 (mips64-dsp-linux.c): Remove.
3118 (nios2-linux.c): Remove.
3119 (powerpc-32.c): Remove.
3120 (powerpc-32l.c): Remove.
3121 (powerpc-altivec32l.c): Remove.
3122 (powerpc-cell32l.c): Remove.
3123 (powerpc-vsx32l.c): Remove.
3124 (powerpc-isa205-32l.c): Remove.
3125 (powerpc-isa205-altivec32l.c): Remove.
3126 (powerpc-isa205-vsx32l.c): Remove.
3127 (powerpc-e500l.c): Remove.
3128 (powerpc-64l.c): Remove.
3129 (powerpc-altivec64l.c): Remove.
3130 (powerpc-cell64l.c): Remove.
3131 (powerpc-vsx64l.c): Remove.
3132 (powerpc-isa205-64l.c): Remove.
3133 (powerpc-isa205-altivec64l.c): Remove.
3134 (powerpc-isa205-vsx64l.c): Remove.
3135 (s390-linux32.c): Remove.
3136 (s390-linux32v1.c): Remove.
3137 (s390-linux32v2.c): Remove.
3138 (s390-linux64.c): Remove.
3139 (s390-linux64v1.c): Remove.
3140 (s390-linux64v2.c): Remove.
3141 (s390-te-linux64.c): Remove.
3142 (s390-vx-linux64.c): Remove.
3143 (s390-tevx-linux64.c): Remove.
3144 (s390x-linux64.c): Remove.
3145 (s390x-linux64v1.c): Remove.
3146 (s390x-linux64v2.c): Remove.
3147 (s390x-te-linux64.c): Remove.
3148 (s390x-vx-linux64.c): Remove.
3149 (s390x-tevx-linux64.c): Remove.
3150 (tic6x-c64xp-linux.c): Remove.
3151 (tic6x-c64x-linux.c): Remove.
3152 (tic6x-c62x-linux.c): Remove.
3153 (reg-sh.c): Remove.
3154 (reg-sparc64.c): Remove.
3155 (reg-spu.c): Remove.
3156 (amd64.c): Remove.
3157 (amd64-linux.c): Remove.
3158 (amd64-avx.c): Remove.
3159 (amd64-avx-linux.c): Remove.
3160 (amd64-avx-avx512.c): Remove.
3161 (amd64-avx-avx512-linux.c): Remove.
3162 (amd64-mpx.c): Remove.
3163 (amd64-mpx-linux.c): Remove.
3164 (amd64-avx-mpx-avx512-pku.c): Remove.
3165 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
3166 (amd64-avx-mpx.c): Remove.
3167 (amd64-avx-mpx-linux.c): Remove.
3168 (x32.c): Remove.
3169 (x32-linux.c): Remove.
3170 (x32-avx.c): Remove.
3171 (x32-avx-linux.c): Remove.
3172 (x32-avx-avx512.c): Remove.
3173 (x32-avx-avx512-linux.c): Remove.
3174 (reg-xtensa.c): Remove.
3175 (reg-tilegx.c): Remove.
3176 (reg-tilegx32.c): Remove.
3177
1672e0d9
SDJ
31782017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
3179
3180 * Makefile.in (SFILES): Add "common/environ.c".
3181 (OBJS): Add "common/environ.h".
3182
239b6d10
WT
31832017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
3184
3185 * configure.ac: Check if the fs_base and gs_base members of
3186 `struct user_regs_struct' exist.
3187 * config.in: Regenerated.
3188 * configure: Likewise.
3189
694b382c
AT
31902017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
3191
3192 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
3193 target_read_memory.
3194 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
3195 (get_next_pcs_syscall_next_pc): Likewise.
3196
7dc53023
LM
31972016-12-23 Luis Machado <lgustavo@codesourcery.com>
3198
3199 * win32-i386-low.c: Fix incorrect reference to a couple source files.
3200 * nto-x86-low.c: Likewise.
3201
ad02e4fe
SM
32022016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
3203
3204 * Makefile.in: Include disable-implicit-rules.mk.
3205
dcb07cfa
PA
32062016-11-23 Pedro Alves <palves@redhat.com>
3207
3208 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
3209 (debug_vprintf): Use std::chrono::steady_clock instead of
3210 gettimeofday. Use '.' instead of ':'.
3211 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
3212 (get_timestamp): Use std::chrono::steady_clock instead of
3213 gettimeofday.
3214
8629c02c
SM
32152016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
3216
3217 * Makefile.in: Fix whitespace formatting.
3218
b593ecca
SM
32192016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
3220
3221 * Makefile.in (SFILES, OBS): Flatten list and order
3222 alphabetically.
3223
9986ba08
PA
32242016-11-23 Pedro Alves <palves@redhat.com>
3225
3226 * event-loop.c (handle_file_event): Use warning.
3227 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
3228 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
3229 Use warning.
3230
4eefa7bc
PA
32312016-11-23 Pedro Alves <palves@redhat.com>
3232
3233 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
3234 output.
3235 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
3236 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
3237 debug_printf and debug_flush for debug output.
3238 * server.c (handle_general_set): Likewise.
3239 * thread-db.c (try_thread_db_load): Use debug_printf for debug
3240 output.
3241
5443506e
SM
32422016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
3243
3244 * Makefile.in (.c.o): Replace rule with ...
3245 (%.o: %.c): ... this one.
3246
3b165252
SM
32472016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
3248
3249 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
3250 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
3251 make.
3252 * configure.ac: Remove checks for the make program.
3253 * configure: Re-generate.
3254
0bcda685
PA
32552016-10-28 Pedro Alves <palves@redhat.com>
3256
3257 * Makefile.in (CXX_DIALECT): Get from configure.
3258 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
3259 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
3260 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
3261 * config.in: Regenerate.
3262 * configure: Regenerate.
3263
c3805894
YQ
32642016-10-27 Yao Qi <yao.qi@linaro.org>
3265
3266 * linux-low.c (linux_supports_range_stepping): Return true if
3267 can_software_single_step return true.
3268
89342618
YQ
32692016-10-27 Yao Qi <yao.qi@linaro.org>
3270
3271 * inferiors.c (find_inferior_in_random): New function.
3272 * inferiors.h (find_inferior_in_random): Declare.
3273 * linux-low.c (linux_wait_for_event_filtered): Call
3274 find_inferior_in_random instead of find_inferior.
3275
e3652c84
YQ
32762016-10-27 Yao Qi <yao.qi@linaro.org>
3277
3278 * linux-low.c (linux_wait_1): If single-step breakpoints are
3279 inserted, remove them.
3280
5a04c4cf
PA
32812016-10-26 Pedro Alves <palves@redhat.com>
3282
3283 * linux-low.c (handle_extended_wait): Link parent/child fork
3284 threads.
3285 (linux_wait_1): Unlink them.
3286 (linux_set_resume_request): Ignore resume requests for
3287 already-resumed and unhandled fork child threads.
3288 * linux-low.h (struct lwp_info) <fork_relative>: New field.
3289 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
3290 New functions.
3291 (handle_v_requests) <vCont>: Don't call require_running.
3292 * server.h (in_queued_stop_replies): New declaration.
3293
cb93dc7f
YQ
32942016-10-24 Yao Qi <yao.qi@linaro.org>
3295
3296 PR server/20733
3297 * linux-aarch64-low.c (append_insns): Cast the return value to
3298 'uint32_t *'.
3299
a1078bea
YQ
33002016-10-10 Yao Qi <yao.qi@linaro.org>
3301
3302 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
3303
1fb77080
SDJ
33042016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
3305
3306 * target.c (target_supports_multi_process): New function, moved
3307 from...
3308 * target.h (target_supports_multi_process): ... here. Remove
3309 macro.
3310
39b5a3b9
TT
33112016-10-05 Tom Tromey <tom@tromey.com>
3312
3313 PR remote/20655:
3314 * tracepoint.c (handle_tracepoint_bkpts): Check
3315 ipa_error_tracepoint, not ipa_stopping_tracepoint.
3316
c1d0b70a
YQ
33172016-10-05 Yao Qi <yao.qi@linaro.org>
3318
3319 * configure.srv: Update the path of arm-*.xml files.
3320
0a69eedb
YQ
33212016-10-05 Terry Guo <terry.guo@arm.com>
3322 Yao Qi <yao.qi@linaro.org>
3323
3324 * Makefile.in: Adjust the path of rules.
3325 * configure.srv: Update the path of xml files.
3326 * regformats/arm-with-iwmmxt.dat: Regenerated.
3327 * regformats/arm-with-neon.dat: Likewise.
3328 * regformats/arm-with-vfpv2.dat: Likewise.
3329 * regformats/arm-with-vfpv3.dat Likewise.
3330
17e16485
YQ
33312016-09-30 Yao Qi <yao.qi@linaro.org>
3332
3333 PR gdbserver/20627
3334 * target.c (target_stop_and_wait): Don't call
3335 target_continue_no_signal, use resume_stop instead.
3336
edeeb602
YQ
33372016-09-26 Yao Qi <yao.qi@linaro.org>
3338
3339 * linux-low.c (linux_wait_1): Call debug_exit.
3340
503b1c39
PA
33412016-09-23 Pedro Alves <palves@redhat.com>
3342
3343 * Makefile.in (SFILES): Add common/new-op.c.
3344 (OBS): Add common/new-op.o.
3345 (new-op.o): New rule.
3346
74172ecf
SM
33472016-09-21 Simon Marchi <simon.marchi@ericsson.com>
3348
3349 * .gitinore: Ignore more files.
3350
fc6cda2e
YQ
33512016-09-21 Yao Qi <yao.qi@linaro.org>
3352
3353 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
3354 23.
3355
bc1e6c81
SDJ
33562016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
3357
3358 * server.c (start_inferior): Call target_mourn_inferior instead of
3359 mourn_inferior; pass ptid_t argument to it.
3360 (resume): Likewise.
3361 (handle_target_event): Likewise.
3362 * target.c (target_mourn_inferior): New function.
3363 * target.h (mourn_inferior): Delete macro.
3364
0e00e962
AA
33652016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
3366
3367 * linux-low.c (lwp_is_stepping): New function.
3368
1d8cb77d
CL
33692016-09-06 Carl Love <cel@us.ibm.com>
3370
3371 * server.c (start_inferior): Fixed comment, requested comment change
3372 didn't get updated correctly. Removed reference to ptrace () call as
3373 it is only true on Linux systems.
3374
7313bced
CL
33752016-09-06 Carl Love <cel@us.ibm.com>
3376
3377 * server.c (start_inferior): Do not call
3378 function target_post_create_inferior () if the
3379 inferior process has already exited.
3380
cf6de44d
PA
33812016-09-05 Pedro Alves <palves@redhat.com>
3382
3383 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
3384 (COMPILE.pre, CC_LD): Use CXX directly.
3385 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
3386 * acinclude.m4: Don't include build-with-cxx.m4.
3387 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
3388 * configure: Regenerate.
3389
c1da6748
AT
33902016-09-02 Akash Trehan <akash.trehan123@gmail.com>
3391
3392 PR gdb/19495
3393 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
3394 call writing data to own_buf.
3395
f2b9e3df
SDJ
33962016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
3397
3398 * target.c (mywait): Call target_wait instead of
3399 the_target->wait.
3400 (target_wait): New function.
3401
049a8570
SDJ
34022016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
3403
3404 * server.c (start_inferior): New variable 'ptid'. Replace calls
3405 to the_target->resume by target_continue{,_no_signal}, depending
3406 on the case.
3407 * target.c (target_stop_and_wait): Call target_continue_no_signal
3408 instead of the_target->resume.
3409 (target_continue): New function.
3410
3aa5cfa0
AT
34112016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
3412
3413 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
3414
754653a7
AZ
34152016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
3416
3417 PR server/20491
3418 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
3419 ps_prochandle.
3420 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
3421 * linux-arm-low.c (ps_get_thread_area): Likewise.
3422 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
3423 * linux-m68k-low.c (ps_get_thread_area): Likewise.
3424 * linux-mips-low.c (ps_get_thread_area): Likewise.
3425 * linux-nios2-low.c (ps_get_thread_area): Likewise.
3426 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
3427 * linux-x86-low.c (ps_get_thread_area): Likewise.
3428 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
3429
ed036b40
PA
34302016-08-19 Pedro Alves <palves@redhat.com>
3431
3432 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
3433
c8ef42ee
PA
34342016-08-19 Pedro Alves <palves@redhat.com>
3435
3436 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
3437 comment. Use memcpy instead of casting through unsigned long.
3438
9c235a72
PA
34392016-08-19 Pedro Alves <palves@redhat.com>
3440
3441 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
3442 allocating around 0x80000000.
3443
201506da
PA
34442016-08-19 Pedro Alves <palves@redhat.com>
3445
3446 PR gdb/20415
3447 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
3448 (x32-avx512-linux-ipa.o): New rules.
3449 * configure.ac (x86_64-*-linux*): New x32 check.
3450 * configure.srv (ipa_x32_linux_regobj): New.
3451 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
3452 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
3453 descriptions.
3454 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
3455 descriptions.
3456 * configure: Regenerate.
3457
f348d89a
PA
34582016-08-09 Pedro Alves <palves@redhat.com>
3459
3460 PR gdb/18653
3461 * Makefile.in (OBS): Add signals-state-save-restore.o.
3462 (signals-state-save-restore.o): New rule.
3463 * config.in: Regenerate.
3464 * configure: Regenerate.
3465 * linux-low.c: Include "signals-state-save-restore.h".
3466 (linux_create_inferior): Call
3467 restore_original_signals_state.
3468 * server.c: Include "dispositions-save-restore.h".
3469 (captured_main): Call save_original_signals_state.
3470
1baf5149
PA
34712016-08-05 Pedro Alves <palves@redhat.com>
3472
3473 * configure: Regenerate.
3474
fcd4a73d
YQ
34752016-08-04 Yao Qi <yao.qi@linaro.org>
3476
3477 * linux-low.c (regsets_fetch_inferior_registers): Check
3478 errno is ESRCH or not.
3479
979659d0
YQ
34802016-08-02 Yao Qi <yao.qi@linaro.org>
3481
3482 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
3483 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
3484 (thread_db_load_search): Update.
3485 (try_thread_db_load_1): Don't look for td_ta_event_addr,
3486 td_ta_set_event and td_ta_event_getmsg.
3487
6598661d
PA
34882016-07-26 Pedro Alves <palves@redhat.com>
3489
3490 PR server/20414
3491 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
3492 of unsigned long for 64-bit registers and use uint32_t instead of
3493 unsigned int for 32-bit registers.
3494
9cf12d57
PA
34952016-07-26 Pedro Alves <palves@redhat.com>
3496
3497 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
3498 to 'ptrace'.
3499
305450ed
TT
35002016-07-21 Tom Tromey <tom@tromey.com>
3501
3502 * configure: Rebuild.
3503
2583da7c
YQ
35042016-07-21 Yao Qi <yao.qi@linaro.org>
3505
3506 * mem-break.c (find_gdb_breakpoint): Cast bp to
3507 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
3508
21536b36
YQ
35092016-07-21 Yao Qi <yao.qi@linaro.org>
3510
3511 * server.c (handle_v_requests): Support s and S actions
3512 if target_supports_software_single_step return true.
3513
8901d193
YQ
35142016-07-21 Yao Qi <yao.qi@linaro.org>
3515
3516 * linux-low.c (resume_stopped_resumed_lwps): If resume request
3517 is resume_step, call maybe_hw_step.
3518 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
3519 and unstop them.
3520 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
3521 breakpoints or not.
3522 (proceed_one_lwp): If resume request is resume_step, install
3523 reinsert breakpoints and call maybe_hw_step.
3524
0e9a339e
YQ
35252016-07-21 Yao Qi <yao.qi@linaro.org>
3526
3527 * linux-low.c (proceed_one_lwp): Declare.
3528 (linux_resume_one_thread): Remove local variable 'step'.
3529 Lift code enqueue signal. Call proceed_one_lwp instead of
3530 linux_resume_one_lwp.
3531
4281b351
YQ
35322016-07-21 Yao Qi <yao.qi@linaro.org>
3533
3534 * linux-low.c (linux_resume_one_thread): Call
3535 enqueue_pending_signal.
3536
984a2c04
YQ
35372016-07-21 Yao Qi <yao.qi@linaro.org>
3538
3539 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
3540 * inferiors.c (do_restore_current_thread_cleanup): New function.
3541 (make_cleanup_restore_current_thread): Likewise.
3542 * linux-low.c (install_software_single_step_breakpoints): Call
3543 make_cleanup_restore_current_thread. Switch current_thread to
3544 thread.
3545
bec903c9
YQ
35462016-07-21 Yao Qi <yao.qi@linaro.org>
3547
3548 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
3549 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
3550 (clone_one_breakpoint): Likewise.
3551 (delete_reinsert_breakpoints): Change parameter to thread.
3552 Callers updated.
3553 (has_reinsert_breakpoints): Likewise.
3554 (uninsert_reinsert_breakpoints): Likewise.
3555 (reinsert_reinsert_breakpoints): Likewise.
3556 * mem-break.h (set_reinsert_breakpoint): Update declaration.
3557 (delete_reinsert_breakpoints): Likewise.
3558 (reinsert_reinsert_breakpoints): Likewise.
3559 (uninsert_reinsert_breakpoints): Likewise.
3560 (has_reinsert_breakpoints): Likewise.
3561
63c40ec7
YQ
35622016-07-21 Yao Qi <yao.qi@linaro.org>
3563
3564 * inferiors.c (get_thread_process): Make parameter const.
3565 * inferiors.h (get_thread_process): Update declaration.
3566 * mem-break.c (clone_all_breakpoints): Remove all parameters.
3567 Add new parameters child_thread and parent_thread. Callers
3568 updated.
3569 * mem-break.h (clone_all_breakpoints): Update declaration.
3570
9aa76cd0
YQ
35712016-07-21 Yao Qi <yao.qi@linaro.org>
3572
3573 * mem-break.c (struct breakpoint) <cond_list>: Remove.
3574 <command_list, handler>: Remove.
3575 (struct gdb_breakpoint): New.
3576 (struct other_breakpoint): New.
3577 (struct reinsert_breakpoint): New.
3578 (is_gdb_breakpoint): New function.
3579 (any_persistent_commands): Update command_list if
3580 is_gdb_breakpoint returns true.
3581 (set_breakpoint): Create breakpoints according to their types.
3582 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
3583 (set_gdb_breakpoint_1): Likewise.
3584 (set_gdb_breakpoint): Likewise.
3585 (clear_breakpoint_conditions): Change parameter type to
3586 'struct gdb_breakpoint *'.
3587 (clear_breakpoint_commands): Likewise.
3588 (clear_breakpoint_conditions_and_commands): Likewise.
3589 (add_condition_to_breakpoint): Likewise.
3590 (add_breakpoint_condition): Likewise.
3591 (add_commands_to_breakpoint): Likewise.
3592 (check_breakpoints): Check other_breakpoint.
3593 (clone_one_breakpoint): Clone breakpopint according to its type.
3594 * mem-break.h (struct gdb_breakpoint): Declare.
3595 (set_gdb_breakpoint): Update declaration.
3596 (clear_breakpoint_conditions_and_commands): Likewise.
3597 (add_breakpoint_condition): Likewise.
3598 (add_breakpoint_commands): Likewise.
3599 * server.c (process_point_options): Change parameter type to
3600 'struct gdb_breakpoint *'.
3601
811f8301
YQ
36022016-07-21 Yao Qi <yao.qi@linaro.org>
3603
3604 * mem-break.c (set_breakpoint_at): Rename it to ...
3605 (set_breakpoint_type_at): ... it.
3606 (set_breakpoint_at): Call set_breakpoint_type_at.
3607 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
3608 * mem-break.h (set_breakpoint_at): Update comments.
3609
b1c51e36
CLT
36102016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
3611
3612 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
3613 to buf parameter.
3614 (nios2_store_gregset): Likewise.
3615
ced2dffb
PA
36162016-07-01 Pedro Alves <palves@redhat.com>
3617 Antoine Tremblay <antoine.tremblay@ericsson.com>
3618
3619 * linux-low.c: Change interface to take the target lwp_info
3620 pointer directly and return void. Handle detaching from a zombie
3621 thread.
3622 (linux_detach_lwp_callback): New function.
3623 (linux_detach): Detach from the leader thread after detaching from
3624 the clone threads.
3625
2ac09a5b
YQ
36262016-06-28 Yao Qi <yao.qi@linaro.org>
3627
3628 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
3629 for variable new_offset.
3630 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
3631 (aarch64_ftrace_insn_reloc_cb): Likewise.
3632 (aarch64_ftrace_insn_reloc_tb): Likewise.
3633 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
3634 PRIx64 instead of PRIx32.
3635
79e7fd4f
YQ
36362016-06-28 Yao Qi <yao.qi@linaro.org>
3637
3638 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
3639 (the_low_target): Install arm_get_syscall_trapinfo.
3640
061fc021
YQ
36412016-06-28 Yao Qi <yao.qi@linaro.org>
3642
3643 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
3644 function.
3645 (the_low_target): Install aarch64_get_syscall_trapinfo.
3646
4cc32bec
YQ
36472016-06-28 Yao Qi <yao.qi@linaro.org>
3648
3649 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
3650 Callers updated.
3651 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
3652 Remove parameter sysno.
3653 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
3654 sysret.
3655
782c1122
AA
36562016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
3657
3658 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
3659 (s390_emit_ne_goto): Likewise.
3660 (s390_emit_lt_goto): Likewise.
3661 (s390_emit_le_goto): Likewise.
3662 (s390_emit_gt_goto): Likewise.
3663 (s390_emit_ge_goto): Likewise.
3664 (s390x_emit_eq_goto): Likewise.
3665 (s390x_emit_ne_goto): Likewise.
3666 (s390x_emit_lt_goto): Likewise.
3667 (s390x_emit_le_goto): Likewise.
3668 (s390x_emit_gt_goto): Likewise.
3669 (s390x_emit_ge_goto): Likewise.
3670 (s390_emit_ops_impl): Mark variable static.
3671 (s390x_emit_ops): Likewise.
3672
2e7b624b
YQ
36732016-06-17 Yao Qi <yao.qi@linaro.org>
3674
3675 * linux-low.c (handle_extended_wait): Call
3676 uninsert_reinsert_breakpoints for the parent process. Remove
3677 reinsert breakpoints from the child process. Reinsert them to
3678 the parent process when vfork is done.
3679 * mem-break.c (uninsert_reinsert_breakpoints): New function.
3680 (reinsert_reinsert_breakpoints): New function.
3681 * mem-break.h (uninsert_reinsert_breakpoints): Declare
3682 (reinsert_reinsert_breakpoints): Declare.
3683
8a81c5d7
YQ
36842016-06-17 Yao Qi <yao.qi@linaro.org>
3685
3686 * linux-low.c (handle_extended_wait): If the parent is doing
3687 step-over, remove the reinsert breakpoints from the forked child.
3688
f50bf8e5
YQ
36892016-06-17 Yao Qi <yao.qi@linaro.org>
3690
3691 * linux-low.c (unsuspend_all_lwps): Declare.
3692 (linux_low_filter_event): If thread exited, call finish_step_over.
3693 If step-over is finished, unsuspend other threads.
3694
8376a3cb
YQ
36952016-06-17 Yao Qi <yao.qi@linaro.org>
3696
3697 * linux-low.c (linux_resume_one_lwp_throw): Assert
3698 has_reinsert_breakpoints returns false.
3699 * mem-break.c (delete_disabled_breakpoints): Assert
3700 bp type isn't reinsert_breakpoint.
3701
f79b145d
YQ
37022016-06-17 Yao Qi <yao.qi@linaro.org>
3703
3704 * linux-low.c (maybe_hw_step): New function.
3705 (linux_resume_one_lwp_throw): Call maybe_hw_step.
3706 (finish_step_over): Switch current_thread to lwp temporarily,
3707 and assert has_reinsert_breakpoints returns true.
3708 (proceed_one_lwp): Call maybe_hw_step.
3709 * mem-break.c (has_reinsert_breakpoints): New function.
3710 * mem-break.h (has_reinsert_breakpoints): Declare.
3711
0ae534d2
JT
37122016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
3713
3714 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
3715
fcdad592
YQ
37162016-05-17 Yao Qi <yao.qi@linaro.org>
3717
3718 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
3719 instead of find_inferior.
3720
9e784964
YQ
37212016-05-05 Yao Qi <yao.qi@linaro.org>
3722
3723 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
3724 Initialize res to zero.
3725
cf2ebb6e
YQ
37262016-05-05 Yao Qi <yao.qi@linaro.org>
3727
3728 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
3729 to uint32_t.
3730
c1aebf87
UW
37312016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
3732
3733 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
3734 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
3735 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
3736
35fd2deb 37372016-04-28 Par Olsson <par.olsson@windriver.com>
cbe14bcf 3738 Simon Marchi <simon.marchi@ericsson.com>
35fd2deb
PO
3739
3740 * tracepoint.c (write_inferior_int8): New function.
3741 (cmd_qtenable_disable): Write enable flag using
3742 write_inferior_int8.
3743
484b3c32
YQ
37442016-04-25 Yao Qi <yao.qi@linaro.org>
3745
3746 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
3747 (need_step_over_p): Return zero if the LWP has pending signals
3748 can be delivered on software single step target.
3749
85ba7d86
YQ
37502016-04-25 Yao Qi <yao.qi@linaro.org>
3751
3752 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
3753 return instead of error.
3754
3539aa13
YQ
37552016-04-22 Yao Qi <yao.qi@linaro.org>
3756
3757 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
3758 to 23.
3759
5b061e98
YQ
37602016-04-22 Yao Qi <yao.qi@linaro.org>
3761
3762 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
3763 signal when stepping over breakpoint with software single
3764 step.
3765
3451269c
PA
37662016-04-21 Pedro Alves <palves@redhat.com>
3767
3768 * linux-s390-low.c (s390_collect_ptrace_register)
3769 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
3770 add casts.
3771 (s390_check_regset): Use void * instead of gdb_byte *.
3772
a2358508
PA
37732016-04-20 Pedro Alves <palves@redhat.com>
3774
3775 * configure: Renegerate.
3776
6885166d
YQ
37772016-04-20 Yao Qi <yao.qi@linaro.org>
3778
3779 * linux-aarch32-low.c: Include "arch/arm-linux.h".
3780 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
3781 number 16.
3782 (arm_store_gregset): Likewise.
3783
2b863f51
WT
37842016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
3785
3786 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
3787 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
3788 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
3789 (amd64-avx-mpx-linux.c): New rules.
3790 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
3791 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
3792 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
3793 (srv_amd64_regobj): Add amd64-avx-mpx.o.
3794 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
3795 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
3796 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
3797 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
3798 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
3799 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
3800 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
3801 * linux-x86-low.c (x86_linux_read_description): Add case for
3802 X86_XSTATE_AVX_MPX_MASK.
3803 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
3804 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
3805 init_registers_i386_avx_mpx_linux.
3806 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
3807 (initialize_low_tracepoint): Call
3808 init_registers_i386_avx_mpx_linux.
3809 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
3810 (initialize_low_tracepoint): Call
3811 init_registers_amd64_avx_mpx_linux.
3812 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
3813 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
3814 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
3815 declarations.
3816
9b30624b
PA
38172016-04-18 Pedro Alves <palves@redhat.com>
3818
3819 * configure: Regenerate.
3820
45e3745e
AT
38212016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
3822
3823 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
3824 (aarch64_emit_sub): Likewise.
3825
2afc13ff
PA
38262016-04-12 Pedro Alves <palves@redhat.com>
3827
3828 * utils.c (prepare_to_throw_exception): Delete.
3829
6e774b13
SM
38302016-04-05 Simon Marchi <simon.marchi@ericsson.com>
3831
3832 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
3833
4dca19f8
MK
38342016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
3835
3836 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
3837
d0a9981f
MK
38382016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
3839
3840 * linux-aarch64-ipa.c: Add <elf.h> include.
3841 * linux-ppc-ipa.c: Add <elf.h> include.
3842 * linux-s390-ipa.c: Add <elf.h> include.
3843
252db07e
MK
38442016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
3845
3846 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
3847 (get_raw_reg_ptr): Likewise.
3848 (get_trace_state_variable_value_ptr): Likewise.
3849 (set_trace_state_variable_value_ptr): Likewise.
3850 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
3851 char *.
3852
14e2b6d9
MK
38532016-03-31 Wei-cheng Wang <cole945@gmail.com>
3854 Marcin Kościelnicki <koriakin@0x04.net>
3855
3856 PR/17221
3857 * linux-ppc-low.c (emit_insns): New function.
3858 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
3859 (ppc_emit_prologue): New function.
3860 (ppc_emit_epilogue): New function.
3861 (ppc_emit_add): New function.
3862 (ppc_emit_sub): New function.
3863 (ppc_emit_mul): New function.
3864 (ppc_emit_lsh): New function.
3865 (ppc_emit_rsh_signed): New function.
3866 (ppc_emit_rsh_unsigned): New function.
3867 (ppc_emit_ext): New function.
3868 (ppc_emit_zero_ext): New function.
3869 (ppc_emit_log_not): New function.
3870 (ppc_emit_bit_and): New function.
3871 (ppc_emit_bit_or): New function.
3872 (ppc_emit_bit_xor): New function.
3873 (ppc_emit_bit_not): New function.
3874 (ppc_emit_equal): New function.
3875 (ppc_emit_less_signed): New function.
3876 (ppc_emit_less_unsigned): New function.
3877 (ppc_emit_ref): New function.
3878 (ppc_emit_const): New function.
3879 (ppc_emit_reg): New function.
3880 (ppc_emit_pop): New function.
3881 (ppc_emit_stack_flush): New function.
3882 (ppc_emit_swap): New function.
3883 (ppc_emit_stack_adjust): New function.
3884 (ppc_emit_call): New function.
3885 (ppc_emit_int_call_1): New function.
3886 (ppc_emit_void_call_2): New function.
3887 (ppc_emit_if_goto): New function.
3888 (ppc_emit_goto): New function.
3889 (ppc_emit_eq_goto): New function.
3890 (ppc_emit_ne_goto): New function.
3891 (ppc_emit_lt_goto): New function.
3892 (ppc_emit_le_goto): New function.
3893 (ppc_emit_gt_goto): New function.
3894 (ppc_emit_ge_goto): New function.
3895 (ppc_write_goto_address): New function.
3896 (ppc_emit_ops_impl): New static variable.
3897 (ppc64v1_emit_prologue): New function.
3898 (ppc64v2_emit_prologue): New function.
3899 (ppc64_emit_epilogue): New function.
3900 (ppc64_emit_add): New function.
3901 (ppc64_emit_sub): New function.
3902 (ppc64_emit_mul): New function.
3903 (ppc64_emit_lsh): New function.
3904 (ppc64_emit_rsh_signed): New function.
3905 (ppc64_emit_rsh_unsigned): New function.
3906 (ppc64_emit_ext): New function.
3907 (ppc64_emit_zero_ext): New function.
3908 (ppc64_emit_log_not): New function.
3909 (ppc64_emit_bit_and): New function.
3910 (ppc64_emit_bit_or): New function.
3911 (ppc64_emit_bit_xor): New function.
3912 (ppc64_emit_bit_not): New function.
3913 (ppc64_emit_equal): New function.
3914 (ppc64_emit_less_signed): New function.
3915 (ppc64_emit_less_unsigned): New function.
3916 (ppc64_emit_ref): New function.
3917 (ppc64_emit_const): New function.
3918 (ppc64v1_emit_reg): New function.
3919 (ppc64v2_emit_reg): New function.
3920 (ppc64_emit_pop): New function.
3921 (ppc64_emit_stack_flush): New function.
3922 (ppc64_emit_swap): New function.
3923 (ppc64v1_emit_call): New function.
3924 (ppc64v2_emit_call): New function.
3925 (ppc64v1_emit_int_call_1): New function.
3926 (ppc64v2_emit_int_call_1): New function.
3927 (ppc64v1_emit_void_call_2): New function.
3928 (ppc64v2_emit_void_call_2): New function.
3929 (ppc64_emit_if_goto): New function.
3930 (ppc64_emit_eq_goto): New function.
3931 (ppc64_emit_ne_goto): New function.
3932 (ppc64_emit_lt_goto): New function.
3933 (ppc64_emit_le_goto): New function.
3934 (ppc64_emit_gt_goto): New function.
3935 (ppc64_emit_ge_goto): New function.
3936 (ppc64v1_emit_ops_impl): New static variable.
3937 (ppc64v2_emit_ops_impl): New static variable.
3938 (ppc_emit_ops): New function.
3939 (linux_low_target): Wire in ppc_emit_ops.
3940
a2174ba4
MK
39412016-03-31 Wei-cheng Wang <cole945@gmail.com>
3942 Marcin Kościelnicki <koriakin@0x04.net>
3943
3944 PR/17221
3945 * Makefile.in: Add powerpc-*-ipa.o
3946 * configure.srv: Add ipa_obj for powerpc*-linux.
3947 * linux-ppc-ipa.c: New file.
3948 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
3949 includes.
3950 (PPC_FIELD): New macro.
3951 (PPC_SEXT): New macro.
3952 (PPC_OP6): New macro.
3953 (PPC_BO): New macro.
3954 (PPC_LI): New macro.
3955 (PPC_BD): New macro.
3956 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
3957 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
3958 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
3959 (ppc_get_thread_area): New function.
3960 (is_elfv2_inferior): New function.
3961 (gen_ds_form): New function.
3962 (GEN_STD): New macro.
3963 (GEN_STDU): New macro.
3964 (GEN_LD): New macro.
3965 (GEN_LDU): New macro.
3966 (gen_d_form): New function.
3967 (GEN_ADDI): New macro.
3968 (GEN_ADDIS): New macro.
3969 (GEN_LI): New macro.
3970 (GEN_LIS): New macro.
3971 (GEN_ORI): New macro.
3972 (GEN_ORIS): New macro.
3973 (GEN_LWZ): New macro.
3974 (GEN_STW): New macro.
3975 (GEN_STWU): New macro.
3976 (gen_xfx_form): New function.
3977 (GEN_MFSPR): New macro.
3978 (GEN_MTSPR): New macro.
3979 (GEN_MFCR): New macro.
3980 (GEN_MTCR): New macro.
3981 (GEN_SYNC): New macro.
3982 (GEN_LWSYNC): New macro.
3983 (gen_x_form): New function.
3984 (GEN_OR): New macro.
3985 (GEN_MR): New macro.
3986 (GEN_LWARX): New macro.
3987 (GEN_STWCX): New macro.
3988 (GEN_CMPW): New macro.
3989 (gen_md_form): New function.
3990 (GEN_RLDICL): New macro.
3991 (GEN_RLDICR): New macro.
3992 (gen_i_form): New function.
3993 (GEN_B): New macro.
3994 (GEN_BL): New macro.
3995 (gen_b_form): New function.
3996 (GEN_BNE): New macro.
3997 (GEN_LOAD): New macro.
3998 (GEN_STORE): New macro.
3999 (gen_limm): New function.
4000 (gen_atomic_xchg): New function.
4001 (gen_call): New function.
4002 (ppc_relocate_instruction): New function.
4003 (ppc_install_fast_tracepoint_jump_pad): New function.
4004 (ppc_get_min_fast_tracepoint_insn_len): New function.
4005 (ppc_get_ipa_tdesc_idx): New function.
4006 (the_low_target): Wire in the new functions.
4007 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
4008 tdescs.
4009 * linux-ppc-tdesc.h: New file.
4010
a13c4696
MK
40112016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
4012
4013 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
4014 (alloc_jump_pad_buffer): New function.
4015 * linux-amd64-ipa.c: Add <sys/mman.h> include.
4016 (alloc_jump_pad_buffer): New function.
4017 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
4018 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
4019 (alloc_jump_pad_buffer): New function.
4020 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
4021 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
4022 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
4023 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
4024
1cda1512
MK
40252016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
4026
4027 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
4028 * linux-amd64-ipa.c: Likewise.
4029 * linux-i386-ipa.c: Likewise.
4030 * linux-s390-ipa.c: Likewise.
4031 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
4032 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
4033 set_trace_state_variable_value_ptr.
4034 (struct ipa_sym_addresses): Likewise.
4035 (symbol_list): Likewise.
4036 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
4037 accessing gdb_collect directly.
4038 (gdb_collect_ptr_type): New typedef.
4039 (get_raw_reg_ptr_type): New typedef.
4040 (get_trace_state_variable_value_ptr_type): New typedef.
4041 (set_trace_state_variable_value_ptr_type): New typedef.
4042 (gdb_collect_ptr): New global.
4043 (get_raw_reg_ptr): New global.
4044 (get_trace_state_variable_value_ptr): New global.
4045 (set_trace_state_variable_value_ptr): New global.
4046 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
4047 accessing get_raw_reg directly.
4048 (get_get_tsv_func_addr): Likewise for
4049 get_trace_state_variable_value_ptr.
4050 (get_set_tsv_func_addr): Likewise for
4051 set_trace_state_variable_value_ptr.
4052 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
4053
72fb5488
SM
40542016-03-30 Simon Marchi <simon.marchi@ericsson.com>
4055
4056 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
4057
28170b88
MK
40582016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
4059
4060 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
4061 packets.
4062 (relocate_instruction): Remove own_buf.
4063 * server.c (own_buf): Make global.
4064 (handle_v_requests): Make global.
4065 * server.h (own_buf): New declaration.
4066 (handle_v_requests): New prototype.
4067
f39e8743
MK
40682016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
4069
4070 PR 18377
4071 * linux-s390-low.c (add_insns): New function.
4072 (s390_emit_prologue): New function.
4073 (s390_emit_epilogue): New function.
4074 (s390_emit_add): New function.
4075 (s390_emit_sub): New function.
4076 (s390_emit_mul): New function.
4077 (s390_emit_lsh): New function.
4078 (s390_emit_rsh_signed): New function.
4079 (s390_emit_rsh_unsigned): New function.
4080 (s390_emit_ext): New function.
4081 (s390_emit_log_not): New function.
4082 (s390_emit_bit_and): New function.
4083 (s390_emit_bit_or): New function.
4084 (s390_emit_bit_xor): New function.
4085 (s390_emit_bit_not): New function.
4086 (s390_emit_equal): New function.
4087 (s390_emit_less_signed): New function.
4088 (s390_emit_less_unsigned): New function.
4089 (s390_emit_ref): New function.
4090 (s390_emit_if_goto): New function.
4091 (s390_emit_goto): New function.
4092 (s390_write_goto_address): New function.
4093 (s390_emit_litpool): New function.
4094 (s390_emit_const): New function.
4095 (s390_emit_call): New function.
4096 (s390_emit_reg): New function.
4097 (s390_emit_pop): New function.
4098 (s390_emit_stack_flush): New function.
4099 (s390_emit_zero_ext): New function.
4100 (s390_emit_swap): New function.
4101 (s390_emit_stack_adjust): New function.
4102 (s390_emit_set_r2): New function.
4103 (s390_emit_int_call_1): New function.
4104 (s390_emit_void_call_2): New function.
4105 (s390_emit_eq_goto): New function.
4106 (s390_emit_ne_goto): New function.
4107 (s390_emit_lt_goto): New function.
4108 (s390_emit_le_goto): New function.
4109 (s390_emit_gt_goto): New function.
4110 (s390_emit_ge_goto): New function.
4111 (s390x_emit_prologue): New function.
4112 (s390x_emit_epilogue): New function.
4113 (s390x_emit_add): New function.
4114 (s390x_emit_sub): New function.
4115 (s390x_emit_mul): New function.
4116 (s390x_emit_lsh): New function.
4117 (s390x_emit_rsh_signed): New function.
4118 (s390x_emit_rsh_unsigned): New function.
4119 (s390x_emit_ext): New function.
4120 (s390x_emit_log_not): New function.
4121 (s390x_emit_bit_and): New function.
4122 (s390x_emit_bit_or): New function.
4123 (s390x_emit_bit_xor): New function.
4124 (s390x_emit_bit_not): New function.
4125 (s390x_emit_equal): New function.
4126 (s390x_emit_less_signed): New function.
4127 (s390x_emit_less_unsigned): New function.
4128 (s390x_emit_ref): New function.
4129 (s390x_emit_if_goto): New function.
4130 (s390x_emit_const): New function.
4131 (s390x_emit_call): New function.
4132 (s390x_emit_reg): New function.
4133 (s390x_emit_pop): New function.
4134 (s390x_emit_stack_flush): New function.
4135 (s390x_emit_zero_ext): New function.
4136 (s390x_emit_swap): New function.
4137 (s390x_emit_stack_adjust): New function.
4138 (s390x_emit_int_call_1): New function.
4139 (s390x_emit_void_call_2): New function.
4140 (s390x_emit_eq_goto): New function.
4141 (s390x_emit_ne_goto): New function.
4142 (s390x_emit_lt_goto): New function.
4143 (s390x_emit_le_goto): New function.
4144 (s390x_emit_gt_goto): New function.
4145 (s390x_emit_ge_goto): New function.
4146 (s390_emit_ops): New function.
4147 (struct linux_target_ops): Fill in emit_ops hook.
4148
abd9baf9
MK
41492016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
4150
4151 PR 18377
4152 * Makefile.in: Add s390 IPA files.
4153 * configure.srv: Build IPA for s390.
4154 * linux-s390-ipa.c: New file.
4155 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
4156 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
4157 (tdesc_s390_linux32): Likewise.
4158 (init_registers_s390_linux32v1): Likewise.
4159 (tdesc_s390_linux32v1): Likewise.
4160 (init_registers_s390_linux32v2): Likewise.
4161 (tdesc_s390_linux32v2): Likewise.
4162 (init_registers_s390_linux64): Likewise.
4163 (tdesc_s390_linux64): Likewise.
4164 (init_registers_s390_linux64v1): Likewise.
4165 (tdesc_s390_linux64v1): Likewise.
4166 (init_registers_s390_linux64v2): Likewise.
4167 (tdesc_s390_linux64v2): Likewise.
4168 (init_registers_s390_te_linux64): Likewise.
4169 (tdesc_s390_te_linux64): Likewise.
4170 (init_registers_s390_vx_linux64): Likewise.
4171 (tdesc_s390_vx_linux64): Likewise.
4172 (init_registers_s390_tevx_linux64): Likewise.
4173 (tdesc_s390_tevx_linux64): Likewise.
4174 (init_registers_s390x_linux64): Likewise.
4175 (tdesc_s390x_linux64): Likewise.
4176 (init_registers_s390x_linux64v1): Likewise.
4177 (tdesc_s390x_linux64v1): Likewise.
4178 (init_registers_s390x_linux64v2): Likewise.
4179 (tdesc_s390x_linux64v2): Likewise.
4180 (init_registers_s390x_te_linux64): Likewise.
4181 (tdesc_s390x_te_linux64): Likewise.
4182 (init_registers_s390x_vx_linux64): Likewise.
4183 (tdesc_s390x_vx_linux64): Likewise.
4184 (init_registers_s390x_tevx_linux64): Likewise.
4185 (tdesc_s390x_tevx_linux64): Likewise.
4186 (have_hwcap_s390_vx): New static variable.
4187 (s390_arch_setup): Fill have_hwcap_s390_vx.
4188 (s390_get_thread_area): New function.
4189 (s390_ft_entry_gpr_esa): New const.
4190 (s390_ft_entry_gpr_zarch): New const.
4191 (s390_ft_entry_misc): New const.
4192 (s390_ft_entry_fr): New const.
4193 (s390_ft_entry_vr): New const.
4194 (s390_ft_main_31): New const.
4195 (s390_ft_main_64): New const.
4196 (s390_ft_exit_fr): New const.
4197 (s390_ft_exit_vr): New const.
4198 (s390_ft_exit_misc): New const.
4199 (s390_ft_exit_gpr_esa): New const.
4200 (s390_ft_exit_gpr_zarch): New const.
4201 (append_insns): New function.
4202 (s390_relocate_instruction): New function.
4203 (s390_install_fast_tracepoint_jump_pad): New function.
4204 (s390_get_min_fast_tracepoint_insn_len): New function.
4205 (s390_get_ipa_tdesc_idx): New function.
4206 (struct linux_target_ops): Wire in the above functions.
4207 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
4208 * linux-s390-tdesc.h: New file.
4209
a4105d04
MK
42102016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
4211
4212 * linux-s390-low.c (s390_supports_tracepoints): New function.
4213 (struct linux_target_ops): Fill supports_tracepoints hook.
4214
35ac8b3e
YQ
42152016-03-18 Yao Qi <yao.qi@linaro.org>
4216
4217 * linux-low.c (lwp_signal_can_be_delivered): New function.
4218 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
4219
94610ec4
YQ
42202016-03-18 Yao Qi <yao.qi@linaro.org>
4221
4222 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
4223 0 if signal is enqueued. Remove 'signal' from one debugging
4224 message. Move one debugging message to some lines below.
4225 Remove code setting 'signal' to 0.
4226
80aea927
YQ
42272016-03-18 Yao Qi <yao.qi@linaro.org>
4228
4229 * linux-low.c (linux_low_filter_event): Remove redundant
4230 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
4231
b04fd3be
MK
42322016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
4233
4234 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
4235 (struct linux_target_ops): Wire in the above.
4236
c40c8d4b
YQ
42372016-03-03 Yao Qi <yao.qi@linaro.org>
4238
4239 * linux-low.c: Update comments to start_step_over.
4240
0f8288ae
YQ
42412016-03-03 Yao Qi <yao.qi@linaro.org>
4242
4243 PR server/19736
4244 * linux-low.c (handle_extended_wait): Set child suspended
4245 if event_lwp->bp_reinsert isn't zero.
4246
fdbd04a8
YQ
42472016-03-02 Yao Qi <yao.qi@linaro.org>
4248
4249 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
4250 enqueue_pending_signal.
4251
6896a8fa
MK
42522016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
4253
4254 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
4255 is actually loaded.
4256
ab503087
MK
42572016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
4258
4259 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
4260 (s390_regmap_3264) [!__s390x__]: New global.
4261 (s390_collect_ptrace_register): Skip map entries containing -1.
4262 (s390_supply_ptrace_register): Ditto.
4263 (s390_fill_gprs_high): New function.
4264 (s390_store_gprs_high): New function.
4265 (s390_regsets): Add NT_S390_HIGH_GPRS.
4266 (s390_get_hwcap): Enable on 31-bit.
4267 (have_hwcap_s390_high_gprs): Enable on 31-bit.
4268 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
4269 Detect NT_S390_HIGH_GPRS.
4270 (s390_usrregs_info_3264): Enable on 31-bit.
4271 (s390_regs_info): Enable regs_info_3264 on 31-bit.
4272 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
4273
ae91f625
MK
42742016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
4275
4276 PR gdb/13808
4277 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
4278 * configure.srv: Ditto.
4279 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
4280 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
4281 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
4282 (init_registers_amd64_linux): Remove prototype.
4283 (tdesc_amd64_linux): Remove declaration.
4284 (get_ipa_tdesc): New function.
4285 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
4286 initialize remaining tdescs.
4287 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
4288 (init_registers_i386_linux): Remove prototype.
4289 (tdesc_i386_linux): Remove declaration.
4290 (get_ipa_tdesc): New function.
4291 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
4292 initialize remaining tdescs.
4293 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
4294 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
4295 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
4296 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
4297 (x86_get_ipa_tdesc_idx): New function.
4298 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
4299 * linux-x86-tdesc.h: New file.
4300 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
4301 (target_get_ipa_tdesc_idx): New macro.
4302 * tracepoint.c (ipa_tdesc_idx): New macro.
4303 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
4304 (symbol_list): Add ipa_tdesc_idx.
4305 (cmd_qtstart): Write ipa_tdesc_idx in the target.
4306 (ipa_tdesc): Remove.
4307 (ipa_tdesc_idx): New variable.
4308 (get_context_regcache): Use get_ipa_tdesc.
4309 (gdb_collect): Ditto.
4310 (gdb_probe): Ditto.
4311 * tracepoint.h (get_ipa_tdesc): New prototype.
4312 (ipa_tdesc): Remove.
4313
e7ad2f14
PA
43142016-02-24 Pedro Alves <palves@redhat.com>
4315
4316 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
4317 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
4318 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
4319 Factor out common code between the USE_SIGTRAP_SIGINFO and
4320 !USE_SIGTRAP_SIGINFO blocks.
4321 (linux_low_filter_event): Call save_stop_reason instead of
4322 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
4323 Update comments.
4324 (linux_wait_1): Update comments.
4325
657f9cde
WW
43262016-02-24 Wei-cheng Wang <cole945@gmail.com>
4327
4328 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
4329 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
4330 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
4331 ppc_insert_point, ppc_remove_point.
4332
b00b61e1
MK
43332016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
4334
4335 * linux-s390-low.c (s390_supports_z_point_type): New function.
4336 (struct linux_target_ops): Wire s390_supports_z_point_type in.
4337
553cb527
YQ
43382016-02-16 Yao Qi <yao.qi@linaro.org>
4339
4340 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
4341 PC. Get pc from regcache_read_pc.
4342
a5652c21
YQ
43432016-02-12 Yao Qi <yao.qi@linaro.org>
4344
4345 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
4346 or linux_get_pc_32bit.
4347 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
4348
ed443b61
YQ
43492016-02-12 Yao Qi <yao.qi@linaro.org>
4350
4351 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
4352 arm_linux_get_next_pcs_fixup.
4353
020ecd38
MK
43542016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
4355
4356 * tracepoint.c (x_tracepoint_action_download): Change
4357 write_inferior_data_ptr to write_inferior_data_pointer.
4358 (cmd_qtstart): Likewise.
4359 (write_inferior_data_ptr): Remove.
4360 (download_agent_expr): Change write_inferior_data_ptr to
4361 write_inferior_data_pointer.
4362 (download_tracepoint_1): Likewise.
4363 (download_tracepoint): Likewise.
4364 (download_trace_state_variables): Likewise.
4365
7cae9051
WW
43662016-02-11 Wei-cheng Wang <cole945@gmail.com>
4367 Marcin Kościelnicki <koriakin@0x04.net>
4368
4369 * tracepoint.c (struct tracepoint_action_ops): Remove.
4370 (struct tracepoint_action): Remove ops.
4371 (m_tracepoint_action_download, r_tracepoint_action_download)
4372 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
4373 size and offset accordingly.
4374 (m_tracepoint_action_ops, r_tracepoint_action_ops)
4375 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
4376 (tracepoint_action_send, tracepoint_action_download): New functions.
4377 Helpers for trace action handlers.
4378 (add_tracepoint_action): Remove setup actions ops.
4379 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
4380
9f6a71b4
YQ
43812016-02-10 Yao Qi <yao.qi@linaro.org>
4382
4383 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
4384
1e94266c
SM
43852016-02-09 Simon Marchi <simon.marchi@ericsson.com>
4386
4387 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
4388 to AC_OUTPUT.
4389 * configure: Regenerate.
4390
8adce034
SM
43912016-02-09 Simon Marchi <simon.marchi@ericsson.com>
4392
4393 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
4394 void * to gdb_byte *.
4395 * linux-low.c (siginfo_fixup): Likewise.
4396 (linux_xfer_siginfo): Likewise.
4397 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
4398 Likewise.
4399 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
4400
93813b37
WT
44012016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
4402
4403 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
4404 to srv_tgtobj.
4405 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
4406 to srv_tgtobj.
4407 * linux-x86-low.c [__x86_64__]: Include
4408 "nat/amd64-linux-siginfo.h".
4409 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
4410 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
4411 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
4412 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
4413 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
4414 (cpt_si_fd, si_timerid, si_overrun): Move from
4415 nat/amd64-linux-siginfo.c.
4416 * Makefile.in (amd64-linux-siginfo.o:): New rule.
4417
8424cc97
SM
44182016-01-28 Simon Marchi <simon.marchi@ericsson.com>
4419
4420 * server.c (skip_to_semicolon): Remove.
4421 (process_point_options): Use strchrnul instead of
4422 skip_to_semicolon.
4423
4d18591b
YQ
44242016-01-26 Yao Qi <yao.qi@linaro.org>
4425
4426 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
4427 * linux-low.c (install_software_single_step_breakpoints): Don't
4428 call regcache_read_pc.
4429 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
4430 argument pc.
4431
d8020970
YQ
44322016-01-26 Yao Qi <yao.qi@linaro.org>
4433
4434 * linux-low.c (install_software_single_step_breakpoints): Call
4435 regcache_read_pc instead of get_pc.
4436
8b207339
YQ
44372016-01-26 Yao Qi <yao.qi@linaro.org>
4438
4439 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
4440 (unblock_async_io): Rename to ...
4441 (block_unblock_async_io): ... it. New function.
4442 (enable_async_io): Don't install SIGIO handler. Unblock it
4443 instead.
4444 (disable_async_io): Don't ignore SIGIO. Block it instead.
4445 (initialize_async_io): Install SIGIO handler. Don't call
4446 unblock_async_io.
4447
18879fef
YQ
44482016-01-26 Yao Qi <yao.qi@linaro.org>
4449
4450 * remote-utils.c (getpkt): If the buffer isn't empty, and the
4451 first character is '\003', call *the_target->request_interrupt.
4452
a0f8e08a
YQ
44532016-01-25 Yao Qi <yao.qi@linaro.org>
4454
4455 * remote-utils.c (new_thread_notify): Remove.
4456 (dead_thread_notify): Likewise.
4457 * remote-utils.h (new_thread_notify): Remove declaration.
4458 (dead_thread_notify): Likewise.
4459
cc5fd9ab
MK
44602016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
4461
4462 * gdb.trace/pending.exp: Fix expected message on continue.
4463
99e8eb11
MK
44642016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
4465
4466 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
4467 it works properly on big-endian machines where sizeof (CORE_ADDR)
4468 != sizeof (void *).
4469
a994041d
PA
44702016-01-21 Pedro Alves <palves@redhat.com>
4471
4472 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
4473 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
4474 * configure: Regenerate.
4475
f7a6a40d
YQ
44762016-01-21 Yao Qi <yao.qi@linaro.org>
4477
4478 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
4479 is_thumb and set it according to CPSR saved on the stack.
4480 (get_next_pcs_syscall_next_pc): Pass is_thumb to
4481 arm_sigreturn_next_pc.
4482
6f69e520
YQ
44832016-01-18 Yao Qi <yao.qi@linaro.org>
4484
4485 * linux-low.c (linux_set_pc_64bit): New function.
4486 (linux_get_pc_64bit): New function.
4487 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
4488 Declare.
4489 * linux-sparc-low.c (debug_threads): Remove declaration.
4490 (sparc_get_pc): Remove.
4491 (the_low_target): Use linux_get_pc_64bit instead of
4492 sparc_get_pc.
4493 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
4494 (the_low_target): Use linux_get_pc_64bit and
4495 linux_set_pc_64bit.
4496
276d4552
YQ
44972016-01-18 Yao Qi <yao.qi@linaro.org>
4498
4499 * linux-arm-low.c (debug_threads): Remove declaration.
4500 (arm_get_pc, arm_set_pc): Remove.
4501 (the_low_target): Use linux_get_pc_32bit and
4502 linux_set_pc_32bit.
4503 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
4504 (the_low_target): Use linux_get_pc_32bit and
4505 linux_set_pc_32bit.
4506 * linux-cris-low.c (debug_threads): Remove declaration.
4507 (cris_get_pc, cris_set_pc,): Remove.
4508 (the_low_target): Use linux_get_pc_32bit and
4509 linux_set_pc_32bit.
4510 * linux-crisv32-low.c (debug_threads): Remove declaration.
4511 (cris_get_pc, cris_set_pc): Remove.
4512 (the_low_target): Use linux_get_pc_32bit and
4513 linux_set_pc_32bit.
4514 * linux-low.c: Include inttypes.h.
4515 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
4516 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
4517 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
4518 (the_low_target): Use linux_get_pc_32bit and
4519 linux_set_pc_32bit.
4520 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
4521 (the_low_target): Use linux_get_pc_32bit and
4522 linux_set_pc_32bit.
4523 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
4524 (the_low_target): Use linux_get_pc_32bit and
4525 linux_set_pc_32bit.
4526 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
4527 (the_low_target): Use linux_get_pc_32bit and
4528 linux_set_pc_32bit.
4529 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
4530 (the_low_target): Use linux_get_pc_32bit and
4531 linux_set_pc_32bit.
4532
eb0edac8
GB
45332016-01-18 Gary Benson <gbenson@redhat.com>
4534
4535 * configure.ac (AC_FUNC_FORK): New check.
4536 * config.in: Regenerate.
4537 * configure: Likewise.
4538
1b451dda
YQ
45392016-01-14 Yao Qi <yao.qi@linaro.org>
4540
4541 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
4542 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
4543 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
4544 arm_get_next_pcs_ctor.
4545
82075af2
JS
45462016-01-12 Josh Stone <jistone@redhat.com>
4547 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4548
4549 * inferiors.h: Include "gdb_vecs.h".
4550 (struct process_info): Add syscalls_to_catch.
4551 * inferiors.c (remove_process): Free syscalls_to_catch.
4552 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
4553 syscall_return stops.
4554 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
4555 * server.c (handle_general_set): Handle QCatchSyscalls.
4556 (handle_query): Report support for QCatchSyscalls.
4557 * target.h (struct target_ops): Add supports_catch_syscall.
4558 (target_supports_catch_syscall): New macro.
4559 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
4560 (struct lwp_info): Add syscall_state.
4561 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
4562 Maintain syscall_state and syscalls_to_catch across exec.
4563 (get_syscall_trapinfo): New function, proxy to the_low_target.
4564 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
4565 (linux_low_filter_event): Toggle syscall_state entry/return for
4566 syscall traps, and set it ignored for all others.
4567 (gdb_catching_syscalls_p): New function.
4568 (gdb_catch_this_syscall_p): New function.
4569 (linux_wait_1): Handle SYSCALL_SIGTRAP.
4570 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
4571 (linux_supports_catch_syscall): New function.
4572 (linux_target_ops): Install it.
4573 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
4574 (the_low_target): Install it.
4575
8f13a3ce
MF
45762016-01-12 Mike Frysinger <vapier@gentoo.org>
4577
4578 * acinclude.m4: Include new ../warning.m4 file.
4579 * configure: Regenerated.
4580 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
4581
5b3da067
MF
45822016-01-12 Mike Frysinger <vapier@gentoo.org>
4583
4584 * ax.c (is_goto_target): Mark static.
4585 * linux-low.c (register_addr): Likewise.
4586 (linux_fetch_registers, linux_store_registers): Likewise.
4587 * mem-break.c (any_persistent_commands): Fix old prototype.
4588 (add_commands_to_breakpoint): Mark static.
4589 * regcache.c (find_register_by_name): Delete unused func.
4590 * remote-utils.c (hex_or_minus_one): Mark static.
4591 * server.c (monitor_show_help): Mark static.
4592 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
4593 handle_v_requests): Likewise.
4594
bc504a31
PA
45952016-01-12 Pedro Alves <palves@redhat.com>
4596
4597 Remove use of the registered trademark symbol throughout.
4598
5a0dd67a
YQ
45992016-01-08 Yao Qi <yao.qi@linaro.org>
4600
4601 * remote-utils.c (getpkt): If c is '\003', call target hook
4602 request_interrupt.
4603
b2ca446f
YQ
46042016-01-06 Yao Qi <yao.qi@linaro.org>
4605
4606 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
4607 linux-aarch32-low.c.
4608 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4609 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
4610 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4611 (thumb2_breakpoint): Declare.
4612 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
4613 linux-aarch32-low.h.
4614 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4615 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
4616 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4617
edd88788
JB
46182016-01-01 Joel Brobecker <brobecker@adacore.com>
4619
4620 * gdbreplay.c (gdbreplay_version): Change copyright year in
4621 version message.
4622 * server.c (gdbserver_version): Likewise.
4623
65da7f14
PP
46242015-12-28 Patrick Palka <patrick@parcs.ath.cx>
4625
4626 * server.c (crc32_table): Delete.
4627 (crc32): Use libiberty's xcrc32 function.
4628
4abd5ed2
JB
46292015-12-22 Joel Brobecker <brobecker@adacore.com>
4630
4631 * lynx-low.c (lynx_delete_thread_callback): New function.
4632 (lynx_mourn): Properly delete our process and all of its
4633 threads. Remove call to clear_inferiors.
4634
0e50fe5c
JB
46352015-12-22 Joel Brobecker <brobecker@adacore.com>
4636
4637 * target.c (thread_search_callback): Add check that
4638 the thread_stopped target callback is not NULL before
4639 calling it.
4640
35adc03f
YQ
46412015-12-21 Yao Qi <yao.qi@linaro.org>
4642
4643 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
4644 arm breakpoint.
4645
bd2b2909
AT
46462015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4647
4648 * server.c (handle_query): Call target_supports_software_single_step.
4649
7fe5e27e
AT
46502015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4651
4652 * linux-low.c (single_step): New function.
4653 (linux_resume_one_lwp_throw): Call single_step.
4654 (start_step_over): Likewise.
4655
d9311bfa
AT
46562015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4657
4658 * Makefile.in (SFILES): Append arch/arm-linux.c,
4659 arch/arm-get-next-pcs.c.
4660 (arm-linux.o): New rule.
4661 (arm-get-next-pcs.o): New rule.
4662 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
4663 arm-linux.o.
4664 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
4665 to linux-aarch32-low.c.
4666 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4667 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4668 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4669 (thumb2_breakpoint_len): Likewise.
4670 (arm_is_thumb_mode): Make non-static.
4671 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
4672 from linux-aarch32-low.c.
4673 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4674 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4675 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4676 (thumb2_breakpoint_len): Likewise.
4677 (arm_is_thumb_mode): New declaration.
4678 * linux-arm-low.c: Include arch/arm-linux.h
4679 aarch/arm-get-next-pcs.h, sys/syscall.h.
4680 (get_next_pcs_ops): New struct.
4681 (get_next_pcs_addr_bits_remove): New function.
4682 (get_next_pcs_is_thumb): New function.
4683 (get_next_pcs_read_memory_unsigned_integer): Likewise.
4684 (arm_sigreturn_next_pc): Likewise.
4685 (get_next_pcs_syscall_next_pc): Likewise.
4686 (arm_gdbserver_get_next_pcs): Likewise.
4687 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
4688 Initialize.
4689 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
4690 * server.h: Include gdb_vecs.h.
4691
68ce2059
AT
46922015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4693
4694 * Makefile.in (SFILES): Append common/common-regcache.c.
4695 (OBS): Append common-regcache.o.
4696 (common-regcache.o): New rule.
4697 * regcache.c (init_register_cache): Initialize cache to
4698 REG_UNAVAILABLE.
4699 (regcache_raw_read_unsigned): New function.
4700 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
4701 register_status enum.
4702
fa5308bd
AT
47032015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4704
4705 * linux-aarch64-low.c (the_low_targets): Rename
4706 breakpoint_reinsert_addr to get_next_pcs.
4707 * linux-arm-low.c (the_low_targets): Likewise.
4708 * linux-bfin-low.c (the_low_targets): Likewise.
4709 * linux-cris-low.c (the_low_targets): Likewise.
4710 * linux-crisv32-low.c (the_low_targets): Likewise.
4711 * linux-low.c (can_software_single_step): Likewise.
4712 (install_software_single_step_breakpoints): New function.
4713 (start_step_over): Use install_software_single_step_breakpoints.
4714 * linux-low.h: New CORE_ADDR vector.
4715 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
4716 get_next_pcs.
4717 * linux-mips-low.c (the_low_targets): Likewise.
4718 * linux-nios2-low.c (the_low_targets): Likewise.
4719 * linux-sparc-low.c (the_low_targets): Likewise.
4720
4a6ed09b
PA
47212015-12-17 Pedro Alves <palves@redhat.com>
4722
4723 * linux-low.c (linux_kill_one_lwp): Remove references to
4724 LinuxThreads.
4725 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
4726 to 'kill'.
4727 (linux_init_signals): Delete.
4728 (initialize_low): Adjust.
4729 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
4730
7544db95
PA
47312015-12-16 Pedro Alves <palves@redhat.com>
4732
4733 * configure.ac (compiler warning flags): When testing a
4734 -Wno-foo option, check whether -Wfoo works instead.
4735 * configure: Regenerate.
4736
8020350c
DB
47372015-12-11 Don Breazeal <donb@codesourcery.com>
4738
4739 * server.c (process_serial_event): Don't exit from gdbserver
4740 in remote mode if there are still active inferiors.
4741
db91f502
YQ
47422015-12-11 Yao Qi <yao.qi@linaro.org>
4743
4744 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
4745 arm_breakpoint_at if the process is 32-bit.
4746
b37a6290
YQ
47472015-12-11 Yao Qi <yao.qi@linaro.org>
4748
4749 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
4750 arm breakpoint.
4751
17b1509a
YQ
47522015-12-07 Yao Qi <yao.qi@linaro.org>
4753
4754 * configure.srv: Append arm.o to srv_tgtobj for
4755 aarch64*-*-linux* target.
4756 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
4757 from linux-arm-low.c.
4758 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4759 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4760 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4761 (thumb2_breakpoint_len): Likewise.
4762 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
4763 (arm_breakpoint_kinds): Likewise.
4764 (arm_breakpoint_kind_from_pc): Likewise.
4765 (arm_sw_breakpoint_from_kind): Likewise.
4766 (arm_breakpoint_kind_from_current_state): Likewise.
4767 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
4768 (arm_sw_breakpoint_from_kind): Declare.
4769 (arm_breakpoint_kind_from_current_state): Declare.
4770 (arm_breakpoint_at): Declare.
4771 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
4772 arm_sw_breakpoint_from_kind if process is 32-bit.
4773 (aarch64_breakpoint_kind_from_pc): New function.
4774 (aarch64_breakpoint_kind_from_current_state): New function.
4775 (the_low_target): Initialize fields breakpoint_kind_from_pc
4776 and breakpoint_kind_from_current_state.
4777 * linux-arm-low.c (arm_breakpoint_kinds): Move to
4778 linux-aarch32-low.c.
4779 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
4780 (arm_breakpoint, arm_breakpoint_len): Likewise.
4781 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
4782 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4783 (arm_is_thumb_mode): Likewise.
4784 (arm_breakpoint_at): Likewise.
4785 (arm_breakpoint_kind_from_pc): Likewise.
4786 (arm_sw_breakpoint_from_kind): Likewise.
4787 (arm_breakpoint_kind_from_current_state): Likewise.
4788
4789 Revert:
4790 2015-08-04 Yao Qi <yao.qi@linaro.org>
4791
4792 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
4793 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
4794 * server.c (extended_protocol): Remove "static".
4795 * server.h (extended_protocol): Declare it.
4796
ece66d65
JS
47972015-12-04 Josh Stone <jistone@redhat.com>
4798
4799 * target.h (struct target_ops) <arch_setup>: Rename to ...
4800 (struct target_ops) <post_create_inferior>: ... this.
4801 (target_arch_setup): Rename to ...
4802 (target_post_create_inferior): ... this, calling post_create_inferior.
4803 * server.c (start_inferior): Update target_arch_setup calls to
4804 target_post_create_inferior.
4805 * linux-low.c (linux_low_ptrace_options): Forward declare.
4806 (linux_arch_setup): Update its comment for general use.
4807 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
4808 (struct linux_target_ops): Use linux_post_create_inferior.
4809 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
4810 to post_create_inferior.
4811 * nto-low.c (struct nto_target_ops): Likewise.
4812 * spu-low.c (struct spu_target_ops): Likewise.
4813 * win32-low.c (struct win32_target_ops): Likewise.
4814
e58c48b4
AT
48152015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
4816
4817 * linux-arm-low.c: Remove duplicate arch/arm.h include.
4818
fbec8956
AT
48192015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4820
4821 * linux-arm-low.c (arm_reinsert_addr): Remove function.
4822 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
4823 * linux-cris-low.c (cris_reinsert_addr> Remove function.
4824 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4825 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
4826 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4827 * linux-mips-low.c (mips_reinsert_addr): Remove function.
4828 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4829 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
4830 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4831 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
4832 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4833
9b4c5f87
AT
48342015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4835
4836 * linux-low.c (linux_look_up_symbols): Don't call
4837 linux_supports_traceclone.
4838 * linux-low.h (thread_db_init): Remove use_events argument.
4839 * thread-db.c (thread_db_use_event): Remove global variable.
4840 (struct thread_db) <td_thr_event_enable_p>: Remove field.
4841 (struct thread_db) <td_create_bp>: Remove field.
4842 (thread_db_create_event): Remove function.
4843 (thread_db_enable_reporting): Likewise.
4844 (find_one_thread): Don't check for thread_db_use_events.
4845 (attach_thread): Likewise.
4846 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
4847 (try_thread_db_load_1): Don't check for thread_db_use_events.
4848 (thread_db_init): Remove use_events argument and thread events
4849 handling.
4850 (remove_thread_event_breakpoints): Remove function.
4851 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
4852
7d00775e
AT
48532015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4854
4855 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
4856 New function.
4857 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4858 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
4859 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4860 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
4861 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
4862 Initialize.
4863 * linux-crisv32-low.c (cris_supports_hardware_single_step):
4864 New function.
4865 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4866 * linux-low.c (can_hardware_single_step): Use
4867 supports_hardware_single_step.
4868 (can_software_single_step): New function.
4869 (start_step_over): Call can_software_single_step.
4870 (linux_supports_hardware_single_step): New function.
4871 (struct target_ops) <supports_software_single_step>: Initialize.
4872 * linux-low.h (struct linux_target_ops)
4873 <supports_hardware_single_step>: Initialize.
4874 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
4875 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4876 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
4877 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
4878 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
4879 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4880 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
4881 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4882 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
4883 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
4884 Initialize.
4885 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
4886 (struct linux_target_ops) <tile_supports_hardware_single_step>:
4887 Initialize.
4888 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
4889 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4890 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
4891 New function.
4892 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4893 * target.h (struct target_ops): <supports_software_single_step>:
4894 New field.
4895 (target_supports_software_single_step): New macro.
4896
2d97cd35
AT
48972015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4898
4899 * linux-low.c (linux_wait_1): Fix pc advance condition.
4900 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
4901 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
4902
769ef81f
AT
49032015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4904
4905 * linux-arm-low.c (arm_is_thumb_mode): New function.
4906 (arm_breakpoint_at): Use arm_is_thumb_mode.
4907 (arm_breakpoint_kind_from_current_state): New function.
4908 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
4909 Initialize.
4910 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
4911 (linux_breakpoint_kind_from_current_state): New function.
4912 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
4913 * linux-low.h (struct linux_target_ops)
4914 <breakpoint_kind_from_current_state>: New field.
4915 * target.h (struct target_ops): Likewise.
4916 (target_breakpoint_kind_from_current_state): New macro.
4917
1bebeeca
PA
49182015-11-30 Pedro Alves <palves@redhat.com>
4919
4920 * linux-low.c (linux_resume): Wake up the event loop before
4921 returning.
4922
a67a9fae
PA
49232015-11-30 Pedro Alves <palves@redhat.com>
4924
4925 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
4926 check.
4927 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
4928 to -1.
4929 * target.c (struct thread_search): New structure.
4930 (thread_search_callback): New function.
4931 (prev_general_thread): New global.
4932 (prepare_to_access_memory, done_accessing_memory): New functions.
4933 * target.h (prepare_to_access_memory, done_accessing_memory):
4934 Replace macros with function declarations.
4935
f2faf941
PA
49362015-11-30 Pedro Alves <palves@redhat.com>
4937
4938 PR 14618
4939 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
4940 report TARGET_WAITKIND_NO_RESUMED.
4941 * remote-utils.c (prepare_resume_reply): Handle
4942 TARGET_WAITKIND_NO_RESUMED.
4943 * server.c (report_no_resumed): New global.
4944 (handle_query) <qSupported>: Handle "no-resumed+". Report
4945 "no-resumed+" support.
4946 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
4947 return error if the client doesn't support no-resumed events.
4948 (push_stop_notification): New function.
4949 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
4950 events if the client supports them.
4951
a681f9c9
PA
49522015-11-30 Pedro Alves <palves@redhat.com>
4953
4954 * linux-low.c (thread_still_has_status_pending_p): Don't check
4955 vCont;t here.
4956 (lwp_resumed): New function.
4957 (status_pending_p_callback): Return early if the LWP is not
4958 supposed to be resumed.
4959
65706a29
PA
49602015-11-30 Pedro Alves <palves@redhat.com>
4961
4962 * linux-low.c (handle_extended_wait): Assert that the LWP's
4963 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
4964 thread create events, leave the new child's status pending.
4965 (linux_low_filter_event): If GDB wants to hear about thread exit
4966 events, leave the LWP marked dead and don't delete it.
4967 (linux_wait_for_event_filtered): Don't check for thread exit.
4968 (filter_exit_event): New function.
4969 (linux_wait_1): Use it, when returning an exit event.
4970 (linux_resume_one_lwp_throw): Assert that the LWP's
4971 waitstatus is TARGET_WAITKIND_IGNORE.
4972 * remote-utils.c (prepare_resume_reply): Handle
4973 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
4974 * server.c (report_thread_events): New global.
4975 (handle_general_set): Handle QThreadEvents.
4976 (handle_query) <qSupported>: Handle and report QThreadEvents+;
4977 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
4978 TARGET_WAITKIND_THREAD_EXITED.
4979 * server.h (report_thread_events): Declare.
4980
56cf4bed
PA
49812015-11-30 Pedro Alves <palves@redhat.com>
4982
4983 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
4984 the thread's last_resume_kind was resume_stop.
4985
500c1d85
PA
49862015-11-30 Pedro Alves <palves@redhat.com>
4987
4988 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
4989 before returning.
4990
de979965
PA
49912015-11-30 Pedro Alves <palves@redhat.com>
4992
4993 * server.c (handle_v_requests): Handle vCtrlC.
4994
34c65914
PA
49952015-11-30 Pedro Alves <palves@redhat.com>
4996
4997 * gdbthread.h (find_any_thread_of_pid): Declare.
4998 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
4999 functions.
5000 * server.c (handle_query): If current_thread is NULL, look for
5001 another thread of the selected process.
5002
79efa585 50032015-11-26 Daniel Colascione <dancol@dancol.org>
01a49af8 5004 Simon Marchi <simon.marchi@ericsson.com>
79efa585
SM
5005
5006 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
5007 * server.c (handle_qxfer_threads_worker): Refactor to include thread
5008 name in reply.
5009 * target.h (struct target_ops) <thread_name>: New field.
5010 (target_thread_name): New macro.
5011
80d82c19
JB
50122015-11-23 Joel Brobecker <brobecker@adacore.com>
5013
5014 * regcache.h (regcache_invalidate_pid): Add declaration.
5015 * regcache.c (regcache_invalidate_pid): New function, extracted
5016 from regcache_invalidate.
5017 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
5018 Add trivial documentation comment.
5019 * lynx-low.c: Use regcache_invalidate_pid instead of
5020 regcache_invalidate.
5021
64da5dd5
JB
50222015-11-23 Joel Brobecker <brobecker@adacore.com>
5023
5024 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
5025 and Elf64_auxv_t if the target is Android.
5026
37ce4055
DE
50272015-11-22 Doug Evans <xdje42@gmail.com>
5028
5029 * target.h: #include <sys/types.h>.
5030
06e03fff
PA
50312015-11-19 Pedro Alves <palves@redhat.com>
5032
5033 * linux-low.c (linux_process_qsupported): Change prototype.
5034 Adjust.
5035 * linux-low.h (struct linux_target_ops) <process_qsupported>:
5036 Change prototype.
5037 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
5038 and adjust to loop over all features.
5039 * server.c (handle_query) <qSupported>: Adjust to call
5040 target_process_qsupported once, passing it a vector of unprocessed
5041 features.
5042 * target.h (struct target_ops) <process_qsupported>: Change
5043 prototype.
5044 (target_process_qsupported): Adjust.
5045
9a084706
PA
50462015-11-19 Pedro Alves <palves@redhat.com>
5047
5048 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
5049 mode.
5050 * configure: Regenerate.
5051
dad44a1f
PA
50522015-11-19 Pedro Alves <palves@redhat.com>
5053
5054 * configure: Regenerate.
5055
231c0592
YQ
50562015-11-19 Yao Qi <yao.qi@linaro.org>
5057
5058 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
5059 type to uint32_t.
5060
6c1c9a8b
YQ
50612015-11-19 Yao Qi <yao.qi@linaro.org>
5062
5063 * linux-aarch64-low.c (enum aarch64_operand_type): New.
5064 (struct aarch64_operand): Move enum out.
5065
9caa3311
YQ
50662015-11-19 Yao Qi <yao.qi@linaro.org>
5067
5068 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
5069 struct user_fpsimd_state *.
5070 (aarch64_store_fpregset): Likewise.
5071
6a69a054
YQ
50722015-11-19 Yao Qi <yao.qi@linaro.org>
5073
5074 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
5075 struct user_pt_regs *.
5076 (aarch64_store_gregset): Likewise.
5077
1798301e
PA
50782015-11-18 Pedro Alves <palves@redhat.com>
5079
5080 * Makefile.in (all_object_files): Add $IPA_OBJS.
5081
ce7715e2
PA
50822015-11-17 Pedro Alves <palves@redhat.com>
5083
5084 * win32-low.c (win32_resume): Use gdb_signal_from_host,
5085 GDB_SIGNAL_0 and gdb_signal_to_string.
5086
c0879059
PA
50872015-11-17 Pedro Alves <palves@redhat.com>
5088
5089 * win32-low.c (handle_output_debug_string): Remove parameter.
5090 (win32_kill): Remove our_status local and adjust call to
5091 handle_output_debug_string.
5092 (get_child_debug_event): Adjust call to
5093 handle_output_debug_string.
5094
1996e237
SM
50952015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5096
5097 * linux-mips-low.c (mips_fill_gregset): Add cast.
5098 (mips_store_gregset): Likewise.
5099 (mips_fill_fpregset): Likewise.
5100 (mips_store_fpregset): Likewise.
5101
cbec665b
SM
51022015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5103
5104 * linux-mips-low.c (mips_add_watchpoint): Rename private to
5105 priv.
5106
eb3e3c67
SM
51072015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5108
5109 * linux-mips-low.c (mips_linux_new_thread): Change type of
5110 watch_type to enum target_hw_bp_type.
5111
171de4b8
SM
51122015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5113
5114 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
5115 Change return type to arm_hwbp_type.
5116
04248ead
SM
51172015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5118
5119 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
5120 (arm_store_gregset): Likewise.
5121 * linux-arm-low.c (arm_get_hwcap): Likewise.
5122 (arm_read_description): Likewise.
5123
04b3479c
SM
51242015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5125
5126 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
5127
2bc84e8a
SM
51282015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5129
5130 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
5131 (ppc_fill_vsxregset): Likewise.
5132 (ppc_store_vsxregset): Likewise.
5133 (ppc_fill_vrregset): Likewise.
5134 (ppc_store_vrregset): Likewise.
5135 (ppc_fill_evrregset): Likewise.
5136 (ppc_store_evrregset): Likewise.
5137
e6c5bb05
SM
51382015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5139
5140 * linux-ppc-low.c (ppc_usrregs_info): Remove
5141 forward-declaration.
5142 (ppc_arch_setup): Move lower in file.
5143
7ea45d72
SM
51442015-10-30 Simon Marchi <simon.marchi@ericsson.com>
5145
5146 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
5147 (ps_pdwrite): Likewise.
5148
69291610
HW
51492015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
5150
5151 * linux-arm-low.c (arm_new_thread): Move pointer dereference
5152 to after assert checks.
5153
b42945fd
SM
51542015-10-29 Simon Marchi <simon.marchi@ericsson.com>
5155
5156 * proc-service.c (ps_pdread): Add/adjust casts.
5157 (ps_pdwrite): Add/adjust casts.
5158
d6f85c84
SM
51592015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
5160
5161 * server.c (handle_search_memory_1): Cast return value of
5162 memmem.
5163
f98cd059
SM
51642015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
5165
5166 * server.c (write_qxfer_response): Change type of data to
5167 gdb_byte *.
5168
d2412fa5
PA
51692015-10-29 Pedro Alves <palves@redhat.com>
5170
5171 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
5172
c17414a2
PA
51732015-10-29 Pedro Alves <palves@redhat.com>
5174
5175 * tracepoint.c (clear_installed_tracepoints): Add casts.
5176
e053fbc4
PA
51772015-10-29 Pedro Alves <palves@redhat.com>
5178
5179 * server.c (handle_v_cont, process_serial_event): Add enum
5180 gdb_signal casts to signal parsing code.
5181
add67df8
PA
51822015-10-29 Pedro Alves <palves@redhat.com>
5183
5184 * linux-low.h (NULL_REGSET): Define.
5185 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
5186 * linux-arm-low.c (arm_regsets): Likewise.
5187 * linux-crisv32-low.c (cris_regsets): Likewise.
5188 * linux-m68k-low.c (m68k_regsets): Likewise.
5189 * linux-mips-low.c (mips_regsets): Likewise.
5190 * linux-nios2-low.c (nios2_regsets): Likewise.
5191 * linux-ppc-low.c (ppc_regsets): Likewise.
5192 * linux-s390-low.c (s390_regsets): Likewise.
5193 * linux-sh-low.c (sh_regsets): Likewise.
5194 * linux-sparc-low.c (sparc_regsets): Likewise.
5195 * linux-tic6x-low.c (tic6x_regsets): Likewise.
5196 * linux-tile-low.c (tile_regsets): Likewise.
5197 * linux-x86-low.c (x86_regsets): Likewise.
5198 * linux-xtensa-low.c (xtensa_regsets): Likewise.
5199
50bc912a
PA
52002015-10-29 Pedro Alves <palves@redhat.com>
5201
5202 * linux-low.h (NULL_REGSET): Define.
5203 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
5204 * linux-arm-low.c (arm_regsets): Likewise.
5205 * linux-crisv32-low.c (cris_regsets): Likewise.
5206 * linux-m68k-low.c (m68k_regsets): Likewise.
5207 * linux-mips-low.c (mips_regsets): Likewise.
5208 * linux-nios2-low.c (nios2_regsets): Likewise.
5209 * linux-ppc-low.c (ppc_regsets): Likewise.
5210 * linux-s390-low.c (s390_regsets): Likewise.
5211 * linux-sh-low.c (sh_regsets): Likewise.
5212 * linux-sparc-low.c (sparc_regsets): Likewise.
5213 * linux-tic6x-low.c (tic6x_regsets): Likewise.
5214 * linux-tile-low.c (tile_regsets): Likewise.
5215 * linux-x86-low.c (x86_regsets): Likewise.
5216 * linux-xtensa-low.c (xtensa_regsets): Likewise.
5217
682b2546
DE
52182015-10-26 Doug Evans <dje@google.com>
5219
5220 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
5221
963843d4
DE
52222015-10-26 Doug Evans <dje@google.com>
5223
5224 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
5225
d41401ac
DE
52262015-10-26 Doug Evans <dje@google.com>
5227
5228 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
5229 for debug_printf.
5230 (attach_thread, find_new_threads_callback): Ditto.
5231
3db28855
AT
52322015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5233
5234 * mem-break.h (set_breakpoint_data): Remove.
5235
fb78e89c
AT
52362015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5237
5238 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
5239 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
5240 (initialize_low): Remove set_breakpoint_data call.
5241 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
5242 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
5243 (initialize_low): Remove set_breakpoint_data call.
5244 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
5245 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
5246 (initialize_low): Remove set_breakpoint_data call.
5247
2e6ee069
AT
52482015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5249
5250 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
5251 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
5252 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
5253 * target.h (target_breakpoint_kind_from_pc): New macro.
5254
1652a986
AT
52552015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
5256
5257 * linux-low.c (default_breakpoint_kind_from_pc): New function.
5258 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
5259 the default breakpoint kind.
5260
abeead09
AT
52612015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5262
5263 * linux-arm-low.c (arm_supports_z_point_type): Add software
5264 breakpoint support.
5265
b0b4b501
AT
52662015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5267
5268 * linux-arm-low.c: Refactor breakpoint definitions.
5269 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
5270 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
5271
8689682c
AT
52722015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5273
5274 * Makefile.in: Add arm.c/o.
5275 * configure.srv: Likewise.
5276 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
5277 (arm_breakpoint_kind_from_pc): New function.
5278 (arm_sw_breakpoint_from_kind): Return proper kind.
5279 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
5280
27165294
AT
52812015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5282
5283 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
5284 removal.
5285 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
5286 (struct raw_breakpoint) <size>: Remove.
5287 (struct raw_breakpoint) <kind>: Add.
5288 (bp_size): New function.
5289 (bp_opcode): Likewise.
5290 (find_raw_breakpoint_at): Adjust for kind.
5291 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
5292 (remove_memory_breakpoint): Adjust for kind call bp_size.
5293 (set_raw_breakpoint_at): Adjust for kind.
5294 (set_breakpoint): Likewise.
5295 (set_breakpoint_at): Call breakpoint_kind_from_pc.
5296 (delete_raw_breakpoint): Adjust for kind.
5297 (delete_breakpoint): Likewise.
5298 (find_gdb_breakpoint): Likewise.
5299 (set_gdb_breakpoint_1): Likewise.
5300 (set_gdb_breakpoint): Likewise.
5301 (delete_gdb_breakpoint_1): Likewise.
5302 (delete_gdb_breakpoint): Likewise.
5303 (uninsert_raw_breakpoint): Likewise.
5304 (reinsert_raw_breakpoint): Likewise.
5305 (set_breakpoint_data): Remove.
5306 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
5307 (check_mem_read): Adjust for kind call bp_size.
5308 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
5309 (clone_one_breakpoint): Adjust for kind.
5310 * mem-break.h (set_gdb_breakpoint): Likewise.
5311 (delete_gdb_breakpoint): Likewise.
5312 * server.c (process_serial_event): Likewise.
5313
dd373349
AT
53142015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5315
5316 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
5317 (struct linux_target_ops) <breakpoint>: Remove.
5318 (struct linux_target_ops) <breakpoint_len>: Remove.
5319 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5320 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5321 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
5322 (arm_sw_breakpoint_from_kind): New function.
5323 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
5324 (struct linux_target_ops) <breakpoint>: Remove.
5325 (struct linux_target_ops) <breakpoint_len>: Remove.
5326 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5327 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5328 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
5329 (struct linux_target_ops) <breakpoint>: Remove.
5330 (struct linux_target_ops) <breakpoint_len>: Remove.
5331 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5332 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5333 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
5334 (struct linux_target_ops) <breakpoint>: Remove.
5335 (struct linux_target_ops) <breakpoint_len>: Remove.
5336 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5337 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5338 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
5339 and sw_breakpoint_from_kind to increment the pc.
5340 (linux_breakpoint_kind_from_pc): New function.
5341 (linux_sw_breakpoint_from_kind): New function.
5342 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
5343 (initialize_low): Call breakpoint_kind_from_pc and
5344 sw_breakpoint_from_kind to replace breakpoint_data/len.
5345 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
5346 New field.
5347 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
5348 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
5349 (struct linux_target_ops) <breakpoint>: Remove.
5350 (struct linux_target_ops) <breakpoint_len>: Remove.
5351 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5352 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5353 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
5354 (struct linux_target_ops) <breakpoint>: Remove.
5355 (struct linux_target_ops) <breakpoint_len>: Remove.
5356 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5357 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5358 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
5359 (struct linux_target_ops) <breakpoint>: Remove.
5360 (struct linux_target_ops) <breakpoint_len>: Remove.
5361 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5362 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5363 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
5364 (struct linux_target_ops) <breakpoint>: Remove.
5365 (struct linux_target_ops) <breakpoint_len>: Remove.
5366 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5367 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5368 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
5369 (struct linux_target_ops) <breakpoint>: Remove.
5370 (struct linux_target_ops) <breakpoint_len>: Remove.
5371 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5372 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5373 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
5374 (struct linux_target_ops) <breakpoint>: Remove.
5375 (struct linux_target_ops) <breakpoint_len>: Remove.
5376 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5377 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5378 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
5379 (struct linux_target_ops) <breakpoint>: Remove.
5380 (struct linux_target_ops) <breakpoint_len>: Remove.
5381 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5382 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5383 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
5384 (struct linux_target_ops) <breakpoint>: Remove.
5385 (struct linux_target_ops) <breakpoint_len>: Remove.
5386 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5387 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5388 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
5389 (struct linux_target_ops) <breakpoint>: Remove.
5390 (struct linux_target_ops) <breakpoint_len>: Remove.
5391 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5392 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5393 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
5394 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
5395 (struct linux_target_ops) <breakpoint>: Remove.
5396 (struct linux_target_ops) <breakpoint_len>: Remove.
5397 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5398 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5399 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
5400 (struct linux_target_ops) <breakpoint>: Remove.
5401 (struct linux_target_ops) <breakpoint_len>: Remove.
5402 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5403 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5404
4cd98a19
AT
54052015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5406
5407 * linux-cris-low.c (cris_get_pc): Remove void arg.
5408
774ee6d2
AR
54092015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
5410
5411 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
5412 variable name.
5413
833dcd29
AR
54142015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
5415
5416 * inferiors.c (thread_pid_matches_callback): New function.
5417 (find_thread_process): New function.
5418 (remove_thread): Reset current_thread.
5419 (remove_process): Assert threads have been removed first.
5420
8d689ee5
YQ
54212015-10-15 Yao Qi <yao.qi@linaro.org>
5422
5423 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
5424 if it is 3.
5425 (aarch64_remove_point): Likewise.
5426 * regcache.c (regcache_register_size): New function.
5427
1c2e1515
YQ
54282015-10-12 Yao Qi <yao.qi@linaro.org>
5429
5430 * linux-aarch64-low.c: Update all callers as emit_load_store
5431 is renamed to aarch64_emit_load_store.
5432
e1c587c3
YQ
54332015-10-12 Yao Qi <yao.qi@linaro.org>
5434
5435 * linux-aarch64-low.c: Update all callers of function renaming
5436 from emit_insn to aarch64_emit_insn.
5437
b6542f81
YQ
54382015-10-12 Yao Qi <yao.qi@linaro.org>
5439
5440 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
5441 arch/aarch64-insn.h.
5442 (struct aarch64_memory_operand): Likewise.
5443 (ENCODE): Likewise.
5444 (emit_insn): Move to arch/aarch64-insn.c.
5445 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
5446 (emit_load_store): Move to arch/aarch64-insn.c.
5447 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
5448 (can_encode_int32): Remove.
5449
246994ce
YQ
54502015-10-12 Yao Qi <yao.qi@linaro.org>
5451
5452 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
5453 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
5454 (aarch64_relocate_instruction): Likewise.
5455 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
5456 (struct aarch64_insn_visitor): Likewise.
5457
0badd99f
YQ
54582015-10-12 Yao Qi <yao.qi@linaro.org>
5459
5460 * linux-aarch64-low.c (struct aarch64_insn_data): New.
5461 (struct aarch64_insn_visitor): New.
5462 (struct aarch64_insn_relocation_data): New.
5463 (aarch64_ftrace_insn_reloc_b): New function.
5464 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
5465 (aarch64_ftrace_insn_reloc_cb): Likewise.
5466 (aarch64_ftrace_insn_reloc_tb): Likewise.
5467 (aarch64_ftrace_insn_reloc_adr): Likewise.
5468 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
5469 (aarch64_ftrace_insn_reloc_others): Likewise.
5470 (visitor): New.
5471 (aarch64_relocate_instruction): Use visitor.
5472
dfaffe9d
YQ
54732015-10-12 Yao Qi <yao.qi@linaro.org>
5474
5475 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
5476 int. Add argument buf.
5477 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
5478 aarch64_relocate_instruction.
5479
70b439f0
YQ
54802015-10-12 Yao Qi <yao.qi@linaro.org>
5481
5482 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
5483 argument insn. Remove local variable insn. Don't call
5484 target_read_uint32.
5485 (aarch64_install_fast_tracepoint_jump_pad): Call
5486 target_read_uint32.
5487
7781c06f
YQ
54882015-09-30 Yao Qi <yao.qi@linaro.org>
5489
5490 * linux-aarch64-low.c (emit_movk): Shorten a long line.
5491 (emit_load_store_pair): Likewise.
5492
9a3c8263
SM
54932015-09-25 Simon Marchi <simon.marchi@ericsson.com>
5494
5495 * dll.c (match_dll): Add cast(s).
5496 (unloaded_dll): Likewise.
5497 * linux-low.c (second_thread_of_pid_p): Likewise.
5498 (delete_lwp_callback): Likewise.
5499 (count_events_callback): Likewise.
5500 (select_event_lwp_callback): Likewise.
5501 (linux_set_resume_request): Likewise.
5502 * server.c (accumulate_file_name_length): Likewise.
5503 (emit_dll_description): Likewise.
5504 (handle_qxfer_threads_worker): Likewise.
5505 (visit_actioned_threads): Likewise.
5506 * thread-db.c (any_thread_of): Likewise.
5507 * tracepoint.c (same_process_p): Likewise.
5508 (match_blocktype): Likewise.
5509 (build_traceframe_info_xml): Likewise.
5510
224c3ddb
SM
55112015-09-25 Simon Marchi <simon.marchi@ericsson.com>
5512
5513 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
5514 assignment.
5515 (gdb_unparse_agent_expr): Likewise.
5516 * hostio.c (require_data): Likewise.
5517 (handle_pread): Likewise.
5518 * linux-low.c (disable_regset): Likewise.
5519 (fetch_register): Likewise.
5520 (store_register): Likewise.
5521 (get_dynamic): Likewise.
5522 (linux_qxfer_libraries_svr4): Likewise.
5523 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
5524 (set_fast_tracepoint_jump): Likewise.
5525 (uninsert_fast_tracepoint_jumps_at): Likewise.
5526 (reinsert_fast_tracepoint_jumps_at): Likewise.
5527 (validate_inserted_breakpoint): Likewise.
5528 (clone_agent_expr): Likewise.
5529 * regcache.c (init_register_cache): Likewise.
5530 * remote-utils.c (putpkt_binary_1): Likewise.
5531 (decode_M_packet): Likewise.
5532 (decode_X_packet): Likewise.
5533 (look_up_one_symbol): Likewise.
5534 (relocate_instruction): Likewise.
5535 (monitor_output): Likewise.
5536 * server.c (handle_search_memory): Likewise.
5537 (handle_qxfer_exec_file): Likewise.
5538 (handle_qxfer_libraries): Likewise.
5539 (handle_qxfer): Likewise.
5540 (handle_query): Likewise.
5541 (handle_v_cont): Likewise.
5542 (handle_v_run): Likewise.
5543 (captured_main): Likewise.
5544 * target.c (write_inferior_memory): Likewise.
5545 * thread-db.c (try_thread_db_load_from_dir): Likewise.
5546 * tracepoint.c (init_trace_buffer): Likewise.
5547 (add_tracepoint_action): Likewise.
5548 (add_traceframe): Likewise.
5549 (add_traceframe_block): Likewise.
5550 (cmd_qtdpsrc): Likewise.
5551 (cmd_qtdv): Likewise.
5552 (cmd_qtstatus): Likewise.
5553 (response_source): Likewise.
5554 (response_tsv): Likewise.
5555 (cmd_qtnotes): Likewise.
5556 (gdb_collect): Likewise.
5557 (initialize_tracepoint): Likewise.
5558
afbe19f8
PL
55592015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5560
5561 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
5562 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
5563 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
5564 <NOP>: New.
5565 (enum aarch64_condition_codes): New enum.
5566 (w0): New static global.
5567 (fp): Likewise.
5568 (lr): Likewise.
5569 (struct aarch64_memory_operand) <type>: New
5570 MEMORY_OPERAND_POSTINDEX type.
5571 (postindex_memory_operand): New helper function.
5572 (emit_ret): New function.
5573 (emit_load_store_pair): New function, factored out of emit_stp
5574 with support for MEMORY_OPERAND_POSTINDEX.
5575 (emit_stp): Rewrite using emit_load_store_pair.
5576 (emit_ldp): New function.
5577 (emit_load_store): Likewise.
5578 (emit_ldr): Mention post-index instruction in comment.
5579 (emit_ldrh): New function.
5580 (emit_ldrb): New function.
5581 (emit_ldrsw): Mention post-index instruction in comment.
5582 (emit_str): Likewise.
5583 (emit_subs): New function.
5584 (emit_cmp): Likewise.
5585 (emit_and): Likewise.
5586 (emit_orr): Likewise.
5587 (emit_orn): Likewise.
5588 (emit_eor): Likewise.
5589 (emit_mvn): Likewise.
5590 (emit_lslv): Likewise.
5591 (emit_lsrv): Likewise.
5592 (emit_asrv): Likewise.
5593 (emit_mul): Likewise.
5594 (emit_sbfm): Likewise.
5595 (emit_sbfx): Likewise.
5596 (emit_ubfm): Likewise.
5597 (emit_ubfx): Likewise.
5598 (emit_csinc): Likewise.
5599 (emit_cset): Likewise.
5600 (emit_nop): Likewise.
5601 (emit_ops_insns): New helper function.
5602 (emit_pop): Likewise.
5603 (emit_push): Likewise.
5604 (aarch64_emit_prologue): New function.
5605 (aarch64_emit_epilogue): Likewise.
5606 (aarch64_emit_add): Likewise.
5607 (aarch64_emit_sub): Likewise.
5608 (aarch64_emit_mul): Likewise.
5609 (aarch64_emit_lsh): Likewise.
5610 (aarch64_emit_rsh_signed): Likewise.
5611 (aarch64_emit_rsh_unsigned): Likewise.
5612 (aarch64_emit_ext): Likewise.
5613 (aarch64_emit_log_not): Likewise.
5614 (aarch64_emit_bit_and): Likewise.
5615 (aarch64_emit_bit_or): Likewise.
5616 (aarch64_emit_bit_xor): Likewise.
5617 (aarch64_emit_bit_not): Likewise.
5618 (aarch64_emit_equal): Likewise.
5619 (aarch64_emit_less_signed): Likewise.
5620 (aarch64_emit_less_unsigned): Likewise.
5621 (aarch64_emit_ref): Likewise.
5622 (aarch64_emit_if_goto): Likewise.
5623 (aarch64_emit_goto): Likewise.
5624 (aarch64_write_goto_address): Likewise.
5625 (aarch64_emit_const): Likewise.
5626 (aarch64_emit_call): Likewise.
5627 (aarch64_emit_reg): Likewise.
5628 (aarch64_emit_pop): Likewise.
5629 (aarch64_emit_stack_flush): Likewise.
5630 (aarch64_emit_zero_ext): Likewise.
5631 (aarch64_emit_swap): Likewise.
5632 (aarch64_emit_stack_adjust): Likewise.
5633 (aarch64_emit_int_call_1): Likewise.
5634 (aarch64_emit_void_call_2): Likewise.
5635 (aarch64_emit_eq_goto): Likewise.
5636 (aarch64_emit_ne_goto): Likewise.
5637 (aarch64_emit_lt_goto): Likewise.
5638 (aarch64_emit_le_goto): Likewise.
5639 (aarch64_emit_gt_goto): Likewise.
5640 (aarch64_emit_ge_got): Likewise.
5641 (aarch64_emit_ops_impl): New static global variable.
5642 (aarch64_emit_ops): New target function, return
5643 &aarch64_emit_ops_impl.
5644 (struct linux_target_ops): Install it.
5645
bb903df0
PL
56462015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5647
5648 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
5649 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
5650 aarch64-ipa.o.
5651 * linux-aarch64-ipa.c: New file.
5652 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
5653 and endian.h.
5654 (aarch64_get_thread_area): New target method.
5655 (extract_signed_bitfield): New helper function.
5656 (aarch64_decode_ldr_literal): New function.
5657 (enum aarch64_opcodes): New enum.
5658 (struct aarch64_register): New struct.
5659 (struct aarch64_operand): New struct.
5660 (x0): New static global.
5661 (x1): Likewise.
5662 (x2): Likewise.
5663 (x3): Likewise.
5664 (x4): Likewise.
5665 (w2): Likewise.
5666 (ip0): Likewise.
5667 (sp): Likewise.
5668 (xzr): Likewise.
5669 (aarch64_register): New helper function.
5670 (register_operand): Likewise.
5671 (immediate_operand): Likewise.
5672 (struct aarch64_memory_operand): New struct.
5673 (offset_memory_operand): New helper function.
5674 (preindex_memory_operand): Likewise.
5675 (enum aarch64_system_control_registers): New enum.
5676 (ENCODE): New macro.
5677 (emit_insn): New helper function.
5678 (emit_b): New function.
5679 (emit_bcond): Likewise.
5680 (emit_cb): Likewise.
5681 (emit_tb): Likewise.
5682 (emit_blr): Likewise.
5683 (emit_stp): Likewise.
5684 (emit_ldp_q_offset): Likewise.
5685 (emit_stp_q_offset): Likewise.
5686 (emit_load_store): Likewise.
5687 (emit_ldr): Likewise.
5688 (emit_ldrsw): Likewise.
5689 (emit_str): Likewise.
5690 (emit_ldaxr): Likewise.
5691 (emit_stxr): Likewise.
5692 (emit_stlr): Likewise.
5693 (emit_data_processing_reg): Likewise.
5694 (emit_data_processing): Likewise.
5695 (emit_add): Likewise.
5696 (emit_sub): Likewise.
5697 (emit_mov): Likewise.
5698 (emit_movk): Likewise.
5699 (emit_mov_addr): Likewise.
5700 (emit_mrs): Likewise.
5701 (emit_msr): Likewise.
5702 (emit_sevl): Likewise.
5703 (emit_wfe): Likewise.
5704 (append_insns): Likewise.
5705 (can_encode_int32_in): New helper function.
5706 (aarch64_relocate_instruction): New function.
5707 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
5708 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
5709 (struct linux_target_ops): Install aarch64_get_thread_area,
5710 aarch64_install_fast_tracepoint_jump_pad and
5711 aarch64_get_min_fast_tracepoint_insn_len.
5712
787749ea
PL
57132015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5714
5715 * Makefile.in (aarch64-insn.o): New rule.
5716 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
5717
9812b2e6
YQ
57182015-09-21 Yao Qi <yao.qi@linaro.org>
5719
5720 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
5721
18fe412b
YQ
57222015-09-21 Yao Qi <yao.qi@linaro.org>
5723
5724 * tracepoint.c (max_jump_pad_size): Remove.
5725
a0cc84cd
YQ
57262015-09-18 Yao Qi <yao.qi@linaro.org>
5727
5728 * linux-aarch64-low.c: Don't include sys/uio.h.
5729 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
5730
d78908cf
WW
57312015-09-16 Wei-cheng Wang <cole945@gmail.com>
5732
5733 * tracepoint.c (eval_result_type): Change prototype.
5734 (condition_true_at_tracepoint): Fix argument to compiled_cond.
5735
d57e0d50
PA
57362015-09-15 Pedro Alves <palves@redhat.com>
5737
5738 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
5739 Check whether to report exec events instead of checking whether
5740 multiprocess is enabled.
5741
5a676acc
PA
57422015-09-15 Pedro Alves <palves@redhat.com>
5743
5744 PR remote/18965
5745 * remote-utils.c (prepare_resume_reply): Merge
5746 TARGET_WAITKIND_VFORK_DONE switch case with the
5747 TARGET_WAITKIND_FORKED case.
5748
7c5d0fad
YQ
57492015-09-15 Yao Qi <yao.qi@linaro.org>
5750
5751 * server.c (handle_query): Check string comparison using
5752 "else if" instead of "if".
5753
750ce8d1
YQ
57542015-09-15 Yao Qi <yao.qi@linaro.org>
5755
5756 * server.c (vCont_supported): New global variable.
5757 (handle_query): Set vCont_supported to 1 if "vContSupported+"
5758 matches. Append ";vContSupported+" to own_buf.
5759 (handle_v_requests): Append ";s;S" to own_buf if target supports
5760 hardware single step or vCont_supported is false.
5761 (capture_main): Set vCont_supported to zero.
5762
70b90b91
YQ
57632015-09-15 Yao Qi <yao.qi@linaro.org>
5764
5765 * linux-low.c (linux_supports_conditional_breakpoints): Rename
5766 it to ...
5767 (linux_supports_hardware_single_step): ... New function.
5768 (linux_target_ops): Update.
5769 * lynx-low.c (lynx_target_ops): Set field
5770 supports_hardware_single_step to target_can_do_hardware_single_step.
5771 * nto-low.c (nto_target_ops): Likewise.
5772 * spu-low.c (spu_target_ops): Likewise.
5773 * win32-low.c (win32_target_ops): Likewise.
5774 * target.c (target_can_do_hardware_single_step): New function.
5775 * target.h (struct target_ops) <supports_conditional_breakpoints>:
5776 Remove. <supports_hardware_single_step>: New field.
5777 (target_supports_conditional_breakpoints): Remove.
5778 (target_supports_hardware_single_step): New macro.
5779 (target_can_do_hardware_single_step): Declare.
5780 * server.c (handle_query): Use target_supports_hardware_single_step
5781 instead of target_supports_conditional_breakpoints.
5782
ade90bde
YQ
57832015-09-15 Yao Qi <yao.qi@linaro.org>
5784
5785 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
5786 function.
5787 (struct linux_target_ops the_low_target): Install
5788 aarch64_linux_siginfo_fixup.
5789
94585166
DB
57902015-09-11 Don Breazeal <donb@codesourcery.com>
5791 Luis Machado <lgustavo@codesourcery.com>
5792
5793 * linux-low.c (linux_mourn): Static declaration.
5794 (linux_arch_setup): Move in front of
5795 handle_extended_wait.
5796 (linux_arch_setup_thread): New function.
5797 (handle_extended_wait): Handle exec events. Call
5798 linux_arch_setup_thread. Make event_lwp argument a
5799 pointer-to-a-pointer.
5800 (check_zombie_leaders): Do not check stopped threads.
5801 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
5802 (linux_low_filter_event): Add lwp and thread for exec'ing
5803 non-leader thread if leader thread has been deleted.
5804 Refactor code into linux_arch_setup_thread and call it.
5805 Pass child lwp pointer by reference to handle_extended_wait.
5806 (linux_wait_for_event_filtered): Update comment.
5807 (linux_wait_1): Prevent clobbering exec event status.
5808 (linux_supports_exec_events): New function.
5809 (linux_target_ops) <supports_exec_events>: Initialize new member.
5810 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
5811 new member.
5812 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
5813 * server.c (report_exec_events): New global variable.
5814 (handle_query): Handle qSupported query for exec-events feature.
5815 (captured_main): Initialize report_exec_events.
5816 * server.h (report_exec_events): Declare new global variable.
5817 * target.h (struct target_ops) <supports_exec_events>: New
5818 member.
5819 (target_supports_exec_events): New macro.
5820 * win32-low.c (win32_target_ops) <supports_exec_events>:
5821 Initialize new member.
5822
0568462b
MM
58232015-09-09 Markus Metzger <markus.t.metzger@intel.com>
5824
5825 * linux-low.c (linux_low_enable_btrace): Remove.
5826 (linux_target_ops): Replace linux_low_enable_btrace with
5827 linux_enable_btrace.
5828
39edd165
YQ
58292015-09-03 Yao Qi <yao.qi@linaro.org>
5830
5831 * linux-aarch64-low.c (aarch64_insert_point): Call
5832 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
5833 returns true.
5834
1db33b5a
UW
58352015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
5836
5837 * linux-low.c (check_stopped_by_breakpoint): Use
5838 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
5839
ab290430
PA
58402015-08-27 Pedro Alves <palves@redhat.com>
5841
5842 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
5843
8d749320
SM
58442015-08-26 Simon Marchi <simon.marchi@ericsson.com>
5845
6711b7f8
SM
5846 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
5847 the XNEW-family equivalent.
8d749320
SM
5848 (compile_bytecodes): Likewise.
5849 * dll.c (loaded_dll): Likewise.
5850 * event-loop.c (append_callback_event): Likewise.
5851 (create_file_handler): Likewise.
5852 (create_file_event): Likewise.
5853 * hostio.c (handle_open): Likewise.
5854 * inferiors.c (add_thread): Likewise.
5855 (add_process): Likewise.
5856 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
5857 * linux-arm-low.c (arm_new_process): Likewise.
5858 (arm_new_thread): Likewise.
5859 * linux-low.c (add_to_pid_list): Likewise.
5860 (linux_add_process): Likewise.
5861 (handle_extended_wait): Likewise.
5862 (add_lwp): Likewise.
5863 (enqueue_one_deferred_signal): Likewise.
5864 (enqueue_pending_signal): Likewise.
5865 (linux_resume_one_lwp_throw): Likewise.
5866 (linux_resume_one_thread): Likewise.
5867 (linux_read_memory): Likewise.
5868 (linux_write_memory): Likewise.
5869 * linux-mips-low.c (mips_linux_new_process): Likewise.
5870 (mips_linux_new_thread): Likewise.
5871 (mips_add_watchpoint): Likewise.
5872 * linux-x86-low.c (initialize_low_arch): Likewise.
5873 * lynx-low.c (lynx_add_process): Likewise.
5874 * mem-break.c (set_raw_breakpoint_at): Likewise.
5875 (set_breakpoint): Likewise.
5876 (add_condition_to_breakpoint): Likewise.
5877 (add_commands_to_breakpoint): Likewise.
5878 (clone_agent_expr): Likewise.
5879 (clone_one_breakpoint): Likewise.
5880 * regcache.c (new_register_cache): Likewise.
5881 * remote-utils.c (look_up_one_symbol): Likewise.
5882 * server.c (queue_stop_reply): Likewise.
5883 (start_inferior): Likewise.
5884 (queue_stop_reply_callback): Likewise.
5885 (handle_target_event): Likewise.
5886 * spu-low.c (fetch_ppc_memory): Likewise.
5887 (store_ppc_memory): Likewise.
5888 * target.c (set_target_ops): Likewise.
5889 * thread-db.c (thread_db_load_search): Likewise.
5890 (try_thread_db_load_1): Likewise.
5891 * tracepoint.c (add_tracepoint): Likewise.
5892 (add_tracepoint_action): Likewise.
5893 (create_trace_state_variable): Likewise.
5894 (cmd_qtdpsrc): Likewise.
5895 (cmd_qtro): Likewise.
5896 (add_while_stepping_state): Likewise.
5897 * win32-low.c (child_add_thread): Likewise.
5898 (get_image_name): Likewise.
5899
ed8b7b42
YQ
59002015-08-25 Yao Qi <yao.qi@linaro.org>
5901
5902 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
5903
db3cb7cb
YQ
59042015-08-25 Yao Qi <yao.qi@linaro.org>
5905
5906 * Makefile.in (aarch64-linux.o): New rule.
5907 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
5908 srv_tgtobj.
5909 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
5910 (aarch64_init_debug_reg_state): Make it extern.
5911 (aarch64_linux_prepare_to_resume): Remove.
5912
f6011a1c
YQ
59132015-08-25 Yao Qi <yao.qi@linaro.org>
5914
5915 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
5916 lwp_arch_private_info and ptid_of_lwp.
5917
88e2cf7e
YQ
59182015-08-25 Yao Qi <yao.qi@linaro.org>
5919
5920 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
5921 Find proc_info by find_process_pid. All callers updated.
5922
5e35436e
YQ
59232015-08-25 Yao Qi <yao.qi@linaro.org>
5924
5925 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
5926 Remove.
5927 (debug_reg_change_callback): Remove.
5928 (aarch64_notify_debug_reg_change): Remove.
5929
4a8a7965
YQ
59302015-08-25 Yao Qi <yao.qi@linaro.org>
5931
5932 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
5933 Call current_lwp_ptid.
5934
32a271ee
YQ
59352015-08-25 Yao Qi <yao.qi@linaro.org>
5936
5937 * linux-aarch64-low.c (debug_reg_change_callback): Use
5938 debug_printf.
5939
0d51c8d7
YQ
59402015-08-25 Yao Qi <yao.qi@linaro.org>
5941
5942 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
5943
31a43dd5
YQ
59442015-08-25 Yao Qi <yao.qi@linaro.org>
5945
5946 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
5947
8ee52567
YQ
59482015-08-25 Yao Qi <yao.qi@linaro.org>
5949
5950 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
5951 the code.
5952
ff3f0f45
YQ
59532015-08-25 Yao Qi <yao.qi@linaro.org>
5954
5955 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
5956 Remove.
5957 (debug_reg_change_callback): Remove argument entry and add argument
5958 lwp. Remove local variable thread. Don't print thread id in the
5959 debugging output. Don't check whether pid of thread equals to pid.
5960 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
5961 iterate_over_lwps instead find_inferior.
5962
3d40fbb5
PA
59632015-08-24 Pedro Alves <palves@redhat.com>
5964
5965 * inferiors.c (get_first_process): New function.
5966 * inferiors.h (get_first_process): New declaration.
5967 * remote-utils.c (read_ptid): Default to the first process in the
5968 list, instead of to the current thread's process.
5969
438e1e42
PA
59702015-08-24 Pedro Alves <palves@redhat.com>
5971
5972 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
5973 * event-loop.c: Likewise.
5974 * remote-utils.c: Likewise.
5975 * tracepoint.c: Likewise.
5976
a8c6d4fc
PA
59772015-08-24 Pedro Alves <palves@redhat.com>
5978
5979 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
5980 ptid_get_lwp.
5981
99b0bb12
PA
59822015-08-21 Pedro Alves <palves@redhat.com>
5983
5984 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
5985 instead of literal 1.
5986
f8904751
PA
59872015-08-21 Pedro Alves <palves@redhat.com>
5988
5989 * tdesc.c (default_description): Explicitly zero-initialize.
5990
465a859e
PA
59912015-08-21 Pedro Alves <palves@redhat.com>
5992
5993 PR gdb/18749
5994 * inferiors.c (remove_thread): Discard any pending stop reply for
5995 this thread.
5996 * server.c (remove_all_on_match_pid): Rename to ...
5997 (remove_all_on_match_ptid): ... this. Work with a filter ptid
5998 instead of a pid.
5999 (discard_queued_stop_replies): Change parameter to a ptid. Now
6000 extern.
6001 (handle_v_kill, kill_inferior_callback, captured_main)
6002 (process_serial_event): Adjust.
6003 * server.h (discard_queued_stop_replies): Declare.
6004
f0db101d
PA
60052015-08-21 Pedro Alves <palves@redhat.com>
6006
6007 * linux-low.c (wait_for_sigstop): Always switch to no thread
6008 selected if the previously current thread dies.
6009 * lynx-low.c (lynx_request_interrupt): Use the first thread's
6010 process instead of the current thread's.
6011 * remote-utils.c (input_interrupt): Don't check if there's no
6012 current thread.
6013 * server.c (gdb_read_memory, gdb_write_memory): If setting the
6014 current thread to the general thread fails, error out.
6015 (handle_qxfer_auxv, handle_qxfer_libraries)
6016 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
6017 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
6018 (handle_query): Check if there's a thread selected instead of
6019 checking whether there's any thread in the thread list.
6020 (handle_qxfer_threads, handle_qxfer_btrace)
6021 (handle_qxfer_btrace_conf): Don't error out early if there's no
6022 thread in the thread list.
6023 (handle_v_cont, myresume): Don't set the current thread to the
6024 continue thread.
6025 (process_serial_event) <Hg handling>: Also set thread_id if the
6026 previous general thread is still alive.
6027 (process_serial_event) <g/G handling>: If setting the current
6028 thread to the general thread fails, error out.
6029 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
6030 thread's lwp instead of the current thread's.
6031 * target.c (set_desired_thread): If the desired thread was not
6032 found, leave the current thread pointing to NULL. Return an int
6033 (boolean) indicating success.
6034 * target.h (set_desired_thread): Change return type to int.
6035
40045d91
MF
60362015-08-20 Max Filippov <jcmvbkbc@gmail.com>
6037
6038 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
6039 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
6040 #includes.
6041 (ps_get_thread_area): New function.
6042
45face3b
GB
60432015-08-19 Gary Benson <gbenson@redhat.com>
6044
6045 * hostio.c (handle_pread): Do not attempt to read more data
6046 than hostio_reply_with_data can fit in a packet.
6047
16d5f642
JB
60482015-08-18 Joel Brobecker <brobecker@adacore.com>
6049
6050 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
6051
a738da3a
MF
60522015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
6053
6054 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
6055
33ebda9d
PA
60562015-08-06 Pedro Alves <palves@redhat.com>
6057
6058 * tracepoint.c (expr_eval_result): Now an int.
6059
a44892be
PA
60602015-08-06 Pedro Alves <palves@redhat.com>
6061
6062 * gdbthread.h (struct regcache): Forward declare.
6063 (struct thread_info) <regcache_data>: Now a struct regcache
6064 pointer.
6065 * inferiors.c (inferior_regcache_data)
6066 (set_inferior_regcache_data): Now work with struct regcache
6067 pointers.
6068 * inferiors.h (struct regcache): Forward declare.
6069 (inferior_regcache_data, set_inferior_regcache_data): Now work
6070 with struct regcache pointers.
6071 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
6072 (free_register_cache_thread): Remove struct regcache pointer
6073 casts.
6074
608a1e46
PA
60752015-08-06 Pedro Alves <palves@redhat.com>
6076
6077 * server.c (captured_main): On error, print the exception message
6078 to stderr, and if run_once is set, throw a quit.
6079
f0ce0d3a
PA
60802015-08-06 Pedro Alves <palves@redhat.com>
6081
6082 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
6083 the current thread.
6084
bf47e248
PA
60852015-08-06 Pedro Alves <palves@redhat.com>
6086
6087 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
6088 reading beyond the passed in buffer length.
6089
b6b9ffcc
PL
60902015-08-06 Pierre Langlois <pierre.langlois@arm.com>
6091
6092 * tracepoint.c (symbol_list) <required>: Remove.
6093
863d01bd
PA
60942015-08-06 Pedro Alves <palves@redhat.com>
6095
6096 * linux-low.c (handle_extended_wait): Set the fork child's suspend
6097 count if stopping and suspending threads.
6098 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
6099 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
6100 (linux_detach): Complete an ongoing step-over.
6101 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
6102 throughout.
6103 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
6104 (linux_wait_1): If passing a signal to the inferior after
6105 finishing a step-over, unsuspend and re-resume all lwps. If we
6106 see a single-step event but the thread should be continuing, don't
6107 pass the trap to gdb.
6108 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
6109 internal_error instead of gdb_assert.
6110 (enqueue_pending_signal): New function.
6111 (check_ptrace_stopped_lwp_gone): Add debug output.
6112 (start_step_over): Use internal_error instead of gdb_assert.
6113 (complete_ongoing_step_over): New function.
6114 (linux_resume_one_thread): Don't resume a suspended thread.
6115 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
6116 it stepping.
6117
00db26fa
PA
61182015-08-06 Pedro Alves <palves@redhat.com>
6119
6120 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
6121 (linux_thread_alive): Use lwp_is_marked_dead.
6122 (extended_event_reported): Delete.
6123 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
6124 instead of extended_event_reported.
6125 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
6126 as well.
6127 (lwp_is_marked_dead): New function.
6128 (lwp_running): Use lwp_is_marked_dead.
6129 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
6130 comment.
6131
ad071a30
PA
61322015-08-06 Pedro Alves <palves@redhat.com>
6133
6134 * linux-low.c (linux_wait_1): Move fork event output out of the
6135 !report_to_gdb check. Pass event_child->waitstatus to
6136 target_waitstatus_to_string instead of ourstatus.
6137
524b57e6
YQ
61382015-08-04 Yao Qi <yao.qi@linaro.org>
6139
6140 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
6141 if current_thread is 32 bit.
6142
6085d6f6
YQ
61432015-08-04 Yao Qi <yao.qi@linaro.org>
6144
6145 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
6146 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
6147 * server.c (extended_protocol): Remove "static".
6148 * server.h (extended_protocol): Declare it.
6149
8a7e4587
YQ
61502015-08-04 Yao Qi <yao.qi@linaro.org>
6151
6152 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
6153 both aarch64 and aarch32.
6154 (aarch64_set_pc): Likewise.
6155
3b53ae99
YQ
61562015-08-04 Yao Qi <yao.qi@linaro.org>
6157
6158 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
6159 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
6160 arm-with-neon.xml to srv_xmlfiles.
6161 * linux-aarch64-low.c: Include linux-aarch32-low.h.
6162 (is_64bit_tdesc): New function.
6163 (aarch64_linux_read_description): New function.
6164 (aarch64_arch_setup): Call aarch64_linux_read_description.
6165 (regs_info): Rename to regs_info_aarch64.
6166 (aarch64_regs_info): Return right regs_info.
6167 (initialize_low_arch): Call initialize_low_arch_aarch32.
6168
bd9e6534
YQ
61692015-08-04 Yao Qi <yao.qi@linaro.org>
6170
6171 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
6172 * linux-aarch32-low.c: New file.
6173 * linux-aarch32-low.h: New file.
6174 * linux-arm-low.c (arm_fill_gregset): Move it to
6175 linux-aarch32-low.c.
6176 (arm_store_gregset): Likewise.
6177 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
6178 (arm_store_vfpregset): Call arm_store_vfpregset_num.
6179 (arm_arch_setup): Check if PTRACE_GETREGSET works.
6180 (regs_info): Rename to regs_info_arm.
6181 (arm_regs_info): Return regs_info_aarch32 if
6182 have_ptrace_getregset is 1 and target description is
6183 arm_with_neon or arm_with_vfpv3.
6184 (initialize_low_arch): Don't call init_registers_arm_with_neon.
6185 Call initialize_low_arch_aarch32 instead.
6186
ded48a5e
YQ
61872015-08-04 Yao Qi <yao.qi@linaro.org>
6188
6189 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
6190 * linux-low.c: ... here.
6191 * linux-low.h (have_ptrace_getregset): Declare it.
6192
96e9210f
PA
61932015-08-04 Pedro Alves <palves@redhat.com>
6194
6195 * thread-db.c (struct thread_db): Use new typedefs.
6196 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
6197 CHK calls.
6198 (disable_thread_event_reporting): Cast result of dlsym to
6199 destination function pointer type.
6200 (thread_db_mourn): Use td_ta_delete_ftype.
6201
af60a1ef
SL
62022015-08-03 Sandra Loosemore <sandra@codesourcery.com>
6203
6204 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
6205 arch variant.
6206 (CDX_BREAKPOINT): Define for R2.
6207 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
6208 (the_low_target): Add comments.
6209
e8b41681
YQ
62102015-07-30 Yao Qi <yao.qi@linaro.org>
6211
6212 * linux-arm-low.c (arm_hwcap): Remove it.
6213 (arm_read_description): New local variable arm_hwcap. Don't
6214 set arm_hwcap to zero.
6215
89abb039
YQ
62162015-07-30 Yao Qi <yao.qi@linaro.org>
6217
6218 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
6219 Use regcache->tdesc instead.
6220 (arm_store_wmmxregset): Likewise.
6221 (arm_fill_vfpregset): Likewise.
6222 (arm_store_vfpregset): Likewise.
6223
deca266c
YQ
62242015-07-30 Yao Qi <yao.qi@linaro.org>
6225
6226 * linux-arm-low.c: Include arch/arm.h.
6227 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
6228 (arm_store_gregset): Likewise.
6229
aa58a496
SM
62302015-07-29 Simon Marchi <simon.marchi@ericsson.com>
6231
6232 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
6233 ptrace's 4th parameter.
6234
50904b25
YQ
62352015-07-27 Yao Qi <yao.qi@linaro.org>
6236
6237 * configure.srv (case aarch64*-*-linux*): Don't set
6238 srv_linux_usrregs.
6239
5826e159
PA
62402015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
6241
6242 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
6243 sys/ptrace.h.
6244 * linux-arm-low.c: Likewise.
6245 * linux-cris-low.c: Likewise.
6246 * linux-crisv32-low.c: Likewise.
6247 * linux-low.c: Likewise.
6248 * linux-m68k-low.c: Likewise.
6249 * linux-mips-low.c: Likewise.
6250 * linux-nios2-low.c: Likewise.
6251 * linux-s390-low.c: Likewise.
6252 * linux-sparc-low.c: Likewise.
6253 * linux-tic6x-low.c: Likewise.
6254 * linux-tile-low.c: Likewise.
6255 * linux-x86-low.c: Likewise.
6256
54019719
PA
62572015-07-24 Pedro Alves <palves@redhat.com>
6258
6259 * config.in: Regenerate.
6260 * configure: Regenerate.
6261
eb7aa561
PA
62622015-07-24 Pedro Alves <palves@redhat.com>
6263
6264 * acinclude.m4: Include ../ptrace.m4.
6265 * configure.ac: Call GDB_AC_PTRACE.
6266 * config.in, configure: Regenerate.
6267
55d7b841
YQ
62682015-07-24 Yao Qi <yao.qi@linaro.org>
6269
6270 * linux-low.c (linux_create_inferior): Remove setting to
6271 proc->priv->new_inferior.
6272 (linux_attach): Likewise.
6273 (linux_low_filter_event): Likewise.
6274 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
6275
c06cbd92
YQ
62762015-07-24 Yao Qi <yao.qi@linaro.org>
6277
6278 * linux-low.c (linux_arch_setup): New function.
6279 (linux_low_filter_event): If proc->tdesc is NULL and
6280 proc->attached is true, call the_low_target.arch_setup.
6281 Otherwise, keep status pending, and return.
6282 (linux_resume_one_lwp_throw): Don't call get_pc if
6283 thread->while_stepping isn't NULL. Don't call
6284 get_thread_regcache if proc->tdesc is NULL.
6285 (need_step_over_p): Return 0 if proc->tdesc is NULL.
6286 (linux_target_ops): Install arch_setup.
6287 * server.c (start_inferior): Call the_target->arch_setup.
6288 * target.h (struct target_ops) <arch_setup>: New field.
6289 (target_arch_setup): New marco.
6290 * lynx-low.c (lynx_target_ops): Update.
6291 * nto-low.c (nto_target_ops): Update.
6292 * spu-low.c (spu_target_ops): Update.
6293 * win32-low.c (win32_target_ops): Update.
6294
5ae3ebba
YQ
62952015-07-24 Yao Qi <yao.qi@linaro.org>
6296
6297 * linux-low.c (linux_add_process): Don't set
6298 proc->priv->new_inferior.
6299 (linux_create_inferior): Set proc->priv->new_inferior to 1.
6300 (linux_attach): Likewise.
6301
eb97750b
YQ
63022015-07-24 Yao Qi <yao.qi@linaro.org>
6303
6304 * server.c (start_inferior): Code refactor.
6305
51aee833
YQ
63062015-07-24 Yao Qi <yao.qi@linaro.org>
6307
6308 * server.c (process_serial_event): Set general_thread.
6309
af1b22f3
YQ
63102015-07-21 Yao Qi <yao.qi@linaro.org>
6311
6312 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
6313 aarch64_linux_get_debug_reg_capacity.
6314
554717a3
YQ
63152015-07-17 Yao Qi <yao.qi@linaro.org>
6316
6317 * Makefile.in (aarch64-linux-hw-point.o): New rule.
6318 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
6319 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
6320 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
6321 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
6322 (AARCH64_HWP_ALIGNMENT): Likewise.
6323 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
6324 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
6325 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
6326 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
6327 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
6328 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
6329 (struct aarch64_debug_reg_state): Likewise.
6330 (struct arch_lwp_info): Likewise.
6331 (aarch64_align_watchpoint): Likewise.
6332 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
6333 (aarch64_watchpoint_length): Likewise.
6334 (aarch64_point_encode_ctrl_reg): Likewise
6335 (aarch64_point_is_aligned): Likewise.
6336 (aarch64_align_watchpoint): Likewise.
6337 (aarch64_linux_set_debug_regs):
6338 (aarch64_dr_state_insert_one_point): Likewise.
6339 (aarch64_dr_state_remove_one_point): Likewise.
6340 (aarch64_handle_breakpoint): Likewise.
6341 (aarch64_handle_aligned_watchpoint): Likewise.
6342 (aarch64_handle_unaligned_watchpoint): Likewise.
6343 (aarch64_handle_watchpoint): Likewise.
6344
c67ca4de
YQ
63452015-07-17 Yao Qi <yao.qi@linaro.org>
6346
6347 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
6348 and don't aarch64_get_debug_reg_state. All callers update.
6349 (aarch64_handle_aligned_watchpoint): Likewise.
6350 (aarch64_handle_unaligned_watchpoint): Likewise.
6351 (aarch64_handle_watchpoint): Likewise.
6352 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
6353 (aarch64_remove_point): Likewise.
6354
25abf979
YQ
63552015-07-17 Yao Qi <yao.qi@linaro.org>
6356
6357 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
6358 debug_printf.
6359 (aarch64_handle_unaligned_watchpoint): Likewise.
6360
db1ff28b
JK
63612015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
6362
6363 Revert the previous 3 commits:
6364 Move gdb_regex* to common/
6365 Move linux_find_memory_regions_full & co.
6366 gdbserver build-id attribute generator
6367
700ca40f
JK
63682015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6369 Jan Kratochvil <jan.kratochvil@redhat.com>
6370
6371 gdbserver build-id attribute generator.
6372 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
6373 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
6374 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
6375 (find_phdr): New.
6376 (get_dynamic): Use find_pdhr to traverse program headers.
6377 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
6378 (compare_mapping_entry_range, struct find_memory_region_callback_data)
6379 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
6380 (get_hex_build_id): New.
6381 (linux_qxfer_libraries_svr4): Add optional build-id attribute
6382 to reply XML document.
6383
9904185c
JK
63842015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6385 Jan Kratochvil <jan.kratochvil@redhat.com>
6386
6387 * target.c: Include target/target-utils.h and fcntl.h.
6388 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
6389 (target_fileio_read_stralloc): New functions.
6390
6e5b4429
JK
63912015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
6392
6393 * Makefile.in (OBS): Add gdb_regex.o.
6394 (gdb_regex.o): New.
6395 * config.in: Rebuilt.
6396 * configure: Rebuilt.
6397
ddc98fbf
JK
63982015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6399 Jan Kratochvil <jan.kratochvil@redhat.com>
6400
6401 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
6402 * Makefile.in (OBS): Add target-utils.o.
6403 (linux-maps.o, target-utils.o): New.
6404 * configure.srv (srv_linux_obj): Add linux-maps.o.
6405
e57bb7a0
PL
64062015-07-15 Pierre Langlois <pierre.langlois@arm.com>
6407
6408 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
6409 function, return 1.
6410 (the_low_target): Install it.
6411
586b02a9
PA
64122015-07-14 Pedro Alves <palves@redhat.com>
6413
6414 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
6415 Instead, ignore ECHILD, and throw an error for other errnos.
6416
58c1b36c
PA
64172015-07-10 Pedro Alves <palves@redhat.com>
6418
6419 * event-loop.c (struct callback_event) <data>: Change type to
6420 gdb_client_data instance instead of gdb_client_data pointer.
6421 (append_callback_event): Adjust.
6422
421530db
PL
64232015-07-10 Pierre Langlois <pierre.langlois@arm.com>
6424
6425 * linux-aarch64-low.c: Add comments for each linux_target_ops
6426 method. Remove comments already covered in target_ops and
6427 linux_target_ops definitions.
6428 (the_low_target): Add comments for each unimplemented method.
6429
c2d65f38
YQ
64302015-07-09 Yao Qi <yao.qi@linaro.org>
6431
6432 * linux-aarch64-low.c (aarch64_regmap): Remove.
6433 (aarch64_usrregs_info): Remove.
6434 (regs_info): Set field usrregs to NULL.
6435
b20a6524
MM
64362015-07-02 Markus Metzger <markus.t.metzger@intel.com>
6437
6438 * linux-low.c: Include "rsp-low.h"
6439 (linux_low_encode_pt_config, linux_low_encode_raw): New.
6440 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
6441 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
6442 (handle_btrace_enable_pt): New.
6443 (handle_btrace_general_set): Support "pt".
6444 (handle_btrace_conf_general_set): Support "pt:size".
6445
96c97461
PL
64462015-06-29 Pierre Langlois <pierre.langlois@arm.com>
6447
6448 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
6449 Z_PACKET_SW_BP.
6450
37d66942
PL
64512015-06-29 Pierre Langlois <pierre.langlois@arm.com>
6452
6453 * linux-aarch64-low.c: Remove comment about endianness.
6454 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
6455 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
6456 memcmp.
6457
dc06243f
GB
64582015-06-24 Gary Benson <gbenson@redhat.com>
6459
6460 * linux-i386-ipa.c (stdint.h): Do not include.
6461 * lynx-i386-low.c (stdint.h): Likewise.
6462 * lynx-ppc-low.c (stdint.h): Likewise.
6463 * mem-break.c (stdint.h): Likewise.
6464 * thread-db.c (stdint.h): Likewise.
6465 * tracepoint.c (stdint.h): Likewise.
6466 * win32-low.c (stdint.h): Likewise.
6467
124e13d9
SM
64682015-06-18 Simon Marchi <simon.marchi@ericsson.com>
6469
6470 * server.c (write_qxfer_response): Update call to
6471 remote_escape_output.
6472
909c2cda
JK
64732015-06-15 Aleksandar Ristovski <aristovski@qnx.com
6474 Jan Kratochvil <jan.kratochvil@redhat.com>
6475
6476 Merge multiple hex conversions.
6477 * gdbreplay.c (tohex): Rename to 'fromhex'.
6478 (logchar): Use fromhex.
6479
24c05f46
JK
64802015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
6481
6482 * server.c (handle_qxfer_libraries): Set `version' attribute for
6483 <library-list>.
6484
14d2069a
GB
64852015-06-10 Gary Benson <gbenson@redhat.com>
6486
6487 * target.h (struct target_ops) <multifs_open>: New field.
6488 <multifs_unlink>: Likewise.
6489 <multifs_readlink>: Likewise.
6490 * linux-low.c (nat/linux-namespaces.h): New include.
6491 (linux_target_ops): Initialize the_target->multifs_open,
6492 the_target->multifs_unlink and the_target->multifs_readlink.
6493 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
6494 * hostio.c (hostio_fs_pid): New static variable.
6495 (hostio_handle_new_gdb_connection): New function.
6496 (handle_setfs): Likewise.
6497 (handle_open): Use the_target->multifs_open as appropriate.
6498 (handle_unlink): Use the_target->multifs_unlink as appropriate.
6499 (handle_readlink): Use the_target->multifs_readlink as
6500 appropriate.
6501 (handle_vFile): Handle vFile:setfs packets.
6502 * server.c (handle_query): Call hostio_handle_new_gdb_connection
6503 after target_handle_new_gdb_connection.
6504
4b8b5e72
GB
65052015-06-10 Gary Benson <gbenson@redhat.com>
6506
6507 * configure.ac (AC_CHECK_FUNCS): Add setns.
6508 * config.in: Regenerate.
6509 * configure: Likewise.
6510 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
6511 (linux-namespaces.o): New rule.
6512 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
6513
3ac2e371
GB
65142015-06-09 Gary Benson <gbenson@redhat.com>
6515
6516 * hostio.c (handle_open): Process mode argument with
6517 fileio_to_host_mode.
6518
ca9b78ce
YQ
65192015-06-01 Yao Qi <yao.qi@linaro.org>
6520
6521 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
6522 * linux-x86-low.c: Likewise.
6523
bfacd19d
DB
65242015-05-28 Don Breazeal <donb@codesourcery.com>
6525
6526 * linux-low.c (handle_extended_wait): Initialize
6527 thread_info.last_resume_kind for new fork children.
6528
452003ef
PA
65292015-05-15 Pedro Alves <palves@redhat.com>
6530
6531 * target.h (target_handle_new_gdb_connection): Rewrite using if
6532 wrapped in do/while.
6533
1041a03c
JB
65342015-05-14 Joel Brobecker <brobecker@adacore.com>
6535
6536 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
6537 * configure, config.in: Regenerate.
6538 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
6539 Declare typedef.
6540
c269dbdb
DB
65412015-05-12 Don Breazeal <donb@codesourcery.com>
6542
6543 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
6544 PTRACE_EVENT_VFORK_DONE.
6545 (linux_low_ptrace_options, extended_event_reported): Add vfork
6546 events.
6547 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
6548 and "vforkdone" for RSP 'T' Stop Reply Packet.
6549 * server.h (report_vfork_events): Declare
6550 global variable.
6551
3a8a0396
DB
65522015-05-12 Don Breazeal <donb@codesourcery.com>
6553
6554 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
6555 (the_low_target) <new_fork>: Initialize new member.
6556 * linux-arm-low.c (arm_new_fork): New function.
6557 (the_low_target) <new_fork>: Initialize new member.
6558 * linux-low.c (handle_extended_wait): Call new target function
6559 new_fork.
6560 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
6561 * linux-mips-low.c (mips_add_watchpoint): New function
6562 extracted from mips_insert_point.
6563 (the_low_target) <new_fork>: Initialize new member.
6564 (mips_linux_new_fork): New function.
6565 (mips_insert_point): Call mips_add_watchpoint.
6566 * linux-x86-low.c (x86_linux_new_fork): New function.
6567 (the_low_target) <new_fork>: Initialize new member.
6568
de0d863e
DB
65692015-05-12 Don Breazeal <donb@codesourcery.com>
6570
6571 * linux-low.c (handle_extended_wait): Implement return value,
6572 rename argument 'event_child' to 'event_lwp', handle
6573 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
6574 (linux_low_ptrace_options): New function.
6575 (linux_low_filter_event): Call linux_low_ptrace_options,
6576 use different argument fo linux_enable_event_reporting,
6577 use return value from handle_extended_wait.
6578 (extended_event_reported): New function.
6579 (linux_wait_1): Call extended_event_reported and set
6580 status to report fork events.
6581 (linux_write_memory): Add pid to debug message.
6582 (reset_lwp_ptrace_options_callback): New function.
6583 (linux_handle_new_gdb_connection): New function.
6584 (linux_target_ops): Initialize new structure member.
6585 * linux-low.h (struct lwp_info) <waitstatus>: New member.
6586 * lynx-low.c: Initialize new structure member.
6587 * remote-utils.c (prepare_resume_reply): Implement stop reason
6588 "fork" for "T" stop message.
6589 * server.c (handle_query): Call handle_new_gdb_connection.
6590 * server.h (report_fork_events): Declare global flag.
6591 * target.h (struct target_ops) <handle_new_gdb_connection>:
6592 New member.
6593 (target_handle_new_gdb_connection): New macro.
6594 * win32-low.c: Initialize new structure member.
6595
ddcbc397
DB
65962015-05-12 Don Breazeal <donb@codesourcery.com>
6597
6598 * mem-break.c (APPEND_TO_LIST): Define macro.
6599 (clone_agent_expr): New function.
6600 (clone_one_breakpoint): New function.
6601 (clone_all_breakpoints): New function.
6602 * mem-break.h: Declare new functions.
6603
89245bc0
DB
66042015-05-12 Don Breazeal <donb@codesourcery.com>
6605
6606 * linux-low.c (linux_supports_fork_events): New function.
6607 (linux_supports_vfork_events): New function.
6608 (linux_target_ops): Initialize new structure members.
6609 (initialize_low): Call linux_check_ptrace_features.
6610 * lynx-low.c (lynx_target_ops): Initialize new structure
6611 members.
6612 * server.c (report_fork_events, report_vfork_events):
6613 New global flags.
6614 (handle_query): Add new features to qSupported packet and
6615 response.
6616 (captured_main): Initialize new global variables.
6617 * target.h (struct target_ops) <supports_fork_events>:
6618 New member.
6619 <supports_vfork_events>: New member.
6620 (target_supports_fork_events): New macro.
6621 (target_supports_vfork_events): New macro.
6622 * win32-low.c (win32_target_ops): Initialize new structure
6623 members.
6624
835205d0
GB
66252015-05-12 Gary Benson <gbenson@redhat.com>
6626
6627 * server.c (handle_qxfer_exec_file): Use current process
6628 if annex is empty.
6629
21e94bd9
SL
66302015-05-08 Sandra Loosemore <sandra@codesourcery.com>
6631
6632 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
6633 Remove HAVE_PTRACE_GETREGS conditionals.
6634 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
6635 instead of PTRACE_GETREGS and PTRACE_SETREGS.
6636
45614f15
YQ
66372015-05-08 Yao Qi <yao.qi@linaro.org>
6638
6639 * linux-low.c (linux_supports_conditional_breakpoints): New
6640 function.
6641 (linux_target_ops): Install new target method.
6642 * lynx-low.c (lynx_target_ops): Install NULL hook for
6643 supports_conditional_breakpoints.
6644 * nto-low.c (nto_target_ops): Likewise.
6645 * spu-low.c (spu_target_ops): Likewise.
6646 * win32-low.c (win32_target_ops): Likewise.
6647 * server.c (handle_query): Check
6648 target_supports_conditional_breakpoints.
6649 * target.h (struct target_ops) <supports_conditional_breakpoints>:
6650 New field.
6651 (target_supports_conditional_breakpoints): New macro.
6652
80ad801e
PA
66532015-05-06 Pedro Alves <palves@redhat.com>
6654
6655 PR server/18081
6656 * server.c (start_inferior): If the process exits, mourn it.
6657
819843c7
GB
66582015-04-21 Gary Benson <gbenson@redhat.com>
6659
6660 * hostio.c (fileio_open_flags_to_host): Factored out to
6661 fileio_to_host_openflags in common/fileio.c. Single use
6662 updated.
6663
a2d5a9d7
MF
66642015-04-17 Max Filippov <jcmvbkbc@gmail.com>
6665
6666 * linux-xtensa-low.c (xtensa_fill_gregset)
6667 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
6668 XCHAL_HAVE_LOOP.
6669
deb44829
MF
66702015-04-17 Max Filippov <jcmvbkbc@gmail.com>
6671
6672 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
6673 (regs_info): Replace usrregs pointer with NULL.
6674
e57f1de3
GB
66752015-04-17 Gary Benson <gbenson@redhat.com>
6676
6677 * target.h (struct target_ops) <pid_to_exec_file>: New field.
6678 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
6679 * server.c (handle_qxfer_exec_file): New function.
6680 (qxfer_packets): Add exec-file entry.
6681 (handle_query): Report qXfer:exec-file:read as supported packet.
6682
62828379
RN
66832015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
6684
6685 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
6686
b88bb450
GB
66872015-04-09 Gary Benson <gbenson@redhat.com>
6688
6689 * hostio-errno.c (errno_to_fileio_error): Remove function.
6690 Update caller to use remote_fileio_to_fio_error.
6691
c8f4bfdd
YQ
66922015-04-09 Yao Qi <yao.qi@linaro.org>
6693
6694 * linux-low.c (linux_insert_point): Call
6695 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
6696 (linux_remove_point): Call remove_memory_breakpoint if type is
6697 raw_bkpt_type_sw.
6698 * linux-x86-low.c (x86_insert_point): Don't call
6699 insert_memory_breakpoint.
6700 (x86_remove_point): Don't call remove_memory_breakpoint.
6701
41f98f02
PA
67022015-04-01 Pedro Alves <palves@redhat.com>
6703 Cleber Rosa <crosa@redhat.com>
6704
6705 * server.c (gdbserver_usage): Reorganize and extend the usage
6706 message.
6707
2bf6fb9d
PA
67082015-03-24 Pedro Alves <palves@redhat.com>
6709
6710 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
6711 output. Also dump TRAP_TRACE.
6712 (linux_low_filter_event): In debug output, distinguish a
6713 resume_stop SIGSTOP from a delayed SIGSTOP.
6714
369f6daa
GB
67152015-03-24 Gary Benson <gbenson@redhat.com>
6716
6717 * linux-x86-low.c (x86_linux_new_thread): Moved to
6718 nat/x86-linux.c.
6719 (x86_linux_prepare_to_resume): Likewise.
6720
8e5d4070
GB
67212015-03-24 Gary Benson <gbenson@redhat.com>
6722
6723 * Makefile.in (x86-linux-dregs.o): New rule.
6724 * configure.srv: Add x86-linux-dregs.o to relevant targets.
6725 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
6726 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
6727 (x86_linux_dr_get): Likewise.
6728 (x86_linux_dr_set): Likewise.
6729 (update_debug_registers_callback): Likewise.
6730 (x86_linux_dr_set_addr): Likewise.
6731 (x86_linux_dr_get_addr): Likewise.
6732 (x86_linux_dr_set_control): Likewise.
6733 (x86_linux_dr_get_control): Likewise.
6734 (x86_linux_dr_get_status): Likewise.
6735 (x86_linux_update_debug_registers): Likewise.
6736
2b95d440
GB
67372015-03-24 Gary Benson <gbenson@redhat.com>
6738
6739 * linux-x86-low.c (x86_linux_update_debug_registers):
6740 New function, factored out from...
6741 (x86_linux_prepare_to_resume): ...this.
6742
14b0bc68
GB
67432015-03-24 Gary Benson <gbenson@redhat.com>
6744
6745 * linux-x86-low.c (x86_linux_dr_get): Update comments.
6746 (x86_linux_dr_set): Likewise.
6747 (update_debug_registers_callback): Likewise.
6748 (x86_linux_dr_set_addr): Likewise.
6749 (x86_linux_dr_get_addr): Likewise.
6750 (x86_linux_dr_set_control): Likewise.
6751 (x86_linux_dr_get_control): Likewise.
6752 (x86_linux_dr_get_status): Likewise.
6753 (x86_linux_prepare_to_resume): Likewise.
6754
5dfe6ca8
GB
67552015-03-24 Gary Benson <gbenson@redhat.com>
6756
6757 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
6758 Use perror_with_name. Pass string through gettext.
6759 (x86_linux_dr_set): Likewise.
6760
d33472ad
GB
67612015-03-24 Gary Benson <gbenson@redhat.com>
6762
6763 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
6764 (x86_linux_dr_set_addr): ...this.
6765 (x86_dr_low_get_addr): Rename to...
6766 (x86_linux_dr_get_addr): ...this.
6767 (x86_dr_low_set_control): Rename to...
6768 (x86_linux_dr_set_control): ...this.
6769 (x86_dr_low_get_control): Rename to...
6770 (x86_linux_dr_get_control): ...this.
6771 (x86_dr_low_get_status): Rename to...
6772 (x86_linux_dr_get_status): ...this.
6773 (x86_dr_low): Update with new function names.
6774
4b134ca1
GB
67752015-03-24 Gary Benson <gbenson@redhat.com>
6776
6777 * Makefile.in (x86-linux.o): New rule.
6778 * configure.srv: Add x86-linux.o to relevant targets.
6779 * linux-low.c (lwp_set_arch_private_info): New function.
6780 (lwp_arch_private_info): Likewise.
6781 * linux-x86-low.c: Include nat/x86-linux.h.
6782 (arch_lwp_info): Removed structure.
6783 (update_debug_registers_callback):
6784 Use lwp_set_debug_registers_changed.
6785 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
6786 and lwp_set_debug_registers_changed.
6787 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
6788
34c703da
GB
67892015-03-24 Gary Benson <gbenson@redhat.com>
6790
6791 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
6792 * linux-arm-low.c (arm_new_thread): Likewise.
6793 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
6794 * linux-mips-low.c (mips_linux_new_thread): Likewise.
6795 * linux-x86-low.c (x86_linux_new_thread): Likewise.
6796 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
6797
cff068da
GB
67982015-03-24 Gary Benson <gbenson@redhat.com>
6799
6800 * linux-low.c (ptid_of_lwp): New function.
6801 (lwp_is_stopped): Likewise.
6802 (lwp_stop_reason): Likewise.
6803 * linux-x86-low.c (update_debug_registers_callback):
6804 Use lwp_is_stopped.
6805 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
6806 lwp_stop_reason.
6807
b2f7c7e8
GB
68082015-03-24 Gary Benson <gbenson@redhat.com>
6809
6810 * linux-low.h (linux_stop_lwp): Remove declaration.
6811
6d4ee8c6
GB
68122015-03-24 Gary Benson <gbenson@redhat.com>
6813
6814 * linux-low.h: Include nat/linux-nat.h.
6815 * linux-low.c (iterate_over_lwps_args): New structure.
6816 (iterate_over_lwps_filter): New function.
6817 (iterate_over_lwps): Likewise.
6818 * linux-x86-low.c (update_debug_registers_callback):
6819 Update signature to what iterate_over_lwps expects.
6820 Remove PID check that iterate_over_lwps now performs.
6821 (x86_dr_low_set_addr): Use iterate_over_lwps.
6822 (x86_dr_low_set_control): Likewise.
6823
70a0bb6b
GB
68242015-03-24 Gary Benson <gbenson@redhat.com>
6825
6826 * linux-x86-low.c (x86_debug_reg_state): New function.
6827 (x86_linux_prepare_to_resume): Use the above.
6828
7b669087
GB
68292015-03-24 Gary Benson <gbenson@redhat.com>
6830
6831 * linux-low.c (current_lwp_ptid): New function.
6832 * linux-x86-low.c: Include nat/linux-nat.h.
6833 (x86_dr_low_get_addr): Use current_lwp_ptid.
6834 (x86_dr_low_get_control): Likewise.
6835 (x86_dr_low_get_status): Likewise.
6836
eef49a3d
PA
68372015-03-20 Pedro Alves <palves@redhat.com>
6838
6839 * tracepoint.c (cmd_qtstatus): Make "str" const.
6840
b2333d22
PA
68412015-03-20 Pedro Alves <palves@redhat.com>
6842
6843 * server.c (handle_general_set): Make "req_str" const.
6844
23f238d3
PA
68452015-03-19 Pedro Alves <palves@redhat.com>
6846
6847 * linux-low.c (linux_resume_one_lwp): Rename to ...
6848 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
6849 instead call perror_with_name.
6850 (check_ptrace_stopped_lwp_gone): New function.
6851 (linux_resume_one_lwp): Reimplement as wrapper around
6852 linux_resume_one_lwp_throw that swallows errors if the LWP is
6853 gone.
6854
91baf43f
PA
68552015-03-19 Pedro Alves <palves@redhat.com>
6856
6857 * linux-low.c (count_events_callback, select_event_lwp_callback):
6858 No longer check whether the thread has resume_stop as last resume
6859 kind.
6860
8bf3b159
PA
68612015-03-19 Pedro Alves <palves@redhat.com>
6862
6863 * linux-low.c (count_events_callback, select_event_lwp_callback):
6864 Use the lwp's status_pending_p field, not the thread's.
6865
b90fc188
PA
68662015-03-19 Pedro Alves <palves@redhat.com>
6867
6868 * linux-low.c (select_event_lwp_callback): Update comments to
6869 no longer mention SIGTRAP.
6870
464b0089
GB
68712015-03-18 Gary Benson <gbenson@redhat.com>
6872
6873 * server.c (handle_query): Do not report vFile:fstat as supported.
6874
aa9e327f
GB
68752015-03-11 Gary Benson <gbenson@redhat.com>
6876
6877 * hostio.c (sys/types.h): New include.
6878 (sys/stat.h): Likewise.
6879 (common-remote-fileio.h): Likewise.
6880 (handle_fstat): New function.
6881 (handle_vFile): Handle vFile:fstat packets.
aa9e327f 6882
791c0056
GB
68832015-03-11 Gary Benson <gbenson@redhat.com>
6884
6885 * configure.ac (AC_CHECK_MEMBERS): Add checks for
6886 struct stat.st_blocks and struct stat.st_blksize.
6887 * configure: Regenerate.
6888 * config.in: Likewise.
6889 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
6890 (OBS): Add common-remote-fileio.o.
6891 (common-remote-fileio.o): New rule.
6892
9a9df970
PA
68932015-03-09 Pedro Alves <palves@redhat.com>
6894
6895 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
6896 'struct sockaddr' pointer in 'accept' call.
6897
9eb1356e
PA
68982015-03-09 Pedro Alves <palves@redhat.com>
6899
6900 Revert:
6901 2015-03-07 Pedro Alves <palves@redhat.com>
6902 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
6903 or <winsock2.h> here. Instead include "gdb_socket.h".
6904 (remote_open): Use union gdb_sockaddr_u.
6905 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
6906 or <winsock2.h> here. Instead include "gdb_socket.h".
6907 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
6908 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
6909 or <sys/un.h>.
6910 (init_named_socket, gdb_agent_helper_thread): Use union
6911 gdb_sockaddr_u.
6912
aac331e4
PA
69132015-03-07 Pedro Alves <palves@redhat.com>
6914
6915 * configure.ac (build_warnings): Move
6916 -Wdeclaration-after-statement to the C-specific set.
6917 * configure: Regenerate.
6918
366c75fc
PA
69192015-03-07 Pedro Alves <palves@redhat.com>
6920
6921 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
6922 or <winsock2.h> here. Instead include "gdb_socket.h".
6923 (remote_open): Use union gdb_sockaddr_u.
6924 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
6925 or <winsock2.h> here. Instead include "gdb_socket.h".
6926 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
6927 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
6928 or <sys/un.h>.
6929 (init_named_socket, gdb_agent_helper_thread): Use union
6930 gdb_sockaddr_u.
6931
492d29ea
PA
69322015-03-07 Pedro Alves <palves@redhat.com>
6933
6934 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
6935 instead.
6936
60a191ed
YQ
69372015-03-06 Yao Qi <yao.qi@linaro.org>
6938
6939 * linux-aarch64-low.c (aarch64_insert_point): Use
6940 show_debug_regs as a boolean.
6941 (aarch64_remove_point): Likewise.
6942
f5771b1d
PA
69432015-03-05 Pedro Alves <palves@redhat.com>
6944
6945 * lynx-low.c (lynx_target_ops): Install NULL hooks for
6946 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
6947 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
6948 * nto-low.c (nto_target_ops): Likewise.
6949 * spu-low.c (spu_target_ops): Likewise.
6950 * win32-low.c (win32_target_ops): Likewise.
6951
3e572f71
PA
69522015-03-04 Pedro Alves <palves@redhat.com>
6953
72f4393d 6954 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
3e572f71
PA
6955 Decide whether a breakpoint triggered based on the SIGTRAP's
6956 siginfo.si_code.
72f4393d
L
6957 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
6958 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
3e572f71
PA
6959 (linux_low_filter_event): Check for breakpoints before checking
6960 watchpoints.
6961 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
6962 siginfo.si_code.
72f4393d
L
6963 (linux_stopped_by_sw_breakpoint)
6964 (linux_supports_stopped_by_sw_breakpoint)
6965 (linux_stopped_by_hw_breakpoint)
6966 (linux_supports_stopped_by_hw_breakpoint): New functions.
6967 (linux_target_ops): Install new target methods.
3e572f71 6968
1ec68e26
PA
69692015-03-04 Pedro Alves <palves@redhat.com>
6970
6971 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
6972 * server.c (swbreak_feature, hwbreak_feature): New globals.
6973 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
6974 (captured_main): Clear swbreak_feature and hwbreak_feature.
6975 * server.h (swbreak_feature, hwbreak_feature): Declare.
6976 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
6977 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
6978 supports_stopped_by_hw_breakpoint>: New fields.
6979 (target_supports_stopped_by_sw_breakpoint)
6980 (target_stopped_by_sw_breakpoint)
6981 (target_supports_stopped_by_hw_breakpoint)
6982 (target_stopped_by_hw_breakpoint): Declare.
6983
15c66dd6
PA
69842015-03-04 Pedro Alves <palves@redhat.com>
6985
6986 enum lwp_stop_reason -> enum target_stop_reason
6987 * linux-low.c (check_stopped_by_breakpoint): Adjust.
6988 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
6989 (linux_wait_1, stuck_in_jump_pad_callback)
6990 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
6991 (linux_stopped_by_watchpoint):
6992 * linux-low.h (enum lwp_stop_reason): Delete.
6993 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
6994 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
6995
98fc70d6
YQ
69962015-03-04 Yao Qi <yao.qi@linaro.org>
6997
6998 * Makefile.in (SFILES): Add linux-aarch64-low.c.
6999
dd2ac174
GB
70002015-03-03 Gary Benson <gbenson@redhat.com>
7001
7002 * hostio.c (handle_vFile): Fix prefix lengths.
7003
d68e53f4
MM
70042015-03-03 Markus Metzger <markus.t.metzger@intel.com>
7005
7006 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
7007 ptr_bits.
7008
bf2d68ab
AA
70092015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
7010
7011 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
7012 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
7013 (clean): Add "rm -f" for above C files.
7014 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
7015 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
7016 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
7017 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
7018 * linux-s390-low.c (HWCAP_S390_VX): New macro.
7019 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
7020 (init_registers_s390x_vx_linux64)
7021 (init_registers_s390x_tevx_linux64)
7022 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
7023 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
7024 declarations.
7025 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
7026 (s390_store_vxrs_high): New functions.
7027 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
7028 NT_S390_VXRS_HIGH.
7029 (s390_arch_setup): Add logic for selecting one of the new target
7030 descriptions. Activate the new vector regsets if applicable.
7031 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
7032 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
7033 and init_registers_s390x_tevx_linux64.
7034
c966a859
PA
70352015-03-01 Pedro Alves <palves@redhat.com>
7036
7037 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
7038 parameter.
7039
4180215b
PA
70402015-02-27 Pedro Alves <palves@redhat.com>
7041
7042 * linux-x86-low.c (u_debugreg_offset): New function.
7043 (x86_linux_dr_get, x86_linux_dr_set): Use it.
7044
749bab01
PA
70452015-02-27 Pedro Alves <palves@redhat.com>
7046
7047 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
7048 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
7049 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
7050 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
7051 (ps_lsetfpregs, ps_getpid)
7052 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
7053 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
7054 (ps_lsetxregs, ps_plog): Declare.
7055
3c14e5a3
PA
70562015-02-27 Pedro Alves <palves@redhat.com>
7057
7058 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
7059 IP_AGENT_EXPORT_FUNC.
7060 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
7061 IP_AGENT_EXPORT_FUNC.
7062 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
7063 (IP_AGENT_EXPORT): Delete.
7064 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
7065 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
7066 (gdb_trampoline_buffer_error, collecting, gdb_collect)
7067 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
7068 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
7069 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
7070 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
7071 (traceframe_read_count, traceframe_write_count)
7072 (traceframes_created, trace_state_variables, get_raw_reg)
7073 (get_trace_state_variable_value, set_trace_state_variable_value)
7074 (ust_loaded, helper_thread_id, cmd_buf): Use
7075 IPA_SYM_EXPORTED_NAME.
7076 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
7077 (tracepoints) Use IP_AGENT_EXPORT_VAR.
7078 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
7079 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
7080 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
7081 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
7082 EXTERN_C_PUSH/EXTERN_C_POP.
7083 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
7084 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
7085 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
7086 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
7087 (traceframe_write_count, traceframe_read_count)
7088 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
7089 (about_to_request_buffer_space, get_trace_state_variable_value)
7090 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
7091 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
7092 EXTERN_C_PUSH/EXTERN_C_POP.
7093 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
7094 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
7095 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
7096 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
7097 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
7098 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
7099 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
7100 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
7101 Define.
7102 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
7103 (IP_AGENT_EXPORT_VAR_DECL): Define.
7104 (tracing): Declare.
7105 (gdb_agent_get_raw_reg): Declare.
7106
fe978cb0
PA
71072015-02-27 Tom Tromey <tromey@redhat.com>
7108 Pedro Alves <palves@redhat.com>
7109
7110 Rename symbols whose names are reserved C++ keywords throughout.
7111
3bc3d82a
PA
71122015-02-27 Pedro Alves <palves@redhat.com>
7113
7114 * Makefile.in (COMPILER): New, get it from autoconf.
7115 (CXX): Get from autoconf instead.
7116 (COMPILE.pre): Use COMPILER.
7117 (CC-LD): Rename to ...
7118 (CC_LD): ... this. Use COMPILER.
7119 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
7120 (CXX_FOR_TARGET): Default to g++ instead of gcc.
7121 * acinclude.m4: Include build-with-cxx.m4.
7122 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
7123 Disable -Werror by default if building in C++ mode.
7124 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
7125 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
7126 the C++ compiler. Save/restore CXXFLAGS too.
7127 * configure: Regenerate.
7128
07697489
PA
71292015-02-27 Pedro Alves <palves@redhat.com>
7130
7131 * acinclude.m4: Include libiberty.m4.
7132 * configure.ac: Call libiberty_INIT.
7133 * config.in, configure: Regenerate.
7134
9beb7c4e
PA
71352015-02-26 Pedro Alves <palves@redhat.com>
7136
7137 * linux-low.c (linux_wait_1): When incrementing the PC past a
7138 program breakpoint always use the_low_target.breakpoint_len as
7139 increment, rather than the maximum between that and
7140 the_low_target.decr_pc_after_break.
7141
8090aef2
PA
71422015-02-23 Pedro Alves <palves@redhat.com>
7143
7144 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
7145 thread was doing a step-over; always adjust the PC if
7146 we stepped over a permanent breakpoint.
7147 (linux_wait_1): If we stepped over breakpoint that was on top of a
7148 permanent breakpoint, manually advance the PC past it.
7149
bc9540e8
PA
71502015-02-23 Pedro Alves <palves@redhat.com>
7151
7152 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
7153 modes.
7154 (x86_fill_gregset, x86_store_gregset): Use it when handling
7155 $orig_eax.
7156
2db9a427
PA
71572015-02-20 Pedro Alves <palves@redhat.com>
7158
7159 * thread-db.c: Include "nat/linux-procfs.h".
7160 (thread_db_init): Skip listing new threads if the kernel supports
7161 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
7162
afa8d396
PA
71632015-02-20 Pedro Alves <palves@redhat.com>
7164
7165 * linux-low.c (status_pending_p_callback): Use ptid_match.
7166
c9587f88
AT
71672015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
7168
7169 PR breakpoints/16812
7170 * linux-low.c (wstatus_maybe_breakpoint): Remove.
7171 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
7172 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
7173
b05ec7a5
AT
71742015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
7175
7176 PR breakpoints/15956
7177 * tracepoint.c (cmd_qtinit): Add check for current_thread.
7178
d33501a5
MM
71792015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7180
7181 * linux-low.c (linux_low_btrace_conf): Print size.
7182 * server.c (handle_btrace_conf_general_set): New.
7183 (hanle_general_set): Call handle_btrace_conf_general_set.
7184 (handle_query): Report Qbtrace-conf:bts:size as supported.
7185
f4abbc16
MM
71862015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7187
7188 * linux-low.c (linux_low_enable_btrace): Update parameters.
7189 (linux_low_btrace_conf): New.
7190 (linux_target_ops)<to_btrace_conf>: Initialize.
7191 * server.c (current_btrace_conf): New.
7192 (handle_btrace_enable): Rename to ...
7193 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
7194 to target_enable_btrace. Update comment. Update users.
7195 (handle_qxfer_btrace_conf): New.
7196 (qxfer_packets): Add btrace-conf entry.
7197 (handle_query): Report qXfer:btrace-conf:read as supported packet.
7198 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
7199 (target_ops)<read_btrace_conf>: New.
7200 (target_enable_btrace): Update parameters.
7201 (target_read_btrace_conf): New.
7202
043c3577
MM
72032015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7204
7205 * server.c (handle_btrace_general_set): Remove call to
7206 target_supports_btrace.
7207 (supported_btrace_packets): New.
7208 (handle_query): Call supported_btrace_packets.
7209 * target.h: include btrace-common.h.
7210 (btrace_target_info): Removed.
7211 (supports_btrace, target_supports_btrace): Update parameters.
7212
734b0e4b
MM
72132015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7214
7215 * Makefile.in (SFILES): Add common/btrace-common.c.
7216 (OBS): Add common/btrace-common.o.
7217 (btrace-common.o): Add build rules.
7218 * linux-low: Include btrace-common.h.
7219 (linux_low_read_btrace): Use struct btrace_data. Call
7220 btrace_data_init and btrace_data_fini.
7221
d6c146e9
PA
72222015-02-06 Pedro Alves <palves@redhat.com>
7223
7224 * thread-db.c (find_new_threads_callback): Add debug output.
7225
20ba1ce6
PA
72262015-02-04 Pedro Alves <palves@redhat.com>
7227
7228 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
7229 (resume_stopped_resumed_lwps): New function.
7230 (linux_wait_for_event_filtered): Use it.
7231
8cc73a39
SDJ
72322015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
7233
7234 * Makefile.in (SFILES): Add linux-personality.c.
7235 (linux-personality.o): New rule.
7236 * configure.srv (srv_linux_obj): Add linux-personality.o to the
7237 list of objects to be built.
7238 * linux-low.c: Include nat/linux-personality.h.
7239 (linux_create_inferior): Remove code to disable address space
7240 randomization (moved to ../nat/linux-personality.c). Create
7241 cleanup to disable address space randomization.
7242
fb23d554
SDJ
72432015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
7244
7245 * Makefile.in (posix-strerror.o): New rule.
7246 (mingw-strerror.o): Likewise.
7247 * configure: Regenerated.
7248 * configure.ac: Source file ../common/common.host. Initialize new
7249 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
7250
cdf43629
YQ
72512015-01-14 Yao Qi <yao@codesourcery.com>
7252
7253 * Makefile.in (SFILES): Add nat/ppc-linux.c.
7254 (ppc-linux.o): New rule.
7255 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
7256 * configure.ac: AC_CHECK_FUNCS(getauxval).
7257 * config.in: Re-generated.
7258 * configure: Re-generated.
7259 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
7260 ppc64_64bit_inferior_p
7261
514c5338
YQ
72622015-01-14 Yao Qi <yao@codesourcery.com>
7263
7264 * linux-ppc-low.c: Include "nat/ppc-linux.h".
7265 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
7266 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
7267 (PT_ORIG_R3, PT_TRAP): Likewise.
7268 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
7269 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
7270 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
7271
3368c1e5
JB
72722015-01-10 Joel Brobecker <brobecker@adacore.com>
7273
7274 * i387-fp.c (i387_cache_to_xsave): In look over
7275 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
7276 zmmh_low_space field by use of zmmh_high_space.
7277
582511be
PA
72782015-01-09 Pedro Alves <palves@redhat.com>
7279
7280 * linux-low.c (step_over_bkpt): Move higher up in the file.
7281 (handle_extended_wait): Don't store the stop_pc here.
7282 (get_stop_pc): Adjust comments and rename to ...
7283 (check_stopped_by_breakpoint): ... this. Record whether the LWP
7284 stopped for a software breakpoint or hardware breakpoint.
7285 (thread_still_has_status_pending_p): New function.
7286 (status_pending_p_callback): Use
7287 thread_still_has_status_pending_p. If the event is no longer
7288 interesting, resume the LWP.
7289 (handle_tracepoints): Add assert.
7290 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
7291 (wstatus_maybe_breakpoint): New function.
7292 (cancel_breakpoint): Delete function.
7293 (check_stopped_by_watchpoint): New function, factored out from
7294 linux_low_filter_event.
7295 (lp_status_maybe_breakpoint): Delete function.
7296 (linux_low_filter_event): Remove filter_ptid argument.
7297 Leave thread group exits pending here. Store the LWP's stop PC.
7298 Always leave events pending.
7299 (linux_wait_for_event_filtered): Pull all events out of the
7300 kernel, and leave them all pending.
7301 (count_events_callback, select_event_lwp_callback): Consider all
7302 events.
7303 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
7304 (select_event_lwp): Only give preference to the stepping LWP in
7305 all-stop mode. Adjust comments.
7306 (ignore_event): New function.
7307 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
7308 references to cancel_breakpoints. Adjust to renames. Also give
7309 equal priority to all LWPs that have had events in non-stop mode.
7310 If reporting a software breakpoint event, unadjust the LWP's PC.
7311 (linux_wait): If linux_wait_1 returned an ignored event, retry.
7312 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
7313 Adjust.
7314 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
7315 (resume_status_pending_p): Use thread_still_has_status_pending_p.
7316 (linux_stopped_by_watchpoint): Adjust.
7317 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
7318 * linux-low.h (enum lwp_stop_reason): New.
7319 (struct lwp_info) <stop_pc>: Adjust comment.
7320 <stopped_by_watchpoint>: Delete field.
7321 <stop_reason>: New field.
7322 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
7323 * mem-break.c (software_breakpoint_inserted_here)
7324 (hardware_breakpoint_inserted_here): New function.
7325 * mem-break.h (software_breakpoint_inserted_here)
7326 (hardware_breakpoint_inserted_here): Declare.
7327 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
7328 (cancel_breakpoints): Delete.
7329 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
7330 (upload_fast_traceframes): Remove references to
7331 cancel_breakpoints.
7332
a33e3959
PA
73332015-01-09 Pedro Alves <palves@redhat.com>
7334
7335 * thread-db.c (find_new_threads_callback): Ignore thread if the
7336 kernel thread ID is -1.
7337
8784d563
PA
73382015-01-09 Pedro Alves <palves@redhat.com>
7339
7340 * linux-low.c (linux_attach_fail_reason_string): Move to
7341 nat/linux-ptrace.c, and rename.
7342 (linux_attach_lwp): Update comment.
7343 (attach_proc_task_lwp_callback): New function.
7344 (linux_attach): Adjust to rename and use
7345 linux_proc_attach_tgid_threads.
7346 (linux_attach_fail_reason_string): Delete declaration.
7347
76f2b779
JB
73482015-01-01 Joel Brobecker <brobecker@adacore.com>
7349
7350 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
7351 * server.c (gdbserver_version): Likewise.
7352
fafcc06a
SDJ
73532014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
7354
7355 * remote-utils.c: Include ctype.h.
7356 (input_interrupt): Explicitly handle the case when the char
7357 received is the NUL byte. Improve the printing of non-ASCII
7358 characters.
7359
beed38b8
JB
73602014-12-16 Joel Brobecker <brobecker@adacore.com>
7361
7362 * linux-low.c (linux_low_filter_event): Update call to
7363 linux_enable_event_reporting following the addition of
7364 a new parameter to that function.
7365
bf330350
CU
73662014-12-16 Catalin Udma <catalin.udma@freescale.com>
7367
7368 PR server/17457
7369 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
7370 (AARCH64_FPCR_REGNO): Likewise.
7371 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
7372 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
7373 (aarch64_store_fpregset): Likewise.
7374
5227d625
JB
73752014-12-15 Joel Brobecker <brobecker@adacore.com>
7376
7377 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
7378 Remove FIXME comment about assumption about N.
7379
f93b65a0
JB
73802014-12-13 Joel Brobecker <brobecker@adacore.com>
7381
7382 * configure.ac: If large-file support is disabled in GDBserver,
7383 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
7384 * configure: Regenerate.
7385
e5a9158d
AA
73862014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7387
7388 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
7389 warning upon ENODATA from ptrace.
7390 * linux-s390-low.c (s390_store_tdb): New.
7391 (s390_regsets): Add regset for NT_S390_TDB.
7392
feea5f36
AA
73932014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7394
7395 * linux-low.c (regsets_store_inferior_registers): Skip regsets
7396 without a fill_function.
7397 * linux-s390-low.c (s390_fill_last_break): Remove.
7398 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
7399 (s390_arch_setup): Use regset's size instead of fill_function for
7400 loop end condition.
7401
098dbe61
AA
74022014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7403
7404 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
7405 the regset's store function when ptrace returned an error.
7406 * regcache.c (get_thread_regcache): Invalidate register cache
7407 before fetching inferior's registers.
7408
28eef672
AA
74092014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7410
7411 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
7412 while-loop as for-loop.
7413 (regsets_store_inferior_registers): Likewise.
7414
bdca27a2
YQ
74152014-11-28 Yao Qi <yao@codesourcery.com>
7416
7417 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
7418 * config.in, configure: Re-generate.
7419 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
7420 is defined.
7421
9c232dda
YQ
74222014-11-21 Yao Qi <yao@codesourcery.com>
7423
7424 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
7425 (AC_CHECK_HEADERS): Remove malloc.h.
7426 * configure: Re-generated.
7427 * config.in: Re-generated.
7428 * server.h: Don't include alloca.h and malloc.h.
7429 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
7430 Don't include malloc.h.
7431
43968415
JB
74322014-11-17 Joel Brobecker <brobecker@adacore.com>
7433
7434 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
7435 corresponding ERRNO check in same block.
7436
40e91bc7
PA
74372014-11-12 Pedro Alves <palves@redhat.com>
7438
7439 * server.c (cont_thread): Update comment.
7440 (start_inferior, attach_inferior): No longer clear cont_thread.
7441 (handle_v_cont): No longer set cont_thread.
7442 (captured_main): Clear cont_thread each time a GDB connects.
7443
c2c118cf
PA
74442014-11-12 Pedro Alves <palves@redhat.com>
7445
7446 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
7447 thread, and don't resume all threads if the Hc thread has exited.
7448
78708b7c
PA
74492014-11-12 Pedro Alves <palves@redhat.com>
7450
7451 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
7452 the process group instead of to a specific LWP.
7453
a2abc7de
PA
74542014-10-15 Pedro Alves <palves@redhat.com>
7455
7456 PR server/17487
7457 * win32-arm-low.c (arm_set_thread_context): Remove current_event
7458 parameter.
7459 (arm_set_thread_context): Delete.
7460 (the_low_target): Adjust.
7461 * win32-i386-low.c (debug_registers_changed)
7462 (debug_registers_used): Delete.
7463 (update_debug_registers_callback): New function.
7464 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
7465 needing to update their debug registers.
7466 (win32_get_current_dr): New function.
7467 (x86_dr_low_get_addr, x86_dr_low_get_control)
7468 (x86_dr_low_get_status): Fetch the debug register from the thread
7469 record's context.
7470 (i386_initial_stuff): Adjust.
7471 (i386_get_thread_context): Remove current_event parameter. Don't
7472 clear debug_registers_changed nor copy DR values to
7473 debug_reg_state.
7474 (i386_set_thread_context): Delete.
7475 (i386_prepare_to_resume): New function.
7476 (i386_thread_added): Mark the thread as needing to update irs
7477 debug registers.
7478 (the_low_target): Remove i386_set_thread_context and install
7479 i386_prepare_to_resume.
7480 * win32-low.c (win32_get_thread_context): Adjust.
7481 (win32_set_thread_context): Use SetThreadContext
7482 directly.
7483 (win32_prepare_to_resume): New function.
7484 (win32_require_context): New function, factored out from ...
7485 (thread_rec): ... this.
7486 (continue_one_thread): Call win32_prepare_to_resume on each thread
7487 we're about to continue.
7488 (win32_resume): Call win32_prepare_to_resume on the event thread.
7489 * win32-low.h (struct win32_thread_info)
7490 <debug_registers_changed>: New field.
7491 (struct win32_target_ops): Change prototype of set_thread_context,
7492 delete set_thread_context and add prepare_to_resume.
7493 (win32_require_context): New declaration.
7494
a442d071
GB
74952014-10-08 Gary Benson <gbenson@redhat.com>
7496
7497 * server.h: Do not include common-exceptions.h.
7498
6f1947e8
GB
74992014-10-08 Gary Benson <gbenson@redhat.com>
7500
7501 * server.h: Do not include cleanups.h.
7502
63b434a4
JH
75032014-09-30 James Hogan <james.hogan@imgtec.com>
7504
7505 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
7506 mips64-dsp-linux.c.
7507
c4d9ceb6
YQ
75082014-09-23 Yao Qi <yao@codesourcery.com>
7509
7510 * linux-low.c (lp_status_maybe_breakpoint): New function.
7511 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
7512 (count_events_callback): Likewise.
7513 (select_event_lwp_callback): Likewise.
7514 (cancel_breakpoints_callback): Likewise.
7515
89a5711c
DB
75162014-09-19 Don Breazeal <donb@codesourcery.com>
7517
7518 * linux-low.c (handle_extended_wait): Call
7519 linux_ptrace_get_extended_event.
7520 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
7521 linux_is_extended_waitstatus.
7522
bffc0964
JB
75232014-09-16 Joel Brobecker <brobecker@adacore.com>
7524
7525 * Makefile.in (CPPFLAGS): Define.
7526 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
7527 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
7528
0bfdf32f
GB
75292014-09-16 Gary Benson <gbenson@redhat.com>
7530
7531 * inferiors.h (current_inferior): Renamed as...
7532 (current_thread): New variable. All uses updated.
7533 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
7534 (maybe_move_out_of_jump_pad): Likewise.
7535 (cancel_breakpoint): Likewise.
7536 (linux_low_filter_event): Likewise.
7537 (wait_for_sigstop): Likewise.
7538 (linux_resume_one_lwp): Likewise.
7539 (need_step_over_p): Likewise.
7540 (start_step_over): Likewise.
7541 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
7542 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
7543 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
7544 and save_inferior as saved_thread.
7545 * regcache.c (get_thread_regcache): Renamed saved_inferior as
7546 saved_thread.
7547 (regcache_invalidate_thread): Likewise.
7548 * remote-utils.c (prepare_resume_reply): Likewise.
7549 * thread-db.c (thread_db_get_tls_address): Likewise.
7550 (disable_thread_event_reporting): Likewise.
7551 (remove_thread_event_breakpoints): Likewise.
7552 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
7553 as saved_thread.
7554 * target.h (set_desired_inferior): Renamed as...
7555 (set_desired_thread): New declaration. All uses updated.
7556 * server.c (myresume): Updated comment to reference thread instead
7557 of inferior.
7558 (handle_serial_event): Likewise.
7559 (handle_target_event): Likewise.
7560
361c8ade
GB
75612014-09-12 Tom Tromey <tromey@redhat.com>
7562 Gary Benson <gbenson@redhat.com>
7563
7564 * regcache.h: Include common-regcache.h.
7565 (regcache_read_pc): Don't declare.
7566 * regcache.c (get_thread_regcache_for_ptid): New function.
7567
bd9269f7
GB
75682014-09-11 Tom Tromey <tromey@redhat.com>
7569 Gary Benson <gbenson@redhat.com>
7570
7571 * symbol.c: New file.
7572 * Makefile.in (SFILES): Add symbol.c.
7573 (OBS): Add symbol.o.
7574
f8c1d06b
GB
75752014-09-11 Gary Benson <gbenson@redhat.com>
7576
7577 * target.c (target_stop_ptid, target_continue_ptid): New
7578 functions.
7579
721ec300
GB
75802014-09-11 Tom Tromey <tromey@redhat.com>
7581 Gary Benson <gbenson@redhat.com>
7582
7583 * target.h: Include target/target.h.
7584 * target.c (target_read_memory, target_read_uint32)
7585 (target_write_memory): New functions.
7586
c5e92cca
GB
75872014-09-11 Gary Benson <gbenson@redhat.com>
7588
7589 * server.h (debug_hw_points): Don't declare.
7590 * server.c (debug_hw_points): Don't define. Replace all uses
7591 with show_debug_regs.
7592 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
7593 all uses with show_debug_regs.
7594
2e4bb98a
EBM
75952014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
7596
7597 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
7598 endianness into account.
7599 (ppc_supply_ptrace_register): Likewise.
7600
ac740bc7
JH
76012014-09-03 James Hogan <james.hogan@imgtec.com>
7602
7603 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
7604 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
7605
97ea6506
GB
76062014-09-03 Gary Benson <gbenson@redhat.com>
7607
7608 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
7609 ALL_DEBUG_ADDRESS_REGISTERS.
7610
df7e5265
GB
76112014-09-02 Gary Benson <gbenson@redhat.com>
7612
7613 * i386-low.h: Renamed as...
7614 * x86-low.h: New file. All type, function and variable name
7615 prefixes changed from "i386_" to "x86_". All references updated.
7616 * i386-low.c: Renamed as...
7617 * x86-low.c: New file. All type, function and variable name
7618 prefixes changed from "i386_" to "x86_". All references updated.
7619
ed859da7
GB
76202014-09-02 Gary Benson <gbenson@redhat.com>
7621
7622 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
7623 (x86_linux_new_thread): Likewise.
7624
860789c7
GB
76252014-08-29 Gary Benson <gbenson@redhat.com>
7626
7627 * server.h (setjmp.h): Do not include.
7628 (toplevel): Do not declare.
7629 (common-exceptions.h): Include.
7630 (cleanups.h): Likewise.
7631 * server.c (toplevel): Do not define.
7632 (exit_code): New static global.
7633 (detach_or_kill_for_exit_cleanup): New function.
7634 (main): New function. Original main renamed to...
7635 (captured_main): New function.
7636 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
7637
ff55e1b5
GB
76382014-08-29 Gary Benson <gbenson@redhat.com>
7639
7640 * Makefile.in (SFILES): Add common/common-exceptions.c.
7641 (OBS): Add common-exceptions.o.
7642 (common-exceptions.o): New rule.
7643 * utils.c (prepare_to_throw_exception): New function.
7644
e9bcb658
GB
76452014-08-29 Gary Benson <gbenson@redhat.com>
7646
7647 * config.in: Regenerate.
7648 * configure: Likewise.
7649
e3180625
GB
76502014-08-29 Gary Benson <gbenson@redhat.com>
7651
7652 * Makefile.in (SFILES): Add common/cleanups.c.
7653 (OBS): cleanups.o.
7654 (cleanups.o): New rule.
7655
e3d6ba5d
GB
76562014-08-29 Gary Benson <gbenson@redhat.com>
7657
7658 * utils.c (internal_vwarning): New function.
7659
7096e886
GB
76602014-08-28 Gary Benson <gbenson@redhat.com>
7661
7662 * utils.h (fatal): Remove declaration.
7663 * utils.c (fatal): Remove function.
7664
14ce3192
GB
76652014-08-28 Gary Benson <gbenson@redhat.com>
7666
7667 * tracepoint.c (gdb_agent_init): Replace fatal with
7668 perror_with_name.
7669 (initialize_tracepoint): Likewise.
7670
50278d59
GB
76712014-08-28 Gary Benson <gbenson@redhat.com>
7672
7673 * remote-utils.c (remote_prepare): Replace fatal with error.
7674
aa96c426
GB
76752014-08-28 Gary Benson <gbenson@redhat.com>
7676
7677 * linux-low.c (linux_async): Replace fatal with warning.
7678 Tidy up and return.
7679 (linux_start_non_stop): Return -1 if linux_async failed.
7680
f7160e97
GB
76812014-08-28 Gary Benson <gbenson@redhat.com>
7682
7683 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
7684 gdb_assert.
7685 (i386_dr_low_get_addr): Remove vague comment.
7686 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
7687 gdb_assert.
7688
38e08fca
GB
76892014-08-28 Gary Benson <gbenson@redhat.com>
7690
7691 * inferiors.c (get_thread_process): Replace check with gdb_assert.
7692 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
7693 internal_error.
7694 (linux_resume_one_lwp): Likewise.
7695 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
7696 gdb_assert.
7697 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
7698 with internal_error.
7699 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
7700 (init_register_cache): Replace fatal with gdb_assert_not_reached.
7701 (find_register_by_name): Replace fatal with internal_error.
7702 (find_regno): Likewise.
7703 * tdesc.c (init_target_desc): Replace check with gdb_assert.
7704 * thread-db.c (thread_db_create_event): Likewise.
7705 (thread_db_load_search): Likewise.
7706 (try_thread_db_load_1): Likewise.
7707 * tracepoint.c (get_jump_space_head): Replace fatal with
7708 internal_error.
7709 (claim_trampoline_space): Likewise.
7710 (have_fast_tracepoint_trampoline_buffer): Likewise.
7711 (cmd_qtstart): Likewise.
7712 (stop_tracing): Likewise.
7713 (fast_tracepoint_collecting): Likewise.
7714 (target_malloc): Likewise.
7715 (download_tracepoint): Likewise.
7716 (download_trace_state_variables): Replace check with gdb_assert.
7717 (upload_fast_traceframes): Replace fatal with internal_error.
7718
34abf635
GB
77192014-08-19 Tom Tromey <tromey@redhat.com>
7720 Gary Benson <gbenson@redhat.com>
7721
7722 * Makefile.in (SFILES): Add common/common-debug.c.
7723 (OBS): Add common-debug.o.
7724 (common-debug.o): New rule.
7725 * debug.h (debug_printf): Don't declare.
7726 * debug.c (debug_printf): Renamed and rewritten as...
7727 (debug_vprintf): New function.
7728
f6e94d78
GB
77292014-08-19 Gary Benson <gbenson@redhat.com>
7730
7731 * utils.h: Do not include print-utils.h.
7732
9239eeab
GB
77332014-08-19 Tom Tromey <tromey@redhat.com>
7734 Gary Benson <gbenson@redhat.com>
7735
7736 * server.h: Add static assertion.
7737 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
7738
ef87c8bb
GB
77392014-08-19 Tom Tromey <tromey@redhat.com>
7740 Gary Benson <gbenson@redhat.com>
7741
7742 * Makefile.in (SFILES): Add common/errors.c.
7743 (OBS): Add errors.o.
7744 (IPA_OBS): Add errors-ipa.o.
7745 (errors.o): New rule.
7746 (errors-ipa.o): Likewise.
7747 * utils.h (perror_with_name, error, warning): Don't declare.
7748 * utils.c (warning): Renamed and rewritten as...
7749 (vwarning): New function.
7750 (error): Renamed and rewritten as...
7751 (verror): New function.
7752 (internal_error): Renamed and rewritten as...
7753 (internal_verror): New function.
7754
bb974a24
GB
77552014-08-07 Gary Benson <gbenson@redhat.com>
7756
7757 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
7758 * configure: Regenerate.
7759 * config.in: Likewise.
7760 * server.h: Do not include errno.h.
7761 * event-loop.c: Likewise.
7762 * hostio-errno.c: Likewise.
7763 * linux-low.c: Likewise.
7764 * remote-utils.c: Likewise.
7765 * spu-low.c: Likewise.
7766 * utils.c: Likewise.
7767 * gdbreplay.c: Unconditionally include errno.h.
7768
6d3d12eb
GB
77692014-08-07 Gary Benson <gbenson@redhat.com>
7770
7771 * server.h: Do not include string.h.
7772 * event-loop.c: Likewise.
7773 * linux-low.c: Likewise.
7774 * regcache.c: Likewise.
7775 * remote-utils.c: Likewise.
7776 * spu-low.c: Likewise.
7777 * utils.c: Likewise.
7778
dccbb609
GB
77792014-08-07 Gary Benson <gbenson@redhat.com>
7780
7781 * server.h: Do not include gdb_assert.h.
7782
e76df0d0
GB
77832014-08-07 Gary Benson <gbenson@redhat.com>
7784
7785 * server.h: Do not include common-utils.h.
7786
4cb9c816
GB
77872014-08-07 Gary Benson <gbenson@redhat.com>
7788
7789 * server.h: Do not include ptid.h.
7790 * notif.h: Likewise.
7791
3995eeee
GB
77922014-08-07 Gary Benson <gbenson@redhat.com>
7793
7794 * server.h: Do not include gdb_locale.h.
7795
cb9f1a9b
GB
77962014-08-07 Gary Benson <gbenson@redhat.com>
7797
7798 * server.h: Do not include gdb/signals.h.
7799 * win32-low.c: Likewise.
7800
a5fceff8
GB
78012014-08-07 Gary Benson <gbenson@redhat.com>
7802
7803 * server.h: Do not include pathmax.h.
7804
b9391142
GB
78052014-08-07 Gary Benson <gbenson@redhat.com>
7806
7807 * server.h: Do not include libiberty.h.
7808 * linux-bfin-low.c: Likewise.
7809
0e443c87
GB
78102014-08-07 Gary Benson <gbenson@redhat.com>
7811
7812 * server.h: Do not include ansidecl.h.
7813
8ebb3f56
GB
78142014-08-07 Gary Benson <gbenson@redhat.com>
7815
7816 * linux-x86-low.c: Do not include stddef.h.
7817 * lynx-ppc-low.c: Likewise.
7818 * tracepoint.c: Likewise.
7819
8980bdf6
GB
78202014-08-07 Gary Benson <gbenson@redhat.com>
7821
7822 * server.h: Do not include stdarg.h.
7823 * nto-low.c: Likewise.
7824
d7096f71
GB
78252014-08-07 Gary Benson <gbenson@redhat.com>
7826
7827 * server.h: Do not include stdlib.h.
7828 * inferiors.c: Likewise.
7829 * linux-low.c: Likewise.
7830 * regcache.c: Likewise.
7831 * spu-low.c: Likewise.
7832 * tracepoint.c: Likewise.
7833 * utils.c: Likewise.
7834
d02f550d
GB
78352014-08-07 Gary Benson <gbenson@redhat.com>
7836
7837 * server.h: Do not include stdio.h.
7838 * linux-low.c: Likewise.
7839 * remote-utils.c: Likewise.
7840 * spu-low.c: Likewise.
7841 * utils.c: Likewise.
7842 * wincecompat.c: Likewise.
7843
87f6c4e3
GB
78442014-08-06 Gary Benson <gbenson@redhat.com>
7845
7846 * regcache.c (init_register_cache): Move conditionals inside if.
7847
7089dca4
GB
78482014-08-06 Gary Benson <gbenson@redhat.com>
7849
7850 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
7851
462f517e
GB
78522014-07-31 Gary Benson <gbenson@redhat.com>
7853
7854 * ax.h: Do not include server.h.
7855 * gdbthread.h: Likewise.
7856 * lynx-low.h: Likewise.
7857 * notif.h: Likewise.
7858
976411d6
GB
78592014-07-30 Gary Benson <gbenson@redhat.com>
7860
7861 * server.h: Include common-defs.h.
7862 Do not include config.h or build-gnulib-gdbserver/config.h.
7863
d41f6d8e
GB
78642014-07-30 Gary Benson <gbenson@redhat.com>
7865
7866 * hostio-errno.c: Move server.h to top of includes list.
7867 * inferiors.c: Likewise.
7868 * linux-x86-low.c: Likewise.
7869 * notif.c: Include server.h.
7870
314c6a35
TT
78712014-07-24 Tom Tromey <tromey@redhat.com>
7872 Gary Benson <gbenson@redhat.com>
7873
7874 * server.h (CORE_ADDR): Now unsigned.
7875
69ff6be5
PA
78762014-07-16 Pedro Alves <palves@redhat.com>
7877
7878 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
7879
ce9e3fe7
PA
78802014-07-15 Pedro Alves <palves@redhat.com>
7881
7882 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
7883 copy.
7884
e76126e8
PA
78852014-07-11 Pedro Alves <palves@redhat.com>
7886
7887 * linux-low.c (kill_wait_lwp): New function, based on
7888 kill_one_lwp_callback, but use my_waitpid directly.
7889 (kill_one_lwp_callback, linux_kill): Use it.
7890
8e9db26e
PA
78912014-06-23 Pedro Alves <palves@redhat.com>
7892
7893 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
7894 before setting DR0..DR3.
7895
698b3e08
GB
78962014-06-20 Gary Benson <gbenson@redhat.com>
7897
7898 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
7899 * configure: Regenerated.
7900 * config.in: Likewise.
7901
125f8a3d
GB
79022014-06-20 Gary Benson <gbenson@redhat.com>
7903
7904 * Makefile.in (SFILES): Update locations for files moved
7905 from common to nat.
7906 (object file files): Reordered.
7907
42995dbd
GB
79082014-06-20 Gary Benson <gbenson@redhat.com>
7909
7910 * i386-low.h (i386_dr_low_can_set_addr): Removed.
7911 (i386_dr_low_set_addr): Likewise.
7912 (i386_dr_low_get_addr): Likewise.
7913 (i386_dr_low_can_set_control): Likewise.
7914 (i386_dr_low_set_control): Likewise.
7915 (i386_dr_low_get_control): Likewise.
7916 (i386_dr_low_get_status): Likewise.
7917 (i386_get_debug_register_length): Likewise.
7918 * linux-x86-low.c (i386_dr_low_set_addr):
7919 Changed signature. Made static.
7920 (i386_dr_low_get_addr): Likewise.
7921 (i386_dr_low_set_control): Likewise.
7922 (i386_dr_low_get_control): Likewise.
7923 (i386_dr_low_get_status): Likewise.
7924 (i386_dr_low): New global variable.
7925 * win32-i386-low.c (i386_dr_low_set_addr):
7926 Changed signature. Made static.
7927 (i386_dr_low_get_addr): Likewise.
7928 (i386_dr_low_set_control): Likewise.
7929 (i386_dr_low_get_control): Likewise.
7930 (i386_dr_low_get_status): Likewise.
7931 (i386_dr_low): New global variable.
7932
e1d2394b
MS
79332014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
7934
7935 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
7936 * Makefile.in (AR, AR_FLAGS): Define.
7937 * configure: Regenerate.
7938
3a8ee006
GB
79392014-06-19 Gary Benson <gbenson@redhat.com>
7940
7941 * Makefile.in (i386-dregs.o): New rule.
7942 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
7943 * i386-low.c (target.h): Remove include.
7944 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
7945 (DR_CONTROL_SHIFT): Likewise.
7946 (DR_CONTROL_SIZE): Likewise.
7947 (DR_RW_EXECUTE): Likewise.
7948 (DR_RW_WRITE): Likewise.
7949 (DR_RW_READ): Likewise.
7950 (DR_RW_IORW): Likewise.
7951 (DR_LEN_1): Likewise.
7952 (DR_LEN_2): Likewise.
7953 (DR_LEN_4): Likewise.
7954 (DR_LEN_8): Likewise.
7955 (DR_LOCAL_ENABLE_SHIFT): Likewise.
7956 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
7957 (DR_ENABLE_SIZE): Likewise.
7958 (DR_LOCAL_SLOWDOWN): Likewise.
7959 (DR_GLOBAL_SLOWDOWN): Likewise.
7960 (DR_CONTROL_RESERVED): Likewise.
7961 (I386_DR_CONTROL_MASK): Likewise.
7962 (I386_DR_VACANT): Likewise.
7963 (I386_DR_LOCAL_ENABLE): Likewise.
7964 (I386_DR_GLOBAL_ENABLE): Likewise.
7965 (I386_DR_DISABLE): Likewise.
7966 (I386_DR_SET_RW_LEN): Likewise.
7967 (I386_DR_GET_RW_LEN): Likewise.
7968 (I386_DR_WATCH_HIT): Likewise.
7969 (i386_wp_op_t): Likewise.
7970 (i386_show_dr): Likewise.
7971 (i386_length_and_rw_bits): Likewise.
7972 (i386_insert_aligned_watchpoint): Likewise.
7973 (i386_remove_aligned_watchpoint): Likewise.
7974 (i386_handle_nonaligned_watchpoint): Likewise.
7975 i386_update_inferior_debug_regs(): Likewise.
7976 (i386_dr_insert_watchpoint): Likewise.
7977 (i386_dr_remove_watchpoint): Likewise.
7978 (i386_dr_region_ok_for_watchpoint): Likewise.
7979 (i386_dr_stopped_data_address): Likewise.
7980 (i386_dr_stopped_by_watchpoint): Likewise.
7981
8f26655c
GB
79822014-06-19 Gary Benson <gbenson@redhat.com>
7983
7984 * i386-low.c (i386_dr_show): Renamed to
7985 i386_show_dr and made static. All uses updated.
7986 (i386_dr_length_and_rw_bits): Renamed to
7987 i386_length_and_rw_bits and made static.
7988 All uses updated.
7989 (i386_dr_insert_aligned_watchpoint): Renamed to
7990 i386_insert_aligned_watchpoint and made static.
7991 All uses updated.
7992 (i386_dr_remove_aligned_watchpoint): Renamed to
7993 i386_remove_aligned_watchpoint and made static.
7994 All uses updated.
7995 (i386_dr_update_inferior_debug_regs): Renamed to
7996 i386_update_inferior_debug_regs and made static.
7997 All uses updated.
7998
b9228891
GB
79992014-06-18 Gary Benson <gbenson@redhat.com>
8000
5171def3
GB
8001 * i386-low.h (i386_dr_low_can_set_addr): New macro.
8002 (i386_dr_low_can_set_control): Likewise.
8003 (i386_get_debug_register_length): Likewise.
8004 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
8005 (i386_dr_low_can_set_control): Likewise.
8006 (i386_get_debug_register_length): Likewise.
8007
80082014-06-17 Gary Benson <gbenson@redhat.com>
8009
b9228891
GB
8010 * i386-low.h (i386-dregs.h): New include.
8011 (DR_FIRSTADDR): Now in i386-dregs.h.
8012 (DR_LASTADDR): Likewise.
8013 (DR_NADDR): Likewise.
8014 (DR_STATUS): Likewise.
8015 (DR_CONTROL): Likewise.
8016 (i386_debug_reg_state): Likewise.
8017 (i386_dr_insert_watchpoint): Likewise.
8018 (i386_dr_remove_watchpoint): Likewise.
8019 (i386_dr_region_ok_for_watchpoint): Likewise.
8020 (i386_dr_stopped_data_address): Likewise.
8021 (i386_dr_stopped_by_watchpoint): Likewise.
8022 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
8023
4be83cc2
GB
80242014-06-18 Gary Benson <gbenson@redhat.com>
8025
8026 * i386-low.h (i386_low_insert_watchpoint): Renamed to
8027 i386_dr_insert_watchpoint.
8028 (i386_low_remove_watchpoint): Renamed to
8029 i386_dr_remove_watchpoint.
8030 (i386_low_region_ok_for_watchpoint): Renamed to
8031 i386_dr_region_ok_for_watchpoint.
8032 (i386_low_stopped_data_address): Renamed to
8033 i386_dr_stopped_data_address.
8034 (i386_low_stopped_by_watchpoint): Renamed to
8035 i386_dr_stopped_by_watchpoint.
8036 * i386-low.c (i386_show_dr): Renamed to
8037 i386_dr_show and made nonstatic. All uses updated.
8038 (i386_length_and_rw_bits): Renamed to
8039 i386_dr_length_and_rw_bits and made nonstatic.
8040 All uses updated.
8041 (i386_insert_aligned_watchpoint): Renamed to
8042 i386_dr_insert_aligned_watchpoint and made nonstatic.
8043 All uses updated.
8044 (i386_remove_aligned_watchpoint): Renamed to
8045 i386_dr_remove_aligned_watchpoint and made nonstatic.
8046 All uses updated.
8047 (i386_update_inferior_debug_regs): Renamed to
8048 i386_dr_update_inferior_debug_regs and made nonstatic.
8049 All uses updated.
8050 (i386_low_insert_watchpoint): Renamed to
8051 i386_dr_insert_watchpoint. All uses updated.
8052 (i386_low_remove_watchpoint): Renamed to
8053 i386_dr_remove_watchpoint. All uses updated.
8054 (i386_low_region_ok_for_watchpoint): Renamed to
8055 i386_dr_region_ok_for_watchpoint. All uses updated.
8056 (i386_low_stopped_data_address): Renamed to
8057 i386_dr_stopped_data_address. All uses updated.
8058 (i386_low_stopped_by_watchpoint): Renamed to
8059 i386_dr_stopped_by_watchpoint. All uses updated.
8060
131aa0d4
GB
80612014-06-18 Gary Benson <gbenson@redhat.com>
8062
8063 * i386-low.c (i386_dr_low_can_set_addr): New macro.
8064 (i386_dr_low_can_set_control): Likewise.
8065 (i386_insert_aligned_watchpoint): New check.
8066
d9305f7f
GB
80672014-06-18 Gary Benson <gbenson@redhat.com>
8068
8069 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
8070 Renamed to state.
8071
e927c9fc
GB
80722014-06-18 Gary Benson <gbenson@redhat.com>
8073
8074 * i386-low.c (i386_length_and_rw_bits): Use internal_error
8075 instead of fatal and error.
8076 (i386_handle_nonaligned_watchpoint): Likewise.
8077
1b6d4134
GB
80782014-06-18 Gary Benson <gbenson@redhat.com>
8079
8080 * i386-low.c (i386_get_debug_register_length): New macro.
8081 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
8082 (i386_show_dr): Use debug_printf instead of fprintf. Use
8083 phex to format values.
8084
6e62758f
GB
80852014-06-18 Gary Benson <gbenson@redhat.com>
8086
8087 * i386-low.h: Comment changes.
8088 * i386-low.c: Likewise.
8089
fc6e2f03
GB
80902014-06-18 Gary Benson <gbenson@redhat.com>
8091
8092 * i386-low.c: Whitespace changes.
8093
f9d1eeed
TT
80942014-06-12 Tom Tromey <tromey@redhat.com>
8095
8096 * utils.c (freeargv): Remove.
8097
0b04e523
TT
80982014-06-12 Tom Tromey <tromey@redhat.com>
8099
8100 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
8101 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
8102 (parse_debug_format_options): Likewise.
8103 (gdbserver_usage): Likewise.
8104 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
8105 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
8106 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
8107 against libiberty.
8108 ($(LIBGNU)): Depend on libiberty.
8109 (all-lib): Recurse into all subdirs.
8110 (install-only): Invoke "install" target in subdirs.
8111 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
8112 targets.
8113 * configure: Rebuild.
8114 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
8115 for vasprintf, vsnprintf, or gettimeofday.
8116 * configure.srv: Don't add safe-ctype.o or lbasename.o to
8117 srv_tgtobj.
8118
270c9937
JB
81192014-06-05 Joel Brobecker <brobecker@adacore.com>
8120
8121 * development.sh: Delete.
8122 * Makefile.in (config.status): Adjust dependency on development.sh.
8123 * configure.ac: Adjust development.sh source call.
8124 * configure: Regenerate.
8125
0a261ed8
PA
81262014-06-02 Pedro Alves <palves@redhat.com>
8127
8128 * ax.c (gdb_free_agent_expr): New function.
8129 * ax.h (gdb_free_agent_expr): New declaration.
8130 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
8131 list.
8132 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
8133 static.
8134 (clear_breakpoint_conditions_and_commands): New function.
8135 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
8136 (clear_breakpoint_conditions_and_commands): New declaration.
8137
e9dae05e
RR
81382014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
8139
8140 * linux-aarch64-low.c (asm/ptrace.h): Include.
8141
5876f503
JK
81422014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
8143
8144 Fix TLS access for -static -pthread.
8145 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
8146 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
8147 (thread_db_load_search, try_thread_db_load_1): Initialize it.
8148
802e8e6d
PA
81492014-05-20 Pedro Alves <palves@redhat.com>
8150
8151 * linux-aarch64-low.c (aarch64_insert_point)
8152 (aarch64_remove_point): No longer check whether the type is
8153 supported here. Adjust to new interface.
8154 (the_low_target): Install aarch64_supports_z_point_type as
8155 supports_z_point_type method.
8156 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
8157 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
8158 instead of a Z packet char. Adjust.
8159 (arm_supports_z_point_type): New function.
8160 (arm_insert_point, arm_remove_point): Adjust to new interface.
8161 (the_low_target): Install arm_supports_z_point_type.
8162 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
8163 (cris_insert_point, cris_remove_point): Adjust to new interface.
8164 Don't check whether the type is supported here.
8165 (the_low_target): Install cris_supports_z_point_type.
8166 * linux-low.c (linux_supports_z_point_type): New function.
8167 (linux_insert_point, linux_remove_point): Adjust to new interface.
8168 * linux-low.h (struct linux_target_ops) <insert_point,
8169 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
8170 raw_breakpoint pointer parameter.
8171 <supports_z_point_type>: New method.
8172 * linux-mips-low.c (mips_supports_z_point_type): New function.
8173 (mips_insert_point, mips_remove_point): Adjust to new interface.
8174 Use mips_supports_z_point_type.
8175 (the_low_target): Install mips_supports_z_point_type.
8176 * linux-ppc-low.c (the_low_target): Install NULL as
8177 supports_z_point_type method.
8178 * linux-s390-low.c (the_low_target): Install NULL as
8179 supports_z_point_type method.
8180 * linux-sparc-low.c (the_low_target): Install NULL as
8181 supports_z_point_type method.
8182 * linux-x86-low.c (x86_supports_z_point_type): New function.
8183 (x86_insert_point): Adjust to new insert_point interface. Use
8184 insert_memory_breakpoint. Adjust to new
8185 i386_low_insert_watchpoint interface.
8186 (x86_remove_point): Adjust to remove_point interface. Use
8187 remove_memory_breakpoint. Adjust to new
8188 i386_low_remove_watchpoint interface.
8189 (the_low_target): Install x86_supports_z_point_type.
8190 * lynx-low.c (lynx_target_ops): Install NULL as
8191 supports_z_point_type callback.
8192 * nto-low.c (nto_supports_z_point_type): New.
8193 (nto_insert_point, nto_remove_point): Adjust to new interface.
8194 (nto_target_ops): Install nto_supports_z_point_type.
8195 * mem-break.c: Adjust intro comment.
8196 (struct raw_breakpoint) <raw_type, size>: New fields.
8197 <inserted>: Update comment.
8198 <shlib_disabled>: Delete field.
8199 (enum bkpt_type) <gdb_breakpoint>: Delete value.
8200 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
8201 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
8202 (raw_bkpt_type_to_target_hw_bp_type): New function.
8203 (find_enabled_raw_code_breakpoint_at): New function.
8204 (find_raw_breakpoint_at): New type and size parameters. Use them.
8205 (insert_memory_breakpoint): New function, based off
8206 set_raw_breakpoint_at.
8207 (remove_memory_breakpoint): New function.
8208 (set_raw_breakpoint_at): Reimplement.
8209 (set_breakpoint): New, based on set_breakpoint_at.
8210 (set_breakpoint_at): Reimplement.
8211 (delete_raw_breakpoint): Go through the_target->remove_point
8212 instead of assuming memory breakpoints.
8213 (find_gdb_breakpoint_at): Delete.
8214 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
8215 (find_gdb_breakpoint): New function.
8216 (set_gdb_breakpoint_at): Delete.
8217 (z_type_supported): New function.
8218 (set_gdb_breakpoint_1): New function, loosely based off
8219 set_gdb_breakpoint_at.
8220 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
8221 (delete_gdb_breakpoint_at): Delete.
8222 (delete_gdb_breakpoint_1): New function, loosely based off
8223 delete_gdb_breakpoint_at.
8224 (delete_gdb_breakpoint): New function.
8225 (clear_gdb_breakpoint_conditions): Rename to ...
8226 (clear_breakpoint_conditions): ... this. Don't handle a NULL
8227 breakpoint.
8228 (add_condition_to_breakpoint): Make static.
8229 (add_breakpoint_condition): Take a struct breakpoint pointer
8230 instead of an address. Adjust.
8231 (gdb_condition_true_at_breakpoint): Rename to ...
8232 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
8233 z_type parameter.
8234 (gdb_condition_true_at_breakpoint): Reimplement.
8235 (add_breakpoint_commands): Take a struct breakpoint pointer
8236 instead of an address. Adjust.
8237 (gdb_no_commands_at_breakpoint): Rename to ...
8238 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
8239 parameter. Return true if no breakpoint was found. Change debug
8240 output.
8241 (gdb_no_commands_at_breakpoint): Reimplement.
8242 (run_breakpoint_commands): Rename to ...
8243 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
8244 and change return type to boolean.
8245 (run_breakpoint_commands): New function.
8246 (gdb_breakpoint_here): Also check for Z1 breakpoints.
8247 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
8248 breakpoint. Go through the_target->remove_point instead of
8249 assuming memory breakpoint.
8250 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
8251 software and hardware breakpoints.
8252 (reinsert_raw_breakpoint): Go through the_target->insert_point
8253 instead of assuming memory breakpoint.
8254 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
8255 software and hardware breakpoints.
8256 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
8257 Check both software and hardware breakpoints.
8258 (validate_inserted_breakpoint): Assert the breakpoint is a
8259 software breakpoint. Set the inserted flag to -1 instead of
8260 setting shlib_disabled.
8261 (delete_disabled_breakpoints): Adjust.
8262 (validate_breakpoints): Only validate software breakpoints.
8263 Adjust to inserted flag change.
8264 (check_mem_read, check_mem_write): Skip breakpoint types other
8265 than software breakpoints. Adjust to inserted flag change.
8266 * mem-break.h (enum raw_bkpt_type): New enum.
8267 (raw_breakpoint, struct process_info): Forward declare.
8268 (Z_packet_to_target_hw_bp_type): Delete declaration.
8269 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
8270 (set_gdb_breakpoint, delete_gdb_breakpoint)
8271 (clear_breakpoint_conditions): New declarations.
8272 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
8273 (breakpoint_inserted_here): Update comment.
8274 (add_breakpoint_condition, add_breakpoint_commands): Replace
8275 address parameter with a breakpoint pointer parameter.
8276 (gdb_breakpoint_here): Update comment.
8277 (delete_gdb_breakpoint_at): Delete.
8278 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
8279 * server.c (process_point_options): Take a struct breakpoint
8280 pointer instead of an address. Adjust.
8281 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
8282 delete_gdb_breakpoint.
8283 * spu-low.c (spu_target_ops): Install NULL as
8284 supports_z_point_type method.
8285 * target.h: Include mem-break.h.
8286 (struct target_ops) <prepare_to_access_memory>: Update comment.
8287 <supports_z_point_type>: New field.
8288 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
8289 instead of a char. Also take a raw breakpoint pointer.
8290 * win32-arm-low.c (the_low_target): Install NULL as
8291 supports_z_point_type.
8292 * win32-i386-low.c (i386_supports_z_point_type): New function.
8293 (i386_insert_point, i386_remove_point): Adjust to new interface.
8294 (the_low_target): Install i386_supports_z_point_type.
8295 * win32-low.c (win32_supports_z_point_type): New function.
8296 (win32_insert_point, win32_remove_point): Adjust to new interface.
8297 (win32_target_ops): Install win32_supports_z_point_type.
8298 * win32-low.h (struct win32_target_ops):
8299 <supports_z_point_type>: New method.
8300 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
8301 instead of a char. Also take a raw breakpoint pointer.
8302
932539e3
PA
83032014-05-20 Pedro Alves <palves@redhat.com>
8304
8305 * mem-break.h: Include break-common.h.
8306 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
8307 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
8308 (Z_packet_to_target_hw_bp_type): New declaration.
8309 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
8310 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
8311 (Z_PACKET_ACCESS_WP): Delete macros.
8312 (Z_packet_to_hw_type): Delete function.
8313 * i386-low.h: Don't include break-common.h here.
8314 (Z_packet_to_hw_type): Delete declaration.
8315 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
8316 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
8317 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
8318 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
8319 * linux-aarch64-low.c: Don't include break-common.h here.
8320 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
8321 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
8322 (Z_packet_to_target_hw_bp_type): Delete function.
8323 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
8324 function.
8325 (mips_insert_point, mips_remove_point): Use
8326 Z_packet_to_target_hw_bp_type.
8327
4ff0d3d8
PA
83282014-05-20 Pedro Alves <palves@redhat.com>
8329
8330 * linux-aarch64-low.c: Include break-common.h.
8331 (enum target_point_type): Delete.
8332 (Z_packet_to_point_type): Rename to ...
8333 (Z_packet_to_target_hw_bp_type): ... this, and return a
8334 target_hw_bp_type instead.
8335 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
8336 instead of an enum target_point_type.
8337 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
8338 breakpoint type.
8339 (aarch64_dr_state_insert_one_point)
8340 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
8341 (aarch64_handle_aligned_watchpoint)
8342 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
8343 Take an enum target_hw_bp_type instead of an enum
8344 target_point_type.
8345 (aarch64_supports_z_point_type): New function.
8346 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
8347 use Z_packet_to_target_hw_bp_type.
8348
786dc519
JB
83492014-05-20 Joel Brobecker <brobecker@adacore.com>
8350
8351 * configure.ac: Only use -Werror by default when DEVELOPMENT
8352 is true.
8353 * configure: Regenerate.
8354
9e0aa64f
JK
83552014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
8356
8357 Fix gdbserver qGetTLSAddr for x86_64 -m32.
8358 * linux-x86-low.c (X86_64_USER_REGS): New.
8359 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
8360
2b577b92
YQ
83612014-04-28 Yao Qi <yao@codesourcery.com>
8362
8363 * Makefile.in (i386-avx512.c): Fix the typo of generated file
8364 name.
8365
94611da2
PA
83662014-04-25 Pedro Alves <palves@redhat.com>
8367
8368 PR server/16255
8369 * linux-low.c (linux_attach_fail_reason_string): New function.
8370 (linux_attach_lwp): Delete.
8371 (linux_attach_lwp_1): Rename to ...
8372 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
8373 argument. Remove "initial" parameter. Return int instead of
8374 void. Don't error or warn here.
8375 (linux_attach): Adjust to call linux_attach_lwp. Call error on
8376 failure to attach to the tgid. Call warning when failing to
8377 attach to an lwp.
8378 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
8379 argument. Remove "initial" parameter. Return int instead of
8380 void. Don't error or warn here.
8381 (linux_attach_fail_reason_string): New declaration.
8382 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
8383 interface change. Use linux_attach_fail_reason_string.
8384
01f9f808
MS
83852014-04-24 Michael Sturm <michael.sturm@mintel.com>
8386 Walfred Tedeschi <walfred.tedeschi@intel.com>
8387
8388 * Makefile.in: Added rules to handle new files
8389 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
8390 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
8391 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
8392 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
8393 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
8394 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
8395 x32-avx512-linux.o.
8396 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
8397 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
8398 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
8399 i386/x32-avx512.xml.
8400 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
8401 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
8402 i386/x32-avx512-linux.xml.
8403 * i387-fp.c (num_avx512_k_registers): New constant for number
8404 of K registers.
8405 (num_avx512_zmmh_low_registers): New constant for number of
8406 lower ZMM registers (0-15).
8407 (num_avx512_zmmh_high_registers): New constant for number of
8408 higher ZMM registers (16-31).
8409 (num_avx512_ymmh_registers): New contant for number of higher
8410 YMM registers (ymm16-31 added by avx521 on x86_64).
8411 (num_avx512_xmm_registers): New constant for number of higher
8412 XMM registers (xmm16-31 added by AVX512 on x86_64).
8413 (struct i387_xsave): Add space for AVX512 registers.
8414 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
8415 Add code to handle AVX512 registers.
8416 (i387_xsave_to_cache): Add code to handle AVX512 registers.
8417 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
8418 prototypei from generated file.
8419 (tdesc_amd64_avx512_linux): Likewise.
8420 (init_registers_x32_avx512_linux): Likewise.
8421 (tdesc_x32_avx512_linux): Likewise.
8422 (init_registers_i386_avx512_linux): Likewise.
8423 (tdesc_i386_avx512_linux): Likewise.
8424 (x86_64_regmap): Add AVX512 registers.
8425 (x86_linux_read_description): Add code to handle AVX512 XSTATE
8426 mask.
8427 (initialize_low_arch): Add code to initialize AVX512 registers.
8428
51aa91f9
PA
84292014-04-23 Pedro Alves <palves@redhat.com>
8430
8431 * mem-break.c (find_gdb_breakpoint_at): Make static.
8432 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
8433
a4165e94
PA
84342014-04-23 Pedro Alves <palves@redhat.com>
8435
8436 * i386-low.c: Don't include break-common.h here.
8437 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
8438 prototype to take target_hw_bp_type as argument instead of a Z
8439 packet char.
8440 * i386-low.h: Include break-common.h here.
8441 (Z_packet_to_hw_type): Declare.
8442 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
8443 prototypes.
8444 * linux-x86-low.c (x86_insert_point): Convert the packet number to
8445 a target_hw_bp_type before calling i386_low_insert_watchpoint.
8446 (x86_remove_point): Convert the packet number to a
8447 target_hw_bp_type before calling i386_low_remove_watchpoint.
8448 * win32-i386-low.c (i386_insert_point): Convert the packet number
8449 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
8450 (i386_remove_point): Convert the packet number to a
8451 target_hw_bp_type before calling i386_low_remove_watchpoint.
8452
b8acf843
PA
84532014-04-23 Pedro Alves <palves@redhat.com>
8454
8455 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
8456
d708bcd1
PA
84572014-04-10 Pedro Alves <palves@redhat.com>
8458
8459 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
8460 Check if the condition or command is NULL before checking if the
8461 breakpoint is known. On success, return true.
8462 * mem-break.h (add_breakpoint_condition): Document return.
8463 (add_breakpoint_commands): Add describing comment.
8464 * server.c (skip_to_semicolon): New function.
8465 (process_point_options): Use it.
8466
2eec7d5b
PA
84672014-04-09 Pedro Alves <palves@redhat.com>
8468
8469 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
8470 to lwpid_of.
8471
fa96cb38
PA
84722014-02-27 Pedro Alves <palves@redhat.com>
8473
8474 PR 12702
8475 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
8476 macros.
8477 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
8478 output.
8479 (last_thread_of_process_p): Take a PID argument instead of a
8480 thread pointer.
8481 (linux_wait_for_lwp): Delete.
8482 (num_lwps, check_zombie_leaders, not_stopped_callback): New
8483 functions.
8484 (linux_low_filter_event): New function, party factored out from
8485 linux_wait_for_event.
8486 (linux_wait_for_event): Rename to ...
8487 (linux_wait_for_event_filtered): ... this. Add new filter ptid
8488 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
8489 sigsuspend. Check for zombie leaders.
8490 (linux_wait_for_event): Reimplement as wrapper around
8491 linux_wait_for_event_filtered.
8492 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
8493 a normal or signal exit is seen, it's the whole process exiting.
8494 (wait_for_sigstop): No longer a for_each_inferior callback.
8495 Rewrite on top of linux_wait_for_event_filtered.
8496 (stop_all_lwps): Call wait_for_sigstop directly.
8497 * server.c (resume, handle_target_event): Handle
8498 TARGET_WAITKIND_NO_RESUMED.
8499
d763de10
JB
85002014-02-26 Joel Brobecker <brobecker@adacore.com>
8501
8502 * win32-low.c (psapi_get_dll_name,
8503 * win32_CreateToolhelp32Snapshot): Delete.
8504 (win32_CreateToolhelp32Snapshot, win32_Module32First)
8505 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
8506 Delete.
8507 (handle_load_dll): Add function description.
8508 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
8509
850a0f76
JB
85102014-02-26 Joel Brobecker <brobecker@adacore.com>
8511
8512 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
8513 Add comment.
8514 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
8515 base address when calling win32_add_one_solib.
8516 (handle_load_dll): Delete local variable load_addr.
8517 Remove 0x1000 offset applied to DLL base address when calling
8518 win32_add_one_solib.
8519 (handle_unload_dll): Add comment.
8520
f25b3fc3
JB
85212014-02-26 Joel Brobecker <brobecker@adacore.com>
8522
8523 * win32-low.c (win32_add_all_dlls): Renames
8524 win32_ensure_ntdll_loaded. Rewrite function documentation.
8525 Adjust implementation to always load all DLLs.
8526 Add 0x1000 offset to DLL base address when calling
8527 win32_add_one_solib.
8528 (child_initialization_done): New static global.
8529 (do_initial_child_stuff): Set child_initialization_done to
8530 zero during child initialization, and 1 after. Replace call
8531 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
8532 Add comment.
8533 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
8534 (handle_unload_dll): Add function documentation.
8535 (get_child_debug_event): Ignore load and unload DLL events
8536 during child initialization.
8537
d86d4aaf
DE
85382014-02-20 Doug Evans <dje@google.com>
8539
3bc32da3 8540 Remove global all_lwps.
d86d4aaf
DE
8541 * inferiors.h (ptid_of): Move here from linux-low.h.
8542 (pid_of, lwpid_of): Ditto.
8543 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
8544 parameter is a struct thread_info * now.
8545 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
8546 directly. Pass &all_threads to find_inferior instead of &all_lwps.
8547 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
8548 directly.
8549 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
8550 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
8551 * linux-arm-low.c (update_registers_callback): Update, "entry"
8552 parameter is a struct thread_info * now.
8553 Fetch lwpid from current_inferior directly.
8554 (arm_insert_point): Pass &all_threads to find_inferior instead of
8555 &all_lwps.
8556 (arm_remove_point): Ditto.
8557 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
8558 (arm_prepare_to_resume): Fetch pid from thread.
8559 (arm_read_description): Fetch lwpid from current_inferior directly.
8560 * linux-low.c (all_lwps): Delete.
8561 (delete_lwp): Delete call to remove_inferior.
8562 (handle_extended_wait): Fetch lwpid from thread.
8563 (add_lwp): Don't set lwp->entry.id. Remove call to
8564 add_inferior_to_list.
8565 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
8566 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
8567 (kill_one_lwp_callback): Ditto.
8568 (linux_kill): Don't dereference NULL pointer.
8569 Fetch ptid,lwpid from thread.
8570 (get_detach_signal): Fetch ptid from thread.
8571 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
8572 Simplify call to regcache_invalidate_thread.
8573 (delete_lwp_callback): Update, "entry" parameter is a
8574 struct thread_info * now. Fetch pid from thread.
8575 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
8576 (status_pending_p_callback): Update, "entry" parameter is a
8577 struct thread_info * now. Fetch ptid from thread.
8578 (find_lwp_pid): Update, "entry" parameter is a
8579 struct thread_info * now.
8580 (linux_wait_for_lwp): Fetch pid from thread.
8581 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
8582 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
8583 (enqueue_one_deferred_signal): Fetch lwpid from thread.
8584 (dequeue_one_deferred_signal): Ditto.
8585 (cancel_breakpoint): Fetch ptid from current_inferior.
8586 (linux_wait_for_event): Pass &all_threads to find_inferior,
8587 not &all_lwps. Fetch ptid, lwpid from thread.
8588 (count_events_callback): Update, "entry" parameter is a
8589 struct thread_info * now.
8590 (select_singlestep_lwp_callback): Ditto.
8591 (select_event_lwp_callback): Ditto.
8592 (cancel_breakpoints_callback): Ditto.
8593 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
8594 not &all_lwps.
8595 (select_event_lwp): Ditto. Fetch ptid from event_thread.
8596 (unsuspend_one_lwp): Update, "entry" parameter is a
8597 struct thread_info * now.
8598 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
8599 not &all_lwps.
8600 (linux_stabilize_threads): Ditto. And for for_each_inferior.
8601 Fetch lwpid from thread, not lwp.
8602 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
8603 Pass &all_threads to find_inferior, not &all_lwps.
8604 (send_sigstop): Fetch lwpid from thread, not lwp.
8605 (send_sigstop_callback): Update, "entry" parameter is a
8606 struct thread_info * now.
8607 (suspend_and_send_sigstop_callback): Ditto.
8608 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
8609 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
8610 struct thread_info * now.
8611 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
8612 from thread, lwp.
8613 (lwp_running): Update, "entry" parameter is a
8614 struct thread_info * now.
8615 (stop_all_lwps): Fetch ptid from thread.
8616 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
8617 (linux_resume_one_lwp): Fetch lwpid from thread.
8618 (linux_set_resume_request): Update, "entry" parameter is a
8619 struct thread_info * now. Fetch pid, lwpid from thread.
8620 (resume_status_pending_p): Update, "entry" parameter is a
8621 struct thread_info * now.
8622 (need_step_over_p): Ditto. Fetch lwpid from thread.
8623 (start_step_over): Fetch lwpid from thread.
8624 (linux_resume_one_thread): Update, "entry" parameter is a
8625 struct thread_info * now. Fetch lwpid from thread.
8626 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
8627 (proceed_one_lwp): Update, "entry" parameter is a
8628 struct thread_info * now. Fetch lwpid from thread.
8629 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
8630 struct thread_info * now.
8631 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
8632 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
8633 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
8634 directly.
8635 (regsets_store_inferior_registers): Ditto.
8636 (fetch_register, store_register): Ditto.
8637 (linux_read_memory, linux_write_memory): Ditto.
8638 (linux_request_interrupt): Ditto.
8639 (linux_read_auxv): Ditto.
8640 (linux_xfer_siginfo): Ditto.
8641 (linux_qxfer_spu): Ditto.
8642 (linux_qxfer_libraries_svr4): Ditto.
8643 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
8644 moved to inferiors.h.
8645 (get_lwp): Delete.
8646 (get_thread_lwp): Update.
8647 (struct lwp_info): Delete member "entry". Simplify comment for
8648 member "thread".
8649 (all_lwps): Delete.
8650 * linux-mips-low.c (mips_read_description): Fetch lwpid from
8651 current_inferior directly.
8652 (update_watch_registers_callback): Update, "entry" parameter is a
8653 struct thread_info * now. Fetch pid from thread.
8654 (mips_linux_prepare_to_resume): Fetch ptid from thread.
8655 (mips_insert_point): Fetch lwpid from current_inferior.
8656 Pass &all_threads to find_inferior, not &all_lwps.
8657 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
8658 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
8659 directly.
8660 (mips_stopped_data_address): Ditto.
8661 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
8662 directly.
8663 * linux-tile-low.c (tile_arch_setup): Ditto.
8664 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
8665 (update_debug_registers_callback): Update, "entry" parameter is a
8666 struct thread_info * now. Fetch pid from thread.
8667 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
8668 Pass &all_threads to find_inferior, not &all_lwps.
8669 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
8670 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
8671 Pass &all_threads to find_inferior, not &all_lwps.
8672 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
8673 (i386_dr_low_get_status): Ditto.
8674 (x86_linux_prepare_to_resume): Fetch ptid from thread.
8675 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
8676 (x86_linux_read_description): Ditto.
8677 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
8678
3b8361aa
DE
86792014-02-20 Doug Evans <dje@google.com>
8680
8681 * inferiors.c (get_first_inferior): Fix buglet.
8682
f7667f0d
DE
86832014-02-19 Doug Evans <dje@google.com>
8684
8685 * gdbthread.h (add_thread): Change result type to struct thread_info *.
8686 * inferiors.c (add_thread): Change result type to struct thread_info *.
8687 All callers updated.
8688 (add_lwp): Call add_thread here instead of in callers.
8689 All callers updated.
8690 * linux-low.h (get_lwp_thread): Rewrite.
8691 (struct lwp_info): New member "thread".
8692
b3312d80
DE
86932014-02-19 Doug Evans <dje@google.com>
8694
8695 * linux-low.c (add_lwp): Change result to struct lwp_info *.
8696 All callers updated.
8697
ecc6f45c
DE
86982014-02-19 Doug Evans <dje@google.com>
8699
8700 * inferiors.c (add_thread): Fix whitespace.
8701
649ebbca
DE
87022014-02-19 Doug Evans <dje@google.com>
8703
8704 * dll.c (clear_dlls): Replace accessing list implemention details
8705 with API function.
8706 * gdbthread.h (get_first_thread): Declare.
8707 * inferiors.c (for_each_inferior_with_data): New function.
8708 (get_first_thread): New function.
8709 (find_thread_ptid): Simplify.
8710 (get_first_inferior): New function.
8711 (clear_list): Delete.
8712 (one_inferior_p): New function.
8713 (clear_inferior_list): New function.
8714 (clear_inferiors): Update.
8715 * inferiors.h (for_each_inferior_with_data): Declare.
8716 (clear_inferior_list): Declare.
8717 (one_inferior_p): Declare.
8718 (get_first_inferior): Declare.
8719 * linux-low.c (linux_wait_for_event): Replace accessing list
8720 implemention details with API function.
8721 * server.c (target_running): Ditto.
8722 (accumulate_file_name_length): New function.
8723 (emit_dll_description): New function.
8724 (handle_qxfer_libraries): Replace accessing list implemention
8725 details with API function.
8726 (handle_qxfer_threads_worker): New function.
8727 (handle_qxfer_threads_proper): Replace accessing list implemention
8728 details with API function.
8729 (handle_query): Ditto.
8730 (visit_actioned_threads_callback_ftype): New typedef.
8731 (visit_actioned_threads_data): New struct.
8732 (visit_actioned_threads): Rewrite to be find_inferior callback.
8733 (resume): Call find_inferior.
8734 (handle_status): Replace accessing list implemention
8735 details with API function.
8736 (process_serial_event): Replace accessing list implemention details
8737 with API function.
8738 * target.c (set_desired_inferior): Replace accessing list implemention
8739 details with API function.
8740 * tracepoint.c (same_process_p): New function.
8741 (gdb_agent_about_to_close): Replace accessing list implemention
8742 details with API function.
8743 * win32-low.c (child_delete_thread): Replace accessing list
8744 implemention details with API function.
8745 (match_dll_by_basename): New function.
8746 (dll_is_loaded_by_basename): New function.
8747 (win32_ensure_ntdll_loaded): Replace accessing list implemention
8748 details call to dll_is_loaded_by_basename.
8749
80894984
DE
87502014-02-19 Doug Evans <dje@google.com>
8751
8752 * dll.h (struct dll_info): Add comment.
8753 * gdbthread.h (struct thread_info): Add comment.
8754 (current_ptid): Simplify.
8755 * inferiors.c (add_process): Update.
8756 (remove_process): Update.
8757 * inferiors.h (struct process_info): Rename member "head" to "entry".
8758 * linux-low.c (delete_lwp): Update.
8759 (add_lwp): Update.
8760 (last_thread_of_process_p): Update.
8761 (kill_one_lwp_callback, linux_kill): Update.
8762 (status_pending_p_callback): Update.
8763 (wait_for_sigstop): Update. Simplify read of ptid.
8764 (start_step_over): Update.
8765 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
8766 (get_lwp_thread): Update.
8767 (struct lwp_info): Rename member "head" to "entry".
8768 * regcache.h (inferior_list_entry): Delete.
8769 * server.c (kill_inferior_callback): Update.
8770 (detach_or_kill_inferior_callback): Update.
8771 (print_started_pid): Update.
8772 (print_attached_pid): Update.
8773 (process_serial_event): Simplify read of ptid.
8774 * thread-db.c (thread_db_create_event): Update.
8775 (thread_db_get_tls_address): Update.
8776 * win32-low.c (current_inferior_ptid): Simplify.
8777
46917d26
TT
87782014-02-19 Tom Tromey <tromey@redhat.com>
8779
8780 * target.h (struct target_ops) <supports_btrace>: Add target_ops
8781 argument.
8782 (target_supports_btrace): Update.
8783
0759a81e
YQ
87842014-02-14 Yao Qi <yao@codesourcery.com>
8785
8786 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
8787 (rsp-low-ipa.o): New target.
8788
a7191e8b
TT
87892014-02-12 Tom Tromey <tromey@redhat.com>
8790
8791 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
8792 convert_ascii_to_int.
8793 * regcache.c (registers_to_string): Likewise.
8794 * remote-utils.c (decode_M_packet): Likewise.
8795 * server.c (process_serial_event): Likewise.
8796
ff0e980e
TT
87972014-02-12 Tom Tromey <tromey@redhat.com>
8798
8799 * server.c (handle_query, handle_v_run): Use hex2bin, not
8800 unhexify.
8801 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
8802
e9371aff
TT
88032014-02-12 Tom Tromey <tromey@redhat.com>
8804
8805 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
8806 convert_int_to_ascii.
8807 * regcache.c (registers_to_string, collect_register_as_string):
8808 Likewise.
8809 * remote-utils.c (look_up_one_symbol, relocate_instruction):
8810 Likewise.
8811 * server.c (process_serial_event): Likewise.
8812 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
8813 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
8814
971dc0b8
TT
88152014-02-12 Tom Tromey <tromey@redhat.com>
8816
8817 * remote-utils.c (look_up_one_symbol, monitor_output): Use
8818 bin2hex, not hexify.
8819 * tracepoint.c (cmd_qtstatus): Likewise.
8820
0a822afb
TT
88212014-02-12 Tom Tromey <tromey@redhat.com>
8822
8823 * remote-utils.c (monitor_output): Pass explicit length to
8824 hexify.
8825
9c3d6531
TT
88262014-02-12 Tom Tromey <tromey@redhat.com>
8827
8828 * tracepoint.c: Include rsp-low.h.
8829 * server.c: Include rsp-low.h.
8830 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
8831 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
8832 declare.
8833 * remote-utils.c: Include rsp-low.h.
8834 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
8835 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
8836 (convert_int_to_ascii, convert_ascii_to_int): Move to
8837 common/rsp-low.c.
8838 * regcache.c: Include rsp-low.h.
8839 * ax.c: Include rsp-low.h.
8840 * Makefile.in (SFILES): Add common/rsp-low.c.
8841 (OBS): Add rsp-low.o.
8842 (rsp-low.o): New target.
8843
01fd3ea5
TT
88442014-02-12 Tom Tromey <tromey@redhat.com>
8845
8846 * utils.h (pulongest, plongest, phex_nz): Don't declare.
8847 Include print-utils.h.
8848 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
8849 (plongest, thirty_two, phex_nz): Remove.
8850 * Makefile.in (SFILES): Add common/print-utils.c.
8851 (OBS): Add print-utils.o.
8852 (print-utils-ipa.o): New target.
8853 (print-utils.o): New target.
8854 (IPA_OBJS): Add print-utils-ipa.o.
8855
e99dc820
TT
88562014-02-06 Tom Tromey <tromey@redhat.com>
8857
8858 * Makefile.in (SFILES): Fix indentation.
8859
ee1e2d4f
DE
88602014-02-05 Doug Evans <dje@google.com>
8861
8862 * linux-low.c (linux_wait_for_event): Improve comment.
8863 (linux_wait_1): Keep current_inferior in sync with event_child.
8864
f5a02773
DE
88652014-01-22 Doug Evans <dje@google.com>
8866
8867 * gdbthread.h (gdb_id_to_thread): Delete, unused.
8868
87ce2a04
DE
88692014-01-22 Doug Evans <dje@google.com>
8870
8871 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
8872 * configure: Regenerate.
8873 * config.in: Regenerate.
8874 * Makefile.in (SFILES): Add debug.c.
8875 (OBS): Add debug.o.
8876 * debug.c: New file.
8877 * debug.h: New file.
8878 * linux-aarch64-low.c (*): Update all debugging printfs to use
8879 debug_printf instead of fprintf.
8880 * linux-arm-low.c (*): Ditto.
8881 * linux-cris-low.c (*): Ditto.
8882 * linux-crisv32-low.c (*): Ditto.
8883 * linux-m32r-low.c (*): Ditto.
8884 * linux-sparc-low.c (*): Ditto.
8885 * linux-x86.c (*): Ditto.
8886 * linux-low.c (*): Ditto.
8887 (linux_wait_1): Add calls to debug_enter, debug_exit.
8888 (linux_wait): Remove redundant debugging printf.
8889 (stop_all_lwps): Add calls to debug_enter, debug_exit.
8890 (linux_resume, unstop_all_lwps): Ditto.
8891 * mem-break.c (*): Update all debugging printfs to use
8892 debug_printf instead of fprintf.
8893 * remote-utils.c (*): Ditto.
8894 * thread-db.c (*): Ditto.
8895 * server.c #include <ctype.h>, "gdb_vecs.h".
8896 (debug_threads): Moved to debug.c.
8897 (*): Update all debugging printfs to use debug_printf instead of
8898 fprintf.
8899 (start_inferior): Replace call to fflush with call to debug_flush.
8900 (monitor_show_help): Mention set debug-format.
8901 (parse_debug_format_options): New function.
8902 (handle_monitor_command): Handle "monitor set debug-format".
8903 (gdbserver_usage): Mention --debug-format.
8904 (main): Parse --debug-format.
8905 * server.h (debug_threads): Declaration moved to debug.h.
8906 #include "debug.h".
8907 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
8908 trace_debug_1 that uses debug_printf.
8909 (tracepoint_look_up_symbols): Update all debugging printfs to use
8910 debug_printf instead of fprintf.
8911
e671835b
BS
89122014-01-20 Baruch Siach <baruch@tkos.co.il>
8913
8914 * linux-xtensa-low.c: Include asm/ptrace.h instead of
8915 sys/ptrace.h.
8916
b5737fa9
PA
89172014-01-17 Pedro Alves <palves@redhat.com>
8918
ea38d2a9 8919 PR build/16445
c7faa97a
PA
8920 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
8921 defined after including gdb_proc_service.h.
b5737fa9 8922
40ed484e
DE
89232014-01-16 Doug Evans <dje@google.com>
8924
8925 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
8926 (match_dll): Use it.
8927
969c39fb
MM
89282014-01-16 Markus Metzger <markus.t.metzger@intel.com>
8929
8930 * target.h (target_ops) <read_btrace>: Change parameters and
8931 return type to allow error reporting.
8932 * server.c (handle_qxfer_btrace): Support delta reads. Pass
8933 trace reading errors on.
8934 * linux-low.c (linux_low_read_btrace): Pass trace reading
8935 errors on.
8936 (linux_low_disable_btrace): New.
8937
ab7f45ba
DE
89382014-01-15 Doug Evans <dje@google.com>
8939
8940 * inferiors.c (thread_id_to_gdb_id): Delete.
8941 * inferiors.h (thread_id_to_gdb_id): Delete.
8942
66af0f44
EZ
89432014-01-13 Eli Zaretskii <eliz@gnu.org>
8944
8945 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
8946 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
8947 versions.
8948
9939e131
PA
89492014-01-08 Pedro Alves <palves@redhat.com>
8950
8951 * server.c (handle_status): Don't discard previous queued stop
8952 replies or thread's pending status here.
8953 (main) <disconnection>: Do it here instead.
8954
b7ea362b
PA
89552014-01-08 Pedro Alves <palves@redhat.com>
8956
8957 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
8958 * server.c (visit_actioned_threads, handle_pending_status): New
8959 function.
8960 (handle_v_cont): Factor out parts to ...
8961 (resume): ... this new function. If in all-stop, and a thread
8962 being resumed has a pending status, report it without actually
8963 resuming.
8964 (myresume): Adjust to use the new 'resume' function.
8965 (clear_pending_status_callback, set_pending_status_callback)
8966 (find_status_pending_thread_callback): New functions.
8967 (handle_status): Handle the case of multiple threads having
8968 interesting statuses to report. Report threads' real last signal
8969 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
8970 with an interesting thread to report the status for, instead of
8971 always reporting the status of the first thread.
8972
28498c42
JB
89732014-01-01 Joel Brobecker <brobecker@adacore.com>
8974
8975 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
8976 * gdbreplay.c (gdbreplay_version): Likewise.
8977
f45c82da
YZ
89782013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
8979
8980 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
8981 iov.iov_len with the real length in use.
8982
379a5e2d
JB
89832013-12-13 Joel Brobecker <brobecker@adacore.com>
8984
8985 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
8986 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
8987 for all targets that use win32-low.c.
8988 * win32-low.c (win32_ensure_ntdll_loaded): New function.
8989 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
8990
4210d83e
PA
89912013-12-13 Pedro Alves <palves@redhat.com>
8992
8993 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
8994 if equal to TARGET_WAITKIND_LOADED.
8995 * win32-low.c (cached_status): New static global.
8996 (win32_wait): Add declaration.
8997 (do_initial_child_stuff): Flush all initial pending debug events
8998 up to the initial breakpoint.
8999 (win32_wait): If CACHED_STATUS was set, return that instead
9000 of doing a real wait. Remove the code resuming the execution
9001 of the inferior after receiving a TARGET_WAITKIND_LOADED event
9002 during the initial phase. Also remove the code changing
9003 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
9004 TARGET_WAITKIND_STOPPED.
9005
e7f0d979
YQ
90062013-12-11 Yao Qi <yao@codesourcery.com>
9007
9008 * notif.c (handle_notif_ack): Return 0 if no notification
9009 matches.
9010
ebcf782c
DE
90112013-11-20 Doug Evans <dje@google.com>
9012
9013 * linux-low.c (linux_set_resume_request): Fix comment.
9014
20ad9378
DE
90152013-11-20 Doug Evans <dje@google.com>
9016
9017 * linux-low.c (resume_status_pending_p): Tweak comment.
9018
a196ebeb
WT
90192013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
9020
9021 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
9022 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
9023 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
9024 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
9025 (srv_amd64_regobj): Add amd64-mpx.o.
9026 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
9027 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
9028 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
9029 * i387-fp.c (num_pl_bnd_register) Added constant.
9030 (num_pl_bnd_cfg_registers) Added constant.
9031 (struct i387_xsave) Added reserved area and MPX fields.
9032 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
9033 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
9034 function.
9035 (tdesc_i386_mpx_linux): Add MPX amd64 target.
9036 (init_registers_amd64_mpx_linux): Declare new function.
9037 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
9038 (x86_64_regmap): Add MPX registers.
9039 (x86_linux_read_description): Add MPX case.
9040 (initialize_low_arch): Initialize MPX targets.
9041
0080a2f6
TT
90422013-11-18 Tom Tromey <tromey@redhat.com>
9043
9044 * configure: Rebuild.
9045 * configure.ac: Don't check for stdlib.h.
9046 * gdbreplay.c: Unconditionally include stdlib.h.
9047
2978b111
TT
90482013-11-18 Tom Tromey <tromey@redhat.com>
9049
9050 * config.in: Rebuild.
9051 * configure: Rebuild.
9052 * configure.ac: Don't use AC_HEADER_DIRENT.
9053
a3d08894
TT
90542013-11-18 Tom Tromey <tromey@redhat.com>
9055
9056 * server.h: Don't check HAVE_STRING_H.
9057 * gdbreplay.c: Don't check HAVE_STRING_H.
9058 * configure: Rebuild.
9059
0a5dd17d
TT
90602013-11-18 Tom Tromey <tromey@redhat.com>
9061
9062 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
9063 LIBGNU.
9064
1bd2f0ba
TT
90652013-11-08 Tom Tromey <tromey@redhat.com>
9066
9067 * configure, config.in: Rebuild.
9068 * configure.ac: Remove unused configury.
9069
3266f10b
TT
90702013-11-08 Tom Tromey <tromey@redhat.com>
9071
9072 * acinclude.m4: Include common.m4, codeset.m4.
9073 * configure, config.in: Rebuild.
9074 * configure.ac: Use GDB_AC_COMMON.
9075
6682d959
AA
90762013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
9077
9078 * linux-s390-low.c (HWCAP_S390_TE): New define.
9079 (s390_arch_setup): Consider the TE field in the HWCAP for
9080 determining 'have_regset_tdb'.
9081
fd0a4d76
SDJ
90822013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
9083
9084 PR gdb/16014
9085 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
9086 call to sizeof.
9087
1a3d890b
PA
90882013-10-02 Pedro Alves <palves@redhat.com>
9089
9090 * server.c (process_serial_event): Don't output "GDBserver
9091 exiting" if GDB is connected through stdio.
9092 * target.c (mywait): Likewise, be silent if GDB is connected
9093 through stdio.
9094
97ad4581
JB
90952013-10-01 Joel Brobecker <brobecker@adacore.com>
9096
9097 * lynx-low.c (lynx_add_threads_after_attach): New function.
9098 (lynx_attach): Remove call to add_thread. Add call to
9099 lynx_add_threads_after_attach instead.
9100
5b4e221c
MF
91012013-09-28 Mike Frysinger <vapier@gentoo.org>
9102
9103 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
9104 * config.in, configure: Regenerated.
9105
ee47b2f8
YQ
91062013-09-18 Yao Qi <yao@codesourcery.com>
9107
9108 PR server/15959
9109 * server.c (start_inferior): Clear 'resume_info'.
9110
d6707650 91112013-09-16 Jiong Wang <jiwang@tilera.com>
0f63d4db 9112
d6707650
JW
9113 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
9114 for each register.
9115
9243dd0e 91162013-09-16 Jiong Wang <jiwang@tilera.com>
0f63d4db 9117
9243dd0e
JW
9118 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
9119 linux-tile-low.o to srv_tgtobj.
9120
c623a6ef
WN
91212013-09-16 Will Newton <will.newton@linaro.org>
9122
9123 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
9124 out regs.
9125
fb71d39e
PA
91262013-09-06 Pedro Alves <palves@redhat.com>
9127
9128 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
9129 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
9130 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
9131 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
9132 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
9133 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
9134
8e7e9910
PA
91352013-09-06 Pedro Alves <palves@redhat.com>
9136
9137 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
9138 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
9139
7c3a12ca
PA
91402013-09-06 Pedro Alves <palves@redhat.com>
9141
9142 * linux-amd64-ipa.c: Include tracepoint.h.
9143 * linux-i386-ipa.c: Include tracepoint.h.
9144
8eb3d7b6
RW
91452013-09-06 Ricard Wanderlof <ricardw@axis.com>
9146
9147 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
9148 (ps_get_thread_area): New function.
9149
eddddb9d
RW
91502013-09-06 Ricard Wanderlof <ricardw@axis.com>
9151
9152 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
9153 (initialize_low_arch): Call init_registers_crisv32 rather than
9154 init_register_crisv32.
9155
533b0600
PA
91562013-09-05 Pedro Alves <palves@redhat.com>
9157
9158 * server.h (handle_vFile, hostio_last_error_from_errno): Move
9159 to ...
9160 * hostio.h: ... this new file.
9161 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
9162 win32-low.c: Include hostio.h.
9163
0ce3d3b5
PA
91642013-09-05 Pedro Alves <palves@redhat.com>
9165
9166 * server.h (gdb_client_data, handler_func, callback_handler_func)
9167 (delete_file_handler, add_file_handler, append_callback_event)
9168 (delete_callback_event, start_event_loop, initialize_event_loop):
9169 Move to event-loop.h and include it.
9170 * event-loop.h: New file.
9171
799cdc37
PA
91722013-09-05 Pedro Alves <palves@redhat.com>
9173
9174 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
9175 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
9176 (loaded_dll, unloaded_dll): Move to ...
9177 * dll.h: ... this new file.
9178 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
9179
6a6bbd9d
PA
91802013-09-05 Pedro Alves <palves@redhat.com>
9181
9182 * server.h (current_process, get_thread_process, all_processes)
9183 (add_inferior_to_list, for_each_inferior, current_inferior)
9184 (remove_inferior, add_process, remove_process, find_process_pid)
9185 (have_started_inferiors_p, have_attached_inferiors_p)
9186 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
9187 (clear_inferiors, find_inferior, find_inferior_id)
9188 (inferior_target_data, set_inferior_target_data)
9189 (inferior_regcache_data, set_inferior_regcache_data): Move to
9190 inferiors.h, and include it.
9191 * inferiors.h: New file.
9192
f699aaba
PA
91932013-09-05 Pedro Alves <palves@redhat.com>
9194
9195 * server.h (struct emit_ops, current_insn_ptr, emit_error):
9196 Move ...
72f4393d 9197 * ax.h: ... here.
f699aaba 9198
c144c7a0
PA
91992013-09-05 Pedro Alves <palves@redhat.com>
9200
9201 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
9202 tracepoint.h.
9203 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
9204 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
9205 (handle_tracepoint_general_set, handle_tracepoint_query)
9206 (tracepoint_finished_step, tracepoint_was_hit)
9207 (release_while_stepping_state_list, current_traceframe)
9208 (in_readonly_region, traceframe_read_mem)
9209 (fetch_traceframe_registers, traceframe_read_sdata)
9210 (traceframe_read_info, struct fast_tpoint_collect_status)
9211 (fast_tracepoint_collecting, force_unlock_trace_buffer)
9212 (handle_tracepoit_bkpts, initialize_low_tracepoint)
9213 (supply_fast_tracepoint_registers)
9214 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
9215 (ipa_tdesc, claim_trampoline_space)
9216 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
9217 (agent_mem_read, agent_get_trace_state_variable_value)
9218 (agent_set_trace_state_variable_value, agent_tsv_read)
9219 (agent_mem_read_string, get_raw_reg_func_addr)
9220 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
9221 * tracepoint.h: ... this new file.
9222
ff42e6ab
PA
92232013-09-05 Pedro Alves <palves@redhat.com>
9224
9225 * server.h (perror_with_name, error, fatal, warning, paddress)
9226 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
9227 include it.
9228 * utils.h: New file.
9229
541af0f4
PA
92302013-09-05 Pedro Alves <palves@redhat.com>
9231
9232 * server.h (remote_debug, noack_mode, transport_is_reliable)
9233 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
9234 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
9235 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
9236 (write_enn, initialize_async_io, enable_async_io)
9237 (disable_async_io, check_remote_input_interrupt_request)
9238 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
9239 (dead_thread_notify, prepare_resume_reply)
9240 (decode_address_to_semicolon, decode_address, decode_m_packet)
9241 (decode_M_packet, decode_X_packet, decode_xfer_write)
9242 (decode_search_memory_packet, unhexify, hexify)
9243 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
9244 (look_up_one_symbol, relocate_instruction)
9245 (monitor_output): Move to remote-utils.h, and include it.
9246 * remote-utils.h: New file.
9247
eebdf26b
PA
92482013-09-05 Pedro Alves <palves@redhat.com>
9249
9250 * server.h (_): Delete.
9251
3aafd2ff
PA
92522013-09-02 Pedro Alves <palves@redhat.com>
9253
9254 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
9255 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
9256 allocated.
9257 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
9258
cee83bcb
PM
92592013-09-02 Pierre Muller <muller@sourceware.org>
9260
9261 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
9262 or WriteProcessMemory complete successfully and handle
9263 ERROR_PARTIAL_COPY error.
9264
9a13b2fa
PA
92652013-09-02 Pedro Alves <palves@redhat.com>
9266
9267 * server.c (gdb_read_memory): Return -1 on traceframe memory read
9268 error instead of EIO.
9269
602e3198
JK
92702013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
9271
9272 PR server/15604
9273 * linux-low.c: Include filestuff.h.
9274 (linux_create_inferior) <pid == 0>: Call close_most_fds.
9275 * lynx-low.c: Include filestuff.h.
9276 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
9277 * server.c: Include filestuff.h.
9278 (main): Call notice_open_fds.
9279 * spu-low.c: Include filestuff.h.
9280 (spu_create_inferior) <pid == 0>: Call close_most_fds.
9281
96d7229d
LM
92822013-08-22 Luis Machado <lgustavo@codesourcery.com>
9283
9284 * Makefile.in: Explain why ../target and ../nat are not
9285 listed as include file search paths.
9286 (linux-waitpid.o): New object file rule.
9287 * configure.srv (srv_native_linux_obj): New variable.
9288 Replace all occurrences of linux native object files with
9289 $srv_native_linux_obj.
9290 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
9291 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
9292 (linux_enable_event_reporting): Remove declaration.
9293 (my_waitpid): Moved to common/linux-waitpid.c.
9294 (linux_wait_for_event): Pass ptid when calling
9295 linux_enable_event_reporting.
9296 (linux_supports_tracefork_flag): Remove.
9297 (linux_enable_event_reporting): Likewise.
9298 (linux_tracefork_grandchild): Remove.
9299 (STACK_SIZE): Moved to common/linux-ptrace.c.
9300 (linux_tracefork_child): Remove.
9301 (linux_test_for_tracefork): Remove.
9302 (linux_look_up_symbols): Call linux_supports_traceclone.
9303 (initialize_low): Remove call to linux_test_for_tracefork.
9304 * linux-low.h (PTRACE_TYPE_ARG3): Move to
9305 common/linux-ptrace.h.
9306 (PTRACE_TYPE_ARG4): Likewise.
9307 Include linux-ptrace.h.
9308
32940073
PA
93092013-08-21 Pedro Alves <palves@redhat.com>
9310
9311 * config.in: Renegerate.
9312
33b60d58 93132013-08-19 Luis Machado <lgustavo@codesourcery.com>
a261b8f5 9314
33b60d58
LM
9315 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
9316 (SFILES): Remove $(srcdir)/common/target-common.c and
9317 add $(srcdir)/target/waitstatus.c.
9318 (OBS): Remove target-common.o and add waitstatus.o.
9319 (server_h): Remove $(srcdir)/../common/target-common.h and
9320 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
9321 and $(srcdir)/../target/waitstatus.h.
9322 (target-common.o): Remove.
9323 (waitstatus.o): New target object file.
9324 * target.h: Do not include target-common.h and
9325 include target/resume.h, target/wait.h and
9326 target/waitstatus.h.
9327
b8e1b30e
LM
93282013-08-13 Luis Machado <lgustavo@codesourcery.com>
9329
9330 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
9331 to PTRACE_TYPE_ARG3.
9332 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
9333 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
9334 PTRACE_TYPE_ARG4.
9335 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
9336 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
9337
7a60ad40
YQ
93382013-07-27 Jie Zhang <jie@codesourcery.com>
9339 Daniel Jacobowitz <dan@codesourcery.com>
9340 Yao Qi <yao@codesourcery.com>
9341
9342 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
9343 (mips-linux-watch.o): New rule.
9344 (mips_linux_watch_h): New variable.
9345 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
9346 srv_tgtobj.
9347 * linux-mips-low.c: Include mips-linux-watch.h.
9348 (struct arch_process_info, struct arch_lwp_info): New.
9349 (update_watch_registers_callback): New function.
9350 (mips_linux_new_process, mips_linux_new_thread) New functions.
9351 (mips_linux_prepare_to_resume, mips_insert_point): New
9352 functions.
9353 (mips_remove_point, mips_stopped_by_watchpoint): New
9354 functions.
9355 (rsp_bp_type_to_target_hw_bp_type): New function.
9356 (mips_stopped_data_address): New function.
9357 (the_low_target): Add watchpoint support functions.
9358
de6f69ad
YQ
93592013-07-27 Yao Qi <yao@codesourcery.com>
9360
9361 * i386-low.c: Include break-common.h.
9362 (enum target_hw_bp_type): Remove.
9363
3360c0bf
LM
93642013-07-24 Luis Machado <lgustavo@codesourcery.com>
9365
9366 * Makefile.in (SFILES): /common/target-common.c.
9367 (OBS): Add target-common.o.
9368 (server_h): Add $(srcdir)/../common/target-common.h.
9369 (target-common.o): New target.
9370 * server.c (queue_stop_reply_callback): Free
9371 status string after use.
9372 * target.c (target_waitstatus_to_string): Remove.
9373 * target.h: Include target-common.h.
9374 (resume_kind): Likewise.
9375 (target_waitkind): Likewise.
9376 (target_waitstatus): Likewise.
9377 (TARGET_WNOHANG): Likewise.
9378
bd885420
YQ
93792013-07-04 Yao Qi <yao@codesourcery.com>
9380
9381 * Makefile.in (host_alias): Use @host_noncanonical@.
9382 (target_alias): Use @target_noncanonical@.
9383 * configure.ac: Use ACX_NONCANONICAL_TARGET and
9384 ACX_NONCANONICAL_HOST.
9385 * configure: Regenerated.
9386
9387 Revert:
9388 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
9389
9390 * configure.ac (version_host, version_target): Set and AC_SUBST them.
9391 * configure: Rebuild.
9392 * Makefile.in (version_host, version_target): Get from configure.
9393 (version.c): Use $(version_host) and $(version_target).
9394
17ef446e
PA
93952013-07-03 Pedro Alves <palves@redhat.com>
9396
9397 * Makefile.in (config.status): Depend on development.sh.
9398 * acinclude.m4: Include libmcheck.m4.
9399 * configure: Regenerate.
9400
7a9a7487
MG
94012013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
9402
9403 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
9404 attribute inside the parentheses.
9405 (winapi_DebugSetProcessKillOnExit): Ditto.
9406 (winapi_DebugBreakProcess): Ditto.
9407 (winapi_GenerateConsoleCtrlEvent): Ditto.
a261b8f5 9408
49b64de6
MG
94092013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
9410
9411 * notif.h (notif_event): Add a dummy member to avoid compiler
9412 errors.
9413
d5749ee7
PA
94142013-07-01 Pedro Alves <palves@redhat.com>
9415
9416 * hostio.c (HOSTIO_PATH_MAX): Define.
9417 (require_filename, handle_open, handle_unlink, handle_readlink):
9418 Use it.
9419
d8d2a3ee
PA
94202013-07-01 Pedro Alves <palves@redhat.com>
9421
9422 * server.h: Include "pathmax.h".
9423 * linux-low.c: Don't include sys/param.h.
9424 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
9425 MAXPATHLEN.
9426 * win32-low.c: Don't include sys/param.h.
9427 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
9428
bc7dea8d
PA
94292013-07-01 Pedro Alves <palves@redhat.com>
9430
9431 * event-loop.c: Don't check HAVE_UNISTD_H before including
9432 <unistd.h>.
9433 * gdbreplay.c: Likewise.
9434 * remote-utils.c: Likewise.
9435 * server.c: Likewise.
9436 * configure.ac: Don't check for unistd.h.
9437 * configure: Regenerate.
9438
d6c2da54
TT
94392013-06-28 Tom Tromey <tromey@redhat.com>
9440
9441 * Makefile.in (version.c): Use version.in, not
9442 common/version.in.
9443
257b6bec
MG
94442013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
9445
9446 * configure.ac (version_host, version_target): Set and AC_SUBST them.
9447 * configure: Rebuild.
9448 * Makefile.in (version_host, version_target): Get from configure.
9449 (version.c): Use $(version_host) and $(version_target).
9450
86ebe149
DK
94512013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
9452
9453 Fix trace-status to output user name without trailing colon.
9454 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
9455
f30aa5af
DK
94562013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
9457
9458 Fix trace-status to output proper start-time and stop-time.
9459 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
9460 output start time and stop time in hex as gdb expects.
9461
28a93511
YQ
94622013-06-26 Pedro Alves <pedro@codesourcery.com>
9463
9464 * tracepoint.c (build_traceframe_info_xml): Output trace state
9465 variables present in the trace buffer.
9466
01208463
TT
94672013-06-24 Tom Tromey <tromey@redhat.com>
9468
9469 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
9470 create-version.sh.
9471 (version.o): Remove.
9472 * gdbreplay.c: Include version.h.
9473 (version, host_name): Don't declare.
9474 * server.h: Include version.h.
9475 (version, host_name): Don't declare.
9476
760256f9
PA
94772013-06-12 Pedro Alves <palves@redhat.com>
9478
9479 * linux-x86-low.c (linux_is_elf64): Delete global.
9480 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
9481 with local linux_pid_exe_is_elf_64_file use.
9482
030031ee
PA
94832013-06-11 Pedro Alves <palves@redhat.com>
9484
9485 * linux-low.c (regset_disabled, disable_regset): New functions.
9486 (regsets_fetch_inferior_registers)
9487 (regsets_store_inferior_registers): Use them.
9488 (initialize_regsets_info); Don't allocate the disabled_regsets
9489 array here.
9490 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
9491 comment.
9492
5da6eb0a
PA
94932013-06-11 Pedro Alves <palves@redhat.com>
9494
9495 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
9496 xmalloc.
9497
7e5aaa09
PA
94982013-06-11 Pedro Alves <palves@redhat.com>
9499
9500 * linux-x86-low.c (initialize_low_arch): Call
9501 init_registers_x32_avx_linux.
9502
d878444c
JK
95032013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
9504
9505 Fix compatibility with Android Bionic.
9506 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
9507 it is not empty.
9508
3aee8918
PA
95092013-06-07 Pedro Alves <palves@redhat.com>
9510
5f2b57b5 9511 PR server/14823
3aee8918
PA
9512 * Makefile.in (OBS): Add tdesc.o.
9513 (IPA_OBJS): Add tdesc-ipa.o.
9514 (tdesc-ipa.o): New rule.
9515 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
9516 interface.
9517 * linux-low.c (new_inferior): Delete.
9518 (disabled_regsets, num_regsets): Delete.
9519 (linux_add_process): Adjust to set the new per-process
9520 new_inferior flag.
9521 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
9522 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
9523 was a stop. When calling arch_setup, switch the current inferior
9524 to the thread that got an event.
9525 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
9526 (regsets_fetch_inferior_registers)
9527 (regsets_store_inferior_registers): New regsets_info parameter.
9528 Adjust to use it.
9529 (linux_register_in_regsets): New regs_info parameter. Adjust to
9530 use it.
9531 (register_addr, fetch_register, store_register): New usrregs_info
9532 parameter. Adjust to use it.
9533 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
9534 parameter regs_info. Adjust to use it.
9535 (linux_fetch_registers): Get the current inferior's regs_info, and
9536 adjust to use it.
9537 (linux_store_registers): Ditto.
9538 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
9539 (initialize_low): Don't initialize the target_regsets here. Call
9540 initialize_low_arch.
9541 * linux-low.h (target_regsets): Delete declaration.
9542 (struct regsets_info): New.
9543 (struct usrregs_info): New.
9544 (struct regs_info): New.
9545 (struct process_info_private) <new_inferior>: New field.
9546 (struct linux_target_ops): Delete the num_regs, regmap, and
9547 regset_bitmap fields. New field regs_info.
9548 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
9549 * i387-fp.c (num_xmm_registers): Delete.
9550 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
9551 calls to new interface.
9552 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
9553 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
9554 Infer the number of xmm registers from the regcache's target
9555 description.
9556 * i387-fp.h (num_xmm_registers): Delete.
9557 * inferiors.c (add_thread): Don't install the thread's regcache
9558 here.
9559 * proc-service.c (gregset_info): Fetch the current inferior's
9560 regs_info. Adjust to use it.
9561 * regcache.c: Include tdesc.h.
9562 (register_bytes, reg_defs, num_registers)
9563 (gdbserver_expedite_regs): Delete.
9564 (get_thread_regcache): If the thread doesn't have a regcache yet,
9565 create one, instead of aborting gdbserver.
9566 (regcache_invalidate_one): Rename to ...
9567 (regcache_invalidate_thread): ... this.
9568 (regcache_invalidate_one): New.
9569 (regcache_invalidate): Only invalidate registers of the current
9570 process.
9571 (init_register_cache): Add target_desc parameter, and use it.
9572 (new_register_cache): Ditto. Assert the target description has a
9573 non zero registers_size.
9574 (regcache_cpy): Add assertions. Adjust.
9575 (realloc_register_cache, set_register_cache): Delete.
9576 (registers_to_string, registers_from_string): Adjust.
9577 (find_register_by_name, find_regno, find_register_by_number)
9578 (register_cache_size): Add target_desc parameter, and use it.
9579 (free_register_cache_thread, free_register_cache_thread_one)
9580 (regcache_release, register_cache_size): New.
9581 (register_size): Add target_desc parameter, and use it.
9582 (register_data, supply_register, supply_register_zeroed)
9583 (supply_regblock, supply_register_by_name, collect_register)
9584 (collect_register_as_string, collect_register_by_name): Adjust.
9585 * regcache.h (struct target_desc): Forward declare.
9586 (struct regcache) <tdesc>: New field.
9587 (init_register_cache, new_register_cache): Add target_desc
9588 parameter.
9589 (regcache_invalidate_thread): Declare.
9590 (regcache_invalidate_one): Delete declaration.
9591 (regcache_release): Declare.
9592 (find_register_by_number, register_cache_size, register_size)
9593 (find_regno): Add target_desc parameter.
9594 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
9595 declarations.
9596 * remote-utils.c: Include tdesc.h.
9597 (outreg, prepare_resume_reply): Adjust.
9598 * server.c: Include tdesc.h.
9599 (gdbserver_xmltarget): Delete declaration.
9600 (get_features_xml, process_serial_event): Adjust.
9601 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
9602 declare.
9603 (struct process_info) <tdesc>: New field.
9604 (ipa_tdesc): Declare.
9605 * tdesc.c: New file.
9606 * tdesc.h: New file.
9607 * tracepoint.c: Include tdesc.h.
9608 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
9609 (get_context_regcache): Adjust to pass ipa_tdesc down.
9610 (do_action_at_tracepoint): Adjust to get the register cache size
9611 from the context regcache's description.
9612 (traceframe_walk_blocks): Adjust to get the register cache size
9613 from the current trace frame's description.
9614 (traceframe_get_pc): Adjust to get current trace frame's
9615 description and pass it down.
9616 (gdb_collect): Adjust to get the register cache size from the
9617 IPA's description.
9618 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
9619 (gdbserver_xmltarget): Delete.
9620 (initialize_low_tracepoint): Set the ipa's target description.
9621 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
9622 (initialize_low_tracepoint): Set the ipa's target description.
9623 * linux-x86-low.c: Include tdesc.h.
9624 [__x86_64__] (is_64bit_tdesc): New.
9625 (ps_get_thread_area, x86_get_thread_area): Use it.
9626 (i386_cannot_store_register): Rename to ...
9627 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
9628 (i386_cannot_fetch_register): Rename to ...
9629 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
9630 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
9631 to new interface.
9632 (target_regsets): Rename to ...
9633 (x86_regsets): ... this.
9634 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
9635 interface.
9636 (x86_siginfo_fixup): Use is_64bit_tdesc.
9637 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
9638 (tdesc_x32_avx_linux, tdesc_x32_linux)
9639 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
9640 Declare.
9641 (x86_linux_update_xmltarget): Delete.
9642 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
9643 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
9644 (AMD64_LINUX_USER64_CS): New.
9645 (x86_linux_read_description): New, based on
9646 x86_linux_update_xmltarget.
9647 (same_process_callback): New.
9648 (x86_arch_setup_process_callback): New.
9649 (x86_linux_update_xmltarget): New.
9650 (x86_regsets_info): New.
9651 (amd64_linux_regs_info): New.
9652 (i386_linux_usrregs_info): New.
9653 (i386_linux_regs_info): New.
9654 (x86_linux_regs_info): New.
9655 (x86_arch_setup): Reimplement.
9656 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
9657 (x86_emit_ops): Ditto.
9658 (the_low_target): Adjust. Install x86_linux_regs_info,
9659 x86_cannot_fetch_register, and x86_cannot_store_register.
9660 (initialize_low_arch): New.
9661 * linux-ia64-low.c (tdesc_ia64): Declare.
9662 (ia64_fetch_register): Adjust.
9663 (ia64_usrregs_info, regs_info): New globals.
9664 (ia64_regs_info): New function.
9665 (the_low_target): Adjust.
9666 (initialize_low_arch): New function.
9667 * linux-sparc-low.c (tdesc_sparc64): Declare.
9668 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
9669 Adjust.
9670 (sparc_arch_setup): New function.
9671 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
9672 (the_low_target): Adjust.
9673 (initialize_low_arch): New function.
9674 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
9675 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
9676 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
9677 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
9678 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
9679 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
9680 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
9681 (tdesc_powerpc_isa205_vsx64l): Declare.
9682 (ppc_cannot_store_register, ppc_collect_ptrace_register)
9683 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
9684 (ppc_set_pc, ppc_get_hwcap): Adjust.
9685 (ppc_usrregs_info): Forward declare.
9686 (!__powerpc64__) ppc_regmap_adjusted: New global.
9687 (ppc_arch_setup): Adjust to the current process'es target
9688 description.
9689 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
9690 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
9691 (ppc_store_evrregset): Adjust.
9692 (target_regsets): Rename to ...
9693 (ppc_regsets): ... this, and make static.
9694 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
9695 (ppc_regs_info): New function.
9696 (the_low_target): Adjust.
9697 (initialize_low_arch): New function.
9698 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
9699 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
9700 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
9701 (tdesc_s390x_linux64v2): Declare.
9702 (s390_collect_ptrace_register, s390_supply_ptrace_register)
9703 (s390_fill_gregset, s390_store_last_break): Adjust.
9704 (target_regsets): Rename to ...
9705 (s390_regsets): ... this, and make static.
9706 (s390_get_pc, s390_set_pc): Adjust.
9707 (s390_get_hwcap): New target_desc parameter, and use it.
9708 [__s390x__] (have_hwcap_s390_high_gprs): New global.
9709 (s390_arch_setup): Adjust to set the current process'es target
9710 description. Don't adjust the regmap.
9711 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
9712 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
9713 (regs_info_3264): New globals.
9714 (s390_regs_info): New function.
9715 (the_low_target): Adjust.
9716 (initialize_low_arch): New function.
9717 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
9718 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
9719 [__mips64] (init_registers_mips_linux)
9720 (init_registers_mips_dsp_linux): Delete defines.
9721 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
9722 (have_dsp): New global.
9723 (mips_read_description): New, based on mips_arch_setup.
9724 (mips_arch_setup): Reimplement.
9725 (get_usrregs_info): New function.
9726 (mips_cannot_fetch_register, mips_cannot_store_register)
9727 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
9728 (mips_fill_fpregset, mips_store_fpregset): Adjust.
9729 (target_regsets): Rename to ...
9730 (mips_regsets): ... this, and make static.
9731 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
9732 (dsp_regs_info, regs_info): New globals.
9733 (mips_regs_info): New function.
9734 (the_low_target): Adjust.
9735 (initialize_low_arch): New function.
9736 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
9737 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
9738 Declare.
9739 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
9740 (arm_read_description): New, with bits factored from
9741 arm_arch_setup.
9742 (arm_arch_setup): Reimplement.
9743 (target_regsets): Rename to ...
9744 (arm_regsets): ... this, and make static.
9745 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
9746 (arm_regs_info): New function.
9747 (the_low_target): Adjust.
9748 (initialize_low_arch): New function.
9749 * linux-m68k-low.c (tdesc_m68k): Declare.
9750 (target_regsets): Rename to ...
9751 (m68k_regsets): ... this, and make static.
9752 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
9753 (m68k_regs_info): New function.
9754 (m68k_arch_setup): New function.
9755 (the_low_target): Adjust.
9756 (initialize_low_arch): New function.
9757 * linux-sh-low.c (tdesc_sharch): Declare.
9758 (target_regsets): Rename to ...
9759 (sh_regsets): ... this, and make static.
9760 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
9761 (sh_regs_info, sh_arch_setup): New functions.
9762 (the_low_target): Adjust.
9763 (initialize_low_arch): New function.
9764 * linux-bfin-low.c (tdesc_bfin): Declare.
9765 (bfin_arch_setup): New function.
9766 (bfin_usrregs_info, regs_info): New globals.
9767 (bfin_regs_info): New function.
9768 (the_low_target): Adjust.
9769 (initialize_low_arch): New function.
9770 * linux-cris-low.c (tdesc_cris): Declare.
9771 (cris_arch_setup): New function.
9772 (cris_usrregs_info, regs_info): New globals.
9773 (cris_regs_info): New function.
9774 (the_low_target): Adjust.
9775 (initialize_low_arch): New function.
9776 * linux-cris-low.c (tdesc_crisv32): Declare.
9777 (cris_arch_setup): New function.
9778 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
9779 (cris_regs_info): New function.
9780 (the_low_target): Adjust.
9781 (initialize_low_arch): New function.
9782 * linux-m32r-low.c (tdesc_m32r): Declare.
9783 (m32r_arch_setup): New function.
9784 (m32r_usrregs_info, regs_info): New globals.
9785 (m32r_regs_info): Adjust.
9786 (initialize_low_arch): New function.
9787 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
9788 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
9789 (tic6x_usrregs_info): Forward declare.
9790 (tic6x_read_description): New function, based on ...
9791 (tic6x_arch_setup): ... this. Reimplement.
9792 (target_regsets): Rename to ...
9793 (tic6x_regsets): ... this, and make static.
9794 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
9795 (tic6x_regs_info): New function.
9796 (the_low_target): Adjust.
9797 (initialize_low_arch): New function.
9798 * linux-xtensa-low.c (tdesc_xtensa): Declare.
9799 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
9800 (target_regsets): Rename to ...
9801 (xtensa_regsets): ... this, and make static.
9802 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
9803 globals.
9804 (xtensa_arch_setup, xtensa_regs_info): New functions.
9805 (the_low_target): Adjust.
9806 (initialize_low_arch): New function.
9807 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
9808 (nios2_arch_setup): Set the current process'es tdesc.
9809 (target_regsets): Rename to ...
9810 (nios2_regsets): ... this.
9811 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
9812 (nios2_regs_info): New function.
9813 (the_low_target): Adjust.
9814 (initialize_low_arch): New function.
a261b8f5
PA
9815 * linux-aarch64-low.c (tdesc_aarch64): Declare.
9816 (aarch64_arch_setup): Set the current process'es tdesc.
9817 (target_regsets): Rename to ...
9818 (aarch64_regsets): ... this.
9819 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
9820 (aarch64_regs_info): New function.
9821 (the_low_target): Adjust.
9822 (initialize_low_arch): New function.
3aee8918
PA
9823 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
9824 globals.
9825 (target_regsets): Rename to ...
9826 (tile_regsets): ... this.
9827 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
9828 (tile_regs_info): New function.
9829 (tile_arch_setup): Set the current process'es tdesc.
9830 (the_low_target): Adjust.
9831 (initialize_low_arch): New function.
9832 * spu-low.c (tdesc_spu): Declare.
9833 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
9834 * win32-arm-low.c (tdesc_arm): Declare.
9835 (arm_arch_setup): New function.
9836 (the_low_target): Install arm_arch_setup instead of
9837 init_registers_arm.
9838 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
9839 (init_windows_x86): Rename to ...
9840 (i386_arch_setup): ... this. Set `win32_tdesc'.
9841 (the_low_target): Adjust.
9842 * win32-low.c (win32_tdesc): New global.
9843 (child_add_thread): Don't create the thread cache here.
9844 (do_initial_child_stuff): Set the new process'es tdesc.
9845 * win32-low.h (struct target_desc): Forward declare.
9846 (win32_tdesc): Declare.
9847 * lynx-i386-low.c (tdesc_i386): Declare global.
9848 (lynx_i386_arch_setup): Set `lynx_tdesc'.
9849 * lynx-low.c (lynx_tdesc): New global.
9850 (lynx_add_process): Set the new process'es tdesc.
9851 * lynx-low.h (struct target_desc): Forward declare.
9852 (lynx_tdesc): Declare global.
9853 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
9854 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
9855 * nto-low.c (nto_tdesc): New global.
9856 (do_attach): Set the new process'es tdesc.
9857 * nto-low.h (struct target_desc): Forward declare.
9858 (nto_tdesc): Declare.
9859 * nto-x86-low.c (tdesc_i386): Declare.
9860 (nto_x86_arch_setup): Set `nto_tdesc'.
9861
b1fbec62
GB
98622013-06-04 Gary Benson <gbenson@redhat.com>
9863
9864 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
9865 to qSupported response when appropriate.
9866 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
9867 with nonzero-length annex.
9868 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
9869 arguments supplied in annex.
9870
d1ec4ce7
DE
98712013-05-31 Doug Evans <dje@google.com>
9872
ac44adcb 9873 PR server/15594
d1ec4ce7
DE
9874 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
9875 64 bits in 64-cross-32 environment.
9876
9b25f2d3
PA
98772013-05-28 Pedro Alves <palves@redhat.com>
9878
9879 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
9880 (aarch64-without-fpu.c): Delete rule.
9881 * configure.srv (aarch64*-*-linux*): Remove references to
9882 aarch64-without-fpu.o and aarch64-without-fpu.xml.
9883 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
9884 declaration.
9885
6740dc9c
PA
98862013-05-24 Pedro Alves <palves@redhat.com>
9887
9888 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
9889 instead of strchr/decode_address. Error if the range isn't split
9890 with a ','. Don't assume there's be a ':' in the action.
9891
c2d6af84
PA
98922013-05-23 Yao Qi <yao@codesourcery.com>
9893 Pedro Alves <palves@redhat.com>
9894
9895 * linux-low.c (lwp_in_step_range): New function.
9896 (linux_wait_1): If the thread was range stepping and stopped
9897 outside the stepping range, report the stop to GDB. Otherwise,
9898 continue stepping. Add range stepping debug output.
9899 (linux_set_resume_request): Copy the step range from the resume
9900 request to the lwp.
9901 (linux_supports_range_stepping): New.
9902 (linux_target_ops) <supports_range_stepping>: Set to
9903 linux_supports_range_stepping.
9904 * linux-low.h (struct linux_target_ops)
9905 <supports_range_stepping>: New field.
9906 (struct lwp_info) <step_range_start, step_range_end>: New fields.
9907 * linux-x86-low.c (x86_supports_range_stepping): New.
9908 (the_low_target) <supports_range_stepping>: Set to
9909 x86_supports_range_stepping.
9910 * server.c (handle_v_cont): Handle 'r' action.
9911 (handle_v_requests): Append ";r" if the target supports range
9912 stepping.
9913 * target.h (struct thread_resume) <step_range_start,
9914 step_range_end>: New fields.
9915 (struct target_ops) <supports_range_stepping>:
9916 New field.
9917 (target_supports_range_stepping): New macro.
9918
58794e1a
JB
99192013-05-17 Joel Brobecker <brobecker@adacore.com>
9920
9921 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
9922 confusion in comment.
9923
d631c5a7
JB
99242013-05-17 Joel Brobecker <brobecker@adacore.com>
9925
9926 * lynx-low.c (struct process_info_private): New type.
9927 (lynx_add_process): New function.
9928 (lynx_create_inferior, lynx_attach): Replace calls to
9929 add_process by calls to lynx_add_process.
9930 (lynx_resume): If PTID is null, then try using
9931 current_process()->private->last_wait_event_ptid.
9932 Add comments.
9933 (lynx_clear_inferiors): Delete. The contents of that function
9934 has been inlined in lynx_mourn;
9935 (lynx_wait_1): Save the ptid in the process's private data.
9936 (lynx_mourn): Free the process' private data. Replace call
9937 to lynx_clear_inferiors by call to clear_inferiors.
9938
96f7a20f
YQ
99392013-05-17 Yao Qi <yao@codesourcery.com>
9940
9941 * i386-low.c (i386_length_and_rw_bits): Move the comment to
9942 the right place.
9943
db0dfaa0
LM
99442013-05-16 Luis Machado <lgustavo@codesourcery.com>
9945
9946 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
9947 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
9948 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
9949 PT_TEXT_END_ADDR guards. Update comments.
9950 (linux_target_op) <read_offsets>: Conditionally define to
9951 linux_read_offsets if the target is UCLIBC and if it defines
9952 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
9953
68f5f838
SL
99542013-05-06 Sandra Loosemore <sandra@codesourcery.com>
9955 Andrew Jenner <andrew@codesourcery.com>
9956
9957 * Makefile.in (SFILES): Add linux-nios2-low.c.
9958 (clean): Add action to delete nios2-linux.c.
9959 (nios2-linux.c): New rule.
9960 * configure.srv: Add nios2*-*-linux*.
9961 * linux-nios2-low.c: New.
9962
1ebff1fd
HAQ
99632013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
9964
9965 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
9966
f6150862
HZ
99672013-04-25 Hui Zhu <hui@codesourcery.com>
9968
9969 PR gdb/15186
f6150862
HZ
9970 * ax.c (ax_printf): Add fflush.
9971
614c279d
TT
99722013-04-22 Tom Tromey <tromey@redhat.com>
9973
9974 * Makefile.in (SFILES): Add filestuff.c.
9975 (OBS): Add filestuff.o.
9976 (filestuff.o): New target.
9977 * config.in, configure: Rebuild.
9978 * configure.ac: Check for fdwalk, pipe2.
9979
7d4e5717
PA
99802013-04-17 Pedro Alves <palves@redhat.com>
9981
9982 * configure.ac (USE_THREAD_DB): Delete variable.
9983 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
9984 Don't AC_SUBST USE_THREAD_DB.
9985 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
9986 * config.in, configure: Regenerate.
9987
d5c93e41
PA
99882013-04-16 Pedro Alves <palves@redhat.com>
9989
9990 * linux-low.h (struct lwp_info) <thread_known>: Move under
9991 the USE_THREAD_DB #ifdef.
9992
04f5fe89
PA
99932013-04-16 Pedro Alves <palves@redhat.com>
9994
9995 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
9996 (linux-low.o): Delete rule.
9997 * linux-low.h: Always include "gdb_thread_db.h" instead of
9998 conditionally including thread_db.h.
9999 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
10000 HAVE_THREAD_DB_H.
10001
480b27bf
JK
100022013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
10003
10004 * Makefile.in (install-only): Fix make install regression.
10005
43662968
JK
100062013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
10007
10008 Convert man pages to texinfo, new gdbinit.5 texinfo page.
10009 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
10010 installation.
10011 * gdbserver.1: Remove.
10012
3e74e146
PA
100132013-03-22 Pedro Alves <palves@redhat.com>
10014
10015 * linux-low.c (handle_extended_wait): Don't call
10016 linux_enable_event_reporting.
10017
a8347a2a
TT
100182013-03-15 Tony Theodore <tonyt@logyst.com>
10019
10020 PR build/9098:
10021 * Makefile.in (SHELL): Use @SHELL@.
10022
eeb56fa7
SDJ
100232013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
10024
10025 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
10026 compiler warning.
10027
4fa7e2ff
JB
100282013-03-13 Joel Brobecker <brobecker@adacore.com>
10029
10030 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
10031 Remove extraneous NULL element.
10032
8ddb1965
YQ
100332013-03-13 Yao Qi <yao@codesourcery.com>
10034
10035 * tracepoint.c (traceframe_read_tsv): Look for the last matched
10036 'V' block in trace frame.
10037
9accd112
MM
100382013-03-11 Markus Metzger <markus.t.metzger@intel.com>
10039
10040 * target.h (struct target_ops): Add btrace ops.
10041 (target_supports_btrace): New macro.
10042 (target_enable_btrace): New macro.
10043 (target_disable_btrace): New macro.
10044 (target_read_btrace): New macro.
10045 * gdbthread.h (struct thread_info): Add btrace field.
10046 * server.c: Include btrace-common.h.
10047 (handle_btrace_general_set): New function.
10048 (handle_btrace_enable): New function.
10049 (handle_btrace_disable): New function.
10050 (handle_general_set): Call handle_btrace_general_set.
10051 (handle_qxfer_btrace): New function.
10052 (struct qxfer qxfer_packets[]): Add btrace entry.
10053 * inferiors.c (remove_thread): Disable btrace.
10054 * linux-low: Include linux-btrace.h.
10055 (linux_low_enable_btrace): New function.
10056 (linux_low_read_btrace): New function.
10057 (linux_target_ops): Add btrace ops.
10058 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
10059 Add srv_linux_btrace=yes.
10060 (x86_64-*-linux*): Add linux-btrace.o.
10061 Add srv_linux_btrace=yes.
10062 * configure.ac: Define HAVE_LINUX_BTRACE.
10063 * config.in: Regenerated.
10064 * configure: Regenerated.
10065
5cc22e4c
MM
100662013-03-11 Markus Metzger <markus.t.metzger@intel.com>
10067
10068 * server.c (handle_qxfer): Preserve error message if -3 is
10069 returned.
10070 (qxfer): Document the -3 return value.
10071
7c97f91e
MM
100722013-03-11 Markus Metzger <markus.t.metzger@intel.com>
10073
10074 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
10075 (linux_btrace_h): New variable.
10076 (linux-btrace.o): New rule.
10077
be9a119c 100782013-03-08 Stan Shebs <stan@codesourcery.com>
f6f899bf
HAQ
10079 Hafiz Abid Qadeer <abidh@codesourcery.com>
10080
10081 * tracepoint.c (trace_buffer_size): New global.
10082 (DEFAULT_TRACE_BUFFER_SIZE): New define.
10083 (init_trace_buffer): Change to one-argument function. Allocate
10084 trace buffer memory.
10085 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
10086 handle QTBuffer:size packet.
10087 (cmd_bigqtbuffer_size): New function.
10088 (initialize_tracepoint): Call init_trace_buffer with
10089 DEFAULT_TRACE_BUFFER_SIZE.
10090 * server.c (handle_query): Add QTBuffer:size in the
10091 supported packets.
10092
e64f7499
YQ
100932013-03-07 Yao Qi <yao@codesourcery.com>
10094
10095 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
10096 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
10097 of -1.
10098 (cmd_qtsp): Adjust condition. Do post increment.
10099 Set cur_action and cur_step_action back to 0.
10100
f0ae6fc3
PA
101012013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
10102
10103 PR server/15236
10104 * linux-low.c (linux_write_memory): Return early success if LEN is
10105 zero.
10106
b5b0b0af
CV
101072013-03-05 Corinna Vinschen <vinschen@redhat.de>
10108
334ad4a8 10109 * configure.srv: Add x86_64-*-cygwin* as target.
b5b0b0af 10110
589bc927
TT
101112013-02-28 Tom Tromey <tromey@redhat.com>
10112
10113 * configure.ac: Invoke AC_SYS_LARGEFILE.
10114 * configure, config.in: Rebuild.
10115
dfe07582
CV
101162013-02-28 Corinna Vinschen <vinschen@redhat.com>
10117
10118 * win32-low.c: Throughout, fix format strings and casts of
10119 printf-like functions to avoid type related warnings on all
10120 platforms.
10121 (get_child_debug_event): Print dwDebugEventCode as hex since
10122 that's how it's usually documented.
10123
736cd585
YQ
101242013-02-28 Yao Qi <yao@codesourcery.com>
10125
10126 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
10127 pulongest.
10128
e1f58301
JW
101292013-02-27 Jiong Wang <jiwang@tilera.com>
10130
10131 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
10132 (reg-tilegx32.c): New rule.
10133 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
10134 * linux-tile-low.c (tile_arch_setup): New function. Invoke
10135 different register info initializer according to elf class.
10136 (init_registers_tilgx32): New function. The tilegx32 register info
10137 initializer.
10138 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
10139 (tile_store_gregset): Likewise.
10140
d171ca78
YQ
101412013-02-27 Yao Qi <yao@codesourcery.com>
10142
10143 * server.c (process_point_options): Print debug message when
10144 debug_threads is true.
10145
282bbdf3
YQ
101462013-02-26 Yao Qi <yao@codesourcery.com>
10147
10148 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
10149
aca22551
PA
101502013-02-19 Pedro Alves <palves@redhat.com>
10151 Kai Tietz <ktietz@redhat.com>
10152
10153 PR gdb/15161
10154
10155 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
10156 instead of strtoul to extract address from packet.
10157 (process_serial_event) <'z'>: Likewise.
10158
4f3cee1c
YQ
101592013-02-18 Yao Qi <yao@codesourcery.com>
10160
10161 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
10162
8e1d55a3
PA
101632013-02-14 Pedro Alves <palves@redhat.com>
10164
10165 Plug memory leak.
10166
10167 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
10168 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
10169
458820da
PA
101702013-02-14 Pedro Alves <palves@redhat.com>
10171
10172 * tracepoint.c (cmd_qtdpsrc): Use savestring.
10173
baea0dae
PA
101742013-02-14 Pedro Alves <palves@redhat.com>
10175
10176 * tracepoint.c (save_string): Delete.
10177 (add_tracepoint_action): Use savestring instead of save_string.
10178
0b1afbb3
PA
101792013-02-12 Pedro Alves <palves@redhat.com>
10180
10181 * linux-xtensa-low.c: Ditto.
10182 * xtensa-xtregs.c: Ditto.
10183
8a4ac37e
PA
101842013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
10185
10186 * thread-db.c (thread_db_get_tls_address): NULL pointer check
10187 thread_db.
10188
148de6bb
MS
101892013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
10190
10191 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
10192 aarch64_num_wp_regs and aarch64_num_bp_regs to
10193 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
10194
55fac6e0
MS
101952013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
10196
10197 * linux-aarch64-low.c (ps_get_thread_area): Replace
10198 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
10199
176eb98c
MS
102002013-02-04 Jim MacArthur <jim.macarthur@arm.com>
10201 Marcus Shawcroft <marcus.shawcroft@arm.com>
10202 Nigel Stephens <nigel.stephens@arm.com>
10203 Yufeng Zhang <yufeng.zhang@arm.com>
10204
10205 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
10206 (aarch64.c, aarch64-without-fpu.c): New targets.
10207 * configure.srv (aarch64*-*-linux*): New.
10208 * linux-aarch64-low.c: New file.
10209
56f7af9c
MS
102102013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
10211
43aaf8b6 10212 * linux-low.c (handle_extended_wait, linux_create_inferior)
56f7af9c
MS
10213 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
10214 (dequeue_one_deferred_signal, linux_resume_one_thread)
10215 (fetch_register, linux_write_memory, linux_enable_event_reporting)
10216 (linux_tracefork_grandchild, linux_test_for_tracefork)
10217 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
10218 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
10219 where the argument is 0.
10220
60f662b0
YQ
102212013-01-25 Yao Qi <yao@codesourcery.com>
10222
10223 * event-loop.c: Include "queue.h".
10224 (gdb_event_p): New typedef.
10225 (struct gdb_event) <next_event>: Remove.
10226 (event_queue): Change to QUEUE(gdb_event_p).
10227 (async_queue_event): Remove.
10228 (gdb_event_xfree): New.
10229 (initialize_event_loop): New.
10230 (process_event): Use API from QUEUE.
10231 (wait_for_event): Likewise.
10232 * server.c (main): Call initialize_event_loop.
10233 * server.h (initialize_event_loop): Declare.
10234
5ae4861a
YQ
102352013-01-18 Yao Qi <yao@codesourcery.com>
10236
10237 * ax.h (struct eval_agent_expr_context): New.
10238 (gdb_eval_agent_expr): Update declaration.
10239 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
10240 TFRAME. Add new argument CTX.
10241 * server.h (struct eval_agent_expr_context): Declare.
10242 (agent_mem_read, agent_tsv_read): Update declaration.
10243 (agent_mem_read_string): Likewise.
10244 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
10245 (add_traceframe_block): Add new argument TPOINT.
10246 Increase TPOINT->traceframe_usage.
10247 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
10248 eval_tracepoint_agent_expr.
10249 (condition_true_at_tracepoint): Likewise.
10250 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
10251 (agent_mem_read_string, agent_tsv_read): Likewise.
10252
85e00e85
YQ
102532013-01-16 Yao Qi <yao@codesourcery.com>
10254
10255 * linux-low.c (linux_resume_one_lwp): Don't check
10256 'lwp->bp_reinsert != 0'.
10257
4039cf45
JB
102582013-01-07 Joel Brobecker <brobecker@adacore.com>
10259 Pedro Alves <palves@redhat.com>
10260
10261 * lynx-low.c (ptrace_request_to_str): Define a temporary
10262 macro and use it to simplify this function's implementation.
10263
9044dee2
JB
102642013-01-07 Joel Brobecker <brobecker@adacore.com>
10265
10266 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
10267 sets errno.
10268
e6352c8f
JB
102692013-01-07 Joel Brobecker <brobecker@adacore.com>
10270
10271 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
10272
50681a27
JB
102732013-01-07 Joel Brobecker <brobecker@adacore.com>
10274
10275 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
10276
3f6e77ef
JB
102772013-01-07 Joel Brobecker <brobecker@adacore.com>
10278
10279 * lynx-low.c (lynx_resume): Use the resume_info parameter
10280 to determine the ptid for the lynx_ptrace call, unless
10281 it is equal to minus_one_ptid, in which case we use the
10282 ptid of the current_inferior.
10283 (lynx_wait_1): After having received a thread create/exit
10284 event, resume the inferior's execution using the signaling
10285 thread's ptid, rather than the old ptid.
10286
7fda33ae
JB
102872013-01-07 Joel Brobecker <brobecker@adacore.com>
10288
10289 * lynx-low.c (lynx_resume): Delete variable ret.
10290
b9786c74
JB
102912013-01-01 Joel Brobecker <brobecker@adacore.com>
10292
10293 * gdbreplay.c (gdbreplay_version): Update copyright year.
10294 * server.c (gdbserver_version): Likewise.
10295
8b93d60f
JB
102962012-12-17 Joel Brobecker <brobecker@adacore.com>
10297
10298 * lynx-low.c (lynx_wait_1): Add debug trace before adding
10299 new thread.
10300
037335a7
JB
103012012-12-17 Joel Brobecker <brobecker@adacore.com>
10302
10303 * lynx-low.c (ptrace_request_to_str): Add handling for
10304 PTRACE_GETTRACESIG.
10305
52d4cbd8
JB
103062012-12-17 Joel Brobecker <brobecker@adacore.com>
10307
10308 * lynx-low.c (lynx_attach): Delete variable new_process.
10309
ab8f6ca9
JB
103102012-12-17 Joel Brobecker <brobecker@adacore.com>
10311
10312 * lynx-low.c (lynx_create_inferior): Delete variable
10313 new_process.
10314
78cbc024
JB
103152012-12-17 Joel Brobecker <brobecker@adacore.com>
10316
10317 * lynx-low.c (ptrace_request_to_str): Do not handle
10318 PTRACE_GETTHREADLIST if this macro does not exist.
10319
14a00470
YQ
103202012-12-15 Yao Qi <yao@codesourcery.com>
10321
10322 * Makefile.in (OBS): Add notif.o.
10323 * notif.c, notif.h: New.
10324 * server.c: Include "notif.h".
10325 (struct vstop_notif) <next>: Remove.
10326 <base>: New field.
10327 (queue_stop_reply): Update.
10328 (push_event, send_next_stop_reply): Remove.
10329 (discard_queued_stop_replies): Update.
10330 (notif_stop): New variable.
10331 (handle_v_stopped): Remove.
10332 (handle_v_requests): Don't call handle_v_stopped. Call
10333 handle_ack_notif instead.
10334 (queue_stop_reply_callback): Call notif_event_enque instead
10335 of queue_stop_reply.
10336 (handle_status): Don't call send_next_stop_reply, call
10337 notif_write_event instead.
10338 (kill_inferior_callback): Likewise.
10339 (detach_or_kill_inferior_callback): Likewise.
10340 (main): Call initialize_notif.
10341 (process_serial_event): Call QUEUE_is_empty.
10342 (handle_target_event): Call notif_push instead of push event.
10343 * server.h (push_event): Remove declaration.
10344
61c125b9
TT
103452012-12-10 Tom Tromey <tromey@redhat.com>
10346
10347 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
10348 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
10349 macros.
10350 (.c.o): Rewrite.
10351 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
10352 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
10353 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
10354 (amd64-linux-ipa.o, ax.o): Rewrite.
10355 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
10356 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
10357 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
10358 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
10359 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
10360 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
10361 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
10362 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
10363 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
10364 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
10365 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
10366 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
10367 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
10368 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
10369 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
10370 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
10371 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
10372 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
10373 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
10374 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
10375 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
10376 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
10377 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
10378 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
10379 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
10380 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
10381 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
10382 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
10383 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
10384 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
10385 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
10386 (reg-tilegx.o): Remove.
10387 (all_object_files): New macro.
10388 Include .deps files.
10389 * aclocal.m4, configure: Rebuild.
10390 * acinclude.m4: Include depstand.m4, lead-dot.m4.
10391 * configure.ac: Invoke ZW_CREATE_DEPDIR,
10392 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
10393
e90e9ad9
TT
103942012-12-05 Tom Tromey <tromey@redhat.com>
10395
10396 PR gdb/14917:
10397 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
10398
02d403bf 103992012-11-28 Markus Metzger <markus.t.metzger@intel.com>
945bf713
MM
10400
10401 * configure.ac: Check for linux/perf_event.h.
10402 * config.in: Regenerated.
10403 * configure: Regenerated.
10404
0270a750
PA
104052012-11-26 Maxime Villard <rustyBSD@gmx.fr>
10406
10407 * hostio.c (handle_readlink): Decrease buffer size
10408 parameter passed to readlink by one byte.
10409
8c29b58e
YQ
104102012-11-26 Yao Qi <yao@codesourcery.com>
10411
10412 * configure.ac (build_warnings): Append '-Wempty-body'.
10413 * configure: Regenerated.
10414 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
10415 body.
10416
8bdce1ff
PM
104172012-11-15 Pierre Muller <muller@sourceware.org>
10418
10419 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
10420 * config.in: Regenerate.
10421 * configure: Regenerate.
10422 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
10423 Use "gdb_wait.h" header instead of <sys/wait.h> header.
10424 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
10425 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
10426 header.
10427 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
10428 instead of <sys/wait.h> header.
10429 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
10430
02d403bf 104312012-11-13 Markus Metzger <markus.t.metzger@intel.com>
3ba6ad0f
MM
10432
10433 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
10434 (various make rules): Remove -DGDBSERVER
10435
fbd5db48
YQ
104362012-11-09 Yao Qi <yao@codesourcery.com>
10437
10438 * spu-low.c (current_ptid): Move it to ..
10439 * gdbthread.h: ... here. New.
10440 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
10441 * server.c (myresume, process_serial_event): Likewise.
10442 * thread-db.c (thread_db_find_new_threads): Likewise.
10443 * tracepoint.c (run_inferior_command): Likewise.
10444
b3dc46ff
AB
104452012-10-01 Andrew Burgess <aburgess@broadcom.com>
10446
10447 * server.c (handle_search_memory_1): Include access length in
10448 warning message.
10449
07c04788
HPN
104502012-09-05 Michael Brandt <michael.brandt@axis.com>
10451
10452 * linux-crisv32-low.c: Fix compile errors.
10453
918d227b
YQ
104542012-09-04 Yao Qi <yao@codesourcery.com>
10455
10456 * tracepoint.c (cmd_qtsv): Adjust debug message.
10457 Don't check CUR_TPOINT.
10458
18c1b81a
YQ
104592012-08-28 Yao Qi <yao@codesourcery.com>
10460
10461 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
10462 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
10463 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
10464 Remove declarations of xmalloc, xreallloc, xstrdup and
10465 freeargv.
10466 * Makefile.in (libiberty_h): New.
10467 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
10468 (linux-bfin-low.o): Append dependency 'libiberty.h'.
10469
dc82f37b
YQ
104702012-08-23 Yao Qi <yao@codesourcery.com>
10471
10472 * server.h: Remove declaration of 'xsnprintf'.
10473
406b1477
KS
104742012-08-22 Keith Seitz <keiths@redhat.com>
10475
10476 * server.h: Include build-gnulib-gbserver/config.h.
10477 * gdbreplay.c: Likewise.
10478
e6712ff1
DE
104792012-08-08 Doug Evans <dje@google.com>
10480
10481 * Makefile.in (SFILES): Add gdb_vecs.c.
10482 (OBS): Add gdb_vecs.o.
10483 (gdb_vecs_h, host_defs_h): New variables.
10484 (thread-db.o): Add $(gdb_vecs_h) dependency.
10485 (gdb_vecs.o): New rule.
10486 * thread-db.c: #include "gdb_vecs.h".
10487 (thread_db_load_search): Use a vector to iterate over path elements.
10488 Handle text appearing after "$pdir".
10489
10490 * configure.ac: Add check for strstr.
10491 * config.in: Regenerate.
10492 * configure: Regenerate.
10493
7c3270ae
UW
104942012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
10495
10496 * hostio.c (handle_pread): If pread fails, fall back to attempting
10497 lseek/read.
10498 (handle_pwrite): Likewise for pwrite.
10499
b62e2b27
UW
105002012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
10501
10502 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
10503 between unsupported TYPE and unimplementable ADDR/LEN combination.
10504 (arm_insert_point): Act on new return value.
10505
78a99e91
PA
105062012-07-31 Pedro Alves <palves@redhat.com>
10507
10508 * server.c (process_point_options): Only skip tokens if we find
10509 one that is unrecognized. Don't treat 'X' specially while
10510 skipping unrecognized tokens.
10511
fcf303ab
UW
105122012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
10513
10514 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
10515 to 4-byte-align HW breakpoint addresses for Thumb.
10516
7255706c
YQ
105172012-07-27 Yao Qi <yao@codesourcery.com>
10518
10519 PR remote/14161.
10520
10521 * server.h: Declare gdb_agent_about_to_close.
10522 * target.c (kill_inferior): Include "agent.h".
10523 New. Send command 'kill'.
10524 * target.h (kill_inferior): Removed macro.
10525 * tracepoint.c (gdb_agent_about_to_close): New.
10526 (gdb_agent_helper_thread): Handle command 'close'.
10527 Wait endlessly until the inferior stops.
10528 Install gdb_agent_remove_socket to atexit hook.
10529 (agent_socket_name): New static variable.
10530 (gdb_agent_socket_init): Replace local variable 'name' with
10531 'agent_socket_name'.
10532 (gdb_agent_remove_socket): New.
10533
5a3f286f
YQ
105342012-07-27 Yao Qi <yao@codesourcery.com>
10535
10536 * server.c (process_point_options): Stop at 'X' when parsing.
10537
961bd387
ME
105382012-07-19 Michael Eager <eager@eagercon.com>
10539
a261b8f5 10540 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
961bd387
ME
10541 to hw_execute.
10542 * linux-x86-low.c (x86_insert_point, x86_remove_point):
10543 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
10544 hardware breakpoint.
10545
aa7c7447
JK
105462012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
10547
10548 * gdbserver/linux-low.c (initialize_low): Call
10549 linux_ptrace_init_warnings.
10550
7f216e7c
DE
105512012-07-02 Doug Evans <dje@google.com>
10552
10553 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
10554 pointer to int.
10555
d3ce09f5
SS
105562012-07-02 Stan Shebs <stan@codesourcery.com>
10557
10558 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
10559 (ax.o): Add it to build rule.
10560 (ax-ipa.o): Ditto.
10561 (OBS): Add format.o.
10562 (IPA_OBS): Add format.o.
10563 * server.c (handle_query): Claim support for breakpoint commands.
10564 (process_point_options): Add command case.
10565 (process_serial_event): Leave running if there are printfs in
10566 effect.
10567 * mem-break.h (any_persistent_commands): Declare.
10568 (add_breakpoint_commands): Declare.
10569 (gdb_no_commands_at_breakpoint): Declare.
10570 (run_breakpoint_commands): Declare.
10571 * mem-break.c (struct point_command_list): New struct.
10572 (struct breakpoint): New field command_list.
10573 (any_persistent_commands): New function.
10574 (add_commands_to_breakpoint): New function.
10575 (add_breakpoint_commands): New function.
10576 (gdb_no_commands_at_breakpoint): New function.
10577 (run_breakpoint_commands): New function.
10578 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
10579 locally.
10580 * ax.c: Include format.h.
10581 (ax_printf): New function.
10582 (gdb_eval_agent_expr): Add printf opcode.
10583
2f8f6aed
YQ
105842012-06-13 Yao Qi <yao@codesourcery.com>
10585
10586 * server.c (start_inferior): Remove duplicated writes to fields
10587 'last_resume_kind' and 'last_status' of 'current_inferior'.
10588
0c9070b3
YQ
105892012-06-12 Yao Qi <yao@codesourcery.com>
10590 Pedro Alves <palves@redhat.com>
10591
10592 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
10593 comment.
10594 * server.c (handle_v_cont): Extend comment.
10595
c52daf70
YQ
105962012-06-11 Yao Qi <yao@codesourcery.com>
10597
10598 * linux-low.c (linux_attach): Add 'static'.
10599
d38bbb0a
YQ
106002012-06-06 Yao Qi <yao@codesourcery.com>
10601
10602 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
10603
89dc0afd
JK
106042012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
10605
10606 Fix gcc -flto compilation warning.
10607 * server.c (main): Make variable multi_mode and attach volatile.
10608
75f62ce7
TJB
106092012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10610
10611 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
10612 if the platform doesn't know about it.
10613
65f479b6
PA
106142012-05-30 Jeff Kenton <jkenton@tilera.com>
10615
10616 * Makefile.in (SFILES): Add linux-tile-low.c.
10617 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
10618 * configure.srv: Handle tilegx-*-linux*.
10619 * linux-tile-low.c: New file.
10620
0c5bf5a9
JK
106212012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
10622
10623 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
10624
a493e3e2
PA
106252012-05-24 Pedro Alves <palves@redhat.com>
10626
10627 PR gdb/7205
10628
43aaf8b6 10629 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
a493e3e2 10630
2ea28649
PA
106312012-05-24 Pedro Alves <palves@redhat.com>
10632
10633 PR gdb/7205
10634
10635 Replace target_signal with gdb_signal throughout.
10636
8d409d16
MR
106372012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
10638
10639 * linux-low.c (linux_store_registers): Avoid the copying sequence
10640 when no data has been retrieved by ptrace.
10641
23512c01
MGD
106422012-05-22 Will Deacon <will.deacon@arm.com>
10643
10644 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
10645 Include asm/ptrace.h.
10646 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
10647 already defined.
10648
4934b29e
MR
106492012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
10650
10651 * linux-low.c (linux_store_registers): Don't re-retrieve data
10652 with ptrace that has already been obtained from /proc. Always
10653 copy any data retrieved with ptrace to the buffer supplied.
10654
bde24c0a
PA
106552012-05-11 Yao Qi <yao@codesourcery.com>
10656 Pedro Alves <palves@redhat.com>
10657
10658 * linux-low.c (enum stopping_threads_kind): New.
10659 (stopping_threads): Change type to `enum stopping_threads_kind'.
10660 (handle_extended_wait): If stopping and suspending threads, leave
10661 the new_lwp suspended too.
10662 (linux_wait_for_event): Adjust.
10663 (stop_all_lwps): Set `stopping_threads' to
10664 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
10665 whether we're suspending threads or just stopping them. Assert no
10666 recursion happens.
10667
623b6bdf
YQ
106682012-04-29 Yao Qi <yao@codesourcery.com>
10669
10670 * server.h: Move some code to ...
10671 * gdbthread.h: ... here. New.
10672 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
10673 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
10674 (nto-low.o, win32-low.o): Likewise.
10675 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
10676 * regcache.c, remote-utils.c, server.c: Likewise.
10677 * target.c, tracepoint.c, win32-low.c: Likewise.
10678
f15f9948
TJB
106792012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10680
10681 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
10682 (PTRACE_ARG4_TYPE): Likewise.
10683 (PTRACE_XFER_TYPE): Likewise.
10684 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
10685 ptrace to PTRACE_ARG3_TYPE.
10686 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
10687 (PTRACE_ARG4_TYPE): Likewise.
10688 (PTRACE_XFER_TYPE): Likewise.
10689 (linux_detach_one_lwp): Cast fourth argument of
10690 ptrace to long then PTRACE_ARG4_TYPE.
10691 (regsets_fetch_inferior_registers): Cast third argument of
10692 ptrace to long then PTRACE_ARG3_TYPE.
10693 (regsets_store_inferior_registers): Likewise.
10694
38ea300a
PA
106952012-04-20 Pedro Alves <palves@redhat.com>
10696
10697 * configure: Regenerate.
10698
c971b7fa
PA
106992012-04-19 Pedro Alves <palves@redhat.com>
10700
43aaf8b6 10701 * Makefile.in (GNULIB_BUILDDIR): New.
c971b7fa 10702 (LIBGNU, INCGNU, GNULIB_H): Adjust.
43aaf8b6
PA
10703 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
10704 (all, install-only, uninstall, clean-info, all-lib, clean): No
10705 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
10706 (maintainer-clean realclean distclean): Use subdir_do.
10707 (subdir_do): New.
10708 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
c971b7fa 10709 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
43aaf8b6
PA
10710 * acinclude.m4: Include acx_configure_dir.m4.
10711 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
10712 calls. Call AC_PROG_RANLIB. Configure gnulib using
10713 ACX_CONFIGURE_DIR.
10714 (GNULIB): New.
10715 (GNULIB_STDINT_H): Adjust.
10716 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
10717 * gdbreplay.c: Include build-gnulib/config.h.
10718 * server.h: Likewise.
10719 * aclocal.m4: Regenerate.
10720 * config.in: Regenerate.
10721 * configure: Regenerate.
c971b7fa 10722
809277f8
PA
107232012-04-19 Pedro Alves <palves@redhat.com>
10724
10725 * Makefile.in (LIBGNU, INCGNU): Adjust.
10726 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
10727 (all, install-only, uninstall, clean-info, all-lib, clean)
10728 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
10729 * configure.ac: Adjust AC_OUTPUT output.
10730 * aclocal.m4: Regenerate.
10731 * configure: Regenerate.
10732
fd9bb8b8
PA
107332012-04-19 Pedro Alves <palves@redhat.com>
10734
10735 * Makefile.in (generated_files): New.
10736 (server_h): Remove the explicit dependency on config.h, and depend
10737 on $generated_files.
10738
1c298c66
PA
107392012-04-19 Pedro Alves <palves@redhat.com>
10740
10741 * Makefile.in (INCGNU): Add -Ignulib.
10742
57c4b50b
PA
107432012-04-19 Pedro Alves <palves@redhat.com>
10744
10745 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
10746 (INCGNU): ... this, and spell out -I here.
10747 (GNULIB_LIB): Rename to ...
10748 (LIBGNU): ... this.
10749 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
10750
1030e047
PA
107512012-04-19 Pedro Alves <palves@redhat.com>
10752
10753 * config.in: Regenerate.
10754
447d4319
PA
107552012-04-19 Pedro Alves <palves@redhat.com>
10756
10757 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
10758 * server.h (memmem): Remove declaration.
10759 * config.in: Regenerate.
10760 * configure: Regenerate.
10761
aad9eab9
YQ
107622012-04-19 Yao Qi <yao@codesourcery.com>
10763
10764 * Makefile.in (SFILES): Add common/vec.c.
10765 (OBS): Add vec.o.
10766 (vec.o): New rule.
10767
3e10640f
YQ
107682012-04-19 Yao Qi <yao@codesourcery.com>
10769
10770 * remote-utils.c (prepare_resume_reply): Replace with macro
10771 target_core_of_thread.
10772 * server.c (handle_qxfer_threads_proper): Likewise.
10773 * target.h (traget_core_of_thread): New macro.
10774
71622373
PA
107752012-04-18 Pedro Alves <palves@redhat.com>
10776
10777 * aclocal.m4: Regenerate.
10778 * configure: Regenerate.
10779
80d26939
YQ
107802012-04-16 Yao Qi <yao@codesourcery.com>
10781
10782 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
10783 duplicated on address.
10784
42476b70
YQ
107852012-04-16 Yao Qi <yao@codesourcery.com>
10786
10787 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
10788 (struct tracepoint_action_ops) <send>: New field.
10789 (m_tracepoint_action_send, r_tracepoint_action_send): New.
10790 (agent_expr_send, x_tracepoint_action_send): New.
10791 (l_tracepoint_action_send): New.
10792 (cmd_qtdp): Download and install tracepoint
10793 according to `use_agent'.
10794 (run_inferior_command): Add one more parameter `len'.
10795 Update callers.
10796 (tracepoint_send_agent): New.
10797 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
10798
7bc83639
YQ
107992012-04-16 Yao Qi <yao@codesourcery.com>
10800
10801 * tracepoint.c (download_tracepoints): Moved to ...
10802 (cmd_qtstart): ... here.
10803
5f18041e
YQ
108042012-04-14 Yao Qi <yao@codesourcery.com>
10805
10806 * tracepoint.c: Include inttypes.h.
10807 (struct collect_memory_action): Use sized types.
10808 (struct tracepoint): Likewise.
10809 (cmd_qtdp, stop_tracing): Update print specifiers.
10810 (cmd_qtp, response_tracepoint): Likewise.
10811 (collect_data_at_tracepoint): Likewise.
10812 (collect_data_at_step): Likewise.
10813
55a8c076
YQ
108142012-04-14 Yao Qi <yao@codesourcery.com>
10815
10816 Import gnulib module inttypes.
10817 * aclocal.m4, config.in, configure: Regenerated.
10818
dc750257
YQ
108192012-04-14 Yao Qi <yao@codesourcery.com>
10820
10821 * Makefile.in (maintainer-clean, realclean, distclean): Remove
10822 Makefile and config.status at last.
10823
0ab5faf9
YQ
108242012-04-13 Yao Qi <yao@codesourcery.com>
10825
10826 * tracepoint.c: Include stdint.h unconditionally.
10827
18f5fd81
TJB
108282012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10829
10830 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
10831 on BFD_HAVE_SYS_PROCFS_TYPE.
10832 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
10833 * configure: Regenerate.
10834 * config.in: Likewise.
10835
4d47af5c
L
108362012-04-13 H.J. Lu <hongjiu.lu@intel.com>
10837
10838 * Makefile.in (clean): Also remove x32.c x32-linux.c
10839 x32-avx.c x32-avx-linux.c.
10840 (x32.o): New target.
10841 (x32.c): Likewise.
10842 (x32-linux.o): Likewise.
10843 (x32-linux.c): Likewise.
10844 (x32-avx.o): Likewise.
10845 (x32-avx.c): Likewise.
10846 (x32-avx-linux.o): Likewise.
10847 (x32-avx-linux.c): Likewise.
10848
10849 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
10850 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
10851 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
10852 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
10853 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
10854 i386/x32-avx-linux.xml.
10855
10856 * linux-x86-low.c (init_registers_x32_linux): New prototype.
10857 (init_registers_x32_avx_linux): Likwise.
10858 (x86_linux_update_xmltarget): Call init_registers_x32_linux
10859 or init_registers_x32_avx_linux if linux_is_elf64 is false.
10860
ecedbe58
PA
108612012-04-13 Pedro Alves <palves@redhat.com>
10862
10863 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
10864 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
10865 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
10866 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
10867 the sub-make.
10868
c92b5177
L
108692012-04-12 H.J. Lu <hongjiu.lu@intel.com>
10870
10871 * linux-x86-low.c (compat_x32_clock_t): New.
10872 (compat_x32_siginfo_t): Likewise.
10873 (compat_x32_siginfo_from_siginfo): Likewise.
10874 (siginfo_from_compat_x32_siginfo): Likewise.
10875 (linux_is_elf64): Likewise.
10876 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
10877 and siginfo_from_compat_x32_siginfo for x32.
10878 (x86_arch_setup): Set linux_is_elf64.
10879
214d508e
L
108802012-04-12 H.J. Lu <hongjiu.lu@intel.com>
10881
10882 PR gdb/13969
10883 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
10884 e_machine field.
10885 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
10886 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
10887 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
10888 compatible with process.
10889
c9a1864a
YQ
108902012-04-12 Yao Qi <yao@codesourcery.com>
10891
10892 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
10893 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
10894 (install-only, install-info, clean): Handle sub dir gnulib.
10895 (all-lib, am--refresh): New targets.
10896 (memmem.o): Remove target.
10897 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
10898 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
10899 (AC_REPLACE_FUNCS): Remove memmem.
10900 Invoke gl_INIT and AM_INIT_AUTOMAKE.
10901 (AC_OUTPUT): Generate Makefile in gnulib/.
10902 * aclocal.m4, config.in, configure: Regenerated.
10903
367ba2c2
MR
109042012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
10905
10906 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
10907
9d236627
PA
109082012-04-05 Pedro Alves <palves@redhat.com>
10909
10910 -Werror=strict-aliasing
10911
10912 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
10913 pointer.
10914
111217b3
PA
109152012-04-04 Pedro Alves <palves@redhat.com>
10916
10917 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
10918 (sparc_store_gregset_from_stack, sparc_store_gregset)
10919 (sparc_breakpoint_at): Fix formatting.
10920
8365dcf5
TJB
109212012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10922
10923 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
10924 are available.
10925 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
10926 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
10927 * config.in: Regenerate.
10928 * configure: Likewise.
10929
689cc2ae
PA
109302012-03-29 Pedro Alves <palves@redhat.com>
10931
10932 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
10933 Correct ptrace arguments.
10934
c14dfd32
PA
109352012-03-28 Pedro Alves <palves@redhat.com>
10936
10937 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
10938 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
10939 (IA64_FR1_REGNUM): New defines.
10940 (ia64_fetch_register): New.
10941 (the_low_target): Install it.
10942 * linux-low.h (struct linux_target_ops) <fetch_register>: New
10943 field.
10944 * linux-low.c (linux_fetch_registers): Try the
10945 the_low_target.fetch_register hook first.
10946
10947 * linux-arm-low.c (the_low_target): Adjust.
10948 * linux-bfin-low.c (the_low_target): Adjust.
10949 * linux-cris-low.c (the_low_target): Adjust.
10950 * linux-crisv32-low.c (the_low_target): Adjust.
10951 * linux-m32r-low.c (the_low_target): Adjust.
10952 * linux-m68k-low.c (the_low_target): Adjust.
10953 * linux-mips-low.c (the_low_target): Adjust.
10954 * linux-ppc-low.c (the_low_target): Adjust.
10955 * linux-s390-low.c (the_low_target): Adjust.
10956 * linux-sh-low.c (the_low_target): Adjust.
10957 * linux-sparc-low.c (the_low_target): Adjust.
10958 * linux-tic6x-low.c (the_low_target): Adjust.
10959 * linux-x86-low.c (the_low_target): Adjust.
10960 * linux-xtensa-low.c (the_low_target): Adjust.
10961
63c88e13
PA
109622012-03-26 Pedro Alves <palves@redhat.com>
10963
10964 * server.c (handle_qxfer_libraries): Don't bail early if
10965 the_target->qxfer_libraries_svr4 is not NULL.
10966
fb723180
PA
109672012-03-26 Pedro Alves <palves@redhat.com>
10968
10969 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
10970
0afae3cf
PA
109712012-03-23 Pedro Alves <palves@redhat.com>
10972
10973 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
10974 "library-list-svr4" element's start tag when the the DSO list is
10975 empty.
10976
485f1ee4
PA
109772012-03-23 Pedro Alves <palves@redhat.com>
10978
10979 * linux-low.c (read_one_ptr): Read the inferior's pointer through
10980 a variable whose type size is the same as the inferior's pointer
10981 size.
10982
a5362b9a
TS
109832012-03-21 Thomas Schwinge <thomas@codesourcery.com>
10984
10985 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
10986 struct siginfo.
10987 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
10988 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
10989 * linux-low.h: Include <signal.h>.
10990 (struct siginfo): Remove forward declaration.
10991 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
10992 struct siginfo.
10993
d226c142
MF
109942012-03-21 Mike Frysinger <vapier@gentoo.org>
10995
10996 * .gitignore: Ignore more files.
10997
122f36ef
PA
109982012-03-19 Pedro Alves <palves@redhat.com>
10999 Jan Kratochvil <jan.kratochvil@redhat.com>
11000
11001 * server.c (cont_thread, general_thread): Add describing comments.
11002 (start_inferior): Clear `cont_thread'.
11003 (handle_v_cont): Don't set `cont_thread' if resuming all threads
11004 of a process.
11005
fc3e5175
YQ
110062012-03-15 Yao Qi <yao@codesourcery.com>
11007
11008 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
11009 handling to ...
11010 (cmd_qtdp): ... here.
11011
8d0d92cd
YQ
110122012-03-15 Yao Qi <yao@codesourcery.com>
11013
11014 * tracepoint.c (struct tracepoint_action_ops): New.
11015 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
11016 (m_tracepoint_action_download): New.
11017 (r_tracepoint_action_download): New.
11018 (x_tracepoint_action_download): New.
11019 (l_tracepoint_action_download): New.
11020 (add_tracepoint_action): Install `action->ops' according type.
11021 (download_tracepoint_1): Move code `download' function pointer
11022 of various tracepoint_action_ops.
11023
87b0bb13
JK
110242012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
11025
11026 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
11027 linux_ptrace_attach_warnings.
11028
5f572dec
JK
110292012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
11030
11031 * Makefile.in (linux-ptrace.o): New.
11032 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
11033 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
11034 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
11035 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
11036 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
11037 of these targets.
11038 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
11039
f4647387
YQ
110402012-03-08 Yao Qi <yao@codesourcery.com>
11041 Pedro Alves <palves@redhat.com>
11042
11043 Fix PR server/13392.
11044 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
11045 offset of JMP insn.
11046 * tracepoint.c (remove_tracepoint): New.
11047 (cmd_qtdp): Call remove_tracepoint when failed to install.
11048
9b224c5e
PA
110492012-03-07 Pedro Alves <palves@redhat.com>
11050
11051 * linux-low.c (get_detach_signal): New.
11052 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
11053 Pass on pending signals to PTRACE_DETACH. Check the result of the
11054 ptrace call.
11055 * server.c (program_signals, program_signals_p): New.
11056 (handle_general_set): Handle QProgramSignals.
11057 * server.h (program_signals, program_signals_p): Declare.
11058
e237a7e2
JK
110592012-03-05 Pedro Alves <palves@redhat.com>
11060 Jan Kratochvil <jan.kratochvil@redhat.com>
11061
11062 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
11063 New comment why.
11064
5808517f
YQ
110652012-03-03 Yao Qi <yao@codesourcery.com>
11066
11067 * tracepoint.c (tracepoint_look_up_symbols): Update call to
11068 agent_look_up_symbols.
11069
58b4daa5
YQ
110702012-03-03 Yao Qi <yao@codesourcery.com>
11071
11072 * Makefile.in (linux-low.o): Keep dependence on agent.h.
11073 (linux-x86-low.o): Likewise.
11074 * server.h: Remove in_process_agent_loaded.
11075 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
11076 common/agent.c.
11077 Update callers.
11078
8ffcbaaf
YQ
110792012-03-03 Yao Qi <yao@codesourcery.com>
11080
11081 * tracepoint.c (gdb_agent_capability): New global.
11082 (in_process_agent_loaded_ust): Renamed to
11083 `in_process_agent_supports_ust'.
11084 Update callers.
11085 (in_process_agent_supports_ust): Call agent_capability_check.
11086 (clear_installed_tracepoints): Assert that agent supports
11087 agent.
11088
d1feda86
YQ
110892012-03-03 Yao Qi <yao@codesourcery.com>
11090
11091 * linux-low.c (linux_supports_agent): New.
11092 (linux_target_ops): Initialize field `supports_agent' with
11093 linux_supports_agent.
11094 * target.h (struct target_ops) <supports_agent>: New.
11095 (target_supports_agent): New macro.
11096 * server.c (handle_general_set): Handle packet 'QAgent'.
11097 (handle_query): Send `QAgent+'.
11098 * Makefile.in (server.o): Depends on agent.h.
11099
2fa291ac
YQ
111002012-03-03 Yao Qi <yao@codesourcery.com>
11101
11102 * Makefile.in (OBS): Add agent.o.
11103 Add new rule for agent.o.
11104 Track dependence of tracepoint.c on agent.h.
11105 * tracepoint.c (run_inferior_command_1):
11106 (run_inferior_command): Call agent_run_command.
11107 (gdb_ust_connect_sync_socket): Deleted. Move it to
11108 common/agent.c.
11109 (resume_thread, stop_thread): Likewise.
11110 (gdb_ust_socket_init): Renamed to ...
11111 (gdb_agent_socket_init): ... New.
11112 (gdb_ust_thread): Renamed to ...
11113 (gdb_agent_helper_thread): ... New.
11114 (gdb_ust_init): Move some code to ...
11115 (gdb_agent_init): ... here. New.
11116 [HAVE_UST]: Call gdb_ust_init.
11117 (initialize_tracepoint_ftlib): Call gdb_agent_init.
11118 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
11119 * config.in, configure: Regenerated.
11120
05044653
PA
111212012-03-02 Pedro Alves <palves@redhat.com>
11122
11123 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
11124 * linux-low.c (struct simple_pid_list): New.
11125 (stopped_pids): New a struct simple_pid_list pointer.
11126 (add_to_pid_list, pull_pid_from_list): New.
11127 (handle_extended_wait): Don't assume the first signal new children
11128 report is SIGSTOP. Adjust call to pull_pid_from_list.
11129 (linux_wait_for_lwp): Adjust.
11130
8d00225b
YQ
111312012-03-02 Yao Qi <yao@codesourcery.com>
11132
11133 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
11134 debug log.
11135
19560ba5
YQ
111362012-03-02 Yao Qi <yao@codesourcery.com>
11137
11138 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
11139 `stop_pc' and `tpoint'. Update caller.
11140
1faeff08
MR
111412012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
11142
11143 * linux-low.h (linux_target_ops): Add regset_bitmap member.
11144 * linux-low.c (use_linux_regsets): New macro.
11145 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
11146 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
11147 (linux_register_in_regsets): New function.
11148 (usr_fetch_inferior_registers): Skip registers covered by
11149 regsets.
11150 (usr_store_inferior_registers): Likewise.
11151 (usr_fetch_inferior_registers): New macro.
11152 (usr_store_inferior_registers): Likewise.
11153 (linux_fetch_registers): Handle mixed regset/non-regset targets.
11154 (linux_store_registers): Likewise.
11155 * linux-mips-low.c (init_registers_mips_dsp_linux): New
11156 prototype.
11157 (init_registers_mips64_dsp_linux): Likewise.
11158 (init_registers_mips_linux): New macro.
11159 (init_registers_mips_dsp_linux): Likewise.
11160 (mips_dsp_num_regs): Likewise.
11161 (DSP_BASE, DSP_CONTROL): New fallback macros.
11162 (mips_base_regs): New macro.
11163 (mips_regmap): Use it. Fix the size.
11164 (mips_dsp_regmap): New variable.
11165 (mips_dsp_regset_bitmap): Likewise.
11166 (mips_arch_setup): New function.
11167 (mips_cannot_fetch_register): Use the_low_target.regmap rather
11168 than mips_regmap.
11169 (mips_cannot_store_register): Likewise.
11170 (the_low_target): Update .arch_setup, .num_regs and .regmap
11171 initializers. Add .regset_bitmap initializer.
11172 * linux-arm-low.c (the_low_target): Add .regset_bitmap
11173 initializer.
11174 * linux-bfin-low.c (the_low_target): Likewise.
11175 * linux-cris-low.c (the_low_target): Likewise.
11176 * linux-crisv32-low.c (the_low_target): Likewise.
11177 * linux-ia64-low.c (the_low_target): Likewise.
11178 * linux-m32r-low.c (the_low_target): Likewise.
11179 * linux-m68k-low.c (the_low_target): Likewise.
11180 * linux-ppc-low.c (the_low_target): Likewise.
11181 * linux-s390-low.c (the_low_target): Likewise.
11182 * linux-sh-low.c (the_low_target): Likewise.
11183 * linux-sparc-low.c (the_low_target): Likewise.
11184 * linux-tic6x-low.c (the_low_target): Likewise.
11185 * linux-x86-low.c (the_low_target): Likewise.
11186 * linux-xtensa-low.c (the_low_target): Likewise.
11187 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
11188 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
11189 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
11190 srv_xmlfiles.
11191 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
11192 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
11193
c03e6ccc
YQ
111942012-02-29 Yao Qi <yao@codesourcery.com>
11195 Pedro Alves <palves@redhat.com>
11196
11197 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
11198 `step_over_finished' is true.
11199
644cebc9
PA
112002012-02-27 Pedro Alves <palves@redhat.com>
11201
11202 * linux-low.c (pid_is_stopped): Delete, moved to common/.
11203 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
11204
c14d7ab2
PA
112052012-02-27 Pedro Alves <palves@redhat.com>
11206
11207 PR server/9684
11208 * linux-low.c (pid_is_stopped): New.
11209 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
11210
412c89dd
LM
112112012-02-25 Luis Machado <lgustavo@codesourcery.com>
11212
11213 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
11214 of conditions.
11215
b745defe
MR
112162012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
11217
11218 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
11219
9f3a5c85
LM
112202012-02-24 Luis Machado <lgustavo@codesourcery>
11221
11222 * server.c (handle_query): Advertise support for target-side
11223 breakpoint condition evaluation.
11224 (process_point_options): New function.
11225 (process_serial_event): When inserting a breakpoint, check for
11226 a target-side condition that should be evaluated.
11227
11228 * mem-break.c: Include regcache.h and ax.h.
11229 (point_cond_list_t): New data structure.
11230 (breakpoint) <cond_list>: New field.
11231 (find_gdb_breakpoint_at): Make non-static.
11232 (delete_gdb_breakpoint_at): Clear any target-side
11233 conditions.
11234 (clear_gdb_breakpoint_conditions): New function.
11235 (add_condition_to_breakpoint): Likewise.
11236 (add_breakpoint_condition): Likewise.
11237 (gdb_condition_true_at_breakpoint): Likewise.
11238 (gdb_breakpoint_here): Return result directly instead
11239 of going through a local variable.
11240
11241 * mem-break.h (find_gdb_breakpoint_at): New prototype.
11242 (clear_gdb_breakpoint_conditions): Likewise.
11243 (add_breakpoint_condition): Likewise.
11244 (gdb_condition_true_at_breakpoint): Likewise.
11245
11246 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
11247 (need_step_over_p): Take target-side breakpoint condition into
11248 consideration.
11249
5e1dc496
LM
112502012-02-24 Luis Machado <lgustavo@codesourcery>
11251
11252 * server.h: Include tracepoint.h.
11253 (agent_mem_read, agent_get_trace_state_variable_value,
11254 agent_set_trace_state_variable_value,
11255 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
11256 get_set_tsv_func_addr): New prototypes.
11257
11258 * ax.h: New include file.
11259 * ax.c: New source file.
11260
11261 * tracepoint.c: Include ax.h.
11262 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
11263 agent_expr, eval_result_type): Move to ax.h.
11264 (parse_agent_expr): Rename to ...
11265 (gdb_parse_agent_expr): ... this, make it non-static and move
11266 to ax.h.
11267 (unparse_agent_expr) Rename to ...
11268 (gdb_unparse_agent_expr): ... this, make it non-static and move
11269 to ax.h.
11270 (eval_agent_expr): Rename to ...
11271 (eval_tracepoint_agent_expr): ... this.
11272 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
11273 forward declarations.
11274 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
11275 (agent_get_trace_state_variable_value): New function.
11276 (agent_set_trace_state_variable_value): New function.
11277 (cmd_qtdp): Call gdb_parse_agent_expr (...).
11278 (response_tracepoint): Call gdb_unparse_agent_expr (...).
11279 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
11280 (condition_true_at_tracepoint): Likewise.
11281 (parse_agent_expr): Rename to ...
11282 (gdb_parse_agent_expr): ... this and move to ax.c.
11283 (unparse_agent_expr): Rename to ...
11284 (gdb_unparse_agent_expr): ... this and move to ax.c.
11285 (gdb_agent_op_name): Move to ax.c.
11286 (eval_agent_expr): Rename to ...
11287 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
11288 and move to ax.c.
11289 (eval_tracepoint_agent_expr): New function.
11290 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
43aaf8b6 11291 non-static.
5e1dc496
LM
11292 (current_insn_ptr, emit_error, struct bytecode_address): Move to
11293 ax.c.
11294 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
11295 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
11296 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
11297 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
11298 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
11299 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
11300 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
11301 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
11302 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
11303 (compile_bytecodes): Remove forward declaration.
11304 (is_goto_target): Move to ax.c.
11305 (compile_bytecodes): Move to ax.c and call
11306 agent_get_trace_state_variable_value (...) and
11307 agent_set_trace_state_variable_value (...).
11308
11309 * Makefile.in: Update ax.c and IPA dependencies.
11310
277e4e52
PA
113112012-02-24 Pedro Alves <palves@redhat.com>
11312
11313 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
11314 (cmd_bigqtbuffer_circular): ... this. Only handle
11315 'QTBuffer:circular:'.
11316 (handle_tracepoint_general_set): Adjust.
11317
bf4c19f7
YQ
113182012-02-16 Yao Qi <yao@codesourcery.com>
11319
11320 * inferiors.c: Move code to ...
11321 * dll.c: .... here. New.
11322 * server.h: Declare clear_dlls.
11323 * Makefile.in (SFILES): Add dll.c.
11324 (OBS): Add dll.o
11325 (dll.o): New rule.
11326
d73f2619
YQ
113272012-02-11 Yao Qi <yao@codesourcery.com>
11328
11329 * server.c: (handle_monitor_command): Add a new parameter
11330 `own_buf'.
11331 (handle_query): Update caller.
11332
f8255c2a
JB
113332012-02-09 Joel Brobecker <brobecker@adacore.com>
11334
11335 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
11336 * configure, config.in: Regenerate.
11337 * hostio.c: Provide an alternate implementation if HAVE_READLINK
11338 is not defined.
11339
da84f473
PA
113402012-02-02 Pedro Alves <palves@redhat.com>
11341
11342 Try SIGKILL first, then PTRACE_KILL.
11343 * linux-low.c (linux_kill_one_lwp): New.
11344 (linux_kill_one_lwp): Rename to ...
11345 (kill_one_lwp_callback): ... this. Use the new
11346 linux_kill_one_lwp.
11347
e886a173
PA
113482012-02-02 Pedro Alves <palves@redhat.com>
11349
11350 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
11351 inferior.
11352
be07f1a2
PA
113532012-01-27 Pedro Alves <palves@redhat.com>
11354
11355 * linux-low.c (linux_child_pid_to_exec_file): Delete.
11356 (elf_64_file_p): Make static.
11357 (linux_pid_exe_is_elf_64_file): New.
11358 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
11359 Delete declarations.
11360 (linux_pid_exe_is_elf_64_file): Declare.
11361 * linux-x86-low.c (x86_arch_setup): Use
11362 linux_pid_exe_is_elf_64_file.
11363
d8301ad1
JK
113642012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
11365
11366 * linux-low.c (linux_wait_for_event_1): Rename to ...
11367 (linux_wait_for_event): ... here and merge it with former
11368 linux_wait_for_event - new variable wait_ptid, use it.
11369 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
11370
01b17894
PA
113712012-01-23 Pedro Alves <palves@redhat.com>
11372
11373 * server.c (main): Avoid yet another case of infinite loop while
11374 detaching/killing after a longjmp.
11375
e825046f
JK
113762012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
11377
11378 Code cleanup.
11379 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
11380
b9e7b9c3
UW
113812012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
11382
11383 * hostio.c (handle_readlink): New function.
11384 (handle_vFile): Call it to handle "vFile:readlink" packets.
11385
901f9912
UW
113862012-01-20 Pedro Alves <palves@redhat.com>
11387 Ulrich Weigand <ulrich.weigand@linaro.org>
11388
11389 * server.c (handle_v_requests): Only support vAttach and vRun to
11390 start multiple processes when in extended protocol mode.
11391
fc1ab1a0
PA
113922012-01-17 Pedro Alves <palves@redhat.com>
11393
11394 * tracepoint.c (initialize_tracepoint): Use mmap instead of
11395 memalign plus mprotect to allocate the scratch buffer.
11396
7d5d4e98
PA
113972012-01-13 Pedro Alves <palves@redhat.com>
11398
11399 * server.c (attach_inferior): Clear `cont_thread'.
11400
f128d5e9
PA
114012012-01-13 Pedro Alves <palves@redhat.com>
11402
11403 * server.c (main): Avoid infinite loop while detaching/killing
11404 after a longjmp.
11405
06db92f0
DE
114062012-01-09 Doug Evans <dje@google.com>
11407
11408 * server.c (start_inferior): Set last_ptid in --wrapper case.
11409
32d92999
YQ
114102012-01-06 Yao Qi <yao@codesourcery.com>
11411
11412 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
11413 defined.
11414 [IN_PROCESS_AGENT] (debug_agent): New global variable.
11415
5e0a92a9
YQ
114162012-01-04 Yao Qi <yao@codesourcery.com>
11417
11418 * tracepoint.c (cmd_qtdp): Print debug message
11419 for static tracepoint.
11420
ae639e8c
YQ
114212012-01-04 Yao Qi <yao@codesourcery.com>
11422
11423 * tracepoint.c (trace_vdebug): Differentiate debug message
11424 between gdbserver and IPA.
11425
f72429c5
YQ
114262012-01-03 Yao Qi <yao@codesourcery.com>
11427
11428 * tracepoint.c (tracepoint_was_hit): Don't collect for
11429 static tracepoint.
11430
12c3e59c
JB
114312012-01-02 Joel Brobecker <brobecker@adacore.com>
11432
11433 * terminal.h: Reformat copyright header.
11434
67827812
JB
114352012-01-02 Joel Brobecker <brobecker@adacore.com>
11436
11437 * server.c (gdbserver_version): Update copyright year.
11438 * gdbreplay.c (gdbreplay_version): Likewise.
11439
3e52c33d
JK
114402011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
11441
11442 * linux-low.c (linux_create_inferior): Put empty if clause for write.
11443
11444 Revert:
11445 2011-12-18 Hui Zhu <teawater@gmail.com>
11446 * linux-low.c (linux_create_inferior): Save return value to ret.
11447
66f1260e
HZ
114482011-12-18 Hui Zhu <teawater@gmail.com>
11449
11450 * linux-low.c (linux_create_inferior): Save return value to ret.
11451
e77616d7
DE
114522011-12-16 Doug Evans <dje@google.com>
11453
e7b06c57
DE
11454 * linux-low.c (linux_create_inferior): If stdio connection,
11455 redirect stdin from /dev/null, stdout to stderr.
11456 * remote-utils.c (remote_is_stdio): New static global.
11457 (remote_connection_is_stdio): New function.
11458 (remote_prepare): Handle stdio connection.
11459 (remote_open): Ditto.
11460 (remote_close): Don't close stdin for stdio connections.
11461 (read_prim,write_prim): New functions. Replace all calls to
11462 read/write to these.
11463 * server.c (main): Watch for "-" argument. Move call to
11464 remote_prepare before start_inferior.
11465 * server.h (STDIO_CONNECTION_NAME): New macro.
11466 (remote_connection_is_stdio): Declare.
11467
e77616d7
DE
11468 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
11469 in debugging output.
11470
82067193
YQ
114712011-12-15 Yao Qi <yao@codesourcery.com>
11472
11473 * tracepoint.c: Include sys/syscall.h.
11474 (gdb_ust_thread): Remove preprocessor conditional.
11475
82bfbe7e
PA
114762011-12-14 Pedro Alves <pedro@codesourcery.com>
11477
11478 * linux-low.c (linux_detach_one_lwp): Call
11479 the_low_target.prepare_to_resume before detaching.
11480
712c6575
YQ
114812011-12-14 Yao Qi <yao@codesourcery.com>
11482
11483 * tracepoint.c (gdb_ust_thread): Don't ignore return value
11484 of write.
11485
d54d1edf
YQ
114862011-12-14 Yao Qi <yao@codesourcery.com>
11487
11488 * i386-low.c (i386_low_stopped_data_address): Initialize local
11489 variable `control'.
11490
6210a125
PA
114912011-12-13 Pedro Alves <pedro@codesourcery.com>
11492
11493 PR remote/13492
11494
11495 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
11496 DR_CONTROL unless necessary. Extend comments.
11497 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
11498 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
11499
2ece8244
YQ
115002011-12-13 Yao Qi <yao@codesourcery.com>
11501
11502 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
11503 macros.
11504 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
11505
784867a5
JK
115062011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
11507
11508 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
11509 Print new debug message for such case.
11510
6bf36717
JK
115112011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
11512
11513 Fix overlapping memcpy.
11514 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
11515 the read_inferior_memory transfer.
11516 (delete_fast_tracepoint_jump): New variable buf. Use it for the
11517 write_inferior_memory transfer.
11518 (set_fast_tracepoint_jump): New variable buf. Use it for the
11519 read_inferior_memory and write_inferior_memory transfers.
11520 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
11521 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
11522 Use it for the write_inferior_memory transfer.
11523 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
11524 buffers.
11525
50275556
MR
115262011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
11527
11528 * linux-low.c (fetch_register, store_register): Make code
11529 consistent, fix formatting.
11530
7325beb4
MR
115312011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
11532
11533 * linux-low.c (usr_store_inferior_registers): Factor out code
11534 to handle individual registers into...
11535 (store_register): ... this new function.
11536
c642a434
UW
115372011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
11538
11539 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
11540 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
11541 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
11542 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
11543 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
11544 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
11545 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
11546 (srv_xmlfiles): Add new XML files.
11547
11548 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
11549 and <sys/uio.h>.
11550 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
11551 (init_registers_s390_linux32v1): Add prototype.
11552 (init_registers_s390_linux32v2): Likewise.
11553 (init_registers_s390_linux64v1): Likewise.
11554 (init_registers_s390_linux64v2): Likewise.
11555 (init_registers_s390x_linux64v1): Likewise.
11556 (init_registers_s390x_linux64v2): Likewise.
11557 (s390_num_regs): Increment to 52.
11558 (s390_regmap): Add orig_r2 register.
11559 (s390_num_regs_3264): Increment to 68.
11560 (s390_regmap_3264): Add orig_r2 register.
11561 (s390_collect_ptrace_register): Handle orig_r2 register.
11562 (s390_supply_ptrace_register): Likewise.
11563 (s390_fill_last_break): New function.
11564 (s390_store_last_break): Likewise.
11565 (s390_fill_system_call): New function.
11566 (s390_store_system_call): Likewise.
11567 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
11568 register sets.
11569 (s390_check_regset): New function.
11570 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
11571 NT_S390_SYSTEM_CALL regsets and use appropriate description.
11572 Update target_regsets for available register sets.
11573
2268b414
JK
115742011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
11575 Jan Kratochvil <jan.kratochvil@redhat.com>
11576
11577 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
11578 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
11579 New.
11580 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
11581 * linux-low.h (struct process_info_private): New member r_debug.
11582 * server.c (handle_qxfer_libraries): Call
11583 the_target->qxfer_libraries_svr4.
11584 (handle_qxfer_libraries_svr4): New function.
11585 (qxfer_packets): New entry "libraries-svr4".
11586 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
11587 * target.h (struct target_ops): New member qxfer_libraries_svr4.
11588 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
11589 PACKET_qXfer_libraries_svr4.
11590
d6db1fab
UW
115912011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
11592
11593 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
11594 PSW address/mask between 8-byte and 16-byte formats.
11595 (s390_supply_ptrace_register): Likewise.
11596 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
11597 basic addressing mode bit.
11598
242f5f1c
SS
115992011-11-24 Stan Shebs <stan@codesourcery.com>
11600
11601 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
11602
f196051f
SS
116032011-11-17 Stan Shebs <stan@codesourcery.com>
11604
11605 * tracepoint.c (struct tracepoint): New field traceframe_usage.
11606 (tracing_start_time): New global.
11607 (tracing_stop_time): New global.
11608 (tracing_user_name): New global.
11609 (tracing_notes): New global.
11610 (tracing_stop_note): New global.
11611 (cmd_qtstart): Set traceframe_usage, start_time.
11612 (stop_tracing): Set stop_time.
11613 (cmd_qtstatus): Report additional status.
11614 (cmd_qtp): New function.
11615 (handle_tracepoint_query): Call it.
11616 (cmd_qtnotes): New function.
11617 (handle_tracepoint_general_set): Call it.
11618 (get_timestamp): Rename from tsv_get_timestamp.
11619
405f8e94
SS
116202011-11-14 Stan Shebs <stan@codesourcery.com>
11621 Kwok Cheung Yeung <kcy@codesourcery.com>
11622
11623 * linux-x86-low.c (small_jump_insn): New.
11624 (i386_install_fast_tracepoint_jump_pad): Add arguments for
11625 trampoline and error message, build a trampoline and issue a small
11626 jump instruction to it.
11627 (x86_install_fast_tracepoint_jump_pad): Add arguments for
11628 trampoline and error message.
11629 (x86_get_min_fast_tracepoint_insn_len): New.
11630 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
11631 * linux-low.h (struct linux_target_ops): Add arguments to
11632 install_fast_tracepoint_jump_pad operation, add new operation.
11633 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
11634 arguments.
11635 (linux_get_min_fast_tracepoint_insn_len): New function.
11636 (linux_target_op): Add new operation.
11637 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
11638 (gdb_trampoline_buffer_end): Ditto.
11639 (gdb_trampoline_buffer_error): Ditto.
11640 (struct ipa_sym_addresses): Add fields for new IPA variables.
11641 (symbol_list): Add entries for new IPA variables.
11642 (struct tracepoint): Add fields to hold the address range of the
11643 trampoline used by the tracepoint.
11644 (trampoline_buffer_head): New static variable.
11645 (trampoline_buffer_tail): Ditto.
11646 (claim_trampoline_space): New function.
11647 (have_fast_tracepoint_trampoline_buffer): New function.
11648 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
11649 structure.
11650 (install_fast_tracepoint): Ditto, also add error buffer argument.
11651 (cmd_qtminftpilen): New function.
11652 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
11653 (fast_tracepoint_from_trampoline_address): New function.
11654 (fast_tracepoint_collecting): Handle trampoline as part of jump
11655 pad space.
11656 (set_trampoline_buffer_space): New function.
11657 (initialize_tracepoint): Initialize new IPA variables.
11658 * target.h (struct target_ops): Add arguments to
11659 install_fast_tracepoint_jump_pad operation, add new
11660 get_min_fast_tracepoint_insn_len operation.
11661 (target_get_min_fast_tracepoint_insn_len): New.
11662 (install_fast_tracepoint_jump_pad): Add arguments.
11663 * server.h (IPA_BUFSIZ): Define.
11664 * linux-i386-ipa.c: Include extra header files.
11665 (initialize_fast_tracepoint_trampoline_buffer): New function.
11666 (initialize_low_tracepoint): Call it.
11667 * server.h (set_trampoline_buffer_space): Declare.
11668 (claim_trampoline_space): Ditto.
11669 (have_fast_tracepoint_trampoline_buffer): Ditto.
11670
1e4d1764
YQ
116712011-11-14 Yao Qi <yao@codesourcery.com>
11672
11673 * server.c (handle_query): Handle InstallInTrace for qSupported.
11674 * tracepoint.c (add_tracepoint): Sort list.
11675 (install_tracepoint, download_tracepoint): New.
11676 (cmd_qtdp): Call them to install and download tracepoints.
11677 (sort_tracepoints): Removed.
11678 (cmd_qtstart): Update.
11679
5c73ff4e
YQ
116802011-11-14 Yao Qi <yao@codesourcery.com>
11681
11682 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
11683 * mem-break.h: Declare.
11684 * tracepoint.c (cmd_qtstart): Move some code to ...
11685 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
11686 New.
11687 (download_tracepoints): Move some code to ...
11688 (download_tracepoint_1): ... here. New.
11689
86a30030
YQ
116902011-11-08 Yao Qi <yao@codesourcery.com>
11691
11692 * remote-utils.c (relocate_instruction): A comment fix.
11693
8d26e50c
JB
116942011-11-07 Joel Brobecker <brobecker@adacore.com>
11695
11696 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
11697 (i386_dr_low_get_control, i386_dr_low_get_status): Use
11698 dr_status_mirror and dr_control_mirror from debug_reg_state.
11699 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
11700 (i386_initial_stuff): Remove use of deleted globals.
11701 (i386_get_thread_context, i386_set_thread_context,
11702 i386_thread_added): Use dr_status_mirror and dr_control_mirror
11703 from debug_reg_state.
11704
a59306a3
YQ
117052011-11-05 Yao Qi <yao@codesourcery.com>
11706
11707 * tracepoint.c (gdb_collect): Loop over tracepoints of same
11708 address as TPOINT's.
11709
3065dfb6
SS
117102011-11-02 Stan Shebs <stan@codesourcery.com>
11711
11712 * tracepoint.c (agent_mem_read_string): New function.
11713 (eval_agent_expr): Call it for tracenz.
11714 * server.c (handle_query): Report support for tracenz.
11715
fd0d8c7c
YQ
117162011-11-02 Yao Qi <yao@codesourcery.com>
11717
11718 * tracepoint.c (cmd_qtstart): Remove unused local variables.
11719
609086b1
YQ
117202011-11-02 Yao Qi <yao@codesourcery.com>
11721
11722 * target.h: Fix a typo in comment.
11723
b9fd1791
PA
117242011-10-31 Pedro Alves <pedro@codesourcery.com>
11725
11726 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
11727 clobber the breakpoints' shadows with fast tracepoint jumps.
11728 * mem-break.h (check_mem_write): Add `myaddr' parameter.
11729 * target.c (write_inferior_memory): Also pass MYADDR down to
11730 check_mem_write.
11731
03583c20
UW
117322011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
11733
11734 * configure.ac: Check support for personality routine.
11735 * configure: Regenerate.
11736 * config.in: Likewise.
11737 * linux-low.c: Include <sys/personality.h>.
11738 Define ADDR_NO_RANDOMIZE if necessary.
11739 (linux_create_inferior): Disable address space randomization when
11740 forking inferior, if requested.
11741 (linux_supports_disable_randomization): New function.
11742 (linux_target_ops): Install it.
11743 * server.h (disable_randomization): Declare.
11744 * server.c (disable_randomization): New global variable.
11745 (handle_general_set): Handle QDisableRandomization.
11746 (handle_query): Likewise for qSupported.
11747 (main): Support --disable-randomization and --no-disable-randomization
11748 command line arguments.
11749 * target.h (struct target_ops): Add supports_disable_randomization.
11750 (target_supports_disable_randomization): New macro.
11751
723b724b
MF
117522011-09-29 Mike Frysinger <vapier@gentoo.org>
11753
11754 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
11755 ifdef check.
11756 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
11757 [!PT_GETDSBT] (target_loadmap): New definition.
11758 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
11759 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
11760 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
11761 and PT_GETDSBT to LINUX_LOADMAP.
11762 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
11763 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
11764
55329a5c 117652011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
71487fd7
UW
11766
11767 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
11768 (arm_linux_hwbp_cap): New static variable.
11769 (arm_linux_get_hwbp_cap): Replace by ...
11770 (arm_linux_init_hwbp_cap): ... this new function.
11771 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
11772 (arm_linux_get_hw_watchpoint_count): Likewise.
11773 (arm_linux_get_hw_watchpoint_max_length): Likewise.
11774 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
11775 (arm_prepare_to_resume): Use perror_with_name instead of error.
11776
55329a5c 117772011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
09b4ad9f
UW
11778
11779 * linux-arm-low.c: Include <signal.h>.
11780 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
11781 (struct arm_linux_hwbp_cap): New data type.
11782 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
11783 (struct arm_linux_hw_breakpoint): New data type.
11784 (MAX_BPTS, MAX_WPTS): Define.
11785 (struct arch_process_info, struct arch_lwp_info): New data types.
11786 (arm_linux_get_hwbp_cap): New function.
11787 (arm_linux_get_hw_breakpoint_count): Likewise.
11788 (arm_linux_get_hw_watchpoint_count): Likewise.
11789 (arm_linux_get_hw_watchpoint_max_length): Likewise.
11790 (arm_hwbp_control_initialize): Likewise.
11791 (arm_hwbp_control_is_enabled): Likewise.
11792 (arm_hwbp_control_is_initialized): Likewise.
11793 (arm_hwbp_control_disable): Likewise.
11794 (arm_linux_hw_breakpoint_equal): Likewise.
11795 (arm_linux_hw_point_initialize): Likewise.
11796 (struct update_registers_data): New data structure.
11797 (update_registers_callback: New function.
11798 (arm_insert_point): Likewise.
11799 (arm_remove_point): Likewise.
11800 (arm_stopped_by_watchpoint): Likewise.
11801 (arm_stopped_data_address): Likewise.
11802 (arm_new_process): Likewise.
11803 (arm_new_thread): Likewise.
11804 (arm_prepare_to_resume): Likewise.
11805 (the_low_target): Register arm_insert_point, arm_remove_point,
11806 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
11807 arm_new_thread, and arm_prepare_to_resume.
11808
6b9801d4
SS
118092011-09-15 Stan Shebs <stan@codesourcery.com>
11810
11811 * server.h (struct emit_ops): Add compare-goto fields.
11812 * tracepoint.c (gdb_agent_op_sizes): New table.
11813 (emit_eq_goto): New function.
11814 (emit_ne_goto): New function.
11815 (emit_lt_goto): New function.
11816 (emit_le_goto): New function.
11817 (emit_gt_goto): New function.
11818 (emit_ge_goto): New function.
11819 (is_goto_target): New function.
11820 (compile_bytecodes): Recognize special cases of compare-goto
11821 combinations and call specialized emitters for them.
11822 * linux-x86-low.c (amd64_emit_eq_goto): New function.
11823 (amd64_emit_ne_goto): New function.
11824 (amd64_emit_lt_goto): New function.
11825 (amd64_emit_le_goto): New function.
11826 (amd64_emit_gt_goto): New function.
11827 (amd64_emit_ge_goto): New function.
11828 (amd64_emit_ops): Add the new functions.
11829 (i386_emit_eq_goto): New function.
11830 (i386_emit_ne_goto): New function.
11831 (i386_emit_lt_goto): New function.
11832 (i386_emit_le_goto): New function.
11833 (i386_emit_gt_goto): New function.
11834 (i386_emit_ge_goto): New function.
11835 (i386_emit_ops): Add the new functions.
11836
bf15cbda
SS
118372011-09-08 Stan Shebs <stan@codesourcery.com>
11838
11839 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
11840 (i386_emit_epilogue): Restore %ebx.
11841
943ca1dd
JZ
118422011-08-31 Jie Zhang <jzhang918@gmail.com>
11843
11844 * server.c (step_thread): Remove definition.
11845 (process_serial_event): Don't handle Hs.
11846 * server.h (step_thread): Remove declaration.
11847 * target.c (set_desired_inferior): Remove use of step_thread.
11848
e3deef73
LM
118492011-08-24 Luis Machado <lgustavo@codesourcery.com>
11850
11851 * linux-low.c: Include linux-procfs.h.
11852 (linux_attach_lwp_1): Update comments.
11853 (linux_attach): Scan for existing threads when attaching to a
11854 process that is the tgid.
11855 * Makefile.in: Update dependencies.
11856
13da1c97
LM
118572011-08-24 Luis Machado <lgustavo@codesourcery.com>
11858
11859 * configure.srv: Add linux-procfs.o dependencies.
11860
881127c9
YQ
118612011-08-14 Yao Qi <yao@codesourcery.com>
11862
11863 * target.h (struct target_ops): Fix indent.
11864 * win32-low.c (win32_target_ops): Fix comment.
11865
58dbd541
YQ
118662011-08-14 Andrew Jenner <andrew@codesourcery.com>
11867 Yao Qi <yao@codesourcery.com>
11868
11869 * Makefile.in (clean): Remove tic6x-*.c files.
11870 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
11871 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
11872 (tic6x-c64xp-linux.c): Likewise.
11873 * configure.srv: Add support for tic6x-*-uclinux.
11874 * linux-tic6x-low.c: New.
11875 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
11876
78d85199
YQ
118772011-08-14 Andrew Stubbs <ams@codesourcery.com>
11878 Yao Qi <yao@codesourcery.com>
11879
11880 * target.h (struct target_ops): Add read_loadmap.
11881 * linux-low.c (struct target_loadseg): New type.
11882 (struct target_loadmap): New type.
11883 (linux_read_loadmap): New function.
11884 (linux_target_ops): Add linux_read_loadmap.
11885 * server.c (handle_query): Support qXfer:fdpic:read packet.
43aaf8b6
PA
11886 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
11887 to NULL.
78d85199 11888
a959a88d
EZ
118892011-08-05 Eli Zaretskii <eliz@gnu.org>
11890
11891 * win32-low.c: Include <stdint.h>.
11892
1ced966e
PA
118932011-07-22 Pedro Alves <pedro@codesourcery.com>
11894
11895 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
11896 to the inferior here.
11897 (i386_remove_aligned_watchpoint): Ditto.
11898 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
11899 fit part of the watchpoint in the debug registers.
11900 (i386_update_inferior_debug_regs): New.
11901 (i386_low_insert_watchpoint): Work on a local mirror of the debug
11902 registers, and only update the inferior on success.
11903 (i386_low_remove_watchpoint): Ditto.
11904
d26e3629
KY
119052011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
11906
11907 * linux-low.c (compare_ints, unique, list_threads, show_process,
11908 linux_core_of_thread): Delete.
11909 (linux_target_ops): Change linux_core_of_thread to
11910 linux_common_core_of_thread.
11911 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
11912 * utils.c (malloc_failure): Change type of argument.
11913 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
11914 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
11915 common/linux-osdata.c, common/ptid.c and common/buffer.c.
11916 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
11917 (IPA_OBJS): Add common-utils-ipa.o.
11918 (ptid_h, linux_osdata_h): New macros.
11919 (server_h): Add common/common-utils.h, common/xml-utils.h,
11920 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
11921 common/ptid.h.
11922 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
11923 ptid.o, buffer.o): New rules.
11924 (linux-low.o): Add common/linux-osdata.h as a dependency.
11925 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
11926 * configure.ac: Add AC_HEADER_DIRENT check.
11927 * config.in: Regenerate.
11928 * configure: Regenerate.
11929 * remote-utils.c (xml_escape_text): Delete.
11930 (buffer_grow, buffer_free, buffer_init, buffer_finish,
11931 buffer_xml_printf): Move to common/buffer.c.
11932 * server.c (main): Remove call to initialize_inferiors.
11933 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
11934 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
11935 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
11936 internal_error, gdb_assert, gdb_assert_fail): Delete.
11937 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
11938 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
11939 common/buffer.h.
11940 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
11941 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
11942 initialize_inferiors): Delete.
11943
2275a1a7
PA
119442011-07-20 Pedro Alves <pedro@codesourcery.com>
11945
11946 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
11947 symbol error.
11948
0a5b1e09
PA
119492011-05-31 Pedro Alves <pedro@codesourcery.com>
11950
11951 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
11952 assertion.
11953 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
11954
6938fd34
YQ
119552011-05-26 Yao Qi <yao@codesourcery.com>
11956
11957 * Makefile.in (thread-db.o): Track dependence to
11958 common/gdb_thread_db.h.
11959 * thread-db.c: include gdb_thread_db.h from right place.
11960
b481f9e0
TT
119612011-05-16 Adrian Cornish <gnu@bluedreamer.com>
11962
11963 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
11964 __FILE__ and __LINE__ to internal_error.
11965
98a5dd13
DE
119662011-05-13 Doug Evans <dje@google.com>
11967
11968 * thread-db.c (try_thread_db_load_from_sdir): New function.
11969 (try_thread_db_load_from_dir): New function.
11970 (thread_db_load_search): Handle $sdir, ignore $pdir.
11971 Remove trying of system directories if search of
11972 libthread-db-search-path fails, that is now done via $sdir.
11973
d248b706
KY
119742011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
11975
11976 * server.c (handle_query): Add EnableDisableTracepoints to the list
11977 of supported features.
43aaf8b6 11978 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
d248b706 11979 tracepoints.
43aaf8b6
PA
11980 (cmd_qtenable_disable): New.
11981 (cmd_qtstart): Install tracepoints even if disabled.
11982 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
11983 receiving a QTEnable or QTDisable packet.
11984 (gdb_collect): Skip data collection if fast tracepoint is disabled.
11985 (ust_marker_to_static_tracepoint): Do not ignore disabled static
11986 tracepoints.
11987 (gdb_probe): Skip data collection if static tracepoint is disabled.
d248b706 11988
84e578fb
DE
119892011-05-10 Doug Evans <dje@google.com>
11990
11991 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
11992
71f55dd8
DE
119932011-05-04 Doug Evans <dje@google.com>
11994
11995 * linux-low.c (linux_join): Skip process lookup.
11996 * spu-low.c (spu_join): Ditto.
11997 * server.c (join_inferiors_callback): Delete.
11998 (process_serial_event): For 'D' packet (detach) call join_inferior
11999 directly.
12000
4d393d60
JM
120012011-05-04 Joseph Myers <joseph@codesourcery.com>
12002
12003 * README: Don't mention xscale*-*-linux*.
12004 * configure.srv (xscale*-*-linux*): Don't handle target.
12005
b00ad6ff
NF
120062011-04-27 Nathan Froyd <froydnj@codesourcery.com>
12007
12008 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
12009 casting pointers.
12010 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
12011 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
12012 (i386_emit_void_call_2): Likewise.
12013
af96c192
YQ
120142011-04-26 Yao Qi <yao@codesourcery.com>
12015
43aaf8b6
PA
12016 * linux-low.c: Move common macros to linux-ptrace.h.
12017 Include linux-ptrace.h.
af96c192
YQ
12018 * Makefile.in (linux_ptrace_h): New.
12019 (linux-low.o): Depends on linux-ptrace.h.
12020
03f2bd59
JK
120212011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
12022
12023 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
12024 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
12025 (remote_prepare): New function with most of the TCP code from ...
12026 (remote_open): ... here. Detect PORT here unconditionally. Move also
12027 setting transport_is_reliable.
12028 * server.c (run_once): New variable.
12029 (gdbserver_usage): Document it.
12030 (main): Set run_once for `--once'. Call remote_prepare. Exit after
12031 the first run if RUN_ONCE.
12032 * server.h (run_once, remote_prepare): New declarations.
12033
7a9dd1b2
TT
120342011-04-19 Tom Tromey <tromey@redhat.com>
12035
12036 * win32-low.c (handle_load_dll): Remove duplicate "the".
12037
81239425
PM
120382011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
12039
12040 Remove support for old Cygwin 1.5 versions.
12041 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
12042 function to avoid warning.
12043 (win32_add_one_solib): Use cygwin_conv_path function to avoid
12044 warning.
12045
9e0627f1
PM
120462011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
12047
12048 * gdbserver/server.h (Macro _): Define it if not available.
12049
588eebee
MS
120502011-03-14 Michael Snyder <msnyder@vmware.com>
12051
348af9f7 12052 * hostio.c (handle_close): Remove unnecessary null test.
588eebee 12053
43f70d4c
JB
120542011-03-10 Joel Brobecker <brobecker@adacore.com>
12055
12056 * Makefile.in (maintainer-clean realclean distclean): Remove
12057 "make ... subdir_do" command.
12058
348af9f7
MS
120592011-03-10 Michael Snyder <msnyder@vmware.com>
12060
12061 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
12062
12063 * server.c (handle_v_run): Free alloced buffer on early return.
12064
e637a4f5
YQ
120652011-03-09 Yao Qi <yao@codesourcery.com>
12066
12067 Revert:
12068 2011-03-04 Yao Qi <yao@codesourcery.com>
12069
12070 * Makefile.in: Remove GNU make feature --directory.
12071
12072 2011-03-05 Yao Qi <yao@codesourcery.com>
12073
12074 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
12075 (subdir_do): New make target. Copied from gdb/Makefile.
12076 (maintainer-clean, realclean, distclean, clean): Call corresponding
12077 make targets in common/Makefile.
12078
12079 2011-02-11 Yao Qi <yao@codesourcery.com>
12080
12081 * configure.ac: Call AC_PROG_RANLIB.
12082 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
12083 * configure: Regenerate.
12084
e6edda56
JK
120852011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
12086
12087 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
12088
e5141119
JB
120892011-03-06 Yao Qi <yao@codesourcery.com>
12090
12091 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
12092
64794aa4
JB
120932011-03-05 Yao Qi <yao@codesourcery.com>
12094
12095 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
12096 (subdir_do): New make target. Copied from gdb/Makefile.
12097 (maintainer-clean, realclean, distclean, clean): Call corresponding
12098 make targets in common/Makefile.
12099
7a762829
YQ
121002011-03-04 Yao Qi <yao@codesourcery.com>
12101
12102 * Makefile.in: Remove GNU make feature --directory.
12103
348af9f7
MS
121042011-03-04 Michael Snyder <msnyder@vmware.com>
12105
12106 * server.c (queue_stop_reply): Call xmalloc not malloc.
12107
121082011-03-02 Michael Snyder <msnyder@vmware.com>
12109
12110 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
12111
9f72fee2
MS
121122011-02-28 Michael Snyder <msnyder@vmware.com>
12113
588eebee
MS
12114 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
12115 (cmd_qtframe): Ditto.
12116 (cmd_qtbuffer): Ditto.
12117 (cmd_bigqtbuffer): Ditto.
12118
9f72fee2
MS
12119 * utils.c (decimal2str): Initialize 'width' to nine, then
12120 don't mess with it.
12121
8040bd49
UW
121222011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
12123
12124 * hostio.c (require_data): Free *data, not data.
12125
7e52cbd0
JK
121262011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12127
12128 * hostio.c (require_data): Use free, not xfree.
12129
9130f83e
MS
121302011-02-27 Michael Snyder <msnyder@vmware.com>
12131
4b812f4e
MS
12132 * server.c (handle_query): Discard unused value.
12133
9130f83e
MS
12134 * hostio.c (require_data): Free malloc memory before returning
12135 error.
12136
69d37113
MS
121372011-02-26 Michael Snyder <msnyder@vmware.com>
12138
12139 * linux-low.c (list_threads): Call closedir for dirent.
12140
35f5825a
MS
121412011-02-27 Michael Snyder <msnyder@vmware.com>
12142
2a589cef
MS
12143 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
12144 a case statement falls through.
12145
0adea5f7
MS
12146 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
12147
35f5825a
MS
12148 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
12149 in comparison.
12150
238f1c74
MS
121512011-02-26 Michael Snyder <msnyder@vmware.com>
12152
12153 * utils.c (decimal2str): Eliminate dead code and dead param.
12154 (pulongest): Drop dead param from call to decimal2str.
12155 (plongest): Ditto.
12156
633ff500
JB
121572011-02-24 Joel Brobecker <brobecker@adacore.com>
12158
12159 Revert the following patch (not approved yet):
12160 2011-02-21 Hui Zhu <teawater@gmail.com>
12161 * tracepoint.c (tp_printf): New function.
12162 (eval_agent_expr): Handle gdb_agent_op_printf.
12163
f9c6ff72
HZ
121642011-02-21 Hui Zhu <teawater@gmail.com>
12165
12166 * tracepoint.c (tp_printf): New function.
12167 (eval_agent_expr): Handle gdb_agent_op_printf.
12168
94d5e490
TT
121692011-02-18 Tom Tromey <tromey@redhat.com>
12170
12171 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
12172 (tracepoint.o): Likewise.
12173 * tracepoint.c (enum gdb_agent_op): Use ax.def.
12174 (gdb_agent_op_names): Likewise.
12175
c7f96d2b
TT
121762011-02-18 Tom Tromey <tromey@redhat.com>
12177
12178 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
12179 gdb_agent_op_rot>: New constants.
12180 (gdb_agent_op_names): Add pick and roll.
12181 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
12182 cases.
12183
0feedb2c
JK
121842011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
12185
12186 * aclocal.m4: Regenerated with aclocal-1.11.1.
12187
b3b9301e
PA
121882011-02-14 Pedro Alves <pedro@codesourcery.com>
12189
12190 * server.c (handle_qxfer_traceframe_info): New.
12191 (qxfer_packets): Register "traceframe-info".
12192 (handle_query): Report support for qXfer:traceframe-info:read+.
12193 * tracepoint.c (match_blocktype): New.
12194 (traceframe_find_block_type): Rename to ...
12195 (traceframe_walk_blocks): ... this. Add callback filter argument,
12196 and use it.
12197 (traceframe_find_block_type): New, reimplemented on top of
12198 traceframe_walk_blocks.
12199 (build_traceframe_info_xml): New.
12200 (traceframe_read_info): New.
12201 * server.h (traceframe_read_info): Declare.
12202
4f3e6fb7
YQ
122032011-02-11 Yao Qi <yao@codesourcery.com>
12204
12205 * configure.ac: Call AC_PROG_RANLIB.
12206 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
12207 * configure: Regenerate.
12208
764880b7
PA
122092011-02-07 Pedro Alves <pedro@codesourcery.com>
12210
12211 * server.c (gdb_read_memory): Change return semantics to allow
12212 partial transfers.
12213 (handle_search_memory_1): Adjust.
12214 (process_serial_event) <'m' packet>: Handle partial transfers.
12215 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
12216
1c79eb8a
PA
122172011-01-28 Pedro Alves <pedro@codesourcery.com>
12218
12219 * regcache.c (init_register_cache): Initialize
12220 regcache->register_status.
12221 (free_register_cache): Release regcache->register_status.
12222 (regcache_cpy): Copy register_status.
12223 (registers_to_string): Print 'x's for unavailable registers.
12224 (supply_register): Mark the register's status valid or
12225 unavailable, depending on whether a buffer was passed in or not.
12226 (supply_register_zeroed): New.
12227 (supply_regblock): Mark the registers' status valid or
12228 unavailable, depending on whether a buffer was passed in or not.
12229 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
12230 (struct regcache): New `register_status' field.
12231 (supply_register_zeroed): Declare.
12232 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
12233 supply_register_zeroed, rather than passing a NULL buffer to
12234 supply_register.
12235 * tracepoint.c (fetch_traceframe_registers): Update comment.
12236
85724a0e
PA
122372011-01-28 Pedro Alves <pedro@codesourcery.com>
12238
12239 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
12240 buffer explicit.
12241
d08aafef
PA
122422011-01-25 Pedro Alves <pedro@codesourcery.com>
12243
12244 * server.h (decode_xfer_write): Change prototype.
12245 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
12246 and don't extract the annex here.
12247 * server.c (decode_xfer_read): Remove `annex' parameter,
12248 and don't extract the annex here.
12249 (decode_xfer): New.
12250 (struct qxfer): New.
12251 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
12252 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
12253 (handle_qxfer_statictrace): New functions, abstracted out from
12254 handle_query, and made to use the struct qxfer interface.
12255 (handle_threads_qxfer_proper): Rename to ...
12256 (handle_qxfer_threads_proper): ... this.
12257 (handle_threads_qxfer): Rename to ...
12258 (handle_qxfer_threads): ... this. Adjust.
12259 (qxfer_packets): New array.
12260 (handle_qxfer): New function.
12261 (handle_query): Use handle_qxfer.
12262
493e2a69
MS
122632011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
12264
12265 * gdbreplay.c: Shorten lines of >= 80 columns.
12266 * linux-low.c: Ditto.
12267 * linux-ppc-low.c: Ditto.
12268 * linux-s390-low.c: Ditto.
12269 * linux-sparc-low.c: Ditto.
12270 * linux-x86-low.c: Ditto.
12271 * linux-xtensa-low.c: Ditto.
12272 * mem-break.c: Ditto.
12273 * nto-low.c: Ditto.
12274 * regcache.h: Ditto.
12275 * remote-utils.c: Ditto.
12276 * server.c: Ditto.
12277 * server.h: Ditto.
12278 * thread-db.c: Ditto.
12279 * tracepoint.c: Ditto.
12280 * utils.c: Ditto.
12281 * win32-low.h: Ditto.
12282
44944448
JB
122832011-01-05 Joel Brobecker <brobecker@adacore.com>
12284
12285 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
12286 update.
12287
71ce852c
JB
122882011-01-01 Joel Brobecker <brobecker@adacore.com>
12289
12290 * server.c (gdbserver_version): Update copyright year in version
12291 output.
12292 * gdbreplay.c (gdbreplay_version): Ditto.
12293
eb826dc6
MF
122942010-12-29 Jie Zhang <jie.zhang@analog.com>
12295
12296 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
12297 * linux-bfin-low.c: New file.
12298 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
12299 PT_DATA_ADDR for BFIN targets.
12300 * Makefile.in (SFILES): Add linux-bfin-low.c.
12301 (clean): Remove reg-bfin.c.
12302 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
12303 * README: Mention supported Blackfin targets.
12304
39ab222a
MF
123052010-12-23 Mike Frysinger <vapier@gentoo.org>
12306
12307 * .gitignore: New file.
12308
a1f2ce7d
MF
123092010-11-16 Mike Frysinger <vapier@gentoo.org>
12310
12311 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
12312
f474844c
JZ
123132010-10-22 Jie Zhang <jie@codesourcery.com>
12314
12315 * Makefile.in: Add FLAGS_TO_PASS variable.
12316 (install): Remove dependency of install-only and recursively
12317 invoke make for install-only.
12318
f1048712
DE
123192010-10-04 Doug Evans <dje@google.com>
12320
12321 * Makefile.in (uninstall): Use $(DESTDIR).
12322
b53a1623
PA
123232010-09-24 Pedro Alves <pedro@codesourcery.com>
12324
e6ee044d
PA
12325 PR gdb/11842
12326
b53a1623
PA
12327 * linux-x86-low.c (compat_siginfo_from_siginfo)
12328 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
12329 si_code is < 0. Check for si_code == SI_TIMER before checking for
12330 si_code < 0.
12331
fa1bd1e4
JB
123322010-09-13 Joel Brobecker <brobecker@adacore.com>
12333
12334 * lynx-i386-low.c: New file.
12335 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
12336
47fac8f8
JB
123372010-09-13 Joel Brobecker <brobecker@adacore.com>
12338
12339 * lynx-low.c (ptrace_request_to_str): Remove handling for
12340 request values that have been removed in LynxOS 5.x.
12341
1adfc54d
JB
123422010-09-13 Joel Brobecker <brobecker@adacore.com>
12343
12344 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
12345 <ptrace.h>
12346
c2a66c29
NS
123472010-09-09 Nathan Sidwell <nathan@codesourcery.com>
12348
12349 * configure.ac: Add --enable-inprocess-agent option.
12350 * configure: Rebuilt.
12351
32fcada3
YQ
123522010-09-06 Yao Qi <yao@codesourcery.com>
12353
12354 * linux-low.c (linux_kill): Remove unused variable.
12355 (linux_stabilize_threads): Likewise.
12356 * server.c (start_inferior): Likewise.
12357 (queue_stop_reply_callback): Likewise.
12358 * tracepoint.c (do_action_at_tracepoint): Likewise.
12359
0cccb683
YQ
123602010-09-06 Yao Qi <yao@codesourcery.com>
12361
12362 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
12363 on return.
12364
423ec54c
JK
123652010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
12366
12367 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
12368
12ac6819
PA
123692010-09-06 Pedro Alves <pedro@codesourcery.com>
12370
12371 * Makefile.in (install-only): Replace $IPA_DEPFILES with
12372 "$(IPA_DEPFILES)".
12373
8ed54b31
JB
123742010-09-01 Joel Brobecker <brobecker@adacore.com>
12375
12376 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
12377 gdbserver/lynx-ppc-low.c: New files.
12378 * Makefile.in (lynx_low_h): New variable.
12379 (lynx-low.o, lynx-ppc-low.o): New rules.
12380 * configure.ac: On LynxOS, link with -lnetinet.
12381 * configure.srv: Add handling of powerpc-*-lynxos* targets.
12382 * configure: regenerate.
12383
bb0116a4
JB
123842010-09-01 Joel Brobecker <brobecker@adacore.com>
12385
12386 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
12387 * configure.ac: Add check for vasprintf and vsnprintf.
12388 * configure, config.in: Regenerate.
12389 * server.h (vasprintf, vsnprintf): Add conditional declarations.
12390
a778ab81 123912010-09-01 Joel Brobecker <brobecker@adacore.com>
12392
12393 * gdbreplay.c: Move include of alloca.h up, next to include of
12394 malloc.h.
12395 * server.h: Add include of malloc.h.
12396 * mem-break.c: Remove include of malloc.h.
12397 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
12398
8b034a19 123992010-09-01 Joel Brobecker <brobecker@adacore.com>
12400
12401 * Makefile.in (memmem.o): Build with -Wno-error.
12402
124032010-09-01 Joel Brobecker <brobecker@adacore.com>
12404
12405 * utils.c (xsnprintf): Make non-static.
12406 * server.h: Add xsnprintf declaration.
12407 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
12408 replace calls to snprintf by calls to xsnprintf throughout.
12409
124102010-09-01 Joel Brobecker <brobecker@adacore.com>
12411
12412 * configure.ac: Add configure check for alloca.
12413 * configure, config.in: Regenerate.
12414 * server.h: Include alloca.h if it exists.
12415 * gdbreplay.c: Include alloca.h if it exists.
12416
1a981360
PA
124172010-08-28 Pedro Alves <pedro@codesourcery.com>
12418
12419 * linux-low.c (__SIGRTMIN): Define if not already defined.
12420 (linux_create_inferior): Check for __ANDROID__ rather than
12421 __SIGRTMIN.
12422 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
12423 are already deferred.
12424 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
12425 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
12426 stopped and already has a pending signal to report.
12427 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
12428 a pending signal to report or is moving out of a jump pad.
12429 (linux_init_signals): Check for __ANDROID__ rather than
12430 __SIGRTMIN.
12431
b4d51a55
PA
124322010-08-28 Pedro Alves <pedro@codesourcery.com>
12433
12434 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
12435 debug_threads check. Avoid a linear search when not doing debug
12436 output.
12437
ec48365d
PA
124382010-08-27 Pedro Alves <pedro@codesourcery.com>
12439
12440 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
12441 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
12442 (struct file_handler) <fd>: Change type to gdb_fildes_t.
12443 (process_event): Change local fd's type to gdb_fildes_t.
12444 (create_file_handler): Adjust prototype.
12445 (delete_file_handler): Adjust prototype.
12446 (handle_file_event): Adjust prototype. Use pfildes.
12447 (create_file_event): Adjsut prototype.
12448 * remote-utils.c (remote_desc, listen_desc): Change type to
12449 gdb_fildes_t.
12450 * server.h: New gdb_fildes_t typedef.
12451 [USE_WIN32API]: Include winsock2.h.
12452 (delete_file_handler, add_file_handler): Adjust prototypes.
12453 (pfildes): Declare.
12454 * utils.c (pfildes): New.
12455
854d88f0
PA
124562010-08-27 Pedro Alves <pedro@codesourcery.com>
12457
12458 * configure.ac (build_warnings): Add -Wno-char-subscripts.
12459 * configure: Regenerate.
12460
0146f85b
PA
124612010-08-27 Pedro Alves <pedro@codesourcery.com>
12462
12463 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
12464 (linux_done_accessing_memory): ... this.
12465 (linux_target_ops): Adjust.
12466 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
12467 * nto-low.c (nto_target_ops): Adjust comment.
12468 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
12469 * spu-low.c (spu_target_ops): Adjust comment.
12470 * target.h (target_ops): Rename unprepare_to_access_memory field
12471 to done_accessing_memory.
12472 (unprepare_to_access_memory): Rename to ...
12473 (done_accessing_memory): ... this.
12474
90d74c30
PA
124752010-08-26 Pedro Alves <pedro@codesourcery.com>
12476
12477 * linux-low.c (linux_prepare_to_access_memory): New.
12478 (linux_unprepare_to_access_memory): New.
12479 (linux_target_ops): Install them.
12480 * server.c (read_memory): Rename to ...
12481 (gdb_read_memory): ... this. Use
12482 prepare_to_access_memory/prepare_to_access_memory.
12483 (write_memory): Rename to ...
12484 (gdb_write_memory): ... this. Use
12485 prepare_to_access_memory/prepare_to_access_memory.
12486 (handle_search_memory_1): Adjust.
12487 (process_serial_event): Adjust.
12488 * target.h (struct target_ops): New fields
12489 prepare_to_access_memory and unprepare_to_access_memory.
12490 (prepare_to_access_memory, unprepare_to_access_memory): New.
12491 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
12492 prepare_to_access_memory/prepare_to_access_memory.
12493 * nto-low.c (nto_target_ops): Adjust.
12494 * spu-low.c (spu_target_ops): Adjust.
12495 * win32-low.c (win32_target_ops): Adjust.
12496
fd467969
PA
124972010-08-26 Pedro Alves <pedro@codesourcery.com>
12498
12499 * Makefile.in (WARN_CFLAGS): Get it from configure.
12500 (WERROR_CFLAGS): New.
12501 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
12502 * configure.ac: Introduce --enable-werror, which adds -Werror to
12503 the compiler command line. Enabled by default. Disable with
12504 --disable-werror. Add -Wdeclaration-after-statement
12505 Wpointer-arith and -Wformat-nonliteral to warning flags.
12506 * configure: Regenerate.
12507
331e2f5f
PA
125082010-08-26 Pedro Alves <pedro@codesourcery.com>
12509
12510 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
12511
e581f2b4
PA
125122010-08-26 Pedro Alves <pedro@codesourcery.com>
12513
12514 * gdbreplay.c (remote_error): New.
12515 (gdbchar): New.
12516 (expect): Use gdbchar. Check for error reading from GDB.
12517 Clarify sync error output.
12518 (play): Check for errors writing to GDB.
12519 * linux-low.c (sigchld_handler): Really ignore `write' errors.
12520 * remote-utils.c (getpkt): Check for errors writing to the remote
12521 descriptor.
12522
3c11dd79
PA
125232010-08-25 Pedro Alves <pedro@codesourcery.com>
12524
12525 * linux-low.c (linux_wait_1): Move non-debugging code out of
12526 `debug_threads' control.
12527
d20a8ad9
PA
125282010-08-25 Pedro Alves <pedro@codesourcery.com>
12529
12530 * linux-low.c (linux_wait_1): Don't set last_status here.
12531 * server.c (push_event, queue_stop_reply_callback): Assert we're
12532 not pushing a TARGET_WAITKIND_IGNORE event.
12533 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
12534 (myresume, handle_target_event): Set the thread's last_resume_kind
12535 and last_status from the target returned status.
12536
964e4306
PA
125372010-08-25 Pedro Alves <pedro@codesourcery.com>
12538
12539 PR threads/10729
12540
12541 * linux-x86-low.c (update_debug_registers_callback): New.
12542 (i386_dr_low_set_addr): Use it.
12543 (i386_dr_low_get_addr): New.
12544 (i386_dr_low_set_control): Use update_debug_registers_callback.
12545 (i386_dr_low_get_control): New.
12546 (i386_dr_low_get_status): Adjust.
12547 * linux-low.c (linux_stop_lwp): New.
12548 * linux-low.h (linux_stop_lwp): Declare.
12549
12550 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
12551 argument instead of a i386_debug_reg_state.
12552 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
12553 a i386_debug_reg_state.
12554 (i386_insert_aligned_watchpoint): Adjust.
12555 (i386_remove_aligned_watchpoint): Adjust.
12556 (i386_low_stopped_data_address): Read the debug registers from the
12557 inferior instead of from the mirrors.
12558 * i386-low.h (struct i386_debug_reg_state): Extend comment.
12559 (i386_dr_low_get_addr): Declare.
12560 (i386_dr_low_get_control): Declare.
12561 (i386_dr_low_get_status): Change prototype.
12562
12563 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
12564 (i386_dr_low_get_addr): New.
12565 (i386_dr_low_get_control): New.
12566 (i386_dr_low_get_status): Adjust prototype. Return
12567 dr_status_mirror.
12568 (i386_initial_stuff): Clear dr_status_mirror and
12569 dr_control_mirror.
12570 (i386_get_thread_context): Adjust.
12571 (i386_set_thread_context): Adjust.
12572 (i386_thread_added): Adjust.
12573
5f21a75b
PA
125742010-08-24 Pedro Alves <pedro@codesourcery.com>
12575
12576 * linux-low.h (linux_thread_area): Delete declaration.
12577
3e4c1235
TS
125782010-08-11 Thomas Schwinge <thomas@codesourcery.com>
12579
12580 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
12581 after its termination.
12582
1971b033
PA
125832010-08-09 Pedro Alves <pedro@codesourcery.com>
12584
12585 * linux-low.c (gdb_wants_lwp_stopped): Delete.
12586 (gdb_wants_all_stopped): Delete.
12587 (linux_wait_1): Don't call them.
12588 * server.c (handle_v_cont): Tag all threads as want-stopped.
12589 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
12590 stopped as "client-wants-stopped".
12591
310444ac
PA
125922010-07-31 Pedro Alves <pedro@codesourcery.com>
12593
12594 * Makefile.in (signals_h): New.
12595 (server_h): Depend on it.
12596 (server.o): Don't depend on $(signals_def).
12597 (signals.o): Depend on $(signals_def).
12598
a19cae16
JK
125992010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
12600
12601 * Makefile.in (signals_def): New.
12602 (server_h): Append include/gdb/signals.h and signals_def.
12603 (server.o): Append signals_def.
12604
30d50328
JK
126052010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
12606
12607 * server.c (handle_target_event): Use target_signal_to_host for
12608 resume_info.sig initialization.
12609 * target.h (struct thread_resume) <sig>: New comment.
12610
5c3216e2
OS
126112010-07-20 Ozkan Sezer <sezeroz@gmail.com>
12612
c6f46ca0
OS
12613 * server.c (handle_query): strcpy() the returned string from paddress()
12614 instead of sprintf().
5c3216e2
OS
12615 * utils.c (paddress): Return phex_nz().
12616
6bd31874
JB
126172010-07-07 Joel Brobecker <brobecker@adacore.com>
12618
12619 * server.c (handle_v_cont): Call mourn_inferior if process
12620 just exited.
12621 (myresume): Likewise.
12622
0fb4aa4b
PA
126232010-07-01 Pedro Alves <pedro@codesourcery.com>
12624
12625 Static tracepoints, and integration with UST.
12626
12627 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
12628 * mem-break.c (uninsert_all_breakpoints)
12629 (reinsert_all_breakpoints): New.
12630 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
12631 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
12632 (gdb_agent_ust_loaded, helper_thread_id)
12633 (gdb_agent_helper_thread_id): New macros.
12634 (struct ipa_sym_addresses): Add addr_ust_loaded,
12635 addr_helper_thread_id, addr_cmd_buf.
12636 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
12637 (in_process_agent_loaded_ust): New.
12638 (write_e_ust_not_loaded): New.
12639 (maybe_write_ipa_ust_not_loaded): New.
12640 (struct collect_static_trace_data_action): New.
12641 (enum tracepoint_type) <static_tracepoint>: New.
12642 (struct tracepoint) <handle>: Mention static tracepoints.
12643 (struct static_tracepoint_ctx): New.
12644 (CMD_BUF_SIZE): New.
12645 (add_tracepoint_action): Handle static tracepoint actions.
12646 (unprobe_marker_at): New.
12647 (clear_installed_tracepoints): Handle static tracepoints.
12648 (cmd_qtdp): Handle static tracepoints.
12649 (probe_marker_at): New.
12650 (cmd_qtstart): Handle static tracepoints.
12651 (response_tracepoint): Handle static tracepoints.
12652 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
12653 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
12654 (get_context_regcache): Handle static tracepoints.
12655 (do_action_at_tracepoint): Handle static tracepoint actions.
12656 (traceframe_find_block_type): Handle static trace data blocks.
12657 (traceframe_read_sdata): New.
12658 (download_tracepoints): Download static tracepoint actions.
12659 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
12660 (GDB_PROBE_NAME): New.
12661 (ust_ops): New.
12662 (GET_UST_SYM): New.
12663 (USTF): New.
12664 (dlsym_ust): New.
12665 (ust_marker_to_static_tracepoint): New.
12666 (gdb_probe): New.
12667 (collect_ust_data_at_tracepoint): New.
12668 (gdb_ust_probe): New.
12669 (UNIX_PATH_MAX, SOCK_DIR): New.
12670 (gdb_ust_connect_sync_socket): New.
12671 (resume_thread, stop_thread): New.
12672 (run_inferior_command): New.
12673 (init_named_socket): New.
12674 (gdb_ust_socket_init): New.
12675 (cstr_to_hexstr): New.
12676 (next_st): New.
12677 (first_marker, next_marker): New.
12678 (response_ust_marker): New.
12679 (cmd_qtfstm, cmd_qtsstm): New.
12680 (unprobe_marker_at, probe_marker_at): New.
12681 (cmd_qtstmat, gdb_ust_thread): New.
12682 (gdb_ust_init): New.
12683 (initialize_tracepoint_ftlib): Call gdb_ust_init.
12684 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
12685 (ST_REGENTRY): New.
12686 (x86_64_st_collect_regmap): New.
12687 (X86_64_NUM_ST_COLLECT_GREGS): New.
12688 (AMD64_RIP_REGNUM): New.
12689 (supply_static_tracepoint_registers): New.
12690 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
12691 (ST_REGENTRY): New.
12692 (i386_st_collect_regmap): New.
12693 (i386_NUM_ST_COLLECT_GREGS): New.
12694 (supply_static_tracepoint_registers): New.
12695 * server.c (handle_query): Handle qXfer:statictrace:read.
12696 <qSupported>: Report support for StaticTracepoints, and
12697 qXfer:statictrace:read features.
12698 * server.h (traceframe_read_sdata)
12699 (supply_static_tracepoint_registers): Declare.
12700 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
12701 (unpack_varlen_hex): Include in IPA build.
12702 * Makefile.in (ustlibs, ustinc): New.
12703 (IPA_OBJS): Add remote-utils-ipa.o.
12704 ($(IPA_LIB)): Link -ldl and -lpthread.
12705 (UST_CFLAGS): New.
12706 (IPAGENT_CFLAGS): Add UST_CFLAGS.
12707 * config.in, configure: Regenerate.
12708
9e4344e5
PA
127092010-06-20 Ian Lance Taylor <iant@google.com>
12710 Pedro Alves <pedro@codesourcery.com>
12711
12712 * linux-x86-low.c (always_true): Delete.
12713 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
12714 trying to fool the compiler with always_true.
12715
c6beb2cb
PA
127162010-06-20 Pedro Alves <pedro@codesourcery.com>
12717
12718 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
12719 conditions in gdbserver.
12720
d2ed6730
UW
127212010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
12722
12723 * spu-low.c (spu_read_memory): Wrap around local store limit.
12724 (spu_write_memory): Likewise.
12725
4e29fb54
PA
127262010-06-15 Pedro Alves <pedro@codesourcery.com>
12727
12728 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
12729 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
12730 LONGEST uses.
12731 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
12732 uses.
12733 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
12734 uses with LONGEST uses.
12735
6a271cae
PA
127362010-06-14 Stan Shebs <stan@codesourcery.com>
12737 Pedro Alves <pedro@codesourcery.com>
12738
12739 Bytecode compiler.
12740
12741 * linux-x86-low.c: Include limits.h.
12742 (add_insns): New.
12743 (always_true): New.
12744 (EMIT_ASM): New.
12745 (EMIT_ASM32): New.
12746 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
12747 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
12748 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
12749 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
12750 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
12751 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
12752 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
12753 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
12754 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
12755 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
12756 (amd64_emit_void_call_2): New.
12757 (amd64_emit_ops): New.
12758 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
12759 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
12760 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
12761 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
12762 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
12763 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
12764 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
12765 (i386_emit_call, i386_emit_reg, i386_emit_pop)
12766 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
12767 (i386_emit_stack_adjust, i386_emit_int_call_1)
12768 (i386_emit_void_call_2): New.
12769 (i386_emit_ops): New.
12770 (x86_emit_ops): New.
12771 (the_low_target): Install x86_emit_ops.
12772 * server.h (struct emit_ops): New.
12773 (get_raw_reg_func_addr): Declare.
12774 (current_insn_ptr, emit_error): Declare.
12775 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
12776 (set_trace_state_variable_value): New defines.
12777 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
12778 addr_get_trace_state_variable_value and
12779 addr_set_trace_state_variable_value.
12780 (symbol_list): New fields for get_raw_reg,
12781 get_trace_state_variable_value and set_trace_state_variable_value.
12782 (condfn): New typedef.
12783 (struct tracepoint): New field `compiled_cond'.
12784 (do_action_at_tracepoint): Clear compiled_cond.
12785 (get_trace_state_variable_value, set_trace_state_variable_value):
12786 Export in the IPA.
12787 (condition_true_at_tracepoint): If there's a compiled condition,
12788 run that.
12789 (current_insn_ptr, emit_error): New globals.
12790 (struct bytecode_address): New.
12791 (get_raw_reg_func_addr): New.
12792 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
12793 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
12794 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
12795 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
12796 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
12797 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
12798 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
12799 (compile_tracepoint_condition, compile_bytecodes): New.
12800 * target.h (emit_ops): Forward declare.
12801 (struct target_ops): New field emit_ops.
12802 (target_emit_ops): New.
12803 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
12804 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
12805 * linux-low.c (linux_emit_ops): New.
12806 (linux_target_ops): Install it.
12807 * linux-low.h (struct linux_target_ops): New field emit_ops.
12808
92b72907
UW
128092010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
12810
12811 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
12812 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
12813
fa593d66
PA
128142010-06-01 Pedro Alves <pedro@codesourcery.com>
12815 Stan Shebs <stan@codesourcery.com>
12816
12817 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
12818 (all): Depend on $(extra_libraries).
12819 (install-only): Install the IPA.
12820 (IPA_OBJS, IPA_LIB): New.
12821 (clean): Remove the IPA lib.
12822 (IPAGENT_CFLAGS): New.
12823 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
12824 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
12825 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
12826 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
12827 * configure.ac: Check for atomic builtins support in the compiler.
12828 (IPA_DEPFILES, extra_libraries): Define.
12829 * configure.srv (ipa_obj): Add description.
12830 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
12831 (i[34567]86-*-linux*): Set ipa_obj.
12832 (x86_64-*-linux*): Set ipa_obj.
12833 * linux-low.c (stabilizing_threads): New.
12834 (supports_fast_tracepoints): New.
12835 (linux_detach): Stabilize threads before detaching.
12836 (handle_tracepoints): Handle internal tracing breakpoints. Assert
12837 the lwp is either not stabilizing, or is moving out of a jump pad.
12838 (linux_fast_tracepoint_collecting): New.
12839 (maybe_move_out_of_jump_pad): New.
12840 (enqueue_one_deferred_signal): New.
12841 (dequeue_one_deferred_signal): New.
12842 (linux_wait_for_event_1): If moving out of a jump pad, defer
12843 pending signals to later.
12844 (linux_stabilize_threads): New.
12845 (linux_wait_1): Check if threads need moving out of jump pads, and
12846 do it if so.
12847 (stuck_in_jump_pad_callback): New.
12848 (move_out_of_jump_pad_callback): New.
12849 (lwp_running): New.
12850 (linux_resume_one_lwp): Handle moving out of jump pads.
12851 (linux_set_resume_request): Dequeue deferred signals.
12852 (need_step_over_p): Also step over fast tracepoint jumps.
12853 (start_step_over): Also uninsert fast tracepoint jumps.
12854 (finish_step_over): Also reinsert fast tracepoint jumps.
12855 (linux_install_fast_tracepoint_jump): New.
12856 (linux_target_ops): Install linux_stabilize_threads and
12857 linux_install_fast_tracepoint_jump_pad.
12858 * linux-low.h (linux_target_ops) <get_thread_area,
12859 install_fast_tracepoint_jump_pad>: New fields.
12860 (struct lwp_info) <collecting_fast_tracepoint,
12861 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
12862 (linux_get_thread_area): Declare.
12863 * linux-x86-low.c (jump_insn): New.
12864 (x86_get_thread_area): New.
12865 (append_insns): New.
12866 (push_opcode): New.
12867 (amd64_install_fast_tracepoint_jump_pad): New.
12868 (i386_install_fast_tracepoint_jump_pad): New.
12869 (x86_install_fast_tracepoint_jump_pad): New.
12870 (the_low_target): Install x86_get_thread_area and
12871 x86_install_fast_tracepoint_jump_pad.
12872 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
12873 (struct fast_tracepoint_jump): New.
12874 (fast_tracepoint_jump_insn): New.
12875 (fast_tracepoint_jump_shadow): New.
12876 (find_fast_tracepoint_jump_at): New.
12877 (fast_tracepoint_jump_here): New.
12878 (delete_fast_tracepoint_jump): New.
12879 (set_fast_tracepoint_jump): New.
12880 (uninsert_fast_tracepoint_jumps_at): New.
12881 (reinsert_fast_tracepoint_jumps_at): New.
12882 (set_breakpoint_at): Use write_inferior_memory.
12883 (uninsert_raw_breakpoint): Use write_inferior_memory.
12884 (check_mem_read): Mask out fast tracepoint jumps.
12885 (check_mem_write): Mask out fast tracepoint jumps.
12886 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
12887 (set_fast_tracepoint_jump): Declare.
12888 (delete_fast_tracepoint_jump)
12889 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
12890 (reinsert_fast_tracepoint_jumps_at): Declare.
12891 * regcache.c: Don't compile many functions when building the
12892 in-process agent library.
12893 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
12894 the register buffer in the heap.
12895 (free_register_cache): If the register buffer isn't owned by the
12896 regcache, don't free it.
12897 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
12898 pre-existing register caches.
12899 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
12900 type.
12901 (convert_ascii_to_int): : Constify `from' parameter type.
12902 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
12903 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
12904 the needed buffer in-place.
12905 (relocate_instruction): New.
12906 * server.c (handle_query) <qSymbols>: If the target supports
12907 tracepoints, give it a chance of looking up symbols. Report
12908 support for fast tracepoints.
12909 (handle_status): Stabilize threads.
12910 (process_serial_event): Adjust.
12911 * server.h (struct fast_tracepoint_jump): Forward declare.
12912 (struct process_info) <fast_tracepoint_jumps>: New field.
12913 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
12914 (decode_X_packet, decode_M_packet): Adjust.
12915 (relocate_instruction): Declare.
12916 (in_process_agent_loaded): Declare.
12917 (tracepoint_look_up_symbols): Declare.
12918 (struct fast_tpoint_collect_status): Declare.
12919 (fast_tracepoint_collecting): Declare.
12920 (force_unlock_trace_buffer): Declare.
12921 (handle_tracepoint_bkpts): Declare.
12922 (initialize_low_tracepoint)
12923 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
12924 * target.h (struct target_ops) <stabilize_threads,
12925 install_fast_tracepoint_jump_pad>: New fields.
12926 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
12927 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
12928 [HAVE_STDINT_H]: Include stdint.h.
12929 (trace_debug_1): Rename to ...
12930 (trace_vdebug): ... this.
12931 (trace_debug): Rename to ...
12932 (trace_debug_1): ... this. Add `level' parameter.
12933 (trace_debug): New.
12934 (ATTR_USED, ATTR_NOINLINE): New.
12935 (IP_AGENT_EXPORT): New.
12936 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
12937 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
12938 (about_to_request_buffer_space, trace_buffer_is_full)
12939 (stopping_tracepoint, expr_eval_result, error_tracepoint)
12940 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
12941 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
12942 (traceframe_write_count, traceframes_created)
12943 (trace_state_variables)
12944 New renaming defines.
12945 (struct ipa_sym_addresses): New.
12946 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
12947 (symbol_list): New.
12948 (ipa_sym_addrs): New.
12949 (all_tracepoint_symbols_looked_up): New.
12950 (in_process_agent_loaded): New.
12951 (write_e_ipa_not_loaded): New.
12952 (maybe_write_ipa_not_loaded): New.
12953 (tracepoint_look_up_symbols): New.
12954 (debug_threads) [IN_PROCESS_AGENT]: New.
12955 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
12956 (UNKNOWN_SIDE_EFFECTS): New.
12957 (stop_tracing): New.
12958 (flush_trace_buffer): New.
12959 (stop_tracing_bkpt): New.
12960 (flush_trace_buffer_bkpt): New.
12961 (read_inferior_integer): New.
12962 (read_inferior_uinteger): New.
12963 (read_inferior_data_pointer): New.
12964 (write_inferior_data_pointer): New.
12965 (write_inferior_integer): New.
12966 (write_inferior_uinteger): New.
12967 (struct collect_static_trace_data_action): Delete.
12968 (enum tracepoint_type): New.
12969 (struct tracepoint) <type>: New field `type'.
43aaf8b6
PA
12970 <actions_str, step_actions, step_actions_str>: Only include in
12971 GDBserver.
fa593d66
PA
12972 <orig_size, obj_addr_on_target, adjusted_insn_addr>
12973 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
12974 (tracepoints): Use IP_AGENT_EXPORT.
12975 (last_tracepoint): Don't include in the IPA.
12976 (stopping_tracepoint): Use IP_AGENT_EXPORT.
12977 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
12978 (alloced_trace_state_variables): New.
12979 (trace_state_variables): Use IP_AGENT_EXPORT.
12980 (traceframe_t): Delete unused variable.
12981 (circular_trace_buffer): Don't include in the IPA.
12982 (trace_buffer_start): Delete.
12983 (struct trace_buffer_control): New.
12984 (trace_buffer_free): Delete.
12985 (struct ipa_trace_buffer_control): New.
12986 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
12987 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
12988 New.
12989 (trace_buffer_ctrl): New.
12990 (TRACE_BUFFER_CTRL_CURR): New.
12991 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
12992 Reimplement as macros.
12993 (trace_buffer_wrap): Delete.
12994 (traceframe_write_count, traceframe_read_count)
12995 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
12996 (struct tracepoint_hit_ctx) <type>: New field.
12997 (struct fast_tracepoint_ctx): New.
12998 (memory_barrier): New.
12999 (cmpxchg): New.
13000 (record_tracepoint_error): Update atomically in the IPA.
13001 (clear_inferior_trace_buffer): New.
13002 (about_to_request_buffer_space): New.
13003 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
13004 updating the same buffer.
13005 (add_tracepoint): Default the tracepoint's type to trap
13006 tracepoint, and orig_size to -1.
13007 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
13008 internal variables.
13009 (create_trace_state_variable): New parameter `gdb'. Handle it.
13010 (clear_installed_tracepoints): Clear fast tracepoint jumps.
13011 (cmd_qtdp): Handle fast tracepoints.
13012 (cmd_qtdv): Adjust.
13013 (max_jump_pad_size): New.
13014 (gdb_jump_pad_head): New.
13015 (get_jump_space_head): New.
13016 (claim_jump_space): New.
13017 (sort_tracepoints): New.
13018 (MAX_JUMP_SIZE): New.
13019 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
13020 IPA.
13021 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
13022 support. Upload fast traceframes, and delete internal IPA
13023 breakpoints.
13024 (stop_tracing_handler): New.
13025 (flush_trace_buffer_handler): New.
13026 (cmd_qtstop): Upload fast tracepoints.
13027 (response_tracepoint): Handle fast tracepoints.
13028 (tracepoint_finished_step): Upload fast traceframes. Set the
13029 tracepoint hit context's tracepoint type.
13030 (handle_tracepoint_bkpts): New.
13031 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
13032 type. Add comment about fast tracepoints.
13033 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
13034 non-existing action_str field.
13035 (get_context_regcache): Handle fast tracepoints.
13036 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
13037 to the regcache.
13038 (fast_tracepoint_from_jump_pad_address): New.
13039 (fast_tracepoint_from_ipa_tpoint_address): New.
13040 (collecting_t): New.
13041 (force_unlock_trace_buffer): New.
13042 (fast_tracepoint_collecting): New.
13043 (collecting): New.
13044 (gdb_collect): New.
13045 (write_inferior_data_ptr): New.
13046 (target_tp_heap): New.
13047 (target_malloc): New.
13048 (download_agent_expr): New.
13049 (UALIGN): New.
13050 (download_tracepoints): New.
13051 (download_trace_state_variables): New.
13052 (upload_fast_traceframes): New.
13053 (IPA_FIRST_TRACEFRAME): New.
13054 (IPA_NEXT_TRACEFRAME_1): New.
13055 (IPA_NEXT_TRACEFRAME): New.
13056 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
13057 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
13058 (gdb_jump_pad_buffer_end): New.
13059 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
13060 (initialize_tracepoint): Adjust.
13061 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
13062 buffer. Initialize the low module.
13063 * utils.c (PREFIX, TOOLNAME): New.
13064 (malloc_failure): Use PREFIX.
13065 (error): In the IPA, an error causes an exit.
13066 (fatal, warning): Use PREFIX.
13067 (internal_error): Use TOOLNAME.
13068 (NUMCELLS): Increase to 10.
13069 * configure, config.in: Regenerate.
13070
d149dd1d
PA
130712010-06-01 Pedro Alves <pedro@codesourcery.com>
13072
13073 * server.c (handle_query) <qSupported>: Do two passes over the
13074 qSupported string to avoid nesting strtok.
13075
f6528abd
JK
130762010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13077
13078 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
13079 (CDEPS): New.
13080 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
13081 -Wl,--dynamic-list.
13082 * configure: Regenerate.
13083 * proc-service.list: New.
13084
ca2a87a0
JK
130852010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13086
13087 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
13088 New comment.
13089
363a6e9f
OS
130902010-05-26 Ozkan Sezer <sezeroz@gmail.com>
13091
13092 * gdbreplay.c (remote_open): Check error return from socket() call by
13093 its equality to -1 not by it being negative.
13094 * remote-utils.c (remote_open): Likewise.
13095
d23b6cb1
PA
130962010-05-23 Pedro Alves <pedro@codesourcery.com>
13097
13098 * config.h: Regenerate.
13099
28d3cf85
MK
131002010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
13101
13102 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
13103 doesn't provide PTRACE_GET_THREAD_AREA.
13104
fea36a59
MK
131052010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
13106
13107 * linux-m68k-low.c: Include <asm/ptrace.h>
13108 (ps_get_thread_area): Implement.
13109
24b066ba
DE
131102010-05-03 Doug Evans <dje@google.com>
13111
13112 * event-loop.c (struct callback_event): New struct.
13113 (callback_list): New global.
13114 (append_callback_event, delete_callback_event): New functions.
13115 (process_callback): New function.
13116 (start_event_loop): Call it.
13117 * remote-utils.c (NOT_SCHEDULED): Define.
13118 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
13119 moved out of readchar.
13120 (readchar): Rewrite. Call reschedule before returning.
13121 (reset_readchar): New function.
13122 (remote_close): Call it.
13123 (process_remaining, reschedule): New functions.
13124 * server.h (callback_handler_func): New typedef.
13125 (append_callback_event, delete_callback_event): Declare.
13126
9836d6ea
PA
131272010-05-03 Pedro Alves <pedro@codesourcery.com>
13128
13129 * proc-service.c (ps_pglobal_lookup): Use
13130 thread_db_look_up_one_symbol.
13131 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
13132 parameter. Use it instead of all_symbols_looked_up.
13133 * server.h (struct process_info) <all_symbols_looked_up>: Delete
13134 field.
13135 (all_symbols_looked_up): Don't declare.
13136 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
13137 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
13138 field.
13139 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
13140 Set all_symbols_looked_up here.
13141 (thread_db_look_up_one_symbol): New.
13142 (thread_db_get_tls_address): Adjust.
13143 (thread_db_load_search, try_thread_db_load_1): Always allocate the
13144 thread_db object on the heap, and tentatively set it in the
13145 process structure.
13146 (thread_db_init): Don't set all_symbols_looked_up here.
13147 * linux-low.h (thread_db_look_up_one_symbol): Declare.
13148
7984d532
PA
131492010-05-03 Pedro Alves <pedro@codesourcery.com>
13150
13151 * linux-low.c (linux_kill, linux_detach): Adjust.
13152 (status_pending_p_callback): Remove redundant statement. Check
13153 for !TARGET_WAITIKIND_IGNORE, instead of
13154 TARGET_WAITKIND_STOPPED.
13155 (handle_tracepoints): Make sure LWP is locked. Adjust.
13156 (linux_wait_for_event_1): Adjust.
13157 (linux_cancel_breakpoints): New.
13158 (unsuspend_one_lwp): New.
13159 (unsuspend_all_lwps): New.
13160 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
13161 (send_sigstop_callback): Change return type to int, add new
13162 `except' parameter and handle it.
13163 (suspend_and_send_sigstop_callback): New.
13164 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
13165 pass them down. If SUSPEND, also increment the lwp's suspend
13166 count.
13167 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
13168 (need_step_over_p): Don't consider suspended LWPs.
13169 (start_step_over): Adjust.
13170 (proceed_one_lwp): Change return type to int, add new `except'
13171 parameter and handle it.
13172 (unsuspend_and_proceed_one_lwp): New.
13173 (proceed_all_lwps): Use find_inferior instead of
13174 for_each_inferior.
13175 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
13176 also decrement the suspend count of LWPs. Pass `except' down,
13177 instead of hacking its suspend count.
13178 (linux_pause_all): Add `freeze' parameter. Adjust.
13179 (linux_unpause_all): New.
13180 (linux_target_ops): Install linux_unpause_all.
13181 * server.c (handle_status): Adjust.
13182 * target.h (struct target_ops): New fields `unpause_all' and
13183 `cancel_breakpoints'. Add new parameter to `pause_all'.
13184 (pause_all): Add new `freeze' parameter.
13185 (unpause_all): New.
13186 (cancel_breakpoints): New.
13187 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
13188 cancel breakpoints.
13189 (cmd_qtstart): Pause threads.
13190 (stop_tracing): Pause threads, and cancel breakpoints.
13191 * win32-low.c (win32_target_ops): Adjust.
13192
e471f25b
PA
131932010-05-03 Pedro Alves <pedro@codesourcery.com>
13194
13195 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
13196 the inferior right away from here...
13197 (linux_wait_1): ... to here, and adjust to check the thread's
13198 last_resume_kind instead of the lwp's step or stop_expected flags.
13199
1915ef4f
PA
132002010-05-02 Pedro Alves <pedro@codesourcery.com>
13201
13202 * README: Use consistent `GDB' and `GDBserver' spellings.
13203
f9e39928
PA
132042010-05-02 Pedro Alves <pedro@codesourcery.com>
13205
13206 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
13207 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
13208 (linux_detach_one_lwp): Assume the lwp is stopped.
13209 (any_thread_of): Delete.
13210 (linux_detach): Stop all lwps here. Don't blindly delete all
13211 breakpoints.
13212 (delete_lwp_callback): New.
13213 (linux_mourn): Delete all lwps of the process that is gone.
13214 (linux_wait_1): Don't delete the last lwp of the process here.
13215 * mem-break.h (mark_breakpoints_out): Declare.
13216 * mem-break.c (mark_breakpoints_out): New.
13217 (free_all_breakpoints): Use it.
13218 * server.c (handle_target_event): If the process is gone, mark
13219 breakpoints out.
13220 * thread-db.c (struct thread_db) <create_bp>: New field.
13221 (thread_db_enable_reporting): Fix prototype. Store a thread event
13222 breakpoint reference in the thread_db struct.
13223 (thread_db_load_search): Clear the thread_db object.
13224 (try_thread_db_load_1): Ditto.
13225 (switch_to_process): New.
13226 (disable_thread_event_reporting): Use it.
13227 (remove_thread_event_breakpoints): New.
13228 (thread_db_detach, thread_db_mourn): Use it.
13229
1e7fc18c
PA
132302010-05-01 Pedro Alves <pedro@codesourcery.com>
13231
13232 * linux-low.c (linux_enable_event_reporting): New.
13233 (linux_wait_for_event_1, handle_extended_wait): Use it.
13234
02fc4de7
PA
132352010-04-30 Pedro Alves <pedro@codesourcery.com>
13236
13237 * linux-low.c (linux_kill_one_lwp, linux_kill)
13238 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
13239 (send_sigstop): Take an lwp_info as parameter instead. Queue a
13240 SIGSTOP even if the LWP is stopped.
13241 (send_sigstop_callback): New.
13242 (stop_all_lwps): Use send_sigstop_callback instead.
13243 (linux_resume_one_thread): Adjust.
13244 (proceed_one_lwp): Still proceed an LWP that the client has
13245 requested to stop, if we haven't reported it as stopped yet. Make
13246 sure that LWPs the client want stopped, have a pending SIGSTOP.
13247
bc3b5632
DE
132482010-04-26 Doug Evans <dje@google.com>
13249
ae1ada35
DE
13250 * server.c (handle_general_set): Make static.
13251
bc3b5632
DE
13252 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
13253 Print received char after testing for error/eof instead of before.
13254 (input_interrupt): Tweak comment.
13255
65730243
DE
132562010-04-23 Doug Evans <dje@google.com>
13257
13258 * server.c (start_inferior): Print inferior argv if --debug.
13259
a8ae7dc0
AR
132602010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
13261
13262 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
13263 * nto-x86-low.c: Include server.h
13264
1c07cc19
PM
132652010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
13266
13267 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
13268 be consistent with other sources of this directory.
13269 (init_registers_amd64): Correct name of source file of this function
13270 in the comment.
13271
e0a61e09
PM
132722010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13273
13274 * configure.srv (x86_64-*-mingw*): New configuration for Windows
13275 64-bit executables.
13276
54709339
PM
132772010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13278
13279 * win32-i386-low.c: Add 64-bit support.
13280 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
13281 (init_registers_amd64): Declare.
13282 (mappings): Add 64-bit version of array.
13283 (init_windows_x86): New function.
13284 (the_low_target): Change init_arch field to init_windows_x86.
13285
e8f0053d
PM
132862010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13287
13288 * win32-low.c: Adapt to support also 64-bit architecture.
13289 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
13290 (get_image_name): Use SIZE_T type for local variable `done'.
13291 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
13292 (toolhelp_get_dll_name): Idem.
13293 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
13294 Use uintptr_t typecast to avoid warning.
13295 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
13296 (handle_exception): Use phex_nz to avoid warning.
13297 (win32_wait): Remove unused local variable `process'.
13298
c481e77e
PM
132992010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13300
13301 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
13302 `amd64-avx.o'.
13303
12ea4b69
PM
133042010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
13305
13306 * configure.ac: Use `ws2_32' library for srv_mingw.
13307 * configure: Regenerate.
13308 * gdbreplay.c: Include winsock2.h instead of winsock.h.
13309 * remote-utils.c: Likewise.
13310
f6d1620c
L
133112010-04-17 H.J. Lu <hongjiu.lu@intel.com>
13312
13313 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
13314 if __x86_64__ is defined.
13315
8e642873
PM
133162010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
13317
13318 * configure: Regenerate.
13319
711e434b
PM
133202010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
13321
13322 * server.c (handle_query): Handle 'qGetTIBAddr' query.
13323 * target.h (target_ops): New get_tib_address field.
13324 * win32-low.h (win32_thread_info): Add thread_local_base field.
13325 * win32-low.c (child_add_thread): Add tlb argument.
13326 Set thread_local_base field to TLB.
13327 (get_child_debug_event): Adapt to child_add_thread change.
13328 (win32_get_tib_address): New function.
13329 (win32_target_ops): Set get_tib_address field to
13330 win32_get_tib_address.
13331 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
13332
505106cd
PA
133332010-04-12 Pedro Alves <pedro@codesourcery.com>
13334
505106cd
PA
13335 * linux-low.c (linux_mourn): Also remove the process.
13336 * server.c (handle_target_event): Don't remove the process here.
13337 * nto-low.c (nto_mourn): New.
13338 (nto_target_ops): Install it.
13339 * spu-low.c (spu_mourn): New.
13340 (spu_target_ops): Install it.
13341 * win32-low.c (win32_mourn): New.
13342 (win32_target_ops): Install it.
13343
e8470a06
PA
133442010-04-12 Pedro Alves <pedro@codesourcery.com>
13345
13346 * server.h (buffer_xml_printf): Remove redundant `;'.
13347
45ba0d02
PA
133482010-04-12 Pedro Alves <pedro@codesourcery.com>
13349
13350 * regcache.c (set_register_cache): Invalidate regcaches before
13351 changing the register cache layout.
13352 (regcache_invalidate_one): Allow a NULL regcache.
13353 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
13354 regcaches before changing the register cache layout or the target
13355 regsets.
13356
59e04013
L
133572010-04-12 H.J. Lu <hongjiu.lu@intel.com>
13358
13359 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
13360 variable warning on Linux/x86-64.
13361
8336d594
PA
133622010-04-11 Pedro Alves <pedro@codesourcery.com>
13363
13364 GDBserver disconnected tracing support.
13365
13366 * linux-low.c (linux_remove_process): Delete.
13367 (add_lwp): Don't set last_resume_kind here.
13368 (linux_kill): Use `mourn'.
13369 (linux_detach): Use `thread_db_detach', and `mourn'.
13370 (linux_mourn): New.
13371 (linux_attach_lwp_1): Adjust comment.
13372 (linux_attach): last_resume_kind moved the thread_info; adjust.
13373 (status_pending_p_callback): Adjust.
13374 (linux_wait_for_event_1): Adjust.
13375 (count_events_callback, select_singlestep_lwp_callback)
13376 (select_event_lwp_callback, cancel_breakpoints_callback)
13377 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
13378 (proceed_one_lwp): Adjust.
13379 (linux_async): Add debug output.
13380 (linux_thread_stopped): New.
13381 (linux_pause_all): New.
13382 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
13383 linux_pause_all.
13384 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
13385 (thread_db_free): Delete declaration.
13386 (thread_db_detach, thread_db_mourn): Declare.
13387 * thread-db.c (thread_db_init): Use thread_db_mourn.
13388 (thread_db_free): Delete, split in two.
13389 (disable_thread_event_reporting): New.
13390 (thread_db_detach): New.
13391 (thread_db_mourn): New.
13392
13393 * server.h (struct thread_info) <last_resume_kind>: New field.
13394 <attached>: Add comment.
13395 <gdb_detached>: New field.
13396 (handler_func): Change return type to int.
13397 (handle_serial_event, handle_target_event): Ditto.
13398 (gdb_connected): Declare.
13399 (tracing): Delete.
13400 (disconnected_tracing): Declare.
13401 (stop_tracing): Declare.
13402
13403 * server.c (handle_query) <qSupported>: Report support for
13404 disconnected tracing.
13405 (queue_stop_reply_callback): Account for running threads.
13406 (gdb_wants_thread_stopped): New.
13407 (gdb_wants_all_threads_stopped): New.
13408 (gdb_reattached_process): New.
13409 (handle_status): Clear the `gdb_detached' flag of all processes.
13410 In all-stop, stop all threads.
13411 (main): Be sure to leave tfind mode. Handle disconnected tracing.
13412 (process_serial_event): If the remote connection breaks, or if an
13413 exit was forced with "monitor exit", force an event loop exit.
13414 Handle disconnected tracing on detach.
13415 (handle_serial_event): Adjust.
13416 (handle_target_event): If GDB isn't connected, forward events back
13417 to the inferior, unless the last process exited, in which case,
13418 exit gdbserver. Adjust interface.
13419
13420 * remote-utils.c (remote_open): Don't block in accept. Instead
13421 register an event loop source on the listen socket file
13422 descriptor. Refactor bits into ...
13423 (listen_desc): ... this new global.
13424 (gdb_connected): ... this new function.
13425 (enable_async_notification): ... this new function.
13426 (handle_accept_event): ... this new function.
13427 (remote_close): Clear remote_desc.
13428
13429 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
13430
13431 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
13432 New fields.
13433 (mourn_inferior): Define.
13434 (target_process_qsupported): Avoid the dangling else problem.
13435 (thread_stopped): Define.
13436 (pause_all): Define.
13437 (target_waitstatus_to_string): Declare.
13438 * target.c (target_waitstatus_to_string): New.
13439
13440 * tracepoint.c (tracing): Make extern.
13441 (disconnected_tracing): New.
13442 (stop_tracing): Make extern. Handle tracing stops due to GDB
13443 disconnecting.
13444 (cmd_qtdisconnected): New.
13445 (cmd_qtstatus): Report disconnected tracing status in trace reply.
13446 (handle_tracepoint_general_set): Handle QTDisconnected.
13447
13448 * event-loop.c (event_handler_func): Change return type to int.
13449 (process_event): Bail out if the event handler wants the event
13450 loop to stop.
13451 (handle_file_event): Ditto.
13452 (start_event_loop): Bail out if the event handler wants the event
13453 loop to stop.
13454
13455 * nto-low.c (nto_target_ops): Adjust.
13456 * spu-low.c (spu_wait): Don't remove the process here.
13457 (spu_target_ops): Adjust.
13458 * win32-low.c (win32_wait): Don't remove the process here.
13459 (win32_target_ops): Adjust.
13460
5d267c4c
PA
134612010-04-11 Pedro Alves <pedro@codesourcery.com>
13462
13463 * regcache.c (realloc_register_cache): Invalidate inferior's
13464 regcache before recreating it.
13465
623ccd72
PA
134662010-04-09 Pedro Alves <pedro@codesourcery.com>
13467
13468 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
13469
219f2f23
PA
134702010-04-09 Stan Shebs <stan@codesourcery.com>
13471 Pedro Alves <pedro@codesourcery.com>
13472
13473 * server.h (LONGEST): New.
13474 (struct thread_info) <while_stepping>: New field.
13475 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
13476 Declare.
13477 (initialize_tracepoint, handle_tracepoint_general_set)
13478 (handle_tracepoint_query, tracepoint_finished_step)
13479 (tracepoint_was_hit, release_while_stepping_state_list):
13480 (current_traceframe): Declare.
13481 * server.c (handle_general_set): Handle tracepoint packets.
13482 (read_memory): New.
13483 (write_memory): New.
13484 (handle_search_memory_1): Use read_memory.
13485 (handle_query): Report support for conditional tracepoints, trace
13486 state variables, and tracepoint sources. Handle tracepoint
13487 queries.
13488 (main): Initialize the tracepoints module.
13489 (process_serial_event): Handle traceframe reads/writes.
13490
13491 * linux-low.c (handle_tracepoints): New.
13492 (linux_wait_1): Call it.
13493 (linux_resume_one_lwp): Handle while-stepping.
13494 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
13495 (linux_target_ops): Install them.
13496 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
13497 New field.
13498 * linux-x86-low.c (x86_supports_tracepoints): New.
13499 (the_low_target). Install it.
13500
13501 * mem-break.h (delete_breakpoint): Declare.
13502 * mem-break.c (delete_breakpoint): Make external.
13503
13504 * target.h (struct target_ops): Add `supports_tracepoints',
13505 `read_pc', and `write_pc' fields.
13506 (target_supports_tracepoints): Define.
13507 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
13508 (phex_nz): New.
13509
13510 * regcache.h (struct regcache) <registers_owned>: New field.
13511 (init_register_cache, regcache_cpy): Declare.
13512 (regcache_read_pc, regcache_write_pc): Declare.
13513 (register_cache_size): Declare.
13514 (supply_regblock): Declare.
13515 * regcache.c (init_register_cache): New.
13516 (new_register_cache): Use it.
13517 (regcache_cpy): New.
13518 (register_cache_size): New.
13519 (supply_regblock): New.
13520 (regcache_read_pc, regcache_write_pc): New.
889bf7c5 13521
219f2f23
PA
13522 * tracepoint.c: New.
13523
13524 * Makefile.in (OBS): Add tracepoint.o.
13525 (tracepoint.o): New rule.
13526
3a13a53b
L
135272010-04-08 H.J. Lu <hongjiu.lu@intel.com>
13528
13529 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
13530 (i386-mmx.o): New.
13531 (i386-mmx.c): Likewise.
13532 (i386-mmx-linux.o): Likewise.
13533 (i386-mmx-linux.c): Likewise.
13534
13535 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
13536 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
13537 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
13538 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
13539
13540 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
13541 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
13542 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
13543
1570b33e
L
135442010-04-07 H.J. Lu <hongjiu.lu@intel.com>
13545
13546 * Makefile.in (clean): Updated.
13547 (i386-avx.o): New.
13548 (i386-avx.c): Likewise.
13549 (i386-avx-linux.o): Likewise.
13550 (i386-avx-linux.c): Likewise.
13551 (amd64-avx.o): Likewise.
13552 (amd64-avx.c): Likewise.
13553 (amd64-avx-linux.o): Likewise.
13554 (amd64-avx-linux.c): Likewise.
13555
13556 * configure.srv (srv_i386_regobj): Add i386-avx.o.
13557 (srv_i386_linux_regobj): Add i386-avx-linux.o.
13558 (srv_amd64_regobj): Add amd64-avx.o.
13559 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
13560 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
13561 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
13562 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
13563 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
13564 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
13565 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
13566
13567 * i387-fp.c: Include "i386-xstate.h".
13568 (i387_xsave): New.
13569 (i387_cache_to_xsave): Likewise.
13570 (i387_xsave_to_cache): Likewise.
13571 (x86_xcr0): Likewise.
13572
13573 * i387-fp.h (i387_cache_to_xsave): Likewise.
13574 (i387_xsave_to_cache): Likewise.
13575 (x86_xcr0): Likewise.
13576
13577 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
13578 * linux-crisv32-low.c (target_regsets): Likewise.
13579 * linux-m68k-low.c (target_regsets): Likewise.
13580 * linux-mips-low.c (target_regsets): Likewise.
13581 * linux-ppc-low.c (target_regsets): Likewise.
13582 * linux-s390-low.c (target_regsets): Likewise.
13583 * linux-sh-low.c (target_regsets): Likewise.
13584 * linux-sparc-low.c (target_regsets): Likewise.
13585 * linux-xtensa-low.c (target_regsets): Likewise.
13586
13587 * linux-low.c: Include <sys/uio.h>.
13588 (regsets_fetch_inferior_registers): Support nt_type.
13589 (regsets_store_inferior_registers): Likewise.
13590 (linux_process_qsupported): New.
13591 (linux_target_ops): Add linux_process_qsupported.
13592
13593 * linux-low.h (regset_info): Add nt_type.
13594 (linux_target_ops): Add process_qsupported.
13595
13596 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
13597 and <sys/uio.h>.
13598 (init_registers_i386_avx_linux): New.
13599 (init_registers_amd64_avx_linux): Likewise.
13600 (xmltarget_i386_linux_no_xml): Likewise.
13601 (xmltarget_amd64_linux_no_xml): Likewise.
13602 (PTRACE_GETREGSET): Likewise.
13603 (PTRACE_SETREGSET): Likewise.
13604 (x86_fill_xstateregset): Likewise.
13605 (x86_store_xstateregset): Likewise.
13606 (use_xml): Likewise.
13607 (x86_linux_update_xmltarget): Likewise.
13608 (x86_linux_process_qsupported): Likewise.
13609 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
13610 (x86_arch_setup): Don't call init_registers_amd64_linux nor
13611 init_registers_i386_linux here. Call
13612 x86_linux_update_xmltarget.
13613 (the_low_target): Add x86_linux_process_qsupported.
13614
13615 * server.c (handle_query): Call target_process_qsupported.
13616
13617 * target.h (target_ops): Add process_qsupported.
13618 (target_process_qsupported): New.
13619
fc7238bb
PA
136202010-04-03 Pedro Alves <pedro@codesourcery.com>
13621
13622 * inferiors.c (add_thread): Set last_status kind to
13623 TARGET_WAITKIND_IGNORE.
13624 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
13625 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
13626 (linux_wait_1): Move `thread' local definition to block that uses
13627 it. Don't NULL initialize `event_child'.
13628 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
13629 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
13630 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
13631
bdabb078
PA
136322010-04-01 Pedro Alves <pedro@codesourcery.com>
13633
13634 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
13635 an extended waitstatus, or by a watchpoint.
13636 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
13637 thread was stepping or has been stopped by a watchpoint.
13638
d3bbe7a0
PA
136392010-04-01 Pedro Alves <pedro@codesourcery.com>
13640
13641 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
13642 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
13643 of another, then delete the previous, and validate all
13644 breakpoints.
13645 (validate_inserted_breakpoint): New.
13646 (delete_disabled_breakpoints): New.
13647 (validate_breakpoints): New.
13648 (check_mem_read): Validate breakpoints before trusting their
13649 shadow. Delete disabled breakpoints.
13650 (check_mem_write): Validate breakpoints before trusting they
13651 should be inserted. Delete disabled breakpoints.
13652 * mem-break.h (validate_breakpoints):
13653 * server.c (handle_query): Validate breakpoints when we see a
13654 qSymbol query.
13655
8b07ae33
PA
136562010-04-01 Pedro Alves <pedro@codesourcery.com>
13657
13658 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
13659 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
13660 if we could tell there's a GDB breakpoint at stop_pc.
13661 (need_step_over_p): Don't do a step over if we find a GDB
13662 breakpoint at the resume PC.
13663
13664 * mem-break.c (struct raw_breakpoint): New.
13665 (enum bkpt_type): New type `gdb_breakpoint'.
13666 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
13667 fields. New field `raw'.
13668 (find_raw_breakpoint_at): New.
13669 (set_raw_breakpoint_at): Handle refcounting. Create a raw
13670 breakpoint instead.
13671 (set_breakpoint_at): Adjust.
13672 (delete_raw_breakpoint): New.
13673 (release_breakpoint): New.
13674 (delete_breakpoint): Rename to...
13675 (delete_breakpoint_1): ... this. Add proc parameter. Use
13676 release_breakpoint. Return ENOENT.
13677 (delete_breakpoint): Reimplement.
13678 (find_breakpoint_at): Delete.
13679 (find_gdb_breakpoint_at): New.
13680 (delete_breakpoint_at): Delete.
13681 (set_gdb_breakpoint_at): New.
13682 (delete_gdb_breakpoint_at): New.
13683 (gdb_breakpoint_here): New.
13684 (set_reinsert_breakpoint): Use release_breakpoint.
13685 (uninsert_breakpoint): Rename to ...
13686 (uninsert_raw_breakpoint): ... this.
13687 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
13688 (reinsert_raw_breakpoint): Change parameter type to
13689 raw_breakpoint.
13690 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
13691 instead.
13692 (check_breakpoints): Adjust. Use release_breakpoint.
13693 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
13694 (breakpoint_inserted_here): Ditto.
13695 (check_mem_read): Adjust to iterate over raw breakpoints instead.
13696 Don't trust the breakpoint's shadow if it is not inserted.
13697 (check_mem_write): Adjust to iterate over raw breakpoints instead.
13698 (delete_all_breakpoints): Adjust.
13699 (free_all_breakpoints): Mark all breakpoints as uninserted, and
13700 use delete_breakpoint_1.
13701
13702 * mem-break.h (breakpoints_supported): Delete declaration.
13703 (set_gdb_breakpoint_at): Declare.
13704 (gdb_breakpoint_here): Declare.
13705 (delete_breakpoint_at): Delete.
13706 (delete_gdb_breakpoint_at): Declare.
13707
13708 * server.h (struct raw_breakpoint): Forward declare.
13709 (struct process_info): New field `raw_breakpoints'.
13710
13711 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
13712 breakpoints.
13713
6bf5e0ba
PA
137142010-03-24 Pedro Alves <pedro@codesourcery.com>
13715
13716 * linux-low.c (status_pending_p_callback): Fix comment.
13717 (linux_wait_for_event_1): Move most of the internal breakpoint
13718 handling from here...
13719 (linux_wait_1): ... to here.
13720 (count_events_callback): New.
13721 (select_singlestep_lwp_callback): New.
13722 (select_event_lwp_callback): New.
13723 (cancel_breakpoints_callback): New.
13724 (select_event_lwp): New.
13725 (linux_wait_1): Simplify internal breakpoint handling. Give equal
13726 priority to all LWPs that have had events that should be reported
13727 to the client. Cancel breakpoints when about to reporting the
13728 event to the client, not while stopping lwps. No longer cancel
13729 finished single-steps here.
13730 (cancel_finished_single_step): Delete.
13731 (cancel_finished_single_steps): Delete.
13732
414a389f
PA
137332010-03-24 Pedro Alves <pedro@codesourcery.com>
13734
13735 * mem-break.c (enum bkpt_type): New.
13736 (struct breakpoint): New field `type'.
13737 (set_breakpoint_at): Change return type to struct breakpoint
13738 pointer. Set type to `other_breakpoint' by default.
13739 (delete_breakpoint): Rewrite, supporting more than one breakpoint
13740 in the breakpoint list.
13741 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
13742 (reinsert_breakpoint): Rename to ...
13743 (reinsert_raw_breakpoint): ... this.
13744 (reinsert_breakpoints_at): Adjust.
13745 * mem-break.h (struct breakpoint): Declare.
13746 (set_breakpoint_at): Change return type to struct breakpoint
13747 pointer.
13748
2280c721
PA
137492010-03-24 Pedro Alves <pedro@codesourcery.com>
13750
13751 * server.c (handle_query): Assign, not compare.
13752
d50171e4
PA
137532010-03-24 Pedro Alves <pedro@codesourcery.com>
13754
13755 Teach linux gdbserver to step-over-breakpoints.
13756
13757 * linux-low.c (can_hardware_single_step): New.
13758 (supports_breakpoints): New.
13759 (handle_extended_wait): If stopping threads, read the stop pc of
13760 the new cloned LWP.
13761 (get_pc): New.
13762 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
13763 low target doesn't support retrieving the PC.
13764 (add_lwp): Set last_resume_kind to resume_continue.
13765 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
13766 (linux_attach): Don't clear stop_expected. Set the lwp's
13767 last_resume_kind to resume_stop.
13768 (linux_detach_one_lwp): Don't check for removed breakpoints.
13769 (check_removed_breakpoint): Delete.
13770 (status_pending_p): Rename to ...
13771 (status_pending_p_callback): ... this. Don't check for removed
13772 breakpoints. Don't consider threads that are stopped from GDB's
13773 perspective.
13774 (linux_wait_for_lwp): Always read the stop_pc here.
13775 (cancel_breakpoint): New.
13776 (step_over_bkpt): New global.
13777 (linux_wait_for_event_1): Implement stepping over breakpoints.
13778 (gdb_wants_lwp_stopped): New.
13779 (gdb_wants_all_stopped): New.
13780 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
13781 single-step traps here. Store the thread's last reported target
13782 wait status.
13783 (send_sigstop): Don't clear stop_expected. Always set it,
13784 instead.
13785 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
13786 (cancel_finished_single_step): New.
13787 (cancel_finished_single_steps): New.
13788 (wait_for_sigstop): Don't cancel finished single-step traps here.
13789 (linux_resume_one_lwp): Don't check for removed breakpoints.
13790 Don't set `step' on non-hardware step archs.
13791 (linux_set_resume_request): Ignore resume_stop requests if already
13792 stopping or stopped. Set the lwp's last_resume_kind.
13793 (resume_status_pending_p): Don't check for removed breakpoints.
13794 (need_step_over_p): New.
13795 (start_step_over): New.
13796 (finish_step_over): New.
13797 (linux_resume_one_thread): Always queue a sigstop for resume_stop
13798 requests. Clear the thread's last reported target waitstatus.
13799 Don't use the `suspended' flag. Don't consider pending breakpoints.
13800 (linux_resume): Start a step-over if necessary.
13801 (proceed_one_lwp): New.
13802 (proceed_all_lwps): New.
13803 (unstop_all_lwps): New.
13804 * linux-low.h (struct lwp_info): Rewrite comment for the
13805 `suspended' flag. Add the `stop_pc' field. Delete the
13806 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
13807 Add `'last_resume_kind' and `need_step_over' fields.
13808 * inferiors.c (struct thread_info): Delete, moved elsewhere.
13809 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
13810 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
13811 (set_raw_breakpoint_at): New.
13812 (set_breakpoint_at): Rewrite to use it.
13813 (reinsert_breakpoint_handler): Delete.
13814 (set_reinsert_breakpoint): New.
13815 (reinsert_breakpoint_by_bp): Delete.
13816 (delete_reinsert_breakpoints): New.
13817 (uninsert_breakpoint): Rewrite.
13818 (uninsert_breakpoints_at): New.
13819 (reinsert_breakpoint): Rewrite.
13820 (reinsert_breakpoints_at): New.
13821 (check_breakpoints): Rewrite.
13822 (breakpoint_here): New.
13823 (breakpoint_inserted_here): New.
13824 (check_mem_read): Adjust.
13825 * mem-break.h (breakpoints_supported, breakpoint_here)
13826 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
13827 (reinsert_breakpoint_by_bp): Delete declaration.
13828 (delete_reinsert_breakpoints): Declare.
13829 (reinsert_breakpoint): Delete declaration.
13830 (reinsert_breakpoints_at): Declare.
13831 (uninsert_breakpoint): Delete declaration.
13832 (uninsert_breakpoints_at): Declare.
13833 (check_breakpoints): Adjust prototype.
13834 * server.h: Adjust include order.
13835 (struct thread_info): Declare here. Add a `last_status' field.
13836
30ba68cb
MS
138372010-03-23 Michael Snyder <msnyder@vmware.com>
13838
13839 * server.c (crc32): New function.
13840 (handle_query): Add handling for 'qCRC:' request.
13841
b9a881c2
PA
138422010-03-23 Pedro Alves <pedro@codesourcery.com>
13843
13844 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
13845 lwp had been stopped by a watchpoint.
13846
e92d13d5
PA
138472010-03-16 Pedro Alves <pedro@codesourcery.com>
13848
13849 * server.h (internal_error): Declare.
13850 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
13851 * utils.c (internal_error): New function.
13852
64daa791
AS
138532010-03-15 Andreas Schwab <schwab@redhat.com>
13854
13855 * configure.srv: Fix typo setting srv_regobj.
13856
f52cd8cd
PA
138572010-03-15 Pedro Alves <pedro@codesourcery.com>
13858
13859 * linux-low.c (fetch_register): Avoid passing a non string literal
13860 format to `error'.
13861 (usr_store_inferior_registers): Ditto.
13862
93ae6fdc
PA
138632010-03-14 Pedro Alves <pedro@codesourcery.com>
13864
13865 * linux-low.c (linux_write_memory): Bail out early if peeking
13866 memory failed.
13867
c3adc08c
PA
138682010-03-14 Pedro Alves <pedro@codesourcery.com>
13869
13870 * linux-low.h (struct lwp_info): New fields
13871 `stopped_by_watchpoint' and `stopped_data_address'.
13872 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
13873 here, and cache them in the lwp object.
13874 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
13875 directly.
13876 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
13877 field.
13878 (linux_stopped_by_watchpoint): Rewrite.
13879 (linux_stopped_data_address): Rewrite.
13880
bce522a2
PA
138812010-03-06 Simo Melenius <simo.melenius@iki.fi>
13882
13883 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
13884 switching the current inferior, not before.
13885
90884b2b
L
138862010-03-01 H.J. Lu <hongjiu.lu@intel.com>
13887
13888 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
13889 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
13890 i386-linux.c and amd64-linux.c.
13891 (reg-i386.o): Removed.
13892 (reg-i386.c): Likewise.
13893 (reg-i386-linux.o): Likewise.
13894 (reg-i386-linux.c): Likewise.
13895 (reg-x86-64.o): Likewise.
13896 (reg-x86-64.c): Likewise.
13897 (reg-x86-64-linux.o): Likewise.
13898 (reg-x86-64-linux.c): Likewise.
13899 (i386.o): New.
13900 (i386.c): Likewise.
13901 (i386-linux.o): Likewise.
13902 (i386-linux.c): Likewise.
13903 (amd64.o): Likewise.
13904 (amd64.c): Likewise.
13905 (amd64-linux.o): Likewise.
13906 (amd64-linux.c): Likewise.
13907
13908 * configure.srv (srv_i386_regobj): New.
13909 (srv_i386_linux_regobj): Likewise.
13910 (srv_amd64_regobj): Likewise.
13911 (srv_amd64_linux_regobj): Likewise.
13912 (srv_i386_32bit_xmlfiles): Likewise.
13913 (srv_i386_64bit_xmlfiles): Likewise.
13914 (srv_i386_xmlfiles): Likewise.
13915 (srv_amd64_xmlfiles): Likewise.
13916 (srv_i386_linux_xmlfiles): Likewise.
13917 (srv_amd64_linux_xmlfiles): Likewise.
13918 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
13919 srv_xmlfiles to $srv_i386_xmlfiles.
13920 (i[34567]86-*-mingw32ce*): Likewise.
13921 (i[34567]86-*-mingw*): Likewise.
13922 (i[34567]86-*-nto*): Likewise.
13923 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
13924 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
13925 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
13926 (x86_64-*-linux*): Likewise.
13927
13928 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
13929 (init_registers_amd64_linux): New.
13930 (x86_arch_setup): Replace init_registers_x86_64_linux with
13931 init_registers_amd64_linux.
13932
193f13e6
MK
139332010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
13934
13935 * configure.ac: Check for libdl. If it is not available link against
13936 static libthread_db.
13937 * configure: Regenerate.
13938
85d721b8
PA
139392010-02-22 Pedro Alves <pedro@codesourcery.com>
13940
13941 PR9605
13942
13943 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
13944 handing a read watchpoint.
13945 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
13946
6076632b
DE
139472010-02-12 Doug Evans <dje@google.com>
13948
13949 * linux-low.c (linux_supports_tracefork_flag): Document.
13950 (linux_look_up_symbols): Add comment.
13951
3327ccf7
L
139522010-02-03 H.J. Lu <hongjiu.lu@intel.com>
13953
13954 * regcache.c (supply_register): Clear regcache if buf is NULL.
13955
0718675c 139562010-02-02 Nicolas Roche <roche@sourceware.org>
3327ccf7 13957 Joel Brobecker <brobecker@adacore.com>
0718675c
JB
13958
13959 * inferiors.c (find_inferior): Add function documentation.
13960 (unloaded_dll): Handle the case where the unloaded dll has not
13961 been previously registered in the dll list.
13962
177321bd
DJ
139632010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
13964
13965 * linux-arm-low.c (thumb_breakpoint_len): Delete.
13966 (thumb2_breakpoint): New.
13967 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
13968
2b009048
DJ
139692010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
13970
13971 * linux-low.c (get_stop_pc): Check for SIGTRAP.
13972 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
13973 breakpoints.
13974
3be029c7
PA
139752010-01-21 Pedro Alves <pedro@codesourcery.com>
13976
13977 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
13978
18f5de3b
JK
139792010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13980
13981 * linux-s390-low.c (s390_collect_ptrace_register)
13982 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
13983
3743bb4f
DE
139842010-01-21 Doug Evans <dje@google.com>
13985
14ce3065
DE
13986 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
13987 (PTRACE_ARG4_TYPE): New macro.
13988 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
13989 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
13990 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
13991 (usr_store_inferior_registers): Ditto.
13992 (linux_read_memory, linux_write_memory): Ditto.
13993 (linux_test_for_tracefork): Ditto.
13994
3743bb4f
DE
13995 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
13996 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
13997
8b315be5
PA
139982010-01-21 Pedro Alves <pedro@codesourcery.com>
13999
14000 * proc-service.c (ps_lgetregs): Don't refetch registers from the
14001 target.
14002
85492558
PA
140032010-01-21 Pedro Alves <pedro@codesourcery.com>
14004
14005 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
14006 prototype to take a regcache. Adjust.
14007
442ea881
PA
140082010-01-20 Pedro Alves <pedro@codesourcery.com>
14009
14010 * regcache.h (struct thread_info): Forward declare.
14011 (struct regcache): New.
14012 (new_register_cache): Adjust prototype.
14013 (get_thread_regcache): Declare.
14014 (free_register_cache): Adjust prototype.
14015 (registers_to_string, registers_from_string): Ditto.
14016 (supply_register, supply_register_by_name, collect_register)
14017 (collect_register_as_string, collect_register_by_name): Ditto.
14018 * regcache.c (struct inferior_regcache_data): Delete.
14019 (get_regcache): Rename to ...
14020 (get_thread_regcache): ... this. Adjust. Switch inferior before
14021 fetching registers.
14022 (regcache_invalidate_one): Adjust.
14023 (regcache_invalidate): Fix prototype.
14024 (new_register_cache): Return the new register cache.
14025 (free_register_cache): Change prototype.
14026 (realloc_register_cache): Adjust.
14027 (registers_to_string): Change prototype to take a regcache. Adjust.
14028 (registers_from_string): Ditto.
14029 (register_data): Ditto.
14030 (supply_register): Ditto.
14031 (supply_register_by_name): Ditto.
14032 (collect_register): Ditto.
14033 (collect_register_as_string): Ditto.
14034 (collect_register_by_name): Ditto.
14035 * server.c (process_serial_event): Adjust.
14036 * linux-low.h (regset_fill_func, regset_store_func): Change
14037 prototype.
14038 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
14039 Change prototype.
14040 * linux-low.c (get_stop_pc): Adjust.
14041 (check_removed_breakpoint): Adjust.
14042 (linux_wait_for_event): Adjust.
14043 (linux_resume_one_lwp): Adjust.
14044 (fetch_register): Add regcache parameter. Adjust.
14045 (usr_store_inferior_registers): Ditto.
14046 (regsets_fetch_inferior_registers): Ditto.
14047 (regsets_store_inferior_registers): Ditto.
14048 (linux_fetch_registers, linux_store_registers): Ditto.
14049 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
14050 regcache. Adjust.
43aaf8b6
PA
14051 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
14052 Ditto.
442ea881
PA
14053 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
14054 prototype to take a regcache.
14055 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
14056 * remote-utils.c (convert_ascii_to_int, outreg)
14057 (prepare_resume_reply): Change prototype to take a regcache.
14058 Adjust.
14059 * target.h (struct target_ops) <fetch_registers, store_registers>:
14060 Change prototype to take a regcache.
14061 (fetch_inferior_registers, store_inferior_registers): Change
14062 prototype to take a regcache. Adjust.
14063 * proc-service.c (ps_lgetregs): Adjust.
14064 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
14065 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
14066 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
14067 take a regcache. Adjust.
14068 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
14069 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
14070 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
14071 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
14072 * linux-cris-low.c (cris_get_pc, cris_set_pc)
14073 (cris_cannot_fetch_register):
14074 (cris_breakpoint_at): Change prototype to take a regcache.
14075 Adjust.
14076 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
14077 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
14078 to take a regcache. Adjust.
14079 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
14080 Adjust.
14081 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
14082 take a regcache. Adjust.
14083 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
14084 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
14085 (m68k_set_pc): Change prototype to take a regcache. Adjust.
14086 * linux-mips-low.c (mips_get_pc):
14087 (mips_set_pc): Change prototype to take a regcache. Adjust.
14088 (mips_reinsert_addr): Adjust.
14089 (mips_collect_register): Change prototype to take a regcache.
14090 Adjust.
14091 (mips_supply_register):
14092 (mips_collect_register_32bit, mips_supply_register_32bit)
14093 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
14094 (mips_store_fpregset): Ditto.
43aaf8b6
PA
14095 * linux-ppc-low.c (ppc_supply_ptrace_register)
14096 (ppc_supply_ptrace_register): Ditto.
442ea881
PA
14097 (parse_spufs_run): Adjust.
14098 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
14099 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
14100 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
14101 take a regcache. Adjust.
14102 * linux-s390-low.c (s390_collect_ptrace_register)
14103 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
14104 (s390_set_pc): Change prototype to take a regcache. Adjust.
14105 (s390_arch_setup): Adjust.
14106 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
14107 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
14108 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
14109 (sparc_fill_gregset, sparc_store_gregset_from_stack)
14110 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
14111 regcache. Adjust.
14112 (sparc_breakpoint_at): Adjust.
14113 * linux-xtensa-low.c (xtensa_fill_gregset):
14114 (xtensa_store_gregset):
14115 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
14116 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
14117 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
14118 prototype to take a regcache. Adjust.
14119 * win32-arm-low.c (arm_fetch_inferior_register)
14120 (arm_store_inferior_register): Change prototype to take a
14121 regcache. Adjust.
14122 * win32-i386-low.c (i386_fetch_inferior_register)
14123 (i386_store_inferior_register): Change prototype to take a
14124 regcache. Adjust.
14125 * win32-low.c (child_fetch_inferior_registers)
14126 (child_store_inferior_registers): Change prototype to take a
14127 regcache. Adjust.
14128 (win32_wait): Adjust.
14129 (win32_fetch_inferior_registers): Change prototype to take a
14130 regcache. Adjust.
14131 (win32_store_inferior_registers): Adjust.
14132 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
14133 store_inferior_register>: Change prototype to take a regcache.
14134
60c3d7b0
DE
141352010-01-20 Doug Evans <dje@google.com>
14136
14137 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
14138 #ifdef.
14139 (linux_wait_for_event1, linux_init_signals): Ditto.
ec8ebe72 14140 (W_STOPCODE): Provide definition if missing.
60c3d7b0 14141
dc146f7c
VP
141422010-01-13 Vladimir Prus <vladimir@codesourcery.com>
14143
14144 * linux-low.c (linux_core_of_thread): New.
14145 (compare_ints, show_process, list_threads): New.
14146 (linux_qxfer_osdata): Report threads and cores.
14147 (linux_target_op): Register linux_core_of_thread.
14148 * remote-utils.c (prepare_resume_reply): Report the core.
14149 (buffer_xml_printf): Support %d specifier.
14150 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
14151 New.
14152 (handle_query): Handle qXfer:threads. Announce availability
14153 thereof.
14154 * target.h (struct target_ops): New field core_of_thread.
14155
7803799a
UW
141562010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
14157
14158 * Makefile.in (clean): Remove new generated files.
14159 (reg-s390.o, reg-s390.c): Remove rules.
14160 (reg-s390x.o, reg-s390x.c): Likewise.
14161 (s390-linux32.o, s390-linux32.c): Add rules.
14162 (s390-linux64.o, s390-linux64.c): Likewise.
14163 (s390x-linux64.o, s390x-linux64.c): Likewise.
14164 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
14165 * linux-s390-low.c: Include <elf.h>.
14166 (HWCAP_S390_HIGH_GPRS): Define if undefined.
14167 (init_registers_s390): Remove prototype.
14168 (init_registers_s390x): Likewise.
14169 (init_registers_s390_linux32): Add prototype.
14170 (init_registers_s390_linux64): Likewise.
14171 (init_registers_s390x_linux64): Likewise.
14172 (s390_num_regs_3264): New define.
14173 (s390_regmap_3264): New global variable.
14174 (s390_cannot_fetch_register): Remove obsolete check.
14175 (s390_cannot_store_register): Likewise.
14176 (s390_collect_ptrace_register): Handle upper/lower register halves.
14177 (s390_supply_ptrace_register): Likewise.
14178 (s390_fill_gregset): Update to register number changes.
14179 (s390_get_hwcap): New routine.
14180 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
14181 Install appropriate regmap and register set.
14182
6e7ffa39
JB
141832010-01-01 Joel Brobecker <brobecker@adacore.com>
14184
14185 * server.c (gdbserver_version): Update copyright year to 2010.
14186 * gdbreplay.c (gdbreplay_version): Likewise.
14187
957f3f49
DE
141882009-12-28 Doug Evans <dje@google.com>
14189
14190 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
14191 elf/external.h. Include <elf.h> instead but only if necessary.
14192
ca5c370d
PA
141932009-12-28 Pedro Alves <pedro@codesourcery.com>
14194
14195 * linux-low.c (linux_remove_process): Remove `detaching'
14196 parameter. Don't release/detach from thread_db here.
14197 (linux_kill): Release/detach from thread_db here, ...
14198 (linux_detach): ... and here, before actually detaching.
14199 (linux_wait_1): ... and here, when a process exits.
14200 * thread-db.c (any_thread_of): New.
14201 (thread_db_free): Switch the current inferior to a thread of the
14202 passed in process.
14203
4ee62156
DE
142042009-12-21 Doug Evans <dje@google.com>
14205
d90e6a88
DE
14206 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
14207
c5f62d5f
DE
14208 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
14209 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
14210 warning ifndef __NR_tkill. Move setting of errno there too.
14211 Delete unnecessary resetting of errno after syscall.
14212 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
14213
10e86dd7
DE
14214 * configure.ac: Check for dladdr.
14215 * config.in: Regenerate.
14216 * configure: Regenerate.
14217 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
14218 (try_thread_db_load): Update.
14219
4ee62156
DE
14220 * linux-low.c (my_waitpid): Delete unnecessary prototype.
14221
00f515da
DE
142222009-12-18 Doug Evans <dje@google.com>
14223
e9464885
DE
14224 * event-loop.c: Include unistd.h if it exists.
14225
07d4f67e
DE
14226 * linux-low.c (my_waitpid): Move definition away from being in
14227 between linux_tracefork_child/linux_test_for_tracefork.
14228
00f515da
DE
14229 * gdb_proc_service.h (psaddr_t): Fix type.
14230 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
14231 signature to match glibc.
14232
1de1badb
DE
142332009-12-16 Doug Evans <dje@google.com>
14234
14235 * linux-low.c (linux_read_memory): Fix argument to read.
14236
aeeb81d1
PA
142372009-11-26 Pedro Alves <pedro@codesourcery.com>
14238
14239 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
14240 events, don't leave current_inferior pointing at null.
14241
10357975
PA
142422009-11-26 Pedro Alves <pedro@codesourcery.com>
14243
14244 * win32-low.c (LOG): Delete.
14245 (OUTMSG): Output to stderr.
14246 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
14247 on compile time LOG macro.
14248 (win32_wait): Fix debug output.
14249
cf6e3471
PA
142502009-11-26 Pedro Alves <pedro@codesourcery.com>
14251
14252 * win32-low.c (win32_add_one_solib): If the dll name is
14253 "ntdll.dll", prepend the system directory to the dll path.
14254
0c85e18e
MK
142552009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
14256
14257 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
14258
9ac544ce 142592009-11-17 Nathan Sidwell <nathan@codesourcery.com>
889bf7c5 14260 Vladimir Prus <vladimir@codesourcery.com>
9ac544ce
MK
14261
14262 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
14263 * configure.ac: Check for __mcoldfire__ and set
14264 gdb_cv_m68k_is_coldfire.
14265 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
14266 reg-cf.o and reg-m68k.o.
14267 * configure: Regenerated.
14268
fd7dd3e6
PA
142692009-11-16 Pedro Alves <pedro@codesourcery.com>
14270
14271 * linux-low.c (linux_remove_process): Add `detaching' parameter.
14272 Pass it to thread_db_free.
14273 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
14274 proper `detaching' argument to linux_remove_process.
14275 * linux-low.h (thread_db_free): Add `detaching' parameter.
14276 * thread-db.c (thread_db_init): Pass false as `detaching' argument
14277 to thread_db_free.
14278 (thread_db_free): Add `detaching' parameter. Only
14279 call td_ta_clear_event if detaching from process.
14280
75aa492e
MK
142812009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
14282
14283 * thread-db.c (thread_db_free): Fix typo.
14284
21e1bee4
PP
142852009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
14286
14287 PR gdb/10838
14288 * thread-db.c (thread_db_free): Call td_ta_clear_event.
14289
8838b45e
NS
142902009-11-03 Nathan Sidwell <nathan@codesourcery.com>
14291
14292 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
14293 with an i686 compiler.
14294 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
14295 needed.
14296 * configure: Rebuilt.
14297
8a35fb51
SL
142982009-10-29 Sandra Loosemore <sandra@codesourcery.com>
14299
14300 PR gdb/10783
14301
14302 * server.c (handle_search_memory_1): Correct read_addr initialization
14303 in loop for searching subsequent chunks.
14304
96f15937
PP
143052009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
14306
14307 * configure.ac: New --with-libthread-db option.
14308 * thread-db.c: Allow direct dependence on libthread_db.
14309 (thread_db_free): Adjust.
14310 * config.in: Regenerate.
14311 * configure: Likewise.
889bf7c5 14312
5f7d1694
PP
143132009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
14314
14315 PR gdb/10757
14316 * thread-db.c (attach_thread): New function.
14317 (maybe_attach_thread): Return success/failure.
14318 (find_new_threads_callback): Adjust.
889bf7c5
PA
14319 (thread_db_find_new_threads): Loop until no new threads.
14320
88e3b899
PA
143212009-10-13 Pedro Alves <pedro@codesourcery.com>
14322
14323 * proc-service.c (ps_lgetregs): Formatting.
14324
cdbfd419
PP
143252009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
14326
14327 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
14328 * configure.ac: Adjust.
14329 * linux-low.h (struct process_info_private): Move members to struct
14330 thread_db.
14331 (thread_db_free, thread_db_handle_monitor_command): New prototype.
14332 * linux-low.c (linux_remove_process): Adjust.
14333 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
14334 * server.c (handle_query): Move code ...
14335 (handle_monitor_command): ... here. New function.
14336 * target.h (struct target_ops): New member.
14337 * thread-db.c (struct thread_db): New.
14338 (libthread_db_search_path): New variable.
14339 (thread_db_create_event, thread_db_enable_reporting)
14340 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
14341 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
14342 (try_thread_db_load_1, dladdr_to_soname): New functions.
14343 (try_thread_db_load, thread_db_load_search): New functions.
14344 (thread_db_init): Search for libthread_db.
14345 (thread_db_free): New function.
14346 (thread_db_handle_monitor_command): Likewise.
14347 * config.in: Regenerate.
14348 * configure: Regenerate.
889bf7c5 14349
4168d2d6
UW
143502009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
14351
14352 * spu-low.c (spu_kill): Wait for inferior to terminate.
14353 Call clear_inferiors.
14354 (spu_detach): Call clear_inferiors.
14355
81ecdfbb
RW
143562009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
14357
14358 * aclocal.m4: Regenerate.
14359 * config.in: Likewise.
14360 * configure: Likewise.
14361
0b9ff2c0
UW
143622009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14363
14364 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
14365 (parse_spufs_run): New function.
14366 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
14367 (ppc_breakpoint_at): Handle SPU breakpoints.
14368
efcbbd14
UW
143692009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14370
14371 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
14372 (SPUFS_MAGIC): Define.
14373 (spu_enumerate_spu_ids): New function.
14374 (linux_qxfer_spu): New function.
14375 (linux_target_ops): Install linux_qxfer_spu.
14376
f4d9bade
UW
143772009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14378
14379 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
14380 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
14381 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
14382 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
14383 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
14384 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
14385 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
14386 (init_registers_powerpc_cell32l): Add prototype.
14387 (init_registers_powerpc_cell64l): Likewise.
14388 (ppc_arch_setup): Detect Cell/B.E. architecture.
14389
96e946ca
RW
143902009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
14391
14392 * Makefile.in (datarootdir): New variable.
14393
58d6951d
DJ
143942009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
14395
14396 * linux-low.c (linux_write_memory): Update debugging output.
14397 * Makefile.in (clean): Add new descriptions.
14398 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
14399 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
14400 * configure.srv: Add new files for arm*-*-linux*.
14401 * linux-arm-low.c: Add new declarations.
14402 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
14403 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
14404 (HWCAP_VFPv3D16): New.
14405 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
14406 instead of __IWMMXT__.
14407 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
14408 (arm_arch_setup): New.
14409 (target_regsets): Remove #ifdef. Add VFP regset.
14410 (the_low_target): Use arm_arch_setup.
14411
12b42a12
DJ
144122009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
14413
14414 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
14415 the main thread again.
14416
ac8c974e
AR
144172009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
14418
14419 Adding Neutrino gdbserver.
14420 * configure: Regenerated.
14421 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
14422 * configure.srv (i[34567]86-*-nto*): New target.
14423 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
14424 * remote-utils.c [__QNX__]: Include sys/iomgr.h
14425 (nto_comctrl) [__QNX__]: New function.
14426 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
14427
4424e0c3 144282009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
7437790a
PA
14429
14430 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
14431 srv_tgtobj.
14432
912cf4ba
PA
144332009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
14434 Pedro Alves <pedro@codesourcery.com>
14435
14436 * win32-i386-low.c (i386_get_thread_context): Handle systems that
14437 don't support CONTEXT_EXTENDED_REGISTERS.
14438 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
14439 (the_low_target): Install them.
14440 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
14441 failing with ERROR_PIPE_NOT_CONNECTED.
14442
aa5ca48f
DE
144432009-06-30 Doug Evans <dje@google.com>
14444 Pierre Muller <muller@ics.u-strasbg.fr>
14445
14446 Add h/w watchpoint support to x86-linux, win32-i386.
14447 * Makefile.in (SFILES): Add i386-low.c
14448 (i386_low_h): Define.
14449 (i386-low.o): Add dependencies.
14450 (linux-x86-low.o): Add i386-low.h dependency.
14451 (win32-i386-low.o): Ditto.
14452 * i386-low.c: New file.
14453 * i386-low.h: New file.
14454 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
14455 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
14456 * linux-low.c (linux_add_process): Initialize arch_private.
14457 (linux_remove_process): Free arch_private.
14458 (add_lwp): Initialize arch_private.
14459 (delete_lwp): Free arch_private.
14460 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
14461 provided.
14462 * linux-low.h (process_info_private): New member arch_private.
14463 (lwp_info): New member arch_private.
14464 (linux_target_ops): New members new_process, new_thread,
14465 prepare_to_resume.
14466 (ptid_of): New macro.
14467 * linux-x86-low.c: Include stddef.h, i386-low.h.
14468 (arch_process_info): New struct.
14469 (arch_lwp_info): New struct.
14470 (x86_linux_dr_get, x86_linux_dr_set): New functions.
14471 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
14472 (i386_dr_low_get_status): New function.
14473 (x86_insert_point, x86_remove_point): New functions.
14474 (x86_stopped_by_watchpoint): New function.
14475 (x86_stopped_data_address): New function.
14476 (x86_linux_new_process, x86_linux_new_thread): New functions.
14477 (x86_linux_prepare_to_resume): New function.
14478 (the_low_target): Add entries for insert_point, remove_point,
14479 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
14480 prepare_to_resume.
14481 * server.c (debug_hw_points): New global.
14482 (monitor_show_help): Document set debug-hw-points.
14483 (handle_query): Process "set debug-hw-points".
14484 * server.h (debug_hw_points): Declare.
14485 (paddress): Declare.
14486 * utils.c (NUMCELLS, CELLSIZE): New macros.
14487 (get_sell, xsnprintf, paddress): New functions.
14488 * win32-arm-low.c (the_low_target): Add entries for insert_point,
14489 remove_point, stopped_by_watchpoint, stopped_data_address.
14490 * win32-i386-low.c: Include i386-low.h.
14491 (debug_reg_state): Replaces dr.
14492 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
14493 (i386_dr_low_get_status): New function.
14494 (i386_insert_point, i386_remove_point): New functions.
14495 (i386_stopped_by_watchpoint): New function.
14496 (i386_stopped_data_address): New function.
14497 (i386_initial_stuff): Update.
14498 (get_thread_context,set_thread_context,i386_thread_added): Update.
14499 (the_low_target): Add entries for insert_point,
14500 remove_point, stopped_by_watchpoint, stopped_data_address.
14501 * win32-low.c (win32_insert_watchpoint): New function.
14502 (win32_remove_watchpoint): New function.
14503 (win32_stopped_by_watchpoint): New function.
14504 (win32_stopped_data_address): New function.
14505 (win32_target_ops): Add entries for insert_watchpoint,
14506 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
14507 * win32-low.h (win32_target_ops): New members insert_point,
14508 remove_point, stopped_by_watchpoint, stopped_data_address.
14509
d993e290
PA
145102009-06-25 Pedro Alves <pedro@codesourcery.com>
14511
14512 * server.c (process_serial_event): Re-return unsupported, not
14513 error, if the type isn't recognized. Re-allow supporting only
14514 insert or remove packets. Also call require_running for
14515 breakpoints. Add missing break statement to default case. Tidy.
14516 * target.h (struct target_ops): Rename insert_watchpoint to
14517 insert_point, and remove_watchpoint to remove_point.
14518
14519 * linux-low.h (struct linux_target_ops): Likewise.
14520 * linux-low.c (linux_insert_watchpoint): Rename to ...
14521 (linux_insert_point): ... this. Adjust.
14522 (linux_remove_watchpoint): Rename to ...
14523 (linux_remove_point): ... this. Adjust.
14524 (linux_target_ops): Adjust.
14525 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
14526 (cris_insert_point): ... this.
14527 (cris_remove_watchpoint): Rename to ...
14528 (cris_remove_point): ... this.
14529 (the_low_target): Adjust.
14530
0f54c268
PM
145312009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
14532
14533 * server.c (handle_v_kill): Pass signal_pid to
14534 kill_inferior if multi_process is zero.
14535
c6314022
AR
145362009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
14537
14538 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
14539 * target.h (target_ops): Comment for *_watchpoint to make it clear
14540 the functions can get types '0' and '1'.
14541
4463ce24
AR
145422009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
14543
14544 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
14545 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
14546 * regcache.c (get_regcache): Likewise.
14547 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
14548 * win32-low.c (child_fetch_inferior_registers): Remove check for
14549 regno 0.
14550
cf8fd78b
PA
145512009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
14552 Pedro Alves <pedro@codesourcery.com>
14553
14554 * target.h (struct target_ops) <supports_multi_process>: New
14555 callback.
14556 (target_supports_multi_process): New.
14557 * server.c (handle_query): Even if GDB reports support, only
14558 enable multi-process if the target also supports it. Report
14559 multi-process support only if the target backend supports it.
14560 * linux-low.c (linux_supports_multi_process): New function.
14561 (linux_target_ops): Install it as target_supports_multi_process
14562 callback.
14563
47c0c975
DE
145642009-05-24 Doug Evans <dje@google.com>
14565
e09875d4
DE
14566 Global renaming of find_thread_pid to find_thread_ptid.
14567 * server.h (find_thread_ptid): Renamed from find_thread_pid.
14568 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
14569 All callers updated.
14570
e27d73f6
DE
14571 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
14572 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
14573 directly.
14574
47c0c975
DE
14575 * linux-low.c (get_stop_pc): Print pc if debug_threads.
14576 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
14577 (linux_resume_one_lwp): Ditto.
14578
2acc282a
DE
145792009-05-23 Doug Evans <dje@google.com>
14580
14581 * linux-low.c (linux_resume_one_lwp): Change type of first arg
14582 from struct inferior_list_entry * to struct lwp_info *.
14583 All callers updated.
14584
9f1036c1
DE
145852009-05-13 Doug Evans <dje@google.com>
14586
14587 * linux-x86-low.c: Don't include assert.h.
14588 (x86_siginfo_fixup): Use fatal, not assert.
14589 (x86_arch_setup): Fix comment.
14590
d0722149
DE
145912009-05-12 Doug Evans <dje@google.com>
14592
14593 Biarch support for i386/amd64 gdbserver.
14594 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
14595 Add linux-x86-low.c.
14596 (linux-i386-low.o, linux-x86-64-low.o): Delete.
14597 (linux-x86-low.o): Add.
14598 * linux-x86-64-low.c: Delete.
14599 * linux-i386-low.c: Delete.
14600 * linux-x86-low.c: New file.
14601 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
14602 linux-x86-low.o.
14603 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
14604 linux-x86-low.o.
14605 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
14606 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
14607 (linux_child_pid_to_exec_file): New function.
14608 (elf_64_header_p, elf_64_file_p): New functions.
14609 (siginfo_fixup): New function.
14610 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
14611 give target a chance to convert layout.
14612 * linux-low.h (linux_target_ops): New member siginfo_fixup.
14613 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
14614
fdeb2a12
DE
146152009-05-07 Doug Evans <dje@google.com>
14616
14617 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
14618 (regsets_store_inferior_registers): Ditto.
14619
a6dbe5df
PA
146202009-05-06 Pedro Alves <pedro@codesourcery.com>
14621
14622 PR server/10048
14623
14624 * linux-low.c (must_set_ptrace_flags): Delete.
14625 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
14626 of the global.
14627 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
14628 `lwp->must_set_ptrace_flags' instead.
ba42693b 14629 (linux_wait_for_event_1): Set ptrace options here.
a6dbe5df
PA
14630 (linux_wait_1): ... not here.
14631
5091eb23
DE
146322009-04-30 Doug Evans <dje@google.com>
14633
9f767825
DE
14634 * inferiors.c (started_inferior_callback): New function.
14635 (attached_inferior_callback): New function.
14636 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
14637 * server.c (print_started_pid, print_attached_pid): New functions.
14638 (detach_or_kill_for_exit): New function.
14639 (main): Call it instead of for_each_inferior (kill_inferior_callback).
14640 * server.h (have_started_inferiors_p): Declare.
14641 (have_attached_inferiors_p): Declare.
14642
5091eb23
DE
14643 * inferiors.c (remove_process): Fix memory leak, free process.
14644 * linux-low.c (linux_remove_process): New function.
14645 (linux_kill): Call it instead of remove_process.
14646 (linux_detach, linux_wait_1): Ditto.
14647
155c8968
PA
146482009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
14649
14650 * configure.srv: Add x86 Windows CE target.
14651
7fe519cb
UW
146522009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
14653
14654 * inferiors.c (get_thread_process): Make global.
14655 * server.h (get_thread_process): Add prototype.
14656 * thread-db.c (find_one_thread): Use get_thread_process
14657 instead of current_process.
14658 (thread_db_get_tls_address): Do not crash if called when
14659 thread layer is not yet initialized.
14660
5472f405
UW
146612009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
14662
14663 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
14664 * spu-low.c (current_tid): Rename to ...
14665 (current_ptid): ... this.
14666 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
14667 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
14668 ptid_get_lwp (current_ptid) instead of current_tid.
14669 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
14670 instead of current_tid. Use find_process_pid to verify pid
14671 argument is valid. Pass proper argument to remove_process.
14672 (spu_thread_alive): Compare current_ptid instead of current_tid.
14673 (spu_resume): Likewise.
14674
55ac2b99
PA
146752009-04-02 Pedro Alves <pedro@codesourcery.com>
14676
14677 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
14678 variable.
14679
95954743
PA
146802009-04-01 Pedro Alves <pedro@codesourcery.com>
14681
14682 Implement the multiprocess extensions, and add linux multiprocess
14683 support.
14684
14685 * server.h (ULONGEST): Declare.
14686 (struct ptid, ptid_t): New.
14687 (minus_one_ptid, null_ptid): Declare.
14688 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
14689 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
14690 (struct inferior_list_entry): Change `id' type from unsigned from
14691 to ptid_t.
14692 (struct sym_cache, struct breakpoint, struct
14693 process_info_private): Forward declare.
14694 (struct process_info): Declare.
14695 (current_process): Declare.
14696 (all_processes): Declare.
14697 (initialize_inferiors): Declare.
14698 (add_thread): Adjust to use ptid_t.
14699 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
14700 (add_process, remove_process, find_thread_pid): Declare.
14701 (find_inferior_id): Adjust to use ptid_t.
14702 (cont_thread, general_thread, step_thread): Change type to ptid_t.
14703 (multi_process): Declare.
14704 (push_event): Adjust to use ptid_t.
14705 (read_ptid, write_ptid): Declare.
14706 (prepare_resume_reply): Adjust to use ptid_t.
14707 (clear_symbol_cache): Declare.
14708 * inferiors.c (all_processes): New.
14709 (null_ptid, minus_one_ptid): New.
14710 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
14711 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
14712 (add_thread): Change unsigned long to ptid. Remove gdb_id
14713 parameter. Adjust.
14714 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
14715 (gdb_id_to_thread): Rename to ...
14716 (find_thread_pid): ... this. Change unsigned long to ptid.
14717 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
14718 (loaded_dll, pull_pid_from_list): Adjust.
14719 (add_process, remove_process, find_process_pid)
14720 (get_thread_process, current_process, initialize_inferiors): New.
14721 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
14722 (struct target_waitstatus) <related_pid>: Ditto.
14723 (struct target_ops) <kill, detach>: Add `pid' argument. Change
14724 return type to int.
14725 (struct target_ops) <join>: Add `pid' argument.
14726 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
14727 (struct target_ops) <wait>: Add `ptid' field. Change return type
14728 to ptid.
14729 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
14730 (mywait): Add `ptid' argument. Change return type to ptid_t.
14731 (target_pid_to_str): Declare.
14732 * target.c (set_desired_inferior): Adjust to use ptids.
14733 (mywait): Add new `ptid' argument. Adjust.
14734 (target_pid_to_str): New.
14735 * mem-break.h (free_all_breakpoints): Declare.
14736 * mem-break.c (breakpoints): Delelete.
14737 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
14738 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
14739 to use per-process breakpoint list.
14740 (free_all_breakpoints): New.
14741 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
14742 (symbol_cache, all_symbols_looked_up): Delete.
14743 (hexchars): New.
14744 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
14745 read_ptid): New.
14746 (prepare_resume_reply): Change ptid argument's type from unsigned
14747 long to ptid_t. Adjust. Implement W;process and X;process.
14748 (free_sym_cache, clear_symbol_cache): New.
14749 (look_up_one_symbol): Adjust to per-process symbol cache. *
14750 * server.c (cont_thread, general_thread, step_thread): Change type
14751 to ptid_t.
14752 (attached): Delete.
14753 (multi_process): New.
14754 (last_ptid): Change type to ptid_t.
14755 (struct vstop_notif) <ptid>: Change type to ptid_t.
14756 (queue_stop_reply, push_event): Change `ptid' argument's type to
14757 ptid_t.
14758 (discard_queued_stop_replies): Add `pid' argument.
14759 (start_inferior): Adjust to use ptids. Adjust to mywait interface
14760 changes. Don't reference the `attached' global.
14761 (attach_inferior): Adjust to mywait interface changes.
14762 (handle_query): Adjust to use ptids. Parse GDB's qSupported
14763 features. Handle and report "multiprocess+". Handle
14764 "qAttached:PID".
14765 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
14766 changes.
14767 (handle_v_kill): New.
14768 (handle_v_stopped): Adjust to use target_pid_to_str.
14769 (handle_v_requests): Allow multiple attaches and runs when
14770 multiprocess extensions are in effect. Handle "vKill".
14771 (myresume): Adjust to use ptids.
14772 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
14773 (handle_status): Adjust to discard_queued_stop_replies interface
14774 change.
14775 (first_thread_of, kill_inferior_callback)
14776 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
14777 (main): Call initialize_inferiors. Adjust to use ptids, killing
14778 and detaching from all inferiors. Handle multiprocess packet
14779 variants.
14780 * linux-low.h: Include gdb_proc_service.h.
14781 (struct process_info_private): New.
14782 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
14783 <lwpid_of>: Use ptid_get_lwp.
14784 (get_lwp_thread): Adjust.
14785 (struct lwp_info): Add `dead' member.
14786 (find_lwp_pid): Declare.
14787 * linux-low.c (thread_db_active): Delete.
14788 (new_inferior): Adjust comment.
14789 (inferior_pid): Delete.
14790 (linux_add_process): New.
14791 (handle_extended_wait): Adjust.
14792 (add_lwp): Change unsigned long to ptid.
14793 (linux_create_inferior): Add process to processes table. Adjust
14794 to use ptids. Don't set new_inferior here.
14795 (linux_attach_lwp): Rename to ...
14796 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
14797 it. Adjust to use ptids.
14798 (linux_attach_lwp): New.
14799 (linux_attach): Add process to processes table. Don't set
14800 new_inferior here.
14801 (struct counter): New.
14802 (second_thread_of_pid_p, last_thread_of_process_p): New.
14803 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
14804 multiple processes.
14805 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
14806 processes. Remove process from process table.
14807 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
14808 to multiple processes.
14809 (any_thread_of): New.
14810 (linux_detach): Add `pid' argument, and handle it. Remove process
14811 from processes table.
14812 (linux_join): Add `pid' argument. Handle it.
14813 (linux_thread_alive): Change unsighed long argument to ptid_t.
14814 Consider dead lwps as not being alive.
14815 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
14816 threads we're not interested in.
14817 (same_lwp, find_lwp_pid): New.
14818 (linux_wait_for_lwp): Change `pid' argument's type from int to
14819 ptid_t. Adjust.
14820 (linux_wait_for_event): Rename to ...
14821 (linux_wait_for_event_1): ... this. Change `pid' argument's type
14822 from int to ptid_t. Adjust.
14823 (linux_wait_for_event): New.
14824 (linux_wait_1): Add `ptid' argument. Change return type to
14825 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
14826 that exit from the process table.
14827 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
14828 Adjust.
14829 (mark_lwp_dead): New.
14830 (wait_for_sigstop): Adjust to use ptids. If a process exits while
14831 stopping all threads, mark its main lwp as dead.
14832 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
14833 ptids.
14834 (fetch_register, usr_store_inferior_registers)
14835 (regsets_fetch_inferior_registers)
14836 (regsets_store_inferior_registers, linux_read_memory)
14837 (linux_write_memory): Inline `inferior_pid'.
14838 (linux_look_up_symbols): Adjust to use per-process
14839 `thread_db_active'.
14840 (linux_request_interrupt): Adjust to use ptids.
14841 (linux_read_auxv): Inline `inferior_pid'.
14842 (initialize_low): Don't reference thread_db_active.
14843 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
14844 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
14845 (ps_getpid): Return the pid of the current inferior.
14846 * thread-db.c (proc_handle, thread_agent): Delete.
14847 (thread_db_create_event, thread_db_enable_reporting): Adjust to
14848 per-process data.
14849 (find_one_thread): Change argument type to ptid_t. Adjust to
14850 per-process data.
14851 (maybe_attach_thread): Adjust to per-process data and ptids.
14852 (thread_db_find_new_threads): Ditto.
14853 (thread_db_init): Ditto.
14854 * spu-low.c (spu_create_inferior, spu_attach): Add process to
14855 processes table. Adjust to use ptids.
14856 (spu_kill, spu_detach): Adjust interface. Remove process from
14857 processes table.
14858 (spu_join, spu_thread_alive): Adjust interface.
14859 (spu_wait): Adjust interface. Remove process from processes
14860 table. Adjust to use ptids.
14861 * win32-low.c (current_inferior_tid): Delete.
14862 (current_inferior_ptid): New.
14863 (debug_event_ptid): New.
14864 (thread_rec): Take a ptid. Adjust.
14865 (child_add_thread): Add `pid' argument. Adjust to use ptids.
14866 (child_delete_thread): Ditto.
14867 (do_initial_child_stuff): Add `attached' argument. Add process to
14868 processes table.
14869 (child_fetch_inferior_registers, child_store_inferior_registers):
14870 Adjust.
14871 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
14872 (win32_attach): Pass 1 to do_initial_child_stuff.
14873 (win32_kill): Adjust interface. Remove process from processes
14874 table.
14875 (win32_detach): Ditto.
14876 (win32_join): Adjust interface.
14877 (win32_thread_alive): Take a ptid.
14878 (win32_resume): Adjust to use ptids.
14879 (get_child_debug_event): Ditto.
14880 (win32_wait): Adjust interface. Remove exiting process from
14881 processes table.
14882
bd99dc85
PA
148832009-04-01 Pedro Alves <pedro@codesourcery.com>
14884
14885 Non-stop mode support.
14886
14887 * server.h (non_stop): Declare.
14888 (gdb_client_data, handler_func): Declare.
14889 (delete_file_handler, add_file_handler, start_event_loop):
14890 Declare.
14891 (handle_serial_event, handle_target_event, push_event)
14892 (putpkt_notif): Declare.
14893 * target.h (enum resume_kind): New.
14894 (struct thread_resume): Replace `step' field by `kind' field.
14895 (TARGET_WNOHANG): Define.
14896 (struct target_ops) <wait>: Add `options' argument.
14897 <supports_non_stop, async, start_non_stop>: New fields.
14898 (target_supports_non_stop, target_async): New.
14899 (start_non_stop): Declare.
14900 (mywait): Add `options' argument.
14901 * target.c (mywait): Add `options' argument. Print child exit
14902 notifications here.
14903 (start_non_stop): New.
14904 * server.c (non_stop, own_buf, mem_buf): New globals.
14905 (struct vstop_notif): New.
14906 (notif_queue): New global.
14907 (queue_stop_reply, push_event, discard_queued_stop_replies)
14908 (send_next_stop_reply): New.
14909 (start_inferior): Adjust to use resume_kind. Adjust to mywait
14910 interface changes.
14911 (attach_inferior): In non-stop mode, don't wait for the target
14912 here.
14913 (handle_general_set): Handle QNonStop.
14914 (handle_query): When handling qC, return the current general
14915 thread, instead of the first thread of the list.
14916 (handle_query): If the backend supports non-stop mode, include
14917 QNonStop+ in the qSupported query response.
14918 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
14919 and non-stop mode.
14920 (handle_v_attach, handle_v_run): Handle non-stop mode.
14921 (handle_v_stopped): New.
14922 (handle_v_requests): Report support for vCont;t. Handle vStopped.
14923 (myresume): Adjust to use resume_kind. Handle non-stop.
14924 (queue_stop_reply_callback): New.
14925 (handle_status): Handle non-stop mode.
14926 (main): Clear non_stop flag on reconnection. Use the event-loop.
14927 Refactor serial protocol handling from here ...
14928 (process_serial_event): ... to this new function. When GDB
14929 selects any thread, select one here. In non-stop mode, wait until
14930 GDB acks all pending events before exiting.
14931 (handle_serial_event, handle_target_event): New.
14932 * remote-utils.c (remote_open): Install remote_desc in the event
14933 loop.
14934 (remote_close): Remove remote_desc from the event loop.
14935 (putpkt_binary): Rename to...
14936 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
14937 (putpkt_binary): New as wrapper around putpkt_binary_1.
14938 (putpkt_notif): New.
14939 (prepare_resume_reply): In non-stop mode, don't change the
14940 general_thread.
14941 * event-loop.c: New.
14942 * Makefile.in (OBJ): Add event-loop.o.
14943 (event-loop.o): New rule.
14944
14945 * linux-low.h (pid_of): Moved here.
14946 (lwpid_of): New.
14947 (get_lwp_thread): Use lwpid_of.
14948 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
14949 * linux-low.c (pid_of): Delete.
14950 (inferior_pid): Use lwpid_of.
14951 (linux_event_pipe): New.
14952 (target_is_async_p): New.
14953 (delete_lwp): New.
14954 (handle_extended_wait): Use lwpid_of.
14955 (add_lwp): Don't set lwpid field.
14956 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
14957 (linux_kill_one_lwp): If killing a running lwp, stop it first.
14958 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
14959 (linux_detach_one_lwp): If detaching from a running lwp, stop it
14960 first. Adjust to linux_wait_for_event interface changes. Use
14961 lwpid_of.
14962 (linux_detach): Don't delete the main lwp here.
14963 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
14964 (status_pending_p): Don't consider explicitly suspended lwps.
14965 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
14966 pointer. Add OPTIONS argument. Change return type to int. Use
14967 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
14968 (linux_wait_for_event): Take an integer pid instead of a lwp_info
14969 pointer. Add status pointer argument. Return a pid instead of a
14970 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
14971 changes. In non-stop mode, don't switch to a random thread.
14972 (linux_wait): Rename to...
14973 (linux_wait_1): ... this. Add target_options argument, and handle
14974 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
14975 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
14976 clean exit and signal exit code. Don't stop all threads in
14977 non-stop mode. In all-stop mode, only stop all threads when
14978 reporting a stop to GDB. Handle explicit thread stop requests.
14979 (async_file_flush, async_file_mark): New.
14980 (linux_wait): New.
14981 (send_sigstop): Use lwpid_of.
14982 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
14983 interface changes. In non-stop mode, don't switch to a random
14984 thread.
14985 (linux_resume_one_lwp): Use lwpid_of.
14986 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
14987 (linux_resume_one_thread): ... this. Handle resume_stop. In
14988 non-stop mode, don't look for pending flag in all threads.
14989 (resume_status_pending_p): Don't consider explicitly suspended
14990 threads.
14991 (my_waitpid): Reimplement. Emulate __WALL.
14992 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
14993 Use lwpid_of.
14994 (sigchld_handler, linux_supports_non_stop, linux_async)
14995 (linux_start_non_stop): New.
14996 (linux_target_ops): Register linux_supports_non_stop, linux_async
14997 and linux_start_non_stop.
14998 (initialize_low): Install SIGCHLD handler.
14999 * thread-db.c (thread_db_create_event, find_one_thread)
15000 (thread_db_get_tls_address): Use lwpid_of.
15001 * win32-low.c (win32_detach): Adjust to use resume_kind.
15002 (win32_wait): Add `options' argument.
15003 * spu-low.c (spu_resume): Adjust to use resume_kind.
15004 (spu_wait): Add `options' argument.
15005
5b1c542e
PA
150062009-04-01 Pedro Alves <pedro@codesourcery.com>
15007
15008 Decouple target code from remote protocol.
15009
15010 * target.h (enum target_waitkind): New.
15011 (struct target_waitstatus): New.
15012 (struct target_ops) <wait>: Return an unsigned long. Take a
15013 target_waitstatus pointer instead of a char pointer.
15014 (mywait): Likewise.
15015 * target.c (mywait): Change prototype to return an unsigned long.
15016 Take a target_waitstatus pointer instead of a char pointer. Adjust.
15017 * server.h (thread_from_wait, old_thread_from_wait): Delete
15018 declarations.
15019 (prepare_resume_reply): Change prototype to take a
15020 target_waitstatus.
15021 * server.c (thread_from_wait, old_thread_from_wait): Delete.
15022 (last_status, last_ptid): New.
15023 (start_inferior): Remove "statusptr" argument. Adjust. Return a
15024 pid instead of a signal.
15025 (attach_inferior): Remove "status" and "signal" parameters.
15026 Adjust.
15027 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
15028 not as an address.
15029 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
15030 (handle_v_requests, myresume): Remove "status" and "signal"
15031 parameters. Adjust.
15032 (handle_status): New.
15033 (main): Delete local `status'. Adjust.
15034 * remote-utils.c: Include target.h.
15035 (prepare_resume_reply): Change prototype to take a
15036 target_waitstatus. Adjust.
15037
15038 * linux-low.c (linux_wait): Adjust to new target_ops->wait
15039 interface.
15040 * spu-low.c (spu_wait): Adjust.
15041 * win32-low.c (enum target_waitkind, struct target_waitstatus):
15042 Delete.
15043 (win32_wait): Adjust.
15044
2bd7c093
PA
150452009-04-01 Pedro Alves <pedro@codesourcery.com>
15046
15047 * target.h (struct thread_resume): Delete leave_stopped member.
15048 (struct target_ops): Add a `n' argument to the `resume' callback.
15049 * server.c (start_inferior): Adjust.
15050 (handle_v_cont, myresume): Adjust.
15051 * linux-low.c (check_removed_breakpoint): Adjust to resume
15052 interface change, and to removed leave_stopped field.
15053 (resume_ptr): Delete.
15054 (struct thread_resume_array): New.
15055 (linux_set_resume_request): Add new `arg' parameter. Adjust to
15056 resume interface change.
15057 (linux_continue_one_thread, linux_queue_one_thread)
15058 (resume_status_pending_p): Check if the resume field is NULL
15059 instead of checking the leave_stopped member.
15060 (linux_resume): Adjust to the target resume interface change.
15061 * spu-low.c (spu_resume): Adjust to the target resume interface
15062 change.
15063 * win32-low.c (win32_detach, win32_resume): Ditto.
15064
c35fafde
PA
150652009-04-01 Pedro Alves <pedro@codesourcery.com>
15066
15067 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
15068 flag.
15069 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
15070 pending.
15071 (linux_continue_one_thread): Only preserve the stepping flag if
15072 there's a pending breakpoint.
15073
0a59d50b
PA
150742009-03-31 Pedro Alves <pedro@codesourcery.com>
15075
15076 * server.c (main): After the inferior having exited, call
15077 remote_close before exiting gdbserver.
15078
f04c6d38
TJB
150792009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
15080
15081 Fix size of FPSCR in Power 7 processors.
15082 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
15083 (PPC_FEATURE_HAS_DFP): New #define.
15084 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
15085 size of the FPSCR.
15086
78e5cee6
PA
150872009-03-23 Pedro Alves <pedro@codesourcery.com>
15088
15089 * server.c (handle_query) Whitespace and formatting.
15090
1b3f6016
PA
150912009-03-22 Pedro Alves <pedro@codesourcery.com>
15092
15093 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
15094 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
15095 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
15096 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
15097 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
15098 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
15099 Makefile.in, configure.ac: Fix whitespace throughout.
15100 * configure: Regenerate.
15101
a07b2135
PA
151022009-03-22 Pedro Alves <pedro@codesourcery.com>
15103
15104 * inferiors.c (find_inferior): Make it safe for the callback
15105 function to delete the currently iterated inferior.
15106
67cc2626
PA
151072009-03-22 Pedro Alves <pedro@codesourcery.com>
15108
15109 * Makefile.in (linuw_low_h): Move higher.
15110 (thread-db.o): Depend on $(linux_low_h).
15111
54a0b537
PA
151122009-03-17 Pedro Alves <pedro@codesourcery.com>
15113
15114 Rename "process" to "lwp" throughout.
15115
15116 * linux-low.c (all_processes): Rename to...
15117 (all_lwps): ... this.
15118 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
15119 (add_process): Rename to ...
15120 (add_lwp): ... this. Adjust.
15121 (linux_create_inferior): Adjust.
15122 (linux_attach_lwp): Adjust.
15123 (linux_attach): Adjust.
15124 (linux_kill_one_process): Rename to ...
15125 (linux_kill_one_lwp): ... this. Adjust.
15126 (linux_kill): Adjust.
15127 (linux_detach_one_process): Rename to ...
15128 (linux_detach_one_lwp): ... this. Adjust.
15129 (linux_detach): Adjust.
15130 (check_removed_breakpoint): Adjust.
15131 (status_pending_p): Adjust.
15132 (linux_wait_for_process): Rename to ...
15133 (linux_wait_for_lwp): ... this. Adjust.
15134 (linux_wait_for_event): Adjust.
15135 (send_sigstop): Adjust.
15136 (wait_for_sigstop): Adjust.
15137 (stop_all_processes): Rename to ...
15138 (stop_all_lwps): ... this.
15139 (linux_resume_one_process): Rename to ...
15140 (linux_resume_one_lwp): ... this. Adjust.
15141 (linux_set_resume_request, linux_continue_one_thread)
15142 (linux_queue_one_thread, resume_status_pending_p)
15143 (usr_store_inferior_registers, regsets_store_inferior_registers)
15144 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
15145 Adjust.
15146 * linux-low.h (get_process): Rename to ...
15147 (get_lwp): ... this. Adjust.
15148 (get_thread_process): Rename to ...
15149 (get_thread_lwp): ... this. Adjust.
15150 (get_process_thread): Rename to ...
15151 (get_lwp_thread): ... this. Adjust.
15152 (struct process_info): Rename to ...
15153 (struct lwp_info): ... this.
15154 (all_processes): Rename to ...
15155 (all_lwps): ... this.
15156 * proc-service.c (ps_lgetregs): Adjust.
15157 * thread-db.c (thread_db_create_event, find_one_thread)
15158 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
15159
0b16c5cf
PA
151602009-03-14 Pedro Alves <pedro@codesourcery.com>
15161
15162 * server.c (handle_query): Handle "qAttached".
15163
32de4b9d
NS
151642009-03-13 Nathan Sidwell <nathan@codesourcery.com>
15165
15166 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
15167 GPLv3, update license URL.
15168
2aecd87f
DE
151692009-03-01 Doug Evans <dje@google.com>
15170
93efd302 15171 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
2aecd87f
DE
15172 (server_h): Add gdb_signals.h.
15173 (signals.o): Update.
15174 * server.h (target_signal_from_host,target_signal_to_host_p)
15175 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
15176
86b1f9c5
PM
151772009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
15178
15179 * remote-utils.c (getpkt): Also generate remote-debug
15180 information if noack_mode is set.
15181
4aa995e1
PA
151822009-02-06 Pedro Alves <pedro@codesourcery.com>
15183
15184 * server.c (handle_query): Report qXfer:siginfo:read and
15185 qXfer:siginfo:write as supported and handle them.
15186 * target.h (struct target_ops) <qxfer_siginfo>: New field.
15187 * linux-low.c (linux_xfer_siginfo): New.
15188 (linux_target_ops): Set it.
15189
62709adf
PA
151902009-01-26 Pedro Alves <pedro@codesourcery.com>
15191
15192 * server.c (gdbserver_usage): Mention --remote-debug.
15193 (main): Accept '--remote-debug' switch.
15194
aef93bd7
DE
151952009-01-18 Doug Evans <dje@google.com>
15196
15197 * regcache.c (new_register_cache): No need to check result of xcalloc.
15198 * server.c (handle_search_memory): Back out calls to xmalloc,
15199 result is checked and error is returned to user upon failure.
15200 (handle_query): Ditto. Add more checks for result of malloc.
15201 (handle_v_cont): Check result of malloc, report error back to
15202 user upon failure.
15203 (handle_v_run): Ditto. Call freeargv.
15204 * server.h (freeargv): Declare.
15205 * utils.c (freeargv): New fn.
15206
54363045
DE
152072009-01-15 Doug Evans <dje@google.com>
15208
f626972c
DE
15209 * gdbreplay.c (perror_with_name): Make arg const char *.
15210 * server.h (target_signal_to_name): Make return type const char *.
0842e787 15211 * thread-db.c (thread_db_err_str): Make return type const char *.
f626972c 15212 * utils.c (perror_with_name): Make arg const char *.
54363045 15213
18aae699
PA
152142009-01-14 Pedro Alves <pedro@codesourcery.com>
15215
15216 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
15217 when handling a EXIT_PROCESS_DEBUG_EVENT.
15218
ff703abe
JB
152192009-01-06 Joel Brobecker <brobecker@adacore.com>
15220
15221 * gdbreplay.c (gdbreplay_version): Update copyright year.
15222 * server.c (gdbserver_version): Likewise.
15223
f21cc1a2 152242009-01-05 Doug Evans <dje@google.com>
0e21c1ec
DE
15225
15226 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
f21cc1a2 15227 (handle_extended_wait): Improve comment.
0e21c1ec 15228
bca929d3
DE
152292008-12-13 Doug Evans <dje@google.com>
15230
15231 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
15232 * server.h (ATTR_MALLOC): New macro.
15233 (xmalloc,xcalloc,xstrdup): Declare.
15234 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
15235 * inferiors.c: Ditto.
15236 * linux-low.c: Ditto.
15237 * mem-break.c: Ditto.
15238 * regcache.c: Ditto.
15239 * remote-utils.c: Ditto.
15240 * server.c: Ditto.
15241 * target.c: Ditto.
15242 * win32-low.c: Ditto.
15243
97438e3f
DE
152442008-12-12 Doug Evans <dje@google.com>
15245
896c7fbb
DE
15246 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
15247 in debugging printf.
15248
97438e3f
DE
15249 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
15250
e3b886f8
DE
152512008-12-09 Doug Evans <dje@google.com>
15252
15253 * linux-low.h (struct process_info): Delete member tid, unused.
15254 * thread-db.c (find_one_thread): Update.
15255 (maybe_attach_thread): Update.
15256
07e059b5
VP
152572008-12-02 Pedro Alves <pedro@codesourcery.com>
15258
889bf7c5
PA
15259 * target.h (struct target_ops): Add qxfer_osdata member.
15260 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
15261 and dirent.h.
15262 (linux_qxfer_osdata): New functions.
15263 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
15264 callback.
15265 * server.c (handle_query): Handle "qXfer:osdata:read:".
15266 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
15267 (buffer_xml_printf): New functions.
15268 * server.h (struct buffer): New.
15269 (buffer_grow_str, buffer_grow_str0): New macros.
15270 (buffer_grow, buffer_free, buffer_init, buffer_finish)
15271 (buffer_xml_printf): Declare.
07e059b5 15272
4cab47ab
DE
152732008-11-24 Doug Evans <dje@google.com>
15274
15275 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
15276
f142445f
DJ
152772008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
15278
15279 * server.c (handle_v_run): Always use the supplied argument list.
15280
d0107bb6 152812008-11-19 Bob Wilson <bob.wilson@acm.org>
889bf7c5 15282
d0107bb6
BW
15283 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
15284 (xtensa_regmap_table): Add entry for scompare1.
889bf7c5 15285
2c4ad781
TJB
152862008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
15287
15288 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
15289 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
15290 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
15291 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
15292 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
15293 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
15294 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
15295 XML target descriptions.
15296 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
15297 when inferior is running on an ISA 2.05 or later processor. Add
15298 special case to return offset for full 64-bit slot of FPSCR when
15299 in 32-bits.
15300
dfb64f85
DJ
153012008-11-14 Daniel Gutson <dgutson@codesourcery.com>
15302
15303 * Makefile.in (SFILES, clean): Added sparc64 files.
15304 (reg-sparc64.o, reg-sparc64.c): New.
15305 * configure.srv (sparc*-*-linux*): New configuration.
15306 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
15307 syscall arguments for SPARC.
15308 (regsets_store_inferior_registers): Likewise.
15309 * linux-sparc-low.c: New file.
15310
66b6e1dd
DE
153112008-10-21 Doug Evans <dje@google.com>
15312
15313 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
15314 (READLINE_DIR,READLINE_DEP): Delete.
15315 (INTERNAL_CFLAGS): Update.
15316 (LINTFLAGS): Update.
15317
9b710a42
PA
153182008-10-10 Pedro Alves <pedro@codesourcery.com>
15319
15320 * server.c (handle_v_run): If GDB didn't specify an argv, use the
15321 whole argv from the last run, not just argv[0].
15322
5822d809
PA
153232008-09-08 Pedro Alves <pedro@codesourcery.com>
15324
15325 * regcache.c (new_register_cache): Return NULL if the register
15326 cache size isn't known yet.
15327 (free_register_cache): Avoid dereferencing a NULL regcache.
15328
74aac56f
DJ
153292008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
15330
15331 * configure.srv: Merge MIPS and MIPS64.
15332
400b20f5
MR
153332008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
15334
15335 * Makefile.in (uninstall): Apply $(EXEEXT) too.
15336
677c5bb1
LM
153372008-08-18 Luis Machado <luisgpm@br.ibm.com>
15338
15339 * Makefile.in: Add required vsx dependencies.
15340
15341 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
15342 Declare init_registers_powerpc_vsx32l.
15343 Declare init_registers_powerpc_vsx64l.
15344 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
15345 (ppc_arch_setup): Check for VSX in hwcap.
15346 (ppc_fill_vsxregset): New function.
15347 (ppc_store_vsxregset): New function.
15348 Add new VSX entry in regset_info target_regsets.
15349
15350 * configure.srv: Add new VSX dependencies.
15351
a6f3e723
SL
153522008-08-12 Pedro Alves <pedro@codesourcery.com>
15353
15354 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
15355 (remote_open): Set or clear transport_is_reliable.
15356 (putpkt_binary): Don't expect acks in noack mode.
15357 (getpkt): Don't send ack/nac in noack mode.
15358 * server.c (handle_general_set): Handle QStartNoAckMode.
15359 (handle_query): If connected by tcp pass QStartNoAckMode+ in
15360 qSupported.
15361 (main): Reset noack_mode on every connection.
15362 * server.h (noack_mode): Declare.
15363
a417dc56
RW
153642008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15365
15366 * Makefile.in (GDBREPLAY_OBS): New variable.
15367 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
15368
3221518c
UW
153692008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
15370 Daniel Jacobowitz <dan@codesourcery.com>
15371
15372 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
15373 (usr_store_inferior_registers): Likewise.
15374 (regsets_store_inferior_registers): Likewise.
15375
ec56be1b
PA
153762008-07-31 Rolf Jansen <rj@surtec.com>
15377 Pedro Alves <pedro@codesourcery.com>
15378
15379 * configure.ac: Check for memmem declaration.
15380 * server.c [HAVE_MALLOC_H]: Include malloc.h.
15381 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
15382 (disable_packet_qfThreadInfo): Unconditionally compile.
15383 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
15384 * configure, config.in: Regenerate.
15385
2fe5e3ff
DE
153862008-07-28 Doug Kwan <dougkwan@google.com>
15387
15388 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
15389 (linux_write_memory): Remove declaration of errno.
15390
836acd6d
UW
153912008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
15392
15393 * linux-low.c (handle_extended_wait): Do not use "status"
15394 variable uninitialized.
15395
aeba519e
PA
153962008-07-07 Pedro Alves <pedro@codesourcery.com>
15397
15398 * server.c (handle_v_attach): Inhibit reporting dll changes.
15399
db42f210
PA
154002008-06-27 Pedro Alves <pedro@codesourcery.com>
15401
15402 * remote-utils.c (prepare_resume_reply): If requested, don't
15403 output "thread:TID" in the T stop reply.
15404
15405 * server.c (disable_packet_vCont, disable_packet_Tthread)
15406 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
15407 (handle_query): If requested, disable support for qC, qfThreadInfo
15408 and qsThreadInfo.
15409 (handle_v_requests): If requested, disable support for vCont.
15410 (gdbserver_show_disableable): New.
15411 (main): Handle --disable-packet and --disable-packet=LIST.
15412
15413 * server.h (disable_packet_vCont, disable_packet_Tthread)
15414 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
15415
8e4c5421
CD
154162008-06-20 Carlos O'Donell <carlos@codesourcery.com>
15417
15418 * server.c (gdbserver_usage): Mention --version.
15419
6e23a804
DJ
154202008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
15421
15422 * Makefile.in (gdbreplay.o): New rule.
15423
90aa6a40
JM
154242008-06-06 Joseph Myers <joseph@codesourcery.com>
15425
15426 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
15427 message, not gdbserver.
15428
c16158bc 154292008-06-05 Vladimir Prus <vladimir@codesourcery.com>
889bf7c5
PA
15430 Nathan Sidwell <nathan@codesourcery.com>
15431 Joseph Myers <joseph@codesourcery.com>
c16158bc
JM
15432
15433 * acinclude.m4: Include ../../config/acx.m4.
15434 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
15435 * configure, config.in: Regenerate.
15436 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
15437 * server.c (gdbserver_version): Print PKGVERSION.
15438 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
15439 (main): Adjust gdbserver_usage calls.
15440 * gdbreplay.c (version, host_name): Add declarations.
15441 (gdbreplay_version, gdbreplay_usage): New.
15442 (main): Accept --version and --help options.
15443
aeb75bf5
DJ
154442008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
15445
15446 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
15447 (arm_breakpoint_at): Handle Thumb.
15448 (the_low_target): Add comment.
15449
76b233dd
UW
154502008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
15451
15452 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
15453
08388c79
DE
154542008-05-09 Doug Evans <dje@google.com>
15455
a3c83fae
DE
15456 * server.h (decode_search_memory_packet): Declare.
15457 * remote-utils.c (decode_search_memory_packet): New fn.
15458 * server.c (handle_search_memory_1): New fn.
08388c79
DE
15459 (handle_search_memory): New fn.
15460 (handle_query): Process qSearch:memory packets.
15461
bb9c3d36
UW
154622008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
15463
15464 * regcache.c (registers_length): Remove.
15465 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
15466 full register packet.
15467 * regcache.h (registers_length): Remove prototype.
15468 * server.h (PBUFSIZ): Define to 16384.
15469
7284e1be
UW
154702008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
15471
15472 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
15473 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
15474 powerpc-64l.o, and powerpc-altivec64l.o.
15475 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
15476 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
15477 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
15478 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
15479 rs6000/power-linux.xml, and rs6000/power64-linux.xml
15480 to srv_xmlfiles.
15481
15482 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
15483 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
15484 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
15485 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
15486 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
15487 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
15488 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
15489 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
15490 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
15491 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
15492 (clean): Update.
15493
15494 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
15495 (init_registers_powerpc_32l): ... this new prototype.
15496 (init_registers_powerpc_32): Remove, replace by ...
15497 (init_registers_powerpc_altivec32l): ... this new prototype.
15498 (init_registers_powerpc_e500): Remove, replace by ...
15499 (init_registers_powerpc_e500l): ... this new prototype.
15500 (init_registers_ppc64): Remove, replace by ...
15501 (init_registers_powerpc_64l): ... this new prototype.
15502 (init_registers_powerpc_64): Remove, replace by ...
15503 (init_registers_powerpc_altivec64l): ... this new prototype.
15504 (ppc_num_regs): Set to 73.
15505 (PT_ORIG_R3, PT_TRAP): Define if necessary.
15506 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
15507 (ppc_cannot_store_register): Handle orig_r3 and trap.
15508 (ppc_arch_setup): Update init_registers_... calls.
15509 (ppc_fill_gregset): Handle orig_r3 and trap.
15510
15511 * inferiors.c (clear_inferiors): Reset current_inferior.
15512
fdc59709
PB
155132008-04-23 Paolo Bonzini <bonzini@gnu.org>
15514
889bf7c5
PA
15515 * acinclude.m4: Add override.m4.
15516 * configure: Regenerate.
fdc59709 15517
c9b2f845
UW
155182008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
15519
15520 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
15521 initial call to init_register_ppc64.
15522
550512b8
UW
155232008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
15524
43aaf8b6
PA
15525 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
15526 single powerpc*-*-linux* case.
550512b8
UW
15527 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
15528
b6430ec3
UW
155292008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
15530
15531 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
889bf7c5 15532 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
b6430ec3
UW
15533 from reg_xmlfiles.
15534 * linux-ppc-low.c: Include <elf.h>.
15535 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
15536 (ppc_hwcap): New global variable.
15537 (ppc_regmap): Remove __SPE__ #ifdef sections.
15538 (ppc_regmap_e500): New global variable.
15539 (ppc_cannot_store_register): Update __SPE__ special case.
15540 (ppc_get_hwcap): New function.
15541 (ppc_arch_setup): Use it to determine whether inferior supports
15542 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
15543 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
15544 Do not access registers if target does not support AltiVec.
15545 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
15546 Do not access registers if target does not support SPE.
15547 (target_regsets): Unconditionally include AltiVec and SPE regsets.
15548
52fa2412
UW
155492008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
15550
15551 * linux-low.c (disabled_regsets, num_regsets): New.
15552 (use_regsets_p): Delete.
15553 (linux_wait_for_process): Clear disabled_regsets.
15554 (regsets_fetch_inferior_registers): Check and set it.
15555 (regsets_store_inferior_registers): Likewise.
15556 (linux_fetch_registers, linux_store_registers): Do not use
15557 use_regsets_p.
15558 (initialize_low): Allocate disabled_regsets.
15559
e28b3332
DJ
155602008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
15561
15562 * Makefile.in (LIBOBJS): New.
15563 (OBS): Use LIBOBJS.
15564 (memmem.o): New rule.
15565 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
15566 * configure: Regenerated.
15567
4536995d
UW
155682008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
15569
15570 * server.c (handle_query): Never return "unsupported" for
15571 qXfer:features:read queries.
15572
221c031f
UW
155732008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
15574
15575 * server.c (get_features_xml): Fix inverted condition.
15576 (handle_query): Always support qXfer:feature:read.
15577
ccd213ac
DJ
155782008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
15579
15580 * server.c (wrapper_argv): New.
15581 (start_inferior): Handle wrapper_argv. If set, expect an extra
15582 trap.
15583 (gdbserver_usage): Document --wrapper.
15584 (main): Parse --wrapper.
15585
6fe305f7
UW
155862008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15587
15588 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
15589 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
15590 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
15591 (ppc_set_pc): Likewise.
15592 (ppc_arch_setup): New function.
15593 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
15594 of collect_register.
889bf7c5 15595 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
6fe305f7 15596
5b0a002e
UW
155972008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15598
15599 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
15600 instead of linux-ppc64-low.o.
15601 * linux-ppc64-low.c: Remove file.
15602 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
15603 (linux-ppc64-low.o): Remove rule.
15604
15605 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
15606 (init_registers_powerpc_64): Likewise.
15607 (ppc_regmap): Conditionally define depending on __powerpc64__.
15608 (ppc_cannot_store_register): Do not special-case "fpscr" when
15609 compiled on __powerpc64__.
15610 (ppc_collect_ptrace_register): New function.
15611 (ppc_supply_ptrace_register): New function.
15612 (ppc_breakpoint): Change type to "unsigned int".
15613 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
15614 (the_low_target): Conditionally provide initializers for the
889bf7c5 15615 arch_setup member depending on __powerpc64__. Install
5b0a002e
UW
15616 collect_ptrace_register and supply_ptrace_register members.
15617
9b4b61c8
UW
156182008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15619
15620 * regcache.h (gdbserver_xmltarget): Add extern declaration.
15621 * server.c (gdbserver_xmltarget): Define.
15622 (get_features_xml): Use it to replace "target.xml" and arch_string.
15623
15624 * configure.srv: Remove srv_xmltarget. Add XML files that were
15625 mentioned there to srv_xmlfiles instead. Remove conditional tests
15626 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
15627 srv_xmlfiles and srv_regobj to include all possible choices.
15628 * configure.ac (srv_xmltarget): Remove.
15629 (srv_xmlfiles): Do not add "target.xml".
15630 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
15631 checks for supplementary target information.
15632 * configure: Regenerate.
15633 * Makefile.in (XML_TARGET): Remove.
15634 (target.xml): Remove rule.
15635 (clean): Do not clean up target.xml.
15636 (.PRECIOUS): Do not mention target.xml.
15637
15638 * target.h (struct target_ops): Remove arch_string member.
15639 * linux-low.c (linux_arch_string): Remove.
15640 (linux_target_ops): Remove arch_string initializer.
15641 * linux-low.h (struct linux_target_ops): Remove arch_string member.
15642 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
15643 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
15644 * spu-low.c (spu_arch_string): Remove.
15645 (spu_target_ops): Remove arch_string initializer.
15646 * win32-low.c (win32_arch_string): Remove.
15647 (win32_target_ops): Remove arch_string initializer.
15648 * win32-low.h (struct win32_target_ops): Remove arch_string member.
15649 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
15650 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
15651
ee1a7ae4
UW
156522008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15653
15654 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
15655 by collect_ptrace_register and supply_ptrace_register hooks.
15656 * linux-low.c (fetch_register): Use supply_ptrace_register callback
15657 instead of checking for the_low_target.left_pad_xfer.
15658 (usr_store_inferior_registers): Use collect_ptrace_register callback
15659 instead of checking for the_low_target.left_pad_xfer.
15660
15661 * linux-s390-low.c (s390_collect_ptrace_register): New function.
15662 (s390_supply_ptrace_register): Likewise.
15663 (s390_fill_gregset): Call s390_collect_ptrace_register.
15664 (the_low_target): Update.
15665
15666 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
15667 (ppc_supply_ptrace_register): Likewise.
15668 (the_low_target): Update.
15669
15670 * linux-i386-low.c (the_low_target): Update.
15671 * linux-x86-64-low.c (the_low_target): Update.
15672
d61ddec4
UW
156732008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15674
15675 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
15676 reg-s390.o and reg-s390x.o.
15677
15678 * linux-low.c (new_inferior): New global variable.
15679 (linux_create_inferior, linux_attach): Set it.
15680 (linux_wait_for_process): Call the_low_target.arch_setup after the
15681 target has stopped for the first time.
15682 (initialize_low): Do not call the_low_target.arch_setup.
15683
15684 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
15685 (s390_set_pc): Likewise.
15686 (s390_arch_setup): New function.
15687 (the_low_target): Use s390_arch_setup as arch_setup routine.
15688
15689 * regcache.c (realloc_register_cache): New function.
15690 (set_register_cache): Call it for each existing regcache.
15691
d05b4ac3
UW
156922008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15693
15694 * server.h (init_registers): Remove prototype.
15695
15696 * linux-low.h (struct linux_target_ops): Add arch_setup field.
15697 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
15698 instead of init_registers ().
15699 * linux-arm-low.c (init_registers_arm): Add prototype.
15700 (init_registers_arm_with_iwmmxt): Likewise.
15701 (the_low_target): Add initializer for arch_setup field.
15702 * linux-cris-low.c (init_registers_cris): Add prototype.
15703 (the_low_target): Add initializer for arch_setup field.
15704 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
15705 (the_low_target): Add initializer for arch_setup field.
15706 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
15707 (the_low_target): Add initializer for arch_setup field.
15708 * linux-ia64-low.c (init_registers_ia64): Add prototype.
15709 (the_low_target): Add initializer for arch_setup field.
15710 * linux-m32r-low.c (init_registers_m32r): Add prototype.
15711 (the_low_target): Add initializer for arch_setup field.
15712 * linux-m68k-low.c (init_registers_m68k): Add prototype.
15713 (the_low_target): Add initializer for arch_setup field.
15714 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
15715 (init_registers_mips64_linux): Likewise.
15716 (the_low_target): Add initializer for arch_setup field.
15717 * linux-ppc-low.c (init_registers_ppc): Add prototype.
15718 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
15719 (the_low_target): Add initializer for arch_setup field.
15720 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
15721 (init_registers_powerpc_64): Likewise.
15722 (the_low_target): Add initializer for arch_setup field.
15723 * linux-s390-low.c (init_registers_s390): Add prototype.
15724 (init_registers_s390x): Likewise.
15725 (the_low_target): Add initializer for arch_setup field.
15726 * linux-sh-low.c (init_registers_sh): Add prototype.
15727 (the_low_target): Add initializer for arch_setup field.
15728 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
15729 (the_low_target): Add initializer for arch_setup field.
15730 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
15731 (the_low_target): Add initializer for arch_setup field.
15732
15733 * win32-low.h (struct win32_target_ops): Add arch_setup field.
15734 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
15735 instead of init_registers ().
15736 * win32-arm-low.c (init_registers_arm): Add prototype.
15737 (the_low_target): Add initializer for arch_setup field.
15738 * win32-i386-low.c (init_registers_i386): Add prototype.
15739 (the_low_target): Add initializer for arch_setup field.
15740
15741 * spu-low.c (init_registers_spu): Add prototype.
15742 (initialize_low): Call initialie_registers_spu () instead of
15743 initialize_registers ().
15744
fd96d250
PA
157452008-02-19 Pedro Alves <pedro@codesourcery.com>
15746
15747 * server.c (handle_v_requests): When handling the vRun and vAttach
15748 packets, if already debugging a process, don't kill it. Return an
15749 error instead.
15750
d41b6bb4
DJ
157512008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
15752
15753 * server.c (handle_query): Correct length check.
15754
5ac588cf
PA
157552008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
15756
15757 * win32-low.c (do_initial_child_stuff): Add process handle
15758 parameter. Set current_process_handle and current_process_id from the
15759 parameters. Clear globals.
15760 (win32_create_inferior): Don't set current_process_handle and
15761 current_process_id here. Instead pass them on the call to
15762 do_initial_child_stuff.
15763 (win32_attach): Likewise.
15764 (win32_clear_inferiors): New.
15765 (win32_kill): Don't close the current process handle or the
15766 current thread handle here. Instead call win32_clear_inferiors.
15767 (win32_detach): Don't open a new handle to the process. Call
15768 win32_clear_inferiors.
15769 (win32_join): Don't rely on current_process_handle; open a new
15770 handle using the process id.
15771 (win32_wait): Call win32_clear_inferiors when the inferior process
15772 has exited.
15773
ecd7ecbc
DJ
157742008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
15775
15776 * server.c (monitor_show_help): Add "exit".
15777
1525d545
MG
157782008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
15779
ecd7ecbc 15780 * Makefile.in (SFILES): Add linux-xtensa-low.c.
1525d545
MG
15781 (clean): Add reg-xtensa.c.
15782 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
ecd7ecbc
DJ
15783 * configure.srv (xtensa*-*-linux*) New target.
15784 * linux-xtensa-low.c: New.
15785 * xtensa-xtregs.c: New.
1525d545 15786
59a016f0
PA
157872008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
15788
15789 * hostio.c: Don't include errno.h.
15790 (errno_to_fileio_errno): Move to hostio-errno.
15791 * hostio.c: (hostio_error): Remove the error parameter. Defer the
15792 error number outputting to the target->hostio_last_error callback.
15793 (hostio_packet_error): Use FILEIO_EINVAL directly.
15794 (handle_open, handle_pread, hostio_error, handle_unlink): Update
15795 calls to hostio_error.
15796 * hostio-errno.c: New.
15797 * server.h (hostio_last_error_from_errno): Declare.
15798 * target.h (target_ops): Add hostio_last_error member.
15799 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
15800 as hostio_last_error handler.
889bf7c5 15801 * spu-low.c (spu_target_ops): Likewise.
59a016f0
PA
15802 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
15803 (wince_hostio_last_error): New functions.
15804 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
15805 as hostio_last_error handler.
15806 (win32_target_ops) [!_WIN32_WCE]: Register
15807 hostio_last_error_from_errno as hostio_last_error handler.
15808 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
15809 (hostio-errno.o): New rule.
15810 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
15811 * configure.srv (srv_hostio_err_objs): New variable. Default to
15812 hostio-errno.o.
15813 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
15814 * configure: Regenerate.
15815
2d717e4f
DJ
158162008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
15817
15818 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
15819 (linux_kill, linux_detach): Clean up the process list.
15820 * remote-utils.c (remote_open): Improve port number parsing.
15821 (putpkt_binary, input_interrupt): Only send interrupts if the target
15822 is running.
15823 * server.c (extended_protocol): Make static.
15824 (attached): Define earlier.
15825 (exit_requested, response_needed, program_argv): New variables.
15826 (target_running): New.
15827 (start_inferior): Clear attached here.
15828 (attach_inferior): Set attached here.
15829 (require_running): Define.
15830 (handle_query): Use require_running and target_running. Implement
15831 "monitor exit".
15832 (handle_v_attach, handle_v_run): New.
15833 (handle_v_requests): Use require_running. Handle vAttach and vRun.
15834 (gdbserver_usage): Update.
15835 (main): Redo argument parsing. Handle --debug and --multi. Handle
15836 --attach along with other options or after the port. Save
15837 program_argv. Support no initial program. Resynchronize
15838 communication with GDB after an error. Handle "monitor exit".
15839 Use require_running and target_running. Always allow the extended
15840 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
15841 restart in extended mode.
15842 * README: Refer to the GDB manual. Update --attach usage.
15843
7407e2de
AS
158442007-12-20 Andreas Schwab <schwab@suse.de>
15845
15846 * linux-low.c (STACK_SIZE): Define.
15847 (linux_tracefork_child): Use it. Use __clone2 on ia64.
15848 (linux_test_for_tracefork): Likewise.
15849
b65d95c5
DJ
158502007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
15851
15852 * linux-low.c (linux_wait_for_event): Update messages. Do not
15853 reinsert auto-delete breakpoints.
15854 * mem-break.c (struct breakpoint): Change return type of handler to
15855 int.
15856 (set_breakpoint_at): Update handler type.
15857 (reinsert_breakpoint_handler): Return 1 instead of calling
15858 delete_breakpoint.
15859 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
15860 setting a new one.
15861 (check_breakpoints): Delete auto-delete breakpoints and return 2.
15862 * mem-break.h (set_breakpoint_at): Update handler type.
15863 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
15864 * win32-low.c (auto_delete_breakpoint): New.
15865 (get_child_debug_event): Use it.
15866
4e799345
DJ
158672007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
15868
15869 * configure.ac: Check for pread and pwrite.
15870 * hostio.c (handle_pread): Fall back to lseek and read.
15871 (handle_pwrite): Fall back to lseek and write.
15872 * config.in, configure: Regenerated.
15873
27524b67
DJ
158742007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
15875
15876 * server.c (myresume): Add own_buf argument.
15877 (main): Update calls.
15878
a20d5e98
DJ
158792007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
15880
15881 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
15882 * remote-utils.c (remote_open): Do not call disable_async_io.
15883 (block_async_io): Delete.
15884 (unblock_async_io): Make static.
15885 (initialize_async_io): New.
15886 * server.c (handle_v_cont): Handle async I/O here.
15887 (myresume): Likewise. Move other common resume tasks here...
15888 (main): ... from here. Call initialize_async_io. Disable async
15889 I/O before the main loop.
15890 * server.h (initialize_async_io): Declare.
15891 (block_async_io, unblock_async_io): Delete prototypes.
15892 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
15893
b79d787e
DJ
158942007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
15895
15896 * remote-utils.c (readchar): Allow binary data in received messages.
15897
d97903b2
PA
158982007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15899
15900 * win32-low.c (attaching): New global.
15901 (win32_create_inferior): Clear the `attaching' global.
15902 (win32_attach): Set the `attaching' global.
15903 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
15904 attaching. Only set a breakpoint at the entry point if not
15905 attaching.
15906
311de423
PA
159072007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15908
15909 * server.c (main): Don't report dll events on the initial
15910 connection on attaches.
15911
6c2d16d2
PA
159122007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15913
15914 * server.c (main): Relax numerical bases supported for the pid of
15915 the --attach command line argument.
15916
5ca906e6
PA
159172007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15918
15919 * win32-low.c (win32_attach): Call OpenProcess before
15920 DebugActiveProcess, not after. Add last error output to error
15921 call.
15922
9c6c8194
PA
159232007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15924
15925 * win32-low.c (win32_get_thread_context)
15926 (win32_set_thread_context): New functions.
15927 (thread_rec): Use win32_get_thread_context.
15928 (continue_one_thread, win32_resume): Use win32_set_thread_context.
15929 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
15930 field.
15931
4d5d1aaa
PA
159322007-12-03 Leo Zayas
15933 Pedro Alves <pedro_alves@portugalmail.pt>
15934
15935 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
15936 global variables.
15937 (child_add_thread): Minor cleanup.
15938 (child_continue): Resume artificially suspended threads before
15939 calling ContinueDebugEvent.
15940 (suspend_one_thread): New.
15941 (fake_breakpoint_event): New.
15942 (get_child_debug_event): Change return type to int. Check here if
15943 gdb sent an interrupt request. If a soft interrupt was requested,
15944 fake a breakpoint event. Return 0 if there is no event to handle,
15945 and 1 otherwise.
15946 (win32_wait): Don't check here if gdb sent an interrupt request.
15947 Ensure there is a valid event to handle.
15948 (win32_request_interrupt): Add soft interruption method as last
15949 resort.
15950
c436e841
PA
159512007-12-03 Leo Zayas
15952 Pedro Alves <pedro_alves@portugalmail.pt>
15953
15954 * win32-low.h (win32_thread_info): Add descriptions to the
15955 structure members. Replace `suspend_count' counter by a
15956 `suspended' flag.
15957 * win32-low.c (thread_rec): Update condition of when to get the
15958 context from the inferior. Rely on ContextFlags being set if it
15959 has already been retrieved. Only suspend the inferior thread if
15960 we haven't already. Warn if that fails.
15961 (continue_one_thread): s/suspend_count/suspended/. Only call
15962 ResumeThread once. Warn if that fails.
15963
e7b5fa67
PA
159642007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
15965
15966 * win32-low.c (win32_wait): Don't read from the inferior when it
15967 has already exited.
15968
a385171d
PA
159692007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
15970
15971 * Makefile.in (win32_low_h): New variable.
15972 (win32-low.o): Add dependency on $(win32_low_h).
15973 (win32-arm-low.o, win32-i386-low.o): New rules.
15974
f80c84b3
DJ
159752007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
15976
15977 * hostio.c: Correct copyright year.
15978
a6b151f1
DJ
159792007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
15980
15981 * Makefile.in (OBS): Add hostio.o.
15982 (hostio.o): New rule.
15983 * server.h (handle_vFile): Declare.
15984 * hostio.c: New file.
15985 * server.c (handle_v_requests): Take packet_len and new_packet_len
15986 for binary packets. Call handle_vFile.
15987 (main): Update call to handle_v_requests.
15988
f9387fc3
DJ
159892007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
15990
15991 * linux-low.c: Include <sched.h>.
15992
51c2684e
DJ
159932007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
15994
15995 * linux-low.c (linux_tracefork_grandchild): New.
15996 (linux_tracefork_child): Use clone.
15997 (linux_test_for_tracefork): Use clone; allocate and free a stack.
15998
75f83163
JB
159992007-10-31 Joel Brobecker <brobecker@adacore.com>
16000
16001 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
16002
da5898ce
DJ
160032007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
16004
16005 * linux-low.c (handle_extended_wait): Handle unexpected signals.
16006
24a09b5f
DJ
160072007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
16008
16009 * inferiors.c (change_inferior_id): Delete.
16010 (add_pid_to_list, pull_pid_from_list): New.
16011 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
16012 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
16013 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
16014 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
16015 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
16016 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
16017 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
16018 (using_threads): Always set to 1.
16019 (handle_extended_wait): New.
16020 (add_process): Do not set TID.
16021 (linux_create_inferior): Set must_set_ptrace_flags.
16022 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
16023 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
16024 (linux_thread_alive): Rename TID argument to LWPID.
16025 (linux_wait_for_process): Handle unknown processes. Do not use TID.
16026 (linux_wait_for_event): Do not use TID or check using_threads. Update
16027 call to dead_thread_notify. Call handle_extended_wait.
16028 (linux_create_inferior): Use PTRACE_SETOPTIONS.
16029 (send_sigstop): Delete sigstop_sent.
16030 (wait_for_sigstop): Avoid TID.
16031 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
16032 (linux_test_for_tracefork): New.
16033 (linux_lookup_signals): Use thread_db_active and
16034 linux_supports_tracefork_flag.
16035 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
16036 * linux-low.h (get_process_thread): Avoid TID.
16037 (struct process_ifo): Move thread_known and tid to the end. Remove
16038 sigstop_sent.
16039 (linux_attach_lwp, thread_db_init): Update prototypes.
16040 * server.h (change_inferior_id): Delete prototype.
16041 (add_pid_to_list, pull_pid_from_list): New prototypes.
16042 * thread-db.c (thread_db_use_events): New.
16043 (find_first_thread): Rename to...
16044 (find_one_thread): ...this. Update callers and messages. Do not
16045 call fatal. Check thread_db_use_events. Do not call
16046 change_inferior_id or new_thread_notify.
16047 (maybe_attach_thread): Update. Do not call new_thread_notify.
16048 (thread_db_init): Set thread_db_use_events. Check use_events.
16049 * utils.c (fatal, warning): Correct message prefix.
16050
30ed0a8f
DJ
160512007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
16052
16053 * Makefile.in (clean): Remove new files.
16054 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
16055 (powerpc-64.o, powerpc-64.c): New rules.
16056 * configure.srv: Use alternate register sets for powerpc64-*-linux*
16057 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
16058 with SPE.
16059 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
16060 SPE targets.
16061 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
16062 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
16063 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
16064 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
16065 (target_regsets): Add AltiVec and SPE register sets.
16066 * configure.ac: Check for AltiVec and SPE.
16067 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
16068 (ppc_fill_vrregset, ppc_store_vrregset): New.
16069 (target_regsets): Add AltiVec register set.
16070 * configure: Regenerated.
16071
fd462a61
DJ
160722007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
16073
16074 * linux-low.c (O_LARGEFILE): Define.
16075 (linux_read_memory): Use /proc/PID/mem.
16076 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
16077 * configure, config.in: Regenerated.
16078
69f223ed
DJ
160792007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
16080
16081 * linux-low.c (linux_wait_for_event): Do not pass signals while
16082 single-stepping.
16083
aec18585
PA
160842007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
16085
16086 * win32-low.c (create_process): New.
16087 (win32_create_inferior): Use create_process instead of
16088 CreateProcess. If create_process failed retry appending an ".exe"
16089 suffix. Store the GetLastError result immediatelly after
16090 create_process calls and use it on the call to error.
16091
34d86ddd
PA
160922007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
16093
16094 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
16095
5a0e3bd0
JB
160962007-08-23 Joel Brobecker <brobecker@adacore.com>
16097
16098 * configure.ac: Switch license to GPLv3.
16099
f88c79e6
MS
161002007-08-01 Michael Snyder <msnyder@access-company.com>
16101
16102 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
16103
6b3d9b83
PA
161042007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
16105
16106 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
16107 typedef.
16108 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
16109 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
16110 CloseToolhelp32Snapshot.
16111 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
16112 CloseToolhelp32Snapshot.
16113
c588c53c
MS
161142007-07-27 Michael Snyder <michael.snyder@access-company.com>
16115
16116 * server.c (main): Check for inferior exit before main loop.
16117
aa0403d9
PA
161182007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
16119
16120 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
16121 instead of on tmp_desc.
16122
255e7678
DJ
161232007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
16124 Daniel Jacobowitz <dan@codesourcery.com>
16125
16126 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
16127 (add_thread): Minor cleanups.
16128 (clear_inferiors): Move lower in the file. Clear the DLL
16129 list.
16130 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
16131 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
16132 (xml_escape_text): New.
16133 * server.c (handle_query): Handle qXfer:libraries:read. Report it
16134 for qSupported.
16135 (handle_v_cont): Report errors.
16136 (gdbserver_version): Update.
16137 (main): Correct size of own_buf. Do not report initial DLL events.
16138 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
16139 (unloaded_dll, xml_escape_text): New.
16140 * win32-low.c (enum target_waitkind): Update comments.
16141 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
16142 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
16143 (win32_EnumProcessModules, win32_GetModuleInformation)
16144 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
16145 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
16146 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
16147 (win32_Module32First, win32_Module32Next, load_toolhelp)
16148 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
16149 (get_child_debug_event): Handle DLL events.
16150 (win32_wait): Likewise.
16151
0d37add9
DJ
161522007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
16153
16154 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
16155 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
16156
45e2715e
PA
161572007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
16158
16159 * win32-low.c (handle_output_debug_string): Ignore event if not
16160 waiting.
16161
c5674cf1
PA
161622007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
16163
16164 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
16165
2bbe3cc1
DJ
161662007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
16167
16168 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
16169
ae13219e
DJ
161702007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
16171
16172 * inferiors.c (change_inferior_id): Add comment.
16173 * linux-low.c (check_removed_breakpoint): Add an early
16174 prototype. Improve debug output.
16175 (linux_attach): Doc update.
16176 (linux_detach_one_process, linux_detach): Clean up before releasing
16177 each process.
16178 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
16179 * linux-low.h (struct process_info): Doc improvement.
16180 * mem-break.c (delete_all_breakpoints): New.
16181 * mem-break.h (delete_all_breakpoints): New prototype.
16182 * thread-db.c (find_first_thread): New.
16183 (thread_db_create_event): Call it instead of
16184 thread_db_find_new_threads. Clean up unused variables.
16185 (maybe_attach_thread): Remove first thread handling.
16186 (thread_db_find_new_threads): Use find_first_thread.
16187 (thread_db_get_tls_address): Likewise.
16188
4105de34
DJ
161892007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
16190
16191 * thread-db.c (thread_db_find_new_threads): Add prototype.
16192 (thread_db_create_event): Check for the main thread before adding
16193 a new thread.
16194 (maybe_attach_thread): Only enable event reporting if TID == 0.
16195 (thread_db_get_tls_address): Check for new threads.
16196
2b876972
DJ
161972007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
16198
16199 * linux-low.c (linux_create_inferior): Try execv before execvp.
16200 * spu-low.c (spu_create_inferior): Likewise.
16201
7a245884
DJ
162022007-06-13 Mike Frysinger <vapier@gentoo.org>
16203
16204 * linux-low.c (linux_create_inferior): Change execv to execvp.
16205 * spu-low.c (spu_create_inferior): Likewies.
16206
117ce543
DJ
162072007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
16208
16209 * Makefile.in (clean): Clean new files instead of deleted ones.
16210 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
16211 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
16212 rules.
16213 * configure.srv: Specify XML files and new regformats for MIPS and
16214 MIPS64 GNU/Linux.
16215 * linux-mips-low.c (mips_num_regs): Set to only used registers.
16216 (mips_regmap): Do not fetch $0. Remove unused registers. Add
16217 an entry for the restart register.
16218 (mips_cannot_fetch_register, mips_cannot_store_register)
16219 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
16220 register names to match the XML descriptions.
16221 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
16222 restart register instead of $0.
16223
0e7f50da
UW
162242007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
16225 Markus Deuling <deuling@de.ibm.com>
16226
16227 * remote-utils.c (decode_xfer_write): New function.
16228 * server.h (decode_xfer_write): Add prototype.
16229 * server.c (handle_query): Add PACKET_LEN argument. Support
16230 qXfer:spu:read and qXfer:spu:write packets.
16231 (main): Pass packet_len to handle_query.
16232 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
16233 * target.h (target_ops): Add qxfer_spu.
16234
374c1d38
UW
162352007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
16236
16237 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
16238 accessing non-seekable spufs files.
16239
bb63802a
UW
162402007-05-16 Markus Deuling <deuling@de.ibm.com>
16241
889bf7c5 16242 * server.c (handle_query): Add reply for qC packet.
bb63802a 16243
7390519e
PA
162442007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16245 Leo Zayas <lerele@champenstudios@com>
16246
16247 * server.h (check_remote_input_interrupt_request): New function.
16248 * remote_utils.c (INVALID_DESCRIPTOR): New define.
16249 (remote_desc): Initialize with INVALID_DESCRIPTOR.
16250 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
16251 (check_remote_input_interrupt_request): New function.
16252 * server.h (check_remote_input_interrupt_request): Declare.
3ecf0694 16253 * win32-low.c (winapi_DebugBreakProcess,
7390519e
PA
16254 winapi_GenerateConsoleCtrlEvent): New typedefs.
16255 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
16256 to 250 ms.
16257 (win32_wait): Check for remote interrupt request
16258 with check_remote_input_interrupt_request.
16259 (win32_request_interrupt): New function.
16260 (win32_target_op): Set request_interrupt to win32_request_interrupt.
16261
34b34921
PA
162622007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16263
16264 * win32-low.c (debug_registers_changed,
16265 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
16266 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
16267 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
16268 (thread_rec): Get context using the low target.
16269 (child_add_thread): Call thread_added on the low target,
16270 which does the same thing.
16271 (regptr): Delete.
16272 (do_initial_child_stuff): Remove debug registers references.
16273 Set context using the low target. Resume threads after
16274 setting the contexts.
16275 (child_continue): Remove dead variable. Remove debug
16276 registers references.
16277 (child_fetch_inferior_registers): Go through the low target.
16278 (do_child_store_inferior_registers): Remove.
16279 (child_store_inferior_registers): Go through the low target.
16280 (win32_resume): Remove debug registers references.
16281 Set context using the low target.
16282 (handle_exception): Change return type to void. Don't record
16283 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
16284 first chance exception.
889bf7c5 16285 (get_child_debug_event): Change return type to void. Remove
34b34921
PA
16286 goto loop. Always return after waiting for debug event.
16287 (win32_wait): Convert to switch statement. Handle spurious
16288 events.
16289
16290 * win32-i386-low.c (debug_registers_changed,
16291 debug_registers_used): New.
16292 (initial_stuff): Rename to ...
16293 (i386_initial_stuff): ... this. Clear debug registers
16294 state variables.
16295 (store_debug_registers): Delete.
16296 (i386_get_thread_context): New.
16297 (load_debug_registers): Delete.
16298 (i386_set_thread_context): New.
16299 (i386_thread_added): New.
16300 (single_step): Rename to ...
16301 (i386_single_step): ... this.
16302 (do_fetch_inferior_registers): Rename to ...
16303 (i386_fetch_inferior_register): ... this.
16304 (i386_store_inferior_register): New.
16305 (the_low_target): Adapt to new interface.
16306
16307 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
16308 (arm_get_thread_context): New.
16309 (arm_set_thread_context): New.
16310 (regptr): New.
16311 (do_fetch_inferior_registers): Rename to ...
16312 (arm_fetch_inferior_register): ... this.
16313 (arm_store_inferior_register): New.
16314 (arm_wince_breakpoint): Reimplement as unsigned long.
16315 (arm_wince_breakpoint_len): Define.
16316 (the_low_target): Adapt to new interface.
16317
16318 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
16319 load_debug_registers. Add get_thread_context, set_thread_context,
16320 thread_added and store_inferior_register. Rename
16321 fetch_inferior_registers to fetch_inferior_register.
16322 (regptr): Remove declaration.
16323
dd6953e1
PA
163242007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16325
16326 * linux-low.c (linux_detach): Change return type to int. Return 0.
16327 * spu-low.c (spu_detach): Likewise.
16328
444d6139
PA
163292007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16330
16331 * target.h (target_ops): Change return type of detach to int.
16332 Add join.
16333 (join_inferior): New.
16334 * server.c (main): Don't skip detach support on mingw32.
16335 If the inferior doesn't support detaching return error.
16336 Call join_inferior instead of using waitpid.
16337 * linux-low.c (linux_join): New.
16338 (linux_target_op): Add linux_join.
16339 * spu-low.c (spu_join): New.
16340 (spu_target_ops): Add spu_join.
16341 * win32-low.c (win32_detach): Adapt to new interface.
16342 Reopen current_process_handle before detaching. Issue a child
16343 resume before detaching.
16344 (win32_join): New.
16345 (win32_target_op): Add win32_join.
16346
1d5315fe
PA
163472007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16348
16349 * win32-low.c (win32-attach): Fix return value.
16350 * target.h (target_ops): Describe ATTACH return values.
16351
bf914831
PA
163522007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16353
16354 * win32-low.c (GETPROCADDRESS): Define.
16355 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
16356 (winapi_DebugSetProcessKillOnExit): Likewise.
16357 (win32_create_inferior): Force usage of ansi CreateProcessA.
16358 (win32_attach): Use GETPROCADDRESS.
16359 (win32_detach): Likewise.
16360
f72f3e60
PA
163612007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16362
16363 * win32-low.c (win32_wait): Don't use WSTOPSIG.
16364
ed50f18f
PA
163652007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
16366
16367 * win32-low.c: Commit leftover changes from 2007-03-29.
16368
0c2ead7e
DJ
163692007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
16370
16371 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
16372 fields short instead of int. Add explicit padding.
16373 (i387_cache_to_fsave): Remove unnecessary casts.
16374 (i387_fsave_to_cache): Doc fix.
16375 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
16376
73725ff3
DJ
163772007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
16378
16379 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
16380 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
16381
d99f33d8
PA
163822007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
16383
16384 * configure.srv (arm*-*-mingw32ce*): Move near the other
16385 arm targets.
16386
68070c10
PA
163872007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
16388
2482afc6 16389 * configure.ac: Add errno checking.
68070c10
PA
16390 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
16391 sys/file.h and malloc.h.
16392 (AC_CHECK_DECLS): Add perror.
16393 (srv_mingwce): Handle.
2482afc6 16394 * configure.srv (i[34567]86-*-cygwin*): Add
68070c10
PA
16395 win32-i386-low.o to srv_tgtobj.
16396 (i[34567]86-*-mingw*): Likewise.
16397 (arm*-*-mingw32ce*): Add case.
16398 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
16399 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
16400 [__MINGW32CE__] (strerror): New function.
16401 [__MINGW32CE__] (errno): Define to GetLastError.
16402 [__MINGW32CE__] (COUNTOF): New macro.
16403 (remote_open): Remove extra close call.
16404 * mem-break.c (delete_breakpoint_at): New function.
16405 * mem-break.h (delete_breakpoint_at): Declare.
16406 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
16407 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
16408 [USE_WIN32API] (read, write): Add char* casts.
16409 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
16410 * server.h: Include wincecompat.h on Windows CE.
16411 [HAVE_ERRNO_H]: Check.
16412 (perror): Declare if not declared.
16413 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
16414 (perror_with_name): Remove errno declaration.
16415 * wincecompat.h: New.
16416 * wincecompat.c: New.
16417 * win32-low.h: New.
16418 * win32-arm-low.c: New.
16419 * win32-i386-low.c: New.
16420 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
16421 (OUTMSG2): Make it safe.
16422 (_T): New macro.
16423 (COUNTOF): New macro.
16424 (NUM_REGS): Get it from the low target.
16425 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
16426 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
16427 (thread_rec): Let low target handle debug registers.
16428 (child_add_thread): Likewise.
16429 (child_init_thread_list): Likewise.
16430 (continue_one_thread): Likewise.
16431 (regptr): New.
16432 (do_child_fetch_inferior_registers): Move to ...
16433 * win32-i386-low.c: ... here, and rename to ...
16434 (do_fetch_inferior_registers): ... this.
889bf7c5 16435 * win32-low.c (child_fetch_inferior_registers):
68070c10
PA
16436 Go through the low target.
16437 (do_child_store_inferior_registers): Use regptr.
16438 (strwinerror): New function.
16439 (win32_create_inferior): Handle Windows CE.
16440 Use strwinerror instead of strerror on Windows error
16441 codes. Add program to the error output.
16442 Don't close the main thread handle on Windows CE.
16443 (win32_attach): Use coredll.dll on Windows CE.
16444 (win32_kill): Close current process and current
16445 thread handles.
16446 (win32_detach): Use coredll.dll on Windows CE.
16447 (win32_resume): Let low target handle debug registers, and
16448 step request.
16449 (handle_exception): Add/Remove initial breakpoint. Avoid
16450 non-existant WSTOPSIG on Windows CE.
16451 (win32_read_inferior_memory): Cast to remove warning.
16452 (win32_arch_string): Go through the low target.
16453 (initialize_low): Call set_breakpoint_data with the low
16454 target's breakpoint.
16455 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
16456 FOP_REGNUM, mappings): Move to ...
16457 * win32-i386-low.c: ... here.
16458 * win32-low.c (win32_thread_info): Move to ...
16459 * win32-low.h: ... here.
16460 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
16461 win32-arm-low.c and wincecompat.c.
16462 (all:): Add $EXEEXT.
16463 (install-only:): Likewise.
16464 (gdbserver:): Likewise.
16465 (gdbreplay:): Likewise.
16466 * config.in: Regenerate.
16467 * configure: Regenerate.
16468
41093d81
PA
164692007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
16470
16471 * win32-low.c: Rename typedef thread_info to
16472 win32_thread_info throughout.
16473
544afa54
PA
164742007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
16475
16476 * win32-i386-low.c: Rename to ...
16477 * win32-low.c: ... this.
16478 * configure.srv: Replace win32-i386-low.o with win32-low.o.
16479 * Makefile.in: Likewise.
16480
bce7165d
PA
164812007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
16482
16483 * remote-utils.c (monitor_output): Constify msg parameter.
16484 * server.h (monitor_output): Likewise.
16485 * win32-i386-low.c (handle_output_debug_string): New.
16486 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
16487 handle_output_debug_string.
16488 (get_child_debug_event): Likewise.
16489
506c7aa0
DJ
164902007-03-27 Mat Hostetter <mat@lcs.mit.edu>
16491
16492 * server.c (main): Correct strtoul check.
16493
42c81e2a
DJ
164942007-03-27 Jon Ringle <jon@ringle.org>
16495
16496 * linux-low.c: Check __ARCH_HAS_MMU__ also.
16497
9453113a
DJ
164982007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
16499
16500 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
16501
64a69107
DJ
165022007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
16503
16504 * terminal.h: Check HAVE_SGTTY_H.
16505
165062007-02-27 Mat Hostetter <mat@lcs.mit.edu>
6f8486da
DJ
16507
16508 * remote-utils.c (remote_open): Print out the assigned port number.
16509
c74d0ad8
DJ
165102007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
16511
16512 * remote-utils.c (monitor_output): New function.
16513 * server.c (debug_threads): Define here.
16514 (monitor_show_help): New function.
16515 (handle_query): Handle qRcmd.
16516 (main): Do not handle 'd' packet.
16517 * server.h (debug_threads, remote_debug, monitor_output): Declare.
16518 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
16519 of debug_threads.
16520
de7c3b4a
PA
165212007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16522
16523 * Makefile.in (EXEEXT): New.
16524 (clean): Use $(EXEEXT).
16525
ef57601b
PA
165262007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16527
16528 * target.h (target_ops): Rename send_signal to request_interrupt,
16529 and remove enum target_signal parameter.
16530 * linux-low.c (linux_request_interrupt): Rename from
16531 linux_send_signal, and always send SIGINT.
16532 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
16533 and always send SIGINT.
16534 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
16535 of send_signal.
16536 (input_interrupt): Likewise.
16537
820f2bda
PA
165382007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16539
16540 * server.c (get_features_xml): Check if target implemented
16541 arch_string.
16542 * win32-i386-low.c (win32_arch_string): New.
16543 (win32_target_ops): Add win32_arch_string as arch_string member.
16544
ab39bf24
UW
165452007-02-22 Markus Deuling <deuling@de.ibm.com>
16546
16547 * spu-low.c (spu_arch_string): New.
16548 (spu_target_ops): Add spu_arch_string.
16549
61ff6e04
DJ
165502007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
16551
16552 * remote-utils.c: Remove HAVE_TERMINAL_H check.
16553 * configure.ac: Do not check for terminal.h.
16554 * configure, config.in: Regenerated.
16555
fb1e4ffc
DJ
165562007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
16557
16558 * Makefile.in (OBS): Add $(XML_BUILTIN).
16559 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
16560 (clean): Update.
16561 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
16562 (arm-with-iwmmxt.c): New.
16563 * config.in, configure: Regenerate.
16564 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
16565 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
16566 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
16567 (arm*-*-linux*): Add iWMMXt and regset support.
16568 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
16569 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
16570 (arm_store_wmmxregset, target_regsets): New.
16571 * server.c (get_features_xml): Take annex argument. Check builtin
16572 XML documents.
16573 (handle_query): Handle multiple annexes.
16574
0f48aa01
DJ
165752007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
16576
16577 * remote-utils.c [USE_WIN32API] (read, write): Define.
16578 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
16579 write.
16580
23181151
DJ
165812007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
16582
16583 * linux-i386-low.c (the_low_target): Set arch_string.
16584 * linux-x86-64-low.c (the_low_target): Likewise.
16585 * linux-low.c (linux_arch_string): New.
16586 (linux_target_ops): Add it.
16587 * linux-low.h (struct linux_target_ops): Add arch_string.
16588 * server.c (write_qxfer_response): Use const void * for DATA.
16589 (get_features_xml): New.
16590 (handle_query): Handle qXfer:features:read. Report it for qSupported.
16591 * target.h (struct target_ops): Add arch_string method.
16592
9d606399
DJ
165932007-01-03 Denis Pilat <denis.pilat@st.com>
16594 Daniel Jacobowitz <dan@codesourcery.com>
16595
16596 * linux-low.c (linux_kill): Handle being called with no threads.
16597 * win32-i386-low.c (win32_kill): Likewise.
16598 (get_child_debug_event): Clear current_process_handle.
16599
166002006-12-30 Denis PILAT <denis.pilat@st.com>
8264bb58
DJ
16601 Daniel Jacobowitz <dan@codesourcery.com>
16602
16603 * remote-utils.c (remote_open): Check the type of specified
16604 serial port devices before opening them.
16605 * server.c (main): Kill the inferior if an error occurs during
16606 the first remote_open.
16607
a5e13d24
DJ
166082006-12-05 Markus Deuling <deuling@de.ibm.com>
16609
16610 * README: Update supported targets.
16611
186947f7
DJ
166122006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
16613
16614 * Makefile.in (clean): Remove reg-mips64.c.
16615 (reg-mips64.c, reg-mips64.o): New rules.
16616 * configure.srv: Handle mips64. Include regset support for mips.
16617 * linux-mips-low.c (union mips_register): New.
16618 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
16619 (mips_breakpoint, mips_breakpoint_at): Use int.
16620 (mips_collect_register, mips_supply_register)
16621 (mips_collect_register_32bit, mips_supply_register_32bit)
16622 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
16623 (mips_store_fpregset, target_regsets): New.
16624 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
16625
a13e2c95
UW
166262006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
16627
16628 * configure.srv: Add target "spu*-*-*".
16629 * Makefile.in (clean): Remove reg-spu.c.
16630 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
16631 * spu-low.c: New file.
16632
cb7283db
DJ
166332006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
16634
16635 * configure.ac: Correct td_thr_tls_get_addr test.
16636 * configure: Regenerated.
16637
89be2091
DJ
166382006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
16639
16640 * linux-low.c (linux_wait_for_event): Reformat. Use the
16641 pass_signals array.
16642 * remote-utils.c (decode_address_to_semicolon): New.
16643 * server.c (pass_signals, handle_general_set): New.
16644 (handle_query): Mention QPassSignals for qSupported.
16645 (main): Call handle_general_set.
16646 * server.h (pass_signals, decode_address_to_semicolon): New.
16647
000ef4f0
DJ
166482006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
16649
16650 * server.c (handle_query): Correct error handling for read_auxv.
16651
b7149293
UW
166522005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
16653
16654 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
16655 and srv_linux_thread_db to yes.
16656 * linux-s390-low.c (s390_fill_gregset): New function.
16657 (target_regsets): Define data structure.
16658
dae5f5cf
DJ
166592006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
16660
16661 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
16662 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
16663 * config.in, configure: Regenerated.
16664 * inferiors.c (gdb_id_to_thread): New function.
16665 (gdb_id_to_thread_id): Use it.
16666 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
16667 * linux-low.h (struct process_info): Add th member.
16668 (thread_db_get_tls_address): New prototype.
16669 * remote-utils.c (decode_address): Make non-static.
16670 * server.c (handle_query): Handle qGetTLSAddr.
16671 * server.h (gdb_id_to_thread, decode_address): New prototypes.
16672 * target.h (struct target_ops): Add get_tls_address.
16673 * thread-db.c (maybe_attach_thread): Save the thread handle.
16674 (thread_db_get_tls_address): New.
16675
32ca6d61
DJ
166762006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
16677
16678 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
16679 (linux_resume_one_process): Take a siginfo_t *. Update all
16680 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
16681 (struct pending_signals): Add a siginfo_t.
16682 (linux_wait_for_process): Always set last_status.
16683 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
16684 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
16685 * linux-low.h (struct process_info): Add last_status.
16686
5ffff7c1
DJ
166872006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
16688
16689 * remote-utils.c (try_rle): New function.
16690 (putpkt_binary): Use it.
16691
8695c747
DJ
166922006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
16693
16694 * Makefile.in (clean): Clean reg-x86-64-linux.c.
16695 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
16696 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
16697 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
16698 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
16699 point registers.
16700
290fadea
RS
167012006-08-08 Richard Sandiford <richard@codesourcery.com>
16702
16703 * server.c (terminal_fd): New variable.
16704 (old_foreground_pgrp): Likewise.
16705 (restore_old_foreground_pgrp): New function.
16706 (start_inferior): Record the terminal file descriptor in terminal_fd
16707 and its original foreground group in old_foreground_pgrp. Register
16708 restore_old_foreground_pgrp with atexit().
16709
9f2e1e63
DJ
167102006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
16711
16712 * server.c (handle_query): Correct qPart to qXfer.
16713
b80864fb
DJ
167142006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
16715
16716 * configure.ac: Check for more headers which are missing on
16717 Windows. Automatically supply -lwsock32 and USE_WIN32API.
16718 * configure.srv: Add Cygwin and mingw32.
16719 * remote-utils.c: Don't include headers unconditionally which
16720 are missing on mingw32. Include <winsock.h> for mingw32.
16721 (remote_open): Adjust for mingw32 support. Flush
16722 standard error after writing to it.
16723 (remote_close, putpkt_binary, input_interrupt, block_async_io)
16724 (unblock_async_io, enable_async_io, disable_async_io)
16725 (readchar, getpkt): Update for Winsock support.
16726 (prepare_resume_reply): Expect a protocol signal number.
16727 * server.c: Disable <sys/wait.h> on mingw32.
16728 (start_inferior): Adjust for mingw32 support. Flush
16729 standard error after writing to it.
16730 (attach_inferior): Likewise. Use protocol signal
16731 numbers.
16732 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
16733 and names.
16734 * win32-i386-low.c: New file.
16735 * Makefile.in (XM_CLIBS): Set.
16736 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
16737 (win32-i386-low.o): New dependency rule.
16738 * linux-low.c (linux_wait): Use target signal numbers.
16739 * target.h (struct target_ops): Doc fix.
16740 * server.h (target_signal_to_name): New prototype.
16741 * gdbreplay.c: Don't include headers unconditionally which
16742 are missing on mingw32. Include <winsock.h> for mingw32.
16743 (remote_close, remote_open): Adjust for Winsock support.
16744 * configure, config.in: Regenerated.
16745
0876f84a
DJ
167462006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
16747
16748 * server.c (decode_xfer_read, write_qxfer_response): New.
16749 (handle_query): Take a packet length argument. Handle
16750 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
16751 the qSupported response.
16752 (main): Update call to handle_query.
16753
01f9e8fa
DJ
167542006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
16755
16756 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
16757 (putpkt_binary): Renamed from putpkt and adjusted for binary
16758 data.
16759 (putpkt): New wrapper for putpkt_binary.
16760 (readchar): Don't mask off the high bit.
16761 (decode_X_packet): New function.
16762 * server.c (main): Call putpkt_binary if a handler sets the packet
16763 length. Save the length of the incoming packet. Handle 'X'.
16764 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
16765
be2a5f71
DJ
167662006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
16767
16768 * server.c (handle_query): Handle qSupported.
16769
ea025f5f
DJ
167702006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
16771
16772 * remote-utils.c (all_symbols_looked_up): New variable.
16773 (look_up_one_symbol): Check it.
16774 * server.h (look_up_one_symbol): New declaration.
16775 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
16776
9308fc88
DJ
167772006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
16778
16779 * Makefile.in (linux-arm-low.o): Update dependencies.
66f338c7 16780 * linux-arm-low.c: Include "gdb_proc_service.h".
9308fc88
DJ
16781 (PTRACE_GET_THREAD_AREA): Define.
16782 (ps_get_thread_area): New function.
16783
52fb6437
NS
167842006-05-09 Nathan Sidwell <nathan@codesourcery.com>
16785
16786 * configure.srv (m68k*-*-uclinux*): New target.
16787 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
16788 (linux_resume_one_process): Remove extraneous cast.
16789 (linux_read_offsets): New.
16790 (linux_target_op): Add linux_read_offsets on mmuless systems.
16791 * server.c (handle_query): Add qOffsets logic.
16792 * target.h (struct target_ops): Add read_offsets.
16793
21b0f40c
DJ
167942006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
16795
16796 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
16797 (PTRACE_GET_THREAD_AREA): Define.
16798 (ps_get_thread_area): New function.
16799 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
16800 (linux-x86-64-low.o): Update.
16801
0050a760
DJ
168022006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
16803
16804 * configure.ac: Remove checks for prfpregset_t.
16805 * gdb_proc_service.h: New file.
16806 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
16807 new "gdb_proc_service.h".
16808 * proc-service.c: Likewise.
16809 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
16810 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
16811 * Makefile.in (gdb_proc_service_h): Updated.
16812 * configure, config.in: Regenerated.
16813
b92a518e
DJ
168142006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
16815
16816 * remote-utils.c (prepare_resume_reply): Move declaration
16817 of gdb_id_from_wait to the top of the block.
16818
545587ee
DJ
168192006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
16820
16821 * linux-low.c (regsets_store_inferior_registers): Read the regset
16822 from the target before filling it.
16823
9db87ebd
DJ
168242006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
16825
16826 * server.c (attach_inferior): Return SIGTRAP for a successful
16827 attach.
16828
dd24457d
DJ
168292006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
16830
16831 * Makefile.in (OBS): Add version.o.
16832 (STAGESTUFF): Delete.
16833 (version.o): Add dependencies.
16834 (version.c): Replace rule.
16835 (clean): Remove version.c.
16836 * server.c (gdbserver_version): New.
16837 (gdbserver_usage): Use printf.
16838 (main): Handle --version and --help.
16839 * server.h (version, host_name): Add declarations.
16840
6f0f660e
EZ
168412005-12-23 Eli Zaretskii <eliz@gnu.org>
16842
889bf7c5
PA
16843 * linux-arm-low.c:
16844 * linux-arm-low.c:
16845 * inferiors.c:
16846 * i387-fp.h:
16847 * i387-fp.c:
16848 * gdbreplay.c:
16849 * regcache.c:
16850 * proc-service.c:
16851 * mem-break.h:
16852 * mem-break.c:
16853 * linux-x86-64-low.c:
16854 * linux-sh-low.c:
16855 * linux-s390-low.c:
16856 * linux-ppc64-low.c:
16857 * linux-ppc-low.c:
16858 * linux-mips-low.c:
16859 * linux-m68k-low.c:
16860 * linux-m32r-low.c:
16861 * linux-low.h:
16862 * linux-low.c:
16863 * linux-ia64-low.c:
16864 * linux-i386-low.c:
16865 * linux-crisv32-low.c:
16866 * thread-db.c:
16867 * terminal.h:
16868 * target.h:
16869 * target.c:
16870 * server.h:
16871 * server.c:
16872 * remote-utils.c:
16873 * regcache.h:
16874 * utils.c:
16875 * Makefile.in:
16876 * configure.ac:
6f0f660e
EZ
16877 * gdbserver.1: Add (C) after Copyright. Update the FSF
16878 address.
16879
9d1fb177
DJ
168802005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
16881
16882 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
16883 (arm_breakpoint_at): Recognize both breakpoints.
16884 (the_low_target): Use the correct breakpoint instruction.
16885
011a70c2
DJ
168862005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
16887
16888 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
16889 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
16890 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
16891 (the_low_target): Update.
16892
7fb85e41
AS
168932005-10-25 Andreas Schwab <schwab@suse.de>
16894
16895 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
16896
16897 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
16898 (ia64_num_regs): Reduce to 462.
16899
3db0444b
DJ
169002005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
16901
16902 * acinclude.m4: Correct quoting.
16903 * aclocal.m4: Regenerated.
16904
16905 Suggested by SZOKOVACS Robert <szo@ies.hu>:
16906 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
16907 (thread_db_init): Call thread_db_err_str.
16908 * configure.ac: Check for TD_VERSION.
16909 * config.in, configure: Regenerated.
16910
bee0189a
DJ
169112005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16912
16913 * server.h (error, fatal, warning): Add ATTR_FORMAT.
16914
e9d25b98
DJ
169152005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16916
16917 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
16918 is not available. Define HAVE_PTRACE_GETREGS if it is.
16919 * config.in, configure: Regenerated.
16920 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
16921 * linux-i386-low.c, linux-m68k-low.c: Update to use
16922 HAVE_PTRACE_GETREGS.
16923 * linux-low.c (regsets_fetch_inferior_registers)
16924 (regsets_store_inferior_registers): Only return 0 if we processed
16925 GENERAL_REGS.
16926 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
16927 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
16928
a06660f7
DJ
169292005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16930
16931 * inferiors.c (struct thread_info): Add gdb_id.
16932 (add_thread): Add gdb_id argument.
16933 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
16934 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
16935 calls to add_thread.
16936 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
16937 * server.c (handle_query): Use thread_to_gdb_id.
16938 (handle_v_cont, main): Use gdb_id_to_thread_id.
16939 * server.h (add_thread): Update prototype.
16940 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
16941 prototypes.
16942
5a1f5858
DJ
169432005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16944
16945 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
16946 left-padded registers.
16947 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
16948 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
16949
e122f1f5
SE
169502005-07-01 Steve Ellcey <sje@cup.hp.com>
16951
16952 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
16953 * configure: Regenerate.
16954 * config.in: Regenerate.
16955 * server.h (NEED_DECLARATION_STRERROR):
16956 Replace with !HAVE_DECL_STRERROR.
16957
d592fa2f
DJ
169582005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
16959
16960 * linux-low.c (linux_wait, linux_send_signal): Don't test
16961 an unsigned long variable for > 0 if it could be MAX_ULONG.
16962 * server.c (myresume): Likewise.
16963 * target.c (set_desired_inferior): Likewise.
16964
ccbd4912
MK
169652005-06-13 Mark Kettenis <kettenis@gnu.org>
16966
16967 * configure.ac: Simplify and improve check for socklen_t.
16968 * configure, config.in: Regenerate.
16969
f450004a
DJ
169702005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
16971
16972 * acconfig.h: Remove.
16973 * configure.ac: Add a test for socklen_t. Use three-argument
16974 AC_DEFINE throughout.
16975 * config.in: Regenerated using autoheader 2.59.
16976 * configure: Regenerated.
16977
16978 * gdbreplay.c (socklen_t): Provide a default.
16979 (remote_open): Use socklen_t.
16980 * remote-utils.c (socklen_t): Provide a default.
16981 (remote_open): Use socklen_t.
16982 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
16983 unsigned char.
16984
16985 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
16986 char for buffers.
16987 * linux-low.c (linux_read_memory, linux_write_memory)
16988 (linux_read_auxv): Likewise.
16989 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
16990 (check_mem_write): Likewise.
16991 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
16992 Likewise.
16993 * regcache.c (struct inferior_rgcache_data, registers_to_string)
16994 (registers_from_string, register_data): Likewise.
16995 * server.c (handle_query, main): Likewise.
16996 * server.h (convert_ascii_to_int, convert_int_to_ascii)
16997 (decode_M_packet): Likewise.
16998 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
16999 * target.h (struct target_ops): Update read_memory, write_memory,
17000 and read_auxv.
17001 (read_inferior_memory, write_inferior_memory): Update.
17002 * linux-low.h (struct linux_target_ops): Change type of breakpoint
17003 to unsigned char *.
17004 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
17005 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
17006 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
17007 linux-s390-low.c, linux-sh-low.c: Update for changes in
17008 read_inferior_memory and the_low_target->breakpoint.
17009
eee84df1
DJ
170102005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
17011
17012 * Makefile.in (SFILES): Add linux-ppc64-low.c.
17013 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
17014 * configure.srv: Add powerpc64-*-linux*.
17015 * linux-ppc64-low.c: New file.
17016
45b134e5
OF
170172005-05-23 Orjan Friberg <orjanf@axis.com>
17018
17019 * linux-cris-low.c: New file with support for CRIS.
17020 * linux-crisv32-low.c: Ditto for CRISv32.
17021 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
17022 (clean): Add reg-cris.c and reg-crisv32.c.
889bf7c5 17023 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
45b134e5
OF
17024 reg-crisv32.o, and reg-crisv32.c to make rules.
17025 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
17026 recognized targets.
17027
48d93c75
UW
170282005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
17029
17030 * linux-low.c (fetch_register): Ensure buffer size is a multiple
17031 of sizeof (PTRACE_XFER_TYPE).
17032 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
17033
e013ee27
OF
170342005-05-12 Orjan Friberg <orjanf@axis.com>
17035
889bf7c5 17036 * target.h (struct target_ops): Add insert_watchpoint,
e013ee27
OF
17037 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
17038 pointers for hardware watchpoint support.
17039 * linux-low.h (struct linux_target_ops): Ditto.
17040 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
17041 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
17042 to linux_target_ops.
17043 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
17044 reply packet.
17045 * server.c (main): Recognize 'Z' and 'z' packets.
17046
b0ded00b
UW
170472005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
17048
17049 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
17050 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
17051 (the_low_target): Add new members.
17052
8643e2ad
DJ
170532005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
17054
17055 * proc-service.c (ps_lgetregs): Search all_processes instead of
17056 all_threads.
17057
fc620387
DJ
170582005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
17059
17060 * server.c (start_inferior): Change return type to int.
17061 (attach_inferior): Change sigptr to int *.
17062 (handle_v_cont, handle_v_requests): Change signal to int *.
17063 (main): Change signal to int.
17064
170652005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
7cfbc4a0
KI
17066
17067 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
17068 * configure.srv: Add m32r*-*-linux*.
17069 * linux-m32r-low.c: New file.
17070
e0e76420
DJ
170712005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
17072
17073 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
17074
a1928bad
DJ
170752005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
17076
17077 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
17078 Take unsigned long arguments for PIDs.
17079 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
17080 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
17081 (wait_for_sigstop, linux_resume_one_process)
17082 (regsets_fetch_inferior_registers, linux_send_signal)
17083 (linux_read_auxv): Likewise. Update the types of variables holding
17084 PIDs. Update format string specifiers.
17085 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
17086 * remote-utils.c (prepare_resume_reply): Likewise.
17087 * server.c (cont_thread, general_thread, step_thread)
17088 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
17089 unsigned long.
17090 (handle_query): Update format specifiers.
17091 (handle_v_cont, main): Use strtoul for thread IDs.
17092 * server.h (struct inferior_list_entry): Use unsigned long for ID.
17093 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
17094 (general_thread, step_thread, thread_from_wait)
17095 (old_thread_from_wait): Update.
17096 * target.h (struct thread_resume): Use unsigned long for THREAD.
17097 (struct target_ops): Use unsigned long for arguments to attach and
17098 thread_alive.
17099
dcdb98d2
DJ
171002005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
17101
17102 * acinclude.m4: Include bfd/bfd.m4 directly.
17103 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
17104 <agriffis@toolchain.org>.
17105 * aclocal.m4, configure: Regenerated.
17106
bec39cab
AC
171072005-01-07 Andrew Cagney <cagney@gnu.org>
17108
17109 * configure.ac: Rename configure.in, require autoconf 2.59.
17110 * configure: Re-generate.
17111
434c4c77
DJ
171122004-12-08 Daniel Jacobowitz <dan@debian.org>
17113
17114 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
17115 LIBS when finished.
17116 * aclocal.m4: Regenerated.
17117 * configure: Regenerated.
17118
db1d3e1b
AS
171192004-11-21 Andreas Schwab <schwab@suse.de>
17120
17121 * linux-m68k-low.c (m68k_num_gregs): Define.
17122 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
17123 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
17124 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
17125 (m68k_breakpoint_at): New. Add to the_low_target.
17126
17127 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
17128 srv_linux_thread_db to yes.
17129
43360365
JB
171302004-10-20 Joel Brobecker <brobecker@gnat.com>
17131
17132 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
17133 (ARCH_SET_FS): Likewise.
17134 (ARCH_GET_FS): Likewise.
17135 (ARCH_GET_GS): Likewise.
17136
fd500816
DJ
171372004-10-16 Daniel Jacobowitz <dan@debian.org>
17138
17139 * linux-i386-low.c (ps_get_thread_area): New.
17140 * linux-x86-64-low.c (ps_get_thread_area): New.
17141 * linux-low.c: Include <sys/syscall.h>.
17142 (linux_kill_one_process): Don't kill the first thread here.
17143 (linux_kill): Kill the first thread here.
17144 (kill_lwp): New function.
17145 (send_sigstop, linux_send_signal): Use it.
17146 * proc-service.c: Clean up #ifdefs.
17147 (fpregset_info): Delete.
17148 (ps_lgetregs): Update and enable implementation.
17149 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
17150 implementations.
17151 * remote-utils.c (struct sym_cache, symbol_cache): New.
17152 (input_interrupt): Print a clearer message.
17153 (async_io_enabled): New variable.
17154 (enable_async_io, disable_async_io): Use it. Update comments.
17155 (look_up_one_symbol): Use the symbol cache.
17156 * thread-db.c (thread_db_look_up_symbols): New function.
17157 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
17158
f6de3c42
DJ
171592004-10-16 Daniel Jacobowitz <dan@debian.org>
17160
17161 * configure.in: Test for -rdynamic.
17162 * configure: Regenerated.
17163 * Makefile (INTERNAL_LDFLAGS): New.
17164 (gdbserver, gdbreplay): Use it.
17165
2c0fc042
AC
171662004-09-02 Andrew Cagney <cagney@gnu.org>
17167
17168 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
17169
075b3282
DJ
171702004-03-23 Daniel Jacobowitz <drow@mvista.com>
17171
17172 * linux-low.c (linux_wait): Clear all_processes list also.
17173
fa6a77dc
DJ
171742004-03-12 Daniel Jacobowitz <drow@mvista.com>
17175
17176 * linux-low.c: Include <errno.h>. Remove extern declaration of
17177 errno.
17178
6d782a97
DJ
171792004-03-12 Daniel Jacobowitz <drow@mvista.com>
17180
17181 * gdbreplay.c, server.h, utils.c: Update copyright years.
17182
3a7fb99b
DJ
171832004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
17184
17185 * server.c (main): Print child status or termination signal from
17186 variable 'signal', not 'sig'.
17187
c3e735a6
DJ
171882004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
17189
17190 * linux-low.c (linux_read_memory): Change return type to
17191 int. Check for and return error from ptrace().
17192 * target.c (read_inferior_memory): Change return type to int. Pass
17193 back return status from the_target->read_memory().
17194 * target.h (struct target_ops): Adapt *read_memory() prototype.
17195 Update comment.
17196 (read_inferior_memory): Adapt prototype.
17197 * server.c (main): Return an error packet if
17198 read_inferior_memory() returns an error.
17199
a59d1c82
DJ
172002004-03-04 Daniel Jacobowitz <drow@mvista.com>
17201
17202 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
17203 Unify with other clean targets.
17204
dc3f8883
DJ
172052004-02-29 Daniel Jacobowitz <drow@mvista.com>
17206
17207 * server.c (handle_v_cont): Call set_desired_inferior.
17208
89a208da
DJ
172092004-02-29 Daniel Jacobowitz <drow@mvista.com>
17210
17211 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
17212
62ea82f5
DJ
172132004-02-29 Daniel Jacobowitz <drow@mvista.com>
17214
17215 * linux-low.c (linux_wait): Unblock async I/O.
17216 (linux_resume): Block and enable async I/O.
17217 * remote-utils.c (block_async_io, unblock_async_io): New functions.
17218 * server.h (block_async_io, unblock_async_io): Add prototypes.
17219
6910d122
DJ
172202004-02-29 Daniel Jacobowitz <drow@mvista.com>
17221
17222 * remote-utils.c (remote_open): Print a status notice after
17223 opening a TCP port.
17224 * server.c (attach_inferior): Print a status notice after
17225 attaching.
17226
172272004-02-29 Daniel Jacobowitz <drow@mvista.com>
d677d77d
DJ
17228
17229 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
17230
c89dc5d4
DJ
172312004-02-26 Daniel Jacobowitz <drow@mvista.com>
17232
17233 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
17234 error packet.
17235 * server.c, target.h: Update copyright years.
17236
4b8dad4a
RM
172372004-02-25 Roland McGrath <roland@redhat.com>
17238
17239 * target.h (struct target_ops): New member `read_auxv'.
17240 * server.c (handle_query): Handle qPart:auxv:read: query using that.
17241 * linux-low.c (linux_read_auxv): New function.
17242 (linux_target_ops): Initialize `read_auxv' member to that.
17243
d7446758
JB
172442004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
17245
17246 Committed by Jim Blandy <jimb@redhat.com>.
17247
17248 * linux-s390-low.c (s390_num_regs): Update.
4b8dad4a 17249 (s390_regmap): Remove control registers. Use __s390x__ predefine
d7446758
JB
17250 instead of GPR_SIZE to distiguish s390 and s390x targets.
17251
5544ad89
DJ
172522004-01-31 Daniel Jacobowitz <drow@mvista.com>
17253
17254 * linux-low.c: Update copyright year.
17255 (check_removed_breakpoint): Clear pending_is_breakpoint.
17256 (linux_set_resume_request, linux_queue_one_thread)
17257 (resume_status_pending_p): New functions.
17258 (linux_continue_one_thread): Use process->resume.
17259 (linux_resume): Only resume threads if there are no pending events.
17260 * linux-low.h (struct process_info): Add resume request
17261 pointer.
17262
2a68b70e
DJ
172632004-01-30 Daniel Jacobowitz <drow@mvista.com>
17264
17265 * regcache.c (new_register_cache): Clear the allocated register
17266 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
17267
64386c31
DJ
172682003-10-13 Daniel Jacobowitz <drow@mvista.com>
17269
17270 * linux-low.c (linux_resume): Take a struct thread_resume *
17271 argument.
17272 (linux_wait): Update call.
17273 (resume_ptr): New static variable.
17274 (linux_continue_one_thread): Renamed from
17275 linux_continue_one_process. Use resume_ptr.
17276 (linux_resume): Use linux_continue_one_thread.
17277 * server.c (handle_v_cont, handle_v_requests): New functions.
17278 (myresume): New function.
17279 (main): Handle 'v' case.
17280 * target.h (struct thread_resume): New type.
17281 (struct target_ops): Change argument of "resume" to struct
17282 thread_resume *.
17283 (myresume): Delete macro.
17284
c938e9b0
L
172852003-08-08 H.J. Lu <hongjiu.lu@intel.com>
17286
17287 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
17288 (uninstall): Support DESTDIR.
17289
7f313d07
BC
17290Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
17291
17292 * configure.srv: Add xscale*linux copy of arm*linux entry.
17293
3b2fc2ea
DJ
172942003-07-24 Daniel Jacobowitz <drow@mvista.com>
17295
17296 * linux-arm-low.c (arm_reinsert_addr): New function.
17297 (the_low_target): Add arm_reinsert_addr.
17298
1c0a559e
MK
172992003-07-08 Mark Kettenis <kettenis@gnu.org>
17300
17301 * mem-break.c: Remove whitespace at end of file.
17302
43d5792c
DJ
173032003-06-28 Daniel Jacobowitz <drow@mvista.com>
17304
17305 * configure.in: Check whether we need to prototype strerror.
17306 * server.h: Optionally prototype strerror.
17307 * gdbreplay.c (perror_with_name): Use strerror.
17308 * linux-low.c (linux_attach_lwp): Use strerror.
17309 * utils.c (perror_with_name): Use strerror.
17310 * config.in, configure: Regenerated.
17311
c8a86edf
DJ
173122003-06-28 Daniel Jacobowitz <drow@mvista.com>
17313
17314 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
17315 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
17316
73d37363
DJ
173172003-06-20 Daniel Jacobowitz <drow@mvista.com>
17318
17319 * Makefile.in (SFILES): Update.
17320 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
17321 low-sun3.c: Remove files.
17322
6ad8ae5c
DJ
173232003-06-17 Daniel Jacobowitz <drow@mvista.com>
17324
17325 * linux-low.c: Move comment to linux_thread_alive where it belonged.
17326 (linux_detach_one_process, linux_detach): New functions.
17327 (linux_target_ops): Add linux_detach.
17328 * server.c (main): Handle 'D' packet.
17329 * target.h (struct target_ops): Add "detach" member.
17330 (detach_inferior): Define.
17331
1581182a
MK
173322003-06-13 Mark Kettenis <kettenis@gnu.org>
17333
17334 From Kelley Cook <kelleycook@wideopenwest.com>:
17335 * configure.srv: Accept i[34567]86 variants.
17336
e5379b03
DJ
173372003-06-05 Daniel Jacobowitz <drow@mvista.com>
17338
17339 * linux-low.c (linux_wait_for_event): Correct comment typos.
17340 (linux_resume_one_process): Call check_removed_breakpoint.
17341 (linux_send_signal): New function.
17342 (linux_target_ops): Add linux_send_signal.
17343 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
17344 of kill.
17345 * target.h (struct target_ops): Add send_signal.
17346
2ff29de4
JB
173472003-05-29 Jim Blandy <jimb@redhat.com>
17348
17349 * linux-low.c (usr_store_inferior_registers): Transfer buf in
17350 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
17351 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
17352 away part of the register's value.
17353
254787d4
DJ
173542003-03-26 Daniel Jacobowitz <drow@mvista.com>
17355
17356 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
17357 (linux_wait_for_event, linux_init_signals): Likewise.
17358
94e10508
DJ
173592003-03-17 Daniel Jacobowitz <drow@mvista.com>
17360
17361 * configure.in: Check for stdlib.h.
17362 * configure: Regenerated.
17363 * config.in: Regenerated.
17364
4c0711e0
DJ
173652003-01-04 Andreas Schwab <schwab@suse.de>
17366
17367 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
17368
ef66e766
AC
173692003-01-02 Andrew Cagney <ac131313@redhat.com>
17370
17371 * Makefile.in: Remove obsolete code.
17372
a1358604
DJ
173732002-11-20 Daniel Jacobowitz <drow@mvista.com>
17374
17375 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
17376 defined(PT_FPR0_HI).
17377
23ce3b1c
DJ
173782002-11-17 Stuart Hughes <seh@zee2.com>
17379
17380 * linux-arm-low.c (arm_num_regs): Increase.
17381 (arm_regmap): Include status register.
17382
173832002-11-17 Daniel Jacobowitz <drow@mvista.com>
17384
17385 * linux-low.c (register_addr): Remove incorrect -1 check.
17386
a9fa9f7d
DJ
173872002-08-29 Daniel Jacobowitz <drow@mvista.com>
17388
17389 * linux-low.c (linux_create_inferior): Call setpgid. Return
17390 the new PID.
17391 (unstopped_p, linux_signal_pid): Remove.
17392 (linux_target_ops): Remove linux_signal_pid.
17393 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
17394 global instead of target method.
17395 * target.h (struct target_ops): Remove signal_pid. Update comment
17396 for create_inferior.
17397 * server.c (signal_pid): New variable.
17398 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
4b8dad4a 17399 gdbserver. Set the child to be the foreground process group.
a9fa9f7d
DJ
17400 (attach_inferior): Set signal_pid.
17401
17574093
DJ
174022002-08-23 Daniel Jacobowitz <drow@mvista.com>
17403
17404 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
17405
174062002-08-20 Jim Blandy <jimb@redhat.com>
17407
17408 * Makefile.in (LDFLAGS): Allow the configure script to establish a
17409 default for this.
17410
174112002-08-01 Andrew Cagney <cagney@redhat.com>
17412
17413 * Makefile.in: Make chill references obsolete.
17414
174152002-07-24 Kevin Buettner <kevinb@redhat.com>
17416
17417 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
17418 * configure: Regenerate.
17419 * config.in: Regenerate.
17420
174212002-07-09 David O'Brien <obrien@FreeBSD.org>
17422
17423 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
17424 (perror_with_name, remote_close, remote_open, expect, play): Static.
17425
174262002-07-04 Michal Ludvig <mludvig@suse.cz>
17427
4b8dad4a 17428 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
17574093
DJ
17429 byte offsets instead of an array of indexes.
17430 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
17431
174322002-06-13 Daniel Jacobowitz <drow@mvista.com>
17433
17434 * regcache.c: Add comment.
17435
174362002-06-11 Daniel Jacobowitz <drow@mvista.com>
17437
17438 * thread-db.c: New file.
17439 * proc-service.c: New file.
17440 * acinclude.m4: New file.
17441 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
17442 proc-service.o, and thread-db.o.
17443 (linux-low.o): Add USE_THREAD_DB.
17444 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
17445 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
17446 * aclocal.m4: Regenerated.
17447 * config.in: Regenerated.
17448 * configure: Regenerated.
17449 * configure.in: Check for proc_service.h, sys/procfs.h,
17450 thread_db.h, and linux/elf.h headrs.
17451 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
17452 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
17453 Check for -lthread_db and thread support.
17454 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
17455 PowerPC, and SuperH.
17456 * i387-fp.c: Constify arguments.
17457 * i387-fp.h: Likewise.
17458 * inferiors.c: (struct thread_info): Renamed from
17459 `struct inferior_info'. Remove PID member. Use generic inferior
17460 list header. All uses updated.
17461 (inferiors, signal_pid): Removed.
17462 (all_threads): New variable.
17463 (get_thread): Define.
17464 (add_inferior_to_list): New function.
17465 (for_each_inferior): New function.
17466 (change_inferior_id): New function.
17467 (add_inferior): Removed.
17468 (remove_inferior): New function.
17469 (add_thread): New function.
17470 (free_one_thread): New function.
17471 (remove_thread): New function.
17472 (clear_inferiors): Use for_each_inferior and free_one_thread.
17473 (find_inferior): New function.
17474 (find_inferior_id): New function.
17475 (inferior_target_data): Update argument type.
17476 (set_inferior_target_data): Likewise.
17477 (inferior_regcache_data): Likewise.
17478 (set_inferior_regcache_data): Likewise.
17479 * linux-low.c (linux_bp_reinsert): Remove.
17480 (all_processes, stopping_threads, using_thrads)
17481 (struct pending_signals, debug_threads, pid_of): New.
17482 (inferior_pid): Replace with macro.
17483 (struct inferior_linux_data): Remove.
17484 (get_stop_pc, add_process): New functions.
17485 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
17486 Use add_process and add_thread.
17487 (linux_attach_lwp): New function, based on old linux_attach. Use
17488 add_process and add_thread. Set stop_expected for new threads.
17489 (linux_attach): New function.
17490 (linux_kill_one_process): New function.
17491 (linux_kill): Kill all LWPs.
17492 (linux_thread_alive): Use find_inferior_id.
17493 (check_removed_breakpoints, status_pending_p): New functions.
17494 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
17495 Update. Use WNOHANG. Wait for cloned processes also. Update process
17496 struct for the found process.
17497 (linux_wait_for_event): New function.
17498 (linux_wait): Use it. Support LWPs.
17499 (send_sigstop, wait_for_sigstop, stop_all_processes)
17500 (linux_resume_one_process, linux_continue_one_process): New functions.
17501 (linux_resume): Support LWPs.
17502 (REGISTER_RAW_SIZE): Remove.
17503 (fetch_register): Use register_size instead. Call supply_register.
17504 (usr_store_inferior_registers): Likewise. Call collect_register.
17505 Fix recursive case.
17506 (regsets_fetch_inferior_registers): Improve error message.
17507 (regsets_store_inferior_registers): Add debugging.
17508 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
17509 (unstopped_p, linux_signal_pid): New functions.
17510 (linux_target_ops): Add linux_signal_pid.
17511 (linux_init_signals): New function.
17512 (initialize_low): Call it. Initialize using_threads.
17513 * regcache.c (inferior_regcache_data): Add valid
17514 flag.
17515 (get_regcache): Fetch registers lazily. Add fetch argument
17516 and update all callers.
17517 (regcache_invalidate_one, regcache_invalidate): New
17518 functions.
17519 (new_register_cache): Renamed from create_register_cache.
17520 Return the new regcache.
17521 (free_register_cache): Change argument to a void *.
17522 (registers_to_string, registers_from_string): Call get_regcache
17523 with fetch flag set.
17524 (register_data): Make static. Pass fetch flag to get_regcache.
17525 (supply_register): Call get_regcache with fetch flag clear.
17526 (collect_register): Call get_regcache with fetch flag set.
17527 (collect_register_as_string): New function.
17528 * regcache.h: Update.
17529 * remote-utils.c (putpkt): Flush after debug output and use
17530 stderr.
17531 Handle input interrupts while waiting for an ACK.
17532 (input_interrupt): Use signal_pid method.
17533 (getpkt): Flush after debug output and use stderr.
17534 (outreg): Use collect_register_as_string.
17535 (new_thread_notify, dead_thread_notify): New functions.
17536 (prepare_resume_reply): Check using_threads. Set thread_from_wait
17537 and general_thread.
17538 (look_up_one_symbol): Flush after debug output.
17539 * server.c (step_thread, server_waiting): New variables.
17540 (start_inferior): Don't use signal_pid. Update call to mywait.
17541 (attach_inferior): Update call to mywait.
17542 (handle_query): Handle qfThreadInfo and qsThreadInfo.
17543 (main): Don't fetch/store registers explicitly. Use
17544 set_desired_inferior. Support proposed ``Hs'' packet. Update
17545 calls to mywait.
17546 * server.h: Update.
17547 (struct inferior_list, struct_inferior_list_entry): New.
17548 * target.c (set_desired_inferior): New.
17549 (write_inferior_memory): Constify.
17550 (mywait): New function.
17551 * target.h: Update.
17552 (struct target_ops): New signal_pid method.
17553 (mywait): Removed macro, added prototype.
17554
17555 * linux-low.h (regset_func): Removed.
17556 (regset_fill_func, regset_store_func): New.
17557 (enum regset_type): New.
17558 (struct regset_info): Add type field. Use new operation types.
17559 (struct linux_target_ops): stop_pc renamed to get_pc.
17560 Add decr_pc_after_break and breakpoint_at.
17561 (get_process, get_thread_proess, get_process_thread)
17562 (strut process_info, all_processes, linux_attach_lwp)
17563 (thread_db_init): New.
17564
17565 * linux-arm-low.c (arm_get_pc, arm_set_pc,
17566 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
17567 (the_low_target): Add new members.
17568 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
17569 (i386_store_fpxregset): Constify.
17570 (target_regsets): Add new kind identifier.
17571 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
17572 (i386_set_pc): Add debugging.
17573 (i386_breakpoint_at): New function.
17574 (the_low_target): Add new members.
17575 * linux-mips-low.c (mips_get_pc, mips_set_pc)
17576 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
17577 (mips_breakpoint_at): New.
17578 (the_low_target): Add new members.
17579 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
17580 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
17581 (the_low_target): Add new members.
17582 * linux-sh-low.c (sh_get_pc, sh_set_pc)
17583 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
17584 (the_low_target): Add new members.
17585 * linux-x86-64-low.c (target_regsets): Add new kind
17586 identifier.
17587
175882002-05-15 Daniel Jacobowitz <drow@mvista.com>
17589
17590 From Martin Pool <mbp@samba.org>:
17591 * server.c (gdbserver_usage): New function.
17592 (main): Call it.
17593
175942002-05-14 Daniel Jacobowitz <drow@mvista.com>
17595
17596 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
17597 stop_at -> stop_pc.
17598
175992002-05-04 Andrew Cagney <ac131313@redhat.com>
17600
17601 * Makefile.in: Remove obsolete code.
17602
176032002-04-24 Michal Ludvig <mludvig@suse.cz>
17604
17605 * linux-low.c (regsets_fetch_inferior_registers),
17606 (regsets_store_inferior_registers): Removed cast to int from
17607 ptrace() calls.
17608 * regcache.h: Added declaration of struct inferior_info.
17609
176102002-04-20 Daniel Jacobowitz <drow@mvista.com>
17611
17612 * inferiors.c (struct inferior_info): Add regcache_data.
17613 (add_inferior): Call create_register_cache.
17614 (clear_inferiors): Call free_register_cache.
17615 (inferior_regcache_data, set_inferior_regcache_data): New functions.
17616 * regcache.c (struct inferior_regcache_data): New.
17617 (registers): Remove.
17618 (get_regcache): New function.
17619 (create_register_cache, free_register_cache): New functions.
17620 (set_register_cache): Don't initialize the register cache here.
17621 (registers_to_string, registers_from_string, register_data): Call
17622 get_regcache.
17623 * regcache.h: Add prototypes.
17624 * server.h: Likewise.
17625
176262002-04-20 Daniel Jacobowitz <drow@mvista.com>
17627
17628 * mem-break.c: New file.
17629 * mem-break.h: New file.
17630 * Makefile.in: Add mem-break.o rule; update server.h
17631 dependencies.
17632 * inferiors.c (struct inferior_info): Add target_data
17633 member.
17634 (clear_inferiors): Free target_data member if set.
17635 (inferior_target_data, set_inferior_target_data): New functions.
17636 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
17637 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
17638 * linux-low.c (linux_bp_reinsert): New variable.
17639 (struct inferior_linux_data): New.
17640 (linux_create_inferior): Use set_inferior_target_data.
17641 (linux_attach): Likewise. Call add_inferior.
17642 (linux_wait_for_one_inferior): New function.
17643 (linux_wait): Call it.
17644 (linux_write_memory): Add const.
17645 (initialize_low): Call set_breakpoint_data.
17646 * linux-low.h (struct linux_target_ops): Add breakpoint
17647 handling members.
17648 * server.c (attach_inferior): Remove extra add_inferior
17649 call.
17650 * server.h: Include mem-break.h. Update inferior.c
17651 prototypes.
17652 * target.c (read_inferior_memory)
17653 (write_inferior_memory): New functions.
17654 * target.h (read_inferior_memory)
17655 (write_inferior_memory): Change macros to prototypes.
17656 (struct target_ops): Update comments. Add const to write_memory
17657 definition.
17658
176592002-04-11 Daniel Jacobowitz <drow@mvista.com>
17660
17661 * linux-low.c (usr_store_inferior_registers): Support
17662 registers which are allowed to fail to store.
17663 * linux-low.h (linux_target_ops): Likewise.
17664 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
17665 (ppc_cannot_store_register): FPSCR may not be storable.
17666
176672002-04-09 Daniel Jacobowitz <drow@mvista.com>
17668
17669 * server.h: Include <string.h> if HAVE_STRING_H.
17670 * ChangeLog: Correct paths in last ChangeLog entry.
17671
176722002-04-09 Daniel Jacobowitz <drow@mvista.com>
17673
17674 * linux-low.h: Remove obsolete prototypes.
17675 (struct linux_target_ops): New.
17676 (extern the_low_target): New.
17677 * linux-low.c (num_regs, regmap): Remove declarations.
17678 (register_addr): Use the_low_target explicitly.
17679 (fetch_register): Likewise.
17680 (usr_fetch_inferior_registers): Likewise.
17681 (usr_store_inferior_registers): Likewise.
17682 * linux-arm-low.c (num_regs): Remove.
17683 (arm_num_regs): Define.
17684 (arm_regmap): Renamed from regmap, made static.
17685 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
17686 made static.
17687 (arm_cannot_store_register): Renamed from cannot_store_register,
17688 made static.
17689 (the_low_target): New.
17690 * linux-i386-low.c (num_regs): Remove.
17691 (i386_num_regs): Define.
17692 (i386_regmap): Renamed from regmap, made static.
17693 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
17694 made static.
17695 (i386_cannot_store_register): Renamed from cannot_store_register,
17696 made static.
17697 (the_low_target): New.
17698 * linux-ia64-low.c (num_regs): Remove.
17699 (ia64_num_regs): Define.
17700 (ia64_regmap): Renamed from regmap, made static.
17701 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
17702 made static.
17703 (ia64_cannot_store_register): Renamed from cannot_store_register,
17704 made static.
17705 (the_low_target): New.
17706 * linux-m68k-low.c (num_regs): Remove.
17707 (m68k_num_regs): Define.
17708 (m68k_regmap): Renamed from regmap, made static.
17709 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
17710 made static.
17711 (m68k_cannot_store_register): Renamed from cannot_store_register,
17712 made static.
17713 (the_low_target): New.
17714 * linux-mips-low.c (num_regs): Remove.
17715 (mips_num_regs): Define.
17716 (mips_regmap): Renamed from regmap, made static.
17717 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
17718 made static.
17719 (mips_cannot_store_register): Renamed from cannot_store_register,
17720 made static.
17721 (the_low_target): New.
17722 * linux-ppc-low.c (num_regs): Remove.
17723 (ppc_num_regs): Define.
17724 (ppc_regmap): Renamed from regmap, made static.
17725 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
17726 made static.
17727 (ppc_cannot_store_register): Renamed from cannot_store_register,
17728 made static.
17729 (the_low_target): New.
17730 * linux-s390-low.c (num_regs): Remove.
17731 (s390_num_regs): Define.
17732 (s390_regmap): Renamed from regmap, made static.
17733 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
17734 made static.
17735 (s390_cannot_store_register): Renamed from cannot_store_register,
17736 made static.
17737 (the_low_target): New.
17738 * linux-sh-low.c (num_regs): Remove.
17739 (sh_num_regs): Define.
17740 (sh_regmap): Renamed from regmap, made static.
17741 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
17742 made static.
17743 (sh_cannot_store_register): Renamed from cannot_store_register,
17744 made static.
17745 (the_low_target): New.
17746 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
17747 (the_low_target): New.
17748
177492002-04-09 Daniel Jacobowitz <drow@mvista.com>
17750
17751 * Makefile.in: Add stamp-h target.
17752 * configure.in: Create stamp-h.
17753 * configure: Regenerated.
17754
177552002-04-09 Daniel Jacobowitz <drow@mvista.com>
17756
17757 * inferiors.c: New file.
17758 * target.c: New file.
17759 * target.h: New file.
17760 * Makefile.in: Add target.o and inferiors.o. Update
17761 dependencies.
17762 * linux-low.c (inferior_pid): New static variable,
17763 moved from server.c.
17764 (linux_create_inferior): Renamed from create_inferior.
17765 Call add_inferior. Return 0 on success instead of a PID.
17766 (linux_attach): Renamed from myattach.
17767 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
17768 (linux_thread_alive): Renamed from mythread_alive.
17769 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
17770 child dies.
17771 (linux_resume): Renamed from myresume. Add missing ``return 0''.
17772 (regsets_store_inferior_registers): Correct error message.
17773 Add missing ``return 0''.
17774 (linux_fetch_registers): Renamed from fetch_inferior_registers.
17775 (linux_store_registers): Renamed from store_inferior_registers.
17776 (linux_read_memory): Renamed from read_inferior_memory.
17777 (linux_write_memory): Renamed from write_inferior_memory.
17778 (linux_target_ops): New structure.
17779 (initialize_low): Call set_target_ops ().
17780 * remote-utils.c (unhexify): New function.
17781 (hexify): New function.
17782 (input_interrupt): Send signals to ``signal_pid''.
17783 * server.c (inferior_pid): Remove.
17784 (start_inferior): Update create_inferior call.
17785 (attach_inferior): Call add_inferior.
17786 (handle_query): New function.
17787 (main): Call handle_query for `q' packets.
17788 * server.h: Include "target.h". Remove obsolete prototypes.
17789 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
17790
177912002-04-09 Daniel Jacobowitz <drow@mvista.com>
17792
17793 * Makefile.in: Add WARN_CFLAGS. Update configury
17794 dependencies.
17795 * configure.in: Check for <string.h>
17796 * configure: Regenerate.
17797 * config.in: Regenerate.
17798 * gdbreplay.c: Include needed system headers.
17799 (remote_open): Remove strchr prototype.
17800 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
17801 * regcache.c (supply_register): Change buf argument to const void *.
17802 (supply_register_by_name): Likewise.
17803 (collect_register): Change buf argument to void *.
17804 (collect_register_by_name): Likewise.
17805 * regcache.h: Add missing prototypes.
17806 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
17807 * server.c (handle_query): New function.
17808 (attached): New static variable, moved out of main.
17809 (main): Quiet longjmp clobber warnings.
17810 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
17811 * utils.c (error): Remove NORETURN.
17812 (fatal): Likewise.
This page took 2.060058 seconds and 4 git commands to generate.