1 2020-03-12 Tom Tromey <tom@tromey.com>
3 * config.in, configure: Rebuild.
4 * configure.ac: Call ZW_GNU_GETTEXT_SISTER_DIR.
5 * acinclude.m4: Include gettext-sister.m4.
6 * Makefile.in (top_builddir, INTL, INTL_DEPS, INTL_CFLAGS): New
8 (INCLUDE_CFLAGS): Add INTL_CFLAGS.
9 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Use INTL_DEPS, INTL.
11 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
13 * acinclude.m4: Update path to selftest.m4.
15 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
17 * configure.ac: Don't source bfd/development.sh, move
19 * configure: Re-generate.
21 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
23 * configure: Re-generate.
25 2020-03-11 Simon Marchi <simon.marchi@efficios.com>
27 * configure: Re-generate.
29 2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
31 * .dir-locals.el: New file.
33 2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
35 * .gitattributes: New file.
37 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
39 * remote-utils.cc (prepare_resume_reply): Add ability to convert T
40 reply into an S reply.
41 * server.cc (disable_packet_T): New global.
42 (captured_main): Set new global when appropriate.
43 * server.h (disable_packet_T): Declare.
45 2020-02-21 Tom Tromey <tom@tromey.com>
47 * Makefile.in (mostlyclean): New target.
49 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
51 * target.h (struct process_stratum_target): Remove.
52 (class process_target): Rename to ...
53 (class process_stratum_target): ... this.
54 * linux-low.h (class linux_process_target): Derive from
55 'process_stratum_target'.
56 * linux-low.cc (linux_target_ops): Remove.
57 (initialize_low): Set the_target to the singleton instance of
59 * lynx-low.h (class lynx_process_target): Derive from
60 'process_stratum_target'.
61 * lynx-low.cc (lynx_target_ops): Remove.
62 (initialize_low): Set the_target to the singleton instance of
64 * nto-low.h (class nto_process_target): Derive from
65 'process_stratum_target'.
66 * nto-low.cc (nto_target_ops): Remove.
67 (initialize_low): Set the_target to the singleton instance of
69 * win32-low.h (class win32_process_target): Derive from
70 'process_stratum_target'.
71 * win32-low.cc (win32_target_ops): Remove.
72 (initialize_low): Set the_target to the singleton instance of
75 Replace 'the_target->pt' with 'the_target' in the uses below.
77 * hostio.cc (hostio_error)
82 * linux-aarch32-low.cc (arm_breakpoint_at)
83 * linux-aarch64-low.cc (aarch64_breakpoint_at)
84 * linux-arm-low.cc (arm_sigreturn_next_pc)
86 (arm_get_syscall_trapinfo)
87 * linux-cris-low.cc (cris_breakpoint_at)
88 * linux-crisv32-low.cc (cris_breakpoint_at)
89 * linux-low.cc (handle_extended_wait)
92 (linux_process_target::breakpoint_kind_from_pc)
94 * linux-m32r-low.cc (m32r_breakpoint_at)
95 * linux-mips-low.cc (mips_breakpoint_at)
96 * linux-nios2-low.cc (nios2_breakpoint_at)
97 * linux-ppc-low.cc (ppc_breakpoint_at)
98 * linux-s390-low.cc (s390_get_hwcap)
99 * linux-sh-low.cc (sh_breakpoint_at)
100 * linux-sparc-low.cc (sparc_fill_gregset_to_stack)
101 (sparc_store_gregset_from_stack)
102 (sparc_breakpoint_at)
103 * linux-tic6x-low.cc (tic6x_breakpoint_at)
104 * linux-tile-low.cc (tile_breakpoint_at)
105 * linux-x86-low.cc (x86_breakpoint_at)
106 * linux-xtensa-low.cc (xtensa_breakpoint_at)
107 * mem-break.cc (bp_size)
109 (insert_memory_breakpoint)
110 (set_raw_breakpoint_at)
111 (delete_raw_breakpoint)
113 (uninsert_raw_breakpoint)
114 (reinsert_raw_breakpoint)
115 (validate_inserted_breakpoint)
116 * regcache.cc (regcache_read_pc)
118 * remote-utils.cc (putpkt_binary_1)
121 (prepare_resume_reply)
122 * server.cc (handle_general_set)
125 (handle_qxfer_exec_file)
126 (handle_qxfer_libraries_svr4)
127 (handle_qxfer_osdata)
128 (handle_qxfer_siginfo)
133 (queue_stop_reply_callback)
135 * target.cc (prepare_to_access_memory)
136 (done_accessing_memory)
137 (read_inferior_memory)
138 (target_write_memory)
139 (target_stop_and_wait)
141 (target_mourn_inferior)
142 (target_continue_no_signal)
144 (target_supports_multi_process)
147 (target_create_inferior)
148 (target_post_create_inferior)
150 (target_supports_fork_events)
151 (target_supports_vfork_events)
152 (target_supports_exec_events)
153 (target_handle_new_gdb_connection)
156 (fetch_inferior_registers)
157 (store_inferior_registers)
159 (target_supports_non_stop)
161 (target_process_qsupported)
162 (target_supports_catch_syscall)
163 (target_get_ipa_tdesc_idx)
164 (target_supports_tracepoints)
165 (target_supports_fast_tracepoints)
166 (target_get_min_fast_tracepoint_insn_len)
167 (target_thread_stopped)
170 (target_stabilize_threads)
171 (target_install_fast_tracepoint_jump_pad)
173 (target_supports_disable_randomization)
174 (target_supports_agent)
175 (target_enable_btrace)
176 (target_disable_btrace)
178 (target_read_btrace_conf)
179 (target_supports_range_stepping)
180 (target_supports_stopped_by_sw_breakpoint)
181 (target_stopped_by_sw_breakpoint)
182 (target_supports_stopped_by_hw_breakpoint)
183 (target_supports_hardware_single_step)
184 (target_stopped_by_hw_breakpoint)
185 (target_breakpoint_kind_from_pc)
186 (target_breakpoint_kind_from_current_state)
187 (target_supports_software_single_step)
188 (target_core_of_thread)
190 (target_thread_handle)
191 * win32-low.cc (do_initial_child_stuff)
193 Rename target op default definitions listed below.
195 * target.cc (process_target::post_create_inferior): Rename as ...
196 (process_stratum_target::post_create_inferior): ... this.
197 (process_target::prepare_to_access_memory): Rename as ...
198 (process_stratum_target::prepare_to_access_memory): ... this.
199 (process_target::done_accessing_memory): Rename as ...
200 (process_stratum_target::done_accessing_memory): ... this.
201 (process_target::look_up_symbols): Rename as ...
202 (process_stratum_target::look_up_symbols): ... this.
203 (process_target::supports_read_auxv): Rename as ...
204 (process_stratum_target::supports_read_auxv): ... this.
205 (process_target::read_auxv): Rename as ...
206 (process_stratum_target::read_auxv): ... this.
207 (process_target::supports_z_point_type): Rename as ...
208 (process_stratum_target::supports_z_point_type): ... this.
209 (process_target::insert_point): Rename as ...
210 (process_stratum_target::insert_point): ... this.
211 (process_target::remove_point): Rename as ...
212 (process_stratum_target::remove_point): ... this.
213 (process_target::stopped_by_sw_breakpoint): Rename as ...
214 (process_stratum_target::stopped_by_sw_breakpoint): ... this.
215 (process_target::supports_stopped_by_sw_breakpoint): Rename as ...
216 (process_stratum_target::supports_stopped_by_sw_breakpoint): ... this.
217 (process_target::stopped_by_hw_breakpoint): Rename as ...
218 (process_stratum_target::stopped_by_hw_breakpoint): ... this.
219 (process_target::supports_stopped_by_hw_breakpoint): Rename as ...
220 (process_stratum_target::supports_stopped_by_hw_breakpoint): ... this.
221 (process_target::supports_hardware_single_step): Rename as ...
222 (process_stratum_target::supports_hardware_single_step): ... this.
223 (process_target::stopped_by_watchpoint): Rename as ...
224 (process_stratum_target::stopped_by_watchpoint): ... this.
225 (process_target::stopped_data_address): Rename as ...
226 (process_stratum_target::stopped_data_address): ... this.
227 (process_target::supports_read_offsets): Rename as ...
228 (process_stratum_target::supports_read_offsets): ... this.
229 (process_target::read_offsets): Rename as ...
230 (process_stratum_target::read_offsets): ... this.
231 (process_target::supports_get_tls_address): Rename as ...
232 (process_stratum_target::supports_get_tls_address): ... this.
233 (process_target::get_tls_address): Rename as ...
234 (process_stratum_target::get_tls_address): ... this.
235 (process_target::hostio_last_error): Rename as ...
236 (process_stratum_target::hostio_last_error): ... this.
237 (process_target::supports_qxfer_osdata): Rename as ...
238 (process_stratum_target::supports_qxfer_osdata): ... this.
239 (process_target::qxfer_osdata): Rename as ...
240 (process_stratum_target::qxfer_osdata): ... this.
241 (process_target::supports_qxfer_siginfo): Rename as ...
242 (process_stratum_target::supports_qxfer_siginfo): ... this.
243 (process_target::qxfer_siginfo): Rename as ...
244 (process_stratum_target::qxfer_siginfo): ... this.
245 (process_target::supports_non_stop): Rename as ...
246 (process_stratum_target::supports_non_stop): ... this.
247 (process_target::async): Rename as ...
248 (process_stratum_target::async): ... this.
249 (process_target::start_non_stop): Rename as ...
250 (process_stratum_target::start_non_stop): ... this.
251 (process_target::supports_multi_process): Rename as ...
252 (process_stratum_target::supports_multi_process): ... this.
253 (process_target::supports_fork_events): Rename as ...
254 (process_stratum_target::supports_fork_events): ... this.
255 (process_target::supports_vfork_events): Rename as ...
256 (process_stratum_target::supports_vfork_events): ... this.
257 (process_target::supports_exec_events): Rename as ...
258 (process_stratum_target::supports_exec_events): ... this.
259 (process_target::handle_new_gdb_connection): Rename as ...
260 (process_stratum_target::handle_new_gdb_connection): ... this.
261 (process_target::handle_monitor_command): Rename as ...
262 (process_stratum_target::handle_monitor_command): ... this.
263 (process_target::core_of_thread): Rename as ...
264 (process_stratum_target::core_of_thread): ... this.
265 (process_target::supports_read_loadmap): Rename as ...
266 (process_stratum_target::supports_read_loadmap): ... this.
267 (process_target::read_loadmap): Rename as ...
268 (process_stratum_target::read_loadmap): ... this.
269 (process_target::process_qsupported): Rename as ...
270 (process_stratum_target::process_qsupported): ... this.
271 (process_target::supports_tracepoints): Rename as ...
272 (process_stratum_target::supports_tracepoints): ... this.
273 (process_target::read_pc): Rename as ...
274 (process_stratum_target::read_pc): ... this.
275 (process_target::write_pc): Rename as ...
276 (process_stratum_target::write_pc): ... this.
277 (process_target::supports_thread_stopped): Rename as ...
278 (process_stratum_target::supports_thread_stopped): ... this.
279 (process_target::thread_stopped): Rename as ...
280 (process_stratum_target::thread_stopped): ... this.
281 (process_target::supports_get_tib_address): Rename as ...
282 (process_stratum_target::supports_get_tib_address): ... this.
283 (process_target::get_tib_address): Rename as ...
284 (process_stratum_target::get_tib_address): ... this.
285 (process_target::pause_all): Rename as ...
286 (process_stratum_target::pause_all): ... this.
287 (process_target::unpause_all): Rename as ...
288 (process_stratum_target::unpause_all): ... this.
289 (process_target::stabilize_threads): Rename as ...
290 (process_stratum_target::stabilize_threads): ... this.
291 (process_target::supports_fast_tracepoints): Rename as ...
292 (process_stratum_target::supports_fast_tracepoints): ... this.
293 (process_target::get_min_fast_tracepoint_insn_len): Rename as ...
294 (process_stratum_target::get_min_fast_tracepoint_insn_len): ... this.
295 (process_target::emit_ops): Rename as ...
296 (process_stratum_target::emit_ops): ... this.
297 (process_target::supports_disable_randomization): Rename as ...
298 (process_stratum_target::supports_disable_randomization): ... this.
299 (process_target::supports_qxfer_libraries_svr4): Rename as ...
300 (process_stratum_target::supports_qxfer_libraries_svr4): ... this.
301 (process_target::qxfer_libraries_svr4): Rename as ...
302 (process_stratum_target::qxfer_libraries_svr4): ... this.
303 (process_target::supports_agent): Rename as ...
304 (process_stratum_target::supports_agent): ... this.
305 (process_target::enable_btrace): Rename as ...
306 (process_stratum_target::enable_btrace): ... this.
307 (process_target::disable_btrace): Rename as ...
308 (process_stratum_target::disable_btrace): ... this.
309 (process_target::read_btrace): Rename as ...
310 (process_stratum_target::read_btrace): ... this.
311 (process_target::read_btrace_conf): Rename as ...
312 (process_stratum_target::read_btrace_conf): ... this.
313 (process_target::supports_range_stepping): Rename as ...
314 (process_stratum_target::supports_range_stepping): ... this.
315 (process_target::supports_pid_to_exec_file): Rename as ...
316 (process_stratum_target::supports_pid_to_exec_file): ... this.
317 (process_target::pid_to_exec_file): Rename as ...
318 (process_stratum_target::pid_to_exec_file): ... this.
319 (process_target::supports_multifs): Rename as ...
320 (process_stratum_target::supports_multifs): ... this.
321 (process_target::multifs_open): Rename as ...
322 (process_stratum_target::multifs_open): ... this.
323 (process_target::multifs_unlink): Rename as ...
324 (process_stratum_target::multifs_unlink): ... this.
325 (process_target::multifs_readlink): Rename as ...
326 (process_stratum_target::multifs_readlink): ... this.
327 (process_target::breakpoint_kind_from_pc): Rename as ...
328 (process_stratum_target::breakpoint_kind_from_pc): ... this.
329 (process_target::breakpoint_kind_from_current_state): Rename as ...
330 (process_stratum_target::breakpoint_kind_from_current_state): ... this.
331 (process_target::thread_name): Rename as ...
332 (process_stratum_target::thread_name): ... this.
333 (process_target::thread_handle): Rename as ...
334 (process_stratum_target::thread_handle): ... this.
335 (process_target::supports_software_single_step): Rename as ...
336 (process_stratum_target::supports_software_single_step): ... this.
337 (process_target::supports_catch_syscall): Rename as ...
338 (process_stratum_target::supports_catch_syscall): ... this.
339 (process_target::get_ipa_tdesc_idx): Rename as ...
340 (process_stratum_target::get_ipa_tdesc_idx): ... this.
342 2020-02-20 Pedro Alves <palves@redhat.com>
344 * target.cc (set_target_ops): Simply copy the given target pointer
345 instead of creating a copy of the pointed object.
347 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
349 Turn process_stratum_target's get_ipa_tdesc_idx op into a method
352 * target.h (struct process_stratum_target): Remove the target op.
353 (class process_target): Add the target op.
354 (target_get_ipa_tdesc_idx): Update the macro.
355 * target.cc (process_target::get_ipa_tdesc_idx): Define.
357 Update the derived classes and callers below.
359 * linux-low.cc (linux_target_ops): Update.
360 (linux_get_ipa_tdesc_idx): Turn into ...
361 (linux_process_target::get_ipa_tdesc_idx): ... this.
362 * linux-low.h (class linux_process_target): Update.
363 * lynx-low.cc (lynx_target_ops): Update.
364 * nto-low.cc (nto_target_ops): Update.
365 * win32-low.cc (win32_target_ops): Update.
367 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
369 Turn process_stratum_target's supports_catch_syscall op into a
370 method of process_target.
372 * target.h (struct process_stratum_target): Remove the target op.
373 (class process_target): Add the target op.
374 (target_supports_catch_syscall): Update the macro.
375 * target.cc (process_target::supports_catch_syscall): Define.
377 Update the derived classes and callers below.
379 * linux-low.cc (linux_target_ops): Update.
380 (linux_supports_catch_syscall): Turn into ...
381 (linux_process_target::supports_catch_syscall): ... this.
382 * linux-low.h (class linux_process_target): Update.
383 * lynx-low.cc (lynx_target_ops): Update.
384 * nto-low.cc (nto_target_ops): Update.
385 * win32-low.cc (win32_target_ops): Update.
387 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
389 Turn process_stratum_target's supports_software_single_step op
390 into a method of process_target.
392 * target.h (struct process_stratum_target): Remove the target op.
393 (class process_target): Add the target op.
394 (target_supports_software_single_step): Update the macro.
395 * target.cc (process_target::supports_software_single_step): Define.
397 Update the derived classes and callers below.
399 * linux-low.cc (linux_target_ops): Update.
400 (linux_supports_software_single_step): Turn into ...
401 (linux_process_target::supports_software_single_step): ... this.
402 * linux-low.h (class linux_process_target): Update.
403 * lynx-low.cc (lynx_target_ops): Update.
404 * nto-low.cc (nto_target_ops): Update.
405 * win32-low.cc (win32_target_ops): Update.
407 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
409 Turn process_stratum_target's thread_name and thread_handle ops
410 into methods of process_target.
412 * target.h (struct process_stratum_target): Remove the target ops.
413 (class process_target): Add the target ops.
414 (target_thread_name): Update the macro.
415 (target_thread_handle): Update the macro.
416 * target.cc (process_target::thread_name): Define.
417 (process_target::thread_handle): Define.
419 Update the derived classes and callers below.
421 * linux-low.cc (linux_target_ops): Update.
422 (linux_process_target::thread_name): Define.
423 (linux_process_target::thread_handle): Define.
424 * linux-low.h (class linux_process_target): Update.
425 * lynx-low.cc (lynx_target_ops): Update.
426 * nto-low.cc (nto_target_ops): Update.
427 * win32-low.cc (win32_target_ops): Update.
429 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
431 Turn process_stratum_target's breakpoint_kind_from_pc,
432 sw_breakpoint_from_kind, and breakpoint_kind_from_current_state
433 ops into methods of process_target.
435 * target.h (struct process_stratum_target): Remove the target op.
436 (class process_target): Add the target op.
437 (target_breakpoint_kind_from_pc): Update the macro.
438 (target_breakpoint_kind_from_current_state): Update the macro.
439 (default_breakpoint_kind_from_pc): Remove declaration.
440 * target.cc (default_breakpoint_kind_from_pc): Turn into ...
441 (process_target::breakpoint_kind_from_pc): ... this.
442 (process_target::breakpoint_kind_from_current_state): Define.
444 Update the derived classes and callers below.
446 * mem-break.cc (bp_size): Update.
448 * linux-low.cc (linux_target_ops): Update.
449 (linux_wait_1): Update.
450 (linux_breakpoint_kind_from_pc): Turn into ...
451 (linux_process_target::breakpoint_kind_from_pc): ... this.
452 (linux_sw_breakpoint_from_kind): Turn into ...
453 (linux_process_target::sw_breakpoint_from_kind): ... this.
454 (linux_breakpoint_kind_from_current_state): Turn into ...
455 (linux_process_target::breakpoint_kind_from_current_state): ... this.
456 * linux-low.h (class linux_process_target): Update.
457 * lynx-low.cc (lynx_target_ops): Update.
458 (lynx_process_target::sw_breakpoint_from_kind): Define.
459 * lynx-low.h (class lynx_process_target): Update.
460 * nto-low.cc (nto_target_ops): Update.
461 (nto_sw_breakpoint_from_kind): Turn into ...
462 (nto_process_target::sw_breakpoint_from_kind): ... this.
463 * nto-low.h (class nto_process_target): Update.
464 * win32-low.cc (win32_target_ops): Update.
465 (win32_sw_breakpoint_from_kind): Turn into ...
466 (win32_process_target::sw_breakpoint_from_kind): ... this.
467 * win32-low.h (class win32_process_target): Update.
469 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
471 Turn process_stratum_target's multifs_open, multifs_readlink,
472 multifs_unlink ops into methods of process_target.
474 * target.h (struct process_stratum_target): Remove the target ops.
475 (class process_target): Add the target ops. Also add
477 * target.cc: Include "fcntl.h", "unistd.h", "sys/types.h", and
479 (process_target::supports_multifs): Define.
480 (process_target::multifs_open): Define.
481 (process_target::multifs_readlink): Define.
482 (process_target::multifs_unlink): Define.
484 Update the derived classes and callers below.
486 * hostio.cc (handle_setfs): Update.
487 (handle_open): Update.
488 (handle_unlink): Update.
489 (handle_readlink): Update.
490 * linux-low.cc (linux_target_ops): Update.
491 (linux_process_target::supports_multifs): Define.
492 (linux_process_target::multifs_open): Define.
493 (linux_process_target::multifs_readlink): Define.
494 (linux_process_target::multifs_unlink): Define.
495 * linux-low.h (class linux_process_target): Update.
496 * lynx-low.cc (lynx_target_ops): Update.
497 * nto-low.cc (nto_target_ops): Update.
498 * win32-low.cc (win32_target_ops): Update.
500 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
502 Turn process_stratum_target's pid_to_exec_file op into a method
505 * target.h (struct process_stratum_target): Remove the target op.
506 (class process_target): Add the target op. Also add
507 'supports_pid_to_exec_file'.
508 * target.cc (process_target::pid_to_exec_file): Define.
509 (process_target::supports_pid_to_exec_file): Define.
511 Update the derived classes and callers below.
513 * server.cc (handle_qxfer_exec_file): Update.
514 (handle_query): Update.
515 * linux-low.cc (linux_target_ops): Update.
516 (linux_process_target::supports_pid_to_exec_file): Define.
517 (linux_process_target::pid_to_exec_file): Define.
518 * linux-low.h (class linux_process_target): Update.
519 * lynx-low.cc (lynx_target_ops): Update.
520 * nto-low.cc (nto_target_ops): Update.
521 * win32-low.cc (win32_target_ops): Update.
523 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
525 Turn process_stratum_target's supports_range_stepping op into a
526 method of process_target.
528 * target.h (struct process_stratum_target): Remove the target op.
529 (class process_target): Add the target op.
530 (target_supports_range_stepping): Update the macro.
531 * target.cc (process_target::supports_range_stepping): Define.
533 Update the derived classes and callers below.
535 * linux-low.cc (linux_target_ops): Update.
536 (linux_supports_range_stepping): Turn into ...
537 (linux_process_target::supports_range_stepping): ... this.
538 * linux-low.h (class linux_process_target): Update.
539 * lynx-low.cc (lynx_target_ops): Update.
540 * nto-low.cc (nto_target_ops): Update.
541 * win32-low.cc (win32_target_ops): Update.
543 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
545 Turn process_stratum_target's btrace-related ops (enable_btrace,
546 disable_btrace, read_btrace, read_btrace_conf) into methods of
549 * target.h (struct process_stratum_target): Remove the target ops.
550 (class process_target): Add the target ops.
551 (target_enable_btrace): Update.
552 (target_disable_btrace): Update.
553 (target_read_btrace): Update.
554 (target_read_btrace_conf): Update.
555 * target.cc (process_target::enable_btrace): Define.
556 (process_target::disable_btrace): Define.
557 (process_target::read_btrace): Define.
558 (process_target::read_btrace_conf): Define.
560 Update the derived classes and callers below.
562 * linux-low.cc (linux_target_ops): Update.
563 (linux_process_target:enable_btrace): Define as a wrapper around
565 (linux_low_disable_btrace): Turn into ...
566 (linux_process_target::disable_btrace): ... this.
567 (linux_low_read_btrace): Turn into ...
568 (linux_process_target::read_btrace): ... this.
569 (linux_low_btrace_conf): Turn into ...
570 (linux_process_target::read_btrace_conf): ... this.
571 * linux-low.h (class linux_process_target): Update.
572 * lynx-low.cc (lynx_target_ops): Update.
573 * nto-low.cc (nto_target_ops): Update.
574 * win32-low.cc (win32_target_ops): Update.
576 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
578 Turn process_stratum_target's supports_agent op into a method of
581 * target.h (struct process_stratum_target): Remove the target op.
582 (class process_target): Add the target op.
583 (target_supports_agent): Update the macro.
584 * target.cc (process_target::supports_agent): Define.
586 Update the derived classes and callers below.
588 * linux-low.cc (linux_target_ops): Update.
589 (linux_supports_agent): Turn into ...
590 (linux_process_target::supports_agent): ... this.
591 * linux-low.h (class linux_process_target): Update.
592 * lynx-low.cc (lynx_target_ops): Update.
593 * nto-low.cc (nto_target_ops): Update.
594 * win32-low.cc (win32_target_ops): Update.
596 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
598 Turn process_stratum_target's qxfer_libraries_svr4 op into a
599 method of process_target.
601 * target.h (struct process_stratum_target): Remove the target op.
602 (class process_target): Add the target op. Also add
603 'supports_qxfer_libraries_svr4'.
604 * target.cc (process_target::qxfer_libraries_svr4): Define.
605 (process_target::supports_qxfer_libraries_svr4): Define.
607 Update the derived classes and callers below.
609 * server.cc (handle_qxfer_libraries_svr4): Update.
610 (handle_query): Update.
611 * linux-low.cc (linux_target_ops): Update.
612 (linux_process_target::supports_qxfer_libraries_svr4): Define.
613 (linux_qxfer_libraries_svr4): Turn into ...
614 (linux_process_target::qxfer_libraries_svr4): ... this.
615 * linux-low.h (class linux_process_target): Update.
616 * lynx-low.cc (lynx_target_ops): Update.
617 * nto-low.cc (nto_target_ops): Update.
618 * win32-low.cc (win32_target_ops): Update.
620 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
622 Turn process_stratum_target's supports_disable_randomization op
623 into a method of process_target.
625 * target.h (struct process_stratum_target): Remove the target op.
626 (class process_target): Add the target op.
627 (target_supports_disable_randomization): Update the macro.
628 * target.cc (process_target::supports_disable_randomization): Define.
630 Update the derived classes and callers below.
632 * linux-low.cc (linux_target_ops): Update.
633 (linux_supports_disable_randomization): Turn into ...
634 (linux_process_target::supports_disable_randomization): ... this.
635 * linux-low.h (class linux_process_target): Update.
636 * lynx-low.cc (lynx_target_ops): Update.
637 * nto-low.cc (nto_target_ops): Update.
638 * win32-low.cc (win32_target_ops): Update.
640 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
642 Turn process_stratum_target's emit_ops op into a method of
645 * target.h (struct process_stratum_target): Remove the target op.
646 (class process_target): Add the target op.
647 (target_emit_ops): Update the macro.
648 * target.cc (process_target::emit_ops): Define.
650 Update the derived classes and callers below.
652 * linux-low.cc (linux_target_ops): Update.
653 (linux_emit_ops): Turn into ...
654 (linux_process_target::emit_ops): ... this.
655 * linux-low.h (class linux_process_target): Update.
656 * lynx-low.cc (lynx_target_ops): Update.
657 * nto-low.cc (nto_target_ops): Update.
658 * win32-low.cc (win32_target_ops): Update.
660 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
662 Turn process_stratum_target's install_fast_tracepoint_jump_pad
663 and get_min_fast_tracepoint_insn_len ops into methods of
666 * target.h (struct process_stratum_target): Remove the target ops.
667 (class process_target): Add the target ops. Also add
668 'supports_fast_tracepoints'.
669 (target_supports_fast_tracepoints): Update the macro.
670 (target_get_min_fast_tracepoint_insn_len): Update the macro.
671 (install_fast_tracepoint_jump_pad): Update and rename the macro
673 (target_install_fast_tracepoint_jump_pad): ... this.
674 * target.cc (process_target::supports_fast_tracepoints): Define.
675 (process_target::install_fast_tracepoint_jump_pad): Define.
676 (process_target::get_min_fast_tracepoint_insn_len): Define.
678 Update the derived classes and callers below.
680 * tracepoint.cc (install_fast_tracepoint): Update.
681 * linux-low.cc (linux_target_ops): Update.
682 (linux_process_target::supports_fast_tracepoints): Define.
683 (linux_install_fast_tracepoint_jump_pad): Turn into ...
684 (linux_process_target::install_fast_tracepoint_jump_pad): ... this.
685 (linux_get_min_fast_tracepoint_insn_len): Turn into ...
686 (linux_process_target::get_min_fast_tracepoint_insn_len): ... this.
687 * linux-low.h (class linux_process_target): Update.
688 * lynx-low.cc (lynx_target_ops): Update.
689 * nto-low.cc (nto_target_ops): Update.
690 * win32-low.cc (win32_target_ops): Update.
692 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
694 Turn process_stratum_target's stabilize_threads op into a
695 method of process_target.
697 * target.h (struct process_stratum_target): Remove the target op.
698 (class process_target): Add the target op.
699 (target_stabilize_threads): Update the macro.
700 * target.cc (process_target::stabilize_threads): Define.
702 Update the derived classes and callers below.
704 * server.cc (handle_status): Update.
705 * tracepoint.cc (cmd_qtdp): Update.
706 (cmd_qtstart): Update.
707 * linux-low.cc (linux_target_ops): Update.
708 (linux_stabilize_threads): Turn into ...
709 (linux_process_target::stabilize_threads): ... this.
710 (linux_wait_1): Update.
711 * linux-low.h (class linux_process_target): Update.
712 * lynx-low.cc (lynx_target_ops): Update.
713 * nto-low.cc (nto_target_ops): Update.
714 * win32-low.cc (win32_target_ops): Update.
716 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
718 Turn process_stratum_target's pause_all and unpause_all ops
719 into methods of process_target.
721 * target.h (struct process_stratum_target): Remove the target ops.
722 (class process_target): Add the target ops.
723 (pause_all): Update the macro and rename to...
724 (target_pause_all): ... this.
725 (unpause_all): Update the macro and rename to...
726 (target_unpause_all): ... this.
727 * target.cc (process_target::pause_all): Define.
728 (process_target::unpause_all): Define.
730 Update the derived classes and callers below.
732 * server.cc (handle_status): Update.
733 * tracepoint.cc (clear_installed_tracepoints): Update.
735 (cmd_qtstart): Update.
736 (stop_tracing): Update.
737 (cmd_qtstatus): Update.
738 (upload_fast_traceframes): Update.
739 (run_inferior_command): Update.
740 * linux-low.cc (linux_target_ops): Update.
741 (linux_pause_all): Turn into ...
742 (linux_process_target::pause_all): ... this.
743 (linux_unpause_all): Turn into ...
744 (linux_process_target::unpause_all): ... this.
745 (linux_process_target::prepare_to_access_memory): Update.
746 (linux_process_target::done_accessing_memory): Update.
747 * linux-low.h (class linux_process_target): Update.
748 * lynx-low.cc (lynx_target_ops): Update.
749 * nto-low.cc (nto_target_ops): Update.
750 * win32-low.cc (win32_target_ops): Update.
752 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
754 Turn process_stratum_target's get_tib_address op into a method of
757 * target.h (struct process_stratum_target): Remove the target op.
758 (class process_target): Add the target op. Also add
759 'supports_get_tib_address'.
760 * target.cc (process_target::get_tib_address): Define.
761 (process_target::supports_get_tib_address): Define.
763 Update the derived classes and callers below.
765 * server.cc (handle_query): Update.
766 * linux-low.cc (win32_target_ops): Update.
767 * lynx-low.cc (lynx_target_ops): Update.
768 * nto-low.cc (nto_target_ops): Update.
769 * win32-low.cc (win32_target_ops): Update.
770 (win32_process_target::supports_get_tib_address): Define.
771 (win32_get_tib_address): Turn into ...
772 (win32_process_target::get_tib_address): ... this.
773 * win32-low.h (class win32_process_target): Update.
775 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
777 Turn process_stratum_target's thread_stopped op into a method of
780 * target.h (struct process_stratum_target): Remove the target op.
781 (class process_target): Add the target op. Also add
782 'supports_thread_stopped'.
783 (target_thread_stopped): Update the macro.
784 * target.cc (process_target::thread_stopped): Define.
785 (process_target::supports_thread_stopped): Define.
786 (prepare_to_access_memory): Update.
788 Update the derived classes and callers below.
790 * server.cc (queue_stop_reply_callback): Update.
791 * linux-low.cc (linux_target_ops): Update.
792 (linux_process_target::supports_thread_stopped): Define.
793 (linux_thread_stopped): Turn into ...
794 (linux_process_target::thread_stopped): ... this.
795 * linux-low.h (class linux_process_target): Update.
796 * lynx-low.cc (lynx_target_ops): Update.
797 * nto-low.cc (nto_target_ops): Update.
798 * win32-low.cc (win32_target_ops): Update.
800 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
802 Turn process_stratum_target's read_pc and write_pc ops into
803 methods of process_target.
805 * target.h (struct process_stratum_target): Remove the target ops.
806 (class process_target): Add the target ops.
807 * target.cc (process_target::read_pc): Define.
808 (process_target::write_pc): Define.
810 Update the derived classes and callers below.
812 * regcache.cc (regcache_read_pc): Update.
813 (regcache_write_pc): Update.
814 * linux-low.cc (linux_target_ops): Update.
815 (linux_read_pc): Turn into ...
816 (linux_process_target::read_pc): ... this.
817 (linux_write_pc): Turn into ...
818 (linux_process_target::write_pc): ... this.
819 * linux-low.h (class linux_process_target): Update.
820 * lynx-low.cc (lynx_target_ops): Update.
821 * nto-low.cc (nto_target_ops): Update.
822 * win32-low.cc (win32_target_ops): Update.
824 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
826 Turn process_stratum_target's supports_tracepoints op into a
827 method of process_target.
829 * target.h (struct process_stratum_target): Remove the target op.
830 (class process_target): Add the target op.
831 (target_supports_tracepoints): Update the macro.
832 * target.cc (process_target::supports_tracepoints): Define.
834 Update the derived classes and callers below.
836 * linux-low.cc (linux_target_ops): Update.
837 (linux_supports_tracepoints): Turn into ...
838 (linux_process_target::supports_tracepoints): ... this.
839 * linux-low.h (class linux_process_target): Update.
840 * lynx-low.cc (lynx_target_ops): Update.
841 * nto-low.cc (nto_target_ops): Update.
842 * win32-low.cc (win32_target_ops): Update.
844 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
846 Turn process_stratum_target's process_qsupported op into a method
849 * target.h (struct process_stratum_target): Remove the target op.
850 (class process_target): Add the target op.
851 (target_process_qsupported): Update the macro.
852 * target.cc (process_target::process_qsupported): Define.
854 Update the derived classes and callers below.
856 * linux-low.cc (linux_target_ops): Update.
857 (linux_process_qsupported): Turn into ...
858 (linux_process_target::process_qsupported): ... this.
859 * linux-low.h (class linux_process_target): Update.
860 * lynx-low.cc (lynx_target_ops): Update.
861 * nto-low.cc (nto_target_ops): Update.
862 * win32-low.cc (win32_target_ops): Update.
864 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
866 Turn process_stratum_target's read_loadmap op into a method of
869 * target.h (struct process_stratum_target): Remove the target op.
870 (class process_target): Add the target op. Also add
871 'supports_read_loadmap'.
872 * target.cc (process_target::read_loadmap): Define.
873 (process_target::supports_read_loadmap): Define.
875 Update the derived classes and callers below.
877 * server.cc (handle_qxfer_fdpic): Update.
878 (handle_query): Update.
879 * linux-low.cc (linux_target_ops): Update.
880 (linux_process_target::supports_read_loadmap): Define.
881 (linux_read_loadmap): Turn into ...
882 (linux_process_target::read_loadmap): ... this.
883 * linux-low.h (class linux_process_target): Update.
884 * lynx-low.cc (lynx_target_ops): Update.
885 * nto-low.cc (nto_target_ops): Update.
886 * win32-low.cc (win32_target_ops): Update.
888 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
890 Turn process_stratum_target's core_of_thread op into a method of
893 * target.h (struct process_stratum_target): Remove the target op.
894 (class process_target): Add the target op.
895 (target_core_of_thread): Update the macro.
896 * target.cc (process_target::core_of_thread): Define.
898 Update the derived classes and callers below.
900 * linux-low.cc (linux_target_ops): Update.
901 (linux_process_target::core_of_thread): Define.
902 * linux-low.h (class linux_process_target): Update.
903 * lynx-low.cc (lynx_target_ops): Update.
904 * nto-low.cc (nto_target_ops): Update.
905 * win32-low.cc (win32_target_ops): Update.
907 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
909 Turn process_stratum_target's handle_monitor_command op into a
910 method of process_target.
912 * target.h (struct process_stratum_target): Remove the target op.
913 (class process_target): Add the target op.
914 (target_handle_monitor_command): Update the macro.
915 * target.cc (process_target::handle_monitor_command): Define.
917 Update the derived classes and callers below.
919 * server.cc (handle_query): Update.
920 * linux-low.cc (linux_target_ops): Update.
921 (linux_process_target::handle_monitor_command): Define.
922 * linux-low.h (class linux_process_target): Update.
923 * lynx-low.cc (lynx_target_ops): Update.
924 * nto-low.cc (nto_target_ops): Update.
925 * win32-low.cc (win32_target_ops): Update.
927 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
929 Turn process_stratum_target's handle_new_gdb_connection op into a
930 method of process_target.
932 * target.h (struct process_stratum_target): Remove the target op.
933 (class process_target): Add the target op.
934 (target_handle_new_gdb_connection): Update the macro.
935 * target.cc (process_target::handle_new_gdb_connection): Define.
937 Update the derived classes and callers below.
939 * linux-low.cc (linux_target_ops): Update.
940 (linux_handle_new_gdb_connection): Turn into ...
941 (linux_process_target::handle_new_gdb_connection): ... this.
942 * linux-low.h (class linux_process_target): Update.
943 * lynx-low.cc (lynx_target_ops): Update.
944 * nto-low.cc (nto_target_ops): Update.
945 * win32-low.cc (win32_target_ops): Update.
947 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
949 Turn process_stratum_target's supports_fork_events,
950 supports_vfork_events, and supports_exec_events ops into methods
953 * target.h (struct process_stratum_target): Remove the target ops.
954 (class process_target): Add the target ops.
955 (target_supports_fork_events): Update the macro.
956 (target_supports_vfork_events): Update the macro.
957 (target_supports_exec_events): Update the macro.
958 * target.cc (process_target::supports_fork_events): Define.
959 (process_target::supports_vfork_events): Define.
960 (process_target::supports_exec_events): Define.
962 Update the derived classes and callers below.
964 * linux-low.cc (linux_target_ops): Update.
965 (linux_supports_fork_events): Turn into ...
966 (linux_process_target::supports_fork_events): ... this.
967 (linux_supports_vfork_events): Turn into ...
968 (linux_process_target::supports_vfork_events): ... this.
969 (linux_supports_exec_events): Turn into ...
970 (linux_process_target::supports_exec_events): ... this.
971 * linux-low.h (class linux_process_target): Update.
972 * lynx-low.cc (lynx_target_ops): Update.
973 * nto-low.cc (nto_target_ops): Update.
974 * win32-low.cc (win32_target_ops): Update.
976 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
978 Turn process_stratum_target's supports_multi_process op into a
979 method of process_target.
981 * target.h (struct process_stratum_target): Remove the target op.
982 (class process_target): Add the target op.
983 * target.cc (process_target::supports_multi_process): Define.
984 (target_supports_multi_process): Update.
986 Update the derived classes and callers below.
988 * linux-low.cc (linux_target_ops): Update.
989 (linux_supports_multi_process): Turn into ...
990 (linux_process_target::supports_multi_process): ... this.
991 * linux-low.h (class linux_process_target): Update.
992 * lynx-low.cc (lynx_target_ops): Update.
993 * nto-low.cc (nto_target_ops): Update.
994 * win32-low.cc (win32_target_ops): Update.
996 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
998 Turn process_stratum_target's supports_non_stop, async, and
999 start_non_stop ops into methods of process_target.
1001 * target.h (struct process_stratum_target): Remove the target ops.
1002 (class process_target): Add the target ops.
1003 (target_supports_non_stop): Update the macro.
1004 (target_async): Update the macro.
1005 (start_non_stop): Remove declaration.
1006 * target.cc (process_target::supports_non_stop): Define.
1007 (process_target::async): Define.
1008 (process_target::start_non_stop): Define.
1009 (start_non_stop): Remove.
1011 Update the derived classes and callers below.
1013 * server.cc (handle_qxfer_siginfo): Update.
1014 (handle_query): Update.
1015 * linux-low.cc (linux_target_ops): Update.
1016 (linux_supports_non_stop): Turn into ...
1017 (linux_process_target::supports_non_stop): ... this.
1018 (linux_async): Turn into ...
1019 (linux_process_target::async): ... this.
1020 (linux_start_non_stop): Turn into ...
1021 (linux_process_target::start_non_stop): ... this.
1022 * linux-low.h (class linux_process_target): Update.
1023 * lynx-low.cc (lynx_target_ops): Update.
1024 * nto-low.cc (nto_target_ops): Update.
1025 (nto_supports_non_stop): Remove; rely on the default behavior
1027 * win32-low.cc (win32_target_ops): Update.
1029 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1031 Turn process_stratum_target's qxfer_siginfo op into a method of
1034 * target.h (struct process_stratum_target): Remove the target op.
1035 (class process_target): Add the target op. Also add
1036 'supports_qxfer_siginfo'.
1037 * target.cc (process_target::qxfer_siginfo): Define.
1038 (process_target::supports_qxfer_siginfo): Define.
1040 Update the derived classes and callers below.
1042 * server.cc (handle_qxfer_siginfo): Update.
1043 (handle_query): Update.
1044 * linux-low.cc (linux_target_ops): Update.
1045 (linux_process_target::supports_qxfer_siginfo): Define.
1046 (linux_xfer_siginfo): Turn into ...
1047 (linux_process_target::qxfer_siginfo): ... this.
1048 * linux-low.h (class linux_process_target): Update.
1049 * lynx-low.cc (lynx_target_ops): Update.
1050 * nto-low.cc (nto_target_ops): Update.
1051 * win32-low.cc (win32_target_ops): Update.
1053 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1055 Turn process_stratum_target's qxfer_osdata op into a method of
1058 * target.h (struct process_stratum_target): Remove the target op.
1059 (class process_target): Add the target op. Also add
1060 'supports_qxfer_osdata'.
1061 * target.cc (process_target::qxfer_osdata): Define.
1062 (process_target::supports_qxfer_osdata): Define.
1064 Update the derived classes and callers below.
1066 * server.cc (handle_qxfer_osdata): Update.
1067 (handle_query): Update.
1068 * linux-low.cc (linux_target_ops): Update.
1069 (linux_process_target::supports_qxfer_osdata): Define.
1070 (linux_qxfer_osdata): Turn into ...
1071 (linux_process_target::qxfer_osdata): ... this.
1072 * linux-low.h (class linux_process_target): Update.
1073 * lynx-low.cc (lynx_target_ops): Update.
1074 * nto-low.cc (nto_target_ops): Update.
1075 * win32-low.cc (win32_target_ops): Update.
1077 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1079 Turn process_stratum_target's hostio_last_error op into a
1080 method of process_target.
1082 * target.h (struct process_stratum_target): Remove the target op.
1083 (class process_target): Add the target op.
1084 * target.cc: Add "hostio.h" to includes.
1085 (process_target::hostio_last_error): Define.
1087 Update the derived classes and callers below.
1089 * hostio.cc (hostio_error): Update.
1090 * linux-low.cc: Remove "hostio.h" from includes.
1091 (linux_target_ops): Update.
1092 * lynx-low.cc (lynx_target_ops): Update.
1093 * nto-low.cc (nto_target_ops): Update.
1094 * win32-low.h (class win32_process_target): Update.
1095 * win32-low.cc (win32_target_ops): Update.
1096 (wince_hostio_last_error): Turn into ...
1097 (win32_process_target::hostio_last_error): ... this.
1099 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1101 Turn process_stratum_target's get_tls_address op into a method of
1104 * target.h (struct process_stratum_target): Remove the target op.
1105 (class process_target): Add the target op. Also add
1106 'supports_get_tls_address'.
1107 * target.cc (process_target::get_tls_address): Define.
1108 (process_target::supports_get_tls_address): Define.
1110 Update the derived classes and callers below.
1112 * server.cc (handle_query): Update.
1113 * linux-low.cc (linux_target_ops): Update.
1114 (linux_process_target::supports_get_tls_address): Define.
1115 (linux_process_target::get_tls_address): Define.
1116 * linux-low.h (class linux_process_target): Update.
1117 * lynx-low.cc (lynx_target_ops): Update.
1118 * nto-low.cc (nto_target_ops): Update.
1119 * win32-low.cc (win32_target_ops): Update.
1121 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1123 Turn process_stratum_target's read_offsets op into a method of
1126 * target.h (struct process_stratum_target): Remove the target op.
1127 (class process_target): Add the target op. Also add
1128 'supports_read_offsets'.
1129 * target.cc (process_target::read_offsets): Define.
1130 (process_target::supports_read_offsets): Define.
1132 Update the derived classes and callers below.
1134 * server.cc (handle_query): Update.
1135 * linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
1136 (linux_target_ops): Update.
1137 (linux_process_target::supports_read_offsets): Define.
1138 (linux_read_offsets): Turn into ...
1139 (linux_process_target::read_offsets): ... this.
1140 * linux-low.h (class linux_process_target): Update.
1141 * lynx-low.cc (lynx_target_ops): Update.
1142 * nto-low.cc (nto_target_ops): Update.
1143 * win32-low.cc (win32_target_ops): Update.
1145 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1147 Turn process_stratum_target's stopped_by_watchpoint and
1148 stopped_data_address ops into methods of process_target.
1150 * target.h (struct process_stratum_target): Remove the target ops.
1151 (class process_target): Add the target ops.
1152 * target.cc (process_target::stopped_by_watchpoint): Define.
1153 (process_target::stopped_data_address): Define.
1155 Update the derived classes and callers below.
1157 * remote-utils.cc (prepare_resume_reply): Update.
1158 * linux-low.cc (linux_target_ops): Update.
1159 (linux_stopped_by_watchpoint): Turn into ...
1160 (linux_process_target::stopped_by_watchpoint): ... this.
1161 (linux_stopped_data_address): Turn into ...
1162 (linux_process_target::stopped_data_address): ... this.
1163 * linux-low.h (class linux_process_target): Update.
1164 * lynx-low.cc (lynx_target_ops): Update.
1165 * nto-low.cc (nto_target_ops): Update.
1166 (nto_stopped_by_watchpoint): Turn into ...
1167 (nto_process_target::stopped_by_watchpoint): ... this.
1168 (nto_stopped_data_address): Turn into ...
1169 (nto_process_target::stopped_data_address): ... this.
1170 * nto-low.h (class nto_process_target): Update.
1171 * win32-low.cc (win32_target_ops): Update.
1172 (win32_stopped_by_watchpoint): Turn into ...
1173 (win32_process_target::stopped_by_watchpoint): ... this.
1174 (win32_stopped_data_address): Turn into ...
1175 (win32_process_target::stopped_data_address): ... this.
1176 * win32-low.h (class win32_process_target): Update.
1178 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1180 Turn process_stratum_target's supports_hardware_single_step op into
1181 a method of process_target.
1183 * target.h (struct process_stratum_target): Remove the target op.
1184 (class process_target): Add the target op.
1185 (target_supports_hardware_single_step): Update the macro.
1186 (target_can_do_hardware_single_step): Remove declaration.
1187 * target.cc (process_target::supports_hardware_single_step): Define.
1188 (target_can_do_hardware_single_step): Remove.
1190 Update the derived classes and callers below.
1192 * linux-low.h (class linux_process_target): Update.
1193 * linux-low.cc (linux_target_ops): Update.
1194 (linux_supports_hardware_single_step): Turn into ...
1195 (linux_process_target::supports_hardware_single_step): ... this.
1196 * lynx-low.h (class lynx_process_target): Update.
1197 * lynx-low.cc (lynx_target_ops): Update.
1198 (lynx_process_target::supports_hardware_single_step): Define.
1199 * nto-low.h (class nto_process_target): Update.
1200 * nto-low.cc (nto_target_ops): Update.
1201 (nto_process_target::supports_hardware_single_step): Define.
1202 * win32-low.h (class win32_process_target): Update.
1203 * win32-low.cc (win32_target_ops): Update.
1204 (win32_process_target::supports_hardware_single_step): Define.
1206 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1208 Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
1209 ops into methods of process_target.
1211 * target.h (struct process_stratum_target): Remove the target ops.
1212 (class process_target): Add the target ops.
1213 (target_stopped_by_hw_breakpoint): Update the macro.
1214 (target_supports_stopped_by_hw_breakpoint): Update the macro.
1215 * target.cc (process_target::stopped_by_hw_breakpoint): Define.
1216 (process_target::supports_stopped_by_hw_breakpoint): Define.
1218 Update the derived classes and callers below.
1220 * linux-low.cc (linux_target_ops): Update.
1221 (linux_stopped_by_hw_breakpoint): Turn into ...
1222 (linux_process_target::stopped_by_hw_breakpoint): ... this.
1223 (linux_supports_stopped_by_hw_breakpoint): Turn into ...
1224 (linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
1225 * linux-low.h (class linux_process_target): Update.
1226 * lynx-low.cc (lynx_target_ops): Update.
1227 * nto-low.cc (nto_target_ops): Update.
1228 * win32-low.cc (win32_target_ops): Update.
1230 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1232 Turn process_stratum_target's {supports_}stopped_by_sw_breakpoint
1233 ops into methods of process_target.
1235 * target.h (struct process_stratum_target): Remove the target ops.
1236 (class process_target): Add the target ops.
1237 (target_stopped_by_sw_breakpoint): Update the macro.
1238 (target_supports_stopped_by_sw_breakpoint): Update the macro.
1239 * target.cc (process_target::stopped_by_sw_breakpoint): Define.
1240 (process_target::supports_stopped_by_sw_breakpoint): Define.
1242 Update the derived classes and callers below.
1244 * linux-low.cc (linux_target_ops): Update.
1245 (linux_stopped_by_sw_breakpoint): Turn into ...
1246 (linux_process_target::stopped_by_sw_breakpoint): ... this.
1247 (linux_supports_stopped_by_sw_breakpoint): Turn into ...
1248 (linux_process_target::supports_stopped_by_sw_breakpoint): ... this.
1249 * linux-low.h (class linux_process_target): Update.
1250 * lynx-low.cc (lynx_target_ops): Update.
1251 * nto-low.cc (nto_target_ops): Update.
1252 * win32-low.cc (win32_target_ops): Update.
1254 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1256 Turn process_stratum_target's insert_point and remove_point ops
1257 into methods of process_target.
1259 * target.h (struct process_stratum_target): Remove the target ops.
1260 (class process_target): Add the target ops.
1261 * target.cc (process_target::insert_point): Define.
1262 (process_target::remove_point): Define.
1264 Update the derived classes and callers below.
1266 * mem-break.cc (set_raw_breakpoint_at): Update.
1267 (delete_raw_breakpoint): Update.
1268 (uninsert_raw_breakpoint): Update.
1269 (reinsert_raw_breakpoint): Update.
1270 * linux-low.cc (linux_target_ops): Update.
1271 (linux_insert_point): Turn into ...
1272 (linux_process_target::insert_point): ... this.
1273 (linux_remove_point): Turn into ...
1274 (linux_process_target::remove_point): ... this.
1275 * linux-low.h (class linux_process_target): Update.
1276 * lynx-low.cc (lynx_target_ops): Update.
1277 * nto-low.cc (nto_target_ops): Update.
1278 (nto_insert_point): Turn into ...
1279 (nto_process_target::insert_point): ... this.
1280 (nto_remove_point): Turn into ...
1281 (nto_process_target::remove_point): ... this.
1282 * nto-low.h (class nto_process_target): Update.
1283 * win32-low.cc (win32_target_ops): Update.
1284 (win32_insert_point): Turn into ...
1285 (win32_process_target::insert_point): ... this.
1286 (win32_remove_point): Turn into ...
1287 (win32_process_target::remove_point): ... this.
1288 * win32-low.h (class win32_process_target): Update.
1290 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1292 Turn process_stratum_target's supports_z_point_type op into a
1293 method of process_target.
1295 * target.h (struct process_stratum_target): Remove the target op.
1296 (class process_target): Add the target op.
1297 * target.cc (process_target::supports_z_point_type): Define.
1299 Update the derived classes and callers below.
1301 * mem-break.cc (z_type_supported): Update.
1302 * linux-low.cc (linux_target_ops): Update.
1303 (linux_supports_z_point_type): Turn into ...
1304 (linux_process_target::supports_z_point_type): ... this.
1305 * linux-low.h (class linux_process_target): Update.
1306 * lynx-low.cc (lynx_target_ops): Update.
1307 * nto-low.cc (nto_target_ops): Update.
1308 (nto_supports_z_point_type): Turn into ...
1309 (nto_process_target::supports_z_point_type): ... this.
1310 * nto-low.h (class nto_process_target): Update.
1311 * win32-low.cc (win32_target_ops): Update.
1312 (win32_supports_z_point_type): Turn into ...
1313 (win32_process_target::supports_z_point_type): ... this.
1314 * win32-low.h (class win32_process_target): Update.
1316 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1318 Turn process_stratum_target's read_auxv op into a method of
1321 * target.h (class process_stratum_target): Remove the target op.
1322 (struct process_target): Add the target op. Also add
1323 'supports_read_auxv'.
1324 * target.cc (process_target::read_auxv): Define.
1325 (process_target::supports_read_auxv): Define.
1327 Update the derived classes and callers below.
1329 * server.cc (handle_qxfer_auxv): Update.
1330 (handle_query): Update.
1331 * linux-low.cc (linux_target_ops): Update.
1332 (linux_process_target::supports_read_auxv): Define.
1333 (linux_read_auxv): Turn into ...
1334 (linux_process_target::read_auxv): ... this.
1335 * linux-low.h (class linux_process_target): Update.
1336 * lynx-low.cc (lynx_target_ops): Update.
1337 * nto-low.cc (nto_target_ops): Update.
1338 (nto_process_target::supports_read_auxv): Define.
1339 (nto_read_auxv): Turn into ...
1340 (nto_process_target::read_auxv): ... this.
1341 * nto-low.h (class nto_process_target): Update.
1342 * win32-low.cc (win32_target_ops): Update.
1344 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1346 Turn process_stratum_target's request_interrupt op into a method of
1349 * target.h (struct process_stratum_target): Remove the target op.
1350 (class process_target): Add the target op.
1352 Update the derived classes and callers below.
1354 * remote-utils.cc (putpkt_binary_1): Update.
1355 (input_interrupt): Update.
1357 * server.cc (handle_v_requests): Update.
1358 * linux-low.cc (linux_target_ops): Update.
1359 (linux_request_interrupt): Turn into ...
1360 (linux_process_target::request_interrupt): ... this.
1361 * linux-low.h (class linux_process_target): Update.
1362 * lynx-low.cc (lynx_target_ops): Update.
1363 (lynx_request_interrupt): Turn into ...
1364 (lynx_process_target::request_interrupt): ... this.
1365 * lynx-low.h (class lynx_process_target): Update.
1366 * nto-low.cc (nto_target_ops): Update.
1367 (nto_request_interrupt): Turn into ...
1368 (nto_process_target::request_interrupt): ... this.
1369 * nto-low.h (class nto_process_target): Update.
1370 * win32-low.cc (win32_target_ops): Update.
1371 (win32_request_interrupt): Turn into ...
1372 (win32_process_target::request_interrupt): ... this.
1373 * win32-low.h (class win32_process_target): Update.
1375 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1377 Turn process_stratum_target's look_up_symbols op into a method of
1380 * target.h (struct process_stratum_target): Remove the target op.
1381 (class process_target): Add the target op.
1382 * target.cc (process_target::look_up_symbols): Define.
1384 Update the derived classes and callers below.
1386 * server.cc (handle_query): Update.
1387 * linux-low.cc (linux_target_ops): Update.
1388 (linux_look_up_symbols): Turn into ...
1389 (linux_process_target::look_up_symbols): ... this.
1390 * linux-low.h (class linux_process_target): Update.
1391 * lynx-low.cc (lynx_target_ops): Update.
1392 * nto-low.cc (nto_target_ops): Update.
1393 * win32-low.cc (win32_target_ops): Update.
1395 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1397 Turn process_stratum_target's read_memory and write_memory
1398 ops into methods of process_target.
1400 * target.h (struct process_stratum_target): Remove the target ops.
1401 (class process_target): Add the target ops.
1403 Update the derived classes and callers below.
1405 * linux-aarch32-low.cc (arm_breakpoint_at): Update.
1406 * linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
1407 * linux-arm-low.cc (arm_sigreturn_next_pc): Update.
1408 (arm_get_syscall_trapinfo): Update.
1409 * linux-cris-low.cc (cris_breakpoint_at): Update.
1410 * linux-crisv32-low.cc (cris_breakpoint_at): Update.
1411 * linux-m32r-low.cc (m32r_breakpoint_at): Update.
1412 * linux-mips-low.cc (mips_breakpoint_at): Update.
1413 * linux-nios2-low.cc (nios2_breakpoint_at): Update.
1414 * linux-ppc-low.cc (ppc_breakpoint_at): Update.
1415 * linux-sh-low.cc (sh_breakpoint_at): Update.
1416 * linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
1417 (sparc_store_gregset_from_stack): Update.
1418 (sparc_breakpoint_at): Update.
1419 * linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
1420 * linux-tile-low.cc (tile_breakpoint_at): Update.
1421 * linux-x86-low.cc (x86_breakpoint_at): Update.
1422 * linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
1423 * mem-brea.cc (insert_memory_breakpoint): Update.
1424 (validate_inserted_breakpoint): Update.
1425 * target.cc (read_inferior_memory): Update.
1426 (target_write_memory): Update.
1427 * linux-low.cc (linux_target_ops): Update.
1428 (linux_read_memory): Make a wrapper around the read_memory target
1430 (linux_process_target::read_memory): Rename from linux_read_memory.
1431 (linux_write_memory): Turn into ...
1432 (linux_process_target::write_memory): ... this.
1433 * linux-low.h (class linux_process_target): Update.
1434 * lynx-low.cc (lynx_target_ops): Update.
1435 (lynx_read_memory): Turn into ...
1436 (lynx_process_target::read_memory): ... this.
1437 (lynx_write_memory): Turn into ...
1438 (lynx_process_target::write_memory): ... this.
1439 * lynx-low.h (class lynx_process_target): Update.
1440 * nto-low.cc (nto_target_ops): Update.
1441 (nto_read_memory): Turn into ...
1442 (nto_process_target::read_memory): ... this.
1443 (nto_write_memory): Turn into ...
1444 (nto_process_target::write_memory): ... this.
1445 * nto-low.h (class nto_process_target): Update.
1446 * win32-low.cc (win32_target_ops): Update.
1447 (win32_read_inferior_memory): Turn into ...
1448 (win32_process_target::read_memory): ... this.
1449 (win32_write_inferior_memory): Turn into ...
1450 (win32_process_target::write_memory): ... this.
1451 * win32-low.h (class win32_process_target): Update.
1453 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1455 Turn process_stratum_target's prepare_to_access_memory and
1456 done_accessing_memory ops into methods of process_target.
1458 * target.h (struct process_stratum_target): Remove the target ops.
1459 (class process_target): Add the target ops.
1460 * target.cc (process_target::prepare_to_access_memory): Define.
1461 (process_target::done_accessing_memory): Define.
1462 (prepare_to_access_memory): Update.
1463 (done_accessing_memory): Update.
1465 Update the derived classes and callers below.
1467 * linux-low.cc (linux_target_ops): Update.
1468 (linux_prepare_to_access_memory): Turn into ...
1469 (linux_process_target::prepare_to_access_memory): ... this.
1470 (linux_done_accessing_memory): Turn into ...
1471 (linux_process_target::done_accessing_memory): ... this.
1472 * linux-low.h (class linux_process_target): Update.
1473 * lynx-low.cc (lynx_target_ops): Update.
1474 * nto-low.cc (nto_target_ops): Update.
1475 * win32-low.cc (win32_target_ops): Update.
1477 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1479 Turn process_stratum_target's fetch_registers and store_registers
1480 ops into methods of process_target.
1482 * target.h (struct process_stratum_target): Remove the target ops.
1483 (class process_target): Add the target ops.
1484 (fetch_inferior_registers): Update the macro.
1485 (store_inferior_registers): Update the macro.
1487 Update the derived classes and callers below.
1489 * linux-low.cc (linux_target_ops): Update.
1490 (linux_fetch_registers): Turn into ...
1491 (linux_process_target::fetch_registers): ... this.
1492 (linux_store_registers): Turn into ...
1493 (linux_process_target::store_registers): ... this.
1494 * linux-low.h (class linux_process_target): Update.
1495 * lynx-low.cc (lynx_target_ops): Update.
1496 (lynx_fetch_registers): Turn into ...
1497 (lynx_process_target::fetch_registers): ... this.
1498 (lynx_store_registers): Turn into ...
1499 (lynx_process_target::store_registers): ... this.
1500 * lynx-low.h (class lynx_process_target): Update.
1501 * nto-low.cc (nto_target_ops): Update.
1502 (nto_fetch_registers): Turn into ...
1503 (nto_process_target::fetch_registers): ... this.
1504 (nto_store_registers): Turn into ...
1505 (nto_process_target::store_registers): ... this.
1506 * nto-low.h (class nto_process_target): Update.
1507 * win32-low.cc (win32_target_ops): Update.
1508 (win32_fetch_inferior_registers): Turn into ...
1509 (win32_process_target::fetch_registers): ... this.
1510 (win32_store_inferior_registers): Turn into ...
1511 (win32_process_target::store_registers): ... this.
1512 * win32-low.h (class win32_process_target): Update.
1514 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1516 Turn process_stratum_target's wait op into a method of
1519 * target.h (struct process_stratum_target): Remove the target op.
1520 (class process_target): Add the target op.
1522 Update the derived classes and callers below.
1524 * target.cc (target_wait): Update.
1525 * linux-low.cc (linux_target_ops): Update.
1526 (linux_wait): Turn into ...
1527 (linux_process_target::wait): ... this.
1528 * linux-low.h (class linux_process_target): Update.
1529 * lynx-low.cc (lynx_target_ops): Update.
1530 (lynx_wait): Turn into ...
1531 (lynx_process_target::wait): ... this.
1532 * lynx-low.h (class lynx_process_target): Update.
1533 * nto-low.cc (nto_target_ops): Update.
1534 (nto_wait): Turn into ...
1535 (nto_process_target::wait): ... this.
1536 * nto-low.h (class nto_process_target): Update.
1537 * win32-low.cc (win32_target_ops): Update.
1538 (win32_wait): Turn into ...
1539 (win32_process_target::wait): ... this.
1540 (do_initial_child_stuff): Update.
1541 * win32-low.h (class win32_process_target): Update.
1543 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1545 Turn process_stratum_target's resume op into a method of
1548 * target.h (struct process_stratum_target): Remove the target op.
1549 (class process_target): Add the target op.
1551 Update the derived classes and callers below.
1553 * server.cc (resume): Update.
1554 * target.cc (target_stop_and_wait): Update.
1555 (target_continue_no_signal): Update.
1556 (target_continue): Update.
1557 * linux-low.cc (linux_target_ops): Update.
1558 (linux_resume): Turn into ...
1559 (linux_process_target::resume): ... this.
1560 * linux-low.h (class linux_process_target): Update.
1561 * lynx-low.cc (lynx_target_ops): Update.
1562 (lynx_resume): Turn into ...
1563 (lynx_process_target::resume): ... this.
1564 * lynx-low.h (class lynx_process_target): Update.
1565 * nto-low.cc (nto_target_ops): Update.
1566 (nto_resume): Turn into ...
1567 (nto_process_target::resume): ... this.
1568 * nto-low.h (class nto_process_target): Update.
1569 * win32-low.cc (win32_target_ops): Update.
1570 (win32_resume): Turn into ...
1571 (win32_process_target::resume): ... this.
1572 (win32_process_target::detach): Update.
1573 (do_initial_child_stuff): Update.
1574 * win32-low.h (class win32_process_target): Update.
1576 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1578 Turn process_stratum_target's thread_alive op into a method of
1581 * target.h (struct process_stratum_target): Remove the target op.
1582 (class process_target): Add the target op.
1583 (mythread_alive): Update the macro.
1585 Update the derived classes and callers below.
1587 * linux-low.cc (linux_target_ops): Update.
1588 (linux_thread_alive): Turn into ...
1589 (linux_process_target::thread_alive): ... this.
1590 (wait_for_sigstop): Update.
1591 * linux-low.h (class linux_process_target): Update.
1592 * lynx-low.cc (lynx_target_ops): Update.
1593 (lynx_thread_alive): Turn into ...
1594 (lynx_process_target::thread_alive): ... this.
1595 * lynx-low.h (class lynx_process_target): Update.
1596 * nto-low.cc (nto_target_ops): Update.
1597 (nto_thread_alive): Turn into ...
1598 (nto_process_target::thread_alive): ... this.
1599 * nto-low.h (class nto_process_target): Update.
1600 * win32-low.cc (win32_target_ops): Update.
1601 (win32_thread_alive): Turn into ...
1602 (win32_process_target::thread_alive): ... this.
1603 * win32-low.h (class win32_process_target): Update.
1605 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1607 Turn process_stratum_target's join op into a method of
1610 * target.h (struct process_stratum_target): Remove the target op.
1611 (class process_target): Add the target op.
1612 (join_inferior): Update the macro.
1614 Update the derived classes and callers below.
1616 * linux-low.cc (linux_target_ops): Update.
1617 (linux_join): Turn into ...
1618 (linux_process_target::join): ... this.
1619 * linux-low.h (class linux_process_target): Update.
1620 * lynx-low.cc (lynx_target_ops): Update.
1621 (lynx_join): Turn into ...
1622 (lynx_process_target::join): ... this.
1623 * lynx-low.h (class lynx_process_target): Update.
1624 * nto-low.cc (nto_target_ops): Update.
1625 (nto_process_target::join): Define.
1626 * nto-low.h (class nto_process_target): Update.
1627 * win32-low.cc (win32_target_ops): Update.
1628 (win32_join): Turn into ...
1629 (win32_process_target::join): ... this.
1630 * win32-low.h (class win32_process_target): Update.
1632 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1634 Turn process_stratum_target's mourn op into a method of
1637 * target.h (struct process_stratum_target): Remove the target op.
1638 (class process_target): Add the target op.
1640 Update the derived classes and callers below.
1642 * target.cc (target_mourn_inferior): Update.
1643 * linux-low.cc (linux_target_ops): Update.
1644 (linux_mourn): Turn into ...
1645 (linux_process_target::mourn): ... this.
1646 (handle_extended_wait): Update.
1647 (linux_process_target::kill): Update.
1648 (linux_process_target::detach): Update.
1649 * linux-low.h (class linux_process_target): Update.
1650 * lynx-low.cc (lynx_target_ops): Update.
1651 (lynx_mourn): Turn into ...
1652 (lynx_process_target::mourn): ... this.
1653 * lynx-low.h (class lynx_process_target): Update.
1654 * nto-low.cc (nto_target_ops): Update.
1655 (nto_mourn): Turn into ...
1656 (nto_process_target::mourn): ... this.
1657 * nto-low.h (class nto_process_target): Update.
1658 * win32-low.cc (win32_target_ops): Update.
1659 (win32_mourn): Turn into ...
1660 (win32_process_target::mourn): ... this.
1661 * win32-low.h (class win32_process_target): Update.
1663 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1665 Turn process_stratum_target's detach op into a method of
1668 * target.h (struct process_stratum_target): Remove the target op.
1669 (class process_target): Add the target op.
1670 (detach_inferior): Update the macro.
1672 Update the derived classes and callers below.
1674 * linux-low.cc (linux_target_ops): Update.
1675 (linux_detach): Turn into ...
1676 (linux_process_target::detach): ... this.
1677 * linux-low.h (class linux_process_target): Update.
1678 * lynx-low.cc (lynx_target_ops): Update.
1679 (lynx_detach): Turn into ...
1680 (lynx_process_target::detach): ... this.
1681 * lynx-low.h (class lynx_process_target): Update.
1682 * nto-low.cc (nto_target_ops): Update.
1683 (nto_detach): Turn into ...
1684 (nto_process_target::detach): ... this.
1685 * nto-low.h (class nto_process_target): Update.
1686 * win32-low.cc (win32_target_ops): Update.
1687 (win32_detach): Turn into ...
1688 (win32_process_target::detach): ... this.
1689 * win32-low.h (class win32_process_target): Update.
1691 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1693 Turn process_stratum_target's kill op into a method of
1696 * target.h (struct process_stratum_target): Remove the target op.
1697 (class process_target): Add the target op.
1699 Update the derived classes and callers below.
1701 * target.cc (kill_inferior): Update.
1702 * linux-low.cc (linux_target_ops): Update.
1703 (linux_kill): Turn into ...
1704 (linux_process_target::kill): ... this.
1705 * linux-low.h (class linux_process_target): Update.
1706 * lynx-low.cc (lynx_target_ops): Update.
1707 (lynx_kill): Turn into ...
1708 (lynx_process_target::kill): ... this.
1709 * lynx-low.h (class lynx_process_target): Update.
1710 * nto-low.cc (nto_target_ops): Update.
1711 (nto_kill): Turn into ...
1712 (nto_process_target::kill): ... this.
1713 * nto-low.h (class nto_process_target): Update.
1714 * win32-low.cc (win32_target_ops): Update.
1715 (win32_kill): Turn into ...
1716 (win32_process_target::kill): ... this.
1717 * win32-low.h (class win32_process_target): Update.
1719 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1721 Turn process_stratum_target's attach op into a method of
1724 * target.h (struct process_stratum_target): Remove the target op.
1725 (class process_target): Add the target op.
1726 (myattach): Update the macro.
1728 Update the derived classes and callers below.
1730 * linux-low.cc (linux_target_ops): Update.
1731 (linux_attach): Turn into ...
1732 (linux_process_target::attach): ... this.
1733 * linux-low.h (class linux_process_target): Update.
1734 * lynx-low.cc (lynx_target_ops): Update.
1735 (lynx_attach): Turn into ...
1736 (lynx_process_target::attach): ... this.
1737 * lynx-low.h (class lynx_process_target): Update.
1738 * nto-low.cc (nto_target_ops): Update.
1739 (nto_attach): Turn into ...
1740 (nto_process_target::attach): ... this.
1741 * nto-low.h (class nto_process_target): Update.
1742 * win32-low.cc (win32_target_ops): Update.
1743 (win32_attach): Turn into ...
1744 (win32_process_target::attach): ... this.
1745 * win32-low.h (class win32_process_target): Update.
1747 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1749 Turn process_stratum_target's post_create_inferior op into a method
1752 * target.h (struct process_stratum_target): Remove the target op.
1753 (class process_target): Add the target op.
1754 (target_post_create_inferior): Update the macro.
1755 * target.cc (process_target::post_create_inferior): Define.
1757 Update the derived classes and callers below.
1759 * linux-low.cc (linux_target_ops): Update.
1760 (linux_post_create_inferior): Turn into ...
1761 (linux_process_target::post_create_inferior): ... this.
1762 * linux-low.h (class linux_process_target): Update.
1763 * lynx-low.cc (lynx_target_ops): Update.
1764 * nto-low.cc (nto_target_ops): Update.
1765 * win32-low.cc (win32_target_ops): Update.
1767 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1769 Turn process_stratum_target's create_inferior op into a method of
1772 * target.h (struct process_stratum_target): Remove the target op.
1773 (class process_target): Add the target op.
1774 (create_inferior): Rename the macro to ...
1775 (target_create_inferior): ... this.
1777 Update the derived classes and callers below.
1779 * server.cc (handle_v_run): Update.
1780 (captured_main): Update.
1781 (process_serial_event): Update.
1782 * linux-low.cc (linux_target_ops): Update.
1783 (linux_create_inferior): Turn into ...
1784 (linux_process_target::create_inferior): ... this.
1785 * linux-low.h (class linux_process_target): Update.
1786 * lynx-low.cc (lynx_target_ops): Update.
1787 (lynx_create_inferior): Turn into ...
1788 (lynx_process_target::create_inferior): ... this.
1789 * lynx-low.h (class lynx_process_target): Update.
1790 * nto-low.cc (nto_target_ops): Update.
1791 (nto_create_inferior): Turn into ...
1792 (nto_process_target::create_inferior): ... this.
1793 * nto-low.h (class nto_process_target): Update.
1794 * win32-low.cc (win32_target_ops): Update.
1795 (win32_create_inferior): Turn into ...
1796 (win32_process_target::create_inferior): ... this.
1797 * win32-low.h (class win32_process_target): Update.
1799 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1801 * target.h (class process_target): New class definition.
1802 (struct process_stratum_target) <pt>: New field with type
1804 * linux-low.h (class linux_process_target): Define as a derived
1805 class of 'process_target'.
1806 * linux-low.cc (linux_target_ops): Add a linux_process_target*
1808 * lynx-low.h (class lynx_process_target): Define as a derived
1809 class of 'process_target'.
1810 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
1812 * nto-low.h (class nto_process_target): Define as a derived
1813 class of 'process_target'.
1814 * nto-low.cc (nto_target_ops): Add an nto_process_target*
1816 * win32-low.h (class win32_process_target): Define as a derived
1817 class of 'process_target'.
1818 * win32-low.cc (win32_target_ops): Add a win32_process_target*
1821 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
1823 * configure: Regenerate.
1825 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
1826 Andrew Burgess <andrew.burgess@embecosm.com>
1828 * linux-riscv-low.cc: New file.
1829 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
1830 and nat/riscv-linux-tdesc.c.
1831 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
1832 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
1835 2020-02-14 Tom Tromey <tom@tromey.com>
1837 * acinclude.m4: Don't include acx_configure_dir.m4.
1838 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
1839 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
1840 (all, install-only, uninstall, clean-info, clean)
1841 (maintainer-clean): Don't recurse.
1842 (subdir_do, all-lib): Remove.
1843 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
1845 (generated_files): Update.
1846 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
1847 * configure: Rebuild.
1848 * configure.ac: Don't configure gnulib or libiberty.
1851 2020-02-14 Eli Zaretskii <eliz@gnu.org>
1853 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
1854 preparing the command line for CreateProcess.
1855 (win32_create_inferior): Reflect the program name in debugging
1856 output that shows the process and its command line.
1858 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
1860 * Makefile.in: Rename source files from .c to .cc.
1861 * %.c: Rename to %.cc.
1862 * configure.ac: Rename server.c to server.cc.
1863 * configure: Re-generate.
1865 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
1867 * Makefile.in: Rename gdbsupport source files from .c to .cc.
1869 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
1871 * win32-low.c (win32_create_inferior): Set signal_pid.
1873 2020-02-12 Maciej W. Rozycki <macro@wdc.com>
1874 Pedro Alves <palves@redhat.com>
1876 Skip building gdbserver in a cross-configuration.
1877 * configure.srv: Set $gdbserver_host depending on whether $target
1878 is $host. Use $gdbserver_host instead of $host.
1880 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
1882 * configure: Re-generate.
1884 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
1886 * configure: Re-generate.
1888 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
1890 * acinclude.m4: Update warning.m4 path.
1892 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
1894 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
1895 (handle_exception): Set siginfo_er.
1896 (win32_xfer_siginfo): New function.
1898 2020-02-07 Tom Tromey <tom@tromey.com>
1899 Pedro Alves <palves@redhat.com>
1901 * README: Update build documentation.
1902 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
1904 * configure.ac: Update paths.
1905 * configure: Rebuild.
1906 * acinclude.m4: Update paths.
1907 * Makefile.in: Update include paths.
1908 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
1909 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
1910 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
1911 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
1912 (%-generated.c): Update paths.
1913 * Move entire directory from ../gdb/gdbserver.
1915 2020-01-29 Maciej W. Rozycki <macro@wdc.com>
1917 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
1919 2020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1921 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
1922 assignment instead of srv_linux_obj.
1924 2020-01-28 Hannes Domani <ssbssa@yahoo.de>
1926 * server.c (handle_qxfer_libraries): Write segment-address with
1929 2020-01-24 Hannes Domani <ssbssa@yahoo.de>
1931 * Makefile.in (install-strip): New target.
1932 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
1933 * aclocal.m4: Regenerate.
1934 * configure: Regenerate.
1935 * configure.ac: Add AM_PROG_INSTALL_STRIP.
1937 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
1939 * Makefile.in (SFILES): Adjust paths to point to real files.
1940 (OBS): Move waitstatus.o to target/waitstatus.o.
1941 (TAGS): Transform paths appropriately.
1943 (nat/%.o): ... this pattern rule.
1945 (target/%.o): ... this pattern rule.
1946 * configure.srv: Adjust paths throughout to include nat/ prefix
1947 with the revant files.
1948 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
1949 * configure: Regenerate.
1951 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
1953 * Makefile.in (TAGS): Remove config files from the recipe.
1955 2020-01-14 Tom Tromey <tom@tromey.com>
1957 * configure: Rebuild.
1958 * configure.ac: Remove any checks that were added to common.m4.
1959 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
1962 2020-01-14 Tom Tromey <tom@tromey.com>
1964 * server.h: Include config.h.
1965 * gdbreplay.c: Include config.h.
1966 * configure: Rebuild.
1967 * configure.ac: Don't source common.host.
1968 * acinclude.m4: Update path.
1969 * Makefile.in (INCSUPPORT): New variable.
1970 (INCLUDE_CFLAGS): Add INCSUPPORT.
1971 (SFILES): Update paths.
1972 (version-generated.c): Update path to create-version.sh.
1973 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
1975 2020-01-14 Tom Tromey <tom@tromey.com>
1977 * configure.ac (LIBS): Use WIN32APILIBS.
1978 (USE_WIN32API): Don't define.
1979 * configure: Rebuild.
1981 2020-01-14 Tom Tromey <tom@tromey.com>
1983 * configure: Rebuild.
1985 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1987 * Makefile.in (%-generated.c): Remove rule for files from
1990 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1992 * configure: Re-generate.
1994 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1996 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
1998 * tracepoint.c (stop_tracing, flush_trace_buffer,
1999 about_to_request_buffer_space, get_trace_state_variable_value,
2000 set_trace_state_variable_value, gdb_collect): Add declaration.
2002 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
2004 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
2005 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
2006 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
2007 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
2008 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
2011 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
2013 * inferiors.c: Include gdbsupport/common-inferior.h.
2015 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
2017 * hostio-errno.c: Include hostio.h.
2019 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
2021 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
2024 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
2026 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
2027 * linux-arm-tdesc.h: Include arch/arm.h.
2029 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
2031 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
2033 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
2035 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
2036 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
2038 2020-01-10 Pedro Alves <palves@redhat.com>
2040 * fork-child.c (post_fork_inferior): Pass target down to
2042 * inferiors.c (switch_to_thread): Add process_stratum_target
2044 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
2045 * nto-low.c (nto_target_ops): Now a process_stratum_target.
2046 * linux-low.c (linux_target_ops): Now a process_stratum_target.
2047 * remote-utils.c (prepare_resume_reply): Pass the target to
2049 * target.c (the_target): Now a process_stratum_target.
2050 (done_accessing_memory): Pass the target to switch_to_thread.
2051 (set_target_ops): Ajust to use process_stratum_target.
2052 * target.h (struct target_ops): Rename to ...
2053 (struct process_stratum_target): ... this.
2054 (the_target, set_target_ops): Adjust.
2055 (prepare_to_access_memory): Adjust comment.
2056 * win32-low.c (child_xfer_memory): Adjust to use
2057 process_stratum_target.
2058 (win32_target_ops): Now a process_stratum_target.
2060 2020-01-06 Eli Zaretskii <eliz@gnu.org>
2061 Pedro Alves <palves@redhat.com>
2063 * win32-low.c (get_child_debug_event): Extract the fatal exception
2064 from the exit status and convert to the equivalent Posix signal
2066 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
2067 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
2069 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
2071 * Makefile.in: Use INSTALL_PROGRAM_ENV.
2073 2020-01-01 Joel Brobecker <brobecker@adacore.com>
2075 * server.c (gdbserver_version): Change copyright year to 2020.
2076 * gdbreplay.c (gdbreplay_version): Likewise.
2078 2019-12-19 Christian Biesinger <cbiesinger@google.com>
2080 * configure: Regenerate.
2081 * configure.ac: Quote variable arguments of test.
2083 2019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
2085 * Makefile.in: Fix build with GNU Make 3.81
2087 2019-12-16 Tom Tromey <tromey@adacore.com>
2089 * server.c (get_exec_file): Constify result.
2091 2019-12-10 Christian Biesinger <cbiesinger@google.com>
2093 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
2094 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
2095 * config.in: Regenerate.
2096 * configure: Regenerate.
2097 * configure.ac: Don't check for strerror.
2098 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
2099 Call safe_strerror instead of strerror.
2100 * server.h (strerror): Remove this now-unnecessary declaration.
2101 * tracepoint.c (init_named_socket): Call safe_strerror instead of
2103 (gdb_agent_helper_thread): Likewise.
2104 * utils.c (perror_with_name): Likewise.
2106 2019-11-26 Tom Tromey <tom@tromey.com>
2108 * configure, config.in: Rebuild.
2110 2019-11-26 Tom Tromey <tom@tromey.com>
2112 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
2113 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
2115 * configure, config.in: Rebuild.
2117 2019-11-26 Tom Tromey <tom@tromey.com>
2119 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
2120 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
2121 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
2122 * acinclude.m4: Include ax_pthread.m4.
2123 * config.in, configure: Rebuild.
2125 2019-11-26 Christian Biesinger <cbiesinger@google.com>
2127 * debug.c (debug_set_output): Call safe_strerror instead of
2129 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
2130 (linux_kill_one_lwp): Likewise.
2131 (linux_detach_one_lwp): Likewise.
2132 (linux_wait_for_event_filtered): Likewise.
2133 (store_register): Likewise.
2134 * lynx-low.c (lynx_attach): Likewise.
2135 * mem-break.c (insert_memory_breakpoint): Likewise.
2136 (remove_memory_breakpoint): Likewise.
2137 (delete_fast_tracepoint_jump): Likewise.
2138 (set_fast_tracepoint_jump): Likewise.
2139 (uninsert_fast_tracepoint_jumps_at): Likewise.
2140 (reinsert_fast_tracepoint_jumps_at): Likewise.
2141 * nto-low.c (nto_xfer_memory): Likewise.
2142 (nto_resume): Likewise.
2144 2019-11-20 Luis Machado <luis.machado@linaro.org>
2146 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
2147 instead of register count.
2148 * tdesc.c (tdesc_contains_feature): New function.
2149 * tdesc.h (tdesc_contains_feature): New prototype.
2151 2019-11-15 Christian Biesinger <cbiesinger@google.com>
2153 * Makefile.in: Add safe-strerror.c.
2154 * configure: Regenerate.
2155 * configure.ac: Don't source common.host.
2157 2019-11-15 Christian Biesinger <cbiesinger@google.com>
2159 * config.in: Regenerate.
2160 * configure: Regenerate.
2162 2019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
2164 * ax.c (ax_printf): Handle size_t_arg.
2166 2019-11-06 Christian Biesinger <cbiesinger@google.com>
2168 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
2169 * mi/mi-main.c (output_cores): Likewise.
2170 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
2171 (linux_xfer_osdata_modules): Likewise.
2172 * remote.c (register_remote_support_xml): Likewise.
2173 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
2174 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
2176 2019-11-01 Christian Biesinger <cbiesinger@google.com>
2178 * configure: Regenerate.
2179 * configure.ac: Remove check for strerror_r.
2181 2019-10-31 Christian Biesinger <cbiesinger@google.com>
2183 * config.in: Regenerate.
2184 * configure: Regenerate.
2185 * configure.ac: Also check for strerror_r.
2187 2019-10-31 Christian Biesinger <cbiesinger@google.com>
2189 * ax.h (debug_agent): Remove duplicate declaration.
2191 2019-10-26 Tom de Vries <tdevries@suse.de>
2193 * linux-aarch64-low.c: Fix typos in comments.
2194 * linux-arm-low.c: Same.
2195 * linux-low.c: Same.
2196 * linux-ppc-low.c: Same.
2197 * proc-service.c: Same.
2200 * tracepoint.c: Same.
2201 * win32-low.c: Same.
2203 2019-10-25 Tom Tromey <tromey@adacore.com>
2205 * utils.c (xstrdup): Remove.
2207 2019-10-23 Tom Tromey <tom@tromey.com>
2209 * configure, config.in: Rebuild.
2211 2019-10-23 Tom Tromey <tom@tromey.com>
2213 * configure: Rebuild.
2214 * acinclude.m4: Use m4_include, not sinclude.
2216 2019-10-17 Tom Tromey <tromey@adacore.com>
2218 * configure: Rebuild.
2219 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
2220 in AC_CONFIG_FILES invocation.
2221 * Makefile.in (stamp-h, Makefile): Use new-style config.status
2224 2019-10-16 Christian Biesinger <cbiesinger@google.com>
2226 * server.c: Include xml-builtin.h.
2227 (get_xml_features): Don't declare xml_builtins here.
2229 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
2231 * Makefile.in: Remove references to vec-ipa.o.
2233 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
2235 * Makefile.in: Remove references to vec.c.
2237 2019-10-02 Christian Biesinger <cbiesinger@google.com>
2239 * server.c (server_waiting): Change to bool.
2240 (extended_protocol): Likewise.
2241 (response_needed): Likewise.
2242 (exit_requested): Likewise.
2243 (run_once): Likewise.
2244 (report_no_resumed): Likewise.
2245 (non_stop): Likewise.
2246 (disable_packet_vCont): Likewise.
2247 (disable_packet_Tthread): Likewise.
2248 (disable_packet_qC): Likewise.
2249 (disable_packet_qfThreadInfo): Likewise.
2250 (handle_general_set): Update.
2251 (handle_detach): Update.
2252 (handle_monitor_command): Update.
2253 (handle_query): Update.
2254 (captured_main): Update.
2255 (process_serial_event): Update.
2256 * server.h (server_waiting): Change to bool.
2257 (disable_packet_vCont): Likewise.
2258 (disable_packet_Tthread): Likewise.
2259 (disable_packet_qC): Likewise.
2260 (disable_packet_qfThreadInfo): Likewise.
2261 (run_once): Likewise.
2262 (non_stop): Likewise.
2263 * target.c (target_stop_and_wait): Update.
2265 2019-10-02 Tom Tromey <tromey@adacore.com>
2267 * Makefile.in (SFILES): Add common-inferior.c.
2268 (OBS): Add common-inferior.o.
2269 * server.c (startup_with_shell): Don't define.
2271 2019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
2273 * linux-low.c (linux_low_read_btrace): Update for change to
2276 2019-09-20 Christian Biesinger <cbiesinger@google.com>
2278 * debug.c (debug_threads): Remove comment in favor of the header.
2279 * debug.h (using_threads): Add declaration.
2280 (debug_threads): Add comment.
2281 * linux-aarch64-low.c: Include debug.h and remove declaration of
2283 * nto-low.c: Likewise.
2284 * remote-utils.c: Likewise.
2285 * thread-db.c: Likewise.
2287 2019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
2289 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
2290 and powerpc-cell64l-ipa.o.
2291 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
2292 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
2293 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
2296 * spu-low.c: Remove file.
2298 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
2299 (parse_spufs_run): Remove.
2300 (ppc_get_pc): Remove Cell/B.E. support.
2301 (ppc_set_pc): Likewise.
2302 (ppc_breakpoint_at): Likewise.
2303 (ppc_arch_setup): Likewise.
2304 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
2305 tdesc_powerpc_cell32l.
2306 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
2307 or init_registers_powerpc_cell32l.
2308 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
2309 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
2310 or init_registers_powerpc_cell32l.
2311 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
2312 (init_registers_powerpc_cell32l): Remove prototype.
2313 (init_registers_powerpc_cell64l): Likewise.
2315 * target.h (struct target_ops): Remove qxfer_spu member.
2316 * server.c (handle_qxfer_spu): Remove.
2317 (qxfer_packets): Remove entry for "spu".
2318 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
2319 * linux-low.c (SPUFS_MAGIC): Remove.
2320 (spu_enumerate_spu_ids): Remove.
2321 (linux_qxfer_spu): Remove.
2322 (linux_target_ops): Remove qxfer_spu member.
2323 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
2324 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
2325 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
2327 2019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
2329 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
2330 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
2331 * config.in: Regenerate.
2332 * configure: Regenerate.
2334 2019-08-15 Tom Tromey <tromey@adacore.com>
2336 * target.c (target_write_memory): Use gdb::byte_vector.
2338 2019-08-15 Tom Tromey <tromey@adacore.com>
2340 * tracepoint.c (write_inferior_data_pointer)
2341 (write_inferior_integer, write_inferior_int8)
2342 (write_inferior_uinteger, m_tracepoint_action_download)
2343 (r_tracepoint_action_download, x_tracepoint_action_download)
2344 (l_tracepoint_action_download, clear_inferior_trace_buffer)
2345 (download_agent_expr, download_tracepoint_1)
2346 (download_trace_state_variables, upload_fast_traceframes): Update.
2347 * server.c (gdb_write_memory): Update.
2348 * remote-utils.c (relocate_instruction): Update.
2349 * proc-service.c (ps_pdwrite): Update.
2350 * mem-break.c (remove_memory_breakpoint)
2351 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
2352 (uninsert_fast_tracepoint_jumps_at)
2353 (reinsert_fast_tracepoint_jumps_at): Update.
2354 * linux-x86-low.c (append_insns)
2355 (i386_install_fast_tracepoint_jump_pad)
2356 (amd64_write_goto_address, i386_write_goto_address): Update.
2357 * linux-s390-low.c (append_insns, s390_write_goto_address):
2359 * linux-ppc-low.c (ppc_relocate_instruction)
2360 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
2361 (ppc_write_goto_address): Update.
2362 * linux-aarch64-low.c (append_insns): Update.
2363 * target.h (struct target_ops): Update.
2364 (write_inferior_memory): Don't declare.
2365 * target.c (target_write_memory): Rename from
2366 write_inferior_memory. Remove old target_write_memory.
2368 2019-08-15 Tom Tromey <tromey@adacore.com>
2370 * target.c (write_inferior_memory): Use std::vector.
2372 2019-08-06 Frank Ch. Eigler <fche@redhat.com>
2375 * configure.ac: Drop enable-libmcheck support.
2376 * configure, config.in: Rebuild.
2377 * acinclude.m4: Don't include it.
2379 2019-07-19 Alan Hayward <alan.hayward@arm.com>
2381 * configure.srv: Remove Arm xml files.
2383 2019-07-19 Alan Hayward <alan.hayward@arm.com>
2385 * configure.srv: Add new files. Remove xml generated files.
2386 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
2388 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
2389 * linux-aarch32-tdesc.c: New file.
2390 * linux-aarch32-tdesc.h: New file.
2391 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
2392 * linux-arm-low.c (init_registers_arm, tdesc_arm)
2393 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
2394 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
2395 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
2396 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
2397 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
2398 (arm_read_description): Call arm_linux_read_description.
2399 (initialize_low_arch): Don't init registers.
2400 * linux-arm-tdesc.c: New file.
2401 * linux-arm-tdesc.h: New file.
2403 2019-07-10 Alan Hayward <alan.hayward@arm.com>
2405 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
2406 Move counter inside for.
2407 (arm_read_description): Check ptrace earlier.
2408 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
2410 2019-07-09 Tom Tromey <tom@tromey.com>
2412 * configure: Rebuild.
2413 * configure.ac: Change common to gdbsupport.
2414 * acinclude.m4: Change common to gdbsupport.
2415 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
2416 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
2417 common to gdbsupport.
2418 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
2419 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
2420 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
2421 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
2422 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
2423 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
2424 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
2425 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
2426 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
2427 common to gdbsupport.
2429 2019-07-04 Alan Hayward <alan.hayward@arm.com>
2431 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
2433 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
2435 2019-07-04 Alan Hayward <alan.hayward@arm.com>
2437 * configure.srv: Remove legacy xml.
2438 * linux-aarch64-low.c (initialize_low_arch): Remove
2439 initialize_low_tdesc call.
2440 * linux-aarch64-tdesc-selftest.c: Remove file.
2441 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
2442 * linux-x86-low.c (initialize_low_arch): Remove
2443 initialize_low_tdesc call.
2444 * linux-x86-tdesc-selftest.c: Remove file.
2445 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
2447 2019-06-20 Tom de Vries <tdevries@suse.de>
2449 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
2450 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
2452 2019-06-19 Tom de Vries <tdevries@suse.de>
2454 * debug.h (debug_write): Change return type to ssize_t.
2455 * debug.c (debug_write): Same.
2457 2019-06-14 Tom Tromey <tom@tromey.com>
2459 * configure.ac: Use new path to gnulib.
2460 * configure: Rebuild.
2461 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
2464 2019-06-11 Tom Tromey <tom@tromey.com>
2466 * Makefile.in (SFILES): Add alloc.c.
2468 (IPA_OBJS): Add alloc-ipa.o.
2469 (alloc-ipa.o): New target.
2470 (%.o: ../%.c): New pattern rule.
2472 2019-06-10 Tom Tromey <tromey@adacore.com>
2474 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
2475 end warning with a newline.
2476 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
2478 * thread-db.c (attach_thread): Don't end warning with a newline.
2479 (thread_db_notice_clone): Likewise.
2480 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
2482 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
2483 end warning with a newline.
2485 2019-06-04 Pedro Alves <palves@redhat.com>
2487 * server.c (captured_main): Use make_unique_xstrdup.
2489 2019-06-02 Tom Tromey <tom@tromey.com>
2491 * gdbreplay.c (fromhex): Remove.
2492 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
2494 2019-05-29 Tom Tromey <tromey@adacore.com>
2496 * configure: Rebuild.
2498 2019-05-06 Kevin Buettner <kevinb@redhat.com>
2500 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
2501 sign extension code on 32-bit builds.
2503 2019-05-03 Eli Zaretskii <eliz@gnu.org>
2506 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
2508 2019-04-19 Tom Tromey <tom@tromey.com>
2510 * server.c (struct vstop_notif): Derive from notif_event.
2512 (queue_stop_reply): Update.
2513 (remove_all_on_match_ptid): Change type. Rewrite.
2514 (discard_queued_stop_replies): Rewrite.
2515 (in_queued_stop_replies_ptid): Change type.
2516 (in_queued_stop_replies): Rewrite.
2517 (notif_stop): Update.
2518 (queue_stop_reply_callback): Update.
2519 (captured_main): Don't call initialize_notif.
2520 (push_stop_notification): Update.
2521 * notif.c (notif_write_event, handle_notif_ack)
2522 (notif_event_enque, notif_push): Update.
2523 (notif_event_xfree, initialize_notif): Remove.
2524 * notif.h (struct notif_event): Include <list>, not
2526 (struct notif_server) <queue>: Now a std::list.
2527 (notif_event_p): Remove typedef.
2528 (initialize_notif): Don't declare.
2529 (struct notif_event): Add virtual destructor.
2531 2019-04-17 Alan Hayward <alan.hayward@arm.com>
2533 * ax.c (ax_vdebug): Call debug_printf.
2534 * debug.c (debug_write): New function.
2535 * debug.h (debug_write): New declaration.
2536 * linux-low.c (sigchld_handler): Call debug_write.
2538 2019-04-17 Alan Hayward <alan.hayward@arm.com>
2540 * debug.c (debug_set_output): New function.
2541 (debug_vprintf): Send output to debug_file.
2542 (debug_flush): Likewise.
2543 * debug.h (debug_set_output): New declaration.
2544 * server.c (handle_monitor_command): Add debug-file option.
2545 (captured_main): Likewise.
2547 2019-04-17 Alan Hayward <alan.hayward@arm.com>
2549 * debug.c (remote_debug): Add definition.
2550 * debug.h (remote_debug): Add declaration.
2551 * hostio.c (remote_debug): Remove declaration.
2552 * remote-utils.c (struct ui_file): Likewise.
2553 (remote_debug): Likewise.
2554 * remote-utils.h (remote_debug): Likewise,
2555 * server.c (remote_debug): Remove definition.
2557 2019-04-10 Kevin Buettner <kevinb@redhat.com>
2559 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
2560 when using a 64-bit gdbserver.
2562 2019-04-09 Tom Tromey <tromey@adacore.com>
2564 * linux-low.c (select_event_lwp): Use find_thread_in_random.
2566 2019-04-08 Tom Tromey <tom@tromey.com>
2568 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
2570 (linux_resume_one_lwp): Likewise.
2572 2019-04-08 Tom Tromey <tom@tromey.com>
2574 * gdbreplay.c: Update.
2575 * linux-low.c: Update.
2578 2019-04-08 Tom Tromey <tom@tromey.com>
2580 * server.c: Use C++ exception handling.
2581 * linux-low.c: Use C++ exception handling.
2582 * gdbreplay.c: Use C++ exception handling.
2584 2019-04-08 Tom Tromey <tom@tromey.com>
2586 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
2587 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
2588 (captured_main, main): Update.
2589 * gdbreplay.c (main): Update.
2591 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2593 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
2594 value in argument pointer, return 1 if the entry is found and 0
2595 otherwise. Move comment.
2596 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
2597 * linux-low.h (linux_get_auxv): Declare.
2598 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
2600 2019-04-05 Tom Tromey <tromey@adacore.com>
2602 * server.c (gdbserver_usage): Use upper-case for metasyntactic
2605 2019-03-28 Alan Hayward <alan.hayward@arm.com>
2607 * linux-low.c (AT_HWCAP2): Add define if not already included.
2609 2019-03-26 Alan Hayward <alan.hayward@arm.com>
2611 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
2612 (aarch64_arch_setup): Call linux_get_hwcap.
2613 * linux-arm-low.c (arm_get_hwcap): Remove function.
2614 (arm_read_description): Call linux_get_hwcap.
2615 * linux-low.c (linux_get_auxv): New function.
2616 (linux_get_hwcap): Likewise.
2617 (linux_get_hwcap2): Likewise.
2618 * linux-low.h (linux_get_hwcap): New declaration.
2619 (linux_get_hwcap2): Likewise.
2620 * linux-ppc-low.c (ppc_get_auxv): Remove function.
2621 (ppc_arch_setup): Call linux_get_hwcap.
2622 * linux-s390-low.c (s390_get_hwcap): Remove function.
2623 (s390_arch_setup): Call linux_get_hwcap.
2625 2019-03-22 Alan Hayward <alan.hayward@arm.com>
2626 Jiong Wang <jiong.wang@arm.com>
2628 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
2629 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
2631 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
2633 2019-03-22 Alan Hayward <alan.hayward@arm.com>
2634 Jiong Wang <jiong.wang@arm.com>
2636 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
2637 (aarch64_get_hwcap): New function.
2638 (aarch64_arch_setup): Read APIA hwcap.
2640 2019-03-22 Alan Hayward <alan.hayward@arm.com>
2641 Jiong Wang <jiong.wang@arm.com>
2643 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
2644 (initialize_low_tracepoint): Likewise.
2645 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
2646 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
2647 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
2648 (aarch64_linux_read_description): Likewise.
2649 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
2651 2019-03-12 John Baldwin <jhb@FreeBSD.org>
2653 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
2654 i386_create_target_description for 'segments' parameter.
2655 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
2656 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
2657 * win32-i386-low.c (i386_arch_setup): Likewise.
2659 2019-03-12 Tom Tromey <tromey@adacore.com>
2661 * linux-low.c (iterate_over_lwps): Update.
2663 2019-03-06 Tom Tromey <tom@tromey.com>
2665 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
2666 (captured_main): Use SCOPE_EXIT.
2668 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
2670 * configure.srv: Use '$enable_unittest' instead of '$development'
2671 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
2674 2019-02-27 Tom Tromey <tromey@adacore.com>
2676 * gdbreplay.c (logchar): Handle \r\n.
2678 2019-02-07 Alan Hayward <alan.hayward@arm.com>
2680 * linux-low.c (linux_attach): Add process before lwp.
2681 * server.c (attach_inferior): Check if already attached.
2683 2019-02-07 Tom Tromey <tom@tromey.com>
2685 * x86-tdesc.h: Rename include guard.
2686 * x86-low.h: Add include guard.
2687 * wincecompat.h: Rename include guard.
2688 * win32-low.h: Add include guard.
2689 * utils.h: Rename include guard.
2690 * tracepoint.h: Rename include guard.
2691 * tdesc.h: Rename include guard.
2692 * target.h: Rename include guard.
2693 * server.h: Rename include guard.
2694 * remote-utils.h: Rename include guard.
2695 * regcache.h: Rename include guard.
2696 * nto-low.h: Rename include guard.
2697 * notif.h: Add include guard.
2698 * mem-break.h: Rename include guard.
2699 * lynx-low.h: Add include guard.
2700 * linux-x86-tdesc.h: Add include guard.
2701 * linux-s390-tdesc.h: Add include guard.
2702 * linux-ppc-tdesc-init.h: Add include guard.
2703 * linux-low.h: Add include guard.
2704 * linux-aarch64-tdesc.h: Add include guard.
2705 * linux-aarch32-low.h: Add include guard.
2706 * inferiors.h: Rename include guard.
2707 * i387-fp.h: Rename include guard.
2708 * hostio.h: Rename include guard.
2709 * gdbthread.h: Rename include guard.
2710 * gdb_proc_service.h: Rename include guard.
2711 * event-loop.h: Rename include guard.
2712 * dll.h: Rename include guard.
2713 * debug.h: Rename include guard.
2714 * ax.h: Rename include guard.
2716 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
2719 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
2720 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
2722 2019-01-25 Tom Tromey <tom@tromey.com>
2724 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
2726 2019-01-25 Tom Tromey <tom@tromey.com>
2728 * win32-low.c: Fix common/ includes.
2729 * win32-i386-low.c: Fix common/ includes.
2730 * tracepoint.c: Fix common/ includes.
2731 * thread-db.c: Fix common/ includes.
2732 * target.h: Fix common/ includes.
2733 * symbol.c: Fix common/ includes.
2734 * spu-low.c: Fix common/ includes.
2735 * server.h: Fix common/ includes.
2736 * server.c: Fix common/ includes.
2737 * remote-utils.c: Fix common/ includes.
2738 * regcache.h: Fix common/ includes.
2739 * regcache.c: Fix common/ includes.
2740 * nto-x86-low.c: Fix common/ includes.
2741 * notif.h: Fix common/ includes.
2742 * mem-break.h: Fix common/ includes.
2743 * lynx-low.c: Fix common/ includes.
2744 * lynx-i386-low.c: Fix common/ includes.
2745 * linux-x86-tdesc-selftest.c: Fix common/ includes.
2746 * linux-x86-low.c: Fix common/ includes.
2747 * linux-low.c: Fix common/ includes.
2748 * inferiors.h: Fix common/ includes.
2749 * i387-fp.c: Fix common/ includes.
2750 * hostio.c: Fix common/ includes.
2751 * hostio-errno.c: Fix common/ includes.
2752 * gdbthread.h: Fix common/ includes.
2753 * gdbreplay.c: Fix common/ includes.
2754 * fork-child.c: Fix common/ includes.
2755 * event-loop.c: Fix common/ includes.
2757 (enum gdb_agent_op): Fix common/ includes.
2759 2019-01-21 Tom Tromey <tom@tromey.com>
2761 * tracepoint.c: Fix includes.
2762 * remote-utils.c: Fix includes.
2763 * linux-x86-low.c: Fix includes.
2765 2019-01-01 Joel Brobecker <brobecker@adacore.com>
2767 * gdbreplay.c (gdbreplay_version): Update copyright year in
2769 * server.c (gdbserver_version): Likewise.
2771 2018-12-05 Alan Hayward <alan.hayward@arm.com>
2773 * linux-low.c (add_lwp): Switch ordering.
2775 2018-11-29 Tom Tromey <tom@tromey.com>
2777 * win32-low.c (win32_join): Take pid, not process.
2778 * target.h (struct target_ops) <join>: Change argument type.
2779 (join_inferior): Change argument name.
2780 * spu-low.c (spu_join): Take pid, not process.
2781 * server.c (handle_detach): Preserve pid before destroying
2783 * lynx-low.c (lynx_join): Take pid, not process.
2784 * linux-low.c (linux_join): Take pid, not process.
2786 2018-11-23 Alan Hayward <alan.hayward@arm.com>
2788 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
2789 (aarch64_cannot_fetch_register): Likewise.
2790 (struct linux_target_ops): Update references.
2792 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2794 * linux-ppc-low.c: Include nat/linux-ptrace.h.
2796 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2798 * configure.srv (ipa_ppc_linux_regobj): Add
2799 powerpc-isa207-htm-vsx32l-ipa.o and
2800 powerpc-isa207-htm-vsx64l-ipa.o.
2801 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
2802 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
2803 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
2804 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
2805 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
2806 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
2807 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
2808 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
2809 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
2810 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
2811 (init_registers_powerpc_isa207_htm_vsx32l)
2812 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
2813 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
2814 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
2815 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
2816 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
2817 (ppc_store_tm_ctarregset): New functions.
2818 (ppc_regsets): Add entries for HTM regsets.
2819 (ppc_arch_setup): Set htm in features struct when needed. Set
2820 sizes for the HTM regsets.
2821 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
2822 (initialize_low_arch): Call
2823 init_registers_powerpc_isa207_htm_vsx32l and
2824 init_registers_powerpc_isa207_htm_vsx64l.
2825 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
2826 PPC_TDESC_ISA207_HTM_VSX.
2827 (initialize_low_tracepoint): Call
2828 init_registers_powerpc_isa207_htm_vsx32l and
2829 init_registers_powerpc_isa207_htm_vsx64l.
2831 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2833 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
2834 rs6000/power-linux-pmu.xml to srv_xmlfiles.
2835 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
2836 (ppc_store_pmuregset): New functions.
2837 (ppc_regsets): Add entries for ebb and pmu regsets.
2838 (ppc_arch_setup): Set isa207 in features struct if the ebb and
2839 pmu regsets are available. Set sizes for these regsets.
2841 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2843 * configure.srv (ipa_ppc_linux_regobj): Add
2844 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
2845 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
2846 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
2847 rs6000/powerpc-isa207-vsx32l.xml, and
2848 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
2849 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
2850 <PPC_TDESC_ISA207_VSX>: New enum value.
2851 (init_registers_powerpc_isa207_vsx32l): Declare.
2852 (init_registers_powerpc_isa207_vsx64l): Declare.
2853 * linux-ppc-low.c (ppc_fill_tarregset): New function.
2854 (ppc_store_tarregset): New function.
2855 (ppc_regsets): Add entry for the TAR regset.
2856 (ppc_arch_setup): Set isa207 in features struct when needed. Set
2857 size for the TAR regsets.
2858 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
2859 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
2860 and init_registers_powerpc_isa207_vsx64l.
2861 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
2862 (initialize_low_tracepoint): Call
2863 init_registers_powerpc_isa207_vsx32l and
2864 init_registers_powerpc_isa207_vsx64l.
2866 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
2867 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2869 * configure.srv (ipa_ppc_linux_regobj): Add
2870 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
2871 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
2872 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
2873 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
2874 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
2875 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
2876 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
2877 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
2878 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
2879 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
2880 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
2881 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
2882 (ppc_hwcap): Add comment.
2883 (ppc_hwcap2): New global.
2884 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
2885 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
2886 (ppc_regsets): Add entries for the DSCR and PPR regsets.
2887 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
2888 when needed. Set sizes for the the DSCR and PPR regsets.
2889 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
2890 (initialize_low_arch): Call
2891 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
2892 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
2893 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
2894 PPC_TDESC_ISA205_PPR_DSCR_VSX.
2895 (initialize_low_tracepoint): Call
2896 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
2897 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
2899 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2901 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
2903 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
2904 Simon Marchi <simark@simark.ca>
2906 * acinclude.m4: Include "../selftest.m4".
2907 * configure: Regenerate.
2908 * configure.ac: Use "GDB_AC_SELFTEST".
2909 * configure.srv: Use "$enable_unittests" instead of
2910 "$development" when checking whether unit tests have been
2912 * server.c (captured_main): Update message informing that
2913 selftests have been disabled.
2915 2018-10-04 Tom Tromey <tom@tromey.com>
2917 * configure: Rebuild.
2919 2018-10-04 Tom Tromey <tom@tromey.com>
2921 * server.c (handle_status): Rename inner "thread".
2922 (process_serial_event): Declare "res" in 'm' case.
2923 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
2924 (iterate_over_lwps): Rename inner "thread".
2925 (linux_qxfer_libraries_svr4): Rename inner "len".
2926 * gdbthread.h (find_thread_in_random): Rename inner "thread".
2928 2018-10-01 Gary Benson <gbenson@redhat.com>
2930 * gdb_proc_service.h: Moved common code to
2931 common/gdb_proc_service.h.
2933 2018-10-01 Gary Benson <gbenson@redhat.com>
2935 * gdb_proc_service.h: Synchronize comments and whitespace with
2936 GDB's version of this file.
2938 2018-09-25 Tom Tromey <tom@tromey.com>
2940 * configure: Rebuild.
2941 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
2943 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
2945 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
2946 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
2947 ($(IPA_LIB)): Sort IPA_OBJS.
2949 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
2951 * Makefile.in: Remove references to $(ADD_DEPS).
2953 2018-09-16 Tom Tromey <tom@tromey.com>
2955 * remote-utils.c (remote_open): Use GNU style for metasyntactic
2957 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
2960 2018-09-05 Tom Tromey <tom@tromey.com>
2962 * configure: Rebuild.
2964 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
2967 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
2969 2018-08-27 Tom Tromey <tom@tromey.com>
2972 * configure: Rebuild.
2974 2018-08-27 Tom Tromey <tom@tromey.com>
2976 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
2977 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
2978 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
2979 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
2980 (s390x_emit_stack_adjust): Add casts to unsigned char.
2982 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
2986 * server.h (struct client_state) <disable_randomization>:
2989 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2991 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
2993 (mips_supply_ptrace_register): Likewise.
2995 2018-07-22 Tom Tromey <tom@tromey.com>
2997 * configure: Rebuild.
2999 2018-07-22 Tom Tromey <tom@tromey.com>
3001 * win32-low.c (win32_create_inferior): Remove unused variables.
3002 * gdbreplay.c (remote_open): Remove unused variable.
3003 * remote-utils.c (remote_prepare): Remove unused variable.
3004 * x86-tdesc.h (X86_TDESC_H): Define.
3005 (amd64_expedite_regs): Define conditionally.
3006 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
3007 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
3008 * remote-utils.c (readchar): Remove unused variable.
3010 2018-07-13 Pedro Alves <palves@redhat.com>
3012 * linux-low.c (linux_kill): Change parameter to process_info
3013 pointer instead of pid. Adjust.
3014 * lynx-low.c (lynx_kill): Likewise.
3015 * nto-low.c (nto_kill): Likewise.
3016 * spu-low.c (spu_kill): Likewise.
3017 * win32-low.c (win32_kill): Likewise.
3018 * server.c (handle_v_kill, kill_inferior_callback)
3019 (detach_or_kill_for_exit): Adjust.
3020 * target.c (kill_inferior): Change parameter to process_info
3021 pointer instead of pid. Adjust.
3022 * target.h (struct target_ops) <kill>: Change parameter to
3023 process_info pointer instead of pid. Adjust all implementations
3025 (kill_inferior): Likewise.
3027 2018-07-13 Pedro Alves <palves@redhat.com>
3029 * linux-low.c (linux_detach, linux_join): Change parameter to
3030 process_info pointer instead of pid. Adjust.
3031 * lynx-low.c (lynx_detach, lynx_join): Likewise.
3032 * nto-low.c (nto_detach): Likewise.
3033 * spu-low.c (spu_detach, spu_join): Likewise.
3034 * win32-low.c (win32_detach, win32_join): Likewise.
3035 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
3036 * target.h (struct target_ops) <detach, join>: Change parameter to
3037 process_info pointer instead of pid. Adjust all implementations
3039 (detach_inferior, join_inferior): Rename 'pid' parameter to
3042 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
3043 Jan Kratochvil <jan.kratochvil@redhat.com>
3044 Paul Fertser <fercerpav@gmail.com>
3045 Tsutomu Seki <sekiriki@gmail.com>
3047 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
3048 (OBS): Add 'common/netstuff.o'.
3049 (GDBREPLAY_OBS): Likewise.
3050 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
3051 (remote_open): Implement support for IPv6
3053 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
3055 (handle_accept_event): Accept connections from IPv6 sources.
3056 (remote_prepare): Handle IPv6-style hostnames; implement
3057 support for IPv6 connections.
3058 (remote_open): Implement support for printing connections from
3061 2018-07-11 Pedro Alves <palves@redhat.com>
3064 * mem-break.c (any_persistent_commands): Add process_info
3065 parameter and use it instead of relying on the current process.
3066 Change return type to bool.
3067 * mem-break.h (any_persistent_commands): Add process_info
3068 parameter and change return type to bool.
3069 * server.c (handle_detach): Remove require_running_or_return call.
3070 Look up the process_info for the process we're about to detach.
3071 If not found, return back error to GDB. Adjust
3072 any_persistent_commands call to pass down a process pointer.
3074 2018-07-11 Pedro Alves <palves@redhat.com>
3076 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
3077 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
3078 instead of collect_register_by_name.
3079 * regcache.c (regcache_raw_get_unsigned_by_name): New.
3080 * regcache.h (regcache_raw_get_unsigned_by_name): New.
3082 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
3083 Pedro Alves <palves@redhat.com>
3085 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
3087 2018-07-03 Tom Tromey <tom@tromey.com>
3089 * linux-low.c: Update.
3090 * lynx-low.c: Update.
3091 * mem-break.c: Update.
3092 * nto-low.c: Update.
3093 * remote-utils.c: Update.
3095 * spu-low.c: Update.
3097 * win32-low.c: Update.
3099 2018-07-03 Tom Tromey <tom@tromey.com>
3103 2018-07-03 Tom Tromey <tom@tromey.com>
3105 * linux-low.c: Update.
3107 2018-07-03 Tom Tromey <tom@tromey.com>
3111 2018-07-03 Tom Tromey <tom@tromey.com>
3113 * linux-low.c: Update.
3114 * linux-mips-low.c: Update.
3115 * lynx-low.c: Update.
3116 * nto-low.c: Update.
3117 * remote-utils.c: Update.
3119 * spu-low.c: Update.
3121 * thread-db.c: Update.
3123 2018-07-03 Tom Tromey <tom@tromey.com>
3125 * linux-low.c: Update.
3126 * linux-mips-low.c: Update.
3127 * lynx-low.c: Update.
3128 * mem-break.c: Update.
3129 * nto-low.c: Update.
3130 * remote-utils.c: Update.
3132 * spu-low.c: Update.
3134 * tracepoint.c: Update.
3136 2018-07-03 Tom Tromey <tom@tromey.com>
3138 * linux-low.c: Update.
3139 * linux-ppc-low.c: Update.
3140 * linux-x86-low.c: Update.
3141 * proc-service.c: Update.
3143 * spu-low.c: Update.
3144 * thread-db.c: Update.
3145 * win32-low.c: Update.
3147 2018-07-03 Tom Tromey <tom@tromey.com>
3149 * linux-low.c: Update.
3150 * lynx-low.c: Update.
3151 * nto-low.c: Update.
3152 * remote-utils.c: Update.
3153 * spu-low.c: Update.
3154 * thread-db.c: Update.
3155 * win32-low.c: Update.
3157 2018-06-29 Joel Brobecker <brobecker@adacore.com>
3159 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
3160 parameter in call to 'amd64_create_target_description'.
3162 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
3164 * x86-tdesc.h: Remove executable permission flag.
3166 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
3168 * configure.ac: Remove AC_PREREQ, add missing quoting.
3169 * configure: Re-generate.
3170 * config.in: Re-generate.
3171 * aclocal.m4: Re-generate.
3173 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
3175 * tracepoint.h (current_traceframe): Remove declaration.
3177 2018-06-18 Alan Hayward <alan.hayward@arm.com>
3179 * linux-aarch64-low.c (is_sve_tdesc): New function.
3180 (aarch64_sve_regs_copy_to_regcache): Likewise.
3181 (aarch64_sve_regs_copy_from_regcache): Likewise.
3182 (aarch64_regs_info): Add SVE checks.
3183 (initialize_low_arch): Initialize SVE.
3185 2018-06-18 Alan Hayward <alan.hayward@arm.com>
3187 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
3189 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3191 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
3192 (initialize_low_tracepoint): Likewise
3193 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
3194 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
3196 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
3198 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
3200 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3202 * server.h (PBUFSIZ): Increase size
3204 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3206 * regcache.c (regcache::raw_compare): New function.
3207 * regcache.h (regcache::raw_compare): New declaration.
3209 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3211 * regcache.c (new_register_cache): Use new.
3212 (free_register_cache): Use delete.
3213 (register_data): Use const.
3214 (supply_register): Move body inside regcache.
3215 (regcache::raw_supply): New override function.
3216 (collect_register): Move body inside regcache.
3217 (regcache::raw_collect): New override function.
3218 (regcache::get_register_status): New override function.
3219 * regcache.h (struct regcache): Inherit from reg_buffer_common.
3221 2018-06-09 Tom Tromey <tom@tromey.com>
3223 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
3225 (event_queue): Use std::queue.
3226 (gdb_event_xfree): Remove.
3227 (initialize_event_loop, process_event, wait_for_event): Update.
3229 2018-06-08 Stan Cox <scox@redhat.com>
3231 * win32-low.c (win32_create_inferior): last_ptid and last_status
3232 moved to client_state.
3234 2018-06-08 Pedro Alves <palves@redhat.com>
3236 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
3237 common/common-exceptions.o, common/common-utils.o,
3238 common/errors.o, common/print-utils.o and utils.o.
3239 * gdbreplay.c: Include "common-defs.h" instead of the two
3240 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
3241 string.h or alloca.h.
3242 (perror_with_name): Delete.
3243 (remote_open): Use xstrdup instead of strdup.
3244 (main): Rename to ...
3245 (captured_main): ... this.
3248 2018-06-08 Tom Tromey <tom@tromey.com>
3250 * linux-low.c (linux_low_read_btrace): Update.
3252 2018-06-04 Stan Cox <scox@redhat.com>
3254 * server.h (struct client_state): New.
3255 * server.c (cont_thread, general_thread, multi_process)
3256 (report_fork_events, report_vfork_events, report_exec_events)
3257 (report_thread_events, swbreak_feature, hwbreak_feature)
3258 (vCont_supported, disable_randomization, pass_signals)
3259 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
3260 Moved to client_state.
3261 * remote-utils.c (remote_debug, noack_mode)
3262 (transport_is_reliable): Moved to client_state.
3263 * tracepoint.c (current_traceframe): Moved to client_state.
3266 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
3267 linux-low.c, remote-utils.h, target.c: Use client_state.
3269 2018-05-31 Alan Hayward <alan.hayward@arm.com>
3271 * configure.srv: Add new c/h file.
3273 2018-05-31 Alan Hayward <alan.hayward@arm.com>
3275 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
3278 2018-05-25 Maciej W. Rozycki <macro@mips.com>
3280 * gdb.arch/mips-fpregset-core.exp: New test.
3281 * gdb.arch/mips-fpregset-core.c: New test source.
3283 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
3286 * hostio.c (require_int): Do not report overflow for integers
3287 between 0xfffffff and 0x7fffffff.
3289 2018-05-22 Maciej W. Rozycki <macro@mips.com>
3291 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
3292 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
3293 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
3295 (the_low_target): Wire them.
3297 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3299 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
3300 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
3301 mode. Call collect_register_by_name with vscr using
3302 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
3303 (ppc_store_vrregset): Add and set vscr_offset variable as in
3304 ppc_fill_vrregset. Call supply_register_by_name with vscr using
3307 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3309 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
3310 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
3311 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
3313 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3315 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
3316 (ppc_store_vsxregset): Likewise.
3317 (ppc_fill_vrregset): Likewise.
3318 (ppc_store_vrregset): Likewise.
3319 (ppc_fill_evrregset): Likewise.
3320 (ppc_store_evrregset): Likewise.
3321 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
3322 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
3325 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3327 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
3328 wordsize of the inferior. Call ppc_linux_target_wordsize.
3330 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3332 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
3333 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
3334 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
3335 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
3336 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
3337 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
3338 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
3339 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
3340 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
3341 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
3342 (tdesc_powerpc_e500l): Remove.
3343 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
3344 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
3345 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
3346 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
3348 (ppc_arch_setup): Remove target description matching code. Fill a
3349 ppc_linux_features struct and call ppc_linux_match_description
3352 2018-05-22 Maciej W. Rozycki <macro@mips.com>
3354 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
3355 width of the requested register exceeds the width of the
3357 (mips_cannot_store_register): Likewise.
3359 2018-05-21 Maciej W. Rozycki <macro@mips.com>
3361 * linux-mips-low.c (mips_fetch_register): New function. Update
3363 (mips_store_gregset): Supply 0 rather than $restart for $zero.
3364 (the_low_target): Wire `mips_fetch_register'.
3366 2018-05-10 Joel Brobecker <brobecker@adacore.com>
3368 * lynx-i386-low.c (LYNXOS_178): New macro.
3369 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
3370 the layout on LynxOS-178.
3371 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
3372 handle floating point registers that are not supported by
3375 2018-05-10 Tom Tromey <tom@tromey.com>
3377 * configure: Rebuild.
3379 2018-05-10 Joel Brobecker <brobecker@adacore.com>
3382 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
3383 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
3384 Use it to set the expedite_regs field in the given tdesc.
3385 * x86-tdesc.h: New file.
3386 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
3387 Adjust following the addition of the new expedite_regs parameter
3388 to init_target_desc.
3389 * linux-tic6x-low.c (tic6x_read_description): Likewise.
3390 * linux-x86-tdesc.c: #include "x86-tdesc.h".
3391 (i386_linux_read_description, amd64_linux_read_description):
3392 Adjust following the addition of the new expedite_regs parameter
3393 to init_target_desc.
3394 * lynx-i386-low.c: #include "x86-tdesc.h".
3395 (lynx_i386_arch_setup): Adjust following the addition of the new
3396 expedite_regs parameter to init_target_desc.
3397 * nto-x86-low.c: #include "x86-tdesc.h".
3398 (nto_x86_arch_setup): Adjust following the addition of the new
3399 expedite_regs parameter to init_target_desc.
3400 * win32-i386-low.c: #include "x86-tdesc.h".
3401 (i386_arch_setup): Adjust following the addition of the new
3402 expedite_regs parameter to init_target_desc.
3404 2018-05-10 Joel Brobecker <brobecker@adacore.com>
3407 * win32-low.c (win32_create_inferior): Add call to my_wait
3408 setting last_status global.
3410 2018-05-10 Joel Brobecker <brobecker@adacore.com>
3413 * win32-low.c (create_process): Only call gdb_tilde_expand if
3414 inferior_cwd is not NULL.
3416 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
3418 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
3419 registers to the cache if their values have changed.
3420 (i387_xsave_to_cache): Provide default values for x87 control
3421 registers when these features are available, but disabled.
3422 * regcache.c (supply_register_by_name_zeroed): New function.
3423 * regcache.h (supply_register_by_name_zeroed): Declare new
3426 2018-05-07 Tom Tromey <tom@tromey.com>
3428 * configure: Rebuild.
3430 2018-05-04 Tom Tromey <tom@tromey.com>
3432 * configure: Rebuild.
3434 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
3435 Pedro Alves <palves@redhat.com>
3437 * linux-aarch64-low.c (aarch64_stopped_data_address):
3440 2018-04-27 Tom Tromey <tom@tromey.com>
3442 * configure: Rebuild.
3444 2018-04-23 Tom Tromey <tom@tromey.com>
3446 * configure: Rebuild.
3448 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
3450 * Makefile.in (depcomp): Add "..".
3451 (all_deps_files): New and use it.
3453 2018-04-18 Alan Hayward <alan.hayward@arm.com>
3455 * configure.srv (aarch64*-*-linux*): Don't include xml.
3456 (i[34567]86-*-cygwin*): Likewise.
3457 (i[34567]86-*-linux*): Likewise.
3458 (i[34567]86-*-lynxos*): Likewise.
3459 (i[34567]86-*-mingw32ce*): Likewise.
3460 (i[34567]86-*-mingw*): Likewise.
3461 (i[34567]86-*-nto*): Likewise.
3462 (tic6x-*-uclinux): Likewise.
3463 (x86_64-*-linux*): Likewise.
3464 (x86_64-*-mingw*): Likewise.
3465 (x86_64-*-cygwin*): Likewise.
3467 2018-04-18 Alan Hayward <alan.hayward@arm.com>
3469 * tdesc.c: Remove xml parameter.
3471 2018-04-18 Alan Hayward <alan.hayward@arm.com>
3473 * server.c (get_features_xml): Remove cast.
3474 * tdesc.c (void target_desc::accept): Fill in function.
3475 (tdesc_get_features_xml): Remove old xml creation.
3476 (print_xml_feature::visit_pre): Add xml vistor.
3477 * tdesc.h (struct target_desc): Make xmltarget mutable.
3478 (tdesc_get_features_xml): Remove declaration.
3480 2018-04-18 Alan Hayward <alan.hayward@arm.com>
3482 * tdesc.c (tdesc_architecture_name): Add new function.
3483 (tdesc_osabi_name): Likewise.
3484 (tdesc_get_features_xml): Use new functions.
3486 2018-04-18 Alan Hayward <alan.hayward@arm.com>
3488 * tdesc.c (tdesc_create_flags): Remove.
3489 (tdesc_add_flag): Likewise.
3490 (tdesc_named_type): Likewise.
3491 (tdesc_create_union): Likewise.
3492 (tdesc_create_struct): Likewise.
3493 (tdesc_create_vector): Likewise.
3494 (tdesc_add_bitfield): Likewise.
3495 (tdesc_add_field): Likewise.
3496 (tdesc_set_struct_size): Likewise.
3498 2018-04-18 Alan Hayward <alan.hayward@arm.com>
3500 * tdesc.c (~target_desc): Remove implictly deleted items.
3501 (init_target_desc): Iterate all features.
3502 (tdesc_get_features_xml): Use vector.
3503 (tdesc_create_feature): Create feature.
3504 * tdesc.h (tdesc_feature) Remove
3505 (target_desc): Add features.
3507 2018-04-18 Alan Hayward <alan.hayward@arm.com>
3509 * Makefile.in: Add common/tdesc.c
3510 * tdesc.c (init_target_desc): init all reg_defs from register
3512 (tdesc_create_reg): Create tdesc_reg.
3513 * tdesc.h (tdesc_feature): Add register vector.
3515 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
3517 * tdesc.h (struct target_desc) <features>: Change type to
3518 std::vector<std::string>.
3519 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
3521 (tdesc_get_features_xml): Likewise.
3522 (tdesc_create_feature): Likewise.
3524 2018-03-26 Alan Hayward <alan.hayward@arm.com>
3526 * regcache.c (find_register_by_number): Return a ref.
3527 (find_regno): Use references.
3528 (register_size): Likewise.
3529 (register_data): Likewise.
3530 * tdesc.c (target_desc::~target_desc): Remove free calls.
3531 (target_desc::operator==): Use std::vector compare.
3532 (init_target_desc): Use reference.
3533 (tdesc_create_reg): Use reg constructors.
3534 * tdesc.h (struct target_desc): Replace pointer with object.
3536 2018-03-23 Alan Hayward <alan.hayward@arm.com>
3538 * regcache.c (find_register_by_number): Make static.
3539 (find_regno): Use find_register_by_number
3540 * regcache.h (struct reg): Remove declaration.
3542 2018-03-23 Alan Hayward <alan.hayward@arm.com>
3544 * tdesc.c (target_desc::~target_desc): Move to here.
3545 (target_desc::operator==): Likewise.
3546 * tdesc.h (target_desc::~target_desc): Move from here.
3547 (target_desc::operator==): Likewise.
3549 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
3551 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
3553 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
3555 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
3557 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
3558 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
3559 and init_registers_s390_gs_linux64.
3561 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
3563 * linux-s390-low.c (s390_fill_gs): Remove function.
3564 (s390_fill_gsbc): Remove function.
3565 (s390_regsets): Set fill functions for the guarded storage regsets
3568 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
3570 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
3571 the word size. Add comment.
3572 (s390_get_wordsize): New function.
3573 (s390_arch_setup): No longer select a temporary tdesc to fetch the
3574 pswm with it. Instead, use s390_get_wordsize to determine the
3575 word size first and derive the correct tdesc from that directly.
3577 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
3579 * Makefile.in: Include silent-rules.mk.
3580 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
3581 (COMPILE): Add ECHO_CXX.
3582 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
3583 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
3584 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
3585 (version-generated.c): Add ECHO_GEN.
3586 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
3587 (IPAGENT_COMPILE): Add ECHO_CXX.
3588 (%-generated.c): Add ECHO_REGDAT.
3590 2018-03-14 Tom Tromey <tom@tromey.com>
3593 * ax.c (ax_printf): Special case for NULL.
3595 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
3597 * linux-low.c (linux_qxfer_libraries_svr4): Use
3598 xml_escape_text_append.
3600 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
3602 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
3604 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
3606 * server.c (handle_general_set): Remove unnecessary xstrdup.
3608 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
3610 * server.c (parse_debug_format_options): Adjust to
3611 delim_string_to_char_ptr_vec changes.
3612 * thread-db.c (thread_db_load_search): Adjust to
3613 dirnames_to_char_ptr_vec changes.
3615 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
3617 * target.h (target_enable_btrace, target_disable_btrace)
3618 (target_read_btrace, target_read_btrace_conf): Turn macro into
3619 inline function. Throw error if target method is not defined.
3620 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
3621 check for btrace target method. Be prepared to handle exceptions
3622 from btrace target methods.
3624 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
3626 * server.c (captured_main): Change order of error message printed
3627 when the current working directory cannot be found.
3629 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
3631 * server.c: Include "filenames.h" and "pathstuff.h".
3632 (program_name): Delete variable.
3633 (program_path): New anonymous class.
3634 (get_exec_wrapper): Use "program_path" instead of
3636 (handle_v_run): Likewise.
3637 (captured_main): Likewise.
3638 (process_serial_event): Likewise.
3640 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
3642 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
3643 (OBJS): Add "pathstuff.o".
3644 * server.c (current_directory): New global variable.
3645 (captured_main): Initialize "current_directory".
3647 2018-02-26 Alan Hayward <alan.hayward@arm.com>
3649 * tdesc.c: Use common/tdesc.h.
3650 * tdesc.h: Likewise.
3652 2018-02-20 Alan Hayward <alan.hayward@arm.com>
3653 Simon Marchi <simon.marchi@ericsson.com>
3655 * Makefile.in: Switch order of make rules.
3657 2018-02-19 Alan Hayward <alan.hayward@arm.com>
3659 * Makefile.in: Add common directory in build.
3660 * configure.ac: Add common reference.
3661 * configure: Regenerate.
3663 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
3665 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
3666 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
3667 * spu-low.c (spu_target_ops): Likewise.
3668 * win32-low.c (win32_target_ops): Likewise.
3669 * server.c (supported_btrace_packets): Report packets unconditionally.
3670 * target.h (target_ops) <supports_btrace>: Remove.
3671 (target_supports_btrace): Remove.
3673 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
3675 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
3676 (handle_btrace_disable): Change return type to void. Use exceptions
3678 (handle_btrace_general_set): Catch exception and copy message to
3681 2018-02-08 Tom Tromey <tom@tromey.com>
3683 * linux-low.c (install_software_single_step_breakpoints): Use
3684 make_scoped_restore.
3685 * inferiors.c (make_cleanup_restore_current_thread): Remove.
3686 (do_restore_current_thread_cleanup): Remove.
3687 * gdbthread.h (make_cleanup_restore_current_thread): Don't
3690 2018-02-08 Tom Tromey <tom@tromey.com>
3692 * mem-break.c (set_raw_breakpoint_at): Use
3693 gdb::unique_xmalloc_ptr.
3695 2018-01-30 Pedro Alves <palves@redhat.com>
3698 * target.c (target_terminal::terminal_state): Rename to ...
3699 (target_terminal::m_terminal_state): ... this.
3701 2018-01-19 James Clarke <jrtc27@jrtc27.com>
3703 * linux-low.c (handle_extended_wait): Surround call to
3704 thread_db_notice_clone with #ifdef USE_THREAD_DB.
3706 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
3708 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
3709 linux_ptrace_attach_fail_reason_string now returning an
3711 (linux_attach): Likewise.
3712 * thread-db.c (attach_thread): Likewise.
3714 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
3717 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
3718 checking for fs_base/gs_base fields in struct user_regs_struct.
3719 * configure: Regenerate.
3721 2018-01-16 Yao Qi <yao.qi@linaro.org>
3724 * linux-low.c (fetch_register): Call supply_register instead of
3727 2018-01-08 Yao Qi <yao.qi@linaro.org>
3728 Simon Marchi <simon.marchi@ericsson.com>
3730 * Makefile.in (OBS): Remove selftest.o.
3731 * configure.ac: Set srv_selftest_objs if $development is true.
3732 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
3733 * configure: Re-generated.
3734 * server.c (captured_main): Wrap variable selftest_filter with
3737 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
3739 * server.c (parse_debug_format_options): Return std::string.
3740 (handle_monitor_command, captured_main): Adjust.
3742 2018-01-05 Pedro Alves <palves@redhat.com>
3745 * server.c (captured_main): Pass quiet=false to
3746 save_original_signals_state.
3748 2018-01-01 Joel Brobecker <brobecker@adacore.com>
3750 * gdbreplay.c (gdbreplay_version): Update copyright year in
3752 * server.c (gdbserver_version): Likewise.
3754 2017-12-08 Tom Tromey <tom@tromey.com>
3756 * ax.c (ax_printf): Update.
3758 2017-12-07 Yao Qi <yao.qi@linaro.org>
3760 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
3761 aarch64_linux_read_description.
3762 * linux-amd64-ipa.c (idx2mask): New array.
3763 (get_ipa_tdesc): Move idx2mask out.
3764 (initialize_low_tracepoint): Initialize target descriptions.
3765 * linux-i386-ipa.c (idx2mask): New array.
3766 (get_ipa_tdesc): Move idx2mask out.
3767 (initialize_low_tracepoint): Initialize target descriptions.
3769 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
3771 * tdesc.c (struct tdesc_type): Change return type.
3772 (tdesc_add_flag): Change parameter type.
3773 (tdesc_add_bitfield): Likewise.
3774 (tdesc_add_field): Likewise.
3775 (tdesc_set_struct_size): Likewise.
3777 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
3779 * regcache.c (registers_to_string): Remove unused variable.
3781 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3783 * inferiors.c (for_each_inferior_with_data): Remove.
3784 * inferiors.h (for_each_inferior_with_data): Remove.
3785 * server.c (handle_qxfer_threads_worker): Change parameter type.
3786 (handle_qxfer_threads_proper): Use for_each_thread.
3788 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3790 * inferiors.c (for_each_inferior): Remove.
3791 (clear_inferiors): Use for_each_thread.
3792 * inferiors.h (for_each_inferior): Remove.
3793 * linux-low.c (linux_wait_for_event_filtered): Use
3795 (linux_stabilize_threads): Likewise.
3796 * regcache.c (regcache_release): Likewise.
3797 * server.c (gdb_wants_all_threads_stopped): Likewise.
3798 (clear_pending_status_callback): Remove.
3799 (handle_status): Use for_each_thread.
3800 (captured_main): Likewise.
3801 * win32-low.c (child_init_thread_list): Likewise.
3802 (win32_clear_inferiors): Likewise.
3803 (fake_breakpoint_event): Likewise.
3805 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3807 * inferiors.h (find_inferior): Remove.
3808 * inferiors.c (find_inferior): Remove.
3810 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3812 * linux-low.c (resume_status_pending_p): Update comment.
3813 (need_step_over_p): Update comment.
3815 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3817 * linux-low.c (proceed_one_lwp): Return void, change parameter
3819 (unsuspend_and_proceed_one_lwp): Likewise.
3820 (proceed_all_lwps): Use for_each_thread.
3821 (unstop_all_lwps): Likewise.
3823 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3825 * linux-low.c (linux_resume_one_thread): Return void, take
3827 (linux_resume): Use for_each_thread.
3829 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3831 * linux-low.c (send_sigstop_callback): Return void, change
3832 parameter type. Rename to...
3833 (send_sigstop): ... this.
3834 (suspend_and_send_sigstop_callback): Return void, change parameter
3836 (suspend_and_send_sigstop): ... this.
3837 (stop_all_lwps): Use for_each_thread.
3839 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3841 * linux-low.c (lwp_running): Return bool, remove unused
3843 (linux_stabilize_threads): Use find_thread.
3845 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3847 * linux-low.c (select_singlestep_lwp_callback): Remove.
3848 (count_events_callback): Remove.
3849 (select_event_lwp_callback): Remove.
3850 (select_event_lwp): Use find_thread/for_each_thread.
3852 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3854 * linux-low.c (not_stopped_callback): Return bool, take filter
3856 (linux_wait_for_event_filtered): Use find_thread.
3857 (linux_wait_1): Likewise.
3859 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3861 * linux-low.c (same_lwp): Remove.
3862 (find_lwp_pid): Use find_thread.
3864 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3866 * linux-low.c (delete_lwp_callback): Remove.
3867 (linux_mourn): Use for_each_thread.
3869 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3871 * linux-low.c (linux_detach_lwp_callback): Return void, remove
3872 args parameter, don't check for pid.
3873 (linux_detach): Use for_each_thread.
3875 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3877 * linux-low.c (struct counter): Remove.
3878 (second_thread_of_pid_p): Remove.
3879 (last_thread_of_process_p): Use find_thread.
3881 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3883 * inferiors.c (find_inferior_in_random): Remove.
3884 * inferiors.h (find_inferior_in_random): Remove.
3885 * linux-low.c (status_pending_p_callback): Return bool, accept
3886 parameter ptid directly.
3887 (linux_wait_for_event_filtered): Use find_thread_in_random.
3888 (linux_wait_1): Likewise.
3890 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3892 * inferiors.c (find_inferior_id): Remove.
3893 (find_thread_ptid): Move implemention from find_inferior_id to
3895 * inferiors.h (find_inferior_id): Remove.
3896 * server.c (handle_status): Use find_thread_ptid.
3897 (process_serial_event): Likewise.
3898 * thread-db.c (find_one_thread): Likewise.
3899 (thread_db_thread_handle): Likewise.
3900 * win32-low.c (thread_rec): Likewise.
3901 (child_delete_thread): Likewise.
3902 (win32_thread_alive): Likewise.
3903 (get_child_debug_event): Likewise.
3905 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3907 * linux-mips-low.c (update_watch_registers_callback): Return
3908 void, remove pid_p parameter, don't check for pid.
3909 (mips_insert_point, mips_remove_point): Use for_each_thread.
3911 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3913 * lynx.low (lynx_delete_thread_callback): Remove.
3914 (lynx_mourn): Use for_each_thread.
3916 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3918 * regcache.c (regcache_invalidate_one): Remove.
3919 (regcache_invalidate_pid): use for_each_thread.
3921 2017-11-26 Tom Tromey <tom@tromey.com>
3923 * linux-low.c (linux_create_inferior): Update.
3925 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
3927 * spu-low.c (spu_create_inferior): Fix typo in argument name.
3929 2017-11-24 Alan Hayward <alan.hayward@arm.com>
3931 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
3932 * linux-aarch64-low.c (initialize_low_arch): Call init func.
3933 * linux-aarch64-tdesc-selftest.c: New file.
3934 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
3936 2017-11-24 Alan Hayward <alan.hayward@arm.com>
3938 * configure.srv: Add new file.
3939 * linux-aarch64-low.c (initialize_low_arch): Call init func.
3940 * linux-aarch64-tdesc-selftest.c: New file.
3941 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
3943 2017-11-24 Alan Hayward <alan.hayward@arm.com>
3945 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
3946 * linux-aarch64-low.c (initialize_low_arch): Remove init.
3947 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
3949 2017-11-24 Alan Hayward <alan.hayward@arm.com>
3951 * configure.srv: Add new files.
3952 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
3953 aarch64_linux_read_description.
3954 * linux-aarch64-low.c (aarch64_linux_read_description):
3955 Merge with aarch64_arch_setup.
3956 (aarch64_arch_setup): Call aarch64_linux_read_description.
3957 * linux-aarch64-tdesc.c: New file.
3958 * linux-aarch64-tdesc.h: New file.
3960 2017-11-24 Yao Qi <yao.qi@linaro.org>
3962 * configure.srv: Set $srv_regobj for tic6x-linux.
3963 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
3964 (tic6x_read_description): Move some code to tic6x_arch_setup.
3965 (tic6x_tdesc_test): New function.
3966 (initialize_low_arch): Call selftests::register_test.
3968 2017-11-22 Yao Qi <yao.qi@linaro.org>
3970 * remote-utils.c (prepare_resume_reply): Use memcpy.
3972 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3974 * linux-low.c (kill_one_lwp_callback): Return void, take
3975 argument directly, don't filter on pid.
3976 (linux_kill): Use for_each_thread.
3978 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3980 * linux-low.c (need_step_over_p): Return bool, remove dummy
3982 (linux_resume, proceed_all_lwps): Use find_thread.
3984 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3986 * linux-low.c (resume_status_pending_p): Return bool, remove
3988 (linux_resume): Use find_thread.
3990 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3992 * linux-low.c (struct thread_resume_array): Remove.
3993 (linux_set_resume_request): Return void, take arguments
3995 (linux_resume): Use for_each_thread.
3997 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3999 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
4000 return bool, remove data argument.
4001 (linux_stabilize_threads): Use find_thread.
4003 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4005 * linux-low.c (unsuspend_one_lwp): Remove.
4006 (unsuspend_all_lwps): Use for_each_thread, inline code from
4009 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4011 * gdbthread.h (find_thread): Add overload with ptid_t filter.
4012 * linux-low.c (struct iterate_over_lwps_args): Remove.
4013 (iterate_over_lwps_filter): Remove.
4014 (iterate_over_lwps): Use find_thread.
4016 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4018 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
4019 (linux_handle_new_gdb_connection): Use for_each_thread, inline
4020 code from reset_lwp_ptrace_options_callback.
4022 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4024 * linux-arm-low.c (struct update_registers_data): Remove.
4025 (update_registers_callback): Return void, take arguments
4026 directly, don't check thread's pid.
4027 (arm_insert_point, arm_remove_point): Use for_each_thread.
4029 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4031 * win32-low.c (continue_one_thread): Return void, take argument
4033 (child_continue): Use for_each_thread.
4035 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4037 * win32-i386-low.c (update_debug_registers_callback): Rename
4039 (update_debug_registers): ... this, return void, remove pid_p arg.
4040 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
4042 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
4044 * inferiors.h (struct process_info): Add constructor, initialize
4046 <syscalls_to_catch>: Change type to std::vector<int>.
4047 * inferiors.c (add_process): Allocate process_info with new.
4048 (remove_process): Free process_info with delete.
4049 * linux-low.c (handle_extended_wait): Adjust.
4050 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
4051 * server.c (handle_general_set): Adjust.
4053 2017-11-16 Pedro Alves <palves@redhat.com>
4055 * remote-utils.c (remote_close): Block SIGIO signals instead of
4056 uninstalling the SIGIO handler.
4058 2017-11-16 Alan Hayward <alan.hayward@arm.com>
4060 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
4062 2017-11-16 Yao Qi <yao.qi@linaro.org>
4064 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
4065 (tic6x_store_gregset): Likewise.
4066 (tic6x_usrregs_info): Move it up.
4068 2017-11-15 Alan Hayward <alan.hayward@arm.com>
4070 * Makefile.in: Update arch rules.
4071 * configure.srv: Explicitly mark arch/ files.
4073 2017-11-13 Andreas Schwab <schwab@suse.de>
4075 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
4077 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4079 2017-11-06 Pedro Alves <palves@redhat.com>
4081 * config.in, configure: Regenerate.
4083 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4085 * target.c (struct thread_search): Remove.
4086 (thread_search_callback): Remove.
4087 (prepare_to_access_memory): Use for_each_thread instead of
4088 find_inferior. Inline code from thread_search_callback.
4090 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4092 * server.c (struct visit_actioned_threads_data): Remove.
4093 (visit_actioned_threads): Change prototype to take arguments
4095 (resume): Use find_thread instead of find_inferior.
4097 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4099 * server.c (queue_stop_reply_callback): Change prototype, return
4101 (find_status_pending_thread_callback): Remove.
4102 (handle_status): Replace find_inferior with find_thread and
4105 2017-10-25 Alan Hayward <alan.hayward@arm.com>
4107 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
4109 (aarch64_store_gregset): Likewise.
4110 (aarch64_fill_fpregset): Likewise.
4111 (aarch64_store_fpregset): Likewise.
4113 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
4115 * gdbthread.h (find_thread, for_each_thread): New functions.
4116 * inferiors.c (thread_of_pid): Remove.
4117 (find_any_thread_of_pid): Use find_thread.
4118 * linux-low.c (num_lwps): Use for_each_thread.
4120 2017-10-17 Yao Qi <yao.qi@linaro.org>
4122 * Makefile.in: Remove one rule.
4123 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
4125 2017-10-17 Yao Qi <yao.qi@linaro.org>
4127 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
4128 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
4130 2017-10-17 Yao Qi <yao.qi@linaro.org>
4132 * configure.srv: Rename arm.o with arch/arm.o.
4134 2017-10-17 Yao Qi <yao.qi@linaro.org>
4136 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
4137 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
4138 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
4139 (arch-i386.o, arch-amd64.o): Remove rules.
4140 (arch/%.o): New rule.
4141 Update POSTCOMPILE and COMPILE.pre.
4142 * configure.ac: Invoke AC_CONFIG_COMMANDS.
4143 * configure: Re-generated.
4144 * configure.srv: Replace arch-i386.o with arch/i386.o.
4145 Replace arch-amd64.o with arch/amd64.o.
4147 2017-10-16 Yao Qi <yao.qi@linaro.org>
4149 * configure: Regenerated.
4151 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4153 * inferiors.h: (struct inferior_list): Remove.
4154 (struct inferior_list_entry); Remove.
4155 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
4156 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
4157 get_first_inferior): Remove.
4158 (for_each_inferior, for_each_inferior_with_data, find_inferior,
4159 find_inferior_id, find_inferior_in_random): Change signature.
4160 * inferiors.c (all_threads): Change type to
4161 std::list<thread_info *>.
4162 (get_thread): Remove macro.
4163 (find_inferior, find_inferior_id): Change signature, implement
4165 (find_inferior_in_random): Change signature, implement using
4166 find_thread_in_random.
4167 (for_each_inferior, for_each_inferior_with_data): Change
4168 signature, implement using for_each_thread.
4169 (add_inferior_to_list, remove_inferior): Remove.
4170 (add_thread, get_first_thread, thread_of_pid,
4171 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
4172 (get_first_inferior, one_inferior_p, clear_inferior_list):
4174 (clear_inferiors, get_thread_process): Update.
4175 * gdbthread.h: Include <list>.
4176 (struct thread_info) <entry>: Remove field.
4178 (all_threads): Change type to std::list<thread_info *>.
4179 (get_first_inferior): Add doc.
4180 (find_thread, for_each_thread, find_thread_in_random): New
4182 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
4183 * linux-arm-low.c (update_registers_callback): Update.
4184 * linux-low.c (second_thread_of_pid_p): Update.
4185 (kill_one_lwp_callback, linux_detach_lwp_callback,
4186 delete_lwp_callback, status_pending_p_callback, same_lwp,
4187 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
4188 iterate_over_lwps, not_stopped_callback,
4189 resume_stopped_resumed_lwps, count_events_callback,
4190 select_singlestep_lwp_callback, select_event_lwp_callback,
4191 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
4192 suspend_and_send_sigstop_callback, wait_for_sigstop,
4193 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
4194 lwp_running, linux_set_resume_request, resume_status_pending_p,
4195 need_step_over_p, start_step_over, linux_resume_one_thread,
4196 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
4197 reset_lwp_ptrace_options_callback): Update.
4198 * linux-mips-low.c (update_watch_registers_callback): Update.
4199 * regcache.c (regcache_invalidate_one, regcache_invalidate):
4201 (free_register_cache_thread_one): Remove.
4202 (regcache_release): Update.
4203 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
4204 handle_qxfer_threads_worker): Update.
4205 (handle_query): Update, use list iterator.
4206 (visit_actioned_threads, handle_pending_status,
4207 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
4208 clear_pending_status_callback, set_pending_status_callback,
4209 find_status_pending_thread_callback, handle_status,
4210 process_serial_event): Update.
4211 * target.c (thread_search_callback): Update.
4212 * thread-db.c (thread_db_get_tls_address): Update.
4213 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
4215 * win32-i386-low.c (update_debug_registers_callback): Update.
4216 * win32-low.c (delete_thread_info, child_delete_thread,
4217 continue_one_thread, suspend_one_thread,
4218 get_child_debug_event): Adjust.
4220 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4222 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
4223 * inferiors.h: Include <list>.
4224 (struct process_info) <entry>: Remove field.
4226 (pid_of): Change macro to function.
4227 (ptid_of, lwpid_of): Remove macro.
4228 (all_processes): Change type to std::list<process_info *>.
4229 (ALL_PROCESSES): Remove macro.
4230 (for_each_process, find_process): New function.
4231 * inferiors.c (all_processes): Change type to
4232 std::list<process_info *>.
4233 (find_thread_process): Adjust.
4234 (add_process): Likewise.
4235 (remove_process): Likewise.
4236 (find_process_pid): Likewise.
4237 (get_first_process): Likewise.
4238 (started_inferior_callback): Remove.
4239 (have_started_inferiors_p): Adjust.
4240 (attached_inferior_callback): Remove.
4241 (have_attached_inferiors_p): Adjust.
4242 * linux-low.c (check_zombie_leaders): Likewise.
4243 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
4244 (x86_linux_update_xmltarget): Adjust.
4245 * server.c (handle_query): Likewise.
4246 (gdb_reattached_process): Remove.
4247 (handle_status): Adjust.
4248 (kill_inferior_callback): Likewise.
4249 (detach_or_kill_inferior): Remove.
4250 (print_started_pid): Likewise.
4251 (print_attached_pid): Likewise.
4252 (detach_or_kill_for_exit): Update.
4253 (process_serial_event): Likewise.
4254 * linux-arm-low.c (arm_new_fork): Likewise.
4256 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4258 * dll.h: Include <list>.
4259 (struct dll_info): Add constructor.
4260 <entry>: Remove field.
4261 (all_dlls): Change type to std::list<dll_info>.
4262 * dll.c: Include <algorithm>.
4263 (get_dll): Remove macro.
4264 (all_dlls): Change type to std::list<dll_info *>.
4265 (free_one_dll): Remove.
4266 (match_dll): Likewise.
4267 (loaded_dll): Adjust.
4268 (unloaded_dll): Adjust to all_dlls type change, use
4269 std::find_if. Inline code from match_dll.
4270 (clear_dlls): Adjust to all_dlls type change.
4271 * server.c (emit_dll_description): Remove.
4272 (handle_qxfer_libraries): Adjust to all_dlls type change,
4273 integrate emit_dll_description's functionality.
4275 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
4277 * linux-low.h (struct linux_target_ops) <delete_process>: New
4279 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
4280 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
4281 (struct linux_target_ops): Add delete_process callback.
4282 * linux-arm-low.c (arm_delete_process): New.
4283 (struct linux_target_ops): Add delete_process callback.
4284 * linux-bfin-low.c (struct linux_target_ops): Likewise.
4285 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
4286 * linux-m32r-low.c (struct linux_target_ops): Likewise.
4287 * linux-mips-low.c (mips_linux_delete_process): New.
4288 (struct linux_target_ops): Add delete_process callback.
4289 * linux-ppc-low.c (struct linux_target_ops): Likewise.
4290 * linux-s390-low.c (struct linux_target_ops): Likewise.
4291 * linux-sh-low.c (struct linux_target_ops): Likewise.
4292 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
4293 * linux-tile-low.c (struct linux_target_ops): Likewise.
4294 * linux-x86-low.c (x86_linux_delete_process): New.
4295 (struct linux_target_ops): Add delete_process callback.
4296 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
4298 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
4300 * linux-aarch64-low.c (the_low_target): Add thread delete
4302 * linux-arm-low.c (arm_delete_thread): New function.
4303 (the_low_target): Add thread delete callback.
4304 * linux-bfin-low.c (the_low_target): Likewise.
4305 * linux-crisv32-low.c (the_low_target): Likewise.
4306 * linux-low.c (delete_lwp): Invoke delete_thread callback if
4308 * linux-low.h (struct linux_target_ops) <delete_thread>: New
4310 * linux-m32r-low.c (the_low_target): Add thread delete callback.
4311 * linux-mips-low.c (mips_linux_delete_thread): New function.
4312 (the_low_target): Add thread delete callback.
4313 * linux-ppc-low.c (the_low_target): Likewise.
4314 * linux-s390-low.c (the_low_target): Likewise.
4315 * linux-sh-low.c (the_low_target): Likewise.
4316 * linux-tic6x-low.c (the_low_target): Likewise.
4317 * linux-tile-low.c (the_low_target): Likewise.
4318 * linux-x86-low.c (the_low_target): Likewise.
4319 * linux-xtensa-low.c (the_low_target): Likewise.
4321 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
4323 * win32-low.c: Include "common-inferior.h".
4325 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4327 * inferiors.c (set_inferior_cwd): New function.
4328 * server.c (handle_general_set): Handle QSetWorkingDir packet.
4329 (handle_query): Inform that QSetWorkingDir is supported.
4330 * win32-low.c (create_process): Pass the inferior's cwd to
4333 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4335 * inferiors.c (current_inferior_cwd): New global variable.
4336 (get_inferior_cwd): New function.
4337 * inferiors.h (struct process_info) <cwd>: New field.
4339 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4341 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
4342 (OBS): Add gdb_tilde_expand.o.
4344 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
4346 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
4347 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
4349 2017-09-29 Pedro Alves <palves@redhat.com>
4351 * ax.c (gdb_parse_agent_expr): Constify.
4352 * ax.h (gdb_parse_agent_expr): Constify.
4353 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
4355 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
4356 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
4357 * remote-utils.h (read_ptid): Constify.
4358 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
4359 (process_point_options, process_serial_event): Constify.
4360 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
4361 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
4362 (cmd_qtbuffer): Constify.
4364 2017-09-29 Pedro Alves <palves@redhat.com>
4366 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
4369 2017-09-29 Pedro Alves <palves@redhat.com>
4371 * linux-low.c (handle_extended_wait): Pass parent thread instead
4372 of process to thread_db_notice_clone.
4373 * linux-low.h (thread_db_notice_clone): Replace parent process
4374 parameter with parent thread parameter.
4375 * thread-db.c (find_one_thread): Add comment.
4376 (thread_db_notice_clone): Replace parent process parameter with
4377 parent thread parameter. Temporarily switch to the parent thread.
4379 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
4381 * gdbthread.h: Include "common-gdbthread.h".
4382 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
4383 "if" when validating the ptid.
4384 * remote-utils.c: Include "gdbthread.h".
4385 (prepare_resume_reply): Use "switch_to_thread".
4386 * target.c (done_accessing_memory): Likewise.
4388 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
4390 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
4391 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
4392 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
4393 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
4394 s390x-gs-linux64-ipa.o to ipa_obj.
4395 * linux-s390-low.c (HWCAP_S390_GS): New define.
4396 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
4398 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
4399 (s390_arch_setup): Check for guarded-storage support and choose
4401 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
4402 init_registers_s390x_gs_linux64.
4403 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
4405 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
4406 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
4408 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
4410 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
4412 2017-09-21 Kevin Buettner <kevinb@redhat.com>
4414 * linux-low.h (struct lwp_info): Add new field, thread_handle.
4415 (thread_db_thread_handle): Declare.
4416 * linux-low.c (linux_target_ops): Initialize thread_handle.
4417 * server.c (handle_qxfer_threads_worker): Add support for
4419 * target.h (struct target_ops): Add new function pointer,
4421 (target_thread_handle): Define.
4422 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
4424 (thread_db_thread_handle): New function.
4426 2017-09-21 Kevin Buettner <kevinb@redhat.com>
4428 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
4429 * linux-low.h (thread_db_notice_clone): Declare.
4430 * thread-db.c (thread_db_notice_clone): New function.
4432 2017-09-21 Pedro Alves <palves@redhat.com>
4434 * server.c (gdb_read_memory, handle_status, process_serial_event)
4435 (handle_serial_event, handle_target_event): Adjust to
4436 set_desired_thread prototype change.
4437 * target.c (set_desired_thread): Remove 'use_general' parameter
4439 * target.h (set_desired_thread): Remove 'use_general' parameter.
4441 2017-09-20 Tom Tromey <tom@tromey.com>
4443 * target.c (target_terminal::terminal_state): Define.
4444 (target_terminal::init): Rename from target_terminal_init.
4445 (target_terminal::inferior): Rename from
4446 target_terminal_inferior.
4447 (target_terminal::ours): Rename from target_terminal_ours.
4448 (target_terminal::ours_for_output, target_terminal::info): New.
4450 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4452 * server.c (accumulate_file_name_length): Remove.
4453 (emit_dll_description): Adjust to std::string change.
4454 (handle_qxfer_libraries): Use std::string to hold document.
4456 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4458 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
4459 return type of xml_escape_text.
4460 * server.c (emit_dll_description): Likewise.
4462 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4464 * server.c (captured_main): Accept argument for --selftest.
4465 Update run_tests call.
4466 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
4467 when registering selftests.
4469 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
4471 * regcache.c (get_thread_regcache): Update code to use "std::vector"
4472 instead of "VEC" for "target_desc.reg_defs".
4473 (regcache_cpy): Likewise.
4474 (registers_to_string): Likewise.
4475 (registers_from_string): Likewise.
4476 (find_regno): Likewise.
4477 (supply_regblock): Likewise.
4478 (regcache_raw_read_unsigned): Likewise.
4479 * tdesc.c (init_target_desc): Likewise.
4480 (tdesc_create_reg): Likewise.
4481 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
4482 (struct target_desc) <reg_defs>: Convert to "std::vector".
4483 (target_desc): Do not initialize "reg_defs".
4484 (~target_desc): Update code to use "std::vector" instead of "VEC"
4485 for "target_desc.reg_defs".
4486 (operator==): Likewise.
4488 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4490 * inferiors.h (thread_to_gdb_id): Remove.
4491 * inferiors.c (thread_to_gdb_id): Remove.
4492 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
4493 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
4494 lynx_store_registers, lynx_read_memory, lynx_write_memory):
4496 * nto-low.c (nto_fetch_registers, nto_store_registers,
4497 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
4499 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4501 * inferiors.h (gdb_id_to_thread_id): Remove.
4502 * inferiors.c (gdb_id_to_thread_id): Remove.
4503 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
4504 removal. Move pid declaration closer to where it's used.
4506 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4508 * server.c (handle_detach): New function.
4509 (process_serial_event): Move code out, call handle_detach.
4511 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4513 * server.c (require_running): Rename to ...
4514 (require_running_or_return): ... this ...
4515 (require_running_or_break): ... and this.
4516 (handle_query, process_serial_event): Adjust.
4518 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4520 * linux-low.c (linux_set_resume_request): Remove unused
4523 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4525 * server.c (first_thread_of): Remove.
4526 (process_serial_event): Replace usage of first_thread_of with
4527 find_any_thread_of_pid.
4528 * tracepoint.c (same_process_p): Remove.
4529 (gdb_agent_about_to_close): Replace usage of same_process_p with
4530 find_any_thread_of_pid.
4531 * linux-x86-low.c (same_process_callback): Remove.
4532 (x86_arch_setup_process_callback): Replace usage of
4533 same_process_callback with find_any_thread_of_pid.
4534 * thread-db.c (any_thread_of): Remove.
4535 (switch_to_process): Replace usage of any_thread_of with
4536 find_any_thread_of_pid.
4537 * inferiors.c (thread_pid_matches_callback): Remove.
4538 (find_thread_process): Adjust to use find_any_thread_of_pid.
4540 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
4542 * regcache.c (get_thread_regcache): Guard calls to "memset"
4545 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
4547 * linux-low.c (handle_extended_wait): Use
4548 "allocate_target_description" instead of "XNEW".
4549 * linux-x86-low.c (initialize_low_arch): Likewise.
4551 2017-09-05 Yao Qi <yao.qi@linaro.org>
4553 * configure.srv (srv_i386_regobj): Remove.
4554 (srv_amd64_regobj): Remove.
4555 (srv_regobj): Set it to "" for x86 non-linux targets.
4556 * linux-x86-tdesc.c (i386_linux_read_description):
4557 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
4558 (init_registers_i386): Remove the declaration.
4559 (tdesc_i386): Remove the declaration.
4560 (lynx_i386_arch_setup): Call i386_create_target_description.
4561 * nto-x86-low.c: Likewise.
4562 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
4563 [!__x86_64__]: include arch/i386.h.
4564 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
4566 2017-09-05 Yao Qi <yao.qi@linaro.org>
4568 * configure.srv (srv_amd64_linux_xmlfiles): Remove
4569 i386/amd64-XXX-linux from it.
4571 2017-09-05 Yao Qi <yao.qi@linaro.org>
4573 * configure.srv: Empty srv_amd64_linux_regobj if $development is
4575 (ipa_amd64_linux_regobj): Remove.
4576 (ipa_x32_linux_regobj): Remove.
4578 2017-09-05 Yao Qi <yao.qi@linaro.org>
4580 * Makefile.in (arch-amd64.o): New rule.
4581 * configure.srv: Append arch-amd64.o.
4582 * linux-amd64-ipa.c: Include common/x86-xstate.h.
4583 (get_ipa_tdesc): Call amd64_linux_read_description.
4584 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
4585 and init_registers_amd64_XXX.
4586 * linux-x86-low.c (x86_linux_read_description): Call
4587 amd64_linux_read_description.
4588 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
4589 (initialize_low_arch): Don't call init_registers_x32_XXX and
4590 init_registers_amd64_XXX.
4591 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
4592 and tdesc_amd64_XXX.
4593 [__x86_64__] (amd64_tdesc_test): New function.
4594 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
4595 and init_registers_amd64_XXX.
4596 * linux-x86-tdesc.c: Include arch/amd64.h.
4597 (xcr0_to_tdesc_idx): New function.
4598 (i386_linux_read_description): New function.
4599 (amd64_get_ipa_tdesc_idx): New function.
4600 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
4601 (amd64_get_ipa_tdesc): Declare.
4603 2017-09-05 Yao Qi <yao.qi@linaro.org>
4605 * configure.srv (srv_i386_linux_xmlfiles): Remove
4606 i386/i386-XXX-linux.xml from it.
4608 2017-09-05 Yao Qi <yao.qi@linaro.org>
4610 * configure.srv: Set srv_i386_linux_regobj empty if $development
4612 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
4613 initialize_low_tdesc.
4614 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
4615 with #if initialize_low_tdesc.
4616 * linux-x86-tdesc-selftest.c: New file.
4617 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
4619 2017-09-05 Yao Qi <yao.qi@linaro.org>
4621 * Makefile.in (arch-i386.o): New rule.
4622 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
4623 (x86_64-*-linux*): Likewise.
4624 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
4625 include arch/i386.h.
4626 (i386_linux_read_description): Remove code and call
4627 i386_create_target_description.
4628 * tdesc.c (allocate_target_description): New function.
4629 * tdesc.h (set_tdesc_architecture): Remove declaration.
4630 (set_tdesc_osabi): Likewise.
4632 2017-09-05 Yao Qi <yao.qi@linaro.org>
4634 * linux-x86-tdesc.c: Don't include <inttypes.h>.
4635 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
4636 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
4638 * server.c (get_features_xml): Call tdesc_get_features_xml.
4639 * tdesc.c (set_tdesc_architecture): New function.
4640 (set_tdesc_osabi): New function.
4641 (tdesc_get_features_xml): New function.
4642 (tdesc_create_feature): Add an argument.
4643 * tdesc.h (struct target_desc) <features>: New field.
4644 <arch, osabi>: New field.
4645 (~target_desc): xfree features, arch, and osabi.
4646 (target_desc::oerator==): Don't compare .xmltarget.
4647 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
4648 (set_tdesc_osabi): Likewise.
4649 (tdesc_get_features_xml): Likewise.
4651 2017-09-05 Yao Qi <yao.qi@linaro.org>
4653 * linux-x86-tdesc.c: Include selftest.h.
4654 (i386_tdesc_test): New function.
4655 (initialize_low_tdesc): Call selftests::register_test.
4656 * tdesc.h: Include regdef.h.
4657 (target_desc): Override operator == and !=.
4659 2017-09-05 Yao Qi <yao.qi@linaro.org>
4661 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
4662 (ipa_obj): Likewise.
4663 * linux-i386-ipa.c: Include common/x86-xstate.h
4664 (get_ipa_tdesc): Call i386_linux_read_description.
4665 (initialize_low_tracepoint): Don't call init_registers_XXX
4666 functions, call initialize_low_tdesc instead.
4667 * linux-x86-low.c (x86_linux_read_description): Call
4668 i386_linux_read_description.
4669 (initialize_low_arch): Don't call init_registers_i386_XXX
4670 functions, call initialize_low_tdesc.
4671 * linux-x86-tdesc.c: New file.
4672 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
4673 (i386_get_ipa_tdesc_idx): Declare.
4674 (i386_get_ipa_tdesc): Declare.
4675 (initialize_low_tdesc): Declare.
4677 2017-09-05 Yao Qi <yao.qi@linaro.org>
4679 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
4682 2017-09-05 Yao Qi <yao.qi@linaro.org>
4684 * Makefile.in (IPA_OBJS): Add vec-ipa.o
4685 * regcache.c (get_thread_regcache): Use VEC_length.
4686 (init_register_cache): Likewise.
4687 (regcache_cpy): Likewise.
4688 (registers_to_string): Iterate reg_defs via VEC_iterate.
4689 (find_regno): Likewise.
4690 (find_register_by_number): Use VEC_index.
4691 (register_size): Call find_register_by_number.
4692 (register_data): Call find_register_by_number.
4693 (supply_regblock): Use VEC_length.
4694 (regcache_raw_read_unsigned): Likewise.
4695 * tdesc.c (init_target_desc): Iterate reg_defs via
4697 (default_description): Update initializer.
4698 (copy_target_description): Don't update field num_registers.
4699 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
4700 <num_registers>: Remove.
4702 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
4704 * Makefile.in (.SECONDARY): Define target.
4706 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
4708 * linux-low.c (linux_wait_1): Adjust.
4709 * server.c (queue_stop_reply_callback): Adjust.
4711 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
4713 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
4714 QEnvironmentUnset and QEnvironmentReset packets.
4715 (handle_query): Inform remote that QEnvironmentHexEncoded,
4716 QEnvironmentUnset and QEnvironmentReset are supported.
4718 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
4720 * inferiors.h (inferior_target_data): Rename to ...
4721 (thread_target_data): ... this.
4722 (inferior_regcache_data): Rename to ...
4723 (thread_regcache_data): ... this.
4724 (set_inferior_regcache_data): Rename to ...
4725 (set_thread_regcache_data): ... this.
4726 * inferiors.c (inferior_target_data): Rename to ...
4727 (thread_target_data): ... this.
4728 (inferior_regcache_data): Rename to ...
4729 (thread_regcache_data): ... this.
4730 (set_inferior_regcache_data): Rename to ...
4731 (set_thread_regcache_data): ... this.
4732 (free_one_thread): Update.
4733 * linux-low.h (get_thread_lwp): Update.
4734 * regcache.c (get_thread_regcache): Update.
4735 (regcache_invalidate_thread): Update.
4736 (free_register_cache_thread): Update.
4737 * win32-i386-low.c (update_debug_registers_callback): Update.
4738 (win32_get_current_dr): Update.
4739 * win32-low.c (thread_rec): Update.
4740 (delete_thread_info): Update.
4741 (continue_one_thread): Update.
4742 (suspend_one_thread): Update.
4744 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
4746 * inferiors.c (set_inferior_target_data): Remove.
4747 * inferiors.h (set_inferior_target_data): Remove.
4749 2017-08-18 Yao Qi <yao.qi@linaro.org>
4751 * Makefile.in (OBS): Add selftest.o.
4752 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
4753 * configure, config.in: Re-generated.
4754 * server.c: Include common/sefltest.h.
4755 (captured_main): Handle option --selftest.
4757 2017-08-09 Yao Qi <yao.qi@linaro.org>
4759 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
4760 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
4761 i386-avx-mpx.o and i386-mmx.o.
4762 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
4763 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
4764 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
4765 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
4766 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
4767 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
4768 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
4769 i386/amd64-avx-mpx.xml.
4771 2017-08-09 Yao Qi <yao.qi@linaro.org>
4773 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
4774 and x32-avx-avx512.o.
4775 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
4776 i386/x32-avx-avx512.xml.
4778 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
4780 * tracepoint.h (enum class fast_tpoint_collect_result): New
4782 (fast_tracepoint_collecting): Change return type to
4783 fast_tpoint_collect_result.
4784 * tracepoint.c (fast_tracepoint_collecting): Likewise.
4785 * linux-low.h: Include tracepoint.h.
4786 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
4787 fast_tpoint_collect_result.
4788 * linux-low.c (handle_tracepoints): Adjust.
4789 (linux_fast_tracepoint_collecting): Change return type to
4790 fast_tpoint_collect_result.
4791 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
4792 linux_wait_1, stuck_in_jump_pad_callback,
4793 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
4794 proceed_one_lwp): Adjust to type change.
4796 2017-07-10 Yao Qi <yao.qi@linaro.org>
4798 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
4800 2017-06-29 Yao Qi <yao.qi@linaro.org>
4802 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
4804 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
4806 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
4808 * Makefile.in (IPA_OBJS): Sort and format one item per line.
4810 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
4812 * linux-low.c (linux_create_inferior): Adjust code to access the
4813 environment information via 'gdb_environ' class.
4814 * lynx-low.c (lynx_create_inferior): Likewise.
4815 * server.c (our_environ): Make it an instance of 'gdb_environ'.
4816 (get_environ): Return a pointer to 'our_environ'.
4817 (captured_main): Initialize 'our_environ'.
4818 * server.h (get_environ): Adjust prototype.
4819 * spu-low.c (spu_create_inferior): Adjust code to access the
4820 environment information via 'gdb_environ' class.
4822 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4824 * linux-low.c (linux_read_memory, linux_write_memory): Remove
4825 usage of "register" keyword.
4827 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4829 * configure: Re-generate.
4831 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4833 * configure: Re-generate.
4835 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4837 * Makefile.in (COMPILE.pre): Add "-x c++".
4839 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
4841 * fork-child.c: Conditionally include <signal.h>.
4843 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4845 * server.c (handle_general_set): Handle new packet
4846 "QStartupWithShell".
4847 (handle_query): Add "QStartupWithShell" to the list of supported
4849 (gdbserver_usage): Add help text explaining the
4850 new "--startup-with-shell" and "--no-startup-with-shell" CLI
4852 (captured_main): Recognize and act upon the presence of the new
4855 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4856 Pedro Alves <palves@redhat.com>
4858 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
4859 * configure: Regenerate.
4860 * configure.srv (srv_linux_obj): Add "fork-child.o" and
4862 (i[34567]86-*-lynxos*): Likewise.
4863 (spu*-*-*): Likewise.
4864 * fork-child.c: New file.
4865 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
4867 (linux_ptrace_fun): New function.
4868 (linux_create_inferior): Adjust function prototype to reflect
4869 change on "target.h". Adjust function code to use
4871 (linux_request_interrupt): Delete "signal_pid".
4872 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
4873 (lynx_ptrace_fun): New function.
4874 (lynx_create_inferior): Adjust function prototype to reflect
4875 change on "target.h". Adjust function code to use
4877 * nto-low.c (nto_create_inferior): Adjust function prototype and
4878 code to reflect change on "target.h". Update comments.
4879 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
4880 "common-terminal.h" and "environ.h".
4881 (terminal_fd): Moved to fork-child.c.
4882 (old_foreground_pgrp): Likewise.
4883 (restore_old_foreground_pgrp): Likewise.
4884 (last_status): Make it global.
4885 (last_ptid): Likewise.
4886 (our_environ): New variable.
4887 (startup_with_shell): Likewise.
4888 (program_name): Likewise.
4889 (program_argv): Rename to...
4890 (program_args): ...this.
4891 (wrapper_argv): New variable.
4892 (start_inferior): Delete function.
4893 (get_exec_wrapper): New function.
4894 (get_exec_file): Likewise.
4895 (get_environ): Likewise.
4896 (prefork_hook): Likewise.
4897 (post_fork_inferior): Likewise.
4898 (postfork_hook): Likewise.
4899 (postfork_child_hook): Likewise.
4900 (handle_v_run): Update code to deal with arguments coming from the
4901 remote host. Update calls from "start_inferior" to
4903 (captured_main): Likewise. Initialize environment variable. Call
4905 * server.h (post_fork_inferior): New prototype.
4906 (get_environ): Likewise.
4907 (last_status): Declare.
4908 (last_ptid): Likewise.
4909 (signal_pid): Likewise.
4910 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
4911 (spu_ptrace_fun): New function.
4912 (spu_create_inferior): Adjust function prototype to reflect change
4913 on "target.h". Adjust function code to use "fork_inferior".
4914 * target.c (target_terminal_init): New function.
4915 (target_terminal_inferior): Likewise.
4916 (target_terminal_ours): Likewise.
4917 * target.h: Include <vector>.
4918 (struct target_ops) <create_inferior>: Update prototype.
4919 (create_inferior): Update macro.
4920 * utils.c (gdb_flush_out_err): New function.
4921 * win32-low.c (win32_create_inferior): Adjust function prototype
4922 and code to reflect change on "target.h".
4924 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4926 * inferiors.c (switch_to_thread): New function.
4928 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4930 * Makefile.in (SFILE): Add "common/job-control.c".
4931 (OBS): Add "job-control.o".
4933 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
4935 * Makefile: Remove "@host_makefile_frag@".
4937 2017-05-05 Pedro Alves <palves@redhat.com>
4939 * configure: Regenerate.
4941 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
4943 * configure: Regenerate.
4945 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
4947 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
4948 software_single_step change of return type to
4949 std::vector<CORE_ADDR>.
4950 * linux-low.c (install_software_single_step_breakpoints):
4952 * linux-low.h (install_software_single_step_breakpoints):
4955 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
4957 * remote-utils.c: Include "gdb_termios.h" instead of
4959 * terminal.h: Delete file.
4961 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
4963 * server.c: Include <vector>.
4964 <program_argv, wrapper_argv>: Convert to std::vector.
4965 (start_inferior): Rewrite function to use C++.
4966 (handle_v_run): Likewise. Update code that calculates the argv
4967 based on the vRun packet; use C++.
4968 (captured_main): Likewise.
4970 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
4972 * server.c (handle_v_cont): Initialize thread_resume::thread
4975 2017-04-05 Pedro Alves <palves@redhat.com>
4977 * configure: Regenerate.
4979 2017-04-05 Pedro Alves <palves@redhat.com>
4981 * gdbreplay.c (sync_error): Constify.
4982 * linux-x86-low.c (push_opcode): Constify.
4984 2017-04-05 Pedro Alves <palves@redhat.com>
4986 * win32-low.c (get_child_debug_event)
4987 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
4988 Report TARGET_WAITKIND_SPURIOUS instead.
4990 2017-04-05 Pedro Alves <palves@redhat.com>
4992 * remote-utils.c (remote_prepare, remote_open): Constify.
4993 * remote-utils.h (remote_prepare, remote_open): Constify.
4994 * server.c (captured_main): Constify 'port' handling.
4996 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
4998 * Makefile.in (clean): Clear .deps.
5000 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
5002 * .gitignore: Remove generated files, replace with wildcard.
5003 * (clean): Replace removal of generated files with wildcard.
5004 (version.c): Replace with...
5005 (version-generated.c): ...this.
5006 (xml-builtin.c): Replace with...
5007 (xml-builtin-generated.c): ...this.
5008 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
5009 (%.c: *regformats*): Replace with...
5010 (%-generated.c: *regformats*): ...this.
5012 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
5014 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
5015 (xtensa_fill_gregset): Call collect_register_by_name for
5017 (xtensa_store_gregset): Call supply_register_by_name for
5020 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
5022 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
5023 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
5024 (xtensa_store_gregset): Call supply_register for all registers in
5025 a0_regnum..a0_regnum + C0_NREGS range.
5027 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5029 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
5030 (ax-ipa.o: ax.c): Remove.
5031 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
5032 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
5033 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
5034 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
5035 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
5037 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5039 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
5040 (print-utils-ipa.o: ../common/print-utils.c): Remove.
5041 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
5042 (errors-ipa.o: ../common/errors.c): Remove.
5043 (format-ipa.o: ../common/format.c): Remove.
5044 (common-utils-ipa.o: ../common/common-utils.c): Remove.
5046 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5048 * Makefile.in (%-ipa.o: %.c): New rule.
5049 (tracepoint-ipa.o: tracepoint.c): Remove.
5050 (utils-ipa.o: utils.c): Remove.
5051 (remote-utils-ipa.o: remote-utils.c): Remove.
5052 (regcache-ipa.o: regcache.c): Remove.
5053 (i386-linux-ipa.o: i386-linux.c): Remove.
5054 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
5055 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
5056 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
5057 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
5058 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
5059 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
5060 (amd64-linux-ipa.o: amd64-linux.c): Remove.
5061 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
5062 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
5063 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
5064 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
5065 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
5066 (aarch64-ipa.o: aarch64.c): Remove.
5067 (s390-linux32-ipa.o: s390-linux32.c): Remove.
5068 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
5069 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
5070 (s390-linux64-ipa.o: s390-linux64.c): Remove.
5071 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
5072 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
5073 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
5074 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
5075 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
5076 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
5077 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
5078 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
5079 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
5080 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
5081 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
5082 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
5083 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
5084 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
5085 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
5086 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
5087 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
5088 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
5089 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
5090 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
5091 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
5092 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
5093 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
5094 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
5095 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
5096 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
5097 (tdesc-ipa.o: tdesc.c): Remove.
5098 (x32-linux-ipa.o: x32-linux.c): Remove.
5099 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
5100 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
5102 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5104 * Makefile.in (%.o: ../arch/%.c): New rule.
5105 (arm.o: ../arch/arm.c): Remove.
5106 (arm-linux.o: ../arch/arm-linux.c): Remove.
5107 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
5108 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
5110 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5112 * Makefile.in (%.o: ../nat/%.c): New rule.
5113 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
5114 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
5115 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
5116 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
5117 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
5118 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
5119 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
5120 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
5121 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
5122 (linux-personality.o: ../nat/linux-personality.c): Remove.
5123 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
5124 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
5125 (x86-linux.o: ../nat/x86-linux.c): Remove.
5126 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
5127 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
5129 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5131 * Makefile.in (%.o: ../common/%.c): New rule.
5132 (signals.o: ../common/signals.c): Remove.
5133 (print-utils.o: ../common/print-utils.c): Remove.
5134 (rsp-low.o: ../common/rsp-low.c): Remove.
5135 (common-utils.o: ../common/common-utils.c): Remove.
5136 (posix-strerror.o: ../common/posix-strerror.c): Remove.
5137 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
5138 (vec.o: ../common/vec.c): Remove.
5139 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
5140 (xml-utils.o: ../common/xml-utils.c): Remove.
5141 (ptid.o: ../common/ptid.c): Remove.
5142 (buffer.o: ../common/buffer.c): Remove.
5143 (format.o: ../common/format.c): Remove.
5144 (filestuff.o: ../common/filestuff.c): Remove.
5145 (agent.o: ../common/agent.c): Remove.
5146 (errors.o: ../common/errors.c): Remove.
5147 (environ.o: ../common/environ.c): Remove.
5148 (common-debug.o: ../common/common-debug.c): Remove.
5149 (cleanups.o: ../common/cleanups.c): Remove.
5150 (common-exceptions.o: ../common/common-exceptions.c): Remove.
5151 (fileio.o: ../common/fileio.c): Remove.
5152 (common-regcache.o: ../common/common-regcache.c): Remove.
5153 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
5154 (new-op.o: ../common/new-op.c): Remove.
5155 (btrace-common.o: ../common/btrace-common.c): Remove.
5157 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5159 * Makefile.in (%.o: ../target/%.c): New rule.
5160 (waitstatus.o: ../target/waitstatus.c): Remove.
5162 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5165 (%.c: ../regformats/%.dat,
5166 (%.c: ../regformats/arm/%.dat,
5167 (%.c: ../regformats/i386/%.dat,
5168 (%.c: ../regformats/rs6000/%.dat): New rules.
5169 (aarch64.c): Remove.
5170 (reg-arm.c): Remove.
5171 (arm-with-iwmmxt.c): Remove.
5172 (arm-with-vfpv2.c): Remove.
5173 (arm-with-vfpv3.c): Remove.
5174 (arm-with-neon.c): Remove.
5175 (reg-bfin.c): Remove.
5176 (reg-cris.c): Remove.
5177 (reg-crisv32.c): Remove.
5179 (i386-linux.c): Remove.
5180 (i386-avx.c): Remove.
5181 (i386-avx-linux.c): Remove.
5182 (i386-avx-avx512.c): Remove.
5183 (i386-avx-avx512-linux.c): Remove.
5184 (i386-mpx.c): Remove.
5185 (i386-mpx-linux.c): Remove.
5186 (i386-avx-mpx-avx512-pku.c): Remove.
5187 (i386-avx-mpx-avx512-pku-linux.c): Remove.
5188 (i386-avx-mpx.c): Remove.
5189 (i386-avx-mpx-linux.c): Remove.
5190 (i386-mmx.c): Remove.
5191 (i386-mmx-linux.c): Remove.
5192 (reg-ia64.c): Remove.
5193 (reg-m32r.c): Remove.
5194 (reg-m68k.c): Remove.
5196 (mips-linux.c): Remove.
5197 (mips-dsp-linux.c): Remove.
5198 (mips64-linux.c): Remove.
5199 (mips64-dsp-linux.c): Remove.
5200 (nios2-linux.c): Remove.
5201 (powerpc-32.c): Remove.
5202 (powerpc-32l.c): Remove.
5203 (powerpc-altivec32l.c): Remove.
5204 (powerpc-cell32l.c): Remove.
5205 (powerpc-vsx32l.c): Remove.
5206 (powerpc-isa205-32l.c): Remove.
5207 (powerpc-isa205-altivec32l.c): Remove.
5208 (powerpc-isa205-vsx32l.c): Remove.
5209 (powerpc-e500l.c): Remove.
5210 (powerpc-64l.c): Remove.
5211 (powerpc-altivec64l.c): Remove.
5212 (powerpc-cell64l.c): Remove.
5213 (powerpc-vsx64l.c): Remove.
5214 (powerpc-isa205-64l.c): Remove.
5215 (powerpc-isa205-altivec64l.c): Remove.
5216 (powerpc-isa205-vsx64l.c): Remove.
5217 (s390-linux32.c): Remove.
5218 (s390-linux32v1.c): Remove.
5219 (s390-linux32v2.c): Remove.
5220 (s390-linux64.c): Remove.
5221 (s390-linux64v1.c): Remove.
5222 (s390-linux64v2.c): Remove.
5223 (s390-te-linux64.c): Remove.
5224 (s390-vx-linux64.c): Remove.
5225 (s390-tevx-linux64.c): Remove.
5226 (s390x-linux64.c): Remove.
5227 (s390x-linux64v1.c): Remove.
5228 (s390x-linux64v2.c): Remove.
5229 (s390x-te-linux64.c): Remove.
5230 (s390x-vx-linux64.c): Remove.
5231 (s390x-tevx-linux64.c): Remove.
5232 (tic6x-c64xp-linux.c): Remove.
5233 (tic6x-c64x-linux.c): Remove.
5234 (tic6x-c62x-linux.c): Remove.
5236 (reg-sparc64.c): Remove.
5237 (reg-spu.c): Remove.
5239 (amd64-linux.c): Remove.
5240 (amd64-avx.c): Remove.
5241 (amd64-avx-linux.c): Remove.
5242 (amd64-avx-avx512.c): Remove.
5243 (amd64-avx-avx512-linux.c): Remove.
5244 (amd64-mpx.c): Remove.
5245 (amd64-mpx-linux.c): Remove.
5246 (amd64-avx-mpx-avx512-pku.c): Remove.
5247 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
5248 (amd64-avx-mpx.c): Remove.
5249 (amd64-avx-mpx-linux.c): Remove.
5251 (x32-linux.c): Remove.
5252 (x32-avx.c): Remove.
5253 (x32-avx-linux.c): Remove.
5254 (x32-avx-avx512.c): Remove.
5255 (x32-avx-avx512-linux.c): Remove.
5256 (reg-xtensa.c): Remove.
5257 (reg-tilegx.c): Remove.
5258 (reg-tilegx32.c): Remove.
5260 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
5262 * Makefile.in (SFILES): Add "common/environ.c".
5263 (OBJS): Add "common/environ.h".
5265 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
5267 * configure.ac: Check if the fs_base and gs_base members of
5268 `struct user_regs_struct' exist.
5269 * config.in: Regenerated.
5270 * configure: Likewise.
5272 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
5274 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
5276 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
5277 (get_next_pcs_syscall_next_pc): Likewise.
5279 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
5281 * win32-i386-low.c: Fix incorrect reference to a couple source files.
5282 * nto-x86-low.c: Likewise.
5284 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
5286 * Makefile.in: Include disable-implicit-rules.mk.
5288 2016-11-23 Pedro Alves <palves@redhat.com>
5290 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
5291 (debug_vprintf): Use std::chrono::steady_clock instead of
5292 gettimeofday. Use '.' instead of ':'.
5293 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
5294 (get_timestamp): Use std::chrono::steady_clock instead of
5297 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
5299 * Makefile.in: Fix whitespace formatting.
5301 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
5303 * Makefile.in (SFILES, OBS): Flatten list and order
5306 2016-11-23 Pedro Alves <palves@redhat.com>
5308 * event-loop.c (handle_file_event): Use warning.
5309 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
5310 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
5313 2016-11-23 Pedro Alves <palves@redhat.com>
5315 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
5317 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
5318 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
5319 debug_printf and debug_flush for debug output.
5320 * server.c (handle_general_set): Likewise.
5321 * thread-db.c (try_thread_db_load): Use debug_printf for debug
5324 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
5326 * Makefile.in (.c.o): Replace rule with ...
5327 (%.o: %.c): ... this one.
5329 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
5331 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
5332 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
5334 * configure.ac: Remove checks for the make program.
5335 * configure: Re-generate.
5337 2016-10-28 Pedro Alves <palves@redhat.com>
5339 * Makefile.in (CXX_DIALECT): Get from configure.
5340 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
5341 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
5342 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
5343 * config.in: Regenerate.
5344 * configure: Regenerate.
5346 2016-10-27 Yao Qi <yao.qi@linaro.org>
5348 * linux-low.c (linux_supports_range_stepping): Return true if
5349 can_software_single_step return true.
5351 2016-10-27 Yao Qi <yao.qi@linaro.org>
5353 * inferiors.c (find_inferior_in_random): New function.
5354 * inferiors.h (find_inferior_in_random): Declare.
5355 * linux-low.c (linux_wait_for_event_filtered): Call
5356 find_inferior_in_random instead of find_inferior.
5358 2016-10-27 Yao Qi <yao.qi@linaro.org>
5360 * linux-low.c (linux_wait_1): If single-step breakpoints are
5361 inserted, remove them.
5363 2016-10-26 Pedro Alves <palves@redhat.com>
5365 * linux-low.c (handle_extended_wait): Link parent/child fork
5367 (linux_wait_1): Unlink them.
5368 (linux_set_resume_request): Ignore resume requests for
5369 already-resumed and unhandled fork child threads.
5370 * linux-low.h (struct lwp_info) <fork_relative>: New field.
5371 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
5373 (handle_v_requests) <vCont>: Don't call require_running.
5374 * server.h (in_queued_stop_replies): New declaration.
5376 2016-10-24 Yao Qi <yao.qi@linaro.org>
5379 * linux-aarch64-low.c (append_insns): Cast the return value to
5382 2016-10-10 Yao Qi <yao.qi@linaro.org>
5384 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
5386 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
5388 * target.c (target_supports_multi_process): New function, moved
5390 * target.h (target_supports_multi_process): ... here. Remove
5393 2016-10-05 Tom Tromey <tom@tromey.com>
5396 * tracepoint.c (handle_tracepoint_bkpts): Check
5397 ipa_error_tracepoint, not ipa_stopping_tracepoint.
5399 2016-10-05 Yao Qi <yao.qi@linaro.org>
5401 * configure.srv: Update the path of arm-*.xml files.
5403 2016-10-05 Terry Guo <terry.guo@arm.com>
5404 Yao Qi <yao.qi@linaro.org>
5406 * Makefile.in: Adjust the path of rules.
5407 * configure.srv: Update the path of xml files.
5408 * regformats/arm-with-iwmmxt.dat: Regenerated.
5409 * regformats/arm-with-neon.dat: Likewise.
5410 * regformats/arm-with-vfpv2.dat: Likewise.
5411 * regformats/arm-with-vfpv3.dat Likewise.
5413 2016-09-30 Yao Qi <yao.qi@linaro.org>
5416 * target.c (target_stop_and_wait): Don't call
5417 target_continue_no_signal, use resume_stop instead.
5419 2016-09-26 Yao Qi <yao.qi@linaro.org>
5421 * linux-low.c (linux_wait_1): Call debug_exit.
5423 2016-09-23 Pedro Alves <palves@redhat.com>
5425 * Makefile.in (SFILES): Add common/new-op.c.
5426 (OBS): Add common/new-op.o.
5427 (new-op.o): New rule.
5429 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
5431 * .gitinore: Ignore more files.
5433 2016-09-21 Yao Qi <yao.qi@linaro.org>
5435 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
5438 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
5440 * server.c (start_inferior): Call target_mourn_inferior instead of
5441 mourn_inferior; pass ptid_t argument to it.
5443 (handle_target_event): Likewise.
5444 * target.c (target_mourn_inferior): New function.
5445 * target.h (mourn_inferior): Delete macro.
5447 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
5449 * linux-low.c (lwp_is_stepping): New function.
5451 2016-09-06 Carl Love <cel@us.ibm.com>
5453 * server.c (start_inferior): Fixed comment, requested comment change
5454 didn't get updated correctly. Removed reference to ptrace () call as
5455 it is only true on Linux systems.
5457 2016-09-06 Carl Love <cel@us.ibm.com>
5459 * server.c (start_inferior): Do not call
5460 function target_post_create_inferior () if the
5461 inferior process has already exited.
5463 2016-09-05 Pedro Alves <palves@redhat.com>
5465 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
5466 (COMPILE.pre, CC_LD): Use CXX directly.
5467 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
5468 * acinclude.m4: Don't include build-with-cxx.m4.
5469 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
5470 * configure: Regenerate.
5472 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
5475 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
5476 call writing data to own_buf.
5478 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
5480 * target.c (mywait): Call target_wait instead of
5482 (target_wait): New function.
5484 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
5486 * server.c (start_inferior): New variable 'ptid'. Replace calls
5487 to the_target->resume by target_continue{,_no_signal}, depending
5489 * target.c (target_stop_and_wait): Call target_continue_no_signal
5490 instead of the_target->resume.
5491 (target_continue): New function.
5493 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
5495 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
5497 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
5500 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
5502 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
5503 * linux-arm-low.c (ps_get_thread_area): Likewise.
5504 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
5505 * linux-m68k-low.c (ps_get_thread_area): Likewise.
5506 * linux-mips-low.c (ps_get_thread_area): Likewise.
5507 * linux-nios2-low.c (ps_get_thread_area): Likewise.
5508 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
5509 * linux-x86-low.c (ps_get_thread_area): Likewise.
5510 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
5512 2016-08-19 Pedro Alves <palves@redhat.com>
5514 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
5516 2016-08-19 Pedro Alves <palves@redhat.com>
5518 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
5519 comment. Use memcpy instead of casting through unsigned long.
5521 2016-08-19 Pedro Alves <palves@redhat.com>
5523 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
5524 allocating around 0x80000000.
5526 2016-08-19 Pedro Alves <palves@redhat.com>
5529 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
5530 (x32-avx512-linux-ipa.o): New rules.
5531 * configure.ac (x86_64-*-linux*): New x32 check.
5532 * configure.srv (ipa_x32_linux_regobj): New.
5533 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
5534 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
5536 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
5538 * configure: Regenerate.
5540 2016-08-09 Pedro Alves <palves@redhat.com>
5543 * Makefile.in (OBS): Add signals-state-save-restore.o.
5544 (signals-state-save-restore.o): New rule.
5545 * config.in: Regenerate.
5546 * configure: Regenerate.
5547 * linux-low.c: Include "signals-state-save-restore.h".
5548 (linux_create_inferior): Call
5549 restore_original_signals_state.
5550 * server.c: Include "dispositions-save-restore.h".
5551 (captured_main): Call save_original_signals_state.
5553 2016-08-05 Pedro Alves <palves@redhat.com>
5555 * configure: Regenerate.
5557 2016-08-04 Yao Qi <yao.qi@linaro.org>
5559 * linux-low.c (regsets_fetch_inferior_registers): Check
5560 errno is ESRCH or not.
5562 2016-08-02 Yao Qi <yao.qi@linaro.org>
5564 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
5565 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
5566 (thread_db_load_search): Update.
5567 (try_thread_db_load_1): Don't look for td_ta_event_addr,
5568 td_ta_set_event and td_ta_event_getmsg.
5570 2016-07-26 Pedro Alves <palves@redhat.com>
5573 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
5574 of unsigned long for 64-bit registers and use uint32_t instead of
5575 unsigned int for 32-bit registers.
5577 2016-07-26 Pedro Alves <palves@redhat.com>
5579 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
5582 2016-07-21 Tom Tromey <tom@tromey.com>
5584 * configure: Rebuild.
5586 2016-07-21 Yao Qi <yao.qi@linaro.org>
5588 * mem-break.c (find_gdb_breakpoint): Cast bp to
5589 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
5591 2016-07-21 Yao Qi <yao.qi@linaro.org>
5593 * server.c (handle_v_requests): Support s and S actions
5594 if target_supports_software_single_step return true.
5596 2016-07-21 Yao Qi <yao.qi@linaro.org>
5598 * linux-low.c (resume_stopped_resumed_lwps): If resume request
5599 is resume_step, call maybe_hw_step.
5600 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
5602 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
5604 (proceed_one_lwp): If resume request is resume_step, install
5605 reinsert breakpoints and call maybe_hw_step.
5607 2016-07-21 Yao Qi <yao.qi@linaro.org>
5609 * linux-low.c (proceed_one_lwp): Declare.
5610 (linux_resume_one_thread): Remove local variable 'step'.
5611 Lift code enqueue signal. Call proceed_one_lwp instead of
5612 linux_resume_one_lwp.
5614 2016-07-21 Yao Qi <yao.qi@linaro.org>
5616 * linux-low.c (linux_resume_one_thread): Call
5617 enqueue_pending_signal.
5619 2016-07-21 Yao Qi <yao.qi@linaro.org>
5621 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
5622 * inferiors.c (do_restore_current_thread_cleanup): New function.
5623 (make_cleanup_restore_current_thread): Likewise.
5624 * linux-low.c (install_software_single_step_breakpoints): Call
5625 make_cleanup_restore_current_thread. Switch current_thread to
5628 2016-07-21 Yao Qi <yao.qi@linaro.org>
5630 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
5631 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
5632 (clone_one_breakpoint): Likewise.
5633 (delete_reinsert_breakpoints): Change parameter to thread.
5635 (has_reinsert_breakpoints): Likewise.
5636 (uninsert_reinsert_breakpoints): Likewise.
5637 (reinsert_reinsert_breakpoints): Likewise.
5638 * mem-break.h (set_reinsert_breakpoint): Update declaration.
5639 (delete_reinsert_breakpoints): Likewise.
5640 (reinsert_reinsert_breakpoints): Likewise.
5641 (uninsert_reinsert_breakpoints): Likewise.
5642 (has_reinsert_breakpoints): Likewise.
5644 2016-07-21 Yao Qi <yao.qi@linaro.org>
5646 * inferiors.c (get_thread_process): Make parameter const.
5647 * inferiors.h (get_thread_process): Update declaration.
5648 * mem-break.c (clone_all_breakpoints): Remove all parameters.
5649 Add new parameters child_thread and parent_thread. Callers
5651 * mem-break.h (clone_all_breakpoints): Update declaration.
5653 2016-07-21 Yao Qi <yao.qi@linaro.org>
5655 * mem-break.c (struct breakpoint) <cond_list>: Remove.
5656 <command_list, handler>: Remove.
5657 (struct gdb_breakpoint): New.
5658 (struct other_breakpoint): New.
5659 (struct reinsert_breakpoint): New.
5660 (is_gdb_breakpoint): New function.
5661 (any_persistent_commands): Update command_list if
5662 is_gdb_breakpoint returns true.
5663 (set_breakpoint): Create breakpoints according to their types.
5664 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
5665 (set_gdb_breakpoint_1): Likewise.
5666 (set_gdb_breakpoint): Likewise.
5667 (clear_breakpoint_conditions): Change parameter type to
5668 'struct gdb_breakpoint *'.
5669 (clear_breakpoint_commands): Likewise.
5670 (clear_breakpoint_conditions_and_commands): Likewise.
5671 (add_condition_to_breakpoint): Likewise.
5672 (add_breakpoint_condition): Likewise.
5673 (add_commands_to_breakpoint): Likewise.
5674 (check_breakpoints): Check other_breakpoint.
5675 (clone_one_breakpoint): Clone breakpopint according to its type.
5676 * mem-break.h (struct gdb_breakpoint): Declare.
5677 (set_gdb_breakpoint): Update declaration.
5678 (clear_breakpoint_conditions_and_commands): Likewise.
5679 (add_breakpoint_condition): Likewise.
5680 (add_breakpoint_commands): Likewise.
5681 * server.c (process_point_options): Change parameter type to
5682 'struct gdb_breakpoint *'.
5684 2016-07-21 Yao Qi <yao.qi@linaro.org>
5686 * mem-break.c (set_breakpoint_at): Rename it to ...
5687 (set_breakpoint_type_at): ... it.
5688 (set_breakpoint_at): Call set_breakpoint_type_at.
5689 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
5690 * mem-break.h (set_breakpoint_at): Update comments.
5692 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
5694 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
5696 (nios2_store_gregset): Likewise.
5698 2016-07-01 Pedro Alves <palves@redhat.com>
5699 Antoine Tremblay <antoine.tremblay@ericsson.com>
5701 * linux-low.c: Change interface to take the target lwp_info
5702 pointer directly and return void. Handle detaching from a zombie
5704 (linux_detach_lwp_callback): New function.
5705 (linux_detach): Detach from the leader thread after detaching from
5708 2016-06-28 Yao Qi <yao.qi@linaro.org>
5710 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
5711 for variable new_offset.
5712 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
5713 (aarch64_ftrace_insn_reloc_cb): Likewise.
5714 (aarch64_ftrace_insn_reloc_tb): Likewise.
5715 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
5716 PRIx64 instead of PRIx32.
5718 2016-06-28 Yao Qi <yao.qi@linaro.org>
5720 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
5721 (the_low_target): Install arm_get_syscall_trapinfo.
5723 2016-06-28 Yao Qi <yao.qi@linaro.org>
5725 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
5727 (the_low_target): Install aarch64_get_syscall_trapinfo.
5729 2016-06-28 Yao Qi <yao.qi@linaro.org>
5731 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
5733 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
5734 Remove parameter sysno.
5735 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
5738 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5740 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
5741 (s390_emit_ne_goto): Likewise.
5742 (s390_emit_lt_goto): Likewise.
5743 (s390_emit_le_goto): Likewise.
5744 (s390_emit_gt_goto): Likewise.
5745 (s390_emit_ge_goto): Likewise.
5746 (s390x_emit_eq_goto): Likewise.
5747 (s390x_emit_ne_goto): Likewise.
5748 (s390x_emit_lt_goto): Likewise.
5749 (s390x_emit_le_goto): Likewise.
5750 (s390x_emit_gt_goto): Likewise.
5751 (s390x_emit_ge_goto): Likewise.
5752 (s390_emit_ops_impl): Mark variable static.
5753 (s390x_emit_ops): Likewise.
5755 2016-06-17 Yao Qi <yao.qi@linaro.org>
5757 * linux-low.c (handle_extended_wait): Call
5758 uninsert_reinsert_breakpoints for the parent process. Remove
5759 reinsert breakpoints from the child process. Reinsert them to
5760 the parent process when vfork is done.
5761 * mem-break.c (uninsert_reinsert_breakpoints): New function.
5762 (reinsert_reinsert_breakpoints): New function.
5763 * mem-break.h (uninsert_reinsert_breakpoints): Declare
5764 (reinsert_reinsert_breakpoints): Declare.
5766 2016-06-17 Yao Qi <yao.qi@linaro.org>
5768 * linux-low.c (handle_extended_wait): If the parent is doing
5769 step-over, remove the reinsert breakpoints from the forked child.
5771 2016-06-17 Yao Qi <yao.qi@linaro.org>
5773 * linux-low.c (unsuspend_all_lwps): Declare.
5774 (linux_low_filter_event): If thread exited, call finish_step_over.
5775 If step-over is finished, unsuspend other threads.
5777 2016-06-17 Yao Qi <yao.qi@linaro.org>
5779 * linux-low.c (linux_resume_one_lwp_throw): Assert
5780 has_reinsert_breakpoints returns false.
5781 * mem-break.c (delete_disabled_breakpoints): Assert
5782 bp type isn't reinsert_breakpoint.
5784 2016-06-17 Yao Qi <yao.qi@linaro.org>
5786 * linux-low.c (maybe_hw_step): New function.
5787 (linux_resume_one_lwp_throw): Call maybe_hw_step.
5788 (finish_step_over): Switch current_thread to lwp temporarily,
5789 and assert has_reinsert_breakpoints returns true.
5790 (proceed_one_lwp): Call maybe_hw_step.
5791 * mem-break.c (has_reinsert_breakpoints): New function.
5792 * mem-break.h (has_reinsert_breakpoints): Declare.
5794 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
5796 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
5798 2016-05-17 Yao Qi <yao.qi@linaro.org>
5800 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
5801 instead of find_inferior.
5803 2016-05-05 Yao Qi <yao.qi@linaro.org>
5805 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
5806 Initialize res to zero.
5808 2016-05-05 Yao Qi <yao.qi@linaro.org>
5810 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
5813 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
5815 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
5816 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
5817 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
5819 2016-04-28 Par Olsson <par.olsson@windriver.com>
5820 Simon Marchi <simon.marchi@ericsson.com>
5822 * tracepoint.c (write_inferior_int8): New function.
5823 (cmd_qtenable_disable): Write enable flag using
5824 write_inferior_int8.
5826 2016-04-25 Yao Qi <yao.qi@linaro.org>
5828 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
5829 (need_step_over_p): Return zero if the LWP has pending signals
5830 can be delivered on software single step target.
5832 2016-04-25 Yao Qi <yao.qi@linaro.org>
5834 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
5835 return instead of error.
5837 2016-04-22 Yao Qi <yao.qi@linaro.org>
5839 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
5842 2016-04-22 Yao Qi <yao.qi@linaro.org>
5844 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
5845 signal when stepping over breakpoint with software single
5848 2016-04-21 Pedro Alves <palves@redhat.com>
5850 * linux-s390-low.c (s390_collect_ptrace_register)
5851 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
5853 (s390_check_regset): Use void * instead of gdb_byte *.
5855 2016-04-20 Pedro Alves <palves@redhat.com>
5857 * configure: Renegerate.
5859 2016-04-20 Yao Qi <yao.qi@linaro.org>
5861 * linux-aarch32-low.c: Include "arch/arm-linux.h".
5862 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
5864 (arm_store_gregset): Likewise.
5866 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
5868 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
5869 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
5870 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
5871 (amd64-avx-mpx-linux.c): New rules.
5872 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
5873 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
5874 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
5875 (srv_amd64_regobj): Add amd64-avx-mpx.o.
5876 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
5877 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
5878 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
5879 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
5880 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
5881 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
5882 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
5883 * linux-x86-low.c (x86_linux_read_description): Add case for
5884 X86_XSTATE_AVX_MPX_MASK.
5885 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
5886 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
5887 init_registers_i386_avx_mpx_linux.
5888 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
5889 (initialize_low_tracepoint): Call
5890 init_registers_i386_avx_mpx_linux.
5891 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
5892 (initialize_low_tracepoint): Call
5893 init_registers_amd64_avx_mpx_linux.
5894 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
5895 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
5896 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
5899 2016-04-18 Pedro Alves <palves@redhat.com>
5901 * configure: Regenerate.
5903 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
5905 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
5906 (aarch64_emit_sub): Likewise.
5908 2016-04-12 Pedro Alves <palves@redhat.com>
5910 * utils.c (prepare_to_throw_exception): Delete.
5912 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
5914 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
5916 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
5918 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
5920 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
5922 * linux-aarch64-ipa.c: Add <elf.h> include.
5923 * linux-ppc-ipa.c: Add <elf.h> include.
5924 * linux-s390-ipa.c: Add <elf.h> include.
5926 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
5928 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
5929 (get_raw_reg_ptr): Likewise.
5930 (get_trace_state_variable_value_ptr): Likewise.
5931 (set_trace_state_variable_value_ptr): Likewise.
5932 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
5935 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
5936 Marcin Kościelnicki <koriakin@0x04.net>
5939 * linux-ppc-low.c (emit_insns): New function.
5940 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
5941 (ppc_emit_prologue): New function.
5942 (ppc_emit_epilogue): New function.
5943 (ppc_emit_add): New function.
5944 (ppc_emit_sub): New function.
5945 (ppc_emit_mul): New function.
5946 (ppc_emit_lsh): New function.
5947 (ppc_emit_rsh_signed): New function.
5948 (ppc_emit_rsh_unsigned): New function.
5949 (ppc_emit_ext): New function.
5950 (ppc_emit_zero_ext): New function.
5951 (ppc_emit_log_not): New function.
5952 (ppc_emit_bit_and): New function.
5953 (ppc_emit_bit_or): New function.
5954 (ppc_emit_bit_xor): New function.
5955 (ppc_emit_bit_not): New function.
5956 (ppc_emit_equal): New function.
5957 (ppc_emit_less_signed): New function.
5958 (ppc_emit_less_unsigned): New function.
5959 (ppc_emit_ref): New function.
5960 (ppc_emit_const): New function.
5961 (ppc_emit_reg): New function.
5962 (ppc_emit_pop): New function.
5963 (ppc_emit_stack_flush): New function.
5964 (ppc_emit_swap): New function.
5965 (ppc_emit_stack_adjust): New function.
5966 (ppc_emit_call): New function.
5967 (ppc_emit_int_call_1): New function.
5968 (ppc_emit_void_call_2): New function.
5969 (ppc_emit_if_goto): New function.
5970 (ppc_emit_goto): New function.
5971 (ppc_emit_eq_goto): New function.
5972 (ppc_emit_ne_goto): New function.
5973 (ppc_emit_lt_goto): New function.
5974 (ppc_emit_le_goto): New function.
5975 (ppc_emit_gt_goto): New function.
5976 (ppc_emit_ge_goto): New function.
5977 (ppc_write_goto_address): New function.
5978 (ppc_emit_ops_impl): New static variable.
5979 (ppc64v1_emit_prologue): New function.
5980 (ppc64v2_emit_prologue): New function.
5981 (ppc64_emit_epilogue): New function.
5982 (ppc64_emit_add): New function.
5983 (ppc64_emit_sub): New function.
5984 (ppc64_emit_mul): New function.
5985 (ppc64_emit_lsh): New function.
5986 (ppc64_emit_rsh_signed): New function.
5987 (ppc64_emit_rsh_unsigned): New function.
5988 (ppc64_emit_ext): New function.
5989 (ppc64_emit_zero_ext): New function.
5990 (ppc64_emit_log_not): New function.
5991 (ppc64_emit_bit_and): New function.
5992 (ppc64_emit_bit_or): New function.
5993 (ppc64_emit_bit_xor): New function.
5994 (ppc64_emit_bit_not): New function.
5995 (ppc64_emit_equal): New function.
5996 (ppc64_emit_less_signed): New function.
5997 (ppc64_emit_less_unsigned): New function.
5998 (ppc64_emit_ref): New function.
5999 (ppc64_emit_const): New function.
6000 (ppc64v1_emit_reg): New function.
6001 (ppc64v2_emit_reg): New function.
6002 (ppc64_emit_pop): New function.
6003 (ppc64_emit_stack_flush): New function.
6004 (ppc64_emit_swap): New function.
6005 (ppc64v1_emit_call): New function.
6006 (ppc64v2_emit_call): New function.
6007 (ppc64v1_emit_int_call_1): New function.
6008 (ppc64v2_emit_int_call_1): New function.
6009 (ppc64v1_emit_void_call_2): New function.
6010 (ppc64v2_emit_void_call_2): New function.
6011 (ppc64_emit_if_goto): New function.
6012 (ppc64_emit_eq_goto): New function.
6013 (ppc64_emit_ne_goto): New function.
6014 (ppc64_emit_lt_goto): New function.
6015 (ppc64_emit_le_goto): New function.
6016 (ppc64_emit_gt_goto): New function.
6017 (ppc64_emit_ge_goto): New function.
6018 (ppc64v1_emit_ops_impl): New static variable.
6019 (ppc64v2_emit_ops_impl): New static variable.
6020 (ppc_emit_ops): New function.
6021 (linux_low_target): Wire in ppc_emit_ops.
6023 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
6024 Marcin Kościelnicki <koriakin@0x04.net>
6027 * Makefile.in: Add powerpc-*-ipa.o
6028 * configure.srv: Add ipa_obj for powerpc*-linux.
6029 * linux-ppc-ipa.c: New file.
6030 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
6032 (PPC_FIELD): New macro.
6033 (PPC_SEXT): New macro.
6034 (PPC_OP6): New macro.
6035 (PPC_BO): New macro.
6036 (PPC_LI): New macro.
6037 (PPC_BD): New macro.
6038 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
6039 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
6040 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
6041 (ppc_get_thread_area): New function.
6042 (is_elfv2_inferior): New function.
6043 (gen_ds_form): New function.
6044 (GEN_STD): New macro.
6045 (GEN_STDU): New macro.
6046 (GEN_LD): New macro.
6047 (GEN_LDU): New macro.
6048 (gen_d_form): New function.
6049 (GEN_ADDI): New macro.
6050 (GEN_ADDIS): New macro.
6051 (GEN_LI): New macro.
6052 (GEN_LIS): New macro.
6053 (GEN_ORI): New macro.
6054 (GEN_ORIS): New macro.
6055 (GEN_LWZ): New macro.
6056 (GEN_STW): New macro.
6057 (GEN_STWU): New macro.
6058 (gen_xfx_form): New function.
6059 (GEN_MFSPR): New macro.
6060 (GEN_MTSPR): New macro.
6061 (GEN_MFCR): New macro.
6062 (GEN_MTCR): New macro.
6063 (GEN_SYNC): New macro.
6064 (GEN_LWSYNC): New macro.
6065 (gen_x_form): New function.
6066 (GEN_OR): New macro.
6067 (GEN_MR): New macro.
6068 (GEN_LWARX): New macro.
6069 (GEN_STWCX): New macro.
6070 (GEN_CMPW): New macro.
6071 (gen_md_form): New function.
6072 (GEN_RLDICL): New macro.
6073 (GEN_RLDICR): New macro.
6074 (gen_i_form): New function.
6076 (GEN_BL): New macro.
6077 (gen_b_form): New function.
6078 (GEN_BNE): New macro.
6079 (GEN_LOAD): New macro.
6080 (GEN_STORE): New macro.
6081 (gen_limm): New function.
6082 (gen_atomic_xchg): New function.
6083 (gen_call): New function.
6084 (ppc_relocate_instruction): New function.
6085 (ppc_install_fast_tracepoint_jump_pad): New function.
6086 (ppc_get_min_fast_tracepoint_insn_len): New function.
6087 (ppc_get_ipa_tdesc_idx): New function.
6088 (the_low_target): Wire in the new functions.
6089 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
6091 * linux-ppc-tdesc.h: New file.
6093 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
6095 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
6096 (alloc_jump_pad_buffer): New function.
6097 * linux-amd64-ipa.c: Add <sys/mman.h> include.
6098 (alloc_jump_pad_buffer): New function.
6099 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
6100 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
6101 (alloc_jump_pad_buffer): New function.
6102 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
6103 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
6104 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
6105 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
6107 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
6109 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
6110 * linux-amd64-ipa.c: Likewise.
6111 * linux-i386-ipa.c: Likewise.
6112 * linux-s390-ipa.c: Likewise.
6113 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
6114 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
6115 set_trace_state_variable_value_ptr.
6116 (struct ipa_sym_addresses): Likewise.
6117 (symbol_list): Likewise.
6118 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
6119 accessing gdb_collect directly.
6120 (gdb_collect_ptr_type): New typedef.
6121 (get_raw_reg_ptr_type): New typedef.
6122 (get_trace_state_variable_value_ptr_type): New typedef.
6123 (set_trace_state_variable_value_ptr_type): New typedef.
6124 (gdb_collect_ptr): New global.
6125 (get_raw_reg_ptr): New global.
6126 (get_trace_state_variable_value_ptr): New global.
6127 (set_trace_state_variable_value_ptr): New global.
6128 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
6129 accessing get_raw_reg directly.
6130 (get_get_tsv_func_addr): Likewise for
6131 get_trace_state_variable_value_ptr.
6132 (get_set_tsv_func_addr): Likewise for
6133 set_trace_state_variable_value_ptr.
6134 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
6136 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
6138 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
6140 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
6142 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
6144 (relocate_instruction): Remove own_buf.
6145 * server.c (own_buf): Make global.
6146 (handle_v_requests): Make global.
6147 * server.h (own_buf): New declaration.
6148 (handle_v_requests): New prototype.
6150 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
6153 * linux-s390-low.c (add_insns): New function.
6154 (s390_emit_prologue): New function.
6155 (s390_emit_epilogue): New function.
6156 (s390_emit_add): New function.
6157 (s390_emit_sub): New function.
6158 (s390_emit_mul): New function.
6159 (s390_emit_lsh): New function.
6160 (s390_emit_rsh_signed): New function.
6161 (s390_emit_rsh_unsigned): New function.
6162 (s390_emit_ext): New function.
6163 (s390_emit_log_not): New function.
6164 (s390_emit_bit_and): New function.
6165 (s390_emit_bit_or): New function.
6166 (s390_emit_bit_xor): New function.
6167 (s390_emit_bit_not): New function.
6168 (s390_emit_equal): New function.
6169 (s390_emit_less_signed): New function.
6170 (s390_emit_less_unsigned): New function.
6171 (s390_emit_ref): New function.
6172 (s390_emit_if_goto): New function.
6173 (s390_emit_goto): New function.
6174 (s390_write_goto_address): New function.
6175 (s390_emit_litpool): New function.
6176 (s390_emit_const): New function.
6177 (s390_emit_call): New function.
6178 (s390_emit_reg): New function.
6179 (s390_emit_pop): New function.
6180 (s390_emit_stack_flush): New function.
6181 (s390_emit_zero_ext): New function.
6182 (s390_emit_swap): New function.
6183 (s390_emit_stack_adjust): New function.
6184 (s390_emit_set_r2): New function.
6185 (s390_emit_int_call_1): New function.
6186 (s390_emit_void_call_2): New function.
6187 (s390_emit_eq_goto): New function.
6188 (s390_emit_ne_goto): New function.
6189 (s390_emit_lt_goto): New function.
6190 (s390_emit_le_goto): New function.
6191 (s390_emit_gt_goto): New function.
6192 (s390_emit_ge_goto): New function.
6193 (s390x_emit_prologue): New function.
6194 (s390x_emit_epilogue): New function.
6195 (s390x_emit_add): New function.
6196 (s390x_emit_sub): New function.
6197 (s390x_emit_mul): New function.
6198 (s390x_emit_lsh): New function.
6199 (s390x_emit_rsh_signed): New function.
6200 (s390x_emit_rsh_unsigned): New function.
6201 (s390x_emit_ext): New function.
6202 (s390x_emit_log_not): New function.
6203 (s390x_emit_bit_and): New function.
6204 (s390x_emit_bit_or): New function.
6205 (s390x_emit_bit_xor): New function.
6206 (s390x_emit_bit_not): New function.
6207 (s390x_emit_equal): New function.
6208 (s390x_emit_less_signed): New function.
6209 (s390x_emit_less_unsigned): New function.
6210 (s390x_emit_ref): New function.
6211 (s390x_emit_if_goto): New function.
6212 (s390x_emit_const): New function.
6213 (s390x_emit_call): New function.
6214 (s390x_emit_reg): New function.
6215 (s390x_emit_pop): New function.
6216 (s390x_emit_stack_flush): New function.
6217 (s390x_emit_zero_ext): New function.
6218 (s390x_emit_swap): New function.
6219 (s390x_emit_stack_adjust): New function.
6220 (s390x_emit_int_call_1): New function.
6221 (s390x_emit_void_call_2): New function.
6222 (s390x_emit_eq_goto): New function.
6223 (s390x_emit_ne_goto): New function.
6224 (s390x_emit_lt_goto): New function.
6225 (s390x_emit_le_goto): New function.
6226 (s390x_emit_gt_goto): New function.
6227 (s390x_emit_ge_goto): New function.
6228 (s390_emit_ops): New function.
6229 (struct linux_target_ops): Fill in emit_ops hook.
6231 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
6234 * Makefile.in: Add s390 IPA files.
6235 * configure.srv: Build IPA for s390.
6236 * linux-s390-ipa.c: New file.
6237 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
6238 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
6239 (tdesc_s390_linux32): Likewise.
6240 (init_registers_s390_linux32v1): Likewise.
6241 (tdesc_s390_linux32v1): Likewise.
6242 (init_registers_s390_linux32v2): Likewise.
6243 (tdesc_s390_linux32v2): Likewise.
6244 (init_registers_s390_linux64): Likewise.
6245 (tdesc_s390_linux64): Likewise.
6246 (init_registers_s390_linux64v1): Likewise.
6247 (tdesc_s390_linux64v1): Likewise.
6248 (init_registers_s390_linux64v2): Likewise.
6249 (tdesc_s390_linux64v2): Likewise.
6250 (init_registers_s390_te_linux64): Likewise.
6251 (tdesc_s390_te_linux64): Likewise.
6252 (init_registers_s390_vx_linux64): Likewise.
6253 (tdesc_s390_vx_linux64): Likewise.
6254 (init_registers_s390_tevx_linux64): Likewise.
6255 (tdesc_s390_tevx_linux64): Likewise.
6256 (init_registers_s390x_linux64): Likewise.
6257 (tdesc_s390x_linux64): Likewise.
6258 (init_registers_s390x_linux64v1): Likewise.
6259 (tdesc_s390x_linux64v1): Likewise.
6260 (init_registers_s390x_linux64v2): Likewise.
6261 (tdesc_s390x_linux64v2): Likewise.
6262 (init_registers_s390x_te_linux64): Likewise.
6263 (tdesc_s390x_te_linux64): Likewise.
6264 (init_registers_s390x_vx_linux64): Likewise.
6265 (tdesc_s390x_vx_linux64): Likewise.
6266 (init_registers_s390x_tevx_linux64): Likewise.
6267 (tdesc_s390x_tevx_linux64): Likewise.
6268 (have_hwcap_s390_vx): New static variable.
6269 (s390_arch_setup): Fill have_hwcap_s390_vx.
6270 (s390_get_thread_area): New function.
6271 (s390_ft_entry_gpr_esa): New const.
6272 (s390_ft_entry_gpr_zarch): New const.
6273 (s390_ft_entry_misc): New const.
6274 (s390_ft_entry_fr): New const.
6275 (s390_ft_entry_vr): New const.
6276 (s390_ft_main_31): New const.
6277 (s390_ft_main_64): New const.
6278 (s390_ft_exit_fr): New const.
6279 (s390_ft_exit_vr): New const.
6280 (s390_ft_exit_misc): New const.
6281 (s390_ft_exit_gpr_esa): New const.
6282 (s390_ft_exit_gpr_zarch): New const.
6283 (append_insns): New function.
6284 (s390_relocate_instruction): New function.
6285 (s390_install_fast_tracepoint_jump_pad): New function.
6286 (s390_get_min_fast_tracepoint_insn_len): New function.
6287 (s390_get_ipa_tdesc_idx): New function.
6288 (struct linux_target_ops): Wire in the above functions.
6289 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
6290 * linux-s390-tdesc.h: New file.
6292 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
6294 * linux-s390-low.c (s390_supports_tracepoints): New function.
6295 (struct linux_target_ops): Fill supports_tracepoints hook.
6297 2016-03-18 Yao Qi <yao.qi@linaro.org>
6299 * linux-low.c (lwp_signal_can_be_delivered): New function.
6300 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
6302 2016-03-18 Yao Qi <yao.qi@linaro.org>
6304 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
6305 0 if signal is enqueued. Remove 'signal' from one debugging
6306 message. Move one debugging message to some lines below.
6307 Remove code setting 'signal' to 0.
6309 2016-03-18 Yao Qi <yao.qi@linaro.org>
6311 * linux-low.c (linux_low_filter_event): Remove redundant
6312 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
6314 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
6316 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
6317 (struct linux_target_ops): Wire in the above.
6319 2016-03-03 Yao Qi <yao.qi@linaro.org>
6321 * linux-low.c: Update comments to start_step_over.
6323 2016-03-03 Yao Qi <yao.qi@linaro.org>
6326 * linux-low.c (handle_extended_wait): Set child suspended
6327 if event_lwp->bp_reinsert isn't zero.
6329 2016-03-02 Yao Qi <yao.qi@linaro.org>
6331 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
6332 enqueue_pending_signal.
6334 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
6336 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
6339 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
6341 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
6342 (s390_regmap_3264) [!__s390x__]: New global.
6343 (s390_collect_ptrace_register): Skip map entries containing -1.
6344 (s390_supply_ptrace_register): Ditto.
6345 (s390_fill_gprs_high): New function.
6346 (s390_store_gprs_high): New function.
6347 (s390_regsets): Add NT_S390_HIGH_GPRS.
6348 (s390_get_hwcap): Enable on 31-bit.
6349 (have_hwcap_s390_high_gprs): Enable on 31-bit.
6350 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
6351 Detect NT_S390_HIGH_GPRS.
6352 (s390_usrregs_info_3264): Enable on 31-bit.
6353 (s390_regs_info): Enable regs_info_3264 on 31-bit.
6354 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
6356 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
6359 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
6360 * configure.srv: Ditto.
6361 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
6362 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
6363 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
6364 (init_registers_amd64_linux): Remove prototype.
6365 (tdesc_amd64_linux): Remove declaration.
6366 (get_ipa_tdesc): New function.
6367 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
6368 initialize remaining tdescs.
6369 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
6370 (init_registers_i386_linux): Remove prototype.
6371 (tdesc_i386_linux): Remove declaration.
6372 (get_ipa_tdesc): New function.
6373 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
6374 initialize remaining tdescs.
6375 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
6376 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
6377 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
6378 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
6379 (x86_get_ipa_tdesc_idx): New function.
6380 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
6381 * linux-x86-tdesc.h: New file.
6382 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
6383 (target_get_ipa_tdesc_idx): New macro.
6384 * tracepoint.c (ipa_tdesc_idx): New macro.
6385 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
6386 (symbol_list): Add ipa_tdesc_idx.
6387 (cmd_qtstart): Write ipa_tdesc_idx in the target.
6388 (ipa_tdesc): Remove.
6389 (ipa_tdesc_idx): New variable.
6390 (get_context_regcache): Use get_ipa_tdesc.
6391 (gdb_collect): Ditto.
6393 * tracepoint.h (get_ipa_tdesc): New prototype.
6394 (ipa_tdesc): Remove.
6396 2016-02-24 Pedro Alves <palves@redhat.com>
6398 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
6399 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
6400 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
6401 Factor out common code between the USE_SIGTRAP_SIGINFO and
6402 !USE_SIGTRAP_SIGINFO blocks.
6403 (linux_low_filter_event): Call save_stop_reason instead of
6404 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
6406 (linux_wait_1): Update comments.
6408 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
6410 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
6411 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
6412 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
6413 ppc_insert_point, ppc_remove_point.
6415 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
6417 * linux-s390-low.c (s390_supports_z_point_type): New function.
6418 (struct linux_target_ops): Wire s390_supports_z_point_type in.
6420 2016-02-16 Yao Qi <yao.qi@linaro.org>
6422 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
6423 PC. Get pc from regcache_read_pc.
6425 2016-02-12 Yao Qi <yao.qi@linaro.org>
6427 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
6428 or linux_get_pc_32bit.
6429 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
6431 2016-02-12 Yao Qi <yao.qi@linaro.org>
6433 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
6434 arm_linux_get_next_pcs_fixup.
6436 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
6438 * tracepoint.c (x_tracepoint_action_download): Change
6439 write_inferior_data_ptr to write_inferior_data_pointer.
6440 (cmd_qtstart): Likewise.
6441 (write_inferior_data_ptr): Remove.
6442 (download_agent_expr): Change write_inferior_data_ptr to
6443 write_inferior_data_pointer.
6444 (download_tracepoint_1): Likewise.
6445 (download_tracepoint): Likewise.
6446 (download_trace_state_variables): Likewise.
6448 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
6449 Marcin Kościelnicki <koriakin@0x04.net>
6451 * tracepoint.c (struct tracepoint_action_ops): Remove.
6452 (struct tracepoint_action): Remove ops.
6453 (m_tracepoint_action_download, r_tracepoint_action_download)
6454 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
6455 size and offset accordingly.
6456 (m_tracepoint_action_ops, r_tracepoint_action_ops)
6457 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
6458 (tracepoint_action_send, tracepoint_action_download): New functions.
6459 Helpers for trace action handlers.
6460 (add_tracepoint_action): Remove setup actions ops.
6461 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
6463 2016-02-10 Yao Qi <yao.qi@linaro.org>
6465 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
6467 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
6469 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
6471 * configure: Regenerate.
6473 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
6475 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
6476 void * to gdb_byte *.
6477 * linux-low.c (siginfo_fixup): Likewise.
6478 (linux_xfer_siginfo): Likewise.
6479 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
6481 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
6483 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
6485 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
6487 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
6489 * linux-x86-low.c [__x86_64__]: Include
6490 "nat/amd64-linux-siginfo.h".
6491 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
6492 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
6493 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
6494 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
6495 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
6496 (cpt_si_fd, si_timerid, si_overrun): Move from
6497 nat/amd64-linux-siginfo.c.
6498 * Makefile.in (amd64-linux-siginfo.o:): New rule.
6500 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
6502 * server.c (skip_to_semicolon): Remove.
6503 (process_point_options): Use strchrnul instead of
6506 2016-01-26 Yao Qi <yao.qi@linaro.org>
6508 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
6509 * linux-low.c (install_software_single_step_breakpoints): Don't
6510 call regcache_read_pc.
6511 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
6514 2016-01-26 Yao Qi <yao.qi@linaro.org>
6516 * linux-low.c (install_software_single_step_breakpoints): Call
6517 regcache_read_pc instead of get_pc.
6519 2016-01-26 Yao Qi <yao.qi@linaro.org>
6521 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
6522 (unblock_async_io): Rename to ...
6523 (block_unblock_async_io): ... it. New function.
6524 (enable_async_io): Don't install SIGIO handler. Unblock it
6526 (disable_async_io): Don't ignore SIGIO. Block it instead.
6527 (initialize_async_io): Install SIGIO handler. Don't call
6530 2016-01-26 Yao Qi <yao.qi@linaro.org>
6532 * remote-utils.c (getpkt): If the buffer isn't empty, and the
6533 first character is '\003', call *the_target->request_interrupt.
6535 2016-01-25 Yao Qi <yao.qi@linaro.org>
6537 * remote-utils.c (new_thread_notify): Remove.
6538 (dead_thread_notify): Likewise.
6539 * remote-utils.h (new_thread_notify): Remove declaration.
6540 (dead_thread_notify): Likewise.
6542 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
6544 * gdb.trace/pending.exp: Fix expected message on continue.
6546 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
6548 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
6549 it works properly on big-endian machines where sizeof (CORE_ADDR)
6552 2016-01-21 Pedro Alves <palves@redhat.com>
6554 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
6555 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
6556 * configure: Regenerate.
6558 2016-01-21 Yao Qi <yao.qi@linaro.org>
6560 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
6561 is_thumb and set it according to CPSR saved on the stack.
6562 (get_next_pcs_syscall_next_pc): Pass is_thumb to
6563 arm_sigreturn_next_pc.
6565 2016-01-18 Yao Qi <yao.qi@linaro.org>
6567 * linux-low.c (linux_set_pc_64bit): New function.
6568 (linux_get_pc_64bit): New function.
6569 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
6571 * linux-sparc-low.c (debug_threads): Remove declaration.
6572 (sparc_get_pc): Remove.
6573 (the_low_target): Use linux_get_pc_64bit instead of
6575 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
6576 (the_low_target): Use linux_get_pc_64bit and
6579 2016-01-18 Yao Qi <yao.qi@linaro.org>
6581 * linux-arm-low.c (debug_threads): Remove declaration.
6582 (arm_get_pc, arm_set_pc): Remove.
6583 (the_low_target): Use linux_get_pc_32bit and
6585 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
6586 (the_low_target): Use linux_get_pc_32bit and
6588 * linux-cris-low.c (debug_threads): Remove declaration.
6589 (cris_get_pc, cris_set_pc,): Remove.
6590 (the_low_target): Use linux_get_pc_32bit and
6592 * linux-crisv32-low.c (debug_threads): Remove declaration.
6593 (cris_get_pc, cris_set_pc): Remove.
6594 (the_low_target): Use linux_get_pc_32bit and
6596 * linux-low.c: Include inttypes.h.
6597 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
6598 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
6599 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
6600 (the_low_target): Use linux_get_pc_32bit and
6602 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
6603 (the_low_target): Use linux_get_pc_32bit and
6605 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
6606 (the_low_target): Use linux_get_pc_32bit and
6608 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
6609 (the_low_target): Use linux_get_pc_32bit and
6611 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
6612 (the_low_target): Use linux_get_pc_32bit and
6615 2016-01-18 Gary Benson <gbenson@redhat.com>
6617 * configure.ac (AC_FUNC_FORK): New check.
6618 * config.in: Regenerate.
6619 * configure: Likewise.
6621 2016-01-14 Yao Qi <yao.qi@linaro.org>
6623 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
6624 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
6625 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
6626 arm_get_next_pcs_ctor.
6628 2016-01-12 Josh Stone <jistone@redhat.com>
6629 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6631 * inferiors.h: Include "gdb_vecs.h".
6632 (struct process_info): Add syscalls_to_catch.
6633 * inferiors.c (remove_process): Free syscalls_to_catch.
6634 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
6635 syscall_return stops.
6636 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
6637 * server.c (handle_general_set): Handle QCatchSyscalls.
6638 (handle_query): Report support for QCatchSyscalls.
6639 * target.h (struct target_ops): Add supports_catch_syscall.
6640 (target_supports_catch_syscall): New macro.
6641 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
6642 (struct lwp_info): Add syscall_state.
6643 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
6644 Maintain syscall_state and syscalls_to_catch across exec.
6645 (get_syscall_trapinfo): New function, proxy to the_low_target.
6646 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
6647 (linux_low_filter_event): Toggle syscall_state entry/return for
6648 syscall traps, and set it ignored for all others.
6649 (gdb_catching_syscalls_p): New function.
6650 (gdb_catch_this_syscall_p): New function.
6651 (linux_wait_1): Handle SYSCALL_SIGTRAP.
6652 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
6653 (linux_supports_catch_syscall): New function.
6654 (linux_target_ops): Install it.
6655 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
6656 (the_low_target): Install it.
6658 2016-01-12 Mike Frysinger <vapier@gentoo.org>
6660 * acinclude.m4: Include new ../warning.m4 file.
6661 * configure: Regenerated.
6662 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
6664 2016-01-12 Mike Frysinger <vapier@gentoo.org>
6666 * ax.c (is_goto_target): Mark static.
6667 * linux-low.c (register_addr): Likewise.
6668 (linux_fetch_registers, linux_store_registers): Likewise.
6669 * mem-break.c (any_persistent_commands): Fix old prototype.
6670 (add_commands_to_breakpoint): Mark static.
6671 * regcache.c (find_register_by_name): Delete unused func.
6672 * remote-utils.c (hex_or_minus_one): Mark static.
6673 * server.c (monitor_show_help): Mark static.
6674 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
6675 handle_v_requests): Likewise.
6677 2016-01-12 Pedro Alves <palves@redhat.com>
6679 Remove use of the registered trademark symbol throughout.
6681 2016-01-08 Yao Qi <yao.qi@linaro.org>
6683 * remote-utils.c (getpkt): If c is '\003', call target hook
6686 2016-01-06 Yao Qi <yao.qi@linaro.org>
6688 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
6689 linux-aarch32-low.c.
6690 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6691 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
6692 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
6693 (thumb2_breakpoint): Declare.
6694 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
6695 linux-aarch32-low.h.
6696 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6697 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
6698 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
6700 2016-01-01 Joel Brobecker <brobecker@adacore.com>
6702 * gdbreplay.c (gdbreplay_version): Change copyright year in
6704 * server.c (gdbserver_version): Likewise.
6706 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
6708 * server.c (crc32_table): Delete.
6709 (crc32): Use libiberty's xcrc32 function.
6711 2015-12-22 Joel Brobecker <brobecker@adacore.com>
6713 * lynx-low.c (lynx_delete_thread_callback): New function.
6714 (lynx_mourn): Properly delete our process and all of its
6715 threads. Remove call to clear_inferiors.
6717 2015-12-22 Joel Brobecker <brobecker@adacore.com>
6719 * target.c (thread_search_callback): Add check that
6720 the thread_stopped target callback is not NULL before
6723 2015-12-21 Yao Qi <yao.qi@linaro.org>
6725 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
6728 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6730 * server.c (handle_query): Call target_supports_software_single_step.
6732 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6734 * linux-low.c (single_step): New function.
6735 (linux_resume_one_lwp_throw): Call single_step.
6736 (start_step_over): Likewise.
6738 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6740 * Makefile.in (SFILES): Append arch/arm-linux.c,
6741 arch/arm-get-next-pcs.c.
6742 (arm-linux.o): New rule.
6743 (arm-get-next-pcs.o): New rule.
6744 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
6746 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
6747 to linux-aarch32-low.c.
6748 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6749 (arm_breakpoint_len, thumb_breakpoint): Likewise.
6750 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
6751 (thumb2_breakpoint_len): Likewise.
6752 (arm_is_thumb_mode): Make non-static.
6753 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
6754 from linux-aarch32-low.c.
6755 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6756 (arm_breakpoint_len, thumb_breakpoint): Likewise.
6757 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
6758 (thumb2_breakpoint_len): Likewise.
6759 (arm_is_thumb_mode): New declaration.
6760 * linux-arm-low.c: Include arch/arm-linux.h
6761 aarch/arm-get-next-pcs.h, sys/syscall.h.
6762 (get_next_pcs_ops): New struct.
6763 (get_next_pcs_addr_bits_remove): New function.
6764 (get_next_pcs_is_thumb): New function.
6765 (get_next_pcs_read_memory_unsigned_integer): Likewise.
6766 (arm_sigreturn_next_pc): Likewise.
6767 (get_next_pcs_syscall_next_pc): Likewise.
6768 (arm_gdbserver_get_next_pcs): Likewise.
6769 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
6771 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
6772 * server.h: Include gdb_vecs.h.
6774 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6776 * Makefile.in (SFILES): Append common/common-regcache.c.
6777 (OBS): Append common-regcache.o.
6778 (common-regcache.o): New rule.
6779 * regcache.c (init_register_cache): Initialize cache to
6781 (regcache_raw_read_unsigned): New function.
6782 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
6783 register_status enum.
6785 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6787 * linux-aarch64-low.c (the_low_targets): Rename
6788 breakpoint_reinsert_addr to get_next_pcs.
6789 * linux-arm-low.c (the_low_targets): Likewise.
6790 * linux-bfin-low.c (the_low_targets): Likewise.
6791 * linux-cris-low.c (the_low_targets): Likewise.
6792 * linux-crisv32-low.c (the_low_targets): Likewise.
6793 * linux-low.c (can_software_single_step): Likewise.
6794 (install_software_single_step_breakpoints): New function.
6795 (start_step_over): Use install_software_single_step_breakpoints.
6796 * linux-low.h: New CORE_ADDR vector.
6797 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
6799 * linux-mips-low.c (the_low_targets): Likewise.
6800 * linux-nios2-low.c (the_low_targets): Likewise.
6801 * linux-sparc-low.c (the_low_targets): Likewise.
6803 2015-12-17 Pedro Alves <palves@redhat.com>
6805 * linux-low.c (linux_kill_one_lwp): Remove references to
6807 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
6809 (linux_init_signals): Delete.
6810 (initialize_low): Adjust.
6811 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
6813 2015-12-16 Pedro Alves <palves@redhat.com>
6815 * configure.ac (compiler warning flags): When testing a
6816 -Wno-foo option, check whether -Wfoo works instead.
6817 * configure: Regenerate.
6819 2015-12-11 Don Breazeal <donb@codesourcery.com>
6821 * server.c (process_serial_event): Don't exit from gdbserver
6822 in remote mode if there are still active inferiors.
6824 2015-12-11 Yao Qi <yao.qi@linaro.org>
6826 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
6827 arm_breakpoint_at if the process is 32-bit.
6829 2015-12-11 Yao Qi <yao.qi@linaro.org>
6831 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
6834 2015-12-07 Yao Qi <yao.qi@linaro.org>
6836 * configure.srv: Append arm.o to srv_tgtobj for
6837 aarch64*-*-linux* target.
6838 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
6839 from linux-arm-low.c.
6840 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6841 (arm_breakpoint_len, thumb_breakpoint): Likewise.
6842 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
6843 (thumb2_breakpoint_len): Likewise.
6844 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
6845 (arm_breakpoint_kinds): Likewise.
6846 (arm_breakpoint_kind_from_pc): Likewise.
6847 (arm_sw_breakpoint_from_kind): Likewise.
6848 (arm_breakpoint_kind_from_current_state): Likewise.
6849 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
6850 (arm_sw_breakpoint_from_kind): Declare.
6851 (arm_breakpoint_kind_from_current_state): Declare.
6852 (arm_breakpoint_at): Declare.
6853 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
6854 arm_sw_breakpoint_from_kind if process is 32-bit.
6855 (aarch64_breakpoint_kind_from_pc): New function.
6856 (aarch64_breakpoint_kind_from_current_state): New function.
6857 (the_low_target): Initialize fields breakpoint_kind_from_pc
6858 and breakpoint_kind_from_current_state.
6859 * linux-arm-low.c (arm_breakpoint_kinds): Move to
6860 linux-aarch32-low.c.
6861 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
6862 (arm_breakpoint, arm_breakpoint_len): Likewise.
6863 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
6864 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
6865 (arm_is_thumb_mode): Likewise.
6866 (arm_breakpoint_at): Likewise.
6867 (arm_breakpoint_kind_from_pc): Likewise.
6868 (arm_sw_breakpoint_from_kind): Likewise.
6869 (arm_breakpoint_kind_from_current_state): Likewise.
6872 2015-08-04 Yao Qi <yao.qi@linaro.org>
6874 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
6875 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
6876 * server.c (extended_protocol): Remove "static".
6877 * server.h (extended_protocol): Declare it.
6879 2015-12-04 Josh Stone <jistone@redhat.com>
6881 * target.h (struct target_ops) <arch_setup>: Rename to ...
6882 (struct target_ops) <post_create_inferior>: ... this.
6883 (target_arch_setup): Rename to ...
6884 (target_post_create_inferior): ... this, calling post_create_inferior.
6885 * server.c (start_inferior): Update target_arch_setup calls to
6886 target_post_create_inferior.
6887 * linux-low.c (linux_low_ptrace_options): Forward declare.
6888 (linux_arch_setup): Update its comment for general use.
6889 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
6890 (struct linux_target_ops): Use linux_post_create_inferior.
6891 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
6892 to post_create_inferior.
6893 * nto-low.c (struct nto_target_ops): Likewise.
6894 * spu-low.c (struct spu_target_ops): Likewise.
6895 * win32-low.c (struct win32_target_ops): Likewise.
6897 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
6899 * linux-arm-low.c: Remove duplicate arch/arm.h include.
6901 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6903 * linux-arm-low.c (arm_reinsert_addr): Remove function.
6904 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
6905 * linux-cris-low.c (cris_reinsert_addr> Remove function.
6906 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6907 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
6908 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6909 * linux-mips-low.c (mips_reinsert_addr): Remove function.
6910 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6911 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
6912 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6913 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
6914 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6916 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6918 * linux-low.c (linux_look_up_symbols): Don't call
6919 linux_supports_traceclone.
6920 * linux-low.h (thread_db_init): Remove use_events argument.
6921 * thread-db.c (thread_db_use_event): Remove global variable.
6922 (struct thread_db) <td_thr_event_enable_p>: Remove field.
6923 (struct thread_db) <td_create_bp>: Remove field.
6924 (thread_db_create_event): Remove function.
6925 (thread_db_enable_reporting): Likewise.
6926 (find_one_thread): Don't check for thread_db_use_events.
6927 (attach_thread): Likewise.
6928 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
6929 (try_thread_db_load_1): Don't check for thread_db_use_events.
6930 (thread_db_init): Remove use_events argument and thread events
6932 (remove_thread_event_breakpoints): Remove function.
6933 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
6935 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6937 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
6939 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6940 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
6941 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6942 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
6943 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
6945 * linux-crisv32-low.c (cris_supports_hardware_single_step):
6947 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6948 * linux-low.c (can_hardware_single_step): Use
6949 supports_hardware_single_step.
6950 (can_software_single_step): New function.
6951 (start_step_over): Call can_software_single_step.
6952 (linux_supports_hardware_single_step): New function.
6953 (struct target_ops) <supports_software_single_step>: Initialize.
6954 * linux-low.h (struct linux_target_ops)
6955 <supports_hardware_single_step>: Initialize.
6956 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
6957 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6958 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
6959 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
6960 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
6961 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6962 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
6963 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6964 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
6965 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
6967 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
6968 (struct linux_target_ops) <tile_supports_hardware_single_step>:
6970 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
6971 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6972 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
6974 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6975 * target.h (struct target_ops): <supports_software_single_step>:
6977 (target_supports_software_single_step): New macro.
6979 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6981 * linux-low.c (linux_wait_1): Fix pc advance condition.
6982 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
6983 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
6985 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6987 * linux-arm-low.c (arm_is_thumb_mode): New function.
6988 (arm_breakpoint_at): Use arm_is_thumb_mode.
6989 (arm_breakpoint_kind_from_current_state): New function.
6990 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
6992 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
6993 (linux_breakpoint_kind_from_current_state): New function.
6994 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
6995 * linux-low.h (struct linux_target_ops)
6996 <breakpoint_kind_from_current_state>: New field.
6997 * target.h (struct target_ops): Likewise.
6998 (target_breakpoint_kind_from_current_state): New macro.
7000 2015-11-30 Pedro Alves <palves@redhat.com>
7002 * linux-low.c (linux_resume): Wake up the event loop before
7005 2015-11-30 Pedro Alves <palves@redhat.com>
7007 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
7009 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
7011 * target.c (struct thread_search): New structure.
7012 (thread_search_callback): New function.
7013 (prev_general_thread): New global.
7014 (prepare_to_access_memory, done_accessing_memory): New functions.
7015 * target.h (prepare_to_access_memory, done_accessing_memory):
7016 Replace macros with function declarations.
7018 2015-11-30 Pedro Alves <palves@redhat.com>
7021 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
7022 report TARGET_WAITKIND_NO_RESUMED.
7023 * remote-utils.c (prepare_resume_reply): Handle
7024 TARGET_WAITKIND_NO_RESUMED.
7025 * server.c (report_no_resumed): New global.
7026 (handle_query) <qSupported>: Handle "no-resumed+". Report
7027 "no-resumed+" support.
7028 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
7029 return error if the client doesn't support no-resumed events.
7030 (push_stop_notification): New function.
7031 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
7032 events if the client supports them.
7034 2015-11-30 Pedro Alves <palves@redhat.com>
7036 * linux-low.c (thread_still_has_status_pending_p): Don't check
7038 (lwp_resumed): New function.
7039 (status_pending_p_callback): Return early if the LWP is not
7040 supposed to be resumed.
7042 2015-11-30 Pedro Alves <palves@redhat.com>
7044 * linux-low.c (handle_extended_wait): Assert that the LWP's
7045 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
7046 thread create events, leave the new child's status pending.
7047 (linux_low_filter_event): If GDB wants to hear about thread exit
7048 events, leave the LWP marked dead and don't delete it.
7049 (linux_wait_for_event_filtered): Don't check for thread exit.
7050 (filter_exit_event): New function.
7051 (linux_wait_1): Use it, when returning an exit event.
7052 (linux_resume_one_lwp_throw): Assert that the LWP's
7053 waitstatus is TARGET_WAITKIND_IGNORE.
7054 * remote-utils.c (prepare_resume_reply): Handle
7055 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
7056 * server.c (report_thread_events): New global.
7057 (handle_general_set): Handle QThreadEvents.
7058 (handle_query) <qSupported>: Handle and report QThreadEvents+;
7059 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
7060 TARGET_WAITKIND_THREAD_EXITED.
7061 * server.h (report_thread_events): Declare.
7063 2015-11-30 Pedro Alves <palves@redhat.com>
7065 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
7066 the thread's last_resume_kind was resume_stop.
7068 2015-11-30 Pedro Alves <palves@redhat.com>
7070 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
7073 2015-11-30 Pedro Alves <palves@redhat.com>
7075 * server.c (handle_v_requests): Handle vCtrlC.
7077 2015-11-30 Pedro Alves <palves@redhat.com>
7079 * gdbthread.h (find_any_thread_of_pid): Declare.
7080 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
7082 * server.c (handle_query): If current_thread is NULL, look for
7083 another thread of the selected process.
7085 2015-11-26 Daniel Colascione <dancol@dancol.org>
7086 Simon Marchi <simon.marchi@ericsson.com>
7088 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
7089 * server.c (handle_qxfer_threads_worker): Refactor to include thread
7091 * target.h (struct target_ops) <thread_name>: New field.
7092 (target_thread_name): New macro.
7094 2015-11-23 Joel Brobecker <brobecker@adacore.com>
7096 * regcache.h (regcache_invalidate_pid): Add declaration.
7097 * regcache.c (regcache_invalidate_pid): New function, extracted
7098 from regcache_invalidate.
7099 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
7100 Add trivial documentation comment.
7101 * lynx-low.c: Use regcache_invalidate_pid instead of
7102 regcache_invalidate.
7104 2015-11-23 Joel Brobecker <brobecker@adacore.com>
7106 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
7107 and Elf64_auxv_t if the target is Android.
7109 2015-11-22 Doug Evans <xdje42@gmail.com>
7111 * target.h: #include <sys/types.h>.
7113 2015-11-19 Pedro Alves <palves@redhat.com>
7115 * linux-low.c (linux_process_qsupported): Change prototype.
7117 * linux-low.h (struct linux_target_ops) <process_qsupported>:
7119 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
7120 and adjust to loop over all features.
7121 * server.c (handle_query) <qSupported>: Adjust to call
7122 target_process_qsupported once, passing it a vector of unprocessed
7124 * target.h (struct target_ops) <process_qsupported>: Change
7126 (target_process_qsupported): Adjust.
7128 2015-11-19 Pedro Alves <palves@redhat.com>
7130 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
7132 * configure: Regenerate.
7134 2015-11-19 Pedro Alves <palves@redhat.com>
7136 * configure: Regenerate.
7138 2015-11-19 Yao Qi <yao.qi@linaro.org>
7140 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
7143 2015-11-19 Yao Qi <yao.qi@linaro.org>
7145 * linux-aarch64-low.c (enum aarch64_operand_type): New.
7146 (struct aarch64_operand): Move enum out.
7148 2015-11-19 Yao Qi <yao.qi@linaro.org>
7150 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
7151 struct user_fpsimd_state *.
7152 (aarch64_store_fpregset): Likewise.
7154 2015-11-19 Yao Qi <yao.qi@linaro.org>
7156 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
7157 struct user_pt_regs *.
7158 (aarch64_store_gregset): Likewise.
7160 2015-11-18 Pedro Alves <palves@redhat.com>
7162 * Makefile.in (all_object_files): Add $IPA_OBJS.
7164 2015-11-17 Pedro Alves <palves@redhat.com>
7166 * win32-low.c (win32_resume): Use gdb_signal_from_host,
7167 GDB_SIGNAL_0 and gdb_signal_to_string.
7169 2015-11-17 Pedro Alves <palves@redhat.com>
7171 * win32-low.c (handle_output_debug_string): Remove parameter.
7172 (win32_kill): Remove our_status local and adjust call to
7173 handle_output_debug_string.
7174 (get_child_debug_event): Adjust call to
7175 handle_output_debug_string.
7177 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7179 * linux-mips-low.c (mips_fill_gregset): Add cast.
7180 (mips_store_gregset): Likewise.
7181 (mips_fill_fpregset): Likewise.
7182 (mips_store_fpregset): Likewise.
7184 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7186 * linux-mips-low.c (mips_add_watchpoint): Rename private to
7189 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7191 * linux-mips-low.c (mips_linux_new_thread): Change type of
7192 watch_type to enum target_hw_bp_type.
7194 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7196 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
7197 Change return type to arm_hwbp_type.
7199 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7201 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
7202 (arm_store_gregset): Likewise.
7203 * linux-arm-low.c (arm_get_hwcap): Likewise.
7204 (arm_read_description): Likewise.
7206 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7208 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
7210 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7212 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
7213 (ppc_fill_vsxregset): Likewise.
7214 (ppc_store_vsxregset): Likewise.
7215 (ppc_fill_vrregset): Likewise.
7216 (ppc_store_vrregset): Likewise.
7217 (ppc_fill_evrregset): Likewise.
7218 (ppc_store_evrregset): Likewise.
7220 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7222 * linux-ppc-low.c (ppc_usrregs_info): Remove
7223 forward-declaration.
7224 (ppc_arch_setup): Move lower in file.
7226 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
7228 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
7229 (ps_pdwrite): Likewise.
7231 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
7233 * linux-arm-low.c (arm_new_thread): Move pointer dereference
7234 to after assert checks.
7236 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
7238 * proc-service.c (ps_pdread): Add/adjust casts.
7239 (ps_pdwrite): Add/adjust casts.
7241 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
7243 * server.c (handle_search_memory_1): Cast return value of
7246 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
7248 * server.c (write_qxfer_response): Change type of data to
7251 2015-10-29 Pedro Alves <palves@redhat.com>
7253 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
7255 2015-10-29 Pedro Alves <palves@redhat.com>
7257 * tracepoint.c (clear_installed_tracepoints): Add casts.
7259 2015-10-29 Pedro Alves <palves@redhat.com>
7261 * server.c (handle_v_cont, process_serial_event): Add enum
7262 gdb_signal casts to signal parsing code.
7264 2015-10-29 Pedro Alves <palves@redhat.com>
7266 * linux-low.h (NULL_REGSET): Define.
7267 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
7268 * linux-arm-low.c (arm_regsets): Likewise.
7269 * linux-crisv32-low.c (cris_regsets): Likewise.
7270 * linux-m68k-low.c (m68k_regsets): Likewise.
7271 * linux-mips-low.c (mips_regsets): Likewise.
7272 * linux-nios2-low.c (nios2_regsets): Likewise.
7273 * linux-ppc-low.c (ppc_regsets): Likewise.
7274 * linux-s390-low.c (s390_regsets): Likewise.
7275 * linux-sh-low.c (sh_regsets): Likewise.
7276 * linux-sparc-low.c (sparc_regsets): Likewise.
7277 * linux-tic6x-low.c (tic6x_regsets): Likewise.
7278 * linux-tile-low.c (tile_regsets): Likewise.
7279 * linux-x86-low.c (x86_regsets): Likewise.
7280 * linux-xtensa-low.c (xtensa_regsets): Likewise.
7282 2015-10-29 Pedro Alves <palves@redhat.com>
7284 * linux-low.h (NULL_REGSET): Define.
7285 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
7286 * linux-arm-low.c (arm_regsets): Likewise.
7287 * linux-crisv32-low.c (cris_regsets): Likewise.
7288 * linux-m68k-low.c (m68k_regsets): Likewise.
7289 * linux-mips-low.c (mips_regsets): Likewise.
7290 * linux-nios2-low.c (nios2_regsets): Likewise.
7291 * linux-ppc-low.c (ppc_regsets): Likewise.
7292 * linux-s390-low.c (s390_regsets): Likewise.
7293 * linux-sh-low.c (sh_regsets): Likewise.
7294 * linux-sparc-low.c (sparc_regsets): Likewise.
7295 * linux-tic6x-low.c (tic6x_regsets): Likewise.
7296 * linux-tile-low.c (tile_regsets): Likewise.
7297 * linux-x86-low.c (x86_regsets): Likewise.
7298 * linux-xtensa-low.c (xtensa_regsets): Likewise.
7300 2015-10-26 Doug Evans <dje@google.com>
7302 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
7304 2015-10-26 Doug Evans <dje@google.com>
7306 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
7308 2015-10-26 Doug Evans <dje@google.com>
7310 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
7312 (attach_thread, find_new_threads_callback): Ditto.
7314 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
7316 * mem-break.h (set_breakpoint_data): Remove.
7318 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
7320 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
7321 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
7322 (initialize_low): Remove set_breakpoint_data call.
7323 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
7324 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
7325 (initialize_low): Remove set_breakpoint_data call.
7326 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
7327 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
7328 (initialize_low): Remove set_breakpoint_data call.
7330 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
7332 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
7333 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
7334 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
7335 * target.h (target_breakpoint_kind_from_pc): New macro.
7337 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
7339 * linux-low.c (default_breakpoint_kind_from_pc): New function.
7340 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
7341 the default breakpoint kind.
7343 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7345 * linux-arm-low.c (arm_supports_z_point_type): Add software
7348 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7350 * linux-arm-low.c: Refactor breakpoint definitions.
7351 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
7352 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
7354 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7356 * Makefile.in: Add arm.c/o.
7357 * configure.srv: Likewise.
7358 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
7359 (arm_breakpoint_kind_from_pc): New function.
7360 (arm_sw_breakpoint_from_kind): Return proper kind.
7361 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
7363 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7365 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
7367 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
7368 (struct raw_breakpoint) <size>: Remove.
7369 (struct raw_breakpoint) <kind>: Add.
7370 (bp_size): New function.
7371 (bp_opcode): Likewise.
7372 (find_raw_breakpoint_at): Adjust for kind.
7373 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
7374 (remove_memory_breakpoint): Adjust for kind call bp_size.
7375 (set_raw_breakpoint_at): Adjust for kind.
7376 (set_breakpoint): Likewise.
7377 (set_breakpoint_at): Call breakpoint_kind_from_pc.
7378 (delete_raw_breakpoint): Adjust for kind.
7379 (delete_breakpoint): Likewise.
7380 (find_gdb_breakpoint): Likewise.
7381 (set_gdb_breakpoint_1): Likewise.
7382 (set_gdb_breakpoint): Likewise.
7383 (delete_gdb_breakpoint_1): Likewise.
7384 (delete_gdb_breakpoint): Likewise.
7385 (uninsert_raw_breakpoint): Likewise.
7386 (reinsert_raw_breakpoint): Likewise.
7387 (set_breakpoint_data): Remove.
7388 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
7389 (check_mem_read): Adjust for kind call bp_size.
7390 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
7391 (clone_one_breakpoint): Adjust for kind.
7392 * mem-break.h (set_gdb_breakpoint): Likewise.
7393 (delete_gdb_breakpoint): Likewise.
7394 * server.c (process_serial_event): Likewise.
7396 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7398 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
7399 (struct linux_target_ops) <breakpoint>: Remove.
7400 (struct linux_target_ops) <breakpoint_len>: Remove.
7401 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7402 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7403 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
7404 (arm_sw_breakpoint_from_kind): New function.
7405 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
7406 (struct linux_target_ops) <breakpoint>: Remove.
7407 (struct linux_target_ops) <breakpoint_len>: Remove.
7408 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7409 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7410 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
7411 (struct linux_target_ops) <breakpoint>: Remove.
7412 (struct linux_target_ops) <breakpoint_len>: Remove.
7413 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7414 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7415 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
7416 (struct linux_target_ops) <breakpoint>: Remove.
7417 (struct linux_target_ops) <breakpoint_len>: Remove.
7418 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7419 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7420 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
7421 and sw_breakpoint_from_kind to increment the pc.
7422 (linux_breakpoint_kind_from_pc): New function.
7423 (linux_sw_breakpoint_from_kind): New function.
7424 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
7425 (initialize_low): Call breakpoint_kind_from_pc and
7426 sw_breakpoint_from_kind to replace breakpoint_data/len.
7427 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
7429 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
7430 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
7431 (struct linux_target_ops) <breakpoint>: Remove.
7432 (struct linux_target_ops) <breakpoint_len>: Remove.
7433 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7434 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7435 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
7436 (struct linux_target_ops) <breakpoint>: Remove.
7437 (struct linux_target_ops) <breakpoint_len>: Remove.
7438 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7439 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7440 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
7441 (struct linux_target_ops) <breakpoint>: Remove.
7442 (struct linux_target_ops) <breakpoint_len>: Remove.
7443 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7444 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7445 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
7446 (struct linux_target_ops) <breakpoint>: Remove.
7447 (struct linux_target_ops) <breakpoint_len>: Remove.
7448 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7449 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7450 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
7451 (struct linux_target_ops) <breakpoint>: Remove.
7452 (struct linux_target_ops) <breakpoint_len>: Remove.
7453 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7454 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7455 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
7456 (struct linux_target_ops) <breakpoint>: Remove.
7457 (struct linux_target_ops) <breakpoint_len>: Remove.
7458 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7459 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7460 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
7461 (struct linux_target_ops) <breakpoint>: Remove.
7462 (struct linux_target_ops) <breakpoint_len>: Remove.
7463 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7464 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7465 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
7466 (struct linux_target_ops) <breakpoint>: Remove.
7467 (struct linux_target_ops) <breakpoint_len>: Remove.
7468 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7469 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7470 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
7471 (struct linux_target_ops) <breakpoint>: Remove.
7472 (struct linux_target_ops) <breakpoint_len>: Remove.
7473 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7474 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7475 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
7476 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
7477 (struct linux_target_ops) <breakpoint>: Remove.
7478 (struct linux_target_ops) <breakpoint_len>: Remove.
7479 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7480 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7481 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
7482 (struct linux_target_ops) <breakpoint>: Remove.
7483 (struct linux_target_ops) <breakpoint_len>: Remove.
7484 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7485 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7487 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7489 * linux-cris-low.c (cris_get_pc): Remove void arg.
7491 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
7493 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
7496 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
7498 * inferiors.c (thread_pid_matches_callback): New function.
7499 (find_thread_process): New function.
7500 (remove_thread): Reset current_thread.
7501 (remove_process): Assert threads have been removed first.
7503 2015-10-15 Yao Qi <yao.qi@linaro.org>
7505 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
7507 (aarch64_remove_point): Likewise.
7508 * regcache.c (regcache_register_size): New function.
7510 2015-10-12 Yao Qi <yao.qi@linaro.org>
7512 * linux-aarch64-low.c: Update all callers as emit_load_store
7513 is renamed to aarch64_emit_load_store.
7515 2015-10-12 Yao Qi <yao.qi@linaro.org>
7517 * linux-aarch64-low.c: Update all callers of function renaming
7518 from emit_insn to aarch64_emit_insn.
7520 2015-10-12 Yao Qi <yao.qi@linaro.org>
7522 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
7523 arch/aarch64-insn.h.
7524 (struct aarch64_memory_operand): Likewise.
7526 (emit_insn): Move to arch/aarch64-insn.c.
7527 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
7528 (emit_load_store): Move to arch/aarch64-insn.c.
7529 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
7530 (can_encode_int32): Remove.
7532 2015-10-12 Yao Qi <yao.qi@linaro.org>
7534 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
7535 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
7536 (aarch64_relocate_instruction): Likewise.
7537 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
7538 (struct aarch64_insn_visitor): Likewise.
7540 2015-10-12 Yao Qi <yao.qi@linaro.org>
7542 * linux-aarch64-low.c (struct aarch64_insn_data): New.
7543 (struct aarch64_insn_visitor): New.
7544 (struct aarch64_insn_relocation_data): New.
7545 (aarch64_ftrace_insn_reloc_b): New function.
7546 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
7547 (aarch64_ftrace_insn_reloc_cb): Likewise.
7548 (aarch64_ftrace_insn_reloc_tb): Likewise.
7549 (aarch64_ftrace_insn_reloc_adr): Likewise.
7550 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
7551 (aarch64_ftrace_insn_reloc_others): Likewise.
7553 (aarch64_relocate_instruction): Use visitor.
7555 2015-10-12 Yao Qi <yao.qi@linaro.org>
7557 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
7558 int. Add argument buf.
7559 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
7560 aarch64_relocate_instruction.
7562 2015-10-12 Yao Qi <yao.qi@linaro.org>
7564 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
7565 argument insn. Remove local variable insn. Don't call
7567 (aarch64_install_fast_tracepoint_jump_pad): Call
7570 2015-09-30 Yao Qi <yao.qi@linaro.org>
7572 * linux-aarch64-low.c (emit_movk): Shorten a long line.
7573 (emit_load_store_pair): Likewise.
7575 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
7577 * dll.c (match_dll): Add cast(s).
7578 (unloaded_dll): Likewise.
7579 * linux-low.c (second_thread_of_pid_p): Likewise.
7580 (delete_lwp_callback): Likewise.
7581 (count_events_callback): Likewise.
7582 (select_event_lwp_callback): Likewise.
7583 (linux_set_resume_request): Likewise.
7584 * server.c (accumulate_file_name_length): Likewise.
7585 (emit_dll_description): Likewise.
7586 (handle_qxfer_threads_worker): Likewise.
7587 (visit_actioned_threads): Likewise.
7588 * thread-db.c (any_thread_of): Likewise.
7589 * tracepoint.c (same_process_p): Likewise.
7590 (match_blocktype): Likewise.
7591 (build_traceframe_info_xml): Likewise.
7593 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
7595 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
7597 (gdb_unparse_agent_expr): Likewise.
7598 * hostio.c (require_data): Likewise.
7599 (handle_pread): Likewise.
7600 * linux-low.c (disable_regset): Likewise.
7601 (fetch_register): Likewise.
7602 (store_register): Likewise.
7603 (get_dynamic): Likewise.
7604 (linux_qxfer_libraries_svr4): Likewise.
7605 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
7606 (set_fast_tracepoint_jump): Likewise.
7607 (uninsert_fast_tracepoint_jumps_at): Likewise.
7608 (reinsert_fast_tracepoint_jumps_at): Likewise.
7609 (validate_inserted_breakpoint): Likewise.
7610 (clone_agent_expr): Likewise.
7611 * regcache.c (init_register_cache): Likewise.
7612 * remote-utils.c (putpkt_binary_1): Likewise.
7613 (decode_M_packet): Likewise.
7614 (decode_X_packet): Likewise.
7615 (look_up_one_symbol): Likewise.
7616 (relocate_instruction): Likewise.
7617 (monitor_output): Likewise.
7618 * server.c (handle_search_memory): Likewise.
7619 (handle_qxfer_exec_file): Likewise.
7620 (handle_qxfer_libraries): Likewise.
7621 (handle_qxfer): Likewise.
7622 (handle_query): Likewise.
7623 (handle_v_cont): Likewise.
7624 (handle_v_run): Likewise.
7625 (captured_main): Likewise.
7626 * target.c (write_inferior_memory): Likewise.
7627 * thread-db.c (try_thread_db_load_from_dir): Likewise.
7628 * tracepoint.c (init_trace_buffer): Likewise.
7629 (add_tracepoint_action): Likewise.
7630 (add_traceframe): Likewise.
7631 (add_traceframe_block): Likewise.
7632 (cmd_qtdpsrc): Likewise.
7633 (cmd_qtdv): Likewise.
7634 (cmd_qtstatus): Likewise.
7635 (response_source): Likewise.
7636 (response_tsv): Likewise.
7637 (cmd_qtnotes): Likewise.
7638 (gdb_collect): Likewise.
7639 (initialize_tracepoint): Likewise.
7641 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
7643 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
7644 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
7645 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
7647 (enum aarch64_condition_codes): New enum.
7648 (w0): New static global.
7651 (struct aarch64_memory_operand) <type>: New
7652 MEMORY_OPERAND_POSTINDEX type.
7653 (postindex_memory_operand): New helper function.
7654 (emit_ret): New function.
7655 (emit_load_store_pair): New function, factored out of emit_stp
7656 with support for MEMORY_OPERAND_POSTINDEX.
7657 (emit_stp): Rewrite using emit_load_store_pair.
7658 (emit_ldp): New function.
7659 (emit_load_store): Likewise.
7660 (emit_ldr): Mention post-index instruction in comment.
7661 (emit_ldrh): New function.
7662 (emit_ldrb): New function.
7663 (emit_ldrsw): Mention post-index instruction in comment.
7664 (emit_str): Likewise.
7665 (emit_subs): New function.
7666 (emit_cmp): Likewise.
7667 (emit_and): Likewise.
7668 (emit_orr): Likewise.
7669 (emit_orn): Likewise.
7670 (emit_eor): Likewise.
7671 (emit_mvn): Likewise.
7672 (emit_lslv): Likewise.
7673 (emit_lsrv): Likewise.
7674 (emit_asrv): Likewise.
7675 (emit_mul): Likewise.
7676 (emit_sbfm): Likewise.
7677 (emit_sbfx): Likewise.
7678 (emit_ubfm): Likewise.
7679 (emit_ubfx): Likewise.
7680 (emit_csinc): Likewise.
7681 (emit_cset): Likewise.
7682 (emit_nop): Likewise.
7683 (emit_ops_insns): New helper function.
7684 (emit_pop): Likewise.
7685 (emit_push): Likewise.
7686 (aarch64_emit_prologue): New function.
7687 (aarch64_emit_epilogue): Likewise.
7688 (aarch64_emit_add): Likewise.
7689 (aarch64_emit_sub): Likewise.
7690 (aarch64_emit_mul): Likewise.
7691 (aarch64_emit_lsh): Likewise.
7692 (aarch64_emit_rsh_signed): Likewise.
7693 (aarch64_emit_rsh_unsigned): Likewise.
7694 (aarch64_emit_ext): Likewise.
7695 (aarch64_emit_log_not): Likewise.
7696 (aarch64_emit_bit_and): Likewise.
7697 (aarch64_emit_bit_or): Likewise.
7698 (aarch64_emit_bit_xor): Likewise.
7699 (aarch64_emit_bit_not): Likewise.
7700 (aarch64_emit_equal): Likewise.
7701 (aarch64_emit_less_signed): Likewise.
7702 (aarch64_emit_less_unsigned): Likewise.
7703 (aarch64_emit_ref): Likewise.
7704 (aarch64_emit_if_goto): Likewise.
7705 (aarch64_emit_goto): Likewise.
7706 (aarch64_write_goto_address): Likewise.
7707 (aarch64_emit_const): Likewise.
7708 (aarch64_emit_call): Likewise.
7709 (aarch64_emit_reg): Likewise.
7710 (aarch64_emit_pop): Likewise.
7711 (aarch64_emit_stack_flush): Likewise.
7712 (aarch64_emit_zero_ext): Likewise.
7713 (aarch64_emit_swap): Likewise.
7714 (aarch64_emit_stack_adjust): Likewise.
7715 (aarch64_emit_int_call_1): Likewise.
7716 (aarch64_emit_void_call_2): Likewise.
7717 (aarch64_emit_eq_goto): Likewise.
7718 (aarch64_emit_ne_goto): Likewise.
7719 (aarch64_emit_lt_goto): Likewise.
7720 (aarch64_emit_le_goto): Likewise.
7721 (aarch64_emit_gt_goto): Likewise.
7722 (aarch64_emit_ge_got): Likewise.
7723 (aarch64_emit_ops_impl): New static global variable.
7724 (aarch64_emit_ops): New target function, return
7725 &aarch64_emit_ops_impl.
7726 (struct linux_target_ops): Install it.
7728 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
7730 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
7731 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
7733 * linux-aarch64-ipa.c: New file.
7734 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
7736 (aarch64_get_thread_area): New target method.
7737 (extract_signed_bitfield): New helper function.
7738 (aarch64_decode_ldr_literal): New function.
7739 (enum aarch64_opcodes): New enum.
7740 (struct aarch64_register): New struct.
7741 (struct aarch64_operand): New struct.
7742 (x0): New static global.
7751 (aarch64_register): New helper function.
7752 (register_operand): Likewise.
7753 (immediate_operand): Likewise.
7754 (struct aarch64_memory_operand): New struct.
7755 (offset_memory_operand): New helper function.
7756 (preindex_memory_operand): Likewise.
7757 (enum aarch64_system_control_registers): New enum.
7758 (ENCODE): New macro.
7759 (emit_insn): New helper function.
7760 (emit_b): New function.
7761 (emit_bcond): Likewise.
7762 (emit_cb): Likewise.
7763 (emit_tb): Likewise.
7764 (emit_blr): Likewise.
7765 (emit_stp): Likewise.
7766 (emit_ldp_q_offset): Likewise.
7767 (emit_stp_q_offset): Likewise.
7768 (emit_load_store): Likewise.
7769 (emit_ldr): Likewise.
7770 (emit_ldrsw): Likewise.
7771 (emit_str): Likewise.
7772 (emit_ldaxr): Likewise.
7773 (emit_stxr): Likewise.
7774 (emit_stlr): Likewise.
7775 (emit_data_processing_reg): Likewise.
7776 (emit_data_processing): Likewise.
7777 (emit_add): Likewise.
7778 (emit_sub): Likewise.
7779 (emit_mov): Likewise.
7780 (emit_movk): Likewise.
7781 (emit_mov_addr): Likewise.
7782 (emit_mrs): Likewise.
7783 (emit_msr): Likewise.
7784 (emit_sevl): Likewise.
7785 (emit_wfe): Likewise.
7786 (append_insns): Likewise.
7787 (can_encode_int32_in): New helper function.
7788 (aarch64_relocate_instruction): New function.
7789 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
7790 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
7791 (struct linux_target_ops): Install aarch64_get_thread_area,
7792 aarch64_install_fast_tracepoint_jump_pad and
7793 aarch64_get_min_fast_tracepoint_insn_len.
7795 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
7797 * Makefile.in (aarch64-insn.o): New rule.
7798 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
7800 2015-09-21 Yao Qi <yao.qi@linaro.org>
7802 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
7804 2015-09-21 Yao Qi <yao.qi@linaro.org>
7806 * tracepoint.c (max_jump_pad_size): Remove.
7808 2015-09-18 Yao Qi <yao.qi@linaro.org>
7810 * linux-aarch64-low.c: Don't include sys/uio.h.
7811 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
7813 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
7815 * tracepoint.c (eval_result_type): Change prototype.
7816 (condition_true_at_tracepoint): Fix argument to compiled_cond.
7818 2015-09-15 Pedro Alves <palves@redhat.com>
7820 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
7821 Check whether to report exec events instead of checking whether
7822 multiprocess is enabled.
7824 2015-09-15 Pedro Alves <palves@redhat.com>
7827 * remote-utils.c (prepare_resume_reply): Merge
7828 TARGET_WAITKIND_VFORK_DONE switch case with the
7829 TARGET_WAITKIND_FORKED case.
7831 2015-09-15 Yao Qi <yao.qi@linaro.org>
7833 * server.c (handle_query): Check string comparison using
7834 "else if" instead of "if".
7836 2015-09-15 Yao Qi <yao.qi@linaro.org>
7838 * server.c (vCont_supported): New global variable.
7839 (handle_query): Set vCont_supported to 1 if "vContSupported+"
7840 matches. Append ";vContSupported+" to own_buf.
7841 (handle_v_requests): Append ";s;S" to own_buf if target supports
7842 hardware single step or vCont_supported is false.
7843 (capture_main): Set vCont_supported to zero.
7845 2015-09-15 Yao Qi <yao.qi@linaro.org>
7847 * linux-low.c (linux_supports_conditional_breakpoints): Rename
7849 (linux_supports_hardware_single_step): ... New function.
7850 (linux_target_ops): Update.
7851 * lynx-low.c (lynx_target_ops): Set field
7852 supports_hardware_single_step to target_can_do_hardware_single_step.
7853 * nto-low.c (nto_target_ops): Likewise.
7854 * spu-low.c (spu_target_ops): Likewise.
7855 * win32-low.c (win32_target_ops): Likewise.
7856 * target.c (target_can_do_hardware_single_step): New function.
7857 * target.h (struct target_ops) <supports_conditional_breakpoints>:
7858 Remove. <supports_hardware_single_step>: New field.
7859 (target_supports_conditional_breakpoints): Remove.
7860 (target_supports_hardware_single_step): New macro.
7861 (target_can_do_hardware_single_step): Declare.
7862 * server.c (handle_query): Use target_supports_hardware_single_step
7863 instead of target_supports_conditional_breakpoints.
7865 2015-09-15 Yao Qi <yao.qi@linaro.org>
7867 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
7869 (struct linux_target_ops the_low_target): Install
7870 aarch64_linux_siginfo_fixup.
7872 2015-09-11 Don Breazeal <donb@codesourcery.com>
7873 Luis Machado <lgustavo@codesourcery.com>
7875 * linux-low.c (linux_mourn): Static declaration.
7876 (linux_arch_setup): Move in front of
7877 handle_extended_wait.
7878 (linux_arch_setup_thread): New function.
7879 (handle_extended_wait): Handle exec events. Call
7880 linux_arch_setup_thread. Make event_lwp argument a
7881 pointer-to-a-pointer.
7882 (check_zombie_leaders): Do not check stopped threads.
7883 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
7884 (linux_low_filter_event): Add lwp and thread for exec'ing
7885 non-leader thread if leader thread has been deleted.
7886 Refactor code into linux_arch_setup_thread and call it.
7887 Pass child lwp pointer by reference to handle_extended_wait.
7888 (linux_wait_for_event_filtered): Update comment.
7889 (linux_wait_1): Prevent clobbering exec event status.
7890 (linux_supports_exec_events): New function.
7891 (linux_target_ops) <supports_exec_events>: Initialize new member.
7892 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
7894 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
7895 * server.c (report_exec_events): New global variable.
7896 (handle_query): Handle qSupported query for exec-events feature.
7897 (captured_main): Initialize report_exec_events.
7898 * server.h (report_exec_events): Declare new global variable.
7899 * target.h (struct target_ops) <supports_exec_events>: New
7901 (target_supports_exec_events): New macro.
7902 * win32-low.c (win32_target_ops) <supports_exec_events>:
7903 Initialize new member.
7905 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
7907 * linux-low.c (linux_low_enable_btrace): Remove.
7908 (linux_target_ops): Replace linux_low_enable_btrace with
7909 linux_enable_btrace.
7911 2015-09-03 Yao Qi <yao.qi@linaro.org>
7913 * linux-aarch64-low.c (aarch64_insert_point): Call
7914 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
7917 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
7919 * linux-low.c (check_stopped_by_breakpoint): Use
7920 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
7922 2015-08-27 Pedro Alves <palves@redhat.com>
7924 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
7926 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
7928 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
7929 the XNEW-family equivalent.
7930 (compile_bytecodes): Likewise.
7931 * dll.c (loaded_dll): Likewise.
7932 * event-loop.c (append_callback_event): Likewise.
7933 (create_file_handler): Likewise.
7934 (create_file_event): Likewise.
7935 * hostio.c (handle_open): Likewise.
7936 * inferiors.c (add_thread): Likewise.
7937 (add_process): Likewise.
7938 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
7939 * linux-arm-low.c (arm_new_process): Likewise.
7940 (arm_new_thread): Likewise.
7941 * linux-low.c (add_to_pid_list): Likewise.
7942 (linux_add_process): Likewise.
7943 (handle_extended_wait): Likewise.
7944 (add_lwp): Likewise.
7945 (enqueue_one_deferred_signal): Likewise.
7946 (enqueue_pending_signal): Likewise.
7947 (linux_resume_one_lwp_throw): Likewise.
7948 (linux_resume_one_thread): Likewise.
7949 (linux_read_memory): Likewise.
7950 (linux_write_memory): Likewise.
7951 * linux-mips-low.c (mips_linux_new_process): Likewise.
7952 (mips_linux_new_thread): Likewise.
7953 (mips_add_watchpoint): Likewise.
7954 * linux-x86-low.c (initialize_low_arch): Likewise.
7955 * lynx-low.c (lynx_add_process): Likewise.
7956 * mem-break.c (set_raw_breakpoint_at): Likewise.
7957 (set_breakpoint): Likewise.
7958 (add_condition_to_breakpoint): Likewise.
7959 (add_commands_to_breakpoint): Likewise.
7960 (clone_agent_expr): Likewise.
7961 (clone_one_breakpoint): Likewise.
7962 * regcache.c (new_register_cache): Likewise.
7963 * remote-utils.c (look_up_one_symbol): Likewise.
7964 * server.c (queue_stop_reply): Likewise.
7965 (start_inferior): Likewise.
7966 (queue_stop_reply_callback): Likewise.
7967 (handle_target_event): Likewise.
7968 * spu-low.c (fetch_ppc_memory): Likewise.
7969 (store_ppc_memory): Likewise.
7970 * target.c (set_target_ops): Likewise.
7971 * thread-db.c (thread_db_load_search): Likewise.
7972 (try_thread_db_load_1): Likewise.
7973 * tracepoint.c (add_tracepoint): Likewise.
7974 (add_tracepoint_action): Likewise.
7975 (create_trace_state_variable): Likewise.
7976 (cmd_qtdpsrc): Likewise.
7977 (cmd_qtro): Likewise.
7978 (add_while_stepping_state): Likewise.
7979 * win32-low.c (child_add_thread): Likewise.
7980 (get_image_name): Likewise.
7982 2015-08-25 Yao Qi <yao.qi@linaro.org>
7984 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
7986 2015-08-25 Yao Qi <yao.qi@linaro.org>
7988 * Makefile.in (aarch64-linux.o): New rule.
7989 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
7991 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
7992 (aarch64_init_debug_reg_state): Make it extern.
7993 (aarch64_linux_prepare_to_resume): Remove.
7995 2015-08-25 Yao Qi <yao.qi@linaro.org>
7997 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
7998 lwp_arch_private_info and ptid_of_lwp.
8000 2015-08-25 Yao Qi <yao.qi@linaro.org>
8002 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
8003 Find proc_info by find_process_pid. All callers updated.
8005 2015-08-25 Yao Qi <yao.qi@linaro.org>
8007 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
8009 (debug_reg_change_callback): Remove.
8010 (aarch64_notify_debug_reg_change): Remove.
8012 2015-08-25 Yao Qi <yao.qi@linaro.org>
8014 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
8015 Call current_lwp_ptid.
8017 2015-08-25 Yao Qi <yao.qi@linaro.org>
8019 * linux-aarch64-low.c (debug_reg_change_callback): Use
8022 2015-08-25 Yao Qi <yao.qi@linaro.org>
8024 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
8026 2015-08-25 Yao Qi <yao.qi@linaro.org>
8028 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
8030 2015-08-25 Yao Qi <yao.qi@linaro.org>
8032 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
8035 2015-08-25 Yao Qi <yao.qi@linaro.org>
8037 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
8039 (debug_reg_change_callback): Remove argument entry and add argument
8040 lwp. Remove local variable thread. Don't print thread id in the
8041 debugging output. Don't check whether pid of thread equals to pid.
8042 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
8043 iterate_over_lwps instead find_inferior.
8045 2015-08-24 Pedro Alves <palves@redhat.com>
8047 * inferiors.c (get_first_process): New function.
8048 * inferiors.h (get_first_process): New declaration.
8049 * remote-utils.c (read_ptid): Default to the first process in the
8050 list, instead of to the current thread's process.
8052 2015-08-24 Pedro Alves <palves@redhat.com>
8054 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
8055 * event-loop.c: Likewise.
8056 * remote-utils.c: Likewise.
8057 * tracepoint.c: Likewise.
8059 2015-08-24 Pedro Alves <palves@redhat.com>
8061 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
8064 2015-08-21 Pedro Alves <palves@redhat.com>
8066 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
8067 instead of literal 1.
8069 2015-08-21 Pedro Alves <palves@redhat.com>
8071 * tdesc.c (default_description): Explicitly zero-initialize.
8073 2015-08-21 Pedro Alves <palves@redhat.com>
8076 * inferiors.c (remove_thread): Discard any pending stop reply for
8078 * server.c (remove_all_on_match_pid): Rename to ...
8079 (remove_all_on_match_ptid): ... this. Work with a filter ptid
8081 (discard_queued_stop_replies): Change parameter to a ptid. Now
8083 (handle_v_kill, kill_inferior_callback, captured_main)
8084 (process_serial_event): Adjust.
8085 * server.h (discard_queued_stop_replies): Declare.
8087 2015-08-21 Pedro Alves <palves@redhat.com>
8089 * linux-low.c (wait_for_sigstop): Always switch to no thread
8090 selected if the previously current thread dies.
8091 * lynx-low.c (lynx_request_interrupt): Use the first thread's
8092 process instead of the current thread's.
8093 * remote-utils.c (input_interrupt): Don't check if there's no
8095 * server.c (gdb_read_memory, gdb_write_memory): If setting the
8096 current thread to the general thread fails, error out.
8097 (handle_qxfer_auxv, handle_qxfer_libraries)
8098 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
8099 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
8100 (handle_query): Check if there's a thread selected instead of
8101 checking whether there's any thread in the thread list.
8102 (handle_qxfer_threads, handle_qxfer_btrace)
8103 (handle_qxfer_btrace_conf): Don't error out early if there's no
8104 thread in the thread list.
8105 (handle_v_cont, myresume): Don't set the current thread to the
8107 (process_serial_event) <Hg handling>: Also set thread_id if the
8108 previous general thread is still alive.
8109 (process_serial_event) <g/G handling>: If setting the current
8110 thread to the general thread fails, error out.
8111 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
8112 thread's lwp instead of the current thread's.
8113 * target.c (set_desired_thread): If the desired thread was not
8114 found, leave the current thread pointing to NULL. Return an int
8115 (boolean) indicating success.
8116 * target.h (set_desired_thread): Change return type to int.
8118 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
8120 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
8121 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
8123 (ps_get_thread_area): New function.
8125 2015-08-19 Gary Benson <gbenson@redhat.com>
8127 * hostio.c (handle_pread): Do not attempt to read more data
8128 than hostio_reply_with_data can fit in a packet.
8130 2015-08-18 Joel Brobecker <brobecker@adacore.com>
8132 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
8134 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
8136 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
8138 2015-08-06 Pedro Alves <palves@redhat.com>
8140 * tracepoint.c (expr_eval_result): Now an int.
8142 2015-08-06 Pedro Alves <palves@redhat.com>
8144 * gdbthread.h (struct regcache): Forward declare.
8145 (struct thread_info) <regcache_data>: Now a struct regcache
8147 * inferiors.c (inferior_regcache_data)
8148 (set_inferior_regcache_data): Now work with struct regcache
8150 * inferiors.h (struct regcache): Forward declare.
8151 (inferior_regcache_data, set_inferior_regcache_data): Now work
8152 with struct regcache pointers.
8153 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
8154 (free_register_cache_thread): Remove struct regcache pointer
8157 2015-08-06 Pedro Alves <palves@redhat.com>
8159 * server.c (captured_main): On error, print the exception message
8160 to stderr, and if run_once is set, throw a quit.
8162 2015-08-06 Pedro Alves <palves@redhat.com>
8164 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
8167 2015-08-06 Pedro Alves <palves@redhat.com>
8169 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
8170 reading beyond the passed in buffer length.
8172 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
8174 * tracepoint.c (symbol_list) <required>: Remove.
8176 2015-08-06 Pedro Alves <palves@redhat.com>
8178 * linux-low.c (handle_extended_wait): Set the fork child's suspend
8179 count if stopping and suspending threads.
8180 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
8181 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
8182 (linux_detach): Complete an ongoing step-over.
8183 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
8185 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
8186 (linux_wait_1): If passing a signal to the inferior after
8187 finishing a step-over, unsuspend and re-resume all lwps. If we
8188 see a single-step event but the thread should be continuing, don't
8189 pass the trap to gdb.
8190 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
8191 internal_error instead of gdb_assert.
8192 (enqueue_pending_signal): New function.
8193 (check_ptrace_stopped_lwp_gone): Add debug output.
8194 (start_step_over): Use internal_error instead of gdb_assert.
8195 (complete_ongoing_step_over): New function.
8196 (linux_resume_one_thread): Don't resume a suspended thread.
8197 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
8200 2015-08-06 Pedro Alves <palves@redhat.com>
8202 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
8203 (linux_thread_alive): Use lwp_is_marked_dead.
8204 (extended_event_reported): Delete.
8205 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
8206 instead of extended_event_reported.
8207 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
8209 (lwp_is_marked_dead): New function.
8210 (lwp_running): Use lwp_is_marked_dead.
8211 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
8214 2015-08-06 Pedro Alves <palves@redhat.com>
8216 * linux-low.c (linux_wait_1): Move fork event output out of the
8217 !report_to_gdb check. Pass event_child->waitstatus to
8218 target_waitstatus_to_string instead of ourstatus.
8220 2015-08-04 Yao Qi <yao.qi@linaro.org>
8222 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
8223 if current_thread is 32 bit.
8225 2015-08-04 Yao Qi <yao.qi@linaro.org>
8227 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
8228 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
8229 * server.c (extended_protocol): Remove "static".
8230 * server.h (extended_protocol): Declare it.
8232 2015-08-04 Yao Qi <yao.qi@linaro.org>
8234 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
8235 both aarch64 and aarch32.
8236 (aarch64_set_pc): Likewise.
8238 2015-08-04 Yao Qi <yao.qi@linaro.org>
8240 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
8241 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
8242 arm-with-neon.xml to srv_xmlfiles.
8243 * linux-aarch64-low.c: Include linux-aarch32-low.h.
8244 (is_64bit_tdesc): New function.
8245 (aarch64_linux_read_description): New function.
8246 (aarch64_arch_setup): Call aarch64_linux_read_description.
8247 (regs_info): Rename to regs_info_aarch64.
8248 (aarch64_regs_info): Return right regs_info.
8249 (initialize_low_arch): Call initialize_low_arch_aarch32.
8251 2015-08-04 Yao Qi <yao.qi@linaro.org>
8253 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
8254 * linux-aarch32-low.c: New file.
8255 * linux-aarch32-low.h: New file.
8256 * linux-arm-low.c (arm_fill_gregset): Move it to
8257 linux-aarch32-low.c.
8258 (arm_store_gregset): Likewise.
8259 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
8260 (arm_store_vfpregset): Call arm_store_vfpregset_num.
8261 (arm_arch_setup): Check if PTRACE_GETREGSET works.
8262 (regs_info): Rename to regs_info_arm.
8263 (arm_regs_info): Return regs_info_aarch32 if
8264 have_ptrace_getregset is 1 and target description is
8265 arm_with_neon or arm_with_vfpv3.
8266 (initialize_low_arch): Don't call init_registers_arm_with_neon.
8267 Call initialize_low_arch_aarch32 instead.
8269 2015-08-04 Yao Qi <yao.qi@linaro.org>
8271 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
8272 * linux-low.c: ... here.
8273 * linux-low.h (have_ptrace_getregset): Declare it.
8275 2015-08-04 Pedro Alves <palves@redhat.com>
8277 * thread-db.c (struct thread_db): Use new typedefs.
8278 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
8280 (disable_thread_event_reporting): Cast result of dlsym to
8281 destination function pointer type.
8282 (thread_db_mourn): Use td_ta_delete_ftype.
8284 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
8286 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
8288 (CDX_BREAKPOINT): Define for R2.
8289 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
8290 (the_low_target): Add comments.
8292 2015-07-30 Yao Qi <yao.qi@linaro.org>
8294 * linux-arm-low.c (arm_hwcap): Remove it.
8295 (arm_read_description): New local variable arm_hwcap. Don't
8296 set arm_hwcap to zero.
8298 2015-07-30 Yao Qi <yao.qi@linaro.org>
8300 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
8301 Use regcache->tdesc instead.
8302 (arm_store_wmmxregset): Likewise.
8303 (arm_fill_vfpregset): Likewise.
8304 (arm_store_vfpregset): Likewise.
8306 2015-07-30 Yao Qi <yao.qi@linaro.org>
8308 * linux-arm-low.c: Include arch/arm.h.
8309 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
8310 (arm_store_gregset): Likewise.
8312 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
8314 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
8315 ptrace's 4th parameter.
8317 2015-07-27 Yao Qi <yao.qi@linaro.org>
8319 * configure.srv (case aarch64*-*-linux*): Don't set
8322 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
8324 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
8326 * linux-arm-low.c: Likewise.
8327 * linux-cris-low.c: Likewise.
8328 * linux-crisv32-low.c: Likewise.
8329 * linux-low.c: Likewise.
8330 * linux-m68k-low.c: Likewise.
8331 * linux-mips-low.c: Likewise.
8332 * linux-nios2-low.c: Likewise.
8333 * linux-s390-low.c: Likewise.
8334 * linux-sparc-low.c: Likewise.
8335 * linux-tic6x-low.c: Likewise.
8336 * linux-tile-low.c: Likewise.
8337 * linux-x86-low.c: Likewise.
8339 2015-07-24 Pedro Alves <palves@redhat.com>
8341 * config.in: Regenerate.
8342 * configure: Regenerate.
8344 2015-07-24 Pedro Alves <palves@redhat.com>
8346 * acinclude.m4: Include ../ptrace.m4.
8347 * configure.ac: Call GDB_AC_PTRACE.
8348 * config.in, configure: Regenerate.
8350 2015-07-24 Yao Qi <yao.qi@linaro.org>
8352 * linux-low.c (linux_create_inferior): Remove setting to
8353 proc->priv->new_inferior.
8354 (linux_attach): Likewise.
8355 (linux_low_filter_event): Likewise.
8356 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
8358 2015-07-24 Yao Qi <yao.qi@linaro.org>
8360 * linux-low.c (linux_arch_setup): New function.
8361 (linux_low_filter_event): If proc->tdesc is NULL and
8362 proc->attached is true, call the_low_target.arch_setup.
8363 Otherwise, keep status pending, and return.
8364 (linux_resume_one_lwp_throw): Don't call get_pc if
8365 thread->while_stepping isn't NULL. Don't call
8366 get_thread_regcache if proc->tdesc is NULL.
8367 (need_step_over_p): Return 0 if proc->tdesc is NULL.
8368 (linux_target_ops): Install arch_setup.
8369 * server.c (start_inferior): Call the_target->arch_setup.
8370 * target.h (struct target_ops) <arch_setup>: New field.
8371 (target_arch_setup): New marco.
8372 * lynx-low.c (lynx_target_ops): Update.
8373 * nto-low.c (nto_target_ops): Update.
8374 * spu-low.c (spu_target_ops): Update.
8375 * win32-low.c (win32_target_ops): Update.
8377 2015-07-24 Yao Qi <yao.qi@linaro.org>
8379 * linux-low.c (linux_add_process): Don't set
8380 proc->priv->new_inferior.
8381 (linux_create_inferior): Set proc->priv->new_inferior to 1.
8382 (linux_attach): Likewise.
8384 2015-07-24 Yao Qi <yao.qi@linaro.org>
8386 * server.c (start_inferior): Code refactor.
8388 2015-07-24 Yao Qi <yao.qi@linaro.org>
8390 * server.c (process_serial_event): Set general_thread.
8392 2015-07-21 Yao Qi <yao.qi@linaro.org>
8394 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
8395 aarch64_linux_get_debug_reg_capacity.
8397 2015-07-17 Yao Qi <yao.qi@linaro.org>
8399 * Makefile.in (aarch64-linux-hw-point.o): New rule.
8400 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
8401 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
8402 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
8403 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
8404 (AARCH64_HWP_ALIGNMENT): Likewise.
8405 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
8406 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
8407 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
8408 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
8409 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
8410 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
8411 (struct aarch64_debug_reg_state): Likewise.
8412 (struct arch_lwp_info): Likewise.
8413 (aarch64_align_watchpoint): Likewise.
8414 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
8415 (aarch64_watchpoint_length): Likewise.
8416 (aarch64_point_encode_ctrl_reg): Likewise
8417 (aarch64_point_is_aligned): Likewise.
8418 (aarch64_align_watchpoint): Likewise.
8419 (aarch64_linux_set_debug_regs):
8420 (aarch64_dr_state_insert_one_point): Likewise.
8421 (aarch64_dr_state_remove_one_point): Likewise.
8422 (aarch64_handle_breakpoint): Likewise.
8423 (aarch64_handle_aligned_watchpoint): Likewise.
8424 (aarch64_handle_unaligned_watchpoint): Likewise.
8425 (aarch64_handle_watchpoint): Likewise.
8427 2015-07-17 Yao Qi <yao.qi@linaro.org>
8429 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
8430 and don't aarch64_get_debug_reg_state. All callers update.
8431 (aarch64_handle_aligned_watchpoint): Likewise.
8432 (aarch64_handle_unaligned_watchpoint): Likewise.
8433 (aarch64_handle_watchpoint): Likewise.
8434 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
8435 (aarch64_remove_point): Likewise.
8437 2015-07-17 Yao Qi <yao.qi@linaro.org>
8439 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
8441 (aarch64_handle_unaligned_watchpoint): Likewise.
8443 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
8445 Revert the previous 3 commits:
8446 Move gdb_regex* to common/
8447 Move linux_find_memory_regions_full & co.
8448 gdbserver build-id attribute generator
8450 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
8451 Jan Kratochvil <jan.kratochvil@redhat.com>
8453 gdbserver build-id attribute generator.
8454 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
8455 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
8456 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
8458 (get_dynamic): Use find_pdhr to traverse program headers.
8459 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
8460 (compare_mapping_entry_range, struct find_memory_region_callback_data)
8461 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
8462 (get_hex_build_id): New.
8463 (linux_qxfer_libraries_svr4): Add optional build-id attribute
8464 to reply XML document.
8466 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
8467 Jan Kratochvil <jan.kratochvil@redhat.com>
8469 * target.c: Include target/target-utils.h and fcntl.h.
8470 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
8471 (target_fileio_read_stralloc): New functions.
8473 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
8475 * Makefile.in (OBS): Add gdb_regex.o.
8477 * config.in: Rebuilt.
8478 * configure: Rebuilt.
8480 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
8481 Jan Kratochvil <jan.kratochvil@redhat.com>
8483 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
8484 * Makefile.in (OBS): Add target-utils.o.
8485 (linux-maps.o, target-utils.o): New.
8486 * configure.srv (srv_linux_obj): Add linux-maps.o.
8488 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
8490 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
8492 (the_low_target): Install it.
8494 2015-07-14 Pedro Alves <palves@redhat.com>
8496 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
8497 Instead, ignore ECHILD, and throw an error for other errnos.
8499 2015-07-10 Pedro Alves <palves@redhat.com>
8501 * event-loop.c (struct callback_event) <data>: Change type to
8502 gdb_client_data instance instead of gdb_client_data pointer.
8503 (append_callback_event): Adjust.
8505 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
8507 * linux-aarch64-low.c: Add comments for each linux_target_ops
8508 method. Remove comments already covered in target_ops and
8509 linux_target_ops definitions.
8510 (the_low_target): Add comments for each unimplemented method.
8512 2015-07-09 Yao Qi <yao.qi@linaro.org>
8514 * linux-aarch64-low.c (aarch64_regmap): Remove.
8515 (aarch64_usrregs_info): Remove.
8516 (regs_info): Set field usrregs to NULL.
8518 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
8520 * linux-low.c: Include "rsp-low.h"
8521 (linux_low_encode_pt_config, linux_low_encode_raw): New.
8522 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
8523 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
8524 (handle_btrace_enable_pt): New.
8525 (handle_btrace_general_set): Support "pt".
8526 (handle_btrace_conf_general_set): Support "pt:size".
8528 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
8530 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
8533 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
8535 * linux-aarch64-low.c: Remove comment about endianness.
8536 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
8537 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
8540 2015-06-24 Gary Benson <gbenson@redhat.com>
8542 * linux-i386-ipa.c (stdint.h): Do not include.
8543 * lynx-i386-low.c (stdint.h): Likewise.
8544 * lynx-ppc-low.c (stdint.h): Likewise.
8545 * mem-break.c (stdint.h): Likewise.
8546 * thread-db.c (stdint.h): Likewise.
8547 * tracepoint.c (stdint.h): Likewise.
8548 * win32-low.c (stdint.h): Likewise.
8550 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
8552 * server.c (write_qxfer_response): Update call to
8553 remote_escape_output.
8555 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
8556 Jan Kratochvil <jan.kratochvil@redhat.com>
8558 Merge multiple hex conversions.
8559 * gdbreplay.c (tohex): Rename to 'fromhex'.
8560 (logchar): Use fromhex.
8562 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
8564 * server.c (handle_qxfer_libraries): Set `version' attribute for
8567 2015-06-10 Gary Benson <gbenson@redhat.com>
8569 * target.h (struct target_ops) <multifs_open>: New field.
8570 <multifs_unlink>: Likewise.
8571 <multifs_readlink>: Likewise.
8572 * linux-low.c (nat/linux-namespaces.h): New include.
8573 (linux_target_ops): Initialize the_target->multifs_open,
8574 the_target->multifs_unlink and the_target->multifs_readlink.
8575 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
8576 * hostio.c (hostio_fs_pid): New static variable.
8577 (hostio_handle_new_gdb_connection): New function.
8578 (handle_setfs): Likewise.
8579 (handle_open): Use the_target->multifs_open as appropriate.
8580 (handle_unlink): Use the_target->multifs_unlink as appropriate.
8581 (handle_readlink): Use the_target->multifs_readlink as
8583 (handle_vFile): Handle vFile:setfs packets.
8584 * server.c (handle_query): Call hostio_handle_new_gdb_connection
8585 after target_handle_new_gdb_connection.
8587 2015-06-10 Gary Benson <gbenson@redhat.com>
8589 * configure.ac (AC_CHECK_FUNCS): Add setns.
8590 * config.in: Regenerate.
8591 * configure: Likewise.
8592 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
8593 (linux-namespaces.o): New rule.
8594 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
8596 2015-06-09 Gary Benson <gbenson@redhat.com>
8598 * hostio.c (handle_open): Process mode argument with
8599 fileio_to_host_mode.
8601 2015-06-01 Yao Qi <yao.qi@linaro.org>
8603 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
8604 * linux-x86-low.c: Likewise.
8606 2015-05-28 Don Breazeal <donb@codesourcery.com>
8608 * linux-low.c (handle_extended_wait): Initialize
8609 thread_info.last_resume_kind for new fork children.
8611 2015-05-15 Pedro Alves <palves@redhat.com>
8613 * target.h (target_handle_new_gdb_connection): Rewrite using if
8614 wrapped in do/while.
8616 2015-05-14 Joel Brobecker <brobecker@adacore.com>
8618 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
8619 * configure, config.in: Regenerate.
8620 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
8623 2015-05-12 Don Breazeal <donb@codesourcery.com>
8625 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
8626 PTRACE_EVENT_VFORK_DONE.
8627 (linux_low_ptrace_options, extended_event_reported): Add vfork
8629 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
8630 and "vforkdone" for RSP 'T' Stop Reply Packet.
8631 * server.h (report_vfork_events): Declare
8634 2015-05-12 Don Breazeal <donb@codesourcery.com>
8636 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
8637 (the_low_target) <new_fork>: Initialize new member.
8638 * linux-arm-low.c (arm_new_fork): New function.
8639 (the_low_target) <new_fork>: Initialize new member.
8640 * linux-low.c (handle_extended_wait): Call new target function
8642 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
8643 * linux-mips-low.c (mips_add_watchpoint): New function
8644 extracted from mips_insert_point.
8645 (the_low_target) <new_fork>: Initialize new member.
8646 (mips_linux_new_fork): New function.
8647 (mips_insert_point): Call mips_add_watchpoint.
8648 * linux-x86-low.c (x86_linux_new_fork): New function.
8649 (the_low_target) <new_fork>: Initialize new member.
8651 2015-05-12 Don Breazeal <donb@codesourcery.com>
8653 * linux-low.c (handle_extended_wait): Implement return value,
8654 rename argument 'event_child' to 'event_lwp', handle
8655 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
8656 (linux_low_ptrace_options): New function.
8657 (linux_low_filter_event): Call linux_low_ptrace_options,
8658 use different argument fo linux_enable_event_reporting,
8659 use return value from handle_extended_wait.
8660 (extended_event_reported): New function.
8661 (linux_wait_1): Call extended_event_reported and set
8662 status to report fork events.
8663 (linux_write_memory): Add pid to debug message.
8664 (reset_lwp_ptrace_options_callback): New function.
8665 (linux_handle_new_gdb_connection): New function.
8666 (linux_target_ops): Initialize new structure member.
8667 * linux-low.h (struct lwp_info) <waitstatus>: New member.
8668 * lynx-low.c: Initialize new structure member.
8669 * remote-utils.c (prepare_resume_reply): Implement stop reason
8670 "fork" for "T" stop message.
8671 * server.c (handle_query): Call handle_new_gdb_connection.
8672 * server.h (report_fork_events): Declare global flag.
8673 * target.h (struct target_ops) <handle_new_gdb_connection>:
8675 (target_handle_new_gdb_connection): New macro.
8676 * win32-low.c: Initialize new structure member.
8678 2015-05-12 Don Breazeal <donb@codesourcery.com>
8680 * mem-break.c (APPEND_TO_LIST): Define macro.
8681 (clone_agent_expr): New function.
8682 (clone_one_breakpoint): New function.
8683 (clone_all_breakpoints): New function.
8684 * mem-break.h: Declare new functions.
8686 2015-05-12 Don Breazeal <donb@codesourcery.com>
8688 * linux-low.c (linux_supports_fork_events): New function.
8689 (linux_supports_vfork_events): New function.
8690 (linux_target_ops): Initialize new structure members.
8691 (initialize_low): Call linux_check_ptrace_features.
8692 * lynx-low.c (lynx_target_ops): Initialize new structure
8694 * server.c (report_fork_events, report_vfork_events):
8696 (handle_query): Add new features to qSupported packet and
8698 (captured_main): Initialize new global variables.
8699 * target.h (struct target_ops) <supports_fork_events>:
8701 <supports_vfork_events>: New member.
8702 (target_supports_fork_events): New macro.
8703 (target_supports_vfork_events): New macro.
8704 * win32-low.c (win32_target_ops): Initialize new structure
8707 2015-05-12 Gary Benson <gbenson@redhat.com>
8709 * server.c (handle_qxfer_exec_file): Use current process
8712 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
8714 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
8715 Remove HAVE_PTRACE_GETREGS conditionals.
8716 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
8717 instead of PTRACE_GETREGS and PTRACE_SETREGS.
8719 2015-05-08 Yao Qi <yao.qi@linaro.org>
8721 * linux-low.c (linux_supports_conditional_breakpoints): New
8723 (linux_target_ops): Install new target method.
8724 * lynx-low.c (lynx_target_ops): Install NULL hook for
8725 supports_conditional_breakpoints.
8726 * nto-low.c (nto_target_ops): Likewise.
8727 * spu-low.c (spu_target_ops): Likewise.
8728 * win32-low.c (win32_target_ops): Likewise.
8729 * server.c (handle_query): Check
8730 target_supports_conditional_breakpoints.
8731 * target.h (struct target_ops) <supports_conditional_breakpoints>:
8733 (target_supports_conditional_breakpoints): New macro.
8735 2015-05-06 Pedro Alves <palves@redhat.com>
8738 * server.c (start_inferior): If the process exits, mourn it.
8740 2015-04-21 Gary Benson <gbenson@redhat.com>
8742 * hostio.c (fileio_open_flags_to_host): Factored out to
8743 fileio_to_host_openflags in common/fileio.c. Single use
8746 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
8748 * linux-xtensa-low.c (xtensa_fill_gregset)
8749 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
8752 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
8754 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
8755 (regs_info): Replace usrregs pointer with NULL.
8757 2015-04-17 Gary Benson <gbenson@redhat.com>
8759 * target.h (struct target_ops) <pid_to_exec_file>: New field.
8760 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
8761 * server.c (handle_qxfer_exec_file): New function.
8762 (qxfer_packets): Add exec-file entry.
8763 (handle_query): Report qXfer:exec-file:read as supported packet.
8765 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
8767 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
8769 2015-04-09 Gary Benson <gbenson@redhat.com>
8771 * hostio-errno.c (errno_to_fileio_error): Remove function.
8772 Update caller to use remote_fileio_to_fio_error.
8774 2015-04-09 Yao Qi <yao.qi@linaro.org>
8776 * linux-low.c (linux_insert_point): Call
8777 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
8778 (linux_remove_point): Call remove_memory_breakpoint if type is
8780 * linux-x86-low.c (x86_insert_point): Don't call
8781 insert_memory_breakpoint.
8782 (x86_remove_point): Don't call remove_memory_breakpoint.
8784 2015-04-01 Pedro Alves <palves@redhat.com>
8785 Cleber Rosa <crosa@redhat.com>
8787 * server.c (gdbserver_usage): Reorganize and extend the usage
8790 2015-03-24 Pedro Alves <palves@redhat.com>
8792 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
8793 output. Also dump TRAP_TRACE.
8794 (linux_low_filter_event): In debug output, distinguish a
8795 resume_stop SIGSTOP from a delayed SIGSTOP.
8797 2015-03-24 Gary Benson <gbenson@redhat.com>
8799 * linux-x86-low.c (x86_linux_new_thread): Moved to
8801 (x86_linux_prepare_to_resume): Likewise.
8803 2015-03-24 Gary Benson <gbenson@redhat.com>
8805 * Makefile.in (x86-linux-dregs.o): New rule.
8806 * configure.srv: Add x86-linux-dregs.o to relevant targets.
8807 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
8808 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
8809 (x86_linux_dr_get): Likewise.
8810 (x86_linux_dr_set): Likewise.
8811 (update_debug_registers_callback): Likewise.
8812 (x86_linux_dr_set_addr): Likewise.
8813 (x86_linux_dr_get_addr): Likewise.
8814 (x86_linux_dr_set_control): Likewise.
8815 (x86_linux_dr_get_control): Likewise.
8816 (x86_linux_dr_get_status): Likewise.
8817 (x86_linux_update_debug_registers): Likewise.
8819 2015-03-24 Gary Benson <gbenson@redhat.com>
8821 * linux-x86-low.c (x86_linux_update_debug_registers):
8822 New function, factored out from...
8823 (x86_linux_prepare_to_resume): ...this.
8825 2015-03-24 Gary Benson <gbenson@redhat.com>
8827 * linux-x86-low.c (x86_linux_dr_get): Update comments.
8828 (x86_linux_dr_set): Likewise.
8829 (update_debug_registers_callback): Likewise.
8830 (x86_linux_dr_set_addr): Likewise.
8831 (x86_linux_dr_get_addr): Likewise.
8832 (x86_linux_dr_set_control): Likewise.
8833 (x86_linux_dr_get_control): Likewise.
8834 (x86_linux_dr_get_status): Likewise.
8835 (x86_linux_prepare_to_resume): Likewise.
8837 2015-03-24 Gary Benson <gbenson@redhat.com>
8839 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
8840 Use perror_with_name. Pass string through gettext.
8841 (x86_linux_dr_set): Likewise.
8843 2015-03-24 Gary Benson <gbenson@redhat.com>
8845 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
8846 (x86_linux_dr_set_addr): ...this.
8847 (x86_dr_low_get_addr): Rename to...
8848 (x86_linux_dr_get_addr): ...this.
8849 (x86_dr_low_set_control): Rename to...
8850 (x86_linux_dr_set_control): ...this.
8851 (x86_dr_low_get_control): Rename to...
8852 (x86_linux_dr_get_control): ...this.
8853 (x86_dr_low_get_status): Rename to...
8854 (x86_linux_dr_get_status): ...this.
8855 (x86_dr_low): Update with new function names.
8857 2015-03-24 Gary Benson <gbenson@redhat.com>
8859 * Makefile.in (x86-linux.o): New rule.
8860 * configure.srv: Add x86-linux.o to relevant targets.
8861 * linux-low.c (lwp_set_arch_private_info): New function.
8862 (lwp_arch_private_info): Likewise.
8863 * linux-x86-low.c: Include nat/x86-linux.h.
8864 (arch_lwp_info): Removed structure.
8865 (update_debug_registers_callback):
8866 Use lwp_set_debug_registers_changed.
8867 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
8868 and lwp_set_debug_registers_changed.
8869 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
8871 2015-03-24 Gary Benson <gbenson@redhat.com>
8873 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
8874 * linux-arm-low.c (arm_new_thread): Likewise.
8875 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
8876 * linux-mips-low.c (mips_linux_new_thread): Likewise.
8877 * linux-x86-low.c (x86_linux_new_thread): Likewise.
8878 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
8880 2015-03-24 Gary Benson <gbenson@redhat.com>
8882 * linux-low.c (ptid_of_lwp): New function.
8883 (lwp_is_stopped): Likewise.
8884 (lwp_stop_reason): Likewise.
8885 * linux-x86-low.c (update_debug_registers_callback):
8887 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
8890 2015-03-24 Gary Benson <gbenson@redhat.com>
8892 * linux-low.h (linux_stop_lwp): Remove declaration.
8894 2015-03-24 Gary Benson <gbenson@redhat.com>
8896 * linux-low.h: Include nat/linux-nat.h.
8897 * linux-low.c (iterate_over_lwps_args): New structure.
8898 (iterate_over_lwps_filter): New function.
8899 (iterate_over_lwps): Likewise.
8900 * linux-x86-low.c (update_debug_registers_callback):
8901 Update signature to what iterate_over_lwps expects.
8902 Remove PID check that iterate_over_lwps now performs.
8903 (x86_dr_low_set_addr): Use iterate_over_lwps.
8904 (x86_dr_low_set_control): Likewise.
8906 2015-03-24 Gary Benson <gbenson@redhat.com>
8908 * linux-x86-low.c (x86_debug_reg_state): New function.
8909 (x86_linux_prepare_to_resume): Use the above.
8911 2015-03-24 Gary Benson <gbenson@redhat.com>
8913 * linux-low.c (current_lwp_ptid): New function.
8914 * linux-x86-low.c: Include nat/linux-nat.h.
8915 (x86_dr_low_get_addr): Use current_lwp_ptid.
8916 (x86_dr_low_get_control): Likewise.
8917 (x86_dr_low_get_status): Likewise.
8919 2015-03-20 Pedro Alves <palves@redhat.com>
8921 * tracepoint.c (cmd_qtstatus): Make "str" const.
8923 2015-03-20 Pedro Alves <palves@redhat.com>
8925 * server.c (handle_general_set): Make "req_str" const.
8927 2015-03-19 Pedro Alves <palves@redhat.com>
8929 * linux-low.c (linux_resume_one_lwp): Rename to ...
8930 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
8931 instead call perror_with_name.
8932 (check_ptrace_stopped_lwp_gone): New function.
8933 (linux_resume_one_lwp): Reimplement as wrapper around
8934 linux_resume_one_lwp_throw that swallows errors if the LWP is
8937 2015-03-19 Pedro Alves <palves@redhat.com>
8939 * linux-low.c (count_events_callback, select_event_lwp_callback):
8940 No longer check whether the thread has resume_stop as last resume
8943 2015-03-19 Pedro Alves <palves@redhat.com>
8945 * linux-low.c (count_events_callback, select_event_lwp_callback):
8946 Use the lwp's status_pending_p field, not the thread's.
8948 2015-03-19 Pedro Alves <palves@redhat.com>
8950 * linux-low.c (select_event_lwp_callback): Update comments to
8951 no longer mention SIGTRAP.
8953 2015-03-18 Gary Benson <gbenson@redhat.com>
8955 * server.c (handle_query): Do not report vFile:fstat as supported.
8957 2015-03-11 Gary Benson <gbenson@redhat.com>
8959 * hostio.c (sys/types.h): New include.
8960 (sys/stat.h): Likewise.
8961 (common-remote-fileio.h): Likewise.
8962 (handle_fstat): New function.
8963 (handle_vFile): Handle vFile:fstat packets.
8965 2015-03-11 Gary Benson <gbenson@redhat.com>
8967 * configure.ac (AC_CHECK_MEMBERS): Add checks for
8968 struct stat.st_blocks and struct stat.st_blksize.
8969 * configure: Regenerate.
8970 * config.in: Likewise.
8971 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
8972 (OBS): Add common-remote-fileio.o.
8973 (common-remote-fileio.o): New rule.
8975 2015-03-09 Pedro Alves <palves@redhat.com>
8977 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
8978 'struct sockaddr' pointer in 'accept' call.
8980 2015-03-09 Pedro Alves <palves@redhat.com>
8983 2015-03-07 Pedro Alves <palves@redhat.com>
8984 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
8985 or <winsock2.h> here. Instead include "gdb_socket.h".
8986 (remote_open): Use union gdb_sockaddr_u.
8987 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
8988 or <winsock2.h> here. Instead include "gdb_socket.h".
8989 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
8990 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
8992 (init_named_socket, gdb_agent_helper_thread): Use union
8995 2015-03-07 Pedro Alves <palves@redhat.com>
8997 * configure.ac (build_warnings): Move
8998 -Wdeclaration-after-statement to the C-specific set.
8999 * configure: Regenerate.
9001 2015-03-07 Pedro Alves <palves@redhat.com>
9003 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
9004 or <winsock2.h> here. Instead include "gdb_socket.h".
9005 (remote_open): Use union gdb_sockaddr_u.
9006 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
9007 or <winsock2.h> here. Instead include "gdb_socket.h".
9008 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
9009 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
9011 (init_named_socket, gdb_agent_helper_thread): Use union
9014 2015-03-07 Pedro Alves <palves@redhat.com>
9016 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
9019 2015-03-06 Yao Qi <yao.qi@linaro.org>
9021 * linux-aarch64-low.c (aarch64_insert_point): Use
9022 show_debug_regs as a boolean.
9023 (aarch64_remove_point): Likewise.
9025 2015-03-05 Pedro Alves <palves@redhat.com>
9027 * lynx-low.c (lynx_target_ops): Install NULL hooks for
9028 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
9029 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
9030 * nto-low.c (nto_target_ops): Likewise.
9031 * spu-low.c (spu_target_ops): Likewise.
9032 * win32-low.c (win32_target_ops): Likewise.
9034 2015-03-04 Pedro Alves <palves@redhat.com>
9036 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
9037 Decide whether a breakpoint triggered based on the SIGTRAP's
9039 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
9040 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
9041 (linux_low_filter_event): Check for breakpoints before checking
9043 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
9045 (linux_stopped_by_sw_breakpoint)
9046 (linux_supports_stopped_by_sw_breakpoint)
9047 (linux_stopped_by_hw_breakpoint)
9048 (linux_supports_stopped_by_hw_breakpoint): New functions.
9049 (linux_target_ops): Install new target methods.
9051 2015-03-04 Pedro Alves <palves@redhat.com>
9053 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
9054 * server.c (swbreak_feature, hwbreak_feature): New globals.
9055 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
9056 (captured_main): Clear swbreak_feature and hwbreak_feature.
9057 * server.h (swbreak_feature, hwbreak_feature): Declare.
9058 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
9059 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
9060 supports_stopped_by_hw_breakpoint>: New fields.
9061 (target_supports_stopped_by_sw_breakpoint)
9062 (target_stopped_by_sw_breakpoint)
9063 (target_supports_stopped_by_hw_breakpoint)
9064 (target_stopped_by_hw_breakpoint): Declare.
9066 2015-03-04 Pedro Alves <palves@redhat.com>
9068 enum lwp_stop_reason -> enum target_stop_reason
9069 * linux-low.c (check_stopped_by_breakpoint): Adjust.
9070 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
9071 (linux_wait_1, stuck_in_jump_pad_callback)
9072 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
9073 (linux_stopped_by_watchpoint):
9074 * linux-low.h (enum lwp_stop_reason): Delete.
9075 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
9076 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
9078 2015-03-04 Yao Qi <yao.qi@linaro.org>
9080 * Makefile.in (SFILES): Add linux-aarch64-low.c.
9082 2015-03-03 Gary Benson <gbenson@redhat.com>
9084 * hostio.c (handle_vFile): Fix prefix lengths.
9086 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
9088 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
9091 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
9093 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
9094 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
9095 (clean): Add "rm -f" for above C files.
9096 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
9097 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
9098 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
9099 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
9100 * linux-s390-low.c (HWCAP_S390_VX): New macro.
9101 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
9102 (init_registers_s390x_vx_linux64)
9103 (init_registers_s390x_tevx_linux64)
9104 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
9105 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
9107 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
9108 (s390_store_vxrs_high): New functions.
9109 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
9111 (s390_arch_setup): Add logic for selecting one of the new target
9112 descriptions. Activate the new vector regsets if applicable.
9113 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
9114 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
9115 and init_registers_s390x_tevx_linux64.
9117 2015-03-01 Pedro Alves <palves@redhat.com>
9119 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
9122 2015-02-27 Pedro Alves <palves@redhat.com>
9124 * linux-x86-low.c (u_debugreg_offset): New function.
9125 (x86_linux_dr_get, x86_linux_dr_set): Use it.
9127 2015-02-27 Pedro Alves <palves@redhat.com>
9129 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
9130 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
9131 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
9132 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
9133 (ps_lsetfpregs, ps_getpid)
9134 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
9135 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
9136 (ps_lsetxregs, ps_plog): Declare.
9138 2015-02-27 Pedro Alves <palves@redhat.com>
9140 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
9141 IP_AGENT_EXPORT_FUNC.
9142 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
9143 IP_AGENT_EXPORT_FUNC.
9144 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
9145 (IP_AGENT_EXPORT): Delete.
9146 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
9147 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
9148 (gdb_trampoline_buffer_error, collecting, gdb_collect)
9149 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
9150 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
9151 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
9152 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
9153 (traceframe_read_count, traceframe_write_count)
9154 (traceframes_created, trace_state_variables, get_raw_reg)
9155 (get_trace_state_variable_value, set_trace_state_variable_value)
9156 (ust_loaded, helper_thread_id, cmd_buf): Use
9157 IPA_SYM_EXPORTED_NAME.
9158 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
9159 (tracepoints) Use IP_AGENT_EXPORT_VAR.
9160 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
9161 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
9162 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
9163 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
9164 EXTERN_C_PUSH/EXTERN_C_POP.
9165 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
9166 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
9167 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
9168 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
9169 (traceframe_write_count, traceframe_read_count)
9170 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
9171 (about_to_request_buffer_space, get_trace_state_variable_value)
9172 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
9173 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
9174 EXTERN_C_PUSH/EXTERN_C_POP.
9175 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
9176 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
9177 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
9178 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
9179 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
9180 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
9181 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
9182 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
9184 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
9185 (IP_AGENT_EXPORT_VAR_DECL): Define.
9187 (gdb_agent_get_raw_reg): Declare.
9189 2015-02-27 Tom Tromey <tromey@redhat.com>
9190 Pedro Alves <palves@redhat.com>
9192 Rename symbols whose names are reserved C++ keywords throughout.
9194 2015-02-27 Pedro Alves <palves@redhat.com>
9196 * Makefile.in (COMPILER): New, get it from autoconf.
9197 (CXX): Get from autoconf instead.
9198 (COMPILE.pre): Use COMPILER.
9199 (CC-LD): Rename to ...
9200 (CC_LD): ... this. Use COMPILER.
9201 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
9202 (CXX_FOR_TARGET): Default to g++ instead of gcc.
9203 * acinclude.m4: Include build-with-cxx.m4.
9204 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
9205 Disable -Werror by default if building in C++ mode.
9206 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
9207 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
9208 the C++ compiler. Save/restore CXXFLAGS too.
9209 * configure: Regenerate.
9211 2015-02-27 Pedro Alves <palves@redhat.com>
9213 * acinclude.m4: Include libiberty.m4.
9214 * configure.ac: Call libiberty_INIT.
9215 * config.in, configure: Regenerate.
9217 2015-02-26 Pedro Alves <palves@redhat.com>
9219 * linux-low.c (linux_wait_1): When incrementing the PC past a
9220 program breakpoint always use the_low_target.breakpoint_len as
9221 increment, rather than the maximum between that and
9222 the_low_target.decr_pc_after_break.
9224 2015-02-23 Pedro Alves <palves@redhat.com>
9226 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
9227 thread was doing a step-over; always adjust the PC if
9228 we stepped over a permanent breakpoint.
9229 (linux_wait_1): If we stepped over breakpoint that was on top of a
9230 permanent breakpoint, manually advance the PC past it.
9232 2015-02-23 Pedro Alves <palves@redhat.com>
9234 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
9236 (x86_fill_gregset, x86_store_gregset): Use it when handling
9239 2015-02-20 Pedro Alves <palves@redhat.com>
9241 * thread-db.c: Include "nat/linux-procfs.h".
9242 (thread_db_init): Skip listing new threads if the kernel supports
9243 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
9245 2015-02-20 Pedro Alves <palves@redhat.com>
9247 * linux-low.c (status_pending_p_callback): Use ptid_match.
9249 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
9251 PR breakpoints/16812
9252 * linux-low.c (wstatus_maybe_breakpoint): Remove.
9253 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
9254 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
9256 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
9258 PR breakpoints/15956
9259 * tracepoint.c (cmd_qtinit): Add check for current_thread.
9261 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
9263 * linux-low.c (linux_low_btrace_conf): Print size.
9264 * server.c (handle_btrace_conf_general_set): New.
9265 (hanle_general_set): Call handle_btrace_conf_general_set.
9266 (handle_query): Report Qbtrace-conf:bts:size as supported.
9268 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
9270 * linux-low.c (linux_low_enable_btrace): Update parameters.
9271 (linux_low_btrace_conf): New.
9272 (linux_target_ops)<to_btrace_conf>: Initialize.
9273 * server.c (current_btrace_conf): New.
9274 (handle_btrace_enable): Rename to ...
9275 (handle_btrace_enable_bts): ... this. Pass ¤t_btrace_conf
9276 to target_enable_btrace. Update comment. Update users.
9277 (handle_qxfer_btrace_conf): New.
9278 (qxfer_packets): Add btrace-conf entry.
9279 (handle_query): Report qXfer:btrace-conf:read as supported packet.
9280 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
9281 (target_ops)<read_btrace_conf>: New.
9282 (target_enable_btrace): Update parameters.
9283 (target_read_btrace_conf): New.
9285 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
9287 * server.c (handle_btrace_general_set): Remove call to
9288 target_supports_btrace.
9289 (supported_btrace_packets): New.
9290 (handle_query): Call supported_btrace_packets.
9291 * target.h: include btrace-common.h.
9292 (btrace_target_info): Removed.
9293 (supports_btrace, target_supports_btrace): Update parameters.
9295 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
9297 * Makefile.in (SFILES): Add common/btrace-common.c.
9298 (OBS): Add common/btrace-common.o.
9299 (btrace-common.o): Add build rules.
9300 * linux-low: Include btrace-common.h.
9301 (linux_low_read_btrace): Use struct btrace_data. Call
9302 btrace_data_init and btrace_data_fini.
9304 2015-02-06 Pedro Alves <palves@redhat.com>
9306 * thread-db.c (find_new_threads_callback): Add debug output.
9308 2015-02-04 Pedro Alves <palves@redhat.com>
9310 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
9311 (resume_stopped_resumed_lwps): New function.
9312 (linux_wait_for_event_filtered): Use it.
9314 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
9316 * Makefile.in (SFILES): Add linux-personality.c.
9317 (linux-personality.o): New rule.
9318 * configure.srv (srv_linux_obj): Add linux-personality.o to the
9319 list of objects to be built.
9320 * linux-low.c: Include nat/linux-personality.h.
9321 (linux_create_inferior): Remove code to disable address space
9322 randomization (moved to ../nat/linux-personality.c). Create
9323 cleanup to disable address space randomization.
9325 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
9327 * Makefile.in (posix-strerror.o): New rule.
9328 (mingw-strerror.o): Likewise.
9329 * configure: Regenerated.
9330 * configure.ac: Source file ../common/common.host. Initialize new
9331 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
9333 2015-01-14 Yao Qi <yao@codesourcery.com>
9335 * Makefile.in (SFILES): Add nat/ppc-linux.c.
9336 (ppc-linux.o): New rule.
9337 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
9338 * configure.ac: AC_CHECK_FUNCS(getauxval).
9339 * config.in: Re-generated.
9340 * configure: Re-generated.
9341 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
9342 ppc64_64bit_inferior_p
9344 2015-01-14 Yao Qi <yao@codesourcery.com>
9346 * linux-ppc-low.c: Include "nat/ppc-linux.h".
9347 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
9348 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
9349 (PT_ORIG_R3, PT_TRAP): Likewise.
9350 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
9351 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
9352 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
9354 2015-01-10 Joel Brobecker <brobecker@adacore.com>
9356 * i387-fp.c (i387_cache_to_xsave): In look over
9357 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
9358 zmmh_low_space field by use of zmmh_high_space.
9360 2015-01-09 Pedro Alves <palves@redhat.com>
9362 * linux-low.c (step_over_bkpt): Move higher up in the file.
9363 (handle_extended_wait): Don't store the stop_pc here.
9364 (get_stop_pc): Adjust comments and rename to ...
9365 (check_stopped_by_breakpoint): ... this. Record whether the LWP
9366 stopped for a software breakpoint or hardware breakpoint.
9367 (thread_still_has_status_pending_p): New function.
9368 (status_pending_p_callback): Use
9369 thread_still_has_status_pending_p. If the event is no longer
9370 interesting, resume the LWP.
9371 (handle_tracepoints): Add assert.
9372 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
9373 (wstatus_maybe_breakpoint): New function.
9374 (cancel_breakpoint): Delete function.
9375 (check_stopped_by_watchpoint): New function, factored out from
9376 linux_low_filter_event.
9377 (lp_status_maybe_breakpoint): Delete function.
9378 (linux_low_filter_event): Remove filter_ptid argument.
9379 Leave thread group exits pending here. Store the LWP's stop PC.
9380 Always leave events pending.
9381 (linux_wait_for_event_filtered): Pull all events out of the
9382 kernel, and leave them all pending.
9383 (count_events_callback, select_event_lwp_callback): Consider all
9385 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
9386 (select_event_lwp): Only give preference to the stepping LWP in
9387 all-stop mode. Adjust comments.
9388 (ignore_event): New function.
9389 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
9390 references to cancel_breakpoints. Adjust to renames. Also give
9391 equal priority to all LWPs that have had events in non-stop mode.
9392 If reporting a software breakpoint event, unadjust the LWP's PC.
9393 (linux_wait): If linux_wait_1 returned an ignored event, retry.
9394 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
9396 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
9397 (resume_status_pending_p): Use thread_still_has_status_pending_p.
9398 (linux_stopped_by_watchpoint): Adjust.
9399 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
9400 * linux-low.h (enum lwp_stop_reason): New.
9401 (struct lwp_info) <stop_pc>: Adjust comment.
9402 <stopped_by_watchpoint>: Delete field.
9403 <stop_reason>: New field.
9404 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
9405 * mem-break.c (software_breakpoint_inserted_here)
9406 (hardware_breakpoint_inserted_here): New function.
9407 * mem-break.h (software_breakpoint_inserted_here)
9408 (hardware_breakpoint_inserted_here): Declare.
9409 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
9410 (cancel_breakpoints): Delete.
9411 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
9412 (upload_fast_traceframes): Remove references to
9415 2015-01-09 Pedro Alves <palves@redhat.com>
9417 * thread-db.c (find_new_threads_callback): Ignore thread if the
9418 kernel thread ID is -1.
9420 2015-01-09 Pedro Alves <palves@redhat.com>
9422 * linux-low.c (linux_attach_fail_reason_string): Move to
9423 nat/linux-ptrace.c, and rename.
9424 (linux_attach_lwp): Update comment.
9425 (attach_proc_task_lwp_callback): New function.
9426 (linux_attach): Adjust to rename and use
9427 linux_proc_attach_tgid_threads.
9428 (linux_attach_fail_reason_string): Delete declaration.
9430 2015-01-01 Joel Brobecker <brobecker@adacore.com>
9432 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
9433 * server.c (gdbserver_version): Likewise.
9435 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
9437 * remote-utils.c: Include ctype.h.
9438 (input_interrupt): Explicitly handle the case when the char
9439 received is the NUL byte. Improve the printing of non-ASCII
9442 2014-12-16 Joel Brobecker <brobecker@adacore.com>
9444 * linux-low.c (linux_low_filter_event): Update call to
9445 linux_enable_event_reporting following the addition of
9446 a new parameter to that function.
9448 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
9451 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
9452 (AARCH64_FPCR_REGNO): Likewise.
9453 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
9454 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
9455 (aarch64_store_fpregset): Likewise.
9457 2014-12-15 Joel Brobecker <brobecker@adacore.com>
9459 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
9460 Remove FIXME comment about assumption about N.
9462 2014-12-13 Joel Brobecker <brobecker@adacore.com>
9464 * configure.ac: If large-file support is disabled in GDBserver,
9465 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
9466 * configure: Regenerate.
9468 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
9470 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
9471 warning upon ENODATA from ptrace.
9472 * linux-s390-low.c (s390_store_tdb): New.
9473 (s390_regsets): Add regset for NT_S390_TDB.
9475 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
9477 * linux-low.c (regsets_store_inferior_registers): Skip regsets
9478 without a fill_function.
9479 * linux-s390-low.c (s390_fill_last_break): Remove.
9480 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
9481 (s390_arch_setup): Use regset's size instead of fill_function for
9484 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
9486 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
9487 the regset's store function when ptrace returned an error.
9488 * regcache.c (get_thread_regcache): Invalidate register cache
9489 before fetching inferior's registers.
9491 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
9493 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
9494 while-loop as for-loop.
9495 (regsets_store_inferior_registers): Likewise.
9497 2014-11-28 Yao Qi <yao@codesourcery.com>
9499 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
9500 * config.in, configure: Re-generate.
9501 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
9504 2014-11-21 Yao Qi <yao@codesourcery.com>
9506 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
9507 (AC_CHECK_HEADERS): Remove malloc.h.
9508 * configure: Re-generated.
9509 * config.in: Re-generated.
9510 * server.h: Don't include alloca.h and malloc.h.
9511 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
9512 Don't include malloc.h.
9514 2014-11-17 Joel Brobecker <brobecker@adacore.com>
9516 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
9517 corresponding ERRNO check in same block.
9519 2014-11-12 Pedro Alves <palves@redhat.com>
9521 * server.c (cont_thread): Update comment.
9522 (start_inferior, attach_inferior): No longer clear cont_thread.
9523 (handle_v_cont): No longer set cont_thread.
9524 (captured_main): Clear cont_thread each time a GDB connects.
9526 2014-11-12 Pedro Alves <palves@redhat.com>
9528 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
9529 thread, and don't resume all threads if the Hc thread has exited.
9531 2014-11-12 Pedro Alves <palves@redhat.com>
9533 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
9534 the process group instead of to a specific LWP.
9536 2014-10-15 Pedro Alves <palves@redhat.com>
9539 * win32-arm-low.c (arm_set_thread_context): Remove current_event
9541 (arm_set_thread_context): Delete.
9542 (the_low_target): Adjust.
9543 * win32-i386-low.c (debug_registers_changed)
9544 (debug_registers_used): Delete.
9545 (update_debug_registers_callback): New function.
9546 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
9547 needing to update their debug registers.
9548 (win32_get_current_dr): New function.
9549 (x86_dr_low_get_addr, x86_dr_low_get_control)
9550 (x86_dr_low_get_status): Fetch the debug register from the thread
9552 (i386_initial_stuff): Adjust.
9553 (i386_get_thread_context): Remove current_event parameter. Don't
9554 clear debug_registers_changed nor copy DR values to
9556 (i386_set_thread_context): Delete.
9557 (i386_prepare_to_resume): New function.
9558 (i386_thread_added): Mark the thread as needing to update irs
9560 (the_low_target): Remove i386_set_thread_context and install
9561 i386_prepare_to_resume.
9562 * win32-low.c (win32_get_thread_context): Adjust.
9563 (win32_set_thread_context): Use SetThreadContext
9565 (win32_prepare_to_resume): New function.
9566 (win32_require_context): New function, factored out from ...
9567 (thread_rec): ... this.
9568 (continue_one_thread): Call win32_prepare_to_resume on each thread
9569 we're about to continue.
9570 (win32_resume): Call win32_prepare_to_resume on the event thread.
9571 * win32-low.h (struct win32_thread_info)
9572 <debug_registers_changed>: New field.
9573 (struct win32_target_ops): Change prototype of set_thread_context,
9574 delete set_thread_context and add prepare_to_resume.
9575 (win32_require_context): New declaration.
9577 2014-10-08 Gary Benson <gbenson@redhat.com>
9579 * server.h: Do not include common-exceptions.h.
9581 2014-10-08 Gary Benson <gbenson@redhat.com>
9583 * server.h: Do not include cleanups.h.
9585 2014-09-30 James Hogan <james.hogan@imgtec.com>
9587 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
9590 2014-09-23 Yao Qi <yao@codesourcery.com>
9592 * linux-low.c (lp_status_maybe_breakpoint): New function.
9593 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
9594 (count_events_callback): Likewise.
9595 (select_event_lwp_callback): Likewise.
9596 (cancel_breakpoints_callback): Likewise.
9598 2014-09-19 Don Breazeal <donb@codesourcery.com>
9600 * linux-low.c (handle_extended_wait): Call
9601 linux_ptrace_get_extended_event.
9602 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
9603 linux_is_extended_waitstatus.
9605 2014-09-16 Joel Brobecker <brobecker@adacore.com>
9607 * Makefile.in (CPPFLAGS): Define.
9608 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
9609 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
9611 2014-09-16 Gary Benson <gbenson@redhat.com>
9613 * inferiors.h (current_inferior): Renamed as...
9614 (current_thread): New variable. All uses updated.
9615 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
9616 (maybe_move_out_of_jump_pad): Likewise.
9617 (cancel_breakpoint): Likewise.
9618 (linux_low_filter_event): Likewise.
9619 (wait_for_sigstop): Likewise.
9620 (linux_resume_one_lwp): Likewise.
9621 (need_step_over_p): Likewise.
9622 (start_step_over): Likewise.
9623 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
9624 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
9625 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
9626 and save_inferior as saved_thread.
9627 * regcache.c (get_thread_regcache): Renamed saved_inferior as
9629 (regcache_invalidate_thread): Likewise.
9630 * remote-utils.c (prepare_resume_reply): Likewise.
9631 * thread-db.c (thread_db_get_tls_address): Likewise.
9632 (disable_thread_event_reporting): Likewise.
9633 (remove_thread_event_breakpoints): Likewise.
9634 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
9636 * target.h (set_desired_inferior): Renamed as...
9637 (set_desired_thread): New declaration. All uses updated.
9638 * server.c (myresume): Updated comment to reference thread instead
9640 (handle_serial_event): Likewise.
9641 (handle_target_event): Likewise.
9643 2014-09-12 Tom Tromey <tromey@redhat.com>
9644 Gary Benson <gbenson@redhat.com>
9646 * regcache.h: Include common-regcache.h.
9647 (regcache_read_pc): Don't declare.
9648 * regcache.c (get_thread_regcache_for_ptid): New function.
9650 2014-09-11 Tom Tromey <tromey@redhat.com>
9651 Gary Benson <gbenson@redhat.com>
9653 * symbol.c: New file.
9654 * Makefile.in (SFILES): Add symbol.c.
9655 (OBS): Add symbol.o.
9657 2014-09-11 Gary Benson <gbenson@redhat.com>
9659 * target.c (target_stop_ptid, target_continue_ptid): New
9662 2014-09-11 Tom Tromey <tromey@redhat.com>
9663 Gary Benson <gbenson@redhat.com>
9665 * target.h: Include target/target.h.
9666 * target.c (target_read_memory, target_read_uint32)
9667 (target_write_memory): New functions.
9669 2014-09-11 Gary Benson <gbenson@redhat.com>
9671 * server.h (debug_hw_points): Don't declare.
9672 * server.c (debug_hw_points): Don't define. Replace all uses
9673 with show_debug_regs.
9674 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
9675 all uses with show_debug_regs.
9677 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
9679 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
9680 endianness into account.
9681 (ppc_supply_ptrace_register): Likewise.
9683 2014-09-03 James Hogan <james.hogan@imgtec.com>
9685 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
9686 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
9688 2014-09-03 Gary Benson <gbenson@redhat.com>
9690 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
9691 ALL_DEBUG_ADDRESS_REGISTERS.
9693 2014-09-02 Gary Benson <gbenson@redhat.com>
9695 * i386-low.h: Renamed as...
9696 * x86-low.h: New file. All type, function and variable name
9697 prefixes changed from "i386_" to "x86_". All references updated.
9698 * i386-low.c: Renamed as...
9699 * x86-low.c: New file. All type, function and variable name
9700 prefixes changed from "i386_" to "x86_". All references updated.
9702 2014-09-02 Gary Benson <gbenson@redhat.com>
9704 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
9705 (x86_linux_new_thread): Likewise.
9707 2014-08-29 Gary Benson <gbenson@redhat.com>
9709 * server.h (setjmp.h): Do not include.
9710 (toplevel): Do not declare.
9711 (common-exceptions.h): Include.
9712 (cleanups.h): Likewise.
9713 * server.c (toplevel): Do not define.
9714 (exit_code): New static global.
9715 (detach_or_kill_for_exit_cleanup): New function.
9716 (main): New function. Original main renamed to...
9717 (captured_main): New function.
9718 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
9720 2014-08-29 Gary Benson <gbenson@redhat.com>
9722 * Makefile.in (SFILES): Add common/common-exceptions.c.
9723 (OBS): Add common-exceptions.o.
9724 (common-exceptions.o): New rule.
9725 * utils.c (prepare_to_throw_exception): New function.
9727 2014-08-29 Gary Benson <gbenson@redhat.com>
9729 * config.in: Regenerate.
9730 * configure: Likewise.
9732 2014-08-29 Gary Benson <gbenson@redhat.com>
9734 * Makefile.in (SFILES): Add common/cleanups.c.
9736 (cleanups.o): New rule.
9738 2014-08-29 Gary Benson <gbenson@redhat.com>
9740 * utils.c (internal_vwarning): New function.
9742 2014-08-28 Gary Benson <gbenson@redhat.com>
9744 * utils.h (fatal): Remove declaration.
9745 * utils.c (fatal): Remove function.
9747 2014-08-28 Gary Benson <gbenson@redhat.com>
9749 * tracepoint.c (gdb_agent_init): Replace fatal with
9751 (initialize_tracepoint): Likewise.
9753 2014-08-28 Gary Benson <gbenson@redhat.com>
9755 * remote-utils.c (remote_prepare): Replace fatal with error.
9757 2014-08-28 Gary Benson <gbenson@redhat.com>
9759 * linux-low.c (linux_async): Replace fatal with warning.
9761 (linux_start_non_stop): Return -1 if linux_async failed.
9763 2014-08-28 Gary Benson <gbenson@redhat.com>
9765 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
9767 (i386_dr_low_get_addr): Remove vague comment.
9768 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
9771 2014-08-28 Gary Benson <gbenson@redhat.com>
9773 * inferiors.c (get_thread_process): Replace check with gdb_assert.
9774 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
9776 (linux_resume_one_lwp): Likewise.
9777 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
9779 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
9780 with internal_error.
9781 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
9782 (init_register_cache): Replace fatal with gdb_assert_not_reached.
9783 (find_register_by_name): Replace fatal with internal_error.
9784 (find_regno): Likewise.
9785 * tdesc.c (init_target_desc): Replace check with gdb_assert.
9786 * thread-db.c (thread_db_create_event): Likewise.
9787 (thread_db_load_search): Likewise.
9788 (try_thread_db_load_1): Likewise.
9789 * tracepoint.c (get_jump_space_head): Replace fatal with
9791 (claim_trampoline_space): Likewise.
9792 (have_fast_tracepoint_trampoline_buffer): Likewise.
9793 (cmd_qtstart): Likewise.
9794 (stop_tracing): Likewise.
9795 (fast_tracepoint_collecting): Likewise.
9796 (target_malloc): Likewise.
9797 (download_tracepoint): Likewise.
9798 (download_trace_state_variables): Replace check with gdb_assert.
9799 (upload_fast_traceframes): Replace fatal with internal_error.
9801 2014-08-19 Tom Tromey <tromey@redhat.com>
9802 Gary Benson <gbenson@redhat.com>
9804 * Makefile.in (SFILES): Add common/common-debug.c.
9805 (OBS): Add common-debug.o.
9806 (common-debug.o): New rule.
9807 * debug.h (debug_printf): Don't declare.
9808 * debug.c (debug_printf): Renamed and rewritten as...
9809 (debug_vprintf): New function.
9811 2014-08-19 Gary Benson <gbenson@redhat.com>
9813 * utils.h: Do not include print-utils.h.
9815 2014-08-19 Tom Tromey <tromey@redhat.com>
9816 Gary Benson <gbenson@redhat.com>
9818 * server.h: Add static assertion.
9819 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
9821 2014-08-19 Tom Tromey <tromey@redhat.com>
9822 Gary Benson <gbenson@redhat.com>
9824 * Makefile.in (SFILES): Add common/errors.c.
9825 (OBS): Add errors.o.
9826 (IPA_OBS): Add errors-ipa.o.
9827 (errors.o): New rule.
9828 (errors-ipa.o): Likewise.
9829 * utils.h (perror_with_name, error, warning): Don't declare.
9830 * utils.c (warning): Renamed and rewritten as...
9831 (vwarning): New function.
9832 (error): Renamed and rewritten as...
9833 (verror): New function.
9834 (internal_error): Renamed and rewritten as...
9835 (internal_verror): New function.
9837 2014-08-07 Gary Benson <gbenson@redhat.com>
9839 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
9840 * configure: Regenerate.
9841 * config.in: Likewise.
9842 * server.h: Do not include errno.h.
9843 * event-loop.c: Likewise.
9844 * hostio-errno.c: Likewise.
9845 * linux-low.c: Likewise.
9846 * remote-utils.c: Likewise.
9847 * spu-low.c: Likewise.
9848 * utils.c: Likewise.
9849 * gdbreplay.c: Unconditionally include errno.h.
9851 2014-08-07 Gary Benson <gbenson@redhat.com>
9853 * server.h: Do not include string.h.
9854 * event-loop.c: Likewise.
9855 * linux-low.c: Likewise.
9856 * regcache.c: Likewise.
9857 * remote-utils.c: Likewise.
9858 * spu-low.c: Likewise.
9859 * utils.c: Likewise.
9861 2014-08-07 Gary Benson <gbenson@redhat.com>
9863 * server.h: Do not include gdb_assert.h.
9865 2014-08-07 Gary Benson <gbenson@redhat.com>
9867 * server.h: Do not include common-utils.h.
9869 2014-08-07 Gary Benson <gbenson@redhat.com>
9871 * server.h: Do not include ptid.h.
9872 * notif.h: Likewise.
9874 2014-08-07 Gary Benson <gbenson@redhat.com>
9876 * server.h: Do not include gdb_locale.h.
9878 2014-08-07 Gary Benson <gbenson@redhat.com>
9880 * server.h: Do not include gdb/signals.h.
9881 * win32-low.c: Likewise.
9883 2014-08-07 Gary Benson <gbenson@redhat.com>
9885 * server.h: Do not include pathmax.h.
9887 2014-08-07 Gary Benson <gbenson@redhat.com>
9889 * server.h: Do not include libiberty.h.
9890 * linux-bfin-low.c: Likewise.
9892 2014-08-07 Gary Benson <gbenson@redhat.com>
9894 * server.h: Do not include ansidecl.h.
9896 2014-08-07 Gary Benson <gbenson@redhat.com>
9898 * linux-x86-low.c: Do not include stddef.h.
9899 * lynx-ppc-low.c: Likewise.
9900 * tracepoint.c: Likewise.
9902 2014-08-07 Gary Benson <gbenson@redhat.com>
9904 * server.h: Do not include stdarg.h.
9905 * nto-low.c: Likewise.
9907 2014-08-07 Gary Benson <gbenson@redhat.com>
9909 * server.h: Do not include stdlib.h.
9910 * inferiors.c: Likewise.
9911 * linux-low.c: Likewise.
9912 * regcache.c: Likewise.
9913 * spu-low.c: Likewise.
9914 * tracepoint.c: Likewise.
9915 * utils.c: Likewise.
9917 2014-08-07 Gary Benson <gbenson@redhat.com>
9919 * server.h: Do not include stdio.h.
9920 * linux-low.c: Likewise.
9921 * remote-utils.c: Likewise.
9922 * spu-low.c: Likewise.
9923 * utils.c: Likewise.
9924 * wincecompat.c: Likewise.
9926 2014-08-06 Gary Benson <gbenson@redhat.com>
9928 * regcache.c (init_register_cache): Move conditionals inside if.
9930 2014-08-06 Gary Benson <gbenson@redhat.com>
9932 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
9934 2014-07-31 Gary Benson <gbenson@redhat.com>
9936 * ax.h: Do not include server.h.
9937 * gdbthread.h: Likewise.
9938 * lynx-low.h: Likewise.
9939 * notif.h: Likewise.
9941 2014-07-30 Gary Benson <gbenson@redhat.com>
9943 * server.h: Include common-defs.h.
9944 Do not include config.h or build-gnulib-gdbserver/config.h.
9946 2014-07-30 Gary Benson <gbenson@redhat.com>
9948 * hostio-errno.c: Move server.h to top of includes list.
9949 * inferiors.c: Likewise.
9950 * linux-x86-low.c: Likewise.
9951 * notif.c: Include server.h.
9953 2014-07-24 Tom Tromey <tromey@redhat.com>
9954 Gary Benson <gbenson@redhat.com>
9956 * server.h (CORE_ADDR): Now unsigned.
9958 2014-07-16 Pedro Alves <palves@redhat.com>
9960 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
9962 2014-07-15 Pedro Alves <palves@redhat.com>
9964 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
9967 2014-07-11 Pedro Alves <palves@redhat.com>
9969 * linux-low.c (kill_wait_lwp): New function, based on
9970 kill_one_lwp_callback, but use my_waitpid directly.
9971 (kill_one_lwp_callback, linux_kill): Use it.
9973 2014-06-23 Pedro Alves <palves@redhat.com>
9975 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
9976 before setting DR0..DR3.
9978 2014-06-20 Gary Benson <gbenson@redhat.com>
9980 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
9981 * configure: Regenerated.
9982 * config.in: Likewise.
9984 2014-06-20 Gary Benson <gbenson@redhat.com>
9986 * Makefile.in (SFILES): Update locations for files moved
9988 (object file files): Reordered.
9990 2014-06-20 Gary Benson <gbenson@redhat.com>
9992 * i386-low.h (i386_dr_low_can_set_addr): Removed.
9993 (i386_dr_low_set_addr): Likewise.
9994 (i386_dr_low_get_addr): Likewise.
9995 (i386_dr_low_can_set_control): Likewise.
9996 (i386_dr_low_set_control): Likewise.
9997 (i386_dr_low_get_control): Likewise.
9998 (i386_dr_low_get_status): Likewise.
9999 (i386_get_debug_register_length): Likewise.
10000 * linux-x86-low.c (i386_dr_low_set_addr):
10001 Changed signature. Made static.
10002 (i386_dr_low_get_addr): Likewise.
10003 (i386_dr_low_set_control): Likewise.
10004 (i386_dr_low_get_control): Likewise.
10005 (i386_dr_low_get_status): Likewise.
10006 (i386_dr_low): New global variable.
10007 * win32-i386-low.c (i386_dr_low_set_addr):
10008 Changed signature. Made static.
10009 (i386_dr_low_get_addr): Likewise.
10010 (i386_dr_low_set_control): Likewise.
10011 (i386_dr_low_get_control): Likewise.
10012 (i386_dr_low_get_status): Likewise.
10013 (i386_dr_low): New global variable.
10015 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
10017 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
10018 * Makefile.in (AR, AR_FLAGS): Define.
10019 * configure: Regenerate.
10021 2014-06-19 Gary Benson <gbenson@redhat.com>
10023 * Makefile.in (i386-dregs.o): New rule.
10024 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
10025 * i386-low.c (target.h): Remove include.
10026 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
10027 (DR_CONTROL_SHIFT): Likewise.
10028 (DR_CONTROL_SIZE): Likewise.
10029 (DR_RW_EXECUTE): Likewise.
10030 (DR_RW_WRITE): Likewise.
10031 (DR_RW_READ): Likewise.
10032 (DR_RW_IORW): Likewise.
10033 (DR_LEN_1): Likewise.
10034 (DR_LEN_2): Likewise.
10035 (DR_LEN_4): Likewise.
10036 (DR_LEN_8): Likewise.
10037 (DR_LOCAL_ENABLE_SHIFT): Likewise.
10038 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
10039 (DR_ENABLE_SIZE): Likewise.
10040 (DR_LOCAL_SLOWDOWN): Likewise.
10041 (DR_GLOBAL_SLOWDOWN): Likewise.
10042 (DR_CONTROL_RESERVED): Likewise.
10043 (I386_DR_CONTROL_MASK): Likewise.
10044 (I386_DR_VACANT): Likewise.
10045 (I386_DR_LOCAL_ENABLE): Likewise.
10046 (I386_DR_GLOBAL_ENABLE): Likewise.
10047 (I386_DR_DISABLE): Likewise.
10048 (I386_DR_SET_RW_LEN): Likewise.
10049 (I386_DR_GET_RW_LEN): Likewise.
10050 (I386_DR_WATCH_HIT): Likewise.
10051 (i386_wp_op_t): Likewise.
10052 (i386_show_dr): Likewise.
10053 (i386_length_and_rw_bits): Likewise.
10054 (i386_insert_aligned_watchpoint): Likewise.
10055 (i386_remove_aligned_watchpoint): Likewise.
10056 (i386_handle_nonaligned_watchpoint): Likewise.
10057 i386_update_inferior_debug_regs(): Likewise.
10058 (i386_dr_insert_watchpoint): Likewise.
10059 (i386_dr_remove_watchpoint): Likewise.
10060 (i386_dr_region_ok_for_watchpoint): Likewise.
10061 (i386_dr_stopped_data_address): Likewise.
10062 (i386_dr_stopped_by_watchpoint): Likewise.
10064 2014-06-19 Gary Benson <gbenson@redhat.com>
10066 * i386-low.c (i386_dr_show): Renamed to
10067 i386_show_dr and made static. All uses updated.
10068 (i386_dr_length_and_rw_bits): Renamed to
10069 i386_length_and_rw_bits and made static.
10071 (i386_dr_insert_aligned_watchpoint): Renamed to
10072 i386_insert_aligned_watchpoint and made static.
10074 (i386_dr_remove_aligned_watchpoint): Renamed to
10075 i386_remove_aligned_watchpoint and made static.
10077 (i386_dr_update_inferior_debug_regs): Renamed to
10078 i386_update_inferior_debug_regs and made static.
10081 2014-06-18 Gary Benson <gbenson@redhat.com>
10083 * i386-low.h (i386_dr_low_can_set_addr): New macro.
10084 (i386_dr_low_can_set_control): Likewise.
10085 (i386_get_debug_register_length): Likewise.
10086 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
10087 (i386_dr_low_can_set_control): Likewise.
10088 (i386_get_debug_register_length): Likewise.
10090 2014-06-17 Gary Benson <gbenson@redhat.com>
10092 * i386-low.h (i386-dregs.h): New include.
10093 (DR_FIRSTADDR): Now in i386-dregs.h.
10094 (DR_LASTADDR): Likewise.
10095 (DR_NADDR): Likewise.
10096 (DR_STATUS): Likewise.
10097 (DR_CONTROL): Likewise.
10098 (i386_debug_reg_state): Likewise.
10099 (i386_dr_insert_watchpoint): Likewise.
10100 (i386_dr_remove_watchpoint): Likewise.
10101 (i386_dr_region_ok_for_watchpoint): Likewise.
10102 (i386_dr_stopped_data_address): Likewise.
10103 (i386_dr_stopped_by_watchpoint): Likewise.
10104 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
10106 2014-06-18 Gary Benson <gbenson@redhat.com>
10108 * i386-low.h (i386_low_insert_watchpoint): Renamed to
10109 i386_dr_insert_watchpoint.
10110 (i386_low_remove_watchpoint): Renamed to
10111 i386_dr_remove_watchpoint.
10112 (i386_low_region_ok_for_watchpoint): Renamed to
10113 i386_dr_region_ok_for_watchpoint.
10114 (i386_low_stopped_data_address): Renamed to
10115 i386_dr_stopped_data_address.
10116 (i386_low_stopped_by_watchpoint): Renamed to
10117 i386_dr_stopped_by_watchpoint.
10118 * i386-low.c (i386_show_dr): Renamed to
10119 i386_dr_show and made nonstatic. All uses updated.
10120 (i386_length_and_rw_bits): Renamed to
10121 i386_dr_length_and_rw_bits and made nonstatic.
10123 (i386_insert_aligned_watchpoint): Renamed to
10124 i386_dr_insert_aligned_watchpoint and made nonstatic.
10126 (i386_remove_aligned_watchpoint): Renamed to
10127 i386_dr_remove_aligned_watchpoint and made nonstatic.
10129 (i386_update_inferior_debug_regs): Renamed to
10130 i386_dr_update_inferior_debug_regs and made nonstatic.
10132 (i386_low_insert_watchpoint): Renamed to
10133 i386_dr_insert_watchpoint. All uses updated.
10134 (i386_low_remove_watchpoint): Renamed to
10135 i386_dr_remove_watchpoint. All uses updated.
10136 (i386_low_region_ok_for_watchpoint): Renamed to
10137 i386_dr_region_ok_for_watchpoint. All uses updated.
10138 (i386_low_stopped_data_address): Renamed to
10139 i386_dr_stopped_data_address. All uses updated.
10140 (i386_low_stopped_by_watchpoint): Renamed to
10141 i386_dr_stopped_by_watchpoint. All uses updated.
10143 2014-06-18 Gary Benson <gbenson@redhat.com>
10145 * i386-low.c (i386_dr_low_can_set_addr): New macro.
10146 (i386_dr_low_can_set_control): Likewise.
10147 (i386_insert_aligned_watchpoint): New check.
10149 2014-06-18 Gary Benson <gbenson@redhat.com>
10151 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
10154 2014-06-18 Gary Benson <gbenson@redhat.com>
10156 * i386-low.c (i386_length_and_rw_bits): Use internal_error
10157 instead of fatal and error.
10158 (i386_handle_nonaligned_watchpoint): Likewise.
10160 2014-06-18 Gary Benson <gbenson@redhat.com>
10162 * i386-low.c (i386_get_debug_register_length): New macro.
10163 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
10164 (i386_show_dr): Use debug_printf instead of fprintf. Use
10165 phex to format values.
10167 2014-06-18 Gary Benson <gbenson@redhat.com>
10169 * i386-low.h: Comment changes.
10170 * i386-low.c: Likewise.
10172 2014-06-18 Gary Benson <gbenson@redhat.com>
10174 * i386-low.c: Whitespace changes.
10176 2014-06-12 Tom Tromey <tromey@redhat.com>
10178 * utils.c (freeargv): Remove.
10180 2014-06-12 Tom Tromey <tromey@redhat.com>
10182 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
10183 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
10184 (parse_debug_format_options): Likewise.
10185 (gdbserver_usage): Likewise.
10186 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
10187 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
10188 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
10190 ($(LIBGNU)): Depend on libiberty.
10191 (all-lib): Recurse into all subdirs.
10192 (install-only): Invoke "install" target in subdirs.
10193 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
10195 * configure: Rebuild.
10196 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
10197 for vasprintf, vsnprintf, or gettimeofday.
10198 * configure.srv: Don't add safe-ctype.o or lbasename.o to
10201 2014-06-05 Joel Brobecker <brobecker@adacore.com>
10203 * development.sh: Delete.
10204 * Makefile.in (config.status): Adjust dependency on development.sh.
10205 * configure.ac: Adjust development.sh source call.
10206 * configure: Regenerate.
10208 2014-06-02 Pedro Alves <palves@redhat.com>
10210 * ax.c (gdb_free_agent_expr): New function.
10211 * ax.h (gdb_free_agent_expr): New declaration.
10212 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
10214 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
10216 (clear_breakpoint_conditions_and_commands): New function.
10217 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
10218 (clear_breakpoint_conditions_and_commands): New declaration.
10220 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
10222 * linux-aarch64-low.c (asm/ptrace.h): Include.
10224 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
10226 Fix TLS access for -static -pthread.
10227 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
10228 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
10229 (thread_db_load_search, try_thread_db_load_1): Initialize it.
10231 2014-05-20 Pedro Alves <palves@redhat.com>
10233 * linux-aarch64-low.c (aarch64_insert_point)
10234 (aarch64_remove_point): No longer check whether the type is
10235 supported here. Adjust to new interface.
10236 (the_low_target): Install aarch64_supports_z_point_type as
10237 supports_z_point_type method.
10238 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
10239 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
10240 instead of a Z packet char. Adjust.
10241 (arm_supports_z_point_type): New function.
10242 (arm_insert_point, arm_remove_point): Adjust to new interface.
10243 (the_low_target): Install arm_supports_z_point_type.
10244 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
10245 (cris_insert_point, cris_remove_point): Adjust to new interface.
10246 Don't check whether the type is supported here.
10247 (the_low_target): Install cris_supports_z_point_type.
10248 * linux-low.c (linux_supports_z_point_type): New function.
10249 (linux_insert_point, linux_remove_point): Adjust to new interface.
10250 * linux-low.h (struct linux_target_ops) <insert_point,
10251 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
10252 raw_breakpoint pointer parameter.
10253 <supports_z_point_type>: New method.
10254 * linux-mips-low.c (mips_supports_z_point_type): New function.
10255 (mips_insert_point, mips_remove_point): Adjust to new interface.
10256 Use mips_supports_z_point_type.
10257 (the_low_target): Install mips_supports_z_point_type.
10258 * linux-ppc-low.c (the_low_target): Install NULL as
10259 supports_z_point_type method.
10260 * linux-s390-low.c (the_low_target): Install NULL as
10261 supports_z_point_type method.
10262 * linux-sparc-low.c (the_low_target): Install NULL as
10263 supports_z_point_type method.
10264 * linux-x86-low.c (x86_supports_z_point_type): New function.
10265 (x86_insert_point): Adjust to new insert_point interface. Use
10266 insert_memory_breakpoint. Adjust to new
10267 i386_low_insert_watchpoint interface.
10268 (x86_remove_point): Adjust to remove_point interface. Use
10269 remove_memory_breakpoint. Adjust to new
10270 i386_low_remove_watchpoint interface.
10271 (the_low_target): Install x86_supports_z_point_type.
10272 * lynx-low.c (lynx_target_ops): Install NULL as
10273 supports_z_point_type callback.
10274 * nto-low.c (nto_supports_z_point_type): New.
10275 (nto_insert_point, nto_remove_point): Adjust to new interface.
10276 (nto_target_ops): Install nto_supports_z_point_type.
10277 * mem-break.c: Adjust intro comment.
10278 (struct raw_breakpoint) <raw_type, size>: New fields.
10279 <inserted>: Update comment.
10280 <shlib_disabled>: Delete field.
10281 (enum bkpt_type) <gdb_breakpoint>: Delete value.
10282 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
10283 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
10284 (raw_bkpt_type_to_target_hw_bp_type): New function.
10285 (find_enabled_raw_code_breakpoint_at): New function.
10286 (find_raw_breakpoint_at): New type and size parameters. Use them.
10287 (insert_memory_breakpoint): New function, based off
10288 set_raw_breakpoint_at.
10289 (remove_memory_breakpoint): New function.
10290 (set_raw_breakpoint_at): Reimplement.
10291 (set_breakpoint): New, based on set_breakpoint_at.
10292 (set_breakpoint_at): Reimplement.
10293 (delete_raw_breakpoint): Go through the_target->remove_point
10294 instead of assuming memory breakpoints.
10295 (find_gdb_breakpoint_at): Delete.
10296 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
10297 (find_gdb_breakpoint): New function.
10298 (set_gdb_breakpoint_at): Delete.
10299 (z_type_supported): New function.
10300 (set_gdb_breakpoint_1): New function, loosely based off
10301 set_gdb_breakpoint_at.
10302 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
10303 (delete_gdb_breakpoint_at): Delete.
10304 (delete_gdb_breakpoint_1): New function, loosely based off
10305 delete_gdb_breakpoint_at.
10306 (delete_gdb_breakpoint): New function.
10307 (clear_gdb_breakpoint_conditions): Rename to ...
10308 (clear_breakpoint_conditions): ... this. Don't handle a NULL
10310 (add_condition_to_breakpoint): Make static.
10311 (add_breakpoint_condition): Take a struct breakpoint pointer
10312 instead of an address. Adjust.
10313 (gdb_condition_true_at_breakpoint): Rename to ...
10314 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
10316 (gdb_condition_true_at_breakpoint): Reimplement.
10317 (add_breakpoint_commands): Take a struct breakpoint pointer
10318 instead of an address. Adjust.
10319 (gdb_no_commands_at_breakpoint): Rename to ...
10320 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
10321 parameter. Return true if no breakpoint was found. Change debug
10323 (gdb_no_commands_at_breakpoint): Reimplement.
10324 (run_breakpoint_commands): Rename to ...
10325 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
10326 and change return type to boolean.
10327 (run_breakpoint_commands): New function.
10328 (gdb_breakpoint_here): Also check for Z1 breakpoints.
10329 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
10330 breakpoint. Go through the_target->remove_point instead of
10331 assuming memory breakpoint.
10332 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
10333 software and hardware breakpoints.
10334 (reinsert_raw_breakpoint): Go through the_target->insert_point
10335 instead of assuming memory breakpoint.
10336 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
10337 software and hardware breakpoints.
10338 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
10339 Check both software and hardware breakpoints.
10340 (validate_inserted_breakpoint): Assert the breakpoint is a
10341 software breakpoint. Set the inserted flag to -1 instead of
10342 setting shlib_disabled.
10343 (delete_disabled_breakpoints): Adjust.
10344 (validate_breakpoints): Only validate software breakpoints.
10345 Adjust to inserted flag change.
10346 (check_mem_read, check_mem_write): Skip breakpoint types other
10347 than software breakpoints. Adjust to inserted flag change.
10348 * mem-break.h (enum raw_bkpt_type): New enum.
10349 (raw_breakpoint, struct process_info): Forward declare.
10350 (Z_packet_to_target_hw_bp_type): Delete declaration.
10351 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
10352 (set_gdb_breakpoint, delete_gdb_breakpoint)
10353 (clear_breakpoint_conditions): New declarations.
10354 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
10355 (breakpoint_inserted_here): Update comment.
10356 (add_breakpoint_condition, add_breakpoint_commands): Replace
10357 address parameter with a breakpoint pointer parameter.
10358 (gdb_breakpoint_here): Update comment.
10359 (delete_gdb_breakpoint_at): Delete.
10360 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
10361 * server.c (process_point_options): Take a struct breakpoint
10362 pointer instead of an address. Adjust.
10363 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
10364 delete_gdb_breakpoint.
10365 * spu-low.c (spu_target_ops): Install NULL as
10366 supports_z_point_type method.
10367 * target.h: Include mem-break.h.
10368 (struct target_ops) <prepare_to_access_memory>: Update comment.
10369 <supports_z_point_type>: New field.
10370 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
10371 instead of a char. Also take a raw breakpoint pointer.
10372 * win32-arm-low.c (the_low_target): Install NULL as
10373 supports_z_point_type.
10374 * win32-i386-low.c (i386_supports_z_point_type): New function.
10375 (i386_insert_point, i386_remove_point): Adjust to new interface.
10376 (the_low_target): Install i386_supports_z_point_type.
10377 * win32-low.c (win32_supports_z_point_type): New function.
10378 (win32_insert_point, win32_remove_point): Adjust to new interface.
10379 (win32_target_ops): Install win32_supports_z_point_type.
10380 * win32-low.h (struct win32_target_ops):
10381 <supports_z_point_type>: New method.
10382 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
10383 instead of a char. Also take a raw breakpoint pointer.
10385 2014-05-20 Pedro Alves <palves@redhat.com>
10387 * mem-break.h: Include break-common.h.
10388 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
10389 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
10390 (Z_packet_to_target_hw_bp_type): New declaration.
10391 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
10392 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
10393 (Z_PACKET_ACCESS_WP): Delete macros.
10394 (Z_packet_to_hw_type): Delete function.
10395 * i386-low.h: Don't include break-common.h here.
10396 (Z_packet_to_hw_type): Delete declaration.
10397 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
10398 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
10399 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
10400 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
10401 * linux-aarch64-low.c: Don't include break-common.h here.
10402 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
10403 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
10404 (Z_packet_to_target_hw_bp_type): Delete function.
10405 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
10407 (mips_insert_point, mips_remove_point): Use
10408 Z_packet_to_target_hw_bp_type.
10410 2014-05-20 Pedro Alves <palves@redhat.com>
10412 * linux-aarch64-low.c: Include break-common.h.
10413 (enum target_point_type): Delete.
10414 (Z_packet_to_point_type): Rename to ...
10415 (Z_packet_to_target_hw_bp_type): ... this, and return a
10416 target_hw_bp_type instead.
10417 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
10418 instead of an enum target_point_type.
10419 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
10421 (aarch64_dr_state_insert_one_point)
10422 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
10423 (aarch64_handle_aligned_watchpoint)
10424 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
10425 Take an enum target_hw_bp_type instead of an enum
10427 (aarch64_supports_z_point_type): New function.
10428 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
10429 use Z_packet_to_target_hw_bp_type.
10431 2014-05-20 Joel Brobecker <brobecker@adacore.com>
10433 * configure.ac: Only use -Werror by default when DEVELOPMENT
10435 * configure: Regenerate.
10437 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
10439 Fix gdbserver qGetTLSAddr for x86_64 -m32.
10440 * linux-x86-low.c (X86_64_USER_REGS): New.
10441 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
10443 2014-04-28 Yao Qi <yao@codesourcery.com>
10445 * Makefile.in (i386-avx512.c): Fix the typo of generated file
10448 2014-04-25 Pedro Alves <palves@redhat.com>
10451 * linux-low.c (linux_attach_fail_reason_string): New function.
10452 (linux_attach_lwp): Delete.
10453 (linux_attach_lwp_1): Rename to ...
10454 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
10455 argument. Remove "initial" parameter. Return int instead of
10456 void. Don't error or warn here.
10457 (linux_attach): Adjust to call linux_attach_lwp. Call error on
10458 failure to attach to the tgid. Call warning when failing to
10460 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
10461 argument. Remove "initial" parameter. Return int instead of
10462 void. Don't error or warn here.
10463 (linux_attach_fail_reason_string): New declaration.
10464 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
10465 interface change. Use linux_attach_fail_reason_string.
10467 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
10468 Walfred Tedeschi <walfred.tedeschi@intel.com>
10470 * Makefile.in: Added rules to handle new files
10471 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
10472 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
10473 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
10474 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
10475 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
10476 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
10477 x32-avx512-linux.o.
10478 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
10479 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
10480 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
10481 i386/x32-avx512.xml.
10482 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
10483 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
10484 i386/x32-avx512-linux.xml.
10485 * i387-fp.c (num_avx512_k_registers): New constant for number
10487 (num_avx512_zmmh_low_registers): New constant for number of
10488 lower ZMM registers (0-15).
10489 (num_avx512_zmmh_high_registers): New constant for number of
10490 higher ZMM registers (16-31).
10491 (num_avx512_ymmh_registers): New contant for number of higher
10492 YMM registers (ymm16-31 added by avx521 on x86_64).
10493 (num_avx512_xmm_registers): New constant for number of higher
10494 XMM registers (xmm16-31 added by AVX512 on x86_64).
10495 (struct i387_xsave): Add space for AVX512 registers.
10496 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
10497 Add code to handle AVX512 registers.
10498 (i387_xsave_to_cache): Add code to handle AVX512 registers.
10499 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
10500 prototypei from generated file.
10501 (tdesc_amd64_avx512_linux): Likewise.
10502 (init_registers_x32_avx512_linux): Likewise.
10503 (tdesc_x32_avx512_linux): Likewise.
10504 (init_registers_i386_avx512_linux): Likewise.
10505 (tdesc_i386_avx512_linux): Likewise.
10506 (x86_64_regmap): Add AVX512 registers.
10507 (x86_linux_read_description): Add code to handle AVX512 XSTATE
10509 (initialize_low_arch): Add code to initialize AVX512 registers.
10511 2014-04-23 Pedro Alves <palves@redhat.com>
10513 * mem-break.c (find_gdb_breakpoint_at): Make static.
10514 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
10516 2014-04-23 Pedro Alves <palves@redhat.com>
10518 * i386-low.c: Don't include break-common.h here.
10519 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
10520 prototype to take target_hw_bp_type as argument instead of a Z
10522 * i386-low.h: Include break-common.h here.
10523 (Z_packet_to_hw_type): Declare.
10524 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
10526 * linux-x86-low.c (x86_insert_point): Convert the packet number to
10527 a target_hw_bp_type before calling i386_low_insert_watchpoint.
10528 (x86_remove_point): Convert the packet number to a
10529 target_hw_bp_type before calling i386_low_remove_watchpoint.
10530 * win32-i386-low.c (i386_insert_point): Convert the packet number
10531 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
10532 (i386_remove_point): Convert the packet number to a
10533 target_hw_bp_type before calling i386_low_remove_watchpoint.
10535 2014-04-23 Pedro Alves <palves@redhat.com>
10537 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
10539 2014-04-10 Pedro Alves <palves@redhat.com>
10541 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
10542 Check if the condition or command is NULL before checking if the
10543 breakpoint is known. On success, return true.
10544 * mem-break.h (add_breakpoint_condition): Document return.
10545 (add_breakpoint_commands): Add describing comment.
10546 * server.c (skip_to_semicolon): New function.
10547 (process_point_options): Use it.
10549 2014-04-09 Pedro Alves <palves@redhat.com>
10551 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
10554 2014-02-27 Pedro Alves <palves@redhat.com>
10557 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
10559 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
10561 (last_thread_of_process_p): Take a PID argument instead of a
10563 (linux_wait_for_lwp): Delete.
10564 (num_lwps, check_zombie_leaders, not_stopped_callback): New
10566 (linux_low_filter_event): New function, party factored out from
10567 linux_wait_for_event.
10568 (linux_wait_for_event): Rename to ...
10569 (linux_wait_for_event_filtered): ... this. Add new filter ptid
10570 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
10571 sigsuspend. Check for zombie leaders.
10572 (linux_wait_for_event): Reimplement as wrapper around
10573 linux_wait_for_event_filtered.
10574 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
10575 a normal or signal exit is seen, it's the whole process exiting.
10576 (wait_for_sigstop): No longer a for_each_inferior callback.
10577 Rewrite on top of linux_wait_for_event_filtered.
10578 (stop_all_lwps): Call wait_for_sigstop directly.
10579 * server.c (resume, handle_target_event): Handle
10580 TARGET_WAITKIND_NO_RESUMED.
10582 2014-02-26 Joel Brobecker <brobecker@adacore.com>
10584 * win32-low.c (psapi_get_dll_name,
10585 * win32_CreateToolhelp32Snapshot): Delete.
10586 (win32_CreateToolhelp32Snapshot, win32_Module32First)
10587 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
10589 (handle_load_dll): Add function description.
10590 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
10592 2014-02-26 Joel Brobecker <brobecker@adacore.com>
10594 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
10596 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
10597 base address when calling win32_add_one_solib.
10598 (handle_load_dll): Delete local variable load_addr.
10599 Remove 0x1000 offset applied to DLL base address when calling
10600 win32_add_one_solib.
10601 (handle_unload_dll): Add comment.
10603 2014-02-26 Joel Brobecker <brobecker@adacore.com>
10605 * win32-low.c (win32_add_all_dlls): Renames
10606 win32_ensure_ntdll_loaded. Rewrite function documentation.
10607 Adjust implementation to always load all DLLs.
10608 Add 0x1000 offset to DLL base address when calling
10609 win32_add_one_solib.
10610 (child_initialization_done): New static global.
10611 (do_initial_child_stuff): Set child_initialization_done to
10612 zero during child initialization, and 1 after. Replace call
10613 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
10615 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
10616 (handle_unload_dll): Add function documentation.
10617 (get_child_debug_event): Ignore load and unload DLL events
10618 during child initialization.
10620 2014-02-20 Doug Evans <dje@google.com>
10622 Remove global all_lwps.
10623 * inferiors.h (ptid_of): Move here from linux-low.h.
10624 (pid_of, lwpid_of): Ditto.
10625 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
10626 parameter is a struct thread_info * now.
10627 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
10628 directly. Pass &all_threads to find_inferior instead of &all_lwps.
10629 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
10631 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
10632 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
10633 * linux-arm-low.c (update_registers_callback): Update, "entry"
10634 parameter is a struct thread_info * now.
10635 Fetch lwpid from current_inferior directly.
10636 (arm_insert_point): Pass &all_threads to find_inferior instead of
10638 (arm_remove_point): Ditto.
10639 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
10640 (arm_prepare_to_resume): Fetch pid from thread.
10641 (arm_read_description): Fetch lwpid from current_inferior directly.
10642 * linux-low.c (all_lwps): Delete.
10643 (delete_lwp): Delete call to remove_inferior.
10644 (handle_extended_wait): Fetch lwpid from thread.
10645 (add_lwp): Don't set lwp->entry.id. Remove call to
10646 add_inferior_to_list.
10647 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
10648 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
10649 (kill_one_lwp_callback): Ditto.
10650 (linux_kill): Don't dereference NULL pointer.
10651 Fetch ptid,lwpid from thread.
10652 (get_detach_signal): Fetch ptid from thread.
10653 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
10654 Simplify call to regcache_invalidate_thread.
10655 (delete_lwp_callback): Update, "entry" parameter is a
10656 struct thread_info * now. Fetch pid from thread.
10657 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
10658 (status_pending_p_callback): Update, "entry" parameter is a
10659 struct thread_info * now. Fetch ptid from thread.
10660 (find_lwp_pid): Update, "entry" parameter is a
10661 struct thread_info * now.
10662 (linux_wait_for_lwp): Fetch pid from thread.
10663 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
10664 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
10665 (enqueue_one_deferred_signal): Fetch lwpid from thread.
10666 (dequeue_one_deferred_signal): Ditto.
10667 (cancel_breakpoint): Fetch ptid from current_inferior.
10668 (linux_wait_for_event): Pass &all_threads to find_inferior,
10669 not &all_lwps. Fetch ptid, lwpid from thread.
10670 (count_events_callback): Update, "entry" parameter is a
10671 struct thread_info * now.
10672 (select_singlestep_lwp_callback): Ditto.
10673 (select_event_lwp_callback): Ditto.
10674 (cancel_breakpoints_callback): Ditto.
10675 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
10677 (select_event_lwp): Ditto. Fetch ptid from event_thread.
10678 (unsuspend_one_lwp): Update, "entry" parameter is a
10679 struct thread_info * now.
10680 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
10682 (linux_stabilize_threads): Ditto. And for for_each_inferior.
10683 Fetch lwpid from thread, not lwp.
10684 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
10685 Pass &all_threads to find_inferior, not &all_lwps.
10686 (send_sigstop): Fetch lwpid from thread, not lwp.
10687 (send_sigstop_callback): Update, "entry" parameter is a
10688 struct thread_info * now.
10689 (suspend_and_send_sigstop_callback): Ditto.
10690 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
10691 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
10692 struct thread_info * now.
10693 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
10695 (lwp_running): Update, "entry" parameter is a
10696 struct thread_info * now.
10697 (stop_all_lwps): Fetch ptid from thread.
10698 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
10699 (linux_resume_one_lwp): Fetch lwpid from thread.
10700 (linux_set_resume_request): Update, "entry" parameter is a
10701 struct thread_info * now. Fetch pid, lwpid from thread.
10702 (resume_status_pending_p): Update, "entry" parameter is a
10703 struct thread_info * now.
10704 (need_step_over_p): Ditto. Fetch lwpid from thread.
10705 (start_step_over): Fetch lwpid from thread.
10706 (linux_resume_one_thread): Update, "entry" parameter is a
10707 struct thread_info * now. Fetch lwpid from thread.
10708 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
10709 (proceed_one_lwp): Update, "entry" parameter is a
10710 struct thread_info * now. Fetch lwpid from thread.
10711 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
10712 struct thread_info * now.
10713 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
10714 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
10715 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
10717 (regsets_store_inferior_registers): Ditto.
10718 (fetch_register, store_register): Ditto.
10719 (linux_read_memory, linux_write_memory): Ditto.
10720 (linux_request_interrupt): Ditto.
10721 (linux_read_auxv): Ditto.
10722 (linux_xfer_siginfo): Ditto.
10723 (linux_qxfer_spu): Ditto.
10724 (linux_qxfer_libraries_svr4): Ditto.
10725 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
10726 moved to inferiors.h.
10728 (get_thread_lwp): Update.
10729 (struct lwp_info): Delete member "entry". Simplify comment for
10731 (all_lwps): Delete.
10732 * linux-mips-low.c (mips_read_description): Fetch lwpid from
10733 current_inferior directly.
10734 (update_watch_registers_callback): Update, "entry" parameter is a
10735 struct thread_info * now. Fetch pid from thread.
10736 (mips_linux_prepare_to_resume): Fetch ptid from thread.
10737 (mips_insert_point): Fetch lwpid from current_inferior.
10738 Pass &all_threads to find_inferior, not &all_lwps.
10739 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
10740 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
10742 (mips_stopped_data_address): Ditto.
10743 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
10745 * linux-tile-low.c (tile_arch_setup): Ditto.
10746 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
10747 (update_debug_registers_callback): Update, "entry" parameter is a
10748 struct thread_info * now. Fetch pid from thread.
10749 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
10750 Pass &all_threads to find_inferior, not &all_lwps.
10751 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
10752 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
10753 Pass &all_threads to find_inferior, not &all_lwps.
10754 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
10755 (i386_dr_low_get_status): Ditto.
10756 (x86_linux_prepare_to_resume): Fetch ptid from thread.
10757 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
10758 (x86_linux_read_description): Ditto.
10759 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
10761 2014-02-20 Doug Evans <dje@google.com>
10763 * inferiors.c (get_first_inferior): Fix buglet.
10765 2014-02-19 Doug Evans <dje@google.com>
10767 * gdbthread.h (add_thread): Change result type to struct thread_info *.
10768 * inferiors.c (add_thread): Change result type to struct thread_info *.
10769 All callers updated.
10770 (add_lwp): Call add_thread here instead of in callers.
10771 All callers updated.
10772 * linux-low.h (get_lwp_thread): Rewrite.
10773 (struct lwp_info): New member "thread".
10775 2014-02-19 Doug Evans <dje@google.com>
10777 * linux-low.c (add_lwp): Change result to struct lwp_info *.
10778 All callers updated.
10780 2014-02-19 Doug Evans <dje@google.com>
10782 * inferiors.c (add_thread): Fix whitespace.
10784 2014-02-19 Doug Evans <dje@google.com>
10786 * dll.c (clear_dlls): Replace accessing list implemention details
10788 * gdbthread.h (get_first_thread): Declare.
10789 * inferiors.c (for_each_inferior_with_data): New function.
10790 (get_first_thread): New function.
10791 (find_thread_ptid): Simplify.
10792 (get_first_inferior): New function.
10793 (clear_list): Delete.
10794 (one_inferior_p): New function.
10795 (clear_inferior_list): New function.
10796 (clear_inferiors): Update.
10797 * inferiors.h (for_each_inferior_with_data): Declare.
10798 (clear_inferior_list): Declare.
10799 (one_inferior_p): Declare.
10800 (get_first_inferior): Declare.
10801 * linux-low.c (linux_wait_for_event): Replace accessing list
10802 implemention details with API function.
10803 * server.c (target_running): Ditto.
10804 (accumulate_file_name_length): New function.
10805 (emit_dll_description): New function.
10806 (handle_qxfer_libraries): Replace accessing list implemention
10807 details with API function.
10808 (handle_qxfer_threads_worker): New function.
10809 (handle_qxfer_threads_proper): Replace accessing list implemention
10810 details with API function.
10811 (handle_query): Ditto.
10812 (visit_actioned_threads_callback_ftype): New typedef.
10813 (visit_actioned_threads_data): New struct.
10814 (visit_actioned_threads): Rewrite to be find_inferior callback.
10815 (resume): Call find_inferior.
10816 (handle_status): Replace accessing list implemention
10817 details with API function.
10818 (process_serial_event): Replace accessing list implemention details
10820 * target.c (set_desired_inferior): Replace accessing list implemention
10821 details with API function.
10822 * tracepoint.c (same_process_p): New function.
10823 (gdb_agent_about_to_close): Replace accessing list implemention
10824 details with API function.
10825 * win32-low.c (child_delete_thread): Replace accessing list
10826 implemention details with API function.
10827 (match_dll_by_basename): New function.
10828 (dll_is_loaded_by_basename): New function.
10829 (win32_ensure_ntdll_loaded): Replace accessing list implemention
10830 details call to dll_is_loaded_by_basename.
10832 2014-02-19 Doug Evans <dje@google.com>
10834 * dll.h (struct dll_info): Add comment.
10835 * gdbthread.h (struct thread_info): Add comment.
10836 (current_ptid): Simplify.
10837 * inferiors.c (add_process): Update.
10838 (remove_process): Update.
10839 * inferiors.h (struct process_info): Rename member "head" to "entry".
10840 * linux-low.c (delete_lwp): Update.
10842 (last_thread_of_process_p): Update.
10843 (kill_one_lwp_callback, linux_kill): Update.
10844 (status_pending_p_callback): Update.
10845 (wait_for_sigstop): Update. Simplify read of ptid.
10846 (start_step_over): Update.
10847 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
10848 (get_lwp_thread): Update.
10849 (struct lwp_info): Rename member "head" to "entry".
10850 * regcache.h (inferior_list_entry): Delete.
10851 * server.c (kill_inferior_callback): Update.
10852 (detach_or_kill_inferior_callback): Update.
10853 (print_started_pid): Update.
10854 (print_attached_pid): Update.
10855 (process_serial_event): Simplify read of ptid.
10856 * thread-db.c (thread_db_create_event): Update.
10857 (thread_db_get_tls_address): Update.
10858 * win32-low.c (current_inferior_ptid): Simplify.
10860 2014-02-19 Tom Tromey <tromey@redhat.com>
10862 * target.h (struct target_ops) <supports_btrace>: Add target_ops
10864 (target_supports_btrace): Update.
10866 2014-02-14 Yao Qi <yao@codesourcery.com>
10868 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
10869 (rsp-low-ipa.o): New target.
10871 2014-02-12 Tom Tromey <tromey@redhat.com>
10873 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
10874 convert_ascii_to_int.
10875 * regcache.c (registers_to_string): Likewise.
10876 * remote-utils.c (decode_M_packet): Likewise.
10877 * server.c (process_serial_event): Likewise.
10879 2014-02-12 Tom Tromey <tromey@redhat.com>
10881 * server.c (handle_query, handle_v_run): Use hex2bin, not
10883 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
10885 2014-02-12 Tom Tromey <tromey@redhat.com>
10887 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
10888 convert_int_to_ascii.
10889 * regcache.c (registers_to_string, collect_register_as_string):
10891 * remote-utils.c (look_up_one_symbol, relocate_instruction):
10893 * server.c (process_serial_event): Likewise.
10894 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
10895 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
10897 2014-02-12 Tom Tromey <tromey@redhat.com>
10899 * remote-utils.c (look_up_one_symbol, monitor_output): Use
10900 bin2hex, not hexify.
10901 * tracepoint.c (cmd_qtstatus): Likewise.
10903 2014-02-12 Tom Tromey <tromey@redhat.com>
10905 * remote-utils.c (monitor_output): Pass explicit length to
10908 2014-02-12 Tom Tromey <tromey@redhat.com>
10910 * tracepoint.c: Include rsp-low.h.
10911 * server.c: Include rsp-low.h.
10912 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
10913 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
10915 * remote-utils.c: Include rsp-low.h.
10916 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
10917 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
10918 (convert_int_to_ascii, convert_ascii_to_int): Move to
10920 * regcache.c: Include rsp-low.h.
10921 * ax.c: Include rsp-low.h.
10922 * Makefile.in (SFILES): Add common/rsp-low.c.
10923 (OBS): Add rsp-low.o.
10924 (rsp-low.o): New target.
10926 2014-02-12 Tom Tromey <tromey@redhat.com>
10928 * utils.h (pulongest, plongest, phex_nz): Don't declare.
10929 Include print-utils.h.
10930 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
10931 (plongest, thirty_two, phex_nz): Remove.
10932 * Makefile.in (SFILES): Add common/print-utils.c.
10933 (OBS): Add print-utils.o.
10934 (print-utils-ipa.o): New target.
10935 (print-utils.o): New target.
10936 (IPA_OBJS): Add print-utils-ipa.o.
10938 2014-02-06 Tom Tromey <tromey@redhat.com>
10940 * Makefile.in (SFILES): Fix indentation.
10942 2014-02-05 Doug Evans <dje@google.com>
10944 * linux-low.c (linux_wait_for_event): Improve comment.
10945 (linux_wait_1): Keep current_inferior in sync with event_child.
10947 2014-01-22 Doug Evans <dje@google.com>
10949 * gdbthread.h (gdb_id_to_thread): Delete, unused.
10951 2014-01-22 Doug Evans <dje@google.com>
10953 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
10954 * configure: Regenerate.
10955 * config.in: Regenerate.
10956 * Makefile.in (SFILES): Add debug.c.
10957 (OBS): Add debug.o.
10958 * debug.c: New file.
10959 * debug.h: New file.
10960 * linux-aarch64-low.c (*): Update all debugging printfs to use
10961 debug_printf instead of fprintf.
10962 * linux-arm-low.c (*): Ditto.
10963 * linux-cris-low.c (*): Ditto.
10964 * linux-crisv32-low.c (*): Ditto.
10965 * linux-m32r-low.c (*): Ditto.
10966 * linux-sparc-low.c (*): Ditto.
10967 * linux-x86.c (*): Ditto.
10968 * linux-low.c (*): Ditto.
10969 (linux_wait_1): Add calls to debug_enter, debug_exit.
10970 (linux_wait): Remove redundant debugging printf.
10971 (stop_all_lwps): Add calls to debug_enter, debug_exit.
10972 (linux_resume, unstop_all_lwps): Ditto.
10973 * mem-break.c (*): Update all debugging printfs to use
10974 debug_printf instead of fprintf.
10975 * remote-utils.c (*): Ditto.
10976 * thread-db.c (*): Ditto.
10977 * server.c #include <ctype.h>, "gdb_vecs.h".
10978 (debug_threads): Moved to debug.c.
10979 (*): Update all debugging printfs to use debug_printf instead of
10981 (start_inferior): Replace call to fflush with call to debug_flush.
10982 (monitor_show_help): Mention set debug-format.
10983 (parse_debug_format_options): New function.
10984 (handle_monitor_command): Handle "monitor set debug-format".
10985 (gdbserver_usage): Mention --debug-format.
10986 (main): Parse --debug-format.
10987 * server.h (debug_threads): Declaration moved to debug.h.
10988 #include "debug.h".
10989 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
10990 trace_debug_1 that uses debug_printf.
10991 (tracepoint_look_up_symbols): Update all debugging printfs to use
10992 debug_printf instead of fprintf.
10994 2014-01-20 Baruch Siach <baruch@tkos.co.il>
10996 * linux-xtensa-low.c: Include asm/ptrace.h instead of
10999 2014-01-17 Pedro Alves <palves@redhat.com>
11002 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
11003 defined after including gdb_proc_service.h.
11005 2014-01-16 Doug Evans <dje@google.com>
11007 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
11008 (match_dll): Use it.
11010 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
11012 * target.h (target_ops) <read_btrace>: Change parameters and
11013 return type to allow error reporting.
11014 * server.c (handle_qxfer_btrace): Support delta reads. Pass
11015 trace reading errors on.
11016 * linux-low.c (linux_low_read_btrace): Pass trace reading
11018 (linux_low_disable_btrace): New.
11020 2014-01-15 Doug Evans <dje@google.com>
11022 * inferiors.c (thread_id_to_gdb_id): Delete.
11023 * inferiors.h (thread_id_to_gdb_id): Delete.
11025 2014-01-13 Eli Zaretskii <eliz@gnu.org>
11027 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
11028 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
11031 2014-01-08 Pedro Alves <palves@redhat.com>
11033 * server.c (handle_status): Don't discard previous queued stop
11034 replies or thread's pending status here.
11035 (main) <disconnection>: Do it here instead.
11037 2014-01-08 Pedro Alves <palves@redhat.com>
11039 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
11040 * server.c (visit_actioned_threads, handle_pending_status): New
11042 (handle_v_cont): Factor out parts to ...
11043 (resume): ... this new function. If in all-stop, and a thread
11044 being resumed has a pending status, report it without actually
11046 (myresume): Adjust to use the new 'resume' function.
11047 (clear_pending_status_callback, set_pending_status_callback)
11048 (find_status_pending_thread_callback): New functions.
11049 (handle_status): Handle the case of multiple threads having
11050 interesting statuses to report. Report threads' real last signal
11051 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
11052 with an interesting thread to report the status for, instead of
11053 always reporting the status of the first thread.
11055 2014-01-01 Joel Brobecker <brobecker@adacore.com>
11057 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
11058 * gdbreplay.c (gdbreplay_version): Likewise.
11060 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
11062 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
11063 iov.iov_len with the real length in use.
11065 2013-12-13 Joel Brobecker <brobecker@adacore.com>
11067 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
11068 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
11069 for all targets that use win32-low.c.
11070 * win32-low.c (win32_ensure_ntdll_loaded): New function.
11071 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
11073 2013-12-13 Pedro Alves <palves@redhat.com>
11075 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
11076 if equal to TARGET_WAITKIND_LOADED.
11077 * win32-low.c (cached_status): New static global.
11078 (win32_wait): Add declaration.
11079 (do_initial_child_stuff): Flush all initial pending debug events
11080 up to the initial breakpoint.
11081 (win32_wait): If CACHED_STATUS was set, return that instead
11082 of doing a real wait. Remove the code resuming the execution
11083 of the inferior after receiving a TARGET_WAITKIND_LOADED event
11084 during the initial phase. Also remove the code changing
11085 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
11086 TARGET_WAITKIND_STOPPED.
11088 2013-12-11 Yao Qi <yao@codesourcery.com>
11090 * notif.c (handle_notif_ack): Return 0 if no notification
11093 2013-11-20 Doug Evans <dje@google.com>
11095 * linux-low.c (linux_set_resume_request): Fix comment.
11097 2013-11-20 Doug Evans <dje@google.com>
11099 * linux-low.c (resume_status_pending_p): Tweak comment.
11101 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
11103 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
11104 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
11105 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
11106 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
11107 (srv_amd64_regobj): Add amd64-mpx.o.
11108 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
11109 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
11110 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
11111 * i387-fp.c (num_pl_bnd_register) Added constant.
11112 (num_pl_bnd_cfg_registers) Added constant.
11113 (struct i387_xsave) Added reserved area and MPX fields.
11114 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
11115 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
11117 (tdesc_i386_mpx_linux): Add MPX amd64 target.
11118 (init_registers_amd64_mpx_linux): Declare new function.
11119 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
11120 (x86_64_regmap): Add MPX registers.
11121 (x86_linux_read_description): Add MPX case.
11122 (initialize_low_arch): Initialize MPX targets.
11124 2013-11-18 Tom Tromey <tromey@redhat.com>
11126 * configure: Rebuild.
11127 * configure.ac: Don't check for stdlib.h.
11128 * gdbreplay.c: Unconditionally include stdlib.h.
11130 2013-11-18 Tom Tromey <tromey@redhat.com>
11132 * config.in: Rebuild.
11133 * configure: Rebuild.
11134 * configure.ac: Don't use AC_HEADER_DIRENT.
11136 2013-11-18 Tom Tromey <tromey@redhat.com>
11138 * server.h: Don't check HAVE_STRING_H.
11139 * gdbreplay.c: Don't check HAVE_STRING_H.
11140 * configure: Rebuild.
11142 2013-11-18 Tom Tromey <tromey@redhat.com>
11144 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
11147 2013-11-08 Tom Tromey <tromey@redhat.com>
11149 * configure, config.in: Rebuild.
11150 * configure.ac: Remove unused configury.
11152 2013-11-08 Tom Tromey <tromey@redhat.com>
11154 * acinclude.m4: Include common.m4, codeset.m4.
11155 * configure, config.in: Rebuild.
11156 * configure.ac: Use GDB_AC_COMMON.
11158 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
11160 * linux-s390-low.c (HWCAP_S390_TE): New define.
11161 (s390_arch_setup): Consider the TE field in the HWCAP for
11162 determining 'have_regset_tdb'.
11164 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
11167 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
11170 2013-10-02 Pedro Alves <palves@redhat.com>
11172 * server.c (process_serial_event): Don't output "GDBserver
11173 exiting" if GDB is connected through stdio.
11174 * target.c (mywait): Likewise, be silent if GDB is connected
11177 2013-10-01 Joel Brobecker <brobecker@adacore.com>
11179 * lynx-low.c (lynx_add_threads_after_attach): New function.
11180 (lynx_attach): Remove call to add_thread. Add call to
11181 lynx_add_threads_after_attach instead.
11183 2013-09-28 Mike Frysinger <vapier@gentoo.org>
11185 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
11186 * config.in, configure: Regenerated.
11188 2013-09-18 Yao Qi <yao@codesourcery.com>
11191 * server.c (start_inferior): Clear 'resume_info'.
11193 2013-09-16 Jiong Wang <jiwang@tilera.com>
11195 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
11198 2013-09-16 Jiong Wang <jiwang@tilera.com>
11200 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
11201 linux-tile-low.o to srv_tgtobj.
11203 2013-09-16 Will Newton <will.newton@linaro.org>
11205 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
11208 2013-09-06 Pedro Alves <palves@redhat.com>
11210 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
11211 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
11212 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
11213 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
11214 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
11215 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
11217 2013-09-06 Pedro Alves <palves@redhat.com>
11219 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
11220 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
11222 2013-09-06 Pedro Alves <palves@redhat.com>
11224 * linux-amd64-ipa.c: Include tracepoint.h.
11225 * linux-i386-ipa.c: Include tracepoint.h.
11227 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
11229 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
11230 (ps_get_thread_area): New function.
11232 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
11234 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
11235 (initialize_low_arch): Call init_registers_crisv32 rather than
11236 init_register_crisv32.
11238 2013-09-05 Pedro Alves <palves@redhat.com>
11240 * server.h (handle_vFile, hostio_last_error_from_errno): Move
11242 * hostio.h: ... this new file.
11243 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
11244 win32-low.c: Include hostio.h.
11246 2013-09-05 Pedro Alves <palves@redhat.com>
11248 * server.h (gdb_client_data, handler_func, callback_handler_func)
11249 (delete_file_handler, add_file_handler, append_callback_event)
11250 (delete_callback_event, start_event_loop, initialize_event_loop):
11251 Move to event-loop.h and include it.
11252 * event-loop.h: New file.
11254 2013-09-05 Pedro Alves <palves@redhat.com>
11256 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
11257 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
11258 (loaded_dll, unloaded_dll): Move to ...
11259 * dll.h: ... this new file.
11260 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
11262 2013-09-05 Pedro Alves <palves@redhat.com>
11264 * server.h (current_process, get_thread_process, all_processes)
11265 (add_inferior_to_list, for_each_inferior, current_inferior)
11266 (remove_inferior, add_process, remove_process, find_process_pid)
11267 (have_started_inferiors_p, have_attached_inferiors_p)
11268 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
11269 (clear_inferiors, find_inferior, find_inferior_id)
11270 (inferior_target_data, set_inferior_target_data)
11271 (inferior_regcache_data, set_inferior_regcache_data): Move to
11272 inferiors.h, and include it.
11273 * inferiors.h: New file.
11275 2013-09-05 Pedro Alves <palves@redhat.com>
11277 * server.h (struct emit_ops, current_insn_ptr, emit_error):
11281 2013-09-05 Pedro Alves <palves@redhat.com>
11283 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
11285 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
11286 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
11287 (handle_tracepoint_general_set, handle_tracepoint_query)
11288 (tracepoint_finished_step, tracepoint_was_hit)
11289 (release_while_stepping_state_list, current_traceframe)
11290 (in_readonly_region, traceframe_read_mem)
11291 (fetch_traceframe_registers, traceframe_read_sdata)
11292 (traceframe_read_info, struct fast_tpoint_collect_status)
11293 (fast_tracepoint_collecting, force_unlock_trace_buffer)
11294 (handle_tracepoit_bkpts, initialize_low_tracepoint)
11295 (supply_fast_tracepoint_registers)
11296 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
11297 (ipa_tdesc, claim_trampoline_space)
11298 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
11299 (agent_mem_read, agent_get_trace_state_variable_value)
11300 (agent_set_trace_state_variable_value, agent_tsv_read)
11301 (agent_mem_read_string, get_raw_reg_func_addr)
11302 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
11303 * tracepoint.h: ... this new file.
11305 2013-09-05 Pedro Alves <palves@redhat.com>
11307 * server.h (perror_with_name, error, fatal, warning, paddress)
11308 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
11310 * utils.h: New file.
11312 2013-09-05 Pedro Alves <palves@redhat.com>
11314 * server.h (remote_debug, noack_mode, transport_is_reliable)
11315 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
11316 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
11317 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
11318 (write_enn, initialize_async_io, enable_async_io)
11319 (disable_async_io, check_remote_input_interrupt_request)
11320 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
11321 (dead_thread_notify, prepare_resume_reply)
11322 (decode_address_to_semicolon, decode_address, decode_m_packet)
11323 (decode_M_packet, decode_X_packet, decode_xfer_write)
11324 (decode_search_memory_packet, unhexify, hexify)
11325 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
11326 (look_up_one_symbol, relocate_instruction)
11327 (monitor_output): Move to remote-utils.h, and include it.
11328 * remote-utils.h: New file.
11330 2013-09-05 Pedro Alves <palves@redhat.com>
11332 * server.h (_): Delete.
11334 2013-09-02 Pedro Alves <palves@redhat.com>
11336 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
11337 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
11339 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
11341 2013-09-02 Pierre Muller <muller@sourceware.org>
11343 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
11344 or WriteProcessMemory complete successfully and handle
11345 ERROR_PARTIAL_COPY error.
11347 2013-09-02 Pedro Alves <palves@redhat.com>
11349 * server.c (gdb_read_memory): Return -1 on traceframe memory read
11350 error instead of EIO.
11352 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
11355 * linux-low.c: Include filestuff.h.
11356 (linux_create_inferior) <pid == 0>: Call close_most_fds.
11357 * lynx-low.c: Include filestuff.h.
11358 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
11359 * server.c: Include filestuff.h.
11360 (main): Call notice_open_fds.
11361 * spu-low.c: Include filestuff.h.
11362 (spu_create_inferior) <pid == 0>: Call close_most_fds.
11364 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
11366 * Makefile.in: Explain why ../target and ../nat are not
11367 listed as include file search paths.
11368 (linux-waitpid.o): New object file rule.
11369 * configure.srv (srv_native_linux_obj): New variable.
11370 Replace all occurrences of linux native object files with
11371 $srv_native_linux_obj.
11372 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
11373 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
11374 (linux_enable_event_reporting): Remove declaration.
11375 (my_waitpid): Moved to common/linux-waitpid.c.
11376 (linux_wait_for_event): Pass ptid when calling
11377 linux_enable_event_reporting.
11378 (linux_supports_tracefork_flag): Remove.
11379 (linux_enable_event_reporting): Likewise.
11380 (linux_tracefork_grandchild): Remove.
11381 (STACK_SIZE): Moved to common/linux-ptrace.c.
11382 (linux_tracefork_child): Remove.
11383 (linux_test_for_tracefork): Remove.
11384 (linux_look_up_symbols): Call linux_supports_traceclone.
11385 (initialize_low): Remove call to linux_test_for_tracefork.
11386 * linux-low.h (PTRACE_TYPE_ARG3): Move to
11387 common/linux-ptrace.h.
11388 (PTRACE_TYPE_ARG4): Likewise.
11389 Include linux-ptrace.h.
11391 2013-08-21 Pedro Alves <palves@redhat.com>
11393 * config.in: Renegerate.
11395 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
11397 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
11398 (SFILES): Remove $(srcdir)/common/target-common.c and
11399 add $(srcdir)/target/waitstatus.c.
11400 (OBS): Remove target-common.o and add waitstatus.o.
11401 (server_h): Remove $(srcdir)/../common/target-common.h and
11402 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
11403 and $(srcdir)/../target/waitstatus.h.
11404 (target-common.o): Remove.
11405 (waitstatus.o): New target object file.
11406 * target.h: Do not include target-common.h and
11407 include target/resume.h, target/wait.h and
11408 target/waitstatus.h.
11410 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
11412 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
11413 to PTRACE_TYPE_ARG3.
11414 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
11415 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
11417 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
11418 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
11420 2013-07-27 Jie Zhang <jie@codesourcery.com>
11421 Daniel Jacobowitz <dan@codesourcery.com>
11422 Yao Qi <yao@codesourcery.com>
11424 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
11425 (mips-linux-watch.o): New rule.
11426 (mips_linux_watch_h): New variable.
11427 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
11429 * linux-mips-low.c: Include mips-linux-watch.h.
11430 (struct arch_process_info, struct arch_lwp_info): New.
11431 (update_watch_registers_callback): New function.
11432 (mips_linux_new_process, mips_linux_new_thread) New functions.
11433 (mips_linux_prepare_to_resume, mips_insert_point): New
11435 (mips_remove_point, mips_stopped_by_watchpoint): New
11437 (rsp_bp_type_to_target_hw_bp_type): New function.
11438 (mips_stopped_data_address): New function.
11439 (the_low_target): Add watchpoint support functions.
11441 2013-07-27 Yao Qi <yao@codesourcery.com>
11443 * i386-low.c: Include break-common.h.
11444 (enum target_hw_bp_type): Remove.
11446 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
11448 * Makefile.in (SFILES): /common/target-common.c.
11449 (OBS): Add target-common.o.
11450 (server_h): Add $(srcdir)/../common/target-common.h.
11451 (target-common.o): New target.
11452 * server.c (queue_stop_reply_callback): Free
11453 status string after use.
11454 * target.c (target_waitstatus_to_string): Remove.
11455 * target.h: Include target-common.h.
11456 (resume_kind): Likewise.
11457 (target_waitkind): Likewise.
11458 (target_waitstatus): Likewise.
11459 (TARGET_WNOHANG): Likewise.
11461 2013-07-04 Yao Qi <yao@codesourcery.com>
11463 * Makefile.in (host_alias): Use @host_noncanonical@.
11464 (target_alias): Use @target_noncanonical@.
11465 * configure.ac: Use ACX_NONCANONICAL_TARGET and
11466 ACX_NONCANONICAL_HOST.
11467 * configure: Regenerated.
11470 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
11472 * configure.ac (version_host, version_target): Set and AC_SUBST them.
11473 * configure: Rebuild.
11474 * Makefile.in (version_host, version_target): Get from configure.
11475 (version.c): Use $(version_host) and $(version_target).
11477 2013-07-03 Pedro Alves <palves@redhat.com>
11479 * Makefile.in (config.status): Depend on development.sh.
11480 * acinclude.m4: Include libmcheck.m4.
11481 * configure: Regenerate.
11483 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
11485 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
11486 attribute inside the parentheses.
11487 (winapi_DebugSetProcessKillOnExit): Ditto.
11488 (winapi_DebugBreakProcess): Ditto.
11489 (winapi_GenerateConsoleCtrlEvent): Ditto.
11491 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
11493 * notif.h (notif_event): Add a dummy member to avoid compiler
11496 2013-07-01 Pedro Alves <palves@redhat.com>
11498 * hostio.c (HOSTIO_PATH_MAX): Define.
11499 (require_filename, handle_open, handle_unlink, handle_readlink):
11502 2013-07-01 Pedro Alves <palves@redhat.com>
11504 * server.h: Include "pathmax.h".
11505 * linux-low.c: Don't include sys/param.h.
11506 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
11508 * win32-low.c: Don't include sys/param.h.
11509 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
11511 2013-07-01 Pedro Alves <palves@redhat.com>
11513 * event-loop.c: Don't check HAVE_UNISTD_H before including
11515 * gdbreplay.c: Likewise.
11516 * remote-utils.c: Likewise.
11517 * server.c: Likewise.
11518 * configure.ac: Don't check for unistd.h.
11519 * configure: Regenerate.
11521 2013-06-28 Tom Tromey <tromey@redhat.com>
11523 * Makefile.in (version.c): Use version.in, not
11526 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
11528 * configure.ac (version_host, version_target): Set and AC_SUBST them.
11529 * configure: Rebuild.
11530 * Makefile.in (version_host, version_target): Get from configure.
11531 (version.c): Use $(version_host) and $(version_target).
11533 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
11535 Fix trace-status to output user name without trailing colon.
11536 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
11538 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
11540 Fix trace-status to output proper start-time and stop-time.
11541 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
11542 output start time and stop time in hex as gdb expects.
11544 2013-06-26 Pedro Alves <pedro@codesourcery.com>
11546 * tracepoint.c (build_traceframe_info_xml): Output trace state
11547 variables present in the trace buffer.
11549 2013-06-24 Tom Tromey <tromey@redhat.com>
11551 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
11553 (version.o): Remove.
11554 * gdbreplay.c: Include version.h.
11555 (version, host_name): Don't declare.
11556 * server.h: Include version.h.
11557 (version, host_name): Don't declare.
11559 2013-06-12 Pedro Alves <palves@redhat.com>
11561 * linux-x86-low.c (linux_is_elf64): Delete global.
11562 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
11563 with local linux_pid_exe_is_elf_64_file use.
11565 2013-06-11 Pedro Alves <palves@redhat.com>
11567 * linux-low.c (regset_disabled, disable_regset): New functions.
11568 (regsets_fetch_inferior_registers)
11569 (regsets_store_inferior_registers): Use them.
11570 (initialize_regsets_info); Don't allocate the disabled_regsets
11572 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
11575 2013-06-11 Pedro Alves <palves@redhat.com>
11577 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
11580 2013-06-11 Pedro Alves <palves@redhat.com>
11582 * linux-x86-low.c (initialize_low_arch): Call
11583 init_registers_x32_avx_linux.
11585 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
11587 Fix compatibility with Android Bionic.
11588 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
11591 2013-06-07 Pedro Alves <palves@redhat.com>
11594 * Makefile.in (OBS): Add tdesc.o.
11595 (IPA_OBJS): Add tdesc-ipa.o.
11596 (tdesc-ipa.o): New rule.
11597 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
11599 * linux-low.c (new_inferior): Delete.
11600 (disabled_regsets, num_regsets): Delete.
11601 (linux_add_process): Adjust to set the new per-process
11603 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
11604 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
11605 was a stop. When calling arch_setup, switch the current inferior
11606 to the thread that got an event.
11607 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
11608 (regsets_fetch_inferior_registers)
11609 (regsets_store_inferior_registers): New regsets_info parameter.
11611 (linux_register_in_regsets): New regs_info parameter. Adjust to
11613 (register_addr, fetch_register, store_register): New usrregs_info
11614 parameter. Adjust to use it.
11615 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
11616 parameter regs_info. Adjust to use it.
11617 (linux_fetch_registers): Get the current inferior's regs_info, and
11619 (linux_store_registers): Ditto.
11620 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
11621 (initialize_low): Don't initialize the target_regsets here. Call
11622 initialize_low_arch.
11623 * linux-low.h (target_regsets): Delete declaration.
11624 (struct regsets_info): New.
11625 (struct usrregs_info): New.
11626 (struct regs_info): New.
11627 (struct process_info_private) <new_inferior>: New field.
11628 (struct linux_target_ops): Delete the num_regs, regmap, and
11629 regset_bitmap fields. New field regs_info.
11630 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
11631 * i387-fp.c (num_xmm_registers): Delete.
11632 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
11633 calls to new interface.
11634 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
11635 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
11636 Infer the number of xmm registers from the regcache's target
11638 * i387-fp.h (num_xmm_registers): Delete.
11639 * inferiors.c (add_thread): Don't install the thread's regcache
11641 * proc-service.c (gregset_info): Fetch the current inferior's
11642 regs_info. Adjust to use it.
11643 * regcache.c: Include tdesc.h.
11644 (register_bytes, reg_defs, num_registers)
11645 (gdbserver_expedite_regs): Delete.
11646 (get_thread_regcache): If the thread doesn't have a regcache yet,
11647 create one, instead of aborting gdbserver.
11648 (regcache_invalidate_one): Rename to ...
11649 (regcache_invalidate_thread): ... this.
11650 (regcache_invalidate_one): New.
11651 (regcache_invalidate): Only invalidate registers of the current
11653 (init_register_cache): Add target_desc parameter, and use it.
11654 (new_register_cache): Ditto. Assert the target description has a
11655 non zero registers_size.
11656 (regcache_cpy): Add assertions. Adjust.
11657 (realloc_register_cache, set_register_cache): Delete.
11658 (registers_to_string, registers_from_string): Adjust.
11659 (find_register_by_name, find_regno, find_register_by_number)
11660 (register_cache_size): Add target_desc parameter, and use it.
11661 (free_register_cache_thread, free_register_cache_thread_one)
11662 (regcache_release, register_cache_size): New.
11663 (register_size): Add target_desc parameter, and use it.
11664 (register_data, supply_register, supply_register_zeroed)
11665 (supply_regblock, supply_register_by_name, collect_register)
11666 (collect_register_as_string, collect_register_by_name): Adjust.
11667 * regcache.h (struct target_desc): Forward declare.
11668 (struct regcache) <tdesc>: New field.
11669 (init_register_cache, new_register_cache): Add target_desc
11671 (regcache_invalidate_thread): Declare.
11672 (regcache_invalidate_one): Delete declaration.
11673 (regcache_release): Declare.
11674 (find_register_by_number, register_cache_size, register_size)
11675 (find_regno): Add target_desc parameter.
11676 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
11678 * remote-utils.c: Include tdesc.h.
11679 (outreg, prepare_resume_reply): Adjust.
11680 * server.c: Include tdesc.h.
11681 (gdbserver_xmltarget): Delete declaration.
11682 (get_features_xml, process_serial_event): Adjust.
11683 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
11685 (struct process_info) <tdesc>: New field.
11686 (ipa_tdesc): Declare.
11687 * tdesc.c: New file.
11688 * tdesc.h: New file.
11689 * tracepoint.c: Include tdesc.h.
11690 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
11691 (get_context_regcache): Adjust to pass ipa_tdesc down.
11692 (do_action_at_tracepoint): Adjust to get the register cache size
11693 from the context regcache's description.
11694 (traceframe_walk_blocks): Adjust to get the register cache size
11695 from the current trace frame's description.
11696 (traceframe_get_pc): Adjust to get current trace frame's
11697 description and pass it down.
11698 (gdb_collect): Adjust to get the register cache size from the
11700 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
11701 (gdbserver_xmltarget): Delete.
11702 (initialize_low_tracepoint): Set the ipa's target description.
11703 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
11704 (initialize_low_tracepoint): Set the ipa's target description.
11705 * linux-x86-low.c: Include tdesc.h.
11706 [__x86_64__] (is_64bit_tdesc): New.
11707 (ps_get_thread_area, x86_get_thread_area): Use it.
11708 (i386_cannot_store_register): Rename to ...
11709 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
11710 (i386_cannot_fetch_register): Rename to ...
11711 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
11712 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
11714 (target_regsets): Rename to ...
11715 (x86_regsets): ... this.
11716 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
11718 (x86_siginfo_fixup): Use is_64bit_tdesc.
11719 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
11720 (tdesc_x32_avx_linux, tdesc_x32_linux)
11721 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
11723 (x86_linux_update_xmltarget): Delete.
11724 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
11725 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
11726 (AMD64_LINUX_USER64_CS): New.
11727 (x86_linux_read_description): New, based on
11728 x86_linux_update_xmltarget.
11729 (same_process_callback): New.
11730 (x86_arch_setup_process_callback): New.
11731 (x86_linux_update_xmltarget): New.
11732 (x86_regsets_info): New.
11733 (amd64_linux_regs_info): New.
11734 (i386_linux_usrregs_info): New.
11735 (i386_linux_regs_info): New.
11736 (x86_linux_regs_info): New.
11737 (x86_arch_setup): Reimplement.
11738 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
11739 (x86_emit_ops): Ditto.
11740 (the_low_target): Adjust. Install x86_linux_regs_info,
11741 x86_cannot_fetch_register, and x86_cannot_store_register.
11742 (initialize_low_arch): New.
11743 * linux-ia64-low.c (tdesc_ia64): Declare.
11744 (ia64_fetch_register): Adjust.
11745 (ia64_usrregs_info, regs_info): New globals.
11746 (ia64_regs_info): New function.
11747 (the_low_target): Adjust.
11748 (initialize_low_arch): New function.
11749 * linux-sparc-low.c (tdesc_sparc64): Declare.
11750 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
11752 (sparc_arch_setup): New function.
11753 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
11754 (the_low_target): Adjust.
11755 (initialize_low_arch): New function.
11756 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
11757 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
11758 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
11759 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
11760 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
11761 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
11762 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
11763 (tdesc_powerpc_isa205_vsx64l): Declare.
11764 (ppc_cannot_store_register, ppc_collect_ptrace_register)
11765 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
11766 (ppc_set_pc, ppc_get_hwcap): Adjust.
11767 (ppc_usrregs_info): Forward declare.
11768 (!__powerpc64__) ppc_regmap_adjusted: New global.
11769 (ppc_arch_setup): Adjust to the current process'es target
11771 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
11772 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
11773 (ppc_store_evrregset): Adjust.
11774 (target_regsets): Rename to ...
11775 (ppc_regsets): ... this, and make static.
11776 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
11777 (ppc_regs_info): New function.
11778 (the_low_target): Adjust.
11779 (initialize_low_arch): New function.
11780 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
11781 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
11782 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
11783 (tdesc_s390x_linux64v2): Declare.
11784 (s390_collect_ptrace_register, s390_supply_ptrace_register)
11785 (s390_fill_gregset, s390_store_last_break): Adjust.
11786 (target_regsets): Rename to ...
11787 (s390_regsets): ... this, and make static.
11788 (s390_get_pc, s390_set_pc): Adjust.
11789 (s390_get_hwcap): New target_desc parameter, and use it.
11790 [__s390x__] (have_hwcap_s390_high_gprs): New global.
11791 (s390_arch_setup): Adjust to set the current process'es target
11792 description. Don't adjust the regmap.
11793 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
11794 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
11795 (regs_info_3264): New globals.
11796 (s390_regs_info): New function.
11797 (the_low_target): Adjust.
11798 (initialize_low_arch): New function.
11799 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
11800 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
11801 [__mips64] (init_registers_mips_linux)
11802 (init_registers_mips_dsp_linux): Delete defines.
11803 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
11804 (have_dsp): New global.
11805 (mips_read_description): New, based on mips_arch_setup.
11806 (mips_arch_setup): Reimplement.
11807 (get_usrregs_info): New function.
11808 (mips_cannot_fetch_register, mips_cannot_store_register)
11809 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
11810 (mips_fill_fpregset, mips_store_fpregset): Adjust.
11811 (target_regsets): Rename to ...
11812 (mips_regsets): ... this, and make static.
11813 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
11814 (dsp_regs_info, regs_info): New globals.
11815 (mips_regs_info): New function.
11816 (the_low_target): Adjust.
11817 (initialize_low_arch): New function.
11818 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
11819 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
11821 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
11822 (arm_read_description): New, with bits factored from
11824 (arm_arch_setup): Reimplement.
11825 (target_regsets): Rename to ...
11826 (arm_regsets): ... this, and make static.
11827 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
11828 (arm_regs_info): New function.
11829 (the_low_target): Adjust.
11830 (initialize_low_arch): New function.
11831 * linux-m68k-low.c (tdesc_m68k): Declare.
11832 (target_regsets): Rename to ...
11833 (m68k_regsets): ... this, and make static.
11834 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
11835 (m68k_regs_info): New function.
11836 (m68k_arch_setup): New function.
11837 (the_low_target): Adjust.
11838 (initialize_low_arch): New function.
11839 * linux-sh-low.c (tdesc_sharch): Declare.
11840 (target_regsets): Rename to ...
11841 (sh_regsets): ... this, and make static.
11842 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
11843 (sh_regs_info, sh_arch_setup): New functions.
11844 (the_low_target): Adjust.
11845 (initialize_low_arch): New function.
11846 * linux-bfin-low.c (tdesc_bfin): Declare.
11847 (bfin_arch_setup): New function.
11848 (bfin_usrregs_info, regs_info): New globals.
11849 (bfin_regs_info): New function.
11850 (the_low_target): Adjust.
11851 (initialize_low_arch): New function.
11852 * linux-cris-low.c (tdesc_cris): Declare.
11853 (cris_arch_setup): New function.
11854 (cris_usrregs_info, regs_info): New globals.
11855 (cris_regs_info): New function.
11856 (the_low_target): Adjust.
11857 (initialize_low_arch): New function.
11858 * linux-cris-low.c (tdesc_crisv32): Declare.
11859 (cris_arch_setup): New function.
11860 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
11861 (cris_regs_info): New function.
11862 (the_low_target): Adjust.
11863 (initialize_low_arch): New function.
11864 * linux-m32r-low.c (tdesc_m32r): Declare.
11865 (m32r_arch_setup): New function.
11866 (m32r_usrregs_info, regs_info): New globals.
11867 (m32r_regs_info): Adjust.
11868 (initialize_low_arch): New function.
11869 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
11870 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
11871 (tic6x_usrregs_info): Forward declare.
11872 (tic6x_read_description): New function, based on ...
11873 (tic6x_arch_setup): ... this. Reimplement.
11874 (target_regsets): Rename to ...
11875 (tic6x_regsets): ... this, and make static.
11876 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
11877 (tic6x_regs_info): New function.
11878 (the_low_target): Adjust.
11879 (initialize_low_arch): New function.
11880 * linux-xtensa-low.c (tdesc_xtensa): Declare.
11881 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
11882 (target_regsets): Rename to ...
11883 (xtensa_regsets): ... this, and make static.
11884 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
11886 (xtensa_arch_setup, xtensa_regs_info): New functions.
11887 (the_low_target): Adjust.
11888 (initialize_low_arch): New function.
11889 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
11890 (nios2_arch_setup): Set the current process'es tdesc.
11891 (target_regsets): Rename to ...
11892 (nios2_regsets): ... this.
11893 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
11894 (nios2_regs_info): New function.
11895 (the_low_target): Adjust.
11896 (initialize_low_arch): New function.
11897 * linux-aarch64-low.c (tdesc_aarch64): Declare.
11898 (aarch64_arch_setup): Set the current process'es tdesc.
11899 (target_regsets): Rename to ...
11900 (aarch64_regsets): ... this.
11901 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
11902 (aarch64_regs_info): New function.
11903 (the_low_target): Adjust.
11904 (initialize_low_arch): New function.
11905 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
11907 (target_regsets): Rename to ...
11908 (tile_regsets): ... this.
11909 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
11910 (tile_regs_info): New function.
11911 (tile_arch_setup): Set the current process'es tdesc.
11912 (the_low_target): Adjust.
11913 (initialize_low_arch): New function.
11914 * spu-low.c (tdesc_spu): Declare.
11915 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
11916 * win32-arm-low.c (tdesc_arm): Declare.
11917 (arm_arch_setup): New function.
11918 (the_low_target): Install arm_arch_setup instead of
11919 init_registers_arm.
11920 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
11921 (init_windows_x86): Rename to ...
11922 (i386_arch_setup): ... this. Set `win32_tdesc'.
11923 (the_low_target): Adjust.
11924 * win32-low.c (win32_tdesc): New global.
11925 (child_add_thread): Don't create the thread cache here.
11926 (do_initial_child_stuff): Set the new process'es tdesc.
11927 * win32-low.h (struct target_desc): Forward declare.
11928 (win32_tdesc): Declare.
11929 * lynx-i386-low.c (tdesc_i386): Declare global.
11930 (lynx_i386_arch_setup): Set `lynx_tdesc'.
11931 * lynx-low.c (lynx_tdesc): New global.
11932 (lynx_add_process): Set the new process'es tdesc.
11933 * lynx-low.h (struct target_desc): Forward declare.
11934 (lynx_tdesc): Declare global.
11935 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
11936 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
11937 * nto-low.c (nto_tdesc): New global.
11938 (do_attach): Set the new process'es tdesc.
11939 * nto-low.h (struct target_desc): Forward declare.
11940 (nto_tdesc): Declare.
11941 * nto-x86-low.c (tdesc_i386): Declare.
11942 (nto_x86_arch_setup): Set `nto_tdesc'.
11944 2013-06-04 Gary Benson <gbenson@redhat.com>
11946 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
11947 to qSupported response when appropriate.
11948 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
11949 with nonzero-length annex.
11950 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
11951 arguments supplied in annex.
11953 2013-05-31 Doug Evans <dje@google.com>
11956 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
11957 64 bits in 64-cross-32 environment.
11959 2013-05-28 Pedro Alves <palves@redhat.com>
11961 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
11962 (aarch64-without-fpu.c): Delete rule.
11963 * configure.srv (aarch64*-*-linux*): Remove references to
11964 aarch64-without-fpu.o and aarch64-without-fpu.xml.
11965 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
11968 2013-05-24 Pedro Alves <palves@redhat.com>
11970 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
11971 instead of strchr/decode_address. Error if the range isn't split
11972 with a ','. Don't assume there's be a ':' in the action.
11974 2013-05-23 Yao Qi <yao@codesourcery.com>
11975 Pedro Alves <palves@redhat.com>
11977 * linux-low.c (lwp_in_step_range): New function.
11978 (linux_wait_1): If the thread was range stepping and stopped
11979 outside the stepping range, report the stop to GDB. Otherwise,
11980 continue stepping. Add range stepping debug output.
11981 (linux_set_resume_request): Copy the step range from the resume
11982 request to the lwp.
11983 (linux_supports_range_stepping): New.
11984 (linux_target_ops) <supports_range_stepping>: Set to
11985 linux_supports_range_stepping.
11986 * linux-low.h (struct linux_target_ops)
11987 <supports_range_stepping>: New field.
11988 (struct lwp_info) <step_range_start, step_range_end>: New fields.
11989 * linux-x86-low.c (x86_supports_range_stepping): New.
11990 (the_low_target) <supports_range_stepping>: Set to
11991 x86_supports_range_stepping.
11992 * server.c (handle_v_cont): Handle 'r' action.
11993 (handle_v_requests): Append ";r" if the target supports range
11995 * target.h (struct thread_resume) <step_range_start,
11996 step_range_end>: New fields.
11997 (struct target_ops) <supports_range_stepping>:
11999 (target_supports_range_stepping): New macro.
12001 2013-05-17 Joel Brobecker <brobecker@adacore.com>
12003 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
12004 confusion in comment.
12006 2013-05-17 Joel Brobecker <brobecker@adacore.com>
12008 * lynx-low.c (struct process_info_private): New type.
12009 (lynx_add_process): New function.
12010 (lynx_create_inferior, lynx_attach): Replace calls to
12011 add_process by calls to lynx_add_process.
12012 (lynx_resume): If PTID is null, then try using
12013 current_process()->private->last_wait_event_ptid.
12015 (lynx_clear_inferiors): Delete. The contents of that function
12016 has been inlined in lynx_mourn;
12017 (lynx_wait_1): Save the ptid in the process's private data.
12018 (lynx_mourn): Free the process' private data. Replace call
12019 to lynx_clear_inferiors by call to clear_inferiors.
12021 2013-05-17 Yao Qi <yao@codesourcery.com>
12023 * i386-low.c (i386_length_and_rw_bits): Move the comment to
12026 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
12028 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
12029 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
12030 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
12031 PT_TEXT_END_ADDR guards. Update comments.
12032 (linux_target_op) <read_offsets>: Conditionally define to
12033 linux_read_offsets if the target is UCLIBC and if it defines
12034 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
12036 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
12037 Andrew Jenner <andrew@codesourcery.com>
12039 * Makefile.in (SFILES): Add linux-nios2-low.c.
12040 (clean): Add action to delete nios2-linux.c.
12041 (nios2-linux.c): New rule.
12042 * configure.srv: Add nios2*-*-linux*.
12043 * linux-nios2-low.c: New.
12045 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
12047 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
12049 2013-04-25 Hui Zhu <hui@codesourcery.com>
12052 * ax.c (ax_printf): Add fflush.
12054 2013-04-22 Tom Tromey <tromey@redhat.com>
12056 * Makefile.in (SFILES): Add filestuff.c.
12057 (OBS): Add filestuff.o.
12058 (filestuff.o): New target.
12059 * config.in, configure: Rebuild.
12060 * configure.ac: Check for fdwalk, pipe2.
12062 2013-04-17 Pedro Alves <palves@redhat.com>
12064 * configure.ac (USE_THREAD_DB): Delete variable.
12065 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
12066 Don't AC_SUBST USE_THREAD_DB.
12067 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
12068 * config.in, configure: Regenerate.
12070 2013-04-16 Pedro Alves <palves@redhat.com>
12072 * linux-low.h (struct lwp_info) <thread_known>: Move under
12073 the USE_THREAD_DB #ifdef.
12075 2013-04-16 Pedro Alves <palves@redhat.com>
12077 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
12078 (linux-low.o): Delete rule.
12079 * linux-low.h: Always include "gdb_thread_db.h" instead of
12080 conditionally including thread_db.h.
12081 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
12084 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
12086 * Makefile.in (install-only): Fix make install regression.
12088 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
12090 Convert man pages to texinfo, new gdbinit.5 texinfo page.
12091 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
12093 * gdbserver.1: Remove.
12095 2013-03-22 Pedro Alves <palves@redhat.com>
12097 * linux-low.c (handle_extended_wait): Don't call
12098 linux_enable_event_reporting.
12100 2013-03-15 Tony Theodore <tonyt@logyst.com>
12103 * Makefile.in (SHELL): Use @SHELL@.
12105 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
12107 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
12110 2013-03-13 Joel Brobecker <brobecker@adacore.com>
12112 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
12113 Remove extraneous NULL element.
12115 2013-03-13 Yao Qi <yao@codesourcery.com>
12117 * tracepoint.c (traceframe_read_tsv): Look for the last matched
12118 'V' block in trace frame.
12120 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
12122 * target.h (struct target_ops): Add btrace ops.
12123 (target_supports_btrace): New macro.
12124 (target_enable_btrace): New macro.
12125 (target_disable_btrace): New macro.
12126 (target_read_btrace): New macro.
12127 * gdbthread.h (struct thread_info): Add btrace field.
12128 * server.c: Include btrace-common.h.
12129 (handle_btrace_general_set): New function.
12130 (handle_btrace_enable): New function.
12131 (handle_btrace_disable): New function.
12132 (handle_general_set): Call handle_btrace_general_set.
12133 (handle_qxfer_btrace): New function.
12134 (struct qxfer qxfer_packets[]): Add btrace entry.
12135 * inferiors.c (remove_thread): Disable btrace.
12136 * linux-low: Include linux-btrace.h.
12137 (linux_low_enable_btrace): New function.
12138 (linux_low_read_btrace): New function.
12139 (linux_target_ops): Add btrace ops.
12140 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
12141 Add srv_linux_btrace=yes.
12142 (x86_64-*-linux*): Add linux-btrace.o.
12143 Add srv_linux_btrace=yes.
12144 * configure.ac: Define HAVE_LINUX_BTRACE.
12145 * config.in: Regenerated.
12146 * configure: Regenerated.
12148 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
12150 * server.c (handle_qxfer): Preserve error message if -3 is
12152 (qxfer): Document the -3 return value.
12154 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
12156 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
12157 (linux_btrace_h): New variable.
12158 (linux-btrace.o): New rule.
12160 2013-03-08 Stan Shebs <stan@codesourcery.com>
12161 Hafiz Abid Qadeer <abidh@codesourcery.com>
12163 * tracepoint.c (trace_buffer_size): New global.
12164 (DEFAULT_TRACE_BUFFER_SIZE): New define.
12165 (init_trace_buffer): Change to one-argument function. Allocate
12166 trace buffer memory.
12167 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
12168 handle QTBuffer:size packet.
12169 (cmd_bigqtbuffer_size): New function.
12170 (initialize_tracepoint): Call init_trace_buffer with
12171 DEFAULT_TRACE_BUFFER_SIZE.
12172 * server.c (handle_query): Add QTBuffer:size in the
12175 2013-03-07 Yao Qi <yao@codesourcery.com>
12177 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
12178 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
12180 (cmd_qtsp): Adjust condition. Do post increment.
12181 Set cur_action and cur_step_action back to 0.
12183 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
12186 * linux-low.c (linux_write_memory): Return early success if LEN is
12189 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
12191 * configure.srv: Add x86_64-*-cygwin* as target.
12193 2013-02-28 Tom Tromey <tromey@redhat.com>
12195 * configure.ac: Invoke AC_SYS_LARGEFILE.
12196 * configure, config.in: Rebuild.
12198 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
12200 * win32-low.c: Throughout, fix format strings and casts of
12201 printf-like functions to avoid type related warnings on all
12203 (get_child_debug_event): Print dwDebugEventCode as hex since
12204 that's how it's usually documented.
12206 2013-02-28 Yao Qi <yao@codesourcery.com>
12208 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
12211 2013-02-27 Jiong Wang <jiwang@tilera.com>
12213 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
12214 (reg-tilegx32.c): New rule.
12215 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
12216 * linux-tile-low.c (tile_arch_setup): New function. Invoke
12217 different register info initializer according to elf class.
12218 (init_registers_tilgx32): New function. The tilegx32 register info
12220 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
12221 (tile_store_gregset): Likewise.
12223 2013-02-27 Yao Qi <yao@codesourcery.com>
12225 * server.c (process_point_options): Print debug message when
12226 debug_threads is true.
12228 2013-02-26 Yao Qi <yao@codesourcery.com>
12230 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
12232 2013-02-19 Pedro Alves <palves@redhat.com>
12233 Kai Tietz <ktietz@redhat.com>
12237 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
12238 instead of strtoul to extract address from packet.
12239 (process_serial_event) <'z'>: Likewise.
12241 2013-02-18 Yao Qi <yao@codesourcery.com>
12243 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
12245 2013-02-14 Pedro Alves <palves@redhat.com>
12249 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
12250 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
12252 2013-02-14 Pedro Alves <palves@redhat.com>
12254 * tracepoint.c (cmd_qtdpsrc): Use savestring.
12256 2013-02-14 Pedro Alves <palves@redhat.com>
12258 * tracepoint.c (save_string): Delete.
12259 (add_tracepoint_action): Use savestring instead of save_string.
12261 2013-02-12 Pedro Alves <palves@redhat.com>
12263 * linux-xtensa-low.c: Ditto.
12264 * xtensa-xtregs.c: Ditto.
12266 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
12268 * thread-db.c (thread_db_get_tls_address): NULL pointer check
12271 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
12273 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
12274 aarch64_num_wp_regs and aarch64_num_bp_regs to
12275 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
12277 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
12279 * linux-aarch64-low.c (ps_get_thread_area): Replace
12280 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
12282 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
12283 Marcus Shawcroft <marcus.shawcroft@arm.com>
12284 Nigel Stephens <nigel.stephens@arm.com>
12285 Yufeng Zhang <yufeng.zhang@arm.com>
12287 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
12288 (aarch64.c, aarch64-without-fpu.c): New targets.
12289 * configure.srv (aarch64*-*-linux*): New.
12290 * linux-aarch64-low.c: New file.
12292 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
12294 * linux-low.c (handle_extended_wait, linux_create_inferior)
12295 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
12296 (dequeue_one_deferred_signal, linux_resume_one_thread)
12297 (fetch_register, linux_write_memory, linux_enable_event_reporting)
12298 (linux_tracefork_grandchild, linux_test_for_tracefork)
12299 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
12300 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
12301 where the argument is 0.
12303 2013-01-25 Yao Qi <yao@codesourcery.com>
12305 * event-loop.c: Include "queue.h".
12306 (gdb_event_p): New typedef.
12307 (struct gdb_event) <next_event>: Remove.
12308 (event_queue): Change to QUEUE(gdb_event_p).
12309 (async_queue_event): Remove.
12310 (gdb_event_xfree): New.
12311 (initialize_event_loop): New.
12312 (process_event): Use API from QUEUE.
12313 (wait_for_event): Likewise.
12314 * server.c (main): Call initialize_event_loop.
12315 * server.h (initialize_event_loop): Declare.
12317 2013-01-18 Yao Qi <yao@codesourcery.com>
12319 * ax.h (struct eval_agent_expr_context): New.
12320 (gdb_eval_agent_expr): Update declaration.
12321 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
12322 TFRAME. Add new argument CTX.
12323 * server.h (struct eval_agent_expr_context): Declare.
12324 (agent_mem_read, agent_tsv_read): Update declaration.
12325 (agent_mem_read_string): Likewise.
12326 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
12327 (add_traceframe_block): Add new argument TPOINT.
12328 Increase TPOINT->traceframe_usage.
12329 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
12330 eval_tracepoint_agent_expr.
12331 (condition_true_at_tracepoint): Likewise.
12332 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
12333 (agent_mem_read_string, agent_tsv_read): Likewise.
12335 2013-01-16 Yao Qi <yao@codesourcery.com>
12337 * linux-low.c (linux_resume_one_lwp): Don't check
12338 'lwp->bp_reinsert != 0'.
12340 2013-01-07 Joel Brobecker <brobecker@adacore.com>
12341 Pedro Alves <palves@redhat.com>
12343 * lynx-low.c (ptrace_request_to_str): Define a temporary
12344 macro and use it to simplify this function's implementation.
12346 2013-01-07 Joel Brobecker <brobecker@adacore.com>
12348 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
12351 2013-01-07 Joel Brobecker <brobecker@adacore.com>
12353 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
12355 2013-01-07 Joel Brobecker <brobecker@adacore.com>
12357 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
12359 2013-01-07 Joel Brobecker <brobecker@adacore.com>
12361 * lynx-low.c (lynx_resume): Use the resume_info parameter
12362 to determine the ptid for the lynx_ptrace call, unless
12363 it is equal to minus_one_ptid, in which case we use the
12364 ptid of the current_inferior.
12365 (lynx_wait_1): After having received a thread create/exit
12366 event, resume the inferior's execution using the signaling
12367 thread's ptid, rather than the old ptid.
12369 2013-01-07 Joel Brobecker <brobecker@adacore.com>
12371 * lynx-low.c (lynx_resume): Delete variable ret.
12373 2013-01-01 Joel Brobecker <brobecker@adacore.com>
12375 * gdbreplay.c (gdbreplay_version): Update copyright year.
12376 * server.c (gdbserver_version): Likewise.
12378 2012-12-17 Joel Brobecker <brobecker@adacore.com>
12380 * lynx-low.c (lynx_wait_1): Add debug trace before adding
12383 2012-12-17 Joel Brobecker <brobecker@adacore.com>
12385 * lynx-low.c (ptrace_request_to_str): Add handling for
12386 PTRACE_GETTRACESIG.
12388 2012-12-17 Joel Brobecker <brobecker@adacore.com>
12390 * lynx-low.c (lynx_attach): Delete variable new_process.
12392 2012-12-17 Joel Brobecker <brobecker@adacore.com>
12394 * lynx-low.c (lynx_create_inferior): Delete variable
12397 2012-12-17 Joel Brobecker <brobecker@adacore.com>
12399 * lynx-low.c (ptrace_request_to_str): Do not handle
12400 PTRACE_GETTHREADLIST if this macro does not exist.
12402 2012-12-15 Yao Qi <yao@codesourcery.com>
12404 * Makefile.in (OBS): Add notif.o.
12405 * notif.c, notif.h: New.
12406 * server.c: Include "notif.h".
12407 (struct vstop_notif) <next>: Remove.
12409 (queue_stop_reply): Update.
12410 (push_event, send_next_stop_reply): Remove.
12411 (discard_queued_stop_replies): Update.
12412 (notif_stop): New variable.
12413 (handle_v_stopped): Remove.
12414 (handle_v_requests): Don't call handle_v_stopped. Call
12415 handle_ack_notif instead.
12416 (queue_stop_reply_callback): Call notif_event_enque instead
12417 of queue_stop_reply.
12418 (handle_status): Don't call send_next_stop_reply, call
12419 notif_write_event instead.
12420 (kill_inferior_callback): Likewise.
12421 (detach_or_kill_inferior_callback): Likewise.
12422 (main): Call initialize_notif.
12423 (process_serial_event): Call QUEUE_is_empty.
12424 (handle_target_event): Call notif_push instead of push event.
12425 * server.h (push_event): Remove declaration.
12427 2012-12-10 Tom Tromey <tromey@redhat.com>
12429 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
12430 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
12433 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
12434 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
12435 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
12436 (amd64-linux-ipa.o, ax.o): Rewrite.
12437 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
12438 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
12439 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
12440 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
12441 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
12442 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
12443 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
12444 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
12445 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
12446 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
12447 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
12448 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
12449 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
12450 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
12451 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
12452 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
12453 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
12454 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
12455 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
12456 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
12457 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
12458 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
12459 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
12460 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
12461 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
12462 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
12463 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
12464 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
12465 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
12466 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
12467 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
12468 (reg-tilegx.o): Remove.
12469 (all_object_files): New macro.
12470 Include .deps files.
12471 * aclocal.m4, configure: Rebuild.
12472 * acinclude.m4: Include depstand.m4, lead-dot.m4.
12473 * configure.ac: Invoke ZW_CREATE_DEPDIR,
12474 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
12476 2012-12-05 Tom Tromey <tromey@redhat.com>
12479 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
12481 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
12483 * configure.ac: Check for linux/perf_event.h.
12484 * config.in: Regenerated.
12485 * configure: Regenerated.
12487 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
12489 * hostio.c (handle_readlink): Decrease buffer size
12490 parameter passed to readlink by one byte.
12492 2012-11-26 Yao Qi <yao@codesourcery.com>
12494 * configure.ac (build_warnings): Append '-Wempty-body'.
12495 * configure: Regenerated.
12496 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
12499 2012-11-15 Pierre Muller <muller@sourceware.org>
12501 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
12502 * config.in: Regenerate.
12503 * configure: Regenerate.
12504 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
12505 Use "gdb_wait.h" header instead of <sys/wait.h> header.
12506 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
12507 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
12509 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
12510 instead of <sys/wait.h> header.
12511 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
12513 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
12515 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
12516 (various make rules): Remove -DGDBSERVER
12518 2012-11-09 Yao Qi <yao@codesourcery.com>
12520 * spu-low.c (current_ptid): Move it to ..
12521 * gdbthread.h: ... here. New.
12522 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
12523 * server.c (myresume, process_serial_event): Likewise.
12524 * thread-db.c (thread_db_find_new_threads): Likewise.
12525 * tracepoint.c (run_inferior_command): Likewise.
12527 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
12529 * server.c (handle_search_memory_1): Include access length in
12532 2012-09-05 Michael Brandt <michael.brandt@axis.com>
12534 * linux-crisv32-low.c: Fix compile errors.
12536 2012-09-04 Yao Qi <yao@codesourcery.com>
12538 * tracepoint.c (cmd_qtsv): Adjust debug message.
12539 Don't check CUR_TPOINT.
12541 2012-08-28 Yao Qi <yao@codesourcery.com>
12543 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
12544 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
12545 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
12546 Remove declarations of xmalloc, xreallloc, xstrdup and
12548 * Makefile.in (libiberty_h): New.
12549 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
12550 (linux-bfin-low.o): Append dependency 'libiberty.h'.
12552 2012-08-23 Yao Qi <yao@codesourcery.com>
12554 * server.h: Remove declaration of 'xsnprintf'.
12556 2012-08-22 Keith Seitz <keiths@redhat.com>
12558 * server.h: Include build-gnulib-gbserver/config.h.
12559 * gdbreplay.c: Likewise.
12561 2012-08-08 Doug Evans <dje@google.com>
12563 * Makefile.in (SFILES): Add gdb_vecs.c.
12564 (OBS): Add gdb_vecs.o.
12565 (gdb_vecs_h, host_defs_h): New variables.
12566 (thread-db.o): Add $(gdb_vecs_h) dependency.
12567 (gdb_vecs.o): New rule.
12568 * thread-db.c: #include "gdb_vecs.h".
12569 (thread_db_load_search): Use a vector to iterate over path elements.
12570 Handle text appearing after "$pdir".
12572 * configure.ac: Add check for strstr.
12573 * config.in: Regenerate.
12574 * configure: Regenerate.
12576 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
12578 * hostio.c (handle_pread): If pread fails, fall back to attempting
12580 (handle_pwrite): Likewise for pwrite.
12582 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
12584 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
12585 between unsupported TYPE and unimplementable ADDR/LEN combination.
12586 (arm_insert_point): Act on new return value.
12588 2012-07-31 Pedro Alves <palves@redhat.com>
12590 * server.c (process_point_options): Only skip tokens if we find
12591 one that is unrecognized. Don't treat 'X' specially while
12592 skipping unrecognized tokens.
12594 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
12596 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
12597 to 4-byte-align HW breakpoint addresses for Thumb.
12599 2012-07-27 Yao Qi <yao@codesourcery.com>
12603 * server.h: Declare gdb_agent_about_to_close.
12604 * target.c (kill_inferior): Include "agent.h".
12605 New. Send command 'kill'.
12606 * target.h (kill_inferior): Removed macro.
12607 * tracepoint.c (gdb_agent_about_to_close): New.
12608 (gdb_agent_helper_thread): Handle command 'close'.
12609 Wait endlessly until the inferior stops.
12610 Install gdb_agent_remove_socket to atexit hook.
12611 (agent_socket_name): New static variable.
12612 (gdb_agent_socket_init): Replace local variable 'name' with
12613 'agent_socket_name'.
12614 (gdb_agent_remove_socket): New.
12616 2012-07-27 Yao Qi <yao@codesourcery.com>
12618 * server.c (process_point_options): Stop at 'X' when parsing.
12620 2012-07-19 Michael Eager <eager@eagercon.com>
12622 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
12624 * linux-x86-low.c (x86_insert_point, x86_remove_point):
12625 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
12626 hardware breakpoint.
12628 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
12630 * gdbserver/linux-low.c (initialize_low): Call
12631 linux_ptrace_init_warnings.
12633 2012-07-02 Doug Evans <dje@google.com>
12635 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
12638 2012-07-02 Stan Shebs <stan@codesourcery.com>
12640 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
12641 (ax.o): Add it to build rule.
12643 (OBS): Add format.o.
12644 (IPA_OBS): Add format.o.
12645 * server.c (handle_query): Claim support for breakpoint commands.
12646 (process_point_options): Add command case.
12647 (process_serial_event): Leave running if there are printfs in
12649 * mem-break.h (any_persistent_commands): Declare.
12650 (add_breakpoint_commands): Declare.
12651 (gdb_no_commands_at_breakpoint): Declare.
12652 (run_breakpoint_commands): Declare.
12653 * mem-break.c (struct point_command_list): New struct.
12654 (struct breakpoint): New field command_list.
12655 (any_persistent_commands): New function.
12656 (add_commands_to_breakpoint): New function.
12657 (add_breakpoint_commands): New function.
12658 (gdb_no_commands_at_breakpoint): New function.
12659 (run_breakpoint_commands): New function.
12660 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
12662 * ax.c: Include format.h.
12663 (ax_printf): New function.
12664 (gdb_eval_agent_expr): Add printf opcode.
12666 2012-06-13 Yao Qi <yao@codesourcery.com>
12668 * server.c (start_inferior): Remove duplicated writes to fields
12669 'last_resume_kind' and 'last_status' of 'current_inferior'.
12671 2012-06-12 Yao Qi <yao@codesourcery.com>
12672 Pedro Alves <palves@redhat.com>
12674 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
12676 * server.c (handle_v_cont): Extend comment.
12678 2012-06-11 Yao Qi <yao@codesourcery.com>
12680 * linux-low.c (linux_attach): Add 'static'.
12682 2012-06-06 Yao Qi <yao@codesourcery.com>
12684 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
12686 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
12688 Fix gcc -flto compilation warning.
12689 * server.c (main): Make variable multi_mode and attach volatile.
12691 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
12693 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
12694 if the platform doesn't know about it.
12696 2012-05-30 Jeff Kenton <jkenton@tilera.com>
12698 * Makefile.in (SFILES): Add linux-tile-low.c.
12699 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
12700 * configure.srv: Handle tilegx-*-linux*.
12701 * linux-tile-low.c: New file.
12703 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12705 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
12707 2012-05-24 Pedro Alves <palves@redhat.com>
12711 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
12713 2012-05-24 Pedro Alves <palves@redhat.com>
12717 Replace target_signal with gdb_signal throughout.
12719 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
12721 * linux-low.c (linux_store_registers): Avoid the copying sequence
12722 when no data has been retrieved by ptrace.
12724 2012-05-22 Will Deacon <will.deacon@arm.com>
12726 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
12727 Include asm/ptrace.h.
12728 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
12731 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
12733 * linux-low.c (linux_store_registers): Don't re-retrieve data
12734 with ptrace that has already been obtained from /proc. Always
12735 copy any data retrieved with ptrace to the buffer supplied.
12737 2012-05-11 Yao Qi <yao@codesourcery.com>
12738 Pedro Alves <palves@redhat.com>
12740 * linux-low.c (enum stopping_threads_kind): New.
12741 (stopping_threads): Change type to `enum stopping_threads_kind'.
12742 (handle_extended_wait): If stopping and suspending threads, leave
12743 the new_lwp suspended too.
12744 (linux_wait_for_event): Adjust.
12745 (stop_all_lwps): Set `stopping_threads' to
12746 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
12747 whether we're suspending threads or just stopping them. Assert no
12750 2012-04-29 Yao Qi <yao@codesourcery.com>
12752 * server.h: Move some code to ...
12753 * gdbthread.h: ... here. New.
12754 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
12755 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
12756 (nto-low.o, win32-low.o): Likewise.
12757 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
12758 * regcache.c, remote-utils.c, server.c: Likewise.
12759 * target.c, tracepoint.c, win32-low.c: Likewise.
12761 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
12763 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
12764 (PTRACE_ARG4_TYPE): Likewise.
12765 (PTRACE_XFER_TYPE): Likewise.
12766 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
12767 ptrace to PTRACE_ARG3_TYPE.
12768 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
12769 (PTRACE_ARG4_TYPE): Likewise.
12770 (PTRACE_XFER_TYPE): Likewise.
12771 (linux_detach_one_lwp): Cast fourth argument of
12772 ptrace to long then PTRACE_ARG4_TYPE.
12773 (regsets_fetch_inferior_registers): Cast third argument of
12774 ptrace to long then PTRACE_ARG3_TYPE.
12775 (regsets_store_inferior_registers): Likewise.
12777 2012-04-20 Pedro Alves <palves@redhat.com>
12779 * configure: Regenerate.
12781 2012-04-19 Pedro Alves <palves@redhat.com>
12783 * Makefile.in (GNULIB_BUILDDIR): New.
12784 (LIBGNU, INCGNU, GNULIB_H): Adjust.
12785 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
12786 (all, install-only, uninstall, clean-info, all-lib, clean): No
12787 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
12788 (maintainer-clean realclean distclean): Use subdir_do.
12790 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
12791 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
12792 * acinclude.m4: Include acx_configure_dir.m4.
12793 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
12794 calls. Call AC_PROG_RANLIB. Configure gnulib using
12797 (GNULIB_STDINT_H): Adjust.
12798 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
12799 * gdbreplay.c: Include build-gnulib/config.h.
12800 * server.h: Likewise.
12801 * aclocal.m4: Regenerate.
12802 * config.in: Regenerate.
12803 * configure: Regenerate.
12805 2012-04-19 Pedro Alves <palves@redhat.com>
12807 * Makefile.in (LIBGNU, INCGNU): Adjust.
12808 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
12809 (all, install-only, uninstall, clean-info, all-lib, clean)
12810 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
12811 * configure.ac: Adjust AC_OUTPUT output.
12812 * aclocal.m4: Regenerate.
12813 * configure: Regenerate.
12815 2012-04-19 Pedro Alves <palves@redhat.com>
12817 * Makefile.in (generated_files): New.
12818 (server_h): Remove the explicit dependency on config.h, and depend
12819 on $generated_files.
12821 2012-04-19 Pedro Alves <palves@redhat.com>
12823 * Makefile.in (INCGNU): Add -Ignulib.
12825 2012-04-19 Pedro Alves <palves@redhat.com>
12827 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
12828 (INCGNU): ... this, and spell out -I here.
12829 (GNULIB_LIB): Rename to ...
12830 (LIBGNU): ... this.
12831 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
12833 2012-04-19 Pedro Alves <palves@redhat.com>
12835 * config.in: Regenerate.
12837 2012-04-19 Pedro Alves <palves@redhat.com>
12839 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
12840 * server.h (memmem): Remove declaration.
12841 * config.in: Regenerate.
12842 * configure: Regenerate.
12844 2012-04-19 Yao Qi <yao@codesourcery.com>
12846 * Makefile.in (SFILES): Add common/vec.c.
12850 2012-04-19 Yao Qi <yao@codesourcery.com>
12852 * remote-utils.c (prepare_resume_reply): Replace with macro
12853 target_core_of_thread.
12854 * server.c (handle_qxfer_threads_proper): Likewise.
12855 * target.h (traget_core_of_thread): New macro.
12857 2012-04-18 Pedro Alves <palves@redhat.com>
12859 * aclocal.m4: Regenerate.
12860 * configure: Regenerate.
12862 2012-04-16 Yao Qi <yao@codesourcery.com>
12864 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
12865 duplicated on address.
12867 2012-04-16 Yao Qi <yao@codesourcery.com>
12869 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
12870 (struct tracepoint_action_ops) <send>: New field.
12871 (m_tracepoint_action_send, r_tracepoint_action_send): New.
12872 (agent_expr_send, x_tracepoint_action_send): New.
12873 (l_tracepoint_action_send): New.
12874 (cmd_qtdp): Download and install tracepoint
12875 according to `use_agent'.
12876 (run_inferior_command): Add one more parameter `len'.
12878 (tracepoint_send_agent): New.
12879 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
12881 2012-04-16 Yao Qi <yao@codesourcery.com>
12883 * tracepoint.c (download_tracepoints): Moved to ...
12884 (cmd_qtstart): ... here.
12886 2012-04-14 Yao Qi <yao@codesourcery.com>
12888 * tracepoint.c: Include inttypes.h.
12889 (struct collect_memory_action): Use sized types.
12890 (struct tracepoint): Likewise.
12891 (cmd_qtdp, stop_tracing): Update print specifiers.
12892 (cmd_qtp, response_tracepoint): Likewise.
12893 (collect_data_at_tracepoint): Likewise.
12894 (collect_data_at_step): Likewise.
12896 2012-04-14 Yao Qi <yao@codesourcery.com>
12898 Import gnulib module inttypes.
12899 * aclocal.m4, config.in, configure: Regenerated.
12901 2012-04-14 Yao Qi <yao@codesourcery.com>
12903 * Makefile.in (maintainer-clean, realclean, distclean): Remove
12904 Makefile and config.status at last.
12906 2012-04-13 Yao Qi <yao@codesourcery.com>
12908 * tracepoint.c: Include stdint.h unconditionally.
12910 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
12912 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
12913 on BFD_HAVE_SYS_PROCFS_TYPE.
12914 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
12915 * configure: Regenerate.
12916 * config.in: Likewise.
12918 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
12920 * Makefile.in (clean): Also remove x32.c x32-linux.c
12921 x32-avx.c x32-avx-linux.c.
12922 (x32.o): New target.
12924 (x32-linux.o): Likewise.
12925 (x32-linux.c): Likewise.
12926 (x32-avx.o): Likewise.
12927 (x32-avx.c): Likewise.
12928 (x32-avx-linux.o): Likewise.
12929 (x32-avx-linux.c): Likewise.
12931 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
12932 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
12933 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
12934 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
12935 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
12936 i386/x32-avx-linux.xml.
12938 * linux-x86-low.c (init_registers_x32_linux): New prototype.
12939 (init_registers_x32_avx_linux): Likwise.
12940 (x86_linux_update_xmltarget): Call init_registers_x32_linux
12941 or init_registers_x32_avx_linux if linux_is_elf64 is false.
12943 2012-04-13 Pedro Alves <palves@redhat.com>
12945 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
12946 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
12947 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
12948 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
12951 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
12953 * linux-x86-low.c (compat_x32_clock_t): New.
12954 (compat_x32_siginfo_t): Likewise.
12955 (compat_x32_siginfo_from_siginfo): Likewise.
12956 (siginfo_from_compat_x32_siginfo): Likewise.
12957 (linux_is_elf64): Likewise.
12958 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
12959 and siginfo_from_compat_x32_siginfo for x32.
12960 (x86_arch_setup): Set linux_is_elf64.
12962 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
12965 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
12967 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
12968 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
12969 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
12970 compatible with process.
12972 2012-04-12 Yao Qi <yao@codesourcery.com>
12974 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
12975 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
12976 (install-only, install-info, clean): Handle sub dir gnulib.
12977 (all-lib, am--refresh): New targets.
12978 (memmem.o): Remove target.
12979 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
12980 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
12981 (AC_REPLACE_FUNCS): Remove memmem.
12982 Invoke gl_INIT and AM_INIT_AUTOMAKE.
12983 (AC_OUTPUT): Generate Makefile in gnulib/.
12984 * aclocal.m4, config.in, configure: Regenerated.
12986 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
12988 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
12990 2012-04-05 Pedro Alves <palves@redhat.com>
12992 -Werror=strict-aliasing
12994 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
12997 2012-04-04 Pedro Alves <palves@redhat.com>
12999 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
13000 (sparc_store_gregset_from_stack, sparc_store_gregset)
13001 (sparc_breakpoint_at): Fix formatting.
13003 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
13005 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
13007 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
13008 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
13009 * config.in: Regenerate.
13010 * configure: Likewise.
13012 2012-03-29 Pedro Alves <palves@redhat.com>
13014 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
13015 Correct ptrace arguments.
13017 2012-03-28 Pedro Alves <palves@redhat.com>
13019 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
13020 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
13021 (IA64_FR1_REGNUM): New defines.
13022 (ia64_fetch_register): New.
13023 (the_low_target): Install it.
13024 * linux-low.h (struct linux_target_ops) <fetch_register>: New
13026 * linux-low.c (linux_fetch_registers): Try the
13027 the_low_target.fetch_register hook first.
13029 * linux-arm-low.c (the_low_target): Adjust.
13030 * linux-bfin-low.c (the_low_target): Adjust.
13031 * linux-cris-low.c (the_low_target): Adjust.
13032 * linux-crisv32-low.c (the_low_target): Adjust.
13033 * linux-m32r-low.c (the_low_target): Adjust.
13034 * linux-m68k-low.c (the_low_target): Adjust.
13035 * linux-mips-low.c (the_low_target): Adjust.
13036 * linux-ppc-low.c (the_low_target): Adjust.
13037 * linux-s390-low.c (the_low_target): Adjust.
13038 * linux-sh-low.c (the_low_target): Adjust.
13039 * linux-sparc-low.c (the_low_target): Adjust.
13040 * linux-tic6x-low.c (the_low_target): Adjust.
13041 * linux-x86-low.c (the_low_target): Adjust.
13042 * linux-xtensa-low.c (the_low_target): Adjust.
13044 2012-03-26 Pedro Alves <palves@redhat.com>
13046 * server.c (handle_qxfer_libraries): Don't bail early if
13047 the_target->qxfer_libraries_svr4 is not NULL.
13049 2012-03-26 Pedro Alves <palves@redhat.com>
13051 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
13053 2012-03-23 Pedro Alves <palves@redhat.com>
13055 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
13056 "library-list-svr4" element's start tag when the the DSO list is
13059 2012-03-23 Pedro Alves <palves@redhat.com>
13061 * linux-low.c (read_one_ptr): Read the inferior's pointer through
13062 a variable whose type size is the same as the inferior's pointer
13065 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
13067 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
13069 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
13070 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
13071 * linux-low.h: Include <signal.h>.
13072 (struct siginfo): Remove forward declaration.
13073 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
13076 2012-03-21 Mike Frysinger <vapier@gentoo.org>
13078 * .gitignore: Ignore more files.
13080 2012-03-19 Pedro Alves <palves@redhat.com>
13081 Jan Kratochvil <jan.kratochvil@redhat.com>
13083 * server.c (cont_thread, general_thread): Add describing comments.
13084 (start_inferior): Clear `cont_thread'.
13085 (handle_v_cont): Don't set `cont_thread' if resuming all threads
13088 2012-03-15 Yao Qi <yao@codesourcery.com>
13090 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
13092 (cmd_qtdp): ... here.
13094 2012-03-15 Yao Qi <yao@codesourcery.com>
13096 * tracepoint.c (struct tracepoint_action_ops): New.
13097 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
13098 (m_tracepoint_action_download): New.
13099 (r_tracepoint_action_download): New.
13100 (x_tracepoint_action_download): New.
13101 (l_tracepoint_action_download): New.
13102 (add_tracepoint_action): Install `action->ops' according type.
13103 (download_tracepoint_1): Move code `download' function pointer
13104 of various tracepoint_action_ops.
13106 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
13108 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
13109 linux_ptrace_attach_warnings.
13111 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
13113 * Makefile.in (linux-ptrace.o): New.
13114 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
13115 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
13116 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
13117 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
13118 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
13120 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
13122 2012-03-08 Yao Qi <yao@codesourcery.com>
13123 Pedro Alves <palves@redhat.com>
13125 Fix PR server/13392.
13126 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
13127 offset of JMP insn.
13128 * tracepoint.c (remove_tracepoint): New.
13129 (cmd_qtdp): Call remove_tracepoint when failed to install.
13131 2012-03-07 Pedro Alves <palves@redhat.com>
13133 * linux-low.c (get_detach_signal): New.
13134 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
13135 Pass on pending signals to PTRACE_DETACH. Check the result of the
13137 * server.c (program_signals, program_signals_p): New.
13138 (handle_general_set): Handle QProgramSignals.
13139 * server.h (program_signals, program_signals_p): Declare.
13141 2012-03-05 Pedro Alves <palves@redhat.com>
13142 Jan Kratochvil <jan.kratochvil@redhat.com>
13144 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
13147 2012-03-03 Yao Qi <yao@codesourcery.com>
13149 * tracepoint.c (tracepoint_look_up_symbols): Update call to
13150 agent_look_up_symbols.
13152 2012-03-03 Yao Qi <yao@codesourcery.com>
13154 * Makefile.in (linux-low.o): Keep dependence on agent.h.
13155 (linux-x86-low.o): Likewise.
13156 * server.h: Remove in_process_agent_loaded.
13157 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
13161 2012-03-03 Yao Qi <yao@codesourcery.com>
13163 * tracepoint.c (gdb_agent_capability): New global.
13164 (in_process_agent_loaded_ust): Renamed to
13165 `in_process_agent_supports_ust'.
13167 (in_process_agent_supports_ust): Call agent_capability_check.
13168 (clear_installed_tracepoints): Assert that agent supports
13171 2012-03-03 Yao Qi <yao@codesourcery.com>
13173 * linux-low.c (linux_supports_agent): New.
13174 (linux_target_ops): Initialize field `supports_agent' with
13175 linux_supports_agent.
13176 * target.h (struct target_ops) <supports_agent>: New.
13177 (target_supports_agent): New macro.
13178 * server.c (handle_general_set): Handle packet 'QAgent'.
13179 (handle_query): Send `QAgent+'.
13180 * Makefile.in (server.o): Depends on agent.h.
13182 2012-03-03 Yao Qi <yao@codesourcery.com>
13184 * Makefile.in (OBS): Add agent.o.
13185 Add new rule for agent.o.
13186 Track dependence of tracepoint.c on agent.h.
13187 * tracepoint.c (run_inferior_command_1):
13188 (run_inferior_command): Call agent_run_command.
13189 (gdb_ust_connect_sync_socket): Deleted. Move it to
13191 (resume_thread, stop_thread): Likewise.
13192 (gdb_ust_socket_init): Renamed to ...
13193 (gdb_agent_socket_init): ... New.
13194 (gdb_ust_thread): Renamed to ...
13195 (gdb_agent_helper_thread): ... New.
13196 (gdb_ust_init): Move some code to ...
13197 (gdb_agent_init): ... here. New.
13198 [HAVE_UST]: Call gdb_ust_init.
13199 (initialize_tracepoint_ftlib): Call gdb_agent_init.
13200 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
13201 * config.in, configure: Regenerated.
13203 2012-03-02 Pedro Alves <palves@redhat.com>
13205 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
13206 * linux-low.c (struct simple_pid_list): New.
13207 (stopped_pids): New a struct simple_pid_list pointer.
13208 (add_to_pid_list, pull_pid_from_list): New.
13209 (handle_extended_wait): Don't assume the first signal new children
13210 report is SIGSTOP. Adjust call to pull_pid_from_list.
13211 (linux_wait_for_lwp): Adjust.
13213 2012-03-02 Yao Qi <yao@codesourcery.com>
13215 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
13218 2012-03-02 Yao Qi <yao@codesourcery.com>
13220 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
13221 `stop_pc' and `tpoint'. Update caller.
13223 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
13225 * linux-low.h (linux_target_ops): Add regset_bitmap member.
13226 * linux-low.c (use_linux_regsets): New macro.
13227 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
13228 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
13229 (linux_register_in_regsets): New function.
13230 (usr_fetch_inferior_registers): Skip registers covered by
13232 (usr_store_inferior_registers): Likewise.
13233 (usr_fetch_inferior_registers): New macro.
13234 (usr_store_inferior_registers): Likewise.
13235 (linux_fetch_registers): Handle mixed regset/non-regset targets.
13236 (linux_store_registers): Likewise.
13237 * linux-mips-low.c (init_registers_mips_dsp_linux): New
13239 (init_registers_mips64_dsp_linux): Likewise.
13240 (init_registers_mips_linux): New macro.
13241 (init_registers_mips_dsp_linux): Likewise.
13242 (mips_dsp_num_regs): Likewise.
13243 (DSP_BASE, DSP_CONTROL): New fallback macros.
13244 (mips_base_regs): New macro.
13245 (mips_regmap): Use it. Fix the size.
13246 (mips_dsp_regmap): New variable.
13247 (mips_dsp_regset_bitmap): Likewise.
13248 (mips_arch_setup): New function.
13249 (mips_cannot_fetch_register): Use the_low_target.regmap rather
13251 (mips_cannot_store_register): Likewise.
13252 (the_low_target): Update .arch_setup, .num_regs and .regmap
13253 initializers. Add .regset_bitmap initializer.
13254 * linux-arm-low.c (the_low_target): Add .regset_bitmap
13256 * linux-bfin-low.c (the_low_target): Likewise.
13257 * linux-cris-low.c (the_low_target): Likewise.
13258 * linux-crisv32-low.c (the_low_target): Likewise.
13259 * linux-ia64-low.c (the_low_target): Likewise.
13260 * linux-m32r-low.c (the_low_target): Likewise.
13261 * linux-m68k-low.c (the_low_target): Likewise.
13262 * linux-ppc-low.c (the_low_target): Likewise.
13263 * linux-s390-low.c (the_low_target): Likewise.
13264 * linux-sh-low.c (the_low_target): Likewise.
13265 * linux-sparc-low.c (the_low_target): Likewise.
13266 * linux-tic6x-low.c (the_low_target): Likewise.
13267 * linux-x86-low.c (the_low_target): Likewise.
13268 * linux-xtensa-low.c (the_low_target): Likewise.
13269 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
13270 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
13271 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
13273 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
13274 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
13276 2012-02-29 Yao Qi <yao@codesourcery.com>
13277 Pedro Alves <palves@redhat.com>
13279 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
13280 `step_over_finished' is true.
13282 2012-02-27 Pedro Alves <palves@redhat.com>
13284 * linux-low.c (pid_is_stopped): Delete, moved to common/.
13285 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
13287 2012-02-27 Pedro Alves <palves@redhat.com>
13290 * linux-low.c (pid_is_stopped): New.
13291 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
13293 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
13295 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
13298 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
13300 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
13302 2012-02-24 Luis Machado <lgustavo@codesourcery>
13304 * server.c (handle_query): Advertise support for target-side
13305 breakpoint condition evaluation.
13306 (process_point_options): New function.
13307 (process_serial_event): When inserting a breakpoint, check for
13308 a target-side condition that should be evaluated.
13310 * mem-break.c: Include regcache.h and ax.h.
13311 (point_cond_list_t): New data structure.
13312 (breakpoint) <cond_list>: New field.
13313 (find_gdb_breakpoint_at): Make non-static.
13314 (delete_gdb_breakpoint_at): Clear any target-side
13316 (clear_gdb_breakpoint_conditions): New function.
13317 (add_condition_to_breakpoint): Likewise.
13318 (add_breakpoint_condition): Likewise.
13319 (gdb_condition_true_at_breakpoint): Likewise.
13320 (gdb_breakpoint_here): Return result directly instead
13321 of going through a local variable.
13323 * mem-break.h (find_gdb_breakpoint_at): New prototype.
13324 (clear_gdb_breakpoint_conditions): Likewise.
13325 (add_breakpoint_condition): Likewise.
13326 (gdb_condition_true_at_breakpoint): Likewise.
13328 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
13329 (need_step_over_p): Take target-side breakpoint condition into
13332 2012-02-24 Luis Machado <lgustavo@codesourcery>
13334 * server.h: Include tracepoint.h.
13335 (agent_mem_read, agent_get_trace_state_variable_value,
13336 agent_set_trace_state_variable_value,
13337 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
13338 get_set_tsv_func_addr): New prototypes.
13340 * ax.h: New include file.
13341 * ax.c: New source file.
13343 * tracepoint.c: Include ax.h.
13344 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
13345 agent_expr, eval_result_type): Move to ax.h.
13346 (parse_agent_expr): Rename to ...
13347 (gdb_parse_agent_expr): ... this, make it non-static and move
13349 (unparse_agent_expr) Rename to ...
13350 (gdb_unparse_agent_expr): ... this, make it non-static and move
13352 (eval_agent_expr): Rename to ...
13353 (eval_tracepoint_agent_expr): ... this.
13354 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
13355 forward declarations.
13356 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
13357 (agent_get_trace_state_variable_value): New function.
13358 (agent_set_trace_state_variable_value): New function.
13359 (cmd_qtdp): Call gdb_parse_agent_expr (...).
13360 (response_tracepoint): Call gdb_unparse_agent_expr (...).
13361 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
13362 (condition_true_at_tracepoint): Likewise.
13363 (parse_agent_expr): Rename to ...
13364 (gdb_parse_agent_expr): ... this and move to ax.c.
13365 (unparse_agent_expr): Rename to ...
13366 (gdb_unparse_agent_expr): ... this and move to ax.c.
13367 (gdb_agent_op_name): Move to ax.c.
13368 (eval_agent_expr): Rename to ...
13369 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
13371 (eval_tracepoint_agent_expr): New function.
13372 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
13374 (current_insn_ptr, emit_error, struct bytecode_address): Move to
13376 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
13377 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
13378 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
13379 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
13380 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
13381 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
13382 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
13383 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
13384 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
13385 (compile_bytecodes): Remove forward declaration.
13386 (is_goto_target): Move to ax.c.
13387 (compile_bytecodes): Move to ax.c and call
13388 agent_get_trace_state_variable_value (...) and
13389 agent_set_trace_state_variable_value (...).
13391 * Makefile.in: Update ax.c and IPA dependencies.
13393 2012-02-24 Pedro Alves <palves@redhat.com>
13395 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
13396 (cmd_bigqtbuffer_circular): ... this. Only handle
13397 'QTBuffer:circular:'.
13398 (handle_tracepoint_general_set): Adjust.
13400 2012-02-16 Yao Qi <yao@codesourcery.com>
13402 * inferiors.c: Move code to ...
13403 * dll.c: .... here. New.
13404 * server.h: Declare clear_dlls.
13405 * Makefile.in (SFILES): Add dll.c.
13409 2012-02-11 Yao Qi <yao@codesourcery.com>
13411 * server.c: (handle_monitor_command): Add a new parameter
13413 (handle_query): Update caller.
13415 2012-02-09 Joel Brobecker <brobecker@adacore.com>
13417 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
13418 * configure, config.in: Regenerate.
13419 * hostio.c: Provide an alternate implementation if HAVE_READLINK
13422 2012-02-02 Pedro Alves <palves@redhat.com>
13424 Try SIGKILL first, then PTRACE_KILL.
13425 * linux-low.c (linux_kill_one_lwp): New.
13426 (linux_kill_one_lwp): Rename to ...
13427 (kill_one_lwp_callback): ... this. Use the new
13428 linux_kill_one_lwp.
13430 2012-02-02 Pedro Alves <palves@redhat.com>
13432 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
13435 2012-01-27 Pedro Alves <palves@redhat.com>
13437 * linux-low.c (linux_child_pid_to_exec_file): Delete.
13438 (elf_64_file_p): Make static.
13439 (linux_pid_exe_is_elf_64_file): New.
13440 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
13441 Delete declarations.
13442 (linux_pid_exe_is_elf_64_file): Declare.
13443 * linux-x86-low.c (x86_arch_setup): Use
13444 linux_pid_exe_is_elf_64_file.
13446 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
13448 * linux-low.c (linux_wait_for_event_1): Rename to ...
13449 (linux_wait_for_event): ... here and merge it with former
13450 linux_wait_for_event - new variable wait_ptid, use it.
13451 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
13453 2012-01-23 Pedro Alves <palves@redhat.com>
13455 * server.c (main): Avoid yet another case of infinite loop while
13456 detaching/killing after a longjmp.
13458 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13461 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
13463 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
13465 * hostio.c (handle_readlink): New function.
13466 (handle_vFile): Call it to handle "vFile:readlink" packets.
13468 2012-01-20 Pedro Alves <palves@redhat.com>
13469 Ulrich Weigand <ulrich.weigand@linaro.org>
13471 * server.c (handle_v_requests): Only support vAttach and vRun to
13472 start multiple processes when in extended protocol mode.
13474 2012-01-17 Pedro Alves <palves@redhat.com>
13476 * tracepoint.c (initialize_tracepoint): Use mmap instead of
13477 memalign plus mprotect to allocate the scratch buffer.
13479 2012-01-13 Pedro Alves <palves@redhat.com>
13481 * server.c (attach_inferior): Clear `cont_thread'.
13483 2012-01-13 Pedro Alves <palves@redhat.com>
13485 * server.c (main): Avoid infinite loop while detaching/killing
13488 2012-01-09 Doug Evans <dje@google.com>
13490 * server.c (start_inferior): Set last_ptid in --wrapper case.
13492 2012-01-06 Yao Qi <yao@codesourcery.com>
13494 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
13496 [IN_PROCESS_AGENT] (debug_agent): New global variable.
13498 2012-01-04 Yao Qi <yao@codesourcery.com>
13500 * tracepoint.c (cmd_qtdp): Print debug message
13501 for static tracepoint.
13503 2012-01-04 Yao Qi <yao@codesourcery.com>
13505 * tracepoint.c (trace_vdebug): Differentiate debug message
13506 between gdbserver and IPA.
13508 2012-01-03 Yao Qi <yao@codesourcery.com>
13510 * tracepoint.c (tracepoint_was_hit): Don't collect for
13513 2012-01-02 Joel Brobecker <brobecker@adacore.com>
13515 * terminal.h: Reformat copyright header.
13517 2012-01-02 Joel Brobecker <brobecker@adacore.com>
13519 * server.c (gdbserver_version): Update copyright year.
13520 * gdbreplay.c (gdbreplay_version): Likewise.
13522 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
13524 * linux-low.c (linux_create_inferior): Put empty if clause for write.
13527 2011-12-18 Hui Zhu <teawater@gmail.com>
13528 * linux-low.c (linux_create_inferior): Save return value to ret.
13530 2011-12-18 Hui Zhu <teawater@gmail.com>
13532 * linux-low.c (linux_create_inferior): Save return value to ret.
13534 2011-12-16 Doug Evans <dje@google.com>
13536 * linux-low.c (linux_create_inferior): If stdio connection,
13537 redirect stdin from /dev/null, stdout to stderr.
13538 * remote-utils.c (remote_is_stdio): New static global.
13539 (remote_connection_is_stdio): New function.
13540 (remote_prepare): Handle stdio connection.
13541 (remote_open): Ditto.
13542 (remote_close): Don't close stdin for stdio connections.
13543 (read_prim,write_prim): New functions. Replace all calls to
13544 read/write to these.
13545 * server.c (main): Watch for "-" argument. Move call to
13546 remote_prepare before start_inferior.
13547 * server.h (STDIO_CONNECTION_NAME): New macro.
13548 (remote_connection_is_stdio): Declare.
13550 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
13551 in debugging output.
13553 2011-12-15 Yao Qi <yao@codesourcery.com>
13555 * tracepoint.c: Include sys/syscall.h.
13556 (gdb_ust_thread): Remove preprocessor conditional.
13558 2011-12-14 Pedro Alves <pedro@codesourcery.com>
13560 * linux-low.c (linux_detach_one_lwp): Call
13561 the_low_target.prepare_to_resume before detaching.
13563 2011-12-14 Yao Qi <yao@codesourcery.com>
13565 * tracepoint.c (gdb_ust_thread): Don't ignore return value
13568 2011-12-14 Yao Qi <yao@codesourcery.com>
13570 * i386-low.c (i386_low_stopped_data_address): Initialize local
13571 variable `control'.
13573 2011-12-13 Pedro Alves <pedro@codesourcery.com>
13577 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
13578 DR_CONTROL unless necessary. Extend comments.
13579 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
13580 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
13582 2011-12-13 Yao Qi <yao@codesourcery.com>
13584 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
13586 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
13588 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
13590 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
13591 Print new debug message for such case.
13593 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
13595 Fix overlapping memcpy.
13596 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
13597 the read_inferior_memory transfer.
13598 (delete_fast_tracepoint_jump): New variable buf. Use it for the
13599 write_inferior_memory transfer.
13600 (set_fast_tracepoint_jump): New variable buf. Use it for the
13601 read_inferior_memory and write_inferior_memory transfers.
13602 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
13603 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
13604 Use it for the write_inferior_memory transfer.
13605 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
13608 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
13610 * linux-low.c (fetch_register, store_register): Make code
13611 consistent, fix formatting.
13613 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
13615 * linux-low.c (usr_store_inferior_registers): Factor out code
13616 to handle individual registers into...
13617 (store_register): ... this new function.
13619 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
13621 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
13622 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
13623 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
13624 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
13625 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
13626 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
13627 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
13628 (srv_xmlfiles): Add new XML files.
13630 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
13632 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
13633 (init_registers_s390_linux32v1): Add prototype.
13634 (init_registers_s390_linux32v2): Likewise.
13635 (init_registers_s390_linux64v1): Likewise.
13636 (init_registers_s390_linux64v2): Likewise.
13637 (init_registers_s390x_linux64v1): Likewise.
13638 (init_registers_s390x_linux64v2): Likewise.
13639 (s390_num_regs): Increment to 52.
13640 (s390_regmap): Add orig_r2 register.
13641 (s390_num_regs_3264): Increment to 68.
13642 (s390_regmap_3264): Add orig_r2 register.
13643 (s390_collect_ptrace_register): Handle orig_r2 register.
13644 (s390_supply_ptrace_register): Likewise.
13645 (s390_fill_last_break): New function.
13646 (s390_store_last_break): Likewise.
13647 (s390_fill_system_call): New function.
13648 (s390_store_system_call): Likewise.
13649 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
13651 (s390_check_regset): New function.
13652 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
13653 NT_S390_SYSTEM_CALL regsets and use appropriate description.
13654 Update target_regsets for available register sets.
13656 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
13657 Jan Kratochvil <jan.kratochvil@redhat.com>
13659 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
13660 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
13662 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
13663 * linux-low.h (struct process_info_private): New member r_debug.
13664 * server.c (handle_qxfer_libraries): Call
13665 the_target->qxfer_libraries_svr4.
13666 (handle_qxfer_libraries_svr4): New function.
13667 (qxfer_packets): New entry "libraries-svr4".
13668 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
13669 * target.h (struct target_ops): New member qxfer_libraries_svr4.
13670 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
13671 PACKET_qXfer_libraries_svr4.
13673 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
13675 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
13676 PSW address/mask between 8-byte and 16-byte formats.
13677 (s390_supply_ptrace_register): Likewise.
13678 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
13679 basic addressing mode bit.
13681 2011-11-24 Stan Shebs <stan@codesourcery.com>
13683 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
13685 2011-11-17 Stan Shebs <stan@codesourcery.com>
13687 * tracepoint.c (struct tracepoint): New field traceframe_usage.
13688 (tracing_start_time): New global.
13689 (tracing_stop_time): New global.
13690 (tracing_user_name): New global.
13691 (tracing_notes): New global.
13692 (tracing_stop_note): New global.
13693 (cmd_qtstart): Set traceframe_usage, start_time.
13694 (stop_tracing): Set stop_time.
13695 (cmd_qtstatus): Report additional status.
13696 (cmd_qtp): New function.
13697 (handle_tracepoint_query): Call it.
13698 (cmd_qtnotes): New function.
13699 (handle_tracepoint_general_set): Call it.
13700 (get_timestamp): Rename from tsv_get_timestamp.
13702 2011-11-14 Stan Shebs <stan@codesourcery.com>
13703 Kwok Cheung Yeung <kcy@codesourcery.com>
13705 * linux-x86-low.c (small_jump_insn): New.
13706 (i386_install_fast_tracepoint_jump_pad): Add arguments for
13707 trampoline and error message, build a trampoline and issue a small
13708 jump instruction to it.
13709 (x86_install_fast_tracepoint_jump_pad): Add arguments for
13710 trampoline and error message.
13711 (x86_get_min_fast_tracepoint_insn_len): New.
13712 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
13713 * linux-low.h (struct linux_target_ops): Add arguments to
13714 install_fast_tracepoint_jump_pad operation, add new operation.
13715 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
13717 (linux_get_min_fast_tracepoint_insn_len): New function.
13718 (linux_target_op): Add new operation.
13719 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
13720 (gdb_trampoline_buffer_end): Ditto.
13721 (gdb_trampoline_buffer_error): Ditto.
13722 (struct ipa_sym_addresses): Add fields for new IPA variables.
13723 (symbol_list): Add entries for new IPA variables.
13724 (struct tracepoint): Add fields to hold the address range of the
13725 trampoline used by the tracepoint.
13726 (trampoline_buffer_head): New static variable.
13727 (trampoline_buffer_tail): Ditto.
13728 (claim_trampoline_space): New function.
13729 (have_fast_tracepoint_trampoline_buffer): New function.
13730 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
13732 (install_fast_tracepoint): Ditto, also add error buffer argument.
13733 (cmd_qtminftpilen): New function.
13734 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
13735 (fast_tracepoint_from_trampoline_address): New function.
13736 (fast_tracepoint_collecting): Handle trampoline as part of jump
13738 (set_trampoline_buffer_space): New function.
13739 (initialize_tracepoint): Initialize new IPA variables.
13740 * target.h (struct target_ops): Add arguments to
13741 install_fast_tracepoint_jump_pad operation, add new
13742 get_min_fast_tracepoint_insn_len operation.
13743 (target_get_min_fast_tracepoint_insn_len): New.
13744 (install_fast_tracepoint_jump_pad): Add arguments.
13745 * server.h (IPA_BUFSIZ): Define.
13746 * linux-i386-ipa.c: Include extra header files.
13747 (initialize_fast_tracepoint_trampoline_buffer): New function.
13748 (initialize_low_tracepoint): Call it.
13749 * server.h (set_trampoline_buffer_space): Declare.
13750 (claim_trampoline_space): Ditto.
13751 (have_fast_tracepoint_trampoline_buffer): Ditto.
13753 2011-11-14 Yao Qi <yao@codesourcery.com>
13755 * server.c (handle_query): Handle InstallInTrace for qSupported.
13756 * tracepoint.c (add_tracepoint): Sort list.
13757 (install_tracepoint, download_tracepoint): New.
13758 (cmd_qtdp): Call them to install and download tracepoints.
13759 (sort_tracepoints): Removed.
13760 (cmd_qtstart): Update.
13762 2011-11-14 Yao Qi <yao@codesourcery.com>
13764 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
13765 * mem-break.h: Declare.
13766 * tracepoint.c (cmd_qtstart): Move some code to ...
13767 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
13769 (download_tracepoints): Move some code to ...
13770 (download_tracepoint_1): ... here. New.
13772 2011-11-08 Yao Qi <yao@codesourcery.com>
13774 * remote-utils.c (relocate_instruction): A comment fix.
13776 2011-11-07 Joel Brobecker <brobecker@adacore.com>
13778 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
13779 (i386_dr_low_get_control, i386_dr_low_get_status): Use
13780 dr_status_mirror and dr_control_mirror from debug_reg_state.
13781 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
13782 (i386_initial_stuff): Remove use of deleted globals.
13783 (i386_get_thread_context, i386_set_thread_context,
13784 i386_thread_added): Use dr_status_mirror and dr_control_mirror
13785 from debug_reg_state.
13787 2011-11-05 Yao Qi <yao@codesourcery.com>
13789 * tracepoint.c (gdb_collect): Loop over tracepoints of same
13790 address as TPOINT's.
13792 2011-11-02 Stan Shebs <stan@codesourcery.com>
13794 * tracepoint.c (agent_mem_read_string): New function.
13795 (eval_agent_expr): Call it for tracenz.
13796 * server.c (handle_query): Report support for tracenz.
13798 2011-11-02 Yao Qi <yao@codesourcery.com>
13800 * tracepoint.c (cmd_qtstart): Remove unused local variables.
13802 2011-11-02 Yao Qi <yao@codesourcery.com>
13804 * target.h: Fix a typo in comment.
13806 2011-10-31 Pedro Alves <pedro@codesourcery.com>
13808 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
13809 clobber the breakpoints' shadows with fast tracepoint jumps.
13810 * mem-break.h (check_mem_write): Add `myaddr' parameter.
13811 * target.c (write_inferior_memory): Also pass MYADDR down to
13814 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
13816 * configure.ac: Check support for personality routine.
13817 * configure: Regenerate.
13818 * config.in: Likewise.
13819 * linux-low.c: Include <sys/personality.h>.
13820 Define ADDR_NO_RANDOMIZE if necessary.
13821 (linux_create_inferior): Disable address space randomization when
13822 forking inferior, if requested.
13823 (linux_supports_disable_randomization): New function.
13824 (linux_target_ops): Install it.
13825 * server.h (disable_randomization): Declare.
13826 * server.c (disable_randomization): New global variable.
13827 (handle_general_set): Handle QDisableRandomization.
13828 (handle_query): Likewise for qSupported.
13829 (main): Support --disable-randomization and --no-disable-randomization
13830 command line arguments.
13831 * target.h (struct target_ops): Add supports_disable_randomization.
13832 (target_supports_disable_randomization): New macro.
13834 2011-09-29 Mike Frysinger <vapier@gentoo.org>
13836 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
13838 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
13839 [!PT_GETDSBT] (target_loadmap): New definition.
13840 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
13841 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
13842 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
13843 and PT_GETDSBT to LINUX_LOADMAP.
13844 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
13845 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
13847 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
13849 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
13850 (arm_linux_hwbp_cap): New static variable.
13851 (arm_linux_get_hwbp_cap): Replace by ...
13852 (arm_linux_init_hwbp_cap): ... this new function.
13853 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
13854 (arm_linux_get_hw_watchpoint_count): Likewise.
13855 (arm_linux_get_hw_watchpoint_max_length): Likewise.
13856 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
13857 (arm_prepare_to_resume): Use perror_with_name instead of error.
13859 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
13861 * linux-arm-low.c: Include <signal.h>.
13862 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
13863 (struct arm_linux_hwbp_cap): New data type.
13864 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
13865 (struct arm_linux_hw_breakpoint): New data type.
13866 (MAX_BPTS, MAX_WPTS): Define.
13867 (struct arch_process_info, struct arch_lwp_info): New data types.
13868 (arm_linux_get_hwbp_cap): New function.
13869 (arm_linux_get_hw_breakpoint_count): Likewise.
13870 (arm_linux_get_hw_watchpoint_count): Likewise.
13871 (arm_linux_get_hw_watchpoint_max_length): Likewise.
13872 (arm_hwbp_control_initialize): Likewise.
13873 (arm_hwbp_control_is_enabled): Likewise.
13874 (arm_hwbp_control_is_initialized): Likewise.
13875 (arm_hwbp_control_disable): Likewise.
13876 (arm_linux_hw_breakpoint_equal): Likewise.
13877 (arm_linux_hw_point_initialize): Likewise.
13878 (struct update_registers_data): New data structure.
13879 (update_registers_callback: New function.
13880 (arm_insert_point): Likewise.
13881 (arm_remove_point): Likewise.
13882 (arm_stopped_by_watchpoint): Likewise.
13883 (arm_stopped_data_address): Likewise.
13884 (arm_new_process): Likewise.
13885 (arm_new_thread): Likewise.
13886 (arm_prepare_to_resume): Likewise.
13887 (the_low_target): Register arm_insert_point, arm_remove_point,
13888 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
13889 arm_new_thread, and arm_prepare_to_resume.
13891 2011-09-15 Stan Shebs <stan@codesourcery.com>
13893 * server.h (struct emit_ops): Add compare-goto fields.
13894 * tracepoint.c (gdb_agent_op_sizes): New table.
13895 (emit_eq_goto): New function.
13896 (emit_ne_goto): New function.
13897 (emit_lt_goto): New function.
13898 (emit_le_goto): New function.
13899 (emit_gt_goto): New function.
13900 (emit_ge_goto): New function.
13901 (is_goto_target): New function.
13902 (compile_bytecodes): Recognize special cases of compare-goto
13903 combinations and call specialized emitters for them.
13904 * linux-x86-low.c (amd64_emit_eq_goto): New function.
13905 (amd64_emit_ne_goto): New function.
13906 (amd64_emit_lt_goto): New function.
13907 (amd64_emit_le_goto): New function.
13908 (amd64_emit_gt_goto): New function.
13909 (amd64_emit_ge_goto): New function.
13910 (amd64_emit_ops): Add the new functions.
13911 (i386_emit_eq_goto): New function.
13912 (i386_emit_ne_goto): New function.
13913 (i386_emit_lt_goto): New function.
13914 (i386_emit_le_goto): New function.
13915 (i386_emit_gt_goto): New function.
13916 (i386_emit_ge_goto): New function.
13917 (i386_emit_ops): Add the new functions.
13919 2011-09-08 Stan Shebs <stan@codesourcery.com>
13921 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
13922 (i386_emit_epilogue): Restore %ebx.
13924 2011-08-31 Jie Zhang <jzhang918@gmail.com>
13926 * server.c (step_thread): Remove definition.
13927 (process_serial_event): Don't handle Hs.
13928 * server.h (step_thread): Remove declaration.
13929 * target.c (set_desired_inferior): Remove use of step_thread.
13931 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
13933 * linux-low.c: Include linux-procfs.h.
13934 (linux_attach_lwp_1): Update comments.
13935 (linux_attach): Scan for existing threads when attaching to a
13936 process that is the tgid.
13937 * Makefile.in: Update dependencies.
13939 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
13941 * configure.srv: Add linux-procfs.o dependencies.
13943 2011-08-14 Yao Qi <yao@codesourcery.com>
13945 * target.h (struct target_ops): Fix indent.
13946 * win32-low.c (win32_target_ops): Fix comment.
13948 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
13949 Yao Qi <yao@codesourcery.com>
13951 * Makefile.in (clean): Remove tic6x-*.c files.
13952 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
13953 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
13954 (tic6x-c64xp-linux.c): Likewise.
13955 * configure.srv: Add support for tic6x-*-uclinux.
13956 * linux-tic6x-low.c: New.
13957 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
13959 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
13960 Yao Qi <yao@codesourcery.com>
13962 * target.h (struct target_ops): Add read_loadmap.
13963 * linux-low.c (struct target_loadseg): New type.
13964 (struct target_loadmap): New type.
13965 (linux_read_loadmap): New function.
13966 (linux_target_ops): Add linux_read_loadmap.
13967 * server.c (handle_query): Support qXfer:fdpic:read packet.
13968 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
13971 2011-08-05 Eli Zaretskii <eliz@gnu.org>
13973 * win32-low.c: Include <stdint.h>.
13975 2011-07-22 Pedro Alves <pedro@codesourcery.com>
13977 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
13978 to the inferior here.
13979 (i386_remove_aligned_watchpoint): Ditto.
13980 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
13981 fit part of the watchpoint in the debug registers.
13982 (i386_update_inferior_debug_regs): New.
13983 (i386_low_insert_watchpoint): Work on a local mirror of the debug
13984 registers, and only update the inferior on success.
13985 (i386_low_remove_watchpoint): Ditto.
13987 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
13989 * linux-low.c (compare_ints, unique, list_threads, show_process,
13990 linux_core_of_thread): Delete.
13991 (linux_target_ops): Change linux_core_of_thread to
13992 linux_common_core_of_thread.
13993 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
13994 * utils.c (malloc_failure): Change type of argument.
13995 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
13996 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
13997 common/linux-osdata.c, common/ptid.c and common/buffer.c.
13998 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
13999 (IPA_OBJS): Add common-utils-ipa.o.
14000 (ptid_h, linux_osdata_h): New macros.
14001 (server_h): Add common/common-utils.h, common/xml-utils.h,
14002 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
14004 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
14005 ptid.o, buffer.o): New rules.
14006 (linux-low.o): Add common/linux-osdata.h as a dependency.
14007 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
14008 * configure.ac: Add AC_HEADER_DIRENT check.
14009 * config.in: Regenerate.
14010 * configure: Regenerate.
14011 * remote-utils.c (xml_escape_text): Delete.
14012 (buffer_grow, buffer_free, buffer_init, buffer_finish,
14013 buffer_xml_printf): Move to common/buffer.c.
14014 * server.c (main): Remove call to initialize_inferiors.
14015 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
14016 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
14017 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
14018 internal_error, gdb_assert, gdb_assert_fail): Delete.
14019 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
14020 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
14022 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
14023 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
14024 initialize_inferiors): Delete.
14026 2011-07-20 Pedro Alves <pedro@codesourcery.com>
14028 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
14031 2011-05-31 Pedro Alves <pedro@codesourcery.com>
14033 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
14035 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
14037 2011-05-26 Yao Qi <yao@codesourcery.com>
14039 * Makefile.in (thread-db.o): Track dependence to
14040 common/gdb_thread_db.h.
14041 * thread-db.c: include gdb_thread_db.h from right place.
14043 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
14045 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
14046 __FILE__ and __LINE__ to internal_error.
14048 2011-05-13 Doug Evans <dje@google.com>
14050 * thread-db.c (try_thread_db_load_from_sdir): New function.
14051 (try_thread_db_load_from_dir): New function.
14052 (thread_db_load_search): Handle $sdir, ignore $pdir.
14053 Remove trying of system directories if search of
14054 libthread-db-search-path fails, that is now done via $sdir.
14056 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
14058 * server.c (handle_query): Add EnableDisableTracepoints to the list
14059 of supported features.
14060 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
14062 (cmd_qtenable_disable): New.
14063 (cmd_qtstart): Install tracepoints even if disabled.
14064 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
14065 receiving a QTEnable or QTDisable packet.
14066 (gdb_collect): Skip data collection if fast tracepoint is disabled.
14067 (ust_marker_to_static_tracepoint): Do not ignore disabled static
14069 (gdb_probe): Skip data collection if static tracepoint is disabled.
14071 2011-05-10 Doug Evans <dje@google.com>
14073 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
14075 2011-05-04 Doug Evans <dje@google.com>
14077 * linux-low.c (linux_join): Skip process lookup.
14078 * spu-low.c (spu_join): Ditto.
14079 * server.c (join_inferiors_callback): Delete.
14080 (process_serial_event): For 'D' packet (detach) call join_inferior
14083 2011-05-04 Joseph Myers <joseph@codesourcery.com>
14085 * README: Don't mention xscale*-*-linux*.
14086 * configure.srv (xscale*-*-linux*): Don't handle target.
14088 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
14090 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
14092 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
14093 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
14094 (i386_emit_void_call_2): Likewise.
14096 2011-04-26 Yao Qi <yao@codesourcery.com>
14098 * linux-low.c: Move common macros to linux-ptrace.h.
14099 Include linux-ptrace.h.
14100 * Makefile.in (linux_ptrace_h): New.
14101 (linux-low.o): Depends on linux-ptrace.h.
14103 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
14105 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
14106 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
14107 (remote_prepare): New function with most of the TCP code from ...
14108 (remote_open): ... here. Detect PORT here unconditionally. Move also
14109 setting transport_is_reliable.
14110 * server.c (run_once): New variable.
14111 (gdbserver_usage): Document it.
14112 (main): Set run_once for `--once'. Call remote_prepare. Exit after
14113 the first run if RUN_ONCE.
14114 * server.h (run_once, remote_prepare): New declarations.
14116 2011-04-19 Tom Tromey <tromey@redhat.com>
14118 * win32-low.c (handle_load_dll): Remove duplicate "the".
14120 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
14122 Remove support for old Cygwin 1.5 versions.
14123 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
14124 function to avoid warning.
14125 (win32_add_one_solib): Use cygwin_conv_path function to avoid
14128 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
14130 * gdbserver/server.h (Macro _): Define it if not available.
14132 2011-03-14 Michael Snyder <msnyder@vmware.com>
14134 * hostio.c (handle_close): Remove unnecessary null test.
14136 2011-03-10 Joel Brobecker <brobecker@adacore.com>
14138 * Makefile.in (maintainer-clean realclean distclean): Remove
14139 "make ... subdir_do" command.
14141 2011-03-10 Michael Snyder <msnyder@vmware.com>
14143 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
14145 * server.c (handle_v_run): Free alloced buffer on early return.
14147 2011-03-09 Yao Qi <yao@codesourcery.com>
14150 2011-03-04 Yao Qi <yao@codesourcery.com>
14152 * Makefile.in: Remove GNU make feature --directory.
14154 2011-03-05 Yao Qi <yao@codesourcery.com>
14156 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
14157 (subdir_do): New make target. Copied from gdb/Makefile.
14158 (maintainer-clean, realclean, distclean, clean): Call corresponding
14159 make targets in common/Makefile.
14161 2011-02-11 Yao Qi <yao@codesourcery.com>
14163 * configure.ac: Call AC_PROG_RANLIB.
14164 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
14165 * configure: Regenerate.
14167 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14169 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
14171 2011-03-06 Yao Qi <yao@codesourcery.com>
14173 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
14175 2011-03-05 Yao Qi <yao@codesourcery.com>
14177 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
14178 (subdir_do): New make target. Copied from gdb/Makefile.
14179 (maintainer-clean, realclean, distclean, clean): Call corresponding
14180 make targets in common/Makefile.
14182 2011-03-04 Yao Qi <yao@codesourcery.com>
14184 * Makefile.in: Remove GNU make feature --directory.
14186 2011-03-04 Michael Snyder <msnyder@vmware.com>
14188 * server.c (queue_stop_reply): Call xmalloc not malloc.
14190 2011-03-02 Michael Snyder <msnyder@vmware.com>
14192 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
14194 2011-02-28 Michael Snyder <msnyder@vmware.com>
14196 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
14197 (cmd_qtframe): Ditto.
14198 (cmd_qtbuffer): Ditto.
14199 (cmd_bigqtbuffer): Ditto.
14201 * utils.c (decimal2str): Initialize 'width' to nine, then
14202 don't mess with it.
14204 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
14206 * hostio.c (require_data): Free *data, not data.
14208 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
14210 * hostio.c (require_data): Use free, not xfree.
14212 2011-02-27 Michael Snyder <msnyder@vmware.com>
14214 * server.c (handle_query): Discard unused value.
14216 * hostio.c (require_data): Free malloc memory before returning
14219 2011-02-26 Michael Snyder <msnyder@vmware.com>
14221 * linux-low.c (list_threads): Call closedir for dirent.
14223 2011-02-27 Michael Snyder <msnyder@vmware.com>
14225 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
14226 a case statement falls through.
14228 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
14230 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
14233 2011-02-26 Michael Snyder <msnyder@vmware.com>
14235 * utils.c (decimal2str): Eliminate dead code and dead param.
14236 (pulongest): Drop dead param from call to decimal2str.
14239 2011-02-24 Joel Brobecker <brobecker@adacore.com>
14241 Revert the following patch (not approved yet):
14242 2011-02-21 Hui Zhu <teawater@gmail.com>
14243 * tracepoint.c (tp_printf): New function.
14244 (eval_agent_expr): Handle gdb_agent_op_printf.
14246 2011-02-21 Hui Zhu <teawater@gmail.com>
14248 * tracepoint.c (tp_printf): New function.
14249 (eval_agent_expr): Handle gdb_agent_op_printf.
14251 2011-02-18 Tom Tromey <tromey@redhat.com>
14253 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
14254 (tracepoint.o): Likewise.
14255 * tracepoint.c (enum gdb_agent_op): Use ax.def.
14256 (gdb_agent_op_names): Likewise.
14258 2011-02-18 Tom Tromey <tromey@redhat.com>
14260 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
14261 gdb_agent_op_rot>: New constants.
14262 (gdb_agent_op_names): Add pick and roll.
14263 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
14266 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
14268 * aclocal.m4: Regenerated with aclocal-1.11.1.
14270 2011-02-14 Pedro Alves <pedro@codesourcery.com>
14272 * server.c (handle_qxfer_traceframe_info): New.
14273 (qxfer_packets): Register "traceframe-info".
14274 (handle_query): Report support for qXfer:traceframe-info:read+.
14275 * tracepoint.c (match_blocktype): New.
14276 (traceframe_find_block_type): Rename to ...
14277 (traceframe_walk_blocks): ... this. Add callback filter argument,
14279 (traceframe_find_block_type): New, reimplemented on top of
14280 traceframe_walk_blocks.
14281 (build_traceframe_info_xml): New.
14282 (traceframe_read_info): New.
14283 * server.h (traceframe_read_info): Declare.
14285 2011-02-11 Yao Qi <yao@codesourcery.com>
14287 * configure.ac: Call AC_PROG_RANLIB.
14288 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
14289 * configure: Regenerate.
14291 2011-02-07 Pedro Alves <pedro@codesourcery.com>
14293 * server.c (gdb_read_memory): Change return semantics to allow
14295 (handle_search_memory_1): Adjust.
14296 (process_serial_event) <'m' packet>: Handle partial transfers.
14297 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
14299 2011-01-28 Pedro Alves <pedro@codesourcery.com>
14301 * regcache.c (init_register_cache): Initialize
14302 regcache->register_status.
14303 (free_register_cache): Release regcache->register_status.
14304 (regcache_cpy): Copy register_status.
14305 (registers_to_string): Print 'x's for unavailable registers.
14306 (supply_register): Mark the register's status valid or
14307 unavailable, depending on whether a buffer was passed in or not.
14308 (supply_register_zeroed): New.
14309 (supply_regblock): Mark the registers' status valid or
14310 unavailable, depending on whether a buffer was passed in or not.
14311 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
14312 (struct regcache): New `register_status' field.
14313 (supply_register_zeroed): Declare.
14314 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
14315 supply_register_zeroed, rather than passing a NULL buffer to
14317 * tracepoint.c (fetch_traceframe_registers): Update comment.
14319 2011-01-28 Pedro Alves <pedro@codesourcery.com>
14321 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
14324 2011-01-25 Pedro Alves <pedro@codesourcery.com>
14326 * server.h (decode_xfer_write): Change prototype.
14327 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
14328 and don't extract the annex here.
14329 * server.c (decode_xfer_read): Remove `annex' parameter,
14330 and don't extract the annex here.
14331 (decode_xfer): New.
14332 (struct qxfer): New.
14333 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
14334 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
14335 (handle_qxfer_statictrace): New functions, abstracted out from
14336 handle_query, and made to use the struct qxfer interface.
14337 (handle_threads_qxfer_proper): Rename to ...
14338 (handle_qxfer_threads_proper): ... this.
14339 (handle_threads_qxfer): Rename to ...
14340 (handle_qxfer_threads): ... this. Adjust.
14341 (qxfer_packets): New array.
14342 (handle_qxfer): New function.
14343 (handle_query): Use handle_qxfer.
14345 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
14347 * gdbreplay.c: Shorten lines of >= 80 columns.
14348 * linux-low.c: Ditto.
14349 * linux-ppc-low.c: Ditto.
14350 * linux-s390-low.c: Ditto.
14351 * linux-sparc-low.c: Ditto.
14352 * linux-x86-low.c: Ditto.
14353 * linux-xtensa-low.c: Ditto.
14354 * mem-break.c: Ditto.
14355 * nto-low.c: Ditto.
14356 * regcache.h: Ditto.
14357 * remote-utils.c: Ditto.
14360 * thread-db.c: Ditto.
14361 * tracepoint.c: Ditto.
14363 * win32-low.h: Ditto.
14365 2011-01-05 Joel Brobecker <brobecker@adacore.com>
14367 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
14370 2011-01-01 Joel Brobecker <brobecker@adacore.com>
14372 * server.c (gdbserver_version): Update copyright year in version
14374 * gdbreplay.c (gdbreplay_version): Ditto.
14376 2010-12-29 Jie Zhang <jie.zhang@analog.com>
14378 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
14379 * linux-bfin-low.c: New file.
14380 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
14381 PT_DATA_ADDR for BFIN targets.
14382 * Makefile.in (SFILES): Add linux-bfin-low.c.
14383 (clean): Remove reg-bfin.c.
14384 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
14385 * README: Mention supported Blackfin targets.
14387 2010-12-23 Mike Frysinger <vapier@gentoo.org>
14389 * .gitignore: New file.
14391 2010-11-16 Mike Frysinger <vapier@gentoo.org>
14393 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
14395 2010-10-22 Jie Zhang <jie@codesourcery.com>
14397 * Makefile.in: Add FLAGS_TO_PASS variable.
14398 (install): Remove dependency of install-only and recursively
14399 invoke make for install-only.
14401 2010-10-04 Doug Evans <dje@google.com>
14403 * Makefile.in (uninstall): Use $(DESTDIR).
14405 2010-09-24 Pedro Alves <pedro@codesourcery.com>
14409 * linux-x86-low.c (compat_siginfo_from_siginfo)
14410 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
14411 si_code is < 0. Check for si_code == SI_TIMER before checking for
14414 2010-09-13 Joel Brobecker <brobecker@adacore.com>
14416 * lynx-i386-low.c: New file.
14417 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
14419 2010-09-13 Joel Brobecker <brobecker@adacore.com>
14421 * lynx-low.c (ptrace_request_to_str): Remove handling for
14422 request values that have been removed in LynxOS 5.x.
14424 2010-09-13 Joel Brobecker <brobecker@adacore.com>
14426 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
14429 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
14431 * configure.ac: Add --enable-inprocess-agent option.
14432 * configure: Rebuilt.
14434 2010-09-06 Yao Qi <yao@codesourcery.com>
14436 * linux-low.c (linux_kill): Remove unused variable.
14437 (linux_stabilize_threads): Likewise.
14438 * server.c (start_inferior): Likewise.
14439 (queue_stop_reply_callback): Likewise.
14440 * tracepoint.c (do_action_at_tracepoint): Likewise.
14442 2010-09-06 Yao Qi <yao@codesourcery.com>
14444 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
14447 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
14449 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
14451 2010-09-06 Pedro Alves <pedro@codesourcery.com>
14453 * Makefile.in (install-only): Replace $IPA_DEPFILES with
14456 2010-09-01 Joel Brobecker <brobecker@adacore.com>
14458 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
14459 gdbserver/lynx-ppc-low.c: New files.
14460 * Makefile.in (lynx_low_h): New variable.
14461 (lynx-low.o, lynx-ppc-low.o): New rules.
14462 * configure.ac: On LynxOS, link with -lnetinet.
14463 * configure.srv: Add handling of powerpc-*-lynxos* targets.
14464 * configure: regenerate.
14466 2010-09-01 Joel Brobecker <brobecker@adacore.com>
14468 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
14469 * configure.ac: Add check for vasprintf and vsnprintf.
14470 * configure, config.in: Regenerate.
14471 * server.h (vasprintf, vsnprintf): Add conditional declarations.
14473 2010-09-01 Joel Brobecker <brobecker@adacore.com>
14475 * gdbreplay.c: Move include of alloca.h up, next to include of
14477 * server.h: Add include of malloc.h.
14478 * mem-break.c: Remove include of malloc.h.
14479 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
14481 2010-09-01 Joel Brobecker <brobecker@adacore.com>
14483 * Makefile.in (memmem.o): Build with -Wno-error.
14485 2010-09-01 Joel Brobecker <brobecker@adacore.com>
14487 * utils.c (xsnprintf): Make non-static.
14488 * server.h: Add xsnprintf declaration.
14489 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
14490 replace calls to snprintf by calls to xsnprintf throughout.
14492 2010-09-01 Joel Brobecker <brobecker@adacore.com>
14494 * configure.ac: Add configure check for alloca.
14495 * configure, config.in: Regenerate.
14496 * server.h: Include alloca.h if it exists.
14497 * gdbreplay.c: Include alloca.h if it exists.
14499 2010-08-28 Pedro Alves <pedro@codesourcery.com>
14501 * linux-low.c (__SIGRTMIN): Define if not already defined.
14502 (linux_create_inferior): Check for __ANDROID__ rather than
14504 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
14505 are already deferred.
14506 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
14507 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
14508 stopped and already has a pending signal to report.
14509 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
14510 a pending signal to report or is moving out of a jump pad.
14511 (linux_init_signals): Check for __ANDROID__ rather than
14514 2010-08-28 Pedro Alves <pedro@codesourcery.com>
14516 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
14517 debug_threads check. Avoid a linear search when not doing debug
14520 2010-08-27 Pedro Alves <pedro@codesourcery.com>
14522 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
14523 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
14524 (struct file_handler) <fd>: Change type to gdb_fildes_t.
14525 (process_event): Change local fd's type to gdb_fildes_t.
14526 (create_file_handler): Adjust prototype.
14527 (delete_file_handler): Adjust prototype.
14528 (handle_file_event): Adjust prototype. Use pfildes.
14529 (create_file_event): Adjsut prototype.
14530 * remote-utils.c (remote_desc, listen_desc): Change type to
14532 * server.h: New gdb_fildes_t typedef.
14533 [USE_WIN32API]: Include winsock2.h.
14534 (delete_file_handler, add_file_handler): Adjust prototypes.
14535 (pfildes): Declare.
14536 * utils.c (pfildes): New.
14538 2010-08-27 Pedro Alves <pedro@codesourcery.com>
14540 * configure.ac (build_warnings): Add -Wno-char-subscripts.
14541 * configure: Regenerate.
14543 2010-08-27 Pedro Alves <pedro@codesourcery.com>
14545 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
14546 (linux_done_accessing_memory): ... this.
14547 (linux_target_ops): Adjust.
14548 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
14549 * nto-low.c (nto_target_ops): Adjust comment.
14550 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
14551 * spu-low.c (spu_target_ops): Adjust comment.
14552 * target.h (target_ops): Rename unprepare_to_access_memory field
14553 to done_accessing_memory.
14554 (unprepare_to_access_memory): Rename to ...
14555 (done_accessing_memory): ... this.
14557 2010-08-26 Pedro Alves <pedro@codesourcery.com>
14559 * linux-low.c (linux_prepare_to_access_memory): New.
14560 (linux_unprepare_to_access_memory): New.
14561 (linux_target_ops): Install them.
14562 * server.c (read_memory): Rename to ...
14563 (gdb_read_memory): ... this. Use
14564 prepare_to_access_memory/prepare_to_access_memory.
14565 (write_memory): Rename to ...
14566 (gdb_write_memory): ... this. Use
14567 prepare_to_access_memory/prepare_to_access_memory.
14568 (handle_search_memory_1): Adjust.
14569 (process_serial_event): Adjust.
14570 * target.h (struct target_ops): New fields
14571 prepare_to_access_memory and unprepare_to_access_memory.
14572 (prepare_to_access_memory, unprepare_to_access_memory): New.
14573 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
14574 prepare_to_access_memory/prepare_to_access_memory.
14575 * nto-low.c (nto_target_ops): Adjust.
14576 * spu-low.c (spu_target_ops): Adjust.
14577 * win32-low.c (win32_target_ops): Adjust.
14579 2010-08-26 Pedro Alves <pedro@codesourcery.com>
14581 * Makefile.in (WARN_CFLAGS): Get it from configure.
14582 (WERROR_CFLAGS): New.
14583 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
14584 * configure.ac: Introduce --enable-werror, which adds -Werror to
14585 the compiler command line. Enabled by default. Disable with
14586 --disable-werror. Add -Wdeclaration-after-statement
14587 Wpointer-arith and -Wformat-nonliteral to warning flags.
14588 * configure: Regenerate.
14590 2010-08-26 Pedro Alves <pedro@codesourcery.com>
14592 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
14594 2010-08-26 Pedro Alves <pedro@codesourcery.com>
14596 * gdbreplay.c (remote_error): New.
14598 (expect): Use gdbchar. Check for error reading from GDB.
14599 Clarify sync error output.
14600 (play): Check for errors writing to GDB.
14601 * linux-low.c (sigchld_handler): Really ignore `write' errors.
14602 * remote-utils.c (getpkt): Check for errors writing to the remote
14605 2010-08-25 Pedro Alves <pedro@codesourcery.com>
14607 * linux-low.c (linux_wait_1): Move non-debugging code out of
14608 `debug_threads' control.
14610 2010-08-25 Pedro Alves <pedro@codesourcery.com>
14612 * linux-low.c (linux_wait_1): Don't set last_status here.
14613 * server.c (push_event, queue_stop_reply_callback): Assert we're
14614 not pushing a TARGET_WAITKIND_IGNORE event.
14615 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
14616 (myresume, handle_target_event): Set the thread's last_resume_kind
14617 and last_status from the target returned status.
14619 2010-08-25 Pedro Alves <pedro@codesourcery.com>
14623 * linux-x86-low.c (update_debug_registers_callback): New.
14624 (i386_dr_low_set_addr): Use it.
14625 (i386_dr_low_get_addr): New.
14626 (i386_dr_low_set_control): Use update_debug_registers_callback.
14627 (i386_dr_low_get_control): New.
14628 (i386_dr_low_get_status): Adjust.
14629 * linux-low.c (linux_stop_lwp): New.
14630 * linux-low.h (linux_stop_lwp): Declare.
14632 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
14633 argument instead of a i386_debug_reg_state.
14634 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
14635 a i386_debug_reg_state.
14636 (i386_insert_aligned_watchpoint): Adjust.
14637 (i386_remove_aligned_watchpoint): Adjust.
14638 (i386_low_stopped_data_address): Read the debug registers from the
14639 inferior instead of from the mirrors.
14640 * i386-low.h (struct i386_debug_reg_state): Extend comment.
14641 (i386_dr_low_get_addr): Declare.
14642 (i386_dr_low_get_control): Declare.
14643 (i386_dr_low_get_status): Change prototype.
14645 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
14646 (i386_dr_low_get_addr): New.
14647 (i386_dr_low_get_control): New.
14648 (i386_dr_low_get_status): Adjust prototype. Return
14650 (i386_initial_stuff): Clear dr_status_mirror and
14652 (i386_get_thread_context): Adjust.
14653 (i386_set_thread_context): Adjust.
14654 (i386_thread_added): Adjust.
14656 2010-08-24 Pedro Alves <pedro@codesourcery.com>
14658 * linux-low.h (linux_thread_area): Delete declaration.
14660 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
14662 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
14663 after its termination.
14665 2010-08-09 Pedro Alves <pedro@codesourcery.com>
14667 * linux-low.c (gdb_wants_lwp_stopped): Delete.
14668 (gdb_wants_all_stopped): Delete.
14669 (linux_wait_1): Don't call them.
14670 * server.c (handle_v_cont): Tag all threads as want-stopped.
14671 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
14672 stopped as "client-wants-stopped".
14674 2010-07-31 Pedro Alves <pedro@codesourcery.com>
14676 * Makefile.in (signals_h): New.
14677 (server_h): Depend on it.
14678 (server.o): Don't depend on $(signals_def).
14679 (signals.o): Depend on $(signals_def).
14681 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
14683 * Makefile.in (signals_def): New.
14684 (server_h): Append include/gdb/signals.h and signals_def.
14685 (server.o): Append signals_def.
14687 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
14689 * server.c (handle_target_event): Use target_signal_to_host for
14690 resume_info.sig initialization.
14691 * target.h (struct thread_resume) <sig>: New comment.
14693 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
14695 * server.c (handle_query): strcpy() the returned string from paddress()
14696 instead of sprintf().
14697 * utils.c (paddress): Return phex_nz().
14699 2010-07-07 Joel Brobecker <brobecker@adacore.com>
14701 * server.c (handle_v_cont): Call mourn_inferior if process
14703 (myresume): Likewise.
14705 2010-07-01 Pedro Alves <pedro@codesourcery.com>
14707 Static tracepoints, and integration with UST.
14709 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
14710 * mem-break.c (uninsert_all_breakpoints)
14711 (reinsert_all_breakpoints): New.
14712 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
14713 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
14714 (gdb_agent_ust_loaded, helper_thread_id)
14715 (gdb_agent_helper_thread_id): New macros.
14716 (struct ipa_sym_addresses): Add addr_ust_loaded,
14717 addr_helper_thread_id, addr_cmd_buf.
14718 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
14719 (in_process_agent_loaded_ust): New.
14720 (write_e_ust_not_loaded): New.
14721 (maybe_write_ipa_ust_not_loaded): New.
14722 (struct collect_static_trace_data_action): New.
14723 (enum tracepoint_type) <static_tracepoint>: New.
14724 (struct tracepoint) <handle>: Mention static tracepoints.
14725 (struct static_tracepoint_ctx): New.
14726 (CMD_BUF_SIZE): New.
14727 (add_tracepoint_action): Handle static tracepoint actions.
14728 (unprobe_marker_at): New.
14729 (clear_installed_tracepoints): Handle static tracepoints.
14730 (cmd_qtdp): Handle static tracepoints.
14731 (probe_marker_at): New.
14732 (cmd_qtstart): Handle static tracepoints.
14733 (response_tracepoint): Handle static tracepoints.
14734 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
14735 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
14736 (get_context_regcache): Handle static tracepoints.
14737 (do_action_at_tracepoint): Handle static tracepoint actions.
14738 (traceframe_find_block_type): Handle static trace data blocks.
14739 (traceframe_read_sdata): New.
14740 (download_tracepoints): Download static tracepoint actions.
14741 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
14742 (GDB_PROBE_NAME): New.
14744 (GET_UST_SYM): New.
14747 (ust_marker_to_static_tracepoint): New.
14749 (collect_ust_data_at_tracepoint): New.
14750 (gdb_ust_probe): New.
14751 (UNIX_PATH_MAX, SOCK_DIR): New.
14752 (gdb_ust_connect_sync_socket): New.
14753 (resume_thread, stop_thread): New.
14754 (run_inferior_command): New.
14755 (init_named_socket): New.
14756 (gdb_ust_socket_init): New.
14757 (cstr_to_hexstr): New.
14759 (first_marker, next_marker): New.
14760 (response_ust_marker): New.
14761 (cmd_qtfstm, cmd_qtsstm): New.
14762 (unprobe_marker_at, probe_marker_at): New.
14763 (cmd_qtstmat, gdb_ust_thread): New.
14764 (gdb_ust_init): New.
14765 (initialize_tracepoint_ftlib): Call gdb_ust_init.
14766 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
14767 (ST_REGENTRY): New.
14768 (x86_64_st_collect_regmap): New.
14769 (X86_64_NUM_ST_COLLECT_GREGS): New.
14770 (AMD64_RIP_REGNUM): New.
14771 (supply_static_tracepoint_registers): New.
14772 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
14773 (ST_REGENTRY): New.
14774 (i386_st_collect_regmap): New.
14775 (i386_NUM_ST_COLLECT_GREGS): New.
14776 (supply_static_tracepoint_registers): New.
14777 * server.c (handle_query): Handle qXfer:statictrace:read.
14778 <qSupported>: Report support for StaticTracepoints, and
14779 qXfer:statictrace:read features.
14780 * server.h (traceframe_read_sdata)
14781 (supply_static_tracepoint_registers): Declare.
14782 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
14783 (unpack_varlen_hex): Include in IPA build.
14784 * Makefile.in (ustlibs, ustinc): New.
14785 (IPA_OBJS): Add remote-utils-ipa.o.
14786 ($(IPA_LIB)): Link -ldl and -lpthread.
14788 (IPAGENT_CFLAGS): Add UST_CFLAGS.
14789 * config.in, configure: Regenerate.
14791 2010-06-20 Ian Lance Taylor <iant@google.com>
14792 Pedro Alves <pedro@codesourcery.com>
14794 * linux-x86-low.c (always_true): Delete.
14795 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
14796 trying to fool the compiler with always_true.
14798 2010-06-20 Pedro Alves <pedro@codesourcery.com>
14800 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
14801 conditions in gdbserver.
14803 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
14805 * spu-low.c (spu_read_memory): Wrap around local store limit.
14806 (spu_write_memory): Likewise.
14808 2010-06-15 Pedro Alves <pedro@codesourcery.com>
14810 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
14811 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
14813 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
14815 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
14816 uses with LONGEST uses.
14818 2010-06-14 Stan Shebs <stan@codesourcery.com>
14819 Pedro Alves <pedro@codesourcery.com>
14823 * linux-x86-low.c: Include limits.h.
14825 (always_true): New.
14828 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
14829 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
14830 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
14831 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
14832 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
14833 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
14834 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
14835 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
14836 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
14837 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
14838 (amd64_emit_void_call_2): New.
14839 (amd64_emit_ops): New.
14840 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
14841 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
14842 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
14843 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
14844 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
14845 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
14846 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
14847 (i386_emit_call, i386_emit_reg, i386_emit_pop)
14848 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
14849 (i386_emit_stack_adjust, i386_emit_int_call_1)
14850 (i386_emit_void_call_2): New.
14851 (i386_emit_ops): New.
14852 (x86_emit_ops): New.
14853 (the_low_target): Install x86_emit_ops.
14854 * server.h (struct emit_ops): New.
14855 (get_raw_reg_func_addr): Declare.
14856 (current_insn_ptr, emit_error): Declare.
14857 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
14858 (set_trace_state_variable_value): New defines.
14859 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
14860 addr_get_trace_state_variable_value and
14861 addr_set_trace_state_variable_value.
14862 (symbol_list): New fields for get_raw_reg,
14863 get_trace_state_variable_value and set_trace_state_variable_value.
14864 (condfn): New typedef.
14865 (struct tracepoint): New field `compiled_cond'.
14866 (do_action_at_tracepoint): Clear compiled_cond.
14867 (get_trace_state_variable_value, set_trace_state_variable_value):
14869 (condition_true_at_tracepoint): If there's a compiled condition,
14871 (current_insn_ptr, emit_error): New globals.
14872 (struct bytecode_address): New.
14873 (get_raw_reg_func_addr): New.
14874 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
14875 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
14876 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
14877 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
14878 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
14879 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
14880 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
14881 (compile_tracepoint_condition, compile_bytecodes): New.
14882 * target.h (emit_ops): Forward declare.
14883 (struct target_ops): New field emit_ops.
14884 (target_emit_ops): New.
14885 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
14886 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
14887 * linux-low.c (linux_emit_ops): New.
14888 (linux_target_ops): Install it.
14889 * linux-low.h (struct linux_target_ops): New field emit_ops.
14891 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
14893 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
14894 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
14896 2010-06-01 Pedro Alves <pedro@codesourcery.com>
14897 Stan Shebs <stan@codesourcery.com>
14899 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
14900 (all): Depend on $(extra_libraries).
14901 (install-only): Install the IPA.
14902 (IPA_OBJS, IPA_LIB): New.
14903 (clean): Remove the IPA lib.
14904 (IPAGENT_CFLAGS): New.
14905 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
14906 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
14907 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
14908 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
14909 * configure.ac: Check for atomic builtins support in the compiler.
14910 (IPA_DEPFILES, extra_libraries): Define.
14911 * configure.srv (ipa_obj): Add description.
14912 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
14913 (i[34567]86-*-linux*): Set ipa_obj.
14914 (x86_64-*-linux*): Set ipa_obj.
14915 * linux-low.c (stabilizing_threads): New.
14916 (supports_fast_tracepoints): New.
14917 (linux_detach): Stabilize threads before detaching.
14918 (handle_tracepoints): Handle internal tracing breakpoints. Assert
14919 the lwp is either not stabilizing, or is moving out of a jump pad.
14920 (linux_fast_tracepoint_collecting): New.
14921 (maybe_move_out_of_jump_pad): New.
14922 (enqueue_one_deferred_signal): New.
14923 (dequeue_one_deferred_signal): New.
14924 (linux_wait_for_event_1): If moving out of a jump pad, defer
14925 pending signals to later.
14926 (linux_stabilize_threads): New.
14927 (linux_wait_1): Check if threads need moving out of jump pads, and
14929 (stuck_in_jump_pad_callback): New.
14930 (move_out_of_jump_pad_callback): New.
14931 (lwp_running): New.
14932 (linux_resume_one_lwp): Handle moving out of jump pads.
14933 (linux_set_resume_request): Dequeue deferred signals.
14934 (need_step_over_p): Also step over fast tracepoint jumps.
14935 (start_step_over): Also uninsert fast tracepoint jumps.
14936 (finish_step_over): Also reinsert fast tracepoint jumps.
14937 (linux_install_fast_tracepoint_jump): New.
14938 (linux_target_ops): Install linux_stabilize_threads and
14939 linux_install_fast_tracepoint_jump_pad.
14940 * linux-low.h (linux_target_ops) <get_thread_area,
14941 install_fast_tracepoint_jump_pad>: New fields.
14942 (struct lwp_info) <collecting_fast_tracepoint,
14943 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
14944 (linux_get_thread_area): Declare.
14945 * linux-x86-low.c (jump_insn): New.
14946 (x86_get_thread_area): New.
14947 (append_insns): New.
14948 (push_opcode): New.
14949 (amd64_install_fast_tracepoint_jump_pad): New.
14950 (i386_install_fast_tracepoint_jump_pad): New.
14951 (x86_install_fast_tracepoint_jump_pad): New.
14952 (the_low_target): Install x86_get_thread_area and
14953 x86_install_fast_tracepoint_jump_pad.
14954 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
14955 (struct fast_tracepoint_jump): New.
14956 (fast_tracepoint_jump_insn): New.
14957 (fast_tracepoint_jump_shadow): New.
14958 (find_fast_tracepoint_jump_at): New.
14959 (fast_tracepoint_jump_here): New.
14960 (delete_fast_tracepoint_jump): New.
14961 (set_fast_tracepoint_jump): New.
14962 (uninsert_fast_tracepoint_jumps_at): New.
14963 (reinsert_fast_tracepoint_jumps_at): New.
14964 (set_breakpoint_at): Use write_inferior_memory.
14965 (uninsert_raw_breakpoint): Use write_inferior_memory.
14966 (check_mem_read): Mask out fast tracepoint jumps.
14967 (check_mem_write): Mask out fast tracepoint jumps.
14968 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
14969 (set_fast_tracepoint_jump): Declare.
14970 (delete_fast_tracepoint_jump)
14971 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
14972 (reinsert_fast_tracepoint_jumps_at): Declare.
14973 * regcache.c: Don't compile many functions when building the
14974 in-process agent library.
14975 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
14976 the register buffer in the heap.
14977 (free_register_cache): If the register buffer isn't owned by the
14978 regcache, don't free it.
14979 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
14980 pre-existing register caches.
14981 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
14983 (convert_ascii_to_int): : Constify `from' parameter type.
14984 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
14985 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
14986 the needed buffer in-place.
14987 (relocate_instruction): New.
14988 * server.c (handle_query) <qSymbols>: If the target supports
14989 tracepoints, give it a chance of looking up symbols. Report
14990 support for fast tracepoints.
14991 (handle_status): Stabilize threads.
14992 (process_serial_event): Adjust.
14993 * server.h (struct fast_tracepoint_jump): Forward declare.
14994 (struct process_info) <fast_tracepoint_jumps>: New field.
14995 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
14996 (decode_X_packet, decode_M_packet): Adjust.
14997 (relocate_instruction): Declare.
14998 (in_process_agent_loaded): Declare.
14999 (tracepoint_look_up_symbols): Declare.
15000 (struct fast_tpoint_collect_status): Declare.
15001 (fast_tracepoint_collecting): Declare.
15002 (force_unlock_trace_buffer): Declare.
15003 (handle_tracepoint_bkpts): Declare.
15004 (initialize_low_tracepoint)
15005 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
15006 * target.h (struct target_ops) <stabilize_threads,
15007 install_fast_tracepoint_jump_pad>: New fields.
15008 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
15009 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
15010 [HAVE_STDINT_H]: Include stdint.h.
15011 (trace_debug_1): Rename to ...
15012 (trace_vdebug): ... this.
15013 (trace_debug): Rename to ...
15014 (trace_debug_1): ... this. Add `level' parameter.
15015 (trace_debug): New.
15016 (ATTR_USED, ATTR_NOINLINE): New.
15017 (IP_AGENT_EXPORT): New.
15018 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
15019 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
15020 (about_to_request_buffer_space, trace_buffer_is_full)
15021 (stopping_tracepoint, expr_eval_result, error_tracepoint)
15022 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
15023 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
15024 (traceframe_write_count, traceframes_created)
15025 (trace_state_variables)
15026 New renaming defines.
15027 (struct ipa_sym_addresses): New.
15028 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
15029 (symbol_list): New.
15030 (ipa_sym_addrs): New.
15031 (all_tracepoint_symbols_looked_up): New.
15032 (in_process_agent_loaded): New.
15033 (write_e_ipa_not_loaded): New.
15034 (maybe_write_ipa_not_loaded): New.
15035 (tracepoint_look_up_symbols): New.
15036 (debug_threads) [IN_PROCESS_AGENT]: New.
15037 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
15038 (UNKNOWN_SIDE_EFFECTS): New.
15039 (stop_tracing): New.
15040 (flush_trace_buffer): New.
15041 (stop_tracing_bkpt): New.
15042 (flush_trace_buffer_bkpt): New.
15043 (read_inferior_integer): New.
15044 (read_inferior_uinteger): New.
15045 (read_inferior_data_pointer): New.
15046 (write_inferior_data_pointer): New.
15047 (write_inferior_integer): New.
15048 (write_inferior_uinteger): New.
15049 (struct collect_static_trace_data_action): Delete.
15050 (enum tracepoint_type): New.
15051 (struct tracepoint) <type>: New field `type'.
15052 <actions_str, step_actions, step_actions_str>: Only include in
15054 <orig_size, obj_addr_on_target, adjusted_insn_addr>
15055 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
15056 (tracepoints): Use IP_AGENT_EXPORT.
15057 (last_tracepoint): Don't include in the IPA.
15058 (stopping_tracepoint): Use IP_AGENT_EXPORT.
15059 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
15060 (alloced_trace_state_variables): New.
15061 (trace_state_variables): Use IP_AGENT_EXPORT.
15062 (traceframe_t): Delete unused variable.
15063 (circular_trace_buffer): Don't include in the IPA.
15064 (trace_buffer_start): Delete.
15065 (struct trace_buffer_control): New.
15066 (trace_buffer_free): Delete.
15067 (struct ipa_trace_buffer_control): New.
15068 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
15069 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
15071 (trace_buffer_ctrl): New.
15072 (TRACE_BUFFER_CTRL_CURR): New.
15073 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
15074 Reimplement as macros.
15075 (trace_buffer_wrap): Delete.
15076 (traceframe_write_count, traceframe_read_count)
15077 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
15078 (struct tracepoint_hit_ctx) <type>: New field.
15079 (struct fast_tracepoint_ctx): New.
15080 (memory_barrier): New.
15082 (record_tracepoint_error): Update atomically in the IPA.
15083 (clear_inferior_trace_buffer): New.
15084 (about_to_request_buffer_space): New.
15085 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
15086 updating the same buffer.
15087 (add_tracepoint): Default the tracepoint's type to trap
15088 tracepoint, and orig_size to -1.
15089 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
15090 internal variables.
15091 (create_trace_state_variable): New parameter `gdb'. Handle it.
15092 (clear_installed_tracepoints): Clear fast tracepoint jumps.
15093 (cmd_qtdp): Handle fast tracepoints.
15094 (cmd_qtdv): Adjust.
15095 (max_jump_pad_size): New.
15096 (gdb_jump_pad_head): New.
15097 (get_jump_space_head): New.
15098 (claim_jump_space): New.
15099 (sort_tracepoints): New.
15100 (MAX_JUMP_SIZE): New.
15101 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
15103 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
15104 support. Upload fast traceframes, and delete internal IPA
15106 (stop_tracing_handler): New.
15107 (flush_trace_buffer_handler): New.
15108 (cmd_qtstop): Upload fast tracepoints.
15109 (response_tracepoint): Handle fast tracepoints.
15110 (tracepoint_finished_step): Upload fast traceframes. Set the
15111 tracepoint hit context's tracepoint type.
15112 (handle_tracepoint_bkpts): New.
15113 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
15114 type. Add comment about fast tracepoints.
15115 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
15116 non-existing action_str field.
15117 (get_context_regcache): Handle fast tracepoints.
15118 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
15120 (fast_tracepoint_from_jump_pad_address): New.
15121 (fast_tracepoint_from_ipa_tpoint_address): New.
15122 (collecting_t): New.
15123 (force_unlock_trace_buffer): New.
15124 (fast_tracepoint_collecting): New.
15126 (gdb_collect): New.
15127 (write_inferior_data_ptr): New.
15128 (target_tp_heap): New.
15129 (target_malloc): New.
15130 (download_agent_expr): New.
15132 (download_tracepoints): New.
15133 (download_trace_state_variables): New.
15134 (upload_fast_traceframes): New.
15135 (IPA_FIRST_TRACEFRAME): New.
15136 (IPA_NEXT_TRACEFRAME_1): New.
15137 (IPA_NEXT_TRACEFRAME): New.
15138 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
15139 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
15140 (gdb_jump_pad_buffer_end): New.
15141 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
15142 (initialize_tracepoint): Adjust.
15143 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
15144 buffer. Initialize the low module.
15145 * utils.c (PREFIX, TOOLNAME): New.
15146 (malloc_failure): Use PREFIX.
15147 (error): In the IPA, an error causes an exit.
15148 (fatal, warning): Use PREFIX.
15149 (internal_error): Use TOOLNAME.
15150 (NUMCELLS): Increase to 10.
15151 * configure, config.in: Regenerate.
15153 2010-06-01 Pedro Alves <pedro@codesourcery.com>
15155 * server.c (handle_query) <qSupported>: Do two passes over the
15156 qSupported string to avoid nesting strtok.
15158 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
15160 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
15162 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
15163 -Wl,--dynamic-list.
15164 * configure: Regenerate.
15165 * proc-service.list: New.
15167 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
15169 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
15172 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
15174 * gdbreplay.c (remote_open): Check error return from socket() call by
15175 its equality to -1 not by it being negative.
15176 * remote-utils.c (remote_open): Likewise.
15178 2010-05-23 Pedro Alves <pedro@codesourcery.com>
15180 * config.h: Regenerate.
15182 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
15184 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
15185 doesn't provide PTRACE_GET_THREAD_AREA.
15187 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
15189 * linux-m68k-low.c: Include <asm/ptrace.h>
15190 (ps_get_thread_area): Implement.
15192 2010-05-03 Doug Evans <dje@google.com>
15194 * event-loop.c (struct callback_event): New struct.
15195 (callback_list): New global.
15196 (append_callback_event, delete_callback_event): New functions.
15197 (process_callback): New function.
15198 (start_event_loop): Call it.
15199 * remote-utils.c (NOT_SCHEDULED): Define.
15200 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
15201 moved out of readchar.
15202 (readchar): Rewrite. Call reschedule before returning.
15203 (reset_readchar): New function.
15204 (remote_close): Call it.
15205 (process_remaining, reschedule): New functions.
15206 * server.h (callback_handler_func): New typedef.
15207 (append_callback_event, delete_callback_event): Declare.
15209 2010-05-03 Pedro Alves <pedro@codesourcery.com>
15211 * proc-service.c (ps_pglobal_lookup): Use
15212 thread_db_look_up_one_symbol.
15213 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
15214 parameter. Use it instead of all_symbols_looked_up.
15215 * server.h (struct process_info) <all_symbols_looked_up>: Delete
15217 (all_symbols_looked_up): Don't declare.
15218 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
15219 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
15221 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
15222 Set all_symbols_looked_up here.
15223 (thread_db_look_up_one_symbol): New.
15224 (thread_db_get_tls_address): Adjust.
15225 (thread_db_load_search, try_thread_db_load_1): Always allocate the
15226 thread_db object on the heap, and tentatively set it in the
15228 (thread_db_init): Don't set all_symbols_looked_up here.
15229 * linux-low.h (thread_db_look_up_one_symbol): Declare.
15231 2010-05-03 Pedro Alves <pedro@codesourcery.com>
15233 * linux-low.c (linux_kill, linux_detach): Adjust.
15234 (status_pending_p_callback): Remove redundant statement. Check
15235 for !TARGET_WAITIKIND_IGNORE, instead of
15236 TARGET_WAITKIND_STOPPED.
15237 (handle_tracepoints): Make sure LWP is locked. Adjust.
15238 (linux_wait_for_event_1): Adjust.
15239 (linux_cancel_breakpoints): New.
15240 (unsuspend_one_lwp): New.
15241 (unsuspend_all_lwps): New.
15242 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
15243 (send_sigstop_callback): Change return type to int, add new
15244 `except' parameter and handle it.
15245 (suspend_and_send_sigstop_callback): New.
15246 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
15247 pass them down. If SUSPEND, also increment the lwp's suspend
15249 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
15250 (need_step_over_p): Don't consider suspended LWPs.
15251 (start_step_over): Adjust.
15252 (proceed_one_lwp): Change return type to int, add new `except'
15253 parameter and handle it.
15254 (unsuspend_and_proceed_one_lwp): New.
15255 (proceed_all_lwps): Use find_inferior instead of
15257 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
15258 also decrement the suspend count of LWPs. Pass `except' down,
15259 instead of hacking its suspend count.
15260 (linux_pause_all): Add `freeze' parameter. Adjust.
15261 (linux_unpause_all): New.
15262 (linux_target_ops): Install linux_unpause_all.
15263 * server.c (handle_status): Adjust.
15264 * target.h (struct target_ops): New fields `unpause_all' and
15265 `cancel_breakpoints'. Add new parameter to `pause_all'.
15266 (pause_all): Add new `freeze' parameter.
15267 (unpause_all): New.
15268 (cancel_breakpoints): New.
15269 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
15270 cancel breakpoints.
15271 (cmd_qtstart): Pause threads.
15272 (stop_tracing): Pause threads, and cancel breakpoints.
15273 * win32-low.c (win32_target_ops): Adjust.
15275 2010-05-03 Pedro Alves <pedro@codesourcery.com>
15277 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
15278 the inferior right away from here...
15279 (linux_wait_1): ... to here, and adjust to check the thread's
15280 last_resume_kind instead of the lwp's step or stop_expected flags.
15282 2010-05-02 Pedro Alves <pedro@codesourcery.com>
15284 * README: Use consistent `GDB' and `GDBserver' spellings.
15286 2010-05-02 Pedro Alves <pedro@codesourcery.com>
15288 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
15289 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
15290 (linux_detach_one_lwp): Assume the lwp is stopped.
15291 (any_thread_of): Delete.
15292 (linux_detach): Stop all lwps here. Don't blindly delete all
15294 (delete_lwp_callback): New.
15295 (linux_mourn): Delete all lwps of the process that is gone.
15296 (linux_wait_1): Don't delete the last lwp of the process here.
15297 * mem-break.h (mark_breakpoints_out): Declare.
15298 * mem-break.c (mark_breakpoints_out): New.
15299 (free_all_breakpoints): Use it.
15300 * server.c (handle_target_event): If the process is gone, mark
15302 * thread-db.c (struct thread_db) <create_bp>: New field.
15303 (thread_db_enable_reporting): Fix prototype. Store a thread event
15304 breakpoint reference in the thread_db struct.
15305 (thread_db_load_search): Clear the thread_db object.
15306 (try_thread_db_load_1): Ditto.
15307 (switch_to_process): New.
15308 (disable_thread_event_reporting): Use it.
15309 (remove_thread_event_breakpoints): New.
15310 (thread_db_detach, thread_db_mourn): Use it.
15312 2010-05-01 Pedro Alves <pedro@codesourcery.com>
15314 * linux-low.c (linux_enable_event_reporting): New.
15315 (linux_wait_for_event_1, handle_extended_wait): Use it.
15317 2010-04-30 Pedro Alves <pedro@codesourcery.com>
15319 * linux-low.c (linux_kill_one_lwp, linux_kill)
15320 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
15321 (send_sigstop): Take an lwp_info as parameter instead. Queue a
15322 SIGSTOP even if the LWP is stopped.
15323 (send_sigstop_callback): New.
15324 (stop_all_lwps): Use send_sigstop_callback instead.
15325 (linux_resume_one_thread): Adjust.
15326 (proceed_one_lwp): Still proceed an LWP that the client has
15327 requested to stop, if we haven't reported it as stopped yet. Make
15328 sure that LWPs the client want stopped, have a pending SIGSTOP.
15330 2010-04-26 Doug Evans <dje@google.com>
15332 * server.c (handle_general_set): Make static.
15334 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
15335 Print received char after testing for error/eof instead of before.
15336 (input_interrupt): Tweak comment.
15338 2010-04-23 Doug Evans <dje@google.com>
15340 * server.c (start_inferior): Print inferior argv if --debug.
15342 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
15344 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
15345 * nto-x86-low.c: Include server.h
15347 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
15349 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
15350 be consistent with other sources of this directory.
15351 (init_registers_amd64): Correct name of source file of this function
15354 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
15356 * configure.srv (x86_64-*-mingw*): New configuration for Windows
15357 64-bit executables.
15359 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
15361 * win32-i386-low.c: Add 64-bit support.
15362 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
15363 (init_registers_amd64): Declare.
15364 (mappings): Add 64-bit version of array.
15365 (init_windows_x86): New function.
15366 (the_low_target): Change init_arch field to init_windows_x86.
15368 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
15370 * win32-low.c: Adapt to support also 64-bit architecture.
15371 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
15372 (get_image_name): Use SIZE_T type for local variable `done'.
15373 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
15374 (toolhelp_get_dll_name): Idem.
15375 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
15376 Use uintptr_t typecast to avoid warning.
15377 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
15378 (handle_exception): Use phex_nz to avoid warning.
15379 (win32_wait): Remove unused local variable `process'.
15381 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
15383 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
15386 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
15388 * configure.ac: Use `ws2_32' library for srv_mingw.
15389 * configure: Regenerate.
15390 * gdbreplay.c: Include winsock2.h instead of winsock.h.
15391 * remote-utils.c: Likewise.
15393 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
15395 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
15396 if __x86_64__ is defined.
15398 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
15400 * configure: Regenerate.
15402 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
15404 * server.c (handle_query): Handle 'qGetTIBAddr' query.
15405 * target.h (target_ops): New get_tib_address field.
15406 * win32-low.h (win32_thread_info): Add thread_local_base field.
15407 * win32-low.c (child_add_thread): Add tlb argument.
15408 Set thread_local_base field to TLB.
15409 (get_child_debug_event): Adapt to child_add_thread change.
15410 (win32_get_tib_address): New function.
15411 (win32_target_ops): Set get_tib_address field to
15412 win32_get_tib_address.
15413 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
15415 2010-04-12 Pedro Alves <pedro@codesourcery.com>
15417 * linux-low.c (linux_mourn): Also remove the process.
15418 * server.c (handle_target_event): Don't remove the process here.
15419 * nto-low.c (nto_mourn): New.
15420 (nto_target_ops): Install it.
15421 * spu-low.c (spu_mourn): New.
15422 (spu_target_ops): Install it.
15423 * win32-low.c (win32_mourn): New.
15424 (win32_target_ops): Install it.
15426 2010-04-12 Pedro Alves <pedro@codesourcery.com>
15428 * server.h (buffer_xml_printf): Remove redundant `;'.
15430 2010-04-12 Pedro Alves <pedro@codesourcery.com>
15432 * regcache.c (set_register_cache): Invalidate regcaches before
15433 changing the register cache layout.
15434 (regcache_invalidate_one): Allow a NULL regcache.
15435 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
15436 regcaches before changing the register cache layout or the target
15439 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
15441 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
15442 variable warning on Linux/x86-64.
15444 2010-04-11 Pedro Alves <pedro@codesourcery.com>
15446 GDBserver disconnected tracing support.
15448 * linux-low.c (linux_remove_process): Delete.
15449 (add_lwp): Don't set last_resume_kind here.
15450 (linux_kill): Use `mourn'.
15451 (linux_detach): Use `thread_db_detach', and `mourn'.
15452 (linux_mourn): New.
15453 (linux_attach_lwp_1): Adjust comment.
15454 (linux_attach): last_resume_kind moved the thread_info; adjust.
15455 (status_pending_p_callback): Adjust.
15456 (linux_wait_for_event_1): Adjust.
15457 (count_events_callback, select_singlestep_lwp_callback)
15458 (select_event_lwp_callback, cancel_breakpoints_callback)
15459 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
15460 (proceed_one_lwp): Adjust.
15461 (linux_async): Add debug output.
15462 (linux_thread_stopped): New.
15463 (linux_pause_all): New.
15464 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
15466 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
15467 (thread_db_free): Delete declaration.
15468 (thread_db_detach, thread_db_mourn): Declare.
15469 * thread-db.c (thread_db_init): Use thread_db_mourn.
15470 (thread_db_free): Delete, split in two.
15471 (disable_thread_event_reporting): New.
15472 (thread_db_detach): New.
15473 (thread_db_mourn): New.
15475 * server.h (struct thread_info) <last_resume_kind>: New field.
15476 <attached>: Add comment.
15477 <gdb_detached>: New field.
15478 (handler_func): Change return type to int.
15479 (handle_serial_event, handle_target_event): Ditto.
15480 (gdb_connected): Declare.
15482 (disconnected_tracing): Declare.
15483 (stop_tracing): Declare.
15485 * server.c (handle_query) <qSupported>: Report support for
15486 disconnected tracing.
15487 (queue_stop_reply_callback): Account for running threads.
15488 (gdb_wants_thread_stopped): New.
15489 (gdb_wants_all_threads_stopped): New.
15490 (gdb_reattached_process): New.
15491 (handle_status): Clear the `gdb_detached' flag of all processes.
15492 In all-stop, stop all threads.
15493 (main): Be sure to leave tfind mode. Handle disconnected tracing.
15494 (process_serial_event): If the remote connection breaks, or if an
15495 exit was forced with "monitor exit", force an event loop exit.
15496 Handle disconnected tracing on detach.
15497 (handle_serial_event): Adjust.
15498 (handle_target_event): If GDB isn't connected, forward events back
15499 to the inferior, unless the last process exited, in which case,
15500 exit gdbserver. Adjust interface.
15502 * remote-utils.c (remote_open): Don't block in accept. Instead
15503 register an event loop source on the listen socket file
15504 descriptor. Refactor bits into ...
15505 (listen_desc): ... this new global.
15506 (gdb_connected): ... this new function.
15507 (enable_async_notification): ... this new function.
15508 (handle_accept_event): ... this new function.
15509 (remote_close): Clear remote_desc.
15511 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
15513 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
15515 (mourn_inferior): Define.
15516 (target_process_qsupported): Avoid the dangling else problem.
15517 (thread_stopped): Define.
15518 (pause_all): Define.
15519 (target_waitstatus_to_string): Declare.
15520 * target.c (target_waitstatus_to_string): New.
15522 * tracepoint.c (tracing): Make extern.
15523 (disconnected_tracing): New.
15524 (stop_tracing): Make extern. Handle tracing stops due to GDB
15526 (cmd_qtdisconnected): New.
15527 (cmd_qtstatus): Report disconnected tracing status in trace reply.
15528 (handle_tracepoint_general_set): Handle QTDisconnected.
15530 * event-loop.c (event_handler_func): Change return type to int.
15531 (process_event): Bail out if the event handler wants the event
15533 (handle_file_event): Ditto.
15534 (start_event_loop): Bail out if the event handler wants the event
15537 * nto-low.c (nto_target_ops): Adjust.
15538 * spu-low.c (spu_wait): Don't remove the process here.
15539 (spu_target_ops): Adjust.
15540 * win32-low.c (win32_wait): Don't remove the process here.
15541 (win32_target_ops): Adjust.
15543 2010-04-11 Pedro Alves <pedro@codesourcery.com>
15545 * regcache.c (realloc_register_cache): Invalidate inferior's
15546 regcache before recreating it.
15548 2010-04-09 Pedro Alves <pedro@codesourcery.com>
15550 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
15552 2010-04-09 Stan Shebs <stan@codesourcery.com>
15553 Pedro Alves <pedro@codesourcery.com>
15555 * server.h (LONGEST): New.
15556 (struct thread_info) <while_stepping>: New field.
15557 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
15559 (initialize_tracepoint, handle_tracepoint_general_set)
15560 (handle_tracepoint_query, tracepoint_finished_step)
15561 (tracepoint_was_hit, release_while_stepping_state_list):
15562 (current_traceframe): Declare.
15563 * server.c (handle_general_set): Handle tracepoint packets.
15564 (read_memory): New.
15565 (write_memory): New.
15566 (handle_search_memory_1): Use read_memory.
15567 (handle_query): Report support for conditional tracepoints, trace
15568 state variables, and tracepoint sources. Handle tracepoint
15570 (main): Initialize the tracepoints module.
15571 (process_serial_event): Handle traceframe reads/writes.
15573 * linux-low.c (handle_tracepoints): New.
15574 (linux_wait_1): Call it.
15575 (linux_resume_one_lwp): Handle while-stepping.
15576 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
15577 (linux_target_ops): Install them.
15578 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
15580 * linux-x86-low.c (x86_supports_tracepoints): New.
15581 (the_low_target). Install it.
15583 * mem-break.h (delete_breakpoint): Declare.
15584 * mem-break.c (delete_breakpoint): Make external.
15586 * target.h (struct target_ops): Add `supports_tracepoints',
15587 `read_pc', and `write_pc' fields.
15588 (target_supports_tracepoints): Define.
15589 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
15592 * regcache.h (struct regcache) <registers_owned>: New field.
15593 (init_register_cache, regcache_cpy): Declare.
15594 (regcache_read_pc, regcache_write_pc): Declare.
15595 (register_cache_size): Declare.
15596 (supply_regblock): Declare.
15597 * regcache.c (init_register_cache): New.
15598 (new_register_cache): Use it.
15599 (regcache_cpy): New.
15600 (register_cache_size): New.
15601 (supply_regblock): New.
15602 (regcache_read_pc, regcache_write_pc): New.
15604 * tracepoint.c: New.
15606 * Makefile.in (OBS): Add tracepoint.o.
15607 (tracepoint.o): New rule.
15609 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
15611 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
15613 (i386-mmx.c): Likewise.
15614 (i386-mmx-linux.o): Likewise.
15615 (i386-mmx-linux.c): Likewise.
15617 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
15618 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
15619 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
15620 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
15622 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
15623 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
15624 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
15626 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
15628 * Makefile.in (clean): Updated.
15630 (i386-avx.c): Likewise.
15631 (i386-avx-linux.o): Likewise.
15632 (i386-avx-linux.c): Likewise.
15633 (amd64-avx.o): Likewise.
15634 (amd64-avx.c): Likewise.
15635 (amd64-avx-linux.o): Likewise.
15636 (amd64-avx-linux.c): Likewise.
15638 * configure.srv (srv_i386_regobj): Add i386-avx.o.
15639 (srv_i386_linux_regobj): Add i386-avx-linux.o.
15640 (srv_amd64_regobj): Add amd64-avx.o.
15641 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
15642 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
15643 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
15644 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
15645 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
15646 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
15647 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
15649 * i387-fp.c: Include "i386-xstate.h".
15651 (i387_cache_to_xsave): Likewise.
15652 (i387_xsave_to_cache): Likewise.
15653 (x86_xcr0): Likewise.
15655 * i387-fp.h (i387_cache_to_xsave): Likewise.
15656 (i387_xsave_to_cache): Likewise.
15657 (x86_xcr0): Likewise.
15659 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
15660 * linux-crisv32-low.c (target_regsets): Likewise.
15661 * linux-m68k-low.c (target_regsets): Likewise.
15662 * linux-mips-low.c (target_regsets): Likewise.
15663 * linux-ppc-low.c (target_regsets): Likewise.
15664 * linux-s390-low.c (target_regsets): Likewise.
15665 * linux-sh-low.c (target_regsets): Likewise.
15666 * linux-sparc-low.c (target_regsets): Likewise.
15667 * linux-xtensa-low.c (target_regsets): Likewise.
15669 * linux-low.c: Include <sys/uio.h>.
15670 (regsets_fetch_inferior_registers): Support nt_type.
15671 (regsets_store_inferior_registers): Likewise.
15672 (linux_process_qsupported): New.
15673 (linux_target_ops): Add linux_process_qsupported.
15675 * linux-low.h (regset_info): Add nt_type.
15676 (linux_target_ops): Add process_qsupported.
15678 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
15680 (init_registers_i386_avx_linux): New.
15681 (init_registers_amd64_avx_linux): Likewise.
15682 (xmltarget_i386_linux_no_xml): Likewise.
15683 (xmltarget_amd64_linux_no_xml): Likewise.
15684 (PTRACE_GETREGSET): Likewise.
15685 (PTRACE_SETREGSET): Likewise.
15686 (x86_fill_xstateregset): Likewise.
15687 (x86_store_xstateregset): Likewise.
15688 (use_xml): Likewise.
15689 (x86_linux_update_xmltarget): Likewise.
15690 (x86_linux_process_qsupported): Likewise.
15691 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
15692 (x86_arch_setup): Don't call init_registers_amd64_linux nor
15693 init_registers_i386_linux here. Call
15694 x86_linux_update_xmltarget.
15695 (the_low_target): Add x86_linux_process_qsupported.
15697 * server.c (handle_query): Call target_process_qsupported.
15699 * target.h (target_ops): Add process_qsupported.
15700 (target_process_qsupported): New.
15702 2010-04-03 Pedro Alves <pedro@codesourcery.com>
15704 * inferiors.c (add_thread): Set last_status kind to
15705 TARGET_WAITKIND_IGNORE.
15706 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
15707 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
15708 (linux_wait_1): Move `thread' local definition to block that uses
15709 it. Don't NULL initialize `event_child'.
15710 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
15711 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
15712 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
15714 2010-04-01 Pedro Alves <pedro@codesourcery.com>
15716 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
15717 an extended waitstatus, or by a watchpoint.
15718 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
15719 thread was stepping or has been stopped by a watchpoint.
15721 2010-04-01 Pedro Alves <pedro@codesourcery.com>
15723 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
15724 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
15725 of another, then delete the previous, and validate all
15727 (validate_inserted_breakpoint): New.
15728 (delete_disabled_breakpoints): New.
15729 (validate_breakpoints): New.
15730 (check_mem_read): Validate breakpoints before trusting their
15731 shadow. Delete disabled breakpoints.
15732 (check_mem_write): Validate breakpoints before trusting they
15733 should be inserted. Delete disabled breakpoints.
15734 * mem-break.h (validate_breakpoints):
15735 * server.c (handle_query): Validate breakpoints when we see a
15738 2010-04-01 Pedro Alves <pedro@codesourcery.com>
15740 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
15741 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
15742 if we could tell there's a GDB breakpoint at stop_pc.
15743 (need_step_over_p): Don't do a step over if we find a GDB
15744 breakpoint at the resume PC.
15746 * mem-break.c (struct raw_breakpoint): New.
15747 (enum bkpt_type): New type `gdb_breakpoint'.
15748 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
15749 fields. New field `raw'.
15750 (find_raw_breakpoint_at): New.
15751 (set_raw_breakpoint_at): Handle refcounting. Create a raw
15752 breakpoint instead.
15753 (set_breakpoint_at): Adjust.
15754 (delete_raw_breakpoint): New.
15755 (release_breakpoint): New.
15756 (delete_breakpoint): Rename to...
15757 (delete_breakpoint_1): ... this. Add proc parameter. Use
15758 release_breakpoint. Return ENOENT.
15759 (delete_breakpoint): Reimplement.
15760 (find_breakpoint_at): Delete.
15761 (find_gdb_breakpoint_at): New.
15762 (delete_breakpoint_at): Delete.
15763 (set_gdb_breakpoint_at): New.
15764 (delete_gdb_breakpoint_at): New.
15765 (gdb_breakpoint_here): New.
15766 (set_reinsert_breakpoint): Use release_breakpoint.
15767 (uninsert_breakpoint): Rename to ...
15768 (uninsert_raw_breakpoint): ... this.
15769 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
15770 (reinsert_raw_breakpoint): Change parameter type to
15772 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
15774 (check_breakpoints): Adjust. Use release_breakpoint.
15775 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
15776 (breakpoint_inserted_here): Ditto.
15777 (check_mem_read): Adjust to iterate over raw breakpoints instead.
15778 Don't trust the breakpoint's shadow if it is not inserted.
15779 (check_mem_write): Adjust to iterate over raw breakpoints instead.
15780 (delete_all_breakpoints): Adjust.
15781 (free_all_breakpoints): Mark all breakpoints as uninserted, and
15782 use delete_breakpoint_1.
15784 * mem-break.h (breakpoints_supported): Delete declaration.
15785 (set_gdb_breakpoint_at): Declare.
15786 (gdb_breakpoint_here): Declare.
15787 (delete_breakpoint_at): Delete.
15788 (delete_gdb_breakpoint_at): Declare.
15790 * server.h (struct raw_breakpoint): Forward declare.
15791 (struct process_info): New field `raw_breakpoints'.
15793 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
15796 2010-03-24 Pedro Alves <pedro@codesourcery.com>
15798 * linux-low.c (status_pending_p_callback): Fix comment.
15799 (linux_wait_for_event_1): Move most of the internal breakpoint
15800 handling from here...
15801 (linux_wait_1): ... to here.
15802 (count_events_callback): New.
15803 (select_singlestep_lwp_callback): New.
15804 (select_event_lwp_callback): New.
15805 (cancel_breakpoints_callback): New.
15806 (select_event_lwp): New.
15807 (linux_wait_1): Simplify internal breakpoint handling. Give equal
15808 priority to all LWPs that have had events that should be reported
15809 to the client. Cancel breakpoints when about to reporting the
15810 event to the client, not while stopping lwps. No longer cancel
15811 finished single-steps here.
15812 (cancel_finished_single_step): Delete.
15813 (cancel_finished_single_steps): Delete.
15815 2010-03-24 Pedro Alves <pedro@codesourcery.com>
15817 * mem-break.c (enum bkpt_type): New.
15818 (struct breakpoint): New field `type'.
15819 (set_breakpoint_at): Change return type to struct breakpoint
15820 pointer. Set type to `other_breakpoint' by default.
15821 (delete_breakpoint): Rewrite, supporting more than one breakpoint
15822 in the breakpoint list.
15823 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
15824 (reinsert_breakpoint): Rename to ...
15825 (reinsert_raw_breakpoint): ... this.
15826 (reinsert_breakpoints_at): Adjust.
15827 * mem-break.h (struct breakpoint): Declare.
15828 (set_breakpoint_at): Change return type to struct breakpoint
15831 2010-03-24 Pedro Alves <pedro@codesourcery.com>
15833 * server.c (handle_query): Assign, not compare.
15835 2010-03-24 Pedro Alves <pedro@codesourcery.com>
15837 Teach linux gdbserver to step-over-breakpoints.
15839 * linux-low.c (can_hardware_single_step): New.
15840 (supports_breakpoints): New.
15841 (handle_extended_wait): If stopping threads, read the stop pc of
15842 the new cloned LWP.
15844 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
15845 low target doesn't support retrieving the PC.
15846 (add_lwp): Set last_resume_kind to resume_continue.
15847 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
15848 (linux_attach): Don't clear stop_expected. Set the lwp's
15849 last_resume_kind to resume_stop.
15850 (linux_detach_one_lwp): Don't check for removed breakpoints.
15851 (check_removed_breakpoint): Delete.
15852 (status_pending_p): Rename to ...
15853 (status_pending_p_callback): ... this. Don't check for removed
15854 breakpoints. Don't consider threads that are stopped from GDB's
15856 (linux_wait_for_lwp): Always read the stop_pc here.
15857 (cancel_breakpoint): New.
15858 (step_over_bkpt): New global.
15859 (linux_wait_for_event_1): Implement stepping over breakpoints.
15860 (gdb_wants_lwp_stopped): New.
15861 (gdb_wants_all_stopped): New.
15862 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
15863 single-step traps here. Store the thread's last reported target
15865 (send_sigstop): Don't clear stop_expected. Always set it,
15867 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
15868 (cancel_finished_single_step): New.
15869 (cancel_finished_single_steps): New.
15870 (wait_for_sigstop): Don't cancel finished single-step traps here.
15871 (linux_resume_one_lwp): Don't check for removed breakpoints.
15872 Don't set `step' on non-hardware step archs.
15873 (linux_set_resume_request): Ignore resume_stop requests if already
15874 stopping or stopped. Set the lwp's last_resume_kind.
15875 (resume_status_pending_p): Don't check for removed breakpoints.
15876 (need_step_over_p): New.
15877 (start_step_over): New.
15878 (finish_step_over): New.
15879 (linux_resume_one_thread): Always queue a sigstop for resume_stop
15880 requests. Clear the thread's last reported target waitstatus.
15881 Don't use the `suspended' flag. Don't consider pending breakpoints.
15882 (linux_resume): Start a step-over if necessary.
15883 (proceed_one_lwp): New.
15884 (proceed_all_lwps): New.
15885 (unstop_all_lwps): New.
15886 * linux-low.h (struct lwp_info): Rewrite comment for the
15887 `suspended' flag. Add the `stop_pc' field. Delete the
15888 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
15889 Add `'last_resume_kind' and `need_step_over' fields.
15890 * inferiors.c (struct thread_info): Delete, moved elsewhere.
15891 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
15892 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
15893 (set_raw_breakpoint_at): New.
15894 (set_breakpoint_at): Rewrite to use it.
15895 (reinsert_breakpoint_handler): Delete.
15896 (set_reinsert_breakpoint): New.
15897 (reinsert_breakpoint_by_bp): Delete.
15898 (delete_reinsert_breakpoints): New.
15899 (uninsert_breakpoint): Rewrite.
15900 (uninsert_breakpoints_at): New.
15901 (reinsert_breakpoint): Rewrite.
15902 (reinsert_breakpoints_at): New.
15903 (check_breakpoints): Rewrite.
15904 (breakpoint_here): New.
15905 (breakpoint_inserted_here): New.
15906 (check_mem_read): Adjust.
15907 * mem-break.h (breakpoints_supported, breakpoint_here)
15908 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
15909 (reinsert_breakpoint_by_bp): Delete declaration.
15910 (delete_reinsert_breakpoints): Declare.
15911 (reinsert_breakpoint): Delete declaration.
15912 (reinsert_breakpoints_at): Declare.
15913 (uninsert_breakpoint): Delete declaration.
15914 (uninsert_breakpoints_at): Declare.
15915 (check_breakpoints): Adjust prototype.
15916 * server.h: Adjust include order.
15917 (struct thread_info): Declare here. Add a `last_status' field.
15919 2010-03-23 Michael Snyder <msnyder@vmware.com>
15921 * server.c (crc32): New function.
15922 (handle_query): Add handling for 'qCRC:' request.
15924 2010-03-23 Pedro Alves <pedro@codesourcery.com>
15926 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
15927 lwp had been stopped by a watchpoint.
15929 2010-03-16 Pedro Alves <pedro@codesourcery.com>
15931 * server.h (internal_error): Declare.
15932 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
15933 * utils.c (internal_error): New function.
15935 2010-03-15 Andreas Schwab <schwab@redhat.com>
15937 * configure.srv: Fix typo setting srv_regobj.
15939 2010-03-15 Pedro Alves <pedro@codesourcery.com>
15941 * linux-low.c (fetch_register): Avoid passing a non string literal
15943 (usr_store_inferior_registers): Ditto.
15945 2010-03-14 Pedro Alves <pedro@codesourcery.com>
15947 * linux-low.c (linux_write_memory): Bail out early if peeking
15950 2010-03-14 Pedro Alves <pedro@codesourcery.com>
15952 * linux-low.h (struct lwp_info): New fields
15953 `stopped_by_watchpoint' and `stopped_data_address'.
15954 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
15955 here, and cache them in the lwp object.
15956 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
15958 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
15960 (linux_stopped_by_watchpoint): Rewrite.
15961 (linux_stopped_data_address): Rewrite.
15963 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
15965 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
15966 switching the current inferior, not before.
15968 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
15970 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
15971 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
15972 i386-linux.c and amd64-linux.c.
15973 (reg-i386.o): Removed.
15974 (reg-i386.c): Likewise.
15975 (reg-i386-linux.o): Likewise.
15976 (reg-i386-linux.c): Likewise.
15977 (reg-x86-64.o): Likewise.
15978 (reg-x86-64.c): Likewise.
15979 (reg-x86-64-linux.o): Likewise.
15980 (reg-x86-64-linux.c): Likewise.
15982 (i386.c): Likewise.
15983 (i386-linux.o): Likewise.
15984 (i386-linux.c): Likewise.
15985 (amd64.o): Likewise.
15986 (amd64.c): Likewise.
15987 (amd64-linux.o): Likewise.
15988 (amd64-linux.c): Likewise.
15990 * configure.srv (srv_i386_regobj): New.
15991 (srv_i386_linux_regobj): Likewise.
15992 (srv_amd64_regobj): Likewise.
15993 (srv_amd64_linux_regobj): Likewise.
15994 (srv_i386_32bit_xmlfiles): Likewise.
15995 (srv_i386_64bit_xmlfiles): Likewise.
15996 (srv_i386_xmlfiles): Likewise.
15997 (srv_amd64_xmlfiles): Likewise.
15998 (srv_i386_linux_xmlfiles): Likewise.
15999 (srv_amd64_linux_xmlfiles): Likewise.
16000 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
16001 srv_xmlfiles to $srv_i386_xmlfiles.
16002 (i[34567]86-*-mingw32ce*): Likewise.
16003 (i[34567]86-*-mingw*): Likewise.
16004 (i[34567]86-*-nto*): Likewise.
16005 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
16006 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
16007 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
16008 (x86_64-*-linux*): Likewise.
16010 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
16011 (init_registers_amd64_linux): New.
16012 (x86_arch_setup): Replace init_registers_x86_64_linux with
16013 init_registers_amd64_linux.
16015 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
16017 * configure.ac: Check for libdl. If it is not available link against
16018 static libthread_db.
16019 * configure: Regenerate.
16021 2010-02-22 Pedro Alves <pedro@codesourcery.com>
16025 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
16026 handing a read watchpoint.
16027 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
16029 2010-02-12 Doug Evans <dje@google.com>
16031 * linux-low.c (linux_supports_tracefork_flag): Document.
16032 (linux_look_up_symbols): Add comment.
16034 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
16036 * regcache.c (supply_register): Clear regcache if buf is NULL.
16038 2010-02-02 Nicolas Roche <roche@sourceware.org>
16039 Joel Brobecker <brobecker@adacore.com>
16041 * inferiors.c (find_inferior): Add function documentation.
16042 (unloaded_dll): Handle the case where the unloaded dll has not
16043 been previously registered in the dll list.
16045 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
16047 * linux-arm-low.c (thumb_breakpoint_len): Delete.
16048 (thumb2_breakpoint): New.
16049 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
16051 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
16053 * linux-low.c (get_stop_pc): Check for SIGTRAP.
16054 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
16057 2010-01-21 Pedro Alves <pedro@codesourcery.com>
16059 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
16061 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
16063 * linux-s390-low.c (s390_collect_ptrace_register)
16064 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
16066 2010-01-21 Doug Evans <dje@google.com>
16068 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
16069 (PTRACE_ARG4_TYPE): New macro.
16070 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
16071 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
16072 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
16073 (usr_store_inferior_registers): Ditto.
16074 (linux_read_memory, linux_write_memory): Ditto.
16075 (linux_test_for_tracefork): Ditto.
16077 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
16078 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
16080 2010-01-21 Pedro Alves <pedro@codesourcery.com>
16082 * proc-service.c (ps_lgetregs): Don't refetch registers from the
16085 2010-01-21 Pedro Alves <pedro@codesourcery.com>
16087 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
16088 prototype to take a regcache. Adjust.
16090 2010-01-20 Pedro Alves <pedro@codesourcery.com>
16092 * regcache.h (struct thread_info): Forward declare.
16093 (struct regcache): New.
16094 (new_register_cache): Adjust prototype.
16095 (get_thread_regcache): Declare.
16096 (free_register_cache): Adjust prototype.
16097 (registers_to_string, registers_from_string): Ditto.
16098 (supply_register, supply_register_by_name, collect_register)
16099 (collect_register_as_string, collect_register_by_name): Ditto.
16100 * regcache.c (struct inferior_regcache_data): Delete.
16101 (get_regcache): Rename to ...
16102 (get_thread_regcache): ... this. Adjust. Switch inferior before
16103 fetching registers.
16104 (regcache_invalidate_one): Adjust.
16105 (regcache_invalidate): Fix prototype.
16106 (new_register_cache): Return the new register cache.
16107 (free_register_cache): Change prototype.
16108 (realloc_register_cache): Adjust.
16109 (registers_to_string): Change prototype to take a regcache. Adjust.
16110 (registers_from_string): Ditto.
16111 (register_data): Ditto.
16112 (supply_register): Ditto.
16113 (supply_register_by_name): Ditto.
16114 (collect_register): Ditto.
16115 (collect_register_as_string): Ditto.
16116 (collect_register_by_name): Ditto.
16117 * server.c (process_serial_event): Adjust.
16118 * linux-low.h (regset_fill_func, regset_store_func): Change
16120 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
16122 * linux-low.c (get_stop_pc): Adjust.
16123 (check_removed_breakpoint): Adjust.
16124 (linux_wait_for_event): Adjust.
16125 (linux_resume_one_lwp): Adjust.
16126 (fetch_register): Add regcache parameter. Adjust.
16127 (usr_store_inferior_registers): Ditto.
16128 (regsets_fetch_inferior_registers): Ditto.
16129 (regsets_store_inferior_registers): Ditto.
16130 (linux_fetch_registers, linux_store_registers): Ditto.
16131 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
16133 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
16135 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
16136 prototype to take a regcache.
16137 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
16138 * remote-utils.c (convert_ascii_to_int, outreg)
16139 (prepare_resume_reply): Change prototype to take a regcache.
16141 * target.h (struct target_ops) <fetch_registers, store_registers>:
16142 Change prototype to take a regcache.
16143 (fetch_inferior_registers, store_inferior_registers): Change
16144 prototype to take a regcache. Adjust.
16145 * proc-service.c (ps_lgetregs): Adjust.
16146 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
16147 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
16148 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
16149 take a regcache. Adjust.
16150 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
16151 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
16152 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
16153 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
16154 * linux-cris-low.c (cris_get_pc, cris_set_pc)
16155 (cris_cannot_fetch_register):
16156 (cris_breakpoint_at): Change prototype to take a regcache.
16158 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
16159 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
16160 to take a regcache. Adjust.
16161 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
16163 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
16164 take a regcache. Adjust.
16165 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
16166 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
16167 (m68k_set_pc): Change prototype to take a regcache. Adjust.
16168 * linux-mips-low.c (mips_get_pc):
16169 (mips_set_pc): Change prototype to take a regcache. Adjust.
16170 (mips_reinsert_addr): Adjust.
16171 (mips_collect_register): Change prototype to take a regcache.
16173 (mips_supply_register):
16174 (mips_collect_register_32bit, mips_supply_register_32bit)
16175 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
16176 (mips_store_fpregset): Ditto.
16177 * linux-ppc-low.c (ppc_supply_ptrace_register)
16178 (ppc_supply_ptrace_register): Ditto.
16179 (parse_spufs_run): Adjust.
16180 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
16181 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
16182 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
16183 take a regcache. Adjust.
16184 * linux-s390-low.c (s390_collect_ptrace_register)
16185 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
16186 (s390_set_pc): Change prototype to take a regcache. Adjust.
16187 (s390_arch_setup): Adjust.
16188 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
16189 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
16190 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
16191 (sparc_fill_gregset, sparc_store_gregset_from_stack)
16192 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
16194 (sparc_breakpoint_at): Adjust.
16195 * linux-xtensa-low.c (xtensa_fill_gregset):
16196 (xtensa_store_gregset):
16197 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
16198 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
16199 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
16200 prototype to take a regcache. Adjust.
16201 * win32-arm-low.c (arm_fetch_inferior_register)
16202 (arm_store_inferior_register): Change prototype to take a
16204 * win32-i386-low.c (i386_fetch_inferior_register)
16205 (i386_store_inferior_register): Change prototype to take a
16207 * win32-low.c (child_fetch_inferior_registers)
16208 (child_store_inferior_registers): Change prototype to take a
16210 (win32_wait): Adjust.
16211 (win32_fetch_inferior_registers): Change prototype to take a
16213 (win32_store_inferior_registers): Adjust.
16214 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
16215 store_inferior_register>: Change prototype to take a regcache.
16217 2010-01-20 Doug Evans <dje@google.com>
16219 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
16221 (linux_wait_for_event1, linux_init_signals): Ditto.
16222 (W_STOPCODE): Provide definition if missing.
16224 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
16226 * linux-low.c (linux_core_of_thread): New.
16227 (compare_ints, show_process, list_threads): New.
16228 (linux_qxfer_osdata): Report threads and cores.
16229 (linux_target_op): Register linux_core_of_thread.
16230 * remote-utils.c (prepare_resume_reply): Report the core.
16231 (buffer_xml_printf): Support %d specifier.
16232 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
16234 (handle_query): Handle qXfer:threads. Announce availability
16236 * target.h (struct target_ops): New field core_of_thread.
16238 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
16240 * Makefile.in (clean): Remove new generated files.
16241 (reg-s390.o, reg-s390.c): Remove rules.
16242 (reg-s390x.o, reg-s390x.c): Likewise.
16243 (s390-linux32.o, s390-linux32.c): Add rules.
16244 (s390-linux64.o, s390-linux64.c): Likewise.
16245 (s390x-linux64.o, s390x-linux64.c): Likewise.
16246 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
16247 * linux-s390-low.c: Include <elf.h>.
16248 (HWCAP_S390_HIGH_GPRS): Define if undefined.
16249 (init_registers_s390): Remove prototype.
16250 (init_registers_s390x): Likewise.
16251 (init_registers_s390_linux32): Add prototype.
16252 (init_registers_s390_linux64): Likewise.
16253 (init_registers_s390x_linux64): Likewise.
16254 (s390_num_regs_3264): New define.
16255 (s390_regmap_3264): New global variable.
16256 (s390_cannot_fetch_register): Remove obsolete check.
16257 (s390_cannot_store_register): Likewise.
16258 (s390_collect_ptrace_register): Handle upper/lower register halves.
16259 (s390_supply_ptrace_register): Likewise.
16260 (s390_fill_gregset): Update to register number changes.
16261 (s390_get_hwcap): New routine.
16262 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
16263 Install appropriate regmap and register set.
16265 2010-01-01 Joel Brobecker <brobecker@adacore.com>
16267 * server.c (gdbserver_version): Update copyright year to 2010.
16268 * gdbreplay.c (gdbreplay_version): Likewise.
16270 2009-12-28 Doug Evans <dje@google.com>
16272 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
16273 elf/external.h. Include <elf.h> instead but only if necessary.
16275 2009-12-28 Pedro Alves <pedro@codesourcery.com>
16277 * linux-low.c (linux_remove_process): Remove `detaching'
16278 parameter. Don't release/detach from thread_db here.
16279 (linux_kill): Release/detach from thread_db here, ...
16280 (linux_detach): ... and here, before actually detaching.
16281 (linux_wait_1): ... and here, when a process exits.
16282 * thread-db.c (any_thread_of): New.
16283 (thread_db_free): Switch the current inferior to a thread of the
16286 2009-12-21 Doug Evans <dje@google.com>
16288 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
16290 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
16291 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
16292 warning ifndef __NR_tkill. Move setting of errno there too.
16293 Delete unnecessary resetting of errno after syscall.
16294 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
16296 * configure.ac: Check for dladdr.
16297 * config.in: Regenerate.
16298 * configure: Regenerate.
16299 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
16300 (try_thread_db_load): Update.
16302 * linux-low.c (my_waitpid): Delete unnecessary prototype.
16304 2009-12-18 Doug Evans <dje@google.com>
16306 * event-loop.c: Include unistd.h if it exists.
16308 * linux-low.c (my_waitpid): Move definition away from being in
16309 between linux_tracefork_child/linux_test_for_tracefork.
16311 * gdb_proc_service.h (psaddr_t): Fix type.
16312 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
16313 signature to match glibc.
16315 2009-12-16 Doug Evans <dje@google.com>
16317 * linux-low.c (linux_read_memory): Fix argument to read.
16319 2009-11-26 Pedro Alves <pedro@codesourcery.com>
16321 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
16322 events, don't leave current_inferior pointing at null.
16324 2009-11-26 Pedro Alves <pedro@codesourcery.com>
16326 * win32-low.c (LOG): Delete.
16327 (OUTMSG): Output to stderr.
16328 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
16329 on compile time LOG macro.
16330 (win32_wait): Fix debug output.
16332 2009-11-26 Pedro Alves <pedro@codesourcery.com>
16334 * win32-low.c (win32_add_one_solib): If the dll name is
16335 "ntdll.dll", prepend the system directory to the dll path.
16337 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
16339 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
16341 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
16342 Vladimir Prus <vladimir@codesourcery.com>
16344 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
16345 * configure.ac: Check for __mcoldfire__ and set
16346 gdb_cv_m68k_is_coldfire.
16347 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
16348 reg-cf.o and reg-m68k.o.
16349 * configure: Regenerated.
16351 2009-11-16 Pedro Alves <pedro@codesourcery.com>
16353 * linux-low.c (linux_remove_process): Add `detaching' parameter.
16354 Pass it to thread_db_free.
16355 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
16356 proper `detaching' argument to linux_remove_process.
16357 * linux-low.h (thread_db_free): Add `detaching' parameter.
16358 * thread-db.c (thread_db_init): Pass false as `detaching' argument
16360 (thread_db_free): Add `detaching' parameter. Only
16361 call td_ta_clear_event if detaching from process.
16363 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
16365 * thread-db.c (thread_db_free): Fix typo.
16367 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
16370 * thread-db.c (thread_db_free): Call td_ta_clear_event.
16372 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
16374 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
16375 with an i686 compiler.
16376 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
16378 * configure: Rebuilt.
16380 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
16384 * server.c (handle_search_memory_1): Correct read_addr initialization
16385 in loop for searching subsequent chunks.
16387 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
16389 * configure.ac: New --with-libthread-db option.
16390 * thread-db.c: Allow direct dependence on libthread_db.
16391 (thread_db_free): Adjust.
16392 * config.in: Regenerate.
16393 * configure: Likewise.
16395 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
16398 * thread-db.c (attach_thread): New function.
16399 (maybe_attach_thread): Return success/failure.
16400 (find_new_threads_callback): Adjust.
16401 (thread_db_find_new_threads): Loop until no new threads.
16403 2009-10-13 Pedro Alves <pedro@codesourcery.com>
16405 * proc-service.c (ps_lgetregs): Formatting.
16407 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
16409 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
16410 * configure.ac: Adjust.
16411 * linux-low.h (struct process_info_private): Move members to struct
16413 (thread_db_free, thread_db_handle_monitor_command): New prototype.
16414 * linux-low.c (linux_remove_process): Adjust.
16415 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
16416 * server.c (handle_query): Move code ...
16417 (handle_monitor_command): ... here. New function.
16418 * target.h (struct target_ops): New member.
16419 * thread-db.c (struct thread_db): New.
16420 (libthread_db_search_path): New variable.
16421 (thread_db_create_event, thread_db_enable_reporting)
16422 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
16423 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
16424 (try_thread_db_load_1, dladdr_to_soname): New functions.
16425 (try_thread_db_load, thread_db_load_search): New functions.
16426 (thread_db_init): Search for libthread_db.
16427 (thread_db_free): New function.
16428 (thread_db_handle_monitor_command): Likewise.
16429 * config.in: Regenerate.
16430 * configure: Regenerate.
16432 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
16434 * spu-low.c (spu_kill): Wait for inferior to terminate.
16435 Call clear_inferiors.
16436 (spu_detach): Call clear_inferiors.
16438 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
16440 * aclocal.m4: Regenerate.
16441 * config.in: Likewise.
16442 * configure: Likewise.
16444 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
16446 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
16447 (parse_spufs_run): New function.
16448 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
16449 (ppc_breakpoint_at): Handle SPU breakpoints.
16451 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
16453 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
16454 (SPUFS_MAGIC): Define.
16455 (spu_enumerate_spu_ids): New function.
16456 (linux_qxfer_spu): New function.
16457 (linux_target_ops): Install linux_qxfer_spu.
16459 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
16461 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
16462 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
16463 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
16464 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
16465 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
16466 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
16467 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
16468 (init_registers_powerpc_cell32l): Add prototype.
16469 (init_registers_powerpc_cell64l): Likewise.
16470 (ppc_arch_setup): Detect Cell/B.E. architecture.
16472 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
16474 * Makefile.in (datarootdir): New variable.
16476 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
16478 * linux-low.c (linux_write_memory): Update debugging output.
16479 * Makefile.in (clean): Add new descriptions.
16480 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
16481 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
16482 * configure.srv: Add new files for arm*-*-linux*.
16483 * linux-arm-low.c: Add new declarations.
16484 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
16485 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
16486 (HWCAP_VFPv3D16): New.
16487 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
16488 instead of __IWMMXT__.
16489 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
16490 (arm_arch_setup): New.
16491 (target_regsets): Remove #ifdef. Add VFP regset.
16492 (the_low_target): Use arm_arch_setup.
16494 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
16496 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
16497 the main thread again.
16499 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
16501 Adding Neutrino gdbserver.
16502 * configure: Regenerated.
16503 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
16504 * configure.srv (i[34567]86-*-nto*): New target.
16505 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
16506 * remote-utils.c [__QNX__]: Include sys/iomgr.h
16507 (nto_comctrl) [__QNX__]: New function.
16508 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
16510 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
16512 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
16515 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
16516 Pedro Alves <pedro@codesourcery.com>
16518 * win32-i386-low.c (i386_get_thread_context): Handle systems that
16519 don't support CONTEXT_EXTENDED_REGISTERS.
16520 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
16521 (the_low_target): Install them.
16522 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
16523 failing with ERROR_PIPE_NOT_CONNECTED.
16525 2009-06-30 Doug Evans <dje@google.com>
16526 Pierre Muller <muller@ics.u-strasbg.fr>
16528 Add h/w watchpoint support to x86-linux, win32-i386.
16529 * Makefile.in (SFILES): Add i386-low.c
16530 (i386_low_h): Define.
16531 (i386-low.o): Add dependencies.
16532 (linux-x86-low.o): Add i386-low.h dependency.
16533 (win32-i386-low.o): Ditto.
16534 * i386-low.c: New file.
16535 * i386-low.h: New file.
16536 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
16537 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
16538 * linux-low.c (linux_add_process): Initialize arch_private.
16539 (linux_remove_process): Free arch_private.
16540 (add_lwp): Initialize arch_private.
16541 (delete_lwp): Free arch_private.
16542 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
16544 * linux-low.h (process_info_private): New member arch_private.
16545 (lwp_info): New member arch_private.
16546 (linux_target_ops): New members new_process, new_thread,
16548 (ptid_of): New macro.
16549 * linux-x86-low.c: Include stddef.h, i386-low.h.
16550 (arch_process_info): New struct.
16551 (arch_lwp_info): New struct.
16552 (x86_linux_dr_get, x86_linux_dr_set): New functions.
16553 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
16554 (i386_dr_low_get_status): New function.
16555 (x86_insert_point, x86_remove_point): New functions.
16556 (x86_stopped_by_watchpoint): New function.
16557 (x86_stopped_data_address): New function.
16558 (x86_linux_new_process, x86_linux_new_thread): New functions.
16559 (x86_linux_prepare_to_resume): New function.
16560 (the_low_target): Add entries for insert_point, remove_point,
16561 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
16563 * server.c (debug_hw_points): New global.
16564 (monitor_show_help): Document set debug-hw-points.
16565 (handle_query): Process "set debug-hw-points".
16566 * server.h (debug_hw_points): Declare.
16567 (paddress): Declare.
16568 * utils.c (NUMCELLS, CELLSIZE): New macros.
16569 (get_sell, xsnprintf, paddress): New functions.
16570 * win32-arm-low.c (the_low_target): Add entries for insert_point,
16571 remove_point, stopped_by_watchpoint, stopped_data_address.
16572 * win32-i386-low.c: Include i386-low.h.
16573 (debug_reg_state): Replaces dr.
16574 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
16575 (i386_dr_low_get_status): New function.
16576 (i386_insert_point, i386_remove_point): New functions.
16577 (i386_stopped_by_watchpoint): New function.
16578 (i386_stopped_data_address): New function.
16579 (i386_initial_stuff): Update.
16580 (get_thread_context,set_thread_context,i386_thread_added): Update.
16581 (the_low_target): Add entries for insert_point,
16582 remove_point, stopped_by_watchpoint, stopped_data_address.
16583 * win32-low.c (win32_insert_watchpoint): New function.
16584 (win32_remove_watchpoint): New function.
16585 (win32_stopped_by_watchpoint): New function.
16586 (win32_stopped_data_address): New function.
16587 (win32_target_ops): Add entries for insert_watchpoint,
16588 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
16589 * win32-low.h (win32_target_ops): New members insert_point,
16590 remove_point, stopped_by_watchpoint, stopped_data_address.
16592 2009-06-25 Pedro Alves <pedro@codesourcery.com>
16594 * server.c (process_serial_event): Re-return unsupported, not
16595 error, if the type isn't recognized. Re-allow supporting only
16596 insert or remove packets. Also call require_running for
16597 breakpoints. Add missing break statement to default case. Tidy.
16598 * target.h (struct target_ops): Rename insert_watchpoint to
16599 insert_point, and remove_watchpoint to remove_point.
16601 * linux-low.h (struct linux_target_ops): Likewise.
16602 * linux-low.c (linux_insert_watchpoint): Rename to ...
16603 (linux_insert_point): ... this. Adjust.
16604 (linux_remove_watchpoint): Rename to ...
16605 (linux_remove_point): ... this. Adjust.
16606 (linux_target_ops): Adjust.
16607 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
16608 (cris_insert_point): ... this.
16609 (cris_remove_watchpoint): Rename to ...
16610 (cris_remove_point): ... this.
16611 (the_low_target): Adjust.
16613 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
16615 * server.c (handle_v_kill): Pass signal_pid to
16616 kill_inferior if multi_process is zero.
16618 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
16620 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
16621 * target.h (target_ops): Comment for *_watchpoint to make it clear
16622 the functions can get types '0' and '1'.
16624 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
16626 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
16627 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
16628 * regcache.c (get_regcache): Likewise.
16629 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
16630 * win32-low.c (child_fetch_inferior_registers): Remove check for
16633 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
16634 Pedro Alves <pedro@codesourcery.com>
16636 * target.h (struct target_ops) <supports_multi_process>: New
16638 (target_supports_multi_process): New.
16639 * server.c (handle_query): Even if GDB reports support, only
16640 enable multi-process if the target also supports it. Report
16641 multi-process support only if the target backend supports it.
16642 * linux-low.c (linux_supports_multi_process): New function.
16643 (linux_target_ops): Install it as target_supports_multi_process
16646 2009-05-24 Doug Evans <dje@google.com>
16648 Global renaming of find_thread_pid to find_thread_ptid.
16649 * server.h (find_thread_ptid): Renamed from find_thread_pid.
16650 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
16651 All callers updated.
16653 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
16654 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
16657 * linux-low.c (get_stop_pc): Print pc if debug_threads.
16658 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
16659 (linux_resume_one_lwp): Ditto.
16661 2009-05-23 Doug Evans <dje@google.com>
16663 * linux-low.c (linux_resume_one_lwp): Change type of first arg
16664 from struct inferior_list_entry * to struct lwp_info *.
16665 All callers updated.
16667 2009-05-13 Doug Evans <dje@google.com>
16669 * linux-x86-low.c: Don't include assert.h.
16670 (x86_siginfo_fixup): Use fatal, not assert.
16671 (x86_arch_setup): Fix comment.
16673 2009-05-12 Doug Evans <dje@google.com>
16675 Biarch support for i386/amd64 gdbserver.
16676 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
16677 Add linux-x86-low.c.
16678 (linux-i386-low.o, linux-x86-64-low.o): Delete.
16679 (linux-x86-low.o): Add.
16680 * linux-x86-64-low.c: Delete.
16681 * linux-i386-low.c: Delete.
16682 * linux-x86-low.c: New file.
16683 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
16685 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
16687 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
16688 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
16689 (linux_child_pid_to_exec_file): New function.
16690 (elf_64_header_p, elf_64_file_p): New functions.
16691 (siginfo_fixup): New function.
16692 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
16693 give target a chance to convert layout.
16694 * linux-low.h (linux_target_ops): New member siginfo_fixup.
16695 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
16697 2009-05-07 Doug Evans <dje@google.com>
16699 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
16700 (regsets_store_inferior_registers): Ditto.
16702 2009-05-06 Pedro Alves <pedro@codesourcery.com>
16706 * linux-low.c (must_set_ptrace_flags): Delete.
16707 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
16709 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
16710 `lwp->must_set_ptrace_flags' instead.
16711 (linux_wait_for_event_1): Set ptrace options here.
16712 (linux_wait_1): ... not here.
16714 2009-04-30 Doug Evans <dje@google.com>
16716 * inferiors.c (started_inferior_callback): New function.
16717 (attached_inferior_callback): New function.
16718 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
16719 * server.c (print_started_pid, print_attached_pid): New functions.
16720 (detach_or_kill_for_exit): New function.
16721 (main): Call it instead of for_each_inferior (kill_inferior_callback).
16722 * server.h (have_started_inferiors_p): Declare.
16723 (have_attached_inferiors_p): Declare.
16725 * inferiors.c (remove_process): Fix memory leak, free process.
16726 * linux-low.c (linux_remove_process): New function.
16727 (linux_kill): Call it instead of remove_process.
16728 (linux_detach, linux_wait_1): Ditto.
16730 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
16732 * configure.srv: Add x86 Windows CE target.
16734 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
16736 * inferiors.c (get_thread_process): Make global.
16737 * server.h (get_thread_process): Add prototype.
16738 * thread-db.c (find_one_thread): Use get_thread_process
16739 instead of current_process.
16740 (thread_db_get_tls_address): Do not crash if called when
16741 thread layer is not yet initialized.
16743 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
16745 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
16746 * spu-low.c (current_tid): Rename to ...
16747 (current_ptid): ... this.
16748 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
16749 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
16750 ptid_get_lwp (current_ptid) instead of current_tid.
16751 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
16752 instead of current_tid. Use find_process_pid to verify pid
16753 argument is valid. Pass proper argument to remove_process.
16754 (spu_thread_alive): Compare current_ptid instead of current_tid.
16755 (spu_resume): Likewise.
16757 2009-04-02 Pedro Alves <pedro@codesourcery.com>
16759 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
16762 2009-04-01 Pedro Alves <pedro@codesourcery.com>
16764 Implement the multiprocess extensions, and add linux multiprocess
16767 * server.h (ULONGEST): Declare.
16768 (struct ptid, ptid_t): New.
16769 (minus_one_ptid, null_ptid): Declare.
16770 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
16771 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
16772 (struct inferior_list_entry): Change `id' type from unsigned from
16774 (struct sym_cache, struct breakpoint, struct
16775 process_info_private): Forward declare.
16776 (struct process_info): Declare.
16777 (current_process): Declare.
16778 (all_processes): Declare.
16779 (initialize_inferiors): Declare.
16780 (add_thread): Adjust to use ptid_t.
16781 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
16782 (add_process, remove_process, find_thread_pid): Declare.
16783 (find_inferior_id): Adjust to use ptid_t.
16784 (cont_thread, general_thread, step_thread): Change type to ptid_t.
16785 (multi_process): Declare.
16786 (push_event): Adjust to use ptid_t.
16787 (read_ptid, write_ptid): Declare.
16788 (prepare_resume_reply): Adjust to use ptid_t.
16789 (clear_symbol_cache): Declare.
16790 * inferiors.c (all_processes): New.
16791 (null_ptid, minus_one_ptid): New.
16792 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
16793 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
16794 (add_thread): Change unsigned long to ptid. Remove gdb_id
16796 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
16797 (gdb_id_to_thread): Rename to ...
16798 (find_thread_pid): ... this. Change unsigned long to ptid.
16799 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
16800 (loaded_dll, pull_pid_from_list): Adjust.
16801 (add_process, remove_process, find_process_pid)
16802 (get_thread_process, current_process, initialize_inferiors): New.
16803 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
16804 (struct target_waitstatus) <related_pid>: Ditto.
16805 (struct target_ops) <kill, detach>: Add `pid' argument. Change
16806 return type to int.
16807 (struct target_ops) <join>: Add `pid' argument.
16808 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
16809 (struct target_ops) <wait>: Add `ptid' field. Change return type
16811 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
16812 (mywait): Add `ptid' argument. Change return type to ptid_t.
16813 (target_pid_to_str): Declare.
16814 * target.c (set_desired_inferior): Adjust to use ptids.
16815 (mywait): Add new `ptid' argument. Adjust.
16816 (target_pid_to_str): New.
16817 * mem-break.h (free_all_breakpoints): Declare.
16818 * mem-break.c (breakpoints): Delelete.
16819 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
16820 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
16821 to use per-process breakpoint list.
16822 (free_all_breakpoints): New.
16823 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
16824 (symbol_cache, all_symbols_looked_up): Delete.
16826 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
16828 (prepare_resume_reply): Change ptid argument's type from unsigned
16829 long to ptid_t. Adjust. Implement W;process and X;process.
16830 (free_sym_cache, clear_symbol_cache): New.
16831 (look_up_one_symbol): Adjust to per-process symbol cache. *
16832 * server.c (cont_thread, general_thread, step_thread): Change type
16834 (attached): Delete.
16835 (multi_process): New.
16836 (last_ptid): Change type to ptid_t.
16837 (struct vstop_notif) <ptid>: Change type to ptid_t.
16838 (queue_stop_reply, push_event): Change `ptid' argument's type to
16840 (discard_queued_stop_replies): Add `pid' argument.
16841 (start_inferior): Adjust to use ptids. Adjust to mywait interface
16842 changes. Don't reference the `attached' global.
16843 (attach_inferior): Adjust to mywait interface changes.
16844 (handle_query): Adjust to use ptids. Parse GDB's qSupported
16845 features. Handle and report "multiprocess+". Handle
16847 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
16849 (handle_v_kill): New.
16850 (handle_v_stopped): Adjust to use target_pid_to_str.
16851 (handle_v_requests): Allow multiple attaches and runs when
16852 multiprocess extensions are in effect. Handle "vKill".
16853 (myresume): Adjust to use ptids.
16854 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
16855 (handle_status): Adjust to discard_queued_stop_replies interface
16857 (first_thread_of, kill_inferior_callback)
16858 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
16859 (main): Call initialize_inferiors. Adjust to use ptids, killing
16860 and detaching from all inferiors. Handle multiprocess packet
16862 * linux-low.h: Include gdb_proc_service.h.
16863 (struct process_info_private): New.
16864 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
16865 <lwpid_of>: Use ptid_get_lwp.
16866 (get_lwp_thread): Adjust.
16867 (struct lwp_info): Add `dead' member.
16868 (find_lwp_pid): Declare.
16869 * linux-low.c (thread_db_active): Delete.
16870 (new_inferior): Adjust comment.
16871 (inferior_pid): Delete.
16872 (linux_add_process): New.
16873 (handle_extended_wait): Adjust.
16874 (add_lwp): Change unsigned long to ptid.
16875 (linux_create_inferior): Add process to processes table. Adjust
16876 to use ptids. Don't set new_inferior here.
16877 (linux_attach_lwp): Rename to ...
16878 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
16879 it. Adjust to use ptids.
16880 (linux_attach_lwp): New.
16881 (linux_attach): Add process to processes table. Don't set
16883 (struct counter): New.
16884 (second_thread_of_pid_p, last_thread_of_process_p): New.
16885 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
16886 multiple processes.
16887 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
16888 processes. Remove process from process table.
16889 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
16890 to multiple processes.
16891 (any_thread_of): New.
16892 (linux_detach): Add `pid' argument, and handle it. Remove process
16893 from processes table.
16894 (linux_join): Add `pid' argument. Handle it.
16895 (linux_thread_alive): Change unsighed long argument to ptid_t.
16896 Consider dead lwps as not being alive.
16897 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
16898 threads we're not interested in.
16899 (same_lwp, find_lwp_pid): New.
16900 (linux_wait_for_lwp): Change `pid' argument's type from int to
16902 (linux_wait_for_event): Rename to ...
16903 (linux_wait_for_event_1): ... this. Change `pid' argument's type
16904 from int to ptid_t. Adjust.
16905 (linux_wait_for_event): New.
16906 (linux_wait_1): Add `ptid' argument. Change return type to
16907 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
16908 that exit from the process table.
16909 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
16911 (mark_lwp_dead): New.
16912 (wait_for_sigstop): Adjust to use ptids. If a process exits while
16913 stopping all threads, mark its main lwp as dead.
16914 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
16916 (fetch_register, usr_store_inferior_registers)
16917 (regsets_fetch_inferior_registers)
16918 (regsets_store_inferior_registers, linux_read_memory)
16919 (linux_write_memory): Inline `inferior_pid'.
16920 (linux_look_up_symbols): Adjust to use per-process
16921 `thread_db_active'.
16922 (linux_request_interrupt): Adjust to use ptids.
16923 (linux_read_auxv): Inline `inferior_pid'.
16924 (initialize_low): Don't reference thread_db_active.
16925 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
16926 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
16927 (ps_getpid): Return the pid of the current inferior.
16928 * thread-db.c (proc_handle, thread_agent): Delete.
16929 (thread_db_create_event, thread_db_enable_reporting): Adjust to
16931 (find_one_thread): Change argument type to ptid_t. Adjust to
16933 (maybe_attach_thread): Adjust to per-process data and ptids.
16934 (thread_db_find_new_threads): Ditto.
16935 (thread_db_init): Ditto.
16936 * spu-low.c (spu_create_inferior, spu_attach): Add process to
16937 processes table. Adjust to use ptids.
16938 (spu_kill, spu_detach): Adjust interface. Remove process from
16940 (spu_join, spu_thread_alive): Adjust interface.
16941 (spu_wait): Adjust interface. Remove process from processes
16942 table. Adjust to use ptids.
16943 * win32-low.c (current_inferior_tid): Delete.
16944 (current_inferior_ptid): New.
16945 (debug_event_ptid): New.
16946 (thread_rec): Take a ptid. Adjust.
16947 (child_add_thread): Add `pid' argument. Adjust to use ptids.
16948 (child_delete_thread): Ditto.
16949 (do_initial_child_stuff): Add `attached' argument. Add process to
16951 (child_fetch_inferior_registers, child_store_inferior_registers):
16953 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
16954 (win32_attach): Pass 1 to do_initial_child_stuff.
16955 (win32_kill): Adjust interface. Remove process from processes
16957 (win32_detach): Ditto.
16958 (win32_join): Adjust interface.
16959 (win32_thread_alive): Take a ptid.
16960 (win32_resume): Adjust to use ptids.
16961 (get_child_debug_event): Ditto.
16962 (win32_wait): Adjust interface. Remove exiting process from
16965 2009-04-01 Pedro Alves <pedro@codesourcery.com>
16967 Non-stop mode support.
16969 * server.h (non_stop): Declare.
16970 (gdb_client_data, handler_func): Declare.
16971 (delete_file_handler, add_file_handler, start_event_loop):
16973 (handle_serial_event, handle_target_event, push_event)
16974 (putpkt_notif): Declare.
16975 * target.h (enum resume_kind): New.
16976 (struct thread_resume): Replace `step' field by `kind' field.
16977 (TARGET_WNOHANG): Define.
16978 (struct target_ops) <wait>: Add `options' argument.
16979 <supports_non_stop, async, start_non_stop>: New fields.
16980 (target_supports_non_stop, target_async): New.
16981 (start_non_stop): Declare.
16982 (mywait): Add `options' argument.
16983 * target.c (mywait): Add `options' argument. Print child exit
16984 notifications here.
16985 (start_non_stop): New.
16986 * server.c (non_stop, own_buf, mem_buf): New globals.
16987 (struct vstop_notif): New.
16988 (notif_queue): New global.
16989 (queue_stop_reply, push_event, discard_queued_stop_replies)
16990 (send_next_stop_reply): New.
16991 (start_inferior): Adjust to use resume_kind. Adjust to mywait
16993 (attach_inferior): In non-stop mode, don't wait for the target
16995 (handle_general_set): Handle QNonStop.
16996 (handle_query): When handling qC, return the current general
16997 thread, instead of the first thread of the list.
16998 (handle_query): If the backend supports non-stop mode, include
16999 QNonStop+ in the qSupported query response.
17000 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
17002 (handle_v_attach, handle_v_run): Handle non-stop mode.
17003 (handle_v_stopped): New.
17004 (handle_v_requests): Report support for vCont;t. Handle vStopped.
17005 (myresume): Adjust to use resume_kind. Handle non-stop.
17006 (queue_stop_reply_callback): New.
17007 (handle_status): Handle non-stop mode.
17008 (main): Clear non_stop flag on reconnection. Use the event-loop.
17009 Refactor serial protocol handling from here ...
17010 (process_serial_event): ... to this new function. When GDB
17011 selects any thread, select one here. In non-stop mode, wait until
17012 GDB acks all pending events before exiting.
17013 (handle_serial_event, handle_target_event): New.
17014 * remote-utils.c (remote_open): Install remote_desc in the event
17016 (remote_close): Remove remote_desc from the event loop.
17017 (putpkt_binary): Rename to...
17018 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
17019 (putpkt_binary): New as wrapper around putpkt_binary_1.
17020 (putpkt_notif): New.
17021 (prepare_resume_reply): In non-stop mode, don't change the
17023 * event-loop.c: New.
17024 * Makefile.in (OBJ): Add event-loop.o.
17025 (event-loop.o): New rule.
17027 * linux-low.h (pid_of): Moved here.
17029 (get_lwp_thread): Use lwpid_of.
17030 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
17031 * linux-low.c (pid_of): Delete.
17032 (inferior_pid): Use lwpid_of.
17033 (linux_event_pipe): New.
17034 (target_is_async_p): New.
17036 (handle_extended_wait): Use lwpid_of.
17037 (add_lwp): Don't set lwpid field.
17038 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
17039 (linux_kill_one_lwp): If killing a running lwp, stop it first.
17040 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
17041 (linux_detach_one_lwp): If detaching from a running lwp, stop it
17042 first. Adjust to linux_wait_for_event interface changes. Use
17044 (linux_detach): Don't delete the main lwp here.
17045 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
17046 (status_pending_p): Don't consider explicitly suspended lwps.
17047 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
17048 pointer. Add OPTIONS argument. Change return type to int. Use
17049 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
17050 (linux_wait_for_event): Take an integer pid instead of a lwp_info
17051 pointer. Add status pointer argument. Return a pid instead of a
17052 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
17053 changes. In non-stop mode, don't switch to a random thread.
17054 (linux_wait): Rename to...
17055 (linux_wait_1): ... this. Add target_options argument, and handle
17056 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
17057 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
17058 clean exit and signal exit code. Don't stop all threads in
17059 non-stop mode. In all-stop mode, only stop all threads when
17060 reporting a stop to GDB. Handle explicit thread stop requests.
17061 (async_file_flush, async_file_mark): New.
17063 (send_sigstop): Use lwpid_of.
17064 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
17065 interface changes. In non-stop mode, don't switch to a random
17067 (linux_resume_one_lwp): Use lwpid_of.
17068 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
17069 (linux_resume_one_thread): ... this. Handle resume_stop. In
17070 non-stop mode, don't look for pending flag in all threads.
17071 (resume_status_pending_p): Don't consider explicitly suspended
17073 (my_waitpid): Reimplement. Emulate __WALL.
17074 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
17076 (sigchld_handler, linux_supports_non_stop, linux_async)
17077 (linux_start_non_stop): New.
17078 (linux_target_ops): Register linux_supports_non_stop, linux_async
17079 and linux_start_non_stop.
17080 (initialize_low): Install SIGCHLD handler.
17081 * thread-db.c (thread_db_create_event, find_one_thread)
17082 (thread_db_get_tls_address): Use lwpid_of.
17083 * win32-low.c (win32_detach): Adjust to use resume_kind.
17084 (win32_wait): Add `options' argument.
17085 * spu-low.c (spu_resume): Adjust to use resume_kind.
17086 (spu_wait): Add `options' argument.
17088 2009-04-01 Pedro Alves <pedro@codesourcery.com>
17090 Decouple target code from remote protocol.
17092 * target.h (enum target_waitkind): New.
17093 (struct target_waitstatus): New.
17094 (struct target_ops) <wait>: Return an unsigned long. Take a
17095 target_waitstatus pointer instead of a char pointer.
17096 (mywait): Likewise.
17097 * target.c (mywait): Change prototype to return an unsigned long.
17098 Take a target_waitstatus pointer instead of a char pointer. Adjust.
17099 * server.h (thread_from_wait, old_thread_from_wait): Delete
17101 (prepare_resume_reply): Change prototype to take a
17103 * server.c (thread_from_wait, old_thread_from_wait): Delete.
17104 (last_status, last_ptid): New.
17105 (start_inferior): Remove "statusptr" argument. Adjust. Return a
17106 pid instead of a signal.
17107 (attach_inferior): Remove "status" and "signal" parameters.
17109 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
17111 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
17112 (handle_v_requests, myresume): Remove "status" and "signal"
17113 parameters. Adjust.
17114 (handle_status): New.
17115 (main): Delete local `status'. Adjust.
17116 * remote-utils.c: Include target.h.
17117 (prepare_resume_reply): Change prototype to take a
17118 target_waitstatus. Adjust.
17120 * linux-low.c (linux_wait): Adjust to new target_ops->wait
17122 * spu-low.c (spu_wait): Adjust.
17123 * win32-low.c (enum target_waitkind, struct target_waitstatus):
17125 (win32_wait): Adjust.
17127 2009-04-01 Pedro Alves <pedro@codesourcery.com>
17129 * target.h (struct thread_resume): Delete leave_stopped member.
17130 (struct target_ops): Add a `n' argument to the `resume' callback.
17131 * server.c (start_inferior): Adjust.
17132 (handle_v_cont, myresume): Adjust.
17133 * linux-low.c (check_removed_breakpoint): Adjust to resume
17134 interface change, and to removed leave_stopped field.
17135 (resume_ptr): Delete.
17136 (struct thread_resume_array): New.
17137 (linux_set_resume_request): Add new `arg' parameter. Adjust to
17138 resume interface change.
17139 (linux_continue_one_thread, linux_queue_one_thread)
17140 (resume_status_pending_p): Check if the resume field is NULL
17141 instead of checking the leave_stopped member.
17142 (linux_resume): Adjust to the target resume interface change.
17143 * spu-low.c (spu_resume): Adjust to the target resume interface
17145 * win32-low.c (win32_detach, win32_resume): Ditto.
17147 2009-04-01 Pedro Alves <pedro@codesourcery.com>
17149 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
17151 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
17153 (linux_continue_one_thread): Only preserve the stepping flag if
17154 there's a pending breakpoint.
17156 2009-03-31 Pedro Alves <pedro@codesourcery.com>
17158 * server.c (main): After the inferior having exited, call
17159 remote_close before exiting gdbserver.
17161 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
17163 Fix size of FPSCR in Power 7 processors.
17164 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
17165 (PPC_FEATURE_HAS_DFP): New #define.
17166 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
17169 2009-03-23 Pedro Alves <pedro@codesourcery.com>
17171 * server.c (handle_query) Whitespace and formatting.
17173 2009-03-22 Pedro Alves <pedro@codesourcery.com>
17175 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
17176 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
17177 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
17178 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
17179 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
17180 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
17181 Makefile.in, configure.ac: Fix whitespace throughout.
17182 * configure: Regenerate.
17184 2009-03-22 Pedro Alves <pedro@codesourcery.com>
17186 * inferiors.c (find_inferior): Make it safe for the callback
17187 function to delete the currently iterated inferior.
17189 2009-03-22 Pedro Alves <pedro@codesourcery.com>
17191 * Makefile.in (linuw_low_h): Move higher.
17192 (thread-db.o): Depend on $(linux_low_h).
17194 2009-03-17 Pedro Alves <pedro@codesourcery.com>
17196 Rename "process" to "lwp" throughout.
17198 * linux-low.c (all_processes): Rename to...
17199 (all_lwps): ... this.
17200 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
17201 (add_process): Rename to ...
17202 (add_lwp): ... this. Adjust.
17203 (linux_create_inferior): Adjust.
17204 (linux_attach_lwp): Adjust.
17205 (linux_attach): Adjust.
17206 (linux_kill_one_process): Rename to ...
17207 (linux_kill_one_lwp): ... this. Adjust.
17208 (linux_kill): Adjust.
17209 (linux_detach_one_process): Rename to ...
17210 (linux_detach_one_lwp): ... this. Adjust.
17211 (linux_detach): Adjust.
17212 (check_removed_breakpoint): Adjust.
17213 (status_pending_p): Adjust.
17214 (linux_wait_for_process): Rename to ...
17215 (linux_wait_for_lwp): ... this. Adjust.
17216 (linux_wait_for_event): Adjust.
17217 (send_sigstop): Adjust.
17218 (wait_for_sigstop): Adjust.
17219 (stop_all_processes): Rename to ...
17220 (stop_all_lwps): ... this.
17221 (linux_resume_one_process): Rename to ...
17222 (linux_resume_one_lwp): ... this. Adjust.
17223 (linux_set_resume_request, linux_continue_one_thread)
17224 (linux_queue_one_thread, resume_status_pending_p)
17225 (usr_store_inferior_registers, regsets_store_inferior_registers)
17226 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
17228 * linux-low.h (get_process): Rename to ...
17229 (get_lwp): ... this. Adjust.
17230 (get_thread_process): Rename to ...
17231 (get_thread_lwp): ... this. Adjust.
17232 (get_process_thread): Rename to ...
17233 (get_lwp_thread): ... this. Adjust.
17234 (struct process_info): Rename to ...
17235 (struct lwp_info): ... this.
17236 (all_processes): Rename to ...
17237 (all_lwps): ... this.
17238 * proc-service.c (ps_lgetregs): Adjust.
17239 * thread-db.c (thread_db_create_event, find_one_thread)
17240 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
17242 2009-03-14 Pedro Alves <pedro@codesourcery.com>
17244 * server.c (handle_query): Handle "qAttached".
17246 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
17248 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
17249 GPLv3, update license URL.
17251 2009-03-01 Doug Evans <dje@google.com>
17253 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
17254 (server_h): Add gdb_signals.h.
17255 (signals.o): Update.
17256 * server.h (target_signal_from_host,target_signal_to_host_p)
17257 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
17259 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
17261 * remote-utils.c (getpkt): Also generate remote-debug
17262 information if noack_mode is set.
17264 2009-02-06 Pedro Alves <pedro@codesourcery.com>
17266 * server.c (handle_query): Report qXfer:siginfo:read and
17267 qXfer:siginfo:write as supported and handle them.
17268 * target.h (struct target_ops) <qxfer_siginfo>: New field.
17269 * linux-low.c (linux_xfer_siginfo): New.
17270 (linux_target_ops): Set it.
17272 2009-01-26 Pedro Alves <pedro@codesourcery.com>
17274 * server.c (gdbserver_usage): Mention --remote-debug.
17275 (main): Accept '--remote-debug' switch.
17277 2009-01-18 Doug Evans <dje@google.com>
17279 * regcache.c (new_register_cache): No need to check result of xcalloc.
17280 * server.c (handle_search_memory): Back out calls to xmalloc,
17281 result is checked and error is returned to user upon failure.
17282 (handle_query): Ditto. Add more checks for result of malloc.
17283 (handle_v_cont): Check result of malloc, report error back to
17285 (handle_v_run): Ditto. Call freeargv.
17286 * server.h (freeargv): Declare.
17287 * utils.c (freeargv): New fn.
17289 2009-01-15 Doug Evans <dje@google.com>
17291 * gdbreplay.c (perror_with_name): Make arg const char *.
17292 * server.h (target_signal_to_name): Make return type const char *.
17293 * thread-db.c (thread_db_err_str): Make return type const char *.
17294 * utils.c (perror_with_name): Make arg const char *.
17296 2009-01-14 Pedro Alves <pedro@codesourcery.com>
17298 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
17299 when handling a EXIT_PROCESS_DEBUG_EVENT.
17301 2009-01-06 Joel Brobecker <brobecker@adacore.com>
17303 * gdbreplay.c (gdbreplay_version): Update copyright year.
17304 * server.c (gdbserver_version): Likewise.
17306 2009-01-05 Doug Evans <dje@google.com>
17308 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
17309 (handle_extended_wait): Improve comment.
17311 2008-12-13 Doug Evans <dje@google.com>
17313 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
17314 * server.h (ATTR_MALLOC): New macro.
17315 (xmalloc,xcalloc,xstrdup): Declare.
17316 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
17317 * inferiors.c: Ditto.
17318 * linux-low.c: Ditto.
17319 * mem-break.c: Ditto.
17320 * regcache.c: Ditto.
17321 * remote-utils.c: Ditto.
17324 * win32-low.c: Ditto.
17326 2008-12-12 Doug Evans <dje@google.com>
17328 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
17329 in debugging printf.
17331 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
17333 2008-12-09 Doug Evans <dje@google.com>
17335 * linux-low.h (struct process_info): Delete member tid, unused.
17336 * thread-db.c (find_one_thread): Update.
17337 (maybe_attach_thread): Update.
17339 2008-12-02 Pedro Alves <pedro@codesourcery.com>
17341 * target.h (struct target_ops): Add qxfer_osdata member.
17342 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
17344 (linux_qxfer_osdata): New functions.
17345 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
17347 * server.c (handle_query): Handle "qXfer:osdata:read:".
17348 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
17349 (buffer_xml_printf): New functions.
17350 * server.h (struct buffer): New.
17351 (buffer_grow_str, buffer_grow_str0): New macros.
17352 (buffer_grow, buffer_free, buffer_init, buffer_finish)
17353 (buffer_xml_printf): Declare.
17355 2008-11-24 Doug Evans <dje@google.com>
17357 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
17359 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
17361 * server.c (handle_v_run): Always use the supplied argument list.
17363 2008-11-19 Bob Wilson <bob.wilson@acm.org>
17365 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
17366 (xtensa_regmap_table): Add entry for scompare1.
17368 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
17370 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
17371 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
17372 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
17373 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
17374 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
17375 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
17376 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
17377 XML target descriptions.
17378 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
17379 when inferior is running on an ISA 2.05 or later processor. Add
17380 special case to return offset for full 64-bit slot of FPSCR when
17383 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
17385 * Makefile.in (SFILES, clean): Added sparc64 files.
17386 (reg-sparc64.o, reg-sparc64.c): New.
17387 * configure.srv (sparc*-*-linux*): New configuration.
17388 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
17389 syscall arguments for SPARC.
17390 (regsets_store_inferior_registers): Likewise.
17391 * linux-sparc-low.c: New file.
17393 2008-10-21 Doug Evans <dje@google.com>
17395 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
17396 (READLINE_DIR,READLINE_DEP): Delete.
17397 (INTERNAL_CFLAGS): Update.
17398 (LINTFLAGS): Update.
17400 2008-10-10 Pedro Alves <pedro@codesourcery.com>
17402 * server.c (handle_v_run): If GDB didn't specify an argv, use the
17403 whole argv from the last run, not just argv[0].
17405 2008-09-08 Pedro Alves <pedro@codesourcery.com>
17407 * regcache.c (new_register_cache): Return NULL if the register
17408 cache size isn't known yet.
17409 (free_register_cache): Avoid dereferencing a NULL regcache.
17411 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
17413 * configure.srv: Merge MIPS and MIPS64.
17415 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
17417 * Makefile.in (uninstall): Apply $(EXEEXT) too.
17419 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
17421 * Makefile.in: Add required vsx dependencies.
17423 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
17424 Declare init_registers_powerpc_vsx32l.
17425 Declare init_registers_powerpc_vsx64l.
17426 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
17427 (ppc_arch_setup): Check for VSX in hwcap.
17428 (ppc_fill_vsxregset): New function.
17429 (ppc_store_vsxregset): New function.
17430 Add new VSX entry in regset_info target_regsets.
17432 * configure.srv: Add new VSX dependencies.
17434 2008-08-12 Pedro Alves <pedro@codesourcery.com>
17436 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
17437 (remote_open): Set or clear transport_is_reliable.
17438 (putpkt_binary): Don't expect acks in noack mode.
17439 (getpkt): Don't send ack/nac in noack mode.
17440 * server.c (handle_general_set): Handle QStartNoAckMode.
17441 (handle_query): If connected by tcp pass QStartNoAckMode+ in
17443 (main): Reset noack_mode on every connection.
17444 * server.h (noack_mode): Declare.
17446 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
17448 * Makefile.in (GDBREPLAY_OBS): New variable.
17449 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
17451 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
17452 Daniel Jacobowitz <dan@codesourcery.com>
17454 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
17455 (usr_store_inferior_registers): Likewise.
17456 (regsets_store_inferior_registers): Likewise.
17458 2008-07-31 Rolf Jansen <rj@surtec.com>
17459 Pedro Alves <pedro@codesourcery.com>
17461 * configure.ac: Check for memmem declaration.
17462 * server.c [HAVE_MALLOC_H]: Include malloc.h.
17463 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
17464 (disable_packet_qfThreadInfo): Unconditionally compile.
17465 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
17466 * configure, config.in: Regenerate.
17468 2008-07-28 Doug Kwan <dougkwan@google.com>
17470 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
17471 (linux_write_memory): Remove declaration of errno.
17473 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
17475 * linux-low.c (handle_extended_wait): Do not use "status"
17476 variable uninitialized.
17478 2008-07-07 Pedro Alves <pedro@codesourcery.com>
17480 * server.c (handle_v_attach): Inhibit reporting dll changes.
17482 2008-06-27 Pedro Alves <pedro@codesourcery.com>
17484 * remote-utils.c (prepare_resume_reply): If requested, don't
17485 output "thread:TID" in the T stop reply.
17487 * server.c (disable_packet_vCont, disable_packet_Tthread)
17488 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
17489 (handle_query): If requested, disable support for qC, qfThreadInfo
17491 (handle_v_requests): If requested, disable support for vCont.
17492 (gdbserver_show_disableable): New.
17493 (main): Handle --disable-packet and --disable-packet=LIST.
17495 * server.h (disable_packet_vCont, disable_packet_Tthread)
17496 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
17498 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
17500 * server.c (gdbserver_usage): Mention --version.
17502 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
17504 * Makefile.in (gdbreplay.o): New rule.
17506 2008-06-06 Joseph Myers <joseph@codesourcery.com>
17508 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
17509 message, not gdbserver.
17511 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
17512 Nathan Sidwell <nathan@codesourcery.com>
17513 Joseph Myers <joseph@codesourcery.com>
17515 * acinclude.m4: Include ../../config/acx.m4.
17516 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
17517 * configure, config.in: Regenerate.
17518 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
17519 * server.c (gdbserver_version): Print PKGVERSION.
17520 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
17521 (main): Adjust gdbserver_usage calls.
17522 * gdbreplay.c (version, host_name): Add declarations.
17523 (gdbreplay_version, gdbreplay_usage): New.
17524 (main): Accept --version and --help options.
17526 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
17528 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
17529 (arm_breakpoint_at): Handle Thumb.
17530 (the_low_target): Add comment.
17532 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
17534 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
17536 2008-05-09 Doug Evans <dje@google.com>
17538 * server.h (decode_search_memory_packet): Declare.
17539 * remote-utils.c (decode_search_memory_packet): New fn.
17540 * server.c (handle_search_memory_1): New fn.
17541 (handle_search_memory): New fn.
17542 (handle_query): Process qSearch:memory packets.
17544 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
17546 * regcache.c (registers_length): Remove.
17547 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
17548 full register packet.
17549 * regcache.h (registers_length): Remove prototype.
17550 * server.h (PBUFSIZ): Define to 16384.
17552 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
17554 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
17555 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
17556 powerpc-64l.o, and powerpc-altivec64l.o.
17557 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
17558 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
17559 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
17560 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
17561 rs6000/power-linux.xml, and rs6000/power64-linux.xml
17564 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
17565 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
17566 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
17567 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
17568 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
17569 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
17570 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
17571 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
17572 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
17573 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
17576 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
17577 (init_registers_powerpc_32l): ... this new prototype.
17578 (init_registers_powerpc_32): Remove, replace by ...
17579 (init_registers_powerpc_altivec32l): ... this new prototype.
17580 (init_registers_powerpc_e500): Remove, replace by ...
17581 (init_registers_powerpc_e500l): ... this new prototype.
17582 (init_registers_ppc64): Remove, replace by ...
17583 (init_registers_powerpc_64l): ... this new prototype.
17584 (init_registers_powerpc_64): Remove, replace by ...
17585 (init_registers_powerpc_altivec64l): ... this new prototype.
17586 (ppc_num_regs): Set to 73.
17587 (PT_ORIG_R3, PT_TRAP): Define if necessary.
17588 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
17589 (ppc_cannot_store_register): Handle orig_r3 and trap.
17590 (ppc_arch_setup): Update init_registers_... calls.
17591 (ppc_fill_gregset): Handle orig_r3 and trap.
17593 * inferiors.c (clear_inferiors): Reset current_inferior.
17595 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
17597 * acinclude.m4: Add override.m4.
17598 * configure: Regenerate.
17600 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
17602 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
17603 initial call to init_register_ppc64.
17605 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
17607 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
17608 single powerpc*-*-linux* case.
17609 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
17611 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
17613 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
17614 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
17616 * linux-ppc-low.c: Include <elf.h>.
17617 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
17618 (ppc_hwcap): New global variable.
17619 (ppc_regmap): Remove __SPE__ #ifdef sections.
17620 (ppc_regmap_e500): New global variable.
17621 (ppc_cannot_store_register): Update __SPE__ special case.
17622 (ppc_get_hwcap): New function.
17623 (ppc_arch_setup): Use it to determine whether inferior supports
17624 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
17625 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
17626 Do not access registers if target does not support AltiVec.
17627 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
17628 Do not access registers if target does not support SPE.
17629 (target_regsets): Unconditionally include AltiVec and SPE regsets.
17631 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
17633 * linux-low.c (disabled_regsets, num_regsets): New.
17634 (use_regsets_p): Delete.
17635 (linux_wait_for_process): Clear disabled_regsets.
17636 (regsets_fetch_inferior_registers): Check and set it.
17637 (regsets_store_inferior_registers): Likewise.
17638 (linux_fetch_registers, linux_store_registers): Do not use
17640 (initialize_low): Allocate disabled_regsets.
17642 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
17644 * Makefile.in (LIBOBJS): New.
17645 (OBS): Use LIBOBJS.
17646 (memmem.o): New rule.
17647 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
17648 * configure: Regenerated.
17650 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
17652 * server.c (handle_query): Never return "unsupported" for
17653 qXfer:features:read queries.
17655 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
17657 * server.c (get_features_xml): Fix inverted condition.
17658 (handle_query): Always support qXfer:feature:read.
17660 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
17662 * server.c (wrapper_argv): New.
17663 (start_inferior): Handle wrapper_argv. If set, expect an extra
17665 (gdbserver_usage): Document --wrapper.
17666 (main): Parse --wrapper.
17668 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
17670 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
17671 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
17672 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
17673 (ppc_set_pc): Likewise.
17674 (ppc_arch_setup): New function.
17675 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
17676 of collect_register.
17677 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
17679 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
17681 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
17682 instead of linux-ppc64-low.o.
17683 * linux-ppc64-low.c: Remove file.
17684 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
17685 (linux-ppc64-low.o): Remove rule.
17687 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
17688 (init_registers_powerpc_64): Likewise.
17689 (ppc_regmap): Conditionally define depending on __powerpc64__.
17690 (ppc_cannot_store_register): Do not special-case "fpscr" when
17691 compiled on __powerpc64__.
17692 (ppc_collect_ptrace_register): New function.
17693 (ppc_supply_ptrace_register): New function.
17694 (ppc_breakpoint): Change type to "unsigned int".
17695 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
17696 (the_low_target): Conditionally provide initializers for the
17697 arch_setup member depending on __powerpc64__. Install
17698 collect_ptrace_register and supply_ptrace_register members.
17700 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
17702 * regcache.h (gdbserver_xmltarget): Add extern declaration.
17703 * server.c (gdbserver_xmltarget): Define.
17704 (get_features_xml): Use it to replace "target.xml" and arch_string.
17706 * configure.srv: Remove srv_xmltarget. Add XML files that were
17707 mentioned there to srv_xmlfiles instead. Remove conditional tests
17708 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
17709 srv_xmlfiles and srv_regobj to include all possible choices.
17710 * configure.ac (srv_xmltarget): Remove.
17711 (srv_xmlfiles): Do not add "target.xml".
17712 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
17713 checks for supplementary target information.
17714 * configure: Regenerate.
17715 * Makefile.in (XML_TARGET): Remove.
17716 (target.xml): Remove rule.
17717 (clean): Do not clean up target.xml.
17718 (.PRECIOUS): Do not mention target.xml.
17720 * target.h (struct target_ops): Remove arch_string member.
17721 * linux-low.c (linux_arch_string): Remove.
17722 (linux_target_ops): Remove arch_string initializer.
17723 * linux-low.h (struct linux_target_ops): Remove arch_string member.
17724 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
17725 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
17726 * spu-low.c (spu_arch_string): Remove.
17727 (spu_target_ops): Remove arch_string initializer.
17728 * win32-low.c (win32_arch_string): Remove.
17729 (win32_target_ops): Remove arch_string initializer.
17730 * win32-low.h (struct win32_target_ops): Remove arch_string member.
17731 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
17732 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
17734 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
17736 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
17737 by collect_ptrace_register and supply_ptrace_register hooks.
17738 * linux-low.c (fetch_register): Use supply_ptrace_register callback
17739 instead of checking for the_low_target.left_pad_xfer.
17740 (usr_store_inferior_registers): Use collect_ptrace_register callback
17741 instead of checking for the_low_target.left_pad_xfer.
17743 * linux-s390-low.c (s390_collect_ptrace_register): New function.
17744 (s390_supply_ptrace_register): Likewise.
17745 (s390_fill_gregset): Call s390_collect_ptrace_register.
17746 (the_low_target): Update.
17748 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
17749 (ppc_supply_ptrace_register): Likewise.
17750 (the_low_target): Update.
17752 * linux-i386-low.c (the_low_target): Update.
17753 * linux-x86-64-low.c (the_low_target): Update.
17755 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
17757 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
17758 reg-s390.o and reg-s390x.o.
17760 * linux-low.c (new_inferior): New global variable.
17761 (linux_create_inferior, linux_attach): Set it.
17762 (linux_wait_for_process): Call the_low_target.arch_setup after the
17763 target has stopped for the first time.
17764 (initialize_low): Do not call the_low_target.arch_setup.
17766 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
17767 (s390_set_pc): Likewise.
17768 (s390_arch_setup): New function.
17769 (the_low_target): Use s390_arch_setup as arch_setup routine.
17771 * regcache.c (realloc_register_cache): New function.
17772 (set_register_cache): Call it for each existing regcache.
17774 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
17776 * server.h (init_registers): Remove prototype.
17778 * linux-low.h (struct linux_target_ops): Add arch_setup field.
17779 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
17780 instead of init_registers ().
17781 * linux-arm-low.c (init_registers_arm): Add prototype.
17782 (init_registers_arm_with_iwmmxt): Likewise.
17783 (the_low_target): Add initializer for arch_setup field.
17784 * linux-cris-low.c (init_registers_cris): Add prototype.
17785 (the_low_target): Add initializer for arch_setup field.
17786 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
17787 (the_low_target): Add initializer for arch_setup field.
17788 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
17789 (the_low_target): Add initializer for arch_setup field.
17790 * linux-ia64-low.c (init_registers_ia64): Add prototype.
17791 (the_low_target): Add initializer for arch_setup field.
17792 * linux-m32r-low.c (init_registers_m32r): Add prototype.
17793 (the_low_target): Add initializer for arch_setup field.
17794 * linux-m68k-low.c (init_registers_m68k): Add prototype.
17795 (the_low_target): Add initializer for arch_setup field.
17796 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
17797 (init_registers_mips64_linux): Likewise.
17798 (the_low_target): Add initializer for arch_setup field.
17799 * linux-ppc-low.c (init_registers_ppc): Add prototype.
17800 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
17801 (the_low_target): Add initializer for arch_setup field.
17802 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
17803 (init_registers_powerpc_64): Likewise.
17804 (the_low_target): Add initializer for arch_setup field.
17805 * linux-s390-low.c (init_registers_s390): Add prototype.
17806 (init_registers_s390x): Likewise.
17807 (the_low_target): Add initializer for arch_setup field.
17808 * linux-sh-low.c (init_registers_sh): Add prototype.
17809 (the_low_target): Add initializer for arch_setup field.
17810 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
17811 (the_low_target): Add initializer for arch_setup field.
17812 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
17813 (the_low_target): Add initializer for arch_setup field.
17815 * win32-low.h (struct win32_target_ops): Add arch_setup field.
17816 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
17817 instead of init_registers ().
17818 * win32-arm-low.c (init_registers_arm): Add prototype.
17819 (the_low_target): Add initializer for arch_setup field.
17820 * win32-i386-low.c (init_registers_i386): Add prototype.
17821 (the_low_target): Add initializer for arch_setup field.
17823 * spu-low.c (init_registers_spu): Add prototype.
17824 (initialize_low): Call initialie_registers_spu () instead of
17825 initialize_registers ().
17827 2008-02-19 Pedro Alves <pedro@codesourcery.com>
17829 * server.c (handle_v_requests): When handling the vRun and vAttach
17830 packets, if already debugging a process, don't kill it. Return an
17833 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
17835 * server.c (handle_query): Correct length check.
17837 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
17839 * win32-low.c (do_initial_child_stuff): Add process handle
17840 parameter. Set current_process_handle and current_process_id from the
17841 parameters. Clear globals.
17842 (win32_create_inferior): Don't set current_process_handle and
17843 current_process_id here. Instead pass them on the call to
17844 do_initial_child_stuff.
17845 (win32_attach): Likewise.
17846 (win32_clear_inferiors): New.
17847 (win32_kill): Don't close the current process handle or the
17848 current thread handle here. Instead call win32_clear_inferiors.
17849 (win32_detach): Don't open a new handle to the process. Call
17850 win32_clear_inferiors.
17851 (win32_join): Don't rely on current_process_handle; open a new
17852 handle using the process id.
17853 (win32_wait): Call win32_clear_inferiors when the inferior process
17856 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
17858 * server.c (monitor_show_help): Add "exit".
17860 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
17862 * Makefile.in (SFILES): Add linux-xtensa-low.c.
17863 (clean): Add reg-xtensa.c.
17864 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
17865 * configure.srv (xtensa*-*-linux*) New target.
17866 * linux-xtensa-low.c: New.
17867 * xtensa-xtregs.c: New.
17869 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
17871 * hostio.c: Don't include errno.h.
17872 (errno_to_fileio_errno): Move to hostio-errno.
17873 * hostio.c: (hostio_error): Remove the error parameter. Defer the
17874 error number outputting to the target->hostio_last_error callback.
17875 (hostio_packet_error): Use FILEIO_EINVAL directly.
17876 (handle_open, handle_pread, hostio_error, handle_unlink): Update
17877 calls to hostio_error.
17878 * hostio-errno.c: New.
17879 * server.h (hostio_last_error_from_errno): Declare.
17880 * target.h (target_ops): Add hostio_last_error member.
17881 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
17882 as hostio_last_error handler.
17883 * spu-low.c (spu_target_ops): Likewise.
17884 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
17885 (wince_hostio_last_error): New functions.
17886 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
17887 as hostio_last_error handler.
17888 (win32_target_ops) [!_WIN32_WCE]: Register
17889 hostio_last_error_from_errno as hostio_last_error handler.
17890 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
17891 (hostio-errno.o): New rule.
17892 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
17893 * configure.srv (srv_hostio_err_objs): New variable. Default to
17895 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
17896 * configure: Regenerate.
17898 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
17900 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
17901 (linux_kill, linux_detach): Clean up the process list.
17902 * remote-utils.c (remote_open): Improve port number parsing.
17903 (putpkt_binary, input_interrupt): Only send interrupts if the target
17905 * server.c (extended_protocol): Make static.
17906 (attached): Define earlier.
17907 (exit_requested, response_needed, program_argv): New variables.
17908 (target_running): New.
17909 (start_inferior): Clear attached here.
17910 (attach_inferior): Set attached here.
17911 (require_running): Define.
17912 (handle_query): Use require_running and target_running. Implement
17914 (handle_v_attach, handle_v_run): New.
17915 (handle_v_requests): Use require_running. Handle vAttach and vRun.
17916 (gdbserver_usage): Update.
17917 (main): Redo argument parsing. Handle --debug and --multi. Handle
17918 --attach along with other options or after the port. Save
17919 program_argv. Support no initial program. Resynchronize
17920 communication with GDB after an error. Handle "monitor exit".
17921 Use require_running and target_running. Always allow the extended
17922 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
17923 restart in extended mode.
17924 * README: Refer to the GDB manual. Update --attach usage.
17926 2007-12-20 Andreas Schwab <schwab@suse.de>
17928 * linux-low.c (STACK_SIZE): Define.
17929 (linux_tracefork_child): Use it. Use __clone2 on ia64.
17930 (linux_test_for_tracefork): Likewise.
17932 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
17934 * linux-low.c (linux_wait_for_event): Update messages. Do not
17935 reinsert auto-delete breakpoints.
17936 * mem-break.c (struct breakpoint): Change return type of handler to
17938 (set_breakpoint_at): Update handler type.
17939 (reinsert_breakpoint_handler): Return 1 instead of calling
17941 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
17943 (check_breakpoints): Delete auto-delete breakpoints and return 2.
17944 * mem-break.h (set_breakpoint_at): Update handler type.
17945 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
17946 * win32-low.c (auto_delete_breakpoint): New.
17947 (get_child_debug_event): Use it.
17949 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
17951 * configure.ac: Check for pread and pwrite.
17952 * hostio.c (handle_pread): Fall back to lseek and read.
17953 (handle_pwrite): Fall back to lseek and write.
17954 * config.in, configure: Regenerated.
17956 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
17958 * server.c (myresume): Add own_buf argument.
17959 (main): Update calls.
17961 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
17963 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
17964 * remote-utils.c (remote_open): Do not call disable_async_io.
17965 (block_async_io): Delete.
17966 (unblock_async_io): Make static.
17967 (initialize_async_io): New.
17968 * server.c (handle_v_cont): Handle async I/O here.
17969 (myresume): Likewise. Move other common resume tasks here...
17970 (main): ... from here. Call initialize_async_io. Disable async
17971 I/O before the main loop.
17972 * server.h (initialize_async_io): Declare.
17973 (block_async_io, unblock_async_io): Delete prototypes.
17974 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
17976 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
17978 * remote-utils.c (readchar): Allow binary data in received messages.
17980 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17982 * win32-low.c (attaching): New global.
17983 (win32_create_inferior): Clear the `attaching' global.
17984 (win32_attach): Set the `attaching' global.
17985 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
17986 attaching. Only set a breakpoint at the entry point if not
17989 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17991 * server.c (main): Don't report dll events on the initial
17992 connection on attaches.
17994 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17996 * server.c (main): Relax numerical bases supported for the pid of
17997 the --attach command line argument.
17999 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
18001 * win32-low.c (win32_attach): Call OpenProcess before
18002 DebugActiveProcess, not after. Add last error output to error
18005 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
18007 * win32-low.c (win32_get_thread_context)
18008 (win32_set_thread_context): New functions.
18009 (thread_rec): Use win32_get_thread_context.
18010 (continue_one_thread, win32_resume): Use win32_set_thread_context.
18011 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
18014 2007-12-03 Leo Zayas
18015 Pedro Alves <pedro_alves@portugalmail.pt>
18017 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
18019 (child_add_thread): Minor cleanup.
18020 (child_continue): Resume artificially suspended threads before
18021 calling ContinueDebugEvent.
18022 (suspend_one_thread): New.
18023 (fake_breakpoint_event): New.
18024 (get_child_debug_event): Change return type to int. Check here if
18025 gdb sent an interrupt request. If a soft interrupt was requested,
18026 fake a breakpoint event. Return 0 if there is no event to handle,
18028 (win32_wait): Don't check here if gdb sent an interrupt request.
18029 Ensure there is a valid event to handle.
18030 (win32_request_interrupt): Add soft interruption method as last
18033 2007-12-03 Leo Zayas
18034 Pedro Alves <pedro_alves@portugalmail.pt>
18036 * win32-low.h (win32_thread_info): Add descriptions to the
18037 structure members. Replace `suspend_count' counter by a
18039 * win32-low.c (thread_rec): Update condition of when to get the
18040 context from the inferior. Rely on ContextFlags being set if it
18041 has already been retrieved. Only suspend the inferior thread if
18042 we haven't already. Warn if that fails.
18043 (continue_one_thread): s/suspend_count/suspended/. Only call
18044 ResumeThread once. Warn if that fails.
18046 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
18048 * win32-low.c (win32_wait): Don't read from the inferior when it
18049 has already exited.
18051 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
18053 * Makefile.in (win32_low_h): New variable.
18054 (win32-low.o): Add dependency on $(win32_low_h).
18055 (win32-arm-low.o, win32-i386-low.o): New rules.
18057 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
18059 * hostio.c: Correct copyright year.
18061 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
18063 * Makefile.in (OBS): Add hostio.o.
18064 (hostio.o): New rule.
18065 * server.h (handle_vFile): Declare.
18066 * hostio.c: New file.
18067 * server.c (handle_v_requests): Take packet_len and new_packet_len
18068 for binary packets. Call handle_vFile.
18069 (main): Update call to handle_v_requests.
18071 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
18073 * linux-low.c: Include <sched.h>.
18075 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
18077 * linux-low.c (linux_tracefork_grandchild): New.
18078 (linux_tracefork_child): Use clone.
18079 (linux_test_for_tracefork): Use clone; allocate and free a stack.
18081 2007-10-31 Joel Brobecker <brobecker@adacore.com>
18083 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
18085 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
18087 * linux-low.c (handle_extended_wait): Handle unexpected signals.
18089 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
18091 * inferiors.c (change_inferior_id): Delete.
18092 (add_pid_to_list, pull_pid_from_list): New.
18093 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
18094 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
18095 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
18096 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
18097 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
18098 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
18099 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
18100 (using_threads): Always set to 1.
18101 (handle_extended_wait): New.
18102 (add_process): Do not set TID.
18103 (linux_create_inferior): Set must_set_ptrace_flags.
18104 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
18105 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
18106 (linux_thread_alive): Rename TID argument to LWPID.
18107 (linux_wait_for_process): Handle unknown processes. Do not use TID.
18108 (linux_wait_for_event): Do not use TID or check using_threads. Update
18109 call to dead_thread_notify. Call handle_extended_wait.
18110 (linux_create_inferior): Use PTRACE_SETOPTIONS.
18111 (send_sigstop): Delete sigstop_sent.
18112 (wait_for_sigstop): Avoid TID.
18113 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
18114 (linux_test_for_tracefork): New.
18115 (linux_lookup_signals): Use thread_db_active and
18116 linux_supports_tracefork_flag.
18117 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
18118 * linux-low.h (get_process_thread): Avoid TID.
18119 (struct process_ifo): Move thread_known and tid to the end. Remove
18121 (linux_attach_lwp, thread_db_init): Update prototypes.
18122 * server.h (change_inferior_id): Delete prototype.
18123 (add_pid_to_list, pull_pid_from_list): New prototypes.
18124 * thread-db.c (thread_db_use_events): New.
18125 (find_first_thread): Rename to...
18126 (find_one_thread): ...this. Update callers and messages. Do not
18127 call fatal. Check thread_db_use_events. Do not call
18128 change_inferior_id or new_thread_notify.
18129 (maybe_attach_thread): Update. Do not call new_thread_notify.
18130 (thread_db_init): Set thread_db_use_events. Check use_events.
18131 * utils.c (fatal, warning): Correct message prefix.
18133 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
18135 * Makefile.in (clean): Remove new files.
18136 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
18137 (powerpc-64.o, powerpc-64.c): New rules.
18138 * configure.srv: Use alternate register sets for powerpc64-*-linux*
18139 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
18141 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
18143 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
18144 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
18145 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
18146 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
18147 (target_regsets): Add AltiVec and SPE register sets.
18148 * configure.ac: Check for AltiVec and SPE.
18149 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
18150 (ppc_fill_vrregset, ppc_store_vrregset): New.
18151 (target_regsets): Add AltiVec register set.
18152 * configure: Regenerated.
18154 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
18156 * linux-low.c (O_LARGEFILE): Define.
18157 (linux_read_memory): Use /proc/PID/mem.
18158 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
18159 * configure, config.in: Regenerated.
18161 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
18163 * linux-low.c (linux_wait_for_event): Do not pass signals while
18166 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
18168 * win32-low.c (create_process): New.
18169 (win32_create_inferior): Use create_process instead of
18170 CreateProcess. If create_process failed retry appending an ".exe"
18171 suffix. Store the GetLastError result immediatelly after
18172 create_process calls and use it on the call to error.
18174 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
18176 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
18178 2007-08-23 Joel Brobecker <brobecker@adacore.com>
18180 * configure.ac: Switch license to GPLv3.
18182 2007-08-01 Michael Snyder <msnyder@access-company.com>
18184 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
18186 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
18188 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
18190 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
18191 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
18192 CloseToolhelp32Snapshot.
18193 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
18194 CloseToolhelp32Snapshot.
18196 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
18198 * server.c (main): Check for inferior exit before main loop.
18200 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
18202 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
18203 instead of on tmp_desc.
18205 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
18206 Daniel Jacobowitz <dan@codesourcery.com>
18208 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
18209 (add_thread): Minor cleanups.
18210 (clear_inferiors): Move lower in the file. Clear the DLL
18212 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
18213 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
18214 (xml_escape_text): New.
18215 * server.c (handle_query): Handle qXfer:libraries:read. Report it
18217 (handle_v_cont): Report errors.
18218 (gdbserver_version): Update.
18219 (main): Correct size of own_buf. Do not report initial DLL events.
18220 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
18221 (unloaded_dll, xml_escape_text): New.
18222 * win32-low.c (enum target_waitkind): Update comments.
18223 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
18224 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
18225 (win32_EnumProcessModules, win32_GetModuleInformation)
18226 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
18227 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
18228 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
18229 (win32_Module32First, win32_Module32Next, load_toolhelp)
18230 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
18231 (get_child_debug_event): Handle DLL events.
18232 (win32_wait): Likewise.
18234 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
18236 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
18237 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
18239 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
18241 * win32-low.c (handle_output_debug_string): Ignore event if not
18244 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
18246 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
18248 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
18250 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
18252 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
18254 * inferiors.c (change_inferior_id): Add comment.
18255 * linux-low.c (check_removed_breakpoint): Add an early
18256 prototype. Improve debug output.
18257 (linux_attach): Doc update.
18258 (linux_detach_one_process, linux_detach): Clean up before releasing
18260 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
18261 * linux-low.h (struct process_info): Doc improvement.
18262 * mem-break.c (delete_all_breakpoints): New.
18263 * mem-break.h (delete_all_breakpoints): New prototype.
18264 * thread-db.c (find_first_thread): New.
18265 (thread_db_create_event): Call it instead of
18266 thread_db_find_new_threads. Clean up unused variables.
18267 (maybe_attach_thread): Remove first thread handling.
18268 (thread_db_find_new_threads): Use find_first_thread.
18269 (thread_db_get_tls_address): Likewise.
18271 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
18273 * thread-db.c (thread_db_find_new_threads): Add prototype.
18274 (thread_db_create_event): Check for the main thread before adding
18276 (maybe_attach_thread): Only enable event reporting if TID == 0.
18277 (thread_db_get_tls_address): Check for new threads.
18279 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
18281 * linux-low.c (linux_create_inferior): Try execv before execvp.
18282 * spu-low.c (spu_create_inferior): Likewise.
18284 2007-06-13 Mike Frysinger <vapier@gentoo.org>
18286 * linux-low.c (linux_create_inferior): Change execv to execvp.
18287 * spu-low.c (spu_create_inferior): Likewies.
18289 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
18291 * Makefile.in (clean): Clean new files instead of deleted ones.
18292 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
18293 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
18295 * configure.srv: Specify XML files and new regformats for MIPS and
18297 * linux-mips-low.c (mips_num_regs): Set to only used registers.
18298 (mips_regmap): Do not fetch $0. Remove unused registers. Add
18299 an entry for the restart register.
18300 (mips_cannot_fetch_register, mips_cannot_store_register)
18301 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
18302 register names to match the XML descriptions.
18303 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
18304 restart register instead of $0.
18306 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
18307 Markus Deuling <deuling@de.ibm.com>
18309 * remote-utils.c (decode_xfer_write): New function.
18310 * server.h (decode_xfer_write): Add prototype.
18311 * server.c (handle_query): Add PACKET_LEN argument. Support
18312 qXfer:spu:read and qXfer:spu:write packets.
18313 (main): Pass packet_len to handle_query.
18314 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
18315 * target.h (target_ops): Add qxfer_spu.
18317 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
18319 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
18320 accessing non-seekable spufs files.
18322 2007-05-16 Markus Deuling <deuling@de.ibm.com>
18324 * server.c (handle_query): Add reply for qC packet.
18326 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18327 Leo Zayas <lerele@champenstudios@com>
18329 * server.h (check_remote_input_interrupt_request): New function.
18330 * remote_utils.c (INVALID_DESCRIPTOR): New define.
18331 (remote_desc): Initialize with INVALID_DESCRIPTOR.
18332 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
18333 (check_remote_input_interrupt_request): New function.
18334 * server.h (check_remote_input_interrupt_request): Declare.
18335 * win32-low.c (winapi_DebugBreakProcess,
18336 winapi_GenerateConsoleCtrlEvent): New typedefs.
18337 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
18339 (win32_wait): Check for remote interrupt request
18340 with check_remote_input_interrupt_request.
18341 (win32_request_interrupt): New function.
18342 (win32_target_op): Set request_interrupt to win32_request_interrupt.
18344 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18346 * win32-low.c (debug_registers_changed,
18347 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
18348 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
18349 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
18350 (thread_rec): Get context using the low target.
18351 (child_add_thread): Call thread_added on the low target,
18352 which does the same thing.
18354 (do_initial_child_stuff): Remove debug registers references.
18355 Set context using the low target. Resume threads after
18356 setting the contexts.
18357 (child_continue): Remove dead variable. Remove debug
18358 registers references.
18359 (child_fetch_inferior_registers): Go through the low target.
18360 (do_child_store_inferior_registers): Remove.
18361 (child_store_inferior_registers): Go through the low target.
18362 (win32_resume): Remove debug registers references.
18363 Set context using the low target.
18364 (handle_exception): Change return type to void. Don't record
18365 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
18366 first chance exception.
18367 (get_child_debug_event): Change return type to void. Remove
18368 goto loop. Always return after waiting for debug event.
18369 (win32_wait): Convert to switch statement. Handle spurious
18372 * win32-i386-low.c (debug_registers_changed,
18373 debug_registers_used): New.
18374 (initial_stuff): Rename to ...
18375 (i386_initial_stuff): ... this. Clear debug registers
18377 (store_debug_registers): Delete.
18378 (i386_get_thread_context): New.
18379 (load_debug_registers): Delete.
18380 (i386_set_thread_context): New.
18381 (i386_thread_added): New.
18382 (single_step): Rename to ...
18383 (i386_single_step): ... this.
18384 (do_fetch_inferior_registers): Rename to ...
18385 (i386_fetch_inferior_register): ... this.
18386 (i386_store_inferior_register): New.
18387 (the_low_target): Adapt to new interface.
18389 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
18390 (arm_get_thread_context): New.
18391 (arm_set_thread_context): New.
18393 (do_fetch_inferior_registers): Rename to ...
18394 (arm_fetch_inferior_register): ... this.
18395 (arm_store_inferior_register): New.
18396 (arm_wince_breakpoint): Reimplement as unsigned long.
18397 (arm_wince_breakpoint_len): Define.
18398 (the_low_target): Adapt to new interface.
18400 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
18401 load_debug_registers. Add get_thread_context, set_thread_context,
18402 thread_added and store_inferior_register. Rename
18403 fetch_inferior_registers to fetch_inferior_register.
18404 (regptr): Remove declaration.
18406 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18408 * linux-low.c (linux_detach): Change return type to int. Return 0.
18409 * spu-low.c (spu_detach): Likewise.
18411 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18413 * target.h (target_ops): Change return type of detach to int.
18415 (join_inferior): New.
18416 * server.c (main): Don't skip detach support on mingw32.
18417 If the inferior doesn't support detaching return error.
18418 Call join_inferior instead of using waitpid.
18419 * linux-low.c (linux_join): New.
18420 (linux_target_op): Add linux_join.
18421 * spu-low.c (spu_join): New.
18422 (spu_target_ops): Add spu_join.
18423 * win32-low.c (win32_detach): Adapt to new interface.
18424 Reopen current_process_handle before detaching. Issue a child
18425 resume before detaching.
18427 (win32_target_op): Add win32_join.
18429 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18431 * win32-low.c (win32-attach): Fix return value.
18432 * target.h (target_ops): Describe ATTACH return values.
18434 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18436 * win32-low.c (GETPROCADDRESS): Define.
18437 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
18438 (winapi_DebugSetProcessKillOnExit): Likewise.
18439 (win32_create_inferior): Force usage of ansi CreateProcessA.
18440 (win32_attach): Use GETPROCADDRESS.
18441 (win32_detach): Likewise.
18443 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18445 * win32-low.c (win32_wait): Don't use WSTOPSIG.
18447 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
18449 * win32-low.c: Commit leftover changes from 2007-03-29.
18451 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
18453 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
18454 fields short instead of int. Add explicit padding.
18455 (i387_cache_to_fsave): Remove unnecessary casts.
18456 (i387_fsave_to_cache): Doc fix.
18457 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
18459 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
18461 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
18462 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
18464 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
18466 * configure.srv (arm*-*-mingw32ce*): Move near the other
18469 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
18471 * configure.ac: Add errno checking.
18472 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
18473 sys/file.h and malloc.h.
18474 (AC_CHECK_DECLS): Add perror.
18475 (srv_mingwce): Handle.
18476 * configure.srv (i[34567]86-*-cygwin*): Add
18477 win32-i386-low.o to srv_tgtobj.
18478 (i[34567]86-*-mingw*): Likewise.
18479 (arm*-*-mingw32ce*): Add case.
18480 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
18481 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
18482 [__MINGW32CE__] (strerror): New function.
18483 [__MINGW32CE__] (errno): Define to GetLastError.
18484 [__MINGW32CE__] (COUNTOF): New macro.
18485 (remote_open): Remove extra close call.
18486 * mem-break.c (delete_breakpoint_at): New function.
18487 * mem-break.h (delete_breakpoint_at): Declare.
18488 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
18489 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
18490 [USE_WIN32API] (read, write): Add char* casts.
18491 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
18492 * server.h: Include wincecompat.h on Windows CE.
18493 [HAVE_ERRNO_H]: Check.
18494 (perror): Declare if not declared.
18495 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
18496 (perror_with_name): Remove errno declaration.
18497 * wincecompat.h: New.
18498 * wincecompat.c: New.
18499 * win32-low.h: New.
18500 * win32-arm-low.c: New.
18501 * win32-i386-low.c: New.
18502 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
18503 (OUTMSG2): Make it safe.
18505 (COUNTOF): New macro.
18506 (NUM_REGS): Get it from the low target.
18507 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
18508 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
18509 (thread_rec): Let low target handle debug registers.
18510 (child_add_thread): Likewise.
18511 (child_init_thread_list): Likewise.
18512 (continue_one_thread): Likewise.
18514 (do_child_fetch_inferior_registers): Move to ...
18515 * win32-i386-low.c: ... here, and rename to ...
18516 (do_fetch_inferior_registers): ... this.
18517 * win32-low.c (child_fetch_inferior_registers):
18518 Go through the low target.
18519 (do_child_store_inferior_registers): Use regptr.
18520 (strwinerror): New function.
18521 (win32_create_inferior): Handle Windows CE.
18522 Use strwinerror instead of strerror on Windows error
18523 codes. Add program to the error output.
18524 Don't close the main thread handle on Windows CE.
18525 (win32_attach): Use coredll.dll on Windows CE.
18526 (win32_kill): Close current process and current
18528 (win32_detach): Use coredll.dll on Windows CE.
18529 (win32_resume): Let low target handle debug registers, and
18531 (handle_exception): Add/Remove initial breakpoint. Avoid
18532 non-existant WSTOPSIG on Windows CE.
18533 (win32_read_inferior_memory): Cast to remove warning.
18534 (win32_arch_string): Go through the low target.
18535 (initialize_low): Call set_breakpoint_data with the low
18536 target's breakpoint.
18537 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
18538 FOP_REGNUM, mappings): Move to ...
18539 * win32-i386-low.c: ... here.
18540 * win32-low.c (win32_thread_info): Move to ...
18541 * win32-low.h: ... here.
18542 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
18543 win32-arm-low.c and wincecompat.c.
18544 (all:): Add $EXEEXT.
18545 (install-only:): Likewise.
18546 (gdbserver:): Likewise.
18547 (gdbreplay:): Likewise.
18548 * config.in: Regenerate.
18549 * configure: Regenerate.
18551 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
18553 * win32-low.c: Rename typedef thread_info to
18554 win32_thread_info throughout.
18556 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
18558 * win32-i386-low.c: Rename to ...
18559 * win32-low.c: ... this.
18560 * configure.srv: Replace win32-i386-low.o with win32-low.o.
18561 * Makefile.in: Likewise.
18563 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
18565 * remote-utils.c (monitor_output): Constify msg parameter.
18566 * server.h (monitor_output): Likewise.
18567 * win32-i386-low.c (handle_output_debug_string): New.
18568 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
18569 handle_output_debug_string.
18570 (get_child_debug_event): Likewise.
18572 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
18574 * server.c (main): Correct strtoul check.
18576 2007-03-27 Jon Ringle <jon@ringle.org>
18578 * linux-low.c: Check __ARCH_HAS_MMU__ also.
18580 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
18582 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
18584 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
18586 * terminal.h: Check HAVE_SGTTY_H.
18588 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
18590 * remote-utils.c (remote_open): Print out the assigned port number.
18592 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
18594 * remote-utils.c (monitor_output): New function.
18595 * server.c (debug_threads): Define here.
18596 (monitor_show_help): New function.
18597 (handle_query): Handle qRcmd.
18598 (main): Do not handle 'd' packet.
18599 * server.h (debug_threads, remote_debug, monitor_output): Declare.
18600 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
18603 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
18605 * Makefile.in (EXEEXT): New.
18606 (clean): Use $(EXEEXT).
18608 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
18610 * target.h (target_ops): Rename send_signal to request_interrupt,
18611 and remove enum target_signal parameter.
18612 * linux-low.c (linux_request_interrupt): Rename from
18613 linux_send_signal, and always send SIGINT.
18614 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
18615 and always send SIGINT.
18616 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
18618 (input_interrupt): Likewise.
18620 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
18622 * server.c (get_features_xml): Check if target implemented
18624 * win32-i386-low.c (win32_arch_string): New.
18625 (win32_target_ops): Add win32_arch_string as arch_string member.
18627 2007-02-22 Markus Deuling <deuling@de.ibm.com>
18629 * spu-low.c (spu_arch_string): New.
18630 (spu_target_ops): Add spu_arch_string.
18632 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
18634 * remote-utils.c: Remove HAVE_TERMINAL_H check.
18635 * configure.ac: Do not check for terminal.h.
18636 * configure, config.in: Regenerated.
18638 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
18640 * Makefile.in (OBS): Add $(XML_BUILTIN).
18641 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
18643 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
18644 (arm-with-iwmmxt.c): New.
18645 * config.in, configure: Regenerate.
18646 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
18647 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
18648 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
18649 (arm*-*-linux*): Add iWMMXt and regset support.
18650 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
18651 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
18652 (arm_store_wmmxregset, target_regsets): New.
18653 * server.c (get_features_xml): Take annex argument. Check builtin
18655 (handle_query): Handle multiple annexes.
18657 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
18659 * remote-utils.c [USE_WIN32API] (read, write): Define.
18660 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
18663 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
18665 * linux-i386-low.c (the_low_target): Set arch_string.
18666 * linux-x86-64-low.c (the_low_target): Likewise.
18667 * linux-low.c (linux_arch_string): New.
18668 (linux_target_ops): Add it.
18669 * linux-low.h (struct linux_target_ops): Add arch_string.
18670 * server.c (write_qxfer_response): Use const void * for DATA.
18671 (get_features_xml): New.
18672 (handle_query): Handle qXfer:features:read. Report it for qSupported.
18673 * target.h (struct target_ops): Add arch_string method.
18675 2007-01-03 Denis Pilat <denis.pilat@st.com>
18676 Daniel Jacobowitz <dan@codesourcery.com>
18678 * linux-low.c (linux_kill): Handle being called with no threads.
18679 * win32-i386-low.c (win32_kill): Likewise.
18680 (get_child_debug_event): Clear current_process_handle.
18682 2006-12-30 Denis PILAT <denis.pilat@st.com>
18683 Daniel Jacobowitz <dan@codesourcery.com>
18685 * remote-utils.c (remote_open): Check the type of specified
18686 serial port devices before opening them.
18687 * server.c (main): Kill the inferior if an error occurs during
18688 the first remote_open.
18690 2006-12-05 Markus Deuling <deuling@de.ibm.com>
18692 * README: Update supported targets.
18694 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
18696 * Makefile.in (clean): Remove reg-mips64.c.
18697 (reg-mips64.c, reg-mips64.o): New rules.
18698 * configure.srv: Handle mips64. Include regset support for mips.
18699 * linux-mips-low.c (union mips_register): New.
18700 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
18701 (mips_breakpoint, mips_breakpoint_at): Use int.
18702 (mips_collect_register, mips_supply_register)
18703 (mips_collect_register_32bit, mips_supply_register_32bit)
18704 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
18705 (mips_store_fpregset, target_regsets): New.
18706 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
18708 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
18710 * configure.srv: Add target "spu*-*-*".
18711 * Makefile.in (clean): Remove reg-spu.c.
18712 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
18713 * spu-low.c: New file.
18715 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
18717 * configure.ac: Correct td_thr_tls_get_addr test.
18718 * configure: Regenerated.
18720 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
18722 * linux-low.c (linux_wait_for_event): Reformat. Use the
18723 pass_signals array.
18724 * remote-utils.c (decode_address_to_semicolon): New.
18725 * server.c (pass_signals, handle_general_set): New.
18726 (handle_query): Mention QPassSignals for qSupported.
18727 (main): Call handle_general_set.
18728 * server.h (pass_signals, decode_address_to_semicolon): New.
18730 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
18732 * server.c (handle_query): Correct error handling for read_auxv.
18734 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
18736 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
18737 and srv_linux_thread_db to yes.
18738 * linux-s390-low.c (s390_fill_gregset): New function.
18739 (target_regsets): Define data structure.
18741 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
18743 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
18744 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
18745 * config.in, configure: Regenerated.
18746 * inferiors.c (gdb_id_to_thread): New function.
18747 (gdb_id_to_thread_id): Use it.
18748 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
18749 * linux-low.h (struct process_info): Add th member.
18750 (thread_db_get_tls_address): New prototype.
18751 * remote-utils.c (decode_address): Make non-static.
18752 * server.c (handle_query): Handle qGetTLSAddr.
18753 * server.h (gdb_id_to_thread, decode_address): New prototypes.
18754 * target.h (struct target_ops): Add get_tls_address.
18755 * thread-db.c (maybe_attach_thread): Save the thread handle.
18756 (thread_db_get_tls_address): New.
18758 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
18760 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
18761 (linux_resume_one_process): Take a siginfo_t *. Update all
18762 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
18763 (struct pending_signals): Add a siginfo_t.
18764 (linux_wait_for_process): Always set last_status.
18765 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
18766 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
18767 * linux-low.h (struct process_info): Add last_status.
18769 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
18771 * remote-utils.c (try_rle): New function.
18772 (putpkt_binary): Use it.
18774 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
18776 * Makefile.in (clean): Clean reg-x86-64-linux.c.
18777 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
18778 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
18779 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
18780 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
18783 2006-08-08 Richard Sandiford <richard@codesourcery.com>
18785 * server.c (terminal_fd): New variable.
18786 (old_foreground_pgrp): Likewise.
18787 (restore_old_foreground_pgrp): New function.
18788 (start_inferior): Record the terminal file descriptor in terminal_fd
18789 and its original foreground group in old_foreground_pgrp. Register
18790 restore_old_foreground_pgrp with atexit().
18792 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
18794 * server.c (handle_query): Correct qPart to qXfer.
18796 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
18798 * configure.ac: Check for more headers which are missing on
18799 Windows. Automatically supply -lwsock32 and USE_WIN32API.
18800 * configure.srv: Add Cygwin and mingw32.
18801 * remote-utils.c: Don't include headers unconditionally which
18802 are missing on mingw32. Include <winsock.h> for mingw32.
18803 (remote_open): Adjust for mingw32 support. Flush
18804 standard error after writing to it.
18805 (remote_close, putpkt_binary, input_interrupt, block_async_io)
18806 (unblock_async_io, enable_async_io, disable_async_io)
18807 (readchar, getpkt): Update for Winsock support.
18808 (prepare_resume_reply): Expect a protocol signal number.
18809 * server.c: Disable <sys/wait.h> on mingw32.
18810 (start_inferior): Adjust for mingw32 support. Flush
18811 standard error after writing to it.
18812 (attach_inferior): Likewise. Use protocol signal
18814 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
18816 * win32-i386-low.c: New file.
18817 * Makefile.in (XM_CLIBS): Set.
18818 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
18819 (win32-i386-low.o): New dependency rule.
18820 * linux-low.c (linux_wait): Use target signal numbers.
18821 * target.h (struct target_ops): Doc fix.
18822 * server.h (target_signal_to_name): New prototype.
18823 * gdbreplay.c: Don't include headers unconditionally which
18824 are missing on mingw32. Include <winsock.h> for mingw32.
18825 (remote_close, remote_open): Adjust for Winsock support.
18826 * configure, config.in: Regenerated.
18828 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
18830 * server.c (decode_xfer_read, write_qxfer_response): New.
18831 (handle_query): Take a packet length argument. Handle
18832 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
18833 the qSupported response.
18834 (main): Update call to handle_query.
18836 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
18838 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
18839 (putpkt_binary): Renamed from putpkt and adjusted for binary
18841 (putpkt): New wrapper for putpkt_binary.
18842 (readchar): Don't mask off the high bit.
18843 (decode_X_packet): New function.
18844 * server.c (main): Call putpkt_binary if a handler sets the packet
18845 length. Save the length of the incoming packet. Handle 'X'.
18846 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
18848 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
18850 * server.c (handle_query): Handle qSupported.
18852 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
18854 * remote-utils.c (all_symbols_looked_up): New variable.
18855 (look_up_one_symbol): Check it.
18856 * server.h (look_up_one_symbol): New declaration.
18857 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
18859 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
18861 * Makefile.in (linux-arm-low.o): Update dependencies.
18862 * linux-arm-low.c: Include "gdb_proc_service.h".
18863 (PTRACE_GET_THREAD_AREA): Define.
18864 (ps_get_thread_area): New function.
18866 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
18868 * configure.srv (m68k*-*-uclinux*): New target.
18869 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
18870 (linux_resume_one_process): Remove extraneous cast.
18871 (linux_read_offsets): New.
18872 (linux_target_op): Add linux_read_offsets on mmuless systems.
18873 * server.c (handle_query): Add qOffsets logic.
18874 * target.h (struct target_ops): Add read_offsets.
18876 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
18878 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
18879 (PTRACE_GET_THREAD_AREA): Define.
18880 (ps_get_thread_area): New function.
18881 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
18882 (linux-x86-64-low.o): Update.
18884 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
18886 * configure.ac: Remove checks for prfpregset_t.
18887 * gdb_proc_service.h: New file.
18888 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
18889 new "gdb_proc_service.h".
18890 * proc-service.c: Likewise.
18891 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
18892 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
18893 * Makefile.in (gdb_proc_service_h): Updated.
18894 * configure, config.in: Regenerated.
18896 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
18898 * remote-utils.c (prepare_resume_reply): Move declaration
18899 of gdb_id_from_wait to the top of the block.
18901 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
18903 * linux-low.c (regsets_store_inferior_registers): Read the regset
18904 from the target before filling it.
18906 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
18908 * server.c (attach_inferior): Return SIGTRAP for a successful
18911 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
18913 * Makefile.in (OBS): Add version.o.
18914 (STAGESTUFF): Delete.
18915 (version.o): Add dependencies.
18916 (version.c): Replace rule.
18917 (clean): Remove version.c.
18918 * server.c (gdbserver_version): New.
18919 (gdbserver_usage): Use printf.
18920 (main): Handle --version and --help.
18921 * server.h (version, host_name): Add declarations.
18923 2005-12-23 Eli Zaretskii <eliz@gnu.org>
18935 * linux-x86-64-low.c:
18937 * linux-s390-low.c:
18938 * linux-ppc64-low.c:
18940 * linux-mips-low.c:
18941 * linux-m68k-low.c:
18942 * linux-m32r-low.c:
18945 * linux-ia64-low.c:
18946 * linux-i386-low.c:
18947 * linux-crisv32-low.c:
18959 * gdbserver.1: Add (C) after Copyright. Update the FSF
18962 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
18964 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
18965 (arm_breakpoint_at): Recognize both breakpoints.
18966 (the_low_target): Use the correct breakpoint instruction.
18968 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
18970 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
18971 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
18972 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
18973 (the_low_target): Update.
18975 2005-10-25 Andreas Schwab <schwab@suse.de>
18977 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
18979 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
18980 (ia64_num_regs): Reduce to 462.
18982 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
18984 * acinclude.m4: Correct quoting.
18985 * aclocal.m4: Regenerated.
18987 Suggested by SZOKOVACS Robert <szo@ies.hu>:
18988 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
18989 (thread_db_init): Call thread_db_err_str.
18990 * configure.ac: Check for TD_VERSION.
18991 * config.in, configure: Regenerated.
18993 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
18995 * server.h (error, fatal, warning): Add ATTR_FORMAT.
18997 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
18999 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
19000 is not available. Define HAVE_PTRACE_GETREGS if it is.
19001 * config.in, configure: Regenerated.
19002 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
19003 * linux-i386-low.c, linux-m68k-low.c: Update to use
19004 HAVE_PTRACE_GETREGS.
19005 * linux-low.c (regsets_fetch_inferior_registers)
19006 (regsets_store_inferior_registers): Only return 0 if we processed
19008 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
19009 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
19011 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
19013 * inferiors.c (struct thread_info): Add gdb_id.
19014 (add_thread): Add gdb_id argument.
19015 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
19016 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
19017 calls to add_thread.
19018 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
19019 * server.c (handle_query): Use thread_to_gdb_id.
19020 (handle_v_cont, main): Use gdb_id_to_thread_id.
19021 * server.h (add_thread): Update prototype.
19022 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
19025 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
19027 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
19028 left-padded registers.
19029 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
19030 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
19032 2005-07-01 Steve Ellcey <sje@cup.hp.com>
19034 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
19035 * configure: Regenerate.
19036 * config.in: Regenerate.
19037 * server.h (NEED_DECLARATION_STRERROR):
19038 Replace with !HAVE_DECL_STRERROR.
19040 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
19042 * linux-low.c (linux_wait, linux_send_signal): Don't test
19043 an unsigned long variable for > 0 if it could be MAX_ULONG.
19044 * server.c (myresume): Likewise.
19045 * target.c (set_desired_inferior): Likewise.
19047 2005-06-13 Mark Kettenis <kettenis@gnu.org>
19049 * configure.ac: Simplify and improve check for socklen_t.
19050 * configure, config.in: Regenerate.
19052 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
19054 * acconfig.h: Remove.
19055 * configure.ac: Add a test for socklen_t. Use three-argument
19056 AC_DEFINE throughout.
19057 * config.in: Regenerated using autoheader 2.59.
19058 * configure: Regenerated.
19060 * gdbreplay.c (socklen_t): Provide a default.
19061 (remote_open): Use socklen_t.
19062 * remote-utils.c (socklen_t): Provide a default.
19063 (remote_open): Use socklen_t.
19064 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
19067 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
19069 * linux-low.c (linux_read_memory, linux_write_memory)
19070 (linux_read_auxv): Likewise.
19071 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
19072 (check_mem_write): Likewise.
19073 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
19075 * regcache.c (struct inferior_rgcache_data, registers_to_string)
19076 (registers_from_string, register_data): Likewise.
19077 * server.c (handle_query, main): Likewise.
19078 * server.h (convert_ascii_to_int, convert_int_to_ascii)
19079 (decode_M_packet): Likewise.
19080 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
19081 * target.h (struct target_ops): Update read_memory, write_memory,
19083 (read_inferior_memory, write_inferior_memory): Update.
19084 * linux-low.h (struct linux_target_ops): Change type of breakpoint
19085 to unsigned char *.
19086 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
19087 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
19088 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
19089 linux-s390-low.c, linux-sh-low.c: Update for changes in
19090 read_inferior_memory and the_low_target->breakpoint.
19092 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
19094 * Makefile.in (SFILES): Add linux-ppc64-low.c.
19095 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
19096 * configure.srv: Add powerpc64-*-linux*.
19097 * linux-ppc64-low.c: New file.
19099 2005-05-23 Orjan Friberg <orjanf@axis.com>
19101 * linux-cris-low.c: New file with support for CRIS.
19102 * linux-crisv32-low.c: Ditto for CRISv32.
19103 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
19104 (clean): Add reg-cris.c and reg-crisv32.c.
19105 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
19106 reg-crisv32.o, and reg-crisv32.c to make rules.
19107 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
19108 recognized targets.
19110 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
19112 * linux-low.c (fetch_register): Ensure buffer size is a multiple
19113 of sizeof (PTRACE_XFER_TYPE).
19114 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
19116 2005-05-12 Orjan Friberg <orjanf@axis.com>
19118 * target.h (struct target_ops): Add insert_watchpoint,
19119 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
19120 pointers for hardware watchpoint support.
19121 * linux-low.h (struct linux_target_ops): Ditto.
19122 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
19123 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
19124 to linux_target_ops.
19125 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
19127 * server.c (main): Recognize 'Z' and 'z' packets.
19129 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
19131 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
19132 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
19133 (the_low_target): Add new members.
19135 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
19137 * proc-service.c (ps_lgetregs): Search all_processes instead of
19140 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
19142 * server.c (start_inferior): Change return type to int.
19143 (attach_inferior): Change sigptr to int *.
19144 (handle_v_cont, handle_v_requests): Change signal to int *.
19145 (main): Change signal to int.
19147 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
19149 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
19150 * configure.srv: Add m32r*-*-linux*.
19151 * linux-m32r-low.c: New file.
19153 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
19155 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
19157 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
19159 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
19160 Take unsigned long arguments for PIDs.
19161 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
19162 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
19163 (wait_for_sigstop, linux_resume_one_process)
19164 (regsets_fetch_inferior_registers, linux_send_signal)
19165 (linux_read_auxv): Likewise. Update the types of variables holding
19166 PIDs. Update format string specifiers.
19167 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
19168 * remote-utils.c (prepare_resume_reply): Likewise.
19169 * server.c (cont_thread, general_thread, step_thread)
19170 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
19172 (handle_query): Update format specifiers.
19173 (handle_v_cont, main): Use strtoul for thread IDs.
19174 * server.h (struct inferior_list_entry): Use unsigned long for ID.
19175 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
19176 (general_thread, step_thread, thread_from_wait)
19177 (old_thread_from_wait): Update.
19178 * target.h (struct thread_resume): Use unsigned long for THREAD.
19179 (struct target_ops): Use unsigned long for arguments to attach and
19182 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
19184 * acinclude.m4: Include bfd/bfd.m4 directly.
19185 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
19186 <agriffis@toolchain.org>.
19187 * aclocal.m4, configure: Regenerated.
19189 2005-01-07 Andrew Cagney <cagney@gnu.org>
19191 * configure.ac: Rename configure.in, require autoconf 2.59.
19192 * configure: Re-generate.
19194 2004-12-08 Daniel Jacobowitz <dan@debian.org>
19196 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
19197 LIBS when finished.
19198 * aclocal.m4: Regenerated.
19199 * configure: Regenerated.
19201 2004-11-21 Andreas Schwab <schwab@suse.de>
19203 * linux-m68k-low.c (m68k_num_gregs): Define.
19204 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
19205 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
19206 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
19207 (m68k_breakpoint_at): New. Add to the_low_target.
19209 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
19210 srv_linux_thread_db to yes.
19212 2004-10-20 Joel Brobecker <brobecker@gnat.com>
19214 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
19215 (ARCH_SET_FS): Likewise.
19216 (ARCH_GET_FS): Likewise.
19217 (ARCH_GET_GS): Likewise.
19219 2004-10-16 Daniel Jacobowitz <dan@debian.org>
19221 * linux-i386-low.c (ps_get_thread_area): New.
19222 * linux-x86-64-low.c (ps_get_thread_area): New.
19223 * linux-low.c: Include <sys/syscall.h>.
19224 (linux_kill_one_process): Don't kill the first thread here.
19225 (linux_kill): Kill the first thread here.
19226 (kill_lwp): New function.
19227 (send_sigstop, linux_send_signal): Use it.
19228 * proc-service.c: Clean up #ifdefs.
19229 (fpregset_info): Delete.
19230 (ps_lgetregs): Update and enable implementation.
19231 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
19233 * remote-utils.c (struct sym_cache, symbol_cache): New.
19234 (input_interrupt): Print a clearer message.
19235 (async_io_enabled): New variable.
19236 (enable_async_io, disable_async_io): Use it. Update comments.
19237 (look_up_one_symbol): Use the symbol cache.
19238 * thread-db.c (thread_db_look_up_symbols): New function.
19239 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
19241 2004-10-16 Daniel Jacobowitz <dan@debian.org>
19243 * configure.in: Test for -rdynamic.
19244 * configure: Regenerated.
19245 * Makefile (INTERNAL_LDFLAGS): New.
19246 (gdbserver, gdbreplay): Use it.
19248 2004-09-02 Andrew Cagney <cagney@gnu.org>
19250 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
19252 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
19254 * linux-low.c (linux_wait): Clear all_processes list also.
19256 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
19258 * linux-low.c: Include <errno.h>. Remove extern declaration of
19261 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
19263 * gdbreplay.c, server.h, utils.c: Update copyright years.
19265 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
19267 * server.c (main): Print child status or termination signal from
19268 variable 'signal', not 'sig'.
19270 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
19272 * linux-low.c (linux_read_memory): Change return type to
19273 int. Check for and return error from ptrace().
19274 * target.c (read_inferior_memory): Change return type to int. Pass
19275 back return status from the_target->read_memory().
19276 * target.h (struct target_ops): Adapt *read_memory() prototype.
19278 (read_inferior_memory): Adapt prototype.
19279 * server.c (main): Return an error packet if
19280 read_inferior_memory() returns an error.
19282 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
19284 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
19285 Unify with other clean targets.
19287 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
19289 * server.c (handle_v_cont): Call set_desired_inferior.
19291 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
19293 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
19295 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
19297 * linux-low.c (linux_wait): Unblock async I/O.
19298 (linux_resume): Block and enable async I/O.
19299 * remote-utils.c (block_async_io, unblock_async_io): New functions.
19300 * server.h (block_async_io, unblock_async_io): Add prototypes.
19302 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
19304 * remote-utils.c (remote_open): Print a status notice after
19305 opening a TCP port.
19306 * server.c (attach_inferior): Print a status notice after
19309 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
19311 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
19313 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
19315 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
19317 * server.c, target.h: Update copyright years.
19319 2004-02-25 Roland McGrath <roland@redhat.com>
19321 * target.h (struct target_ops): New member `read_auxv'.
19322 * server.c (handle_query): Handle qPart:auxv:read: query using that.
19323 * linux-low.c (linux_read_auxv): New function.
19324 (linux_target_ops): Initialize `read_auxv' member to that.
19326 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
19328 Committed by Jim Blandy <jimb@redhat.com>.
19330 * linux-s390-low.c (s390_num_regs): Update.
19331 (s390_regmap): Remove control registers. Use __s390x__ predefine
19332 instead of GPR_SIZE to distiguish s390 and s390x targets.
19334 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
19336 * linux-low.c: Update copyright year.
19337 (check_removed_breakpoint): Clear pending_is_breakpoint.
19338 (linux_set_resume_request, linux_queue_one_thread)
19339 (resume_status_pending_p): New functions.
19340 (linux_continue_one_thread): Use process->resume.
19341 (linux_resume): Only resume threads if there are no pending events.
19342 * linux-low.h (struct process_info): Add resume request
19345 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
19347 * regcache.c (new_register_cache): Clear the allocated register
19348 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
19350 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
19352 * linux-low.c (linux_resume): Take a struct thread_resume *
19354 (linux_wait): Update call.
19355 (resume_ptr): New static variable.
19356 (linux_continue_one_thread): Renamed from
19357 linux_continue_one_process. Use resume_ptr.
19358 (linux_resume): Use linux_continue_one_thread.
19359 * server.c (handle_v_cont, handle_v_requests): New functions.
19360 (myresume): New function.
19361 (main): Handle 'v' case.
19362 * target.h (struct thread_resume): New type.
19363 (struct target_ops): Change argument of "resume" to struct
19365 (myresume): Delete macro.
19367 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
19369 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
19370 (uninstall): Support DESTDIR.
19372 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
19374 * configure.srv: Add xscale*linux copy of arm*linux entry.
19376 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
19378 * linux-arm-low.c (arm_reinsert_addr): New function.
19379 (the_low_target): Add arm_reinsert_addr.
19381 2003-07-08 Mark Kettenis <kettenis@gnu.org>
19383 * mem-break.c: Remove whitespace at end of file.
19385 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
19387 * configure.in: Check whether we need to prototype strerror.
19388 * server.h: Optionally prototype strerror.
19389 * gdbreplay.c (perror_with_name): Use strerror.
19390 * linux-low.c (linux_attach_lwp): Use strerror.
19391 * utils.c (perror_with_name): Use strerror.
19392 * config.in, configure: Regenerated.
19394 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
19396 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
19397 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
19399 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
19401 * Makefile.in (SFILES): Update.
19402 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
19403 low-sun3.c: Remove files.
19405 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
19407 * linux-low.c: Move comment to linux_thread_alive where it belonged.
19408 (linux_detach_one_process, linux_detach): New functions.
19409 (linux_target_ops): Add linux_detach.
19410 * server.c (main): Handle 'D' packet.
19411 * target.h (struct target_ops): Add "detach" member.
19412 (detach_inferior): Define.
19414 2003-06-13 Mark Kettenis <kettenis@gnu.org>
19416 From Kelley Cook <kelleycook@wideopenwest.com>:
19417 * configure.srv: Accept i[34567]86 variants.
19419 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
19421 * linux-low.c (linux_wait_for_event): Correct comment typos.
19422 (linux_resume_one_process): Call check_removed_breakpoint.
19423 (linux_send_signal): New function.
19424 (linux_target_ops): Add linux_send_signal.
19425 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
19427 * target.h (struct target_ops): Add send_signal.
19429 2003-05-29 Jim Blandy <jimb@redhat.com>
19431 * linux-low.c (usr_store_inferior_registers): Transfer buf in
19432 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
19433 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
19434 away part of the register's value.
19436 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
19438 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
19439 (linux_wait_for_event, linux_init_signals): Likewise.
19441 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
19443 * configure.in: Check for stdlib.h.
19444 * configure: Regenerated.
19445 * config.in: Regenerated.
19447 2003-01-04 Andreas Schwab <schwab@suse.de>
19449 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
19451 2003-01-02 Andrew Cagney <ac131313@redhat.com>
19453 * Makefile.in: Remove obsolete code.
19455 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
19457 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
19458 defined(PT_FPR0_HI).
19460 2002-11-17 Stuart Hughes <seh@zee2.com>
19462 * linux-arm-low.c (arm_num_regs): Increase.
19463 (arm_regmap): Include status register.
19465 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
19467 * linux-low.c (register_addr): Remove incorrect -1 check.
19469 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
19471 * linux-low.c (linux_create_inferior): Call setpgid. Return
19473 (unstopped_p, linux_signal_pid): Remove.
19474 (linux_target_ops): Remove linux_signal_pid.
19475 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
19476 global instead of target method.
19477 * target.h (struct target_ops): Remove signal_pid. Update comment
19478 for create_inferior.
19479 * server.c (signal_pid): New variable.
19480 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
19481 gdbserver. Set the child to be the foreground process group.
19482 (attach_inferior): Set signal_pid.
19484 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
19486 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
19488 2002-08-20 Jim Blandy <jimb@redhat.com>
19490 * Makefile.in (LDFLAGS): Allow the configure script to establish a
19493 2002-08-01 Andrew Cagney <cagney@redhat.com>
19495 * Makefile.in: Make chill references obsolete.
19497 2002-07-24 Kevin Buettner <kevinb@redhat.com>
19499 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
19500 * configure: Regenerate.
19501 * config.in: Regenerate.
19503 2002-07-09 David O'Brien <obrien@FreeBSD.org>
19505 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
19506 (perror_with_name, remote_close, remote_open, expect, play): Static.
19508 2002-07-04 Michal Ludvig <mludvig@suse.cz>
19510 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
19511 byte offsets instead of an array of indexes.
19512 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
19514 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
19516 * regcache.c: Add comment.
19518 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
19520 * thread-db.c: New file.
19521 * proc-service.c: New file.
19522 * acinclude.m4: New file.
19523 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
19524 proc-service.o, and thread-db.o.
19525 (linux-low.o): Add USE_THREAD_DB.
19526 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
19527 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
19528 * aclocal.m4: Regenerated.
19529 * config.in: Regenerated.
19530 * configure: Regenerated.
19531 * configure.in: Check for proc_service.h, sys/procfs.h,
19532 thread_db.h, and linux/elf.h headrs.
19533 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
19534 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
19535 Check for -lthread_db and thread support.
19536 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
19537 PowerPC, and SuperH.
19538 * i387-fp.c: Constify arguments.
19539 * i387-fp.h: Likewise.
19540 * inferiors.c: (struct thread_info): Renamed from
19541 `struct inferior_info'. Remove PID member. Use generic inferior
19542 list header. All uses updated.
19543 (inferiors, signal_pid): Removed.
19544 (all_threads): New variable.
19545 (get_thread): Define.
19546 (add_inferior_to_list): New function.
19547 (for_each_inferior): New function.
19548 (change_inferior_id): New function.
19549 (add_inferior): Removed.
19550 (remove_inferior): New function.
19551 (add_thread): New function.
19552 (free_one_thread): New function.
19553 (remove_thread): New function.
19554 (clear_inferiors): Use for_each_inferior and free_one_thread.
19555 (find_inferior): New function.
19556 (find_inferior_id): New function.
19557 (inferior_target_data): Update argument type.
19558 (set_inferior_target_data): Likewise.
19559 (inferior_regcache_data): Likewise.
19560 (set_inferior_regcache_data): Likewise.
19561 * linux-low.c (linux_bp_reinsert): Remove.
19562 (all_processes, stopping_threads, using_thrads)
19563 (struct pending_signals, debug_threads, pid_of): New.
19564 (inferior_pid): Replace with macro.
19565 (struct inferior_linux_data): Remove.
19566 (get_stop_pc, add_process): New functions.
19567 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
19568 Use add_process and add_thread.
19569 (linux_attach_lwp): New function, based on old linux_attach. Use
19570 add_process and add_thread. Set stop_expected for new threads.
19571 (linux_attach): New function.
19572 (linux_kill_one_process): New function.
19573 (linux_kill): Kill all LWPs.
19574 (linux_thread_alive): Use find_inferior_id.
19575 (check_removed_breakpoints, status_pending_p): New functions.
19576 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
19577 Update. Use WNOHANG. Wait for cloned processes also. Update process
19578 struct for the found process.
19579 (linux_wait_for_event): New function.
19580 (linux_wait): Use it. Support LWPs.
19581 (send_sigstop, wait_for_sigstop, stop_all_processes)
19582 (linux_resume_one_process, linux_continue_one_process): New functions.
19583 (linux_resume): Support LWPs.
19584 (REGISTER_RAW_SIZE): Remove.
19585 (fetch_register): Use register_size instead. Call supply_register.
19586 (usr_store_inferior_registers): Likewise. Call collect_register.
19587 Fix recursive case.
19588 (regsets_fetch_inferior_registers): Improve error message.
19589 (regsets_store_inferior_registers): Add debugging.
19590 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
19591 (unstopped_p, linux_signal_pid): New functions.
19592 (linux_target_ops): Add linux_signal_pid.
19593 (linux_init_signals): New function.
19594 (initialize_low): Call it. Initialize using_threads.
19595 * regcache.c (inferior_regcache_data): Add valid
19597 (get_regcache): Fetch registers lazily. Add fetch argument
19598 and update all callers.
19599 (regcache_invalidate_one, regcache_invalidate): New
19601 (new_register_cache): Renamed from create_register_cache.
19602 Return the new regcache.
19603 (free_register_cache): Change argument to a void *.
19604 (registers_to_string, registers_from_string): Call get_regcache
19605 with fetch flag set.
19606 (register_data): Make static. Pass fetch flag to get_regcache.
19607 (supply_register): Call get_regcache with fetch flag clear.
19608 (collect_register): Call get_regcache with fetch flag set.
19609 (collect_register_as_string): New function.
19610 * regcache.h: Update.
19611 * remote-utils.c (putpkt): Flush after debug output and use
19613 Handle input interrupts while waiting for an ACK.
19614 (input_interrupt): Use signal_pid method.
19615 (getpkt): Flush after debug output and use stderr.
19616 (outreg): Use collect_register_as_string.
19617 (new_thread_notify, dead_thread_notify): New functions.
19618 (prepare_resume_reply): Check using_threads. Set thread_from_wait
19619 and general_thread.
19620 (look_up_one_symbol): Flush after debug output.
19621 * server.c (step_thread, server_waiting): New variables.
19622 (start_inferior): Don't use signal_pid. Update call to mywait.
19623 (attach_inferior): Update call to mywait.
19624 (handle_query): Handle qfThreadInfo and qsThreadInfo.
19625 (main): Don't fetch/store registers explicitly. Use
19626 set_desired_inferior. Support proposed ``Hs'' packet. Update
19628 * server.h: Update.
19629 (struct inferior_list, struct_inferior_list_entry): New.
19630 * target.c (set_desired_inferior): New.
19631 (write_inferior_memory): Constify.
19632 (mywait): New function.
19633 * target.h: Update.
19634 (struct target_ops): New signal_pid method.
19635 (mywait): Removed macro, added prototype.
19637 * linux-low.h (regset_func): Removed.
19638 (regset_fill_func, regset_store_func): New.
19639 (enum regset_type): New.
19640 (struct regset_info): Add type field. Use new operation types.
19641 (struct linux_target_ops): stop_pc renamed to get_pc.
19642 Add decr_pc_after_break and breakpoint_at.
19643 (get_process, get_thread_proess, get_process_thread)
19644 (strut process_info, all_processes, linux_attach_lwp)
19645 (thread_db_init): New.
19647 * linux-arm-low.c (arm_get_pc, arm_set_pc,
19648 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
19649 (the_low_target): Add new members.
19650 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
19651 (i386_store_fpxregset): Constify.
19652 (target_regsets): Add new kind identifier.
19653 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
19654 (i386_set_pc): Add debugging.
19655 (i386_breakpoint_at): New function.
19656 (the_low_target): Add new members.
19657 * linux-mips-low.c (mips_get_pc, mips_set_pc)
19658 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
19659 (mips_breakpoint_at): New.
19660 (the_low_target): Add new members.
19661 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
19662 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
19663 (the_low_target): Add new members.
19664 * linux-sh-low.c (sh_get_pc, sh_set_pc)
19665 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
19666 (the_low_target): Add new members.
19667 * linux-x86-64-low.c (target_regsets): Add new kind
19670 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
19672 From Martin Pool <mbp@samba.org>:
19673 * server.c (gdbserver_usage): New function.
19676 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
19678 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
19679 stop_at -> stop_pc.
19681 2002-05-04 Andrew Cagney <ac131313@redhat.com>
19683 * Makefile.in: Remove obsolete code.
19685 2002-04-24 Michal Ludvig <mludvig@suse.cz>
19687 * linux-low.c (regsets_fetch_inferior_registers),
19688 (regsets_store_inferior_registers): Removed cast to int from
19690 * regcache.h: Added declaration of struct inferior_info.
19692 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
19694 * inferiors.c (struct inferior_info): Add regcache_data.
19695 (add_inferior): Call create_register_cache.
19696 (clear_inferiors): Call free_register_cache.
19697 (inferior_regcache_data, set_inferior_regcache_data): New functions.
19698 * regcache.c (struct inferior_regcache_data): New.
19699 (registers): Remove.
19700 (get_regcache): New function.
19701 (create_register_cache, free_register_cache): New functions.
19702 (set_register_cache): Don't initialize the register cache here.
19703 (registers_to_string, registers_from_string, register_data): Call
19705 * regcache.h: Add prototypes.
19706 * server.h: Likewise.
19708 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
19710 * mem-break.c: New file.
19711 * mem-break.h: New file.
19712 * Makefile.in: Add mem-break.o rule; update server.h
19714 * inferiors.c (struct inferior_info): Add target_data
19716 (clear_inferiors): Free target_data member if set.
19717 (inferior_target_data, set_inferior_target_data): New functions.
19718 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
19719 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
19720 * linux-low.c (linux_bp_reinsert): New variable.
19721 (struct inferior_linux_data): New.
19722 (linux_create_inferior): Use set_inferior_target_data.
19723 (linux_attach): Likewise. Call add_inferior.
19724 (linux_wait_for_one_inferior): New function.
19725 (linux_wait): Call it.
19726 (linux_write_memory): Add const.
19727 (initialize_low): Call set_breakpoint_data.
19728 * linux-low.h (struct linux_target_ops): Add breakpoint
19730 * server.c (attach_inferior): Remove extra add_inferior
19732 * server.h: Include mem-break.h. Update inferior.c
19734 * target.c (read_inferior_memory)
19735 (write_inferior_memory): New functions.
19736 * target.h (read_inferior_memory)
19737 (write_inferior_memory): Change macros to prototypes.
19738 (struct target_ops): Update comments. Add const to write_memory
19741 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
19743 * linux-low.c (usr_store_inferior_registers): Support
19744 registers which are allowed to fail to store.
19745 * linux-low.h (linux_target_ops): Likewise.
19746 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
19747 (ppc_cannot_store_register): FPSCR may not be storable.
19749 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
19751 * server.h: Include <string.h> if HAVE_STRING_H.
19752 * ChangeLog: Correct paths in last ChangeLog entry.
19754 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
19756 * linux-low.h: Remove obsolete prototypes.
19757 (struct linux_target_ops): New.
19758 (extern the_low_target): New.
19759 * linux-low.c (num_regs, regmap): Remove declarations.
19760 (register_addr): Use the_low_target explicitly.
19761 (fetch_register): Likewise.
19762 (usr_fetch_inferior_registers): Likewise.
19763 (usr_store_inferior_registers): Likewise.
19764 * linux-arm-low.c (num_regs): Remove.
19765 (arm_num_regs): Define.
19766 (arm_regmap): Renamed from regmap, made static.
19767 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
19769 (arm_cannot_store_register): Renamed from cannot_store_register,
19771 (the_low_target): New.
19772 * linux-i386-low.c (num_regs): Remove.
19773 (i386_num_regs): Define.
19774 (i386_regmap): Renamed from regmap, made static.
19775 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
19777 (i386_cannot_store_register): Renamed from cannot_store_register,
19779 (the_low_target): New.
19780 * linux-ia64-low.c (num_regs): Remove.
19781 (ia64_num_regs): Define.
19782 (ia64_regmap): Renamed from regmap, made static.
19783 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
19785 (ia64_cannot_store_register): Renamed from cannot_store_register,
19787 (the_low_target): New.
19788 * linux-m68k-low.c (num_regs): Remove.
19789 (m68k_num_regs): Define.
19790 (m68k_regmap): Renamed from regmap, made static.
19791 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
19793 (m68k_cannot_store_register): Renamed from cannot_store_register,
19795 (the_low_target): New.
19796 * linux-mips-low.c (num_regs): Remove.
19797 (mips_num_regs): Define.
19798 (mips_regmap): Renamed from regmap, made static.
19799 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
19801 (mips_cannot_store_register): Renamed from cannot_store_register,
19803 (the_low_target): New.
19804 * linux-ppc-low.c (num_regs): Remove.
19805 (ppc_num_regs): Define.
19806 (ppc_regmap): Renamed from regmap, made static.
19807 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
19809 (ppc_cannot_store_register): Renamed from cannot_store_register,
19811 (the_low_target): New.
19812 * linux-s390-low.c (num_regs): Remove.
19813 (s390_num_regs): Define.
19814 (s390_regmap): Renamed from regmap, made static.
19815 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
19817 (s390_cannot_store_register): Renamed from cannot_store_register,
19819 (the_low_target): New.
19820 * linux-sh-low.c (num_regs): Remove.
19821 (sh_num_regs): Define.
19822 (sh_regmap): Renamed from regmap, made static.
19823 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
19825 (sh_cannot_store_register): Renamed from cannot_store_register,
19827 (the_low_target): New.
19828 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
19829 (the_low_target): New.
19831 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
19833 * Makefile.in: Add stamp-h target.
19834 * configure.in: Create stamp-h.
19835 * configure: Regenerated.
19837 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
19839 * inferiors.c: New file.
19840 * target.c: New file.
19841 * target.h: New file.
19842 * Makefile.in: Add target.o and inferiors.o. Update
19844 * linux-low.c (inferior_pid): New static variable,
19845 moved from server.c.
19846 (linux_create_inferior): Renamed from create_inferior.
19847 Call add_inferior. Return 0 on success instead of a PID.
19848 (linux_attach): Renamed from myattach.
19849 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
19850 (linux_thread_alive): Renamed from mythread_alive.
19851 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
19853 (linux_resume): Renamed from myresume. Add missing ``return 0''.
19854 (regsets_store_inferior_registers): Correct error message.
19855 Add missing ``return 0''.
19856 (linux_fetch_registers): Renamed from fetch_inferior_registers.
19857 (linux_store_registers): Renamed from store_inferior_registers.
19858 (linux_read_memory): Renamed from read_inferior_memory.
19859 (linux_write_memory): Renamed from write_inferior_memory.
19860 (linux_target_ops): New structure.
19861 (initialize_low): Call set_target_ops ().
19862 * remote-utils.c (unhexify): New function.
19863 (hexify): New function.
19864 (input_interrupt): Send signals to ``signal_pid''.
19865 * server.c (inferior_pid): Remove.
19866 (start_inferior): Update create_inferior call.
19867 (attach_inferior): Call add_inferior.
19868 (handle_query): New function.
19869 (main): Call handle_query for `q' packets.
19870 * server.h: Include "target.h". Remove obsolete prototypes.
19871 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
19873 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
19875 * Makefile.in: Add WARN_CFLAGS. Update configury
19877 * configure.in: Check for <string.h>
19878 * configure: Regenerate.
19879 * config.in: Regenerate.
19880 * gdbreplay.c: Include needed system headers.
19881 (remote_open): Remove strchr prototype.
19882 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
19883 * regcache.c (supply_register): Change buf argument to const void *.
19884 (supply_register_by_name): Likewise.
19885 (collect_register): Change buf argument to void *.
19886 (collect_register_by_name): Likewise.
19887 * regcache.h: Add missing prototypes.
19888 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
19889 * server.c (handle_query): New function.
19890 (attached): New static variable, moved out of main.
19891 (main): Quiet longjmp clobber warnings.
19892 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
19893 * utils.c (error): Remove NORETURN.