1 2020-03-11 Simon Marchi <simon.marchi@efficios.com>
3 * configure: Re-generate.
5 2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7 * .dir-locals.el: New file.
9 2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
11 * .gitattributes: New file.
13 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
15 * remote-utils.cc (prepare_resume_reply): Add ability to convert T
16 reply into an S reply.
17 * server.cc (disable_packet_T): New global.
18 (captured_main): Set new global when appropriate.
19 * server.h (disable_packet_T): Declare.
21 2020-02-21 Tom Tromey <tom@tromey.com>
23 * Makefile.in (mostlyclean): New target.
25 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
27 * target.h (struct process_stratum_target): Remove.
28 (class process_target): Rename to ...
29 (class process_stratum_target): ... this.
30 * linux-low.h (class linux_process_target): Derive from
31 'process_stratum_target'.
32 * linux-low.cc (linux_target_ops): Remove.
33 (initialize_low): Set the_target to the singleton instance of
35 * lynx-low.h (class lynx_process_target): Derive from
36 'process_stratum_target'.
37 * lynx-low.cc (lynx_target_ops): Remove.
38 (initialize_low): Set the_target to the singleton instance of
40 * nto-low.h (class nto_process_target): Derive from
41 'process_stratum_target'.
42 * nto-low.cc (nto_target_ops): Remove.
43 (initialize_low): Set the_target to the singleton instance of
45 * win32-low.h (class win32_process_target): Derive from
46 'process_stratum_target'.
47 * win32-low.cc (win32_target_ops): Remove.
48 (initialize_low): Set the_target to the singleton instance of
51 Replace 'the_target->pt' with 'the_target' in the uses below.
53 * hostio.cc (hostio_error)
58 * linux-aarch32-low.cc (arm_breakpoint_at)
59 * linux-aarch64-low.cc (aarch64_breakpoint_at)
60 * linux-arm-low.cc (arm_sigreturn_next_pc)
62 (arm_get_syscall_trapinfo)
63 * linux-cris-low.cc (cris_breakpoint_at)
64 * linux-crisv32-low.cc (cris_breakpoint_at)
65 * linux-low.cc (handle_extended_wait)
68 (linux_process_target::breakpoint_kind_from_pc)
70 * linux-m32r-low.cc (m32r_breakpoint_at)
71 * linux-mips-low.cc (mips_breakpoint_at)
72 * linux-nios2-low.cc (nios2_breakpoint_at)
73 * linux-ppc-low.cc (ppc_breakpoint_at)
74 * linux-s390-low.cc (s390_get_hwcap)
75 * linux-sh-low.cc (sh_breakpoint_at)
76 * linux-sparc-low.cc (sparc_fill_gregset_to_stack)
77 (sparc_store_gregset_from_stack)
79 * linux-tic6x-low.cc (tic6x_breakpoint_at)
80 * linux-tile-low.cc (tile_breakpoint_at)
81 * linux-x86-low.cc (x86_breakpoint_at)
82 * linux-xtensa-low.cc (xtensa_breakpoint_at)
83 * mem-break.cc (bp_size)
85 (insert_memory_breakpoint)
86 (set_raw_breakpoint_at)
87 (delete_raw_breakpoint)
89 (uninsert_raw_breakpoint)
90 (reinsert_raw_breakpoint)
91 (validate_inserted_breakpoint)
92 * regcache.cc (regcache_read_pc)
94 * remote-utils.cc (putpkt_binary_1)
97 (prepare_resume_reply)
98 * server.cc (handle_general_set)
101 (handle_qxfer_exec_file)
102 (handle_qxfer_libraries_svr4)
103 (handle_qxfer_osdata)
104 (handle_qxfer_siginfo)
109 (queue_stop_reply_callback)
111 * target.cc (prepare_to_access_memory)
112 (done_accessing_memory)
113 (read_inferior_memory)
114 (target_write_memory)
115 (target_stop_and_wait)
117 (target_mourn_inferior)
118 (target_continue_no_signal)
120 (target_supports_multi_process)
123 (target_create_inferior)
124 (target_post_create_inferior)
126 (target_supports_fork_events)
127 (target_supports_vfork_events)
128 (target_supports_exec_events)
129 (target_handle_new_gdb_connection)
132 (fetch_inferior_registers)
133 (store_inferior_registers)
135 (target_supports_non_stop)
137 (target_process_qsupported)
138 (target_supports_catch_syscall)
139 (target_get_ipa_tdesc_idx)
140 (target_supports_tracepoints)
141 (target_supports_fast_tracepoints)
142 (target_get_min_fast_tracepoint_insn_len)
143 (target_thread_stopped)
146 (target_stabilize_threads)
147 (target_install_fast_tracepoint_jump_pad)
149 (target_supports_disable_randomization)
150 (target_supports_agent)
151 (target_enable_btrace)
152 (target_disable_btrace)
154 (target_read_btrace_conf)
155 (target_supports_range_stepping)
156 (target_supports_stopped_by_sw_breakpoint)
157 (target_stopped_by_sw_breakpoint)
158 (target_supports_stopped_by_hw_breakpoint)
159 (target_supports_hardware_single_step)
160 (target_stopped_by_hw_breakpoint)
161 (target_breakpoint_kind_from_pc)
162 (target_breakpoint_kind_from_current_state)
163 (target_supports_software_single_step)
164 (target_core_of_thread)
166 (target_thread_handle)
167 * win32-low.cc (do_initial_child_stuff)
169 Rename target op default definitions listed below.
171 * target.cc (process_target::post_create_inferior): Rename as ...
172 (process_stratum_target::post_create_inferior): ... this.
173 (process_target::prepare_to_access_memory): Rename as ...
174 (process_stratum_target::prepare_to_access_memory): ... this.
175 (process_target::done_accessing_memory): Rename as ...
176 (process_stratum_target::done_accessing_memory): ... this.
177 (process_target::look_up_symbols): Rename as ...
178 (process_stratum_target::look_up_symbols): ... this.
179 (process_target::supports_read_auxv): Rename as ...
180 (process_stratum_target::supports_read_auxv): ... this.
181 (process_target::read_auxv): Rename as ...
182 (process_stratum_target::read_auxv): ... this.
183 (process_target::supports_z_point_type): Rename as ...
184 (process_stratum_target::supports_z_point_type): ... this.
185 (process_target::insert_point): Rename as ...
186 (process_stratum_target::insert_point): ... this.
187 (process_target::remove_point): Rename as ...
188 (process_stratum_target::remove_point): ... this.
189 (process_target::stopped_by_sw_breakpoint): Rename as ...
190 (process_stratum_target::stopped_by_sw_breakpoint): ... this.
191 (process_target::supports_stopped_by_sw_breakpoint): Rename as ...
192 (process_stratum_target::supports_stopped_by_sw_breakpoint): ... this.
193 (process_target::stopped_by_hw_breakpoint): Rename as ...
194 (process_stratum_target::stopped_by_hw_breakpoint): ... this.
195 (process_target::supports_stopped_by_hw_breakpoint): Rename as ...
196 (process_stratum_target::supports_stopped_by_hw_breakpoint): ... this.
197 (process_target::supports_hardware_single_step): Rename as ...
198 (process_stratum_target::supports_hardware_single_step): ... this.
199 (process_target::stopped_by_watchpoint): Rename as ...
200 (process_stratum_target::stopped_by_watchpoint): ... this.
201 (process_target::stopped_data_address): Rename as ...
202 (process_stratum_target::stopped_data_address): ... this.
203 (process_target::supports_read_offsets): Rename as ...
204 (process_stratum_target::supports_read_offsets): ... this.
205 (process_target::read_offsets): Rename as ...
206 (process_stratum_target::read_offsets): ... this.
207 (process_target::supports_get_tls_address): Rename as ...
208 (process_stratum_target::supports_get_tls_address): ... this.
209 (process_target::get_tls_address): Rename as ...
210 (process_stratum_target::get_tls_address): ... this.
211 (process_target::hostio_last_error): Rename as ...
212 (process_stratum_target::hostio_last_error): ... this.
213 (process_target::supports_qxfer_osdata): Rename as ...
214 (process_stratum_target::supports_qxfer_osdata): ... this.
215 (process_target::qxfer_osdata): Rename as ...
216 (process_stratum_target::qxfer_osdata): ... this.
217 (process_target::supports_qxfer_siginfo): Rename as ...
218 (process_stratum_target::supports_qxfer_siginfo): ... this.
219 (process_target::qxfer_siginfo): Rename as ...
220 (process_stratum_target::qxfer_siginfo): ... this.
221 (process_target::supports_non_stop): Rename as ...
222 (process_stratum_target::supports_non_stop): ... this.
223 (process_target::async): Rename as ...
224 (process_stratum_target::async): ... this.
225 (process_target::start_non_stop): Rename as ...
226 (process_stratum_target::start_non_stop): ... this.
227 (process_target::supports_multi_process): Rename as ...
228 (process_stratum_target::supports_multi_process): ... this.
229 (process_target::supports_fork_events): Rename as ...
230 (process_stratum_target::supports_fork_events): ... this.
231 (process_target::supports_vfork_events): Rename as ...
232 (process_stratum_target::supports_vfork_events): ... this.
233 (process_target::supports_exec_events): Rename as ...
234 (process_stratum_target::supports_exec_events): ... this.
235 (process_target::handle_new_gdb_connection): Rename as ...
236 (process_stratum_target::handle_new_gdb_connection): ... this.
237 (process_target::handle_monitor_command): Rename as ...
238 (process_stratum_target::handle_monitor_command): ... this.
239 (process_target::core_of_thread): Rename as ...
240 (process_stratum_target::core_of_thread): ... this.
241 (process_target::supports_read_loadmap): Rename as ...
242 (process_stratum_target::supports_read_loadmap): ... this.
243 (process_target::read_loadmap): Rename as ...
244 (process_stratum_target::read_loadmap): ... this.
245 (process_target::process_qsupported): Rename as ...
246 (process_stratum_target::process_qsupported): ... this.
247 (process_target::supports_tracepoints): Rename as ...
248 (process_stratum_target::supports_tracepoints): ... this.
249 (process_target::read_pc): Rename as ...
250 (process_stratum_target::read_pc): ... this.
251 (process_target::write_pc): Rename as ...
252 (process_stratum_target::write_pc): ... this.
253 (process_target::supports_thread_stopped): Rename as ...
254 (process_stratum_target::supports_thread_stopped): ... this.
255 (process_target::thread_stopped): Rename as ...
256 (process_stratum_target::thread_stopped): ... this.
257 (process_target::supports_get_tib_address): Rename as ...
258 (process_stratum_target::supports_get_tib_address): ... this.
259 (process_target::get_tib_address): Rename as ...
260 (process_stratum_target::get_tib_address): ... this.
261 (process_target::pause_all): Rename as ...
262 (process_stratum_target::pause_all): ... this.
263 (process_target::unpause_all): Rename as ...
264 (process_stratum_target::unpause_all): ... this.
265 (process_target::stabilize_threads): Rename as ...
266 (process_stratum_target::stabilize_threads): ... this.
267 (process_target::supports_fast_tracepoints): Rename as ...
268 (process_stratum_target::supports_fast_tracepoints): ... this.
269 (process_target::get_min_fast_tracepoint_insn_len): Rename as ...
270 (process_stratum_target::get_min_fast_tracepoint_insn_len): ... this.
271 (process_target::emit_ops): Rename as ...
272 (process_stratum_target::emit_ops): ... this.
273 (process_target::supports_disable_randomization): Rename as ...
274 (process_stratum_target::supports_disable_randomization): ... this.
275 (process_target::supports_qxfer_libraries_svr4): Rename as ...
276 (process_stratum_target::supports_qxfer_libraries_svr4): ... this.
277 (process_target::qxfer_libraries_svr4): Rename as ...
278 (process_stratum_target::qxfer_libraries_svr4): ... this.
279 (process_target::supports_agent): Rename as ...
280 (process_stratum_target::supports_agent): ... this.
281 (process_target::enable_btrace): Rename as ...
282 (process_stratum_target::enable_btrace): ... this.
283 (process_target::disable_btrace): Rename as ...
284 (process_stratum_target::disable_btrace): ... this.
285 (process_target::read_btrace): Rename as ...
286 (process_stratum_target::read_btrace): ... this.
287 (process_target::read_btrace_conf): Rename as ...
288 (process_stratum_target::read_btrace_conf): ... this.
289 (process_target::supports_range_stepping): Rename as ...
290 (process_stratum_target::supports_range_stepping): ... this.
291 (process_target::supports_pid_to_exec_file): Rename as ...
292 (process_stratum_target::supports_pid_to_exec_file): ... this.
293 (process_target::pid_to_exec_file): Rename as ...
294 (process_stratum_target::pid_to_exec_file): ... this.
295 (process_target::supports_multifs): Rename as ...
296 (process_stratum_target::supports_multifs): ... this.
297 (process_target::multifs_open): Rename as ...
298 (process_stratum_target::multifs_open): ... this.
299 (process_target::multifs_unlink): Rename as ...
300 (process_stratum_target::multifs_unlink): ... this.
301 (process_target::multifs_readlink): Rename as ...
302 (process_stratum_target::multifs_readlink): ... this.
303 (process_target::breakpoint_kind_from_pc): Rename as ...
304 (process_stratum_target::breakpoint_kind_from_pc): ... this.
305 (process_target::breakpoint_kind_from_current_state): Rename as ...
306 (process_stratum_target::breakpoint_kind_from_current_state): ... this.
307 (process_target::thread_name): Rename as ...
308 (process_stratum_target::thread_name): ... this.
309 (process_target::thread_handle): Rename as ...
310 (process_stratum_target::thread_handle): ... this.
311 (process_target::supports_software_single_step): Rename as ...
312 (process_stratum_target::supports_software_single_step): ... this.
313 (process_target::supports_catch_syscall): Rename as ...
314 (process_stratum_target::supports_catch_syscall): ... this.
315 (process_target::get_ipa_tdesc_idx): Rename as ...
316 (process_stratum_target::get_ipa_tdesc_idx): ... this.
318 2020-02-20 Pedro Alves <palves@redhat.com>
320 * target.cc (set_target_ops): Simply copy the given target pointer
321 instead of creating a copy of the pointed object.
323 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
325 Turn process_stratum_target's get_ipa_tdesc_idx op into a method
328 * target.h (struct process_stratum_target): Remove the target op.
329 (class process_target): Add the target op.
330 (target_get_ipa_tdesc_idx): Update the macro.
331 * target.cc (process_target::get_ipa_tdesc_idx): Define.
333 Update the derived classes and callers below.
335 * linux-low.cc (linux_target_ops): Update.
336 (linux_get_ipa_tdesc_idx): Turn into ...
337 (linux_process_target::get_ipa_tdesc_idx): ... this.
338 * linux-low.h (class linux_process_target): Update.
339 * lynx-low.cc (lynx_target_ops): Update.
340 * nto-low.cc (nto_target_ops): Update.
341 * win32-low.cc (win32_target_ops): Update.
343 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
345 Turn process_stratum_target's supports_catch_syscall op into a
346 method of process_target.
348 * target.h (struct process_stratum_target): Remove the target op.
349 (class process_target): Add the target op.
350 (target_supports_catch_syscall): Update the macro.
351 * target.cc (process_target::supports_catch_syscall): Define.
353 Update the derived classes and callers below.
355 * linux-low.cc (linux_target_ops): Update.
356 (linux_supports_catch_syscall): Turn into ...
357 (linux_process_target::supports_catch_syscall): ... this.
358 * linux-low.h (class linux_process_target): Update.
359 * lynx-low.cc (lynx_target_ops): Update.
360 * nto-low.cc (nto_target_ops): Update.
361 * win32-low.cc (win32_target_ops): Update.
363 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
365 Turn process_stratum_target's supports_software_single_step op
366 into a method of process_target.
368 * target.h (struct process_stratum_target): Remove the target op.
369 (class process_target): Add the target op.
370 (target_supports_software_single_step): Update the macro.
371 * target.cc (process_target::supports_software_single_step): Define.
373 Update the derived classes and callers below.
375 * linux-low.cc (linux_target_ops): Update.
376 (linux_supports_software_single_step): Turn into ...
377 (linux_process_target::supports_software_single_step): ... this.
378 * linux-low.h (class linux_process_target): Update.
379 * lynx-low.cc (lynx_target_ops): Update.
380 * nto-low.cc (nto_target_ops): Update.
381 * win32-low.cc (win32_target_ops): Update.
383 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
385 Turn process_stratum_target's thread_name and thread_handle ops
386 into methods of process_target.
388 * target.h (struct process_stratum_target): Remove the target ops.
389 (class process_target): Add the target ops.
390 (target_thread_name): Update the macro.
391 (target_thread_handle): Update the macro.
392 * target.cc (process_target::thread_name): Define.
393 (process_target::thread_handle): Define.
395 Update the derived classes and callers below.
397 * linux-low.cc (linux_target_ops): Update.
398 (linux_process_target::thread_name): Define.
399 (linux_process_target::thread_handle): Define.
400 * linux-low.h (class linux_process_target): Update.
401 * lynx-low.cc (lynx_target_ops): Update.
402 * nto-low.cc (nto_target_ops): Update.
403 * win32-low.cc (win32_target_ops): Update.
405 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
407 Turn process_stratum_target's breakpoint_kind_from_pc,
408 sw_breakpoint_from_kind, and breakpoint_kind_from_current_state
409 ops into methods of process_target.
411 * target.h (struct process_stratum_target): Remove the target op.
412 (class process_target): Add the target op.
413 (target_breakpoint_kind_from_pc): Update the macro.
414 (target_breakpoint_kind_from_current_state): Update the macro.
415 (default_breakpoint_kind_from_pc): Remove declaration.
416 * target.cc (default_breakpoint_kind_from_pc): Turn into ...
417 (process_target::breakpoint_kind_from_pc): ... this.
418 (process_target::breakpoint_kind_from_current_state): Define.
420 Update the derived classes and callers below.
422 * mem-break.cc (bp_size): Update.
424 * linux-low.cc (linux_target_ops): Update.
425 (linux_wait_1): Update.
426 (linux_breakpoint_kind_from_pc): Turn into ...
427 (linux_process_target::breakpoint_kind_from_pc): ... this.
428 (linux_sw_breakpoint_from_kind): Turn into ...
429 (linux_process_target::sw_breakpoint_from_kind): ... this.
430 (linux_breakpoint_kind_from_current_state): Turn into ...
431 (linux_process_target::breakpoint_kind_from_current_state): ... this.
432 * linux-low.h (class linux_process_target): Update.
433 * lynx-low.cc (lynx_target_ops): Update.
434 (lynx_process_target::sw_breakpoint_from_kind): Define.
435 * lynx-low.h (class lynx_process_target): Update.
436 * nto-low.cc (nto_target_ops): Update.
437 (nto_sw_breakpoint_from_kind): Turn into ...
438 (nto_process_target::sw_breakpoint_from_kind): ... this.
439 * nto-low.h (class nto_process_target): Update.
440 * win32-low.cc (win32_target_ops): Update.
441 (win32_sw_breakpoint_from_kind): Turn into ...
442 (win32_process_target::sw_breakpoint_from_kind): ... this.
443 * win32-low.h (class win32_process_target): Update.
445 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
447 Turn process_stratum_target's multifs_open, multifs_readlink,
448 multifs_unlink ops into methods of process_target.
450 * target.h (struct process_stratum_target): Remove the target ops.
451 (class process_target): Add the target ops. Also add
453 * target.cc: Include "fcntl.h", "unistd.h", "sys/types.h", and
455 (process_target::supports_multifs): Define.
456 (process_target::multifs_open): Define.
457 (process_target::multifs_readlink): Define.
458 (process_target::multifs_unlink): Define.
460 Update the derived classes and callers below.
462 * hostio.cc (handle_setfs): Update.
463 (handle_open): Update.
464 (handle_unlink): Update.
465 (handle_readlink): Update.
466 * linux-low.cc (linux_target_ops): Update.
467 (linux_process_target::supports_multifs): Define.
468 (linux_process_target::multifs_open): Define.
469 (linux_process_target::multifs_readlink): Define.
470 (linux_process_target::multifs_unlink): Define.
471 * linux-low.h (class linux_process_target): Update.
472 * lynx-low.cc (lynx_target_ops): Update.
473 * nto-low.cc (nto_target_ops): Update.
474 * win32-low.cc (win32_target_ops): Update.
476 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
478 Turn process_stratum_target's pid_to_exec_file op into a method
481 * target.h (struct process_stratum_target): Remove the target op.
482 (class process_target): Add the target op. Also add
483 'supports_pid_to_exec_file'.
484 * target.cc (process_target::pid_to_exec_file): Define.
485 (process_target::supports_pid_to_exec_file): Define.
487 Update the derived classes and callers below.
489 * server.cc (handle_qxfer_exec_file): Update.
490 (handle_query): Update.
491 * linux-low.cc (linux_target_ops): Update.
492 (linux_process_target::supports_pid_to_exec_file): Define.
493 (linux_process_target::pid_to_exec_file): Define.
494 * linux-low.h (class linux_process_target): Update.
495 * lynx-low.cc (lynx_target_ops): Update.
496 * nto-low.cc (nto_target_ops): Update.
497 * win32-low.cc (win32_target_ops): Update.
499 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
501 Turn process_stratum_target's supports_range_stepping op into a
502 method of process_target.
504 * target.h (struct process_stratum_target): Remove the target op.
505 (class process_target): Add the target op.
506 (target_supports_range_stepping): Update the macro.
507 * target.cc (process_target::supports_range_stepping): Define.
509 Update the derived classes and callers below.
511 * linux-low.cc (linux_target_ops): Update.
512 (linux_supports_range_stepping): Turn into ...
513 (linux_process_target::supports_range_stepping): ... this.
514 * linux-low.h (class linux_process_target): Update.
515 * lynx-low.cc (lynx_target_ops): Update.
516 * nto-low.cc (nto_target_ops): Update.
517 * win32-low.cc (win32_target_ops): Update.
519 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
521 Turn process_stratum_target's btrace-related ops (enable_btrace,
522 disable_btrace, read_btrace, read_btrace_conf) into methods of
525 * target.h (struct process_stratum_target): Remove the target ops.
526 (class process_target): Add the target ops.
527 (target_enable_btrace): Update.
528 (target_disable_btrace): Update.
529 (target_read_btrace): Update.
530 (target_read_btrace_conf): Update.
531 * target.cc (process_target::enable_btrace): Define.
532 (process_target::disable_btrace): Define.
533 (process_target::read_btrace): Define.
534 (process_target::read_btrace_conf): Define.
536 Update the derived classes and callers below.
538 * linux-low.cc (linux_target_ops): Update.
539 (linux_process_target:enable_btrace): Define as a wrapper around
541 (linux_low_disable_btrace): Turn into ...
542 (linux_process_target::disable_btrace): ... this.
543 (linux_low_read_btrace): Turn into ...
544 (linux_process_target::read_btrace): ... this.
545 (linux_low_btrace_conf): Turn into ...
546 (linux_process_target::read_btrace_conf): ... this.
547 * linux-low.h (class linux_process_target): Update.
548 * lynx-low.cc (lynx_target_ops): Update.
549 * nto-low.cc (nto_target_ops): Update.
550 * win32-low.cc (win32_target_ops): Update.
552 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
554 Turn process_stratum_target's supports_agent op into a method of
557 * target.h (struct process_stratum_target): Remove the target op.
558 (class process_target): Add the target op.
559 (target_supports_agent): Update the macro.
560 * target.cc (process_target::supports_agent): Define.
562 Update the derived classes and callers below.
564 * linux-low.cc (linux_target_ops): Update.
565 (linux_supports_agent): Turn into ...
566 (linux_process_target::supports_agent): ... this.
567 * linux-low.h (class linux_process_target): Update.
568 * lynx-low.cc (lynx_target_ops): Update.
569 * nto-low.cc (nto_target_ops): Update.
570 * win32-low.cc (win32_target_ops): Update.
572 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
574 Turn process_stratum_target's qxfer_libraries_svr4 op into a
575 method of process_target.
577 * target.h (struct process_stratum_target): Remove the target op.
578 (class process_target): Add the target op. Also add
579 'supports_qxfer_libraries_svr4'.
580 * target.cc (process_target::qxfer_libraries_svr4): Define.
581 (process_target::supports_qxfer_libraries_svr4): Define.
583 Update the derived classes and callers below.
585 * server.cc (handle_qxfer_libraries_svr4): Update.
586 (handle_query): Update.
587 * linux-low.cc (linux_target_ops): Update.
588 (linux_process_target::supports_qxfer_libraries_svr4): Define.
589 (linux_qxfer_libraries_svr4): Turn into ...
590 (linux_process_target::qxfer_libraries_svr4): ... 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 supports_disable_randomization op
599 into a method of process_target.
601 * target.h (struct process_stratum_target): Remove the target op.
602 (class process_target): Add the target op.
603 (target_supports_disable_randomization): Update the macro.
604 * target.cc (process_target::supports_disable_randomization): Define.
606 Update the derived classes and callers below.
608 * linux-low.cc (linux_target_ops): Update.
609 (linux_supports_disable_randomization): Turn into ...
610 (linux_process_target::supports_disable_randomization): ... this.
611 * linux-low.h (class linux_process_target): Update.
612 * lynx-low.cc (lynx_target_ops): Update.
613 * nto-low.cc (nto_target_ops): Update.
614 * win32-low.cc (win32_target_ops): Update.
616 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
618 Turn process_stratum_target's emit_ops op into a method of
621 * target.h (struct process_stratum_target): Remove the target op.
622 (class process_target): Add the target op.
623 (target_emit_ops): Update the macro.
624 * target.cc (process_target::emit_ops): Define.
626 Update the derived classes and callers below.
628 * linux-low.cc (linux_target_ops): Update.
629 (linux_emit_ops): Turn into ...
630 (linux_process_target::emit_ops): ... this.
631 * linux-low.h (class linux_process_target): Update.
632 * lynx-low.cc (lynx_target_ops): Update.
633 * nto-low.cc (nto_target_ops): Update.
634 * win32-low.cc (win32_target_ops): Update.
636 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
638 Turn process_stratum_target's install_fast_tracepoint_jump_pad
639 and get_min_fast_tracepoint_insn_len ops into methods of
642 * target.h (struct process_stratum_target): Remove the target ops.
643 (class process_target): Add the target ops. Also add
644 'supports_fast_tracepoints'.
645 (target_supports_fast_tracepoints): Update the macro.
646 (target_get_min_fast_tracepoint_insn_len): Update the macro.
647 (install_fast_tracepoint_jump_pad): Update and rename the macro
649 (target_install_fast_tracepoint_jump_pad): ... this.
650 * target.cc (process_target::supports_fast_tracepoints): Define.
651 (process_target::install_fast_tracepoint_jump_pad): Define.
652 (process_target::get_min_fast_tracepoint_insn_len): Define.
654 Update the derived classes and callers below.
656 * tracepoint.cc (install_fast_tracepoint): Update.
657 * linux-low.cc (linux_target_ops): Update.
658 (linux_process_target::supports_fast_tracepoints): Define.
659 (linux_install_fast_tracepoint_jump_pad): Turn into ...
660 (linux_process_target::install_fast_tracepoint_jump_pad): ... this.
661 (linux_get_min_fast_tracepoint_insn_len): Turn into ...
662 (linux_process_target::get_min_fast_tracepoint_insn_len): ... this.
663 * linux-low.h (class linux_process_target): Update.
664 * lynx-low.cc (lynx_target_ops): Update.
665 * nto-low.cc (nto_target_ops): Update.
666 * win32-low.cc (win32_target_ops): Update.
668 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
670 Turn process_stratum_target's stabilize_threads op into a
671 method of process_target.
673 * target.h (struct process_stratum_target): Remove the target op.
674 (class process_target): Add the target op.
675 (target_stabilize_threads): Update the macro.
676 * target.cc (process_target::stabilize_threads): Define.
678 Update the derived classes and callers below.
680 * server.cc (handle_status): Update.
681 * tracepoint.cc (cmd_qtdp): Update.
682 (cmd_qtstart): Update.
683 * linux-low.cc (linux_target_ops): Update.
684 (linux_stabilize_threads): Turn into ...
685 (linux_process_target::stabilize_threads): ... this.
686 (linux_wait_1): Update.
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 pause_all and unpause_all ops
695 into methods of process_target.
697 * target.h (struct process_stratum_target): Remove the target ops.
698 (class process_target): Add the target ops.
699 (pause_all): Update the macro and rename to...
700 (target_pause_all): ... this.
701 (unpause_all): Update the macro and rename to...
702 (target_unpause_all): ... this.
703 * target.cc (process_target::pause_all): Define.
704 (process_target::unpause_all): Define.
706 Update the derived classes and callers below.
708 * server.cc (handle_status): Update.
709 * tracepoint.cc (clear_installed_tracepoints): Update.
711 (cmd_qtstart): Update.
712 (stop_tracing): Update.
713 (cmd_qtstatus): Update.
714 (upload_fast_traceframes): Update.
715 (run_inferior_command): Update.
716 * linux-low.cc (linux_target_ops): Update.
717 (linux_pause_all): Turn into ...
718 (linux_process_target::pause_all): ... this.
719 (linux_unpause_all): Turn into ...
720 (linux_process_target::unpause_all): ... this.
721 (linux_process_target::prepare_to_access_memory): Update.
722 (linux_process_target::done_accessing_memory): Update.
723 * linux-low.h (class linux_process_target): Update.
724 * lynx-low.cc (lynx_target_ops): Update.
725 * nto-low.cc (nto_target_ops): Update.
726 * win32-low.cc (win32_target_ops): Update.
728 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
730 Turn process_stratum_target's get_tib_address op into a method of
733 * target.h (struct process_stratum_target): Remove the target op.
734 (class process_target): Add the target op. Also add
735 'supports_get_tib_address'.
736 * target.cc (process_target::get_tib_address): Define.
737 (process_target::supports_get_tib_address): Define.
739 Update the derived classes and callers below.
741 * server.cc (handle_query): Update.
742 * linux-low.cc (win32_target_ops): Update.
743 * lynx-low.cc (lynx_target_ops): Update.
744 * nto-low.cc (nto_target_ops): Update.
745 * win32-low.cc (win32_target_ops): Update.
746 (win32_process_target::supports_get_tib_address): Define.
747 (win32_get_tib_address): Turn into ...
748 (win32_process_target::get_tib_address): ... this.
749 * win32-low.h (class win32_process_target): Update.
751 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
753 Turn process_stratum_target's thread_stopped op into a method of
756 * target.h (struct process_stratum_target): Remove the target op.
757 (class process_target): Add the target op. Also add
758 'supports_thread_stopped'.
759 (target_thread_stopped): Update the macro.
760 * target.cc (process_target::thread_stopped): Define.
761 (process_target::supports_thread_stopped): Define.
762 (prepare_to_access_memory): Update.
764 Update the derived classes and callers below.
766 * server.cc (queue_stop_reply_callback): Update.
767 * linux-low.cc (linux_target_ops): Update.
768 (linux_process_target::supports_thread_stopped): Define.
769 (linux_thread_stopped): Turn into ...
770 (linux_process_target::thread_stopped): ... this.
771 * linux-low.h (class linux_process_target): Update.
772 * lynx-low.cc (lynx_target_ops): Update.
773 * nto-low.cc (nto_target_ops): Update.
774 * win32-low.cc (win32_target_ops): Update.
776 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
778 Turn process_stratum_target's read_pc and write_pc ops into
779 methods of process_target.
781 * target.h (struct process_stratum_target): Remove the target ops.
782 (class process_target): Add the target ops.
783 * target.cc (process_target::read_pc): Define.
784 (process_target::write_pc): Define.
786 Update the derived classes and callers below.
788 * regcache.cc (regcache_read_pc): Update.
789 (regcache_write_pc): Update.
790 * linux-low.cc (linux_target_ops): Update.
791 (linux_read_pc): Turn into ...
792 (linux_process_target::read_pc): ... this.
793 (linux_write_pc): Turn into ...
794 (linux_process_target::write_pc): ... 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 supports_tracepoints op into a
803 method of process_target.
805 * target.h (struct process_stratum_target): Remove the target op.
806 (class process_target): Add the target op.
807 (target_supports_tracepoints): Update the macro.
808 * target.cc (process_target::supports_tracepoints): Define.
810 Update the derived classes and callers below.
812 * linux-low.cc (linux_target_ops): Update.
813 (linux_supports_tracepoints): Turn into ...
814 (linux_process_target::supports_tracepoints): ... this.
815 * linux-low.h (class linux_process_target): Update.
816 * lynx-low.cc (lynx_target_ops): Update.
817 * nto-low.cc (nto_target_ops): Update.
818 * win32-low.cc (win32_target_ops): Update.
820 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
822 Turn process_stratum_target's process_qsupported op into a method
825 * target.h (struct process_stratum_target): Remove the target op.
826 (class process_target): Add the target op.
827 (target_process_qsupported): Update the macro.
828 * target.cc (process_target::process_qsupported): Define.
830 Update the derived classes and callers below.
832 * linux-low.cc (linux_target_ops): Update.
833 (linux_process_qsupported): Turn into ...
834 (linux_process_target::process_qsupported): ... this.
835 * linux-low.h (class linux_process_target): Update.
836 * lynx-low.cc (lynx_target_ops): Update.
837 * nto-low.cc (nto_target_ops): Update.
838 * win32-low.cc (win32_target_ops): Update.
840 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
842 Turn process_stratum_target's read_loadmap op into a method of
845 * target.h (struct process_stratum_target): Remove the target op.
846 (class process_target): Add the target op. Also add
847 'supports_read_loadmap'.
848 * target.cc (process_target::read_loadmap): Define.
849 (process_target::supports_read_loadmap): Define.
851 Update the derived classes and callers below.
853 * server.cc (handle_qxfer_fdpic): Update.
854 (handle_query): Update.
855 * linux-low.cc (linux_target_ops): Update.
856 (linux_process_target::supports_read_loadmap): Define.
857 (linux_read_loadmap): Turn into ...
858 (linux_process_target::read_loadmap): ... 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 core_of_thread op into a method of
869 * target.h (struct process_stratum_target): Remove the target op.
870 (class process_target): Add the target op.
871 (target_core_of_thread): Update the macro.
872 * target.cc (process_target::core_of_thread): Define.
874 Update the derived classes and callers below.
876 * linux-low.cc (linux_target_ops): Update.
877 (linux_process_target::core_of_thread): Define.
878 * linux-low.h (class linux_process_target): Update.
879 * lynx-low.cc (lynx_target_ops): Update.
880 * nto-low.cc (nto_target_ops): Update.
881 * win32-low.cc (win32_target_ops): Update.
883 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
885 Turn process_stratum_target's handle_monitor_command op into a
886 method of process_target.
888 * target.h (struct process_stratum_target): Remove the target op.
889 (class process_target): Add the target op.
890 (target_handle_monitor_command): Update the macro.
891 * target.cc (process_target::handle_monitor_command): Define.
893 Update the derived classes and callers below.
895 * server.cc (handle_query): Update.
896 * linux-low.cc (linux_target_ops): Update.
897 (linux_process_target::handle_monitor_command): Define.
898 * linux-low.h (class linux_process_target): Update.
899 * lynx-low.cc (lynx_target_ops): Update.
900 * nto-low.cc (nto_target_ops): Update.
901 * win32-low.cc (win32_target_ops): Update.
903 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
905 Turn process_stratum_target's handle_new_gdb_connection op into a
906 method of process_target.
908 * target.h (struct process_stratum_target): Remove the target op.
909 (class process_target): Add the target op.
910 (target_handle_new_gdb_connection): Update the macro.
911 * target.cc (process_target::handle_new_gdb_connection): Define.
913 Update the derived classes and callers below.
915 * linux-low.cc (linux_target_ops): Update.
916 (linux_handle_new_gdb_connection): Turn into ...
917 (linux_process_target::handle_new_gdb_connection): ... this.
918 * linux-low.h (class linux_process_target): Update.
919 * lynx-low.cc (lynx_target_ops): Update.
920 * nto-low.cc (nto_target_ops): Update.
921 * win32-low.cc (win32_target_ops): Update.
923 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
925 Turn process_stratum_target's supports_fork_events,
926 supports_vfork_events, and supports_exec_events ops into methods
929 * target.h (struct process_stratum_target): Remove the target ops.
930 (class process_target): Add the target ops.
931 (target_supports_fork_events): Update the macro.
932 (target_supports_vfork_events): Update the macro.
933 (target_supports_exec_events): Update the macro.
934 * target.cc (process_target::supports_fork_events): Define.
935 (process_target::supports_vfork_events): Define.
936 (process_target::supports_exec_events): Define.
938 Update the derived classes and callers below.
940 * linux-low.cc (linux_target_ops): Update.
941 (linux_supports_fork_events): Turn into ...
942 (linux_process_target::supports_fork_events): ... this.
943 (linux_supports_vfork_events): Turn into ...
944 (linux_process_target::supports_vfork_events): ... this.
945 (linux_supports_exec_events): Turn into ...
946 (linux_process_target::supports_exec_events): ... this.
947 * linux-low.h (class linux_process_target): Update.
948 * lynx-low.cc (lynx_target_ops): Update.
949 * nto-low.cc (nto_target_ops): Update.
950 * win32-low.cc (win32_target_ops): Update.
952 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
954 Turn process_stratum_target's supports_multi_process op into a
955 method of process_target.
957 * target.h (struct process_stratum_target): Remove the target op.
958 (class process_target): Add the target op.
959 * target.cc (process_target::supports_multi_process): Define.
960 (target_supports_multi_process): Update.
962 Update the derived classes and callers below.
964 * linux-low.cc (linux_target_ops): Update.
965 (linux_supports_multi_process): Turn into ...
966 (linux_process_target::supports_multi_process): ... this.
967 * linux-low.h (class linux_process_target): Update.
968 * lynx-low.cc (lynx_target_ops): Update.
969 * nto-low.cc (nto_target_ops): Update.
970 * win32-low.cc (win32_target_ops): Update.
972 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
974 Turn process_stratum_target's supports_non_stop, async, and
975 start_non_stop ops into methods of process_target.
977 * target.h (struct process_stratum_target): Remove the target ops.
978 (class process_target): Add the target ops.
979 (target_supports_non_stop): Update the macro.
980 (target_async): Update the macro.
981 (start_non_stop): Remove declaration.
982 * target.cc (process_target::supports_non_stop): Define.
983 (process_target::async): Define.
984 (process_target::start_non_stop): Define.
985 (start_non_stop): Remove.
987 Update the derived classes and callers below.
989 * server.cc (handle_qxfer_siginfo): Update.
990 (handle_query): Update.
991 * linux-low.cc (linux_target_ops): Update.
992 (linux_supports_non_stop): Turn into ...
993 (linux_process_target::supports_non_stop): ... this.
994 (linux_async): Turn into ...
995 (linux_process_target::async): ... this.
996 (linux_start_non_stop): Turn into ...
997 (linux_process_target::start_non_stop): ... this.
998 * linux-low.h (class linux_process_target): Update.
999 * lynx-low.cc (lynx_target_ops): Update.
1000 * nto-low.cc (nto_target_ops): Update.
1001 (nto_supports_non_stop): Remove; rely on the default behavior
1003 * win32-low.cc (win32_target_ops): Update.
1005 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1007 Turn process_stratum_target's qxfer_siginfo op into a method of
1010 * target.h (struct process_stratum_target): Remove the target op.
1011 (class process_target): Add the target op. Also add
1012 'supports_qxfer_siginfo'.
1013 * target.cc (process_target::qxfer_siginfo): Define.
1014 (process_target::supports_qxfer_siginfo): Define.
1016 Update the derived classes and callers below.
1018 * server.cc (handle_qxfer_siginfo): Update.
1019 (handle_query): Update.
1020 * linux-low.cc (linux_target_ops): Update.
1021 (linux_process_target::supports_qxfer_siginfo): Define.
1022 (linux_xfer_siginfo): Turn into ...
1023 (linux_process_target::qxfer_siginfo): ... this.
1024 * linux-low.h (class linux_process_target): Update.
1025 * lynx-low.cc (lynx_target_ops): Update.
1026 * nto-low.cc (nto_target_ops): Update.
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_osdata 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_osdata'.
1037 * target.cc (process_target::qxfer_osdata): Define.
1038 (process_target::supports_qxfer_osdata): Define.
1040 Update the derived classes and callers below.
1042 * server.cc (handle_qxfer_osdata): Update.
1043 (handle_query): Update.
1044 * linux-low.cc (linux_target_ops): Update.
1045 (linux_process_target::supports_qxfer_osdata): Define.
1046 (linux_qxfer_osdata): Turn into ...
1047 (linux_process_target::qxfer_osdata): ... 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 hostio_last_error op into a
1056 method of process_target.
1058 * target.h (struct process_stratum_target): Remove the target op.
1059 (class process_target): Add the target op.
1060 * target.cc: Add "hostio.h" to includes.
1061 (process_target::hostio_last_error): Define.
1063 Update the derived classes and callers below.
1065 * hostio.cc (hostio_error): Update.
1066 * linux-low.cc: Remove "hostio.h" from includes.
1067 (linux_target_ops): Update.
1068 * lynx-low.cc (lynx_target_ops): Update.
1069 * nto-low.cc (nto_target_ops): Update.
1070 * win32-low.h (class win32_process_target): Update.
1071 * win32-low.cc (win32_target_ops): Update.
1072 (wince_hostio_last_error): Turn into ...
1073 (win32_process_target::hostio_last_error): ... this.
1075 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1077 Turn process_stratum_target's get_tls_address op into a method of
1080 * target.h (struct process_stratum_target): Remove the target op.
1081 (class process_target): Add the target op. Also add
1082 'supports_get_tls_address'.
1083 * target.cc (process_target::get_tls_address): Define.
1084 (process_target::supports_get_tls_address): Define.
1086 Update the derived classes and callers below.
1088 * server.cc (handle_query): Update.
1089 * linux-low.cc (linux_target_ops): Update.
1090 (linux_process_target::supports_get_tls_address): Define.
1091 (linux_process_target::get_tls_address): Define.
1092 * linux-low.h (class linux_process_target): Update.
1093 * lynx-low.cc (lynx_target_ops): Update.
1094 * nto-low.cc (nto_target_ops): Update.
1095 * win32-low.cc (win32_target_ops): Update.
1097 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1099 Turn process_stratum_target's read_offsets op into a method of
1102 * target.h (struct process_stratum_target): Remove the target op.
1103 (class process_target): Add the target op. Also add
1104 'supports_read_offsets'.
1105 * target.cc (process_target::read_offsets): Define.
1106 (process_target::supports_read_offsets): Define.
1108 Update the derived classes and callers below.
1110 * server.cc (handle_query): Update.
1111 * linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
1112 (linux_target_ops): Update.
1113 (linux_process_target::supports_read_offsets): Define.
1114 (linux_read_offsets): Turn into ...
1115 (linux_process_target::read_offsets): ... this.
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 stopped_by_watchpoint and
1124 stopped_data_address ops into methods of process_target.
1126 * target.h (struct process_stratum_target): Remove the target ops.
1127 (class process_target): Add the target ops.
1128 * target.cc (process_target::stopped_by_watchpoint): Define.
1129 (process_target::stopped_data_address): Define.
1131 Update the derived classes and callers below.
1133 * remote-utils.cc (prepare_resume_reply): Update.
1134 * linux-low.cc (linux_target_ops): Update.
1135 (linux_stopped_by_watchpoint): Turn into ...
1136 (linux_process_target::stopped_by_watchpoint): ... this.
1137 (linux_stopped_data_address): Turn into ...
1138 (linux_process_target::stopped_data_address): ... this.
1139 * linux-low.h (class linux_process_target): Update.
1140 * lynx-low.cc (lynx_target_ops): Update.
1141 * nto-low.cc (nto_target_ops): Update.
1142 (nto_stopped_by_watchpoint): Turn into ...
1143 (nto_process_target::stopped_by_watchpoint): ... this.
1144 (nto_stopped_data_address): Turn into ...
1145 (nto_process_target::stopped_data_address): ... this.
1146 * nto-low.h (class nto_process_target): Update.
1147 * win32-low.cc (win32_target_ops): Update.
1148 (win32_stopped_by_watchpoint): Turn into ...
1149 (win32_process_target::stopped_by_watchpoint): ... this.
1150 (win32_stopped_data_address): Turn into ...
1151 (win32_process_target::stopped_data_address): ... this.
1152 * win32-low.h (class win32_process_target): Update.
1154 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1156 Turn process_stratum_target's supports_hardware_single_step op into
1157 a method of process_target.
1159 * target.h (struct process_stratum_target): Remove the target op.
1160 (class process_target): Add the target op.
1161 (target_supports_hardware_single_step): Update the macro.
1162 (target_can_do_hardware_single_step): Remove declaration.
1163 * target.cc (process_target::supports_hardware_single_step): Define.
1164 (target_can_do_hardware_single_step): Remove.
1166 Update the derived classes and callers below.
1168 * linux-low.h (class linux_process_target): Update.
1169 * linux-low.cc (linux_target_ops): Update.
1170 (linux_supports_hardware_single_step): Turn into ...
1171 (linux_process_target::supports_hardware_single_step): ... this.
1172 * lynx-low.h (class lynx_process_target): Update.
1173 * lynx-low.cc (lynx_target_ops): Update.
1174 (lynx_process_target::supports_hardware_single_step): Define.
1175 * nto-low.h (class nto_process_target): Update.
1176 * nto-low.cc (nto_target_ops): Update.
1177 (nto_process_target::supports_hardware_single_step): Define.
1178 * win32-low.h (class win32_process_target): Update.
1179 * win32-low.cc (win32_target_ops): Update.
1180 (win32_process_target::supports_hardware_single_step): Define.
1182 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1184 Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
1185 ops into methods of process_target.
1187 * target.h (struct process_stratum_target): Remove the target ops.
1188 (class process_target): Add the target ops.
1189 (target_stopped_by_hw_breakpoint): Update the macro.
1190 (target_supports_stopped_by_hw_breakpoint): Update the macro.
1191 * target.cc (process_target::stopped_by_hw_breakpoint): Define.
1192 (process_target::supports_stopped_by_hw_breakpoint): Define.
1194 Update the derived classes and callers below.
1196 * linux-low.cc (linux_target_ops): Update.
1197 (linux_stopped_by_hw_breakpoint): Turn into ...
1198 (linux_process_target::stopped_by_hw_breakpoint): ... this.
1199 (linux_supports_stopped_by_hw_breakpoint): Turn into ...
1200 (linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
1201 * linux-low.h (class linux_process_target): Update.
1202 * lynx-low.cc (lynx_target_ops): Update.
1203 * nto-low.cc (nto_target_ops): Update.
1204 * win32-low.cc (win32_target_ops): Update.
1206 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1208 Turn process_stratum_target's {supports_}stopped_by_sw_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_sw_breakpoint): Update the macro.
1214 (target_supports_stopped_by_sw_breakpoint): Update the macro.
1215 * target.cc (process_target::stopped_by_sw_breakpoint): Define.
1216 (process_target::supports_stopped_by_sw_breakpoint): Define.
1218 Update the derived classes and callers below.
1220 * linux-low.cc (linux_target_ops): Update.
1221 (linux_stopped_by_sw_breakpoint): Turn into ...
1222 (linux_process_target::stopped_by_sw_breakpoint): ... this.
1223 (linux_supports_stopped_by_sw_breakpoint): Turn into ...
1224 (linux_process_target::supports_stopped_by_sw_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 insert_point and remove_point ops
1233 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.cc (process_target::insert_point): Define.
1238 (process_target::remove_point): Define.
1240 Update the derived classes and callers below.
1242 * mem-break.cc (set_raw_breakpoint_at): Update.
1243 (delete_raw_breakpoint): Update.
1244 (uninsert_raw_breakpoint): Update.
1245 (reinsert_raw_breakpoint): Update.
1246 * linux-low.cc (linux_target_ops): Update.
1247 (linux_insert_point): Turn into ...
1248 (linux_process_target::insert_point): ... this.
1249 (linux_remove_point): Turn into ...
1250 (linux_process_target::remove_point): ... this.
1251 * linux-low.h (class linux_process_target): Update.
1252 * lynx-low.cc (lynx_target_ops): Update.
1253 * nto-low.cc (nto_target_ops): Update.
1254 (nto_insert_point): Turn into ...
1255 (nto_process_target::insert_point): ... this.
1256 (nto_remove_point): Turn into ...
1257 (nto_process_target::remove_point): ... this.
1258 * nto-low.h (class nto_process_target): Update.
1259 * win32-low.cc (win32_target_ops): Update.
1260 (win32_insert_point): Turn into ...
1261 (win32_process_target::insert_point): ... this.
1262 (win32_remove_point): Turn into ...
1263 (win32_process_target::remove_point): ... this.
1264 * win32-low.h (class win32_process_target): Update.
1266 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1268 Turn process_stratum_target's supports_z_point_type op into a
1269 method of process_target.
1271 * target.h (struct process_stratum_target): Remove the target op.
1272 (class process_target): Add the target op.
1273 * target.cc (process_target::supports_z_point_type): Define.
1275 Update the derived classes and callers below.
1277 * mem-break.cc (z_type_supported): Update.
1278 * linux-low.cc (linux_target_ops): Update.
1279 (linux_supports_z_point_type): Turn into ...
1280 (linux_process_target::supports_z_point_type): ... this.
1281 * linux-low.h (class linux_process_target): Update.
1282 * lynx-low.cc (lynx_target_ops): Update.
1283 * nto-low.cc (nto_target_ops): Update.
1284 (nto_supports_z_point_type): Turn into ...
1285 (nto_process_target::supports_z_point_type): ... this.
1286 * nto-low.h (class nto_process_target): Update.
1287 * win32-low.cc (win32_target_ops): Update.
1288 (win32_supports_z_point_type): Turn into ...
1289 (win32_process_target::supports_z_point_type): ... this.
1290 * win32-low.h (class win32_process_target): Update.
1292 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1294 Turn process_stratum_target's read_auxv op into a method of
1297 * target.h (class process_stratum_target): Remove the target op.
1298 (struct process_target): Add the target op. Also add
1299 'supports_read_auxv'.
1300 * target.cc (process_target::read_auxv): Define.
1301 (process_target::supports_read_auxv): Define.
1303 Update the derived classes and callers below.
1305 * server.cc (handle_qxfer_auxv): Update.
1306 (handle_query): Update.
1307 * linux-low.cc (linux_target_ops): Update.
1308 (linux_process_target::supports_read_auxv): Define.
1309 (linux_read_auxv): Turn into ...
1310 (linux_process_target::read_auxv): ... this.
1311 * linux-low.h (class linux_process_target): Update.
1312 * lynx-low.cc (lynx_target_ops): Update.
1313 * nto-low.cc (nto_target_ops): Update.
1314 (nto_process_target::supports_read_auxv): Define.
1315 (nto_read_auxv): Turn into ...
1316 (nto_process_target::read_auxv): ... this.
1317 * nto-low.h (class nto_process_target): Update.
1318 * win32-low.cc (win32_target_ops): Update.
1320 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1322 Turn process_stratum_target's request_interrupt op into a method of
1325 * target.h (struct process_stratum_target): Remove the target op.
1326 (class process_target): Add the target op.
1328 Update the derived classes and callers below.
1330 * remote-utils.cc (putpkt_binary_1): Update.
1331 (input_interrupt): Update.
1333 * server.cc (handle_v_requests): Update.
1334 * linux-low.cc (linux_target_ops): Update.
1335 (linux_request_interrupt): Turn into ...
1336 (linux_process_target::request_interrupt): ... this.
1337 * linux-low.h (class linux_process_target): Update.
1338 * lynx-low.cc (lynx_target_ops): Update.
1339 (lynx_request_interrupt): Turn into ...
1340 (lynx_process_target::request_interrupt): ... this.
1341 * lynx-low.h (class lynx_process_target): Update.
1342 * nto-low.cc (nto_target_ops): Update.
1343 (nto_request_interrupt): Turn into ...
1344 (nto_process_target::request_interrupt): ... this.
1345 * nto-low.h (class nto_process_target): Update.
1346 * win32-low.cc (win32_target_ops): Update.
1347 (win32_request_interrupt): Turn into ...
1348 (win32_process_target::request_interrupt): ... this.
1349 * win32-low.h (class win32_process_target): Update.
1351 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1353 Turn process_stratum_target's look_up_symbols op into a method of
1356 * target.h (struct process_stratum_target): Remove the target op.
1357 (class process_target): Add the target op.
1358 * target.cc (process_target::look_up_symbols): Define.
1360 Update the derived classes and callers below.
1362 * server.cc (handle_query): Update.
1363 * linux-low.cc (linux_target_ops): Update.
1364 (linux_look_up_symbols): Turn into ...
1365 (linux_process_target::look_up_symbols): ... this.
1366 * linux-low.h (class linux_process_target): Update.
1367 * lynx-low.cc (lynx_target_ops): Update.
1368 * nto-low.cc (nto_target_ops): Update.
1369 * win32-low.cc (win32_target_ops): Update.
1371 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1373 Turn process_stratum_target's read_memory and write_memory
1374 ops into methods of process_target.
1376 * target.h (struct process_stratum_target): Remove the target ops.
1377 (class process_target): Add the target ops.
1379 Update the derived classes and callers below.
1381 * linux-aarch32-low.cc (arm_breakpoint_at): Update.
1382 * linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
1383 * linux-arm-low.cc (arm_sigreturn_next_pc): Update.
1384 (arm_get_syscall_trapinfo): Update.
1385 * linux-cris-low.cc (cris_breakpoint_at): Update.
1386 * linux-crisv32-low.cc (cris_breakpoint_at): Update.
1387 * linux-m32r-low.cc (m32r_breakpoint_at): Update.
1388 * linux-mips-low.cc (mips_breakpoint_at): Update.
1389 * linux-nios2-low.cc (nios2_breakpoint_at): Update.
1390 * linux-ppc-low.cc (ppc_breakpoint_at): Update.
1391 * linux-sh-low.cc (sh_breakpoint_at): Update.
1392 * linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
1393 (sparc_store_gregset_from_stack): Update.
1394 (sparc_breakpoint_at): Update.
1395 * linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
1396 * linux-tile-low.cc (tile_breakpoint_at): Update.
1397 * linux-x86-low.cc (x86_breakpoint_at): Update.
1398 * linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
1399 * mem-brea.cc (insert_memory_breakpoint): Update.
1400 (validate_inserted_breakpoint): Update.
1401 * target.cc (read_inferior_memory): Update.
1402 (target_write_memory): Update.
1403 * linux-low.cc (linux_target_ops): Update.
1404 (linux_read_memory): Make a wrapper around the read_memory target
1406 (linux_process_target::read_memory): Rename from linux_read_memory.
1407 (linux_write_memory): Turn into ...
1408 (linux_process_target::write_memory): ... this.
1409 * linux-low.h (class linux_process_target): Update.
1410 * lynx-low.cc (lynx_target_ops): Update.
1411 (lynx_read_memory): Turn into ...
1412 (lynx_process_target::read_memory): ... this.
1413 (lynx_write_memory): Turn into ...
1414 (lynx_process_target::write_memory): ... this.
1415 * lynx-low.h (class lynx_process_target): Update.
1416 * nto-low.cc (nto_target_ops): Update.
1417 (nto_read_memory): Turn into ...
1418 (nto_process_target::read_memory): ... this.
1419 (nto_write_memory): Turn into ...
1420 (nto_process_target::write_memory): ... this.
1421 * nto-low.h (class nto_process_target): Update.
1422 * win32-low.cc (win32_target_ops): Update.
1423 (win32_read_inferior_memory): Turn into ...
1424 (win32_process_target::read_memory): ... this.
1425 (win32_write_inferior_memory): Turn into ...
1426 (win32_process_target::write_memory): ... this.
1427 * win32-low.h (class win32_process_target): Update.
1429 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1431 Turn process_stratum_target's prepare_to_access_memory and
1432 done_accessing_memory ops into methods of process_target.
1434 * target.h (struct process_stratum_target): Remove the target ops.
1435 (class process_target): Add the target ops.
1436 * target.cc (process_target::prepare_to_access_memory): Define.
1437 (process_target::done_accessing_memory): Define.
1438 (prepare_to_access_memory): Update.
1439 (done_accessing_memory): Update.
1441 Update the derived classes and callers below.
1443 * linux-low.cc (linux_target_ops): Update.
1444 (linux_prepare_to_access_memory): Turn into ...
1445 (linux_process_target::prepare_to_access_memory): ... this.
1446 (linux_done_accessing_memory): Turn into ...
1447 (linux_process_target::done_accessing_memory): ... this.
1448 * linux-low.h (class linux_process_target): Update.
1449 * lynx-low.cc (lynx_target_ops): Update.
1450 * nto-low.cc (nto_target_ops): Update.
1451 * win32-low.cc (win32_target_ops): Update.
1453 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1455 Turn process_stratum_target's fetch_registers and store_registers
1456 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 (fetch_inferior_registers): Update the macro.
1461 (store_inferior_registers): Update the macro.
1463 Update the derived classes and callers below.
1465 * linux-low.cc (linux_target_ops): Update.
1466 (linux_fetch_registers): Turn into ...
1467 (linux_process_target::fetch_registers): ... this.
1468 (linux_store_registers): Turn into ...
1469 (linux_process_target::store_registers): ... this.
1470 * linux-low.h (class linux_process_target): Update.
1471 * lynx-low.cc (lynx_target_ops): Update.
1472 (lynx_fetch_registers): Turn into ...
1473 (lynx_process_target::fetch_registers): ... this.
1474 (lynx_store_registers): Turn into ...
1475 (lynx_process_target::store_registers): ... this.
1476 * lynx-low.h (class lynx_process_target): Update.
1477 * nto-low.cc (nto_target_ops): Update.
1478 (nto_fetch_registers): Turn into ...
1479 (nto_process_target::fetch_registers): ... this.
1480 (nto_store_registers): Turn into ...
1481 (nto_process_target::store_registers): ... this.
1482 * nto-low.h (class nto_process_target): Update.
1483 * win32-low.cc (win32_target_ops): Update.
1484 (win32_fetch_inferior_registers): Turn into ...
1485 (win32_process_target::fetch_registers): ... this.
1486 (win32_store_inferior_registers): Turn into ...
1487 (win32_process_target::store_registers): ... this.
1488 * win32-low.h (class win32_process_target): Update.
1490 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1492 Turn process_stratum_target's wait op into a method of
1495 * target.h (struct process_stratum_target): Remove the target op.
1496 (class process_target): Add the target op.
1498 Update the derived classes and callers below.
1500 * target.cc (target_wait): Update.
1501 * linux-low.cc (linux_target_ops): Update.
1502 (linux_wait): Turn into ...
1503 (linux_process_target::wait): ... this.
1504 * linux-low.h (class linux_process_target): Update.
1505 * lynx-low.cc (lynx_target_ops): Update.
1506 (lynx_wait): Turn into ...
1507 (lynx_process_target::wait): ... this.
1508 * lynx-low.h (class lynx_process_target): Update.
1509 * nto-low.cc (nto_target_ops): Update.
1510 (nto_wait): Turn into ...
1511 (nto_process_target::wait): ... this.
1512 * nto-low.h (class nto_process_target): Update.
1513 * win32-low.cc (win32_target_ops): Update.
1514 (win32_wait): Turn into ...
1515 (win32_process_target::wait): ... this.
1516 (do_initial_child_stuff): Update.
1517 * win32-low.h (class win32_process_target): Update.
1519 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1521 Turn process_stratum_target's resume op into a method of
1524 * target.h (struct process_stratum_target): Remove the target op.
1525 (class process_target): Add the target op.
1527 Update the derived classes and callers below.
1529 * server.cc (resume): Update.
1530 * target.cc (target_stop_and_wait): Update.
1531 (target_continue_no_signal): Update.
1532 (target_continue): Update.
1533 * linux-low.cc (linux_target_ops): Update.
1534 (linux_resume): Turn into ...
1535 (linux_process_target::resume): ... this.
1536 * linux-low.h (class linux_process_target): Update.
1537 * lynx-low.cc (lynx_target_ops): Update.
1538 (lynx_resume): Turn into ...
1539 (lynx_process_target::resume): ... this.
1540 * lynx-low.h (class lynx_process_target): Update.
1541 * nto-low.cc (nto_target_ops): Update.
1542 (nto_resume): Turn into ...
1543 (nto_process_target::resume): ... this.
1544 * nto-low.h (class nto_process_target): Update.
1545 * win32-low.cc (win32_target_ops): Update.
1546 (win32_resume): Turn into ...
1547 (win32_process_target::resume): ... this.
1548 (win32_process_target::detach): Update.
1549 (do_initial_child_stuff): Update.
1550 * win32-low.h (class win32_process_target): Update.
1552 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1554 Turn process_stratum_target's thread_alive op into a method of
1557 * target.h (struct process_stratum_target): Remove the target op.
1558 (class process_target): Add the target op.
1559 (mythread_alive): Update the macro.
1561 Update the derived classes and callers below.
1563 * linux-low.cc (linux_target_ops): Update.
1564 (linux_thread_alive): Turn into ...
1565 (linux_process_target::thread_alive): ... this.
1566 (wait_for_sigstop): Update.
1567 * linux-low.h (class linux_process_target): Update.
1568 * lynx-low.cc (lynx_target_ops): Update.
1569 (lynx_thread_alive): Turn into ...
1570 (lynx_process_target::thread_alive): ... this.
1571 * lynx-low.h (class lynx_process_target): Update.
1572 * nto-low.cc (nto_target_ops): Update.
1573 (nto_thread_alive): Turn into ...
1574 (nto_process_target::thread_alive): ... this.
1575 * nto-low.h (class nto_process_target): Update.
1576 * win32-low.cc (win32_target_ops): Update.
1577 (win32_thread_alive): Turn into ...
1578 (win32_process_target::thread_alive): ... this.
1579 * win32-low.h (class win32_process_target): Update.
1581 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1583 Turn process_stratum_target's join op into a method of
1586 * target.h (struct process_stratum_target): Remove the target op.
1587 (class process_target): Add the target op.
1588 (join_inferior): Update the macro.
1590 Update the derived classes and callers below.
1592 * linux-low.cc (linux_target_ops): Update.
1593 (linux_join): Turn into ...
1594 (linux_process_target::join): ... this.
1595 * linux-low.h (class linux_process_target): Update.
1596 * lynx-low.cc (lynx_target_ops): Update.
1597 (lynx_join): Turn into ...
1598 (lynx_process_target::join): ... this.
1599 * lynx-low.h (class lynx_process_target): Update.
1600 * nto-low.cc (nto_target_ops): Update.
1601 (nto_process_target::join): Define.
1602 * nto-low.h (class nto_process_target): Update.
1603 * win32-low.cc (win32_target_ops): Update.
1604 (win32_join): Turn into ...
1605 (win32_process_target::join): ... this.
1606 * win32-low.h (class win32_process_target): Update.
1608 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1610 Turn process_stratum_target's mourn op into a method of
1613 * target.h (struct process_stratum_target): Remove the target op.
1614 (class process_target): Add the target op.
1616 Update the derived classes and callers below.
1618 * target.cc (target_mourn_inferior): Update.
1619 * linux-low.cc (linux_target_ops): Update.
1620 (linux_mourn): Turn into ...
1621 (linux_process_target::mourn): ... this.
1622 (handle_extended_wait): Update.
1623 (linux_process_target::kill): Update.
1624 (linux_process_target::detach): Update.
1625 * linux-low.h (class linux_process_target): Update.
1626 * lynx-low.cc (lynx_target_ops): Update.
1627 (lynx_mourn): Turn into ...
1628 (lynx_process_target::mourn): ... this.
1629 * lynx-low.h (class lynx_process_target): Update.
1630 * nto-low.cc (nto_target_ops): Update.
1631 (nto_mourn): Turn into ...
1632 (nto_process_target::mourn): ... this.
1633 * nto-low.h (class nto_process_target): Update.
1634 * win32-low.cc (win32_target_ops): Update.
1635 (win32_mourn): Turn into ...
1636 (win32_process_target::mourn): ... this.
1637 * win32-low.h (class win32_process_target): Update.
1639 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1641 Turn process_stratum_target's detach op into a method of
1644 * target.h (struct process_stratum_target): Remove the target op.
1645 (class process_target): Add the target op.
1646 (detach_inferior): Update the macro.
1648 Update the derived classes and callers below.
1650 * linux-low.cc (linux_target_ops): Update.
1651 (linux_detach): Turn into ...
1652 (linux_process_target::detach): ... this.
1653 * linux-low.h (class linux_process_target): Update.
1654 * lynx-low.cc (lynx_target_ops): Update.
1655 (lynx_detach): Turn into ...
1656 (lynx_process_target::detach): ... this.
1657 * lynx-low.h (class lynx_process_target): Update.
1658 * nto-low.cc (nto_target_ops): Update.
1659 (nto_detach): Turn into ...
1660 (nto_process_target::detach): ... this.
1661 * nto-low.h (class nto_process_target): Update.
1662 * win32-low.cc (win32_target_ops): Update.
1663 (win32_detach): Turn into ...
1664 (win32_process_target::detach): ... this.
1665 * win32-low.h (class win32_process_target): Update.
1667 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1669 Turn process_stratum_target's kill op into a method of
1672 * target.h (struct process_stratum_target): Remove the target op.
1673 (class process_target): Add the target op.
1675 Update the derived classes and callers below.
1677 * target.cc (kill_inferior): Update.
1678 * linux-low.cc (linux_target_ops): Update.
1679 (linux_kill): Turn into ...
1680 (linux_process_target::kill): ... this.
1681 * linux-low.h (class linux_process_target): Update.
1682 * lynx-low.cc (lynx_target_ops): Update.
1683 (lynx_kill): Turn into ...
1684 (lynx_process_target::kill): ... this.
1685 * lynx-low.h (class lynx_process_target): Update.
1686 * nto-low.cc (nto_target_ops): Update.
1687 (nto_kill): Turn into ...
1688 (nto_process_target::kill): ... this.
1689 * nto-low.h (class nto_process_target): Update.
1690 * win32-low.cc (win32_target_ops): Update.
1691 (win32_kill): Turn into ...
1692 (win32_process_target::kill): ... this.
1693 * win32-low.h (class win32_process_target): Update.
1695 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1697 Turn process_stratum_target's attach op into a method of
1700 * target.h (struct process_stratum_target): Remove the target op.
1701 (class process_target): Add the target op.
1702 (myattach): Update the macro.
1704 Update the derived classes and callers below.
1706 * linux-low.cc (linux_target_ops): Update.
1707 (linux_attach): Turn into ...
1708 (linux_process_target::attach): ... this.
1709 * linux-low.h (class linux_process_target): Update.
1710 * lynx-low.cc (lynx_target_ops): Update.
1711 (lynx_attach): Turn into ...
1712 (lynx_process_target::attach): ... this.
1713 * lynx-low.h (class lynx_process_target): Update.
1714 * nto-low.cc (nto_target_ops): Update.
1715 (nto_attach): Turn into ...
1716 (nto_process_target::attach): ... this.
1717 * nto-low.h (class nto_process_target): Update.
1718 * win32-low.cc (win32_target_ops): Update.
1719 (win32_attach): Turn into ...
1720 (win32_process_target::attach): ... this.
1721 * win32-low.h (class win32_process_target): Update.
1723 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1725 Turn process_stratum_target's post_create_inferior op into a method
1728 * target.h (struct process_stratum_target): Remove the target op.
1729 (class process_target): Add the target op.
1730 (target_post_create_inferior): Update the macro.
1731 * target.cc (process_target::post_create_inferior): Define.
1733 Update the derived classes and callers below.
1735 * linux-low.cc (linux_target_ops): Update.
1736 (linux_post_create_inferior): Turn into ...
1737 (linux_process_target::post_create_inferior): ... this.
1738 * linux-low.h (class linux_process_target): Update.
1739 * lynx-low.cc (lynx_target_ops): Update.
1740 * nto-low.cc (nto_target_ops): Update.
1741 * win32-low.cc (win32_target_ops): Update.
1743 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1745 Turn process_stratum_target's create_inferior op into a method of
1748 * target.h (struct process_stratum_target): Remove the target op.
1749 (class process_target): Add the target op.
1750 (create_inferior): Rename the macro to ...
1751 (target_create_inferior): ... this.
1753 Update the derived classes and callers below.
1755 * server.cc (handle_v_run): Update.
1756 (captured_main): Update.
1757 (process_serial_event): Update.
1758 * linux-low.cc (linux_target_ops): Update.
1759 (linux_create_inferior): Turn into ...
1760 (linux_process_target::create_inferior): ... this.
1761 * linux-low.h (class linux_process_target): Update.
1762 * lynx-low.cc (lynx_target_ops): Update.
1763 (lynx_create_inferior): Turn into ...
1764 (lynx_process_target::create_inferior): ... this.
1765 * lynx-low.h (class lynx_process_target): Update.
1766 * nto-low.cc (nto_target_ops): Update.
1767 (nto_create_inferior): Turn into ...
1768 (nto_process_target::create_inferior): ... this.
1769 * nto-low.h (class nto_process_target): Update.
1770 * win32-low.cc (win32_target_ops): Update.
1771 (win32_create_inferior): Turn into ...
1772 (win32_process_target::create_inferior): ... this.
1773 * win32-low.h (class win32_process_target): Update.
1775 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1777 * target.h (class process_target): New class definition.
1778 (struct process_stratum_target) <pt>: New field with type
1780 * linux-low.h (class linux_process_target): Define as a derived
1781 class of 'process_target'.
1782 * linux-low.cc (linux_target_ops): Add a linux_process_target*
1784 * lynx-low.h (class lynx_process_target): Define as a derived
1785 class of 'process_target'.
1786 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
1788 * nto-low.h (class nto_process_target): Define as a derived
1789 class of 'process_target'.
1790 * nto-low.cc (nto_target_ops): Add an nto_process_target*
1792 * win32-low.h (class win32_process_target): Define as a derived
1793 class of 'process_target'.
1794 * win32-low.cc (win32_target_ops): Add a win32_process_target*
1797 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
1799 * configure: Regenerate.
1801 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
1802 Andrew Burgess <andrew.burgess@embecosm.com>
1804 * linux-riscv-low.cc: New file.
1805 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
1806 and nat/riscv-linux-tdesc.c.
1807 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
1808 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
1811 2020-02-14 Tom Tromey <tom@tromey.com>
1813 * acinclude.m4: Don't include acx_configure_dir.m4.
1814 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
1815 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
1816 (all, install-only, uninstall, clean-info, clean)
1817 (maintainer-clean): Don't recurse.
1818 (subdir_do, all-lib): Remove.
1819 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
1821 (generated_files): Update.
1822 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
1823 * configure: Rebuild.
1824 * configure.ac: Don't configure gnulib or libiberty.
1827 2020-02-14 Eli Zaretskii <eliz@gnu.org>
1829 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
1830 preparing the command line for CreateProcess.
1831 (win32_create_inferior): Reflect the program name in debugging
1832 output that shows the process and its command line.
1834 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
1836 * Makefile.in: Rename source files from .c to .cc.
1837 * %.c: Rename to %.cc.
1838 * configure.ac: Rename server.c to server.cc.
1839 * configure: Re-generate.
1841 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
1843 * Makefile.in: Rename gdbsupport source files from .c to .cc.
1845 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
1847 * win32-low.c (win32_create_inferior): Set signal_pid.
1849 2020-02-12 Maciej W. Rozycki <macro@wdc.com>
1850 Pedro Alves <palves@redhat.com>
1852 Skip building gdbserver in a cross-configuration.
1853 * configure.srv: Set $gdbserver_host depending on whether $target
1854 is $host. Use $gdbserver_host instead of $host.
1856 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
1858 * configure: Re-generate.
1860 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
1862 * configure: Re-generate.
1864 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
1866 * acinclude.m4: Update warning.m4 path.
1868 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
1870 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
1871 (handle_exception): Set siginfo_er.
1872 (win32_xfer_siginfo): New function.
1874 2020-02-07 Tom Tromey <tom@tromey.com>
1875 Pedro Alves <palves@redhat.com>
1877 * README: Update build documentation.
1878 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
1880 * configure.ac: Update paths.
1881 * configure: Rebuild.
1882 * acinclude.m4: Update paths.
1883 * Makefile.in: Update include paths.
1884 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
1885 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
1886 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
1887 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
1888 (%-generated.c): Update paths.
1889 * Move entire directory from ../gdb/gdbserver.
1891 2020-01-29 Maciej W. Rozycki <macro@wdc.com>
1893 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
1895 2020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1897 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
1898 assignment instead of srv_linux_obj.
1900 2020-01-28 Hannes Domani <ssbssa@yahoo.de>
1902 * server.c (handle_qxfer_libraries): Write segment-address with
1905 2020-01-24 Hannes Domani <ssbssa@yahoo.de>
1907 * Makefile.in (install-strip): New target.
1908 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
1909 * aclocal.m4: Regenerate.
1910 * configure: Regenerate.
1911 * configure.ac: Add AM_PROG_INSTALL_STRIP.
1913 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
1915 * Makefile.in (SFILES): Adjust paths to point to real files.
1916 (OBS): Move waitstatus.o to target/waitstatus.o.
1917 (TAGS): Transform paths appropriately.
1919 (nat/%.o): ... this pattern rule.
1921 (target/%.o): ... this pattern rule.
1922 * configure.srv: Adjust paths throughout to include nat/ prefix
1923 with the revant files.
1924 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
1925 * configure: Regenerate.
1927 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
1929 * Makefile.in (TAGS): Remove config files from the recipe.
1931 2020-01-14 Tom Tromey <tom@tromey.com>
1933 * configure: Rebuild.
1934 * configure.ac: Remove any checks that were added to common.m4.
1935 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
1938 2020-01-14 Tom Tromey <tom@tromey.com>
1940 * server.h: Include config.h.
1941 * gdbreplay.c: Include config.h.
1942 * configure: Rebuild.
1943 * configure.ac: Don't source common.host.
1944 * acinclude.m4: Update path.
1945 * Makefile.in (INCSUPPORT): New variable.
1946 (INCLUDE_CFLAGS): Add INCSUPPORT.
1947 (SFILES): Update paths.
1948 (version-generated.c): Update path to create-version.sh.
1949 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
1951 2020-01-14 Tom Tromey <tom@tromey.com>
1953 * configure.ac (LIBS): Use WIN32APILIBS.
1954 (USE_WIN32API): Don't define.
1955 * configure: Rebuild.
1957 2020-01-14 Tom Tromey <tom@tromey.com>
1959 * configure: Rebuild.
1961 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1963 * Makefile.in (%-generated.c): Remove rule for files from
1966 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1968 * configure: Re-generate.
1970 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1972 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
1974 * tracepoint.c (stop_tracing, flush_trace_buffer,
1975 about_to_request_buffer_space, get_trace_state_variable_value,
1976 set_trace_state_variable_value, gdb_collect): Add declaration.
1978 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1980 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
1981 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
1982 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
1983 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
1984 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
1987 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1989 * inferiors.c: Include gdbsupport/common-inferior.h.
1991 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1993 * hostio-errno.c: Include hostio.h.
1995 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1997 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
2000 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
2002 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
2003 * linux-arm-tdesc.h: Include arch/arm.h.
2005 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
2007 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
2009 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
2011 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
2012 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
2014 2020-01-10 Pedro Alves <palves@redhat.com>
2016 * fork-child.c (post_fork_inferior): Pass target down to
2018 * inferiors.c (switch_to_thread): Add process_stratum_target
2020 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
2021 * nto-low.c (nto_target_ops): Now a process_stratum_target.
2022 * linux-low.c (linux_target_ops): Now a process_stratum_target.
2023 * remote-utils.c (prepare_resume_reply): Pass the target to
2025 * target.c (the_target): Now a process_stratum_target.
2026 (done_accessing_memory): Pass the target to switch_to_thread.
2027 (set_target_ops): Ajust to use process_stratum_target.
2028 * target.h (struct target_ops): Rename to ...
2029 (struct process_stratum_target): ... this.
2030 (the_target, set_target_ops): Adjust.
2031 (prepare_to_access_memory): Adjust comment.
2032 * win32-low.c (child_xfer_memory): Adjust to use
2033 process_stratum_target.
2034 (win32_target_ops): Now a process_stratum_target.
2036 2020-01-06 Eli Zaretskii <eliz@gnu.org>
2037 Pedro Alves <palves@redhat.com>
2039 * win32-low.c (get_child_debug_event): Extract the fatal exception
2040 from the exit status and convert to the equivalent Posix signal
2042 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
2043 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
2045 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
2047 * Makefile.in: Use INSTALL_PROGRAM_ENV.
2049 2020-01-01 Joel Brobecker <brobecker@adacore.com>
2051 * server.c (gdbserver_version): Change copyright year to 2020.
2052 * gdbreplay.c (gdbreplay_version): Likewise.
2054 2019-12-19 Christian Biesinger <cbiesinger@google.com>
2056 * configure: Regenerate.
2057 * configure.ac: Quote variable arguments of test.
2059 2019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
2061 * Makefile.in: Fix build with GNU Make 3.81
2063 2019-12-16 Tom Tromey <tromey@adacore.com>
2065 * server.c (get_exec_file): Constify result.
2067 2019-12-10 Christian Biesinger <cbiesinger@google.com>
2069 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
2070 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
2071 * config.in: Regenerate.
2072 * configure: Regenerate.
2073 * configure.ac: Don't check for strerror.
2074 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
2075 Call safe_strerror instead of strerror.
2076 * server.h (strerror): Remove this now-unnecessary declaration.
2077 * tracepoint.c (init_named_socket): Call safe_strerror instead of
2079 (gdb_agent_helper_thread): Likewise.
2080 * utils.c (perror_with_name): Likewise.
2082 2019-11-26 Tom Tromey <tom@tromey.com>
2084 * configure, config.in: Rebuild.
2086 2019-11-26 Tom Tromey <tom@tromey.com>
2088 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
2089 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
2091 * configure, config.in: Rebuild.
2093 2019-11-26 Tom Tromey <tom@tromey.com>
2095 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
2096 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
2097 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
2098 * acinclude.m4: Include ax_pthread.m4.
2099 * config.in, configure: Rebuild.
2101 2019-11-26 Christian Biesinger <cbiesinger@google.com>
2103 * debug.c (debug_set_output): Call safe_strerror instead of
2105 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
2106 (linux_kill_one_lwp): Likewise.
2107 (linux_detach_one_lwp): Likewise.
2108 (linux_wait_for_event_filtered): Likewise.
2109 (store_register): Likewise.
2110 * lynx-low.c (lynx_attach): Likewise.
2111 * mem-break.c (insert_memory_breakpoint): Likewise.
2112 (remove_memory_breakpoint): Likewise.
2113 (delete_fast_tracepoint_jump): Likewise.
2114 (set_fast_tracepoint_jump): Likewise.
2115 (uninsert_fast_tracepoint_jumps_at): Likewise.
2116 (reinsert_fast_tracepoint_jumps_at): Likewise.
2117 * nto-low.c (nto_xfer_memory): Likewise.
2118 (nto_resume): Likewise.
2120 2019-11-20 Luis Machado <luis.machado@linaro.org>
2122 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
2123 instead of register count.
2124 * tdesc.c (tdesc_contains_feature): New function.
2125 * tdesc.h (tdesc_contains_feature): New prototype.
2127 2019-11-15 Christian Biesinger <cbiesinger@google.com>
2129 * Makefile.in: Add safe-strerror.c.
2130 * configure: Regenerate.
2131 * configure.ac: Don't source common.host.
2133 2019-11-15 Christian Biesinger <cbiesinger@google.com>
2135 * config.in: Regenerate.
2136 * configure: Regenerate.
2138 2019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
2140 * ax.c (ax_printf): Handle size_t_arg.
2142 2019-11-06 Christian Biesinger <cbiesinger@google.com>
2144 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
2145 * mi/mi-main.c (output_cores): Likewise.
2146 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
2147 (linux_xfer_osdata_modules): Likewise.
2148 * remote.c (register_remote_support_xml): Likewise.
2149 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
2150 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
2152 2019-11-01 Christian Biesinger <cbiesinger@google.com>
2154 * configure: Regenerate.
2155 * configure.ac: Remove check for strerror_r.
2157 2019-10-31 Christian Biesinger <cbiesinger@google.com>
2159 * config.in: Regenerate.
2160 * configure: Regenerate.
2161 * configure.ac: Also check for strerror_r.
2163 2019-10-31 Christian Biesinger <cbiesinger@google.com>
2165 * ax.h (debug_agent): Remove duplicate declaration.
2167 2019-10-26 Tom de Vries <tdevries@suse.de>
2169 * linux-aarch64-low.c: Fix typos in comments.
2170 * linux-arm-low.c: Same.
2171 * linux-low.c: Same.
2172 * linux-ppc-low.c: Same.
2173 * proc-service.c: Same.
2176 * tracepoint.c: Same.
2177 * win32-low.c: Same.
2179 2019-10-25 Tom Tromey <tromey@adacore.com>
2181 * utils.c (xstrdup): Remove.
2183 2019-10-23 Tom Tromey <tom@tromey.com>
2185 * configure, config.in: Rebuild.
2187 2019-10-23 Tom Tromey <tom@tromey.com>
2189 * configure: Rebuild.
2190 * acinclude.m4: Use m4_include, not sinclude.
2192 2019-10-17 Tom Tromey <tromey@adacore.com>
2194 * configure: Rebuild.
2195 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
2196 in AC_CONFIG_FILES invocation.
2197 * Makefile.in (stamp-h, Makefile): Use new-style config.status
2200 2019-10-16 Christian Biesinger <cbiesinger@google.com>
2202 * server.c: Include xml-builtin.h.
2203 (get_xml_features): Don't declare xml_builtins here.
2205 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
2207 * Makefile.in: Remove references to vec-ipa.o.
2209 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
2211 * Makefile.in: Remove references to vec.c.
2213 2019-10-02 Christian Biesinger <cbiesinger@google.com>
2215 * server.c (server_waiting): Change to bool.
2216 (extended_protocol): Likewise.
2217 (response_needed): Likewise.
2218 (exit_requested): Likewise.
2219 (run_once): Likewise.
2220 (report_no_resumed): Likewise.
2221 (non_stop): Likewise.
2222 (disable_packet_vCont): Likewise.
2223 (disable_packet_Tthread): Likewise.
2224 (disable_packet_qC): Likewise.
2225 (disable_packet_qfThreadInfo): Likewise.
2226 (handle_general_set): Update.
2227 (handle_detach): Update.
2228 (handle_monitor_command): Update.
2229 (handle_query): Update.
2230 (captured_main): Update.
2231 (process_serial_event): Update.
2232 * server.h (server_waiting): Change to bool.
2233 (disable_packet_vCont): Likewise.
2234 (disable_packet_Tthread): Likewise.
2235 (disable_packet_qC): Likewise.
2236 (disable_packet_qfThreadInfo): Likewise.
2237 (run_once): Likewise.
2238 (non_stop): Likewise.
2239 * target.c (target_stop_and_wait): Update.
2241 2019-10-02 Tom Tromey <tromey@adacore.com>
2243 * Makefile.in (SFILES): Add common-inferior.c.
2244 (OBS): Add common-inferior.o.
2245 * server.c (startup_with_shell): Don't define.
2247 2019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
2249 * linux-low.c (linux_low_read_btrace): Update for change to
2252 2019-09-20 Christian Biesinger <cbiesinger@google.com>
2254 * debug.c (debug_threads): Remove comment in favor of the header.
2255 * debug.h (using_threads): Add declaration.
2256 (debug_threads): Add comment.
2257 * linux-aarch64-low.c: Include debug.h and remove declaration of
2259 * nto-low.c: Likewise.
2260 * remote-utils.c: Likewise.
2261 * thread-db.c: Likewise.
2263 2019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
2265 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
2266 and powerpc-cell64l-ipa.o.
2267 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
2268 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
2269 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
2272 * spu-low.c: Remove file.
2274 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
2275 (parse_spufs_run): Remove.
2276 (ppc_get_pc): Remove Cell/B.E. support.
2277 (ppc_set_pc): Likewise.
2278 (ppc_breakpoint_at): Likewise.
2279 (ppc_arch_setup): Likewise.
2280 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
2281 tdesc_powerpc_cell32l.
2282 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
2283 or init_registers_powerpc_cell32l.
2284 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
2285 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
2286 or init_registers_powerpc_cell32l.
2287 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
2288 (init_registers_powerpc_cell32l): Remove prototype.
2289 (init_registers_powerpc_cell64l): Likewise.
2291 * target.h (struct target_ops): Remove qxfer_spu member.
2292 * server.c (handle_qxfer_spu): Remove.
2293 (qxfer_packets): Remove entry for "spu".
2294 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
2295 * linux-low.c (SPUFS_MAGIC): Remove.
2296 (spu_enumerate_spu_ids): Remove.
2297 (linux_qxfer_spu): Remove.
2298 (linux_target_ops): Remove qxfer_spu member.
2299 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
2300 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
2301 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
2303 2019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
2305 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
2306 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
2307 * config.in: Regenerate.
2308 * configure: Regenerate.
2310 2019-08-15 Tom Tromey <tromey@adacore.com>
2312 * target.c (target_write_memory): Use gdb::byte_vector.
2314 2019-08-15 Tom Tromey <tromey@adacore.com>
2316 * tracepoint.c (write_inferior_data_pointer)
2317 (write_inferior_integer, write_inferior_int8)
2318 (write_inferior_uinteger, m_tracepoint_action_download)
2319 (r_tracepoint_action_download, x_tracepoint_action_download)
2320 (l_tracepoint_action_download, clear_inferior_trace_buffer)
2321 (download_agent_expr, download_tracepoint_1)
2322 (download_trace_state_variables, upload_fast_traceframes): Update.
2323 * server.c (gdb_write_memory): Update.
2324 * remote-utils.c (relocate_instruction): Update.
2325 * proc-service.c (ps_pdwrite): Update.
2326 * mem-break.c (remove_memory_breakpoint)
2327 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
2328 (uninsert_fast_tracepoint_jumps_at)
2329 (reinsert_fast_tracepoint_jumps_at): Update.
2330 * linux-x86-low.c (append_insns)
2331 (i386_install_fast_tracepoint_jump_pad)
2332 (amd64_write_goto_address, i386_write_goto_address): Update.
2333 * linux-s390-low.c (append_insns, s390_write_goto_address):
2335 * linux-ppc-low.c (ppc_relocate_instruction)
2336 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
2337 (ppc_write_goto_address): Update.
2338 * linux-aarch64-low.c (append_insns): Update.
2339 * target.h (struct target_ops): Update.
2340 (write_inferior_memory): Don't declare.
2341 * target.c (target_write_memory): Rename from
2342 write_inferior_memory. Remove old target_write_memory.
2344 2019-08-15 Tom Tromey <tromey@adacore.com>
2346 * target.c (write_inferior_memory): Use std::vector.
2348 2019-08-06 Frank Ch. Eigler <fche@redhat.com>
2351 * configure.ac: Drop enable-libmcheck support.
2352 * configure, config.in: Rebuild.
2353 * acinclude.m4: Don't include it.
2355 2019-07-19 Alan Hayward <alan.hayward@arm.com>
2357 * configure.srv: Remove Arm xml files.
2359 2019-07-19 Alan Hayward <alan.hayward@arm.com>
2361 * configure.srv: Add new files. Remove xml generated files.
2362 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
2364 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
2365 * linux-aarch32-tdesc.c: New file.
2366 * linux-aarch32-tdesc.h: New file.
2367 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
2368 * linux-arm-low.c (init_registers_arm, tdesc_arm)
2369 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
2370 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
2371 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
2372 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
2373 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
2374 (arm_read_description): Call arm_linux_read_description.
2375 (initialize_low_arch): Don't init registers.
2376 * linux-arm-tdesc.c: New file.
2377 * linux-arm-tdesc.h: New file.
2379 2019-07-10 Alan Hayward <alan.hayward@arm.com>
2381 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
2382 Move counter inside for.
2383 (arm_read_description): Check ptrace earlier.
2384 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
2386 2019-07-09 Tom Tromey <tom@tromey.com>
2388 * configure: Rebuild.
2389 * configure.ac: Change common to gdbsupport.
2390 * acinclude.m4: Change common to gdbsupport.
2391 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
2392 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
2393 common to gdbsupport.
2394 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
2395 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
2396 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
2397 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
2398 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
2399 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
2400 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
2401 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
2402 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
2403 common to gdbsupport.
2405 2019-07-04 Alan Hayward <alan.hayward@arm.com>
2407 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
2409 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
2411 2019-07-04 Alan Hayward <alan.hayward@arm.com>
2413 * configure.srv: Remove legacy xml.
2414 * linux-aarch64-low.c (initialize_low_arch): Remove
2415 initialize_low_tdesc call.
2416 * linux-aarch64-tdesc-selftest.c: Remove file.
2417 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
2418 * linux-x86-low.c (initialize_low_arch): Remove
2419 initialize_low_tdesc call.
2420 * linux-x86-tdesc-selftest.c: Remove file.
2421 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
2423 2019-06-20 Tom de Vries <tdevries@suse.de>
2425 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
2426 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
2428 2019-06-19 Tom de Vries <tdevries@suse.de>
2430 * debug.h (debug_write): Change return type to ssize_t.
2431 * debug.c (debug_write): Same.
2433 2019-06-14 Tom Tromey <tom@tromey.com>
2435 * configure.ac: Use new path to gnulib.
2436 * configure: Rebuild.
2437 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
2440 2019-06-11 Tom Tromey <tom@tromey.com>
2442 * Makefile.in (SFILES): Add alloc.c.
2444 (IPA_OBJS): Add alloc-ipa.o.
2445 (alloc-ipa.o): New target.
2446 (%.o: ../%.c): New pattern rule.
2448 2019-06-10 Tom Tromey <tromey@adacore.com>
2450 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
2451 end warning with a newline.
2452 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
2454 * thread-db.c (attach_thread): Don't end warning with a newline.
2455 (thread_db_notice_clone): Likewise.
2456 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
2458 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
2459 end warning with a newline.
2461 2019-06-04 Pedro Alves <palves@redhat.com>
2463 * server.c (captured_main): Use make_unique_xstrdup.
2465 2019-06-02 Tom Tromey <tom@tromey.com>
2467 * gdbreplay.c (fromhex): Remove.
2468 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
2470 2019-05-29 Tom Tromey <tromey@adacore.com>
2472 * configure: Rebuild.
2474 2019-05-06 Kevin Buettner <kevinb@redhat.com>
2476 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
2477 sign extension code on 32-bit builds.
2479 2019-05-03 Eli Zaretskii <eliz@gnu.org>
2482 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
2484 2019-04-19 Tom Tromey <tom@tromey.com>
2486 * server.c (struct vstop_notif): Derive from notif_event.
2488 (queue_stop_reply): Update.
2489 (remove_all_on_match_ptid): Change type. Rewrite.
2490 (discard_queued_stop_replies): Rewrite.
2491 (in_queued_stop_replies_ptid): Change type.
2492 (in_queued_stop_replies): Rewrite.
2493 (notif_stop): Update.
2494 (queue_stop_reply_callback): Update.
2495 (captured_main): Don't call initialize_notif.
2496 (push_stop_notification): Update.
2497 * notif.c (notif_write_event, handle_notif_ack)
2498 (notif_event_enque, notif_push): Update.
2499 (notif_event_xfree, initialize_notif): Remove.
2500 * notif.h (struct notif_event): Include <list>, not
2502 (struct notif_server) <queue>: Now a std::list.
2503 (notif_event_p): Remove typedef.
2504 (initialize_notif): Don't declare.
2505 (struct notif_event): Add virtual destructor.
2507 2019-04-17 Alan Hayward <alan.hayward@arm.com>
2509 * ax.c (ax_vdebug): Call debug_printf.
2510 * debug.c (debug_write): New function.
2511 * debug.h (debug_write): New declaration.
2512 * linux-low.c (sigchld_handler): Call debug_write.
2514 2019-04-17 Alan Hayward <alan.hayward@arm.com>
2516 * debug.c (debug_set_output): New function.
2517 (debug_vprintf): Send output to debug_file.
2518 (debug_flush): Likewise.
2519 * debug.h (debug_set_output): New declaration.
2520 * server.c (handle_monitor_command): Add debug-file option.
2521 (captured_main): Likewise.
2523 2019-04-17 Alan Hayward <alan.hayward@arm.com>
2525 * debug.c (remote_debug): Add definition.
2526 * debug.h (remote_debug): Add declaration.
2527 * hostio.c (remote_debug): Remove declaration.
2528 * remote-utils.c (struct ui_file): Likewise.
2529 (remote_debug): Likewise.
2530 * remote-utils.h (remote_debug): Likewise,
2531 * server.c (remote_debug): Remove definition.
2533 2019-04-10 Kevin Buettner <kevinb@redhat.com>
2535 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
2536 when using a 64-bit gdbserver.
2538 2019-04-09 Tom Tromey <tromey@adacore.com>
2540 * linux-low.c (select_event_lwp): Use find_thread_in_random.
2542 2019-04-08 Tom Tromey <tom@tromey.com>
2544 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
2546 (linux_resume_one_lwp): Likewise.
2548 2019-04-08 Tom Tromey <tom@tromey.com>
2550 * gdbreplay.c: Update.
2551 * linux-low.c: Update.
2554 2019-04-08 Tom Tromey <tom@tromey.com>
2556 * server.c: Use C++ exception handling.
2557 * linux-low.c: Use C++ exception handling.
2558 * gdbreplay.c: Use C++ exception handling.
2560 2019-04-08 Tom Tromey <tom@tromey.com>
2562 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
2563 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
2564 (captured_main, main): Update.
2565 * gdbreplay.c (main): Update.
2567 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2569 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
2570 value in argument pointer, return 1 if the entry is found and 0
2571 otherwise. Move comment.
2572 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
2573 * linux-low.h (linux_get_auxv): Declare.
2574 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
2576 2019-04-05 Tom Tromey <tromey@adacore.com>
2578 * server.c (gdbserver_usage): Use upper-case for metasyntactic
2581 2019-03-28 Alan Hayward <alan.hayward@arm.com>
2583 * linux-low.c (AT_HWCAP2): Add define if not already included.
2585 2019-03-26 Alan Hayward <alan.hayward@arm.com>
2587 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
2588 (aarch64_arch_setup): Call linux_get_hwcap.
2589 * linux-arm-low.c (arm_get_hwcap): Remove function.
2590 (arm_read_description): Call linux_get_hwcap.
2591 * linux-low.c (linux_get_auxv): New function.
2592 (linux_get_hwcap): Likewise.
2593 (linux_get_hwcap2): Likewise.
2594 * linux-low.h (linux_get_hwcap): New declaration.
2595 (linux_get_hwcap2): Likewise.
2596 * linux-ppc-low.c (ppc_get_auxv): Remove function.
2597 (ppc_arch_setup): Call linux_get_hwcap.
2598 * linux-s390-low.c (s390_get_hwcap): Remove function.
2599 (s390_arch_setup): Call linux_get_hwcap.
2601 2019-03-22 Alan Hayward <alan.hayward@arm.com>
2602 Jiong Wang <jiong.wang@arm.com>
2604 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
2605 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
2607 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
2609 2019-03-22 Alan Hayward <alan.hayward@arm.com>
2610 Jiong Wang <jiong.wang@arm.com>
2612 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
2613 (aarch64_get_hwcap): New function.
2614 (aarch64_arch_setup): Read APIA hwcap.
2616 2019-03-22 Alan Hayward <alan.hayward@arm.com>
2617 Jiong Wang <jiong.wang@arm.com>
2619 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
2620 (initialize_low_tracepoint): Likewise.
2621 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
2622 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
2623 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
2624 (aarch64_linux_read_description): Likewise.
2625 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
2627 2019-03-12 John Baldwin <jhb@FreeBSD.org>
2629 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
2630 i386_create_target_description for 'segments' parameter.
2631 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
2632 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
2633 * win32-i386-low.c (i386_arch_setup): Likewise.
2635 2019-03-12 Tom Tromey <tromey@adacore.com>
2637 * linux-low.c (iterate_over_lwps): Update.
2639 2019-03-06 Tom Tromey <tom@tromey.com>
2641 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
2642 (captured_main): Use SCOPE_EXIT.
2644 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
2646 * configure.srv: Use '$enable_unittest' instead of '$development'
2647 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
2650 2019-02-27 Tom Tromey <tromey@adacore.com>
2652 * gdbreplay.c (logchar): Handle \r\n.
2654 2019-02-07 Alan Hayward <alan.hayward@arm.com>
2656 * linux-low.c (linux_attach): Add process before lwp.
2657 * server.c (attach_inferior): Check if already attached.
2659 2019-02-07 Tom Tromey <tom@tromey.com>
2661 * x86-tdesc.h: Rename include guard.
2662 * x86-low.h: Add include guard.
2663 * wincecompat.h: Rename include guard.
2664 * win32-low.h: Add include guard.
2665 * utils.h: Rename include guard.
2666 * tracepoint.h: Rename include guard.
2667 * tdesc.h: Rename include guard.
2668 * target.h: Rename include guard.
2669 * server.h: Rename include guard.
2670 * remote-utils.h: Rename include guard.
2671 * regcache.h: Rename include guard.
2672 * nto-low.h: Rename include guard.
2673 * notif.h: Add include guard.
2674 * mem-break.h: Rename include guard.
2675 * lynx-low.h: Add include guard.
2676 * linux-x86-tdesc.h: Add include guard.
2677 * linux-s390-tdesc.h: Add include guard.
2678 * linux-ppc-tdesc-init.h: Add include guard.
2679 * linux-low.h: Add include guard.
2680 * linux-aarch64-tdesc.h: Add include guard.
2681 * linux-aarch32-low.h: Add include guard.
2682 * inferiors.h: Rename include guard.
2683 * i387-fp.h: Rename include guard.
2684 * hostio.h: Rename include guard.
2685 * gdbthread.h: Rename include guard.
2686 * gdb_proc_service.h: Rename include guard.
2687 * event-loop.h: Rename include guard.
2688 * dll.h: Rename include guard.
2689 * debug.h: Rename include guard.
2690 * ax.h: Rename include guard.
2692 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
2695 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
2696 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
2698 2019-01-25 Tom Tromey <tom@tromey.com>
2700 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
2702 2019-01-25 Tom Tromey <tom@tromey.com>
2704 * win32-low.c: Fix common/ includes.
2705 * win32-i386-low.c: Fix common/ includes.
2706 * tracepoint.c: Fix common/ includes.
2707 * thread-db.c: Fix common/ includes.
2708 * target.h: Fix common/ includes.
2709 * symbol.c: Fix common/ includes.
2710 * spu-low.c: Fix common/ includes.
2711 * server.h: Fix common/ includes.
2712 * server.c: Fix common/ includes.
2713 * remote-utils.c: Fix common/ includes.
2714 * regcache.h: Fix common/ includes.
2715 * regcache.c: Fix common/ includes.
2716 * nto-x86-low.c: Fix common/ includes.
2717 * notif.h: Fix common/ includes.
2718 * mem-break.h: Fix common/ includes.
2719 * lynx-low.c: Fix common/ includes.
2720 * lynx-i386-low.c: Fix common/ includes.
2721 * linux-x86-tdesc-selftest.c: Fix common/ includes.
2722 * linux-x86-low.c: Fix common/ includes.
2723 * linux-low.c: Fix common/ includes.
2724 * inferiors.h: Fix common/ includes.
2725 * i387-fp.c: Fix common/ includes.
2726 * hostio.c: Fix common/ includes.
2727 * hostio-errno.c: Fix common/ includes.
2728 * gdbthread.h: Fix common/ includes.
2729 * gdbreplay.c: Fix common/ includes.
2730 * fork-child.c: Fix common/ includes.
2731 * event-loop.c: Fix common/ includes.
2733 (enum gdb_agent_op): Fix common/ includes.
2735 2019-01-21 Tom Tromey <tom@tromey.com>
2737 * tracepoint.c: Fix includes.
2738 * remote-utils.c: Fix includes.
2739 * linux-x86-low.c: Fix includes.
2741 2019-01-01 Joel Brobecker <brobecker@adacore.com>
2743 * gdbreplay.c (gdbreplay_version): Update copyright year in
2745 * server.c (gdbserver_version): Likewise.
2747 2018-12-05 Alan Hayward <alan.hayward@arm.com>
2749 * linux-low.c (add_lwp): Switch ordering.
2751 2018-11-29 Tom Tromey <tom@tromey.com>
2753 * win32-low.c (win32_join): Take pid, not process.
2754 * target.h (struct target_ops) <join>: Change argument type.
2755 (join_inferior): Change argument name.
2756 * spu-low.c (spu_join): Take pid, not process.
2757 * server.c (handle_detach): Preserve pid before destroying
2759 * lynx-low.c (lynx_join): Take pid, not process.
2760 * linux-low.c (linux_join): Take pid, not process.
2762 2018-11-23 Alan Hayward <alan.hayward@arm.com>
2764 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
2765 (aarch64_cannot_fetch_register): Likewise.
2766 (struct linux_target_ops): Update references.
2768 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2770 * linux-ppc-low.c: Include nat/linux-ptrace.h.
2772 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2774 * configure.srv (ipa_ppc_linux_regobj): Add
2775 powerpc-isa207-htm-vsx32l-ipa.o and
2776 powerpc-isa207-htm-vsx64l-ipa.o.
2777 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
2778 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
2779 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
2780 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
2781 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
2782 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
2783 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
2784 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
2785 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
2786 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
2787 (init_registers_powerpc_isa207_htm_vsx32l)
2788 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
2789 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
2790 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
2791 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
2792 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
2793 (ppc_store_tm_ctarregset): New functions.
2794 (ppc_regsets): Add entries for HTM regsets.
2795 (ppc_arch_setup): Set htm in features struct when needed. Set
2796 sizes for the HTM regsets.
2797 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
2798 (initialize_low_arch): Call
2799 init_registers_powerpc_isa207_htm_vsx32l and
2800 init_registers_powerpc_isa207_htm_vsx64l.
2801 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
2802 PPC_TDESC_ISA207_HTM_VSX.
2803 (initialize_low_tracepoint): Call
2804 init_registers_powerpc_isa207_htm_vsx32l and
2805 init_registers_powerpc_isa207_htm_vsx64l.
2807 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2809 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
2810 rs6000/power-linux-pmu.xml to srv_xmlfiles.
2811 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
2812 (ppc_store_pmuregset): New functions.
2813 (ppc_regsets): Add entries for ebb and pmu regsets.
2814 (ppc_arch_setup): Set isa207 in features struct if the ebb and
2815 pmu regsets are available. Set sizes for these regsets.
2817 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2819 * configure.srv (ipa_ppc_linux_regobj): Add
2820 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
2821 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
2822 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
2823 rs6000/powerpc-isa207-vsx32l.xml, and
2824 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
2825 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
2826 <PPC_TDESC_ISA207_VSX>: New enum value.
2827 (init_registers_powerpc_isa207_vsx32l): Declare.
2828 (init_registers_powerpc_isa207_vsx64l): Declare.
2829 * linux-ppc-low.c (ppc_fill_tarregset): New function.
2830 (ppc_store_tarregset): New function.
2831 (ppc_regsets): Add entry for the TAR regset.
2832 (ppc_arch_setup): Set isa207 in features struct when needed. Set
2833 size for the TAR regsets.
2834 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
2835 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
2836 and init_registers_powerpc_isa207_vsx64l.
2837 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
2838 (initialize_low_tracepoint): Call
2839 init_registers_powerpc_isa207_vsx32l and
2840 init_registers_powerpc_isa207_vsx64l.
2842 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
2843 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2845 * configure.srv (ipa_ppc_linux_regobj): Add
2846 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
2847 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
2848 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
2849 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
2850 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
2851 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
2852 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
2853 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
2854 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
2855 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
2856 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
2857 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
2858 (ppc_hwcap): Add comment.
2859 (ppc_hwcap2): New global.
2860 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
2861 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
2862 (ppc_regsets): Add entries for the DSCR and PPR regsets.
2863 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
2864 when needed. Set sizes for the the DSCR and PPR regsets.
2865 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
2866 (initialize_low_arch): Call
2867 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
2868 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
2869 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
2870 PPC_TDESC_ISA205_PPR_DSCR_VSX.
2871 (initialize_low_tracepoint): Call
2872 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
2873 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
2875 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2877 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
2879 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
2880 Simon Marchi <simark@simark.ca>
2882 * acinclude.m4: Include "../selftest.m4".
2883 * configure: Regenerate.
2884 * configure.ac: Use "GDB_AC_SELFTEST".
2885 * configure.srv: Use "$enable_unittests" instead of
2886 "$development" when checking whether unit tests have been
2888 * server.c (captured_main): Update message informing that
2889 selftests have been disabled.
2891 2018-10-04 Tom Tromey <tom@tromey.com>
2893 * configure: Rebuild.
2895 2018-10-04 Tom Tromey <tom@tromey.com>
2897 * server.c (handle_status): Rename inner "thread".
2898 (process_serial_event): Declare "res" in 'm' case.
2899 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
2900 (iterate_over_lwps): Rename inner "thread".
2901 (linux_qxfer_libraries_svr4): Rename inner "len".
2902 * gdbthread.h (find_thread_in_random): Rename inner "thread".
2904 2018-10-01 Gary Benson <gbenson@redhat.com>
2906 * gdb_proc_service.h: Moved common code to
2907 common/gdb_proc_service.h.
2909 2018-10-01 Gary Benson <gbenson@redhat.com>
2911 * gdb_proc_service.h: Synchronize comments and whitespace with
2912 GDB's version of this file.
2914 2018-09-25 Tom Tromey <tom@tromey.com>
2916 * configure: Rebuild.
2917 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
2919 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
2921 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
2922 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
2923 ($(IPA_LIB)): Sort IPA_OBJS.
2925 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
2927 * Makefile.in: Remove references to $(ADD_DEPS).
2929 2018-09-16 Tom Tromey <tom@tromey.com>
2931 * remote-utils.c (remote_open): Use GNU style for metasyntactic
2933 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
2936 2018-09-05 Tom Tromey <tom@tromey.com>
2938 * configure: Rebuild.
2940 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
2943 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
2945 2018-08-27 Tom Tromey <tom@tromey.com>
2948 * configure: Rebuild.
2950 2018-08-27 Tom Tromey <tom@tromey.com>
2952 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
2953 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
2954 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
2955 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
2956 (s390x_emit_stack_adjust): Add casts to unsigned char.
2958 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
2962 * server.h (struct client_state) <disable_randomization>:
2965 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2967 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
2969 (mips_supply_ptrace_register): Likewise.
2971 2018-07-22 Tom Tromey <tom@tromey.com>
2973 * configure: Rebuild.
2975 2018-07-22 Tom Tromey <tom@tromey.com>
2977 * win32-low.c (win32_create_inferior): Remove unused variables.
2978 * gdbreplay.c (remote_open): Remove unused variable.
2979 * remote-utils.c (remote_prepare): Remove unused variable.
2980 * x86-tdesc.h (X86_TDESC_H): Define.
2981 (amd64_expedite_regs): Define conditionally.
2982 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
2983 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
2984 * remote-utils.c (readchar): Remove unused variable.
2986 2018-07-13 Pedro Alves <palves@redhat.com>
2988 * linux-low.c (linux_kill): Change parameter to process_info
2989 pointer instead of pid. Adjust.
2990 * lynx-low.c (lynx_kill): Likewise.
2991 * nto-low.c (nto_kill): Likewise.
2992 * spu-low.c (spu_kill): Likewise.
2993 * win32-low.c (win32_kill): Likewise.
2994 * server.c (handle_v_kill, kill_inferior_callback)
2995 (detach_or_kill_for_exit): Adjust.
2996 * target.c (kill_inferior): Change parameter to process_info
2997 pointer instead of pid. Adjust.
2998 * target.h (struct target_ops) <kill>: Change parameter to
2999 process_info pointer instead of pid. Adjust all implementations
3001 (kill_inferior): Likewise.
3003 2018-07-13 Pedro Alves <palves@redhat.com>
3005 * linux-low.c (linux_detach, linux_join): Change parameter to
3006 process_info pointer instead of pid. Adjust.
3007 * lynx-low.c (lynx_detach, lynx_join): Likewise.
3008 * nto-low.c (nto_detach): Likewise.
3009 * spu-low.c (spu_detach, spu_join): Likewise.
3010 * win32-low.c (win32_detach, win32_join): Likewise.
3011 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
3012 * target.h (struct target_ops) <detach, join>: Change parameter to
3013 process_info pointer instead of pid. Adjust all implementations
3015 (detach_inferior, join_inferior): Rename 'pid' parameter to
3018 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
3019 Jan Kratochvil <jan.kratochvil@redhat.com>
3020 Paul Fertser <fercerpav@gmail.com>
3021 Tsutomu Seki <sekiriki@gmail.com>
3023 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
3024 (OBS): Add 'common/netstuff.o'.
3025 (GDBREPLAY_OBS): Likewise.
3026 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
3027 (remote_open): Implement support for IPv6
3029 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
3031 (handle_accept_event): Accept connections from IPv6 sources.
3032 (remote_prepare): Handle IPv6-style hostnames; implement
3033 support for IPv6 connections.
3034 (remote_open): Implement support for printing connections from
3037 2018-07-11 Pedro Alves <palves@redhat.com>
3040 * mem-break.c (any_persistent_commands): Add process_info
3041 parameter and use it instead of relying on the current process.
3042 Change return type to bool.
3043 * mem-break.h (any_persistent_commands): Add process_info
3044 parameter and change return type to bool.
3045 * server.c (handle_detach): Remove require_running_or_return call.
3046 Look up the process_info for the process we're about to detach.
3047 If not found, return back error to GDB. Adjust
3048 any_persistent_commands call to pass down a process pointer.
3050 2018-07-11 Pedro Alves <palves@redhat.com>
3052 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
3053 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
3054 instead of collect_register_by_name.
3055 * regcache.c (regcache_raw_get_unsigned_by_name): New.
3056 * regcache.h (regcache_raw_get_unsigned_by_name): New.
3058 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
3059 Pedro Alves <palves@redhat.com>
3061 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
3063 2018-07-03 Tom Tromey <tom@tromey.com>
3065 * linux-low.c: Update.
3066 * lynx-low.c: Update.
3067 * mem-break.c: Update.
3068 * nto-low.c: Update.
3069 * remote-utils.c: Update.
3071 * spu-low.c: Update.
3073 * win32-low.c: Update.
3075 2018-07-03 Tom Tromey <tom@tromey.com>
3079 2018-07-03 Tom Tromey <tom@tromey.com>
3081 * linux-low.c: Update.
3083 2018-07-03 Tom Tromey <tom@tromey.com>
3087 2018-07-03 Tom Tromey <tom@tromey.com>
3089 * linux-low.c: Update.
3090 * linux-mips-low.c: Update.
3091 * lynx-low.c: Update.
3092 * nto-low.c: Update.
3093 * remote-utils.c: Update.
3095 * spu-low.c: Update.
3097 * thread-db.c: Update.
3099 2018-07-03 Tom Tromey <tom@tromey.com>
3101 * linux-low.c: Update.
3102 * linux-mips-low.c: Update.
3103 * lynx-low.c: Update.
3104 * mem-break.c: Update.
3105 * nto-low.c: Update.
3106 * remote-utils.c: Update.
3108 * spu-low.c: Update.
3110 * tracepoint.c: Update.
3112 2018-07-03 Tom Tromey <tom@tromey.com>
3114 * linux-low.c: Update.
3115 * linux-ppc-low.c: Update.
3116 * linux-x86-low.c: Update.
3117 * proc-service.c: Update.
3119 * spu-low.c: Update.
3120 * thread-db.c: Update.
3121 * win32-low.c: Update.
3123 2018-07-03 Tom Tromey <tom@tromey.com>
3125 * linux-low.c: Update.
3126 * lynx-low.c: Update.
3127 * nto-low.c: Update.
3128 * remote-utils.c: Update.
3129 * spu-low.c: Update.
3130 * thread-db.c: Update.
3131 * win32-low.c: Update.
3133 2018-06-29 Joel Brobecker <brobecker@adacore.com>
3135 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
3136 parameter in call to 'amd64_create_target_description'.
3138 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
3140 * x86-tdesc.h: Remove executable permission flag.
3142 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
3144 * configure.ac: Remove AC_PREREQ, add missing quoting.
3145 * configure: Re-generate.
3146 * config.in: Re-generate.
3147 * aclocal.m4: Re-generate.
3149 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
3151 * tracepoint.h (current_traceframe): Remove declaration.
3153 2018-06-18 Alan Hayward <alan.hayward@arm.com>
3155 * linux-aarch64-low.c (is_sve_tdesc): New function.
3156 (aarch64_sve_regs_copy_to_regcache): Likewise.
3157 (aarch64_sve_regs_copy_from_regcache): Likewise.
3158 (aarch64_regs_info): Add SVE checks.
3159 (initialize_low_arch): Initialize SVE.
3161 2018-06-18 Alan Hayward <alan.hayward@arm.com>
3163 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
3165 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3167 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
3168 (initialize_low_tracepoint): Likewise
3169 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
3170 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
3172 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
3174 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
3176 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3178 * server.h (PBUFSIZ): Increase size
3180 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3182 * regcache.c (regcache::raw_compare): New function.
3183 * regcache.h (regcache::raw_compare): New declaration.
3185 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3187 * regcache.c (new_register_cache): Use new.
3188 (free_register_cache): Use delete.
3189 (register_data): Use const.
3190 (supply_register): Move body inside regcache.
3191 (regcache::raw_supply): New override function.
3192 (collect_register): Move body inside regcache.
3193 (regcache::raw_collect): New override function.
3194 (regcache::get_register_status): New override function.
3195 * regcache.h (struct regcache): Inherit from reg_buffer_common.
3197 2018-06-09 Tom Tromey <tom@tromey.com>
3199 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
3201 (event_queue): Use std::queue.
3202 (gdb_event_xfree): Remove.
3203 (initialize_event_loop, process_event, wait_for_event): Update.
3205 2018-06-08 Stan Cox <scox@redhat.com>
3207 * win32-low.c (win32_create_inferior): last_ptid and last_status
3208 moved to client_state.
3210 2018-06-08 Pedro Alves <palves@redhat.com>
3212 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
3213 common/common-exceptions.o, common/common-utils.o,
3214 common/errors.o, common/print-utils.o and utils.o.
3215 * gdbreplay.c: Include "common-defs.h" instead of the two
3216 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
3217 string.h or alloca.h.
3218 (perror_with_name): Delete.
3219 (remote_open): Use xstrdup instead of strdup.
3220 (main): Rename to ...
3221 (captured_main): ... this.
3224 2018-06-08 Tom Tromey <tom@tromey.com>
3226 * linux-low.c (linux_low_read_btrace): Update.
3228 2018-06-04 Stan Cox <scox@redhat.com>
3230 * server.h (struct client_state): New.
3231 * server.c (cont_thread, general_thread, multi_process)
3232 (report_fork_events, report_vfork_events, report_exec_events)
3233 (report_thread_events, swbreak_feature, hwbreak_feature)
3234 (vCont_supported, disable_randomization, pass_signals)
3235 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
3236 Moved to client_state.
3237 * remote-utils.c (remote_debug, noack_mode)
3238 (transport_is_reliable): Moved to client_state.
3239 * tracepoint.c (current_traceframe): Moved to client_state.
3242 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
3243 linux-low.c, remote-utils.h, target.c: Use client_state.
3245 2018-05-31 Alan Hayward <alan.hayward@arm.com>
3247 * configure.srv: Add new c/h file.
3249 2018-05-31 Alan Hayward <alan.hayward@arm.com>
3251 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
3254 2018-05-25 Maciej W. Rozycki <macro@mips.com>
3256 * gdb.arch/mips-fpregset-core.exp: New test.
3257 * gdb.arch/mips-fpregset-core.c: New test source.
3259 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
3262 * hostio.c (require_int): Do not report overflow for integers
3263 between 0xfffffff and 0x7fffffff.
3265 2018-05-22 Maciej W. Rozycki <macro@mips.com>
3267 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
3268 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
3269 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
3271 (the_low_target): Wire them.
3273 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3275 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
3276 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
3277 mode. Call collect_register_by_name with vscr using
3278 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
3279 (ppc_store_vrregset): Add and set vscr_offset variable as in
3280 ppc_fill_vrregset. Call supply_register_by_name with vscr using
3283 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3285 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
3286 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
3287 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
3289 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3291 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
3292 (ppc_store_vsxregset): Likewise.
3293 (ppc_fill_vrregset): Likewise.
3294 (ppc_store_vrregset): Likewise.
3295 (ppc_fill_evrregset): Likewise.
3296 (ppc_store_evrregset): Likewise.
3297 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
3298 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
3301 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3303 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
3304 wordsize of the inferior. Call ppc_linux_target_wordsize.
3306 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3308 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
3309 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
3310 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
3311 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
3312 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
3313 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
3314 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
3315 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
3316 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
3317 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
3318 (tdesc_powerpc_e500l): Remove.
3319 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
3320 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
3321 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
3322 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
3324 (ppc_arch_setup): Remove target description matching code. Fill a
3325 ppc_linux_features struct and call ppc_linux_match_description
3328 2018-05-22 Maciej W. Rozycki <macro@mips.com>
3330 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
3331 width of the requested register exceeds the width of the
3333 (mips_cannot_store_register): Likewise.
3335 2018-05-21 Maciej W. Rozycki <macro@mips.com>
3337 * linux-mips-low.c (mips_fetch_register): New function. Update
3339 (mips_store_gregset): Supply 0 rather than $restart for $zero.
3340 (the_low_target): Wire `mips_fetch_register'.
3342 2018-05-10 Joel Brobecker <brobecker@adacore.com>
3344 * lynx-i386-low.c (LYNXOS_178): New macro.
3345 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
3346 the layout on LynxOS-178.
3347 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
3348 handle floating point registers that are not supported by
3351 2018-05-10 Tom Tromey <tom@tromey.com>
3353 * configure: Rebuild.
3355 2018-05-10 Joel Brobecker <brobecker@adacore.com>
3358 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
3359 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
3360 Use it to set the expedite_regs field in the given tdesc.
3361 * x86-tdesc.h: New file.
3362 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
3363 Adjust following the addition of the new expedite_regs parameter
3364 to init_target_desc.
3365 * linux-tic6x-low.c (tic6x_read_description): Likewise.
3366 * linux-x86-tdesc.c: #include "x86-tdesc.h".
3367 (i386_linux_read_description, amd64_linux_read_description):
3368 Adjust following the addition of the new expedite_regs parameter
3369 to init_target_desc.
3370 * lynx-i386-low.c: #include "x86-tdesc.h".
3371 (lynx_i386_arch_setup): Adjust following the addition of the new
3372 expedite_regs parameter to init_target_desc.
3373 * nto-x86-low.c: #include "x86-tdesc.h".
3374 (nto_x86_arch_setup): Adjust following the addition of the new
3375 expedite_regs parameter to init_target_desc.
3376 * win32-i386-low.c: #include "x86-tdesc.h".
3377 (i386_arch_setup): Adjust following the addition of the new
3378 expedite_regs parameter to init_target_desc.
3380 2018-05-10 Joel Brobecker <brobecker@adacore.com>
3383 * win32-low.c (win32_create_inferior): Add call to my_wait
3384 setting last_status global.
3386 2018-05-10 Joel Brobecker <brobecker@adacore.com>
3389 * win32-low.c (create_process): Only call gdb_tilde_expand if
3390 inferior_cwd is not NULL.
3392 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
3394 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
3395 registers to the cache if their values have changed.
3396 (i387_xsave_to_cache): Provide default values for x87 control
3397 registers when these features are available, but disabled.
3398 * regcache.c (supply_register_by_name_zeroed): New function.
3399 * regcache.h (supply_register_by_name_zeroed): Declare new
3402 2018-05-07 Tom Tromey <tom@tromey.com>
3404 * configure: Rebuild.
3406 2018-05-04 Tom Tromey <tom@tromey.com>
3408 * configure: Rebuild.
3410 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
3411 Pedro Alves <palves@redhat.com>
3413 * linux-aarch64-low.c (aarch64_stopped_data_address):
3416 2018-04-27 Tom Tromey <tom@tromey.com>
3418 * configure: Rebuild.
3420 2018-04-23 Tom Tromey <tom@tromey.com>
3422 * configure: Rebuild.
3424 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
3426 * Makefile.in (depcomp): Add "..".
3427 (all_deps_files): New and use it.
3429 2018-04-18 Alan Hayward <alan.hayward@arm.com>
3431 * configure.srv (aarch64*-*-linux*): Don't include xml.
3432 (i[34567]86-*-cygwin*): Likewise.
3433 (i[34567]86-*-linux*): Likewise.
3434 (i[34567]86-*-lynxos*): Likewise.
3435 (i[34567]86-*-mingw32ce*): Likewise.
3436 (i[34567]86-*-mingw*): Likewise.
3437 (i[34567]86-*-nto*): Likewise.
3438 (tic6x-*-uclinux): Likewise.
3439 (x86_64-*-linux*): Likewise.
3440 (x86_64-*-mingw*): Likewise.
3441 (x86_64-*-cygwin*): Likewise.
3443 2018-04-18 Alan Hayward <alan.hayward@arm.com>
3445 * tdesc.c: Remove xml parameter.
3447 2018-04-18 Alan Hayward <alan.hayward@arm.com>
3449 * server.c (get_features_xml): Remove cast.
3450 * tdesc.c (void target_desc::accept): Fill in function.
3451 (tdesc_get_features_xml): Remove old xml creation.
3452 (print_xml_feature::visit_pre): Add xml vistor.
3453 * tdesc.h (struct target_desc): Make xmltarget mutable.
3454 (tdesc_get_features_xml): Remove declaration.
3456 2018-04-18 Alan Hayward <alan.hayward@arm.com>
3458 * tdesc.c (tdesc_architecture_name): Add new function.
3459 (tdesc_osabi_name): Likewise.
3460 (tdesc_get_features_xml): Use new functions.
3462 2018-04-18 Alan Hayward <alan.hayward@arm.com>
3464 * tdesc.c (tdesc_create_flags): Remove.
3465 (tdesc_add_flag): Likewise.
3466 (tdesc_named_type): Likewise.
3467 (tdesc_create_union): Likewise.
3468 (tdesc_create_struct): Likewise.
3469 (tdesc_create_vector): Likewise.
3470 (tdesc_add_bitfield): Likewise.
3471 (tdesc_add_field): Likewise.
3472 (tdesc_set_struct_size): Likewise.
3474 2018-04-18 Alan Hayward <alan.hayward@arm.com>
3476 * tdesc.c (~target_desc): Remove implictly deleted items.
3477 (init_target_desc): Iterate all features.
3478 (tdesc_get_features_xml): Use vector.
3479 (tdesc_create_feature): Create feature.
3480 * tdesc.h (tdesc_feature) Remove
3481 (target_desc): Add features.
3483 2018-04-18 Alan Hayward <alan.hayward@arm.com>
3485 * Makefile.in: Add common/tdesc.c
3486 * tdesc.c (init_target_desc): init all reg_defs from register
3488 (tdesc_create_reg): Create tdesc_reg.
3489 * tdesc.h (tdesc_feature): Add register vector.
3491 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
3493 * tdesc.h (struct target_desc) <features>: Change type to
3494 std::vector<std::string>.
3495 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
3497 (tdesc_get_features_xml): Likewise.
3498 (tdesc_create_feature): Likewise.
3500 2018-03-26 Alan Hayward <alan.hayward@arm.com>
3502 * regcache.c (find_register_by_number): Return a ref.
3503 (find_regno): Use references.
3504 (register_size): Likewise.
3505 (register_data): Likewise.
3506 * tdesc.c (target_desc::~target_desc): Remove free calls.
3507 (target_desc::operator==): Use std::vector compare.
3508 (init_target_desc): Use reference.
3509 (tdesc_create_reg): Use reg constructors.
3510 * tdesc.h (struct target_desc): Replace pointer with object.
3512 2018-03-23 Alan Hayward <alan.hayward@arm.com>
3514 * regcache.c (find_register_by_number): Make static.
3515 (find_regno): Use find_register_by_number
3516 * regcache.h (struct reg): Remove declaration.
3518 2018-03-23 Alan Hayward <alan.hayward@arm.com>
3520 * tdesc.c (target_desc::~target_desc): Move to here.
3521 (target_desc::operator==): Likewise.
3522 * tdesc.h (target_desc::~target_desc): Move from here.
3523 (target_desc::operator==): Likewise.
3525 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
3527 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
3529 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
3531 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
3533 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
3534 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
3535 and init_registers_s390_gs_linux64.
3537 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
3539 * linux-s390-low.c (s390_fill_gs): Remove function.
3540 (s390_fill_gsbc): Remove function.
3541 (s390_regsets): Set fill functions for the guarded storage regsets
3544 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
3546 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
3547 the word size. Add comment.
3548 (s390_get_wordsize): New function.
3549 (s390_arch_setup): No longer select a temporary tdesc to fetch the
3550 pswm with it. Instead, use s390_get_wordsize to determine the
3551 word size first and derive the correct tdesc from that directly.
3553 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
3555 * Makefile.in: Include silent-rules.mk.
3556 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
3557 (COMPILE): Add ECHO_CXX.
3558 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
3559 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
3560 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
3561 (version-generated.c): Add ECHO_GEN.
3562 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
3563 (IPAGENT_COMPILE): Add ECHO_CXX.
3564 (%-generated.c): Add ECHO_REGDAT.
3566 2018-03-14 Tom Tromey <tom@tromey.com>
3569 * ax.c (ax_printf): Special case for NULL.
3571 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
3573 * linux-low.c (linux_qxfer_libraries_svr4): Use
3574 xml_escape_text_append.
3576 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
3578 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
3580 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
3582 * server.c (handle_general_set): Remove unnecessary xstrdup.
3584 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
3586 * server.c (parse_debug_format_options): Adjust to
3587 delim_string_to_char_ptr_vec changes.
3588 * thread-db.c (thread_db_load_search): Adjust to
3589 dirnames_to_char_ptr_vec changes.
3591 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
3593 * target.h (target_enable_btrace, target_disable_btrace)
3594 (target_read_btrace, target_read_btrace_conf): Turn macro into
3595 inline function. Throw error if target method is not defined.
3596 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
3597 check for btrace target method. Be prepared to handle exceptions
3598 from btrace target methods.
3600 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
3602 * server.c (captured_main): Change order of error message printed
3603 when the current working directory cannot be found.
3605 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
3607 * server.c: Include "filenames.h" and "pathstuff.h".
3608 (program_name): Delete variable.
3609 (program_path): New anonymous class.
3610 (get_exec_wrapper): Use "program_path" instead of
3612 (handle_v_run): Likewise.
3613 (captured_main): Likewise.
3614 (process_serial_event): Likewise.
3616 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
3618 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
3619 (OBJS): Add "pathstuff.o".
3620 * server.c (current_directory): New global variable.
3621 (captured_main): Initialize "current_directory".
3623 2018-02-26 Alan Hayward <alan.hayward@arm.com>
3625 * tdesc.c: Use common/tdesc.h.
3626 * tdesc.h: Likewise.
3628 2018-02-20 Alan Hayward <alan.hayward@arm.com>
3629 Simon Marchi <simon.marchi@ericsson.com>
3631 * Makefile.in: Switch order of make rules.
3633 2018-02-19 Alan Hayward <alan.hayward@arm.com>
3635 * Makefile.in: Add common directory in build.
3636 * configure.ac: Add common reference.
3637 * configure: Regenerate.
3639 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
3641 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
3642 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
3643 * spu-low.c (spu_target_ops): Likewise.
3644 * win32-low.c (win32_target_ops): Likewise.
3645 * server.c (supported_btrace_packets): Report packets unconditionally.
3646 * target.h (target_ops) <supports_btrace>: Remove.
3647 (target_supports_btrace): Remove.
3649 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
3651 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
3652 (handle_btrace_disable): Change return type to void. Use exceptions
3654 (handle_btrace_general_set): Catch exception and copy message to
3657 2018-02-08 Tom Tromey <tom@tromey.com>
3659 * linux-low.c (install_software_single_step_breakpoints): Use
3660 make_scoped_restore.
3661 * inferiors.c (make_cleanup_restore_current_thread): Remove.
3662 (do_restore_current_thread_cleanup): Remove.
3663 * gdbthread.h (make_cleanup_restore_current_thread): Don't
3666 2018-02-08 Tom Tromey <tom@tromey.com>
3668 * mem-break.c (set_raw_breakpoint_at): Use
3669 gdb::unique_xmalloc_ptr.
3671 2018-01-30 Pedro Alves <palves@redhat.com>
3674 * target.c (target_terminal::terminal_state): Rename to ...
3675 (target_terminal::m_terminal_state): ... this.
3677 2018-01-19 James Clarke <jrtc27@jrtc27.com>
3679 * linux-low.c (handle_extended_wait): Surround call to
3680 thread_db_notice_clone with #ifdef USE_THREAD_DB.
3682 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
3684 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
3685 linux_ptrace_attach_fail_reason_string now returning an
3687 (linux_attach): Likewise.
3688 * thread-db.c (attach_thread): Likewise.
3690 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
3693 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
3694 checking for fs_base/gs_base fields in struct user_regs_struct.
3695 * configure: Regenerate.
3697 2018-01-16 Yao Qi <yao.qi@linaro.org>
3700 * linux-low.c (fetch_register): Call supply_register instead of
3703 2018-01-08 Yao Qi <yao.qi@linaro.org>
3704 Simon Marchi <simon.marchi@ericsson.com>
3706 * Makefile.in (OBS): Remove selftest.o.
3707 * configure.ac: Set srv_selftest_objs if $development is true.
3708 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
3709 * configure: Re-generated.
3710 * server.c (captured_main): Wrap variable selftest_filter with
3713 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
3715 * server.c (parse_debug_format_options): Return std::string.
3716 (handle_monitor_command, captured_main): Adjust.
3718 2018-01-05 Pedro Alves <palves@redhat.com>
3721 * server.c (captured_main): Pass quiet=false to
3722 save_original_signals_state.
3724 2018-01-01 Joel Brobecker <brobecker@adacore.com>
3726 * gdbreplay.c (gdbreplay_version): Update copyright year in
3728 * server.c (gdbserver_version): Likewise.
3730 2017-12-08 Tom Tromey <tom@tromey.com>
3732 * ax.c (ax_printf): Update.
3734 2017-12-07 Yao Qi <yao.qi@linaro.org>
3736 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
3737 aarch64_linux_read_description.
3738 * linux-amd64-ipa.c (idx2mask): New array.
3739 (get_ipa_tdesc): Move idx2mask out.
3740 (initialize_low_tracepoint): Initialize target descriptions.
3741 * linux-i386-ipa.c (idx2mask): New array.
3742 (get_ipa_tdesc): Move idx2mask out.
3743 (initialize_low_tracepoint): Initialize target descriptions.
3745 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
3747 * tdesc.c (struct tdesc_type): Change return type.
3748 (tdesc_add_flag): Change parameter type.
3749 (tdesc_add_bitfield): Likewise.
3750 (tdesc_add_field): Likewise.
3751 (tdesc_set_struct_size): Likewise.
3753 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
3755 * regcache.c (registers_to_string): Remove unused variable.
3757 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3759 * inferiors.c (for_each_inferior_with_data): Remove.
3760 * inferiors.h (for_each_inferior_with_data): Remove.
3761 * server.c (handle_qxfer_threads_worker): Change parameter type.
3762 (handle_qxfer_threads_proper): Use for_each_thread.
3764 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3766 * inferiors.c (for_each_inferior): Remove.
3767 (clear_inferiors): Use for_each_thread.
3768 * inferiors.h (for_each_inferior): Remove.
3769 * linux-low.c (linux_wait_for_event_filtered): Use
3771 (linux_stabilize_threads): Likewise.
3772 * regcache.c (regcache_release): Likewise.
3773 * server.c (gdb_wants_all_threads_stopped): Likewise.
3774 (clear_pending_status_callback): Remove.
3775 (handle_status): Use for_each_thread.
3776 (captured_main): Likewise.
3777 * win32-low.c (child_init_thread_list): Likewise.
3778 (win32_clear_inferiors): Likewise.
3779 (fake_breakpoint_event): Likewise.
3781 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3783 * inferiors.h (find_inferior): Remove.
3784 * inferiors.c (find_inferior): Remove.
3786 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3788 * linux-low.c (resume_status_pending_p): Update comment.
3789 (need_step_over_p): Update comment.
3791 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3793 * linux-low.c (proceed_one_lwp): Return void, change parameter
3795 (unsuspend_and_proceed_one_lwp): Likewise.
3796 (proceed_all_lwps): Use for_each_thread.
3797 (unstop_all_lwps): Likewise.
3799 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3801 * linux-low.c (linux_resume_one_thread): Return void, take
3803 (linux_resume): Use for_each_thread.
3805 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3807 * linux-low.c (send_sigstop_callback): Return void, change
3808 parameter type. Rename to...
3809 (send_sigstop): ... this.
3810 (suspend_and_send_sigstop_callback): Return void, change parameter
3812 (suspend_and_send_sigstop): ... this.
3813 (stop_all_lwps): Use for_each_thread.
3815 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3817 * linux-low.c (lwp_running): Return bool, remove unused
3819 (linux_stabilize_threads): Use find_thread.
3821 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3823 * linux-low.c (select_singlestep_lwp_callback): Remove.
3824 (count_events_callback): Remove.
3825 (select_event_lwp_callback): Remove.
3826 (select_event_lwp): Use find_thread/for_each_thread.
3828 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3830 * linux-low.c (not_stopped_callback): Return bool, take filter
3832 (linux_wait_for_event_filtered): Use find_thread.
3833 (linux_wait_1): Likewise.
3835 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3837 * linux-low.c (same_lwp): Remove.
3838 (find_lwp_pid): Use find_thread.
3840 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3842 * linux-low.c (delete_lwp_callback): Remove.
3843 (linux_mourn): Use for_each_thread.
3845 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3847 * linux-low.c (linux_detach_lwp_callback): Return void, remove
3848 args parameter, don't check for pid.
3849 (linux_detach): Use for_each_thread.
3851 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3853 * linux-low.c (struct counter): Remove.
3854 (second_thread_of_pid_p): Remove.
3855 (last_thread_of_process_p): Use find_thread.
3857 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3859 * inferiors.c (find_inferior_in_random): Remove.
3860 * inferiors.h (find_inferior_in_random): Remove.
3861 * linux-low.c (status_pending_p_callback): Return bool, accept
3862 parameter ptid directly.
3863 (linux_wait_for_event_filtered): Use find_thread_in_random.
3864 (linux_wait_1): Likewise.
3866 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3868 * inferiors.c (find_inferior_id): Remove.
3869 (find_thread_ptid): Move implemention from find_inferior_id to
3871 * inferiors.h (find_inferior_id): Remove.
3872 * server.c (handle_status): Use find_thread_ptid.
3873 (process_serial_event): Likewise.
3874 * thread-db.c (find_one_thread): Likewise.
3875 (thread_db_thread_handle): Likewise.
3876 * win32-low.c (thread_rec): Likewise.
3877 (child_delete_thread): Likewise.
3878 (win32_thread_alive): Likewise.
3879 (get_child_debug_event): Likewise.
3881 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3883 * linux-mips-low.c (update_watch_registers_callback): Return
3884 void, remove pid_p parameter, don't check for pid.
3885 (mips_insert_point, mips_remove_point): Use for_each_thread.
3887 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3889 * lynx.low (lynx_delete_thread_callback): Remove.
3890 (lynx_mourn): Use for_each_thread.
3892 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3894 * regcache.c (regcache_invalidate_one): Remove.
3895 (regcache_invalidate_pid): use for_each_thread.
3897 2017-11-26 Tom Tromey <tom@tromey.com>
3899 * linux-low.c (linux_create_inferior): Update.
3901 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
3903 * spu-low.c (spu_create_inferior): Fix typo in argument name.
3905 2017-11-24 Alan Hayward <alan.hayward@arm.com>
3907 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
3908 * linux-aarch64-low.c (initialize_low_arch): Call init func.
3909 * linux-aarch64-tdesc-selftest.c: New file.
3910 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
3912 2017-11-24 Alan Hayward <alan.hayward@arm.com>
3914 * configure.srv: Add new file.
3915 * linux-aarch64-low.c (initialize_low_arch): Call init func.
3916 * linux-aarch64-tdesc-selftest.c: New file.
3917 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
3919 2017-11-24 Alan Hayward <alan.hayward@arm.com>
3921 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
3922 * linux-aarch64-low.c (initialize_low_arch): Remove init.
3923 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
3925 2017-11-24 Alan Hayward <alan.hayward@arm.com>
3927 * configure.srv: Add new files.
3928 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
3929 aarch64_linux_read_description.
3930 * linux-aarch64-low.c (aarch64_linux_read_description):
3931 Merge with aarch64_arch_setup.
3932 (aarch64_arch_setup): Call aarch64_linux_read_description.
3933 * linux-aarch64-tdesc.c: New file.
3934 * linux-aarch64-tdesc.h: New file.
3936 2017-11-24 Yao Qi <yao.qi@linaro.org>
3938 * configure.srv: Set $srv_regobj for tic6x-linux.
3939 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
3940 (tic6x_read_description): Move some code to tic6x_arch_setup.
3941 (tic6x_tdesc_test): New function.
3942 (initialize_low_arch): Call selftests::register_test.
3944 2017-11-22 Yao Qi <yao.qi@linaro.org>
3946 * remote-utils.c (prepare_resume_reply): Use memcpy.
3948 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3950 * linux-low.c (kill_one_lwp_callback): Return void, take
3951 argument directly, don't filter on pid.
3952 (linux_kill): Use for_each_thread.
3954 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3956 * linux-low.c (need_step_over_p): Return bool, remove dummy
3958 (linux_resume, proceed_all_lwps): Use find_thread.
3960 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3962 * linux-low.c (resume_status_pending_p): Return bool, remove
3964 (linux_resume): Use find_thread.
3966 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3968 * linux-low.c (struct thread_resume_array): Remove.
3969 (linux_set_resume_request): Return void, take arguments
3971 (linux_resume): Use for_each_thread.
3973 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3975 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
3976 return bool, remove data argument.
3977 (linux_stabilize_threads): Use find_thread.
3979 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3981 * linux-low.c (unsuspend_one_lwp): Remove.
3982 (unsuspend_all_lwps): Use for_each_thread, inline code from
3985 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3987 * gdbthread.h (find_thread): Add overload with ptid_t filter.
3988 * linux-low.c (struct iterate_over_lwps_args): Remove.
3989 (iterate_over_lwps_filter): Remove.
3990 (iterate_over_lwps): Use find_thread.
3992 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3994 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
3995 (linux_handle_new_gdb_connection): Use for_each_thread, inline
3996 code from reset_lwp_ptrace_options_callback.
3998 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4000 * linux-arm-low.c (struct update_registers_data): Remove.
4001 (update_registers_callback): Return void, take arguments
4002 directly, don't check thread's pid.
4003 (arm_insert_point, arm_remove_point): Use for_each_thread.
4005 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4007 * win32-low.c (continue_one_thread): Return void, take argument
4009 (child_continue): Use for_each_thread.
4011 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4013 * win32-i386-low.c (update_debug_registers_callback): Rename
4015 (update_debug_registers): ... this, return void, remove pid_p arg.
4016 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
4018 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
4020 * inferiors.h (struct process_info): Add constructor, initialize
4022 <syscalls_to_catch>: Change type to std::vector<int>.
4023 * inferiors.c (add_process): Allocate process_info with new.
4024 (remove_process): Free process_info with delete.
4025 * linux-low.c (handle_extended_wait): Adjust.
4026 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
4027 * server.c (handle_general_set): Adjust.
4029 2017-11-16 Pedro Alves <palves@redhat.com>
4031 * remote-utils.c (remote_close): Block SIGIO signals instead of
4032 uninstalling the SIGIO handler.
4034 2017-11-16 Alan Hayward <alan.hayward@arm.com>
4036 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
4038 2017-11-16 Yao Qi <yao.qi@linaro.org>
4040 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
4041 (tic6x_store_gregset): Likewise.
4042 (tic6x_usrregs_info): Move it up.
4044 2017-11-15 Alan Hayward <alan.hayward@arm.com>
4046 * Makefile.in: Update arch rules.
4047 * configure.srv: Explicitly mark arch/ files.
4049 2017-11-13 Andreas Schwab <schwab@suse.de>
4051 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
4053 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4055 2017-11-06 Pedro Alves <palves@redhat.com>
4057 * config.in, configure: Regenerate.
4059 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4061 * target.c (struct thread_search): Remove.
4062 (thread_search_callback): Remove.
4063 (prepare_to_access_memory): Use for_each_thread instead of
4064 find_inferior. Inline code from thread_search_callback.
4066 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4068 * server.c (struct visit_actioned_threads_data): Remove.
4069 (visit_actioned_threads): Change prototype to take arguments
4071 (resume): Use find_thread instead of find_inferior.
4073 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4075 * server.c (queue_stop_reply_callback): Change prototype, return
4077 (find_status_pending_thread_callback): Remove.
4078 (handle_status): Replace find_inferior with find_thread and
4081 2017-10-25 Alan Hayward <alan.hayward@arm.com>
4083 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
4085 (aarch64_store_gregset): Likewise.
4086 (aarch64_fill_fpregset): Likewise.
4087 (aarch64_store_fpregset): Likewise.
4089 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
4091 * gdbthread.h (find_thread, for_each_thread): New functions.
4092 * inferiors.c (thread_of_pid): Remove.
4093 (find_any_thread_of_pid): Use find_thread.
4094 * linux-low.c (num_lwps): Use for_each_thread.
4096 2017-10-17 Yao Qi <yao.qi@linaro.org>
4098 * Makefile.in: Remove one rule.
4099 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
4101 2017-10-17 Yao Qi <yao.qi@linaro.org>
4103 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
4104 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
4106 2017-10-17 Yao Qi <yao.qi@linaro.org>
4108 * configure.srv: Rename arm.o with arch/arm.o.
4110 2017-10-17 Yao Qi <yao.qi@linaro.org>
4112 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
4113 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
4114 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
4115 (arch-i386.o, arch-amd64.o): Remove rules.
4116 (arch/%.o): New rule.
4117 Update POSTCOMPILE and COMPILE.pre.
4118 * configure.ac: Invoke AC_CONFIG_COMMANDS.
4119 * configure: Re-generated.
4120 * configure.srv: Replace arch-i386.o with arch/i386.o.
4121 Replace arch-amd64.o with arch/amd64.o.
4123 2017-10-16 Yao Qi <yao.qi@linaro.org>
4125 * configure: Regenerated.
4127 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4129 * inferiors.h: (struct inferior_list): Remove.
4130 (struct inferior_list_entry); Remove.
4131 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
4132 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
4133 get_first_inferior): Remove.
4134 (for_each_inferior, for_each_inferior_with_data, find_inferior,
4135 find_inferior_id, find_inferior_in_random): Change signature.
4136 * inferiors.c (all_threads): Change type to
4137 std::list<thread_info *>.
4138 (get_thread): Remove macro.
4139 (find_inferior, find_inferior_id): Change signature, implement
4141 (find_inferior_in_random): Change signature, implement using
4142 find_thread_in_random.
4143 (for_each_inferior, for_each_inferior_with_data): Change
4144 signature, implement using for_each_thread.
4145 (add_inferior_to_list, remove_inferior): Remove.
4146 (add_thread, get_first_thread, thread_of_pid,
4147 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
4148 (get_first_inferior, one_inferior_p, clear_inferior_list):
4150 (clear_inferiors, get_thread_process): Update.
4151 * gdbthread.h: Include <list>.
4152 (struct thread_info) <entry>: Remove field.
4154 (all_threads): Change type to std::list<thread_info *>.
4155 (get_first_inferior): Add doc.
4156 (find_thread, for_each_thread, find_thread_in_random): New
4158 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
4159 * linux-arm-low.c (update_registers_callback): Update.
4160 * linux-low.c (second_thread_of_pid_p): Update.
4161 (kill_one_lwp_callback, linux_detach_lwp_callback,
4162 delete_lwp_callback, status_pending_p_callback, same_lwp,
4163 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
4164 iterate_over_lwps, not_stopped_callback,
4165 resume_stopped_resumed_lwps, count_events_callback,
4166 select_singlestep_lwp_callback, select_event_lwp_callback,
4167 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
4168 suspend_and_send_sigstop_callback, wait_for_sigstop,
4169 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
4170 lwp_running, linux_set_resume_request, resume_status_pending_p,
4171 need_step_over_p, start_step_over, linux_resume_one_thread,
4172 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
4173 reset_lwp_ptrace_options_callback): Update.
4174 * linux-mips-low.c (update_watch_registers_callback): Update.
4175 * regcache.c (regcache_invalidate_one, regcache_invalidate):
4177 (free_register_cache_thread_one): Remove.
4178 (regcache_release): Update.
4179 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
4180 handle_qxfer_threads_worker): Update.
4181 (handle_query): Update, use list iterator.
4182 (visit_actioned_threads, handle_pending_status,
4183 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
4184 clear_pending_status_callback, set_pending_status_callback,
4185 find_status_pending_thread_callback, handle_status,
4186 process_serial_event): Update.
4187 * target.c (thread_search_callback): Update.
4188 * thread-db.c (thread_db_get_tls_address): Update.
4189 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
4191 * win32-i386-low.c (update_debug_registers_callback): Update.
4192 * win32-low.c (delete_thread_info, child_delete_thread,
4193 continue_one_thread, suspend_one_thread,
4194 get_child_debug_event): Adjust.
4196 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4198 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
4199 * inferiors.h: Include <list>.
4200 (struct process_info) <entry>: Remove field.
4202 (pid_of): Change macro to function.
4203 (ptid_of, lwpid_of): Remove macro.
4204 (all_processes): Change type to std::list<process_info *>.
4205 (ALL_PROCESSES): Remove macro.
4206 (for_each_process, find_process): New function.
4207 * inferiors.c (all_processes): Change type to
4208 std::list<process_info *>.
4209 (find_thread_process): Adjust.
4210 (add_process): Likewise.
4211 (remove_process): Likewise.
4212 (find_process_pid): Likewise.
4213 (get_first_process): Likewise.
4214 (started_inferior_callback): Remove.
4215 (have_started_inferiors_p): Adjust.
4216 (attached_inferior_callback): Remove.
4217 (have_attached_inferiors_p): Adjust.
4218 * linux-low.c (check_zombie_leaders): Likewise.
4219 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
4220 (x86_linux_update_xmltarget): Adjust.
4221 * server.c (handle_query): Likewise.
4222 (gdb_reattached_process): Remove.
4223 (handle_status): Adjust.
4224 (kill_inferior_callback): Likewise.
4225 (detach_or_kill_inferior): Remove.
4226 (print_started_pid): Likewise.
4227 (print_attached_pid): Likewise.
4228 (detach_or_kill_for_exit): Update.
4229 (process_serial_event): Likewise.
4230 * linux-arm-low.c (arm_new_fork): Likewise.
4232 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4234 * dll.h: Include <list>.
4235 (struct dll_info): Add constructor.
4236 <entry>: Remove field.
4237 (all_dlls): Change type to std::list<dll_info>.
4238 * dll.c: Include <algorithm>.
4239 (get_dll): Remove macro.
4240 (all_dlls): Change type to std::list<dll_info *>.
4241 (free_one_dll): Remove.
4242 (match_dll): Likewise.
4243 (loaded_dll): Adjust.
4244 (unloaded_dll): Adjust to all_dlls type change, use
4245 std::find_if. Inline code from match_dll.
4246 (clear_dlls): Adjust to all_dlls type change.
4247 * server.c (emit_dll_description): Remove.
4248 (handle_qxfer_libraries): Adjust to all_dlls type change,
4249 integrate emit_dll_description's functionality.
4251 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
4253 * linux-low.h (struct linux_target_ops) <delete_process>: New
4255 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
4256 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
4257 (struct linux_target_ops): Add delete_process callback.
4258 * linux-arm-low.c (arm_delete_process): New.
4259 (struct linux_target_ops): Add delete_process callback.
4260 * linux-bfin-low.c (struct linux_target_ops): Likewise.
4261 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
4262 * linux-m32r-low.c (struct linux_target_ops): Likewise.
4263 * linux-mips-low.c (mips_linux_delete_process): New.
4264 (struct linux_target_ops): Add delete_process callback.
4265 * linux-ppc-low.c (struct linux_target_ops): Likewise.
4266 * linux-s390-low.c (struct linux_target_ops): Likewise.
4267 * linux-sh-low.c (struct linux_target_ops): Likewise.
4268 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
4269 * linux-tile-low.c (struct linux_target_ops): Likewise.
4270 * linux-x86-low.c (x86_linux_delete_process): New.
4271 (struct linux_target_ops): Add delete_process callback.
4272 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
4274 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
4276 * linux-aarch64-low.c (the_low_target): Add thread delete
4278 * linux-arm-low.c (arm_delete_thread): New function.
4279 (the_low_target): Add thread delete callback.
4280 * linux-bfin-low.c (the_low_target): Likewise.
4281 * linux-crisv32-low.c (the_low_target): Likewise.
4282 * linux-low.c (delete_lwp): Invoke delete_thread callback if
4284 * linux-low.h (struct linux_target_ops) <delete_thread>: New
4286 * linux-m32r-low.c (the_low_target): Add thread delete callback.
4287 * linux-mips-low.c (mips_linux_delete_thread): New function.
4288 (the_low_target): Add thread delete callback.
4289 * linux-ppc-low.c (the_low_target): Likewise.
4290 * linux-s390-low.c (the_low_target): Likewise.
4291 * linux-sh-low.c (the_low_target): Likewise.
4292 * linux-tic6x-low.c (the_low_target): Likewise.
4293 * linux-tile-low.c (the_low_target): Likewise.
4294 * linux-x86-low.c (the_low_target): Likewise.
4295 * linux-xtensa-low.c (the_low_target): Likewise.
4297 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
4299 * win32-low.c: Include "common-inferior.h".
4301 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4303 * inferiors.c (set_inferior_cwd): New function.
4304 * server.c (handle_general_set): Handle QSetWorkingDir packet.
4305 (handle_query): Inform that QSetWorkingDir is supported.
4306 * win32-low.c (create_process): Pass the inferior's cwd to
4309 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4311 * inferiors.c (current_inferior_cwd): New global variable.
4312 (get_inferior_cwd): New function.
4313 * inferiors.h (struct process_info) <cwd>: New field.
4315 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4317 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
4318 (OBS): Add gdb_tilde_expand.o.
4320 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
4322 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
4323 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
4325 2017-09-29 Pedro Alves <palves@redhat.com>
4327 * ax.c (gdb_parse_agent_expr): Constify.
4328 * ax.h (gdb_parse_agent_expr): Constify.
4329 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
4331 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
4332 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
4333 * remote-utils.h (read_ptid): Constify.
4334 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
4335 (process_point_options, process_serial_event): Constify.
4336 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
4337 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
4338 (cmd_qtbuffer): Constify.
4340 2017-09-29 Pedro Alves <palves@redhat.com>
4342 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
4345 2017-09-29 Pedro Alves <palves@redhat.com>
4347 * linux-low.c (handle_extended_wait): Pass parent thread instead
4348 of process to thread_db_notice_clone.
4349 * linux-low.h (thread_db_notice_clone): Replace parent process
4350 parameter with parent thread parameter.
4351 * thread-db.c (find_one_thread): Add comment.
4352 (thread_db_notice_clone): Replace parent process parameter with
4353 parent thread parameter. Temporarily switch to the parent thread.
4355 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
4357 * gdbthread.h: Include "common-gdbthread.h".
4358 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
4359 "if" when validating the ptid.
4360 * remote-utils.c: Include "gdbthread.h".
4361 (prepare_resume_reply): Use "switch_to_thread".
4362 * target.c (done_accessing_memory): Likewise.
4364 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
4366 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
4367 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
4368 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
4369 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
4370 s390x-gs-linux64-ipa.o to ipa_obj.
4371 * linux-s390-low.c (HWCAP_S390_GS): New define.
4372 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
4374 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
4375 (s390_arch_setup): Check for guarded-storage support and choose
4377 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
4378 init_registers_s390x_gs_linux64.
4379 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
4381 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
4382 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
4384 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
4386 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
4388 2017-09-21 Kevin Buettner <kevinb@redhat.com>
4390 * linux-low.h (struct lwp_info): Add new field, thread_handle.
4391 (thread_db_thread_handle): Declare.
4392 * linux-low.c (linux_target_ops): Initialize thread_handle.
4393 * server.c (handle_qxfer_threads_worker): Add support for
4395 * target.h (struct target_ops): Add new function pointer,
4397 (target_thread_handle): Define.
4398 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
4400 (thread_db_thread_handle): New function.
4402 2017-09-21 Kevin Buettner <kevinb@redhat.com>
4404 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
4405 * linux-low.h (thread_db_notice_clone): Declare.
4406 * thread-db.c (thread_db_notice_clone): New function.
4408 2017-09-21 Pedro Alves <palves@redhat.com>
4410 * server.c (gdb_read_memory, handle_status, process_serial_event)
4411 (handle_serial_event, handle_target_event): Adjust to
4412 set_desired_thread prototype change.
4413 * target.c (set_desired_thread): Remove 'use_general' parameter
4415 * target.h (set_desired_thread): Remove 'use_general' parameter.
4417 2017-09-20 Tom Tromey <tom@tromey.com>
4419 * target.c (target_terminal::terminal_state): Define.
4420 (target_terminal::init): Rename from target_terminal_init.
4421 (target_terminal::inferior): Rename from
4422 target_terminal_inferior.
4423 (target_terminal::ours): Rename from target_terminal_ours.
4424 (target_terminal::ours_for_output, target_terminal::info): New.
4426 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4428 * server.c (accumulate_file_name_length): Remove.
4429 (emit_dll_description): Adjust to std::string change.
4430 (handle_qxfer_libraries): Use std::string to hold document.
4432 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4434 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
4435 return type of xml_escape_text.
4436 * server.c (emit_dll_description): Likewise.
4438 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4440 * server.c (captured_main): Accept argument for --selftest.
4441 Update run_tests call.
4442 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
4443 when registering selftests.
4445 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
4447 * regcache.c (get_thread_regcache): Update code to use "std::vector"
4448 instead of "VEC" for "target_desc.reg_defs".
4449 (regcache_cpy): Likewise.
4450 (registers_to_string): Likewise.
4451 (registers_from_string): Likewise.
4452 (find_regno): Likewise.
4453 (supply_regblock): Likewise.
4454 (regcache_raw_read_unsigned): Likewise.
4455 * tdesc.c (init_target_desc): Likewise.
4456 (tdesc_create_reg): Likewise.
4457 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
4458 (struct target_desc) <reg_defs>: Convert to "std::vector".
4459 (target_desc): Do not initialize "reg_defs".
4460 (~target_desc): Update code to use "std::vector" instead of "VEC"
4461 for "target_desc.reg_defs".
4462 (operator==): Likewise.
4464 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4466 * inferiors.h (thread_to_gdb_id): Remove.
4467 * inferiors.c (thread_to_gdb_id): Remove.
4468 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
4469 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
4470 lynx_store_registers, lynx_read_memory, lynx_write_memory):
4472 * nto-low.c (nto_fetch_registers, nto_store_registers,
4473 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
4475 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4477 * inferiors.h (gdb_id_to_thread_id): Remove.
4478 * inferiors.c (gdb_id_to_thread_id): Remove.
4479 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
4480 removal. Move pid declaration closer to where it's used.
4482 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4484 * server.c (handle_detach): New function.
4485 (process_serial_event): Move code out, call handle_detach.
4487 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4489 * server.c (require_running): Rename to ...
4490 (require_running_or_return): ... this ...
4491 (require_running_or_break): ... and this.
4492 (handle_query, process_serial_event): Adjust.
4494 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4496 * linux-low.c (linux_set_resume_request): Remove unused
4499 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4501 * server.c (first_thread_of): Remove.
4502 (process_serial_event): Replace usage of first_thread_of with
4503 find_any_thread_of_pid.
4504 * tracepoint.c (same_process_p): Remove.
4505 (gdb_agent_about_to_close): Replace usage of same_process_p with
4506 find_any_thread_of_pid.
4507 * linux-x86-low.c (same_process_callback): Remove.
4508 (x86_arch_setup_process_callback): Replace usage of
4509 same_process_callback with find_any_thread_of_pid.
4510 * thread-db.c (any_thread_of): Remove.
4511 (switch_to_process): Replace usage of any_thread_of with
4512 find_any_thread_of_pid.
4513 * inferiors.c (thread_pid_matches_callback): Remove.
4514 (find_thread_process): Adjust to use find_any_thread_of_pid.
4516 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
4518 * regcache.c (get_thread_regcache): Guard calls to "memset"
4521 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
4523 * linux-low.c (handle_extended_wait): Use
4524 "allocate_target_description" instead of "XNEW".
4525 * linux-x86-low.c (initialize_low_arch): Likewise.
4527 2017-09-05 Yao Qi <yao.qi@linaro.org>
4529 * configure.srv (srv_i386_regobj): Remove.
4530 (srv_amd64_regobj): Remove.
4531 (srv_regobj): Set it to "" for x86 non-linux targets.
4532 * linux-x86-tdesc.c (i386_linux_read_description):
4533 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
4534 (init_registers_i386): Remove the declaration.
4535 (tdesc_i386): Remove the declaration.
4536 (lynx_i386_arch_setup): Call i386_create_target_description.
4537 * nto-x86-low.c: Likewise.
4538 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
4539 [!__x86_64__]: include arch/i386.h.
4540 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
4542 2017-09-05 Yao Qi <yao.qi@linaro.org>
4544 * configure.srv (srv_amd64_linux_xmlfiles): Remove
4545 i386/amd64-XXX-linux from it.
4547 2017-09-05 Yao Qi <yao.qi@linaro.org>
4549 * configure.srv: Empty srv_amd64_linux_regobj if $development is
4551 (ipa_amd64_linux_regobj): Remove.
4552 (ipa_x32_linux_regobj): Remove.
4554 2017-09-05 Yao Qi <yao.qi@linaro.org>
4556 * Makefile.in (arch-amd64.o): New rule.
4557 * configure.srv: Append arch-amd64.o.
4558 * linux-amd64-ipa.c: Include common/x86-xstate.h.
4559 (get_ipa_tdesc): Call amd64_linux_read_description.
4560 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
4561 and init_registers_amd64_XXX.
4562 * linux-x86-low.c (x86_linux_read_description): Call
4563 amd64_linux_read_description.
4564 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
4565 (initialize_low_arch): Don't call init_registers_x32_XXX and
4566 init_registers_amd64_XXX.
4567 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
4568 and tdesc_amd64_XXX.
4569 [__x86_64__] (amd64_tdesc_test): New function.
4570 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
4571 and init_registers_amd64_XXX.
4572 * linux-x86-tdesc.c: Include arch/amd64.h.
4573 (xcr0_to_tdesc_idx): New function.
4574 (i386_linux_read_description): New function.
4575 (amd64_get_ipa_tdesc_idx): New function.
4576 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
4577 (amd64_get_ipa_tdesc): Declare.
4579 2017-09-05 Yao Qi <yao.qi@linaro.org>
4581 * configure.srv (srv_i386_linux_xmlfiles): Remove
4582 i386/i386-XXX-linux.xml from it.
4584 2017-09-05 Yao Qi <yao.qi@linaro.org>
4586 * configure.srv: Set srv_i386_linux_regobj empty if $development
4588 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
4589 initialize_low_tdesc.
4590 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
4591 with #if initialize_low_tdesc.
4592 * linux-x86-tdesc-selftest.c: New file.
4593 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
4595 2017-09-05 Yao Qi <yao.qi@linaro.org>
4597 * Makefile.in (arch-i386.o): New rule.
4598 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
4599 (x86_64-*-linux*): Likewise.
4600 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
4601 include arch/i386.h.
4602 (i386_linux_read_description): Remove code and call
4603 i386_create_target_description.
4604 * tdesc.c (allocate_target_description): New function.
4605 * tdesc.h (set_tdesc_architecture): Remove declaration.
4606 (set_tdesc_osabi): Likewise.
4608 2017-09-05 Yao Qi <yao.qi@linaro.org>
4610 * linux-x86-tdesc.c: Don't include <inttypes.h>.
4611 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
4612 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
4614 * server.c (get_features_xml): Call tdesc_get_features_xml.
4615 * tdesc.c (set_tdesc_architecture): New function.
4616 (set_tdesc_osabi): New function.
4617 (tdesc_get_features_xml): New function.
4618 (tdesc_create_feature): Add an argument.
4619 * tdesc.h (struct target_desc) <features>: New field.
4620 <arch, osabi>: New field.
4621 (~target_desc): xfree features, arch, and osabi.
4622 (target_desc::oerator==): Don't compare .xmltarget.
4623 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
4624 (set_tdesc_osabi): Likewise.
4625 (tdesc_get_features_xml): Likewise.
4627 2017-09-05 Yao Qi <yao.qi@linaro.org>
4629 * linux-x86-tdesc.c: Include selftest.h.
4630 (i386_tdesc_test): New function.
4631 (initialize_low_tdesc): Call selftests::register_test.
4632 * tdesc.h: Include regdef.h.
4633 (target_desc): Override operator == and !=.
4635 2017-09-05 Yao Qi <yao.qi@linaro.org>
4637 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
4638 (ipa_obj): Likewise.
4639 * linux-i386-ipa.c: Include common/x86-xstate.h
4640 (get_ipa_tdesc): Call i386_linux_read_description.
4641 (initialize_low_tracepoint): Don't call init_registers_XXX
4642 functions, call initialize_low_tdesc instead.
4643 * linux-x86-low.c (x86_linux_read_description): Call
4644 i386_linux_read_description.
4645 (initialize_low_arch): Don't call init_registers_i386_XXX
4646 functions, call initialize_low_tdesc.
4647 * linux-x86-tdesc.c: New file.
4648 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
4649 (i386_get_ipa_tdesc_idx): Declare.
4650 (i386_get_ipa_tdesc): Declare.
4651 (initialize_low_tdesc): Declare.
4653 2017-09-05 Yao Qi <yao.qi@linaro.org>
4655 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
4658 2017-09-05 Yao Qi <yao.qi@linaro.org>
4660 * Makefile.in (IPA_OBJS): Add vec-ipa.o
4661 * regcache.c (get_thread_regcache): Use VEC_length.
4662 (init_register_cache): Likewise.
4663 (regcache_cpy): Likewise.
4664 (registers_to_string): Iterate reg_defs via VEC_iterate.
4665 (find_regno): Likewise.
4666 (find_register_by_number): Use VEC_index.
4667 (register_size): Call find_register_by_number.
4668 (register_data): Call find_register_by_number.
4669 (supply_regblock): Use VEC_length.
4670 (regcache_raw_read_unsigned): Likewise.
4671 * tdesc.c (init_target_desc): Iterate reg_defs via
4673 (default_description): Update initializer.
4674 (copy_target_description): Don't update field num_registers.
4675 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
4676 <num_registers>: Remove.
4678 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
4680 * Makefile.in (.SECONDARY): Define target.
4682 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
4684 * linux-low.c (linux_wait_1): Adjust.
4685 * server.c (queue_stop_reply_callback): Adjust.
4687 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
4689 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
4690 QEnvironmentUnset and QEnvironmentReset packets.
4691 (handle_query): Inform remote that QEnvironmentHexEncoded,
4692 QEnvironmentUnset and QEnvironmentReset are supported.
4694 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
4696 * inferiors.h (inferior_target_data): Rename to ...
4697 (thread_target_data): ... this.
4698 (inferior_regcache_data): Rename to ...
4699 (thread_regcache_data): ... this.
4700 (set_inferior_regcache_data): Rename to ...
4701 (set_thread_regcache_data): ... this.
4702 * inferiors.c (inferior_target_data): Rename to ...
4703 (thread_target_data): ... this.
4704 (inferior_regcache_data): Rename to ...
4705 (thread_regcache_data): ... this.
4706 (set_inferior_regcache_data): Rename to ...
4707 (set_thread_regcache_data): ... this.
4708 (free_one_thread): Update.
4709 * linux-low.h (get_thread_lwp): Update.
4710 * regcache.c (get_thread_regcache): Update.
4711 (regcache_invalidate_thread): Update.
4712 (free_register_cache_thread): Update.
4713 * win32-i386-low.c (update_debug_registers_callback): Update.
4714 (win32_get_current_dr): Update.
4715 * win32-low.c (thread_rec): Update.
4716 (delete_thread_info): Update.
4717 (continue_one_thread): Update.
4718 (suspend_one_thread): Update.
4720 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
4722 * inferiors.c (set_inferior_target_data): Remove.
4723 * inferiors.h (set_inferior_target_data): Remove.
4725 2017-08-18 Yao Qi <yao.qi@linaro.org>
4727 * Makefile.in (OBS): Add selftest.o.
4728 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
4729 * configure, config.in: Re-generated.
4730 * server.c: Include common/sefltest.h.
4731 (captured_main): Handle option --selftest.
4733 2017-08-09 Yao Qi <yao.qi@linaro.org>
4735 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
4736 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
4737 i386-avx-mpx.o and i386-mmx.o.
4738 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
4739 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
4740 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
4741 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
4742 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
4743 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
4744 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
4745 i386/amd64-avx-mpx.xml.
4747 2017-08-09 Yao Qi <yao.qi@linaro.org>
4749 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
4750 and x32-avx-avx512.o.
4751 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
4752 i386/x32-avx-avx512.xml.
4754 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
4756 * tracepoint.h (enum class fast_tpoint_collect_result): New
4758 (fast_tracepoint_collecting): Change return type to
4759 fast_tpoint_collect_result.
4760 * tracepoint.c (fast_tracepoint_collecting): Likewise.
4761 * linux-low.h: Include tracepoint.h.
4762 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
4763 fast_tpoint_collect_result.
4764 * linux-low.c (handle_tracepoints): Adjust.
4765 (linux_fast_tracepoint_collecting): Change return type to
4766 fast_tpoint_collect_result.
4767 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
4768 linux_wait_1, stuck_in_jump_pad_callback,
4769 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
4770 proceed_one_lwp): Adjust to type change.
4772 2017-07-10 Yao Qi <yao.qi@linaro.org>
4774 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
4776 2017-06-29 Yao Qi <yao.qi@linaro.org>
4778 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
4780 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
4782 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
4784 * Makefile.in (IPA_OBJS): Sort and format one item per line.
4786 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
4788 * linux-low.c (linux_create_inferior): Adjust code to access the
4789 environment information via 'gdb_environ' class.
4790 * lynx-low.c (lynx_create_inferior): Likewise.
4791 * server.c (our_environ): Make it an instance of 'gdb_environ'.
4792 (get_environ): Return a pointer to 'our_environ'.
4793 (captured_main): Initialize 'our_environ'.
4794 * server.h (get_environ): Adjust prototype.
4795 * spu-low.c (spu_create_inferior): Adjust code to access the
4796 environment information via 'gdb_environ' class.
4798 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4800 * linux-low.c (linux_read_memory, linux_write_memory): Remove
4801 usage of "register" keyword.
4803 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4805 * configure: Re-generate.
4807 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4809 * configure: Re-generate.
4811 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4813 * Makefile.in (COMPILE.pre): Add "-x c++".
4815 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
4817 * fork-child.c: Conditionally include <signal.h>.
4819 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4821 * server.c (handle_general_set): Handle new packet
4822 "QStartupWithShell".
4823 (handle_query): Add "QStartupWithShell" to the list of supported
4825 (gdbserver_usage): Add help text explaining the
4826 new "--startup-with-shell" and "--no-startup-with-shell" CLI
4828 (captured_main): Recognize and act upon the presence of the new
4831 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4832 Pedro Alves <palves@redhat.com>
4834 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
4835 * configure: Regenerate.
4836 * configure.srv (srv_linux_obj): Add "fork-child.o" and
4838 (i[34567]86-*-lynxos*): Likewise.
4839 (spu*-*-*): Likewise.
4840 * fork-child.c: New file.
4841 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
4843 (linux_ptrace_fun): New function.
4844 (linux_create_inferior): Adjust function prototype to reflect
4845 change on "target.h". Adjust function code to use
4847 (linux_request_interrupt): Delete "signal_pid".
4848 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
4849 (lynx_ptrace_fun): New function.
4850 (lynx_create_inferior): Adjust function prototype to reflect
4851 change on "target.h". Adjust function code to use
4853 * nto-low.c (nto_create_inferior): Adjust function prototype and
4854 code to reflect change on "target.h". Update comments.
4855 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
4856 "common-terminal.h" and "environ.h".
4857 (terminal_fd): Moved to fork-child.c.
4858 (old_foreground_pgrp): Likewise.
4859 (restore_old_foreground_pgrp): Likewise.
4860 (last_status): Make it global.
4861 (last_ptid): Likewise.
4862 (our_environ): New variable.
4863 (startup_with_shell): Likewise.
4864 (program_name): Likewise.
4865 (program_argv): Rename to...
4866 (program_args): ...this.
4867 (wrapper_argv): New variable.
4868 (start_inferior): Delete function.
4869 (get_exec_wrapper): New function.
4870 (get_exec_file): Likewise.
4871 (get_environ): Likewise.
4872 (prefork_hook): Likewise.
4873 (post_fork_inferior): Likewise.
4874 (postfork_hook): Likewise.
4875 (postfork_child_hook): Likewise.
4876 (handle_v_run): Update code to deal with arguments coming from the
4877 remote host. Update calls from "start_inferior" to
4879 (captured_main): Likewise. Initialize environment variable. Call
4881 * server.h (post_fork_inferior): New prototype.
4882 (get_environ): Likewise.
4883 (last_status): Declare.
4884 (last_ptid): Likewise.
4885 (signal_pid): Likewise.
4886 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
4887 (spu_ptrace_fun): New function.
4888 (spu_create_inferior): Adjust function prototype to reflect change
4889 on "target.h". Adjust function code to use "fork_inferior".
4890 * target.c (target_terminal_init): New function.
4891 (target_terminal_inferior): Likewise.
4892 (target_terminal_ours): Likewise.
4893 * target.h: Include <vector>.
4894 (struct target_ops) <create_inferior>: Update prototype.
4895 (create_inferior): Update macro.
4896 * utils.c (gdb_flush_out_err): New function.
4897 * win32-low.c (win32_create_inferior): Adjust function prototype
4898 and code to reflect change on "target.h".
4900 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4902 * inferiors.c (switch_to_thread): New function.
4904 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4906 * Makefile.in (SFILE): Add "common/job-control.c".
4907 (OBS): Add "job-control.o".
4909 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
4911 * Makefile: Remove "@host_makefile_frag@".
4913 2017-05-05 Pedro Alves <palves@redhat.com>
4915 * configure: Regenerate.
4917 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
4919 * configure: Regenerate.
4921 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
4923 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
4924 software_single_step change of return type to
4925 std::vector<CORE_ADDR>.
4926 * linux-low.c (install_software_single_step_breakpoints):
4928 * linux-low.h (install_software_single_step_breakpoints):
4931 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
4933 * remote-utils.c: Include "gdb_termios.h" instead of
4935 * terminal.h: Delete file.
4937 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
4939 * server.c: Include <vector>.
4940 <program_argv, wrapper_argv>: Convert to std::vector.
4941 (start_inferior): Rewrite function to use C++.
4942 (handle_v_run): Likewise. Update code that calculates the argv
4943 based on the vRun packet; use C++.
4944 (captured_main): Likewise.
4946 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
4948 * server.c (handle_v_cont): Initialize thread_resume::thread
4951 2017-04-05 Pedro Alves <palves@redhat.com>
4953 * configure: Regenerate.
4955 2017-04-05 Pedro Alves <palves@redhat.com>
4957 * gdbreplay.c (sync_error): Constify.
4958 * linux-x86-low.c (push_opcode): Constify.
4960 2017-04-05 Pedro Alves <palves@redhat.com>
4962 * win32-low.c (get_child_debug_event)
4963 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
4964 Report TARGET_WAITKIND_SPURIOUS instead.
4966 2017-04-05 Pedro Alves <palves@redhat.com>
4968 * remote-utils.c (remote_prepare, remote_open): Constify.
4969 * remote-utils.h (remote_prepare, remote_open): Constify.
4970 * server.c (captured_main): Constify 'port' handling.
4972 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
4974 * Makefile.in (clean): Clear .deps.
4976 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
4978 * .gitignore: Remove generated files, replace with wildcard.
4979 * (clean): Replace removal of generated files with wildcard.
4980 (version.c): Replace with...
4981 (version-generated.c): ...this.
4982 (xml-builtin.c): Replace with...
4983 (xml-builtin-generated.c): ...this.
4984 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
4985 (%.c: *regformats*): Replace with...
4986 (%-generated.c: *regformats*): ...this.
4988 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
4990 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
4991 (xtensa_fill_gregset): Call collect_register_by_name for
4993 (xtensa_store_gregset): Call supply_register_by_name for
4996 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
4998 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
4999 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
5000 (xtensa_store_gregset): Call supply_register for all registers in
5001 a0_regnum..a0_regnum + C0_NREGS range.
5003 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5005 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
5006 (ax-ipa.o: ax.c): Remove.
5007 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
5008 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
5009 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
5010 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
5011 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
5013 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5015 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
5016 (print-utils-ipa.o: ../common/print-utils.c): Remove.
5017 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
5018 (errors-ipa.o: ../common/errors.c): Remove.
5019 (format-ipa.o: ../common/format.c): Remove.
5020 (common-utils-ipa.o: ../common/common-utils.c): Remove.
5022 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5024 * Makefile.in (%-ipa.o: %.c): New rule.
5025 (tracepoint-ipa.o: tracepoint.c): Remove.
5026 (utils-ipa.o: utils.c): Remove.
5027 (remote-utils-ipa.o: remote-utils.c): Remove.
5028 (regcache-ipa.o: regcache.c): Remove.
5029 (i386-linux-ipa.o: i386-linux.c): Remove.
5030 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
5031 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
5032 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
5033 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
5034 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
5035 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
5036 (amd64-linux-ipa.o: amd64-linux.c): Remove.
5037 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
5038 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
5039 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
5040 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
5041 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
5042 (aarch64-ipa.o: aarch64.c): Remove.
5043 (s390-linux32-ipa.o: s390-linux32.c): Remove.
5044 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
5045 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
5046 (s390-linux64-ipa.o: s390-linux64.c): Remove.
5047 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
5048 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
5049 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
5050 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
5051 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
5052 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
5053 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
5054 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
5055 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
5056 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
5057 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
5058 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
5059 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
5060 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
5061 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
5062 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
5063 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
5064 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
5065 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
5066 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
5067 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
5068 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
5069 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
5070 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
5071 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
5072 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
5073 (tdesc-ipa.o: tdesc.c): Remove.
5074 (x32-linux-ipa.o: x32-linux.c): Remove.
5075 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
5076 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
5078 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5080 * Makefile.in (%.o: ../arch/%.c): New rule.
5081 (arm.o: ../arch/arm.c): Remove.
5082 (arm-linux.o: ../arch/arm-linux.c): Remove.
5083 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
5084 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
5086 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5088 * Makefile.in (%.o: ../nat/%.c): New rule.
5089 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
5090 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
5091 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
5092 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
5093 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
5094 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
5095 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
5096 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
5097 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
5098 (linux-personality.o: ../nat/linux-personality.c): Remove.
5099 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
5100 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
5101 (x86-linux.o: ../nat/x86-linux.c): Remove.
5102 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
5103 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
5105 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5107 * Makefile.in (%.o: ../common/%.c): New rule.
5108 (signals.o: ../common/signals.c): Remove.
5109 (print-utils.o: ../common/print-utils.c): Remove.
5110 (rsp-low.o: ../common/rsp-low.c): Remove.
5111 (common-utils.o: ../common/common-utils.c): Remove.
5112 (posix-strerror.o: ../common/posix-strerror.c): Remove.
5113 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
5114 (vec.o: ../common/vec.c): Remove.
5115 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
5116 (xml-utils.o: ../common/xml-utils.c): Remove.
5117 (ptid.o: ../common/ptid.c): Remove.
5118 (buffer.o: ../common/buffer.c): Remove.
5119 (format.o: ../common/format.c): Remove.
5120 (filestuff.o: ../common/filestuff.c): Remove.
5121 (agent.o: ../common/agent.c): Remove.
5122 (errors.o: ../common/errors.c): Remove.
5123 (environ.o: ../common/environ.c): Remove.
5124 (common-debug.o: ../common/common-debug.c): Remove.
5125 (cleanups.o: ../common/cleanups.c): Remove.
5126 (common-exceptions.o: ../common/common-exceptions.c): Remove.
5127 (fileio.o: ../common/fileio.c): Remove.
5128 (common-regcache.o: ../common/common-regcache.c): Remove.
5129 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
5130 (new-op.o: ../common/new-op.c): Remove.
5131 (btrace-common.o: ../common/btrace-common.c): Remove.
5133 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5135 * Makefile.in (%.o: ../target/%.c): New rule.
5136 (waitstatus.o: ../target/waitstatus.c): Remove.
5138 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5141 (%.c: ../regformats/%.dat,
5142 (%.c: ../regformats/arm/%.dat,
5143 (%.c: ../regformats/i386/%.dat,
5144 (%.c: ../regformats/rs6000/%.dat): New rules.
5145 (aarch64.c): Remove.
5146 (reg-arm.c): Remove.
5147 (arm-with-iwmmxt.c): Remove.
5148 (arm-with-vfpv2.c): Remove.
5149 (arm-with-vfpv3.c): Remove.
5150 (arm-with-neon.c): Remove.
5151 (reg-bfin.c): Remove.
5152 (reg-cris.c): Remove.
5153 (reg-crisv32.c): Remove.
5155 (i386-linux.c): Remove.
5156 (i386-avx.c): Remove.
5157 (i386-avx-linux.c): Remove.
5158 (i386-avx-avx512.c): Remove.
5159 (i386-avx-avx512-linux.c): Remove.
5160 (i386-mpx.c): Remove.
5161 (i386-mpx-linux.c): Remove.
5162 (i386-avx-mpx-avx512-pku.c): Remove.
5163 (i386-avx-mpx-avx512-pku-linux.c): Remove.
5164 (i386-avx-mpx.c): Remove.
5165 (i386-avx-mpx-linux.c): Remove.
5166 (i386-mmx.c): Remove.
5167 (i386-mmx-linux.c): Remove.
5168 (reg-ia64.c): Remove.
5169 (reg-m32r.c): Remove.
5170 (reg-m68k.c): Remove.
5172 (mips-linux.c): Remove.
5173 (mips-dsp-linux.c): Remove.
5174 (mips64-linux.c): Remove.
5175 (mips64-dsp-linux.c): Remove.
5176 (nios2-linux.c): Remove.
5177 (powerpc-32.c): Remove.
5178 (powerpc-32l.c): Remove.
5179 (powerpc-altivec32l.c): Remove.
5180 (powerpc-cell32l.c): Remove.
5181 (powerpc-vsx32l.c): Remove.
5182 (powerpc-isa205-32l.c): Remove.
5183 (powerpc-isa205-altivec32l.c): Remove.
5184 (powerpc-isa205-vsx32l.c): Remove.
5185 (powerpc-e500l.c): Remove.
5186 (powerpc-64l.c): Remove.
5187 (powerpc-altivec64l.c): Remove.
5188 (powerpc-cell64l.c): Remove.
5189 (powerpc-vsx64l.c): Remove.
5190 (powerpc-isa205-64l.c): Remove.
5191 (powerpc-isa205-altivec64l.c): Remove.
5192 (powerpc-isa205-vsx64l.c): Remove.
5193 (s390-linux32.c): Remove.
5194 (s390-linux32v1.c): Remove.
5195 (s390-linux32v2.c): Remove.
5196 (s390-linux64.c): Remove.
5197 (s390-linux64v1.c): Remove.
5198 (s390-linux64v2.c): Remove.
5199 (s390-te-linux64.c): Remove.
5200 (s390-vx-linux64.c): Remove.
5201 (s390-tevx-linux64.c): Remove.
5202 (s390x-linux64.c): Remove.
5203 (s390x-linux64v1.c): Remove.
5204 (s390x-linux64v2.c): Remove.
5205 (s390x-te-linux64.c): Remove.
5206 (s390x-vx-linux64.c): Remove.
5207 (s390x-tevx-linux64.c): Remove.
5208 (tic6x-c64xp-linux.c): Remove.
5209 (tic6x-c64x-linux.c): Remove.
5210 (tic6x-c62x-linux.c): Remove.
5212 (reg-sparc64.c): Remove.
5213 (reg-spu.c): Remove.
5215 (amd64-linux.c): Remove.
5216 (amd64-avx.c): Remove.
5217 (amd64-avx-linux.c): Remove.
5218 (amd64-avx-avx512.c): Remove.
5219 (amd64-avx-avx512-linux.c): Remove.
5220 (amd64-mpx.c): Remove.
5221 (amd64-mpx-linux.c): Remove.
5222 (amd64-avx-mpx-avx512-pku.c): Remove.
5223 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
5224 (amd64-avx-mpx.c): Remove.
5225 (amd64-avx-mpx-linux.c): Remove.
5227 (x32-linux.c): Remove.
5228 (x32-avx.c): Remove.
5229 (x32-avx-linux.c): Remove.
5230 (x32-avx-avx512.c): Remove.
5231 (x32-avx-avx512-linux.c): Remove.
5232 (reg-xtensa.c): Remove.
5233 (reg-tilegx.c): Remove.
5234 (reg-tilegx32.c): Remove.
5236 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
5238 * Makefile.in (SFILES): Add "common/environ.c".
5239 (OBJS): Add "common/environ.h".
5241 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
5243 * configure.ac: Check if the fs_base and gs_base members of
5244 `struct user_regs_struct' exist.
5245 * config.in: Regenerated.
5246 * configure: Likewise.
5248 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
5250 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
5252 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
5253 (get_next_pcs_syscall_next_pc): Likewise.
5255 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
5257 * win32-i386-low.c: Fix incorrect reference to a couple source files.
5258 * nto-x86-low.c: Likewise.
5260 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
5262 * Makefile.in: Include disable-implicit-rules.mk.
5264 2016-11-23 Pedro Alves <palves@redhat.com>
5266 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
5267 (debug_vprintf): Use std::chrono::steady_clock instead of
5268 gettimeofday. Use '.' instead of ':'.
5269 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
5270 (get_timestamp): Use std::chrono::steady_clock instead of
5273 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
5275 * Makefile.in: Fix whitespace formatting.
5277 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
5279 * Makefile.in (SFILES, OBS): Flatten list and order
5282 2016-11-23 Pedro Alves <palves@redhat.com>
5284 * event-loop.c (handle_file_event): Use warning.
5285 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
5286 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
5289 2016-11-23 Pedro Alves <palves@redhat.com>
5291 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
5293 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
5294 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
5295 debug_printf and debug_flush for debug output.
5296 * server.c (handle_general_set): Likewise.
5297 * thread-db.c (try_thread_db_load): Use debug_printf for debug
5300 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
5302 * Makefile.in (.c.o): Replace rule with ...
5303 (%.o: %.c): ... this one.
5305 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
5307 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
5308 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
5310 * configure.ac: Remove checks for the make program.
5311 * configure: Re-generate.
5313 2016-10-28 Pedro Alves <palves@redhat.com>
5315 * Makefile.in (CXX_DIALECT): Get from configure.
5316 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
5317 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
5318 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
5319 * config.in: Regenerate.
5320 * configure: Regenerate.
5322 2016-10-27 Yao Qi <yao.qi@linaro.org>
5324 * linux-low.c (linux_supports_range_stepping): Return true if
5325 can_software_single_step return true.
5327 2016-10-27 Yao Qi <yao.qi@linaro.org>
5329 * inferiors.c (find_inferior_in_random): New function.
5330 * inferiors.h (find_inferior_in_random): Declare.
5331 * linux-low.c (linux_wait_for_event_filtered): Call
5332 find_inferior_in_random instead of find_inferior.
5334 2016-10-27 Yao Qi <yao.qi@linaro.org>
5336 * linux-low.c (linux_wait_1): If single-step breakpoints are
5337 inserted, remove them.
5339 2016-10-26 Pedro Alves <palves@redhat.com>
5341 * linux-low.c (handle_extended_wait): Link parent/child fork
5343 (linux_wait_1): Unlink them.
5344 (linux_set_resume_request): Ignore resume requests for
5345 already-resumed and unhandled fork child threads.
5346 * linux-low.h (struct lwp_info) <fork_relative>: New field.
5347 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
5349 (handle_v_requests) <vCont>: Don't call require_running.
5350 * server.h (in_queued_stop_replies): New declaration.
5352 2016-10-24 Yao Qi <yao.qi@linaro.org>
5355 * linux-aarch64-low.c (append_insns): Cast the return value to
5358 2016-10-10 Yao Qi <yao.qi@linaro.org>
5360 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
5362 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
5364 * target.c (target_supports_multi_process): New function, moved
5366 * target.h (target_supports_multi_process): ... here. Remove
5369 2016-10-05 Tom Tromey <tom@tromey.com>
5372 * tracepoint.c (handle_tracepoint_bkpts): Check
5373 ipa_error_tracepoint, not ipa_stopping_tracepoint.
5375 2016-10-05 Yao Qi <yao.qi@linaro.org>
5377 * configure.srv: Update the path of arm-*.xml files.
5379 2016-10-05 Terry Guo <terry.guo@arm.com>
5380 Yao Qi <yao.qi@linaro.org>
5382 * Makefile.in: Adjust the path of rules.
5383 * configure.srv: Update the path of xml files.
5384 * regformats/arm-with-iwmmxt.dat: Regenerated.
5385 * regformats/arm-with-neon.dat: Likewise.
5386 * regformats/arm-with-vfpv2.dat: Likewise.
5387 * regformats/arm-with-vfpv3.dat Likewise.
5389 2016-09-30 Yao Qi <yao.qi@linaro.org>
5392 * target.c (target_stop_and_wait): Don't call
5393 target_continue_no_signal, use resume_stop instead.
5395 2016-09-26 Yao Qi <yao.qi@linaro.org>
5397 * linux-low.c (linux_wait_1): Call debug_exit.
5399 2016-09-23 Pedro Alves <palves@redhat.com>
5401 * Makefile.in (SFILES): Add common/new-op.c.
5402 (OBS): Add common/new-op.o.
5403 (new-op.o): New rule.
5405 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
5407 * .gitinore: Ignore more files.
5409 2016-09-21 Yao Qi <yao.qi@linaro.org>
5411 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
5414 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
5416 * server.c (start_inferior): Call target_mourn_inferior instead of
5417 mourn_inferior; pass ptid_t argument to it.
5419 (handle_target_event): Likewise.
5420 * target.c (target_mourn_inferior): New function.
5421 * target.h (mourn_inferior): Delete macro.
5423 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
5425 * linux-low.c (lwp_is_stepping): New function.
5427 2016-09-06 Carl Love <cel@us.ibm.com>
5429 * server.c (start_inferior): Fixed comment, requested comment change
5430 didn't get updated correctly. Removed reference to ptrace () call as
5431 it is only true on Linux systems.
5433 2016-09-06 Carl Love <cel@us.ibm.com>
5435 * server.c (start_inferior): Do not call
5436 function target_post_create_inferior () if the
5437 inferior process has already exited.
5439 2016-09-05 Pedro Alves <palves@redhat.com>
5441 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
5442 (COMPILE.pre, CC_LD): Use CXX directly.
5443 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
5444 * acinclude.m4: Don't include build-with-cxx.m4.
5445 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
5446 * configure: Regenerate.
5448 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
5451 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
5452 call writing data to own_buf.
5454 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
5456 * target.c (mywait): Call target_wait instead of
5458 (target_wait): New function.
5460 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
5462 * server.c (start_inferior): New variable 'ptid'. Replace calls
5463 to the_target->resume by target_continue{,_no_signal}, depending
5465 * target.c (target_stop_and_wait): Call target_continue_no_signal
5466 instead of the_target->resume.
5467 (target_continue): New function.
5469 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
5471 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
5473 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
5476 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
5478 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
5479 * linux-arm-low.c (ps_get_thread_area): Likewise.
5480 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
5481 * linux-m68k-low.c (ps_get_thread_area): Likewise.
5482 * linux-mips-low.c (ps_get_thread_area): Likewise.
5483 * linux-nios2-low.c (ps_get_thread_area): Likewise.
5484 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
5485 * linux-x86-low.c (ps_get_thread_area): Likewise.
5486 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
5488 2016-08-19 Pedro Alves <palves@redhat.com>
5490 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
5492 2016-08-19 Pedro Alves <palves@redhat.com>
5494 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
5495 comment. Use memcpy instead of casting through unsigned long.
5497 2016-08-19 Pedro Alves <palves@redhat.com>
5499 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
5500 allocating around 0x80000000.
5502 2016-08-19 Pedro Alves <palves@redhat.com>
5505 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
5506 (x32-avx512-linux-ipa.o): New rules.
5507 * configure.ac (x86_64-*-linux*): New x32 check.
5508 * configure.srv (ipa_x32_linux_regobj): New.
5509 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
5510 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
5512 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
5514 * configure: Regenerate.
5516 2016-08-09 Pedro Alves <palves@redhat.com>
5519 * Makefile.in (OBS): Add signals-state-save-restore.o.
5520 (signals-state-save-restore.o): New rule.
5521 * config.in: Regenerate.
5522 * configure: Regenerate.
5523 * linux-low.c: Include "signals-state-save-restore.h".
5524 (linux_create_inferior): Call
5525 restore_original_signals_state.
5526 * server.c: Include "dispositions-save-restore.h".
5527 (captured_main): Call save_original_signals_state.
5529 2016-08-05 Pedro Alves <palves@redhat.com>
5531 * configure: Regenerate.
5533 2016-08-04 Yao Qi <yao.qi@linaro.org>
5535 * linux-low.c (regsets_fetch_inferior_registers): Check
5536 errno is ESRCH or not.
5538 2016-08-02 Yao Qi <yao.qi@linaro.org>
5540 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
5541 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
5542 (thread_db_load_search): Update.
5543 (try_thread_db_load_1): Don't look for td_ta_event_addr,
5544 td_ta_set_event and td_ta_event_getmsg.
5546 2016-07-26 Pedro Alves <palves@redhat.com>
5549 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
5550 of unsigned long for 64-bit registers and use uint32_t instead of
5551 unsigned int for 32-bit registers.
5553 2016-07-26 Pedro Alves <palves@redhat.com>
5555 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
5558 2016-07-21 Tom Tromey <tom@tromey.com>
5560 * configure: Rebuild.
5562 2016-07-21 Yao Qi <yao.qi@linaro.org>
5564 * mem-break.c (find_gdb_breakpoint): Cast bp to
5565 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
5567 2016-07-21 Yao Qi <yao.qi@linaro.org>
5569 * server.c (handle_v_requests): Support s and S actions
5570 if target_supports_software_single_step return true.
5572 2016-07-21 Yao Qi <yao.qi@linaro.org>
5574 * linux-low.c (resume_stopped_resumed_lwps): If resume request
5575 is resume_step, call maybe_hw_step.
5576 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
5578 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
5580 (proceed_one_lwp): If resume request is resume_step, install
5581 reinsert breakpoints and call maybe_hw_step.
5583 2016-07-21 Yao Qi <yao.qi@linaro.org>
5585 * linux-low.c (proceed_one_lwp): Declare.
5586 (linux_resume_one_thread): Remove local variable 'step'.
5587 Lift code enqueue signal. Call proceed_one_lwp instead of
5588 linux_resume_one_lwp.
5590 2016-07-21 Yao Qi <yao.qi@linaro.org>
5592 * linux-low.c (linux_resume_one_thread): Call
5593 enqueue_pending_signal.
5595 2016-07-21 Yao Qi <yao.qi@linaro.org>
5597 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
5598 * inferiors.c (do_restore_current_thread_cleanup): New function.
5599 (make_cleanup_restore_current_thread): Likewise.
5600 * linux-low.c (install_software_single_step_breakpoints): Call
5601 make_cleanup_restore_current_thread. Switch current_thread to
5604 2016-07-21 Yao Qi <yao.qi@linaro.org>
5606 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
5607 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
5608 (clone_one_breakpoint): Likewise.
5609 (delete_reinsert_breakpoints): Change parameter to thread.
5611 (has_reinsert_breakpoints): Likewise.
5612 (uninsert_reinsert_breakpoints): Likewise.
5613 (reinsert_reinsert_breakpoints): Likewise.
5614 * mem-break.h (set_reinsert_breakpoint): Update declaration.
5615 (delete_reinsert_breakpoints): Likewise.
5616 (reinsert_reinsert_breakpoints): Likewise.
5617 (uninsert_reinsert_breakpoints): Likewise.
5618 (has_reinsert_breakpoints): Likewise.
5620 2016-07-21 Yao Qi <yao.qi@linaro.org>
5622 * inferiors.c (get_thread_process): Make parameter const.
5623 * inferiors.h (get_thread_process): Update declaration.
5624 * mem-break.c (clone_all_breakpoints): Remove all parameters.
5625 Add new parameters child_thread and parent_thread. Callers
5627 * mem-break.h (clone_all_breakpoints): Update declaration.
5629 2016-07-21 Yao Qi <yao.qi@linaro.org>
5631 * mem-break.c (struct breakpoint) <cond_list>: Remove.
5632 <command_list, handler>: Remove.
5633 (struct gdb_breakpoint): New.
5634 (struct other_breakpoint): New.
5635 (struct reinsert_breakpoint): New.
5636 (is_gdb_breakpoint): New function.
5637 (any_persistent_commands): Update command_list if
5638 is_gdb_breakpoint returns true.
5639 (set_breakpoint): Create breakpoints according to their types.
5640 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
5641 (set_gdb_breakpoint_1): Likewise.
5642 (set_gdb_breakpoint): Likewise.
5643 (clear_breakpoint_conditions): Change parameter type to
5644 'struct gdb_breakpoint *'.
5645 (clear_breakpoint_commands): Likewise.
5646 (clear_breakpoint_conditions_and_commands): Likewise.
5647 (add_condition_to_breakpoint): Likewise.
5648 (add_breakpoint_condition): Likewise.
5649 (add_commands_to_breakpoint): Likewise.
5650 (check_breakpoints): Check other_breakpoint.
5651 (clone_one_breakpoint): Clone breakpopint according to its type.
5652 * mem-break.h (struct gdb_breakpoint): Declare.
5653 (set_gdb_breakpoint): Update declaration.
5654 (clear_breakpoint_conditions_and_commands): Likewise.
5655 (add_breakpoint_condition): Likewise.
5656 (add_breakpoint_commands): Likewise.
5657 * server.c (process_point_options): Change parameter type to
5658 'struct gdb_breakpoint *'.
5660 2016-07-21 Yao Qi <yao.qi@linaro.org>
5662 * mem-break.c (set_breakpoint_at): Rename it to ...
5663 (set_breakpoint_type_at): ... it.
5664 (set_breakpoint_at): Call set_breakpoint_type_at.
5665 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
5666 * mem-break.h (set_breakpoint_at): Update comments.
5668 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
5670 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
5672 (nios2_store_gregset): Likewise.
5674 2016-07-01 Pedro Alves <palves@redhat.com>
5675 Antoine Tremblay <antoine.tremblay@ericsson.com>
5677 * linux-low.c: Change interface to take the target lwp_info
5678 pointer directly and return void. Handle detaching from a zombie
5680 (linux_detach_lwp_callback): New function.
5681 (linux_detach): Detach from the leader thread after detaching from
5684 2016-06-28 Yao Qi <yao.qi@linaro.org>
5686 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
5687 for variable new_offset.
5688 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
5689 (aarch64_ftrace_insn_reloc_cb): Likewise.
5690 (aarch64_ftrace_insn_reloc_tb): Likewise.
5691 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
5692 PRIx64 instead of PRIx32.
5694 2016-06-28 Yao Qi <yao.qi@linaro.org>
5696 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
5697 (the_low_target): Install arm_get_syscall_trapinfo.
5699 2016-06-28 Yao Qi <yao.qi@linaro.org>
5701 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
5703 (the_low_target): Install aarch64_get_syscall_trapinfo.
5705 2016-06-28 Yao Qi <yao.qi@linaro.org>
5707 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
5709 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
5710 Remove parameter sysno.
5711 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
5714 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5716 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
5717 (s390_emit_ne_goto): Likewise.
5718 (s390_emit_lt_goto): Likewise.
5719 (s390_emit_le_goto): Likewise.
5720 (s390_emit_gt_goto): Likewise.
5721 (s390_emit_ge_goto): Likewise.
5722 (s390x_emit_eq_goto): Likewise.
5723 (s390x_emit_ne_goto): Likewise.
5724 (s390x_emit_lt_goto): Likewise.
5725 (s390x_emit_le_goto): Likewise.
5726 (s390x_emit_gt_goto): Likewise.
5727 (s390x_emit_ge_goto): Likewise.
5728 (s390_emit_ops_impl): Mark variable static.
5729 (s390x_emit_ops): Likewise.
5731 2016-06-17 Yao Qi <yao.qi@linaro.org>
5733 * linux-low.c (handle_extended_wait): Call
5734 uninsert_reinsert_breakpoints for the parent process. Remove
5735 reinsert breakpoints from the child process. Reinsert them to
5736 the parent process when vfork is done.
5737 * mem-break.c (uninsert_reinsert_breakpoints): New function.
5738 (reinsert_reinsert_breakpoints): New function.
5739 * mem-break.h (uninsert_reinsert_breakpoints): Declare
5740 (reinsert_reinsert_breakpoints): Declare.
5742 2016-06-17 Yao Qi <yao.qi@linaro.org>
5744 * linux-low.c (handle_extended_wait): If the parent is doing
5745 step-over, remove the reinsert breakpoints from the forked child.
5747 2016-06-17 Yao Qi <yao.qi@linaro.org>
5749 * linux-low.c (unsuspend_all_lwps): Declare.
5750 (linux_low_filter_event): If thread exited, call finish_step_over.
5751 If step-over is finished, unsuspend other threads.
5753 2016-06-17 Yao Qi <yao.qi@linaro.org>
5755 * linux-low.c (linux_resume_one_lwp_throw): Assert
5756 has_reinsert_breakpoints returns false.
5757 * mem-break.c (delete_disabled_breakpoints): Assert
5758 bp type isn't reinsert_breakpoint.
5760 2016-06-17 Yao Qi <yao.qi@linaro.org>
5762 * linux-low.c (maybe_hw_step): New function.
5763 (linux_resume_one_lwp_throw): Call maybe_hw_step.
5764 (finish_step_over): Switch current_thread to lwp temporarily,
5765 and assert has_reinsert_breakpoints returns true.
5766 (proceed_one_lwp): Call maybe_hw_step.
5767 * mem-break.c (has_reinsert_breakpoints): New function.
5768 * mem-break.h (has_reinsert_breakpoints): Declare.
5770 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
5772 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
5774 2016-05-17 Yao Qi <yao.qi@linaro.org>
5776 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
5777 instead of find_inferior.
5779 2016-05-05 Yao Qi <yao.qi@linaro.org>
5781 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
5782 Initialize res to zero.
5784 2016-05-05 Yao Qi <yao.qi@linaro.org>
5786 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
5789 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
5791 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
5792 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
5793 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
5795 2016-04-28 Par Olsson <par.olsson@windriver.com>
5796 Simon Marchi <simon.marchi@ericsson.com>
5798 * tracepoint.c (write_inferior_int8): New function.
5799 (cmd_qtenable_disable): Write enable flag using
5800 write_inferior_int8.
5802 2016-04-25 Yao Qi <yao.qi@linaro.org>
5804 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
5805 (need_step_over_p): Return zero if the LWP has pending signals
5806 can be delivered on software single step target.
5808 2016-04-25 Yao Qi <yao.qi@linaro.org>
5810 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
5811 return instead of error.
5813 2016-04-22 Yao Qi <yao.qi@linaro.org>
5815 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
5818 2016-04-22 Yao Qi <yao.qi@linaro.org>
5820 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
5821 signal when stepping over breakpoint with software single
5824 2016-04-21 Pedro Alves <palves@redhat.com>
5826 * linux-s390-low.c (s390_collect_ptrace_register)
5827 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
5829 (s390_check_regset): Use void * instead of gdb_byte *.
5831 2016-04-20 Pedro Alves <palves@redhat.com>
5833 * configure: Renegerate.
5835 2016-04-20 Yao Qi <yao.qi@linaro.org>
5837 * linux-aarch32-low.c: Include "arch/arm-linux.h".
5838 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
5840 (arm_store_gregset): Likewise.
5842 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
5844 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
5845 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
5846 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
5847 (amd64-avx-mpx-linux.c): New rules.
5848 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
5849 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
5850 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
5851 (srv_amd64_regobj): Add amd64-avx-mpx.o.
5852 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
5853 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
5854 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
5855 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
5856 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
5857 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
5858 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
5859 * linux-x86-low.c (x86_linux_read_description): Add case for
5860 X86_XSTATE_AVX_MPX_MASK.
5861 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
5862 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
5863 init_registers_i386_avx_mpx_linux.
5864 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
5865 (initialize_low_tracepoint): Call
5866 init_registers_i386_avx_mpx_linux.
5867 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
5868 (initialize_low_tracepoint): Call
5869 init_registers_amd64_avx_mpx_linux.
5870 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
5871 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
5872 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
5875 2016-04-18 Pedro Alves <palves@redhat.com>
5877 * configure: Regenerate.
5879 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
5881 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
5882 (aarch64_emit_sub): Likewise.
5884 2016-04-12 Pedro Alves <palves@redhat.com>
5886 * utils.c (prepare_to_throw_exception): Delete.
5888 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
5890 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
5892 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
5894 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
5896 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
5898 * linux-aarch64-ipa.c: Add <elf.h> include.
5899 * linux-ppc-ipa.c: Add <elf.h> include.
5900 * linux-s390-ipa.c: Add <elf.h> include.
5902 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
5904 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
5905 (get_raw_reg_ptr): Likewise.
5906 (get_trace_state_variable_value_ptr): Likewise.
5907 (set_trace_state_variable_value_ptr): Likewise.
5908 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
5911 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
5912 Marcin Kościelnicki <koriakin@0x04.net>
5915 * linux-ppc-low.c (emit_insns): New function.
5916 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
5917 (ppc_emit_prologue): New function.
5918 (ppc_emit_epilogue): New function.
5919 (ppc_emit_add): New function.
5920 (ppc_emit_sub): New function.
5921 (ppc_emit_mul): New function.
5922 (ppc_emit_lsh): New function.
5923 (ppc_emit_rsh_signed): New function.
5924 (ppc_emit_rsh_unsigned): New function.
5925 (ppc_emit_ext): New function.
5926 (ppc_emit_zero_ext): New function.
5927 (ppc_emit_log_not): New function.
5928 (ppc_emit_bit_and): New function.
5929 (ppc_emit_bit_or): New function.
5930 (ppc_emit_bit_xor): New function.
5931 (ppc_emit_bit_not): New function.
5932 (ppc_emit_equal): New function.
5933 (ppc_emit_less_signed): New function.
5934 (ppc_emit_less_unsigned): New function.
5935 (ppc_emit_ref): New function.
5936 (ppc_emit_const): New function.
5937 (ppc_emit_reg): New function.
5938 (ppc_emit_pop): New function.
5939 (ppc_emit_stack_flush): New function.
5940 (ppc_emit_swap): New function.
5941 (ppc_emit_stack_adjust): New function.
5942 (ppc_emit_call): New function.
5943 (ppc_emit_int_call_1): New function.
5944 (ppc_emit_void_call_2): New function.
5945 (ppc_emit_if_goto): New function.
5946 (ppc_emit_goto): New function.
5947 (ppc_emit_eq_goto): New function.
5948 (ppc_emit_ne_goto): New function.
5949 (ppc_emit_lt_goto): New function.
5950 (ppc_emit_le_goto): New function.
5951 (ppc_emit_gt_goto): New function.
5952 (ppc_emit_ge_goto): New function.
5953 (ppc_write_goto_address): New function.
5954 (ppc_emit_ops_impl): New static variable.
5955 (ppc64v1_emit_prologue): New function.
5956 (ppc64v2_emit_prologue): New function.
5957 (ppc64_emit_epilogue): New function.
5958 (ppc64_emit_add): New function.
5959 (ppc64_emit_sub): New function.
5960 (ppc64_emit_mul): New function.
5961 (ppc64_emit_lsh): New function.
5962 (ppc64_emit_rsh_signed): New function.
5963 (ppc64_emit_rsh_unsigned): New function.
5964 (ppc64_emit_ext): New function.
5965 (ppc64_emit_zero_ext): New function.
5966 (ppc64_emit_log_not): New function.
5967 (ppc64_emit_bit_and): New function.
5968 (ppc64_emit_bit_or): New function.
5969 (ppc64_emit_bit_xor): New function.
5970 (ppc64_emit_bit_not): New function.
5971 (ppc64_emit_equal): New function.
5972 (ppc64_emit_less_signed): New function.
5973 (ppc64_emit_less_unsigned): New function.
5974 (ppc64_emit_ref): New function.
5975 (ppc64_emit_const): New function.
5976 (ppc64v1_emit_reg): New function.
5977 (ppc64v2_emit_reg): New function.
5978 (ppc64_emit_pop): New function.
5979 (ppc64_emit_stack_flush): New function.
5980 (ppc64_emit_swap): New function.
5981 (ppc64v1_emit_call): New function.
5982 (ppc64v2_emit_call): New function.
5983 (ppc64v1_emit_int_call_1): New function.
5984 (ppc64v2_emit_int_call_1): New function.
5985 (ppc64v1_emit_void_call_2): New function.
5986 (ppc64v2_emit_void_call_2): New function.
5987 (ppc64_emit_if_goto): New function.
5988 (ppc64_emit_eq_goto): New function.
5989 (ppc64_emit_ne_goto): New function.
5990 (ppc64_emit_lt_goto): New function.
5991 (ppc64_emit_le_goto): New function.
5992 (ppc64_emit_gt_goto): New function.
5993 (ppc64_emit_ge_goto): New function.
5994 (ppc64v1_emit_ops_impl): New static variable.
5995 (ppc64v2_emit_ops_impl): New static variable.
5996 (ppc_emit_ops): New function.
5997 (linux_low_target): Wire in ppc_emit_ops.
5999 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
6000 Marcin Kościelnicki <koriakin@0x04.net>
6003 * Makefile.in: Add powerpc-*-ipa.o
6004 * configure.srv: Add ipa_obj for powerpc*-linux.
6005 * linux-ppc-ipa.c: New file.
6006 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
6008 (PPC_FIELD): New macro.
6009 (PPC_SEXT): New macro.
6010 (PPC_OP6): New macro.
6011 (PPC_BO): New macro.
6012 (PPC_LI): New macro.
6013 (PPC_BD): New macro.
6014 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
6015 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
6016 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
6017 (ppc_get_thread_area): New function.
6018 (is_elfv2_inferior): New function.
6019 (gen_ds_form): New function.
6020 (GEN_STD): New macro.
6021 (GEN_STDU): New macro.
6022 (GEN_LD): New macro.
6023 (GEN_LDU): New macro.
6024 (gen_d_form): New function.
6025 (GEN_ADDI): New macro.
6026 (GEN_ADDIS): New macro.
6027 (GEN_LI): New macro.
6028 (GEN_LIS): New macro.
6029 (GEN_ORI): New macro.
6030 (GEN_ORIS): New macro.
6031 (GEN_LWZ): New macro.
6032 (GEN_STW): New macro.
6033 (GEN_STWU): New macro.
6034 (gen_xfx_form): New function.
6035 (GEN_MFSPR): New macro.
6036 (GEN_MTSPR): New macro.
6037 (GEN_MFCR): New macro.
6038 (GEN_MTCR): New macro.
6039 (GEN_SYNC): New macro.
6040 (GEN_LWSYNC): New macro.
6041 (gen_x_form): New function.
6042 (GEN_OR): New macro.
6043 (GEN_MR): New macro.
6044 (GEN_LWARX): New macro.
6045 (GEN_STWCX): New macro.
6046 (GEN_CMPW): New macro.
6047 (gen_md_form): New function.
6048 (GEN_RLDICL): New macro.
6049 (GEN_RLDICR): New macro.
6050 (gen_i_form): New function.
6052 (GEN_BL): New macro.
6053 (gen_b_form): New function.
6054 (GEN_BNE): New macro.
6055 (GEN_LOAD): New macro.
6056 (GEN_STORE): New macro.
6057 (gen_limm): New function.
6058 (gen_atomic_xchg): New function.
6059 (gen_call): New function.
6060 (ppc_relocate_instruction): New function.
6061 (ppc_install_fast_tracepoint_jump_pad): New function.
6062 (ppc_get_min_fast_tracepoint_insn_len): New function.
6063 (ppc_get_ipa_tdesc_idx): New function.
6064 (the_low_target): Wire in the new functions.
6065 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
6067 * linux-ppc-tdesc.h: New file.
6069 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
6071 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
6072 (alloc_jump_pad_buffer): New function.
6073 * linux-amd64-ipa.c: Add <sys/mman.h> include.
6074 (alloc_jump_pad_buffer): New function.
6075 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
6076 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
6077 (alloc_jump_pad_buffer): New function.
6078 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
6079 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
6080 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
6081 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
6083 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
6085 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
6086 * linux-amd64-ipa.c: Likewise.
6087 * linux-i386-ipa.c: Likewise.
6088 * linux-s390-ipa.c: Likewise.
6089 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
6090 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
6091 set_trace_state_variable_value_ptr.
6092 (struct ipa_sym_addresses): Likewise.
6093 (symbol_list): Likewise.
6094 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
6095 accessing gdb_collect directly.
6096 (gdb_collect_ptr_type): New typedef.
6097 (get_raw_reg_ptr_type): New typedef.
6098 (get_trace_state_variable_value_ptr_type): New typedef.
6099 (set_trace_state_variable_value_ptr_type): New typedef.
6100 (gdb_collect_ptr): New global.
6101 (get_raw_reg_ptr): New global.
6102 (get_trace_state_variable_value_ptr): New global.
6103 (set_trace_state_variable_value_ptr): New global.
6104 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
6105 accessing get_raw_reg directly.
6106 (get_get_tsv_func_addr): Likewise for
6107 get_trace_state_variable_value_ptr.
6108 (get_set_tsv_func_addr): Likewise for
6109 set_trace_state_variable_value_ptr.
6110 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
6112 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
6114 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
6116 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
6118 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
6120 (relocate_instruction): Remove own_buf.
6121 * server.c (own_buf): Make global.
6122 (handle_v_requests): Make global.
6123 * server.h (own_buf): New declaration.
6124 (handle_v_requests): New prototype.
6126 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
6129 * linux-s390-low.c (add_insns): New function.
6130 (s390_emit_prologue): New function.
6131 (s390_emit_epilogue): New function.
6132 (s390_emit_add): New function.
6133 (s390_emit_sub): New function.
6134 (s390_emit_mul): New function.
6135 (s390_emit_lsh): New function.
6136 (s390_emit_rsh_signed): New function.
6137 (s390_emit_rsh_unsigned): New function.
6138 (s390_emit_ext): New function.
6139 (s390_emit_log_not): New function.
6140 (s390_emit_bit_and): New function.
6141 (s390_emit_bit_or): New function.
6142 (s390_emit_bit_xor): New function.
6143 (s390_emit_bit_not): New function.
6144 (s390_emit_equal): New function.
6145 (s390_emit_less_signed): New function.
6146 (s390_emit_less_unsigned): New function.
6147 (s390_emit_ref): New function.
6148 (s390_emit_if_goto): New function.
6149 (s390_emit_goto): New function.
6150 (s390_write_goto_address): New function.
6151 (s390_emit_litpool): New function.
6152 (s390_emit_const): New function.
6153 (s390_emit_call): New function.
6154 (s390_emit_reg): New function.
6155 (s390_emit_pop): New function.
6156 (s390_emit_stack_flush): New function.
6157 (s390_emit_zero_ext): New function.
6158 (s390_emit_swap): New function.
6159 (s390_emit_stack_adjust): New function.
6160 (s390_emit_set_r2): New function.
6161 (s390_emit_int_call_1): New function.
6162 (s390_emit_void_call_2): New function.
6163 (s390_emit_eq_goto): New function.
6164 (s390_emit_ne_goto): New function.
6165 (s390_emit_lt_goto): New function.
6166 (s390_emit_le_goto): New function.
6167 (s390_emit_gt_goto): New function.
6168 (s390_emit_ge_goto): New function.
6169 (s390x_emit_prologue): New function.
6170 (s390x_emit_epilogue): New function.
6171 (s390x_emit_add): New function.
6172 (s390x_emit_sub): New function.
6173 (s390x_emit_mul): New function.
6174 (s390x_emit_lsh): New function.
6175 (s390x_emit_rsh_signed): New function.
6176 (s390x_emit_rsh_unsigned): New function.
6177 (s390x_emit_ext): New function.
6178 (s390x_emit_log_not): New function.
6179 (s390x_emit_bit_and): New function.
6180 (s390x_emit_bit_or): New function.
6181 (s390x_emit_bit_xor): New function.
6182 (s390x_emit_bit_not): New function.
6183 (s390x_emit_equal): New function.
6184 (s390x_emit_less_signed): New function.
6185 (s390x_emit_less_unsigned): New function.
6186 (s390x_emit_ref): New function.
6187 (s390x_emit_if_goto): New function.
6188 (s390x_emit_const): New function.
6189 (s390x_emit_call): New function.
6190 (s390x_emit_reg): New function.
6191 (s390x_emit_pop): New function.
6192 (s390x_emit_stack_flush): New function.
6193 (s390x_emit_zero_ext): New function.
6194 (s390x_emit_swap): New function.
6195 (s390x_emit_stack_adjust): New function.
6196 (s390x_emit_int_call_1): New function.
6197 (s390x_emit_void_call_2): New function.
6198 (s390x_emit_eq_goto): New function.
6199 (s390x_emit_ne_goto): New function.
6200 (s390x_emit_lt_goto): New function.
6201 (s390x_emit_le_goto): New function.
6202 (s390x_emit_gt_goto): New function.
6203 (s390x_emit_ge_goto): New function.
6204 (s390_emit_ops): New function.
6205 (struct linux_target_ops): Fill in emit_ops hook.
6207 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
6210 * Makefile.in: Add s390 IPA files.
6211 * configure.srv: Build IPA for s390.
6212 * linux-s390-ipa.c: New file.
6213 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
6214 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
6215 (tdesc_s390_linux32): Likewise.
6216 (init_registers_s390_linux32v1): Likewise.
6217 (tdesc_s390_linux32v1): Likewise.
6218 (init_registers_s390_linux32v2): Likewise.
6219 (tdesc_s390_linux32v2): Likewise.
6220 (init_registers_s390_linux64): Likewise.
6221 (tdesc_s390_linux64): Likewise.
6222 (init_registers_s390_linux64v1): Likewise.
6223 (tdesc_s390_linux64v1): Likewise.
6224 (init_registers_s390_linux64v2): Likewise.
6225 (tdesc_s390_linux64v2): Likewise.
6226 (init_registers_s390_te_linux64): Likewise.
6227 (tdesc_s390_te_linux64): Likewise.
6228 (init_registers_s390_vx_linux64): Likewise.
6229 (tdesc_s390_vx_linux64): Likewise.
6230 (init_registers_s390_tevx_linux64): Likewise.
6231 (tdesc_s390_tevx_linux64): Likewise.
6232 (init_registers_s390x_linux64): Likewise.
6233 (tdesc_s390x_linux64): Likewise.
6234 (init_registers_s390x_linux64v1): Likewise.
6235 (tdesc_s390x_linux64v1): Likewise.
6236 (init_registers_s390x_linux64v2): Likewise.
6237 (tdesc_s390x_linux64v2): Likewise.
6238 (init_registers_s390x_te_linux64): Likewise.
6239 (tdesc_s390x_te_linux64): Likewise.
6240 (init_registers_s390x_vx_linux64): Likewise.
6241 (tdesc_s390x_vx_linux64): Likewise.
6242 (init_registers_s390x_tevx_linux64): Likewise.
6243 (tdesc_s390x_tevx_linux64): Likewise.
6244 (have_hwcap_s390_vx): New static variable.
6245 (s390_arch_setup): Fill have_hwcap_s390_vx.
6246 (s390_get_thread_area): New function.
6247 (s390_ft_entry_gpr_esa): New const.
6248 (s390_ft_entry_gpr_zarch): New const.
6249 (s390_ft_entry_misc): New const.
6250 (s390_ft_entry_fr): New const.
6251 (s390_ft_entry_vr): New const.
6252 (s390_ft_main_31): New const.
6253 (s390_ft_main_64): New const.
6254 (s390_ft_exit_fr): New const.
6255 (s390_ft_exit_vr): New const.
6256 (s390_ft_exit_misc): New const.
6257 (s390_ft_exit_gpr_esa): New const.
6258 (s390_ft_exit_gpr_zarch): New const.
6259 (append_insns): New function.
6260 (s390_relocate_instruction): New function.
6261 (s390_install_fast_tracepoint_jump_pad): New function.
6262 (s390_get_min_fast_tracepoint_insn_len): New function.
6263 (s390_get_ipa_tdesc_idx): New function.
6264 (struct linux_target_ops): Wire in the above functions.
6265 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
6266 * linux-s390-tdesc.h: New file.
6268 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
6270 * linux-s390-low.c (s390_supports_tracepoints): New function.
6271 (struct linux_target_ops): Fill supports_tracepoints hook.
6273 2016-03-18 Yao Qi <yao.qi@linaro.org>
6275 * linux-low.c (lwp_signal_can_be_delivered): New function.
6276 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
6278 2016-03-18 Yao Qi <yao.qi@linaro.org>
6280 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
6281 0 if signal is enqueued. Remove 'signal' from one debugging
6282 message. Move one debugging message to some lines below.
6283 Remove code setting 'signal' to 0.
6285 2016-03-18 Yao Qi <yao.qi@linaro.org>
6287 * linux-low.c (linux_low_filter_event): Remove redundant
6288 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
6290 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
6292 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
6293 (struct linux_target_ops): Wire in the above.
6295 2016-03-03 Yao Qi <yao.qi@linaro.org>
6297 * linux-low.c: Update comments to start_step_over.
6299 2016-03-03 Yao Qi <yao.qi@linaro.org>
6302 * linux-low.c (handle_extended_wait): Set child suspended
6303 if event_lwp->bp_reinsert isn't zero.
6305 2016-03-02 Yao Qi <yao.qi@linaro.org>
6307 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
6308 enqueue_pending_signal.
6310 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
6312 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
6315 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
6317 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
6318 (s390_regmap_3264) [!__s390x__]: New global.
6319 (s390_collect_ptrace_register): Skip map entries containing -1.
6320 (s390_supply_ptrace_register): Ditto.
6321 (s390_fill_gprs_high): New function.
6322 (s390_store_gprs_high): New function.
6323 (s390_regsets): Add NT_S390_HIGH_GPRS.
6324 (s390_get_hwcap): Enable on 31-bit.
6325 (have_hwcap_s390_high_gprs): Enable on 31-bit.
6326 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
6327 Detect NT_S390_HIGH_GPRS.
6328 (s390_usrregs_info_3264): Enable on 31-bit.
6329 (s390_regs_info): Enable regs_info_3264 on 31-bit.
6330 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
6332 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
6335 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
6336 * configure.srv: Ditto.
6337 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
6338 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
6339 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
6340 (init_registers_amd64_linux): Remove prototype.
6341 (tdesc_amd64_linux): Remove declaration.
6342 (get_ipa_tdesc): New function.
6343 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
6344 initialize remaining tdescs.
6345 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
6346 (init_registers_i386_linux): Remove prototype.
6347 (tdesc_i386_linux): Remove declaration.
6348 (get_ipa_tdesc): New function.
6349 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
6350 initialize remaining tdescs.
6351 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
6352 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
6353 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
6354 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
6355 (x86_get_ipa_tdesc_idx): New function.
6356 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
6357 * linux-x86-tdesc.h: New file.
6358 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
6359 (target_get_ipa_tdesc_idx): New macro.
6360 * tracepoint.c (ipa_tdesc_idx): New macro.
6361 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
6362 (symbol_list): Add ipa_tdesc_idx.
6363 (cmd_qtstart): Write ipa_tdesc_idx in the target.
6364 (ipa_tdesc): Remove.
6365 (ipa_tdesc_idx): New variable.
6366 (get_context_regcache): Use get_ipa_tdesc.
6367 (gdb_collect): Ditto.
6369 * tracepoint.h (get_ipa_tdesc): New prototype.
6370 (ipa_tdesc): Remove.
6372 2016-02-24 Pedro Alves <palves@redhat.com>
6374 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
6375 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
6376 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
6377 Factor out common code between the USE_SIGTRAP_SIGINFO and
6378 !USE_SIGTRAP_SIGINFO blocks.
6379 (linux_low_filter_event): Call save_stop_reason instead of
6380 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
6382 (linux_wait_1): Update comments.
6384 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
6386 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
6387 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
6388 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
6389 ppc_insert_point, ppc_remove_point.
6391 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
6393 * linux-s390-low.c (s390_supports_z_point_type): New function.
6394 (struct linux_target_ops): Wire s390_supports_z_point_type in.
6396 2016-02-16 Yao Qi <yao.qi@linaro.org>
6398 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
6399 PC. Get pc from regcache_read_pc.
6401 2016-02-12 Yao Qi <yao.qi@linaro.org>
6403 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
6404 or linux_get_pc_32bit.
6405 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
6407 2016-02-12 Yao Qi <yao.qi@linaro.org>
6409 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
6410 arm_linux_get_next_pcs_fixup.
6412 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
6414 * tracepoint.c (x_tracepoint_action_download): Change
6415 write_inferior_data_ptr to write_inferior_data_pointer.
6416 (cmd_qtstart): Likewise.
6417 (write_inferior_data_ptr): Remove.
6418 (download_agent_expr): Change write_inferior_data_ptr to
6419 write_inferior_data_pointer.
6420 (download_tracepoint_1): Likewise.
6421 (download_tracepoint): Likewise.
6422 (download_trace_state_variables): Likewise.
6424 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
6425 Marcin Kościelnicki <koriakin@0x04.net>
6427 * tracepoint.c (struct tracepoint_action_ops): Remove.
6428 (struct tracepoint_action): Remove ops.
6429 (m_tracepoint_action_download, r_tracepoint_action_download)
6430 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
6431 size and offset accordingly.
6432 (m_tracepoint_action_ops, r_tracepoint_action_ops)
6433 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
6434 (tracepoint_action_send, tracepoint_action_download): New functions.
6435 Helpers for trace action handlers.
6436 (add_tracepoint_action): Remove setup actions ops.
6437 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
6439 2016-02-10 Yao Qi <yao.qi@linaro.org>
6441 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
6443 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
6445 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
6447 * configure: Regenerate.
6449 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
6451 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
6452 void * to gdb_byte *.
6453 * linux-low.c (siginfo_fixup): Likewise.
6454 (linux_xfer_siginfo): Likewise.
6455 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
6457 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
6459 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
6461 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
6463 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
6465 * linux-x86-low.c [__x86_64__]: Include
6466 "nat/amd64-linux-siginfo.h".
6467 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
6468 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
6469 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
6470 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
6471 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
6472 (cpt_si_fd, si_timerid, si_overrun): Move from
6473 nat/amd64-linux-siginfo.c.
6474 * Makefile.in (amd64-linux-siginfo.o:): New rule.
6476 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
6478 * server.c (skip_to_semicolon): Remove.
6479 (process_point_options): Use strchrnul instead of
6482 2016-01-26 Yao Qi <yao.qi@linaro.org>
6484 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
6485 * linux-low.c (install_software_single_step_breakpoints): Don't
6486 call regcache_read_pc.
6487 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
6490 2016-01-26 Yao Qi <yao.qi@linaro.org>
6492 * linux-low.c (install_software_single_step_breakpoints): Call
6493 regcache_read_pc instead of get_pc.
6495 2016-01-26 Yao Qi <yao.qi@linaro.org>
6497 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
6498 (unblock_async_io): Rename to ...
6499 (block_unblock_async_io): ... it. New function.
6500 (enable_async_io): Don't install SIGIO handler. Unblock it
6502 (disable_async_io): Don't ignore SIGIO. Block it instead.
6503 (initialize_async_io): Install SIGIO handler. Don't call
6506 2016-01-26 Yao Qi <yao.qi@linaro.org>
6508 * remote-utils.c (getpkt): If the buffer isn't empty, and the
6509 first character is '\003', call *the_target->request_interrupt.
6511 2016-01-25 Yao Qi <yao.qi@linaro.org>
6513 * remote-utils.c (new_thread_notify): Remove.
6514 (dead_thread_notify): Likewise.
6515 * remote-utils.h (new_thread_notify): Remove declaration.
6516 (dead_thread_notify): Likewise.
6518 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
6520 * gdb.trace/pending.exp: Fix expected message on continue.
6522 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
6524 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
6525 it works properly on big-endian machines where sizeof (CORE_ADDR)
6528 2016-01-21 Pedro Alves <palves@redhat.com>
6530 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
6531 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
6532 * configure: Regenerate.
6534 2016-01-21 Yao Qi <yao.qi@linaro.org>
6536 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
6537 is_thumb and set it according to CPSR saved on the stack.
6538 (get_next_pcs_syscall_next_pc): Pass is_thumb to
6539 arm_sigreturn_next_pc.
6541 2016-01-18 Yao Qi <yao.qi@linaro.org>
6543 * linux-low.c (linux_set_pc_64bit): New function.
6544 (linux_get_pc_64bit): New function.
6545 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
6547 * linux-sparc-low.c (debug_threads): Remove declaration.
6548 (sparc_get_pc): Remove.
6549 (the_low_target): Use linux_get_pc_64bit instead of
6551 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
6552 (the_low_target): Use linux_get_pc_64bit and
6555 2016-01-18 Yao Qi <yao.qi@linaro.org>
6557 * linux-arm-low.c (debug_threads): Remove declaration.
6558 (arm_get_pc, arm_set_pc): Remove.
6559 (the_low_target): Use linux_get_pc_32bit and
6561 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
6562 (the_low_target): Use linux_get_pc_32bit and
6564 * linux-cris-low.c (debug_threads): Remove declaration.
6565 (cris_get_pc, cris_set_pc,): Remove.
6566 (the_low_target): Use linux_get_pc_32bit and
6568 * linux-crisv32-low.c (debug_threads): Remove declaration.
6569 (cris_get_pc, cris_set_pc): Remove.
6570 (the_low_target): Use linux_get_pc_32bit and
6572 * linux-low.c: Include inttypes.h.
6573 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
6574 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
6575 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
6576 (the_low_target): Use linux_get_pc_32bit and
6578 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
6579 (the_low_target): Use linux_get_pc_32bit and
6581 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
6582 (the_low_target): Use linux_get_pc_32bit and
6584 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
6585 (the_low_target): Use linux_get_pc_32bit and
6587 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
6588 (the_low_target): Use linux_get_pc_32bit and
6591 2016-01-18 Gary Benson <gbenson@redhat.com>
6593 * configure.ac (AC_FUNC_FORK): New check.
6594 * config.in: Regenerate.
6595 * configure: Likewise.
6597 2016-01-14 Yao Qi <yao.qi@linaro.org>
6599 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
6600 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
6601 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
6602 arm_get_next_pcs_ctor.
6604 2016-01-12 Josh Stone <jistone@redhat.com>
6605 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6607 * inferiors.h: Include "gdb_vecs.h".
6608 (struct process_info): Add syscalls_to_catch.
6609 * inferiors.c (remove_process): Free syscalls_to_catch.
6610 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
6611 syscall_return stops.
6612 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
6613 * server.c (handle_general_set): Handle QCatchSyscalls.
6614 (handle_query): Report support for QCatchSyscalls.
6615 * target.h (struct target_ops): Add supports_catch_syscall.
6616 (target_supports_catch_syscall): New macro.
6617 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
6618 (struct lwp_info): Add syscall_state.
6619 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
6620 Maintain syscall_state and syscalls_to_catch across exec.
6621 (get_syscall_trapinfo): New function, proxy to the_low_target.
6622 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
6623 (linux_low_filter_event): Toggle syscall_state entry/return for
6624 syscall traps, and set it ignored for all others.
6625 (gdb_catching_syscalls_p): New function.
6626 (gdb_catch_this_syscall_p): New function.
6627 (linux_wait_1): Handle SYSCALL_SIGTRAP.
6628 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
6629 (linux_supports_catch_syscall): New function.
6630 (linux_target_ops): Install it.
6631 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
6632 (the_low_target): Install it.
6634 2016-01-12 Mike Frysinger <vapier@gentoo.org>
6636 * acinclude.m4: Include new ../warning.m4 file.
6637 * configure: Regenerated.
6638 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
6640 2016-01-12 Mike Frysinger <vapier@gentoo.org>
6642 * ax.c (is_goto_target): Mark static.
6643 * linux-low.c (register_addr): Likewise.
6644 (linux_fetch_registers, linux_store_registers): Likewise.
6645 * mem-break.c (any_persistent_commands): Fix old prototype.
6646 (add_commands_to_breakpoint): Mark static.
6647 * regcache.c (find_register_by_name): Delete unused func.
6648 * remote-utils.c (hex_or_minus_one): Mark static.
6649 * server.c (monitor_show_help): Mark static.
6650 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
6651 handle_v_requests): Likewise.
6653 2016-01-12 Pedro Alves <palves@redhat.com>
6655 Remove use of the registered trademark symbol throughout.
6657 2016-01-08 Yao Qi <yao.qi@linaro.org>
6659 * remote-utils.c (getpkt): If c is '\003', call target hook
6662 2016-01-06 Yao Qi <yao.qi@linaro.org>
6664 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
6665 linux-aarch32-low.c.
6666 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6667 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
6668 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
6669 (thumb2_breakpoint): Declare.
6670 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
6671 linux-aarch32-low.h.
6672 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6673 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
6674 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
6676 2016-01-01 Joel Brobecker <brobecker@adacore.com>
6678 * gdbreplay.c (gdbreplay_version): Change copyright year in
6680 * server.c (gdbserver_version): Likewise.
6682 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
6684 * server.c (crc32_table): Delete.
6685 (crc32): Use libiberty's xcrc32 function.
6687 2015-12-22 Joel Brobecker <brobecker@adacore.com>
6689 * lynx-low.c (lynx_delete_thread_callback): New function.
6690 (lynx_mourn): Properly delete our process and all of its
6691 threads. Remove call to clear_inferiors.
6693 2015-12-22 Joel Brobecker <brobecker@adacore.com>
6695 * target.c (thread_search_callback): Add check that
6696 the thread_stopped target callback is not NULL before
6699 2015-12-21 Yao Qi <yao.qi@linaro.org>
6701 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
6704 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6706 * server.c (handle_query): Call target_supports_software_single_step.
6708 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6710 * linux-low.c (single_step): New function.
6711 (linux_resume_one_lwp_throw): Call single_step.
6712 (start_step_over): Likewise.
6714 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6716 * Makefile.in (SFILES): Append arch/arm-linux.c,
6717 arch/arm-get-next-pcs.c.
6718 (arm-linux.o): New rule.
6719 (arm-get-next-pcs.o): New rule.
6720 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
6722 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
6723 to linux-aarch32-low.c.
6724 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6725 (arm_breakpoint_len, thumb_breakpoint): Likewise.
6726 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
6727 (thumb2_breakpoint_len): Likewise.
6728 (arm_is_thumb_mode): Make non-static.
6729 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
6730 from linux-aarch32-low.c.
6731 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6732 (arm_breakpoint_len, thumb_breakpoint): Likewise.
6733 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
6734 (thumb2_breakpoint_len): Likewise.
6735 (arm_is_thumb_mode): New declaration.
6736 * linux-arm-low.c: Include arch/arm-linux.h
6737 aarch/arm-get-next-pcs.h, sys/syscall.h.
6738 (get_next_pcs_ops): New struct.
6739 (get_next_pcs_addr_bits_remove): New function.
6740 (get_next_pcs_is_thumb): New function.
6741 (get_next_pcs_read_memory_unsigned_integer): Likewise.
6742 (arm_sigreturn_next_pc): Likewise.
6743 (get_next_pcs_syscall_next_pc): Likewise.
6744 (arm_gdbserver_get_next_pcs): Likewise.
6745 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
6747 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
6748 * server.h: Include gdb_vecs.h.
6750 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6752 * Makefile.in (SFILES): Append common/common-regcache.c.
6753 (OBS): Append common-regcache.o.
6754 (common-regcache.o): New rule.
6755 * regcache.c (init_register_cache): Initialize cache to
6757 (regcache_raw_read_unsigned): New function.
6758 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
6759 register_status enum.
6761 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6763 * linux-aarch64-low.c (the_low_targets): Rename
6764 breakpoint_reinsert_addr to get_next_pcs.
6765 * linux-arm-low.c (the_low_targets): Likewise.
6766 * linux-bfin-low.c (the_low_targets): Likewise.
6767 * linux-cris-low.c (the_low_targets): Likewise.
6768 * linux-crisv32-low.c (the_low_targets): Likewise.
6769 * linux-low.c (can_software_single_step): Likewise.
6770 (install_software_single_step_breakpoints): New function.
6771 (start_step_over): Use install_software_single_step_breakpoints.
6772 * linux-low.h: New CORE_ADDR vector.
6773 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
6775 * linux-mips-low.c (the_low_targets): Likewise.
6776 * linux-nios2-low.c (the_low_targets): Likewise.
6777 * linux-sparc-low.c (the_low_targets): Likewise.
6779 2015-12-17 Pedro Alves <palves@redhat.com>
6781 * linux-low.c (linux_kill_one_lwp): Remove references to
6783 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
6785 (linux_init_signals): Delete.
6786 (initialize_low): Adjust.
6787 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
6789 2015-12-16 Pedro Alves <palves@redhat.com>
6791 * configure.ac (compiler warning flags): When testing a
6792 -Wno-foo option, check whether -Wfoo works instead.
6793 * configure: Regenerate.
6795 2015-12-11 Don Breazeal <donb@codesourcery.com>
6797 * server.c (process_serial_event): Don't exit from gdbserver
6798 in remote mode if there are still active inferiors.
6800 2015-12-11 Yao Qi <yao.qi@linaro.org>
6802 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
6803 arm_breakpoint_at if the process is 32-bit.
6805 2015-12-11 Yao Qi <yao.qi@linaro.org>
6807 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
6810 2015-12-07 Yao Qi <yao.qi@linaro.org>
6812 * configure.srv: Append arm.o to srv_tgtobj for
6813 aarch64*-*-linux* target.
6814 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
6815 from linux-arm-low.c.
6816 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6817 (arm_breakpoint_len, thumb_breakpoint): Likewise.
6818 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
6819 (thumb2_breakpoint_len): Likewise.
6820 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
6821 (arm_breakpoint_kinds): Likewise.
6822 (arm_breakpoint_kind_from_pc): Likewise.
6823 (arm_sw_breakpoint_from_kind): Likewise.
6824 (arm_breakpoint_kind_from_current_state): Likewise.
6825 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
6826 (arm_sw_breakpoint_from_kind): Declare.
6827 (arm_breakpoint_kind_from_current_state): Declare.
6828 (arm_breakpoint_at): Declare.
6829 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
6830 arm_sw_breakpoint_from_kind if process is 32-bit.
6831 (aarch64_breakpoint_kind_from_pc): New function.
6832 (aarch64_breakpoint_kind_from_current_state): New function.
6833 (the_low_target): Initialize fields breakpoint_kind_from_pc
6834 and breakpoint_kind_from_current_state.
6835 * linux-arm-low.c (arm_breakpoint_kinds): Move to
6836 linux-aarch32-low.c.
6837 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
6838 (arm_breakpoint, arm_breakpoint_len): Likewise.
6839 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
6840 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
6841 (arm_is_thumb_mode): Likewise.
6842 (arm_breakpoint_at): Likewise.
6843 (arm_breakpoint_kind_from_pc): Likewise.
6844 (arm_sw_breakpoint_from_kind): Likewise.
6845 (arm_breakpoint_kind_from_current_state): Likewise.
6848 2015-08-04 Yao Qi <yao.qi@linaro.org>
6850 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
6851 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
6852 * server.c (extended_protocol): Remove "static".
6853 * server.h (extended_protocol): Declare it.
6855 2015-12-04 Josh Stone <jistone@redhat.com>
6857 * target.h (struct target_ops) <arch_setup>: Rename to ...
6858 (struct target_ops) <post_create_inferior>: ... this.
6859 (target_arch_setup): Rename to ...
6860 (target_post_create_inferior): ... this, calling post_create_inferior.
6861 * server.c (start_inferior): Update target_arch_setup calls to
6862 target_post_create_inferior.
6863 * linux-low.c (linux_low_ptrace_options): Forward declare.
6864 (linux_arch_setup): Update its comment for general use.
6865 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
6866 (struct linux_target_ops): Use linux_post_create_inferior.
6867 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
6868 to post_create_inferior.
6869 * nto-low.c (struct nto_target_ops): Likewise.
6870 * spu-low.c (struct spu_target_ops): Likewise.
6871 * win32-low.c (struct win32_target_ops): Likewise.
6873 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
6875 * linux-arm-low.c: Remove duplicate arch/arm.h include.
6877 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6879 * linux-arm-low.c (arm_reinsert_addr): Remove function.
6880 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
6881 * linux-cris-low.c (cris_reinsert_addr> Remove function.
6882 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6883 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
6884 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6885 * linux-mips-low.c (mips_reinsert_addr): Remove function.
6886 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6887 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
6888 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6889 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
6890 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6892 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6894 * linux-low.c (linux_look_up_symbols): Don't call
6895 linux_supports_traceclone.
6896 * linux-low.h (thread_db_init): Remove use_events argument.
6897 * thread-db.c (thread_db_use_event): Remove global variable.
6898 (struct thread_db) <td_thr_event_enable_p>: Remove field.
6899 (struct thread_db) <td_create_bp>: Remove field.
6900 (thread_db_create_event): Remove function.
6901 (thread_db_enable_reporting): Likewise.
6902 (find_one_thread): Don't check for thread_db_use_events.
6903 (attach_thread): Likewise.
6904 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
6905 (try_thread_db_load_1): Don't check for thread_db_use_events.
6906 (thread_db_init): Remove use_events argument and thread events
6908 (remove_thread_event_breakpoints): Remove function.
6909 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
6911 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6913 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
6915 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6916 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
6917 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6918 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
6919 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
6921 * linux-crisv32-low.c (cris_supports_hardware_single_step):
6923 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6924 * linux-low.c (can_hardware_single_step): Use
6925 supports_hardware_single_step.
6926 (can_software_single_step): New function.
6927 (start_step_over): Call can_software_single_step.
6928 (linux_supports_hardware_single_step): New function.
6929 (struct target_ops) <supports_software_single_step>: Initialize.
6930 * linux-low.h (struct linux_target_ops)
6931 <supports_hardware_single_step>: Initialize.
6932 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
6933 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6934 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
6935 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
6936 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
6937 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6938 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
6939 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6940 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
6941 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
6943 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
6944 (struct linux_target_ops) <tile_supports_hardware_single_step>:
6946 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
6947 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6948 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
6950 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6951 * target.h (struct target_ops): <supports_software_single_step>:
6953 (target_supports_software_single_step): New macro.
6955 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6957 * linux-low.c (linux_wait_1): Fix pc advance condition.
6958 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
6959 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
6961 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6963 * linux-arm-low.c (arm_is_thumb_mode): New function.
6964 (arm_breakpoint_at): Use arm_is_thumb_mode.
6965 (arm_breakpoint_kind_from_current_state): New function.
6966 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
6968 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
6969 (linux_breakpoint_kind_from_current_state): New function.
6970 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
6971 * linux-low.h (struct linux_target_ops)
6972 <breakpoint_kind_from_current_state>: New field.
6973 * target.h (struct target_ops): Likewise.
6974 (target_breakpoint_kind_from_current_state): New macro.
6976 2015-11-30 Pedro Alves <palves@redhat.com>
6978 * linux-low.c (linux_resume): Wake up the event loop before
6981 2015-11-30 Pedro Alves <palves@redhat.com>
6983 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
6985 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
6987 * target.c (struct thread_search): New structure.
6988 (thread_search_callback): New function.
6989 (prev_general_thread): New global.
6990 (prepare_to_access_memory, done_accessing_memory): New functions.
6991 * target.h (prepare_to_access_memory, done_accessing_memory):
6992 Replace macros with function declarations.
6994 2015-11-30 Pedro Alves <palves@redhat.com>
6997 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
6998 report TARGET_WAITKIND_NO_RESUMED.
6999 * remote-utils.c (prepare_resume_reply): Handle
7000 TARGET_WAITKIND_NO_RESUMED.
7001 * server.c (report_no_resumed): New global.
7002 (handle_query) <qSupported>: Handle "no-resumed+". Report
7003 "no-resumed+" support.
7004 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
7005 return error if the client doesn't support no-resumed events.
7006 (push_stop_notification): New function.
7007 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
7008 events if the client supports them.
7010 2015-11-30 Pedro Alves <palves@redhat.com>
7012 * linux-low.c (thread_still_has_status_pending_p): Don't check
7014 (lwp_resumed): New function.
7015 (status_pending_p_callback): Return early if the LWP is not
7016 supposed to be resumed.
7018 2015-11-30 Pedro Alves <palves@redhat.com>
7020 * linux-low.c (handle_extended_wait): Assert that the LWP's
7021 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
7022 thread create events, leave the new child's status pending.
7023 (linux_low_filter_event): If GDB wants to hear about thread exit
7024 events, leave the LWP marked dead and don't delete it.
7025 (linux_wait_for_event_filtered): Don't check for thread exit.
7026 (filter_exit_event): New function.
7027 (linux_wait_1): Use it, when returning an exit event.
7028 (linux_resume_one_lwp_throw): Assert that the LWP's
7029 waitstatus is TARGET_WAITKIND_IGNORE.
7030 * remote-utils.c (prepare_resume_reply): Handle
7031 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
7032 * server.c (report_thread_events): New global.
7033 (handle_general_set): Handle QThreadEvents.
7034 (handle_query) <qSupported>: Handle and report QThreadEvents+;
7035 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
7036 TARGET_WAITKIND_THREAD_EXITED.
7037 * server.h (report_thread_events): Declare.
7039 2015-11-30 Pedro Alves <palves@redhat.com>
7041 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
7042 the thread's last_resume_kind was resume_stop.
7044 2015-11-30 Pedro Alves <palves@redhat.com>
7046 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
7049 2015-11-30 Pedro Alves <palves@redhat.com>
7051 * server.c (handle_v_requests): Handle vCtrlC.
7053 2015-11-30 Pedro Alves <palves@redhat.com>
7055 * gdbthread.h (find_any_thread_of_pid): Declare.
7056 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
7058 * server.c (handle_query): If current_thread is NULL, look for
7059 another thread of the selected process.
7061 2015-11-26 Daniel Colascione <dancol@dancol.org>
7062 Simon Marchi <simon.marchi@ericsson.com>
7064 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
7065 * server.c (handle_qxfer_threads_worker): Refactor to include thread
7067 * target.h (struct target_ops) <thread_name>: New field.
7068 (target_thread_name): New macro.
7070 2015-11-23 Joel Brobecker <brobecker@adacore.com>
7072 * regcache.h (regcache_invalidate_pid): Add declaration.
7073 * regcache.c (regcache_invalidate_pid): New function, extracted
7074 from regcache_invalidate.
7075 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
7076 Add trivial documentation comment.
7077 * lynx-low.c: Use regcache_invalidate_pid instead of
7078 regcache_invalidate.
7080 2015-11-23 Joel Brobecker <brobecker@adacore.com>
7082 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
7083 and Elf64_auxv_t if the target is Android.
7085 2015-11-22 Doug Evans <xdje42@gmail.com>
7087 * target.h: #include <sys/types.h>.
7089 2015-11-19 Pedro Alves <palves@redhat.com>
7091 * linux-low.c (linux_process_qsupported): Change prototype.
7093 * linux-low.h (struct linux_target_ops) <process_qsupported>:
7095 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
7096 and adjust to loop over all features.
7097 * server.c (handle_query) <qSupported>: Adjust to call
7098 target_process_qsupported once, passing it a vector of unprocessed
7100 * target.h (struct target_ops) <process_qsupported>: Change
7102 (target_process_qsupported): Adjust.
7104 2015-11-19 Pedro Alves <palves@redhat.com>
7106 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
7108 * configure: Regenerate.
7110 2015-11-19 Pedro Alves <palves@redhat.com>
7112 * configure: Regenerate.
7114 2015-11-19 Yao Qi <yao.qi@linaro.org>
7116 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
7119 2015-11-19 Yao Qi <yao.qi@linaro.org>
7121 * linux-aarch64-low.c (enum aarch64_operand_type): New.
7122 (struct aarch64_operand): Move enum out.
7124 2015-11-19 Yao Qi <yao.qi@linaro.org>
7126 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
7127 struct user_fpsimd_state *.
7128 (aarch64_store_fpregset): Likewise.
7130 2015-11-19 Yao Qi <yao.qi@linaro.org>
7132 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
7133 struct user_pt_regs *.
7134 (aarch64_store_gregset): Likewise.
7136 2015-11-18 Pedro Alves <palves@redhat.com>
7138 * Makefile.in (all_object_files): Add $IPA_OBJS.
7140 2015-11-17 Pedro Alves <palves@redhat.com>
7142 * win32-low.c (win32_resume): Use gdb_signal_from_host,
7143 GDB_SIGNAL_0 and gdb_signal_to_string.
7145 2015-11-17 Pedro Alves <palves@redhat.com>
7147 * win32-low.c (handle_output_debug_string): Remove parameter.
7148 (win32_kill): Remove our_status local and adjust call to
7149 handle_output_debug_string.
7150 (get_child_debug_event): Adjust call to
7151 handle_output_debug_string.
7153 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7155 * linux-mips-low.c (mips_fill_gregset): Add cast.
7156 (mips_store_gregset): Likewise.
7157 (mips_fill_fpregset): Likewise.
7158 (mips_store_fpregset): Likewise.
7160 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7162 * linux-mips-low.c (mips_add_watchpoint): Rename private to
7165 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7167 * linux-mips-low.c (mips_linux_new_thread): Change type of
7168 watch_type to enum target_hw_bp_type.
7170 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7172 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
7173 Change return type to arm_hwbp_type.
7175 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7177 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
7178 (arm_store_gregset): Likewise.
7179 * linux-arm-low.c (arm_get_hwcap): Likewise.
7180 (arm_read_description): Likewise.
7182 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7184 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
7186 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7188 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
7189 (ppc_fill_vsxregset): Likewise.
7190 (ppc_store_vsxregset): Likewise.
7191 (ppc_fill_vrregset): Likewise.
7192 (ppc_store_vrregset): Likewise.
7193 (ppc_fill_evrregset): Likewise.
7194 (ppc_store_evrregset): Likewise.
7196 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7198 * linux-ppc-low.c (ppc_usrregs_info): Remove
7199 forward-declaration.
7200 (ppc_arch_setup): Move lower in file.
7202 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
7204 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
7205 (ps_pdwrite): Likewise.
7207 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
7209 * linux-arm-low.c (arm_new_thread): Move pointer dereference
7210 to after assert checks.
7212 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
7214 * proc-service.c (ps_pdread): Add/adjust casts.
7215 (ps_pdwrite): Add/adjust casts.
7217 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
7219 * server.c (handle_search_memory_1): Cast return value of
7222 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
7224 * server.c (write_qxfer_response): Change type of data to
7227 2015-10-29 Pedro Alves <palves@redhat.com>
7229 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
7231 2015-10-29 Pedro Alves <palves@redhat.com>
7233 * tracepoint.c (clear_installed_tracepoints): Add casts.
7235 2015-10-29 Pedro Alves <palves@redhat.com>
7237 * server.c (handle_v_cont, process_serial_event): Add enum
7238 gdb_signal casts to signal parsing code.
7240 2015-10-29 Pedro Alves <palves@redhat.com>
7242 * linux-low.h (NULL_REGSET): Define.
7243 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
7244 * linux-arm-low.c (arm_regsets): Likewise.
7245 * linux-crisv32-low.c (cris_regsets): Likewise.
7246 * linux-m68k-low.c (m68k_regsets): Likewise.
7247 * linux-mips-low.c (mips_regsets): Likewise.
7248 * linux-nios2-low.c (nios2_regsets): Likewise.
7249 * linux-ppc-low.c (ppc_regsets): Likewise.
7250 * linux-s390-low.c (s390_regsets): Likewise.
7251 * linux-sh-low.c (sh_regsets): Likewise.
7252 * linux-sparc-low.c (sparc_regsets): Likewise.
7253 * linux-tic6x-low.c (tic6x_regsets): Likewise.
7254 * linux-tile-low.c (tile_regsets): Likewise.
7255 * linux-x86-low.c (x86_regsets): Likewise.
7256 * linux-xtensa-low.c (xtensa_regsets): Likewise.
7258 2015-10-29 Pedro Alves <palves@redhat.com>
7260 * linux-low.h (NULL_REGSET): Define.
7261 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
7262 * linux-arm-low.c (arm_regsets): Likewise.
7263 * linux-crisv32-low.c (cris_regsets): Likewise.
7264 * linux-m68k-low.c (m68k_regsets): Likewise.
7265 * linux-mips-low.c (mips_regsets): Likewise.
7266 * linux-nios2-low.c (nios2_regsets): Likewise.
7267 * linux-ppc-low.c (ppc_regsets): Likewise.
7268 * linux-s390-low.c (s390_regsets): Likewise.
7269 * linux-sh-low.c (sh_regsets): Likewise.
7270 * linux-sparc-low.c (sparc_regsets): Likewise.
7271 * linux-tic6x-low.c (tic6x_regsets): Likewise.
7272 * linux-tile-low.c (tile_regsets): Likewise.
7273 * linux-x86-low.c (x86_regsets): Likewise.
7274 * linux-xtensa-low.c (xtensa_regsets): Likewise.
7276 2015-10-26 Doug Evans <dje@google.com>
7278 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
7280 2015-10-26 Doug Evans <dje@google.com>
7282 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
7284 2015-10-26 Doug Evans <dje@google.com>
7286 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
7288 (attach_thread, find_new_threads_callback): Ditto.
7290 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
7292 * mem-break.h (set_breakpoint_data): Remove.
7294 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
7296 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
7297 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
7298 (initialize_low): Remove set_breakpoint_data call.
7299 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
7300 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
7301 (initialize_low): Remove set_breakpoint_data call.
7302 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
7303 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
7304 (initialize_low): Remove set_breakpoint_data call.
7306 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
7308 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
7309 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
7310 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
7311 * target.h (target_breakpoint_kind_from_pc): New macro.
7313 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
7315 * linux-low.c (default_breakpoint_kind_from_pc): New function.
7316 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
7317 the default breakpoint kind.
7319 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7321 * linux-arm-low.c (arm_supports_z_point_type): Add software
7324 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7326 * linux-arm-low.c: Refactor breakpoint definitions.
7327 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
7328 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
7330 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7332 * Makefile.in: Add arm.c/o.
7333 * configure.srv: Likewise.
7334 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
7335 (arm_breakpoint_kind_from_pc): New function.
7336 (arm_sw_breakpoint_from_kind): Return proper kind.
7337 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
7339 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7341 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
7343 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
7344 (struct raw_breakpoint) <size>: Remove.
7345 (struct raw_breakpoint) <kind>: Add.
7346 (bp_size): New function.
7347 (bp_opcode): Likewise.
7348 (find_raw_breakpoint_at): Adjust for kind.
7349 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
7350 (remove_memory_breakpoint): Adjust for kind call bp_size.
7351 (set_raw_breakpoint_at): Adjust for kind.
7352 (set_breakpoint): Likewise.
7353 (set_breakpoint_at): Call breakpoint_kind_from_pc.
7354 (delete_raw_breakpoint): Adjust for kind.
7355 (delete_breakpoint): Likewise.
7356 (find_gdb_breakpoint): Likewise.
7357 (set_gdb_breakpoint_1): Likewise.
7358 (set_gdb_breakpoint): Likewise.
7359 (delete_gdb_breakpoint_1): Likewise.
7360 (delete_gdb_breakpoint): Likewise.
7361 (uninsert_raw_breakpoint): Likewise.
7362 (reinsert_raw_breakpoint): Likewise.
7363 (set_breakpoint_data): Remove.
7364 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
7365 (check_mem_read): Adjust for kind call bp_size.
7366 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
7367 (clone_one_breakpoint): Adjust for kind.
7368 * mem-break.h (set_gdb_breakpoint): Likewise.
7369 (delete_gdb_breakpoint): Likewise.
7370 * server.c (process_serial_event): Likewise.
7372 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7374 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
7375 (struct linux_target_ops) <breakpoint>: Remove.
7376 (struct linux_target_ops) <breakpoint_len>: Remove.
7377 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7378 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7379 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
7380 (arm_sw_breakpoint_from_kind): New function.
7381 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
7382 (struct linux_target_ops) <breakpoint>: Remove.
7383 (struct linux_target_ops) <breakpoint_len>: Remove.
7384 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7385 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7386 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
7387 (struct linux_target_ops) <breakpoint>: Remove.
7388 (struct linux_target_ops) <breakpoint_len>: Remove.
7389 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7390 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7391 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
7392 (struct linux_target_ops) <breakpoint>: Remove.
7393 (struct linux_target_ops) <breakpoint_len>: Remove.
7394 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7395 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7396 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
7397 and sw_breakpoint_from_kind to increment the pc.
7398 (linux_breakpoint_kind_from_pc): New function.
7399 (linux_sw_breakpoint_from_kind): New function.
7400 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
7401 (initialize_low): Call breakpoint_kind_from_pc and
7402 sw_breakpoint_from_kind to replace breakpoint_data/len.
7403 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
7405 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
7406 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
7407 (struct linux_target_ops) <breakpoint>: Remove.
7408 (struct linux_target_ops) <breakpoint_len>: Remove.
7409 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7410 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7411 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
7412 (struct linux_target_ops) <breakpoint>: Remove.
7413 (struct linux_target_ops) <breakpoint_len>: Remove.
7414 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7415 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7416 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
7417 (struct linux_target_ops) <breakpoint>: Remove.
7418 (struct linux_target_ops) <breakpoint_len>: Remove.
7419 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7420 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7421 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
7422 (struct linux_target_ops) <breakpoint>: Remove.
7423 (struct linux_target_ops) <breakpoint_len>: Remove.
7424 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7425 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7426 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
7427 (struct linux_target_ops) <breakpoint>: Remove.
7428 (struct linux_target_ops) <breakpoint_len>: Remove.
7429 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7430 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7431 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
7432 (struct linux_target_ops) <breakpoint>: Remove.
7433 (struct linux_target_ops) <breakpoint_len>: Remove.
7434 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7435 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7436 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
7437 (struct linux_target_ops) <breakpoint>: Remove.
7438 (struct linux_target_ops) <breakpoint_len>: Remove.
7439 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7440 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7441 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
7442 (struct linux_target_ops) <breakpoint>: Remove.
7443 (struct linux_target_ops) <breakpoint_len>: Remove.
7444 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7445 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7446 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
7447 (struct linux_target_ops) <breakpoint>: Remove.
7448 (struct linux_target_ops) <breakpoint_len>: Remove.
7449 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7450 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7451 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
7452 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
7453 (struct linux_target_ops) <breakpoint>: Remove.
7454 (struct linux_target_ops) <breakpoint_len>: Remove.
7455 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7456 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7457 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
7458 (struct linux_target_ops) <breakpoint>: Remove.
7459 (struct linux_target_ops) <breakpoint_len>: Remove.
7460 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7461 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7463 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7465 * linux-cris-low.c (cris_get_pc): Remove void arg.
7467 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
7469 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
7472 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
7474 * inferiors.c (thread_pid_matches_callback): New function.
7475 (find_thread_process): New function.
7476 (remove_thread): Reset current_thread.
7477 (remove_process): Assert threads have been removed first.
7479 2015-10-15 Yao Qi <yao.qi@linaro.org>
7481 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
7483 (aarch64_remove_point): Likewise.
7484 * regcache.c (regcache_register_size): New function.
7486 2015-10-12 Yao Qi <yao.qi@linaro.org>
7488 * linux-aarch64-low.c: Update all callers as emit_load_store
7489 is renamed to aarch64_emit_load_store.
7491 2015-10-12 Yao Qi <yao.qi@linaro.org>
7493 * linux-aarch64-low.c: Update all callers of function renaming
7494 from emit_insn to aarch64_emit_insn.
7496 2015-10-12 Yao Qi <yao.qi@linaro.org>
7498 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
7499 arch/aarch64-insn.h.
7500 (struct aarch64_memory_operand): Likewise.
7502 (emit_insn): Move to arch/aarch64-insn.c.
7503 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
7504 (emit_load_store): Move to arch/aarch64-insn.c.
7505 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
7506 (can_encode_int32): Remove.
7508 2015-10-12 Yao Qi <yao.qi@linaro.org>
7510 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
7511 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
7512 (aarch64_relocate_instruction): Likewise.
7513 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
7514 (struct aarch64_insn_visitor): Likewise.
7516 2015-10-12 Yao Qi <yao.qi@linaro.org>
7518 * linux-aarch64-low.c (struct aarch64_insn_data): New.
7519 (struct aarch64_insn_visitor): New.
7520 (struct aarch64_insn_relocation_data): New.
7521 (aarch64_ftrace_insn_reloc_b): New function.
7522 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
7523 (aarch64_ftrace_insn_reloc_cb): Likewise.
7524 (aarch64_ftrace_insn_reloc_tb): Likewise.
7525 (aarch64_ftrace_insn_reloc_adr): Likewise.
7526 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
7527 (aarch64_ftrace_insn_reloc_others): Likewise.
7529 (aarch64_relocate_instruction): Use visitor.
7531 2015-10-12 Yao Qi <yao.qi@linaro.org>
7533 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
7534 int. Add argument buf.
7535 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
7536 aarch64_relocate_instruction.
7538 2015-10-12 Yao Qi <yao.qi@linaro.org>
7540 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
7541 argument insn. Remove local variable insn. Don't call
7543 (aarch64_install_fast_tracepoint_jump_pad): Call
7546 2015-09-30 Yao Qi <yao.qi@linaro.org>
7548 * linux-aarch64-low.c (emit_movk): Shorten a long line.
7549 (emit_load_store_pair): Likewise.
7551 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
7553 * dll.c (match_dll): Add cast(s).
7554 (unloaded_dll): Likewise.
7555 * linux-low.c (second_thread_of_pid_p): Likewise.
7556 (delete_lwp_callback): Likewise.
7557 (count_events_callback): Likewise.
7558 (select_event_lwp_callback): Likewise.
7559 (linux_set_resume_request): Likewise.
7560 * server.c (accumulate_file_name_length): Likewise.
7561 (emit_dll_description): Likewise.
7562 (handle_qxfer_threads_worker): Likewise.
7563 (visit_actioned_threads): Likewise.
7564 * thread-db.c (any_thread_of): Likewise.
7565 * tracepoint.c (same_process_p): Likewise.
7566 (match_blocktype): Likewise.
7567 (build_traceframe_info_xml): Likewise.
7569 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
7571 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
7573 (gdb_unparse_agent_expr): Likewise.
7574 * hostio.c (require_data): Likewise.
7575 (handle_pread): Likewise.
7576 * linux-low.c (disable_regset): Likewise.
7577 (fetch_register): Likewise.
7578 (store_register): Likewise.
7579 (get_dynamic): Likewise.
7580 (linux_qxfer_libraries_svr4): Likewise.
7581 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
7582 (set_fast_tracepoint_jump): Likewise.
7583 (uninsert_fast_tracepoint_jumps_at): Likewise.
7584 (reinsert_fast_tracepoint_jumps_at): Likewise.
7585 (validate_inserted_breakpoint): Likewise.
7586 (clone_agent_expr): Likewise.
7587 * regcache.c (init_register_cache): Likewise.
7588 * remote-utils.c (putpkt_binary_1): Likewise.
7589 (decode_M_packet): Likewise.
7590 (decode_X_packet): Likewise.
7591 (look_up_one_symbol): Likewise.
7592 (relocate_instruction): Likewise.
7593 (monitor_output): Likewise.
7594 * server.c (handle_search_memory): Likewise.
7595 (handle_qxfer_exec_file): Likewise.
7596 (handle_qxfer_libraries): Likewise.
7597 (handle_qxfer): Likewise.
7598 (handle_query): Likewise.
7599 (handle_v_cont): Likewise.
7600 (handle_v_run): Likewise.
7601 (captured_main): Likewise.
7602 * target.c (write_inferior_memory): Likewise.
7603 * thread-db.c (try_thread_db_load_from_dir): Likewise.
7604 * tracepoint.c (init_trace_buffer): Likewise.
7605 (add_tracepoint_action): Likewise.
7606 (add_traceframe): Likewise.
7607 (add_traceframe_block): Likewise.
7608 (cmd_qtdpsrc): Likewise.
7609 (cmd_qtdv): Likewise.
7610 (cmd_qtstatus): Likewise.
7611 (response_source): Likewise.
7612 (response_tsv): Likewise.
7613 (cmd_qtnotes): Likewise.
7614 (gdb_collect): Likewise.
7615 (initialize_tracepoint): Likewise.
7617 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
7619 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
7620 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
7621 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
7623 (enum aarch64_condition_codes): New enum.
7624 (w0): New static global.
7627 (struct aarch64_memory_operand) <type>: New
7628 MEMORY_OPERAND_POSTINDEX type.
7629 (postindex_memory_operand): New helper function.
7630 (emit_ret): New function.
7631 (emit_load_store_pair): New function, factored out of emit_stp
7632 with support for MEMORY_OPERAND_POSTINDEX.
7633 (emit_stp): Rewrite using emit_load_store_pair.
7634 (emit_ldp): New function.
7635 (emit_load_store): Likewise.
7636 (emit_ldr): Mention post-index instruction in comment.
7637 (emit_ldrh): New function.
7638 (emit_ldrb): New function.
7639 (emit_ldrsw): Mention post-index instruction in comment.
7640 (emit_str): Likewise.
7641 (emit_subs): New function.
7642 (emit_cmp): Likewise.
7643 (emit_and): Likewise.
7644 (emit_orr): Likewise.
7645 (emit_orn): Likewise.
7646 (emit_eor): Likewise.
7647 (emit_mvn): Likewise.
7648 (emit_lslv): Likewise.
7649 (emit_lsrv): Likewise.
7650 (emit_asrv): Likewise.
7651 (emit_mul): Likewise.
7652 (emit_sbfm): Likewise.
7653 (emit_sbfx): Likewise.
7654 (emit_ubfm): Likewise.
7655 (emit_ubfx): Likewise.
7656 (emit_csinc): Likewise.
7657 (emit_cset): Likewise.
7658 (emit_nop): Likewise.
7659 (emit_ops_insns): New helper function.
7660 (emit_pop): Likewise.
7661 (emit_push): Likewise.
7662 (aarch64_emit_prologue): New function.
7663 (aarch64_emit_epilogue): Likewise.
7664 (aarch64_emit_add): Likewise.
7665 (aarch64_emit_sub): Likewise.
7666 (aarch64_emit_mul): Likewise.
7667 (aarch64_emit_lsh): Likewise.
7668 (aarch64_emit_rsh_signed): Likewise.
7669 (aarch64_emit_rsh_unsigned): Likewise.
7670 (aarch64_emit_ext): Likewise.
7671 (aarch64_emit_log_not): Likewise.
7672 (aarch64_emit_bit_and): Likewise.
7673 (aarch64_emit_bit_or): Likewise.
7674 (aarch64_emit_bit_xor): Likewise.
7675 (aarch64_emit_bit_not): Likewise.
7676 (aarch64_emit_equal): Likewise.
7677 (aarch64_emit_less_signed): Likewise.
7678 (aarch64_emit_less_unsigned): Likewise.
7679 (aarch64_emit_ref): Likewise.
7680 (aarch64_emit_if_goto): Likewise.
7681 (aarch64_emit_goto): Likewise.
7682 (aarch64_write_goto_address): Likewise.
7683 (aarch64_emit_const): Likewise.
7684 (aarch64_emit_call): Likewise.
7685 (aarch64_emit_reg): Likewise.
7686 (aarch64_emit_pop): Likewise.
7687 (aarch64_emit_stack_flush): Likewise.
7688 (aarch64_emit_zero_ext): Likewise.
7689 (aarch64_emit_swap): Likewise.
7690 (aarch64_emit_stack_adjust): Likewise.
7691 (aarch64_emit_int_call_1): Likewise.
7692 (aarch64_emit_void_call_2): Likewise.
7693 (aarch64_emit_eq_goto): Likewise.
7694 (aarch64_emit_ne_goto): Likewise.
7695 (aarch64_emit_lt_goto): Likewise.
7696 (aarch64_emit_le_goto): Likewise.
7697 (aarch64_emit_gt_goto): Likewise.
7698 (aarch64_emit_ge_got): Likewise.
7699 (aarch64_emit_ops_impl): New static global variable.
7700 (aarch64_emit_ops): New target function, return
7701 &aarch64_emit_ops_impl.
7702 (struct linux_target_ops): Install it.
7704 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
7706 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
7707 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
7709 * linux-aarch64-ipa.c: New file.
7710 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
7712 (aarch64_get_thread_area): New target method.
7713 (extract_signed_bitfield): New helper function.
7714 (aarch64_decode_ldr_literal): New function.
7715 (enum aarch64_opcodes): New enum.
7716 (struct aarch64_register): New struct.
7717 (struct aarch64_operand): New struct.
7718 (x0): New static global.
7727 (aarch64_register): New helper function.
7728 (register_operand): Likewise.
7729 (immediate_operand): Likewise.
7730 (struct aarch64_memory_operand): New struct.
7731 (offset_memory_operand): New helper function.
7732 (preindex_memory_operand): Likewise.
7733 (enum aarch64_system_control_registers): New enum.
7734 (ENCODE): New macro.
7735 (emit_insn): New helper function.
7736 (emit_b): New function.
7737 (emit_bcond): Likewise.
7738 (emit_cb): Likewise.
7739 (emit_tb): Likewise.
7740 (emit_blr): Likewise.
7741 (emit_stp): Likewise.
7742 (emit_ldp_q_offset): Likewise.
7743 (emit_stp_q_offset): Likewise.
7744 (emit_load_store): Likewise.
7745 (emit_ldr): Likewise.
7746 (emit_ldrsw): Likewise.
7747 (emit_str): Likewise.
7748 (emit_ldaxr): Likewise.
7749 (emit_stxr): Likewise.
7750 (emit_stlr): Likewise.
7751 (emit_data_processing_reg): Likewise.
7752 (emit_data_processing): Likewise.
7753 (emit_add): Likewise.
7754 (emit_sub): Likewise.
7755 (emit_mov): Likewise.
7756 (emit_movk): Likewise.
7757 (emit_mov_addr): Likewise.
7758 (emit_mrs): Likewise.
7759 (emit_msr): Likewise.
7760 (emit_sevl): Likewise.
7761 (emit_wfe): Likewise.
7762 (append_insns): Likewise.
7763 (can_encode_int32_in): New helper function.
7764 (aarch64_relocate_instruction): New function.
7765 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
7766 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
7767 (struct linux_target_ops): Install aarch64_get_thread_area,
7768 aarch64_install_fast_tracepoint_jump_pad and
7769 aarch64_get_min_fast_tracepoint_insn_len.
7771 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
7773 * Makefile.in (aarch64-insn.o): New rule.
7774 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
7776 2015-09-21 Yao Qi <yao.qi@linaro.org>
7778 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
7780 2015-09-21 Yao Qi <yao.qi@linaro.org>
7782 * tracepoint.c (max_jump_pad_size): Remove.
7784 2015-09-18 Yao Qi <yao.qi@linaro.org>
7786 * linux-aarch64-low.c: Don't include sys/uio.h.
7787 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
7789 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
7791 * tracepoint.c (eval_result_type): Change prototype.
7792 (condition_true_at_tracepoint): Fix argument to compiled_cond.
7794 2015-09-15 Pedro Alves <palves@redhat.com>
7796 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
7797 Check whether to report exec events instead of checking whether
7798 multiprocess is enabled.
7800 2015-09-15 Pedro Alves <palves@redhat.com>
7803 * remote-utils.c (prepare_resume_reply): Merge
7804 TARGET_WAITKIND_VFORK_DONE switch case with the
7805 TARGET_WAITKIND_FORKED case.
7807 2015-09-15 Yao Qi <yao.qi@linaro.org>
7809 * server.c (handle_query): Check string comparison using
7810 "else if" instead of "if".
7812 2015-09-15 Yao Qi <yao.qi@linaro.org>
7814 * server.c (vCont_supported): New global variable.
7815 (handle_query): Set vCont_supported to 1 if "vContSupported+"
7816 matches. Append ";vContSupported+" to own_buf.
7817 (handle_v_requests): Append ";s;S" to own_buf if target supports
7818 hardware single step or vCont_supported is false.
7819 (capture_main): Set vCont_supported to zero.
7821 2015-09-15 Yao Qi <yao.qi@linaro.org>
7823 * linux-low.c (linux_supports_conditional_breakpoints): Rename
7825 (linux_supports_hardware_single_step): ... New function.
7826 (linux_target_ops): Update.
7827 * lynx-low.c (lynx_target_ops): Set field
7828 supports_hardware_single_step to target_can_do_hardware_single_step.
7829 * nto-low.c (nto_target_ops): Likewise.
7830 * spu-low.c (spu_target_ops): Likewise.
7831 * win32-low.c (win32_target_ops): Likewise.
7832 * target.c (target_can_do_hardware_single_step): New function.
7833 * target.h (struct target_ops) <supports_conditional_breakpoints>:
7834 Remove. <supports_hardware_single_step>: New field.
7835 (target_supports_conditional_breakpoints): Remove.
7836 (target_supports_hardware_single_step): New macro.
7837 (target_can_do_hardware_single_step): Declare.
7838 * server.c (handle_query): Use target_supports_hardware_single_step
7839 instead of target_supports_conditional_breakpoints.
7841 2015-09-15 Yao Qi <yao.qi@linaro.org>
7843 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
7845 (struct linux_target_ops the_low_target): Install
7846 aarch64_linux_siginfo_fixup.
7848 2015-09-11 Don Breazeal <donb@codesourcery.com>
7849 Luis Machado <lgustavo@codesourcery.com>
7851 * linux-low.c (linux_mourn): Static declaration.
7852 (linux_arch_setup): Move in front of
7853 handle_extended_wait.
7854 (linux_arch_setup_thread): New function.
7855 (handle_extended_wait): Handle exec events. Call
7856 linux_arch_setup_thread. Make event_lwp argument a
7857 pointer-to-a-pointer.
7858 (check_zombie_leaders): Do not check stopped threads.
7859 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
7860 (linux_low_filter_event): Add lwp and thread for exec'ing
7861 non-leader thread if leader thread has been deleted.
7862 Refactor code into linux_arch_setup_thread and call it.
7863 Pass child lwp pointer by reference to handle_extended_wait.
7864 (linux_wait_for_event_filtered): Update comment.
7865 (linux_wait_1): Prevent clobbering exec event status.
7866 (linux_supports_exec_events): New function.
7867 (linux_target_ops) <supports_exec_events>: Initialize new member.
7868 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
7870 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
7871 * server.c (report_exec_events): New global variable.
7872 (handle_query): Handle qSupported query for exec-events feature.
7873 (captured_main): Initialize report_exec_events.
7874 * server.h (report_exec_events): Declare new global variable.
7875 * target.h (struct target_ops) <supports_exec_events>: New
7877 (target_supports_exec_events): New macro.
7878 * win32-low.c (win32_target_ops) <supports_exec_events>:
7879 Initialize new member.
7881 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
7883 * linux-low.c (linux_low_enable_btrace): Remove.
7884 (linux_target_ops): Replace linux_low_enable_btrace with
7885 linux_enable_btrace.
7887 2015-09-03 Yao Qi <yao.qi@linaro.org>
7889 * linux-aarch64-low.c (aarch64_insert_point): Call
7890 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
7893 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
7895 * linux-low.c (check_stopped_by_breakpoint): Use
7896 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
7898 2015-08-27 Pedro Alves <palves@redhat.com>
7900 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
7902 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
7904 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
7905 the XNEW-family equivalent.
7906 (compile_bytecodes): Likewise.
7907 * dll.c (loaded_dll): Likewise.
7908 * event-loop.c (append_callback_event): Likewise.
7909 (create_file_handler): Likewise.
7910 (create_file_event): Likewise.
7911 * hostio.c (handle_open): Likewise.
7912 * inferiors.c (add_thread): Likewise.
7913 (add_process): Likewise.
7914 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
7915 * linux-arm-low.c (arm_new_process): Likewise.
7916 (arm_new_thread): Likewise.
7917 * linux-low.c (add_to_pid_list): Likewise.
7918 (linux_add_process): Likewise.
7919 (handle_extended_wait): Likewise.
7920 (add_lwp): Likewise.
7921 (enqueue_one_deferred_signal): Likewise.
7922 (enqueue_pending_signal): Likewise.
7923 (linux_resume_one_lwp_throw): Likewise.
7924 (linux_resume_one_thread): Likewise.
7925 (linux_read_memory): Likewise.
7926 (linux_write_memory): Likewise.
7927 * linux-mips-low.c (mips_linux_new_process): Likewise.
7928 (mips_linux_new_thread): Likewise.
7929 (mips_add_watchpoint): Likewise.
7930 * linux-x86-low.c (initialize_low_arch): Likewise.
7931 * lynx-low.c (lynx_add_process): Likewise.
7932 * mem-break.c (set_raw_breakpoint_at): Likewise.
7933 (set_breakpoint): Likewise.
7934 (add_condition_to_breakpoint): Likewise.
7935 (add_commands_to_breakpoint): Likewise.
7936 (clone_agent_expr): Likewise.
7937 (clone_one_breakpoint): Likewise.
7938 * regcache.c (new_register_cache): Likewise.
7939 * remote-utils.c (look_up_one_symbol): Likewise.
7940 * server.c (queue_stop_reply): Likewise.
7941 (start_inferior): Likewise.
7942 (queue_stop_reply_callback): Likewise.
7943 (handle_target_event): Likewise.
7944 * spu-low.c (fetch_ppc_memory): Likewise.
7945 (store_ppc_memory): Likewise.
7946 * target.c (set_target_ops): Likewise.
7947 * thread-db.c (thread_db_load_search): Likewise.
7948 (try_thread_db_load_1): Likewise.
7949 * tracepoint.c (add_tracepoint): Likewise.
7950 (add_tracepoint_action): Likewise.
7951 (create_trace_state_variable): Likewise.
7952 (cmd_qtdpsrc): Likewise.
7953 (cmd_qtro): Likewise.
7954 (add_while_stepping_state): Likewise.
7955 * win32-low.c (child_add_thread): Likewise.
7956 (get_image_name): Likewise.
7958 2015-08-25 Yao Qi <yao.qi@linaro.org>
7960 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
7962 2015-08-25 Yao Qi <yao.qi@linaro.org>
7964 * Makefile.in (aarch64-linux.o): New rule.
7965 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
7967 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
7968 (aarch64_init_debug_reg_state): Make it extern.
7969 (aarch64_linux_prepare_to_resume): Remove.
7971 2015-08-25 Yao Qi <yao.qi@linaro.org>
7973 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
7974 lwp_arch_private_info and ptid_of_lwp.
7976 2015-08-25 Yao Qi <yao.qi@linaro.org>
7978 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
7979 Find proc_info by find_process_pid. All callers updated.
7981 2015-08-25 Yao Qi <yao.qi@linaro.org>
7983 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
7985 (debug_reg_change_callback): Remove.
7986 (aarch64_notify_debug_reg_change): Remove.
7988 2015-08-25 Yao Qi <yao.qi@linaro.org>
7990 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
7991 Call current_lwp_ptid.
7993 2015-08-25 Yao Qi <yao.qi@linaro.org>
7995 * linux-aarch64-low.c (debug_reg_change_callback): Use
7998 2015-08-25 Yao Qi <yao.qi@linaro.org>
8000 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
8002 2015-08-25 Yao Qi <yao.qi@linaro.org>
8004 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
8006 2015-08-25 Yao Qi <yao.qi@linaro.org>
8008 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
8011 2015-08-25 Yao Qi <yao.qi@linaro.org>
8013 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
8015 (debug_reg_change_callback): Remove argument entry and add argument
8016 lwp. Remove local variable thread. Don't print thread id in the
8017 debugging output. Don't check whether pid of thread equals to pid.
8018 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
8019 iterate_over_lwps instead find_inferior.
8021 2015-08-24 Pedro Alves <palves@redhat.com>
8023 * inferiors.c (get_first_process): New function.
8024 * inferiors.h (get_first_process): New declaration.
8025 * remote-utils.c (read_ptid): Default to the first process in the
8026 list, instead of to the current thread's process.
8028 2015-08-24 Pedro Alves <palves@redhat.com>
8030 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
8031 * event-loop.c: Likewise.
8032 * remote-utils.c: Likewise.
8033 * tracepoint.c: Likewise.
8035 2015-08-24 Pedro Alves <palves@redhat.com>
8037 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
8040 2015-08-21 Pedro Alves <palves@redhat.com>
8042 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
8043 instead of literal 1.
8045 2015-08-21 Pedro Alves <palves@redhat.com>
8047 * tdesc.c (default_description): Explicitly zero-initialize.
8049 2015-08-21 Pedro Alves <palves@redhat.com>
8052 * inferiors.c (remove_thread): Discard any pending stop reply for
8054 * server.c (remove_all_on_match_pid): Rename to ...
8055 (remove_all_on_match_ptid): ... this. Work with a filter ptid
8057 (discard_queued_stop_replies): Change parameter to a ptid. Now
8059 (handle_v_kill, kill_inferior_callback, captured_main)
8060 (process_serial_event): Adjust.
8061 * server.h (discard_queued_stop_replies): Declare.
8063 2015-08-21 Pedro Alves <palves@redhat.com>
8065 * linux-low.c (wait_for_sigstop): Always switch to no thread
8066 selected if the previously current thread dies.
8067 * lynx-low.c (lynx_request_interrupt): Use the first thread's
8068 process instead of the current thread's.
8069 * remote-utils.c (input_interrupt): Don't check if there's no
8071 * server.c (gdb_read_memory, gdb_write_memory): If setting the
8072 current thread to the general thread fails, error out.
8073 (handle_qxfer_auxv, handle_qxfer_libraries)
8074 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
8075 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
8076 (handle_query): Check if there's a thread selected instead of
8077 checking whether there's any thread in the thread list.
8078 (handle_qxfer_threads, handle_qxfer_btrace)
8079 (handle_qxfer_btrace_conf): Don't error out early if there's no
8080 thread in the thread list.
8081 (handle_v_cont, myresume): Don't set the current thread to the
8083 (process_serial_event) <Hg handling>: Also set thread_id if the
8084 previous general thread is still alive.
8085 (process_serial_event) <g/G handling>: If setting the current
8086 thread to the general thread fails, error out.
8087 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
8088 thread's lwp instead of the current thread's.
8089 * target.c (set_desired_thread): If the desired thread was not
8090 found, leave the current thread pointing to NULL. Return an int
8091 (boolean) indicating success.
8092 * target.h (set_desired_thread): Change return type to int.
8094 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
8096 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
8097 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
8099 (ps_get_thread_area): New function.
8101 2015-08-19 Gary Benson <gbenson@redhat.com>
8103 * hostio.c (handle_pread): Do not attempt to read more data
8104 than hostio_reply_with_data can fit in a packet.
8106 2015-08-18 Joel Brobecker <brobecker@adacore.com>
8108 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
8110 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
8112 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
8114 2015-08-06 Pedro Alves <palves@redhat.com>
8116 * tracepoint.c (expr_eval_result): Now an int.
8118 2015-08-06 Pedro Alves <palves@redhat.com>
8120 * gdbthread.h (struct regcache): Forward declare.
8121 (struct thread_info) <regcache_data>: Now a struct regcache
8123 * inferiors.c (inferior_regcache_data)
8124 (set_inferior_regcache_data): Now work with struct regcache
8126 * inferiors.h (struct regcache): Forward declare.
8127 (inferior_regcache_data, set_inferior_regcache_data): Now work
8128 with struct regcache pointers.
8129 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
8130 (free_register_cache_thread): Remove struct regcache pointer
8133 2015-08-06 Pedro Alves <palves@redhat.com>
8135 * server.c (captured_main): On error, print the exception message
8136 to stderr, and if run_once is set, throw a quit.
8138 2015-08-06 Pedro Alves <palves@redhat.com>
8140 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
8143 2015-08-06 Pedro Alves <palves@redhat.com>
8145 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
8146 reading beyond the passed in buffer length.
8148 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
8150 * tracepoint.c (symbol_list) <required>: Remove.
8152 2015-08-06 Pedro Alves <palves@redhat.com>
8154 * linux-low.c (handle_extended_wait): Set the fork child's suspend
8155 count if stopping and suspending threads.
8156 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
8157 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
8158 (linux_detach): Complete an ongoing step-over.
8159 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
8161 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
8162 (linux_wait_1): If passing a signal to the inferior after
8163 finishing a step-over, unsuspend and re-resume all lwps. If we
8164 see a single-step event but the thread should be continuing, don't
8165 pass the trap to gdb.
8166 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
8167 internal_error instead of gdb_assert.
8168 (enqueue_pending_signal): New function.
8169 (check_ptrace_stopped_lwp_gone): Add debug output.
8170 (start_step_over): Use internal_error instead of gdb_assert.
8171 (complete_ongoing_step_over): New function.
8172 (linux_resume_one_thread): Don't resume a suspended thread.
8173 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
8176 2015-08-06 Pedro Alves <palves@redhat.com>
8178 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
8179 (linux_thread_alive): Use lwp_is_marked_dead.
8180 (extended_event_reported): Delete.
8181 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
8182 instead of extended_event_reported.
8183 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
8185 (lwp_is_marked_dead): New function.
8186 (lwp_running): Use lwp_is_marked_dead.
8187 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
8190 2015-08-06 Pedro Alves <palves@redhat.com>
8192 * linux-low.c (linux_wait_1): Move fork event output out of the
8193 !report_to_gdb check. Pass event_child->waitstatus to
8194 target_waitstatus_to_string instead of ourstatus.
8196 2015-08-04 Yao Qi <yao.qi@linaro.org>
8198 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
8199 if current_thread is 32 bit.
8201 2015-08-04 Yao Qi <yao.qi@linaro.org>
8203 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
8204 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
8205 * server.c (extended_protocol): Remove "static".
8206 * server.h (extended_protocol): Declare it.
8208 2015-08-04 Yao Qi <yao.qi@linaro.org>
8210 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
8211 both aarch64 and aarch32.
8212 (aarch64_set_pc): Likewise.
8214 2015-08-04 Yao Qi <yao.qi@linaro.org>
8216 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
8217 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
8218 arm-with-neon.xml to srv_xmlfiles.
8219 * linux-aarch64-low.c: Include linux-aarch32-low.h.
8220 (is_64bit_tdesc): New function.
8221 (aarch64_linux_read_description): New function.
8222 (aarch64_arch_setup): Call aarch64_linux_read_description.
8223 (regs_info): Rename to regs_info_aarch64.
8224 (aarch64_regs_info): Return right regs_info.
8225 (initialize_low_arch): Call initialize_low_arch_aarch32.
8227 2015-08-04 Yao Qi <yao.qi@linaro.org>
8229 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
8230 * linux-aarch32-low.c: New file.
8231 * linux-aarch32-low.h: New file.
8232 * linux-arm-low.c (arm_fill_gregset): Move it to
8233 linux-aarch32-low.c.
8234 (arm_store_gregset): Likewise.
8235 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
8236 (arm_store_vfpregset): Call arm_store_vfpregset_num.
8237 (arm_arch_setup): Check if PTRACE_GETREGSET works.
8238 (regs_info): Rename to regs_info_arm.
8239 (arm_regs_info): Return regs_info_aarch32 if
8240 have_ptrace_getregset is 1 and target description is
8241 arm_with_neon or arm_with_vfpv3.
8242 (initialize_low_arch): Don't call init_registers_arm_with_neon.
8243 Call initialize_low_arch_aarch32 instead.
8245 2015-08-04 Yao Qi <yao.qi@linaro.org>
8247 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
8248 * linux-low.c: ... here.
8249 * linux-low.h (have_ptrace_getregset): Declare it.
8251 2015-08-04 Pedro Alves <palves@redhat.com>
8253 * thread-db.c (struct thread_db): Use new typedefs.
8254 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
8256 (disable_thread_event_reporting): Cast result of dlsym to
8257 destination function pointer type.
8258 (thread_db_mourn): Use td_ta_delete_ftype.
8260 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
8262 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
8264 (CDX_BREAKPOINT): Define for R2.
8265 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
8266 (the_low_target): Add comments.
8268 2015-07-30 Yao Qi <yao.qi@linaro.org>
8270 * linux-arm-low.c (arm_hwcap): Remove it.
8271 (arm_read_description): New local variable arm_hwcap. Don't
8272 set arm_hwcap to zero.
8274 2015-07-30 Yao Qi <yao.qi@linaro.org>
8276 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
8277 Use regcache->tdesc instead.
8278 (arm_store_wmmxregset): Likewise.
8279 (arm_fill_vfpregset): Likewise.
8280 (arm_store_vfpregset): Likewise.
8282 2015-07-30 Yao Qi <yao.qi@linaro.org>
8284 * linux-arm-low.c: Include arch/arm.h.
8285 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
8286 (arm_store_gregset): Likewise.
8288 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
8290 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
8291 ptrace's 4th parameter.
8293 2015-07-27 Yao Qi <yao.qi@linaro.org>
8295 * configure.srv (case aarch64*-*-linux*): Don't set
8298 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
8300 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
8302 * linux-arm-low.c: Likewise.
8303 * linux-cris-low.c: Likewise.
8304 * linux-crisv32-low.c: Likewise.
8305 * linux-low.c: Likewise.
8306 * linux-m68k-low.c: Likewise.
8307 * linux-mips-low.c: Likewise.
8308 * linux-nios2-low.c: Likewise.
8309 * linux-s390-low.c: Likewise.
8310 * linux-sparc-low.c: Likewise.
8311 * linux-tic6x-low.c: Likewise.
8312 * linux-tile-low.c: Likewise.
8313 * linux-x86-low.c: Likewise.
8315 2015-07-24 Pedro Alves <palves@redhat.com>
8317 * config.in: Regenerate.
8318 * configure: Regenerate.
8320 2015-07-24 Pedro Alves <palves@redhat.com>
8322 * acinclude.m4: Include ../ptrace.m4.
8323 * configure.ac: Call GDB_AC_PTRACE.
8324 * config.in, configure: Regenerate.
8326 2015-07-24 Yao Qi <yao.qi@linaro.org>
8328 * linux-low.c (linux_create_inferior): Remove setting to
8329 proc->priv->new_inferior.
8330 (linux_attach): Likewise.
8331 (linux_low_filter_event): Likewise.
8332 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
8334 2015-07-24 Yao Qi <yao.qi@linaro.org>
8336 * linux-low.c (linux_arch_setup): New function.
8337 (linux_low_filter_event): If proc->tdesc is NULL and
8338 proc->attached is true, call the_low_target.arch_setup.
8339 Otherwise, keep status pending, and return.
8340 (linux_resume_one_lwp_throw): Don't call get_pc if
8341 thread->while_stepping isn't NULL. Don't call
8342 get_thread_regcache if proc->tdesc is NULL.
8343 (need_step_over_p): Return 0 if proc->tdesc is NULL.
8344 (linux_target_ops): Install arch_setup.
8345 * server.c (start_inferior): Call the_target->arch_setup.
8346 * target.h (struct target_ops) <arch_setup>: New field.
8347 (target_arch_setup): New marco.
8348 * lynx-low.c (lynx_target_ops): Update.
8349 * nto-low.c (nto_target_ops): Update.
8350 * spu-low.c (spu_target_ops): Update.
8351 * win32-low.c (win32_target_ops): Update.
8353 2015-07-24 Yao Qi <yao.qi@linaro.org>
8355 * linux-low.c (linux_add_process): Don't set
8356 proc->priv->new_inferior.
8357 (linux_create_inferior): Set proc->priv->new_inferior to 1.
8358 (linux_attach): Likewise.
8360 2015-07-24 Yao Qi <yao.qi@linaro.org>
8362 * server.c (start_inferior): Code refactor.
8364 2015-07-24 Yao Qi <yao.qi@linaro.org>
8366 * server.c (process_serial_event): Set general_thread.
8368 2015-07-21 Yao Qi <yao.qi@linaro.org>
8370 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
8371 aarch64_linux_get_debug_reg_capacity.
8373 2015-07-17 Yao Qi <yao.qi@linaro.org>
8375 * Makefile.in (aarch64-linux-hw-point.o): New rule.
8376 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
8377 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
8378 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
8379 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
8380 (AARCH64_HWP_ALIGNMENT): Likewise.
8381 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
8382 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
8383 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
8384 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
8385 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
8386 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
8387 (struct aarch64_debug_reg_state): Likewise.
8388 (struct arch_lwp_info): Likewise.
8389 (aarch64_align_watchpoint): Likewise.
8390 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
8391 (aarch64_watchpoint_length): Likewise.
8392 (aarch64_point_encode_ctrl_reg): Likewise
8393 (aarch64_point_is_aligned): Likewise.
8394 (aarch64_align_watchpoint): Likewise.
8395 (aarch64_linux_set_debug_regs):
8396 (aarch64_dr_state_insert_one_point): Likewise.
8397 (aarch64_dr_state_remove_one_point): Likewise.
8398 (aarch64_handle_breakpoint): Likewise.
8399 (aarch64_handle_aligned_watchpoint): Likewise.
8400 (aarch64_handle_unaligned_watchpoint): Likewise.
8401 (aarch64_handle_watchpoint): Likewise.
8403 2015-07-17 Yao Qi <yao.qi@linaro.org>
8405 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
8406 and don't aarch64_get_debug_reg_state. All callers update.
8407 (aarch64_handle_aligned_watchpoint): Likewise.
8408 (aarch64_handle_unaligned_watchpoint): Likewise.
8409 (aarch64_handle_watchpoint): Likewise.
8410 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
8411 (aarch64_remove_point): Likewise.
8413 2015-07-17 Yao Qi <yao.qi@linaro.org>
8415 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
8417 (aarch64_handle_unaligned_watchpoint): Likewise.
8419 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
8421 Revert the previous 3 commits:
8422 Move gdb_regex* to common/
8423 Move linux_find_memory_regions_full & co.
8424 gdbserver build-id attribute generator
8426 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
8427 Jan Kratochvil <jan.kratochvil@redhat.com>
8429 gdbserver build-id attribute generator.
8430 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
8431 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
8432 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
8434 (get_dynamic): Use find_pdhr to traverse program headers.
8435 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
8436 (compare_mapping_entry_range, struct find_memory_region_callback_data)
8437 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
8438 (get_hex_build_id): New.
8439 (linux_qxfer_libraries_svr4): Add optional build-id attribute
8440 to reply XML document.
8442 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
8443 Jan Kratochvil <jan.kratochvil@redhat.com>
8445 * target.c: Include target/target-utils.h and fcntl.h.
8446 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
8447 (target_fileio_read_stralloc): New functions.
8449 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
8451 * Makefile.in (OBS): Add gdb_regex.o.
8453 * config.in: Rebuilt.
8454 * configure: Rebuilt.
8456 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
8457 Jan Kratochvil <jan.kratochvil@redhat.com>
8459 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
8460 * Makefile.in (OBS): Add target-utils.o.
8461 (linux-maps.o, target-utils.o): New.
8462 * configure.srv (srv_linux_obj): Add linux-maps.o.
8464 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
8466 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
8468 (the_low_target): Install it.
8470 2015-07-14 Pedro Alves <palves@redhat.com>
8472 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
8473 Instead, ignore ECHILD, and throw an error for other errnos.
8475 2015-07-10 Pedro Alves <palves@redhat.com>
8477 * event-loop.c (struct callback_event) <data>: Change type to
8478 gdb_client_data instance instead of gdb_client_data pointer.
8479 (append_callback_event): Adjust.
8481 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
8483 * linux-aarch64-low.c: Add comments for each linux_target_ops
8484 method. Remove comments already covered in target_ops and
8485 linux_target_ops definitions.
8486 (the_low_target): Add comments for each unimplemented method.
8488 2015-07-09 Yao Qi <yao.qi@linaro.org>
8490 * linux-aarch64-low.c (aarch64_regmap): Remove.
8491 (aarch64_usrregs_info): Remove.
8492 (regs_info): Set field usrregs to NULL.
8494 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
8496 * linux-low.c: Include "rsp-low.h"
8497 (linux_low_encode_pt_config, linux_low_encode_raw): New.
8498 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
8499 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
8500 (handle_btrace_enable_pt): New.
8501 (handle_btrace_general_set): Support "pt".
8502 (handle_btrace_conf_general_set): Support "pt:size".
8504 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
8506 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
8509 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
8511 * linux-aarch64-low.c: Remove comment about endianness.
8512 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
8513 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
8516 2015-06-24 Gary Benson <gbenson@redhat.com>
8518 * linux-i386-ipa.c (stdint.h): Do not include.
8519 * lynx-i386-low.c (stdint.h): Likewise.
8520 * lynx-ppc-low.c (stdint.h): Likewise.
8521 * mem-break.c (stdint.h): Likewise.
8522 * thread-db.c (stdint.h): Likewise.
8523 * tracepoint.c (stdint.h): Likewise.
8524 * win32-low.c (stdint.h): Likewise.
8526 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
8528 * server.c (write_qxfer_response): Update call to
8529 remote_escape_output.
8531 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
8532 Jan Kratochvil <jan.kratochvil@redhat.com>
8534 Merge multiple hex conversions.
8535 * gdbreplay.c (tohex): Rename to 'fromhex'.
8536 (logchar): Use fromhex.
8538 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
8540 * server.c (handle_qxfer_libraries): Set `version' attribute for
8543 2015-06-10 Gary Benson <gbenson@redhat.com>
8545 * target.h (struct target_ops) <multifs_open>: New field.
8546 <multifs_unlink>: Likewise.
8547 <multifs_readlink>: Likewise.
8548 * linux-low.c (nat/linux-namespaces.h): New include.
8549 (linux_target_ops): Initialize the_target->multifs_open,
8550 the_target->multifs_unlink and the_target->multifs_readlink.
8551 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
8552 * hostio.c (hostio_fs_pid): New static variable.
8553 (hostio_handle_new_gdb_connection): New function.
8554 (handle_setfs): Likewise.
8555 (handle_open): Use the_target->multifs_open as appropriate.
8556 (handle_unlink): Use the_target->multifs_unlink as appropriate.
8557 (handle_readlink): Use the_target->multifs_readlink as
8559 (handle_vFile): Handle vFile:setfs packets.
8560 * server.c (handle_query): Call hostio_handle_new_gdb_connection
8561 after target_handle_new_gdb_connection.
8563 2015-06-10 Gary Benson <gbenson@redhat.com>
8565 * configure.ac (AC_CHECK_FUNCS): Add setns.
8566 * config.in: Regenerate.
8567 * configure: Likewise.
8568 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
8569 (linux-namespaces.o): New rule.
8570 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
8572 2015-06-09 Gary Benson <gbenson@redhat.com>
8574 * hostio.c (handle_open): Process mode argument with
8575 fileio_to_host_mode.
8577 2015-06-01 Yao Qi <yao.qi@linaro.org>
8579 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
8580 * linux-x86-low.c: Likewise.
8582 2015-05-28 Don Breazeal <donb@codesourcery.com>
8584 * linux-low.c (handle_extended_wait): Initialize
8585 thread_info.last_resume_kind for new fork children.
8587 2015-05-15 Pedro Alves <palves@redhat.com>
8589 * target.h (target_handle_new_gdb_connection): Rewrite using if
8590 wrapped in do/while.
8592 2015-05-14 Joel Brobecker <brobecker@adacore.com>
8594 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
8595 * configure, config.in: Regenerate.
8596 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
8599 2015-05-12 Don Breazeal <donb@codesourcery.com>
8601 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
8602 PTRACE_EVENT_VFORK_DONE.
8603 (linux_low_ptrace_options, extended_event_reported): Add vfork
8605 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
8606 and "vforkdone" for RSP 'T' Stop Reply Packet.
8607 * server.h (report_vfork_events): Declare
8610 2015-05-12 Don Breazeal <donb@codesourcery.com>
8612 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
8613 (the_low_target) <new_fork>: Initialize new member.
8614 * linux-arm-low.c (arm_new_fork): New function.
8615 (the_low_target) <new_fork>: Initialize new member.
8616 * linux-low.c (handle_extended_wait): Call new target function
8618 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
8619 * linux-mips-low.c (mips_add_watchpoint): New function
8620 extracted from mips_insert_point.
8621 (the_low_target) <new_fork>: Initialize new member.
8622 (mips_linux_new_fork): New function.
8623 (mips_insert_point): Call mips_add_watchpoint.
8624 * linux-x86-low.c (x86_linux_new_fork): New function.
8625 (the_low_target) <new_fork>: Initialize new member.
8627 2015-05-12 Don Breazeal <donb@codesourcery.com>
8629 * linux-low.c (handle_extended_wait): Implement return value,
8630 rename argument 'event_child' to 'event_lwp', handle
8631 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
8632 (linux_low_ptrace_options): New function.
8633 (linux_low_filter_event): Call linux_low_ptrace_options,
8634 use different argument fo linux_enable_event_reporting,
8635 use return value from handle_extended_wait.
8636 (extended_event_reported): New function.
8637 (linux_wait_1): Call extended_event_reported and set
8638 status to report fork events.
8639 (linux_write_memory): Add pid to debug message.
8640 (reset_lwp_ptrace_options_callback): New function.
8641 (linux_handle_new_gdb_connection): New function.
8642 (linux_target_ops): Initialize new structure member.
8643 * linux-low.h (struct lwp_info) <waitstatus>: New member.
8644 * lynx-low.c: Initialize new structure member.
8645 * remote-utils.c (prepare_resume_reply): Implement stop reason
8646 "fork" for "T" stop message.
8647 * server.c (handle_query): Call handle_new_gdb_connection.
8648 * server.h (report_fork_events): Declare global flag.
8649 * target.h (struct target_ops) <handle_new_gdb_connection>:
8651 (target_handle_new_gdb_connection): New macro.
8652 * win32-low.c: Initialize new structure member.
8654 2015-05-12 Don Breazeal <donb@codesourcery.com>
8656 * mem-break.c (APPEND_TO_LIST): Define macro.
8657 (clone_agent_expr): New function.
8658 (clone_one_breakpoint): New function.
8659 (clone_all_breakpoints): New function.
8660 * mem-break.h: Declare new functions.
8662 2015-05-12 Don Breazeal <donb@codesourcery.com>
8664 * linux-low.c (linux_supports_fork_events): New function.
8665 (linux_supports_vfork_events): New function.
8666 (linux_target_ops): Initialize new structure members.
8667 (initialize_low): Call linux_check_ptrace_features.
8668 * lynx-low.c (lynx_target_ops): Initialize new structure
8670 * server.c (report_fork_events, report_vfork_events):
8672 (handle_query): Add new features to qSupported packet and
8674 (captured_main): Initialize new global variables.
8675 * target.h (struct target_ops) <supports_fork_events>:
8677 <supports_vfork_events>: New member.
8678 (target_supports_fork_events): New macro.
8679 (target_supports_vfork_events): New macro.
8680 * win32-low.c (win32_target_ops): Initialize new structure
8683 2015-05-12 Gary Benson <gbenson@redhat.com>
8685 * server.c (handle_qxfer_exec_file): Use current process
8688 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
8690 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
8691 Remove HAVE_PTRACE_GETREGS conditionals.
8692 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
8693 instead of PTRACE_GETREGS and PTRACE_SETREGS.
8695 2015-05-08 Yao Qi <yao.qi@linaro.org>
8697 * linux-low.c (linux_supports_conditional_breakpoints): New
8699 (linux_target_ops): Install new target method.
8700 * lynx-low.c (lynx_target_ops): Install NULL hook for
8701 supports_conditional_breakpoints.
8702 * nto-low.c (nto_target_ops): Likewise.
8703 * spu-low.c (spu_target_ops): Likewise.
8704 * win32-low.c (win32_target_ops): Likewise.
8705 * server.c (handle_query): Check
8706 target_supports_conditional_breakpoints.
8707 * target.h (struct target_ops) <supports_conditional_breakpoints>:
8709 (target_supports_conditional_breakpoints): New macro.
8711 2015-05-06 Pedro Alves <palves@redhat.com>
8714 * server.c (start_inferior): If the process exits, mourn it.
8716 2015-04-21 Gary Benson <gbenson@redhat.com>
8718 * hostio.c (fileio_open_flags_to_host): Factored out to
8719 fileio_to_host_openflags in common/fileio.c. Single use
8722 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
8724 * linux-xtensa-low.c (xtensa_fill_gregset)
8725 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
8728 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
8730 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
8731 (regs_info): Replace usrregs pointer with NULL.
8733 2015-04-17 Gary Benson <gbenson@redhat.com>
8735 * target.h (struct target_ops) <pid_to_exec_file>: New field.
8736 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
8737 * server.c (handle_qxfer_exec_file): New function.
8738 (qxfer_packets): Add exec-file entry.
8739 (handle_query): Report qXfer:exec-file:read as supported packet.
8741 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
8743 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
8745 2015-04-09 Gary Benson <gbenson@redhat.com>
8747 * hostio-errno.c (errno_to_fileio_error): Remove function.
8748 Update caller to use remote_fileio_to_fio_error.
8750 2015-04-09 Yao Qi <yao.qi@linaro.org>
8752 * linux-low.c (linux_insert_point): Call
8753 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
8754 (linux_remove_point): Call remove_memory_breakpoint if type is
8756 * linux-x86-low.c (x86_insert_point): Don't call
8757 insert_memory_breakpoint.
8758 (x86_remove_point): Don't call remove_memory_breakpoint.
8760 2015-04-01 Pedro Alves <palves@redhat.com>
8761 Cleber Rosa <crosa@redhat.com>
8763 * server.c (gdbserver_usage): Reorganize and extend the usage
8766 2015-03-24 Pedro Alves <palves@redhat.com>
8768 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
8769 output. Also dump TRAP_TRACE.
8770 (linux_low_filter_event): In debug output, distinguish a
8771 resume_stop SIGSTOP from a delayed SIGSTOP.
8773 2015-03-24 Gary Benson <gbenson@redhat.com>
8775 * linux-x86-low.c (x86_linux_new_thread): Moved to
8777 (x86_linux_prepare_to_resume): Likewise.
8779 2015-03-24 Gary Benson <gbenson@redhat.com>
8781 * Makefile.in (x86-linux-dregs.o): New rule.
8782 * configure.srv: Add x86-linux-dregs.o to relevant targets.
8783 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
8784 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
8785 (x86_linux_dr_get): Likewise.
8786 (x86_linux_dr_set): Likewise.
8787 (update_debug_registers_callback): Likewise.
8788 (x86_linux_dr_set_addr): Likewise.
8789 (x86_linux_dr_get_addr): Likewise.
8790 (x86_linux_dr_set_control): Likewise.
8791 (x86_linux_dr_get_control): Likewise.
8792 (x86_linux_dr_get_status): Likewise.
8793 (x86_linux_update_debug_registers): Likewise.
8795 2015-03-24 Gary Benson <gbenson@redhat.com>
8797 * linux-x86-low.c (x86_linux_update_debug_registers):
8798 New function, factored out from...
8799 (x86_linux_prepare_to_resume): ...this.
8801 2015-03-24 Gary Benson <gbenson@redhat.com>
8803 * linux-x86-low.c (x86_linux_dr_get): Update comments.
8804 (x86_linux_dr_set): Likewise.
8805 (update_debug_registers_callback): Likewise.
8806 (x86_linux_dr_set_addr): Likewise.
8807 (x86_linux_dr_get_addr): Likewise.
8808 (x86_linux_dr_set_control): Likewise.
8809 (x86_linux_dr_get_control): Likewise.
8810 (x86_linux_dr_get_status): Likewise.
8811 (x86_linux_prepare_to_resume): Likewise.
8813 2015-03-24 Gary Benson <gbenson@redhat.com>
8815 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
8816 Use perror_with_name. Pass string through gettext.
8817 (x86_linux_dr_set): Likewise.
8819 2015-03-24 Gary Benson <gbenson@redhat.com>
8821 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
8822 (x86_linux_dr_set_addr): ...this.
8823 (x86_dr_low_get_addr): Rename to...
8824 (x86_linux_dr_get_addr): ...this.
8825 (x86_dr_low_set_control): Rename to...
8826 (x86_linux_dr_set_control): ...this.
8827 (x86_dr_low_get_control): Rename to...
8828 (x86_linux_dr_get_control): ...this.
8829 (x86_dr_low_get_status): Rename to...
8830 (x86_linux_dr_get_status): ...this.
8831 (x86_dr_low): Update with new function names.
8833 2015-03-24 Gary Benson <gbenson@redhat.com>
8835 * Makefile.in (x86-linux.o): New rule.
8836 * configure.srv: Add x86-linux.o to relevant targets.
8837 * linux-low.c (lwp_set_arch_private_info): New function.
8838 (lwp_arch_private_info): Likewise.
8839 * linux-x86-low.c: Include nat/x86-linux.h.
8840 (arch_lwp_info): Removed structure.
8841 (update_debug_registers_callback):
8842 Use lwp_set_debug_registers_changed.
8843 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
8844 and lwp_set_debug_registers_changed.
8845 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
8847 2015-03-24 Gary Benson <gbenson@redhat.com>
8849 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
8850 * linux-arm-low.c (arm_new_thread): Likewise.
8851 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
8852 * linux-mips-low.c (mips_linux_new_thread): Likewise.
8853 * linux-x86-low.c (x86_linux_new_thread): Likewise.
8854 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
8856 2015-03-24 Gary Benson <gbenson@redhat.com>
8858 * linux-low.c (ptid_of_lwp): New function.
8859 (lwp_is_stopped): Likewise.
8860 (lwp_stop_reason): Likewise.
8861 * linux-x86-low.c (update_debug_registers_callback):
8863 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
8866 2015-03-24 Gary Benson <gbenson@redhat.com>
8868 * linux-low.h (linux_stop_lwp): Remove declaration.
8870 2015-03-24 Gary Benson <gbenson@redhat.com>
8872 * linux-low.h: Include nat/linux-nat.h.
8873 * linux-low.c (iterate_over_lwps_args): New structure.
8874 (iterate_over_lwps_filter): New function.
8875 (iterate_over_lwps): Likewise.
8876 * linux-x86-low.c (update_debug_registers_callback):
8877 Update signature to what iterate_over_lwps expects.
8878 Remove PID check that iterate_over_lwps now performs.
8879 (x86_dr_low_set_addr): Use iterate_over_lwps.
8880 (x86_dr_low_set_control): Likewise.
8882 2015-03-24 Gary Benson <gbenson@redhat.com>
8884 * linux-x86-low.c (x86_debug_reg_state): New function.
8885 (x86_linux_prepare_to_resume): Use the above.
8887 2015-03-24 Gary Benson <gbenson@redhat.com>
8889 * linux-low.c (current_lwp_ptid): New function.
8890 * linux-x86-low.c: Include nat/linux-nat.h.
8891 (x86_dr_low_get_addr): Use current_lwp_ptid.
8892 (x86_dr_low_get_control): Likewise.
8893 (x86_dr_low_get_status): Likewise.
8895 2015-03-20 Pedro Alves <palves@redhat.com>
8897 * tracepoint.c (cmd_qtstatus): Make "str" const.
8899 2015-03-20 Pedro Alves <palves@redhat.com>
8901 * server.c (handle_general_set): Make "req_str" const.
8903 2015-03-19 Pedro Alves <palves@redhat.com>
8905 * linux-low.c (linux_resume_one_lwp): Rename to ...
8906 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
8907 instead call perror_with_name.
8908 (check_ptrace_stopped_lwp_gone): New function.
8909 (linux_resume_one_lwp): Reimplement as wrapper around
8910 linux_resume_one_lwp_throw that swallows errors if the LWP is
8913 2015-03-19 Pedro Alves <palves@redhat.com>
8915 * linux-low.c (count_events_callback, select_event_lwp_callback):
8916 No longer check whether the thread has resume_stop as last resume
8919 2015-03-19 Pedro Alves <palves@redhat.com>
8921 * linux-low.c (count_events_callback, select_event_lwp_callback):
8922 Use the lwp's status_pending_p field, not the thread's.
8924 2015-03-19 Pedro Alves <palves@redhat.com>
8926 * linux-low.c (select_event_lwp_callback): Update comments to
8927 no longer mention SIGTRAP.
8929 2015-03-18 Gary Benson <gbenson@redhat.com>
8931 * server.c (handle_query): Do not report vFile:fstat as supported.
8933 2015-03-11 Gary Benson <gbenson@redhat.com>
8935 * hostio.c (sys/types.h): New include.
8936 (sys/stat.h): Likewise.
8937 (common-remote-fileio.h): Likewise.
8938 (handle_fstat): New function.
8939 (handle_vFile): Handle vFile:fstat packets.
8941 2015-03-11 Gary Benson <gbenson@redhat.com>
8943 * configure.ac (AC_CHECK_MEMBERS): Add checks for
8944 struct stat.st_blocks and struct stat.st_blksize.
8945 * configure: Regenerate.
8946 * config.in: Likewise.
8947 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
8948 (OBS): Add common-remote-fileio.o.
8949 (common-remote-fileio.o): New rule.
8951 2015-03-09 Pedro Alves <palves@redhat.com>
8953 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
8954 'struct sockaddr' pointer in 'accept' call.
8956 2015-03-09 Pedro Alves <palves@redhat.com>
8959 2015-03-07 Pedro Alves <palves@redhat.com>
8960 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
8961 or <winsock2.h> here. Instead include "gdb_socket.h".
8962 (remote_open): Use union gdb_sockaddr_u.
8963 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
8964 or <winsock2.h> here. Instead include "gdb_socket.h".
8965 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
8966 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
8968 (init_named_socket, gdb_agent_helper_thread): Use union
8971 2015-03-07 Pedro Alves <palves@redhat.com>
8973 * configure.ac (build_warnings): Move
8974 -Wdeclaration-after-statement to the C-specific set.
8975 * configure: Regenerate.
8977 2015-03-07 Pedro Alves <palves@redhat.com>
8979 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
8980 or <winsock2.h> here. Instead include "gdb_socket.h".
8981 (remote_open): Use union gdb_sockaddr_u.
8982 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
8983 or <winsock2.h> here. Instead include "gdb_socket.h".
8984 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
8985 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
8987 (init_named_socket, gdb_agent_helper_thread): Use union
8990 2015-03-07 Pedro Alves <palves@redhat.com>
8992 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
8995 2015-03-06 Yao Qi <yao.qi@linaro.org>
8997 * linux-aarch64-low.c (aarch64_insert_point): Use
8998 show_debug_regs as a boolean.
8999 (aarch64_remove_point): Likewise.
9001 2015-03-05 Pedro Alves <palves@redhat.com>
9003 * lynx-low.c (lynx_target_ops): Install NULL hooks for
9004 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
9005 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
9006 * nto-low.c (nto_target_ops): Likewise.
9007 * spu-low.c (spu_target_ops): Likewise.
9008 * win32-low.c (win32_target_ops): Likewise.
9010 2015-03-04 Pedro Alves <palves@redhat.com>
9012 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
9013 Decide whether a breakpoint triggered based on the SIGTRAP's
9015 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
9016 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
9017 (linux_low_filter_event): Check for breakpoints before checking
9019 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
9021 (linux_stopped_by_sw_breakpoint)
9022 (linux_supports_stopped_by_sw_breakpoint)
9023 (linux_stopped_by_hw_breakpoint)
9024 (linux_supports_stopped_by_hw_breakpoint): New functions.
9025 (linux_target_ops): Install new target methods.
9027 2015-03-04 Pedro Alves <palves@redhat.com>
9029 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
9030 * server.c (swbreak_feature, hwbreak_feature): New globals.
9031 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
9032 (captured_main): Clear swbreak_feature and hwbreak_feature.
9033 * server.h (swbreak_feature, hwbreak_feature): Declare.
9034 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
9035 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
9036 supports_stopped_by_hw_breakpoint>: New fields.
9037 (target_supports_stopped_by_sw_breakpoint)
9038 (target_stopped_by_sw_breakpoint)
9039 (target_supports_stopped_by_hw_breakpoint)
9040 (target_stopped_by_hw_breakpoint): Declare.
9042 2015-03-04 Pedro Alves <palves@redhat.com>
9044 enum lwp_stop_reason -> enum target_stop_reason
9045 * linux-low.c (check_stopped_by_breakpoint): Adjust.
9046 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
9047 (linux_wait_1, stuck_in_jump_pad_callback)
9048 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
9049 (linux_stopped_by_watchpoint):
9050 * linux-low.h (enum lwp_stop_reason): Delete.
9051 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
9052 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
9054 2015-03-04 Yao Qi <yao.qi@linaro.org>
9056 * Makefile.in (SFILES): Add linux-aarch64-low.c.
9058 2015-03-03 Gary Benson <gbenson@redhat.com>
9060 * hostio.c (handle_vFile): Fix prefix lengths.
9062 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
9064 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
9067 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
9069 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
9070 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
9071 (clean): Add "rm -f" for above C files.
9072 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
9073 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
9074 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
9075 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
9076 * linux-s390-low.c (HWCAP_S390_VX): New macro.
9077 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
9078 (init_registers_s390x_vx_linux64)
9079 (init_registers_s390x_tevx_linux64)
9080 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
9081 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
9083 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
9084 (s390_store_vxrs_high): New functions.
9085 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
9087 (s390_arch_setup): Add logic for selecting one of the new target
9088 descriptions. Activate the new vector regsets if applicable.
9089 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
9090 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
9091 and init_registers_s390x_tevx_linux64.
9093 2015-03-01 Pedro Alves <palves@redhat.com>
9095 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
9098 2015-02-27 Pedro Alves <palves@redhat.com>
9100 * linux-x86-low.c (u_debugreg_offset): New function.
9101 (x86_linux_dr_get, x86_linux_dr_set): Use it.
9103 2015-02-27 Pedro Alves <palves@redhat.com>
9105 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
9106 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
9107 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
9108 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
9109 (ps_lsetfpregs, ps_getpid)
9110 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
9111 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
9112 (ps_lsetxregs, ps_plog): Declare.
9114 2015-02-27 Pedro Alves <palves@redhat.com>
9116 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
9117 IP_AGENT_EXPORT_FUNC.
9118 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
9119 IP_AGENT_EXPORT_FUNC.
9120 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
9121 (IP_AGENT_EXPORT): Delete.
9122 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
9123 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
9124 (gdb_trampoline_buffer_error, collecting, gdb_collect)
9125 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
9126 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
9127 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
9128 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
9129 (traceframe_read_count, traceframe_write_count)
9130 (traceframes_created, trace_state_variables, get_raw_reg)
9131 (get_trace_state_variable_value, set_trace_state_variable_value)
9132 (ust_loaded, helper_thread_id, cmd_buf): Use
9133 IPA_SYM_EXPORTED_NAME.
9134 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
9135 (tracepoints) Use IP_AGENT_EXPORT_VAR.
9136 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
9137 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
9138 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
9139 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
9140 EXTERN_C_PUSH/EXTERN_C_POP.
9141 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
9142 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
9143 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
9144 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
9145 (traceframe_write_count, traceframe_read_count)
9146 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
9147 (about_to_request_buffer_space, get_trace_state_variable_value)
9148 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
9149 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
9150 EXTERN_C_PUSH/EXTERN_C_POP.
9151 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
9152 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
9153 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
9154 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
9155 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
9156 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
9157 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
9158 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
9160 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
9161 (IP_AGENT_EXPORT_VAR_DECL): Define.
9163 (gdb_agent_get_raw_reg): Declare.
9165 2015-02-27 Tom Tromey <tromey@redhat.com>
9166 Pedro Alves <palves@redhat.com>
9168 Rename symbols whose names are reserved C++ keywords throughout.
9170 2015-02-27 Pedro Alves <palves@redhat.com>
9172 * Makefile.in (COMPILER): New, get it from autoconf.
9173 (CXX): Get from autoconf instead.
9174 (COMPILE.pre): Use COMPILER.
9175 (CC-LD): Rename to ...
9176 (CC_LD): ... this. Use COMPILER.
9177 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
9178 (CXX_FOR_TARGET): Default to g++ instead of gcc.
9179 * acinclude.m4: Include build-with-cxx.m4.
9180 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
9181 Disable -Werror by default if building in C++ mode.
9182 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
9183 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
9184 the C++ compiler. Save/restore CXXFLAGS too.
9185 * configure: Regenerate.
9187 2015-02-27 Pedro Alves <palves@redhat.com>
9189 * acinclude.m4: Include libiberty.m4.
9190 * configure.ac: Call libiberty_INIT.
9191 * config.in, configure: Regenerate.
9193 2015-02-26 Pedro Alves <palves@redhat.com>
9195 * linux-low.c (linux_wait_1): When incrementing the PC past a
9196 program breakpoint always use the_low_target.breakpoint_len as
9197 increment, rather than the maximum between that and
9198 the_low_target.decr_pc_after_break.
9200 2015-02-23 Pedro Alves <palves@redhat.com>
9202 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
9203 thread was doing a step-over; always adjust the PC if
9204 we stepped over a permanent breakpoint.
9205 (linux_wait_1): If we stepped over breakpoint that was on top of a
9206 permanent breakpoint, manually advance the PC past it.
9208 2015-02-23 Pedro Alves <palves@redhat.com>
9210 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
9212 (x86_fill_gregset, x86_store_gregset): Use it when handling
9215 2015-02-20 Pedro Alves <palves@redhat.com>
9217 * thread-db.c: Include "nat/linux-procfs.h".
9218 (thread_db_init): Skip listing new threads if the kernel supports
9219 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
9221 2015-02-20 Pedro Alves <palves@redhat.com>
9223 * linux-low.c (status_pending_p_callback): Use ptid_match.
9225 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
9227 PR breakpoints/16812
9228 * linux-low.c (wstatus_maybe_breakpoint): Remove.
9229 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
9230 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
9232 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
9234 PR breakpoints/15956
9235 * tracepoint.c (cmd_qtinit): Add check for current_thread.
9237 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
9239 * linux-low.c (linux_low_btrace_conf): Print size.
9240 * server.c (handle_btrace_conf_general_set): New.
9241 (hanle_general_set): Call handle_btrace_conf_general_set.
9242 (handle_query): Report Qbtrace-conf:bts:size as supported.
9244 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
9246 * linux-low.c (linux_low_enable_btrace): Update parameters.
9247 (linux_low_btrace_conf): New.
9248 (linux_target_ops)<to_btrace_conf>: Initialize.
9249 * server.c (current_btrace_conf): New.
9250 (handle_btrace_enable): Rename to ...
9251 (handle_btrace_enable_bts): ... this. Pass ¤t_btrace_conf
9252 to target_enable_btrace. Update comment. Update users.
9253 (handle_qxfer_btrace_conf): New.
9254 (qxfer_packets): Add btrace-conf entry.
9255 (handle_query): Report qXfer:btrace-conf:read as supported packet.
9256 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
9257 (target_ops)<read_btrace_conf>: New.
9258 (target_enable_btrace): Update parameters.
9259 (target_read_btrace_conf): New.
9261 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
9263 * server.c (handle_btrace_general_set): Remove call to
9264 target_supports_btrace.
9265 (supported_btrace_packets): New.
9266 (handle_query): Call supported_btrace_packets.
9267 * target.h: include btrace-common.h.
9268 (btrace_target_info): Removed.
9269 (supports_btrace, target_supports_btrace): Update parameters.
9271 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
9273 * Makefile.in (SFILES): Add common/btrace-common.c.
9274 (OBS): Add common/btrace-common.o.
9275 (btrace-common.o): Add build rules.
9276 * linux-low: Include btrace-common.h.
9277 (linux_low_read_btrace): Use struct btrace_data. Call
9278 btrace_data_init and btrace_data_fini.
9280 2015-02-06 Pedro Alves <palves@redhat.com>
9282 * thread-db.c (find_new_threads_callback): Add debug output.
9284 2015-02-04 Pedro Alves <palves@redhat.com>
9286 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
9287 (resume_stopped_resumed_lwps): New function.
9288 (linux_wait_for_event_filtered): Use it.
9290 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
9292 * Makefile.in (SFILES): Add linux-personality.c.
9293 (linux-personality.o): New rule.
9294 * configure.srv (srv_linux_obj): Add linux-personality.o to the
9295 list of objects to be built.
9296 * linux-low.c: Include nat/linux-personality.h.
9297 (linux_create_inferior): Remove code to disable address space
9298 randomization (moved to ../nat/linux-personality.c). Create
9299 cleanup to disable address space randomization.
9301 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
9303 * Makefile.in (posix-strerror.o): New rule.
9304 (mingw-strerror.o): Likewise.
9305 * configure: Regenerated.
9306 * configure.ac: Source file ../common/common.host. Initialize new
9307 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
9309 2015-01-14 Yao Qi <yao@codesourcery.com>
9311 * Makefile.in (SFILES): Add nat/ppc-linux.c.
9312 (ppc-linux.o): New rule.
9313 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
9314 * configure.ac: AC_CHECK_FUNCS(getauxval).
9315 * config.in: Re-generated.
9316 * configure: Re-generated.
9317 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
9318 ppc64_64bit_inferior_p
9320 2015-01-14 Yao Qi <yao@codesourcery.com>
9322 * linux-ppc-low.c: Include "nat/ppc-linux.h".
9323 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
9324 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
9325 (PT_ORIG_R3, PT_TRAP): Likewise.
9326 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
9327 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
9328 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
9330 2015-01-10 Joel Brobecker <brobecker@adacore.com>
9332 * i387-fp.c (i387_cache_to_xsave): In look over
9333 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
9334 zmmh_low_space field by use of zmmh_high_space.
9336 2015-01-09 Pedro Alves <palves@redhat.com>
9338 * linux-low.c (step_over_bkpt): Move higher up in the file.
9339 (handle_extended_wait): Don't store the stop_pc here.
9340 (get_stop_pc): Adjust comments and rename to ...
9341 (check_stopped_by_breakpoint): ... this. Record whether the LWP
9342 stopped for a software breakpoint or hardware breakpoint.
9343 (thread_still_has_status_pending_p): New function.
9344 (status_pending_p_callback): Use
9345 thread_still_has_status_pending_p. If the event is no longer
9346 interesting, resume the LWP.
9347 (handle_tracepoints): Add assert.
9348 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
9349 (wstatus_maybe_breakpoint): New function.
9350 (cancel_breakpoint): Delete function.
9351 (check_stopped_by_watchpoint): New function, factored out from
9352 linux_low_filter_event.
9353 (lp_status_maybe_breakpoint): Delete function.
9354 (linux_low_filter_event): Remove filter_ptid argument.
9355 Leave thread group exits pending here. Store the LWP's stop PC.
9356 Always leave events pending.
9357 (linux_wait_for_event_filtered): Pull all events out of the
9358 kernel, and leave them all pending.
9359 (count_events_callback, select_event_lwp_callback): Consider all
9361 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
9362 (select_event_lwp): Only give preference to the stepping LWP in
9363 all-stop mode. Adjust comments.
9364 (ignore_event): New function.
9365 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
9366 references to cancel_breakpoints. Adjust to renames. Also give
9367 equal priority to all LWPs that have had events in non-stop mode.
9368 If reporting a software breakpoint event, unadjust the LWP's PC.
9369 (linux_wait): If linux_wait_1 returned an ignored event, retry.
9370 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
9372 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
9373 (resume_status_pending_p): Use thread_still_has_status_pending_p.
9374 (linux_stopped_by_watchpoint): Adjust.
9375 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
9376 * linux-low.h (enum lwp_stop_reason): New.
9377 (struct lwp_info) <stop_pc>: Adjust comment.
9378 <stopped_by_watchpoint>: Delete field.
9379 <stop_reason>: New field.
9380 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
9381 * mem-break.c (software_breakpoint_inserted_here)
9382 (hardware_breakpoint_inserted_here): New function.
9383 * mem-break.h (software_breakpoint_inserted_here)
9384 (hardware_breakpoint_inserted_here): Declare.
9385 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
9386 (cancel_breakpoints): Delete.
9387 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
9388 (upload_fast_traceframes): Remove references to
9391 2015-01-09 Pedro Alves <palves@redhat.com>
9393 * thread-db.c (find_new_threads_callback): Ignore thread if the
9394 kernel thread ID is -1.
9396 2015-01-09 Pedro Alves <palves@redhat.com>
9398 * linux-low.c (linux_attach_fail_reason_string): Move to
9399 nat/linux-ptrace.c, and rename.
9400 (linux_attach_lwp): Update comment.
9401 (attach_proc_task_lwp_callback): New function.
9402 (linux_attach): Adjust to rename and use
9403 linux_proc_attach_tgid_threads.
9404 (linux_attach_fail_reason_string): Delete declaration.
9406 2015-01-01 Joel Brobecker <brobecker@adacore.com>
9408 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
9409 * server.c (gdbserver_version): Likewise.
9411 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
9413 * remote-utils.c: Include ctype.h.
9414 (input_interrupt): Explicitly handle the case when the char
9415 received is the NUL byte. Improve the printing of non-ASCII
9418 2014-12-16 Joel Brobecker <brobecker@adacore.com>
9420 * linux-low.c (linux_low_filter_event): Update call to
9421 linux_enable_event_reporting following the addition of
9422 a new parameter to that function.
9424 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
9427 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
9428 (AARCH64_FPCR_REGNO): Likewise.
9429 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
9430 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
9431 (aarch64_store_fpregset): Likewise.
9433 2014-12-15 Joel Brobecker <brobecker@adacore.com>
9435 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
9436 Remove FIXME comment about assumption about N.
9438 2014-12-13 Joel Brobecker <brobecker@adacore.com>
9440 * configure.ac: If large-file support is disabled in GDBserver,
9441 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
9442 * configure: Regenerate.
9444 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
9446 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
9447 warning upon ENODATA from ptrace.
9448 * linux-s390-low.c (s390_store_tdb): New.
9449 (s390_regsets): Add regset for NT_S390_TDB.
9451 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
9453 * linux-low.c (regsets_store_inferior_registers): Skip regsets
9454 without a fill_function.
9455 * linux-s390-low.c (s390_fill_last_break): Remove.
9456 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
9457 (s390_arch_setup): Use regset's size instead of fill_function for
9460 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
9462 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
9463 the regset's store function when ptrace returned an error.
9464 * regcache.c (get_thread_regcache): Invalidate register cache
9465 before fetching inferior's registers.
9467 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
9469 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
9470 while-loop as for-loop.
9471 (regsets_store_inferior_registers): Likewise.
9473 2014-11-28 Yao Qi <yao@codesourcery.com>
9475 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
9476 * config.in, configure: Re-generate.
9477 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
9480 2014-11-21 Yao Qi <yao@codesourcery.com>
9482 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
9483 (AC_CHECK_HEADERS): Remove malloc.h.
9484 * configure: Re-generated.
9485 * config.in: Re-generated.
9486 * server.h: Don't include alloca.h and malloc.h.
9487 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
9488 Don't include malloc.h.
9490 2014-11-17 Joel Brobecker <brobecker@adacore.com>
9492 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
9493 corresponding ERRNO check in same block.
9495 2014-11-12 Pedro Alves <palves@redhat.com>
9497 * server.c (cont_thread): Update comment.
9498 (start_inferior, attach_inferior): No longer clear cont_thread.
9499 (handle_v_cont): No longer set cont_thread.
9500 (captured_main): Clear cont_thread each time a GDB connects.
9502 2014-11-12 Pedro Alves <palves@redhat.com>
9504 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
9505 thread, and don't resume all threads if the Hc thread has exited.
9507 2014-11-12 Pedro Alves <palves@redhat.com>
9509 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
9510 the process group instead of to a specific LWP.
9512 2014-10-15 Pedro Alves <palves@redhat.com>
9515 * win32-arm-low.c (arm_set_thread_context): Remove current_event
9517 (arm_set_thread_context): Delete.
9518 (the_low_target): Adjust.
9519 * win32-i386-low.c (debug_registers_changed)
9520 (debug_registers_used): Delete.
9521 (update_debug_registers_callback): New function.
9522 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
9523 needing to update their debug registers.
9524 (win32_get_current_dr): New function.
9525 (x86_dr_low_get_addr, x86_dr_low_get_control)
9526 (x86_dr_low_get_status): Fetch the debug register from the thread
9528 (i386_initial_stuff): Adjust.
9529 (i386_get_thread_context): Remove current_event parameter. Don't
9530 clear debug_registers_changed nor copy DR values to
9532 (i386_set_thread_context): Delete.
9533 (i386_prepare_to_resume): New function.
9534 (i386_thread_added): Mark the thread as needing to update irs
9536 (the_low_target): Remove i386_set_thread_context and install
9537 i386_prepare_to_resume.
9538 * win32-low.c (win32_get_thread_context): Adjust.
9539 (win32_set_thread_context): Use SetThreadContext
9541 (win32_prepare_to_resume): New function.
9542 (win32_require_context): New function, factored out from ...
9543 (thread_rec): ... this.
9544 (continue_one_thread): Call win32_prepare_to_resume on each thread
9545 we're about to continue.
9546 (win32_resume): Call win32_prepare_to_resume on the event thread.
9547 * win32-low.h (struct win32_thread_info)
9548 <debug_registers_changed>: New field.
9549 (struct win32_target_ops): Change prototype of set_thread_context,
9550 delete set_thread_context and add prepare_to_resume.
9551 (win32_require_context): New declaration.
9553 2014-10-08 Gary Benson <gbenson@redhat.com>
9555 * server.h: Do not include common-exceptions.h.
9557 2014-10-08 Gary Benson <gbenson@redhat.com>
9559 * server.h: Do not include cleanups.h.
9561 2014-09-30 James Hogan <james.hogan@imgtec.com>
9563 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
9566 2014-09-23 Yao Qi <yao@codesourcery.com>
9568 * linux-low.c (lp_status_maybe_breakpoint): New function.
9569 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
9570 (count_events_callback): Likewise.
9571 (select_event_lwp_callback): Likewise.
9572 (cancel_breakpoints_callback): Likewise.
9574 2014-09-19 Don Breazeal <donb@codesourcery.com>
9576 * linux-low.c (handle_extended_wait): Call
9577 linux_ptrace_get_extended_event.
9578 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
9579 linux_is_extended_waitstatus.
9581 2014-09-16 Joel Brobecker <brobecker@adacore.com>
9583 * Makefile.in (CPPFLAGS): Define.
9584 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
9585 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
9587 2014-09-16 Gary Benson <gbenson@redhat.com>
9589 * inferiors.h (current_inferior): Renamed as...
9590 (current_thread): New variable. All uses updated.
9591 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
9592 (maybe_move_out_of_jump_pad): Likewise.
9593 (cancel_breakpoint): Likewise.
9594 (linux_low_filter_event): Likewise.
9595 (wait_for_sigstop): Likewise.
9596 (linux_resume_one_lwp): Likewise.
9597 (need_step_over_p): Likewise.
9598 (start_step_over): Likewise.
9599 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
9600 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
9601 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
9602 and save_inferior as saved_thread.
9603 * regcache.c (get_thread_regcache): Renamed saved_inferior as
9605 (regcache_invalidate_thread): Likewise.
9606 * remote-utils.c (prepare_resume_reply): Likewise.
9607 * thread-db.c (thread_db_get_tls_address): Likewise.
9608 (disable_thread_event_reporting): Likewise.
9609 (remove_thread_event_breakpoints): Likewise.
9610 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
9612 * target.h (set_desired_inferior): Renamed as...
9613 (set_desired_thread): New declaration. All uses updated.
9614 * server.c (myresume): Updated comment to reference thread instead
9616 (handle_serial_event): Likewise.
9617 (handle_target_event): Likewise.
9619 2014-09-12 Tom Tromey <tromey@redhat.com>
9620 Gary Benson <gbenson@redhat.com>
9622 * regcache.h: Include common-regcache.h.
9623 (regcache_read_pc): Don't declare.
9624 * regcache.c (get_thread_regcache_for_ptid): New function.
9626 2014-09-11 Tom Tromey <tromey@redhat.com>
9627 Gary Benson <gbenson@redhat.com>
9629 * symbol.c: New file.
9630 * Makefile.in (SFILES): Add symbol.c.
9631 (OBS): Add symbol.o.
9633 2014-09-11 Gary Benson <gbenson@redhat.com>
9635 * target.c (target_stop_ptid, target_continue_ptid): New
9638 2014-09-11 Tom Tromey <tromey@redhat.com>
9639 Gary Benson <gbenson@redhat.com>
9641 * target.h: Include target/target.h.
9642 * target.c (target_read_memory, target_read_uint32)
9643 (target_write_memory): New functions.
9645 2014-09-11 Gary Benson <gbenson@redhat.com>
9647 * server.h (debug_hw_points): Don't declare.
9648 * server.c (debug_hw_points): Don't define. Replace all uses
9649 with show_debug_regs.
9650 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
9651 all uses with show_debug_regs.
9653 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
9655 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
9656 endianness into account.
9657 (ppc_supply_ptrace_register): Likewise.
9659 2014-09-03 James Hogan <james.hogan@imgtec.com>
9661 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
9662 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
9664 2014-09-03 Gary Benson <gbenson@redhat.com>
9666 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
9667 ALL_DEBUG_ADDRESS_REGISTERS.
9669 2014-09-02 Gary Benson <gbenson@redhat.com>
9671 * i386-low.h: Renamed as...
9672 * x86-low.h: New file. All type, function and variable name
9673 prefixes changed from "i386_" to "x86_". All references updated.
9674 * i386-low.c: Renamed as...
9675 * x86-low.c: New file. All type, function and variable name
9676 prefixes changed from "i386_" to "x86_". All references updated.
9678 2014-09-02 Gary Benson <gbenson@redhat.com>
9680 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
9681 (x86_linux_new_thread): Likewise.
9683 2014-08-29 Gary Benson <gbenson@redhat.com>
9685 * server.h (setjmp.h): Do not include.
9686 (toplevel): Do not declare.
9687 (common-exceptions.h): Include.
9688 (cleanups.h): Likewise.
9689 * server.c (toplevel): Do not define.
9690 (exit_code): New static global.
9691 (detach_or_kill_for_exit_cleanup): New function.
9692 (main): New function. Original main renamed to...
9693 (captured_main): New function.
9694 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
9696 2014-08-29 Gary Benson <gbenson@redhat.com>
9698 * Makefile.in (SFILES): Add common/common-exceptions.c.
9699 (OBS): Add common-exceptions.o.
9700 (common-exceptions.o): New rule.
9701 * utils.c (prepare_to_throw_exception): New function.
9703 2014-08-29 Gary Benson <gbenson@redhat.com>
9705 * config.in: Regenerate.
9706 * configure: Likewise.
9708 2014-08-29 Gary Benson <gbenson@redhat.com>
9710 * Makefile.in (SFILES): Add common/cleanups.c.
9712 (cleanups.o): New rule.
9714 2014-08-29 Gary Benson <gbenson@redhat.com>
9716 * utils.c (internal_vwarning): New function.
9718 2014-08-28 Gary Benson <gbenson@redhat.com>
9720 * utils.h (fatal): Remove declaration.
9721 * utils.c (fatal): Remove function.
9723 2014-08-28 Gary Benson <gbenson@redhat.com>
9725 * tracepoint.c (gdb_agent_init): Replace fatal with
9727 (initialize_tracepoint): Likewise.
9729 2014-08-28 Gary Benson <gbenson@redhat.com>
9731 * remote-utils.c (remote_prepare): Replace fatal with error.
9733 2014-08-28 Gary Benson <gbenson@redhat.com>
9735 * linux-low.c (linux_async): Replace fatal with warning.
9737 (linux_start_non_stop): Return -1 if linux_async failed.
9739 2014-08-28 Gary Benson <gbenson@redhat.com>
9741 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
9743 (i386_dr_low_get_addr): Remove vague comment.
9744 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
9747 2014-08-28 Gary Benson <gbenson@redhat.com>
9749 * inferiors.c (get_thread_process): Replace check with gdb_assert.
9750 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
9752 (linux_resume_one_lwp): Likewise.
9753 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
9755 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
9756 with internal_error.
9757 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
9758 (init_register_cache): Replace fatal with gdb_assert_not_reached.
9759 (find_register_by_name): Replace fatal with internal_error.
9760 (find_regno): Likewise.
9761 * tdesc.c (init_target_desc): Replace check with gdb_assert.
9762 * thread-db.c (thread_db_create_event): Likewise.
9763 (thread_db_load_search): Likewise.
9764 (try_thread_db_load_1): Likewise.
9765 * tracepoint.c (get_jump_space_head): Replace fatal with
9767 (claim_trampoline_space): Likewise.
9768 (have_fast_tracepoint_trampoline_buffer): Likewise.
9769 (cmd_qtstart): Likewise.
9770 (stop_tracing): Likewise.
9771 (fast_tracepoint_collecting): Likewise.
9772 (target_malloc): Likewise.
9773 (download_tracepoint): Likewise.
9774 (download_trace_state_variables): Replace check with gdb_assert.
9775 (upload_fast_traceframes): Replace fatal with internal_error.
9777 2014-08-19 Tom Tromey <tromey@redhat.com>
9778 Gary Benson <gbenson@redhat.com>
9780 * Makefile.in (SFILES): Add common/common-debug.c.
9781 (OBS): Add common-debug.o.
9782 (common-debug.o): New rule.
9783 * debug.h (debug_printf): Don't declare.
9784 * debug.c (debug_printf): Renamed and rewritten as...
9785 (debug_vprintf): New function.
9787 2014-08-19 Gary Benson <gbenson@redhat.com>
9789 * utils.h: Do not include print-utils.h.
9791 2014-08-19 Tom Tromey <tromey@redhat.com>
9792 Gary Benson <gbenson@redhat.com>
9794 * server.h: Add static assertion.
9795 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
9797 2014-08-19 Tom Tromey <tromey@redhat.com>
9798 Gary Benson <gbenson@redhat.com>
9800 * Makefile.in (SFILES): Add common/errors.c.
9801 (OBS): Add errors.o.
9802 (IPA_OBS): Add errors-ipa.o.
9803 (errors.o): New rule.
9804 (errors-ipa.o): Likewise.
9805 * utils.h (perror_with_name, error, warning): Don't declare.
9806 * utils.c (warning): Renamed and rewritten as...
9807 (vwarning): New function.
9808 (error): Renamed and rewritten as...
9809 (verror): New function.
9810 (internal_error): Renamed and rewritten as...
9811 (internal_verror): New function.
9813 2014-08-07 Gary Benson <gbenson@redhat.com>
9815 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
9816 * configure: Regenerate.
9817 * config.in: Likewise.
9818 * server.h: Do not include errno.h.
9819 * event-loop.c: Likewise.
9820 * hostio-errno.c: Likewise.
9821 * linux-low.c: Likewise.
9822 * remote-utils.c: Likewise.
9823 * spu-low.c: Likewise.
9824 * utils.c: Likewise.
9825 * gdbreplay.c: Unconditionally include errno.h.
9827 2014-08-07 Gary Benson <gbenson@redhat.com>
9829 * server.h: Do not include string.h.
9830 * event-loop.c: Likewise.
9831 * linux-low.c: Likewise.
9832 * regcache.c: Likewise.
9833 * remote-utils.c: Likewise.
9834 * spu-low.c: Likewise.
9835 * utils.c: Likewise.
9837 2014-08-07 Gary Benson <gbenson@redhat.com>
9839 * server.h: Do not include gdb_assert.h.
9841 2014-08-07 Gary Benson <gbenson@redhat.com>
9843 * server.h: Do not include common-utils.h.
9845 2014-08-07 Gary Benson <gbenson@redhat.com>
9847 * server.h: Do not include ptid.h.
9848 * notif.h: Likewise.
9850 2014-08-07 Gary Benson <gbenson@redhat.com>
9852 * server.h: Do not include gdb_locale.h.
9854 2014-08-07 Gary Benson <gbenson@redhat.com>
9856 * server.h: Do not include gdb/signals.h.
9857 * win32-low.c: Likewise.
9859 2014-08-07 Gary Benson <gbenson@redhat.com>
9861 * server.h: Do not include pathmax.h.
9863 2014-08-07 Gary Benson <gbenson@redhat.com>
9865 * server.h: Do not include libiberty.h.
9866 * linux-bfin-low.c: Likewise.
9868 2014-08-07 Gary Benson <gbenson@redhat.com>
9870 * server.h: Do not include ansidecl.h.
9872 2014-08-07 Gary Benson <gbenson@redhat.com>
9874 * linux-x86-low.c: Do not include stddef.h.
9875 * lynx-ppc-low.c: Likewise.
9876 * tracepoint.c: Likewise.
9878 2014-08-07 Gary Benson <gbenson@redhat.com>
9880 * server.h: Do not include stdarg.h.
9881 * nto-low.c: Likewise.
9883 2014-08-07 Gary Benson <gbenson@redhat.com>
9885 * server.h: Do not include stdlib.h.
9886 * inferiors.c: Likewise.
9887 * linux-low.c: Likewise.
9888 * regcache.c: Likewise.
9889 * spu-low.c: Likewise.
9890 * tracepoint.c: Likewise.
9891 * utils.c: Likewise.
9893 2014-08-07 Gary Benson <gbenson@redhat.com>
9895 * server.h: Do not include stdio.h.
9896 * linux-low.c: Likewise.
9897 * remote-utils.c: Likewise.
9898 * spu-low.c: Likewise.
9899 * utils.c: Likewise.
9900 * wincecompat.c: Likewise.
9902 2014-08-06 Gary Benson <gbenson@redhat.com>
9904 * regcache.c (init_register_cache): Move conditionals inside if.
9906 2014-08-06 Gary Benson <gbenson@redhat.com>
9908 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
9910 2014-07-31 Gary Benson <gbenson@redhat.com>
9912 * ax.h: Do not include server.h.
9913 * gdbthread.h: Likewise.
9914 * lynx-low.h: Likewise.
9915 * notif.h: Likewise.
9917 2014-07-30 Gary Benson <gbenson@redhat.com>
9919 * server.h: Include common-defs.h.
9920 Do not include config.h or build-gnulib-gdbserver/config.h.
9922 2014-07-30 Gary Benson <gbenson@redhat.com>
9924 * hostio-errno.c: Move server.h to top of includes list.
9925 * inferiors.c: Likewise.
9926 * linux-x86-low.c: Likewise.
9927 * notif.c: Include server.h.
9929 2014-07-24 Tom Tromey <tromey@redhat.com>
9930 Gary Benson <gbenson@redhat.com>
9932 * server.h (CORE_ADDR): Now unsigned.
9934 2014-07-16 Pedro Alves <palves@redhat.com>
9936 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
9938 2014-07-15 Pedro Alves <palves@redhat.com>
9940 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
9943 2014-07-11 Pedro Alves <palves@redhat.com>
9945 * linux-low.c (kill_wait_lwp): New function, based on
9946 kill_one_lwp_callback, but use my_waitpid directly.
9947 (kill_one_lwp_callback, linux_kill): Use it.
9949 2014-06-23 Pedro Alves <palves@redhat.com>
9951 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
9952 before setting DR0..DR3.
9954 2014-06-20 Gary Benson <gbenson@redhat.com>
9956 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
9957 * configure: Regenerated.
9958 * config.in: Likewise.
9960 2014-06-20 Gary Benson <gbenson@redhat.com>
9962 * Makefile.in (SFILES): Update locations for files moved
9964 (object file files): Reordered.
9966 2014-06-20 Gary Benson <gbenson@redhat.com>
9968 * i386-low.h (i386_dr_low_can_set_addr): Removed.
9969 (i386_dr_low_set_addr): Likewise.
9970 (i386_dr_low_get_addr): Likewise.
9971 (i386_dr_low_can_set_control): Likewise.
9972 (i386_dr_low_set_control): Likewise.
9973 (i386_dr_low_get_control): Likewise.
9974 (i386_dr_low_get_status): Likewise.
9975 (i386_get_debug_register_length): Likewise.
9976 * linux-x86-low.c (i386_dr_low_set_addr):
9977 Changed signature. Made static.
9978 (i386_dr_low_get_addr): Likewise.
9979 (i386_dr_low_set_control): Likewise.
9980 (i386_dr_low_get_control): Likewise.
9981 (i386_dr_low_get_status): Likewise.
9982 (i386_dr_low): New global variable.
9983 * win32-i386-low.c (i386_dr_low_set_addr):
9984 Changed signature. Made static.
9985 (i386_dr_low_get_addr): Likewise.
9986 (i386_dr_low_set_control): Likewise.
9987 (i386_dr_low_get_control): Likewise.
9988 (i386_dr_low_get_status): Likewise.
9989 (i386_dr_low): New global variable.
9991 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
9993 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
9994 * Makefile.in (AR, AR_FLAGS): Define.
9995 * configure: Regenerate.
9997 2014-06-19 Gary Benson <gbenson@redhat.com>
9999 * Makefile.in (i386-dregs.o): New rule.
10000 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
10001 * i386-low.c (target.h): Remove include.
10002 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
10003 (DR_CONTROL_SHIFT): Likewise.
10004 (DR_CONTROL_SIZE): Likewise.
10005 (DR_RW_EXECUTE): Likewise.
10006 (DR_RW_WRITE): Likewise.
10007 (DR_RW_READ): Likewise.
10008 (DR_RW_IORW): Likewise.
10009 (DR_LEN_1): Likewise.
10010 (DR_LEN_2): Likewise.
10011 (DR_LEN_4): Likewise.
10012 (DR_LEN_8): Likewise.
10013 (DR_LOCAL_ENABLE_SHIFT): Likewise.
10014 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
10015 (DR_ENABLE_SIZE): Likewise.
10016 (DR_LOCAL_SLOWDOWN): Likewise.
10017 (DR_GLOBAL_SLOWDOWN): Likewise.
10018 (DR_CONTROL_RESERVED): Likewise.
10019 (I386_DR_CONTROL_MASK): Likewise.
10020 (I386_DR_VACANT): Likewise.
10021 (I386_DR_LOCAL_ENABLE): Likewise.
10022 (I386_DR_GLOBAL_ENABLE): Likewise.
10023 (I386_DR_DISABLE): Likewise.
10024 (I386_DR_SET_RW_LEN): Likewise.
10025 (I386_DR_GET_RW_LEN): Likewise.
10026 (I386_DR_WATCH_HIT): Likewise.
10027 (i386_wp_op_t): Likewise.
10028 (i386_show_dr): Likewise.
10029 (i386_length_and_rw_bits): Likewise.
10030 (i386_insert_aligned_watchpoint): Likewise.
10031 (i386_remove_aligned_watchpoint): Likewise.
10032 (i386_handle_nonaligned_watchpoint): Likewise.
10033 i386_update_inferior_debug_regs(): Likewise.
10034 (i386_dr_insert_watchpoint): Likewise.
10035 (i386_dr_remove_watchpoint): Likewise.
10036 (i386_dr_region_ok_for_watchpoint): Likewise.
10037 (i386_dr_stopped_data_address): Likewise.
10038 (i386_dr_stopped_by_watchpoint): Likewise.
10040 2014-06-19 Gary Benson <gbenson@redhat.com>
10042 * i386-low.c (i386_dr_show): Renamed to
10043 i386_show_dr and made static. All uses updated.
10044 (i386_dr_length_and_rw_bits): Renamed to
10045 i386_length_and_rw_bits and made static.
10047 (i386_dr_insert_aligned_watchpoint): Renamed to
10048 i386_insert_aligned_watchpoint and made static.
10050 (i386_dr_remove_aligned_watchpoint): Renamed to
10051 i386_remove_aligned_watchpoint and made static.
10053 (i386_dr_update_inferior_debug_regs): Renamed to
10054 i386_update_inferior_debug_regs and made static.
10057 2014-06-18 Gary Benson <gbenson@redhat.com>
10059 * i386-low.h (i386_dr_low_can_set_addr): New macro.
10060 (i386_dr_low_can_set_control): Likewise.
10061 (i386_get_debug_register_length): Likewise.
10062 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
10063 (i386_dr_low_can_set_control): Likewise.
10064 (i386_get_debug_register_length): Likewise.
10066 2014-06-17 Gary Benson <gbenson@redhat.com>
10068 * i386-low.h (i386-dregs.h): New include.
10069 (DR_FIRSTADDR): Now in i386-dregs.h.
10070 (DR_LASTADDR): Likewise.
10071 (DR_NADDR): Likewise.
10072 (DR_STATUS): Likewise.
10073 (DR_CONTROL): Likewise.
10074 (i386_debug_reg_state): Likewise.
10075 (i386_dr_insert_watchpoint): Likewise.
10076 (i386_dr_remove_watchpoint): Likewise.
10077 (i386_dr_region_ok_for_watchpoint): Likewise.
10078 (i386_dr_stopped_data_address): Likewise.
10079 (i386_dr_stopped_by_watchpoint): Likewise.
10080 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
10082 2014-06-18 Gary Benson <gbenson@redhat.com>
10084 * i386-low.h (i386_low_insert_watchpoint): Renamed to
10085 i386_dr_insert_watchpoint.
10086 (i386_low_remove_watchpoint): Renamed to
10087 i386_dr_remove_watchpoint.
10088 (i386_low_region_ok_for_watchpoint): Renamed to
10089 i386_dr_region_ok_for_watchpoint.
10090 (i386_low_stopped_data_address): Renamed to
10091 i386_dr_stopped_data_address.
10092 (i386_low_stopped_by_watchpoint): Renamed to
10093 i386_dr_stopped_by_watchpoint.
10094 * i386-low.c (i386_show_dr): Renamed to
10095 i386_dr_show and made nonstatic. All uses updated.
10096 (i386_length_and_rw_bits): Renamed to
10097 i386_dr_length_and_rw_bits and made nonstatic.
10099 (i386_insert_aligned_watchpoint): Renamed to
10100 i386_dr_insert_aligned_watchpoint and made nonstatic.
10102 (i386_remove_aligned_watchpoint): Renamed to
10103 i386_dr_remove_aligned_watchpoint and made nonstatic.
10105 (i386_update_inferior_debug_regs): Renamed to
10106 i386_dr_update_inferior_debug_regs and made nonstatic.
10108 (i386_low_insert_watchpoint): Renamed to
10109 i386_dr_insert_watchpoint. All uses updated.
10110 (i386_low_remove_watchpoint): Renamed to
10111 i386_dr_remove_watchpoint. All uses updated.
10112 (i386_low_region_ok_for_watchpoint): Renamed to
10113 i386_dr_region_ok_for_watchpoint. All uses updated.
10114 (i386_low_stopped_data_address): Renamed to
10115 i386_dr_stopped_data_address. All uses updated.
10116 (i386_low_stopped_by_watchpoint): Renamed to
10117 i386_dr_stopped_by_watchpoint. All uses updated.
10119 2014-06-18 Gary Benson <gbenson@redhat.com>
10121 * i386-low.c (i386_dr_low_can_set_addr): New macro.
10122 (i386_dr_low_can_set_control): Likewise.
10123 (i386_insert_aligned_watchpoint): New check.
10125 2014-06-18 Gary Benson <gbenson@redhat.com>
10127 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
10130 2014-06-18 Gary Benson <gbenson@redhat.com>
10132 * i386-low.c (i386_length_and_rw_bits): Use internal_error
10133 instead of fatal and error.
10134 (i386_handle_nonaligned_watchpoint): Likewise.
10136 2014-06-18 Gary Benson <gbenson@redhat.com>
10138 * i386-low.c (i386_get_debug_register_length): New macro.
10139 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
10140 (i386_show_dr): Use debug_printf instead of fprintf. Use
10141 phex to format values.
10143 2014-06-18 Gary Benson <gbenson@redhat.com>
10145 * i386-low.h: Comment changes.
10146 * i386-low.c: Likewise.
10148 2014-06-18 Gary Benson <gbenson@redhat.com>
10150 * i386-low.c: Whitespace changes.
10152 2014-06-12 Tom Tromey <tromey@redhat.com>
10154 * utils.c (freeargv): Remove.
10156 2014-06-12 Tom Tromey <tromey@redhat.com>
10158 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
10159 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
10160 (parse_debug_format_options): Likewise.
10161 (gdbserver_usage): Likewise.
10162 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
10163 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
10164 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
10166 ($(LIBGNU)): Depend on libiberty.
10167 (all-lib): Recurse into all subdirs.
10168 (install-only): Invoke "install" target in subdirs.
10169 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
10171 * configure: Rebuild.
10172 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
10173 for vasprintf, vsnprintf, or gettimeofday.
10174 * configure.srv: Don't add safe-ctype.o or lbasename.o to
10177 2014-06-05 Joel Brobecker <brobecker@adacore.com>
10179 * development.sh: Delete.
10180 * Makefile.in (config.status): Adjust dependency on development.sh.
10181 * configure.ac: Adjust development.sh source call.
10182 * configure: Regenerate.
10184 2014-06-02 Pedro Alves <palves@redhat.com>
10186 * ax.c (gdb_free_agent_expr): New function.
10187 * ax.h (gdb_free_agent_expr): New declaration.
10188 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
10190 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
10192 (clear_breakpoint_conditions_and_commands): New function.
10193 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
10194 (clear_breakpoint_conditions_and_commands): New declaration.
10196 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
10198 * linux-aarch64-low.c (asm/ptrace.h): Include.
10200 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
10202 Fix TLS access for -static -pthread.
10203 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
10204 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
10205 (thread_db_load_search, try_thread_db_load_1): Initialize it.
10207 2014-05-20 Pedro Alves <palves@redhat.com>
10209 * linux-aarch64-low.c (aarch64_insert_point)
10210 (aarch64_remove_point): No longer check whether the type is
10211 supported here. Adjust to new interface.
10212 (the_low_target): Install aarch64_supports_z_point_type as
10213 supports_z_point_type method.
10214 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
10215 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
10216 instead of a Z packet char. Adjust.
10217 (arm_supports_z_point_type): New function.
10218 (arm_insert_point, arm_remove_point): Adjust to new interface.
10219 (the_low_target): Install arm_supports_z_point_type.
10220 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
10221 (cris_insert_point, cris_remove_point): Adjust to new interface.
10222 Don't check whether the type is supported here.
10223 (the_low_target): Install cris_supports_z_point_type.
10224 * linux-low.c (linux_supports_z_point_type): New function.
10225 (linux_insert_point, linux_remove_point): Adjust to new interface.
10226 * linux-low.h (struct linux_target_ops) <insert_point,
10227 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
10228 raw_breakpoint pointer parameter.
10229 <supports_z_point_type>: New method.
10230 * linux-mips-low.c (mips_supports_z_point_type): New function.
10231 (mips_insert_point, mips_remove_point): Adjust to new interface.
10232 Use mips_supports_z_point_type.
10233 (the_low_target): Install mips_supports_z_point_type.
10234 * linux-ppc-low.c (the_low_target): Install NULL as
10235 supports_z_point_type method.
10236 * linux-s390-low.c (the_low_target): Install NULL as
10237 supports_z_point_type method.
10238 * linux-sparc-low.c (the_low_target): Install NULL as
10239 supports_z_point_type method.
10240 * linux-x86-low.c (x86_supports_z_point_type): New function.
10241 (x86_insert_point): Adjust to new insert_point interface. Use
10242 insert_memory_breakpoint. Adjust to new
10243 i386_low_insert_watchpoint interface.
10244 (x86_remove_point): Adjust to remove_point interface. Use
10245 remove_memory_breakpoint. Adjust to new
10246 i386_low_remove_watchpoint interface.
10247 (the_low_target): Install x86_supports_z_point_type.
10248 * lynx-low.c (lynx_target_ops): Install NULL as
10249 supports_z_point_type callback.
10250 * nto-low.c (nto_supports_z_point_type): New.
10251 (nto_insert_point, nto_remove_point): Adjust to new interface.
10252 (nto_target_ops): Install nto_supports_z_point_type.
10253 * mem-break.c: Adjust intro comment.
10254 (struct raw_breakpoint) <raw_type, size>: New fields.
10255 <inserted>: Update comment.
10256 <shlib_disabled>: Delete field.
10257 (enum bkpt_type) <gdb_breakpoint>: Delete value.
10258 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
10259 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
10260 (raw_bkpt_type_to_target_hw_bp_type): New function.
10261 (find_enabled_raw_code_breakpoint_at): New function.
10262 (find_raw_breakpoint_at): New type and size parameters. Use them.
10263 (insert_memory_breakpoint): New function, based off
10264 set_raw_breakpoint_at.
10265 (remove_memory_breakpoint): New function.
10266 (set_raw_breakpoint_at): Reimplement.
10267 (set_breakpoint): New, based on set_breakpoint_at.
10268 (set_breakpoint_at): Reimplement.
10269 (delete_raw_breakpoint): Go through the_target->remove_point
10270 instead of assuming memory breakpoints.
10271 (find_gdb_breakpoint_at): Delete.
10272 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
10273 (find_gdb_breakpoint): New function.
10274 (set_gdb_breakpoint_at): Delete.
10275 (z_type_supported): New function.
10276 (set_gdb_breakpoint_1): New function, loosely based off
10277 set_gdb_breakpoint_at.
10278 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
10279 (delete_gdb_breakpoint_at): Delete.
10280 (delete_gdb_breakpoint_1): New function, loosely based off
10281 delete_gdb_breakpoint_at.
10282 (delete_gdb_breakpoint): New function.
10283 (clear_gdb_breakpoint_conditions): Rename to ...
10284 (clear_breakpoint_conditions): ... this. Don't handle a NULL
10286 (add_condition_to_breakpoint): Make static.
10287 (add_breakpoint_condition): Take a struct breakpoint pointer
10288 instead of an address. Adjust.
10289 (gdb_condition_true_at_breakpoint): Rename to ...
10290 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
10292 (gdb_condition_true_at_breakpoint): Reimplement.
10293 (add_breakpoint_commands): Take a struct breakpoint pointer
10294 instead of an address. Adjust.
10295 (gdb_no_commands_at_breakpoint): Rename to ...
10296 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
10297 parameter. Return true if no breakpoint was found. Change debug
10299 (gdb_no_commands_at_breakpoint): Reimplement.
10300 (run_breakpoint_commands): Rename to ...
10301 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
10302 and change return type to boolean.
10303 (run_breakpoint_commands): New function.
10304 (gdb_breakpoint_here): Also check for Z1 breakpoints.
10305 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
10306 breakpoint. Go through the_target->remove_point instead of
10307 assuming memory breakpoint.
10308 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
10309 software and hardware breakpoints.
10310 (reinsert_raw_breakpoint): Go through the_target->insert_point
10311 instead of assuming memory breakpoint.
10312 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
10313 software and hardware breakpoints.
10314 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
10315 Check both software and hardware breakpoints.
10316 (validate_inserted_breakpoint): Assert the breakpoint is a
10317 software breakpoint. Set the inserted flag to -1 instead of
10318 setting shlib_disabled.
10319 (delete_disabled_breakpoints): Adjust.
10320 (validate_breakpoints): Only validate software breakpoints.
10321 Adjust to inserted flag change.
10322 (check_mem_read, check_mem_write): Skip breakpoint types other
10323 than software breakpoints. Adjust to inserted flag change.
10324 * mem-break.h (enum raw_bkpt_type): New enum.
10325 (raw_breakpoint, struct process_info): Forward declare.
10326 (Z_packet_to_target_hw_bp_type): Delete declaration.
10327 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
10328 (set_gdb_breakpoint, delete_gdb_breakpoint)
10329 (clear_breakpoint_conditions): New declarations.
10330 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
10331 (breakpoint_inserted_here): Update comment.
10332 (add_breakpoint_condition, add_breakpoint_commands): Replace
10333 address parameter with a breakpoint pointer parameter.
10334 (gdb_breakpoint_here): Update comment.
10335 (delete_gdb_breakpoint_at): Delete.
10336 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
10337 * server.c (process_point_options): Take a struct breakpoint
10338 pointer instead of an address. Adjust.
10339 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
10340 delete_gdb_breakpoint.
10341 * spu-low.c (spu_target_ops): Install NULL as
10342 supports_z_point_type method.
10343 * target.h: Include mem-break.h.
10344 (struct target_ops) <prepare_to_access_memory>: Update comment.
10345 <supports_z_point_type>: New field.
10346 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
10347 instead of a char. Also take a raw breakpoint pointer.
10348 * win32-arm-low.c (the_low_target): Install NULL as
10349 supports_z_point_type.
10350 * win32-i386-low.c (i386_supports_z_point_type): New function.
10351 (i386_insert_point, i386_remove_point): Adjust to new interface.
10352 (the_low_target): Install i386_supports_z_point_type.
10353 * win32-low.c (win32_supports_z_point_type): New function.
10354 (win32_insert_point, win32_remove_point): Adjust to new interface.
10355 (win32_target_ops): Install win32_supports_z_point_type.
10356 * win32-low.h (struct win32_target_ops):
10357 <supports_z_point_type>: New method.
10358 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
10359 instead of a char. Also take a raw breakpoint pointer.
10361 2014-05-20 Pedro Alves <palves@redhat.com>
10363 * mem-break.h: Include break-common.h.
10364 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
10365 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
10366 (Z_packet_to_target_hw_bp_type): New declaration.
10367 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
10368 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
10369 (Z_PACKET_ACCESS_WP): Delete macros.
10370 (Z_packet_to_hw_type): Delete function.
10371 * i386-low.h: Don't include break-common.h here.
10372 (Z_packet_to_hw_type): Delete declaration.
10373 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
10374 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
10375 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
10376 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
10377 * linux-aarch64-low.c: Don't include break-common.h here.
10378 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
10379 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
10380 (Z_packet_to_target_hw_bp_type): Delete function.
10381 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
10383 (mips_insert_point, mips_remove_point): Use
10384 Z_packet_to_target_hw_bp_type.
10386 2014-05-20 Pedro Alves <palves@redhat.com>
10388 * linux-aarch64-low.c: Include break-common.h.
10389 (enum target_point_type): Delete.
10390 (Z_packet_to_point_type): Rename to ...
10391 (Z_packet_to_target_hw_bp_type): ... this, and return a
10392 target_hw_bp_type instead.
10393 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
10394 instead of an enum target_point_type.
10395 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
10397 (aarch64_dr_state_insert_one_point)
10398 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
10399 (aarch64_handle_aligned_watchpoint)
10400 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
10401 Take an enum target_hw_bp_type instead of an enum
10403 (aarch64_supports_z_point_type): New function.
10404 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
10405 use Z_packet_to_target_hw_bp_type.
10407 2014-05-20 Joel Brobecker <brobecker@adacore.com>
10409 * configure.ac: Only use -Werror by default when DEVELOPMENT
10411 * configure: Regenerate.
10413 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
10415 Fix gdbserver qGetTLSAddr for x86_64 -m32.
10416 * linux-x86-low.c (X86_64_USER_REGS): New.
10417 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
10419 2014-04-28 Yao Qi <yao@codesourcery.com>
10421 * Makefile.in (i386-avx512.c): Fix the typo of generated file
10424 2014-04-25 Pedro Alves <palves@redhat.com>
10427 * linux-low.c (linux_attach_fail_reason_string): New function.
10428 (linux_attach_lwp): Delete.
10429 (linux_attach_lwp_1): Rename to ...
10430 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
10431 argument. Remove "initial" parameter. Return int instead of
10432 void. Don't error or warn here.
10433 (linux_attach): Adjust to call linux_attach_lwp. Call error on
10434 failure to attach to the tgid. Call warning when failing to
10436 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
10437 argument. Remove "initial" parameter. Return int instead of
10438 void. Don't error or warn here.
10439 (linux_attach_fail_reason_string): New declaration.
10440 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
10441 interface change. Use linux_attach_fail_reason_string.
10443 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
10444 Walfred Tedeschi <walfred.tedeschi@intel.com>
10446 * Makefile.in: Added rules to handle new files
10447 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
10448 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
10449 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
10450 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
10451 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
10452 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
10453 x32-avx512-linux.o.
10454 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
10455 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
10456 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
10457 i386/x32-avx512.xml.
10458 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
10459 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
10460 i386/x32-avx512-linux.xml.
10461 * i387-fp.c (num_avx512_k_registers): New constant for number
10463 (num_avx512_zmmh_low_registers): New constant for number of
10464 lower ZMM registers (0-15).
10465 (num_avx512_zmmh_high_registers): New constant for number of
10466 higher ZMM registers (16-31).
10467 (num_avx512_ymmh_registers): New contant for number of higher
10468 YMM registers (ymm16-31 added by avx521 on x86_64).
10469 (num_avx512_xmm_registers): New constant for number of higher
10470 XMM registers (xmm16-31 added by AVX512 on x86_64).
10471 (struct i387_xsave): Add space for AVX512 registers.
10472 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
10473 Add code to handle AVX512 registers.
10474 (i387_xsave_to_cache): Add code to handle AVX512 registers.
10475 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
10476 prototypei from generated file.
10477 (tdesc_amd64_avx512_linux): Likewise.
10478 (init_registers_x32_avx512_linux): Likewise.
10479 (tdesc_x32_avx512_linux): Likewise.
10480 (init_registers_i386_avx512_linux): Likewise.
10481 (tdesc_i386_avx512_linux): Likewise.
10482 (x86_64_regmap): Add AVX512 registers.
10483 (x86_linux_read_description): Add code to handle AVX512 XSTATE
10485 (initialize_low_arch): Add code to initialize AVX512 registers.
10487 2014-04-23 Pedro Alves <palves@redhat.com>
10489 * mem-break.c (find_gdb_breakpoint_at): Make static.
10490 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
10492 2014-04-23 Pedro Alves <palves@redhat.com>
10494 * i386-low.c: Don't include break-common.h here.
10495 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
10496 prototype to take target_hw_bp_type as argument instead of a Z
10498 * i386-low.h: Include break-common.h here.
10499 (Z_packet_to_hw_type): Declare.
10500 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
10502 * linux-x86-low.c (x86_insert_point): Convert the packet number to
10503 a target_hw_bp_type before calling i386_low_insert_watchpoint.
10504 (x86_remove_point): Convert the packet number to a
10505 target_hw_bp_type before calling i386_low_remove_watchpoint.
10506 * win32-i386-low.c (i386_insert_point): Convert the packet number
10507 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
10508 (i386_remove_point): Convert the packet number to a
10509 target_hw_bp_type before calling i386_low_remove_watchpoint.
10511 2014-04-23 Pedro Alves <palves@redhat.com>
10513 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
10515 2014-04-10 Pedro Alves <palves@redhat.com>
10517 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
10518 Check if the condition or command is NULL before checking if the
10519 breakpoint is known. On success, return true.
10520 * mem-break.h (add_breakpoint_condition): Document return.
10521 (add_breakpoint_commands): Add describing comment.
10522 * server.c (skip_to_semicolon): New function.
10523 (process_point_options): Use it.
10525 2014-04-09 Pedro Alves <palves@redhat.com>
10527 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
10530 2014-02-27 Pedro Alves <palves@redhat.com>
10533 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
10535 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
10537 (last_thread_of_process_p): Take a PID argument instead of a
10539 (linux_wait_for_lwp): Delete.
10540 (num_lwps, check_zombie_leaders, not_stopped_callback): New
10542 (linux_low_filter_event): New function, party factored out from
10543 linux_wait_for_event.
10544 (linux_wait_for_event): Rename to ...
10545 (linux_wait_for_event_filtered): ... this. Add new filter ptid
10546 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
10547 sigsuspend. Check for zombie leaders.
10548 (linux_wait_for_event): Reimplement as wrapper around
10549 linux_wait_for_event_filtered.
10550 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
10551 a normal or signal exit is seen, it's the whole process exiting.
10552 (wait_for_sigstop): No longer a for_each_inferior callback.
10553 Rewrite on top of linux_wait_for_event_filtered.
10554 (stop_all_lwps): Call wait_for_sigstop directly.
10555 * server.c (resume, handle_target_event): Handle
10556 TARGET_WAITKIND_NO_RESUMED.
10558 2014-02-26 Joel Brobecker <brobecker@adacore.com>
10560 * win32-low.c (psapi_get_dll_name,
10561 * win32_CreateToolhelp32Snapshot): Delete.
10562 (win32_CreateToolhelp32Snapshot, win32_Module32First)
10563 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
10565 (handle_load_dll): Add function description.
10566 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
10568 2014-02-26 Joel Brobecker <brobecker@adacore.com>
10570 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
10572 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
10573 base address when calling win32_add_one_solib.
10574 (handle_load_dll): Delete local variable load_addr.
10575 Remove 0x1000 offset applied to DLL base address when calling
10576 win32_add_one_solib.
10577 (handle_unload_dll): Add comment.
10579 2014-02-26 Joel Brobecker <brobecker@adacore.com>
10581 * win32-low.c (win32_add_all_dlls): Renames
10582 win32_ensure_ntdll_loaded. Rewrite function documentation.
10583 Adjust implementation to always load all DLLs.
10584 Add 0x1000 offset to DLL base address when calling
10585 win32_add_one_solib.
10586 (child_initialization_done): New static global.
10587 (do_initial_child_stuff): Set child_initialization_done to
10588 zero during child initialization, and 1 after. Replace call
10589 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
10591 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
10592 (handle_unload_dll): Add function documentation.
10593 (get_child_debug_event): Ignore load and unload DLL events
10594 during child initialization.
10596 2014-02-20 Doug Evans <dje@google.com>
10598 Remove global all_lwps.
10599 * inferiors.h (ptid_of): Move here from linux-low.h.
10600 (pid_of, lwpid_of): Ditto.
10601 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
10602 parameter is a struct thread_info * now.
10603 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
10604 directly. Pass &all_threads to find_inferior instead of &all_lwps.
10605 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
10607 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
10608 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
10609 * linux-arm-low.c (update_registers_callback): Update, "entry"
10610 parameter is a struct thread_info * now.
10611 Fetch lwpid from current_inferior directly.
10612 (arm_insert_point): Pass &all_threads to find_inferior instead of
10614 (arm_remove_point): Ditto.
10615 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
10616 (arm_prepare_to_resume): Fetch pid from thread.
10617 (arm_read_description): Fetch lwpid from current_inferior directly.
10618 * linux-low.c (all_lwps): Delete.
10619 (delete_lwp): Delete call to remove_inferior.
10620 (handle_extended_wait): Fetch lwpid from thread.
10621 (add_lwp): Don't set lwp->entry.id. Remove call to
10622 add_inferior_to_list.
10623 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
10624 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
10625 (kill_one_lwp_callback): Ditto.
10626 (linux_kill): Don't dereference NULL pointer.
10627 Fetch ptid,lwpid from thread.
10628 (get_detach_signal): Fetch ptid from thread.
10629 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
10630 Simplify call to regcache_invalidate_thread.
10631 (delete_lwp_callback): Update, "entry" parameter is a
10632 struct thread_info * now. Fetch pid from thread.
10633 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
10634 (status_pending_p_callback): Update, "entry" parameter is a
10635 struct thread_info * now. Fetch ptid from thread.
10636 (find_lwp_pid): Update, "entry" parameter is a
10637 struct thread_info * now.
10638 (linux_wait_for_lwp): Fetch pid from thread.
10639 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
10640 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
10641 (enqueue_one_deferred_signal): Fetch lwpid from thread.
10642 (dequeue_one_deferred_signal): Ditto.
10643 (cancel_breakpoint): Fetch ptid from current_inferior.
10644 (linux_wait_for_event): Pass &all_threads to find_inferior,
10645 not &all_lwps. Fetch ptid, lwpid from thread.
10646 (count_events_callback): Update, "entry" parameter is a
10647 struct thread_info * now.
10648 (select_singlestep_lwp_callback): Ditto.
10649 (select_event_lwp_callback): Ditto.
10650 (cancel_breakpoints_callback): Ditto.
10651 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
10653 (select_event_lwp): Ditto. Fetch ptid from event_thread.
10654 (unsuspend_one_lwp): Update, "entry" parameter is a
10655 struct thread_info * now.
10656 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
10658 (linux_stabilize_threads): Ditto. And for for_each_inferior.
10659 Fetch lwpid from thread, not lwp.
10660 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
10661 Pass &all_threads to find_inferior, not &all_lwps.
10662 (send_sigstop): Fetch lwpid from thread, not lwp.
10663 (send_sigstop_callback): Update, "entry" parameter is a
10664 struct thread_info * now.
10665 (suspend_and_send_sigstop_callback): Ditto.
10666 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
10667 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
10668 struct thread_info * now.
10669 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
10671 (lwp_running): Update, "entry" parameter is a
10672 struct thread_info * now.
10673 (stop_all_lwps): Fetch ptid from thread.
10674 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
10675 (linux_resume_one_lwp): Fetch lwpid from thread.
10676 (linux_set_resume_request): Update, "entry" parameter is a
10677 struct thread_info * now. Fetch pid, lwpid from thread.
10678 (resume_status_pending_p): Update, "entry" parameter is a
10679 struct thread_info * now.
10680 (need_step_over_p): Ditto. Fetch lwpid from thread.
10681 (start_step_over): Fetch lwpid from thread.
10682 (linux_resume_one_thread): Update, "entry" parameter is a
10683 struct thread_info * now. Fetch lwpid from thread.
10684 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
10685 (proceed_one_lwp): Update, "entry" parameter is a
10686 struct thread_info * now. Fetch lwpid from thread.
10687 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
10688 struct thread_info * now.
10689 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
10690 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
10691 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
10693 (regsets_store_inferior_registers): Ditto.
10694 (fetch_register, store_register): Ditto.
10695 (linux_read_memory, linux_write_memory): Ditto.
10696 (linux_request_interrupt): Ditto.
10697 (linux_read_auxv): Ditto.
10698 (linux_xfer_siginfo): Ditto.
10699 (linux_qxfer_spu): Ditto.
10700 (linux_qxfer_libraries_svr4): Ditto.
10701 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
10702 moved to inferiors.h.
10704 (get_thread_lwp): Update.
10705 (struct lwp_info): Delete member "entry". Simplify comment for
10707 (all_lwps): Delete.
10708 * linux-mips-low.c (mips_read_description): Fetch lwpid from
10709 current_inferior directly.
10710 (update_watch_registers_callback): Update, "entry" parameter is a
10711 struct thread_info * now. Fetch pid from thread.
10712 (mips_linux_prepare_to_resume): Fetch ptid from thread.
10713 (mips_insert_point): Fetch lwpid from current_inferior.
10714 Pass &all_threads to find_inferior, not &all_lwps.
10715 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
10716 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
10718 (mips_stopped_data_address): Ditto.
10719 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
10721 * linux-tile-low.c (tile_arch_setup): Ditto.
10722 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
10723 (update_debug_registers_callback): Update, "entry" parameter is a
10724 struct thread_info * now. Fetch pid from thread.
10725 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
10726 Pass &all_threads to find_inferior, not &all_lwps.
10727 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
10728 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
10729 Pass &all_threads to find_inferior, not &all_lwps.
10730 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
10731 (i386_dr_low_get_status): Ditto.
10732 (x86_linux_prepare_to_resume): Fetch ptid from thread.
10733 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
10734 (x86_linux_read_description): Ditto.
10735 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
10737 2014-02-20 Doug Evans <dje@google.com>
10739 * inferiors.c (get_first_inferior): Fix buglet.
10741 2014-02-19 Doug Evans <dje@google.com>
10743 * gdbthread.h (add_thread): Change result type to struct thread_info *.
10744 * inferiors.c (add_thread): Change result type to struct thread_info *.
10745 All callers updated.
10746 (add_lwp): Call add_thread here instead of in callers.
10747 All callers updated.
10748 * linux-low.h (get_lwp_thread): Rewrite.
10749 (struct lwp_info): New member "thread".
10751 2014-02-19 Doug Evans <dje@google.com>
10753 * linux-low.c (add_lwp): Change result to struct lwp_info *.
10754 All callers updated.
10756 2014-02-19 Doug Evans <dje@google.com>
10758 * inferiors.c (add_thread): Fix whitespace.
10760 2014-02-19 Doug Evans <dje@google.com>
10762 * dll.c (clear_dlls): Replace accessing list implemention details
10764 * gdbthread.h (get_first_thread): Declare.
10765 * inferiors.c (for_each_inferior_with_data): New function.
10766 (get_first_thread): New function.
10767 (find_thread_ptid): Simplify.
10768 (get_first_inferior): New function.
10769 (clear_list): Delete.
10770 (one_inferior_p): New function.
10771 (clear_inferior_list): New function.
10772 (clear_inferiors): Update.
10773 * inferiors.h (for_each_inferior_with_data): Declare.
10774 (clear_inferior_list): Declare.
10775 (one_inferior_p): Declare.
10776 (get_first_inferior): Declare.
10777 * linux-low.c (linux_wait_for_event): Replace accessing list
10778 implemention details with API function.
10779 * server.c (target_running): Ditto.
10780 (accumulate_file_name_length): New function.
10781 (emit_dll_description): New function.
10782 (handle_qxfer_libraries): Replace accessing list implemention
10783 details with API function.
10784 (handle_qxfer_threads_worker): New function.
10785 (handle_qxfer_threads_proper): Replace accessing list implemention
10786 details with API function.
10787 (handle_query): Ditto.
10788 (visit_actioned_threads_callback_ftype): New typedef.
10789 (visit_actioned_threads_data): New struct.
10790 (visit_actioned_threads): Rewrite to be find_inferior callback.
10791 (resume): Call find_inferior.
10792 (handle_status): Replace accessing list implemention
10793 details with API function.
10794 (process_serial_event): Replace accessing list implemention details
10796 * target.c (set_desired_inferior): Replace accessing list implemention
10797 details with API function.
10798 * tracepoint.c (same_process_p): New function.
10799 (gdb_agent_about_to_close): Replace accessing list implemention
10800 details with API function.
10801 * win32-low.c (child_delete_thread): Replace accessing list
10802 implemention details with API function.
10803 (match_dll_by_basename): New function.
10804 (dll_is_loaded_by_basename): New function.
10805 (win32_ensure_ntdll_loaded): Replace accessing list implemention
10806 details call to dll_is_loaded_by_basename.
10808 2014-02-19 Doug Evans <dje@google.com>
10810 * dll.h (struct dll_info): Add comment.
10811 * gdbthread.h (struct thread_info): Add comment.
10812 (current_ptid): Simplify.
10813 * inferiors.c (add_process): Update.
10814 (remove_process): Update.
10815 * inferiors.h (struct process_info): Rename member "head" to "entry".
10816 * linux-low.c (delete_lwp): Update.
10818 (last_thread_of_process_p): Update.
10819 (kill_one_lwp_callback, linux_kill): Update.
10820 (status_pending_p_callback): Update.
10821 (wait_for_sigstop): Update. Simplify read of ptid.
10822 (start_step_over): Update.
10823 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
10824 (get_lwp_thread): Update.
10825 (struct lwp_info): Rename member "head" to "entry".
10826 * regcache.h (inferior_list_entry): Delete.
10827 * server.c (kill_inferior_callback): Update.
10828 (detach_or_kill_inferior_callback): Update.
10829 (print_started_pid): Update.
10830 (print_attached_pid): Update.
10831 (process_serial_event): Simplify read of ptid.
10832 * thread-db.c (thread_db_create_event): Update.
10833 (thread_db_get_tls_address): Update.
10834 * win32-low.c (current_inferior_ptid): Simplify.
10836 2014-02-19 Tom Tromey <tromey@redhat.com>
10838 * target.h (struct target_ops) <supports_btrace>: Add target_ops
10840 (target_supports_btrace): Update.
10842 2014-02-14 Yao Qi <yao@codesourcery.com>
10844 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
10845 (rsp-low-ipa.o): New target.
10847 2014-02-12 Tom Tromey <tromey@redhat.com>
10849 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
10850 convert_ascii_to_int.
10851 * regcache.c (registers_to_string): Likewise.
10852 * remote-utils.c (decode_M_packet): Likewise.
10853 * server.c (process_serial_event): Likewise.
10855 2014-02-12 Tom Tromey <tromey@redhat.com>
10857 * server.c (handle_query, handle_v_run): Use hex2bin, not
10859 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
10861 2014-02-12 Tom Tromey <tromey@redhat.com>
10863 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
10864 convert_int_to_ascii.
10865 * regcache.c (registers_to_string, collect_register_as_string):
10867 * remote-utils.c (look_up_one_symbol, relocate_instruction):
10869 * server.c (process_serial_event): Likewise.
10870 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
10871 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
10873 2014-02-12 Tom Tromey <tromey@redhat.com>
10875 * remote-utils.c (look_up_one_symbol, monitor_output): Use
10876 bin2hex, not hexify.
10877 * tracepoint.c (cmd_qtstatus): Likewise.
10879 2014-02-12 Tom Tromey <tromey@redhat.com>
10881 * remote-utils.c (monitor_output): Pass explicit length to
10884 2014-02-12 Tom Tromey <tromey@redhat.com>
10886 * tracepoint.c: Include rsp-low.h.
10887 * server.c: Include rsp-low.h.
10888 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
10889 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
10891 * remote-utils.c: Include rsp-low.h.
10892 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
10893 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
10894 (convert_int_to_ascii, convert_ascii_to_int): Move to
10896 * regcache.c: Include rsp-low.h.
10897 * ax.c: Include rsp-low.h.
10898 * Makefile.in (SFILES): Add common/rsp-low.c.
10899 (OBS): Add rsp-low.o.
10900 (rsp-low.o): New target.
10902 2014-02-12 Tom Tromey <tromey@redhat.com>
10904 * utils.h (pulongest, plongest, phex_nz): Don't declare.
10905 Include print-utils.h.
10906 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
10907 (plongest, thirty_two, phex_nz): Remove.
10908 * Makefile.in (SFILES): Add common/print-utils.c.
10909 (OBS): Add print-utils.o.
10910 (print-utils-ipa.o): New target.
10911 (print-utils.o): New target.
10912 (IPA_OBJS): Add print-utils-ipa.o.
10914 2014-02-06 Tom Tromey <tromey@redhat.com>
10916 * Makefile.in (SFILES): Fix indentation.
10918 2014-02-05 Doug Evans <dje@google.com>
10920 * linux-low.c (linux_wait_for_event): Improve comment.
10921 (linux_wait_1): Keep current_inferior in sync with event_child.
10923 2014-01-22 Doug Evans <dje@google.com>
10925 * gdbthread.h (gdb_id_to_thread): Delete, unused.
10927 2014-01-22 Doug Evans <dje@google.com>
10929 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
10930 * configure: Regenerate.
10931 * config.in: Regenerate.
10932 * Makefile.in (SFILES): Add debug.c.
10933 (OBS): Add debug.o.
10934 * debug.c: New file.
10935 * debug.h: New file.
10936 * linux-aarch64-low.c (*): Update all debugging printfs to use
10937 debug_printf instead of fprintf.
10938 * linux-arm-low.c (*): Ditto.
10939 * linux-cris-low.c (*): Ditto.
10940 * linux-crisv32-low.c (*): Ditto.
10941 * linux-m32r-low.c (*): Ditto.
10942 * linux-sparc-low.c (*): Ditto.
10943 * linux-x86.c (*): Ditto.
10944 * linux-low.c (*): Ditto.
10945 (linux_wait_1): Add calls to debug_enter, debug_exit.
10946 (linux_wait): Remove redundant debugging printf.
10947 (stop_all_lwps): Add calls to debug_enter, debug_exit.
10948 (linux_resume, unstop_all_lwps): Ditto.
10949 * mem-break.c (*): Update all debugging printfs to use
10950 debug_printf instead of fprintf.
10951 * remote-utils.c (*): Ditto.
10952 * thread-db.c (*): Ditto.
10953 * server.c #include <ctype.h>, "gdb_vecs.h".
10954 (debug_threads): Moved to debug.c.
10955 (*): Update all debugging printfs to use debug_printf instead of
10957 (start_inferior): Replace call to fflush with call to debug_flush.
10958 (monitor_show_help): Mention set debug-format.
10959 (parse_debug_format_options): New function.
10960 (handle_monitor_command): Handle "monitor set debug-format".
10961 (gdbserver_usage): Mention --debug-format.
10962 (main): Parse --debug-format.
10963 * server.h (debug_threads): Declaration moved to debug.h.
10964 #include "debug.h".
10965 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
10966 trace_debug_1 that uses debug_printf.
10967 (tracepoint_look_up_symbols): Update all debugging printfs to use
10968 debug_printf instead of fprintf.
10970 2014-01-20 Baruch Siach <baruch@tkos.co.il>
10972 * linux-xtensa-low.c: Include asm/ptrace.h instead of
10975 2014-01-17 Pedro Alves <palves@redhat.com>
10978 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
10979 defined after including gdb_proc_service.h.
10981 2014-01-16 Doug Evans <dje@google.com>
10983 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
10984 (match_dll): Use it.
10986 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
10988 * target.h (target_ops) <read_btrace>: Change parameters and
10989 return type to allow error reporting.
10990 * server.c (handle_qxfer_btrace): Support delta reads. Pass
10991 trace reading errors on.
10992 * linux-low.c (linux_low_read_btrace): Pass trace reading
10994 (linux_low_disable_btrace): New.
10996 2014-01-15 Doug Evans <dje@google.com>
10998 * inferiors.c (thread_id_to_gdb_id): Delete.
10999 * inferiors.h (thread_id_to_gdb_id): Delete.
11001 2014-01-13 Eli Zaretskii <eliz@gnu.org>
11003 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
11004 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
11007 2014-01-08 Pedro Alves <palves@redhat.com>
11009 * server.c (handle_status): Don't discard previous queued stop
11010 replies or thread's pending status here.
11011 (main) <disconnection>: Do it here instead.
11013 2014-01-08 Pedro Alves <palves@redhat.com>
11015 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
11016 * server.c (visit_actioned_threads, handle_pending_status): New
11018 (handle_v_cont): Factor out parts to ...
11019 (resume): ... this new function. If in all-stop, and a thread
11020 being resumed has a pending status, report it without actually
11022 (myresume): Adjust to use the new 'resume' function.
11023 (clear_pending_status_callback, set_pending_status_callback)
11024 (find_status_pending_thread_callback): New functions.
11025 (handle_status): Handle the case of multiple threads having
11026 interesting statuses to report. Report threads' real last signal
11027 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
11028 with an interesting thread to report the status for, instead of
11029 always reporting the status of the first thread.
11031 2014-01-01 Joel Brobecker <brobecker@adacore.com>
11033 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
11034 * gdbreplay.c (gdbreplay_version): Likewise.
11036 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
11038 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
11039 iov.iov_len with the real length in use.
11041 2013-12-13 Joel Brobecker <brobecker@adacore.com>
11043 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
11044 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
11045 for all targets that use win32-low.c.
11046 * win32-low.c (win32_ensure_ntdll_loaded): New function.
11047 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
11049 2013-12-13 Pedro Alves <palves@redhat.com>
11051 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
11052 if equal to TARGET_WAITKIND_LOADED.
11053 * win32-low.c (cached_status): New static global.
11054 (win32_wait): Add declaration.
11055 (do_initial_child_stuff): Flush all initial pending debug events
11056 up to the initial breakpoint.
11057 (win32_wait): If CACHED_STATUS was set, return that instead
11058 of doing a real wait. Remove the code resuming the execution
11059 of the inferior after receiving a TARGET_WAITKIND_LOADED event
11060 during the initial phase. Also remove the code changing
11061 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
11062 TARGET_WAITKIND_STOPPED.
11064 2013-12-11 Yao Qi <yao@codesourcery.com>
11066 * notif.c (handle_notif_ack): Return 0 if no notification
11069 2013-11-20 Doug Evans <dje@google.com>
11071 * linux-low.c (linux_set_resume_request): Fix comment.
11073 2013-11-20 Doug Evans <dje@google.com>
11075 * linux-low.c (resume_status_pending_p): Tweak comment.
11077 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
11079 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
11080 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
11081 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
11082 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
11083 (srv_amd64_regobj): Add amd64-mpx.o.
11084 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
11085 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
11086 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
11087 * i387-fp.c (num_pl_bnd_register) Added constant.
11088 (num_pl_bnd_cfg_registers) Added constant.
11089 (struct i387_xsave) Added reserved area and MPX fields.
11090 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
11091 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
11093 (tdesc_i386_mpx_linux): Add MPX amd64 target.
11094 (init_registers_amd64_mpx_linux): Declare new function.
11095 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
11096 (x86_64_regmap): Add MPX registers.
11097 (x86_linux_read_description): Add MPX case.
11098 (initialize_low_arch): Initialize MPX targets.
11100 2013-11-18 Tom Tromey <tromey@redhat.com>
11102 * configure: Rebuild.
11103 * configure.ac: Don't check for stdlib.h.
11104 * gdbreplay.c: Unconditionally include stdlib.h.
11106 2013-11-18 Tom Tromey <tromey@redhat.com>
11108 * config.in: Rebuild.
11109 * configure: Rebuild.
11110 * configure.ac: Don't use AC_HEADER_DIRENT.
11112 2013-11-18 Tom Tromey <tromey@redhat.com>
11114 * server.h: Don't check HAVE_STRING_H.
11115 * gdbreplay.c: Don't check HAVE_STRING_H.
11116 * configure: Rebuild.
11118 2013-11-18 Tom Tromey <tromey@redhat.com>
11120 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
11123 2013-11-08 Tom Tromey <tromey@redhat.com>
11125 * configure, config.in: Rebuild.
11126 * configure.ac: Remove unused configury.
11128 2013-11-08 Tom Tromey <tromey@redhat.com>
11130 * acinclude.m4: Include common.m4, codeset.m4.
11131 * configure, config.in: Rebuild.
11132 * configure.ac: Use GDB_AC_COMMON.
11134 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
11136 * linux-s390-low.c (HWCAP_S390_TE): New define.
11137 (s390_arch_setup): Consider the TE field in the HWCAP for
11138 determining 'have_regset_tdb'.
11140 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
11143 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
11146 2013-10-02 Pedro Alves <palves@redhat.com>
11148 * server.c (process_serial_event): Don't output "GDBserver
11149 exiting" if GDB is connected through stdio.
11150 * target.c (mywait): Likewise, be silent if GDB is connected
11153 2013-10-01 Joel Brobecker <brobecker@adacore.com>
11155 * lynx-low.c (lynx_add_threads_after_attach): New function.
11156 (lynx_attach): Remove call to add_thread. Add call to
11157 lynx_add_threads_after_attach instead.
11159 2013-09-28 Mike Frysinger <vapier@gentoo.org>
11161 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
11162 * config.in, configure: Regenerated.
11164 2013-09-18 Yao Qi <yao@codesourcery.com>
11167 * server.c (start_inferior): Clear 'resume_info'.
11169 2013-09-16 Jiong Wang <jiwang@tilera.com>
11171 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
11174 2013-09-16 Jiong Wang <jiwang@tilera.com>
11176 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
11177 linux-tile-low.o to srv_tgtobj.
11179 2013-09-16 Will Newton <will.newton@linaro.org>
11181 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
11184 2013-09-06 Pedro Alves <palves@redhat.com>
11186 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
11187 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
11188 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
11189 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
11190 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
11191 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
11193 2013-09-06 Pedro Alves <palves@redhat.com>
11195 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
11196 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
11198 2013-09-06 Pedro Alves <palves@redhat.com>
11200 * linux-amd64-ipa.c: Include tracepoint.h.
11201 * linux-i386-ipa.c: Include tracepoint.h.
11203 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
11205 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
11206 (ps_get_thread_area): New function.
11208 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
11210 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
11211 (initialize_low_arch): Call init_registers_crisv32 rather than
11212 init_register_crisv32.
11214 2013-09-05 Pedro Alves <palves@redhat.com>
11216 * server.h (handle_vFile, hostio_last_error_from_errno): Move
11218 * hostio.h: ... this new file.
11219 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
11220 win32-low.c: Include hostio.h.
11222 2013-09-05 Pedro Alves <palves@redhat.com>
11224 * server.h (gdb_client_data, handler_func, callback_handler_func)
11225 (delete_file_handler, add_file_handler, append_callback_event)
11226 (delete_callback_event, start_event_loop, initialize_event_loop):
11227 Move to event-loop.h and include it.
11228 * event-loop.h: New file.
11230 2013-09-05 Pedro Alves <palves@redhat.com>
11232 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
11233 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
11234 (loaded_dll, unloaded_dll): Move to ...
11235 * dll.h: ... this new file.
11236 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
11238 2013-09-05 Pedro Alves <palves@redhat.com>
11240 * server.h (current_process, get_thread_process, all_processes)
11241 (add_inferior_to_list, for_each_inferior, current_inferior)
11242 (remove_inferior, add_process, remove_process, find_process_pid)
11243 (have_started_inferiors_p, have_attached_inferiors_p)
11244 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
11245 (clear_inferiors, find_inferior, find_inferior_id)
11246 (inferior_target_data, set_inferior_target_data)
11247 (inferior_regcache_data, set_inferior_regcache_data): Move to
11248 inferiors.h, and include it.
11249 * inferiors.h: New file.
11251 2013-09-05 Pedro Alves <palves@redhat.com>
11253 * server.h (struct emit_ops, current_insn_ptr, emit_error):
11257 2013-09-05 Pedro Alves <palves@redhat.com>
11259 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
11261 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
11262 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
11263 (handle_tracepoint_general_set, handle_tracepoint_query)
11264 (tracepoint_finished_step, tracepoint_was_hit)
11265 (release_while_stepping_state_list, current_traceframe)
11266 (in_readonly_region, traceframe_read_mem)
11267 (fetch_traceframe_registers, traceframe_read_sdata)
11268 (traceframe_read_info, struct fast_tpoint_collect_status)
11269 (fast_tracepoint_collecting, force_unlock_trace_buffer)
11270 (handle_tracepoit_bkpts, initialize_low_tracepoint)
11271 (supply_fast_tracepoint_registers)
11272 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
11273 (ipa_tdesc, claim_trampoline_space)
11274 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
11275 (agent_mem_read, agent_get_trace_state_variable_value)
11276 (agent_set_trace_state_variable_value, agent_tsv_read)
11277 (agent_mem_read_string, get_raw_reg_func_addr)
11278 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
11279 * tracepoint.h: ... this new file.
11281 2013-09-05 Pedro Alves <palves@redhat.com>
11283 * server.h (perror_with_name, error, fatal, warning, paddress)
11284 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
11286 * utils.h: New file.
11288 2013-09-05 Pedro Alves <palves@redhat.com>
11290 * server.h (remote_debug, noack_mode, transport_is_reliable)
11291 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
11292 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
11293 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
11294 (write_enn, initialize_async_io, enable_async_io)
11295 (disable_async_io, check_remote_input_interrupt_request)
11296 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
11297 (dead_thread_notify, prepare_resume_reply)
11298 (decode_address_to_semicolon, decode_address, decode_m_packet)
11299 (decode_M_packet, decode_X_packet, decode_xfer_write)
11300 (decode_search_memory_packet, unhexify, hexify)
11301 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
11302 (look_up_one_symbol, relocate_instruction)
11303 (monitor_output): Move to remote-utils.h, and include it.
11304 * remote-utils.h: New file.
11306 2013-09-05 Pedro Alves <palves@redhat.com>
11308 * server.h (_): Delete.
11310 2013-09-02 Pedro Alves <palves@redhat.com>
11312 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
11313 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
11315 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
11317 2013-09-02 Pierre Muller <muller@sourceware.org>
11319 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
11320 or WriteProcessMemory complete successfully and handle
11321 ERROR_PARTIAL_COPY error.
11323 2013-09-02 Pedro Alves <palves@redhat.com>
11325 * server.c (gdb_read_memory): Return -1 on traceframe memory read
11326 error instead of EIO.
11328 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
11331 * linux-low.c: Include filestuff.h.
11332 (linux_create_inferior) <pid == 0>: Call close_most_fds.
11333 * lynx-low.c: Include filestuff.h.
11334 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
11335 * server.c: Include filestuff.h.
11336 (main): Call notice_open_fds.
11337 * spu-low.c: Include filestuff.h.
11338 (spu_create_inferior) <pid == 0>: Call close_most_fds.
11340 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
11342 * Makefile.in: Explain why ../target and ../nat are not
11343 listed as include file search paths.
11344 (linux-waitpid.o): New object file rule.
11345 * configure.srv (srv_native_linux_obj): New variable.
11346 Replace all occurrences of linux native object files with
11347 $srv_native_linux_obj.
11348 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
11349 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
11350 (linux_enable_event_reporting): Remove declaration.
11351 (my_waitpid): Moved to common/linux-waitpid.c.
11352 (linux_wait_for_event): Pass ptid when calling
11353 linux_enable_event_reporting.
11354 (linux_supports_tracefork_flag): Remove.
11355 (linux_enable_event_reporting): Likewise.
11356 (linux_tracefork_grandchild): Remove.
11357 (STACK_SIZE): Moved to common/linux-ptrace.c.
11358 (linux_tracefork_child): Remove.
11359 (linux_test_for_tracefork): Remove.
11360 (linux_look_up_symbols): Call linux_supports_traceclone.
11361 (initialize_low): Remove call to linux_test_for_tracefork.
11362 * linux-low.h (PTRACE_TYPE_ARG3): Move to
11363 common/linux-ptrace.h.
11364 (PTRACE_TYPE_ARG4): Likewise.
11365 Include linux-ptrace.h.
11367 2013-08-21 Pedro Alves <palves@redhat.com>
11369 * config.in: Renegerate.
11371 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
11373 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
11374 (SFILES): Remove $(srcdir)/common/target-common.c and
11375 add $(srcdir)/target/waitstatus.c.
11376 (OBS): Remove target-common.o and add waitstatus.o.
11377 (server_h): Remove $(srcdir)/../common/target-common.h and
11378 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
11379 and $(srcdir)/../target/waitstatus.h.
11380 (target-common.o): Remove.
11381 (waitstatus.o): New target object file.
11382 * target.h: Do not include target-common.h and
11383 include target/resume.h, target/wait.h and
11384 target/waitstatus.h.
11386 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
11388 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
11389 to PTRACE_TYPE_ARG3.
11390 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
11391 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
11393 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
11394 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
11396 2013-07-27 Jie Zhang <jie@codesourcery.com>
11397 Daniel Jacobowitz <dan@codesourcery.com>
11398 Yao Qi <yao@codesourcery.com>
11400 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
11401 (mips-linux-watch.o): New rule.
11402 (mips_linux_watch_h): New variable.
11403 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
11405 * linux-mips-low.c: Include mips-linux-watch.h.
11406 (struct arch_process_info, struct arch_lwp_info): New.
11407 (update_watch_registers_callback): New function.
11408 (mips_linux_new_process, mips_linux_new_thread) New functions.
11409 (mips_linux_prepare_to_resume, mips_insert_point): New
11411 (mips_remove_point, mips_stopped_by_watchpoint): New
11413 (rsp_bp_type_to_target_hw_bp_type): New function.
11414 (mips_stopped_data_address): New function.
11415 (the_low_target): Add watchpoint support functions.
11417 2013-07-27 Yao Qi <yao@codesourcery.com>
11419 * i386-low.c: Include break-common.h.
11420 (enum target_hw_bp_type): Remove.
11422 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
11424 * Makefile.in (SFILES): /common/target-common.c.
11425 (OBS): Add target-common.o.
11426 (server_h): Add $(srcdir)/../common/target-common.h.
11427 (target-common.o): New target.
11428 * server.c (queue_stop_reply_callback): Free
11429 status string after use.
11430 * target.c (target_waitstatus_to_string): Remove.
11431 * target.h: Include target-common.h.
11432 (resume_kind): Likewise.
11433 (target_waitkind): Likewise.
11434 (target_waitstatus): Likewise.
11435 (TARGET_WNOHANG): Likewise.
11437 2013-07-04 Yao Qi <yao@codesourcery.com>
11439 * Makefile.in (host_alias): Use @host_noncanonical@.
11440 (target_alias): Use @target_noncanonical@.
11441 * configure.ac: Use ACX_NONCANONICAL_TARGET and
11442 ACX_NONCANONICAL_HOST.
11443 * configure: Regenerated.
11446 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
11448 * configure.ac (version_host, version_target): Set and AC_SUBST them.
11449 * configure: Rebuild.
11450 * Makefile.in (version_host, version_target): Get from configure.
11451 (version.c): Use $(version_host) and $(version_target).
11453 2013-07-03 Pedro Alves <palves@redhat.com>
11455 * Makefile.in (config.status): Depend on development.sh.
11456 * acinclude.m4: Include libmcheck.m4.
11457 * configure: Regenerate.
11459 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
11461 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
11462 attribute inside the parentheses.
11463 (winapi_DebugSetProcessKillOnExit): Ditto.
11464 (winapi_DebugBreakProcess): Ditto.
11465 (winapi_GenerateConsoleCtrlEvent): Ditto.
11467 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
11469 * notif.h (notif_event): Add a dummy member to avoid compiler
11472 2013-07-01 Pedro Alves <palves@redhat.com>
11474 * hostio.c (HOSTIO_PATH_MAX): Define.
11475 (require_filename, handle_open, handle_unlink, handle_readlink):
11478 2013-07-01 Pedro Alves <palves@redhat.com>
11480 * server.h: Include "pathmax.h".
11481 * linux-low.c: Don't include sys/param.h.
11482 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
11484 * win32-low.c: Don't include sys/param.h.
11485 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
11487 2013-07-01 Pedro Alves <palves@redhat.com>
11489 * event-loop.c: Don't check HAVE_UNISTD_H before including
11491 * gdbreplay.c: Likewise.
11492 * remote-utils.c: Likewise.
11493 * server.c: Likewise.
11494 * configure.ac: Don't check for unistd.h.
11495 * configure: Regenerate.
11497 2013-06-28 Tom Tromey <tromey@redhat.com>
11499 * Makefile.in (version.c): Use version.in, not
11502 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
11504 * configure.ac (version_host, version_target): Set and AC_SUBST them.
11505 * configure: Rebuild.
11506 * Makefile.in (version_host, version_target): Get from configure.
11507 (version.c): Use $(version_host) and $(version_target).
11509 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
11511 Fix trace-status to output user name without trailing colon.
11512 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
11514 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
11516 Fix trace-status to output proper start-time and stop-time.
11517 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
11518 output start time and stop time in hex as gdb expects.
11520 2013-06-26 Pedro Alves <pedro@codesourcery.com>
11522 * tracepoint.c (build_traceframe_info_xml): Output trace state
11523 variables present in the trace buffer.
11525 2013-06-24 Tom Tromey <tromey@redhat.com>
11527 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
11529 (version.o): Remove.
11530 * gdbreplay.c: Include version.h.
11531 (version, host_name): Don't declare.
11532 * server.h: Include version.h.
11533 (version, host_name): Don't declare.
11535 2013-06-12 Pedro Alves <palves@redhat.com>
11537 * linux-x86-low.c (linux_is_elf64): Delete global.
11538 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
11539 with local linux_pid_exe_is_elf_64_file use.
11541 2013-06-11 Pedro Alves <palves@redhat.com>
11543 * linux-low.c (regset_disabled, disable_regset): New functions.
11544 (regsets_fetch_inferior_registers)
11545 (regsets_store_inferior_registers): Use them.
11546 (initialize_regsets_info); Don't allocate the disabled_regsets
11548 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
11551 2013-06-11 Pedro Alves <palves@redhat.com>
11553 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
11556 2013-06-11 Pedro Alves <palves@redhat.com>
11558 * linux-x86-low.c (initialize_low_arch): Call
11559 init_registers_x32_avx_linux.
11561 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
11563 Fix compatibility with Android Bionic.
11564 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
11567 2013-06-07 Pedro Alves <palves@redhat.com>
11570 * Makefile.in (OBS): Add tdesc.o.
11571 (IPA_OBJS): Add tdesc-ipa.o.
11572 (tdesc-ipa.o): New rule.
11573 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
11575 * linux-low.c (new_inferior): Delete.
11576 (disabled_regsets, num_regsets): Delete.
11577 (linux_add_process): Adjust to set the new per-process
11579 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
11580 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
11581 was a stop. When calling arch_setup, switch the current inferior
11582 to the thread that got an event.
11583 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
11584 (regsets_fetch_inferior_registers)
11585 (regsets_store_inferior_registers): New regsets_info parameter.
11587 (linux_register_in_regsets): New regs_info parameter. Adjust to
11589 (register_addr, fetch_register, store_register): New usrregs_info
11590 parameter. Adjust to use it.
11591 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
11592 parameter regs_info. Adjust to use it.
11593 (linux_fetch_registers): Get the current inferior's regs_info, and
11595 (linux_store_registers): Ditto.
11596 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
11597 (initialize_low): Don't initialize the target_regsets here. Call
11598 initialize_low_arch.
11599 * linux-low.h (target_regsets): Delete declaration.
11600 (struct regsets_info): New.
11601 (struct usrregs_info): New.
11602 (struct regs_info): New.
11603 (struct process_info_private) <new_inferior>: New field.
11604 (struct linux_target_ops): Delete the num_regs, regmap, and
11605 regset_bitmap fields. New field regs_info.
11606 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
11607 * i387-fp.c (num_xmm_registers): Delete.
11608 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
11609 calls to new interface.
11610 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
11611 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
11612 Infer the number of xmm registers from the regcache's target
11614 * i387-fp.h (num_xmm_registers): Delete.
11615 * inferiors.c (add_thread): Don't install the thread's regcache
11617 * proc-service.c (gregset_info): Fetch the current inferior's
11618 regs_info. Adjust to use it.
11619 * regcache.c: Include tdesc.h.
11620 (register_bytes, reg_defs, num_registers)
11621 (gdbserver_expedite_regs): Delete.
11622 (get_thread_regcache): If the thread doesn't have a regcache yet,
11623 create one, instead of aborting gdbserver.
11624 (regcache_invalidate_one): Rename to ...
11625 (regcache_invalidate_thread): ... this.
11626 (regcache_invalidate_one): New.
11627 (regcache_invalidate): Only invalidate registers of the current
11629 (init_register_cache): Add target_desc parameter, and use it.
11630 (new_register_cache): Ditto. Assert the target description has a
11631 non zero registers_size.
11632 (regcache_cpy): Add assertions. Adjust.
11633 (realloc_register_cache, set_register_cache): Delete.
11634 (registers_to_string, registers_from_string): Adjust.
11635 (find_register_by_name, find_regno, find_register_by_number)
11636 (register_cache_size): Add target_desc parameter, and use it.
11637 (free_register_cache_thread, free_register_cache_thread_one)
11638 (regcache_release, register_cache_size): New.
11639 (register_size): Add target_desc parameter, and use it.
11640 (register_data, supply_register, supply_register_zeroed)
11641 (supply_regblock, supply_register_by_name, collect_register)
11642 (collect_register_as_string, collect_register_by_name): Adjust.
11643 * regcache.h (struct target_desc): Forward declare.
11644 (struct regcache) <tdesc>: New field.
11645 (init_register_cache, new_register_cache): Add target_desc
11647 (regcache_invalidate_thread): Declare.
11648 (regcache_invalidate_one): Delete declaration.
11649 (regcache_release): Declare.
11650 (find_register_by_number, register_cache_size, register_size)
11651 (find_regno): Add target_desc parameter.
11652 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
11654 * remote-utils.c: Include tdesc.h.
11655 (outreg, prepare_resume_reply): Adjust.
11656 * server.c: Include tdesc.h.
11657 (gdbserver_xmltarget): Delete declaration.
11658 (get_features_xml, process_serial_event): Adjust.
11659 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
11661 (struct process_info) <tdesc>: New field.
11662 (ipa_tdesc): Declare.
11663 * tdesc.c: New file.
11664 * tdesc.h: New file.
11665 * tracepoint.c: Include tdesc.h.
11666 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
11667 (get_context_regcache): Adjust to pass ipa_tdesc down.
11668 (do_action_at_tracepoint): Adjust to get the register cache size
11669 from the context regcache's description.
11670 (traceframe_walk_blocks): Adjust to get the register cache size
11671 from the current trace frame's description.
11672 (traceframe_get_pc): Adjust to get current trace frame's
11673 description and pass it down.
11674 (gdb_collect): Adjust to get the register cache size from the
11676 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
11677 (gdbserver_xmltarget): Delete.
11678 (initialize_low_tracepoint): Set the ipa's target description.
11679 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
11680 (initialize_low_tracepoint): Set the ipa's target description.
11681 * linux-x86-low.c: Include tdesc.h.
11682 [__x86_64__] (is_64bit_tdesc): New.
11683 (ps_get_thread_area, x86_get_thread_area): Use it.
11684 (i386_cannot_store_register): Rename to ...
11685 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
11686 (i386_cannot_fetch_register): Rename to ...
11687 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
11688 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
11690 (target_regsets): Rename to ...
11691 (x86_regsets): ... this.
11692 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
11694 (x86_siginfo_fixup): Use is_64bit_tdesc.
11695 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
11696 (tdesc_x32_avx_linux, tdesc_x32_linux)
11697 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
11699 (x86_linux_update_xmltarget): Delete.
11700 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
11701 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
11702 (AMD64_LINUX_USER64_CS): New.
11703 (x86_linux_read_description): New, based on
11704 x86_linux_update_xmltarget.
11705 (same_process_callback): New.
11706 (x86_arch_setup_process_callback): New.
11707 (x86_linux_update_xmltarget): New.
11708 (x86_regsets_info): New.
11709 (amd64_linux_regs_info): New.
11710 (i386_linux_usrregs_info): New.
11711 (i386_linux_regs_info): New.
11712 (x86_linux_regs_info): New.
11713 (x86_arch_setup): Reimplement.
11714 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
11715 (x86_emit_ops): Ditto.
11716 (the_low_target): Adjust. Install x86_linux_regs_info,
11717 x86_cannot_fetch_register, and x86_cannot_store_register.
11718 (initialize_low_arch): New.
11719 * linux-ia64-low.c (tdesc_ia64): Declare.
11720 (ia64_fetch_register): Adjust.
11721 (ia64_usrregs_info, regs_info): New globals.
11722 (ia64_regs_info): New function.
11723 (the_low_target): Adjust.
11724 (initialize_low_arch): New function.
11725 * linux-sparc-low.c (tdesc_sparc64): Declare.
11726 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
11728 (sparc_arch_setup): New function.
11729 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
11730 (the_low_target): Adjust.
11731 (initialize_low_arch): New function.
11732 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
11733 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
11734 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
11735 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
11736 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
11737 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
11738 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
11739 (tdesc_powerpc_isa205_vsx64l): Declare.
11740 (ppc_cannot_store_register, ppc_collect_ptrace_register)
11741 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
11742 (ppc_set_pc, ppc_get_hwcap): Adjust.
11743 (ppc_usrregs_info): Forward declare.
11744 (!__powerpc64__) ppc_regmap_adjusted: New global.
11745 (ppc_arch_setup): Adjust to the current process'es target
11747 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
11748 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
11749 (ppc_store_evrregset): Adjust.
11750 (target_regsets): Rename to ...
11751 (ppc_regsets): ... this, and make static.
11752 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
11753 (ppc_regs_info): New function.
11754 (the_low_target): Adjust.
11755 (initialize_low_arch): New function.
11756 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
11757 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
11758 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
11759 (tdesc_s390x_linux64v2): Declare.
11760 (s390_collect_ptrace_register, s390_supply_ptrace_register)
11761 (s390_fill_gregset, s390_store_last_break): Adjust.
11762 (target_regsets): Rename to ...
11763 (s390_regsets): ... this, and make static.
11764 (s390_get_pc, s390_set_pc): Adjust.
11765 (s390_get_hwcap): New target_desc parameter, and use it.
11766 [__s390x__] (have_hwcap_s390_high_gprs): New global.
11767 (s390_arch_setup): Adjust to set the current process'es target
11768 description. Don't adjust the regmap.
11769 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
11770 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
11771 (regs_info_3264): New globals.
11772 (s390_regs_info): New function.
11773 (the_low_target): Adjust.
11774 (initialize_low_arch): New function.
11775 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
11776 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
11777 [__mips64] (init_registers_mips_linux)
11778 (init_registers_mips_dsp_linux): Delete defines.
11779 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
11780 (have_dsp): New global.
11781 (mips_read_description): New, based on mips_arch_setup.
11782 (mips_arch_setup): Reimplement.
11783 (get_usrregs_info): New function.
11784 (mips_cannot_fetch_register, mips_cannot_store_register)
11785 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
11786 (mips_fill_fpregset, mips_store_fpregset): Adjust.
11787 (target_regsets): Rename to ...
11788 (mips_regsets): ... this, and make static.
11789 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
11790 (dsp_regs_info, regs_info): New globals.
11791 (mips_regs_info): New function.
11792 (the_low_target): Adjust.
11793 (initialize_low_arch): New function.
11794 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
11795 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
11797 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
11798 (arm_read_description): New, with bits factored from
11800 (arm_arch_setup): Reimplement.
11801 (target_regsets): Rename to ...
11802 (arm_regsets): ... this, and make static.
11803 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
11804 (arm_regs_info): New function.
11805 (the_low_target): Adjust.
11806 (initialize_low_arch): New function.
11807 * linux-m68k-low.c (tdesc_m68k): Declare.
11808 (target_regsets): Rename to ...
11809 (m68k_regsets): ... this, and make static.
11810 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
11811 (m68k_regs_info): New function.
11812 (m68k_arch_setup): New function.
11813 (the_low_target): Adjust.
11814 (initialize_low_arch): New function.
11815 * linux-sh-low.c (tdesc_sharch): Declare.
11816 (target_regsets): Rename to ...
11817 (sh_regsets): ... this, and make static.
11818 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
11819 (sh_regs_info, sh_arch_setup): New functions.
11820 (the_low_target): Adjust.
11821 (initialize_low_arch): New function.
11822 * linux-bfin-low.c (tdesc_bfin): Declare.
11823 (bfin_arch_setup): New function.
11824 (bfin_usrregs_info, regs_info): New globals.
11825 (bfin_regs_info): New function.
11826 (the_low_target): Adjust.
11827 (initialize_low_arch): New function.
11828 * linux-cris-low.c (tdesc_cris): Declare.
11829 (cris_arch_setup): New function.
11830 (cris_usrregs_info, regs_info): New globals.
11831 (cris_regs_info): New function.
11832 (the_low_target): Adjust.
11833 (initialize_low_arch): New function.
11834 * linux-cris-low.c (tdesc_crisv32): Declare.
11835 (cris_arch_setup): New function.
11836 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
11837 (cris_regs_info): New function.
11838 (the_low_target): Adjust.
11839 (initialize_low_arch): New function.
11840 * linux-m32r-low.c (tdesc_m32r): Declare.
11841 (m32r_arch_setup): New function.
11842 (m32r_usrregs_info, regs_info): New globals.
11843 (m32r_regs_info): Adjust.
11844 (initialize_low_arch): New function.
11845 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
11846 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
11847 (tic6x_usrregs_info): Forward declare.
11848 (tic6x_read_description): New function, based on ...
11849 (tic6x_arch_setup): ... this. Reimplement.
11850 (target_regsets): Rename to ...
11851 (tic6x_regsets): ... this, and make static.
11852 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
11853 (tic6x_regs_info): New function.
11854 (the_low_target): Adjust.
11855 (initialize_low_arch): New function.
11856 * linux-xtensa-low.c (tdesc_xtensa): Declare.
11857 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
11858 (target_regsets): Rename to ...
11859 (xtensa_regsets): ... this, and make static.
11860 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
11862 (xtensa_arch_setup, xtensa_regs_info): New functions.
11863 (the_low_target): Adjust.
11864 (initialize_low_arch): New function.
11865 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
11866 (nios2_arch_setup): Set the current process'es tdesc.
11867 (target_regsets): Rename to ...
11868 (nios2_regsets): ... this.
11869 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
11870 (nios2_regs_info): New function.
11871 (the_low_target): Adjust.
11872 (initialize_low_arch): New function.
11873 * linux-aarch64-low.c (tdesc_aarch64): Declare.
11874 (aarch64_arch_setup): Set the current process'es tdesc.
11875 (target_regsets): Rename to ...
11876 (aarch64_regsets): ... this.
11877 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
11878 (aarch64_regs_info): New function.
11879 (the_low_target): Adjust.
11880 (initialize_low_arch): New function.
11881 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
11883 (target_regsets): Rename to ...
11884 (tile_regsets): ... this.
11885 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
11886 (tile_regs_info): New function.
11887 (tile_arch_setup): Set the current process'es tdesc.
11888 (the_low_target): Adjust.
11889 (initialize_low_arch): New function.
11890 * spu-low.c (tdesc_spu): Declare.
11891 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
11892 * win32-arm-low.c (tdesc_arm): Declare.
11893 (arm_arch_setup): New function.
11894 (the_low_target): Install arm_arch_setup instead of
11895 init_registers_arm.
11896 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
11897 (init_windows_x86): Rename to ...
11898 (i386_arch_setup): ... this. Set `win32_tdesc'.
11899 (the_low_target): Adjust.
11900 * win32-low.c (win32_tdesc): New global.
11901 (child_add_thread): Don't create the thread cache here.
11902 (do_initial_child_stuff): Set the new process'es tdesc.
11903 * win32-low.h (struct target_desc): Forward declare.
11904 (win32_tdesc): Declare.
11905 * lynx-i386-low.c (tdesc_i386): Declare global.
11906 (lynx_i386_arch_setup): Set `lynx_tdesc'.
11907 * lynx-low.c (lynx_tdesc): New global.
11908 (lynx_add_process): Set the new process'es tdesc.
11909 * lynx-low.h (struct target_desc): Forward declare.
11910 (lynx_tdesc): Declare global.
11911 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
11912 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
11913 * nto-low.c (nto_tdesc): New global.
11914 (do_attach): Set the new process'es tdesc.
11915 * nto-low.h (struct target_desc): Forward declare.
11916 (nto_tdesc): Declare.
11917 * nto-x86-low.c (tdesc_i386): Declare.
11918 (nto_x86_arch_setup): Set `nto_tdesc'.
11920 2013-06-04 Gary Benson <gbenson@redhat.com>
11922 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
11923 to qSupported response when appropriate.
11924 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
11925 with nonzero-length annex.
11926 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
11927 arguments supplied in annex.
11929 2013-05-31 Doug Evans <dje@google.com>
11932 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
11933 64 bits in 64-cross-32 environment.
11935 2013-05-28 Pedro Alves <palves@redhat.com>
11937 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
11938 (aarch64-without-fpu.c): Delete rule.
11939 * configure.srv (aarch64*-*-linux*): Remove references to
11940 aarch64-without-fpu.o and aarch64-without-fpu.xml.
11941 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
11944 2013-05-24 Pedro Alves <palves@redhat.com>
11946 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
11947 instead of strchr/decode_address. Error if the range isn't split
11948 with a ','. Don't assume there's be a ':' in the action.
11950 2013-05-23 Yao Qi <yao@codesourcery.com>
11951 Pedro Alves <palves@redhat.com>
11953 * linux-low.c (lwp_in_step_range): New function.
11954 (linux_wait_1): If the thread was range stepping and stopped
11955 outside the stepping range, report the stop to GDB. Otherwise,
11956 continue stepping. Add range stepping debug output.
11957 (linux_set_resume_request): Copy the step range from the resume
11958 request to the lwp.
11959 (linux_supports_range_stepping): New.
11960 (linux_target_ops) <supports_range_stepping>: Set to
11961 linux_supports_range_stepping.
11962 * linux-low.h (struct linux_target_ops)
11963 <supports_range_stepping>: New field.
11964 (struct lwp_info) <step_range_start, step_range_end>: New fields.
11965 * linux-x86-low.c (x86_supports_range_stepping): New.
11966 (the_low_target) <supports_range_stepping>: Set to
11967 x86_supports_range_stepping.
11968 * server.c (handle_v_cont): Handle 'r' action.
11969 (handle_v_requests): Append ";r" if the target supports range
11971 * target.h (struct thread_resume) <step_range_start,
11972 step_range_end>: New fields.
11973 (struct target_ops) <supports_range_stepping>:
11975 (target_supports_range_stepping): New macro.
11977 2013-05-17 Joel Brobecker <brobecker@adacore.com>
11979 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
11980 confusion in comment.
11982 2013-05-17 Joel Brobecker <brobecker@adacore.com>
11984 * lynx-low.c (struct process_info_private): New type.
11985 (lynx_add_process): New function.
11986 (lynx_create_inferior, lynx_attach): Replace calls to
11987 add_process by calls to lynx_add_process.
11988 (lynx_resume): If PTID is null, then try using
11989 current_process()->private->last_wait_event_ptid.
11991 (lynx_clear_inferiors): Delete. The contents of that function
11992 has been inlined in lynx_mourn;
11993 (lynx_wait_1): Save the ptid in the process's private data.
11994 (lynx_mourn): Free the process' private data. Replace call
11995 to lynx_clear_inferiors by call to clear_inferiors.
11997 2013-05-17 Yao Qi <yao@codesourcery.com>
11999 * i386-low.c (i386_length_and_rw_bits): Move the comment to
12002 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
12004 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
12005 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
12006 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
12007 PT_TEXT_END_ADDR guards. Update comments.
12008 (linux_target_op) <read_offsets>: Conditionally define to
12009 linux_read_offsets if the target is UCLIBC and if it defines
12010 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
12012 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
12013 Andrew Jenner <andrew@codesourcery.com>
12015 * Makefile.in (SFILES): Add linux-nios2-low.c.
12016 (clean): Add action to delete nios2-linux.c.
12017 (nios2-linux.c): New rule.
12018 * configure.srv: Add nios2*-*-linux*.
12019 * linux-nios2-low.c: New.
12021 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
12023 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
12025 2013-04-25 Hui Zhu <hui@codesourcery.com>
12028 * ax.c (ax_printf): Add fflush.
12030 2013-04-22 Tom Tromey <tromey@redhat.com>
12032 * Makefile.in (SFILES): Add filestuff.c.
12033 (OBS): Add filestuff.o.
12034 (filestuff.o): New target.
12035 * config.in, configure: Rebuild.
12036 * configure.ac: Check for fdwalk, pipe2.
12038 2013-04-17 Pedro Alves <palves@redhat.com>
12040 * configure.ac (USE_THREAD_DB): Delete variable.
12041 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
12042 Don't AC_SUBST USE_THREAD_DB.
12043 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
12044 * config.in, configure: Regenerate.
12046 2013-04-16 Pedro Alves <palves@redhat.com>
12048 * linux-low.h (struct lwp_info) <thread_known>: Move under
12049 the USE_THREAD_DB #ifdef.
12051 2013-04-16 Pedro Alves <palves@redhat.com>
12053 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
12054 (linux-low.o): Delete rule.
12055 * linux-low.h: Always include "gdb_thread_db.h" instead of
12056 conditionally including thread_db.h.
12057 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
12060 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
12062 * Makefile.in (install-only): Fix make install regression.
12064 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
12066 Convert man pages to texinfo, new gdbinit.5 texinfo page.
12067 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
12069 * gdbserver.1: Remove.
12071 2013-03-22 Pedro Alves <palves@redhat.com>
12073 * linux-low.c (handle_extended_wait): Don't call
12074 linux_enable_event_reporting.
12076 2013-03-15 Tony Theodore <tonyt@logyst.com>
12079 * Makefile.in (SHELL): Use @SHELL@.
12081 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
12083 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
12086 2013-03-13 Joel Brobecker <brobecker@adacore.com>
12088 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
12089 Remove extraneous NULL element.
12091 2013-03-13 Yao Qi <yao@codesourcery.com>
12093 * tracepoint.c (traceframe_read_tsv): Look for the last matched
12094 'V' block in trace frame.
12096 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
12098 * target.h (struct target_ops): Add btrace ops.
12099 (target_supports_btrace): New macro.
12100 (target_enable_btrace): New macro.
12101 (target_disable_btrace): New macro.
12102 (target_read_btrace): New macro.
12103 * gdbthread.h (struct thread_info): Add btrace field.
12104 * server.c: Include btrace-common.h.
12105 (handle_btrace_general_set): New function.
12106 (handle_btrace_enable): New function.
12107 (handle_btrace_disable): New function.
12108 (handle_general_set): Call handle_btrace_general_set.
12109 (handle_qxfer_btrace): New function.
12110 (struct qxfer qxfer_packets[]): Add btrace entry.
12111 * inferiors.c (remove_thread): Disable btrace.
12112 * linux-low: Include linux-btrace.h.
12113 (linux_low_enable_btrace): New function.
12114 (linux_low_read_btrace): New function.
12115 (linux_target_ops): Add btrace ops.
12116 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
12117 Add srv_linux_btrace=yes.
12118 (x86_64-*-linux*): Add linux-btrace.o.
12119 Add srv_linux_btrace=yes.
12120 * configure.ac: Define HAVE_LINUX_BTRACE.
12121 * config.in: Regenerated.
12122 * configure: Regenerated.
12124 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
12126 * server.c (handle_qxfer): Preserve error message if -3 is
12128 (qxfer): Document the -3 return value.
12130 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
12132 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
12133 (linux_btrace_h): New variable.
12134 (linux-btrace.o): New rule.
12136 2013-03-08 Stan Shebs <stan@codesourcery.com>
12137 Hafiz Abid Qadeer <abidh@codesourcery.com>
12139 * tracepoint.c (trace_buffer_size): New global.
12140 (DEFAULT_TRACE_BUFFER_SIZE): New define.
12141 (init_trace_buffer): Change to one-argument function. Allocate
12142 trace buffer memory.
12143 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
12144 handle QTBuffer:size packet.
12145 (cmd_bigqtbuffer_size): New function.
12146 (initialize_tracepoint): Call init_trace_buffer with
12147 DEFAULT_TRACE_BUFFER_SIZE.
12148 * server.c (handle_query): Add QTBuffer:size in the
12151 2013-03-07 Yao Qi <yao@codesourcery.com>
12153 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
12154 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
12156 (cmd_qtsp): Adjust condition. Do post increment.
12157 Set cur_action and cur_step_action back to 0.
12159 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
12162 * linux-low.c (linux_write_memory): Return early success if LEN is
12165 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
12167 * configure.srv: Add x86_64-*-cygwin* as target.
12169 2013-02-28 Tom Tromey <tromey@redhat.com>
12171 * configure.ac: Invoke AC_SYS_LARGEFILE.
12172 * configure, config.in: Rebuild.
12174 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
12176 * win32-low.c: Throughout, fix format strings and casts of
12177 printf-like functions to avoid type related warnings on all
12179 (get_child_debug_event): Print dwDebugEventCode as hex since
12180 that's how it's usually documented.
12182 2013-02-28 Yao Qi <yao@codesourcery.com>
12184 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
12187 2013-02-27 Jiong Wang <jiwang@tilera.com>
12189 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
12190 (reg-tilegx32.c): New rule.
12191 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
12192 * linux-tile-low.c (tile_arch_setup): New function. Invoke
12193 different register info initializer according to elf class.
12194 (init_registers_tilgx32): New function. The tilegx32 register info
12196 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
12197 (tile_store_gregset): Likewise.
12199 2013-02-27 Yao Qi <yao@codesourcery.com>
12201 * server.c (process_point_options): Print debug message when
12202 debug_threads is true.
12204 2013-02-26 Yao Qi <yao@codesourcery.com>
12206 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
12208 2013-02-19 Pedro Alves <palves@redhat.com>
12209 Kai Tietz <ktietz@redhat.com>
12213 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
12214 instead of strtoul to extract address from packet.
12215 (process_serial_event) <'z'>: Likewise.
12217 2013-02-18 Yao Qi <yao@codesourcery.com>
12219 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
12221 2013-02-14 Pedro Alves <palves@redhat.com>
12225 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
12226 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
12228 2013-02-14 Pedro Alves <palves@redhat.com>
12230 * tracepoint.c (cmd_qtdpsrc): Use savestring.
12232 2013-02-14 Pedro Alves <palves@redhat.com>
12234 * tracepoint.c (save_string): Delete.
12235 (add_tracepoint_action): Use savestring instead of save_string.
12237 2013-02-12 Pedro Alves <palves@redhat.com>
12239 * linux-xtensa-low.c: Ditto.
12240 * xtensa-xtregs.c: Ditto.
12242 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
12244 * thread-db.c (thread_db_get_tls_address): NULL pointer check
12247 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
12249 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
12250 aarch64_num_wp_regs and aarch64_num_bp_regs to
12251 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
12253 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
12255 * linux-aarch64-low.c (ps_get_thread_area): Replace
12256 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
12258 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
12259 Marcus Shawcroft <marcus.shawcroft@arm.com>
12260 Nigel Stephens <nigel.stephens@arm.com>
12261 Yufeng Zhang <yufeng.zhang@arm.com>
12263 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
12264 (aarch64.c, aarch64-without-fpu.c): New targets.
12265 * configure.srv (aarch64*-*-linux*): New.
12266 * linux-aarch64-low.c: New file.
12268 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
12270 * linux-low.c (handle_extended_wait, linux_create_inferior)
12271 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
12272 (dequeue_one_deferred_signal, linux_resume_one_thread)
12273 (fetch_register, linux_write_memory, linux_enable_event_reporting)
12274 (linux_tracefork_grandchild, linux_test_for_tracefork)
12275 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
12276 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
12277 where the argument is 0.
12279 2013-01-25 Yao Qi <yao@codesourcery.com>
12281 * event-loop.c: Include "queue.h".
12282 (gdb_event_p): New typedef.
12283 (struct gdb_event) <next_event>: Remove.
12284 (event_queue): Change to QUEUE(gdb_event_p).
12285 (async_queue_event): Remove.
12286 (gdb_event_xfree): New.
12287 (initialize_event_loop): New.
12288 (process_event): Use API from QUEUE.
12289 (wait_for_event): Likewise.
12290 * server.c (main): Call initialize_event_loop.
12291 * server.h (initialize_event_loop): Declare.
12293 2013-01-18 Yao Qi <yao@codesourcery.com>
12295 * ax.h (struct eval_agent_expr_context): New.
12296 (gdb_eval_agent_expr): Update declaration.
12297 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
12298 TFRAME. Add new argument CTX.
12299 * server.h (struct eval_agent_expr_context): Declare.
12300 (agent_mem_read, agent_tsv_read): Update declaration.
12301 (agent_mem_read_string): Likewise.
12302 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
12303 (add_traceframe_block): Add new argument TPOINT.
12304 Increase TPOINT->traceframe_usage.
12305 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
12306 eval_tracepoint_agent_expr.
12307 (condition_true_at_tracepoint): Likewise.
12308 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
12309 (agent_mem_read_string, agent_tsv_read): Likewise.
12311 2013-01-16 Yao Qi <yao@codesourcery.com>
12313 * linux-low.c (linux_resume_one_lwp): Don't check
12314 'lwp->bp_reinsert != 0'.
12316 2013-01-07 Joel Brobecker <brobecker@adacore.com>
12317 Pedro Alves <palves@redhat.com>
12319 * lynx-low.c (ptrace_request_to_str): Define a temporary
12320 macro and use it to simplify this function's implementation.
12322 2013-01-07 Joel Brobecker <brobecker@adacore.com>
12324 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
12327 2013-01-07 Joel Brobecker <brobecker@adacore.com>
12329 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
12331 2013-01-07 Joel Brobecker <brobecker@adacore.com>
12333 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
12335 2013-01-07 Joel Brobecker <brobecker@adacore.com>
12337 * lynx-low.c (lynx_resume): Use the resume_info parameter
12338 to determine the ptid for the lynx_ptrace call, unless
12339 it is equal to minus_one_ptid, in which case we use the
12340 ptid of the current_inferior.
12341 (lynx_wait_1): After having received a thread create/exit
12342 event, resume the inferior's execution using the signaling
12343 thread's ptid, rather than the old ptid.
12345 2013-01-07 Joel Brobecker <brobecker@adacore.com>
12347 * lynx-low.c (lynx_resume): Delete variable ret.
12349 2013-01-01 Joel Brobecker <brobecker@adacore.com>
12351 * gdbreplay.c (gdbreplay_version): Update copyright year.
12352 * server.c (gdbserver_version): Likewise.
12354 2012-12-17 Joel Brobecker <brobecker@adacore.com>
12356 * lynx-low.c (lynx_wait_1): Add debug trace before adding
12359 2012-12-17 Joel Brobecker <brobecker@adacore.com>
12361 * lynx-low.c (ptrace_request_to_str): Add handling for
12362 PTRACE_GETTRACESIG.
12364 2012-12-17 Joel Brobecker <brobecker@adacore.com>
12366 * lynx-low.c (lynx_attach): Delete variable new_process.
12368 2012-12-17 Joel Brobecker <brobecker@adacore.com>
12370 * lynx-low.c (lynx_create_inferior): Delete variable
12373 2012-12-17 Joel Brobecker <brobecker@adacore.com>
12375 * lynx-low.c (ptrace_request_to_str): Do not handle
12376 PTRACE_GETTHREADLIST if this macro does not exist.
12378 2012-12-15 Yao Qi <yao@codesourcery.com>
12380 * Makefile.in (OBS): Add notif.o.
12381 * notif.c, notif.h: New.
12382 * server.c: Include "notif.h".
12383 (struct vstop_notif) <next>: Remove.
12385 (queue_stop_reply): Update.
12386 (push_event, send_next_stop_reply): Remove.
12387 (discard_queued_stop_replies): Update.
12388 (notif_stop): New variable.
12389 (handle_v_stopped): Remove.
12390 (handle_v_requests): Don't call handle_v_stopped. Call
12391 handle_ack_notif instead.
12392 (queue_stop_reply_callback): Call notif_event_enque instead
12393 of queue_stop_reply.
12394 (handle_status): Don't call send_next_stop_reply, call
12395 notif_write_event instead.
12396 (kill_inferior_callback): Likewise.
12397 (detach_or_kill_inferior_callback): Likewise.
12398 (main): Call initialize_notif.
12399 (process_serial_event): Call QUEUE_is_empty.
12400 (handle_target_event): Call notif_push instead of push event.
12401 * server.h (push_event): Remove declaration.
12403 2012-12-10 Tom Tromey <tromey@redhat.com>
12405 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
12406 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
12409 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
12410 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
12411 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
12412 (amd64-linux-ipa.o, ax.o): Rewrite.
12413 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
12414 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
12415 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
12416 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
12417 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
12418 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
12419 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
12420 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
12421 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
12422 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
12423 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
12424 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
12425 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
12426 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
12427 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
12428 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
12429 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
12430 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
12431 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
12432 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
12433 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
12434 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
12435 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
12436 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
12437 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
12438 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
12439 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
12440 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
12441 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
12442 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
12443 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
12444 (reg-tilegx.o): Remove.
12445 (all_object_files): New macro.
12446 Include .deps files.
12447 * aclocal.m4, configure: Rebuild.
12448 * acinclude.m4: Include depstand.m4, lead-dot.m4.
12449 * configure.ac: Invoke ZW_CREATE_DEPDIR,
12450 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
12452 2012-12-05 Tom Tromey <tromey@redhat.com>
12455 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
12457 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
12459 * configure.ac: Check for linux/perf_event.h.
12460 * config.in: Regenerated.
12461 * configure: Regenerated.
12463 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
12465 * hostio.c (handle_readlink): Decrease buffer size
12466 parameter passed to readlink by one byte.
12468 2012-11-26 Yao Qi <yao@codesourcery.com>
12470 * configure.ac (build_warnings): Append '-Wempty-body'.
12471 * configure: Regenerated.
12472 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
12475 2012-11-15 Pierre Muller <muller@sourceware.org>
12477 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
12478 * config.in: Regenerate.
12479 * configure: Regenerate.
12480 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
12481 Use "gdb_wait.h" header instead of <sys/wait.h> header.
12482 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
12483 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
12485 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
12486 instead of <sys/wait.h> header.
12487 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
12489 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
12491 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
12492 (various make rules): Remove -DGDBSERVER
12494 2012-11-09 Yao Qi <yao@codesourcery.com>
12496 * spu-low.c (current_ptid): Move it to ..
12497 * gdbthread.h: ... here. New.
12498 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
12499 * server.c (myresume, process_serial_event): Likewise.
12500 * thread-db.c (thread_db_find_new_threads): Likewise.
12501 * tracepoint.c (run_inferior_command): Likewise.
12503 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
12505 * server.c (handle_search_memory_1): Include access length in
12508 2012-09-05 Michael Brandt <michael.brandt@axis.com>
12510 * linux-crisv32-low.c: Fix compile errors.
12512 2012-09-04 Yao Qi <yao@codesourcery.com>
12514 * tracepoint.c (cmd_qtsv): Adjust debug message.
12515 Don't check CUR_TPOINT.
12517 2012-08-28 Yao Qi <yao@codesourcery.com>
12519 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
12520 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
12521 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
12522 Remove declarations of xmalloc, xreallloc, xstrdup and
12524 * Makefile.in (libiberty_h): New.
12525 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
12526 (linux-bfin-low.o): Append dependency 'libiberty.h'.
12528 2012-08-23 Yao Qi <yao@codesourcery.com>
12530 * server.h: Remove declaration of 'xsnprintf'.
12532 2012-08-22 Keith Seitz <keiths@redhat.com>
12534 * server.h: Include build-gnulib-gbserver/config.h.
12535 * gdbreplay.c: Likewise.
12537 2012-08-08 Doug Evans <dje@google.com>
12539 * Makefile.in (SFILES): Add gdb_vecs.c.
12540 (OBS): Add gdb_vecs.o.
12541 (gdb_vecs_h, host_defs_h): New variables.
12542 (thread-db.o): Add $(gdb_vecs_h) dependency.
12543 (gdb_vecs.o): New rule.
12544 * thread-db.c: #include "gdb_vecs.h".
12545 (thread_db_load_search): Use a vector to iterate over path elements.
12546 Handle text appearing after "$pdir".
12548 * configure.ac: Add check for strstr.
12549 * config.in: Regenerate.
12550 * configure: Regenerate.
12552 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
12554 * hostio.c (handle_pread): If pread fails, fall back to attempting
12556 (handle_pwrite): Likewise for pwrite.
12558 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
12560 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
12561 between unsupported TYPE and unimplementable ADDR/LEN combination.
12562 (arm_insert_point): Act on new return value.
12564 2012-07-31 Pedro Alves <palves@redhat.com>
12566 * server.c (process_point_options): Only skip tokens if we find
12567 one that is unrecognized. Don't treat 'X' specially while
12568 skipping unrecognized tokens.
12570 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
12572 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
12573 to 4-byte-align HW breakpoint addresses for Thumb.
12575 2012-07-27 Yao Qi <yao@codesourcery.com>
12579 * server.h: Declare gdb_agent_about_to_close.
12580 * target.c (kill_inferior): Include "agent.h".
12581 New. Send command 'kill'.
12582 * target.h (kill_inferior): Removed macro.
12583 * tracepoint.c (gdb_agent_about_to_close): New.
12584 (gdb_agent_helper_thread): Handle command 'close'.
12585 Wait endlessly until the inferior stops.
12586 Install gdb_agent_remove_socket to atexit hook.
12587 (agent_socket_name): New static variable.
12588 (gdb_agent_socket_init): Replace local variable 'name' with
12589 'agent_socket_name'.
12590 (gdb_agent_remove_socket): New.
12592 2012-07-27 Yao Qi <yao@codesourcery.com>
12594 * server.c (process_point_options): Stop at 'X' when parsing.
12596 2012-07-19 Michael Eager <eager@eagercon.com>
12598 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
12600 * linux-x86-low.c (x86_insert_point, x86_remove_point):
12601 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
12602 hardware breakpoint.
12604 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
12606 * gdbserver/linux-low.c (initialize_low): Call
12607 linux_ptrace_init_warnings.
12609 2012-07-02 Doug Evans <dje@google.com>
12611 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
12614 2012-07-02 Stan Shebs <stan@codesourcery.com>
12616 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
12617 (ax.o): Add it to build rule.
12619 (OBS): Add format.o.
12620 (IPA_OBS): Add format.o.
12621 * server.c (handle_query): Claim support for breakpoint commands.
12622 (process_point_options): Add command case.
12623 (process_serial_event): Leave running if there are printfs in
12625 * mem-break.h (any_persistent_commands): Declare.
12626 (add_breakpoint_commands): Declare.
12627 (gdb_no_commands_at_breakpoint): Declare.
12628 (run_breakpoint_commands): Declare.
12629 * mem-break.c (struct point_command_list): New struct.
12630 (struct breakpoint): New field command_list.
12631 (any_persistent_commands): New function.
12632 (add_commands_to_breakpoint): New function.
12633 (add_breakpoint_commands): New function.
12634 (gdb_no_commands_at_breakpoint): New function.
12635 (run_breakpoint_commands): New function.
12636 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
12638 * ax.c: Include format.h.
12639 (ax_printf): New function.
12640 (gdb_eval_agent_expr): Add printf opcode.
12642 2012-06-13 Yao Qi <yao@codesourcery.com>
12644 * server.c (start_inferior): Remove duplicated writes to fields
12645 'last_resume_kind' and 'last_status' of 'current_inferior'.
12647 2012-06-12 Yao Qi <yao@codesourcery.com>
12648 Pedro Alves <palves@redhat.com>
12650 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
12652 * server.c (handle_v_cont): Extend comment.
12654 2012-06-11 Yao Qi <yao@codesourcery.com>
12656 * linux-low.c (linux_attach): Add 'static'.
12658 2012-06-06 Yao Qi <yao@codesourcery.com>
12660 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
12662 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
12664 Fix gcc -flto compilation warning.
12665 * server.c (main): Make variable multi_mode and attach volatile.
12667 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
12669 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
12670 if the platform doesn't know about it.
12672 2012-05-30 Jeff Kenton <jkenton@tilera.com>
12674 * Makefile.in (SFILES): Add linux-tile-low.c.
12675 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
12676 * configure.srv: Handle tilegx-*-linux*.
12677 * linux-tile-low.c: New file.
12679 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12681 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
12683 2012-05-24 Pedro Alves <palves@redhat.com>
12687 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
12689 2012-05-24 Pedro Alves <palves@redhat.com>
12693 Replace target_signal with gdb_signal throughout.
12695 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
12697 * linux-low.c (linux_store_registers): Avoid the copying sequence
12698 when no data has been retrieved by ptrace.
12700 2012-05-22 Will Deacon <will.deacon@arm.com>
12702 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
12703 Include asm/ptrace.h.
12704 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
12707 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
12709 * linux-low.c (linux_store_registers): Don't re-retrieve data
12710 with ptrace that has already been obtained from /proc. Always
12711 copy any data retrieved with ptrace to the buffer supplied.
12713 2012-05-11 Yao Qi <yao@codesourcery.com>
12714 Pedro Alves <palves@redhat.com>
12716 * linux-low.c (enum stopping_threads_kind): New.
12717 (stopping_threads): Change type to `enum stopping_threads_kind'.
12718 (handle_extended_wait): If stopping and suspending threads, leave
12719 the new_lwp suspended too.
12720 (linux_wait_for_event): Adjust.
12721 (stop_all_lwps): Set `stopping_threads' to
12722 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
12723 whether we're suspending threads or just stopping them. Assert no
12726 2012-04-29 Yao Qi <yao@codesourcery.com>
12728 * server.h: Move some code to ...
12729 * gdbthread.h: ... here. New.
12730 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
12731 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
12732 (nto-low.o, win32-low.o): Likewise.
12733 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
12734 * regcache.c, remote-utils.c, server.c: Likewise.
12735 * target.c, tracepoint.c, win32-low.c: Likewise.
12737 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
12739 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
12740 (PTRACE_ARG4_TYPE): Likewise.
12741 (PTRACE_XFER_TYPE): Likewise.
12742 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
12743 ptrace to PTRACE_ARG3_TYPE.
12744 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
12745 (PTRACE_ARG4_TYPE): Likewise.
12746 (PTRACE_XFER_TYPE): Likewise.
12747 (linux_detach_one_lwp): Cast fourth argument of
12748 ptrace to long then PTRACE_ARG4_TYPE.
12749 (regsets_fetch_inferior_registers): Cast third argument of
12750 ptrace to long then PTRACE_ARG3_TYPE.
12751 (regsets_store_inferior_registers): Likewise.
12753 2012-04-20 Pedro Alves <palves@redhat.com>
12755 * configure: Regenerate.
12757 2012-04-19 Pedro Alves <palves@redhat.com>
12759 * Makefile.in (GNULIB_BUILDDIR): New.
12760 (LIBGNU, INCGNU, GNULIB_H): Adjust.
12761 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
12762 (all, install-only, uninstall, clean-info, all-lib, clean): No
12763 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
12764 (maintainer-clean realclean distclean): Use subdir_do.
12766 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
12767 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
12768 * acinclude.m4: Include acx_configure_dir.m4.
12769 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
12770 calls. Call AC_PROG_RANLIB. Configure gnulib using
12773 (GNULIB_STDINT_H): Adjust.
12774 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
12775 * gdbreplay.c: Include build-gnulib/config.h.
12776 * server.h: Likewise.
12777 * aclocal.m4: Regenerate.
12778 * config.in: Regenerate.
12779 * configure: Regenerate.
12781 2012-04-19 Pedro Alves <palves@redhat.com>
12783 * Makefile.in (LIBGNU, INCGNU): Adjust.
12784 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
12785 (all, install-only, uninstall, clean-info, all-lib, clean)
12786 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
12787 * configure.ac: Adjust AC_OUTPUT output.
12788 * aclocal.m4: Regenerate.
12789 * configure: Regenerate.
12791 2012-04-19 Pedro Alves <palves@redhat.com>
12793 * Makefile.in (generated_files): New.
12794 (server_h): Remove the explicit dependency on config.h, and depend
12795 on $generated_files.
12797 2012-04-19 Pedro Alves <palves@redhat.com>
12799 * Makefile.in (INCGNU): Add -Ignulib.
12801 2012-04-19 Pedro Alves <palves@redhat.com>
12803 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
12804 (INCGNU): ... this, and spell out -I here.
12805 (GNULIB_LIB): Rename to ...
12806 (LIBGNU): ... this.
12807 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
12809 2012-04-19 Pedro Alves <palves@redhat.com>
12811 * config.in: Regenerate.
12813 2012-04-19 Pedro Alves <palves@redhat.com>
12815 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
12816 * server.h (memmem): Remove declaration.
12817 * config.in: Regenerate.
12818 * configure: Regenerate.
12820 2012-04-19 Yao Qi <yao@codesourcery.com>
12822 * Makefile.in (SFILES): Add common/vec.c.
12826 2012-04-19 Yao Qi <yao@codesourcery.com>
12828 * remote-utils.c (prepare_resume_reply): Replace with macro
12829 target_core_of_thread.
12830 * server.c (handle_qxfer_threads_proper): Likewise.
12831 * target.h (traget_core_of_thread): New macro.
12833 2012-04-18 Pedro Alves <palves@redhat.com>
12835 * aclocal.m4: Regenerate.
12836 * configure: Regenerate.
12838 2012-04-16 Yao Qi <yao@codesourcery.com>
12840 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
12841 duplicated on address.
12843 2012-04-16 Yao Qi <yao@codesourcery.com>
12845 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
12846 (struct tracepoint_action_ops) <send>: New field.
12847 (m_tracepoint_action_send, r_tracepoint_action_send): New.
12848 (agent_expr_send, x_tracepoint_action_send): New.
12849 (l_tracepoint_action_send): New.
12850 (cmd_qtdp): Download and install tracepoint
12851 according to `use_agent'.
12852 (run_inferior_command): Add one more parameter `len'.
12854 (tracepoint_send_agent): New.
12855 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
12857 2012-04-16 Yao Qi <yao@codesourcery.com>
12859 * tracepoint.c (download_tracepoints): Moved to ...
12860 (cmd_qtstart): ... here.
12862 2012-04-14 Yao Qi <yao@codesourcery.com>
12864 * tracepoint.c: Include inttypes.h.
12865 (struct collect_memory_action): Use sized types.
12866 (struct tracepoint): Likewise.
12867 (cmd_qtdp, stop_tracing): Update print specifiers.
12868 (cmd_qtp, response_tracepoint): Likewise.
12869 (collect_data_at_tracepoint): Likewise.
12870 (collect_data_at_step): Likewise.
12872 2012-04-14 Yao Qi <yao@codesourcery.com>
12874 Import gnulib module inttypes.
12875 * aclocal.m4, config.in, configure: Regenerated.
12877 2012-04-14 Yao Qi <yao@codesourcery.com>
12879 * Makefile.in (maintainer-clean, realclean, distclean): Remove
12880 Makefile and config.status at last.
12882 2012-04-13 Yao Qi <yao@codesourcery.com>
12884 * tracepoint.c: Include stdint.h unconditionally.
12886 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
12888 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
12889 on BFD_HAVE_SYS_PROCFS_TYPE.
12890 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
12891 * configure: Regenerate.
12892 * config.in: Likewise.
12894 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
12896 * Makefile.in (clean): Also remove x32.c x32-linux.c
12897 x32-avx.c x32-avx-linux.c.
12898 (x32.o): New target.
12900 (x32-linux.o): Likewise.
12901 (x32-linux.c): Likewise.
12902 (x32-avx.o): Likewise.
12903 (x32-avx.c): Likewise.
12904 (x32-avx-linux.o): Likewise.
12905 (x32-avx-linux.c): Likewise.
12907 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
12908 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
12909 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
12910 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
12911 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
12912 i386/x32-avx-linux.xml.
12914 * linux-x86-low.c (init_registers_x32_linux): New prototype.
12915 (init_registers_x32_avx_linux): Likwise.
12916 (x86_linux_update_xmltarget): Call init_registers_x32_linux
12917 or init_registers_x32_avx_linux if linux_is_elf64 is false.
12919 2012-04-13 Pedro Alves <palves@redhat.com>
12921 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
12922 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
12923 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
12924 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
12927 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
12929 * linux-x86-low.c (compat_x32_clock_t): New.
12930 (compat_x32_siginfo_t): Likewise.
12931 (compat_x32_siginfo_from_siginfo): Likewise.
12932 (siginfo_from_compat_x32_siginfo): Likewise.
12933 (linux_is_elf64): Likewise.
12934 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
12935 and siginfo_from_compat_x32_siginfo for x32.
12936 (x86_arch_setup): Set linux_is_elf64.
12938 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
12941 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
12943 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
12944 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
12945 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
12946 compatible with process.
12948 2012-04-12 Yao Qi <yao@codesourcery.com>
12950 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
12951 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
12952 (install-only, install-info, clean): Handle sub dir gnulib.
12953 (all-lib, am--refresh): New targets.
12954 (memmem.o): Remove target.
12955 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
12956 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
12957 (AC_REPLACE_FUNCS): Remove memmem.
12958 Invoke gl_INIT and AM_INIT_AUTOMAKE.
12959 (AC_OUTPUT): Generate Makefile in gnulib/.
12960 * aclocal.m4, config.in, configure: Regenerated.
12962 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
12964 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
12966 2012-04-05 Pedro Alves <palves@redhat.com>
12968 -Werror=strict-aliasing
12970 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
12973 2012-04-04 Pedro Alves <palves@redhat.com>
12975 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
12976 (sparc_store_gregset_from_stack, sparc_store_gregset)
12977 (sparc_breakpoint_at): Fix formatting.
12979 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
12981 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
12983 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
12984 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
12985 * config.in: Regenerate.
12986 * configure: Likewise.
12988 2012-03-29 Pedro Alves <palves@redhat.com>
12990 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
12991 Correct ptrace arguments.
12993 2012-03-28 Pedro Alves <palves@redhat.com>
12995 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
12996 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
12997 (IA64_FR1_REGNUM): New defines.
12998 (ia64_fetch_register): New.
12999 (the_low_target): Install it.
13000 * linux-low.h (struct linux_target_ops) <fetch_register>: New
13002 * linux-low.c (linux_fetch_registers): Try the
13003 the_low_target.fetch_register hook first.
13005 * linux-arm-low.c (the_low_target): Adjust.
13006 * linux-bfin-low.c (the_low_target): Adjust.
13007 * linux-cris-low.c (the_low_target): Adjust.
13008 * linux-crisv32-low.c (the_low_target): Adjust.
13009 * linux-m32r-low.c (the_low_target): Adjust.
13010 * linux-m68k-low.c (the_low_target): Adjust.
13011 * linux-mips-low.c (the_low_target): Adjust.
13012 * linux-ppc-low.c (the_low_target): Adjust.
13013 * linux-s390-low.c (the_low_target): Adjust.
13014 * linux-sh-low.c (the_low_target): Adjust.
13015 * linux-sparc-low.c (the_low_target): Adjust.
13016 * linux-tic6x-low.c (the_low_target): Adjust.
13017 * linux-x86-low.c (the_low_target): Adjust.
13018 * linux-xtensa-low.c (the_low_target): Adjust.
13020 2012-03-26 Pedro Alves <palves@redhat.com>
13022 * server.c (handle_qxfer_libraries): Don't bail early if
13023 the_target->qxfer_libraries_svr4 is not NULL.
13025 2012-03-26 Pedro Alves <palves@redhat.com>
13027 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
13029 2012-03-23 Pedro Alves <palves@redhat.com>
13031 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
13032 "library-list-svr4" element's start tag when the the DSO list is
13035 2012-03-23 Pedro Alves <palves@redhat.com>
13037 * linux-low.c (read_one_ptr): Read the inferior's pointer through
13038 a variable whose type size is the same as the inferior's pointer
13041 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
13043 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
13045 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
13046 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
13047 * linux-low.h: Include <signal.h>.
13048 (struct siginfo): Remove forward declaration.
13049 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
13052 2012-03-21 Mike Frysinger <vapier@gentoo.org>
13054 * .gitignore: Ignore more files.
13056 2012-03-19 Pedro Alves <palves@redhat.com>
13057 Jan Kratochvil <jan.kratochvil@redhat.com>
13059 * server.c (cont_thread, general_thread): Add describing comments.
13060 (start_inferior): Clear `cont_thread'.
13061 (handle_v_cont): Don't set `cont_thread' if resuming all threads
13064 2012-03-15 Yao Qi <yao@codesourcery.com>
13066 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
13068 (cmd_qtdp): ... here.
13070 2012-03-15 Yao Qi <yao@codesourcery.com>
13072 * tracepoint.c (struct tracepoint_action_ops): New.
13073 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
13074 (m_tracepoint_action_download): New.
13075 (r_tracepoint_action_download): New.
13076 (x_tracepoint_action_download): New.
13077 (l_tracepoint_action_download): New.
13078 (add_tracepoint_action): Install `action->ops' according type.
13079 (download_tracepoint_1): Move code `download' function pointer
13080 of various tracepoint_action_ops.
13082 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
13084 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
13085 linux_ptrace_attach_warnings.
13087 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
13089 * Makefile.in (linux-ptrace.o): New.
13090 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
13091 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
13092 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
13093 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
13094 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
13096 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
13098 2012-03-08 Yao Qi <yao@codesourcery.com>
13099 Pedro Alves <palves@redhat.com>
13101 Fix PR server/13392.
13102 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
13103 offset of JMP insn.
13104 * tracepoint.c (remove_tracepoint): New.
13105 (cmd_qtdp): Call remove_tracepoint when failed to install.
13107 2012-03-07 Pedro Alves <palves@redhat.com>
13109 * linux-low.c (get_detach_signal): New.
13110 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
13111 Pass on pending signals to PTRACE_DETACH. Check the result of the
13113 * server.c (program_signals, program_signals_p): New.
13114 (handle_general_set): Handle QProgramSignals.
13115 * server.h (program_signals, program_signals_p): Declare.
13117 2012-03-05 Pedro Alves <palves@redhat.com>
13118 Jan Kratochvil <jan.kratochvil@redhat.com>
13120 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
13123 2012-03-03 Yao Qi <yao@codesourcery.com>
13125 * tracepoint.c (tracepoint_look_up_symbols): Update call to
13126 agent_look_up_symbols.
13128 2012-03-03 Yao Qi <yao@codesourcery.com>
13130 * Makefile.in (linux-low.o): Keep dependence on agent.h.
13131 (linux-x86-low.o): Likewise.
13132 * server.h: Remove in_process_agent_loaded.
13133 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
13137 2012-03-03 Yao Qi <yao@codesourcery.com>
13139 * tracepoint.c (gdb_agent_capability): New global.
13140 (in_process_agent_loaded_ust): Renamed to
13141 `in_process_agent_supports_ust'.
13143 (in_process_agent_supports_ust): Call agent_capability_check.
13144 (clear_installed_tracepoints): Assert that agent supports
13147 2012-03-03 Yao Qi <yao@codesourcery.com>
13149 * linux-low.c (linux_supports_agent): New.
13150 (linux_target_ops): Initialize field `supports_agent' with
13151 linux_supports_agent.
13152 * target.h (struct target_ops) <supports_agent>: New.
13153 (target_supports_agent): New macro.
13154 * server.c (handle_general_set): Handle packet 'QAgent'.
13155 (handle_query): Send `QAgent+'.
13156 * Makefile.in (server.o): Depends on agent.h.
13158 2012-03-03 Yao Qi <yao@codesourcery.com>
13160 * Makefile.in (OBS): Add agent.o.
13161 Add new rule for agent.o.
13162 Track dependence of tracepoint.c on agent.h.
13163 * tracepoint.c (run_inferior_command_1):
13164 (run_inferior_command): Call agent_run_command.
13165 (gdb_ust_connect_sync_socket): Deleted. Move it to
13167 (resume_thread, stop_thread): Likewise.
13168 (gdb_ust_socket_init): Renamed to ...
13169 (gdb_agent_socket_init): ... New.
13170 (gdb_ust_thread): Renamed to ...
13171 (gdb_agent_helper_thread): ... New.
13172 (gdb_ust_init): Move some code to ...
13173 (gdb_agent_init): ... here. New.
13174 [HAVE_UST]: Call gdb_ust_init.
13175 (initialize_tracepoint_ftlib): Call gdb_agent_init.
13176 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
13177 * config.in, configure: Regenerated.
13179 2012-03-02 Pedro Alves <palves@redhat.com>
13181 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
13182 * linux-low.c (struct simple_pid_list): New.
13183 (stopped_pids): New a struct simple_pid_list pointer.
13184 (add_to_pid_list, pull_pid_from_list): New.
13185 (handle_extended_wait): Don't assume the first signal new children
13186 report is SIGSTOP. Adjust call to pull_pid_from_list.
13187 (linux_wait_for_lwp): Adjust.
13189 2012-03-02 Yao Qi <yao@codesourcery.com>
13191 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
13194 2012-03-02 Yao Qi <yao@codesourcery.com>
13196 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
13197 `stop_pc' and `tpoint'. Update caller.
13199 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
13201 * linux-low.h (linux_target_ops): Add regset_bitmap member.
13202 * linux-low.c (use_linux_regsets): New macro.
13203 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
13204 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
13205 (linux_register_in_regsets): New function.
13206 (usr_fetch_inferior_registers): Skip registers covered by
13208 (usr_store_inferior_registers): Likewise.
13209 (usr_fetch_inferior_registers): New macro.
13210 (usr_store_inferior_registers): Likewise.
13211 (linux_fetch_registers): Handle mixed regset/non-regset targets.
13212 (linux_store_registers): Likewise.
13213 * linux-mips-low.c (init_registers_mips_dsp_linux): New
13215 (init_registers_mips64_dsp_linux): Likewise.
13216 (init_registers_mips_linux): New macro.
13217 (init_registers_mips_dsp_linux): Likewise.
13218 (mips_dsp_num_regs): Likewise.
13219 (DSP_BASE, DSP_CONTROL): New fallback macros.
13220 (mips_base_regs): New macro.
13221 (mips_regmap): Use it. Fix the size.
13222 (mips_dsp_regmap): New variable.
13223 (mips_dsp_regset_bitmap): Likewise.
13224 (mips_arch_setup): New function.
13225 (mips_cannot_fetch_register): Use the_low_target.regmap rather
13227 (mips_cannot_store_register): Likewise.
13228 (the_low_target): Update .arch_setup, .num_regs and .regmap
13229 initializers. Add .regset_bitmap initializer.
13230 * linux-arm-low.c (the_low_target): Add .regset_bitmap
13232 * linux-bfin-low.c (the_low_target): Likewise.
13233 * linux-cris-low.c (the_low_target): Likewise.
13234 * linux-crisv32-low.c (the_low_target): Likewise.
13235 * linux-ia64-low.c (the_low_target): Likewise.
13236 * linux-m32r-low.c (the_low_target): Likewise.
13237 * linux-m68k-low.c (the_low_target): Likewise.
13238 * linux-ppc-low.c (the_low_target): Likewise.
13239 * linux-s390-low.c (the_low_target): Likewise.
13240 * linux-sh-low.c (the_low_target): Likewise.
13241 * linux-sparc-low.c (the_low_target): Likewise.
13242 * linux-tic6x-low.c (the_low_target): Likewise.
13243 * linux-x86-low.c (the_low_target): Likewise.
13244 * linux-xtensa-low.c (the_low_target): Likewise.
13245 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
13246 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
13247 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
13249 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
13250 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
13252 2012-02-29 Yao Qi <yao@codesourcery.com>
13253 Pedro Alves <palves@redhat.com>
13255 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
13256 `step_over_finished' is true.
13258 2012-02-27 Pedro Alves <palves@redhat.com>
13260 * linux-low.c (pid_is_stopped): Delete, moved to common/.
13261 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
13263 2012-02-27 Pedro Alves <palves@redhat.com>
13266 * linux-low.c (pid_is_stopped): New.
13267 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
13269 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
13271 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
13274 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
13276 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
13278 2012-02-24 Luis Machado <lgustavo@codesourcery>
13280 * server.c (handle_query): Advertise support for target-side
13281 breakpoint condition evaluation.
13282 (process_point_options): New function.
13283 (process_serial_event): When inserting a breakpoint, check for
13284 a target-side condition that should be evaluated.
13286 * mem-break.c: Include regcache.h and ax.h.
13287 (point_cond_list_t): New data structure.
13288 (breakpoint) <cond_list>: New field.
13289 (find_gdb_breakpoint_at): Make non-static.
13290 (delete_gdb_breakpoint_at): Clear any target-side
13292 (clear_gdb_breakpoint_conditions): New function.
13293 (add_condition_to_breakpoint): Likewise.
13294 (add_breakpoint_condition): Likewise.
13295 (gdb_condition_true_at_breakpoint): Likewise.
13296 (gdb_breakpoint_here): Return result directly instead
13297 of going through a local variable.
13299 * mem-break.h (find_gdb_breakpoint_at): New prototype.
13300 (clear_gdb_breakpoint_conditions): Likewise.
13301 (add_breakpoint_condition): Likewise.
13302 (gdb_condition_true_at_breakpoint): Likewise.
13304 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
13305 (need_step_over_p): Take target-side breakpoint condition into
13308 2012-02-24 Luis Machado <lgustavo@codesourcery>
13310 * server.h: Include tracepoint.h.
13311 (agent_mem_read, agent_get_trace_state_variable_value,
13312 agent_set_trace_state_variable_value,
13313 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
13314 get_set_tsv_func_addr): New prototypes.
13316 * ax.h: New include file.
13317 * ax.c: New source file.
13319 * tracepoint.c: Include ax.h.
13320 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
13321 agent_expr, eval_result_type): Move to ax.h.
13322 (parse_agent_expr): Rename to ...
13323 (gdb_parse_agent_expr): ... this, make it non-static and move
13325 (unparse_agent_expr) Rename to ...
13326 (gdb_unparse_agent_expr): ... this, make it non-static and move
13328 (eval_agent_expr): Rename to ...
13329 (eval_tracepoint_agent_expr): ... this.
13330 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
13331 forward declarations.
13332 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
13333 (agent_get_trace_state_variable_value): New function.
13334 (agent_set_trace_state_variable_value): New function.
13335 (cmd_qtdp): Call gdb_parse_agent_expr (...).
13336 (response_tracepoint): Call gdb_unparse_agent_expr (...).
13337 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
13338 (condition_true_at_tracepoint): Likewise.
13339 (parse_agent_expr): Rename to ...
13340 (gdb_parse_agent_expr): ... this and move to ax.c.
13341 (unparse_agent_expr): Rename to ...
13342 (gdb_unparse_agent_expr): ... this and move to ax.c.
13343 (gdb_agent_op_name): Move to ax.c.
13344 (eval_agent_expr): Rename to ...
13345 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
13347 (eval_tracepoint_agent_expr): New function.
13348 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
13350 (current_insn_ptr, emit_error, struct bytecode_address): Move to
13352 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
13353 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
13354 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
13355 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
13356 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
13357 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
13358 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
13359 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
13360 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
13361 (compile_bytecodes): Remove forward declaration.
13362 (is_goto_target): Move to ax.c.
13363 (compile_bytecodes): Move to ax.c and call
13364 agent_get_trace_state_variable_value (...) and
13365 agent_set_trace_state_variable_value (...).
13367 * Makefile.in: Update ax.c and IPA dependencies.
13369 2012-02-24 Pedro Alves <palves@redhat.com>
13371 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
13372 (cmd_bigqtbuffer_circular): ... this. Only handle
13373 'QTBuffer:circular:'.
13374 (handle_tracepoint_general_set): Adjust.
13376 2012-02-16 Yao Qi <yao@codesourcery.com>
13378 * inferiors.c: Move code to ...
13379 * dll.c: .... here. New.
13380 * server.h: Declare clear_dlls.
13381 * Makefile.in (SFILES): Add dll.c.
13385 2012-02-11 Yao Qi <yao@codesourcery.com>
13387 * server.c: (handle_monitor_command): Add a new parameter
13389 (handle_query): Update caller.
13391 2012-02-09 Joel Brobecker <brobecker@adacore.com>
13393 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
13394 * configure, config.in: Regenerate.
13395 * hostio.c: Provide an alternate implementation if HAVE_READLINK
13398 2012-02-02 Pedro Alves <palves@redhat.com>
13400 Try SIGKILL first, then PTRACE_KILL.
13401 * linux-low.c (linux_kill_one_lwp): New.
13402 (linux_kill_one_lwp): Rename to ...
13403 (kill_one_lwp_callback): ... this. Use the new
13404 linux_kill_one_lwp.
13406 2012-02-02 Pedro Alves <palves@redhat.com>
13408 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
13411 2012-01-27 Pedro Alves <palves@redhat.com>
13413 * linux-low.c (linux_child_pid_to_exec_file): Delete.
13414 (elf_64_file_p): Make static.
13415 (linux_pid_exe_is_elf_64_file): New.
13416 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
13417 Delete declarations.
13418 (linux_pid_exe_is_elf_64_file): Declare.
13419 * linux-x86-low.c (x86_arch_setup): Use
13420 linux_pid_exe_is_elf_64_file.
13422 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
13424 * linux-low.c (linux_wait_for_event_1): Rename to ...
13425 (linux_wait_for_event): ... here and merge it with former
13426 linux_wait_for_event - new variable wait_ptid, use it.
13427 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
13429 2012-01-23 Pedro Alves <palves@redhat.com>
13431 * server.c (main): Avoid yet another case of infinite loop while
13432 detaching/killing after a longjmp.
13434 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13437 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
13439 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
13441 * hostio.c (handle_readlink): New function.
13442 (handle_vFile): Call it to handle "vFile:readlink" packets.
13444 2012-01-20 Pedro Alves <palves@redhat.com>
13445 Ulrich Weigand <ulrich.weigand@linaro.org>
13447 * server.c (handle_v_requests): Only support vAttach and vRun to
13448 start multiple processes when in extended protocol mode.
13450 2012-01-17 Pedro Alves <palves@redhat.com>
13452 * tracepoint.c (initialize_tracepoint): Use mmap instead of
13453 memalign plus mprotect to allocate the scratch buffer.
13455 2012-01-13 Pedro Alves <palves@redhat.com>
13457 * server.c (attach_inferior): Clear `cont_thread'.
13459 2012-01-13 Pedro Alves <palves@redhat.com>
13461 * server.c (main): Avoid infinite loop while detaching/killing
13464 2012-01-09 Doug Evans <dje@google.com>
13466 * server.c (start_inferior): Set last_ptid in --wrapper case.
13468 2012-01-06 Yao Qi <yao@codesourcery.com>
13470 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
13472 [IN_PROCESS_AGENT] (debug_agent): New global variable.
13474 2012-01-04 Yao Qi <yao@codesourcery.com>
13476 * tracepoint.c (cmd_qtdp): Print debug message
13477 for static tracepoint.
13479 2012-01-04 Yao Qi <yao@codesourcery.com>
13481 * tracepoint.c (trace_vdebug): Differentiate debug message
13482 between gdbserver and IPA.
13484 2012-01-03 Yao Qi <yao@codesourcery.com>
13486 * tracepoint.c (tracepoint_was_hit): Don't collect for
13489 2012-01-02 Joel Brobecker <brobecker@adacore.com>
13491 * terminal.h: Reformat copyright header.
13493 2012-01-02 Joel Brobecker <brobecker@adacore.com>
13495 * server.c (gdbserver_version): Update copyright year.
13496 * gdbreplay.c (gdbreplay_version): Likewise.
13498 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
13500 * linux-low.c (linux_create_inferior): Put empty if clause for write.
13503 2011-12-18 Hui Zhu <teawater@gmail.com>
13504 * linux-low.c (linux_create_inferior): Save return value to ret.
13506 2011-12-18 Hui Zhu <teawater@gmail.com>
13508 * linux-low.c (linux_create_inferior): Save return value to ret.
13510 2011-12-16 Doug Evans <dje@google.com>
13512 * linux-low.c (linux_create_inferior): If stdio connection,
13513 redirect stdin from /dev/null, stdout to stderr.
13514 * remote-utils.c (remote_is_stdio): New static global.
13515 (remote_connection_is_stdio): New function.
13516 (remote_prepare): Handle stdio connection.
13517 (remote_open): Ditto.
13518 (remote_close): Don't close stdin for stdio connections.
13519 (read_prim,write_prim): New functions. Replace all calls to
13520 read/write to these.
13521 * server.c (main): Watch for "-" argument. Move call to
13522 remote_prepare before start_inferior.
13523 * server.h (STDIO_CONNECTION_NAME): New macro.
13524 (remote_connection_is_stdio): Declare.
13526 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
13527 in debugging output.
13529 2011-12-15 Yao Qi <yao@codesourcery.com>
13531 * tracepoint.c: Include sys/syscall.h.
13532 (gdb_ust_thread): Remove preprocessor conditional.
13534 2011-12-14 Pedro Alves <pedro@codesourcery.com>
13536 * linux-low.c (linux_detach_one_lwp): Call
13537 the_low_target.prepare_to_resume before detaching.
13539 2011-12-14 Yao Qi <yao@codesourcery.com>
13541 * tracepoint.c (gdb_ust_thread): Don't ignore return value
13544 2011-12-14 Yao Qi <yao@codesourcery.com>
13546 * i386-low.c (i386_low_stopped_data_address): Initialize local
13547 variable `control'.
13549 2011-12-13 Pedro Alves <pedro@codesourcery.com>
13553 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
13554 DR_CONTROL unless necessary. Extend comments.
13555 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
13556 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
13558 2011-12-13 Yao Qi <yao@codesourcery.com>
13560 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
13562 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
13564 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
13566 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
13567 Print new debug message for such case.
13569 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
13571 Fix overlapping memcpy.
13572 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
13573 the read_inferior_memory transfer.
13574 (delete_fast_tracepoint_jump): New variable buf. Use it for the
13575 write_inferior_memory transfer.
13576 (set_fast_tracepoint_jump): New variable buf. Use it for the
13577 read_inferior_memory and write_inferior_memory transfers.
13578 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
13579 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
13580 Use it for the write_inferior_memory transfer.
13581 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
13584 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
13586 * linux-low.c (fetch_register, store_register): Make code
13587 consistent, fix formatting.
13589 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
13591 * linux-low.c (usr_store_inferior_registers): Factor out code
13592 to handle individual registers into...
13593 (store_register): ... this new function.
13595 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
13597 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
13598 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
13599 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
13600 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
13601 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
13602 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
13603 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
13604 (srv_xmlfiles): Add new XML files.
13606 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
13608 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
13609 (init_registers_s390_linux32v1): Add prototype.
13610 (init_registers_s390_linux32v2): Likewise.
13611 (init_registers_s390_linux64v1): Likewise.
13612 (init_registers_s390_linux64v2): Likewise.
13613 (init_registers_s390x_linux64v1): Likewise.
13614 (init_registers_s390x_linux64v2): Likewise.
13615 (s390_num_regs): Increment to 52.
13616 (s390_regmap): Add orig_r2 register.
13617 (s390_num_regs_3264): Increment to 68.
13618 (s390_regmap_3264): Add orig_r2 register.
13619 (s390_collect_ptrace_register): Handle orig_r2 register.
13620 (s390_supply_ptrace_register): Likewise.
13621 (s390_fill_last_break): New function.
13622 (s390_store_last_break): Likewise.
13623 (s390_fill_system_call): New function.
13624 (s390_store_system_call): Likewise.
13625 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
13627 (s390_check_regset): New function.
13628 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
13629 NT_S390_SYSTEM_CALL regsets and use appropriate description.
13630 Update target_regsets for available register sets.
13632 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
13633 Jan Kratochvil <jan.kratochvil@redhat.com>
13635 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
13636 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
13638 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
13639 * linux-low.h (struct process_info_private): New member r_debug.
13640 * server.c (handle_qxfer_libraries): Call
13641 the_target->qxfer_libraries_svr4.
13642 (handle_qxfer_libraries_svr4): New function.
13643 (qxfer_packets): New entry "libraries-svr4".
13644 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
13645 * target.h (struct target_ops): New member qxfer_libraries_svr4.
13646 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
13647 PACKET_qXfer_libraries_svr4.
13649 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
13651 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
13652 PSW address/mask between 8-byte and 16-byte formats.
13653 (s390_supply_ptrace_register): Likewise.
13654 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
13655 basic addressing mode bit.
13657 2011-11-24 Stan Shebs <stan@codesourcery.com>
13659 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
13661 2011-11-17 Stan Shebs <stan@codesourcery.com>
13663 * tracepoint.c (struct tracepoint): New field traceframe_usage.
13664 (tracing_start_time): New global.
13665 (tracing_stop_time): New global.
13666 (tracing_user_name): New global.
13667 (tracing_notes): New global.
13668 (tracing_stop_note): New global.
13669 (cmd_qtstart): Set traceframe_usage, start_time.
13670 (stop_tracing): Set stop_time.
13671 (cmd_qtstatus): Report additional status.
13672 (cmd_qtp): New function.
13673 (handle_tracepoint_query): Call it.
13674 (cmd_qtnotes): New function.
13675 (handle_tracepoint_general_set): Call it.
13676 (get_timestamp): Rename from tsv_get_timestamp.
13678 2011-11-14 Stan Shebs <stan@codesourcery.com>
13679 Kwok Cheung Yeung <kcy@codesourcery.com>
13681 * linux-x86-low.c (small_jump_insn): New.
13682 (i386_install_fast_tracepoint_jump_pad): Add arguments for
13683 trampoline and error message, build a trampoline and issue a small
13684 jump instruction to it.
13685 (x86_install_fast_tracepoint_jump_pad): Add arguments for
13686 trampoline and error message.
13687 (x86_get_min_fast_tracepoint_insn_len): New.
13688 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
13689 * linux-low.h (struct linux_target_ops): Add arguments to
13690 install_fast_tracepoint_jump_pad operation, add new operation.
13691 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
13693 (linux_get_min_fast_tracepoint_insn_len): New function.
13694 (linux_target_op): Add new operation.
13695 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
13696 (gdb_trampoline_buffer_end): Ditto.
13697 (gdb_trampoline_buffer_error): Ditto.
13698 (struct ipa_sym_addresses): Add fields for new IPA variables.
13699 (symbol_list): Add entries for new IPA variables.
13700 (struct tracepoint): Add fields to hold the address range of the
13701 trampoline used by the tracepoint.
13702 (trampoline_buffer_head): New static variable.
13703 (trampoline_buffer_tail): Ditto.
13704 (claim_trampoline_space): New function.
13705 (have_fast_tracepoint_trampoline_buffer): New function.
13706 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
13708 (install_fast_tracepoint): Ditto, also add error buffer argument.
13709 (cmd_qtminftpilen): New function.
13710 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
13711 (fast_tracepoint_from_trampoline_address): New function.
13712 (fast_tracepoint_collecting): Handle trampoline as part of jump
13714 (set_trampoline_buffer_space): New function.
13715 (initialize_tracepoint): Initialize new IPA variables.
13716 * target.h (struct target_ops): Add arguments to
13717 install_fast_tracepoint_jump_pad operation, add new
13718 get_min_fast_tracepoint_insn_len operation.
13719 (target_get_min_fast_tracepoint_insn_len): New.
13720 (install_fast_tracepoint_jump_pad): Add arguments.
13721 * server.h (IPA_BUFSIZ): Define.
13722 * linux-i386-ipa.c: Include extra header files.
13723 (initialize_fast_tracepoint_trampoline_buffer): New function.
13724 (initialize_low_tracepoint): Call it.
13725 * server.h (set_trampoline_buffer_space): Declare.
13726 (claim_trampoline_space): Ditto.
13727 (have_fast_tracepoint_trampoline_buffer): Ditto.
13729 2011-11-14 Yao Qi <yao@codesourcery.com>
13731 * server.c (handle_query): Handle InstallInTrace for qSupported.
13732 * tracepoint.c (add_tracepoint): Sort list.
13733 (install_tracepoint, download_tracepoint): New.
13734 (cmd_qtdp): Call them to install and download tracepoints.
13735 (sort_tracepoints): Removed.
13736 (cmd_qtstart): Update.
13738 2011-11-14 Yao Qi <yao@codesourcery.com>
13740 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
13741 * mem-break.h: Declare.
13742 * tracepoint.c (cmd_qtstart): Move some code to ...
13743 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
13745 (download_tracepoints): Move some code to ...
13746 (download_tracepoint_1): ... here. New.
13748 2011-11-08 Yao Qi <yao@codesourcery.com>
13750 * remote-utils.c (relocate_instruction): A comment fix.
13752 2011-11-07 Joel Brobecker <brobecker@adacore.com>
13754 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
13755 (i386_dr_low_get_control, i386_dr_low_get_status): Use
13756 dr_status_mirror and dr_control_mirror from debug_reg_state.
13757 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
13758 (i386_initial_stuff): Remove use of deleted globals.
13759 (i386_get_thread_context, i386_set_thread_context,
13760 i386_thread_added): Use dr_status_mirror and dr_control_mirror
13761 from debug_reg_state.
13763 2011-11-05 Yao Qi <yao@codesourcery.com>
13765 * tracepoint.c (gdb_collect): Loop over tracepoints of same
13766 address as TPOINT's.
13768 2011-11-02 Stan Shebs <stan@codesourcery.com>
13770 * tracepoint.c (agent_mem_read_string): New function.
13771 (eval_agent_expr): Call it for tracenz.
13772 * server.c (handle_query): Report support for tracenz.
13774 2011-11-02 Yao Qi <yao@codesourcery.com>
13776 * tracepoint.c (cmd_qtstart): Remove unused local variables.
13778 2011-11-02 Yao Qi <yao@codesourcery.com>
13780 * target.h: Fix a typo in comment.
13782 2011-10-31 Pedro Alves <pedro@codesourcery.com>
13784 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
13785 clobber the breakpoints' shadows with fast tracepoint jumps.
13786 * mem-break.h (check_mem_write): Add `myaddr' parameter.
13787 * target.c (write_inferior_memory): Also pass MYADDR down to
13790 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
13792 * configure.ac: Check support for personality routine.
13793 * configure: Regenerate.
13794 * config.in: Likewise.
13795 * linux-low.c: Include <sys/personality.h>.
13796 Define ADDR_NO_RANDOMIZE if necessary.
13797 (linux_create_inferior): Disable address space randomization when
13798 forking inferior, if requested.
13799 (linux_supports_disable_randomization): New function.
13800 (linux_target_ops): Install it.
13801 * server.h (disable_randomization): Declare.
13802 * server.c (disable_randomization): New global variable.
13803 (handle_general_set): Handle QDisableRandomization.
13804 (handle_query): Likewise for qSupported.
13805 (main): Support --disable-randomization and --no-disable-randomization
13806 command line arguments.
13807 * target.h (struct target_ops): Add supports_disable_randomization.
13808 (target_supports_disable_randomization): New macro.
13810 2011-09-29 Mike Frysinger <vapier@gentoo.org>
13812 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
13814 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
13815 [!PT_GETDSBT] (target_loadmap): New definition.
13816 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
13817 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
13818 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
13819 and PT_GETDSBT to LINUX_LOADMAP.
13820 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
13821 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
13823 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
13825 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
13826 (arm_linux_hwbp_cap): New static variable.
13827 (arm_linux_get_hwbp_cap): Replace by ...
13828 (arm_linux_init_hwbp_cap): ... this new function.
13829 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
13830 (arm_linux_get_hw_watchpoint_count): Likewise.
13831 (arm_linux_get_hw_watchpoint_max_length): Likewise.
13832 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
13833 (arm_prepare_to_resume): Use perror_with_name instead of error.
13835 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
13837 * linux-arm-low.c: Include <signal.h>.
13838 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
13839 (struct arm_linux_hwbp_cap): New data type.
13840 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
13841 (struct arm_linux_hw_breakpoint): New data type.
13842 (MAX_BPTS, MAX_WPTS): Define.
13843 (struct arch_process_info, struct arch_lwp_info): New data types.
13844 (arm_linux_get_hwbp_cap): New function.
13845 (arm_linux_get_hw_breakpoint_count): Likewise.
13846 (arm_linux_get_hw_watchpoint_count): Likewise.
13847 (arm_linux_get_hw_watchpoint_max_length): Likewise.
13848 (arm_hwbp_control_initialize): Likewise.
13849 (arm_hwbp_control_is_enabled): Likewise.
13850 (arm_hwbp_control_is_initialized): Likewise.
13851 (arm_hwbp_control_disable): Likewise.
13852 (arm_linux_hw_breakpoint_equal): Likewise.
13853 (arm_linux_hw_point_initialize): Likewise.
13854 (struct update_registers_data): New data structure.
13855 (update_registers_callback: New function.
13856 (arm_insert_point): Likewise.
13857 (arm_remove_point): Likewise.
13858 (arm_stopped_by_watchpoint): Likewise.
13859 (arm_stopped_data_address): Likewise.
13860 (arm_new_process): Likewise.
13861 (arm_new_thread): Likewise.
13862 (arm_prepare_to_resume): Likewise.
13863 (the_low_target): Register arm_insert_point, arm_remove_point,
13864 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
13865 arm_new_thread, and arm_prepare_to_resume.
13867 2011-09-15 Stan Shebs <stan@codesourcery.com>
13869 * server.h (struct emit_ops): Add compare-goto fields.
13870 * tracepoint.c (gdb_agent_op_sizes): New table.
13871 (emit_eq_goto): New function.
13872 (emit_ne_goto): New function.
13873 (emit_lt_goto): New function.
13874 (emit_le_goto): New function.
13875 (emit_gt_goto): New function.
13876 (emit_ge_goto): New function.
13877 (is_goto_target): New function.
13878 (compile_bytecodes): Recognize special cases of compare-goto
13879 combinations and call specialized emitters for them.
13880 * linux-x86-low.c (amd64_emit_eq_goto): New function.
13881 (amd64_emit_ne_goto): New function.
13882 (amd64_emit_lt_goto): New function.
13883 (amd64_emit_le_goto): New function.
13884 (amd64_emit_gt_goto): New function.
13885 (amd64_emit_ge_goto): New function.
13886 (amd64_emit_ops): Add the new functions.
13887 (i386_emit_eq_goto): New function.
13888 (i386_emit_ne_goto): New function.
13889 (i386_emit_lt_goto): New function.
13890 (i386_emit_le_goto): New function.
13891 (i386_emit_gt_goto): New function.
13892 (i386_emit_ge_goto): New function.
13893 (i386_emit_ops): Add the new functions.
13895 2011-09-08 Stan Shebs <stan@codesourcery.com>
13897 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
13898 (i386_emit_epilogue): Restore %ebx.
13900 2011-08-31 Jie Zhang <jzhang918@gmail.com>
13902 * server.c (step_thread): Remove definition.
13903 (process_serial_event): Don't handle Hs.
13904 * server.h (step_thread): Remove declaration.
13905 * target.c (set_desired_inferior): Remove use of step_thread.
13907 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
13909 * linux-low.c: Include linux-procfs.h.
13910 (linux_attach_lwp_1): Update comments.
13911 (linux_attach): Scan for existing threads when attaching to a
13912 process that is the tgid.
13913 * Makefile.in: Update dependencies.
13915 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
13917 * configure.srv: Add linux-procfs.o dependencies.
13919 2011-08-14 Yao Qi <yao@codesourcery.com>
13921 * target.h (struct target_ops): Fix indent.
13922 * win32-low.c (win32_target_ops): Fix comment.
13924 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
13925 Yao Qi <yao@codesourcery.com>
13927 * Makefile.in (clean): Remove tic6x-*.c files.
13928 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
13929 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
13930 (tic6x-c64xp-linux.c): Likewise.
13931 * configure.srv: Add support for tic6x-*-uclinux.
13932 * linux-tic6x-low.c: New.
13933 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
13935 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
13936 Yao Qi <yao@codesourcery.com>
13938 * target.h (struct target_ops): Add read_loadmap.
13939 * linux-low.c (struct target_loadseg): New type.
13940 (struct target_loadmap): New type.
13941 (linux_read_loadmap): New function.
13942 (linux_target_ops): Add linux_read_loadmap.
13943 * server.c (handle_query): Support qXfer:fdpic:read packet.
13944 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
13947 2011-08-05 Eli Zaretskii <eliz@gnu.org>
13949 * win32-low.c: Include <stdint.h>.
13951 2011-07-22 Pedro Alves <pedro@codesourcery.com>
13953 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
13954 to the inferior here.
13955 (i386_remove_aligned_watchpoint): Ditto.
13956 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
13957 fit part of the watchpoint in the debug registers.
13958 (i386_update_inferior_debug_regs): New.
13959 (i386_low_insert_watchpoint): Work on a local mirror of the debug
13960 registers, and only update the inferior on success.
13961 (i386_low_remove_watchpoint): Ditto.
13963 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
13965 * linux-low.c (compare_ints, unique, list_threads, show_process,
13966 linux_core_of_thread): Delete.
13967 (linux_target_ops): Change linux_core_of_thread to
13968 linux_common_core_of_thread.
13969 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
13970 * utils.c (malloc_failure): Change type of argument.
13971 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
13972 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
13973 common/linux-osdata.c, common/ptid.c and common/buffer.c.
13974 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
13975 (IPA_OBJS): Add common-utils-ipa.o.
13976 (ptid_h, linux_osdata_h): New macros.
13977 (server_h): Add common/common-utils.h, common/xml-utils.h,
13978 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
13980 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
13981 ptid.o, buffer.o): New rules.
13982 (linux-low.o): Add common/linux-osdata.h as a dependency.
13983 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
13984 * configure.ac: Add AC_HEADER_DIRENT check.
13985 * config.in: Regenerate.
13986 * configure: Regenerate.
13987 * remote-utils.c (xml_escape_text): Delete.
13988 (buffer_grow, buffer_free, buffer_init, buffer_finish,
13989 buffer_xml_printf): Move to common/buffer.c.
13990 * server.c (main): Remove call to initialize_inferiors.
13991 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
13992 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
13993 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
13994 internal_error, gdb_assert, gdb_assert_fail): Delete.
13995 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
13996 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
13998 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
13999 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
14000 initialize_inferiors): Delete.
14002 2011-07-20 Pedro Alves <pedro@codesourcery.com>
14004 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
14007 2011-05-31 Pedro Alves <pedro@codesourcery.com>
14009 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
14011 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
14013 2011-05-26 Yao Qi <yao@codesourcery.com>
14015 * Makefile.in (thread-db.o): Track dependence to
14016 common/gdb_thread_db.h.
14017 * thread-db.c: include gdb_thread_db.h from right place.
14019 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
14021 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
14022 __FILE__ and __LINE__ to internal_error.
14024 2011-05-13 Doug Evans <dje@google.com>
14026 * thread-db.c (try_thread_db_load_from_sdir): New function.
14027 (try_thread_db_load_from_dir): New function.
14028 (thread_db_load_search): Handle $sdir, ignore $pdir.
14029 Remove trying of system directories if search of
14030 libthread-db-search-path fails, that is now done via $sdir.
14032 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
14034 * server.c (handle_query): Add EnableDisableTracepoints to the list
14035 of supported features.
14036 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
14038 (cmd_qtenable_disable): New.
14039 (cmd_qtstart): Install tracepoints even if disabled.
14040 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
14041 receiving a QTEnable or QTDisable packet.
14042 (gdb_collect): Skip data collection if fast tracepoint is disabled.
14043 (ust_marker_to_static_tracepoint): Do not ignore disabled static
14045 (gdb_probe): Skip data collection if static tracepoint is disabled.
14047 2011-05-10 Doug Evans <dje@google.com>
14049 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
14051 2011-05-04 Doug Evans <dje@google.com>
14053 * linux-low.c (linux_join): Skip process lookup.
14054 * spu-low.c (spu_join): Ditto.
14055 * server.c (join_inferiors_callback): Delete.
14056 (process_serial_event): For 'D' packet (detach) call join_inferior
14059 2011-05-04 Joseph Myers <joseph@codesourcery.com>
14061 * README: Don't mention xscale*-*-linux*.
14062 * configure.srv (xscale*-*-linux*): Don't handle target.
14064 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
14066 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
14068 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
14069 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
14070 (i386_emit_void_call_2): Likewise.
14072 2011-04-26 Yao Qi <yao@codesourcery.com>
14074 * linux-low.c: Move common macros to linux-ptrace.h.
14075 Include linux-ptrace.h.
14076 * Makefile.in (linux_ptrace_h): New.
14077 (linux-low.o): Depends on linux-ptrace.h.
14079 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
14081 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
14082 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
14083 (remote_prepare): New function with most of the TCP code from ...
14084 (remote_open): ... here. Detect PORT here unconditionally. Move also
14085 setting transport_is_reliable.
14086 * server.c (run_once): New variable.
14087 (gdbserver_usage): Document it.
14088 (main): Set run_once for `--once'. Call remote_prepare. Exit after
14089 the first run if RUN_ONCE.
14090 * server.h (run_once, remote_prepare): New declarations.
14092 2011-04-19 Tom Tromey <tromey@redhat.com>
14094 * win32-low.c (handle_load_dll): Remove duplicate "the".
14096 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
14098 Remove support for old Cygwin 1.5 versions.
14099 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
14100 function to avoid warning.
14101 (win32_add_one_solib): Use cygwin_conv_path function to avoid
14104 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
14106 * gdbserver/server.h (Macro _): Define it if not available.
14108 2011-03-14 Michael Snyder <msnyder@vmware.com>
14110 * hostio.c (handle_close): Remove unnecessary null test.
14112 2011-03-10 Joel Brobecker <brobecker@adacore.com>
14114 * Makefile.in (maintainer-clean realclean distclean): Remove
14115 "make ... subdir_do" command.
14117 2011-03-10 Michael Snyder <msnyder@vmware.com>
14119 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
14121 * server.c (handle_v_run): Free alloced buffer on early return.
14123 2011-03-09 Yao Qi <yao@codesourcery.com>
14126 2011-03-04 Yao Qi <yao@codesourcery.com>
14128 * Makefile.in: Remove GNU make feature --directory.
14130 2011-03-05 Yao Qi <yao@codesourcery.com>
14132 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
14133 (subdir_do): New make target. Copied from gdb/Makefile.
14134 (maintainer-clean, realclean, distclean, clean): Call corresponding
14135 make targets in common/Makefile.
14137 2011-02-11 Yao Qi <yao@codesourcery.com>
14139 * configure.ac: Call AC_PROG_RANLIB.
14140 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
14141 * configure: Regenerate.
14143 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14145 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
14147 2011-03-06 Yao Qi <yao@codesourcery.com>
14149 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
14151 2011-03-05 Yao Qi <yao@codesourcery.com>
14153 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
14154 (subdir_do): New make target. Copied from gdb/Makefile.
14155 (maintainer-clean, realclean, distclean, clean): Call corresponding
14156 make targets in common/Makefile.
14158 2011-03-04 Yao Qi <yao@codesourcery.com>
14160 * Makefile.in: Remove GNU make feature --directory.
14162 2011-03-04 Michael Snyder <msnyder@vmware.com>
14164 * server.c (queue_stop_reply): Call xmalloc not malloc.
14166 2011-03-02 Michael Snyder <msnyder@vmware.com>
14168 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
14170 2011-02-28 Michael Snyder <msnyder@vmware.com>
14172 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
14173 (cmd_qtframe): Ditto.
14174 (cmd_qtbuffer): Ditto.
14175 (cmd_bigqtbuffer): Ditto.
14177 * utils.c (decimal2str): Initialize 'width' to nine, then
14178 don't mess with it.
14180 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
14182 * hostio.c (require_data): Free *data, not data.
14184 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
14186 * hostio.c (require_data): Use free, not xfree.
14188 2011-02-27 Michael Snyder <msnyder@vmware.com>
14190 * server.c (handle_query): Discard unused value.
14192 * hostio.c (require_data): Free malloc memory before returning
14195 2011-02-26 Michael Snyder <msnyder@vmware.com>
14197 * linux-low.c (list_threads): Call closedir for dirent.
14199 2011-02-27 Michael Snyder <msnyder@vmware.com>
14201 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
14202 a case statement falls through.
14204 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
14206 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
14209 2011-02-26 Michael Snyder <msnyder@vmware.com>
14211 * utils.c (decimal2str): Eliminate dead code and dead param.
14212 (pulongest): Drop dead param from call to decimal2str.
14215 2011-02-24 Joel Brobecker <brobecker@adacore.com>
14217 Revert the following patch (not approved yet):
14218 2011-02-21 Hui Zhu <teawater@gmail.com>
14219 * tracepoint.c (tp_printf): New function.
14220 (eval_agent_expr): Handle gdb_agent_op_printf.
14222 2011-02-21 Hui Zhu <teawater@gmail.com>
14224 * tracepoint.c (tp_printf): New function.
14225 (eval_agent_expr): Handle gdb_agent_op_printf.
14227 2011-02-18 Tom Tromey <tromey@redhat.com>
14229 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
14230 (tracepoint.o): Likewise.
14231 * tracepoint.c (enum gdb_agent_op): Use ax.def.
14232 (gdb_agent_op_names): Likewise.
14234 2011-02-18 Tom Tromey <tromey@redhat.com>
14236 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
14237 gdb_agent_op_rot>: New constants.
14238 (gdb_agent_op_names): Add pick and roll.
14239 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
14242 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
14244 * aclocal.m4: Regenerated with aclocal-1.11.1.
14246 2011-02-14 Pedro Alves <pedro@codesourcery.com>
14248 * server.c (handle_qxfer_traceframe_info): New.
14249 (qxfer_packets): Register "traceframe-info".
14250 (handle_query): Report support for qXfer:traceframe-info:read+.
14251 * tracepoint.c (match_blocktype): New.
14252 (traceframe_find_block_type): Rename to ...
14253 (traceframe_walk_blocks): ... this. Add callback filter argument,
14255 (traceframe_find_block_type): New, reimplemented on top of
14256 traceframe_walk_blocks.
14257 (build_traceframe_info_xml): New.
14258 (traceframe_read_info): New.
14259 * server.h (traceframe_read_info): Declare.
14261 2011-02-11 Yao Qi <yao@codesourcery.com>
14263 * configure.ac: Call AC_PROG_RANLIB.
14264 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
14265 * configure: Regenerate.
14267 2011-02-07 Pedro Alves <pedro@codesourcery.com>
14269 * server.c (gdb_read_memory): Change return semantics to allow
14271 (handle_search_memory_1): Adjust.
14272 (process_serial_event) <'m' packet>: Handle partial transfers.
14273 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
14275 2011-01-28 Pedro Alves <pedro@codesourcery.com>
14277 * regcache.c (init_register_cache): Initialize
14278 regcache->register_status.
14279 (free_register_cache): Release regcache->register_status.
14280 (regcache_cpy): Copy register_status.
14281 (registers_to_string): Print 'x's for unavailable registers.
14282 (supply_register): Mark the register's status valid or
14283 unavailable, depending on whether a buffer was passed in or not.
14284 (supply_register_zeroed): New.
14285 (supply_regblock): Mark the registers' status valid or
14286 unavailable, depending on whether a buffer was passed in or not.
14287 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
14288 (struct regcache): New `register_status' field.
14289 (supply_register_zeroed): Declare.
14290 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
14291 supply_register_zeroed, rather than passing a NULL buffer to
14293 * tracepoint.c (fetch_traceframe_registers): Update comment.
14295 2011-01-28 Pedro Alves <pedro@codesourcery.com>
14297 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
14300 2011-01-25 Pedro Alves <pedro@codesourcery.com>
14302 * server.h (decode_xfer_write): Change prototype.
14303 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
14304 and don't extract the annex here.
14305 * server.c (decode_xfer_read): Remove `annex' parameter,
14306 and don't extract the annex here.
14307 (decode_xfer): New.
14308 (struct qxfer): New.
14309 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
14310 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
14311 (handle_qxfer_statictrace): New functions, abstracted out from
14312 handle_query, and made to use the struct qxfer interface.
14313 (handle_threads_qxfer_proper): Rename to ...
14314 (handle_qxfer_threads_proper): ... this.
14315 (handle_threads_qxfer): Rename to ...
14316 (handle_qxfer_threads): ... this. Adjust.
14317 (qxfer_packets): New array.
14318 (handle_qxfer): New function.
14319 (handle_query): Use handle_qxfer.
14321 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
14323 * gdbreplay.c: Shorten lines of >= 80 columns.
14324 * linux-low.c: Ditto.
14325 * linux-ppc-low.c: Ditto.
14326 * linux-s390-low.c: Ditto.
14327 * linux-sparc-low.c: Ditto.
14328 * linux-x86-low.c: Ditto.
14329 * linux-xtensa-low.c: Ditto.
14330 * mem-break.c: Ditto.
14331 * nto-low.c: Ditto.
14332 * regcache.h: Ditto.
14333 * remote-utils.c: Ditto.
14336 * thread-db.c: Ditto.
14337 * tracepoint.c: Ditto.
14339 * win32-low.h: Ditto.
14341 2011-01-05 Joel Brobecker <brobecker@adacore.com>
14343 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
14346 2011-01-01 Joel Brobecker <brobecker@adacore.com>
14348 * server.c (gdbserver_version): Update copyright year in version
14350 * gdbreplay.c (gdbreplay_version): Ditto.
14352 2010-12-29 Jie Zhang <jie.zhang@analog.com>
14354 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
14355 * linux-bfin-low.c: New file.
14356 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
14357 PT_DATA_ADDR for BFIN targets.
14358 * Makefile.in (SFILES): Add linux-bfin-low.c.
14359 (clean): Remove reg-bfin.c.
14360 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
14361 * README: Mention supported Blackfin targets.
14363 2010-12-23 Mike Frysinger <vapier@gentoo.org>
14365 * .gitignore: New file.
14367 2010-11-16 Mike Frysinger <vapier@gentoo.org>
14369 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
14371 2010-10-22 Jie Zhang <jie@codesourcery.com>
14373 * Makefile.in: Add FLAGS_TO_PASS variable.
14374 (install): Remove dependency of install-only and recursively
14375 invoke make for install-only.
14377 2010-10-04 Doug Evans <dje@google.com>
14379 * Makefile.in (uninstall): Use $(DESTDIR).
14381 2010-09-24 Pedro Alves <pedro@codesourcery.com>
14385 * linux-x86-low.c (compat_siginfo_from_siginfo)
14386 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
14387 si_code is < 0. Check for si_code == SI_TIMER before checking for
14390 2010-09-13 Joel Brobecker <brobecker@adacore.com>
14392 * lynx-i386-low.c: New file.
14393 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
14395 2010-09-13 Joel Brobecker <brobecker@adacore.com>
14397 * lynx-low.c (ptrace_request_to_str): Remove handling for
14398 request values that have been removed in LynxOS 5.x.
14400 2010-09-13 Joel Brobecker <brobecker@adacore.com>
14402 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
14405 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
14407 * configure.ac: Add --enable-inprocess-agent option.
14408 * configure: Rebuilt.
14410 2010-09-06 Yao Qi <yao@codesourcery.com>
14412 * linux-low.c (linux_kill): Remove unused variable.
14413 (linux_stabilize_threads): Likewise.
14414 * server.c (start_inferior): Likewise.
14415 (queue_stop_reply_callback): Likewise.
14416 * tracepoint.c (do_action_at_tracepoint): Likewise.
14418 2010-09-06 Yao Qi <yao@codesourcery.com>
14420 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
14423 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
14425 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
14427 2010-09-06 Pedro Alves <pedro@codesourcery.com>
14429 * Makefile.in (install-only): Replace $IPA_DEPFILES with
14432 2010-09-01 Joel Brobecker <brobecker@adacore.com>
14434 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
14435 gdbserver/lynx-ppc-low.c: New files.
14436 * Makefile.in (lynx_low_h): New variable.
14437 (lynx-low.o, lynx-ppc-low.o): New rules.
14438 * configure.ac: On LynxOS, link with -lnetinet.
14439 * configure.srv: Add handling of powerpc-*-lynxos* targets.
14440 * configure: regenerate.
14442 2010-09-01 Joel Brobecker <brobecker@adacore.com>
14444 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
14445 * configure.ac: Add check for vasprintf and vsnprintf.
14446 * configure, config.in: Regenerate.
14447 * server.h (vasprintf, vsnprintf): Add conditional declarations.
14449 2010-09-01 Joel Brobecker <brobecker@adacore.com>
14451 * gdbreplay.c: Move include of alloca.h up, next to include of
14453 * server.h: Add include of malloc.h.
14454 * mem-break.c: Remove include of malloc.h.
14455 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
14457 2010-09-01 Joel Brobecker <brobecker@adacore.com>
14459 * Makefile.in (memmem.o): Build with -Wno-error.
14461 2010-09-01 Joel Brobecker <brobecker@adacore.com>
14463 * utils.c (xsnprintf): Make non-static.
14464 * server.h: Add xsnprintf declaration.
14465 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
14466 replace calls to snprintf by calls to xsnprintf throughout.
14468 2010-09-01 Joel Brobecker <brobecker@adacore.com>
14470 * configure.ac: Add configure check for alloca.
14471 * configure, config.in: Regenerate.
14472 * server.h: Include alloca.h if it exists.
14473 * gdbreplay.c: Include alloca.h if it exists.
14475 2010-08-28 Pedro Alves <pedro@codesourcery.com>
14477 * linux-low.c (__SIGRTMIN): Define if not already defined.
14478 (linux_create_inferior): Check for __ANDROID__ rather than
14480 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
14481 are already deferred.
14482 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
14483 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
14484 stopped and already has a pending signal to report.
14485 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
14486 a pending signal to report or is moving out of a jump pad.
14487 (linux_init_signals): Check for __ANDROID__ rather than
14490 2010-08-28 Pedro Alves <pedro@codesourcery.com>
14492 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
14493 debug_threads check. Avoid a linear search when not doing debug
14496 2010-08-27 Pedro Alves <pedro@codesourcery.com>
14498 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
14499 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
14500 (struct file_handler) <fd>: Change type to gdb_fildes_t.
14501 (process_event): Change local fd's type to gdb_fildes_t.
14502 (create_file_handler): Adjust prototype.
14503 (delete_file_handler): Adjust prototype.
14504 (handle_file_event): Adjust prototype. Use pfildes.
14505 (create_file_event): Adjsut prototype.
14506 * remote-utils.c (remote_desc, listen_desc): Change type to
14508 * server.h: New gdb_fildes_t typedef.
14509 [USE_WIN32API]: Include winsock2.h.
14510 (delete_file_handler, add_file_handler): Adjust prototypes.
14511 (pfildes): Declare.
14512 * utils.c (pfildes): New.
14514 2010-08-27 Pedro Alves <pedro@codesourcery.com>
14516 * configure.ac (build_warnings): Add -Wno-char-subscripts.
14517 * configure: Regenerate.
14519 2010-08-27 Pedro Alves <pedro@codesourcery.com>
14521 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
14522 (linux_done_accessing_memory): ... this.
14523 (linux_target_ops): Adjust.
14524 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
14525 * nto-low.c (nto_target_ops): Adjust comment.
14526 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
14527 * spu-low.c (spu_target_ops): Adjust comment.
14528 * target.h (target_ops): Rename unprepare_to_access_memory field
14529 to done_accessing_memory.
14530 (unprepare_to_access_memory): Rename to ...
14531 (done_accessing_memory): ... this.
14533 2010-08-26 Pedro Alves <pedro@codesourcery.com>
14535 * linux-low.c (linux_prepare_to_access_memory): New.
14536 (linux_unprepare_to_access_memory): New.
14537 (linux_target_ops): Install them.
14538 * server.c (read_memory): Rename to ...
14539 (gdb_read_memory): ... this. Use
14540 prepare_to_access_memory/prepare_to_access_memory.
14541 (write_memory): Rename to ...
14542 (gdb_write_memory): ... this. Use
14543 prepare_to_access_memory/prepare_to_access_memory.
14544 (handle_search_memory_1): Adjust.
14545 (process_serial_event): Adjust.
14546 * target.h (struct target_ops): New fields
14547 prepare_to_access_memory and unprepare_to_access_memory.
14548 (prepare_to_access_memory, unprepare_to_access_memory): New.
14549 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
14550 prepare_to_access_memory/prepare_to_access_memory.
14551 * nto-low.c (nto_target_ops): Adjust.
14552 * spu-low.c (spu_target_ops): Adjust.
14553 * win32-low.c (win32_target_ops): Adjust.
14555 2010-08-26 Pedro Alves <pedro@codesourcery.com>
14557 * Makefile.in (WARN_CFLAGS): Get it from configure.
14558 (WERROR_CFLAGS): New.
14559 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
14560 * configure.ac: Introduce --enable-werror, which adds -Werror to
14561 the compiler command line. Enabled by default. Disable with
14562 --disable-werror. Add -Wdeclaration-after-statement
14563 Wpointer-arith and -Wformat-nonliteral to warning flags.
14564 * configure: Regenerate.
14566 2010-08-26 Pedro Alves <pedro@codesourcery.com>
14568 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
14570 2010-08-26 Pedro Alves <pedro@codesourcery.com>
14572 * gdbreplay.c (remote_error): New.
14574 (expect): Use gdbchar. Check for error reading from GDB.
14575 Clarify sync error output.
14576 (play): Check for errors writing to GDB.
14577 * linux-low.c (sigchld_handler): Really ignore `write' errors.
14578 * remote-utils.c (getpkt): Check for errors writing to the remote
14581 2010-08-25 Pedro Alves <pedro@codesourcery.com>
14583 * linux-low.c (linux_wait_1): Move non-debugging code out of
14584 `debug_threads' control.
14586 2010-08-25 Pedro Alves <pedro@codesourcery.com>
14588 * linux-low.c (linux_wait_1): Don't set last_status here.
14589 * server.c (push_event, queue_stop_reply_callback): Assert we're
14590 not pushing a TARGET_WAITKIND_IGNORE event.
14591 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
14592 (myresume, handle_target_event): Set the thread's last_resume_kind
14593 and last_status from the target returned status.
14595 2010-08-25 Pedro Alves <pedro@codesourcery.com>
14599 * linux-x86-low.c (update_debug_registers_callback): New.
14600 (i386_dr_low_set_addr): Use it.
14601 (i386_dr_low_get_addr): New.
14602 (i386_dr_low_set_control): Use update_debug_registers_callback.
14603 (i386_dr_low_get_control): New.
14604 (i386_dr_low_get_status): Adjust.
14605 * linux-low.c (linux_stop_lwp): New.
14606 * linux-low.h (linux_stop_lwp): Declare.
14608 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
14609 argument instead of a i386_debug_reg_state.
14610 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
14611 a i386_debug_reg_state.
14612 (i386_insert_aligned_watchpoint): Adjust.
14613 (i386_remove_aligned_watchpoint): Adjust.
14614 (i386_low_stopped_data_address): Read the debug registers from the
14615 inferior instead of from the mirrors.
14616 * i386-low.h (struct i386_debug_reg_state): Extend comment.
14617 (i386_dr_low_get_addr): Declare.
14618 (i386_dr_low_get_control): Declare.
14619 (i386_dr_low_get_status): Change prototype.
14621 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
14622 (i386_dr_low_get_addr): New.
14623 (i386_dr_low_get_control): New.
14624 (i386_dr_low_get_status): Adjust prototype. Return
14626 (i386_initial_stuff): Clear dr_status_mirror and
14628 (i386_get_thread_context): Adjust.
14629 (i386_set_thread_context): Adjust.
14630 (i386_thread_added): Adjust.
14632 2010-08-24 Pedro Alves <pedro@codesourcery.com>
14634 * linux-low.h (linux_thread_area): Delete declaration.
14636 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
14638 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
14639 after its termination.
14641 2010-08-09 Pedro Alves <pedro@codesourcery.com>
14643 * linux-low.c (gdb_wants_lwp_stopped): Delete.
14644 (gdb_wants_all_stopped): Delete.
14645 (linux_wait_1): Don't call them.
14646 * server.c (handle_v_cont): Tag all threads as want-stopped.
14647 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
14648 stopped as "client-wants-stopped".
14650 2010-07-31 Pedro Alves <pedro@codesourcery.com>
14652 * Makefile.in (signals_h): New.
14653 (server_h): Depend on it.
14654 (server.o): Don't depend on $(signals_def).
14655 (signals.o): Depend on $(signals_def).
14657 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
14659 * Makefile.in (signals_def): New.
14660 (server_h): Append include/gdb/signals.h and signals_def.
14661 (server.o): Append signals_def.
14663 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
14665 * server.c (handle_target_event): Use target_signal_to_host for
14666 resume_info.sig initialization.
14667 * target.h (struct thread_resume) <sig>: New comment.
14669 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
14671 * server.c (handle_query): strcpy() the returned string from paddress()
14672 instead of sprintf().
14673 * utils.c (paddress): Return phex_nz().
14675 2010-07-07 Joel Brobecker <brobecker@adacore.com>
14677 * server.c (handle_v_cont): Call mourn_inferior if process
14679 (myresume): Likewise.
14681 2010-07-01 Pedro Alves <pedro@codesourcery.com>
14683 Static tracepoints, and integration with UST.
14685 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
14686 * mem-break.c (uninsert_all_breakpoints)
14687 (reinsert_all_breakpoints): New.
14688 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
14689 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
14690 (gdb_agent_ust_loaded, helper_thread_id)
14691 (gdb_agent_helper_thread_id): New macros.
14692 (struct ipa_sym_addresses): Add addr_ust_loaded,
14693 addr_helper_thread_id, addr_cmd_buf.
14694 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
14695 (in_process_agent_loaded_ust): New.
14696 (write_e_ust_not_loaded): New.
14697 (maybe_write_ipa_ust_not_loaded): New.
14698 (struct collect_static_trace_data_action): New.
14699 (enum tracepoint_type) <static_tracepoint>: New.
14700 (struct tracepoint) <handle>: Mention static tracepoints.
14701 (struct static_tracepoint_ctx): New.
14702 (CMD_BUF_SIZE): New.
14703 (add_tracepoint_action): Handle static tracepoint actions.
14704 (unprobe_marker_at): New.
14705 (clear_installed_tracepoints): Handle static tracepoints.
14706 (cmd_qtdp): Handle static tracepoints.
14707 (probe_marker_at): New.
14708 (cmd_qtstart): Handle static tracepoints.
14709 (response_tracepoint): Handle static tracepoints.
14710 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
14711 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
14712 (get_context_regcache): Handle static tracepoints.
14713 (do_action_at_tracepoint): Handle static tracepoint actions.
14714 (traceframe_find_block_type): Handle static trace data blocks.
14715 (traceframe_read_sdata): New.
14716 (download_tracepoints): Download static tracepoint actions.
14717 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
14718 (GDB_PROBE_NAME): New.
14720 (GET_UST_SYM): New.
14723 (ust_marker_to_static_tracepoint): New.
14725 (collect_ust_data_at_tracepoint): New.
14726 (gdb_ust_probe): New.
14727 (UNIX_PATH_MAX, SOCK_DIR): New.
14728 (gdb_ust_connect_sync_socket): New.
14729 (resume_thread, stop_thread): New.
14730 (run_inferior_command): New.
14731 (init_named_socket): New.
14732 (gdb_ust_socket_init): New.
14733 (cstr_to_hexstr): New.
14735 (first_marker, next_marker): New.
14736 (response_ust_marker): New.
14737 (cmd_qtfstm, cmd_qtsstm): New.
14738 (unprobe_marker_at, probe_marker_at): New.
14739 (cmd_qtstmat, gdb_ust_thread): New.
14740 (gdb_ust_init): New.
14741 (initialize_tracepoint_ftlib): Call gdb_ust_init.
14742 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
14743 (ST_REGENTRY): New.
14744 (x86_64_st_collect_regmap): New.
14745 (X86_64_NUM_ST_COLLECT_GREGS): New.
14746 (AMD64_RIP_REGNUM): New.
14747 (supply_static_tracepoint_registers): New.
14748 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
14749 (ST_REGENTRY): New.
14750 (i386_st_collect_regmap): New.
14751 (i386_NUM_ST_COLLECT_GREGS): New.
14752 (supply_static_tracepoint_registers): New.
14753 * server.c (handle_query): Handle qXfer:statictrace:read.
14754 <qSupported>: Report support for StaticTracepoints, and
14755 qXfer:statictrace:read features.
14756 * server.h (traceframe_read_sdata)
14757 (supply_static_tracepoint_registers): Declare.
14758 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
14759 (unpack_varlen_hex): Include in IPA build.
14760 * Makefile.in (ustlibs, ustinc): New.
14761 (IPA_OBJS): Add remote-utils-ipa.o.
14762 ($(IPA_LIB)): Link -ldl and -lpthread.
14764 (IPAGENT_CFLAGS): Add UST_CFLAGS.
14765 * config.in, configure: Regenerate.
14767 2010-06-20 Ian Lance Taylor <iant@google.com>
14768 Pedro Alves <pedro@codesourcery.com>
14770 * linux-x86-low.c (always_true): Delete.
14771 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
14772 trying to fool the compiler with always_true.
14774 2010-06-20 Pedro Alves <pedro@codesourcery.com>
14776 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
14777 conditions in gdbserver.
14779 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
14781 * spu-low.c (spu_read_memory): Wrap around local store limit.
14782 (spu_write_memory): Likewise.
14784 2010-06-15 Pedro Alves <pedro@codesourcery.com>
14786 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
14787 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
14789 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
14791 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
14792 uses with LONGEST uses.
14794 2010-06-14 Stan Shebs <stan@codesourcery.com>
14795 Pedro Alves <pedro@codesourcery.com>
14799 * linux-x86-low.c: Include limits.h.
14801 (always_true): New.
14804 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
14805 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
14806 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
14807 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
14808 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
14809 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
14810 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
14811 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
14812 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
14813 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
14814 (amd64_emit_void_call_2): New.
14815 (amd64_emit_ops): New.
14816 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
14817 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
14818 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
14819 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
14820 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
14821 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
14822 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
14823 (i386_emit_call, i386_emit_reg, i386_emit_pop)
14824 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
14825 (i386_emit_stack_adjust, i386_emit_int_call_1)
14826 (i386_emit_void_call_2): New.
14827 (i386_emit_ops): New.
14828 (x86_emit_ops): New.
14829 (the_low_target): Install x86_emit_ops.
14830 * server.h (struct emit_ops): New.
14831 (get_raw_reg_func_addr): Declare.
14832 (current_insn_ptr, emit_error): Declare.
14833 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
14834 (set_trace_state_variable_value): New defines.
14835 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
14836 addr_get_trace_state_variable_value and
14837 addr_set_trace_state_variable_value.
14838 (symbol_list): New fields for get_raw_reg,
14839 get_trace_state_variable_value and set_trace_state_variable_value.
14840 (condfn): New typedef.
14841 (struct tracepoint): New field `compiled_cond'.
14842 (do_action_at_tracepoint): Clear compiled_cond.
14843 (get_trace_state_variable_value, set_trace_state_variable_value):
14845 (condition_true_at_tracepoint): If there's a compiled condition,
14847 (current_insn_ptr, emit_error): New globals.
14848 (struct bytecode_address): New.
14849 (get_raw_reg_func_addr): New.
14850 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
14851 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
14852 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
14853 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
14854 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
14855 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
14856 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
14857 (compile_tracepoint_condition, compile_bytecodes): New.
14858 * target.h (emit_ops): Forward declare.
14859 (struct target_ops): New field emit_ops.
14860 (target_emit_ops): New.
14861 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
14862 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
14863 * linux-low.c (linux_emit_ops): New.
14864 (linux_target_ops): Install it.
14865 * linux-low.h (struct linux_target_ops): New field emit_ops.
14867 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
14869 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
14870 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
14872 2010-06-01 Pedro Alves <pedro@codesourcery.com>
14873 Stan Shebs <stan@codesourcery.com>
14875 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
14876 (all): Depend on $(extra_libraries).
14877 (install-only): Install the IPA.
14878 (IPA_OBJS, IPA_LIB): New.
14879 (clean): Remove the IPA lib.
14880 (IPAGENT_CFLAGS): New.
14881 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
14882 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
14883 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
14884 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
14885 * configure.ac: Check for atomic builtins support in the compiler.
14886 (IPA_DEPFILES, extra_libraries): Define.
14887 * configure.srv (ipa_obj): Add description.
14888 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
14889 (i[34567]86-*-linux*): Set ipa_obj.
14890 (x86_64-*-linux*): Set ipa_obj.
14891 * linux-low.c (stabilizing_threads): New.
14892 (supports_fast_tracepoints): New.
14893 (linux_detach): Stabilize threads before detaching.
14894 (handle_tracepoints): Handle internal tracing breakpoints. Assert
14895 the lwp is either not stabilizing, or is moving out of a jump pad.
14896 (linux_fast_tracepoint_collecting): New.
14897 (maybe_move_out_of_jump_pad): New.
14898 (enqueue_one_deferred_signal): New.
14899 (dequeue_one_deferred_signal): New.
14900 (linux_wait_for_event_1): If moving out of a jump pad, defer
14901 pending signals to later.
14902 (linux_stabilize_threads): New.
14903 (linux_wait_1): Check if threads need moving out of jump pads, and
14905 (stuck_in_jump_pad_callback): New.
14906 (move_out_of_jump_pad_callback): New.
14907 (lwp_running): New.
14908 (linux_resume_one_lwp): Handle moving out of jump pads.
14909 (linux_set_resume_request): Dequeue deferred signals.
14910 (need_step_over_p): Also step over fast tracepoint jumps.
14911 (start_step_over): Also uninsert fast tracepoint jumps.
14912 (finish_step_over): Also reinsert fast tracepoint jumps.
14913 (linux_install_fast_tracepoint_jump): New.
14914 (linux_target_ops): Install linux_stabilize_threads and
14915 linux_install_fast_tracepoint_jump_pad.
14916 * linux-low.h (linux_target_ops) <get_thread_area,
14917 install_fast_tracepoint_jump_pad>: New fields.
14918 (struct lwp_info) <collecting_fast_tracepoint,
14919 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
14920 (linux_get_thread_area): Declare.
14921 * linux-x86-low.c (jump_insn): New.
14922 (x86_get_thread_area): New.
14923 (append_insns): New.
14924 (push_opcode): New.
14925 (amd64_install_fast_tracepoint_jump_pad): New.
14926 (i386_install_fast_tracepoint_jump_pad): New.
14927 (x86_install_fast_tracepoint_jump_pad): New.
14928 (the_low_target): Install x86_get_thread_area and
14929 x86_install_fast_tracepoint_jump_pad.
14930 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
14931 (struct fast_tracepoint_jump): New.
14932 (fast_tracepoint_jump_insn): New.
14933 (fast_tracepoint_jump_shadow): New.
14934 (find_fast_tracepoint_jump_at): New.
14935 (fast_tracepoint_jump_here): New.
14936 (delete_fast_tracepoint_jump): New.
14937 (set_fast_tracepoint_jump): New.
14938 (uninsert_fast_tracepoint_jumps_at): New.
14939 (reinsert_fast_tracepoint_jumps_at): New.
14940 (set_breakpoint_at): Use write_inferior_memory.
14941 (uninsert_raw_breakpoint): Use write_inferior_memory.
14942 (check_mem_read): Mask out fast tracepoint jumps.
14943 (check_mem_write): Mask out fast tracepoint jumps.
14944 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
14945 (set_fast_tracepoint_jump): Declare.
14946 (delete_fast_tracepoint_jump)
14947 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
14948 (reinsert_fast_tracepoint_jumps_at): Declare.
14949 * regcache.c: Don't compile many functions when building the
14950 in-process agent library.
14951 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
14952 the register buffer in the heap.
14953 (free_register_cache): If the register buffer isn't owned by the
14954 regcache, don't free it.
14955 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
14956 pre-existing register caches.
14957 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
14959 (convert_ascii_to_int): : Constify `from' parameter type.
14960 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
14961 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
14962 the needed buffer in-place.
14963 (relocate_instruction): New.
14964 * server.c (handle_query) <qSymbols>: If the target supports
14965 tracepoints, give it a chance of looking up symbols. Report
14966 support for fast tracepoints.
14967 (handle_status): Stabilize threads.
14968 (process_serial_event): Adjust.
14969 * server.h (struct fast_tracepoint_jump): Forward declare.
14970 (struct process_info) <fast_tracepoint_jumps>: New field.
14971 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
14972 (decode_X_packet, decode_M_packet): Adjust.
14973 (relocate_instruction): Declare.
14974 (in_process_agent_loaded): Declare.
14975 (tracepoint_look_up_symbols): Declare.
14976 (struct fast_tpoint_collect_status): Declare.
14977 (fast_tracepoint_collecting): Declare.
14978 (force_unlock_trace_buffer): Declare.
14979 (handle_tracepoint_bkpts): Declare.
14980 (initialize_low_tracepoint)
14981 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
14982 * target.h (struct target_ops) <stabilize_threads,
14983 install_fast_tracepoint_jump_pad>: New fields.
14984 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
14985 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
14986 [HAVE_STDINT_H]: Include stdint.h.
14987 (trace_debug_1): Rename to ...
14988 (trace_vdebug): ... this.
14989 (trace_debug): Rename to ...
14990 (trace_debug_1): ... this. Add `level' parameter.
14991 (trace_debug): New.
14992 (ATTR_USED, ATTR_NOINLINE): New.
14993 (IP_AGENT_EXPORT): New.
14994 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
14995 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
14996 (about_to_request_buffer_space, trace_buffer_is_full)
14997 (stopping_tracepoint, expr_eval_result, error_tracepoint)
14998 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
14999 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
15000 (traceframe_write_count, traceframes_created)
15001 (trace_state_variables)
15002 New renaming defines.
15003 (struct ipa_sym_addresses): New.
15004 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
15005 (symbol_list): New.
15006 (ipa_sym_addrs): New.
15007 (all_tracepoint_symbols_looked_up): New.
15008 (in_process_agent_loaded): New.
15009 (write_e_ipa_not_loaded): New.
15010 (maybe_write_ipa_not_loaded): New.
15011 (tracepoint_look_up_symbols): New.
15012 (debug_threads) [IN_PROCESS_AGENT]: New.
15013 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
15014 (UNKNOWN_SIDE_EFFECTS): New.
15015 (stop_tracing): New.
15016 (flush_trace_buffer): New.
15017 (stop_tracing_bkpt): New.
15018 (flush_trace_buffer_bkpt): New.
15019 (read_inferior_integer): New.
15020 (read_inferior_uinteger): New.
15021 (read_inferior_data_pointer): New.
15022 (write_inferior_data_pointer): New.
15023 (write_inferior_integer): New.
15024 (write_inferior_uinteger): New.
15025 (struct collect_static_trace_data_action): Delete.
15026 (enum tracepoint_type): New.
15027 (struct tracepoint) <type>: New field `type'.
15028 <actions_str, step_actions, step_actions_str>: Only include in
15030 <orig_size, obj_addr_on_target, adjusted_insn_addr>
15031 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
15032 (tracepoints): Use IP_AGENT_EXPORT.
15033 (last_tracepoint): Don't include in the IPA.
15034 (stopping_tracepoint): Use IP_AGENT_EXPORT.
15035 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
15036 (alloced_trace_state_variables): New.
15037 (trace_state_variables): Use IP_AGENT_EXPORT.
15038 (traceframe_t): Delete unused variable.
15039 (circular_trace_buffer): Don't include in the IPA.
15040 (trace_buffer_start): Delete.
15041 (struct trace_buffer_control): New.
15042 (trace_buffer_free): Delete.
15043 (struct ipa_trace_buffer_control): New.
15044 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
15045 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
15047 (trace_buffer_ctrl): New.
15048 (TRACE_BUFFER_CTRL_CURR): New.
15049 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
15050 Reimplement as macros.
15051 (trace_buffer_wrap): Delete.
15052 (traceframe_write_count, traceframe_read_count)
15053 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
15054 (struct tracepoint_hit_ctx) <type>: New field.
15055 (struct fast_tracepoint_ctx): New.
15056 (memory_barrier): New.
15058 (record_tracepoint_error): Update atomically in the IPA.
15059 (clear_inferior_trace_buffer): New.
15060 (about_to_request_buffer_space): New.
15061 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
15062 updating the same buffer.
15063 (add_tracepoint): Default the tracepoint's type to trap
15064 tracepoint, and orig_size to -1.
15065 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
15066 internal variables.
15067 (create_trace_state_variable): New parameter `gdb'. Handle it.
15068 (clear_installed_tracepoints): Clear fast tracepoint jumps.
15069 (cmd_qtdp): Handle fast tracepoints.
15070 (cmd_qtdv): Adjust.
15071 (max_jump_pad_size): New.
15072 (gdb_jump_pad_head): New.
15073 (get_jump_space_head): New.
15074 (claim_jump_space): New.
15075 (sort_tracepoints): New.
15076 (MAX_JUMP_SIZE): New.
15077 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
15079 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
15080 support. Upload fast traceframes, and delete internal IPA
15082 (stop_tracing_handler): New.
15083 (flush_trace_buffer_handler): New.
15084 (cmd_qtstop): Upload fast tracepoints.
15085 (response_tracepoint): Handle fast tracepoints.
15086 (tracepoint_finished_step): Upload fast traceframes. Set the
15087 tracepoint hit context's tracepoint type.
15088 (handle_tracepoint_bkpts): New.
15089 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
15090 type. Add comment about fast tracepoints.
15091 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
15092 non-existing action_str field.
15093 (get_context_regcache): Handle fast tracepoints.
15094 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
15096 (fast_tracepoint_from_jump_pad_address): New.
15097 (fast_tracepoint_from_ipa_tpoint_address): New.
15098 (collecting_t): New.
15099 (force_unlock_trace_buffer): New.
15100 (fast_tracepoint_collecting): New.
15102 (gdb_collect): New.
15103 (write_inferior_data_ptr): New.
15104 (target_tp_heap): New.
15105 (target_malloc): New.
15106 (download_agent_expr): New.
15108 (download_tracepoints): New.
15109 (download_trace_state_variables): New.
15110 (upload_fast_traceframes): New.
15111 (IPA_FIRST_TRACEFRAME): New.
15112 (IPA_NEXT_TRACEFRAME_1): New.
15113 (IPA_NEXT_TRACEFRAME): New.
15114 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
15115 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
15116 (gdb_jump_pad_buffer_end): New.
15117 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
15118 (initialize_tracepoint): Adjust.
15119 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
15120 buffer. Initialize the low module.
15121 * utils.c (PREFIX, TOOLNAME): New.
15122 (malloc_failure): Use PREFIX.
15123 (error): In the IPA, an error causes an exit.
15124 (fatal, warning): Use PREFIX.
15125 (internal_error): Use TOOLNAME.
15126 (NUMCELLS): Increase to 10.
15127 * configure, config.in: Regenerate.
15129 2010-06-01 Pedro Alves <pedro@codesourcery.com>
15131 * server.c (handle_query) <qSupported>: Do two passes over the
15132 qSupported string to avoid nesting strtok.
15134 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
15136 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
15138 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
15139 -Wl,--dynamic-list.
15140 * configure: Regenerate.
15141 * proc-service.list: New.
15143 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
15145 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
15148 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
15150 * gdbreplay.c (remote_open): Check error return from socket() call by
15151 its equality to -1 not by it being negative.
15152 * remote-utils.c (remote_open): Likewise.
15154 2010-05-23 Pedro Alves <pedro@codesourcery.com>
15156 * config.h: Regenerate.
15158 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
15160 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
15161 doesn't provide PTRACE_GET_THREAD_AREA.
15163 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
15165 * linux-m68k-low.c: Include <asm/ptrace.h>
15166 (ps_get_thread_area): Implement.
15168 2010-05-03 Doug Evans <dje@google.com>
15170 * event-loop.c (struct callback_event): New struct.
15171 (callback_list): New global.
15172 (append_callback_event, delete_callback_event): New functions.
15173 (process_callback): New function.
15174 (start_event_loop): Call it.
15175 * remote-utils.c (NOT_SCHEDULED): Define.
15176 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
15177 moved out of readchar.
15178 (readchar): Rewrite. Call reschedule before returning.
15179 (reset_readchar): New function.
15180 (remote_close): Call it.
15181 (process_remaining, reschedule): New functions.
15182 * server.h (callback_handler_func): New typedef.
15183 (append_callback_event, delete_callback_event): Declare.
15185 2010-05-03 Pedro Alves <pedro@codesourcery.com>
15187 * proc-service.c (ps_pglobal_lookup): Use
15188 thread_db_look_up_one_symbol.
15189 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
15190 parameter. Use it instead of all_symbols_looked_up.
15191 * server.h (struct process_info) <all_symbols_looked_up>: Delete
15193 (all_symbols_looked_up): Don't declare.
15194 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
15195 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
15197 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
15198 Set all_symbols_looked_up here.
15199 (thread_db_look_up_one_symbol): New.
15200 (thread_db_get_tls_address): Adjust.
15201 (thread_db_load_search, try_thread_db_load_1): Always allocate the
15202 thread_db object on the heap, and tentatively set it in the
15204 (thread_db_init): Don't set all_symbols_looked_up here.
15205 * linux-low.h (thread_db_look_up_one_symbol): Declare.
15207 2010-05-03 Pedro Alves <pedro@codesourcery.com>
15209 * linux-low.c (linux_kill, linux_detach): Adjust.
15210 (status_pending_p_callback): Remove redundant statement. Check
15211 for !TARGET_WAITIKIND_IGNORE, instead of
15212 TARGET_WAITKIND_STOPPED.
15213 (handle_tracepoints): Make sure LWP is locked. Adjust.
15214 (linux_wait_for_event_1): Adjust.
15215 (linux_cancel_breakpoints): New.
15216 (unsuspend_one_lwp): New.
15217 (unsuspend_all_lwps): New.
15218 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
15219 (send_sigstop_callback): Change return type to int, add new
15220 `except' parameter and handle it.
15221 (suspend_and_send_sigstop_callback): New.
15222 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
15223 pass them down. If SUSPEND, also increment the lwp's suspend
15225 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
15226 (need_step_over_p): Don't consider suspended LWPs.
15227 (start_step_over): Adjust.
15228 (proceed_one_lwp): Change return type to int, add new `except'
15229 parameter and handle it.
15230 (unsuspend_and_proceed_one_lwp): New.
15231 (proceed_all_lwps): Use find_inferior instead of
15233 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
15234 also decrement the suspend count of LWPs. Pass `except' down,
15235 instead of hacking its suspend count.
15236 (linux_pause_all): Add `freeze' parameter. Adjust.
15237 (linux_unpause_all): New.
15238 (linux_target_ops): Install linux_unpause_all.
15239 * server.c (handle_status): Adjust.
15240 * target.h (struct target_ops): New fields `unpause_all' and
15241 `cancel_breakpoints'. Add new parameter to `pause_all'.
15242 (pause_all): Add new `freeze' parameter.
15243 (unpause_all): New.
15244 (cancel_breakpoints): New.
15245 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
15246 cancel breakpoints.
15247 (cmd_qtstart): Pause threads.
15248 (stop_tracing): Pause threads, and cancel breakpoints.
15249 * win32-low.c (win32_target_ops): Adjust.
15251 2010-05-03 Pedro Alves <pedro@codesourcery.com>
15253 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
15254 the inferior right away from here...
15255 (linux_wait_1): ... to here, and adjust to check the thread's
15256 last_resume_kind instead of the lwp's step or stop_expected flags.
15258 2010-05-02 Pedro Alves <pedro@codesourcery.com>
15260 * README: Use consistent `GDB' and `GDBserver' spellings.
15262 2010-05-02 Pedro Alves <pedro@codesourcery.com>
15264 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
15265 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
15266 (linux_detach_one_lwp): Assume the lwp is stopped.
15267 (any_thread_of): Delete.
15268 (linux_detach): Stop all lwps here. Don't blindly delete all
15270 (delete_lwp_callback): New.
15271 (linux_mourn): Delete all lwps of the process that is gone.
15272 (linux_wait_1): Don't delete the last lwp of the process here.
15273 * mem-break.h (mark_breakpoints_out): Declare.
15274 * mem-break.c (mark_breakpoints_out): New.
15275 (free_all_breakpoints): Use it.
15276 * server.c (handle_target_event): If the process is gone, mark
15278 * thread-db.c (struct thread_db) <create_bp>: New field.
15279 (thread_db_enable_reporting): Fix prototype. Store a thread event
15280 breakpoint reference in the thread_db struct.
15281 (thread_db_load_search): Clear the thread_db object.
15282 (try_thread_db_load_1): Ditto.
15283 (switch_to_process): New.
15284 (disable_thread_event_reporting): Use it.
15285 (remove_thread_event_breakpoints): New.
15286 (thread_db_detach, thread_db_mourn): Use it.
15288 2010-05-01 Pedro Alves <pedro@codesourcery.com>
15290 * linux-low.c (linux_enable_event_reporting): New.
15291 (linux_wait_for_event_1, handle_extended_wait): Use it.
15293 2010-04-30 Pedro Alves <pedro@codesourcery.com>
15295 * linux-low.c (linux_kill_one_lwp, linux_kill)
15296 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
15297 (send_sigstop): Take an lwp_info as parameter instead. Queue a
15298 SIGSTOP even if the LWP is stopped.
15299 (send_sigstop_callback): New.
15300 (stop_all_lwps): Use send_sigstop_callback instead.
15301 (linux_resume_one_thread): Adjust.
15302 (proceed_one_lwp): Still proceed an LWP that the client has
15303 requested to stop, if we haven't reported it as stopped yet. Make
15304 sure that LWPs the client want stopped, have a pending SIGSTOP.
15306 2010-04-26 Doug Evans <dje@google.com>
15308 * server.c (handle_general_set): Make static.
15310 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
15311 Print received char after testing for error/eof instead of before.
15312 (input_interrupt): Tweak comment.
15314 2010-04-23 Doug Evans <dje@google.com>
15316 * server.c (start_inferior): Print inferior argv if --debug.
15318 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
15320 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
15321 * nto-x86-low.c: Include server.h
15323 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
15325 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
15326 be consistent with other sources of this directory.
15327 (init_registers_amd64): Correct name of source file of this function
15330 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
15332 * configure.srv (x86_64-*-mingw*): New configuration for Windows
15333 64-bit executables.
15335 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
15337 * win32-i386-low.c: Add 64-bit support.
15338 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
15339 (init_registers_amd64): Declare.
15340 (mappings): Add 64-bit version of array.
15341 (init_windows_x86): New function.
15342 (the_low_target): Change init_arch field to init_windows_x86.
15344 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
15346 * win32-low.c: Adapt to support also 64-bit architecture.
15347 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
15348 (get_image_name): Use SIZE_T type for local variable `done'.
15349 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
15350 (toolhelp_get_dll_name): Idem.
15351 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
15352 Use uintptr_t typecast to avoid warning.
15353 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
15354 (handle_exception): Use phex_nz to avoid warning.
15355 (win32_wait): Remove unused local variable `process'.
15357 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
15359 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
15362 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
15364 * configure.ac: Use `ws2_32' library for srv_mingw.
15365 * configure: Regenerate.
15366 * gdbreplay.c: Include winsock2.h instead of winsock.h.
15367 * remote-utils.c: Likewise.
15369 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
15371 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
15372 if __x86_64__ is defined.
15374 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
15376 * configure: Regenerate.
15378 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
15380 * server.c (handle_query): Handle 'qGetTIBAddr' query.
15381 * target.h (target_ops): New get_tib_address field.
15382 * win32-low.h (win32_thread_info): Add thread_local_base field.
15383 * win32-low.c (child_add_thread): Add tlb argument.
15384 Set thread_local_base field to TLB.
15385 (get_child_debug_event): Adapt to child_add_thread change.
15386 (win32_get_tib_address): New function.
15387 (win32_target_ops): Set get_tib_address field to
15388 win32_get_tib_address.
15389 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
15391 2010-04-12 Pedro Alves <pedro@codesourcery.com>
15393 * linux-low.c (linux_mourn): Also remove the process.
15394 * server.c (handle_target_event): Don't remove the process here.
15395 * nto-low.c (nto_mourn): New.
15396 (nto_target_ops): Install it.
15397 * spu-low.c (spu_mourn): New.
15398 (spu_target_ops): Install it.
15399 * win32-low.c (win32_mourn): New.
15400 (win32_target_ops): Install it.
15402 2010-04-12 Pedro Alves <pedro@codesourcery.com>
15404 * server.h (buffer_xml_printf): Remove redundant `;'.
15406 2010-04-12 Pedro Alves <pedro@codesourcery.com>
15408 * regcache.c (set_register_cache): Invalidate regcaches before
15409 changing the register cache layout.
15410 (regcache_invalidate_one): Allow a NULL regcache.
15411 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
15412 regcaches before changing the register cache layout or the target
15415 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
15417 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
15418 variable warning on Linux/x86-64.
15420 2010-04-11 Pedro Alves <pedro@codesourcery.com>
15422 GDBserver disconnected tracing support.
15424 * linux-low.c (linux_remove_process): Delete.
15425 (add_lwp): Don't set last_resume_kind here.
15426 (linux_kill): Use `mourn'.
15427 (linux_detach): Use `thread_db_detach', and `mourn'.
15428 (linux_mourn): New.
15429 (linux_attach_lwp_1): Adjust comment.
15430 (linux_attach): last_resume_kind moved the thread_info; adjust.
15431 (status_pending_p_callback): Adjust.
15432 (linux_wait_for_event_1): Adjust.
15433 (count_events_callback, select_singlestep_lwp_callback)
15434 (select_event_lwp_callback, cancel_breakpoints_callback)
15435 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
15436 (proceed_one_lwp): Adjust.
15437 (linux_async): Add debug output.
15438 (linux_thread_stopped): New.
15439 (linux_pause_all): New.
15440 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
15442 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
15443 (thread_db_free): Delete declaration.
15444 (thread_db_detach, thread_db_mourn): Declare.
15445 * thread-db.c (thread_db_init): Use thread_db_mourn.
15446 (thread_db_free): Delete, split in two.
15447 (disable_thread_event_reporting): New.
15448 (thread_db_detach): New.
15449 (thread_db_mourn): New.
15451 * server.h (struct thread_info) <last_resume_kind>: New field.
15452 <attached>: Add comment.
15453 <gdb_detached>: New field.
15454 (handler_func): Change return type to int.
15455 (handle_serial_event, handle_target_event): Ditto.
15456 (gdb_connected): Declare.
15458 (disconnected_tracing): Declare.
15459 (stop_tracing): Declare.
15461 * server.c (handle_query) <qSupported>: Report support for
15462 disconnected tracing.
15463 (queue_stop_reply_callback): Account for running threads.
15464 (gdb_wants_thread_stopped): New.
15465 (gdb_wants_all_threads_stopped): New.
15466 (gdb_reattached_process): New.
15467 (handle_status): Clear the `gdb_detached' flag of all processes.
15468 In all-stop, stop all threads.
15469 (main): Be sure to leave tfind mode. Handle disconnected tracing.
15470 (process_serial_event): If the remote connection breaks, or if an
15471 exit was forced with "monitor exit", force an event loop exit.
15472 Handle disconnected tracing on detach.
15473 (handle_serial_event): Adjust.
15474 (handle_target_event): If GDB isn't connected, forward events back
15475 to the inferior, unless the last process exited, in which case,
15476 exit gdbserver. Adjust interface.
15478 * remote-utils.c (remote_open): Don't block in accept. Instead
15479 register an event loop source on the listen socket file
15480 descriptor. Refactor bits into ...
15481 (listen_desc): ... this new global.
15482 (gdb_connected): ... this new function.
15483 (enable_async_notification): ... this new function.
15484 (handle_accept_event): ... this new function.
15485 (remote_close): Clear remote_desc.
15487 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
15489 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
15491 (mourn_inferior): Define.
15492 (target_process_qsupported): Avoid the dangling else problem.
15493 (thread_stopped): Define.
15494 (pause_all): Define.
15495 (target_waitstatus_to_string): Declare.
15496 * target.c (target_waitstatus_to_string): New.
15498 * tracepoint.c (tracing): Make extern.
15499 (disconnected_tracing): New.
15500 (stop_tracing): Make extern. Handle tracing stops due to GDB
15502 (cmd_qtdisconnected): New.
15503 (cmd_qtstatus): Report disconnected tracing status in trace reply.
15504 (handle_tracepoint_general_set): Handle QTDisconnected.
15506 * event-loop.c (event_handler_func): Change return type to int.
15507 (process_event): Bail out if the event handler wants the event
15509 (handle_file_event): Ditto.
15510 (start_event_loop): Bail out if the event handler wants the event
15513 * nto-low.c (nto_target_ops): Adjust.
15514 * spu-low.c (spu_wait): Don't remove the process here.
15515 (spu_target_ops): Adjust.
15516 * win32-low.c (win32_wait): Don't remove the process here.
15517 (win32_target_ops): Adjust.
15519 2010-04-11 Pedro Alves <pedro@codesourcery.com>
15521 * regcache.c (realloc_register_cache): Invalidate inferior's
15522 regcache before recreating it.
15524 2010-04-09 Pedro Alves <pedro@codesourcery.com>
15526 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
15528 2010-04-09 Stan Shebs <stan@codesourcery.com>
15529 Pedro Alves <pedro@codesourcery.com>
15531 * server.h (LONGEST): New.
15532 (struct thread_info) <while_stepping>: New field.
15533 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
15535 (initialize_tracepoint, handle_tracepoint_general_set)
15536 (handle_tracepoint_query, tracepoint_finished_step)
15537 (tracepoint_was_hit, release_while_stepping_state_list):
15538 (current_traceframe): Declare.
15539 * server.c (handle_general_set): Handle tracepoint packets.
15540 (read_memory): New.
15541 (write_memory): New.
15542 (handle_search_memory_1): Use read_memory.
15543 (handle_query): Report support for conditional tracepoints, trace
15544 state variables, and tracepoint sources. Handle tracepoint
15546 (main): Initialize the tracepoints module.
15547 (process_serial_event): Handle traceframe reads/writes.
15549 * linux-low.c (handle_tracepoints): New.
15550 (linux_wait_1): Call it.
15551 (linux_resume_one_lwp): Handle while-stepping.
15552 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
15553 (linux_target_ops): Install them.
15554 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
15556 * linux-x86-low.c (x86_supports_tracepoints): New.
15557 (the_low_target). Install it.
15559 * mem-break.h (delete_breakpoint): Declare.
15560 * mem-break.c (delete_breakpoint): Make external.
15562 * target.h (struct target_ops): Add `supports_tracepoints',
15563 `read_pc', and `write_pc' fields.
15564 (target_supports_tracepoints): Define.
15565 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
15568 * regcache.h (struct regcache) <registers_owned>: New field.
15569 (init_register_cache, regcache_cpy): Declare.
15570 (regcache_read_pc, regcache_write_pc): Declare.
15571 (register_cache_size): Declare.
15572 (supply_regblock): Declare.
15573 * regcache.c (init_register_cache): New.
15574 (new_register_cache): Use it.
15575 (regcache_cpy): New.
15576 (register_cache_size): New.
15577 (supply_regblock): New.
15578 (regcache_read_pc, regcache_write_pc): New.
15580 * tracepoint.c: New.
15582 * Makefile.in (OBS): Add tracepoint.o.
15583 (tracepoint.o): New rule.
15585 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
15587 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
15589 (i386-mmx.c): Likewise.
15590 (i386-mmx-linux.o): Likewise.
15591 (i386-mmx-linux.c): Likewise.
15593 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
15594 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
15595 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
15596 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
15598 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
15599 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
15600 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
15602 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
15604 * Makefile.in (clean): Updated.
15606 (i386-avx.c): Likewise.
15607 (i386-avx-linux.o): Likewise.
15608 (i386-avx-linux.c): Likewise.
15609 (amd64-avx.o): Likewise.
15610 (amd64-avx.c): Likewise.
15611 (amd64-avx-linux.o): Likewise.
15612 (amd64-avx-linux.c): Likewise.
15614 * configure.srv (srv_i386_regobj): Add i386-avx.o.
15615 (srv_i386_linux_regobj): Add i386-avx-linux.o.
15616 (srv_amd64_regobj): Add amd64-avx.o.
15617 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
15618 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
15619 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
15620 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
15621 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
15622 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
15623 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
15625 * i387-fp.c: Include "i386-xstate.h".
15627 (i387_cache_to_xsave): Likewise.
15628 (i387_xsave_to_cache): Likewise.
15629 (x86_xcr0): Likewise.
15631 * i387-fp.h (i387_cache_to_xsave): Likewise.
15632 (i387_xsave_to_cache): Likewise.
15633 (x86_xcr0): Likewise.
15635 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
15636 * linux-crisv32-low.c (target_regsets): Likewise.
15637 * linux-m68k-low.c (target_regsets): Likewise.
15638 * linux-mips-low.c (target_regsets): Likewise.
15639 * linux-ppc-low.c (target_regsets): Likewise.
15640 * linux-s390-low.c (target_regsets): Likewise.
15641 * linux-sh-low.c (target_regsets): Likewise.
15642 * linux-sparc-low.c (target_regsets): Likewise.
15643 * linux-xtensa-low.c (target_regsets): Likewise.
15645 * linux-low.c: Include <sys/uio.h>.
15646 (regsets_fetch_inferior_registers): Support nt_type.
15647 (regsets_store_inferior_registers): Likewise.
15648 (linux_process_qsupported): New.
15649 (linux_target_ops): Add linux_process_qsupported.
15651 * linux-low.h (regset_info): Add nt_type.
15652 (linux_target_ops): Add process_qsupported.
15654 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
15656 (init_registers_i386_avx_linux): New.
15657 (init_registers_amd64_avx_linux): Likewise.
15658 (xmltarget_i386_linux_no_xml): Likewise.
15659 (xmltarget_amd64_linux_no_xml): Likewise.
15660 (PTRACE_GETREGSET): Likewise.
15661 (PTRACE_SETREGSET): Likewise.
15662 (x86_fill_xstateregset): Likewise.
15663 (x86_store_xstateregset): Likewise.
15664 (use_xml): Likewise.
15665 (x86_linux_update_xmltarget): Likewise.
15666 (x86_linux_process_qsupported): Likewise.
15667 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
15668 (x86_arch_setup): Don't call init_registers_amd64_linux nor
15669 init_registers_i386_linux here. Call
15670 x86_linux_update_xmltarget.
15671 (the_low_target): Add x86_linux_process_qsupported.
15673 * server.c (handle_query): Call target_process_qsupported.
15675 * target.h (target_ops): Add process_qsupported.
15676 (target_process_qsupported): New.
15678 2010-04-03 Pedro Alves <pedro@codesourcery.com>
15680 * inferiors.c (add_thread): Set last_status kind to
15681 TARGET_WAITKIND_IGNORE.
15682 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
15683 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
15684 (linux_wait_1): Move `thread' local definition to block that uses
15685 it. Don't NULL initialize `event_child'.
15686 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
15687 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
15688 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
15690 2010-04-01 Pedro Alves <pedro@codesourcery.com>
15692 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
15693 an extended waitstatus, or by a watchpoint.
15694 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
15695 thread was stepping or has been stopped by a watchpoint.
15697 2010-04-01 Pedro Alves <pedro@codesourcery.com>
15699 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
15700 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
15701 of another, then delete the previous, and validate all
15703 (validate_inserted_breakpoint): New.
15704 (delete_disabled_breakpoints): New.
15705 (validate_breakpoints): New.
15706 (check_mem_read): Validate breakpoints before trusting their
15707 shadow. Delete disabled breakpoints.
15708 (check_mem_write): Validate breakpoints before trusting they
15709 should be inserted. Delete disabled breakpoints.
15710 * mem-break.h (validate_breakpoints):
15711 * server.c (handle_query): Validate breakpoints when we see a
15714 2010-04-01 Pedro Alves <pedro@codesourcery.com>
15716 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
15717 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
15718 if we could tell there's a GDB breakpoint at stop_pc.
15719 (need_step_over_p): Don't do a step over if we find a GDB
15720 breakpoint at the resume PC.
15722 * mem-break.c (struct raw_breakpoint): New.
15723 (enum bkpt_type): New type `gdb_breakpoint'.
15724 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
15725 fields. New field `raw'.
15726 (find_raw_breakpoint_at): New.
15727 (set_raw_breakpoint_at): Handle refcounting. Create a raw
15728 breakpoint instead.
15729 (set_breakpoint_at): Adjust.
15730 (delete_raw_breakpoint): New.
15731 (release_breakpoint): New.
15732 (delete_breakpoint): Rename to...
15733 (delete_breakpoint_1): ... this. Add proc parameter. Use
15734 release_breakpoint. Return ENOENT.
15735 (delete_breakpoint): Reimplement.
15736 (find_breakpoint_at): Delete.
15737 (find_gdb_breakpoint_at): New.
15738 (delete_breakpoint_at): Delete.
15739 (set_gdb_breakpoint_at): New.
15740 (delete_gdb_breakpoint_at): New.
15741 (gdb_breakpoint_here): New.
15742 (set_reinsert_breakpoint): Use release_breakpoint.
15743 (uninsert_breakpoint): Rename to ...
15744 (uninsert_raw_breakpoint): ... this.
15745 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
15746 (reinsert_raw_breakpoint): Change parameter type to
15748 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
15750 (check_breakpoints): Adjust. Use release_breakpoint.
15751 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
15752 (breakpoint_inserted_here): Ditto.
15753 (check_mem_read): Adjust to iterate over raw breakpoints instead.
15754 Don't trust the breakpoint's shadow if it is not inserted.
15755 (check_mem_write): Adjust to iterate over raw breakpoints instead.
15756 (delete_all_breakpoints): Adjust.
15757 (free_all_breakpoints): Mark all breakpoints as uninserted, and
15758 use delete_breakpoint_1.
15760 * mem-break.h (breakpoints_supported): Delete declaration.
15761 (set_gdb_breakpoint_at): Declare.
15762 (gdb_breakpoint_here): Declare.
15763 (delete_breakpoint_at): Delete.
15764 (delete_gdb_breakpoint_at): Declare.
15766 * server.h (struct raw_breakpoint): Forward declare.
15767 (struct process_info): New field `raw_breakpoints'.
15769 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
15772 2010-03-24 Pedro Alves <pedro@codesourcery.com>
15774 * linux-low.c (status_pending_p_callback): Fix comment.
15775 (linux_wait_for_event_1): Move most of the internal breakpoint
15776 handling from here...
15777 (linux_wait_1): ... to here.
15778 (count_events_callback): New.
15779 (select_singlestep_lwp_callback): New.
15780 (select_event_lwp_callback): New.
15781 (cancel_breakpoints_callback): New.
15782 (select_event_lwp): New.
15783 (linux_wait_1): Simplify internal breakpoint handling. Give equal
15784 priority to all LWPs that have had events that should be reported
15785 to the client. Cancel breakpoints when about to reporting the
15786 event to the client, not while stopping lwps. No longer cancel
15787 finished single-steps here.
15788 (cancel_finished_single_step): Delete.
15789 (cancel_finished_single_steps): Delete.
15791 2010-03-24 Pedro Alves <pedro@codesourcery.com>
15793 * mem-break.c (enum bkpt_type): New.
15794 (struct breakpoint): New field `type'.
15795 (set_breakpoint_at): Change return type to struct breakpoint
15796 pointer. Set type to `other_breakpoint' by default.
15797 (delete_breakpoint): Rewrite, supporting more than one breakpoint
15798 in the breakpoint list.
15799 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
15800 (reinsert_breakpoint): Rename to ...
15801 (reinsert_raw_breakpoint): ... this.
15802 (reinsert_breakpoints_at): Adjust.
15803 * mem-break.h (struct breakpoint): Declare.
15804 (set_breakpoint_at): Change return type to struct breakpoint
15807 2010-03-24 Pedro Alves <pedro@codesourcery.com>
15809 * server.c (handle_query): Assign, not compare.
15811 2010-03-24 Pedro Alves <pedro@codesourcery.com>
15813 Teach linux gdbserver to step-over-breakpoints.
15815 * linux-low.c (can_hardware_single_step): New.
15816 (supports_breakpoints): New.
15817 (handle_extended_wait): If stopping threads, read the stop pc of
15818 the new cloned LWP.
15820 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
15821 low target doesn't support retrieving the PC.
15822 (add_lwp): Set last_resume_kind to resume_continue.
15823 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
15824 (linux_attach): Don't clear stop_expected. Set the lwp's
15825 last_resume_kind to resume_stop.
15826 (linux_detach_one_lwp): Don't check for removed breakpoints.
15827 (check_removed_breakpoint): Delete.
15828 (status_pending_p): Rename to ...
15829 (status_pending_p_callback): ... this. Don't check for removed
15830 breakpoints. Don't consider threads that are stopped from GDB's
15832 (linux_wait_for_lwp): Always read the stop_pc here.
15833 (cancel_breakpoint): New.
15834 (step_over_bkpt): New global.
15835 (linux_wait_for_event_1): Implement stepping over breakpoints.
15836 (gdb_wants_lwp_stopped): New.
15837 (gdb_wants_all_stopped): New.
15838 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
15839 single-step traps here. Store the thread's last reported target
15841 (send_sigstop): Don't clear stop_expected. Always set it,
15843 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
15844 (cancel_finished_single_step): New.
15845 (cancel_finished_single_steps): New.
15846 (wait_for_sigstop): Don't cancel finished single-step traps here.
15847 (linux_resume_one_lwp): Don't check for removed breakpoints.
15848 Don't set `step' on non-hardware step archs.
15849 (linux_set_resume_request): Ignore resume_stop requests if already
15850 stopping or stopped. Set the lwp's last_resume_kind.
15851 (resume_status_pending_p): Don't check for removed breakpoints.
15852 (need_step_over_p): New.
15853 (start_step_over): New.
15854 (finish_step_over): New.
15855 (linux_resume_one_thread): Always queue a sigstop for resume_stop
15856 requests. Clear the thread's last reported target waitstatus.
15857 Don't use the `suspended' flag. Don't consider pending breakpoints.
15858 (linux_resume): Start a step-over if necessary.
15859 (proceed_one_lwp): New.
15860 (proceed_all_lwps): New.
15861 (unstop_all_lwps): New.
15862 * linux-low.h (struct lwp_info): Rewrite comment for the
15863 `suspended' flag. Add the `stop_pc' field. Delete the
15864 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
15865 Add `'last_resume_kind' and `need_step_over' fields.
15866 * inferiors.c (struct thread_info): Delete, moved elsewhere.
15867 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
15868 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
15869 (set_raw_breakpoint_at): New.
15870 (set_breakpoint_at): Rewrite to use it.
15871 (reinsert_breakpoint_handler): Delete.
15872 (set_reinsert_breakpoint): New.
15873 (reinsert_breakpoint_by_bp): Delete.
15874 (delete_reinsert_breakpoints): New.
15875 (uninsert_breakpoint): Rewrite.
15876 (uninsert_breakpoints_at): New.
15877 (reinsert_breakpoint): Rewrite.
15878 (reinsert_breakpoints_at): New.
15879 (check_breakpoints): Rewrite.
15880 (breakpoint_here): New.
15881 (breakpoint_inserted_here): New.
15882 (check_mem_read): Adjust.
15883 * mem-break.h (breakpoints_supported, breakpoint_here)
15884 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
15885 (reinsert_breakpoint_by_bp): Delete declaration.
15886 (delete_reinsert_breakpoints): Declare.
15887 (reinsert_breakpoint): Delete declaration.
15888 (reinsert_breakpoints_at): Declare.
15889 (uninsert_breakpoint): Delete declaration.
15890 (uninsert_breakpoints_at): Declare.
15891 (check_breakpoints): Adjust prototype.
15892 * server.h: Adjust include order.
15893 (struct thread_info): Declare here. Add a `last_status' field.
15895 2010-03-23 Michael Snyder <msnyder@vmware.com>
15897 * server.c (crc32): New function.
15898 (handle_query): Add handling for 'qCRC:' request.
15900 2010-03-23 Pedro Alves <pedro@codesourcery.com>
15902 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
15903 lwp had been stopped by a watchpoint.
15905 2010-03-16 Pedro Alves <pedro@codesourcery.com>
15907 * server.h (internal_error): Declare.
15908 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
15909 * utils.c (internal_error): New function.
15911 2010-03-15 Andreas Schwab <schwab@redhat.com>
15913 * configure.srv: Fix typo setting srv_regobj.
15915 2010-03-15 Pedro Alves <pedro@codesourcery.com>
15917 * linux-low.c (fetch_register): Avoid passing a non string literal
15919 (usr_store_inferior_registers): Ditto.
15921 2010-03-14 Pedro Alves <pedro@codesourcery.com>
15923 * linux-low.c (linux_write_memory): Bail out early if peeking
15926 2010-03-14 Pedro Alves <pedro@codesourcery.com>
15928 * linux-low.h (struct lwp_info): New fields
15929 `stopped_by_watchpoint' and `stopped_data_address'.
15930 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
15931 here, and cache them in the lwp object.
15932 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
15934 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
15936 (linux_stopped_by_watchpoint): Rewrite.
15937 (linux_stopped_data_address): Rewrite.
15939 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
15941 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
15942 switching the current inferior, not before.
15944 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
15946 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
15947 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
15948 i386-linux.c and amd64-linux.c.
15949 (reg-i386.o): Removed.
15950 (reg-i386.c): Likewise.
15951 (reg-i386-linux.o): Likewise.
15952 (reg-i386-linux.c): Likewise.
15953 (reg-x86-64.o): Likewise.
15954 (reg-x86-64.c): Likewise.
15955 (reg-x86-64-linux.o): Likewise.
15956 (reg-x86-64-linux.c): Likewise.
15958 (i386.c): Likewise.
15959 (i386-linux.o): Likewise.
15960 (i386-linux.c): Likewise.
15961 (amd64.o): Likewise.
15962 (amd64.c): Likewise.
15963 (amd64-linux.o): Likewise.
15964 (amd64-linux.c): Likewise.
15966 * configure.srv (srv_i386_regobj): New.
15967 (srv_i386_linux_regobj): Likewise.
15968 (srv_amd64_regobj): Likewise.
15969 (srv_amd64_linux_regobj): Likewise.
15970 (srv_i386_32bit_xmlfiles): Likewise.
15971 (srv_i386_64bit_xmlfiles): Likewise.
15972 (srv_i386_xmlfiles): Likewise.
15973 (srv_amd64_xmlfiles): Likewise.
15974 (srv_i386_linux_xmlfiles): Likewise.
15975 (srv_amd64_linux_xmlfiles): Likewise.
15976 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
15977 srv_xmlfiles to $srv_i386_xmlfiles.
15978 (i[34567]86-*-mingw32ce*): Likewise.
15979 (i[34567]86-*-mingw*): Likewise.
15980 (i[34567]86-*-nto*): Likewise.
15981 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
15982 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
15983 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
15984 (x86_64-*-linux*): Likewise.
15986 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
15987 (init_registers_amd64_linux): New.
15988 (x86_arch_setup): Replace init_registers_x86_64_linux with
15989 init_registers_amd64_linux.
15991 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
15993 * configure.ac: Check for libdl. If it is not available link against
15994 static libthread_db.
15995 * configure: Regenerate.
15997 2010-02-22 Pedro Alves <pedro@codesourcery.com>
16001 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
16002 handing a read watchpoint.
16003 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
16005 2010-02-12 Doug Evans <dje@google.com>
16007 * linux-low.c (linux_supports_tracefork_flag): Document.
16008 (linux_look_up_symbols): Add comment.
16010 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
16012 * regcache.c (supply_register): Clear regcache if buf is NULL.
16014 2010-02-02 Nicolas Roche <roche@sourceware.org>
16015 Joel Brobecker <brobecker@adacore.com>
16017 * inferiors.c (find_inferior): Add function documentation.
16018 (unloaded_dll): Handle the case where the unloaded dll has not
16019 been previously registered in the dll list.
16021 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
16023 * linux-arm-low.c (thumb_breakpoint_len): Delete.
16024 (thumb2_breakpoint): New.
16025 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
16027 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
16029 * linux-low.c (get_stop_pc): Check for SIGTRAP.
16030 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
16033 2010-01-21 Pedro Alves <pedro@codesourcery.com>
16035 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
16037 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
16039 * linux-s390-low.c (s390_collect_ptrace_register)
16040 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
16042 2010-01-21 Doug Evans <dje@google.com>
16044 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
16045 (PTRACE_ARG4_TYPE): New macro.
16046 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
16047 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
16048 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
16049 (usr_store_inferior_registers): Ditto.
16050 (linux_read_memory, linux_write_memory): Ditto.
16051 (linux_test_for_tracefork): Ditto.
16053 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
16054 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
16056 2010-01-21 Pedro Alves <pedro@codesourcery.com>
16058 * proc-service.c (ps_lgetregs): Don't refetch registers from the
16061 2010-01-21 Pedro Alves <pedro@codesourcery.com>
16063 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
16064 prototype to take a regcache. Adjust.
16066 2010-01-20 Pedro Alves <pedro@codesourcery.com>
16068 * regcache.h (struct thread_info): Forward declare.
16069 (struct regcache): New.
16070 (new_register_cache): Adjust prototype.
16071 (get_thread_regcache): Declare.
16072 (free_register_cache): Adjust prototype.
16073 (registers_to_string, registers_from_string): Ditto.
16074 (supply_register, supply_register_by_name, collect_register)
16075 (collect_register_as_string, collect_register_by_name): Ditto.
16076 * regcache.c (struct inferior_regcache_data): Delete.
16077 (get_regcache): Rename to ...
16078 (get_thread_regcache): ... this. Adjust. Switch inferior before
16079 fetching registers.
16080 (regcache_invalidate_one): Adjust.
16081 (regcache_invalidate): Fix prototype.
16082 (new_register_cache): Return the new register cache.
16083 (free_register_cache): Change prototype.
16084 (realloc_register_cache): Adjust.
16085 (registers_to_string): Change prototype to take a regcache. Adjust.
16086 (registers_from_string): Ditto.
16087 (register_data): Ditto.
16088 (supply_register): Ditto.
16089 (supply_register_by_name): Ditto.
16090 (collect_register): Ditto.
16091 (collect_register_as_string): Ditto.
16092 (collect_register_by_name): Ditto.
16093 * server.c (process_serial_event): Adjust.
16094 * linux-low.h (regset_fill_func, regset_store_func): Change
16096 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
16098 * linux-low.c (get_stop_pc): Adjust.
16099 (check_removed_breakpoint): Adjust.
16100 (linux_wait_for_event): Adjust.
16101 (linux_resume_one_lwp): Adjust.
16102 (fetch_register): Add regcache parameter. Adjust.
16103 (usr_store_inferior_registers): Ditto.
16104 (regsets_fetch_inferior_registers): Ditto.
16105 (regsets_store_inferior_registers): Ditto.
16106 (linux_fetch_registers, linux_store_registers): Ditto.
16107 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
16109 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
16111 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
16112 prototype to take a regcache.
16113 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
16114 * remote-utils.c (convert_ascii_to_int, outreg)
16115 (prepare_resume_reply): Change prototype to take a regcache.
16117 * target.h (struct target_ops) <fetch_registers, store_registers>:
16118 Change prototype to take a regcache.
16119 (fetch_inferior_registers, store_inferior_registers): Change
16120 prototype to take a regcache. Adjust.
16121 * proc-service.c (ps_lgetregs): Adjust.
16122 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
16123 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
16124 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
16125 take a regcache. Adjust.
16126 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
16127 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
16128 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
16129 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
16130 * linux-cris-low.c (cris_get_pc, cris_set_pc)
16131 (cris_cannot_fetch_register):
16132 (cris_breakpoint_at): Change prototype to take a regcache.
16134 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
16135 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
16136 to take a regcache. Adjust.
16137 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
16139 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
16140 take a regcache. Adjust.
16141 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
16142 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
16143 (m68k_set_pc): Change prototype to take a regcache. Adjust.
16144 * linux-mips-low.c (mips_get_pc):
16145 (mips_set_pc): Change prototype to take a regcache. Adjust.
16146 (mips_reinsert_addr): Adjust.
16147 (mips_collect_register): Change prototype to take a regcache.
16149 (mips_supply_register):
16150 (mips_collect_register_32bit, mips_supply_register_32bit)
16151 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
16152 (mips_store_fpregset): Ditto.
16153 * linux-ppc-low.c (ppc_supply_ptrace_register)
16154 (ppc_supply_ptrace_register): Ditto.
16155 (parse_spufs_run): Adjust.
16156 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
16157 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
16158 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
16159 take a regcache. Adjust.
16160 * linux-s390-low.c (s390_collect_ptrace_register)
16161 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
16162 (s390_set_pc): Change prototype to take a regcache. Adjust.
16163 (s390_arch_setup): Adjust.
16164 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
16165 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
16166 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
16167 (sparc_fill_gregset, sparc_store_gregset_from_stack)
16168 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
16170 (sparc_breakpoint_at): Adjust.
16171 * linux-xtensa-low.c (xtensa_fill_gregset):
16172 (xtensa_store_gregset):
16173 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
16174 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
16175 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
16176 prototype to take a regcache. Adjust.
16177 * win32-arm-low.c (arm_fetch_inferior_register)
16178 (arm_store_inferior_register): Change prototype to take a
16180 * win32-i386-low.c (i386_fetch_inferior_register)
16181 (i386_store_inferior_register): Change prototype to take a
16183 * win32-low.c (child_fetch_inferior_registers)
16184 (child_store_inferior_registers): Change prototype to take a
16186 (win32_wait): Adjust.
16187 (win32_fetch_inferior_registers): Change prototype to take a
16189 (win32_store_inferior_registers): Adjust.
16190 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
16191 store_inferior_register>: Change prototype to take a regcache.
16193 2010-01-20 Doug Evans <dje@google.com>
16195 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
16197 (linux_wait_for_event1, linux_init_signals): Ditto.
16198 (W_STOPCODE): Provide definition if missing.
16200 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
16202 * linux-low.c (linux_core_of_thread): New.
16203 (compare_ints, show_process, list_threads): New.
16204 (linux_qxfer_osdata): Report threads and cores.
16205 (linux_target_op): Register linux_core_of_thread.
16206 * remote-utils.c (prepare_resume_reply): Report the core.
16207 (buffer_xml_printf): Support %d specifier.
16208 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
16210 (handle_query): Handle qXfer:threads. Announce availability
16212 * target.h (struct target_ops): New field core_of_thread.
16214 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
16216 * Makefile.in (clean): Remove new generated files.
16217 (reg-s390.o, reg-s390.c): Remove rules.
16218 (reg-s390x.o, reg-s390x.c): Likewise.
16219 (s390-linux32.o, s390-linux32.c): Add rules.
16220 (s390-linux64.o, s390-linux64.c): Likewise.
16221 (s390x-linux64.o, s390x-linux64.c): Likewise.
16222 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
16223 * linux-s390-low.c: Include <elf.h>.
16224 (HWCAP_S390_HIGH_GPRS): Define if undefined.
16225 (init_registers_s390): Remove prototype.
16226 (init_registers_s390x): Likewise.
16227 (init_registers_s390_linux32): Add prototype.
16228 (init_registers_s390_linux64): Likewise.
16229 (init_registers_s390x_linux64): Likewise.
16230 (s390_num_regs_3264): New define.
16231 (s390_regmap_3264): New global variable.
16232 (s390_cannot_fetch_register): Remove obsolete check.
16233 (s390_cannot_store_register): Likewise.
16234 (s390_collect_ptrace_register): Handle upper/lower register halves.
16235 (s390_supply_ptrace_register): Likewise.
16236 (s390_fill_gregset): Update to register number changes.
16237 (s390_get_hwcap): New routine.
16238 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
16239 Install appropriate regmap and register set.
16241 2010-01-01 Joel Brobecker <brobecker@adacore.com>
16243 * server.c (gdbserver_version): Update copyright year to 2010.
16244 * gdbreplay.c (gdbreplay_version): Likewise.
16246 2009-12-28 Doug Evans <dje@google.com>
16248 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
16249 elf/external.h. Include <elf.h> instead but only if necessary.
16251 2009-12-28 Pedro Alves <pedro@codesourcery.com>
16253 * linux-low.c (linux_remove_process): Remove `detaching'
16254 parameter. Don't release/detach from thread_db here.
16255 (linux_kill): Release/detach from thread_db here, ...
16256 (linux_detach): ... and here, before actually detaching.
16257 (linux_wait_1): ... and here, when a process exits.
16258 * thread-db.c (any_thread_of): New.
16259 (thread_db_free): Switch the current inferior to a thread of the
16262 2009-12-21 Doug Evans <dje@google.com>
16264 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
16266 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
16267 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
16268 warning ifndef __NR_tkill. Move setting of errno there too.
16269 Delete unnecessary resetting of errno after syscall.
16270 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
16272 * configure.ac: Check for dladdr.
16273 * config.in: Regenerate.
16274 * configure: Regenerate.
16275 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
16276 (try_thread_db_load): Update.
16278 * linux-low.c (my_waitpid): Delete unnecessary prototype.
16280 2009-12-18 Doug Evans <dje@google.com>
16282 * event-loop.c: Include unistd.h if it exists.
16284 * linux-low.c (my_waitpid): Move definition away from being in
16285 between linux_tracefork_child/linux_test_for_tracefork.
16287 * gdb_proc_service.h (psaddr_t): Fix type.
16288 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
16289 signature to match glibc.
16291 2009-12-16 Doug Evans <dje@google.com>
16293 * linux-low.c (linux_read_memory): Fix argument to read.
16295 2009-11-26 Pedro Alves <pedro@codesourcery.com>
16297 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
16298 events, don't leave current_inferior pointing at null.
16300 2009-11-26 Pedro Alves <pedro@codesourcery.com>
16302 * win32-low.c (LOG): Delete.
16303 (OUTMSG): Output to stderr.
16304 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
16305 on compile time LOG macro.
16306 (win32_wait): Fix debug output.
16308 2009-11-26 Pedro Alves <pedro@codesourcery.com>
16310 * win32-low.c (win32_add_one_solib): If the dll name is
16311 "ntdll.dll", prepend the system directory to the dll path.
16313 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
16315 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
16317 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
16318 Vladimir Prus <vladimir@codesourcery.com>
16320 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
16321 * configure.ac: Check for __mcoldfire__ and set
16322 gdb_cv_m68k_is_coldfire.
16323 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
16324 reg-cf.o and reg-m68k.o.
16325 * configure: Regenerated.
16327 2009-11-16 Pedro Alves <pedro@codesourcery.com>
16329 * linux-low.c (linux_remove_process): Add `detaching' parameter.
16330 Pass it to thread_db_free.
16331 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
16332 proper `detaching' argument to linux_remove_process.
16333 * linux-low.h (thread_db_free): Add `detaching' parameter.
16334 * thread-db.c (thread_db_init): Pass false as `detaching' argument
16336 (thread_db_free): Add `detaching' parameter. Only
16337 call td_ta_clear_event if detaching from process.
16339 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
16341 * thread-db.c (thread_db_free): Fix typo.
16343 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
16346 * thread-db.c (thread_db_free): Call td_ta_clear_event.
16348 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
16350 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
16351 with an i686 compiler.
16352 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
16354 * configure: Rebuilt.
16356 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
16360 * server.c (handle_search_memory_1): Correct read_addr initialization
16361 in loop for searching subsequent chunks.
16363 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
16365 * configure.ac: New --with-libthread-db option.
16366 * thread-db.c: Allow direct dependence on libthread_db.
16367 (thread_db_free): Adjust.
16368 * config.in: Regenerate.
16369 * configure: Likewise.
16371 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
16374 * thread-db.c (attach_thread): New function.
16375 (maybe_attach_thread): Return success/failure.
16376 (find_new_threads_callback): Adjust.
16377 (thread_db_find_new_threads): Loop until no new threads.
16379 2009-10-13 Pedro Alves <pedro@codesourcery.com>
16381 * proc-service.c (ps_lgetregs): Formatting.
16383 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
16385 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
16386 * configure.ac: Adjust.
16387 * linux-low.h (struct process_info_private): Move members to struct
16389 (thread_db_free, thread_db_handle_monitor_command): New prototype.
16390 * linux-low.c (linux_remove_process): Adjust.
16391 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
16392 * server.c (handle_query): Move code ...
16393 (handle_monitor_command): ... here. New function.
16394 * target.h (struct target_ops): New member.
16395 * thread-db.c (struct thread_db): New.
16396 (libthread_db_search_path): New variable.
16397 (thread_db_create_event, thread_db_enable_reporting)
16398 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
16399 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
16400 (try_thread_db_load_1, dladdr_to_soname): New functions.
16401 (try_thread_db_load, thread_db_load_search): New functions.
16402 (thread_db_init): Search for libthread_db.
16403 (thread_db_free): New function.
16404 (thread_db_handle_monitor_command): Likewise.
16405 * config.in: Regenerate.
16406 * configure: Regenerate.
16408 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
16410 * spu-low.c (spu_kill): Wait for inferior to terminate.
16411 Call clear_inferiors.
16412 (spu_detach): Call clear_inferiors.
16414 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
16416 * aclocal.m4: Regenerate.
16417 * config.in: Likewise.
16418 * configure: Likewise.
16420 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
16422 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
16423 (parse_spufs_run): New function.
16424 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
16425 (ppc_breakpoint_at): Handle SPU breakpoints.
16427 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
16429 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
16430 (SPUFS_MAGIC): Define.
16431 (spu_enumerate_spu_ids): New function.
16432 (linux_qxfer_spu): New function.
16433 (linux_target_ops): Install linux_qxfer_spu.
16435 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
16437 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
16438 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
16439 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
16440 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
16441 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
16442 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
16443 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
16444 (init_registers_powerpc_cell32l): Add prototype.
16445 (init_registers_powerpc_cell64l): Likewise.
16446 (ppc_arch_setup): Detect Cell/B.E. architecture.
16448 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
16450 * Makefile.in (datarootdir): New variable.
16452 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
16454 * linux-low.c (linux_write_memory): Update debugging output.
16455 * Makefile.in (clean): Add new descriptions.
16456 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
16457 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
16458 * configure.srv: Add new files for arm*-*-linux*.
16459 * linux-arm-low.c: Add new declarations.
16460 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
16461 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
16462 (HWCAP_VFPv3D16): New.
16463 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
16464 instead of __IWMMXT__.
16465 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
16466 (arm_arch_setup): New.
16467 (target_regsets): Remove #ifdef. Add VFP regset.
16468 (the_low_target): Use arm_arch_setup.
16470 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
16472 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
16473 the main thread again.
16475 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
16477 Adding Neutrino gdbserver.
16478 * configure: Regenerated.
16479 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
16480 * configure.srv (i[34567]86-*-nto*): New target.
16481 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
16482 * remote-utils.c [__QNX__]: Include sys/iomgr.h
16483 (nto_comctrl) [__QNX__]: New function.
16484 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
16486 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
16488 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
16491 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
16492 Pedro Alves <pedro@codesourcery.com>
16494 * win32-i386-low.c (i386_get_thread_context): Handle systems that
16495 don't support CONTEXT_EXTENDED_REGISTERS.
16496 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
16497 (the_low_target): Install them.
16498 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
16499 failing with ERROR_PIPE_NOT_CONNECTED.
16501 2009-06-30 Doug Evans <dje@google.com>
16502 Pierre Muller <muller@ics.u-strasbg.fr>
16504 Add h/w watchpoint support to x86-linux, win32-i386.
16505 * Makefile.in (SFILES): Add i386-low.c
16506 (i386_low_h): Define.
16507 (i386-low.o): Add dependencies.
16508 (linux-x86-low.o): Add i386-low.h dependency.
16509 (win32-i386-low.o): Ditto.
16510 * i386-low.c: New file.
16511 * i386-low.h: New file.
16512 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
16513 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
16514 * linux-low.c (linux_add_process): Initialize arch_private.
16515 (linux_remove_process): Free arch_private.
16516 (add_lwp): Initialize arch_private.
16517 (delete_lwp): Free arch_private.
16518 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
16520 * linux-low.h (process_info_private): New member arch_private.
16521 (lwp_info): New member arch_private.
16522 (linux_target_ops): New members new_process, new_thread,
16524 (ptid_of): New macro.
16525 * linux-x86-low.c: Include stddef.h, i386-low.h.
16526 (arch_process_info): New struct.
16527 (arch_lwp_info): New struct.
16528 (x86_linux_dr_get, x86_linux_dr_set): New functions.
16529 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
16530 (i386_dr_low_get_status): New function.
16531 (x86_insert_point, x86_remove_point): New functions.
16532 (x86_stopped_by_watchpoint): New function.
16533 (x86_stopped_data_address): New function.
16534 (x86_linux_new_process, x86_linux_new_thread): New functions.
16535 (x86_linux_prepare_to_resume): New function.
16536 (the_low_target): Add entries for insert_point, remove_point,
16537 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
16539 * server.c (debug_hw_points): New global.
16540 (monitor_show_help): Document set debug-hw-points.
16541 (handle_query): Process "set debug-hw-points".
16542 * server.h (debug_hw_points): Declare.
16543 (paddress): Declare.
16544 * utils.c (NUMCELLS, CELLSIZE): New macros.
16545 (get_sell, xsnprintf, paddress): New functions.
16546 * win32-arm-low.c (the_low_target): Add entries for insert_point,
16547 remove_point, stopped_by_watchpoint, stopped_data_address.
16548 * win32-i386-low.c: Include i386-low.h.
16549 (debug_reg_state): Replaces dr.
16550 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
16551 (i386_dr_low_get_status): New function.
16552 (i386_insert_point, i386_remove_point): New functions.
16553 (i386_stopped_by_watchpoint): New function.
16554 (i386_stopped_data_address): New function.
16555 (i386_initial_stuff): Update.
16556 (get_thread_context,set_thread_context,i386_thread_added): Update.
16557 (the_low_target): Add entries for insert_point,
16558 remove_point, stopped_by_watchpoint, stopped_data_address.
16559 * win32-low.c (win32_insert_watchpoint): New function.
16560 (win32_remove_watchpoint): New function.
16561 (win32_stopped_by_watchpoint): New function.
16562 (win32_stopped_data_address): New function.
16563 (win32_target_ops): Add entries for insert_watchpoint,
16564 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
16565 * win32-low.h (win32_target_ops): New members insert_point,
16566 remove_point, stopped_by_watchpoint, stopped_data_address.
16568 2009-06-25 Pedro Alves <pedro@codesourcery.com>
16570 * server.c (process_serial_event): Re-return unsupported, not
16571 error, if the type isn't recognized. Re-allow supporting only
16572 insert or remove packets. Also call require_running for
16573 breakpoints. Add missing break statement to default case. Tidy.
16574 * target.h (struct target_ops): Rename insert_watchpoint to
16575 insert_point, and remove_watchpoint to remove_point.
16577 * linux-low.h (struct linux_target_ops): Likewise.
16578 * linux-low.c (linux_insert_watchpoint): Rename to ...
16579 (linux_insert_point): ... this. Adjust.
16580 (linux_remove_watchpoint): Rename to ...
16581 (linux_remove_point): ... this. Adjust.
16582 (linux_target_ops): Adjust.
16583 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
16584 (cris_insert_point): ... this.
16585 (cris_remove_watchpoint): Rename to ...
16586 (cris_remove_point): ... this.
16587 (the_low_target): Adjust.
16589 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
16591 * server.c (handle_v_kill): Pass signal_pid to
16592 kill_inferior if multi_process is zero.
16594 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
16596 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
16597 * target.h (target_ops): Comment for *_watchpoint to make it clear
16598 the functions can get types '0' and '1'.
16600 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
16602 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
16603 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
16604 * regcache.c (get_regcache): Likewise.
16605 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
16606 * win32-low.c (child_fetch_inferior_registers): Remove check for
16609 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
16610 Pedro Alves <pedro@codesourcery.com>
16612 * target.h (struct target_ops) <supports_multi_process>: New
16614 (target_supports_multi_process): New.
16615 * server.c (handle_query): Even if GDB reports support, only
16616 enable multi-process if the target also supports it. Report
16617 multi-process support only if the target backend supports it.
16618 * linux-low.c (linux_supports_multi_process): New function.
16619 (linux_target_ops): Install it as target_supports_multi_process
16622 2009-05-24 Doug Evans <dje@google.com>
16624 Global renaming of find_thread_pid to find_thread_ptid.
16625 * server.h (find_thread_ptid): Renamed from find_thread_pid.
16626 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
16627 All callers updated.
16629 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
16630 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
16633 * linux-low.c (get_stop_pc): Print pc if debug_threads.
16634 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
16635 (linux_resume_one_lwp): Ditto.
16637 2009-05-23 Doug Evans <dje@google.com>
16639 * linux-low.c (linux_resume_one_lwp): Change type of first arg
16640 from struct inferior_list_entry * to struct lwp_info *.
16641 All callers updated.
16643 2009-05-13 Doug Evans <dje@google.com>
16645 * linux-x86-low.c: Don't include assert.h.
16646 (x86_siginfo_fixup): Use fatal, not assert.
16647 (x86_arch_setup): Fix comment.
16649 2009-05-12 Doug Evans <dje@google.com>
16651 Biarch support for i386/amd64 gdbserver.
16652 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
16653 Add linux-x86-low.c.
16654 (linux-i386-low.o, linux-x86-64-low.o): Delete.
16655 (linux-x86-low.o): Add.
16656 * linux-x86-64-low.c: Delete.
16657 * linux-i386-low.c: Delete.
16658 * linux-x86-low.c: New file.
16659 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
16661 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
16663 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
16664 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
16665 (linux_child_pid_to_exec_file): New function.
16666 (elf_64_header_p, elf_64_file_p): New functions.
16667 (siginfo_fixup): New function.
16668 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
16669 give target a chance to convert layout.
16670 * linux-low.h (linux_target_ops): New member siginfo_fixup.
16671 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
16673 2009-05-07 Doug Evans <dje@google.com>
16675 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
16676 (regsets_store_inferior_registers): Ditto.
16678 2009-05-06 Pedro Alves <pedro@codesourcery.com>
16682 * linux-low.c (must_set_ptrace_flags): Delete.
16683 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
16685 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
16686 `lwp->must_set_ptrace_flags' instead.
16687 (linux_wait_for_event_1): Set ptrace options here.
16688 (linux_wait_1): ... not here.
16690 2009-04-30 Doug Evans <dje@google.com>
16692 * inferiors.c (started_inferior_callback): New function.
16693 (attached_inferior_callback): New function.
16694 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
16695 * server.c (print_started_pid, print_attached_pid): New functions.
16696 (detach_or_kill_for_exit): New function.
16697 (main): Call it instead of for_each_inferior (kill_inferior_callback).
16698 * server.h (have_started_inferiors_p): Declare.
16699 (have_attached_inferiors_p): Declare.
16701 * inferiors.c (remove_process): Fix memory leak, free process.
16702 * linux-low.c (linux_remove_process): New function.
16703 (linux_kill): Call it instead of remove_process.
16704 (linux_detach, linux_wait_1): Ditto.
16706 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
16708 * configure.srv: Add x86 Windows CE target.
16710 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
16712 * inferiors.c (get_thread_process): Make global.
16713 * server.h (get_thread_process): Add prototype.
16714 * thread-db.c (find_one_thread): Use get_thread_process
16715 instead of current_process.
16716 (thread_db_get_tls_address): Do not crash if called when
16717 thread layer is not yet initialized.
16719 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
16721 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
16722 * spu-low.c (current_tid): Rename to ...
16723 (current_ptid): ... this.
16724 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
16725 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
16726 ptid_get_lwp (current_ptid) instead of current_tid.
16727 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
16728 instead of current_tid. Use find_process_pid to verify pid
16729 argument is valid. Pass proper argument to remove_process.
16730 (spu_thread_alive): Compare current_ptid instead of current_tid.
16731 (spu_resume): Likewise.
16733 2009-04-02 Pedro Alves <pedro@codesourcery.com>
16735 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
16738 2009-04-01 Pedro Alves <pedro@codesourcery.com>
16740 Implement the multiprocess extensions, and add linux multiprocess
16743 * server.h (ULONGEST): Declare.
16744 (struct ptid, ptid_t): New.
16745 (minus_one_ptid, null_ptid): Declare.
16746 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
16747 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
16748 (struct inferior_list_entry): Change `id' type from unsigned from
16750 (struct sym_cache, struct breakpoint, struct
16751 process_info_private): Forward declare.
16752 (struct process_info): Declare.
16753 (current_process): Declare.
16754 (all_processes): Declare.
16755 (initialize_inferiors): Declare.
16756 (add_thread): Adjust to use ptid_t.
16757 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
16758 (add_process, remove_process, find_thread_pid): Declare.
16759 (find_inferior_id): Adjust to use ptid_t.
16760 (cont_thread, general_thread, step_thread): Change type to ptid_t.
16761 (multi_process): Declare.
16762 (push_event): Adjust to use ptid_t.
16763 (read_ptid, write_ptid): Declare.
16764 (prepare_resume_reply): Adjust to use ptid_t.
16765 (clear_symbol_cache): Declare.
16766 * inferiors.c (all_processes): New.
16767 (null_ptid, minus_one_ptid): New.
16768 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
16769 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
16770 (add_thread): Change unsigned long to ptid. Remove gdb_id
16772 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
16773 (gdb_id_to_thread): Rename to ...
16774 (find_thread_pid): ... this. Change unsigned long to ptid.
16775 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
16776 (loaded_dll, pull_pid_from_list): Adjust.
16777 (add_process, remove_process, find_process_pid)
16778 (get_thread_process, current_process, initialize_inferiors): New.
16779 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
16780 (struct target_waitstatus) <related_pid>: Ditto.
16781 (struct target_ops) <kill, detach>: Add `pid' argument. Change
16782 return type to int.
16783 (struct target_ops) <join>: Add `pid' argument.
16784 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
16785 (struct target_ops) <wait>: Add `ptid' field. Change return type
16787 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
16788 (mywait): Add `ptid' argument. Change return type to ptid_t.
16789 (target_pid_to_str): Declare.
16790 * target.c (set_desired_inferior): Adjust to use ptids.
16791 (mywait): Add new `ptid' argument. Adjust.
16792 (target_pid_to_str): New.
16793 * mem-break.h (free_all_breakpoints): Declare.
16794 * mem-break.c (breakpoints): Delelete.
16795 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
16796 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
16797 to use per-process breakpoint list.
16798 (free_all_breakpoints): New.
16799 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
16800 (symbol_cache, all_symbols_looked_up): Delete.
16802 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
16804 (prepare_resume_reply): Change ptid argument's type from unsigned
16805 long to ptid_t. Adjust. Implement W;process and X;process.
16806 (free_sym_cache, clear_symbol_cache): New.
16807 (look_up_one_symbol): Adjust to per-process symbol cache. *
16808 * server.c (cont_thread, general_thread, step_thread): Change type
16810 (attached): Delete.
16811 (multi_process): New.
16812 (last_ptid): Change type to ptid_t.
16813 (struct vstop_notif) <ptid>: Change type to ptid_t.
16814 (queue_stop_reply, push_event): Change `ptid' argument's type to
16816 (discard_queued_stop_replies): Add `pid' argument.
16817 (start_inferior): Adjust to use ptids. Adjust to mywait interface
16818 changes. Don't reference the `attached' global.
16819 (attach_inferior): Adjust to mywait interface changes.
16820 (handle_query): Adjust to use ptids. Parse GDB's qSupported
16821 features. Handle and report "multiprocess+". Handle
16823 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
16825 (handle_v_kill): New.
16826 (handle_v_stopped): Adjust to use target_pid_to_str.
16827 (handle_v_requests): Allow multiple attaches and runs when
16828 multiprocess extensions are in effect. Handle "vKill".
16829 (myresume): Adjust to use ptids.
16830 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
16831 (handle_status): Adjust to discard_queued_stop_replies interface
16833 (first_thread_of, kill_inferior_callback)
16834 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
16835 (main): Call initialize_inferiors. Adjust to use ptids, killing
16836 and detaching from all inferiors. Handle multiprocess packet
16838 * linux-low.h: Include gdb_proc_service.h.
16839 (struct process_info_private): New.
16840 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
16841 <lwpid_of>: Use ptid_get_lwp.
16842 (get_lwp_thread): Adjust.
16843 (struct lwp_info): Add `dead' member.
16844 (find_lwp_pid): Declare.
16845 * linux-low.c (thread_db_active): Delete.
16846 (new_inferior): Adjust comment.
16847 (inferior_pid): Delete.
16848 (linux_add_process): New.
16849 (handle_extended_wait): Adjust.
16850 (add_lwp): Change unsigned long to ptid.
16851 (linux_create_inferior): Add process to processes table. Adjust
16852 to use ptids. Don't set new_inferior here.
16853 (linux_attach_lwp): Rename to ...
16854 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
16855 it. Adjust to use ptids.
16856 (linux_attach_lwp): New.
16857 (linux_attach): Add process to processes table. Don't set
16859 (struct counter): New.
16860 (second_thread_of_pid_p, last_thread_of_process_p): New.
16861 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
16862 multiple processes.
16863 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
16864 processes. Remove process from process table.
16865 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
16866 to multiple processes.
16867 (any_thread_of): New.
16868 (linux_detach): Add `pid' argument, and handle it. Remove process
16869 from processes table.
16870 (linux_join): Add `pid' argument. Handle it.
16871 (linux_thread_alive): Change unsighed long argument to ptid_t.
16872 Consider dead lwps as not being alive.
16873 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
16874 threads we're not interested in.
16875 (same_lwp, find_lwp_pid): New.
16876 (linux_wait_for_lwp): Change `pid' argument's type from int to
16878 (linux_wait_for_event): Rename to ...
16879 (linux_wait_for_event_1): ... this. Change `pid' argument's type
16880 from int to ptid_t. Adjust.
16881 (linux_wait_for_event): New.
16882 (linux_wait_1): Add `ptid' argument. Change return type to
16883 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
16884 that exit from the process table.
16885 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
16887 (mark_lwp_dead): New.
16888 (wait_for_sigstop): Adjust to use ptids. If a process exits while
16889 stopping all threads, mark its main lwp as dead.
16890 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
16892 (fetch_register, usr_store_inferior_registers)
16893 (regsets_fetch_inferior_registers)
16894 (regsets_store_inferior_registers, linux_read_memory)
16895 (linux_write_memory): Inline `inferior_pid'.
16896 (linux_look_up_symbols): Adjust to use per-process
16897 `thread_db_active'.
16898 (linux_request_interrupt): Adjust to use ptids.
16899 (linux_read_auxv): Inline `inferior_pid'.
16900 (initialize_low): Don't reference thread_db_active.
16901 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
16902 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
16903 (ps_getpid): Return the pid of the current inferior.
16904 * thread-db.c (proc_handle, thread_agent): Delete.
16905 (thread_db_create_event, thread_db_enable_reporting): Adjust to
16907 (find_one_thread): Change argument type to ptid_t. Adjust to
16909 (maybe_attach_thread): Adjust to per-process data and ptids.
16910 (thread_db_find_new_threads): Ditto.
16911 (thread_db_init): Ditto.
16912 * spu-low.c (spu_create_inferior, spu_attach): Add process to
16913 processes table. Adjust to use ptids.
16914 (spu_kill, spu_detach): Adjust interface. Remove process from
16916 (spu_join, spu_thread_alive): Adjust interface.
16917 (spu_wait): Adjust interface. Remove process from processes
16918 table. Adjust to use ptids.
16919 * win32-low.c (current_inferior_tid): Delete.
16920 (current_inferior_ptid): New.
16921 (debug_event_ptid): New.
16922 (thread_rec): Take a ptid. Adjust.
16923 (child_add_thread): Add `pid' argument. Adjust to use ptids.
16924 (child_delete_thread): Ditto.
16925 (do_initial_child_stuff): Add `attached' argument. Add process to
16927 (child_fetch_inferior_registers, child_store_inferior_registers):
16929 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
16930 (win32_attach): Pass 1 to do_initial_child_stuff.
16931 (win32_kill): Adjust interface. Remove process from processes
16933 (win32_detach): Ditto.
16934 (win32_join): Adjust interface.
16935 (win32_thread_alive): Take a ptid.
16936 (win32_resume): Adjust to use ptids.
16937 (get_child_debug_event): Ditto.
16938 (win32_wait): Adjust interface. Remove exiting process from
16941 2009-04-01 Pedro Alves <pedro@codesourcery.com>
16943 Non-stop mode support.
16945 * server.h (non_stop): Declare.
16946 (gdb_client_data, handler_func): Declare.
16947 (delete_file_handler, add_file_handler, start_event_loop):
16949 (handle_serial_event, handle_target_event, push_event)
16950 (putpkt_notif): Declare.
16951 * target.h (enum resume_kind): New.
16952 (struct thread_resume): Replace `step' field by `kind' field.
16953 (TARGET_WNOHANG): Define.
16954 (struct target_ops) <wait>: Add `options' argument.
16955 <supports_non_stop, async, start_non_stop>: New fields.
16956 (target_supports_non_stop, target_async): New.
16957 (start_non_stop): Declare.
16958 (mywait): Add `options' argument.
16959 * target.c (mywait): Add `options' argument. Print child exit
16960 notifications here.
16961 (start_non_stop): New.
16962 * server.c (non_stop, own_buf, mem_buf): New globals.
16963 (struct vstop_notif): New.
16964 (notif_queue): New global.
16965 (queue_stop_reply, push_event, discard_queued_stop_replies)
16966 (send_next_stop_reply): New.
16967 (start_inferior): Adjust to use resume_kind. Adjust to mywait
16969 (attach_inferior): In non-stop mode, don't wait for the target
16971 (handle_general_set): Handle QNonStop.
16972 (handle_query): When handling qC, return the current general
16973 thread, instead of the first thread of the list.
16974 (handle_query): If the backend supports non-stop mode, include
16975 QNonStop+ in the qSupported query response.
16976 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
16978 (handle_v_attach, handle_v_run): Handle non-stop mode.
16979 (handle_v_stopped): New.
16980 (handle_v_requests): Report support for vCont;t. Handle vStopped.
16981 (myresume): Adjust to use resume_kind. Handle non-stop.
16982 (queue_stop_reply_callback): New.
16983 (handle_status): Handle non-stop mode.
16984 (main): Clear non_stop flag on reconnection. Use the event-loop.
16985 Refactor serial protocol handling from here ...
16986 (process_serial_event): ... to this new function. When GDB
16987 selects any thread, select one here. In non-stop mode, wait until
16988 GDB acks all pending events before exiting.
16989 (handle_serial_event, handle_target_event): New.
16990 * remote-utils.c (remote_open): Install remote_desc in the event
16992 (remote_close): Remove remote_desc from the event loop.
16993 (putpkt_binary): Rename to...
16994 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
16995 (putpkt_binary): New as wrapper around putpkt_binary_1.
16996 (putpkt_notif): New.
16997 (prepare_resume_reply): In non-stop mode, don't change the
16999 * event-loop.c: New.
17000 * Makefile.in (OBJ): Add event-loop.o.
17001 (event-loop.o): New rule.
17003 * linux-low.h (pid_of): Moved here.
17005 (get_lwp_thread): Use lwpid_of.
17006 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
17007 * linux-low.c (pid_of): Delete.
17008 (inferior_pid): Use lwpid_of.
17009 (linux_event_pipe): New.
17010 (target_is_async_p): New.
17012 (handle_extended_wait): Use lwpid_of.
17013 (add_lwp): Don't set lwpid field.
17014 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
17015 (linux_kill_one_lwp): If killing a running lwp, stop it first.
17016 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
17017 (linux_detach_one_lwp): If detaching from a running lwp, stop it
17018 first. Adjust to linux_wait_for_event interface changes. Use
17020 (linux_detach): Don't delete the main lwp here.
17021 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
17022 (status_pending_p): Don't consider explicitly suspended lwps.
17023 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
17024 pointer. Add OPTIONS argument. Change return type to int. Use
17025 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
17026 (linux_wait_for_event): Take an integer pid instead of a lwp_info
17027 pointer. Add status pointer argument. Return a pid instead of a
17028 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
17029 changes. In non-stop mode, don't switch to a random thread.
17030 (linux_wait): Rename to...
17031 (linux_wait_1): ... this. Add target_options argument, and handle
17032 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
17033 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
17034 clean exit and signal exit code. Don't stop all threads in
17035 non-stop mode. In all-stop mode, only stop all threads when
17036 reporting a stop to GDB. Handle explicit thread stop requests.
17037 (async_file_flush, async_file_mark): New.
17039 (send_sigstop): Use lwpid_of.
17040 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
17041 interface changes. In non-stop mode, don't switch to a random
17043 (linux_resume_one_lwp): Use lwpid_of.
17044 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
17045 (linux_resume_one_thread): ... this. Handle resume_stop. In
17046 non-stop mode, don't look for pending flag in all threads.
17047 (resume_status_pending_p): Don't consider explicitly suspended
17049 (my_waitpid): Reimplement. Emulate __WALL.
17050 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
17052 (sigchld_handler, linux_supports_non_stop, linux_async)
17053 (linux_start_non_stop): New.
17054 (linux_target_ops): Register linux_supports_non_stop, linux_async
17055 and linux_start_non_stop.
17056 (initialize_low): Install SIGCHLD handler.
17057 * thread-db.c (thread_db_create_event, find_one_thread)
17058 (thread_db_get_tls_address): Use lwpid_of.
17059 * win32-low.c (win32_detach): Adjust to use resume_kind.
17060 (win32_wait): Add `options' argument.
17061 * spu-low.c (spu_resume): Adjust to use resume_kind.
17062 (spu_wait): Add `options' argument.
17064 2009-04-01 Pedro Alves <pedro@codesourcery.com>
17066 Decouple target code from remote protocol.
17068 * target.h (enum target_waitkind): New.
17069 (struct target_waitstatus): New.
17070 (struct target_ops) <wait>: Return an unsigned long. Take a
17071 target_waitstatus pointer instead of a char pointer.
17072 (mywait): Likewise.
17073 * target.c (mywait): Change prototype to return an unsigned long.
17074 Take a target_waitstatus pointer instead of a char pointer. Adjust.
17075 * server.h (thread_from_wait, old_thread_from_wait): Delete
17077 (prepare_resume_reply): Change prototype to take a
17079 * server.c (thread_from_wait, old_thread_from_wait): Delete.
17080 (last_status, last_ptid): New.
17081 (start_inferior): Remove "statusptr" argument. Adjust. Return a
17082 pid instead of a signal.
17083 (attach_inferior): Remove "status" and "signal" parameters.
17085 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
17087 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
17088 (handle_v_requests, myresume): Remove "status" and "signal"
17089 parameters. Adjust.
17090 (handle_status): New.
17091 (main): Delete local `status'. Adjust.
17092 * remote-utils.c: Include target.h.
17093 (prepare_resume_reply): Change prototype to take a
17094 target_waitstatus. Adjust.
17096 * linux-low.c (linux_wait): Adjust to new target_ops->wait
17098 * spu-low.c (spu_wait): Adjust.
17099 * win32-low.c (enum target_waitkind, struct target_waitstatus):
17101 (win32_wait): Adjust.
17103 2009-04-01 Pedro Alves <pedro@codesourcery.com>
17105 * target.h (struct thread_resume): Delete leave_stopped member.
17106 (struct target_ops): Add a `n' argument to the `resume' callback.
17107 * server.c (start_inferior): Adjust.
17108 (handle_v_cont, myresume): Adjust.
17109 * linux-low.c (check_removed_breakpoint): Adjust to resume
17110 interface change, and to removed leave_stopped field.
17111 (resume_ptr): Delete.
17112 (struct thread_resume_array): New.
17113 (linux_set_resume_request): Add new `arg' parameter. Adjust to
17114 resume interface change.
17115 (linux_continue_one_thread, linux_queue_one_thread)
17116 (resume_status_pending_p): Check if the resume field is NULL
17117 instead of checking the leave_stopped member.
17118 (linux_resume): Adjust to the target resume interface change.
17119 * spu-low.c (spu_resume): Adjust to the target resume interface
17121 * win32-low.c (win32_detach, win32_resume): Ditto.
17123 2009-04-01 Pedro Alves <pedro@codesourcery.com>
17125 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
17127 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
17129 (linux_continue_one_thread): Only preserve the stepping flag if
17130 there's a pending breakpoint.
17132 2009-03-31 Pedro Alves <pedro@codesourcery.com>
17134 * server.c (main): After the inferior having exited, call
17135 remote_close before exiting gdbserver.
17137 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
17139 Fix size of FPSCR in Power 7 processors.
17140 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
17141 (PPC_FEATURE_HAS_DFP): New #define.
17142 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
17145 2009-03-23 Pedro Alves <pedro@codesourcery.com>
17147 * server.c (handle_query) Whitespace and formatting.
17149 2009-03-22 Pedro Alves <pedro@codesourcery.com>
17151 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
17152 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
17153 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
17154 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
17155 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
17156 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
17157 Makefile.in, configure.ac: Fix whitespace throughout.
17158 * configure: Regenerate.
17160 2009-03-22 Pedro Alves <pedro@codesourcery.com>
17162 * inferiors.c (find_inferior): Make it safe for the callback
17163 function to delete the currently iterated inferior.
17165 2009-03-22 Pedro Alves <pedro@codesourcery.com>
17167 * Makefile.in (linuw_low_h): Move higher.
17168 (thread-db.o): Depend on $(linux_low_h).
17170 2009-03-17 Pedro Alves <pedro@codesourcery.com>
17172 Rename "process" to "lwp" throughout.
17174 * linux-low.c (all_processes): Rename to...
17175 (all_lwps): ... this.
17176 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
17177 (add_process): Rename to ...
17178 (add_lwp): ... this. Adjust.
17179 (linux_create_inferior): Adjust.
17180 (linux_attach_lwp): Adjust.
17181 (linux_attach): Adjust.
17182 (linux_kill_one_process): Rename to ...
17183 (linux_kill_one_lwp): ... this. Adjust.
17184 (linux_kill): Adjust.
17185 (linux_detach_one_process): Rename to ...
17186 (linux_detach_one_lwp): ... this. Adjust.
17187 (linux_detach): Adjust.
17188 (check_removed_breakpoint): Adjust.
17189 (status_pending_p): Adjust.
17190 (linux_wait_for_process): Rename to ...
17191 (linux_wait_for_lwp): ... this. Adjust.
17192 (linux_wait_for_event): Adjust.
17193 (send_sigstop): Adjust.
17194 (wait_for_sigstop): Adjust.
17195 (stop_all_processes): Rename to ...
17196 (stop_all_lwps): ... this.
17197 (linux_resume_one_process): Rename to ...
17198 (linux_resume_one_lwp): ... this. Adjust.
17199 (linux_set_resume_request, linux_continue_one_thread)
17200 (linux_queue_one_thread, resume_status_pending_p)
17201 (usr_store_inferior_registers, regsets_store_inferior_registers)
17202 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
17204 * linux-low.h (get_process): Rename to ...
17205 (get_lwp): ... this. Adjust.
17206 (get_thread_process): Rename to ...
17207 (get_thread_lwp): ... this. Adjust.
17208 (get_process_thread): Rename to ...
17209 (get_lwp_thread): ... this. Adjust.
17210 (struct process_info): Rename to ...
17211 (struct lwp_info): ... this.
17212 (all_processes): Rename to ...
17213 (all_lwps): ... this.
17214 * proc-service.c (ps_lgetregs): Adjust.
17215 * thread-db.c (thread_db_create_event, find_one_thread)
17216 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
17218 2009-03-14 Pedro Alves <pedro@codesourcery.com>
17220 * server.c (handle_query): Handle "qAttached".
17222 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
17224 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
17225 GPLv3, update license URL.
17227 2009-03-01 Doug Evans <dje@google.com>
17229 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
17230 (server_h): Add gdb_signals.h.
17231 (signals.o): Update.
17232 * server.h (target_signal_from_host,target_signal_to_host_p)
17233 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
17235 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
17237 * remote-utils.c (getpkt): Also generate remote-debug
17238 information if noack_mode is set.
17240 2009-02-06 Pedro Alves <pedro@codesourcery.com>
17242 * server.c (handle_query): Report qXfer:siginfo:read and
17243 qXfer:siginfo:write as supported and handle them.
17244 * target.h (struct target_ops) <qxfer_siginfo>: New field.
17245 * linux-low.c (linux_xfer_siginfo): New.
17246 (linux_target_ops): Set it.
17248 2009-01-26 Pedro Alves <pedro@codesourcery.com>
17250 * server.c (gdbserver_usage): Mention --remote-debug.
17251 (main): Accept '--remote-debug' switch.
17253 2009-01-18 Doug Evans <dje@google.com>
17255 * regcache.c (new_register_cache): No need to check result of xcalloc.
17256 * server.c (handle_search_memory): Back out calls to xmalloc,
17257 result is checked and error is returned to user upon failure.
17258 (handle_query): Ditto. Add more checks for result of malloc.
17259 (handle_v_cont): Check result of malloc, report error back to
17261 (handle_v_run): Ditto. Call freeargv.
17262 * server.h (freeargv): Declare.
17263 * utils.c (freeargv): New fn.
17265 2009-01-15 Doug Evans <dje@google.com>
17267 * gdbreplay.c (perror_with_name): Make arg const char *.
17268 * server.h (target_signal_to_name): Make return type const char *.
17269 * thread-db.c (thread_db_err_str): Make return type const char *.
17270 * utils.c (perror_with_name): Make arg const char *.
17272 2009-01-14 Pedro Alves <pedro@codesourcery.com>
17274 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
17275 when handling a EXIT_PROCESS_DEBUG_EVENT.
17277 2009-01-06 Joel Brobecker <brobecker@adacore.com>
17279 * gdbreplay.c (gdbreplay_version): Update copyright year.
17280 * server.c (gdbserver_version): Likewise.
17282 2009-01-05 Doug Evans <dje@google.com>
17284 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
17285 (handle_extended_wait): Improve comment.
17287 2008-12-13 Doug Evans <dje@google.com>
17289 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
17290 * server.h (ATTR_MALLOC): New macro.
17291 (xmalloc,xcalloc,xstrdup): Declare.
17292 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
17293 * inferiors.c: Ditto.
17294 * linux-low.c: Ditto.
17295 * mem-break.c: Ditto.
17296 * regcache.c: Ditto.
17297 * remote-utils.c: Ditto.
17300 * win32-low.c: Ditto.
17302 2008-12-12 Doug Evans <dje@google.com>
17304 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
17305 in debugging printf.
17307 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
17309 2008-12-09 Doug Evans <dje@google.com>
17311 * linux-low.h (struct process_info): Delete member tid, unused.
17312 * thread-db.c (find_one_thread): Update.
17313 (maybe_attach_thread): Update.
17315 2008-12-02 Pedro Alves <pedro@codesourcery.com>
17317 * target.h (struct target_ops): Add qxfer_osdata member.
17318 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
17320 (linux_qxfer_osdata): New functions.
17321 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
17323 * server.c (handle_query): Handle "qXfer:osdata:read:".
17324 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
17325 (buffer_xml_printf): New functions.
17326 * server.h (struct buffer): New.
17327 (buffer_grow_str, buffer_grow_str0): New macros.
17328 (buffer_grow, buffer_free, buffer_init, buffer_finish)
17329 (buffer_xml_printf): Declare.
17331 2008-11-24 Doug Evans <dje@google.com>
17333 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
17335 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
17337 * server.c (handle_v_run): Always use the supplied argument list.
17339 2008-11-19 Bob Wilson <bob.wilson@acm.org>
17341 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
17342 (xtensa_regmap_table): Add entry for scompare1.
17344 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
17346 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
17347 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
17348 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
17349 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
17350 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
17351 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
17352 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
17353 XML target descriptions.
17354 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
17355 when inferior is running on an ISA 2.05 or later processor. Add
17356 special case to return offset for full 64-bit slot of FPSCR when
17359 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
17361 * Makefile.in (SFILES, clean): Added sparc64 files.
17362 (reg-sparc64.o, reg-sparc64.c): New.
17363 * configure.srv (sparc*-*-linux*): New configuration.
17364 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
17365 syscall arguments for SPARC.
17366 (regsets_store_inferior_registers): Likewise.
17367 * linux-sparc-low.c: New file.
17369 2008-10-21 Doug Evans <dje@google.com>
17371 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
17372 (READLINE_DIR,READLINE_DEP): Delete.
17373 (INTERNAL_CFLAGS): Update.
17374 (LINTFLAGS): Update.
17376 2008-10-10 Pedro Alves <pedro@codesourcery.com>
17378 * server.c (handle_v_run): If GDB didn't specify an argv, use the
17379 whole argv from the last run, not just argv[0].
17381 2008-09-08 Pedro Alves <pedro@codesourcery.com>
17383 * regcache.c (new_register_cache): Return NULL if the register
17384 cache size isn't known yet.
17385 (free_register_cache): Avoid dereferencing a NULL regcache.
17387 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
17389 * configure.srv: Merge MIPS and MIPS64.
17391 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
17393 * Makefile.in (uninstall): Apply $(EXEEXT) too.
17395 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
17397 * Makefile.in: Add required vsx dependencies.
17399 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
17400 Declare init_registers_powerpc_vsx32l.
17401 Declare init_registers_powerpc_vsx64l.
17402 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
17403 (ppc_arch_setup): Check for VSX in hwcap.
17404 (ppc_fill_vsxregset): New function.
17405 (ppc_store_vsxregset): New function.
17406 Add new VSX entry in regset_info target_regsets.
17408 * configure.srv: Add new VSX dependencies.
17410 2008-08-12 Pedro Alves <pedro@codesourcery.com>
17412 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
17413 (remote_open): Set or clear transport_is_reliable.
17414 (putpkt_binary): Don't expect acks in noack mode.
17415 (getpkt): Don't send ack/nac in noack mode.
17416 * server.c (handle_general_set): Handle QStartNoAckMode.
17417 (handle_query): If connected by tcp pass QStartNoAckMode+ in
17419 (main): Reset noack_mode on every connection.
17420 * server.h (noack_mode): Declare.
17422 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
17424 * Makefile.in (GDBREPLAY_OBS): New variable.
17425 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
17427 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
17428 Daniel Jacobowitz <dan@codesourcery.com>
17430 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
17431 (usr_store_inferior_registers): Likewise.
17432 (regsets_store_inferior_registers): Likewise.
17434 2008-07-31 Rolf Jansen <rj@surtec.com>
17435 Pedro Alves <pedro@codesourcery.com>
17437 * configure.ac: Check for memmem declaration.
17438 * server.c [HAVE_MALLOC_H]: Include malloc.h.
17439 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
17440 (disable_packet_qfThreadInfo): Unconditionally compile.
17441 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
17442 * configure, config.in: Regenerate.
17444 2008-07-28 Doug Kwan <dougkwan@google.com>
17446 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
17447 (linux_write_memory): Remove declaration of errno.
17449 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
17451 * linux-low.c (handle_extended_wait): Do not use "status"
17452 variable uninitialized.
17454 2008-07-07 Pedro Alves <pedro@codesourcery.com>
17456 * server.c (handle_v_attach): Inhibit reporting dll changes.
17458 2008-06-27 Pedro Alves <pedro@codesourcery.com>
17460 * remote-utils.c (prepare_resume_reply): If requested, don't
17461 output "thread:TID" in the T stop reply.
17463 * server.c (disable_packet_vCont, disable_packet_Tthread)
17464 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
17465 (handle_query): If requested, disable support for qC, qfThreadInfo
17467 (handle_v_requests): If requested, disable support for vCont.
17468 (gdbserver_show_disableable): New.
17469 (main): Handle --disable-packet and --disable-packet=LIST.
17471 * server.h (disable_packet_vCont, disable_packet_Tthread)
17472 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
17474 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
17476 * server.c (gdbserver_usage): Mention --version.
17478 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
17480 * Makefile.in (gdbreplay.o): New rule.
17482 2008-06-06 Joseph Myers <joseph@codesourcery.com>
17484 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
17485 message, not gdbserver.
17487 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
17488 Nathan Sidwell <nathan@codesourcery.com>
17489 Joseph Myers <joseph@codesourcery.com>
17491 * acinclude.m4: Include ../../config/acx.m4.
17492 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
17493 * configure, config.in: Regenerate.
17494 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
17495 * server.c (gdbserver_version): Print PKGVERSION.
17496 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
17497 (main): Adjust gdbserver_usage calls.
17498 * gdbreplay.c (version, host_name): Add declarations.
17499 (gdbreplay_version, gdbreplay_usage): New.
17500 (main): Accept --version and --help options.
17502 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
17504 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
17505 (arm_breakpoint_at): Handle Thumb.
17506 (the_low_target): Add comment.
17508 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
17510 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
17512 2008-05-09 Doug Evans <dje@google.com>
17514 * server.h (decode_search_memory_packet): Declare.
17515 * remote-utils.c (decode_search_memory_packet): New fn.
17516 * server.c (handle_search_memory_1): New fn.
17517 (handle_search_memory): New fn.
17518 (handle_query): Process qSearch:memory packets.
17520 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
17522 * regcache.c (registers_length): Remove.
17523 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
17524 full register packet.
17525 * regcache.h (registers_length): Remove prototype.
17526 * server.h (PBUFSIZ): Define to 16384.
17528 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
17530 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
17531 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
17532 powerpc-64l.o, and powerpc-altivec64l.o.
17533 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
17534 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
17535 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
17536 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
17537 rs6000/power-linux.xml, and rs6000/power64-linux.xml
17540 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
17541 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
17542 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
17543 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
17544 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
17545 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
17546 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
17547 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
17548 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
17549 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
17552 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
17553 (init_registers_powerpc_32l): ... this new prototype.
17554 (init_registers_powerpc_32): Remove, replace by ...
17555 (init_registers_powerpc_altivec32l): ... this new prototype.
17556 (init_registers_powerpc_e500): Remove, replace by ...
17557 (init_registers_powerpc_e500l): ... this new prototype.
17558 (init_registers_ppc64): Remove, replace by ...
17559 (init_registers_powerpc_64l): ... this new prototype.
17560 (init_registers_powerpc_64): Remove, replace by ...
17561 (init_registers_powerpc_altivec64l): ... this new prototype.
17562 (ppc_num_regs): Set to 73.
17563 (PT_ORIG_R3, PT_TRAP): Define if necessary.
17564 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
17565 (ppc_cannot_store_register): Handle orig_r3 and trap.
17566 (ppc_arch_setup): Update init_registers_... calls.
17567 (ppc_fill_gregset): Handle orig_r3 and trap.
17569 * inferiors.c (clear_inferiors): Reset current_inferior.
17571 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
17573 * acinclude.m4: Add override.m4.
17574 * configure: Regenerate.
17576 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
17578 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
17579 initial call to init_register_ppc64.
17581 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
17583 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
17584 single powerpc*-*-linux* case.
17585 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
17587 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
17589 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
17590 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
17592 * linux-ppc-low.c: Include <elf.h>.
17593 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
17594 (ppc_hwcap): New global variable.
17595 (ppc_regmap): Remove __SPE__ #ifdef sections.
17596 (ppc_regmap_e500): New global variable.
17597 (ppc_cannot_store_register): Update __SPE__ special case.
17598 (ppc_get_hwcap): New function.
17599 (ppc_arch_setup): Use it to determine whether inferior supports
17600 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
17601 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
17602 Do not access registers if target does not support AltiVec.
17603 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
17604 Do not access registers if target does not support SPE.
17605 (target_regsets): Unconditionally include AltiVec and SPE regsets.
17607 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
17609 * linux-low.c (disabled_regsets, num_regsets): New.
17610 (use_regsets_p): Delete.
17611 (linux_wait_for_process): Clear disabled_regsets.
17612 (regsets_fetch_inferior_registers): Check and set it.
17613 (regsets_store_inferior_registers): Likewise.
17614 (linux_fetch_registers, linux_store_registers): Do not use
17616 (initialize_low): Allocate disabled_regsets.
17618 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
17620 * Makefile.in (LIBOBJS): New.
17621 (OBS): Use LIBOBJS.
17622 (memmem.o): New rule.
17623 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
17624 * configure: Regenerated.
17626 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
17628 * server.c (handle_query): Never return "unsupported" for
17629 qXfer:features:read queries.
17631 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
17633 * server.c (get_features_xml): Fix inverted condition.
17634 (handle_query): Always support qXfer:feature:read.
17636 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
17638 * server.c (wrapper_argv): New.
17639 (start_inferior): Handle wrapper_argv. If set, expect an extra
17641 (gdbserver_usage): Document --wrapper.
17642 (main): Parse --wrapper.
17644 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
17646 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
17647 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
17648 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
17649 (ppc_set_pc): Likewise.
17650 (ppc_arch_setup): New function.
17651 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
17652 of collect_register.
17653 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
17655 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
17657 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
17658 instead of linux-ppc64-low.o.
17659 * linux-ppc64-low.c: Remove file.
17660 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
17661 (linux-ppc64-low.o): Remove rule.
17663 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
17664 (init_registers_powerpc_64): Likewise.
17665 (ppc_regmap): Conditionally define depending on __powerpc64__.
17666 (ppc_cannot_store_register): Do not special-case "fpscr" when
17667 compiled on __powerpc64__.
17668 (ppc_collect_ptrace_register): New function.
17669 (ppc_supply_ptrace_register): New function.
17670 (ppc_breakpoint): Change type to "unsigned int".
17671 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
17672 (the_low_target): Conditionally provide initializers for the
17673 arch_setup member depending on __powerpc64__. Install
17674 collect_ptrace_register and supply_ptrace_register members.
17676 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
17678 * regcache.h (gdbserver_xmltarget): Add extern declaration.
17679 * server.c (gdbserver_xmltarget): Define.
17680 (get_features_xml): Use it to replace "target.xml" and arch_string.
17682 * configure.srv: Remove srv_xmltarget. Add XML files that were
17683 mentioned there to srv_xmlfiles instead. Remove conditional tests
17684 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
17685 srv_xmlfiles and srv_regobj to include all possible choices.
17686 * configure.ac (srv_xmltarget): Remove.
17687 (srv_xmlfiles): Do not add "target.xml".
17688 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
17689 checks for supplementary target information.
17690 * configure: Regenerate.
17691 * Makefile.in (XML_TARGET): Remove.
17692 (target.xml): Remove rule.
17693 (clean): Do not clean up target.xml.
17694 (.PRECIOUS): Do not mention target.xml.
17696 * target.h (struct target_ops): Remove arch_string member.
17697 * linux-low.c (linux_arch_string): Remove.
17698 (linux_target_ops): Remove arch_string initializer.
17699 * linux-low.h (struct linux_target_ops): Remove arch_string member.
17700 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
17701 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
17702 * spu-low.c (spu_arch_string): Remove.
17703 (spu_target_ops): Remove arch_string initializer.
17704 * win32-low.c (win32_arch_string): Remove.
17705 (win32_target_ops): Remove arch_string initializer.
17706 * win32-low.h (struct win32_target_ops): Remove arch_string member.
17707 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
17708 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
17710 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
17712 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
17713 by collect_ptrace_register and supply_ptrace_register hooks.
17714 * linux-low.c (fetch_register): Use supply_ptrace_register callback
17715 instead of checking for the_low_target.left_pad_xfer.
17716 (usr_store_inferior_registers): Use collect_ptrace_register callback
17717 instead of checking for the_low_target.left_pad_xfer.
17719 * linux-s390-low.c (s390_collect_ptrace_register): New function.
17720 (s390_supply_ptrace_register): Likewise.
17721 (s390_fill_gregset): Call s390_collect_ptrace_register.
17722 (the_low_target): Update.
17724 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
17725 (ppc_supply_ptrace_register): Likewise.
17726 (the_low_target): Update.
17728 * linux-i386-low.c (the_low_target): Update.
17729 * linux-x86-64-low.c (the_low_target): Update.
17731 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
17733 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
17734 reg-s390.o and reg-s390x.o.
17736 * linux-low.c (new_inferior): New global variable.
17737 (linux_create_inferior, linux_attach): Set it.
17738 (linux_wait_for_process): Call the_low_target.arch_setup after the
17739 target has stopped for the first time.
17740 (initialize_low): Do not call the_low_target.arch_setup.
17742 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
17743 (s390_set_pc): Likewise.
17744 (s390_arch_setup): New function.
17745 (the_low_target): Use s390_arch_setup as arch_setup routine.
17747 * regcache.c (realloc_register_cache): New function.
17748 (set_register_cache): Call it for each existing regcache.
17750 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
17752 * server.h (init_registers): Remove prototype.
17754 * linux-low.h (struct linux_target_ops): Add arch_setup field.
17755 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
17756 instead of init_registers ().
17757 * linux-arm-low.c (init_registers_arm): Add prototype.
17758 (init_registers_arm_with_iwmmxt): Likewise.
17759 (the_low_target): Add initializer for arch_setup field.
17760 * linux-cris-low.c (init_registers_cris): Add prototype.
17761 (the_low_target): Add initializer for arch_setup field.
17762 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
17763 (the_low_target): Add initializer for arch_setup field.
17764 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
17765 (the_low_target): Add initializer for arch_setup field.
17766 * linux-ia64-low.c (init_registers_ia64): Add prototype.
17767 (the_low_target): Add initializer for arch_setup field.
17768 * linux-m32r-low.c (init_registers_m32r): Add prototype.
17769 (the_low_target): Add initializer for arch_setup field.
17770 * linux-m68k-low.c (init_registers_m68k): Add prototype.
17771 (the_low_target): Add initializer for arch_setup field.
17772 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
17773 (init_registers_mips64_linux): Likewise.
17774 (the_low_target): Add initializer for arch_setup field.
17775 * linux-ppc-low.c (init_registers_ppc): Add prototype.
17776 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
17777 (the_low_target): Add initializer for arch_setup field.
17778 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
17779 (init_registers_powerpc_64): Likewise.
17780 (the_low_target): Add initializer for arch_setup field.
17781 * linux-s390-low.c (init_registers_s390): Add prototype.
17782 (init_registers_s390x): Likewise.
17783 (the_low_target): Add initializer for arch_setup field.
17784 * linux-sh-low.c (init_registers_sh): Add prototype.
17785 (the_low_target): Add initializer for arch_setup field.
17786 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
17787 (the_low_target): Add initializer for arch_setup field.
17788 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
17789 (the_low_target): Add initializer for arch_setup field.
17791 * win32-low.h (struct win32_target_ops): Add arch_setup field.
17792 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
17793 instead of init_registers ().
17794 * win32-arm-low.c (init_registers_arm): Add prototype.
17795 (the_low_target): Add initializer for arch_setup field.
17796 * win32-i386-low.c (init_registers_i386): Add prototype.
17797 (the_low_target): Add initializer for arch_setup field.
17799 * spu-low.c (init_registers_spu): Add prototype.
17800 (initialize_low): Call initialie_registers_spu () instead of
17801 initialize_registers ().
17803 2008-02-19 Pedro Alves <pedro@codesourcery.com>
17805 * server.c (handle_v_requests): When handling the vRun and vAttach
17806 packets, if already debugging a process, don't kill it. Return an
17809 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
17811 * server.c (handle_query): Correct length check.
17813 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
17815 * win32-low.c (do_initial_child_stuff): Add process handle
17816 parameter. Set current_process_handle and current_process_id from the
17817 parameters. Clear globals.
17818 (win32_create_inferior): Don't set current_process_handle and
17819 current_process_id here. Instead pass them on the call to
17820 do_initial_child_stuff.
17821 (win32_attach): Likewise.
17822 (win32_clear_inferiors): New.
17823 (win32_kill): Don't close the current process handle or the
17824 current thread handle here. Instead call win32_clear_inferiors.
17825 (win32_detach): Don't open a new handle to the process. Call
17826 win32_clear_inferiors.
17827 (win32_join): Don't rely on current_process_handle; open a new
17828 handle using the process id.
17829 (win32_wait): Call win32_clear_inferiors when the inferior process
17832 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
17834 * server.c (monitor_show_help): Add "exit".
17836 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
17838 * Makefile.in (SFILES): Add linux-xtensa-low.c.
17839 (clean): Add reg-xtensa.c.
17840 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
17841 * configure.srv (xtensa*-*-linux*) New target.
17842 * linux-xtensa-low.c: New.
17843 * xtensa-xtregs.c: New.
17845 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
17847 * hostio.c: Don't include errno.h.
17848 (errno_to_fileio_errno): Move to hostio-errno.
17849 * hostio.c: (hostio_error): Remove the error parameter. Defer the
17850 error number outputting to the target->hostio_last_error callback.
17851 (hostio_packet_error): Use FILEIO_EINVAL directly.
17852 (handle_open, handle_pread, hostio_error, handle_unlink): Update
17853 calls to hostio_error.
17854 * hostio-errno.c: New.
17855 * server.h (hostio_last_error_from_errno): Declare.
17856 * target.h (target_ops): Add hostio_last_error member.
17857 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
17858 as hostio_last_error handler.
17859 * spu-low.c (spu_target_ops): Likewise.
17860 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
17861 (wince_hostio_last_error): New functions.
17862 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
17863 as hostio_last_error handler.
17864 (win32_target_ops) [!_WIN32_WCE]: Register
17865 hostio_last_error_from_errno as hostio_last_error handler.
17866 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
17867 (hostio-errno.o): New rule.
17868 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
17869 * configure.srv (srv_hostio_err_objs): New variable. Default to
17871 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
17872 * configure: Regenerate.
17874 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
17876 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
17877 (linux_kill, linux_detach): Clean up the process list.
17878 * remote-utils.c (remote_open): Improve port number parsing.
17879 (putpkt_binary, input_interrupt): Only send interrupts if the target
17881 * server.c (extended_protocol): Make static.
17882 (attached): Define earlier.
17883 (exit_requested, response_needed, program_argv): New variables.
17884 (target_running): New.
17885 (start_inferior): Clear attached here.
17886 (attach_inferior): Set attached here.
17887 (require_running): Define.
17888 (handle_query): Use require_running and target_running. Implement
17890 (handle_v_attach, handle_v_run): New.
17891 (handle_v_requests): Use require_running. Handle vAttach and vRun.
17892 (gdbserver_usage): Update.
17893 (main): Redo argument parsing. Handle --debug and --multi. Handle
17894 --attach along with other options or after the port. Save
17895 program_argv. Support no initial program. Resynchronize
17896 communication with GDB after an error. Handle "monitor exit".
17897 Use require_running and target_running. Always allow the extended
17898 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
17899 restart in extended mode.
17900 * README: Refer to the GDB manual. Update --attach usage.
17902 2007-12-20 Andreas Schwab <schwab@suse.de>
17904 * linux-low.c (STACK_SIZE): Define.
17905 (linux_tracefork_child): Use it. Use __clone2 on ia64.
17906 (linux_test_for_tracefork): Likewise.
17908 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
17910 * linux-low.c (linux_wait_for_event): Update messages. Do not
17911 reinsert auto-delete breakpoints.
17912 * mem-break.c (struct breakpoint): Change return type of handler to
17914 (set_breakpoint_at): Update handler type.
17915 (reinsert_breakpoint_handler): Return 1 instead of calling
17917 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
17919 (check_breakpoints): Delete auto-delete breakpoints and return 2.
17920 * mem-break.h (set_breakpoint_at): Update handler type.
17921 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
17922 * win32-low.c (auto_delete_breakpoint): New.
17923 (get_child_debug_event): Use it.
17925 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
17927 * configure.ac: Check for pread and pwrite.
17928 * hostio.c (handle_pread): Fall back to lseek and read.
17929 (handle_pwrite): Fall back to lseek and write.
17930 * config.in, configure: Regenerated.
17932 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
17934 * server.c (myresume): Add own_buf argument.
17935 (main): Update calls.
17937 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
17939 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
17940 * remote-utils.c (remote_open): Do not call disable_async_io.
17941 (block_async_io): Delete.
17942 (unblock_async_io): Make static.
17943 (initialize_async_io): New.
17944 * server.c (handle_v_cont): Handle async I/O here.
17945 (myresume): Likewise. Move other common resume tasks here...
17946 (main): ... from here. Call initialize_async_io. Disable async
17947 I/O before the main loop.
17948 * server.h (initialize_async_io): Declare.
17949 (block_async_io, unblock_async_io): Delete prototypes.
17950 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
17952 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
17954 * remote-utils.c (readchar): Allow binary data in received messages.
17956 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17958 * win32-low.c (attaching): New global.
17959 (win32_create_inferior): Clear the `attaching' global.
17960 (win32_attach): Set the `attaching' global.
17961 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
17962 attaching. Only set a breakpoint at the entry point if not
17965 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17967 * server.c (main): Don't report dll events on the initial
17968 connection on attaches.
17970 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17972 * server.c (main): Relax numerical bases supported for the pid of
17973 the --attach command line argument.
17975 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17977 * win32-low.c (win32_attach): Call OpenProcess before
17978 DebugActiveProcess, not after. Add last error output to error
17981 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17983 * win32-low.c (win32_get_thread_context)
17984 (win32_set_thread_context): New functions.
17985 (thread_rec): Use win32_get_thread_context.
17986 (continue_one_thread, win32_resume): Use win32_set_thread_context.
17987 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
17990 2007-12-03 Leo Zayas
17991 Pedro Alves <pedro_alves@portugalmail.pt>
17993 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
17995 (child_add_thread): Minor cleanup.
17996 (child_continue): Resume artificially suspended threads before
17997 calling ContinueDebugEvent.
17998 (suspend_one_thread): New.
17999 (fake_breakpoint_event): New.
18000 (get_child_debug_event): Change return type to int. Check here if
18001 gdb sent an interrupt request. If a soft interrupt was requested,
18002 fake a breakpoint event. Return 0 if there is no event to handle,
18004 (win32_wait): Don't check here if gdb sent an interrupt request.
18005 Ensure there is a valid event to handle.
18006 (win32_request_interrupt): Add soft interruption method as last
18009 2007-12-03 Leo Zayas
18010 Pedro Alves <pedro_alves@portugalmail.pt>
18012 * win32-low.h (win32_thread_info): Add descriptions to the
18013 structure members. Replace `suspend_count' counter by a
18015 * win32-low.c (thread_rec): Update condition of when to get the
18016 context from the inferior. Rely on ContextFlags being set if it
18017 has already been retrieved. Only suspend the inferior thread if
18018 we haven't already. Warn if that fails.
18019 (continue_one_thread): s/suspend_count/suspended/. Only call
18020 ResumeThread once. Warn if that fails.
18022 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
18024 * win32-low.c (win32_wait): Don't read from the inferior when it
18025 has already exited.
18027 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
18029 * Makefile.in (win32_low_h): New variable.
18030 (win32-low.o): Add dependency on $(win32_low_h).
18031 (win32-arm-low.o, win32-i386-low.o): New rules.
18033 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
18035 * hostio.c: Correct copyright year.
18037 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
18039 * Makefile.in (OBS): Add hostio.o.
18040 (hostio.o): New rule.
18041 * server.h (handle_vFile): Declare.
18042 * hostio.c: New file.
18043 * server.c (handle_v_requests): Take packet_len and new_packet_len
18044 for binary packets. Call handle_vFile.
18045 (main): Update call to handle_v_requests.
18047 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
18049 * linux-low.c: Include <sched.h>.
18051 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
18053 * linux-low.c (linux_tracefork_grandchild): New.
18054 (linux_tracefork_child): Use clone.
18055 (linux_test_for_tracefork): Use clone; allocate and free a stack.
18057 2007-10-31 Joel Brobecker <brobecker@adacore.com>
18059 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
18061 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
18063 * linux-low.c (handle_extended_wait): Handle unexpected signals.
18065 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
18067 * inferiors.c (change_inferior_id): Delete.
18068 (add_pid_to_list, pull_pid_from_list): New.
18069 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
18070 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
18071 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
18072 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
18073 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
18074 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
18075 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
18076 (using_threads): Always set to 1.
18077 (handle_extended_wait): New.
18078 (add_process): Do not set TID.
18079 (linux_create_inferior): Set must_set_ptrace_flags.
18080 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
18081 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
18082 (linux_thread_alive): Rename TID argument to LWPID.
18083 (linux_wait_for_process): Handle unknown processes. Do not use TID.
18084 (linux_wait_for_event): Do not use TID or check using_threads. Update
18085 call to dead_thread_notify. Call handle_extended_wait.
18086 (linux_create_inferior): Use PTRACE_SETOPTIONS.
18087 (send_sigstop): Delete sigstop_sent.
18088 (wait_for_sigstop): Avoid TID.
18089 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
18090 (linux_test_for_tracefork): New.
18091 (linux_lookup_signals): Use thread_db_active and
18092 linux_supports_tracefork_flag.
18093 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
18094 * linux-low.h (get_process_thread): Avoid TID.
18095 (struct process_ifo): Move thread_known and tid to the end. Remove
18097 (linux_attach_lwp, thread_db_init): Update prototypes.
18098 * server.h (change_inferior_id): Delete prototype.
18099 (add_pid_to_list, pull_pid_from_list): New prototypes.
18100 * thread-db.c (thread_db_use_events): New.
18101 (find_first_thread): Rename to...
18102 (find_one_thread): ...this. Update callers and messages. Do not
18103 call fatal. Check thread_db_use_events. Do not call
18104 change_inferior_id or new_thread_notify.
18105 (maybe_attach_thread): Update. Do not call new_thread_notify.
18106 (thread_db_init): Set thread_db_use_events. Check use_events.
18107 * utils.c (fatal, warning): Correct message prefix.
18109 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
18111 * Makefile.in (clean): Remove new files.
18112 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
18113 (powerpc-64.o, powerpc-64.c): New rules.
18114 * configure.srv: Use alternate register sets for powerpc64-*-linux*
18115 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
18117 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
18119 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
18120 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
18121 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
18122 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
18123 (target_regsets): Add AltiVec and SPE register sets.
18124 * configure.ac: Check for AltiVec and SPE.
18125 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
18126 (ppc_fill_vrregset, ppc_store_vrregset): New.
18127 (target_regsets): Add AltiVec register set.
18128 * configure: Regenerated.
18130 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
18132 * linux-low.c (O_LARGEFILE): Define.
18133 (linux_read_memory): Use /proc/PID/mem.
18134 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
18135 * configure, config.in: Regenerated.
18137 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
18139 * linux-low.c (linux_wait_for_event): Do not pass signals while
18142 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
18144 * win32-low.c (create_process): New.
18145 (win32_create_inferior): Use create_process instead of
18146 CreateProcess. If create_process failed retry appending an ".exe"
18147 suffix. Store the GetLastError result immediatelly after
18148 create_process calls and use it on the call to error.
18150 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
18152 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
18154 2007-08-23 Joel Brobecker <brobecker@adacore.com>
18156 * configure.ac: Switch license to GPLv3.
18158 2007-08-01 Michael Snyder <msnyder@access-company.com>
18160 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
18162 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
18164 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
18166 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
18167 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
18168 CloseToolhelp32Snapshot.
18169 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
18170 CloseToolhelp32Snapshot.
18172 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
18174 * server.c (main): Check for inferior exit before main loop.
18176 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
18178 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
18179 instead of on tmp_desc.
18181 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
18182 Daniel Jacobowitz <dan@codesourcery.com>
18184 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
18185 (add_thread): Minor cleanups.
18186 (clear_inferiors): Move lower in the file. Clear the DLL
18188 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
18189 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
18190 (xml_escape_text): New.
18191 * server.c (handle_query): Handle qXfer:libraries:read. Report it
18193 (handle_v_cont): Report errors.
18194 (gdbserver_version): Update.
18195 (main): Correct size of own_buf. Do not report initial DLL events.
18196 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
18197 (unloaded_dll, xml_escape_text): New.
18198 * win32-low.c (enum target_waitkind): Update comments.
18199 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
18200 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
18201 (win32_EnumProcessModules, win32_GetModuleInformation)
18202 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
18203 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
18204 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
18205 (win32_Module32First, win32_Module32Next, load_toolhelp)
18206 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
18207 (get_child_debug_event): Handle DLL events.
18208 (win32_wait): Likewise.
18210 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
18212 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
18213 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
18215 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
18217 * win32-low.c (handle_output_debug_string): Ignore event if not
18220 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
18222 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
18224 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
18226 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
18228 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
18230 * inferiors.c (change_inferior_id): Add comment.
18231 * linux-low.c (check_removed_breakpoint): Add an early
18232 prototype. Improve debug output.
18233 (linux_attach): Doc update.
18234 (linux_detach_one_process, linux_detach): Clean up before releasing
18236 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
18237 * linux-low.h (struct process_info): Doc improvement.
18238 * mem-break.c (delete_all_breakpoints): New.
18239 * mem-break.h (delete_all_breakpoints): New prototype.
18240 * thread-db.c (find_first_thread): New.
18241 (thread_db_create_event): Call it instead of
18242 thread_db_find_new_threads. Clean up unused variables.
18243 (maybe_attach_thread): Remove first thread handling.
18244 (thread_db_find_new_threads): Use find_first_thread.
18245 (thread_db_get_tls_address): Likewise.
18247 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
18249 * thread-db.c (thread_db_find_new_threads): Add prototype.
18250 (thread_db_create_event): Check for the main thread before adding
18252 (maybe_attach_thread): Only enable event reporting if TID == 0.
18253 (thread_db_get_tls_address): Check for new threads.
18255 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
18257 * linux-low.c (linux_create_inferior): Try execv before execvp.
18258 * spu-low.c (spu_create_inferior): Likewise.
18260 2007-06-13 Mike Frysinger <vapier@gentoo.org>
18262 * linux-low.c (linux_create_inferior): Change execv to execvp.
18263 * spu-low.c (spu_create_inferior): Likewies.
18265 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
18267 * Makefile.in (clean): Clean new files instead of deleted ones.
18268 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
18269 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
18271 * configure.srv: Specify XML files and new regformats for MIPS and
18273 * linux-mips-low.c (mips_num_regs): Set to only used registers.
18274 (mips_regmap): Do not fetch $0. Remove unused registers. Add
18275 an entry for the restart register.
18276 (mips_cannot_fetch_register, mips_cannot_store_register)
18277 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
18278 register names to match the XML descriptions.
18279 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
18280 restart register instead of $0.
18282 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
18283 Markus Deuling <deuling@de.ibm.com>
18285 * remote-utils.c (decode_xfer_write): New function.
18286 * server.h (decode_xfer_write): Add prototype.
18287 * server.c (handle_query): Add PACKET_LEN argument. Support
18288 qXfer:spu:read and qXfer:spu:write packets.
18289 (main): Pass packet_len to handle_query.
18290 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
18291 * target.h (target_ops): Add qxfer_spu.
18293 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
18295 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
18296 accessing non-seekable spufs files.
18298 2007-05-16 Markus Deuling <deuling@de.ibm.com>
18300 * server.c (handle_query): Add reply for qC packet.
18302 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18303 Leo Zayas <lerele@champenstudios@com>
18305 * server.h (check_remote_input_interrupt_request): New function.
18306 * remote_utils.c (INVALID_DESCRIPTOR): New define.
18307 (remote_desc): Initialize with INVALID_DESCRIPTOR.
18308 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
18309 (check_remote_input_interrupt_request): New function.
18310 * server.h (check_remote_input_interrupt_request): Declare.
18311 * win32-low.c (winapi_DebugBreakProcess,
18312 winapi_GenerateConsoleCtrlEvent): New typedefs.
18313 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
18315 (win32_wait): Check for remote interrupt request
18316 with check_remote_input_interrupt_request.
18317 (win32_request_interrupt): New function.
18318 (win32_target_op): Set request_interrupt to win32_request_interrupt.
18320 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18322 * win32-low.c (debug_registers_changed,
18323 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
18324 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
18325 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
18326 (thread_rec): Get context using the low target.
18327 (child_add_thread): Call thread_added on the low target,
18328 which does the same thing.
18330 (do_initial_child_stuff): Remove debug registers references.
18331 Set context using the low target. Resume threads after
18332 setting the contexts.
18333 (child_continue): Remove dead variable. Remove debug
18334 registers references.
18335 (child_fetch_inferior_registers): Go through the low target.
18336 (do_child_store_inferior_registers): Remove.
18337 (child_store_inferior_registers): Go through the low target.
18338 (win32_resume): Remove debug registers references.
18339 Set context using the low target.
18340 (handle_exception): Change return type to void. Don't record
18341 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
18342 first chance exception.
18343 (get_child_debug_event): Change return type to void. Remove
18344 goto loop. Always return after waiting for debug event.
18345 (win32_wait): Convert to switch statement. Handle spurious
18348 * win32-i386-low.c (debug_registers_changed,
18349 debug_registers_used): New.
18350 (initial_stuff): Rename to ...
18351 (i386_initial_stuff): ... this. Clear debug registers
18353 (store_debug_registers): Delete.
18354 (i386_get_thread_context): New.
18355 (load_debug_registers): Delete.
18356 (i386_set_thread_context): New.
18357 (i386_thread_added): New.
18358 (single_step): Rename to ...
18359 (i386_single_step): ... this.
18360 (do_fetch_inferior_registers): Rename to ...
18361 (i386_fetch_inferior_register): ... this.
18362 (i386_store_inferior_register): New.
18363 (the_low_target): Adapt to new interface.
18365 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
18366 (arm_get_thread_context): New.
18367 (arm_set_thread_context): New.
18369 (do_fetch_inferior_registers): Rename to ...
18370 (arm_fetch_inferior_register): ... this.
18371 (arm_store_inferior_register): New.
18372 (arm_wince_breakpoint): Reimplement as unsigned long.
18373 (arm_wince_breakpoint_len): Define.
18374 (the_low_target): Adapt to new interface.
18376 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
18377 load_debug_registers. Add get_thread_context, set_thread_context,
18378 thread_added and store_inferior_register. Rename
18379 fetch_inferior_registers to fetch_inferior_register.
18380 (regptr): Remove declaration.
18382 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18384 * linux-low.c (linux_detach): Change return type to int. Return 0.
18385 * spu-low.c (spu_detach): Likewise.
18387 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18389 * target.h (target_ops): Change return type of detach to int.
18391 (join_inferior): New.
18392 * server.c (main): Don't skip detach support on mingw32.
18393 If the inferior doesn't support detaching return error.
18394 Call join_inferior instead of using waitpid.
18395 * linux-low.c (linux_join): New.
18396 (linux_target_op): Add linux_join.
18397 * spu-low.c (spu_join): New.
18398 (spu_target_ops): Add spu_join.
18399 * win32-low.c (win32_detach): Adapt to new interface.
18400 Reopen current_process_handle before detaching. Issue a child
18401 resume before detaching.
18403 (win32_target_op): Add win32_join.
18405 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18407 * win32-low.c (win32-attach): Fix return value.
18408 * target.h (target_ops): Describe ATTACH return values.
18410 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18412 * win32-low.c (GETPROCADDRESS): Define.
18413 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
18414 (winapi_DebugSetProcessKillOnExit): Likewise.
18415 (win32_create_inferior): Force usage of ansi CreateProcessA.
18416 (win32_attach): Use GETPROCADDRESS.
18417 (win32_detach): Likewise.
18419 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18421 * win32-low.c (win32_wait): Don't use WSTOPSIG.
18423 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
18425 * win32-low.c: Commit leftover changes from 2007-03-29.
18427 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
18429 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
18430 fields short instead of int. Add explicit padding.
18431 (i387_cache_to_fsave): Remove unnecessary casts.
18432 (i387_fsave_to_cache): Doc fix.
18433 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
18435 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
18437 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
18438 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
18440 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
18442 * configure.srv (arm*-*-mingw32ce*): Move near the other
18445 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
18447 * configure.ac: Add errno checking.
18448 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
18449 sys/file.h and malloc.h.
18450 (AC_CHECK_DECLS): Add perror.
18451 (srv_mingwce): Handle.
18452 * configure.srv (i[34567]86-*-cygwin*): Add
18453 win32-i386-low.o to srv_tgtobj.
18454 (i[34567]86-*-mingw*): Likewise.
18455 (arm*-*-mingw32ce*): Add case.
18456 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
18457 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
18458 [__MINGW32CE__] (strerror): New function.
18459 [__MINGW32CE__] (errno): Define to GetLastError.
18460 [__MINGW32CE__] (COUNTOF): New macro.
18461 (remote_open): Remove extra close call.
18462 * mem-break.c (delete_breakpoint_at): New function.
18463 * mem-break.h (delete_breakpoint_at): Declare.
18464 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
18465 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
18466 [USE_WIN32API] (read, write): Add char* casts.
18467 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
18468 * server.h: Include wincecompat.h on Windows CE.
18469 [HAVE_ERRNO_H]: Check.
18470 (perror): Declare if not declared.
18471 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
18472 (perror_with_name): Remove errno declaration.
18473 * wincecompat.h: New.
18474 * wincecompat.c: New.
18475 * win32-low.h: New.
18476 * win32-arm-low.c: New.
18477 * win32-i386-low.c: New.
18478 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
18479 (OUTMSG2): Make it safe.
18481 (COUNTOF): New macro.
18482 (NUM_REGS): Get it from the low target.
18483 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
18484 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
18485 (thread_rec): Let low target handle debug registers.
18486 (child_add_thread): Likewise.
18487 (child_init_thread_list): Likewise.
18488 (continue_one_thread): Likewise.
18490 (do_child_fetch_inferior_registers): Move to ...
18491 * win32-i386-low.c: ... here, and rename to ...
18492 (do_fetch_inferior_registers): ... this.
18493 * win32-low.c (child_fetch_inferior_registers):
18494 Go through the low target.
18495 (do_child_store_inferior_registers): Use regptr.
18496 (strwinerror): New function.
18497 (win32_create_inferior): Handle Windows CE.
18498 Use strwinerror instead of strerror on Windows error
18499 codes. Add program to the error output.
18500 Don't close the main thread handle on Windows CE.
18501 (win32_attach): Use coredll.dll on Windows CE.
18502 (win32_kill): Close current process and current
18504 (win32_detach): Use coredll.dll on Windows CE.
18505 (win32_resume): Let low target handle debug registers, and
18507 (handle_exception): Add/Remove initial breakpoint. Avoid
18508 non-existant WSTOPSIG on Windows CE.
18509 (win32_read_inferior_memory): Cast to remove warning.
18510 (win32_arch_string): Go through the low target.
18511 (initialize_low): Call set_breakpoint_data with the low
18512 target's breakpoint.
18513 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
18514 FOP_REGNUM, mappings): Move to ...
18515 * win32-i386-low.c: ... here.
18516 * win32-low.c (win32_thread_info): Move to ...
18517 * win32-low.h: ... here.
18518 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
18519 win32-arm-low.c and wincecompat.c.
18520 (all:): Add $EXEEXT.
18521 (install-only:): Likewise.
18522 (gdbserver:): Likewise.
18523 (gdbreplay:): Likewise.
18524 * config.in: Regenerate.
18525 * configure: Regenerate.
18527 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
18529 * win32-low.c: Rename typedef thread_info to
18530 win32_thread_info throughout.
18532 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
18534 * win32-i386-low.c: Rename to ...
18535 * win32-low.c: ... this.
18536 * configure.srv: Replace win32-i386-low.o with win32-low.o.
18537 * Makefile.in: Likewise.
18539 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
18541 * remote-utils.c (monitor_output): Constify msg parameter.
18542 * server.h (monitor_output): Likewise.
18543 * win32-i386-low.c (handle_output_debug_string): New.
18544 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
18545 handle_output_debug_string.
18546 (get_child_debug_event): Likewise.
18548 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
18550 * server.c (main): Correct strtoul check.
18552 2007-03-27 Jon Ringle <jon@ringle.org>
18554 * linux-low.c: Check __ARCH_HAS_MMU__ also.
18556 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
18558 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
18560 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
18562 * terminal.h: Check HAVE_SGTTY_H.
18564 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
18566 * remote-utils.c (remote_open): Print out the assigned port number.
18568 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
18570 * remote-utils.c (monitor_output): New function.
18571 * server.c (debug_threads): Define here.
18572 (monitor_show_help): New function.
18573 (handle_query): Handle qRcmd.
18574 (main): Do not handle 'd' packet.
18575 * server.h (debug_threads, remote_debug, monitor_output): Declare.
18576 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
18579 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
18581 * Makefile.in (EXEEXT): New.
18582 (clean): Use $(EXEEXT).
18584 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
18586 * target.h (target_ops): Rename send_signal to request_interrupt,
18587 and remove enum target_signal parameter.
18588 * linux-low.c (linux_request_interrupt): Rename from
18589 linux_send_signal, and always send SIGINT.
18590 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
18591 and always send SIGINT.
18592 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
18594 (input_interrupt): Likewise.
18596 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
18598 * server.c (get_features_xml): Check if target implemented
18600 * win32-i386-low.c (win32_arch_string): New.
18601 (win32_target_ops): Add win32_arch_string as arch_string member.
18603 2007-02-22 Markus Deuling <deuling@de.ibm.com>
18605 * spu-low.c (spu_arch_string): New.
18606 (spu_target_ops): Add spu_arch_string.
18608 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
18610 * remote-utils.c: Remove HAVE_TERMINAL_H check.
18611 * configure.ac: Do not check for terminal.h.
18612 * configure, config.in: Regenerated.
18614 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
18616 * Makefile.in (OBS): Add $(XML_BUILTIN).
18617 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
18619 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
18620 (arm-with-iwmmxt.c): New.
18621 * config.in, configure: Regenerate.
18622 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
18623 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
18624 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
18625 (arm*-*-linux*): Add iWMMXt and regset support.
18626 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
18627 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
18628 (arm_store_wmmxregset, target_regsets): New.
18629 * server.c (get_features_xml): Take annex argument. Check builtin
18631 (handle_query): Handle multiple annexes.
18633 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
18635 * remote-utils.c [USE_WIN32API] (read, write): Define.
18636 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
18639 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
18641 * linux-i386-low.c (the_low_target): Set arch_string.
18642 * linux-x86-64-low.c (the_low_target): Likewise.
18643 * linux-low.c (linux_arch_string): New.
18644 (linux_target_ops): Add it.
18645 * linux-low.h (struct linux_target_ops): Add arch_string.
18646 * server.c (write_qxfer_response): Use const void * for DATA.
18647 (get_features_xml): New.
18648 (handle_query): Handle qXfer:features:read. Report it for qSupported.
18649 * target.h (struct target_ops): Add arch_string method.
18651 2007-01-03 Denis Pilat <denis.pilat@st.com>
18652 Daniel Jacobowitz <dan@codesourcery.com>
18654 * linux-low.c (linux_kill): Handle being called with no threads.
18655 * win32-i386-low.c (win32_kill): Likewise.
18656 (get_child_debug_event): Clear current_process_handle.
18658 2006-12-30 Denis PILAT <denis.pilat@st.com>
18659 Daniel Jacobowitz <dan@codesourcery.com>
18661 * remote-utils.c (remote_open): Check the type of specified
18662 serial port devices before opening them.
18663 * server.c (main): Kill the inferior if an error occurs during
18664 the first remote_open.
18666 2006-12-05 Markus Deuling <deuling@de.ibm.com>
18668 * README: Update supported targets.
18670 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
18672 * Makefile.in (clean): Remove reg-mips64.c.
18673 (reg-mips64.c, reg-mips64.o): New rules.
18674 * configure.srv: Handle mips64. Include regset support for mips.
18675 * linux-mips-low.c (union mips_register): New.
18676 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
18677 (mips_breakpoint, mips_breakpoint_at): Use int.
18678 (mips_collect_register, mips_supply_register)
18679 (mips_collect_register_32bit, mips_supply_register_32bit)
18680 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
18681 (mips_store_fpregset, target_regsets): New.
18682 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
18684 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
18686 * configure.srv: Add target "spu*-*-*".
18687 * Makefile.in (clean): Remove reg-spu.c.
18688 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
18689 * spu-low.c: New file.
18691 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
18693 * configure.ac: Correct td_thr_tls_get_addr test.
18694 * configure: Regenerated.
18696 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
18698 * linux-low.c (linux_wait_for_event): Reformat. Use the
18699 pass_signals array.
18700 * remote-utils.c (decode_address_to_semicolon): New.
18701 * server.c (pass_signals, handle_general_set): New.
18702 (handle_query): Mention QPassSignals for qSupported.
18703 (main): Call handle_general_set.
18704 * server.h (pass_signals, decode_address_to_semicolon): New.
18706 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
18708 * server.c (handle_query): Correct error handling for read_auxv.
18710 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
18712 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
18713 and srv_linux_thread_db to yes.
18714 * linux-s390-low.c (s390_fill_gregset): New function.
18715 (target_regsets): Define data structure.
18717 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
18719 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
18720 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
18721 * config.in, configure: Regenerated.
18722 * inferiors.c (gdb_id_to_thread): New function.
18723 (gdb_id_to_thread_id): Use it.
18724 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
18725 * linux-low.h (struct process_info): Add th member.
18726 (thread_db_get_tls_address): New prototype.
18727 * remote-utils.c (decode_address): Make non-static.
18728 * server.c (handle_query): Handle qGetTLSAddr.
18729 * server.h (gdb_id_to_thread, decode_address): New prototypes.
18730 * target.h (struct target_ops): Add get_tls_address.
18731 * thread-db.c (maybe_attach_thread): Save the thread handle.
18732 (thread_db_get_tls_address): New.
18734 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
18736 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
18737 (linux_resume_one_process): Take a siginfo_t *. Update all
18738 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
18739 (struct pending_signals): Add a siginfo_t.
18740 (linux_wait_for_process): Always set last_status.
18741 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
18742 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
18743 * linux-low.h (struct process_info): Add last_status.
18745 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
18747 * remote-utils.c (try_rle): New function.
18748 (putpkt_binary): Use it.
18750 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
18752 * Makefile.in (clean): Clean reg-x86-64-linux.c.
18753 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
18754 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
18755 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
18756 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
18759 2006-08-08 Richard Sandiford <richard@codesourcery.com>
18761 * server.c (terminal_fd): New variable.
18762 (old_foreground_pgrp): Likewise.
18763 (restore_old_foreground_pgrp): New function.
18764 (start_inferior): Record the terminal file descriptor in terminal_fd
18765 and its original foreground group in old_foreground_pgrp. Register
18766 restore_old_foreground_pgrp with atexit().
18768 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
18770 * server.c (handle_query): Correct qPart to qXfer.
18772 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
18774 * configure.ac: Check for more headers which are missing on
18775 Windows. Automatically supply -lwsock32 and USE_WIN32API.
18776 * configure.srv: Add Cygwin and mingw32.
18777 * remote-utils.c: Don't include headers unconditionally which
18778 are missing on mingw32. Include <winsock.h> for mingw32.
18779 (remote_open): Adjust for mingw32 support. Flush
18780 standard error after writing to it.
18781 (remote_close, putpkt_binary, input_interrupt, block_async_io)
18782 (unblock_async_io, enable_async_io, disable_async_io)
18783 (readchar, getpkt): Update for Winsock support.
18784 (prepare_resume_reply): Expect a protocol signal number.
18785 * server.c: Disable <sys/wait.h> on mingw32.
18786 (start_inferior): Adjust for mingw32 support. Flush
18787 standard error after writing to it.
18788 (attach_inferior): Likewise. Use protocol signal
18790 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
18792 * win32-i386-low.c: New file.
18793 * Makefile.in (XM_CLIBS): Set.
18794 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
18795 (win32-i386-low.o): New dependency rule.
18796 * linux-low.c (linux_wait): Use target signal numbers.
18797 * target.h (struct target_ops): Doc fix.
18798 * server.h (target_signal_to_name): New prototype.
18799 * gdbreplay.c: Don't include headers unconditionally which
18800 are missing on mingw32. Include <winsock.h> for mingw32.
18801 (remote_close, remote_open): Adjust for Winsock support.
18802 * configure, config.in: Regenerated.
18804 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
18806 * server.c (decode_xfer_read, write_qxfer_response): New.
18807 (handle_query): Take a packet length argument. Handle
18808 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
18809 the qSupported response.
18810 (main): Update call to handle_query.
18812 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
18814 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
18815 (putpkt_binary): Renamed from putpkt and adjusted for binary
18817 (putpkt): New wrapper for putpkt_binary.
18818 (readchar): Don't mask off the high bit.
18819 (decode_X_packet): New function.
18820 * server.c (main): Call putpkt_binary if a handler sets the packet
18821 length. Save the length of the incoming packet. Handle 'X'.
18822 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
18824 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
18826 * server.c (handle_query): Handle qSupported.
18828 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
18830 * remote-utils.c (all_symbols_looked_up): New variable.
18831 (look_up_one_symbol): Check it.
18832 * server.h (look_up_one_symbol): New declaration.
18833 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
18835 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
18837 * Makefile.in (linux-arm-low.o): Update dependencies.
18838 * linux-arm-low.c: Include "gdb_proc_service.h".
18839 (PTRACE_GET_THREAD_AREA): Define.
18840 (ps_get_thread_area): New function.
18842 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
18844 * configure.srv (m68k*-*-uclinux*): New target.
18845 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
18846 (linux_resume_one_process): Remove extraneous cast.
18847 (linux_read_offsets): New.
18848 (linux_target_op): Add linux_read_offsets on mmuless systems.
18849 * server.c (handle_query): Add qOffsets logic.
18850 * target.h (struct target_ops): Add read_offsets.
18852 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
18854 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
18855 (PTRACE_GET_THREAD_AREA): Define.
18856 (ps_get_thread_area): New function.
18857 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
18858 (linux-x86-64-low.o): Update.
18860 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
18862 * configure.ac: Remove checks for prfpregset_t.
18863 * gdb_proc_service.h: New file.
18864 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
18865 new "gdb_proc_service.h".
18866 * proc-service.c: Likewise.
18867 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
18868 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
18869 * Makefile.in (gdb_proc_service_h): Updated.
18870 * configure, config.in: Regenerated.
18872 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
18874 * remote-utils.c (prepare_resume_reply): Move declaration
18875 of gdb_id_from_wait to the top of the block.
18877 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
18879 * linux-low.c (regsets_store_inferior_registers): Read the regset
18880 from the target before filling it.
18882 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
18884 * server.c (attach_inferior): Return SIGTRAP for a successful
18887 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
18889 * Makefile.in (OBS): Add version.o.
18890 (STAGESTUFF): Delete.
18891 (version.o): Add dependencies.
18892 (version.c): Replace rule.
18893 (clean): Remove version.c.
18894 * server.c (gdbserver_version): New.
18895 (gdbserver_usage): Use printf.
18896 (main): Handle --version and --help.
18897 * server.h (version, host_name): Add declarations.
18899 2005-12-23 Eli Zaretskii <eliz@gnu.org>
18911 * linux-x86-64-low.c:
18913 * linux-s390-low.c:
18914 * linux-ppc64-low.c:
18916 * linux-mips-low.c:
18917 * linux-m68k-low.c:
18918 * linux-m32r-low.c:
18921 * linux-ia64-low.c:
18922 * linux-i386-low.c:
18923 * linux-crisv32-low.c:
18935 * gdbserver.1: Add (C) after Copyright. Update the FSF
18938 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
18940 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
18941 (arm_breakpoint_at): Recognize both breakpoints.
18942 (the_low_target): Use the correct breakpoint instruction.
18944 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
18946 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
18947 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
18948 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
18949 (the_low_target): Update.
18951 2005-10-25 Andreas Schwab <schwab@suse.de>
18953 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
18955 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
18956 (ia64_num_regs): Reduce to 462.
18958 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
18960 * acinclude.m4: Correct quoting.
18961 * aclocal.m4: Regenerated.
18963 Suggested by SZOKOVACS Robert <szo@ies.hu>:
18964 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
18965 (thread_db_init): Call thread_db_err_str.
18966 * configure.ac: Check for TD_VERSION.
18967 * config.in, configure: Regenerated.
18969 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
18971 * server.h (error, fatal, warning): Add ATTR_FORMAT.
18973 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
18975 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
18976 is not available. Define HAVE_PTRACE_GETREGS if it is.
18977 * config.in, configure: Regenerated.
18978 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
18979 * linux-i386-low.c, linux-m68k-low.c: Update to use
18980 HAVE_PTRACE_GETREGS.
18981 * linux-low.c (regsets_fetch_inferior_registers)
18982 (regsets_store_inferior_registers): Only return 0 if we processed
18984 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
18985 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
18987 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
18989 * inferiors.c (struct thread_info): Add gdb_id.
18990 (add_thread): Add gdb_id argument.
18991 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
18992 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
18993 calls to add_thread.
18994 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
18995 * server.c (handle_query): Use thread_to_gdb_id.
18996 (handle_v_cont, main): Use gdb_id_to_thread_id.
18997 * server.h (add_thread): Update prototype.
18998 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
19001 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
19003 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
19004 left-padded registers.
19005 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
19006 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
19008 2005-07-01 Steve Ellcey <sje@cup.hp.com>
19010 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
19011 * configure: Regenerate.
19012 * config.in: Regenerate.
19013 * server.h (NEED_DECLARATION_STRERROR):
19014 Replace with !HAVE_DECL_STRERROR.
19016 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
19018 * linux-low.c (linux_wait, linux_send_signal): Don't test
19019 an unsigned long variable for > 0 if it could be MAX_ULONG.
19020 * server.c (myresume): Likewise.
19021 * target.c (set_desired_inferior): Likewise.
19023 2005-06-13 Mark Kettenis <kettenis@gnu.org>
19025 * configure.ac: Simplify and improve check for socklen_t.
19026 * configure, config.in: Regenerate.
19028 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
19030 * acconfig.h: Remove.
19031 * configure.ac: Add a test for socklen_t. Use three-argument
19032 AC_DEFINE throughout.
19033 * config.in: Regenerated using autoheader 2.59.
19034 * configure: Regenerated.
19036 * gdbreplay.c (socklen_t): Provide a default.
19037 (remote_open): Use socklen_t.
19038 * remote-utils.c (socklen_t): Provide a default.
19039 (remote_open): Use socklen_t.
19040 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
19043 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
19045 * linux-low.c (linux_read_memory, linux_write_memory)
19046 (linux_read_auxv): Likewise.
19047 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
19048 (check_mem_write): Likewise.
19049 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
19051 * regcache.c (struct inferior_rgcache_data, registers_to_string)
19052 (registers_from_string, register_data): Likewise.
19053 * server.c (handle_query, main): Likewise.
19054 * server.h (convert_ascii_to_int, convert_int_to_ascii)
19055 (decode_M_packet): Likewise.
19056 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
19057 * target.h (struct target_ops): Update read_memory, write_memory,
19059 (read_inferior_memory, write_inferior_memory): Update.
19060 * linux-low.h (struct linux_target_ops): Change type of breakpoint
19061 to unsigned char *.
19062 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
19063 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
19064 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
19065 linux-s390-low.c, linux-sh-low.c: Update for changes in
19066 read_inferior_memory and the_low_target->breakpoint.
19068 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
19070 * Makefile.in (SFILES): Add linux-ppc64-low.c.
19071 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
19072 * configure.srv: Add powerpc64-*-linux*.
19073 * linux-ppc64-low.c: New file.
19075 2005-05-23 Orjan Friberg <orjanf@axis.com>
19077 * linux-cris-low.c: New file with support for CRIS.
19078 * linux-crisv32-low.c: Ditto for CRISv32.
19079 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
19080 (clean): Add reg-cris.c and reg-crisv32.c.
19081 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
19082 reg-crisv32.o, and reg-crisv32.c to make rules.
19083 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
19084 recognized targets.
19086 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
19088 * linux-low.c (fetch_register): Ensure buffer size is a multiple
19089 of sizeof (PTRACE_XFER_TYPE).
19090 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
19092 2005-05-12 Orjan Friberg <orjanf@axis.com>
19094 * target.h (struct target_ops): Add insert_watchpoint,
19095 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
19096 pointers for hardware watchpoint support.
19097 * linux-low.h (struct linux_target_ops): Ditto.
19098 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
19099 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
19100 to linux_target_ops.
19101 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
19103 * server.c (main): Recognize 'Z' and 'z' packets.
19105 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
19107 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
19108 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
19109 (the_low_target): Add new members.
19111 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
19113 * proc-service.c (ps_lgetregs): Search all_processes instead of
19116 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
19118 * server.c (start_inferior): Change return type to int.
19119 (attach_inferior): Change sigptr to int *.
19120 (handle_v_cont, handle_v_requests): Change signal to int *.
19121 (main): Change signal to int.
19123 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
19125 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
19126 * configure.srv: Add m32r*-*-linux*.
19127 * linux-m32r-low.c: New file.
19129 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
19131 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
19133 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
19135 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
19136 Take unsigned long arguments for PIDs.
19137 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
19138 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
19139 (wait_for_sigstop, linux_resume_one_process)
19140 (regsets_fetch_inferior_registers, linux_send_signal)
19141 (linux_read_auxv): Likewise. Update the types of variables holding
19142 PIDs. Update format string specifiers.
19143 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
19144 * remote-utils.c (prepare_resume_reply): Likewise.
19145 * server.c (cont_thread, general_thread, step_thread)
19146 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
19148 (handle_query): Update format specifiers.
19149 (handle_v_cont, main): Use strtoul for thread IDs.
19150 * server.h (struct inferior_list_entry): Use unsigned long for ID.
19151 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
19152 (general_thread, step_thread, thread_from_wait)
19153 (old_thread_from_wait): Update.
19154 * target.h (struct thread_resume): Use unsigned long for THREAD.
19155 (struct target_ops): Use unsigned long for arguments to attach and
19158 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
19160 * acinclude.m4: Include bfd/bfd.m4 directly.
19161 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
19162 <agriffis@toolchain.org>.
19163 * aclocal.m4, configure: Regenerated.
19165 2005-01-07 Andrew Cagney <cagney@gnu.org>
19167 * configure.ac: Rename configure.in, require autoconf 2.59.
19168 * configure: Re-generate.
19170 2004-12-08 Daniel Jacobowitz <dan@debian.org>
19172 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
19173 LIBS when finished.
19174 * aclocal.m4: Regenerated.
19175 * configure: Regenerated.
19177 2004-11-21 Andreas Schwab <schwab@suse.de>
19179 * linux-m68k-low.c (m68k_num_gregs): Define.
19180 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
19181 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
19182 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
19183 (m68k_breakpoint_at): New. Add to the_low_target.
19185 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
19186 srv_linux_thread_db to yes.
19188 2004-10-20 Joel Brobecker <brobecker@gnat.com>
19190 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
19191 (ARCH_SET_FS): Likewise.
19192 (ARCH_GET_FS): Likewise.
19193 (ARCH_GET_GS): Likewise.
19195 2004-10-16 Daniel Jacobowitz <dan@debian.org>
19197 * linux-i386-low.c (ps_get_thread_area): New.
19198 * linux-x86-64-low.c (ps_get_thread_area): New.
19199 * linux-low.c: Include <sys/syscall.h>.
19200 (linux_kill_one_process): Don't kill the first thread here.
19201 (linux_kill): Kill the first thread here.
19202 (kill_lwp): New function.
19203 (send_sigstop, linux_send_signal): Use it.
19204 * proc-service.c: Clean up #ifdefs.
19205 (fpregset_info): Delete.
19206 (ps_lgetregs): Update and enable implementation.
19207 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
19209 * remote-utils.c (struct sym_cache, symbol_cache): New.
19210 (input_interrupt): Print a clearer message.
19211 (async_io_enabled): New variable.
19212 (enable_async_io, disable_async_io): Use it. Update comments.
19213 (look_up_one_symbol): Use the symbol cache.
19214 * thread-db.c (thread_db_look_up_symbols): New function.
19215 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
19217 2004-10-16 Daniel Jacobowitz <dan@debian.org>
19219 * configure.in: Test for -rdynamic.
19220 * configure: Regenerated.
19221 * Makefile (INTERNAL_LDFLAGS): New.
19222 (gdbserver, gdbreplay): Use it.
19224 2004-09-02 Andrew Cagney <cagney@gnu.org>
19226 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
19228 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
19230 * linux-low.c (linux_wait): Clear all_processes list also.
19232 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
19234 * linux-low.c: Include <errno.h>. Remove extern declaration of
19237 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
19239 * gdbreplay.c, server.h, utils.c: Update copyright years.
19241 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
19243 * server.c (main): Print child status or termination signal from
19244 variable 'signal', not 'sig'.
19246 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
19248 * linux-low.c (linux_read_memory): Change return type to
19249 int. Check for and return error from ptrace().
19250 * target.c (read_inferior_memory): Change return type to int. Pass
19251 back return status from the_target->read_memory().
19252 * target.h (struct target_ops): Adapt *read_memory() prototype.
19254 (read_inferior_memory): Adapt prototype.
19255 * server.c (main): Return an error packet if
19256 read_inferior_memory() returns an error.
19258 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
19260 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
19261 Unify with other clean targets.
19263 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
19265 * server.c (handle_v_cont): Call set_desired_inferior.
19267 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
19269 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
19271 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
19273 * linux-low.c (linux_wait): Unblock async I/O.
19274 (linux_resume): Block and enable async I/O.
19275 * remote-utils.c (block_async_io, unblock_async_io): New functions.
19276 * server.h (block_async_io, unblock_async_io): Add prototypes.
19278 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
19280 * remote-utils.c (remote_open): Print a status notice after
19281 opening a TCP port.
19282 * server.c (attach_inferior): Print a status notice after
19285 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
19287 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
19289 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
19291 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
19293 * server.c, target.h: Update copyright years.
19295 2004-02-25 Roland McGrath <roland@redhat.com>
19297 * target.h (struct target_ops): New member `read_auxv'.
19298 * server.c (handle_query): Handle qPart:auxv:read: query using that.
19299 * linux-low.c (linux_read_auxv): New function.
19300 (linux_target_ops): Initialize `read_auxv' member to that.
19302 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
19304 Committed by Jim Blandy <jimb@redhat.com>.
19306 * linux-s390-low.c (s390_num_regs): Update.
19307 (s390_regmap): Remove control registers. Use __s390x__ predefine
19308 instead of GPR_SIZE to distiguish s390 and s390x targets.
19310 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
19312 * linux-low.c: Update copyright year.
19313 (check_removed_breakpoint): Clear pending_is_breakpoint.
19314 (linux_set_resume_request, linux_queue_one_thread)
19315 (resume_status_pending_p): New functions.
19316 (linux_continue_one_thread): Use process->resume.
19317 (linux_resume): Only resume threads if there are no pending events.
19318 * linux-low.h (struct process_info): Add resume request
19321 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
19323 * regcache.c (new_register_cache): Clear the allocated register
19324 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
19326 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
19328 * linux-low.c (linux_resume): Take a struct thread_resume *
19330 (linux_wait): Update call.
19331 (resume_ptr): New static variable.
19332 (linux_continue_one_thread): Renamed from
19333 linux_continue_one_process. Use resume_ptr.
19334 (linux_resume): Use linux_continue_one_thread.
19335 * server.c (handle_v_cont, handle_v_requests): New functions.
19336 (myresume): New function.
19337 (main): Handle 'v' case.
19338 * target.h (struct thread_resume): New type.
19339 (struct target_ops): Change argument of "resume" to struct
19341 (myresume): Delete macro.
19343 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
19345 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
19346 (uninstall): Support DESTDIR.
19348 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
19350 * configure.srv: Add xscale*linux copy of arm*linux entry.
19352 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
19354 * linux-arm-low.c (arm_reinsert_addr): New function.
19355 (the_low_target): Add arm_reinsert_addr.
19357 2003-07-08 Mark Kettenis <kettenis@gnu.org>
19359 * mem-break.c: Remove whitespace at end of file.
19361 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
19363 * configure.in: Check whether we need to prototype strerror.
19364 * server.h: Optionally prototype strerror.
19365 * gdbreplay.c (perror_with_name): Use strerror.
19366 * linux-low.c (linux_attach_lwp): Use strerror.
19367 * utils.c (perror_with_name): Use strerror.
19368 * config.in, configure: Regenerated.
19370 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
19372 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
19373 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
19375 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
19377 * Makefile.in (SFILES): Update.
19378 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
19379 low-sun3.c: Remove files.
19381 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
19383 * linux-low.c: Move comment to linux_thread_alive where it belonged.
19384 (linux_detach_one_process, linux_detach): New functions.
19385 (linux_target_ops): Add linux_detach.
19386 * server.c (main): Handle 'D' packet.
19387 * target.h (struct target_ops): Add "detach" member.
19388 (detach_inferior): Define.
19390 2003-06-13 Mark Kettenis <kettenis@gnu.org>
19392 From Kelley Cook <kelleycook@wideopenwest.com>:
19393 * configure.srv: Accept i[34567]86 variants.
19395 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
19397 * linux-low.c (linux_wait_for_event): Correct comment typos.
19398 (linux_resume_one_process): Call check_removed_breakpoint.
19399 (linux_send_signal): New function.
19400 (linux_target_ops): Add linux_send_signal.
19401 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
19403 * target.h (struct target_ops): Add send_signal.
19405 2003-05-29 Jim Blandy <jimb@redhat.com>
19407 * linux-low.c (usr_store_inferior_registers): Transfer buf in
19408 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
19409 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
19410 away part of the register's value.
19412 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
19414 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
19415 (linux_wait_for_event, linux_init_signals): Likewise.
19417 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
19419 * configure.in: Check for stdlib.h.
19420 * configure: Regenerated.
19421 * config.in: Regenerated.
19423 2003-01-04 Andreas Schwab <schwab@suse.de>
19425 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
19427 2003-01-02 Andrew Cagney <ac131313@redhat.com>
19429 * Makefile.in: Remove obsolete code.
19431 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
19433 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
19434 defined(PT_FPR0_HI).
19436 2002-11-17 Stuart Hughes <seh@zee2.com>
19438 * linux-arm-low.c (arm_num_regs): Increase.
19439 (arm_regmap): Include status register.
19441 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
19443 * linux-low.c (register_addr): Remove incorrect -1 check.
19445 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
19447 * linux-low.c (linux_create_inferior): Call setpgid. Return
19449 (unstopped_p, linux_signal_pid): Remove.
19450 (linux_target_ops): Remove linux_signal_pid.
19451 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
19452 global instead of target method.
19453 * target.h (struct target_ops): Remove signal_pid. Update comment
19454 for create_inferior.
19455 * server.c (signal_pid): New variable.
19456 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
19457 gdbserver. Set the child to be the foreground process group.
19458 (attach_inferior): Set signal_pid.
19460 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
19462 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
19464 2002-08-20 Jim Blandy <jimb@redhat.com>
19466 * Makefile.in (LDFLAGS): Allow the configure script to establish a
19469 2002-08-01 Andrew Cagney <cagney@redhat.com>
19471 * Makefile.in: Make chill references obsolete.
19473 2002-07-24 Kevin Buettner <kevinb@redhat.com>
19475 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
19476 * configure: Regenerate.
19477 * config.in: Regenerate.
19479 2002-07-09 David O'Brien <obrien@FreeBSD.org>
19481 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
19482 (perror_with_name, remote_close, remote_open, expect, play): Static.
19484 2002-07-04 Michal Ludvig <mludvig@suse.cz>
19486 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
19487 byte offsets instead of an array of indexes.
19488 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
19490 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
19492 * regcache.c: Add comment.
19494 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
19496 * thread-db.c: New file.
19497 * proc-service.c: New file.
19498 * acinclude.m4: New file.
19499 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
19500 proc-service.o, and thread-db.o.
19501 (linux-low.o): Add USE_THREAD_DB.
19502 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
19503 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
19504 * aclocal.m4: Regenerated.
19505 * config.in: Regenerated.
19506 * configure: Regenerated.
19507 * configure.in: Check for proc_service.h, sys/procfs.h,
19508 thread_db.h, and linux/elf.h headrs.
19509 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
19510 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
19511 Check for -lthread_db and thread support.
19512 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
19513 PowerPC, and SuperH.
19514 * i387-fp.c: Constify arguments.
19515 * i387-fp.h: Likewise.
19516 * inferiors.c: (struct thread_info): Renamed from
19517 `struct inferior_info'. Remove PID member. Use generic inferior
19518 list header. All uses updated.
19519 (inferiors, signal_pid): Removed.
19520 (all_threads): New variable.
19521 (get_thread): Define.
19522 (add_inferior_to_list): New function.
19523 (for_each_inferior): New function.
19524 (change_inferior_id): New function.
19525 (add_inferior): Removed.
19526 (remove_inferior): New function.
19527 (add_thread): New function.
19528 (free_one_thread): New function.
19529 (remove_thread): New function.
19530 (clear_inferiors): Use for_each_inferior and free_one_thread.
19531 (find_inferior): New function.
19532 (find_inferior_id): New function.
19533 (inferior_target_data): Update argument type.
19534 (set_inferior_target_data): Likewise.
19535 (inferior_regcache_data): Likewise.
19536 (set_inferior_regcache_data): Likewise.
19537 * linux-low.c (linux_bp_reinsert): Remove.
19538 (all_processes, stopping_threads, using_thrads)
19539 (struct pending_signals, debug_threads, pid_of): New.
19540 (inferior_pid): Replace with macro.
19541 (struct inferior_linux_data): Remove.
19542 (get_stop_pc, add_process): New functions.
19543 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
19544 Use add_process and add_thread.
19545 (linux_attach_lwp): New function, based on old linux_attach. Use
19546 add_process and add_thread. Set stop_expected for new threads.
19547 (linux_attach): New function.
19548 (linux_kill_one_process): New function.
19549 (linux_kill): Kill all LWPs.
19550 (linux_thread_alive): Use find_inferior_id.
19551 (check_removed_breakpoints, status_pending_p): New functions.
19552 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
19553 Update. Use WNOHANG. Wait for cloned processes also. Update process
19554 struct for the found process.
19555 (linux_wait_for_event): New function.
19556 (linux_wait): Use it. Support LWPs.
19557 (send_sigstop, wait_for_sigstop, stop_all_processes)
19558 (linux_resume_one_process, linux_continue_one_process): New functions.
19559 (linux_resume): Support LWPs.
19560 (REGISTER_RAW_SIZE): Remove.
19561 (fetch_register): Use register_size instead. Call supply_register.
19562 (usr_store_inferior_registers): Likewise. Call collect_register.
19563 Fix recursive case.
19564 (regsets_fetch_inferior_registers): Improve error message.
19565 (regsets_store_inferior_registers): Add debugging.
19566 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
19567 (unstopped_p, linux_signal_pid): New functions.
19568 (linux_target_ops): Add linux_signal_pid.
19569 (linux_init_signals): New function.
19570 (initialize_low): Call it. Initialize using_threads.
19571 * regcache.c (inferior_regcache_data): Add valid
19573 (get_regcache): Fetch registers lazily. Add fetch argument
19574 and update all callers.
19575 (regcache_invalidate_one, regcache_invalidate): New
19577 (new_register_cache): Renamed from create_register_cache.
19578 Return the new regcache.
19579 (free_register_cache): Change argument to a void *.
19580 (registers_to_string, registers_from_string): Call get_regcache
19581 with fetch flag set.
19582 (register_data): Make static. Pass fetch flag to get_regcache.
19583 (supply_register): Call get_regcache with fetch flag clear.
19584 (collect_register): Call get_regcache with fetch flag set.
19585 (collect_register_as_string): New function.
19586 * regcache.h: Update.
19587 * remote-utils.c (putpkt): Flush after debug output and use
19589 Handle input interrupts while waiting for an ACK.
19590 (input_interrupt): Use signal_pid method.
19591 (getpkt): Flush after debug output and use stderr.
19592 (outreg): Use collect_register_as_string.
19593 (new_thread_notify, dead_thread_notify): New functions.
19594 (prepare_resume_reply): Check using_threads. Set thread_from_wait
19595 and general_thread.
19596 (look_up_one_symbol): Flush after debug output.
19597 * server.c (step_thread, server_waiting): New variables.
19598 (start_inferior): Don't use signal_pid. Update call to mywait.
19599 (attach_inferior): Update call to mywait.
19600 (handle_query): Handle qfThreadInfo and qsThreadInfo.
19601 (main): Don't fetch/store registers explicitly. Use
19602 set_desired_inferior. Support proposed ``Hs'' packet. Update
19604 * server.h: Update.
19605 (struct inferior_list, struct_inferior_list_entry): New.
19606 * target.c (set_desired_inferior): New.
19607 (write_inferior_memory): Constify.
19608 (mywait): New function.
19609 * target.h: Update.
19610 (struct target_ops): New signal_pid method.
19611 (mywait): Removed macro, added prototype.
19613 * linux-low.h (regset_func): Removed.
19614 (regset_fill_func, regset_store_func): New.
19615 (enum regset_type): New.
19616 (struct regset_info): Add type field. Use new operation types.
19617 (struct linux_target_ops): stop_pc renamed to get_pc.
19618 Add decr_pc_after_break and breakpoint_at.
19619 (get_process, get_thread_proess, get_process_thread)
19620 (strut process_info, all_processes, linux_attach_lwp)
19621 (thread_db_init): New.
19623 * linux-arm-low.c (arm_get_pc, arm_set_pc,
19624 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
19625 (the_low_target): Add new members.
19626 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
19627 (i386_store_fpxregset): Constify.
19628 (target_regsets): Add new kind identifier.
19629 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
19630 (i386_set_pc): Add debugging.
19631 (i386_breakpoint_at): New function.
19632 (the_low_target): Add new members.
19633 * linux-mips-low.c (mips_get_pc, mips_set_pc)
19634 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
19635 (mips_breakpoint_at): New.
19636 (the_low_target): Add new members.
19637 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
19638 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
19639 (the_low_target): Add new members.
19640 * linux-sh-low.c (sh_get_pc, sh_set_pc)
19641 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
19642 (the_low_target): Add new members.
19643 * linux-x86-64-low.c (target_regsets): Add new kind
19646 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
19648 From Martin Pool <mbp@samba.org>:
19649 * server.c (gdbserver_usage): New function.
19652 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
19654 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
19655 stop_at -> stop_pc.
19657 2002-05-04 Andrew Cagney <ac131313@redhat.com>
19659 * Makefile.in: Remove obsolete code.
19661 2002-04-24 Michal Ludvig <mludvig@suse.cz>
19663 * linux-low.c (regsets_fetch_inferior_registers),
19664 (regsets_store_inferior_registers): Removed cast to int from
19666 * regcache.h: Added declaration of struct inferior_info.
19668 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
19670 * inferiors.c (struct inferior_info): Add regcache_data.
19671 (add_inferior): Call create_register_cache.
19672 (clear_inferiors): Call free_register_cache.
19673 (inferior_regcache_data, set_inferior_regcache_data): New functions.
19674 * regcache.c (struct inferior_regcache_data): New.
19675 (registers): Remove.
19676 (get_regcache): New function.
19677 (create_register_cache, free_register_cache): New functions.
19678 (set_register_cache): Don't initialize the register cache here.
19679 (registers_to_string, registers_from_string, register_data): Call
19681 * regcache.h: Add prototypes.
19682 * server.h: Likewise.
19684 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
19686 * mem-break.c: New file.
19687 * mem-break.h: New file.
19688 * Makefile.in: Add mem-break.o rule; update server.h
19690 * inferiors.c (struct inferior_info): Add target_data
19692 (clear_inferiors): Free target_data member if set.
19693 (inferior_target_data, set_inferior_target_data): New functions.
19694 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
19695 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
19696 * linux-low.c (linux_bp_reinsert): New variable.
19697 (struct inferior_linux_data): New.
19698 (linux_create_inferior): Use set_inferior_target_data.
19699 (linux_attach): Likewise. Call add_inferior.
19700 (linux_wait_for_one_inferior): New function.
19701 (linux_wait): Call it.
19702 (linux_write_memory): Add const.
19703 (initialize_low): Call set_breakpoint_data.
19704 * linux-low.h (struct linux_target_ops): Add breakpoint
19706 * server.c (attach_inferior): Remove extra add_inferior
19708 * server.h: Include mem-break.h. Update inferior.c
19710 * target.c (read_inferior_memory)
19711 (write_inferior_memory): New functions.
19712 * target.h (read_inferior_memory)
19713 (write_inferior_memory): Change macros to prototypes.
19714 (struct target_ops): Update comments. Add const to write_memory
19717 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
19719 * linux-low.c (usr_store_inferior_registers): Support
19720 registers which are allowed to fail to store.
19721 * linux-low.h (linux_target_ops): Likewise.
19722 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
19723 (ppc_cannot_store_register): FPSCR may not be storable.
19725 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
19727 * server.h: Include <string.h> if HAVE_STRING_H.
19728 * ChangeLog: Correct paths in last ChangeLog entry.
19730 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
19732 * linux-low.h: Remove obsolete prototypes.
19733 (struct linux_target_ops): New.
19734 (extern the_low_target): New.
19735 * linux-low.c (num_regs, regmap): Remove declarations.
19736 (register_addr): Use the_low_target explicitly.
19737 (fetch_register): Likewise.
19738 (usr_fetch_inferior_registers): Likewise.
19739 (usr_store_inferior_registers): Likewise.
19740 * linux-arm-low.c (num_regs): Remove.
19741 (arm_num_regs): Define.
19742 (arm_regmap): Renamed from regmap, made static.
19743 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
19745 (arm_cannot_store_register): Renamed from cannot_store_register,
19747 (the_low_target): New.
19748 * linux-i386-low.c (num_regs): Remove.
19749 (i386_num_regs): Define.
19750 (i386_regmap): Renamed from regmap, made static.
19751 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
19753 (i386_cannot_store_register): Renamed from cannot_store_register,
19755 (the_low_target): New.
19756 * linux-ia64-low.c (num_regs): Remove.
19757 (ia64_num_regs): Define.
19758 (ia64_regmap): Renamed from regmap, made static.
19759 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
19761 (ia64_cannot_store_register): Renamed from cannot_store_register,
19763 (the_low_target): New.
19764 * linux-m68k-low.c (num_regs): Remove.
19765 (m68k_num_regs): Define.
19766 (m68k_regmap): Renamed from regmap, made static.
19767 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
19769 (m68k_cannot_store_register): Renamed from cannot_store_register,
19771 (the_low_target): New.
19772 * linux-mips-low.c (num_regs): Remove.
19773 (mips_num_regs): Define.
19774 (mips_regmap): Renamed from regmap, made static.
19775 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
19777 (mips_cannot_store_register): Renamed from cannot_store_register,
19779 (the_low_target): New.
19780 * linux-ppc-low.c (num_regs): Remove.
19781 (ppc_num_regs): Define.
19782 (ppc_regmap): Renamed from regmap, made static.
19783 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
19785 (ppc_cannot_store_register): Renamed from cannot_store_register,
19787 (the_low_target): New.
19788 * linux-s390-low.c (num_regs): Remove.
19789 (s390_num_regs): Define.
19790 (s390_regmap): Renamed from regmap, made static.
19791 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
19793 (s390_cannot_store_register): Renamed from cannot_store_register,
19795 (the_low_target): New.
19796 * linux-sh-low.c (num_regs): Remove.
19797 (sh_num_regs): Define.
19798 (sh_regmap): Renamed from regmap, made static.
19799 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
19801 (sh_cannot_store_register): Renamed from cannot_store_register,
19803 (the_low_target): New.
19804 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
19805 (the_low_target): New.
19807 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
19809 * Makefile.in: Add stamp-h target.
19810 * configure.in: Create stamp-h.
19811 * configure: Regenerated.
19813 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
19815 * inferiors.c: New file.
19816 * target.c: New file.
19817 * target.h: New file.
19818 * Makefile.in: Add target.o and inferiors.o. Update
19820 * linux-low.c (inferior_pid): New static variable,
19821 moved from server.c.
19822 (linux_create_inferior): Renamed from create_inferior.
19823 Call add_inferior. Return 0 on success instead of a PID.
19824 (linux_attach): Renamed from myattach.
19825 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
19826 (linux_thread_alive): Renamed from mythread_alive.
19827 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
19829 (linux_resume): Renamed from myresume. Add missing ``return 0''.
19830 (regsets_store_inferior_registers): Correct error message.
19831 Add missing ``return 0''.
19832 (linux_fetch_registers): Renamed from fetch_inferior_registers.
19833 (linux_store_registers): Renamed from store_inferior_registers.
19834 (linux_read_memory): Renamed from read_inferior_memory.
19835 (linux_write_memory): Renamed from write_inferior_memory.
19836 (linux_target_ops): New structure.
19837 (initialize_low): Call set_target_ops ().
19838 * remote-utils.c (unhexify): New function.
19839 (hexify): New function.
19840 (input_interrupt): Send signals to ``signal_pid''.
19841 * server.c (inferior_pid): Remove.
19842 (start_inferior): Update create_inferior call.
19843 (attach_inferior): Call add_inferior.
19844 (handle_query): New function.
19845 (main): Call handle_query for `q' packets.
19846 * server.h: Include "target.h". Remove obsolete prototypes.
19847 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
19849 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
19851 * Makefile.in: Add WARN_CFLAGS. Update configury
19853 * configure.in: Check for <string.h>
19854 * configure: Regenerate.
19855 * config.in: Regenerate.
19856 * gdbreplay.c: Include needed system headers.
19857 (remote_open): Remove strchr prototype.
19858 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
19859 * regcache.c (supply_register): Change buf argument to const void *.
19860 (supply_register_by_name): Likewise.
19861 (collect_register): Change buf argument to void *.
19862 (collect_register_by_name): Likewise.
19863 * regcache.h: Add missing prototypes.
19864 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
19865 * server.c (handle_query): New function.
19866 (attached): New static variable, moved out of main.
19867 (main): Quiet longjmp clobber warnings.
19868 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
19869 * utils.c (error): Remove NORETURN.