1 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3 Turn process_stratum_target's supports_agent op into a method of
6 * target.h (struct process_stratum_target): Remove the target op.
7 (class process_target): Add the target op.
8 (target_supports_agent): Update the macro.
9 * target.cc (process_target::supports_agent): Define.
11 Update the derived classes and callers below.
13 * linux-low.cc (linux_target_ops): Update.
14 (linux_supports_agent): Turn into ...
15 (linux_process_target::supports_agent): ... this.
16 * linux-low.h (class linux_process_target): Update.
17 * lynx-low.cc (lynx_target_ops): Update.
18 * nto-low.cc (nto_target_ops): Update.
19 * win32-low.cc (win32_target_ops): Update.
21 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
23 Turn process_stratum_target's qxfer_libraries_svr4 op into a
24 method of process_target.
26 * target.h (struct process_stratum_target): Remove the target op.
27 (class process_target): Add the target op. Also add
28 'supports_qxfer_libraries_svr4'.
29 * target.cc (process_target::qxfer_libraries_svr4): Define.
30 (process_target::supports_qxfer_libraries_svr4): Define.
32 Update the derived classes and callers below.
34 * server.cc (handle_qxfer_libraries_svr4): Update.
35 (handle_query): Update.
36 * linux-low.cc (linux_target_ops): Update.
37 (linux_process_target::supports_qxfer_libraries_svr4): Define.
38 (linux_qxfer_libraries_svr4): Turn into ...
39 (linux_process_target::qxfer_libraries_svr4): ... this.
40 * linux-low.h (class linux_process_target): Update.
41 * lynx-low.cc (lynx_target_ops): Update.
42 * nto-low.cc (nto_target_ops): Update.
43 * win32-low.cc (win32_target_ops): Update.
45 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
47 Turn process_stratum_target's supports_disable_randomization op
48 into a method of process_target.
50 * target.h (struct process_stratum_target): Remove the target op.
51 (class process_target): Add the target op.
52 (target_supports_disable_randomization): Update the macro.
53 * target.cc (process_target::supports_disable_randomization): Define.
55 Update the derived classes and callers below.
57 * linux-low.cc (linux_target_ops): Update.
58 (linux_supports_disable_randomization): Turn into ...
59 (linux_process_target::supports_disable_randomization): ... this.
60 * linux-low.h (class linux_process_target): Update.
61 * lynx-low.cc (lynx_target_ops): Update.
62 * nto-low.cc (nto_target_ops): Update.
63 * win32-low.cc (win32_target_ops): Update.
65 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
67 Turn process_stratum_target's emit_ops op into a method of
70 * target.h (struct process_stratum_target): Remove the target op.
71 (class process_target): Add the target op.
72 (target_emit_ops): Update the macro.
73 * target.cc (process_target::emit_ops): Define.
75 Update the derived classes and callers below.
77 * linux-low.cc (linux_target_ops): Update.
78 (linux_emit_ops): Turn into ...
79 (linux_process_target::emit_ops): ... this.
80 * linux-low.h (class linux_process_target): Update.
81 * lynx-low.cc (lynx_target_ops): Update.
82 * nto-low.cc (nto_target_ops): Update.
83 * win32-low.cc (win32_target_ops): Update.
85 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
87 Turn process_stratum_target's install_fast_tracepoint_jump_pad
88 and get_min_fast_tracepoint_insn_len ops into methods of
91 * target.h (struct process_stratum_target): Remove the target ops.
92 (class process_target): Add the target ops. Also add
93 'supports_fast_tracepoints'.
94 (target_supports_fast_tracepoints): Update the macro.
95 (target_get_min_fast_tracepoint_insn_len): Update the macro.
96 (install_fast_tracepoint_jump_pad): Update and rename the macro
98 (target_install_fast_tracepoint_jump_pad): ... this.
99 * target.cc (process_target::supports_fast_tracepoints): Define.
100 (process_target::install_fast_tracepoint_jump_pad): Define.
101 (process_target::get_min_fast_tracepoint_insn_len): Define.
103 Update the derived classes and callers below.
105 * tracepoint.cc (install_fast_tracepoint): Update.
106 * linux-low.cc (linux_target_ops): Update.
107 (linux_process_target::supports_fast_tracepoints): Define.
108 (linux_install_fast_tracepoint_jump_pad): Turn into ...
109 (linux_process_target::install_fast_tracepoint_jump_pad): ... this.
110 (linux_get_min_fast_tracepoint_insn_len): Turn into ...
111 (linux_process_target::get_min_fast_tracepoint_insn_len): ... this.
112 * linux-low.h (class linux_process_target): Update.
113 * lynx-low.cc (lynx_target_ops): Update.
114 * nto-low.cc (nto_target_ops): Update.
115 * win32-low.cc (win32_target_ops): Update.
117 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
119 Turn process_stratum_target's stabilize_threads op into a
120 method of process_target.
122 * target.h (struct process_stratum_target): Remove the target op.
123 (class process_target): Add the target op.
124 (target_stabilize_threads): Update the macro.
125 * target.cc (process_target::stabilize_threads): Define.
127 Update the derived classes and callers below.
129 * server.cc (handle_status): Update.
130 * tracepoint.cc (cmd_qtdp): Update.
131 (cmd_qtstart): Update.
132 * linux-low.cc (linux_target_ops): Update.
133 (linux_stabilize_threads): Turn into ...
134 (linux_process_target::stabilize_threads): ... this.
135 (linux_wait_1): Update.
136 * linux-low.h (class linux_process_target): Update.
137 * lynx-low.cc (lynx_target_ops): Update.
138 * nto-low.cc (nto_target_ops): Update.
139 * win32-low.cc (win32_target_ops): Update.
141 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
143 Turn process_stratum_target's pause_all and unpause_all ops
144 into methods of process_target.
146 * target.h (struct process_stratum_target): Remove the target ops.
147 (class process_target): Add the target ops.
148 (pause_all): Update the macro and rename to...
149 (target_pause_all): ... this.
150 (unpause_all): Update the macro and rename to...
151 (target_unpause_all): ... this.
152 * target.cc (process_target::pause_all): Define.
153 (process_target::unpause_all): Define.
155 Update the derived classes and callers below.
157 * server.cc (handle_status): Update.
158 * tracepoint.cc (clear_installed_tracepoints): Update.
160 (cmd_qtstart): Update.
161 (stop_tracing): Update.
162 (cmd_qtstatus): Update.
163 (upload_fast_traceframes): Update.
164 (run_inferior_command): Update.
165 * linux-low.cc (linux_target_ops): Update.
166 (linux_pause_all): Turn into ...
167 (linux_process_target::pause_all): ... this.
168 (linux_unpause_all): Turn into ...
169 (linux_process_target::unpause_all): ... this.
170 (linux_process_target::prepare_to_access_memory): Update.
171 (linux_process_target::done_accessing_memory): Update.
172 * linux-low.h (class linux_process_target): Update.
173 * lynx-low.cc (lynx_target_ops): Update.
174 * nto-low.cc (nto_target_ops): Update.
175 * win32-low.cc (win32_target_ops): Update.
177 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
179 Turn process_stratum_target's get_tib_address op into a method of
182 * target.h (struct process_stratum_target): Remove the target op.
183 (class process_target): Add the target op. Also add
184 'supports_get_tib_address'.
185 * target.cc (process_target::get_tib_address): Define.
186 (process_target::supports_get_tib_address): Define.
188 Update the derived classes and callers below.
190 * server.cc (handle_query): Update.
191 * linux-low.cc (win32_target_ops): Update.
192 * lynx-low.cc (lynx_target_ops): Update.
193 * nto-low.cc (nto_target_ops): Update.
194 * win32-low.cc (win32_target_ops): Update.
195 (win32_process_target::supports_get_tib_address): Define.
196 (win32_get_tib_address): Turn into ...
197 (win32_process_target::get_tib_address): ... this.
198 * win32-low.h (class win32_process_target): Update.
200 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
202 Turn process_stratum_target's thread_stopped op into a method of
205 * target.h (struct process_stratum_target): Remove the target op.
206 (class process_target): Add the target op. Also add
207 'supports_thread_stopped'.
208 (target_thread_stopped): Update the macro.
209 * target.cc (process_target::thread_stopped): Define.
210 (process_target::supports_thread_stopped): Define.
211 (prepare_to_access_memory): Update.
213 Update the derived classes and callers below.
215 * server.cc (queue_stop_reply_callback): Update.
216 * linux-low.cc (linux_target_ops): Update.
217 (linux_process_target::supports_thread_stopped): Define.
218 (linux_thread_stopped): Turn into ...
219 (linux_process_target::thread_stopped): ... this.
220 * linux-low.h (class linux_process_target): Update.
221 * lynx-low.cc (lynx_target_ops): Update.
222 * nto-low.cc (nto_target_ops): Update.
223 * win32-low.cc (win32_target_ops): Update.
225 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
227 Turn process_stratum_target's read_pc and write_pc ops into
228 methods of process_target.
230 * target.h (struct process_stratum_target): Remove the target ops.
231 (class process_target): Add the target ops.
232 * target.cc (process_target::read_pc): Define.
233 (process_target::write_pc): Define.
235 Update the derived classes and callers below.
237 * regcache.cc (regcache_read_pc): Update.
238 (regcache_write_pc): Update.
239 * linux-low.cc (linux_target_ops): Update.
240 (linux_read_pc): Turn into ...
241 (linux_process_target::read_pc): ... this.
242 (linux_write_pc): Turn into ...
243 (linux_process_target::write_pc): ... this.
244 * linux-low.h (class linux_process_target): Update.
245 * lynx-low.cc (lynx_target_ops): Update.
246 * nto-low.cc (nto_target_ops): Update.
247 * win32-low.cc (win32_target_ops): Update.
249 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
251 Turn process_stratum_target's supports_tracepoints op into a
252 method of process_target.
254 * target.h (struct process_stratum_target): Remove the target op.
255 (class process_target): Add the target op.
256 (target_supports_tracepoints): Update the macro.
257 * target.cc (process_target::supports_tracepoints): Define.
259 Update the derived classes and callers below.
261 * linux-low.cc (linux_target_ops): Update.
262 (linux_supports_tracepoints): Turn into ...
263 (linux_process_target::supports_tracepoints): ... this.
264 * linux-low.h (class linux_process_target): Update.
265 * lynx-low.cc (lynx_target_ops): Update.
266 * nto-low.cc (nto_target_ops): Update.
267 * win32-low.cc (win32_target_ops): Update.
269 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
271 Turn process_stratum_target's process_qsupported op into a method
274 * target.h (struct process_stratum_target): Remove the target op.
275 (class process_target): Add the target op.
276 (target_process_qsupported): Update the macro.
277 * target.cc (process_target::process_qsupported): Define.
279 Update the derived classes and callers below.
281 * linux-low.cc (linux_target_ops): Update.
282 (linux_process_qsupported): Turn into ...
283 (linux_process_target::process_qsupported): ... this.
284 * linux-low.h (class linux_process_target): Update.
285 * lynx-low.cc (lynx_target_ops): Update.
286 * nto-low.cc (nto_target_ops): Update.
287 * win32-low.cc (win32_target_ops): Update.
289 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
291 Turn process_stratum_target's read_loadmap op into a method of
294 * target.h (struct process_stratum_target): Remove the target op.
295 (class process_target): Add the target op. Also add
296 'supports_read_loadmap'.
297 * target.cc (process_target::read_loadmap): Define.
298 (process_target::supports_read_loadmap): Define.
300 Update the derived classes and callers below.
302 * server.cc (handle_qxfer_fdpic): Update.
303 (handle_query): Update.
304 * linux-low.cc (linux_target_ops): Update.
305 (linux_process_target::supports_read_loadmap): Define.
306 (linux_read_loadmap): Turn into ...
307 (linux_process_target::read_loadmap): ... this.
308 * linux-low.h (class linux_process_target): Update.
309 * lynx-low.cc (lynx_target_ops): Update.
310 * nto-low.cc (nto_target_ops): Update.
311 * win32-low.cc (win32_target_ops): Update.
313 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
315 Turn process_stratum_target's core_of_thread op into a method of
318 * target.h (struct process_stratum_target): Remove the target op.
319 (class process_target): Add the target op.
320 (target_core_of_thread): Update the macro.
321 * target.cc (process_target::core_of_thread): Define.
323 Update the derived classes and callers below.
325 * linux-low.cc (linux_target_ops): Update.
326 (linux_process_target::core_of_thread): Define.
327 * linux-low.h (class linux_process_target): Update.
328 * lynx-low.cc (lynx_target_ops): Update.
329 * nto-low.cc (nto_target_ops): Update.
330 * win32-low.cc (win32_target_ops): Update.
332 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
334 Turn process_stratum_target's handle_monitor_command op into a
335 method of process_target.
337 * target.h (struct process_stratum_target): Remove the target op.
338 (class process_target): Add the target op.
339 (target_handle_monitor_command): Update the macro.
340 * target.cc (process_target::handle_monitor_command): Define.
342 Update the derived classes and callers below.
344 * server.cc (handle_query): Update.
345 * linux-low.cc (linux_target_ops): Update.
346 (linux_process_target::handle_monitor_command): Define.
347 * linux-low.h (class linux_process_target): Update.
348 * lynx-low.cc (lynx_target_ops): Update.
349 * nto-low.cc (nto_target_ops): Update.
350 * win32-low.cc (win32_target_ops): Update.
352 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
354 Turn process_stratum_target's handle_new_gdb_connection op into a
355 method of process_target.
357 * target.h (struct process_stratum_target): Remove the target op.
358 (class process_target): Add the target op.
359 (target_handle_new_gdb_connection): Update the macro.
360 * target.cc (process_target::handle_new_gdb_connection): Define.
362 Update the derived classes and callers below.
364 * linux-low.cc (linux_target_ops): Update.
365 (linux_handle_new_gdb_connection): Turn into ...
366 (linux_process_target::handle_new_gdb_connection): ... this.
367 * linux-low.h (class linux_process_target): Update.
368 * lynx-low.cc (lynx_target_ops): Update.
369 * nto-low.cc (nto_target_ops): Update.
370 * win32-low.cc (win32_target_ops): Update.
372 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
374 Turn process_stratum_target's supports_fork_events,
375 supports_vfork_events, and supports_exec_events ops into methods
378 * target.h (struct process_stratum_target): Remove the target ops.
379 (class process_target): Add the target ops.
380 (target_supports_fork_events): Update the macro.
381 (target_supports_vfork_events): Update the macro.
382 (target_supports_exec_events): Update the macro.
383 * target.cc (process_target::supports_fork_events): Define.
384 (process_target::supports_vfork_events): Define.
385 (process_target::supports_exec_events): Define.
387 Update the derived classes and callers below.
389 * linux-low.cc (linux_target_ops): Update.
390 (linux_supports_fork_events): Turn into ...
391 (linux_process_target::supports_fork_events): ... this.
392 (linux_supports_vfork_events): Turn into ...
393 (linux_process_target::supports_vfork_events): ... this.
394 (linux_supports_exec_events): Turn into ...
395 (linux_process_target::supports_exec_events): ... this.
396 * linux-low.h (class linux_process_target): Update.
397 * lynx-low.cc (lynx_target_ops): Update.
398 * nto-low.cc (nto_target_ops): Update.
399 * win32-low.cc (win32_target_ops): Update.
401 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
403 Turn process_stratum_target's supports_multi_process op into a
404 method of process_target.
406 * target.h (struct process_stratum_target): Remove the target op.
407 (class process_target): Add the target op.
408 * target.cc (process_target::supports_multi_process): Define.
409 (target_supports_multi_process): Update.
411 Update the derived classes and callers below.
413 * linux-low.cc (linux_target_ops): Update.
414 (linux_supports_multi_process): Turn into ...
415 (linux_process_target::supports_multi_process): ... this.
416 * linux-low.h (class linux_process_target): Update.
417 * lynx-low.cc (lynx_target_ops): Update.
418 * nto-low.cc (nto_target_ops): Update.
419 * win32-low.cc (win32_target_ops): Update.
421 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
423 Turn process_stratum_target's supports_non_stop, async, and
424 start_non_stop ops into methods of process_target.
426 * target.h (struct process_stratum_target): Remove the target ops.
427 (class process_target): Add the target ops.
428 (target_supports_non_stop): Update the macro.
429 (target_async): Update the macro.
430 (start_non_stop): Remove declaration.
431 * target.cc (process_target::supports_non_stop): Define.
432 (process_target::async): Define.
433 (process_target::start_non_stop): Define.
434 (start_non_stop): Remove.
436 Update the derived classes and callers below.
438 * server.cc (handle_qxfer_siginfo): Update.
439 (handle_query): Update.
440 * linux-low.cc (linux_target_ops): Update.
441 (linux_supports_non_stop): Turn into ...
442 (linux_process_target::supports_non_stop): ... this.
443 (linux_async): Turn into ...
444 (linux_process_target::async): ... this.
445 (linux_start_non_stop): Turn into ...
446 (linux_process_target::start_non_stop): ... this.
447 * linux-low.h (class linux_process_target): Update.
448 * lynx-low.cc (lynx_target_ops): Update.
449 * nto-low.cc (nto_target_ops): Update.
450 (nto_supports_non_stop): Remove; rely on the default behavior
452 * win32-low.cc (win32_target_ops): Update.
454 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
456 Turn process_stratum_target's qxfer_siginfo op into a method of
459 * target.h (struct process_stratum_target): Remove the target op.
460 (class process_target): Add the target op. Also add
461 'supports_qxfer_siginfo'.
462 * target.cc (process_target::qxfer_siginfo): Define.
463 (process_target::supports_qxfer_siginfo): Define.
465 Update the derived classes and callers below.
467 * server.cc (handle_qxfer_siginfo): Update.
468 (handle_query): Update.
469 * linux-low.cc (linux_target_ops): Update.
470 (linux_process_target::supports_qxfer_siginfo): Define.
471 (linux_xfer_siginfo): Turn into ...
472 (linux_process_target::qxfer_siginfo): ... this.
473 * linux-low.h (class linux_process_target): Update.
474 * lynx-low.cc (lynx_target_ops): Update.
475 * nto-low.cc (nto_target_ops): Update.
476 * win32-low.cc (win32_target_ops): Update.
478 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
480 Turn process_stratum_target's qxfer_osdata op into a method of
483 * target.h (struct process_stratum_target): Remove the target op.
484 (class process_target): Add the target op. Also add
485 'supports_qxfer_osdata'.
486 * target.cc (process_target::qxfer_osdata): Define.
487 (process_target::supports_qxfer_osdata): Define.
489 Update the derived classes and callers below.
491 * server.cc (handle_qxfer_osdata): Update.
492 (handle_query): Update.
493 * linux-low.cc (linux_target_ops): Update.
494 (linux_process_target::supports_qxfer_osdata): Define.
495 (linux_qxfer_osdata): Turn into ...
496 (linux_process_target::qxfer_osdata): ... this.
497 * linux-low.h (class linux_process_target): Update.
498 * lynx-low.cc (lynx_target_ops): Update.
499 * nto-low.cc (nto_target_ops): Update.
500 * win32-low.cc (win32_target_ops): Update.
502 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
504 Turn process_stratum_target's hostio_last_error op into a
505 method of process_target.
507 * target.h (struct process_stratum_target): Remove the target op.
508 (class process_target): Add the target op.
509 * target.cc: Add "hostio.h" to includes.
510 (process_target::hostio_last_error): Define.
512 Update the derived classes and callers below.
514 * hostio.cc (hostio_error): Update.
515 * linux-low.cc: Remove "hostio.h" from includes.
516 (linux_target_ops): Update.
517 * lynx-low.cc (lynx_target_ops): Update.
518 * nto-low.cc (nto_target_ops): Update.
519 * win32-low.h (class win32_process_target): Update.
520 * win32-low.cc (win32_target_ops): Update.
521 (wince_hostio_last_error): Turn into ...
522 (win32_process_target::hostio_last_error): ... this.
524 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
526 Turn process_stratum_target's get_tls_address op into a method of
529 * target.h (struct process_stratum_target): Remove the target op.
530 (class process_target): Add the target op. Also add
531 'supports_get_tls_address'.
532 * target.cc (process_target::get_tls_address): Define.
533 (process_target::supports_get_tls_address): Define.
535 Update the derived classes and callers below.
537 * server.cc (handle_query): Update.
538 * linux-low.cc (linux_target_ops): Update.
539 (linux_process_target::supports_get_tls_address): Define.
540 (linux_process_target::get_tls_address): Define.
541 * linux-low.h (class linux_process_target): Update.
542 * lynx-low.cc (lynx_target_ops): Update.
543 * nto-low.cc (nto_target_ops): Update.
544 * win32-low.cc (win32_target_ops): Update.
546 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
548 Turn process_stratum_target's read_offsets op into a method of
551 * target.h (struct process_stratum_target): Remove the target op.
552 (class process_target): Add the target op. Also add
553 'supports_read_offsets'.
554 * target.cc (process_target::read_offsets): Define.
555 (process_target::supports_read_offsets): Define.
557 Update the derived classes and callers below.
559 * server.cc (handle_query): Update.
560 * linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
561 (linux_target_ops): Update.
562 (linux_process_target::supports_read_offsets): Define.
563 (linux_read_offsets): Turn into ...
564 (linux_process_target::read_offsets): ... this.
565 * linux-low.h (class linux_process_target): Update.
566 * lynx-low.cc (lynx_target_ops): Update.
567 * nto-low.cc (nto_target_ops): Update.
568 * win32-low.cc (win32_target_ops): Update.
570 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
572 Turn process_stratum_target's stopped_by_watchpoint and
573 stopped_data_address ops into methods of process_target.
575 * target.h (struct process_stratum_target): Remove the target ops.
576 (class process_target): Add the target ops.
577 * target.cc (process_target::stopped_by_watchpoint): Define.
578 (process_target::stopped_data_address): Define.
580 Update the derived classes and callers below.
582 * remote-utils.cc (prepare_resume_reply): Update.
583 * linux-low.cc (linux_target_ops): Update.
584 (linux_stopped_by_watchpoint): Turn into ...
585 (linux_process_target::stopped_by_watchpoint): ... this.
586 (linux_stopped_data_address): Turn into ...
587 (linux_process_target::stopped_data_address): ... this.
588 * linux-low.h (class linux_process_target): Update.
589 * lynx-low.cc (lynx_target_ops): Update.
590 * nto-low.cc (nto_target_ops): Update.
591 (nto_stopped_by_watchpoint): Turn into ...
592 (nto_process_target::stopped_by_watchpoint): ... this.
593 (nto_stopped_data_address): Turn into ...
594 (nto_process_target::stopped_data_address): ... this.
595 * nto-low.h (class nto_process_target): Update.
596 * win32-low.cc (win32_target_ops): Update.
597 (win32_stopped_by_watchpoint): Turn into ...
598 (win32_process_target::stopped_by_watchpoint): ... this.
599 (win32_stopped_data_address): Turn into ...
600 (win32_process_target::stopped_data_address): ... this.
601 * win32-low.h (class win32_process_target): Update.
603 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
605 Turn process_stratum_target's supports_hardware_single_step op into
606 a method of process_target.
608 * target.h (struct process_stratum_target): Remove the target op.
609 (class process_target): Add the target op.
610 (target_supports_hardware_single_step): Update the macro.
611 (target_can_do_hardware_single_step): Remove declaration.
612 * target.cc (process_target::supports_hardware_single_step): Define.
613 (target_can_do_hardware_single_step): Remove.
615 Update the derived classes and callers below.
617 * linux-low.h (class linux_process_target): Update.
618 * linux-low.cc (linux_target_ops): Update.
619 (linux_supports_hardware_single_step): Turn into ...
620 (linux_process_target::supports_hardware_single_step): ... this.
621 * lynx-low.h (class lynx_process_target): Update.
622 * lynx-low.cc (lynx_target_ops): Update.
623 (lynx_process_target::supports_hardware_single_step): Define.
624 * nto-low.h (class nto_process_target): Update.
625 * nto-low.cc (nto_target_ops): Update.
626 (nto_process_target::supports_hardware_single_step): Define.
627 * win32-low.h (class win32_process_target): Update.
628 * win32-low.cc (win32_target_ops): Update.
629 (win32_process_target::supports_hardware_single_step): Define.
631 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
633 Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
634 ops into methods of process_target.
636 * target.h (struct process_stratum_target): Remove the target ops.
637 (class process_target): Add the target ops.
638 (target_stopped_by_hw_breakpoint): Update the macro.
639 (target_supports_stopped_by_hw_breakpoint): Update the macro.
640 * target.cc (process_target::stopped_by_hw_breakpoint): Define.
641 (process_target::supports_stopped_by_hw_breakpoint): Define.
643 Update the derived classes and callers below.
645 * linux-low.cc (linux_target_ops): Update.
646 (linux_stopped_by_hw_breakpoint): Turn into ...
647 (linux_process_target::stopped_by_hw_breakpoint): ... this.
648 (linux_supports_stopped_by_hw_breakpoint): Turn into ...
649 (linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
650 * linux-low.h (class linux_process_target): Update.
651 * lynx-low.cc (lynx_target_ops): Update.
652 * nto-low.cc (nto_target_ops): Update.
653 * win32-low.cc (win32_target_ops): Update.
655 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
657 Turn process_stratum_target's {supports_}stopped_by_sw_breakpoint
658 ops into methods of process_target.
660 * target.h (struct process_stratum_target): Remove the target ops.
661 (class process_target): Add the target ops.
662 (target_stopped_by_sw_breakpoint): Update the macro.
663 (target_supports_stopped_by_sw_breakpoint): Update the macro.
664 * target.cc (process_target::stopped_by_sw_breakpoint): Define.
665 (process_target::supports_stopped_by_sw_breakpoint): Define.
667 Update the derived classes and callers below.
669 * linux-low.cc (linux_target_ops): Update.
670 (linux_stopped_by_sw_breakpoint): Turn into ...
671 (linux_process_target::stopped_by_sw_breakpoint): ... this.
672 (linux_supports_stopped_by_sw_breakpoint): Turn into ...
673 (linux_process_target::supports_stopped_by_sw_breakpoint): ... this.
674 * linux-low.h (class linux_process_target): Update.
675 * lynx-low.cc (lynx_target_ops): Update.
676 * nto-low.cc (nto_target_ops): Update.
677 * win32-low.cc (win32_target_ops): Update.
679 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
681 Turn process_stratum_target's insert_point and remove_point ops
682 into methods of process_target.
684 * target.h (struct process_stratum_target): Remove the target ops.
685 (class process_target): Add the target ops.
686 * target.cc (process_target::insert_point): Define.
687 (process_target::remove_point): Define.
689 Update the derived classes and callers below.
691 * mem-break.cc (set_raw_breakpoint_at): Update.
692 (delete_raw_breakpoint): Update.
693 (uninsert_raw_breakpoint): Update.
694 (reinsert_raw_breakpoint): Update.
695 * linux-low.cc (linux_target_ops): Update.
696 (linux_insert_point): Turn into ...
697 (linux_process_target::insert_point): ... this.
698 (linux_remove_point): Turn into ...
699 (linux_process_target::remove_point): ... this.
700 * linux-low.h (class linux_process_target): Update.
701 * lynx-low.cc (lynx_target_ops): Update.
702 * nto-low.cc (nto_target_ops): Update.
703 (nto_insert_point): Turn into ...
704 (nto_process_target::insert_point): ... this.
705 (nto_remove_point): Turn into ...
706 (nto_process_target::remove_point): ... this.
707 * nto-low.h (class nto_process_target): Update.
708 * win32-low.cc (win32_target_ops): Update.
709 (win32_insert_point): Turn into ...
710 (win32_process_target::insert_point): ... this.
711 (win32_remove_point): Turn into ...
712 (win32_process_target::remove_point): ... this.
713 * win32-low.h (class win32_process_target): Update.
715 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
717 Turn process_stratum_target's supports_z_point_type op into a
718 method of process_target.
720 * target.h (struct process_stratum_target): Remove the target op.
721 (class process_target): Add the target op.
722 * target.cc (process_target::supports_z_point_type): Define.
724 Update the derived classes and callers below.
726 * mem-break.cc (z_type_supported): Update.
727 * linux-low.cc (linux_target_ops): Update.
728 (linux_supports_z_point_type): Turn into ...
729 (linux_process_target::supports_z_point_type): ... this.
730 * linux-low.h (class linux_process_target): Update.
731 * lynx-low.cc (lynx_target_ops): Update.
732 * nto-low.cc (nto_target_ops): Update.
733 (nto_supports_z_point_type): Turn into ...
734 (nto_process_target::supports_z_point_type): ... this.
735 * nto-low.h (class nto_process_target): Update.
736 * win32-low.cc (win32_target_ops): Update.
737 (win32_supports_z_point_type): Turn into ...
738 (win32_process_target::supports_z_point_type): ... this.
739 * win32-low.h (class win32_process_target): Update.
741 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
743 Turn process_stratum_target's read_auxv op into a method of
746 * target.h (class process_stratum_target): Remove the target op.
747 (struct process_target): Add the target op. Also add
748 'supports_read_auxv'.
749 * target.cc (process_target::read_auxv): Define.
750 (process_target::supports_read_auxv): Define.
752 Update the derived classes and callers below.
754 * server.cc (handle_qxfer_auxv): Update.
755 (handle_query): Update.
756 * linux-low.cc (linux_target_ops): Update.
757 (linux_process_target::supports_read_auxv): Define.
758 (linux_read_auxv): Turn into ...
759 (linux_process_target::read_auxv): ... this.
760 * linux-low.h (class linux_process_target): Update.
761 * lynx-low.cc (lynx_target_ops): Update.
762 * nto-low.cc (nto_target_ops): Update.
763 (nto_process_target::supports_read_auxv): Define.
764 (nto_read_auxv): Turn into ...
765 (nto_process_target::read_auxv): ... this.
766 * nto-low.h (class nto_process_target): Update.
767 * win32-low.cc (win32_target_ops): Update.
769 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
771 Turn process_stratum_target's request_interrupt op into a method of
774 * target.h (struct process_stratum_target): Remove the target op.
775 (class process_target): Add the target op.
777 Update the derived classes and callers below.
779 * remote-utils.cc (putpkt_binary_1): Update.
780 (input_interrupt): Update.
782 * server.cc (handle_v_requests): Update.
783 * linux-low.cc (linux_target_ops): Update.
784 (linux_request_interrupt): Turn into ...
785 (linux_process_target::request_interrupt): ... this.
786 * linux-low.h (class linux_process_target): Update.
787 * lynx-low.cc (lynx_target_ops): Update.
788 (lynx_request_interrupt): Turn into ...
789 (lynx_process_target::request_interrupt): ... this.
790 * lynx-low.h (class lynx_process_target): Update.
791 * nto-low.cc (nto_target_ops): Update.
792 (nto_request_interrupt): Turn into ...
793 (nto_process_target::request_interrupt): ... this.
794 * nto-low.h (class nto_process_target): Update.
795 * win32-low.cc (win32_target_ops): Update.
796 (win32_request_interrupt): Turn into ...
797 (win32_process_target::request_interrupt): ... this.
798 * win32-low.h (class win32_process_target): Update.
800 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
802 Turn process_stratum_target's look_up_symbols op into a method of
805 * target.h (struct process_stratum_target): Remove the target op.
806 (class process_target): Add the target op.
807 * target.cc (process_target::look_up_symbols): Define.
809 Update the derived classes and callers below.
811 * server.cc (handle_query): Update.
812 * linux-low.cc (linux_target_ops): Update.
813 (linux_look_up_symbols): Turn into ...
814 (linux_process_target::look_up_symbols): ... 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 read_memory and write_memory
823 ops into methods of process_target.
825 * target.h (struct process_stratum_target): Remove the target ops.
826 (class process_target): Add the target ops.
828 Update the derived classes and callers below.
830 * linux-aarch32-low.cc (arm_breakpoint_at): Update.
831 * linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
832 * linux-arm-low.cc (arm_sigreturn_next_pc): Update.
833 (arm_get_syscall_trapinfo): Update.
834 * linux-cris-low.cc (cris_breakpoint_at): Update.
835 * linux-crisv32-low.cc (cris_breakpoint_at): Update.
836 * linux-m32r-low.cc (m32r_breakpoint_at): Update.
837 * linux-mips-low.cc (mips_breakpoint_at): Update.
838 * linux-nios2-low.cc (nios2_breakpoint_at): Update.
839 * linux-ppc-low.cc (ppc_breakpoint_at): Update.
840 * linux-sh-low.cc (sh_breakpoint_at): Update.
841 * linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
842 (sparc_store_gregset_from_stack): Update.
843 (sparc_breakpoint_at): Update.
844 * linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
845 * linux-tile-low.cc (tile_breakpoint_at): Update.
846 * linux-x86-low.cc (x86_breakpoint_at): Update.
847 * linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
848 * mem-brea.cc (insert_memory_breakpoint): Update.
849 (validate_inserted_breakpoint): Update.
850 * target.cc (read_inferior_memory): Update.
851 (target_write_memory): Update.
852 * linux-low.cc (linux_target_ops): Update.
853 (linux_read_memory): Make a wrapper around the read_memory target
855 (linux_process_target::read_memory): Rename from linux_read_memory.
856 (linux_write_memory): Turn into ...
857 (linux_process_target::write_memory): ... this.
858 * linux-low.h (class linux_process_target): Update.
859 * lynx-low.cc (lynx_target_ops): Update.
860 (lynx_read_memory): Turn into ...
861 (lynx_process_target::read_memory): ... this.
862 (lynx_write_memory): Turn into ...
863 (lynx_process_target::write_memory): ... this.
864 * lynx-low.h (class lynx_process_target): Update.
865 * nto-low.cc (nto_target_ops): Update.
866 (nto_read_memory): Turn into ...
867 (nto_process_target::read_memory): ... this.
868 (nto_write_memory): Turn into ...
869 (nto_process_target::write_memory): ... this.
870 * nto-low.h (class nto_process_target): Update.
871 * win32-low.cc (win32_target_ops): Update.
872 (win32_read_inferior_memory): Turn into ...
873 (win32_process_target::read_memory): ... this.
874 (win32_write_inferior_memory): Turn into ...
875 (win32_process_target::write_memory): ... this.
876 * win32-low.h (class win32_process_target): Update.
878 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
880 Turn process_stratum_target's prepare_to_access_memory and
881 done_accessing_memory ops into methods of process_target.
883 * target.h (struct process_stratum_target): Remove the target ops.
884 (class process_target): Add the target ops.
885 * target.cc (process_target::prepare_to_access_memory): Define.
886 (process_target::done_accessing_memory): Define.
887 (prepare_to_access_memory): Update.
888 (done_accessing_memory): Update.
890 Update the derived classes and callers below.
892 * linux-low.cc (linux_target_ops): Update.
893 (linux_prepare_to_access_memory): Turn into ...
894 (linux_process_target::prepare_to_access_memory): ... this.
895 (linux_done_accessing_memory): Turn into ...
896 (linux_process_target::done_accessing_memory): ... this.
897 * linux-low.h (class linux_process_target): Update.
898 * lynx-low.cc (lynx_target_ops): Update.
899 * nto-low.cc (nto_target_ops): Update.
900 * win32-low.cc (win32_target_ops): Update.
902 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
904 Turn process_stratum_target's fetch_registers and store_registers
905 ops into methods of process_target.
907 * target.h (struct process_stratum_target): Remove the target ops.
908 (class process_target): Add the target ops.
909 (fetch_inferior_registers): Update the macro.
910 (store_inferior_registers): Update the macro.
912 Update the derived classes and callers below.
914 * linux-low.cc (linux_target_ops): Update.
915 (linux_fetch_registers): Turn into ...
916 (linux_process_target::fetch_registers): ... this.
917 (linux_store_registers): Turn into ...
918 (linux_process_target::store_registers): ... this.
919 * linux-low.h (class linux_process_target): Update.
920 * lynx-low.cc (lynx_target_ops): Update.
921 (lynx_fetch_registers): Turn into ...
922 (lynx_process_target::fetch_registers): ... this.
923 (lynx_store_registers): Turn into ...
924 (lynx_process_target::store_registers): ... this.
925 * lynx-low.h (class lynx_process_target): Update.
926 * nto-low.cc (nto_target_ops): Update.
927 (nto_fetch_registers): Turn into ...
928 (nto_process_target::fetch_registers): ... this.
929 (nto_store_registers): Turn into ...
930 (nto_process_target::store_registers): ... this.
931 * nto-low.h (class nto_process_target): Update.
932 * win32-low.cc (win32_target_ops): Update.
933 (win32_fetch_inferior_registers): Turn into ...
934 (win32_process_target::fetch_registers): ... this.
935 (win32_store_inferior_registers): Turn into ...
936 (win32_process_target::store_registers): ... this.
937 * win32-low.h (class win32_process_target): Update.
939 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
941 Turn process_stratum_target's wait op into a method of
944 * target.h (struct process_stratum_target): Remove the target op.
945 (class process_target): Add the target op.
947 Update the derived classes and callers below.
949 * target.cc (target_wait): Update.
950 * linux-low.cc (linux_target_ops): Update.
951 (linux_wait): Turn into ...
952 (linux_process_target::wait): ... this.
953 * linux-low.h (class linux_process_target): Update.
954 * lynx-low.cc (lynx_target_ops): Update.
955 (lynx_wait): Turn into ...
956 (lynx_process_target::wait): ... this.
957 * lynx-low.h (class lynx_process_target): Update.
958 * nto-low.cc (nto_target_ops): Update.
959 (nto_wait): Turn into ...
960 (nto_process_target::wait): ... this.
961 * nto-low.h (class nto_process_target): Update.
962 * win32-low.cc (win32_target_ops): Update.
963 (win32_wait): Turn into ...
964 (win32_process_target::wait): ... this.
965 (do_initial_child_stuff): Update.
966 * win32-low.h (class win32_process_target): Update.
968 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
970 Turn process_stratum_target's resume op into a method of
973 * target.h (struct process_stratum_target): Remove the target op.
974 (class process_target): Add the target op.
976 Update the derived classes and callers below.
978 * server.cc (resume): Update.
979 * target.cc (target_stop_and_wait): Update.
980 (target_continue_no_signal): Update.
981 (target_continue): Update.
982 * linux-low.cc (linux_target_ops): Update.
983 (linux_resume): Turn into ...
984 (linux_process_target::resume): ... this.
985 * linux-low.h (class linux_process_target): Update.
986 * lynx-low.cc (lynx_target_ops): Update.
987 (lynx_resume): Turn into ...
988 (lynx_process_target::resume): ... this.
989 * lynx-low.h (class lynx_process_target): Update.
990 * nto-low.cc (nto_target_ops): Update.
991 (nto_resume): Turn into ...
992 (nto_process_target::resume): ... this.
993 * nto-low.h (class nto_process_target): Update.
994 * win32-low.cc (win32_target_ops): Update.
995 (win32_resume): Turn into ...
996 (win32_process_target::resume): ... this.
997 (win32_process_target::detach): Update.
998 (do_initial_child_stuff): Update.
999 * win32-low.h (class win32_process_target): Update.
1001 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1003 Turn process_stratum_target's thread_alive op into a method of
1006 * target.h (struct process_stratum_target): Remove the target op.
1007 (class process_target): Add the target op.
1008 (mythread_alive): Update the macro.
1010 Update the derived classes and callers below.
1012 * linux-low.cc (linux_target_ops): Update.
1013 (linux_thread_alive): Turn into ...
1014 (linux_process_target::thread_alive): ... this.
1015 (wait_for_sigstop): Update.
1016 * linux-low.h (class linux_process_target): Update.
1017 * lynx-low.cc (lynx_target_ops): Update.
1018 (lynx_thread_alive): Turn into ...
1019 (lynx_process_target::thread_alive): ... this.
1020 * lynx-low.h (class lynx_process_target): Update.
1021 * nto-low.cc (nto_target_ops): Update.
1022 (nto_thread_alive): Turn into ...
1023 (nto_process_target::thread_alive): ... this.
1024 * nto-low.h (class nto_process_target): Update.
1025 * win32-low.cc (win32_target_ops): Update.
1026 (win32_thread_alive): Turn into ...
1027 (win32_process_target::thread_alive): ... this.
1028 * win32-low.h (class win32_process_target): Update.
1030 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1032 Turn process_stratum_target's join op into a method of
1035 * target.h (struct process_stratum_target): Remove the target op.
1036 (class process_target): Add the target op.
1037 (join_inferior): Update the macro.
1039 Update the derived classes and callers below.
1041 * linux-low.cc (linux_target_ops): Update.
1042 (linux_join): Turn into ...
1043 (linux_process_target::join): ... this.
1044 * linux-low.h (class linux_process_target): Update.
1045 * lynx-low.cc (lynx_target_ops): Update.
1046 (lynx_join): Turn into ...
1047 (lynx_process_target::join): ... this.
1048 * lynx-low.h (class lynx_process_target): Update.
1049 * nto-low.cc (nto_target_ops): Update.
1050 (nto_process_target::join): Define.
1051 * nto-low.h (class nto_process_target): Update.
1052 * win32-low.cc (win32_target_ops): Update.
1053 (win32_join): Turn into ...
1054 (win32_process_target::join): ... this.
1055 * win32-low.h (class win32_process_target): Update.
1057 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1059 Turn process_stratum_target's mourn op into a method of
1062 * target.h (struct process_stratum_target): Remove the target op.
1063 (class process_target): Add the target op.
1065 Update the derived classes and callers below.
1067 * target.cc (target_mourn_inferior): Update.
1068 * linux-low.cc (linux_target_ops): Update.
1069 (linux_mourn): Turn into ...
1070 (linux_process_target::mourn): ... this.
1071 (handle_extended_wait): Update.
1072 (linux_process_target::kill): Update.
1073 (linux_process_target::detach): Update.
1074 * linux-low.h (class linux_process_target): Update.
1075 * lynx-low.cc (lynx_target_ops): Update.
1076 (lynx_mourn): Turn into ...
1077 (lynx_process_target::mourn): ... this.
1078 * lynx-low.h (class lynx_process_target): Update.
1079 * nto-low.cc (nto_target_ops): Update.
1080 (nto_mourn): Turn into ...
1081 (nto_process_target::mourn): ... this.
1082 * nto-low.h (class nto_process_target): Update.
1083 * win32-low.cc (win32_target_ops): Update.
1084 (win32_mourn): Turn into ...
1085 (win32_process_target::mourn): ... this.
1086 * win32-low.h (class win32_process_target): Update.
1088 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1090 Turn process_stratum_target's detach op into a method of
1093 * target.h (struct process_stratum_target): Remove the target op.
1094 (class process_target): Add the target op.
1095 (detach_inferior): Update the macro.
1097 Update the derived classes and callers below.
1099 * linux-low.cc (linux_target_ops): Update.
1100 (linux_detach): Turn into ...
1101 (linux_process_target::detach): ... this.
1102 * linux-low.h (class linux_process_target): Update.
1103 * lynx-low.cc (lynx_target_ops): Update.
1104 (lynx_detach): Turn into ...
1105 (lynx_process_target::detach): ... this.
1106 * lynx-low.h (class lynx_process_target): Update.
1107 * nto-low.cc (nto_target_ops): Update.
1108 (nto_detach): Turn into ...
1109 (nto_process_target::detach): ... this.
1110 * nto-low.h (class nto_process_target): Update.
1111 * win32-low.cc (win32_target_ops): Update.
1112 (win32_detach): Turn into ...
1113 (win32_process_target::detach): ... this.
1114 * win32-low.h (class win32_process_target): Update.
1116 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1118 Turn process_stratum_target's kill op into a method of
1121 * target.h (struct process_stratum_target): Remove the target op.
1122 (class process_target): Add the target op.
1124 Update the derived classes and callers below.
1126 * target.cc (kill_inferior): Update.
1127 * linux-low.cc (linux_target_ops): Update.
1128 (linux_kill): Turn into ...
1129 (linux_process_target::kill): ... this.
1130 * linux-low.h (class linux_process_target): Update.
1131 * lynx-low.cc (lynx_target_ops): Update.
1132 (lynx_kill): Turn into ...
1133 (lynx_process_target::kill): ... this.
1134 * lynx-low.h (class lynx_process_target): Update.
1135 * nto-low.cc (nto_target_ops): Update.
1136 (nto_kill): Turn into ...
1137 (nto_process_target::kill): ... this.
1138 * nto-low.h (class nto_process_target): Update.
1139 * win32-low.cc (win32_target_ops): Update.
1140 (win32_kill): Turn into ...
1141 (win32_process_target::kill): ... this.
1142 * win32-low.h (class win32_process_target): Update.
1144 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1146 Turn process_stratum_target's attach op into a method of
1149 * target.h (struct process_stratum_target): Remove the target op.
1150 (class process_target): Add the target op.
1151 (myattach): Update the macro.
1153 Update the derived classes and callers below.
1155 * linux-low.cc (linux_target_ops): Update.
1156 (linux_attach): Turn into ...
1157 (linux_process_target::attach): ... this.
1158 * linux-low.h (class linux_process_target): Update.
1159 * lynx-low.cc (lynx_target_ops): Update.
1160 (lynx_attach): Turn into ...
1161 (lynx_process_target::attach): ... this.
1162 * lynx-low.h (class lynx_process_target): Update.
1163 * nto-low.cc (nto_target_ops): Update.
1164 (nto_attach): Turn into ...
1165 (nto_process_target::attach): ... this.
1166 * nto-low.h (class nto_process_target): Update.
1167 * win32-low.cc (win32_target_ops): Update.
1168 (win32_attach): Turn into ...
1169 (win32_process_target::attach): ... this.
1170 * win32-low.h (class win32_process_target): Update.
1172 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1174 Turn process_stratum_target's post_create_inferior op into a method
1177 * target.h (struct process_stratum_target): Remove the target op.
1178 (class process_target): Add the target op.
1179 (target_post_create_inferior): Update the macro.
1180 * target.cc (process_target::post_create_inferior): Define.
1182 Update the derived classes and callers below.
1184 * linux-low.cc (linux_target_ops): Update.
1185 (linux_post_create_inferior): Turn into ...
1186 (linux_process_target::post_create_inferior): ... this.
1187 * linux-low.h (class linux_process_target): Update.
1188 * lynx-low.cc (lynx_target_ops): Update.
1189 * nto-low.cc (nto_target_ops): Update.
1190 * win32-low.cc (win32_target_ops): Update.
1192 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1194 Turn process_stratum_target's create_inferior op into a method of
1197 * target.h (struct process_stratum_target): Remove the target op.
1198 (class process_target): Add the target op.
1199 (create_inferior): Rename the macro to ...
1200 (target_create_inferior): ... this.
1202 Update the derived classes and callers below.
1204 * server.cc (handle_v_run): Update.
1205 (captured_main): Update.
1206 (process_serial_event): Update.
1207 * linux-low.cc (linux_target_ops): Update.
1208 (linux_create_inferior): Turn into ...
1209 (linux_process_target::create_inferior): ... this.
1210 * linux-low.h (class linux_process_target): Update.
1211 * lynx-low.cc (lynx_target_ops): Update.
1212 (lynx_create_inferior): Turn into ...
1213 (lynx_process_target::create_inferior): ... this.
1214 * lynx-low.h (class lynx_process_target): Update.
1215 * nto-low.cc (nto_target_ops): Update.
1216 (nto_create_inferior): Turn into ...
1217 (nto_process_target::create_inferior): ... this.
1218 * nto-low.h (class nto_process_target): Update.
1219 * win32-low.cc (win32_target_ops): Update.
1220 (win32_create_inferior): Turn into ...
1221 (win32_process_target::create_inferior): ... this.
1222 * win32-low.h (class win32_process_target): Update.
1224 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1226 * target.h (class process_target): New class definition.
1227 (struct process_stratum_target) <pt>: New field with type
1229 * linux-low.h (class linux_process_target): Define as a derived
1230 class of 'process_target'.
1231 * linux-low.cc (linux_target_ops): Add a linux_process_target*
1233 * lynx-low.h (class lynx_process_target): Define as a derived
1234 class of 'process_target'.
1235 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
1237 * nto-low.h (class nto_process_target): Define as a derived
1238 class of 'process_target'.
1239 * nto-low.cc (nto_target_ops): Add an nto_process_target*
1241 * win32-low.h (class win32_process_target): Define as a derived
1242 class of 'process_target'.
1243 * win32-low.cc (win32_target_ops): Add a win32_process_target*
1246 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
1248 * configure: Regenerate.
1250 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
1251 Andrew Burgess <andrew.burgess@embecosm.com>
1253 * linux-riscv-low.cc: New file.
1254 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
1255 and nat/riscv-linux-tdesc.c.
1256 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
1257 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
1260 2020-02-14 Tom Tromey <tom@tromey.com>
1262 * acinclude.m4: Don't include acx_configure_dir.m4.
1263 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
1264 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
1265 (all, install-only, uninstall, clean-info, clean)
1266 (maintainer-clean): Don't recurse.
1267 (subdir_do, all-lib): Remove.
1268 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
1270 (generated_files): Update.
1271 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
1272 * configure: Rebuild.
1273 * configure.ac: Don't configure gnulib or libiberty.
1276 2020-02-14 Eli Zaretskii <eliz@gnu.org>
1278 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
1279 preparing the command line for CreateProcess.
1280 (win32_create_inferior): Reflect the program name in debugging
1281 output that shows the process and its command line.
1283 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
1285 * Makefile.in: Rename source files from .c to .cc.
1286 * %.c: Rename to %.cc.
1287 * configure.ac: Rename server.c to server.cc.
1288 * configure: Re-generate.
1290 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
1292 * Makefile.in: Rename gdbsupport source files from .c to .cc.
1294 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
1296 * win32-low.c (win32_create_inferior): Set signal_pid.
1298 2020-02-12 Maciej W. Rozycki <macro@wdc.com>
1299 Pedro Alves <palves@redhat.com>
1301 Skip building gdbserver in a cross-configuration.
1302 * configure.srv: Set $gdbserver_host depending on whether $target
1303 is $host. Use $gdbserver_host instead of $host.
1305 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
1307 * configure: Re-generate.
1309 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
1311 * configure: Re-generate.
1313 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
1315 * acinclude.m4: Update warning.m4 path.
1317 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
1319 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
1320 (handle_exception): Set siginfo_er.
1321 (win32_xfer_siginfo): New function.
1323 2020-02-07 Tom Tromey <tom@tromey.com>
1324 Pedro Alves <palves@redhat.com>
1326 * README: Update build documentation.
1327 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
1329 * configure.ac: Update paths.
1330 * configure: Rebuild.
1331 * acinclude.m4: Update paths.
1332 * Makefile.in: Update include paths.
1333 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
1334 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
1335 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
1336 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
1337 (%-generated.c): Update paths.
1338 * Move entire directory from ../gdb/gdbserver.
1340 2020-01-29 Maciej W. Rozycki <macro@wdc.com>
1342 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
1344 2020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1346 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
1347 assignment instead of srv_linux_obj.
1349 2020-01-28 Hannes Domani <ssbssa@yahoo.de>
1351 * server.c (handle_qxfer_libraries): Write segment-address with
1354 2020-01-24 Hannes Domani <ssbssa@yahoo.de>
1356 * Makefile.in (install-strip): New target.
1357 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
1358 * aclocal.m4: Regenerate.
1359 * configure: Regenerate.
1360 * configure.ac: Add AM_PROG_INSTALL_STRIP.
1362 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
1364 * Makefile.in (SFILES): Adjust paths to point to real files.
1365 (OBS): Move waitstatus.o to target/waitstatus.o.
1366 (TAGS): Transform paths appropriately.
1368 (nat/%.o): ... this pattern rule.
1370 (target/%.o): ... this pattern rule.
1371 * configure.srv: Adjust paths throughout to include nat/ prefix
1372 with the revant files.
1373 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
1374 * configure: Regenerate.
1376 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
1378 * Makefile.in (TAGS): Remove config files from the recipe.
1380 2020-01-14 Tom Tromey <tom@tromey.com>
1382 * configure: Rebuild.
1383 * configure.ac: Remove any checks that were added to common.m4.
1384 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
1387 2020-01-14 Tom Tromey <tom@tromey.com>
1389 * server.h: Include config.h.
1390 * gdbreplay.c: Include config.h.
1391 * configure: Rebuild.
1392 * configure.ac: Don't source common.host.
1393 * acinclude.m4: Update path.
1394 * Makefile.in (INCSUPPORT): New variable.
1395 (INCLUDE_CFLAGS): Add INCSUPPORT.
1396 (SFILES): Update paths.
1397 (version-generated.c): Update path to create-version.sh.
1398 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
1400 2020-01-14 Tom Tromey <tom@tromey.com>
1402 * configure.ac (LIBS): Use WIN32APILIBS.
1403 (USE_WIN32API): Don't define.
1404 * configure: Rebuild.
1406 2020-01-14 Tom Tromey <tom@tromey.com>
1408 * configure: Rebuild.
1410 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1412 * Makefile.in (%-generated.c): Remove rule for files from
1415 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1417 * configure: Re-generate.
1419 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1421 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
1423 * tracepoint.c (stop_tracing, flush_trace_buffer,
1424 about_to_request_buffer_space, get_trace_state_variable_value,
1425 set_trace_state_variable_value, gdb_collect): Add declaration.
1427 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1429 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
1430 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
1431 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
1432 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
1433 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
1436 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1438 * inferiors.c: Include gdbsupport/common-inferior.h.
1440 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1442 * hostio-errno.c: Include hostio.h.
1444 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1446 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
1449 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
1451 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
1452 * linux-arm-tdesc.h: Include arch/arm.h.
1454 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
1456 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
1458 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
1460 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
1461 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
1463 2020-01-10 Pedro Alves <palves@redhat.com>
1465 * fork-child.c (post_fork_inferior): Pass target down to
1467 * inferiors.c (switch_to_thread): Add process_stratum_target
1469 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
1470 * nto-low.c (nto_target_ops): Now a process_stratum_target.
1471 * linux-low.c (linux_target_ops): Now a process_stratum_target.
1472 * remote-utils.c (prepare_resume_reply): Pass the target to
1474 * target.c (the_target): Now a process_stratum_target.
1475 (done_accessing_memory): Pass the target to switch_to_thread.
1476 (set_target_ops): Ajust to use process_stratum_target.
1477 * target.h (struct target_ops): Rename to ...
1478 (struct process_stratum_target): ... this.
1479 (the_target, set_target_ops): Adjust.
1480 (prepare_to_access_memory): Adjust comment.
1481 * win32-low.c (child_xfer_memory): Adjust to use
1482 process_stratum_target.
1483 (win32_target_ops): Now a process_stratum_target.
1485 2020-01-06 Eli Zaretskii <eliz@gnu.org>
1486 Pedro Alves <palves@redhat.com>
1488 * win32-low.c (get_child_debug_event): Extract the fatal exception
1489 from the exit status and convert to the equivalent Posix signal
1491 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
1492 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
1494 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
1496 * Makefile.in: Use INSTALL_PROGRAM_ENV.
1498 2020-01-01 Joel Brobecker <brobecker@adacore.com>
1500 * server.c (gdbserver_version): Change copyright year to 2020.
1501 * gdbreplay.c (gdbreplay_version): Likewise.
1503 2019-12-19 Christian Biesinger <cbiesinger@google.com>
1505 * configure: Regenerate.
1506 * configure.ac: Quote variable arguments of test.
1508 2019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
1510 * Makefile.in: Fix build with GNU Make 3.81
1512 2019-12-16 Tom Tromey <tromey@adacore.com>
1514 * server.c (get_exec_file): Constify result.
1516 2019-12-10 Christian Biesinger <cbiesinger@google.com>
1518 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
1519 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
1520 * config.in: Regenerate.
1521 * configure: Regenerate.
1522 * configure.ac: Don't check for strerror.
1523 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
1524 Call safe_strerror instead of strerror.
1525 * server.h (strerror): Remove this now-unnecessary declaration.
1526 * tracepoint.c (init_named_socket): Call safe_strerror instead of
1528 (gdb_agent_helper_thread): Likewise.
1529 * utils.c (perror_with_name): Likewise.
1531 2019-11-26 Tom Tromey <tom@tromey.com>
1533 * configure, config.in: Rebuild.
1535 2019-11-26 Tom Tromey <tom@tromey.com>
1537 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
1538 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
1540 * configure, config.in: Rebuild.
1542 2019-11-26 Tom Tromey <tom@tromey.com>
1544 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
1545 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
1546 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
1547 * acinclude.m4: Include ax_pthread.m4.
1548 * config.in, configure: Rebuild.
1550 2019-11-26 Christian Biesinger <cbiesinger@google.com>
1552 * debug.c (debug_set_output): Call safe_strerror instead of
1554 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
1555 (linux_kill_one_lwp): Likewise.
1556 (linux_detach_one_lwp): Likewise.
1557 (linux_wait_for_event_filtered): Likewise.
1558 (store_register): Likewise.
1559 * lynx-low.c (lynx_attach): Likewise.
1560 * mem-break.c (insert_memory_breakpoint): Likewise.
1561 (remove_memory_breakpoint): Likewise.
1562 (delete_fast_tracepoint_jump): Likewise.
1563 (set_fast_tracepoint_jump): Likewise.
1564 (uninsert_fast_tracepoint_jumps_at): Likewise.
1565 (reinsert_fast_tracepoint_jumps_at): Likewise.
1566 * nto-low.c (nto_xfer_memory): Likewise.
1567 (nto_resume): Likewise.
1569 2019-11-20 Luis Machado <luis.machado@linaro.org>
1571 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
1572 instead of register count.
1573 * tdesc.c (tdesc_contains_feature): New function.
1574 * tdesc.h (tdesc_contains_feature): New prototype.
1576 2019-11-15 Christian Biesinger <cbiesinger@google.com>
1578 * Makefile.in: Add safe-strerror.c.
1579 * configure: Regenerate.
1580 * configure.ac: Don't source common.host.
1582 2019-11-15 Christian Biesinger <cbiesinger@google.com>
1584 * config.in: Regenerate.
1585 * configure: Regenerate.
1587 2019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
1589 * ax.c (ax_printf): Handle size_t_arg.
1591 2019-11-06 Christian Biesinger <cbiesinger@google.com>
1593 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
1594 * mi/mi-main.c (output_cores): Likewise.
1595 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
1596 (linux_xfer_osdata_modules): Likewise.
1597 * remote.c (register_remote_support_xml): Likewise.
1598 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
1599 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
1601 2019-11-01 Christian Biesinger <cbiesinger@google.com>
1603 * configure: Regenerate.
1604 * configure.ac: Remove check for strerror_r.
1606 2019-10-31 Christian Biesinger <cbiesinger@google.com>
1608 * config.in: Regenerate.
1609 * configure: Regenerate.
1610 * configure.ac: Also check for strerror_r.
1612 2019-10-31 Christian Biesinger <cbiesinger@google.com>
1614 * ax.h (debug_agent): Remove duplicate declaration.
1616 2019-10-26 Tom de Vries <tdevries@suse.de>
1618 * linux-aarch64-low.c: Fix typos in comments.
1619 * linux-arm-low.c: Same.
1620 * linux-low.c: Same.
1621 * linux-ppc-low.c: Same.
1622 * proc-service.c: Same.
1625 * tracepoint.c: Same.
1626 * win32-low.c: Same.
1628 2019-10-25 Tom Tromey <tromey@adacore.com>
1630 * utils.c (xstrdup): Remove.
1632 2019-10-23 Tom Tromey <tom@tromey.com>
1634 * configure, config.in: Rebuild.
1636 2019-10-23 Tom Tromey <tom@tromey.com>
1638 * configure: Rebuild.
1639 * acinclude.m4: Use m4_include, not sinclude.
1641 2019-10-17 Tom Tromey <tromey@adacore.com>
1643 * configure: Rebuild.
1644 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
1645 in AC_CONFIG_FILES invocation.
1646 * Makefile.in (stamp-h, Makefile): Use new-style config.status
1649 2019-10-16 Christian Biesinger <cbiesinger@google.com>
1651 * server.c: Include xml-builtin.h.
1652 (get_xml_features): Don't declare xml_builtins here.
1654 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
1656 * Makefile.in: Remove references to vec-ipa.o.
1658 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
1660 * Makefile.in: Remove references to vec.c.
1662 2019-10-02 Christian Biesinger <cbiesinger@google.com>
1664 * server.c (server_waiting): Change to bool.
1665 (extended_protocol): Likewise.
1666 (response_needed): Likewise.
1667 (exit_requested): Likewise.
1668 (run_once): Likewise.
1669 (report_no_resumed): Likewise.
1670 (non_stop): Likewise.
1671 (disable_packet_vCont): Likewise.
1672 (disable_packet_Tthread): Likewise.
1673 (disable_packet_qC): Likewise.
1674 (disable_packet_qfThreadInfo): Likewise.
1675 (handle_general_set): Update.
1676 (handle_detach): Update.
1677 (handle_monitor_command): Update.
1678 (handle_query): Update.
1679 (captured_main): Update.
1680 (process_serial_event): Update.
1681 * server.h (server_waiting): Change to bool.
1682 (disable_packet_vCont): Likewise.
1683 (disable_packet_Tthread): Likewise.
1684 (disable_packet_qC): Likewise.
1685 (disable_packet_qfThreadInfo): Likewise.
1686 (run_once): Likewise.
1687 (non_stop): Likewise.
1688 * target.c (target_stop_and_wait): Update.
1690 2019-10-02 Tom Tromey <tromey@adacore.com>
1692 * Makefile.in (SFILES): Add common-inferior.c.
1693 (OBS): Add common-inferior.o.
1694 * server.c (startup_with_shell): Don't define.
1696 2019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
1698 * linux-low.c (linux_low_read_btrace): Update for change to
1701 2019-09-20 Christian Biesinger <cbiesinger@google.com>
1703 * debug.c (debug_threads): Remove comment in favor of the header.
1704 * debug.h (using_threads): Add declaration.
1705 (debug_threads): Add comment.
1706 * linux-aarch64-low.c: Include debug.h and remove declaration of
1708 * nto-low.c: Likewise.
1709 * remote-utils.c: Likewise.
1710 * thread-db.c: Likewise.
1712 2019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
1714 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
1715 and powerpc-cell64l-ipa.o.
1716 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
1717 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
1718 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
1721 * spu-low.c: Remove file.
1723 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
1724 (parse_spufs_run): Remove.
1725 (ppc_get_pc): Remove Cell/B.E. support.
1726 (ppc_set_pc): Likewise.
1727 (ppc_breakpoint_at): Likewise.
1728 (ppc_arch_setup): Likewise.
1729 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
1730 tdesc_powerpc_cell32l.
1731 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
1732 or init_registers_powerpc_cell32l.
1733 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
1734 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
1735 or init_registers_powerpc_cell32l.
1736 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
1737 (init_registers_powerpc_cell32l): Remove prototype.
1738 (init_registers_powerpc_cell64l): Likewise.
1740 * target.h (struct target_ops): Remove qxfer_spu member.
1741 * server.c (handle_qxfer_spu): Remove.
1742 (qxfer_packets): Remove entry for "spu".
1743 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
1744 * linux-low.c (SPUFS_MAGIC): Remove.
1745 (spu_enumerate_spu_ids): Remove.
1746 (linux_qxfer_spu): Remove.
1747 (linux_target_ops): Remove qxfer_spu member.
1748 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
1749 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
1750 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
1752 2019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
1754 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
1755 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
1756 * config.in: Regenerate.
1757 * configure: Regenerate.
1759 2019-08-15 Tom Tromey <tromey@adacore.com>
1761 * target.c (target_write_memory): Use gdb::byte_vector.
1763 2019-08-15 Tom Tromey <tromey@adacore.com>
1765 * tracepoint.c (write_inferior_data_pointer)
1766 (write_inferior_integer, write_inferior_int8)
1767 (write_inferior_uinteger, m_tracepoint_action_download)
1768 (r_tracepoint_action_download, x_tracepoint_action_download)
1769 (l_tracepoint_action_download, clear_inferior_trace_buffer)
1770 (download_agent_expr, download_tracepoint_1)
1771 (download_trace_state_variables, upload_fast_traceframes): Update.
1772 * server.c (gdb_write_memory): Update.
1773 * remote-utils.c (relocate_instruction): Update.
1774 * proc-service.c (ps_pdwrite): Update.
1775 * mem-break.c (remove_memory_breakpoint)
1776 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
1777 (uninsert_fast_tracepoint_jumps_at)
1778 (reinsert_fast_tracepoint_jumps_at): Update.
1779 * linux-x86-low.c (append_insns)
1780 (i386_install_fast_tracepoint_jump_pad)
1781 (amd64_write_goto_address, i386_write_goto_address): Update.
1782 * linux-s390-low.c (append_insns, s390_write_goto_address):
1784 * linux-ppc-low.c (ppc_relocate_instruction)
1785 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
1786 (ppc_write_goto_address): Update.
1787 * linux-aarch64-low.c (append_insns): Update.
1788 * target.h (struct target_ops): Update.
1789 (write_inferior_memory): Don't declare.
1790 * target.c (target_write_memory): Rename from
1791 write_inferior_memory. Remove old target_write_memory.
1793 2019-08-15 Tom Tromey <tromey@adacore.com>
1795 * target.c (write_inferior_memory): Use std::vector.
1797 2019-08-06 Frank Ch. Eigler <fche@redhat.com>
1800 * configure.ac: Drop enable-libmcheck support.
1801 * configure, config.in: Rebuild.
1802 * acinclude.m4: Don't include it.
1804 2019-07-19 Alan Hayward <alan.hayward@arm.com>
1806 * configure.srv: Remove Arm xml files.
1808 2019-07-19 Alan Hayward <alan.hayward@arm.com>
1810 * configure.srv: Add new files. Remove xml generated files.
1811 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
1813 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
1814 * linux-aarch32-tdesc.c: New file.
1815 * linux-aarch32-tdesc.h: New file.
1816 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
1817 * linux-arm-low.c (init_registers_arm, tdesc_arm)
1818 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
1819 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
1820 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
1821 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
1822 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
1823 (arm_read_description): Call arm_linux_read_description.
1824 (initialize_low_arch): Don't init registers.
1825 * linux-arm-tdesc.c: New file.
1826 * linux-arm-tdesc.h: New file.
1828 2019-07-10 Alan Hayward <alan.hayward@arm.com>
1830 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
1831 Move counter inside for.
1832 (arm_read_description): Check ptrace earlier.
1833 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
1835 2019-07-09 Tom Tromey <tom@tromey.com>
1837 * configure: Rebuild.
1838 * configure.ac: Change common to gdbsupport.
1839 * acinclude.m4: Change common to gdbsupport.
1840 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
1841 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
1842 common to gdbsupport.
1843 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
1844 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
1845 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
1846 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
1847 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
1848 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
1849 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
1850 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
1851 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
1852 common to gdbsupport.
1854 2019-07-04 Alan Hayward <alan.hayward@arm.com>
1856 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
1858 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
1860 2019-07-04 Alan Hayward <alan.hayward@arm.com>
1862 * configure.srv: Remove legacy xml.
1863 * linux-aarch64-low.c (initialize_low_arch): Remove
1864 initialize_low_tdesc call.
1865 * linux-aarch64-tdesc-selftest.c: Remove file.
1866 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
1867 * linux-x86-low.c (initialize_low_arch): Remove
1868 initialize_low_tdesc call.
1869 * linux-x86-tdesc-selftest.c: Remove file.
1870 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
1872 2019-06-20 Tom de Vries <tdevries@suse.de>
1874 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
1875 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
1877 2019-06-19 Tom de Vries <tdevries@suse.de>
1879 * debug.h (debug_write): Change return type to ssize_t.
1880 * debug.c (debug_write): Same.
1882 2019-06-14 Tom Tromey <tom@tromey.com>
1884 * configure.ac: Use new path to gnulib.
1885 * configure: Rebuild.
1886 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
1889 2019-06-11 Tom Tromey <tom@tromey.com>
1891 * Makefile.in (SFILES): Add alloc.c.
1893 (IPA_OBJS): Add alloc-ipa.o.
1894 (alloc-ipa.o): New target.
1895 (%.o: ../%.c): New pattern rule.
1897 2019-06-10 Tom Tromey <tromey@adacore.com>
1899 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
1900 end warning with a newline.
1901 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
1903 * thread-db.c (attach_thread): Don't end warning with a newline.
1904 (thread_db_notice_clone): Likewise.
1905 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
1907 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
1908 end warning with a newline.
1910 2019-06-04 Pedro Alves <palves@redhat.com>
1912 * server.c (captured_main): Use make_unique_xstrdup.
1914 2019-06-02 Tom Tromey <tom@tromey.com>
1916 * gdbreplay.c (fromhex): Remove.
1917 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
1919 2019-05-29 Tom Tromey <tromey@adacore.com>
1921 * configure: Rebuild.
1923 2019-05-06 Kevin Buettner <kevinb@redhat.com>
1925 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
1926 sign extension code on 32-bit builds.
1928 2019-05-03 Eli Zaretskii <eliz@gnu.org>
1931 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
1933 2019-04-19 Tom Tromey <tom@tromey.com>
1935 * server.c (struct vstop_notif): Derive from notif_event.
1937 (queue_stop_reply): Update.
1938 (remove_all_on_match_ptid): Change type. Rewrite.
1939 (discard_queued_stop_replies): Rewrite.
1940 (in_queued_stop_replies_ptid): Change type.
1941 (in_queued_stop_replies): Rewrite.
1942 (notif_stop): Update.
1943 (queue_stop_reply_callback): Update.
1944 (captured_main): Don't call initialize_notif.
1945 (push_stop_notification): Update.
1946 * notif.c (notif_write_event, handle_notif_ack)
1947 (notif_event_enque, notif_push): Update.
1948 (notif_event_xfree, initialize_notif): Remove.
1949 * notif.h (struct notif_event): Include <list>, not
1951 (struct notif_server) <queue>: Now a std::list.
1952 (notif_event_p): Remove typedef.
1953 (initialize_notif): Don't declare.
1954 (struct notif_event): Add virtual destructor.
1956 2019-04-17 Alan Hayward <alan.hayward@arm.com>
1958 * ax.c (ax_vdebug): Call debug_printf.
1959 * debug.c (debug_write): New function.
1960 * debug.h (debug_write): New declaration.
1961 * linux-low.c (sigchld_handler): Call debug_write.
1963 2019-04-17 Alan Hayward <alan.hayward@arm.com>
1965 * debug.c (debug_set_output): New function.
1966 (debug_vprintf): Send output to debug_file.
1967 (debug_flush): Likewise.
1968 * debug.h (debug_set_output): New declaration.
1969 * server.c (handle_monitor_command): Add debug-file option.
1970 (captured_main): Likewise.
1972 2019-04-17 Alan Hayward <alan.hayward@arm.com>
1974 * debug.c (remote_debug): Add definition.
1975 * debug.h (remote_debug): Add declaration.
1976 * hostio.c (remote_debug): Remove declaration.
1977 * remote-utils.c (struct ui_file): Likewise.
1978 (remote_debug): Likewise.
1979 * remote-utils.h (remote_debug): Likewise,
1980 * server.c (remote_debug): Remove definition.
1982 2019-04-10 Kevin Buettner <kevinb@redhat.com>
1984 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
1985 when using a 64-bit gdbserver.
1987 2019-04-09 Tom Tromey <tromey@adacore.com>
1989 * linux-low.c (select_event_lwp): Use find_thread_in_random.
1991 2019-04-08 Tom Tromey <tom@tromey.com>
1993 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
1995 (linux_resume_one_lwp): Likewise.
1997 2019-04-08 Tom Tromey <tom@tromey.com>
1999 * gdbreplay.c: Update.
2000 * linux-low.c: Update.
2003 2019-04-08 Tom Tromey <tom@tromey.com>
2005 * server.c: Use C++ exception handling.
2006 * linux-low.c: Use C++ exception handling.
2007 * gdbreplay.c: Use C++ exception handling.
2009 2019-04-08 Tom Tromey <tom@tromey.com>
2011 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
2012 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
2013 (captured_main, main): Update.
2014 * gdbreplay.c (main): Update.
2016 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2018 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
2019 value in argument pointer, return 1 if the entry is found and 0
2020 otherwise. Move comment.
2021 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
2022 * linux-low.h (linux_get_auxv): Declare.
2023 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
2025 2019-04-05 Tom Tromey <tromey@adacore.com>
2027 * server.c (gdbserver_usage): Use upper-case for metasyntactic
2030 2019-03-28 Alan Hayward <alan.hayward@arm.com>
2032 * linux-low.c (AT_HWCAP2): Add define if not already included.
2034 2019-03-26 Alan Hayward <alan.hayward@arm.com>
2036 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
2037 (aarch64_arch_setup): Call linux_get_hwcap.
2038 * linux-arm-low.c (arm_get_hwcap): Remove function.
2039 (arm_read_description): Call linux_get_hwcap.
2040 * linux-low.c (linux_get_auxv): New function.
2041 (linux_get_hwcap): Likewise.
2042 (linux_get_hwcap2): Likewise.
2043 * linux-low.h (linux_get_hwcap): New declaration.
2044 (linux_get_hwcap2): Likewise.
2045 * linux-ppc-low.c (ppc_get_auxv): Remove function.
2046 (ppc_arch_setup): Call linux_get_hwcap.
2047 * linux-s390-low.c (s390_get_hwcap): Remove function.
2048 (s390_arch_setup): Call linux_get_hwcap.
2050 2019-03-22 Alan Hayward <alan.hayward@arm.com>
2051 Jiong Wang <jiong.wang@arm.com>
2053 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
2054 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
2056 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
2058 2019-03-22 Alan Hayward <alan.hayward@arm.com>
2059 Jiong Wang <jiong.wang@arm.com>
2061 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
2062 (aarch64_get_hwcap): New function.
2063 (aarch64_arch_setup): Read APIA hwcap.
2065 2019-03-22 Alan Hayward <alan.hayward@arm.com>
2066 Jiong Wang <jiong.wang@arm.com>
2068 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
2069 (initialize_low_tracepoint): Likewise.
2070 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
2071 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
2072 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
2073 (aarch64_linux_read_description): Likewise.
2074 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
2076 2019-03-12 John Baldwin <jhb@FreeBSD.org>
2078 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
2079 i386_create_target_description for 'segments' parameter.
2080 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
2081 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
2082 * win32-i386-low.c (i386_arch_setup): Likewise.
2084 2019-03-12 Tom Tromey <tromey@adacore.com>
2086 * linux-low.c (iterate_over_lwps): Update.
2088 2019-03-06 Tom Tromey <tom@tromey.com>
2090 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
2091 (captured_main): Use SCOPE_EXIT.
2093 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
2095 * configure.srv: Use '$enable_unittest' instead of '$development'
2096 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
2099 2019-02-27 Tom Tromey <tromey@adacore.com>
2101 * gdbreplay.c (logchar): Handle \r\n.
2103 2019-02-07 Alan Hayward <alan.hayward@arm.com>
2105 * linux-low.c (linux_attach): Add process before lwp.
2106 * server.c (attach_inferior): Check if already attached.
2108 2019-02-07 Tom Tromey <tom@tromey.com>
2110 * x86-tdesc.h: Rename include guard.
2111 * x86-low.h: Add include guard.
2112 * wincecompat.h: Rename include guard.
2113 * win32-low.h: Add include guard.
2114 * utils.h: Rename include guard.
2115 * tracepoint.h: Rename include guard.
2116 * tdesc.h: Rename include guard.
2117 * target.h: Rename include guard.
2118 * server.h: Rename include guard.
2119 * remote-utils.h: Rename include guard.
2120 * regcache.h: Rename include guard.
2121 * nto-low.h: Rename include guard.
2122 * notif.h: Add include guard.
2123 * mem-break.h: Rename include guard.
2124 * lynx-low.h: Add include guard.
2125 * linux-x86-tdesc.h: Add include guard.
2126 * linux-s390-tdesc.h: Add include guard.
2127 * linux-ppc-tdesc-init.h: Add include guard.
2128 * linux-low.h: Add include guard.
2129 * linux-aarch64-tdesc.h: Add include guard.
2130 * linux-aarch32-low.h: Add include guard.
2131 * inferiors.h: Rename include guard.
2132 * i387-fp.h: Rename include guard.
2133 * hostio.h: Rename include guard.
2134 * gdbthread.h: Rename include guard.
2135 * gdb_proc_service.h: Rename include guard.
2136 * event-loop.h: Rename include guard.
2137 * dll.h: Rename include guard.
2138 * debug.h: Rename include guard.
2139 * ax.h: Rename include guard.
2141 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
2144 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
2145 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
2147 2019-01-25 Tom Tromey <tom@tromey.com>
2149 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
2151 2019-01-25 Tom Tromey <tom@tromey.com>
2153 * win32-low.c: Fix common/ includes.
2154 * win32-i386-low.c: Fix common/ includes.
2155 * tracepoint.c: Fix common/ includes.
2156 * thread-db.c: Fix common/ includes.
2157 * target.h: Fix common/ includes.
2158 * symbol.c: Fix common/ includes.
2159 * spu-low.c: Fix common/ includes.
2160 * server.h: Fix common/ includes.
2161 * server.c: Fix common/ includes.
2162 * remote-utils.c: Fix common/ includes.
2163 * regcache.h: Fix common/ includes.
2164 * regcache.c: Fix common/ includes.
2165 * nto-x86-low.c: Fix common/ includes.
2166 * notif.h: Fix common/ includes.
2167 * mem-break.h: Fix common/ includes.
2168 * lynx-low.c: Fix common/ includes.
2169 * lynx-i386-low.c: Fix common/ includes.
2170 * linux-x86-tdesc-selftest.c: Fix common/ includes.
2171 * linux-x86-low.c: Fix common/ includes.
2172 * linux-low.c: Fix common/ includes.
2173 * inferiors.h: Fix common/ includes.
2174 * i387-fp.c: Fix common/ includes.
2175 * hostio.c: Fix common/ includes.
2176 * hostio-errno.c: Fix common/ includes.
2177 * gdbthread.h: Fix common/ includes.
2178 * gdbreplay.c: Fix common/ includes.
2179 * fork-child.c: Fix common/ includes.
2180 * event-loop.c: Fix common/ includes.
2182 (enum gdb_agent_op): Fix common/ includes.
2184 2019-01-21 Tom Tromey <tom@tromey.com>
2186 * tracepoint.c: Fix includes.
2187 * remote-utils.c: Fix includes.
2188 * linux-x86-low.c: Fix includes.
2190 2019-01-01 Joel Brobecker <brobecker@adacore.com>
2192 * gdbreplay.c (gdbreplay_version): Update copyright year in
2194 * server.c (gdbserver_version): Likewise.
2196 2018-12-05 Alan Hayward <alan.hayward@arm.com>
2198 * linux-low.c (add_lwp): Switch ordering.
2200 2018-11-29 Tom Tromey <tom@tromey.com>
2202 * win32-low.c (win32_join): Take pid, not process.
2203 * target.h (struct target_ops) <join>: Change argument type.
2204 (join_inferior): Change argument name.
2205 * spu-low.c (spu_join): Take pid, not process.
2206 * server.c (handle_detach): Preserve pid before destroying
2208 * lynx-low.c (lynx_join): Take pid, not process.
2209 * linux-low.c (linux_join): Take pid, not process.
2211 2018-11-23 Alan Hayward <alan.hayward@arm.com>
2213 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
2214 (aarch64_cannot_fetch_register): Likewise.
2215 (struct linux_target_ops): Update references.
2217 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2219 * linux-ppc-low.c: Include nat/linux-ptrace.h.
2221 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2223 * configure.srv (ipa_ppc_linux_regobj): Add
2224 powerpc-isa207-htm-vsx32l-ipa.o and
2225 powerpc-isa207-htm-vsx64l-ipa.o.
2226 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
2227 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
2228 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
2229 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
2230 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
2231 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
2232 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
2233 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
2234 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
2235 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
2236 (init_registers_powerpc_isa207_htm_vsx32l)
2237 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
2238 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
2239 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
2240 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
2241 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
2242 (ppc_store_tm_ctarregset): New functions.
2243 (ppc_regsets): Add entries for HTM regsets.
2244 (ppc_arch_setup): Set htm in features struct when needed. Set
2245 sizes for the HTM regsets.
2246 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
2247 (initialize_low_arch): Call
2248 init_registers_powerpc_isa207_htm_vsx32l and
2249 init_registers_powerpc_isa207_htm_vsx64l.
2250 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
2251 PPC_TDESC_ISA207_HTM_VSX.
2252 (initialize_low_tracepoint): Call
2253 init_registers_powerpc_isa207_htm_vsx32l and
2254 init_registers_powerpc_isa207_htm_vsx64l.
2256 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2258 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
2259 rs6000/power-linux-pmu.xml to srv_xmlfiles.
2260 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
2261 (ppc_store_pmuregset): New functions.
2262 (ppc_regsets): Add entries for ebb and pmu regsets.
2263 (ppc_arch_setup): Set isa207 in features struct if the ebb and
2264 pmu regsets are available. Set sizes for these regsets.
2266 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2268 * configure.srv (ipa_ppc_linux_regobj): Add
2269 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
2270 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
2271 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
2272 rs6000/powerpc-isa207-vsx32l.xml, and
2273 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
2274 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
2275 <PPC_TDESC_ISA207_VSX>: New enum value.
2276 (init_registers_powerpc_isa207_vsx32l): Declare.
2277 (init_registers_powerpc_isa207_vsx64l): Declare.
2278 * linux-ppc-low.c (ppc_fill_tarregset): New function.
2279 (ppc_store_tarregset): New function.
2280 (ppc_regsets): Add entry for the TAR regset.
2281 (ppc_arch_setup): Set isa207 in features struct when needed. Set
2282 size for the TAR regsets.
2283 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
2284 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
2285 and init_registers_powerpc_isa207_vsx64l.
2286 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
2287 (initialize_low_tracepoint): Call
2288 init_registers_powerpc_isa207_vsx32l and
2289 init_registers_powerpc_isa207_vsx64l.
2291 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
2292 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2294 * configure.srv (ipa_ppc_linux_regobj): Add
2295 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
2296 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
2297 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
2298 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
2299 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
2300 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
2301 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
2302 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
2303 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
2304 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
2305 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
2306 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
2307 (ppc_hwcap): Add comment.
2308 (ppc_hwcap2): New global.
2309 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
2310 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
2311 (ppc_regsets): Add entries for the DSCR and PPR regsets.
2312 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
2313 when needed. Set sizes for the the DSCR and PPR regsets.
2314 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
2315 (initialize_low_arch): Call
2316 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
2317 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
2318 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
2319 PPC_TDESC_ISA205_PPR_DSCR_VSX.
2320 (initialize_low_tracepoint): Call
2321 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
2322 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
2324 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2326 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
2328 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
2329 Simon Marchi <simark@simark.ca>
2331 * acinclude.m4: Include "../selftest.m4".
2332 * configure: Regenerate.
2333 * configure.ac: Use "GDB_AC_SELFTEST".
2334 * configure.srv: Use "$enable_unittests" instead of
2335 "$development" when checking whether unit tests have been
2337 * server.c (captured_main): Update message informing that
2338 selftests have been disabled.
2340 2018-10-04 Tom Tromey <tom@tromey.com>
2342 * configure: Rebuild.
2344 2018-10-04 Tom Tromey <tom@tromey.com>
2346 * server.c (handle_status): Rename inner "thread".
2347 (process_serial_event): Declare "res" in 'm' case.
2348 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
2349 (iterate_over_lwps): Rename inner "thread".
2350 (linux_qxfer_libraries_svr4): Rename inner "len".
2351 * gdbthread.h (find_thread_in_random): Rename inner "thread".
2353 2018-10-01 Gary Benson <gbenson@redhat.com>
2355 * gdb_proc_service.h: Moved common code to
2356 common/gdb_proc_service.h.
2358 2018-10-01 Gary Benson <gbenson@redhat.com>
2360 * gdb_proc_service.h: Synchronize comments and whitespace with
2361 GDB's version of this file.
2363 2018-09-25 Tom Tromey <tom@tromey.com>
2365 * configure: Rebuild.
2366 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
2368 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
2370 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
2371 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
2372 ($(IPA_LIB)): Sort IPA_OBJS.
2374 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
2376 * Makefile.in: Remove references to $(ADD_DEPS).
2378 2018-09-16 Tom Tromey <tom@tromey.com>
2380 * remote-utils.c (remote_open): Use GNU style for metasyntactic
2382 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
2385 2018-09-05 Tom Tromey <tom@tromey.com>
2387 * configure: Rebuild.
2389 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
2392 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
2394 2018-08-27 Tom Tromey <tom@tromey.com>
2397 * configure: Rebuild.
2399 2018-08-27 Tom Tromey <tom@tromey.com>
2401 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
2402 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
2403 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
2404 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
2405 (s390x_emit_stack_adjust): Add casts to unsigned char.
2407 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
2411 * server.h (struct client_state) <disable_randomization>:
2414 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2416 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
2418 (mips_supply_ptrace_register): Likewise.
2420 2018-07-22 Tom Tromey <tom@tromey.com>
2422 * configure: Rebuild.
2424 2018-07-22 Tom Tromey <tom@tromey.com>
2426 * win32-low.c (win32_create_inferior): Remove unused variables.
2427 * gdbreplay.c (remote_open): Remove unused variable.
2428 * remote-utils.c (remote_prepare): Remove unused variable.
2429 * x86-tdesc.h (X86_TDESC_H): Define.
2430 (amd64_expedite_regs): Define conditionally.
2431 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
2432 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
2433 * remote-utils.c (readchar): Remove unused variable.
2435 2018-07-13 Pedro Alves <palves@redhat.com>
2437 * linux-low.c (linux_kill): Change parameter to process_info
2438 pointer instead of pid. Adjust.
2439 * lynx-low.c (lynx_kill): Likewise.
2440 * nto-low.c (nto_kill): Likewise.
2441 * spu-low.c (spu_kill): Likewise.
2442 * win32-low.c (win32_kill): Likewise.
2443 * server.c (handle_v_kill, kill_inferior_callback)
2444 (detach_or_kill_for_exit): Adjust.
2445 * target.c (kill_inferior): Change parameter to process_info
2446 pointer instead of pid. Adjust.
2447 * target.h (struct target_ops) <kill>: Change parameter to
2448 process_info pointer instead of pid. Adjust all implementations
2450 (kill_inferior): Likewise.
2452 2018-07-13 Pedro Alves <palves@redhat.com>
2454 * linux-low.c (linux_detach, linux_join): Change parameter to
2455 process_info pointer instead of pid. Adjust.
2456 * lynx-low.c (lynx_detach, lynx_join): Likewise.
2457 * nto-low.c (nto_detach): Likewise.
2458 * spu-low.c (spu_detach, spu_join): Likewise.
2459 * win32-low.c (win32_detach, win32_join): Likewise.
2460 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
2461 * target.h (struct target_ops) <detach, join>: Change parameter to
2462 process_info pointer instead of pid. Adjust all implementations
2464 (detach_inferior, join_inferior): Rename 'pid' parameter to
2467 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
2468 Jan Kratochvil <jan.kratochvil@redhat.com>
2469 Paul Fertser <fercerpav@gmail.com>
2470 Tsutomu Seki <sekiriki@gmail.com>
2472 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
2473 (OBS): Add 'common/netstuff.o'.
2474 (GDBREPLAY_OBS): Likewise.
2475 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
2476 (remote_open): Implement support for IPv6
2478 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
2480 (handle_accept_event): Accept connections from IPv6 sources.
2481 (remote_prepare): Handle IPv6-style hostnames; implement
2482 support for IPv6 connections.
2483 (remote_open): Implement support for printing connections from
2486 2018-07-11 Pedro Alves <palves@redhat.com>
2489 * mem-break.c (any_persistent_commands): Add process_info
2490 parameter and use it instead of relying on the current process.
2491 Change return type to bool.
2492 * mem-break.h (any_persistent_commands): Add process_info
2493 parameter and change return type to bool.
2494 * server.c (handle_detach): Remove require_running_or_return call.
2495 Look up the process_info for the process we're about to detach.
2496 If not found, return back error to GDB. Adjust
2497 any_persistent_commands call to pass down a process pointer.
2499 2018-07-11 Pedro Alves <palves@redhat.com>
2501 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
2502 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
2503 instead of collect_register_by_name.
2504 * regcache.c (regcache_raw_get_unsigned_by_name): New.
2505 * regcache.h (regcache_raw_get_unsigned_by_name): New.
2507 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
2508 Pedro Alves <palves@redhat.com>
2510 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
2512 2018-07-03 Tom Tromey <tom@tromey.com>
2514 * linux-low.c: Update.
2515 * lynx-low.c: Update.
2516 * mem-break.c: Update.
2517 * nto-low.c: Update.
2518 * remote-utils.c: Update.
2520 * spu-low.c: Update.
2522 * win32-low.c: Update.
2524 2018-07-03 Tom Tromey <tom@tromey.com>
2528 2018-07-03 Tom Tromey <tom@tromey.com>
2530 * linux-low.c: Update.
2532 2018-07-03 Tom Tromey <tom@tromey.com>
2536 2018-07-03 Tom Tromey <tom@tromey.com>
2538 * linux-low.c: Update.
2539 * linux-mips-low.c: Update.
2540 * lynx-low.c: Update.
2541 * nto-low.c: Update.
2542 * remote-utils.c: Update.
2544 * spu-low.c: Update.
2546 * thread-db.c: Update.
2548 2018-07-03 Tom Tromey <tom@tromey.com>
2550 * linux-low.c: Update.
2551 * linux-mips-low.c: Update.
2552 * lynx-low.c: Update.
2553 * mem-break.c: Update.
2554 * nto-low.c: Update.
2555 * remote-utils.c: Update.
2557 * spu-low.c: Update.
2559 * tracepoint.c: Update.
2561 2018-07-03 Tom Tromey <tom@tromey.com>
2563 * linux-low.c: Update.
2564 * linux-ppc-low.c: Update.
2565 * linux-x86-low.c: Update.
2566 * proc-service.c: Update.
2568 * spu-low.c: Update.
2569 * thread-db.c: Update.
2570 * win32-low.c: Update.
2572 2018-07-03 Tom Tromey <tom@tromey.com>
2574 * linux-low.c: Update.
2575 * lynx-low.c: Update.
2576 * nto-low.c: Update.
2577 * remote-utils.c: Update.
2578 * spu-low.c: Update.
2579 * thread-db.c: Update.
2580 * win32-low.c: Update.
2582 2018-06-29 Joel Brobecker <brobecker@adacore.com>
2584 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
2585 parameter in call to 'amd64_create_target_description'.
2587 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
2589 * x86-tdesc.h: Remove executable permission flag.
2591 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
2593 * configure.ac: Remove AC_PREREQ, add missing quoting.
2594 * configure: Re-generate.
2595 * config.in: Re-generate.
2596 * aclocal.m4: Re-generate.
2598 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
2600 * tracepoint.h (current_traceframe): Remove declaration.
2602 2018-06-18 Alan Hayward <alan.hayward@arm.com>
2604 * linux-aarch64-low.c (is_sve_tdesc): New function.
2605 (aarch64_sve_regs_copy_to_regcache): Likewise.
2606 (aarch64_sve_regs_copy_from_regcache): Likewise.
2607 (aarch64_regs_info): Add SVE checks.
2608 (initialize_low_arch): Initialize SVE.
2610 2018-06-18 Alan Hayward <alan.hayward@arm.com>
2612 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
2614 2018-06-11 Alan Hayward <alan.hayward@arm.com>
2616 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
2617 (initialize_low_tracepoint): Likewise
2618 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
2619 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
2621 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
2623 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
2625 2018-06-11 Alan Hayward <alan.hayward@arm.com>
2627 * server.h (PBUFSIZ): Increase size
2629 2018-06-11 Alan Hayward <alan.hayward@arm.com>
2631 * regcache.c (regcache::raw_compare): New function.
2632 * regcache.h (regcache::raw_compare): New declaration.
2634 2018-06-11 Alan Hayward <alan.hayward@arm.com>
2636 * regcache.c (new_register_cache): Use new.
2637 (free_register_cache): Use delete.
2638 (register_data): Use const.
2639 (supply_register): Move body inside regcache.
2640 (regcache::raw_supply): New override function.
2641 (collect_register): Move body inside regcache.
2642 (regcache::raw_collect): New override function.
2643 (regcache::get_register_status): New override function.
2644 * regcache.h (struct regcache): Inherit from reg_buffer_common.
2646 2018-06-09 Tom Tromey <tom@tromey.com>
2648 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
2650 (event_queue): Use std::queue.
2651 (gdb_event_xfree): Remove.
2652 (initialize_event_loop, process_event, wait_for_event): Update.
2654 2018-06-08 Stan Cox <scox@redhat.com>
2656 * win32-low.c (win32_create_inferior): last_ptid and last_status
2657 moved to client_state.
2659 2018-06-08 Pedro Alves <palves@redhat.com>
2661 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
2662 common/common-exceptions.o, common/common-utils.o,
2663 common/errors.o, common/print-utils.o and utils.o.
2664 * gdbreplay.c: Include "common-defs.h" instead of the two
2665 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
2666 string.h or alloca.h.
2667 (perror_with_name): Delete.
2668 (remote_open): Use xstrdup instead of strdup.
2669 (main): Rename to ...
2670 (captured_main): ... this.
2673 2018-06-08 Tom Tromey <tom@tromey.com>
2675 * linux-low.c (linux_low_read_btrace): Update.
2677 2018-06-04 Stan Cox <scox@redhat.com>
2679 * server.h (struct client_state): New.
2680 * server.c (cont_thread, general_thread, multi_process)
2681 (report_fork_events, report_vfork_events, report_exec_events)
2682 (report_thread_events, swbreak_feature, hwbreak_feature)
2683 (vCont_supported, disable_randomization, pass_signals)
2684 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
2685 Moved to client_state.
2686 * remote-utils.c (remote_debug, noack_mode)
2687 (transport_is_reliable): Moved to client_state.
2688 * tracepoint.c (current_traceframe): Moved to client_state.
2691 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
2692 linux-low.c, remote-utils.h, target.c: Use client_state.
2694 2018-05-31 Alan Hayward <alan.hayward@arm.com>
2696 * configure.srv: Add new c/h file.
2698 2018-05-31 Alan Hayward <alan.hayward@arm.com>
2700 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
2703 2018-05-25 Maciej W. Rozycki <macro@mips.com>
2705 * gdb.arch/mips-fpregset-core.exp: New test.
2706 * gdb.arch/mips-fpregset-core.c: New test source.
2708 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
2711 * hostio.c (require_int): Do not report overflow for integers
2712 between 0xfffffff and 0x7fffffff.
2714 2018-05-22 Maciej W. Rozycki <macro@mips.com>
2716 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
2717 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
2718 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
2720 (the_low_target): Wire them.
2722 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2724 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
2725 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
2726 mode. Call collect_register_by_name with vscr using
2727 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
2728 (ppc_store_vrregset): Add and set vscr_offset variable as in
2729 ppc_fill_vrregset. Call supply_register_by_name with vscr using
2732 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2734 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
2735 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
2736 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
2738 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2740 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
2741 (ppc_store_vsxregset): Likewise.
2742 (ppc_fill_vrregset): Likewise.
2743 (ppc_store_vrregset): Likewise.
2744 (ppc_fill_evrregset): Likewise.
2745 (ppc_store_evrregset): Likewise.
2746 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
2747 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
2750 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2752 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
2753 wordsize of the inferior. Call ppc_linux_target_wordsize.
2755 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2757 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
2758 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
2759 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
2760 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
2761 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
2762 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
2763 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
2764 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
2765 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
2766 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
2767 (tdesc_powerpc_e500l): Remove.
2768 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
2769 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
2770 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
2771 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
2773 (ppc_arch_setup): Remove target description matching code. Fill a
2774 ppc_linux_features struct and call ppc_linux_match_description
2777 2018-05-22 Maciej W. Rozycki <macro@mips.com>
2779 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
2780 width of the requested register exceeds the width of the
2782 (mips_cannot_store_register): Likewise.
2784 2018-05-21 Maciej W. Rozycki <macro@mips.com>
2786 * linux-mips-low.c (mips_fetch_register): New function. Update
2788 (mips_store_gregset): Supply 0 rather than $restart for $zero.
2789 (the_low_target): Wire `mips_fetch_register'.
2791 2018-05-10 Joel Brobecker <brobecker@adacore.com>
2793 * lynx-i386-low.c (LYNXOS_178): New macro.
2794 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
2795 the layout on LynxOS-178.
2796 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
2797 handle floating point registers that are not supported by
2800 2018-05-10 Tom Tromey <tom@tromey.com>
2802 * configure: Rebuild.
2804 2018-05-10 Joel Brobecker <brobecker@adacore.com>
2807 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
2808 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
2809 Use it to set the expedite_regs field in the given tdesc.
2810 * x86-tdesc.h: New file.
2811 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
2812 Adjust following the addition of the new expedite_regs parameter
2813 to init_target_desc.
2814 * linux-tic6x-low.c (tic6x_read_description): Likewise.
2815 * linux-x86-tdesc.c: #include "x86-tdesc.h".
2816 (i386_linux_read_description, amd64_linux_read_description):
2817 Adjust following the addition of the new expedite_regs parameter
2818 to init_target_desc.
2819 * lynx-i386-low.c: #include "x86-tdesc.h".
2820 (lynx_i386_arch_setup): Adjust following the addition of the new
2821 expedite_regs parameter to init_target_desc.
2822 * nto-x86-low.c: #include "x86-tdesc.h".
2823 (nto_x86_arch_setup): Adjust following the addition of the new
2824 expedite_regs parameter to init_target_desc.
2825 * win32-i386-low.c: #include "x86-tdesc.h".
2826 (i386_arch_setup): Adjust following the addition of the new
2827 expedite_regs parameter to init_target_desc.
2829 2018-05-10 Joel Brobecker <brobecker@adacore.com>
2832 * win32-low.c (win32_create_inferior): Add call to my_wait
2833 setting last_status global.
2835 2018-05-10 Joel Brobecker <brobecker@adacore.com>
2838 * win32-low.c (create_process): Only call gdb_tilde_expand if
2839 inferior_cwd is not NULL.
2841 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
2843 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
2844 registers to the cache if their values have changed.
2845 (i387_xsave_to_cache): Provide default values for x87 control
2846 registers when these features are available, but disabled.
2847 * regcache.c (supply_register_by_name_zeroed): New function.
2848 * regcache.h (supply_register_by_name_zeroed): Declare new
2851 2018-05-07 Tom Tromey <tom@tromey.com>
2853 * configure: Rebuild.
2855 2018-05-04 Tom Tromey <tom@tromey.com>
2857 * configure: Rebuild.
2859 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
2860 Pedro Alves <palves@redhat.com>
2862 * linux-aarch64-low.c (aarch64_stopped_data_address):
2865 2018-04-27 Tom Tromey <tom@tromey.com>
2867 * configure: Rebuild.
2869 2018-04-23 Tom Tromey <tom@tromey.com>
2871 * configure: Rebuild.
2873 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
2875 * Makefile.in (depcomp): Add "..".
2876 (all_deps_files): New and use it.
2878 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2880 * configure.srv (aarch64*-*-linux*): Don't include xml.
2881 (i[34567]86-*-cygwin*): Likewise.
2882 (i[34567]86-*-linux*): Likewise.
2883 (i[34567]86-*-lynxos*): Likewise.
2884 (i[34567]86-*-mingw32ce*): Likewise.
2885 (i[34567]86-*-mingw*): Likewise.
2886 (i[34567]86-*-nto*): Likewise.
2887 (tic6x-*-uclinux): Likewise.
2888 (x86_64-*-linux*): Likewise.
2889 (x86_64-*-mingw*): Likewise.
2890 (x86_64-*-cygwin*): Likewise.
2892 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2894 * tdesc.c: Remove xml parameter.
2896 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2898 * server.c (get_features_xml): Remove cast.
2899 * tdesc.c (void target_desc::accept): Fill in function.
2900 (tdesc_get_features_xml): Remove old xml creation.
2901 (print_xml_feature::visit_pre): Add xml vistor.
2902 * tdesc.h (struct target_desc): Make xmltarget mutable.
2903 (tdesc_get_features_xml): Remove declaration.
2905 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2907 * tdesc.c (tdesc_architecture_name): Add new function.
2908 (tdesc_osabi_name): Likewise.
2909 (tdesc_get_features_xml): Use new functions.
2911 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2913 * tdesc.c (tdesc_create_flags): Remove.
2914 (tdesc_add_flag): Likewise.
2915 (tdesc_named_type): Likewise.
2916 (tdesc_create_union): Likewise.
2917 (tdesc_create_struct): Likewise.
2918 (tdesc_create_vector): Likewise.
2919 (tdesc_add_bitfield): Likewise.
2920 (tdesc_add_field): Likewise.
2921 (tdesc_set_struct_size): Likewise.
2923 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2925 * tdesc.c (~target_desc): Remove implictly deleted items.
2926 (init_target_desc): Iterate all features.
2927 (tdesc_get_features_xml): Use vector.
2928 (tdesc_create_feature): Create feature.
2929 * tdesc.h (tdesc_feature) Remove
2930 (target_desc): Add features.
2932 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2934 * Makefile.in: Add common/tdesc.c
2935 * tdesc.c (init_target_desc): init all reg_defs from register
2937 (tdesc_create_reg): Create tdesc_reg.
2938 * tdesc.h (tdesc_feature): Add register vector.
2940 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
2942 * tdesc.h (struct target_desc) <features>: Change type to
2943 std::vector<std::string>.
2944 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
2946 (tdesc_get_features_xml): Likewise.
2947 (tdesc_create_feature): Likewise.
2949 2018-03-26 Alan Hayward <alan.hayward@arm.com>
2951 * regcache.c (find_register_by_number): Return a ref.
2952 (find_regno): Use references.
2953 (register_size): Likewise.
2954 (register_data): Likewise.
2955 * tdesc.c (target_desc::~target_desc): Remove free calls.
2956 (target_desc::operator==): Use std::vector compare.
2957 (init_target_desc): Use reference.
2958 (tdesc_create_reg): Use reg constructors.
2959 * tdesc.h (struct target_desc): Replace pointer with object.
2961 2018-03-23 Alan Hayward <alan.hayward@arm.com>
2963 * regcache.c (find_register_by_number): Make static.
2964 (find_regno): Use find_register_by_number
2965 * regcache.h (struct reg): Remove declaration.
2967 2018-03-23 Alan Hayward <alan.hayward@arm.com>
2969 * tdesc.c (target_desc::~target_desc): Move to here.
2970 (target_desc::operator==): Likewise.
2971 * tdesc.h (target_desc::~target_desc): Move from here.
2972 (target_desc::operator==): Likewise.
2974 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
2976 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
2978 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
2980 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
2982 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
2983 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
2984 and init_registers_s390_gs_linux64.
2986 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
2988 * linux-s390-low.c (s390_fill_gs): Remove function.
2989 (s390_fill_gsbc): Remove function.
2990 (s390_regsets): Set fill functions for the guarded storage regsets
2993 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
2995 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
2996 the word size. Add comment.
2997 (s390_get_wordsize): New function.
2998 (s390_arch_setup): No longer select a temporary tdesc to fetch the
2999 pswm with it. Instead, use s390_get_wordsize to determine the
3000 word size first and derive the correct tdesc from that directly.
3002 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
3004 * Makefile.in: Include silent-rules.mk.
3005 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
3006 (COMPILE): Add ECHO_CXX.
3007 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
3008 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
3009 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
3010 (version-generated.c): Add ECHO_GEN.
3011 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
3012 (IPAGENT_COMPILE): Add ECHO_CXX.
3013 (%-generated.c): Add ECHO_REGDAT.
3015 2018-03-14 Tom Tromey <tom@tromey.com>
3018 * ax.c (ax_printf): Special case for NULL.
3020 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
3022 * linux-low.c (linux_qxfer_libraries_svr4): Use
3023 xml_escape_text_append.
3025 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
3027 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
3029 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
3031 * server.c (handle_general_set): Remove unnecessary xstrdup.
3033 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
3035 * server.c (parse_debug_format_options): Adjust to
3036 delim_string_to_char_ptr_vec changes.
3037 * thread-db.c (thread_db_load_search): Adjust to
3038 dirnames_to_char_ptr_vec changes.
3040 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
3042 * target.h (target_enable_btrace, target_disable_btrace)
3043 (target_read_btrace, target_read_btrace_conf): Turn macro into
3044 inline function. Throw error if target method is not defined.
3045 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
3046 check for btrace target method. Be prepared to handle exceptions
3047 from btrace target methods.
3049 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
3051 * server.c (captured_main): Change order of error message printed
3052 when the current working directory cannot be found.
3054 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
3056 * server.c: Include "filenames.h" and "pathstuff.h".
3057 (program_name): Delete variable.
3058 (program_path): New anonymous class.
3059 (get_exec_wrapper): Use "program_path" instead of
3061 (handle_v_run): Likewise.
3062 (captured_main): Likewise.
3063 (process_serial_event): Likewise.
3065 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
3067 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
3068 (OBJS): Add "pathstuff.o".
3069 * server.c (current_directory): New global variable.
3070 (captured_main): Initialize "current_directory".
3072 2018-02-26 Alan Hayward <alan.hayward@arm.com>
3074 * tdesc.c: Use common/tdesc.h.
3075 * tdesc.h: Likewise.
3077 2018-02-20 Alan Hayward <alan.hayward@arm.com>
3078 Simon Marchi <simon.marchi@ericsson.com>
3080 * Makefile.in: Switch order of make rules.
3082 2018-02-19 Alan Hayward <alan.hayward@arm.com>
3084 * Makefile.in: Add common directory in build.
3085 * configure.ac: Add common reference.
3086 * configure: Regenerate.
3088 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
3090 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
3091 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
3092 * spu-low.c (spu_target_ops): Likewise.
3093 * win32-low.c (win32_target_ops): Likewise.
3094 * server.c (supported_btrace_packets): Report packets unconditionally.
3095 * target.h (target_ops) <supports_btrace>: Remove.
3096 (target_supports_btrace): Remove.
3098 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
3100 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
3101 (handle_btrace_disable): Change return type to void. Use exceptions
3103 (handle_btrace_general_set): Catch exception and copy message to
3106 2018-02-08 Tom Tromey <tom@tromey.com>
3108 * linux-low.c (install_software_single_step_breakpoints): Use
3109 make_scoped_restore.
3110 * inferiors.c (make_cleanup_restore_current_thread): Remove.
3111 (do_restore_current_thread_cleanup): Remove.
3112 * gdbthread.h (make_cleanup_restore_current_thread): Don't
3115 2018-02-08 Tom Tromey <tom@tromey.com>
3117 * mem-break.c (set_raw_breakpoint_at): Use
3118 gdb::unique_xmalloc_ptr.
3120 2018-01-30 Pedro Alves <palves@redhat.com>
3123 * target.c (target_terminal::terminal_state): Rename to ...
3124 (target_terminal::m_terminal_state): ... this.
3126 2018-01-19 James Clarke <jrtc27@jrtc27.com>
3128 * linux-low.c (handle_extended_wait): Surround call to
3129 thread_db_notice_clone with #ifdef USE_THREAD_DB.
3131 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
3133 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
3134 linux_ptrace_attach_fail_reason_string now returning an
3136 (linux_attach): Likewise.
3137 * thread-db.c (attach_thread): Likewise.
3139 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
3142 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
3143 checking for fs_base/gs_base fields in struct user_regs_struct.
3144 * configure: Regenerate.
3146 2018-01-16 Yao Qi <yao.qi@linaro.org>
3149 * linux-low.c (fetch_register): Call supply_register instead of
3152 2018-01-08 Yao Qi <yao.qi@linaro.org>
3153 Simon Marchi <simon.marchi@ericsson.com>
3155 * Makefile.in (OBS): Remove selftest.o.
3156 * configure.ac: Set srv_selftest_objs if $development is true.
3157 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
3158 * configure: Re-generated.
3159 * server.c (captured_main): Wrap variable selftest_filter with
3162 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
3164 * server.c (parse_debug_format_options): Return std::string.
3165 (handle_monitor_command, captured_main): Adjust.
3167 2018-01-05 Pedro Alves <palves@redhat.com>
3170 * server.c (captured_main): Pass quiet=false to
3171 save_original_signals_state.
3173 2018-01-01 Joel Brobecker <brobecker@adacore.com>
3175 * gdbreplay.c (gdbreplay_version): Update copyright year in
3177 * server.c (gdbserver_version): Likewise.
3179 2017-12-08 Tom Tromey <tom@tromey.com>
3181 * ax.c (ax_printf): Update.
3183 2017-12-07 Yao Qi <yao.qi@linaro.org>
3185 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
3186 aarch64_linux_read_description.
3187 * linux-amd64-ipa.c (idx2mask): New array.
3188 (get_ipa_tdesc): Move idx2mask out.
3189 (initialize_low_tracepoint): Initialize target descriptions.
3190 * linux-i386-ipa.c (idx2mask): New array.
3191 (get_ipa_tdesc): Move idx2mask out.
3192 (initialize_low_tracepoint): Initialize target descriptions.
3194 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
3196 * tdesc.c (struct tdesc_type): Change return type.
3197 (tdesc_add_flag): Change parameter type.
3198 (tdesc_add_bitfield): Likewise.
3199 (tdesc_add_field): Likewise.
3200 (tdesc_set_struct_size): Likewise.
3202 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
3204 * regcache.c (registers_to_string): Remove unused variable.
3206 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3208 * inferiors.c (for_each_inferior_with_data): Remove.
3209 * inferiors.h (for_each_inferior_with_data): Remove.
3210 * server.c (handle_qxfer_threads_worker): Change parameter type.
3211 (handle_qxfer_threads_proper): Use for_each_thread.
3213 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3215 * inferiors.c (for_each_inferior): Remove.
3216 (clear_inferiors): Use for_each_thread.
3217 * inferiors.h (for_each_inferior): Remove.
3218 * linux-low.c (linux_wait_for_event_filtered): Use
3220 (linux_stabilize_threads): Likewise.
3221 * regcache.c (regcache_release): Likewise.
3222 * server.c (gdb_wants_all_threads_stopped): Likewise.
3223 (clear_pending_status_callback): Remove.
3224 (handle_status): Use for_each_thread.
3225 (captured_main): Likewise.
3226 * win32-low.c (child_init_thread_list): Likewise.
3227 (win32_clear_inferiors): Likewise.
3228 (fake_breakpoint_event): Likewise.
3230 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3232 * inferiors.h (find_inferior): Remove.
3233 * inferiors.c (find_inferior): Remove.
3235 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3237 * linux-low.c (resume_status_pending_p): Update comment.
3238 (need_step_over_p): Update comment.
3240 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3242 * linux-low.c (proceed_one_lwp): Return void, change parameter
3244 (unsuspend_and_proceed_one_lwp): Likewise.
3245 (proceed_all_lwps): Use for_each_thread.
3246 (unstop_all_lwps): Likewise.
3248 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3250 * linux-low.c (linux_resume_one_thread): Return void, take
3252 (linux_resume): Use for_each_thread.
3254 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3256 * linux-low.c (send_sigstop_callback): Return void, change
3257 parameter type. Rename to...
3258 (send_sigstop): ... this.
3259 (suspend_and_send_sigstop_callback): Return void, change parameter
3261 (suspend_and_send_sigstop): ... this.
3262 (stop_all_lwps): Use for_each_thread.
3264 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3266 * linux-low.c (lwp_running): Return bool, remove unused
3268 (linux_stabilize_threads): Use find_thread.
3270 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3272 * linux-low.c (select_singlestep_lwp_callback): Remove.
3273 (count_events_callback): Remove.
3274 (select_event_lwp_callback): Remove.
3275 (select_event_lwp): Use find_thread/for_each_thread.
3277 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3279 * linux-low.c (not_stopped_callback): Return bool, take filter
3281 (linux_wait_for_event_filtered): Use find_thread.
3282 (linux_wait_1): Likewise.
3284 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3286 * linux-low.c (same_lwp): Remove.
3287 (find_lwp_pid): Use find_thread.
3289 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3291 * linux-low.c (delete_lwp_callback): Remove.
3292 (linux_mourn): Use for_each_thread.
3294 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3296 * linux-low.c (linux_detach_lwp_callback): Return void, remove
3297 args parameter, don't check for pid.
3298 (linux_detach): Use for_each_thread.
3300 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3302 * linux-low.c (struct counter): Remove.
3303 (second_thread_of_pid_p): Remove.
3304 (last_thread_of_process_p): Use find_thread.
3306 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3308 * inferiors.c (find_inferior_in_random): Remove.
3309 * inferiors.h (find_inferior_in_random): Remove.
3310 * linux-low.c (status_pending_p_callback): Return bool, accept
3311 parameter ptid directly.
3312 (linux_wait_for_event_filtered): Use find_thread_in_random.
3313 (linux_wait_1): Likewise.
3315 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3317 * inferiors.c (find_inferior_id): Remove.
3318 (find_thread_ptid): Move implemention from find_inferior_id to
3320 * inferiors.h (find_inferior_id): Remove.
3321 * server.c (handle_status): Use find_thread_ptid.
3322 (process_serial_event): Likewise.
3323 * thread-db.c (find_one_thread): Likewise.
3324 (thread_db_thread_handle): Likewise.
3325 * win32-low.c (thread_rec): Likewise.
3326 (child_delete_thread): Likewise.
3327 (win32_thread_alive): Likewise.
3328 (get_child_debug_event): Likewise.
3330 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3332 * linux-mips-low.c (update_watch_registers_callback): Return
3333 void, remove pid_p parameter, don't check for pid.
3334 (mips_insert_point, mips_remove_point): Use for_each_thread.
3336 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3338 * lynx.low (lynx_delete_thread_callback): Remove.
3339 (lynx_mourn): Use for_each_thread.
3341 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3343 * regcache.c (regcache_invalidate_one): Remove.
3344 (regcache_invalidate_pid): use for_each_thread.
3346 2017-11-26 Tom Tromey <tom@tromey.com>
3348 * linux-low.c (linux_create_inferior): Update.
3350 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
3352 * spu-low.c (spu_create_inferior): Fix typo in argument name.
3354 2017-11-24 Alan Hayward <alan.hayward@arm.com>
3356 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
3357 * linux-aarch64-low.c (initialize_low_arch): Call init func.
3358 * linux-aarch64-tdesc-selftest.c: New file.
3359 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
3361 2017-11-24 Alan Hayward <alan.hayward@arm.com>
3363 * configure.srv: Add new file.
3364 * linux-aarch64-low.c (initialize_low_arch): Call init func.
3365 * linux-aarch64-tdesc-selftest.c: New file.
3366 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
3368 2017-11-24 Alan Hayward <alan.hayward@arm.com>
3370 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
3371 * linux-aarch64-low.c (initialize_low_arch): Remove init.
3372 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
3374 2017-11-24 Alan Hayward <alan.hayward@arm.com>
3376 * configure.srv: Add new files.
3377 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
3378 aarch64_linux_read_description.
3379 * linux-aarch64-low.c (aarch64_linux_read_description):
3380 Merge with aarch64_arch_setup.
3381 (aarch64_arch_setup): Call aarch64_linux_read_description.
3382 * linux-aarch64-tdesc.c: New file.
3383 * linux-aarch64-tdesc.h: New file.
3385 2017-11-24 Yao Qi <yao.qi@linaro.org>
3387 * configure.srv: Set $srv_regobj for tic6x-linux.
3388 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
3389 (tic6x_read_description): Move some code to tic6x_arch_setup.
3390 (tic6x_tdesc_test): New function.
3391 (initialize_low_arch): Call selftests::register_test.
3393 2017-11-22 Yao Qi <yao.qi@linaro.org>
3395 * remote-utils.c (prepare_resume_reply): Use memcpy.
3397 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3399 * linux-low.c (kill_one_lwp_callback): Return void, take
3400 argument directly, don't filter on pid.
3401 (linux_kill): Use for_each_thread.
3403 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3405 * linux-low.c (need_step_over_p): Return bool, remove dummy
3407 (linux_resume, proceed_all_lwps): Use find_thread.
3409 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3411 * linux-low.c (resume_status_pending_p): Return bool, remove
3413 (linux_resume): Use find_thread.
3415 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3417 * linux-low.c (struct thread_resume_array): Remove.
3418 (linux_set_resume_request): Return void, take arguments
3420 (linux_resume): Use for_each_thread.
3422 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3424 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
3425 return bool, remove data argument.
3426 (linux_stabilize_threads): Use find_thread.
3428 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3430 * linux-low.c (unsuspend_one_lwp): Remove.
3431 (unsuspend_all_lwps): Use for_each_thread, inline code from
3434 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3436 * gdbthread.h (find_thread): Add overload with ptid_t filter.
3437 * linux-low.c (struct iterate_over_lwps_args): Remove.
3438 (iterate_over_lwps_filter): Remove.
3439 (iterate_over_lwps): Use find_thread.
3441 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3443 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
3444 (linux_handle_new_gdb_connection): Use for_each_thread, inline
3445 code from reset_lwp_ptrace_options_callback.
3447 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3449 * linux-arm-low.c (struct update_registers_data): Remove.
3450 (update_registers_callback): Return void, take arguments
3451 directly, don't check thread's pid.
3452 (arm_insert_point, arm_remove_point): Use for_each_thread.
3454 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3456 * win32-low.c (continue_one_thread): Return void, take argument
3458 (child_continue): Use for_each_thread.
3460 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3462 * win32-i386-low.c (update_debug_registers_callback): Rename
3464 (update_debug_registers): ... this, return void, remove pid_p arg.
3465 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
3467 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
3469 * inferiors.h (struct process_info): Add constructor, initialize
3471 <syscalls_to_catch>: Change type to std::vector<int>.
3472 * inferiors.c (add_process): Allocate process_info with new.
3473 (remove_process): Free process_info with delete.
3474 * linux-low.c (handle_extended_wait): Adjust.
3475 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
3476 * server.c (handle_general_set): Adjust.
3478 2017-11-16 Pedro Alves <palves@redhat.com>
3480 * remote-utils.c (remote_close): Block SIGIO signals instead of
3481 uninstalling the SIGIO handler.
3483 2017-11-16 Alan Hayward <alan.hayward@arm.com>
3485 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
3487 2017-11-16 Yao Qi <yao.qi@linaro.org>
3489 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
3490 (tic6x_store_gregset): Likewise.
3491 (tic6x_usrregs_info): Move it up.
3493 2017-11-15 Alan Hayward <alan.hayward@arm.com>
3495 * Makefile.in: Update arch rules.
3496 * configure.srv: Explicitly mark arch/ files.
3498 2017-11-13 Andreas Schwab <schwab@suse.de>
3500 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
3502 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
3504 2017-11-06 Pedro Alves <palves@redhat.com>
3506 * config.in, configure: Regenerate.
3508 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3510 * target.c (struct thread_search): Remove.
3511 (thread_search_callback): Remove.
3512 (prepare_to_access_memory): Use for_each_thread instead of
3513 find_inferior. Inline code from thread_search_callback.
3515 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3517 * server.c (struct visit_actioned_threads_data): Remove.
3518 (visit_actioned_threads): Change prototype to take arguments
3520 (resume): Use find_thread instead of find_inferior.
3522 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3524 * server.c (queue_stop_reply_callback): Change prototype, return
3526 (find_status_pending_thread_callback): Remove.
3527 (handle_status): Replace find_inferior with find_thread and
3530 2017-10-25 Alan Hayward <alan.hayward@arm.com>
3532 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
3534 (aarch64_store_gregset): Likewise.
3535 (aarch64_fill_fpregset): Likewise.
3536 (aarch64_store_fpregset): Likewise.
3538 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
3540 * gdbthread.h (find_thread, for_each_thread): New functions.
3541 * inferiors.c (thread_of_pid): Remove.
3542 (find_any_thread_of_pid): Use find_thread.
3543 * linux-low.c (num_lwps): Use for_each_thread.
3545 2017-10-17 Yao Qi <yao.qi@linaro.org>
3547 * Makefile.in: Remove one rule.
3548 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
3550 2017-10-17 Yao Qi <yao.qi@linaro.org>
3552 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
3553 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
3555 2017-10-17 Yao Qi <yao.qi@linaro.org>
3557 * configure.srv: Rename arm.o with arch/arm.o.
3559 2017-10-17 Yao Qi <yao.qi@linaro.org>
3561 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
3562 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
3563 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
3564 (arch-i386.o, arch-amd64.o): Remove rules.
3565 (arch/%.o): New rule.
3566 Update POSTCOMPILE and COMPILE.pre.
3567 * configure.ac: Invoke AC_CONFIG_COMMANDS.
3568 * configure: Re-generated.
3569 * configure.srv: Replace arch-i386.o with arch/i386.o.
3570 Replace arch-amd64.o with arch/amd64.o.
3572 2017-10-16 Yao Qi <yao.qi@linaro.org>
3574 * configure: Regenerated.
3576 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3578 * inferiors.h: (struct inferior_list): Remove.
3579 (struct inferior_list_entry); Remove.
3580 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
3581 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
3582 get_first_inferior): Remove.
3583 (for_each_inferior, for_each_inferior_with_data, find_inferior,
3584 find_inferior_id, find_inferior_in_random): Change signature.
3585 * inferiors.c (all_threads): Change type to
3586 std::list<thread_info *>.
3587 (get_thread): Remove macro.
3588 (find_inferior, find_inferior_id): Change signature, implement
3590 (find_inferior_in_random): Change signature, implement using
3591 find_thread_in_random.
3592 (for_each_inferior, for_each_inferior_with_data): Change
3593 signature, implement using for_each_thread.
3594 (add_inferior_to_list, remove_inferior): Remove.
3595 (add_thread, get_first_thread, thread_of_pid,
3596 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
3597 (get_first_inferior, one_inferior_p, clear_inferior_list):
3599 (clear_inferiors, get_thread_process): Update.
3600 * gdbthread.h: Include <list>.
3601 (struct thread_info) <entry>: Remove field.
3603 (all_threads): Change type to std::list<thread_info *>.
3604 (get_first_inferior): Add doc.
3605 (find_thread, for_each_thread, find_thread_in_random): New
3607 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
3608 * linux-arm-low.c (update_registers_callback): Update.
3609 * linux-low.c (second_thread_of_pid_p): Update.
3610 (kill_one_lwp_callback, linux_detach_lwp_callback,
3611 delete_lwp_callback, status_pending_p_callback, same_lwp,
3612 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
3613 iterate_over_lwps, not_stopped_callback,
3614 resume_stopped_resumed_lwps, count_events_callback,
3615 select_singlestep_lwp_callback, select_event_lwp_callback,
3616 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
3617 suspend_and_send_sigstop_callback, wait_for_sigstop,
3618 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
3619 lwp_running, linux_set_resume_request, resume_status_pending_p,
3620 need_step_over_p, start_step_over, linux_resume_one_thread,
3621 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
3622 reset_lwp_ptrace_options_callback): Update.
3623 * linux-mips-low.c (update_watch_registers_callback): Update.
3624 * regcache.c (regcache_invalidate_one, regcache_invalidate):
3626 (free_register_cache_thread_one): Remove.
3627 (regcache_release): Update.
3628 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
3629 handle_qxfer_threads_worker): Update.
3630 (handle_query): Update, use list iterator.
3631 (visit_actioned_threads, handle_pending_status,
3632 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
3633 clear_pending_status_callback, set_pending_status_callback,
3634 find_status_pending_thread_callback, handle_status,
3635 process_serial_event): Update.
3636 * target.c (thread_search_callback): Update.
3637 * thread-db.c (thread_db_get_tls_address): Update.
3638 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
3640 * win32-i386-low.c (update_debug_registers_callback): Update.
3641 * win32-low.c (delete_thread_info, child_delete_thread,
3642 continue_one_thread, suspend_one_thread,
3643 get_child_debug_event): Adjust.
3645 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3647 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
3648 * inferiors.h: Include <list>.
3649 (struct process_info) <entry>: Remove field.
3651 (pid_of): Change macro to function.
3652 (ptid_of, lwpid_of): Remove macro.
3653 (all_processes): Change type to std::list<process_info *>.
3654 (ALL_PROCESSES): Remove macro.
3655 (for_each_process, find_process): New function.
3656 * inferiors.c (all_processes): Change type to
3657 std::list<process_info *>.
3658 (find_thread_process): Adjust.
3659 (add_process): Likewise.
3660 (remove_process): Likewise.
3661 (find_process_pid): Likewise.
3662 (get_first_process): Likewise.
3663 (started_inferior_callback): Remove.
3664 (have_started_inferiors_p): Adjust.
3665 (attached_inferior_callback): Remove.
3666 (have_attached_inferiors_p): Adjust.
3667 * linux-low.c (check_zombie_leaders): Likewise.
3668 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
3669 (x86_linux_update_xmltarget): Adjust.
3670 * server.c (handle_query): Likewise.
3671 (gdb_reattached_process): Remove.
3672 (handle_status): Adjust.
3673 (kill_inferior_callback): Likewise.
3674 (detach_or_kill_inferior): Remove.
3675 (print_started_pid): Likewise.
3676 (print_attached_pid): Likewise.
3677 (detach_or_kill_for_exit): Update.
3678 (process_serial_event): Likewise.
3679 * linux-arm-low.c (arm_new_fork): Likewise.
3681 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3683 * dll.h: Include <list>.
3684 (struct dll_info): Add constructor.
3685 <entry>: Remove field.
3686 (all_dlls): Change type to std::list<dll_info>.
3687 * dll.c: Include <algorithm>.
3688 (get_dll): Remove macro.
3689 (all_dlls): Change type to std::list<dll_info *>.
3690 (free_one_dll): Remove.
3691 (match_dll): Likewise.
3692 (loaded_dll): Adjust.
3693 (unloaded_dll): Adjust to all_dlls type change, use
3694 std::find_if. Inline code from match_dll.
3695 (clear_dlls): Adjust to all_dlls type change.
3696 * server.c (emit_dll_description): Remove.
3697 (handle_qxfer_libraries): Adjust to all_dlls type change,
3698 integrate emit_dll_description's functionality.
3700 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
3702 * linux-low.h (struct linux_target_ops) <delete_process>: New
3704 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
3705 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
3706 (struct linux_target_ops): Add delete_process callback.
3707 * linux-arm-low.c (arm_delete_process): New.
3708 (struct linux_target_ops): Add delete_process callback.
3709 * linux-bfin-low.c (struct linux_target_ops): Likewise.
3710 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
3711 * linux-m32r-low.c (struct linux_target_ops): Likewise.
3712 * linux-mips-low.c (mips_linux_delete_process): New.
3713 (struct linux_target_ops): Add delete_process callback.
3714 * linux-ppc-low.c (struct linux_target_ops): Likewise.
3715 * linux-s390-low.c (struct linux_target_ops): Likewise.
3716 * linux-sh-low.c (struct linux_target_ops): Likewise.
3717 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
3718 * linux-tile-low.c (struct linux_target_ops): Likewise.
3719 * linux-x86-low.c (x86_linux_delete_process): New.
3720 (struct linux_target_ops): Add delete_process callback.
3721 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
3723 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
3725 * linux-aarch64-low.c (the_low_target): Add thread delete
3727 * linux-arm-low.c (arm_delete_thread): New function.
3728 (the_low_target): Add thread delete callback.
3729 * linux-bfin-low.c (the_low_target): Likewise.
3730 * linux-crisv32-low.c (the_low_target): Likewise.
3731 * linux-low.c (delete_lwp): Invoke delete_thread callback if
3733 * linux-low.h (struct linux_target_ops) <delete_thread>: New
3735 * linux-m32r-low.c (the_low_target): Add thread delete callback.
3736 * linux-mips-low.c (mips_linux_delete_thread): New function.
3737 (the_low_target): Add thread delete callback.
3738 * linux-ppc-low.c (the_low_target): Likewise.
3739 * linux-s390-low.c (the_low_target): Likewise.
3740 * linux-sh-low.c (the_low_target): Likewise.
3741 * linux-tic6x-low.c (the_low_target): Likewise.
3742 * linux-tile-low.c (the_low_target): Likewise.
3743 * linux-x86-low.c (the_low_target): Likewise.
3744 * linux-xtensa-low.c (the_low_target): Likewise.
3746 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
3748 * win32-low.c: Include "common-inferior.h".
3750 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3752 * inferiors.c (set_inferior_cwd): New function.
3753 * server.c (handle_general_set): Handle QSetWorkingDir packet.
3754 (handle_query): Inform that QSetWorkingDir is supported.
3755 * win32-low.c (create_process): Pass the inferior's cwd to
3758 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3760 * inferiors.c (current_inferior_cwd): New global variable.
3761 (get_inferior_cwd): New function.
3762 * inferiors.h (struct process_info) <cwd>: New field.
3764 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3766 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
3767 (OBS): Add gdb_tilde_expand.o.
3769 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
3771 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
3772 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
3774 2017-09-29 Pedro Alves <palves@redhat.com>
3776 * ax.c (gdb_parse_agent_expr): Constify.
3777 * ax.h (gdb_parse_agent_expr): Constify.
3778 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
3780 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
3781 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
3782 * remote-utils.h (read_ptid): Constify.
3783 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
3784 (process_point_options, process_serial_event): Constify.
3785 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
3786 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
3787 (cmd_qtbuffer): Constify.
3789 2017-09-29 Pedro Alves <palves@redhat.com>
3791 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
3794 2017-09-29 Pedro Alves <palves@redhat.com>
3796 * linux-low.c (handle_extended_wait): Pass parent thread instead
3797 of process to thread_db_notice_clone.
3798 * linux-low.h (thread_db_notice_clone): Replace parent process
3799 parameter with parent thread parameter.
3800 * thread-db.c (find_one_thread): Add comment.
3801 (thread_db_notice_clone): Replace parent process parameter with
3802 parent thread parameter. Temporarily switch to the parent thread.
3804 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
3806 * gdbthread.h: Include "common-gdbthread.h".
3807 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
3808 "if" when validating the ptid.
3809 * remote-utils.c: Include "gdbthread.h".
3810 (prepare_resume_reply): Use "switch_to_thread".
3811 * target.c (done_accessing_memory): Likewise.
3813 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
3815 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
3816 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
3817 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
3818 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
3819 s390x-gs-linux64-ipa.o to ipa_obj.
3820 * linux-s390-low.c (HWCAP_S390_GS): New define.
3821 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
3823 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
3824 (s390_arch_setup): Check for guarded-storage support and choose
3826 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
3827 init_registers_s390x_gs_linux64.
3828 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
3830 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
3831 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
3833 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
3835 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
3837 2017-09-21 Kevin Buettner <kevinb@redhat.com>
3839 * linux-low.h (struct lwp_info): Add new field, thread_handle.
3840 (thread_db_thread_handle): Declare.
3841 * linux-low.c (linux_target_ops): Initialize thread_handle.
3842 * server.c (handle_qxfer_threads_worker): Add support for
3844 * target.h (struct target_ops): Add new function pointer,
3846 (target_thread_handle): Define.
3847 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
3849 (thread_db_thread_handle): New function.
3851 2017-09-21 Kevin Buettner <kevinb@redhat.com>
3853 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
3854 * linux-low.h (thread_db_notice_clone): Declare.
3855 * thread-db.c (thread_db_notice_clone): New function.
3857 2017-09-21 Pedro Alves <palves@redhat.com>
3859 * server.c (gdb_read_memory, handle_status, process_serial_event)
3860 (handle_serial_event, handle_target_event): Adjust to
3861 set_desired_thread prototype change.
3862 * target.c (set_desired_thread): Remove 'use_general' parameter
3864 * target.h (set_desired_thread): Remove 'use_general' parameter.
3866 2017-09-20 Tom Tromey <tom@tromey.com>
3868 * target.c (target_terminal::terminal_state): Define.
3869 (target_terminal::init): Rename from target_terminal_init.
3870 (target_terminal::inferior): Rename from
3871 target_terminal_inferior.
3872 (target_terminal::ours): Rename from target_terminal_ours.
3873 (target_terminal::ours_for_output, target_terminal::info): New.
3875 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3877 * server.c (accumulate_file_name_length): Remove.
3878 (emit_dll_description): Adjust to std::string change.
3879 (handle_qxfer_libraries): Use std::string to hold document.
3881 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3883 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
3884 return type of xml_escape_text.
3885 * server.c (emit_dll_description): Likewise.
3887 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3889 * server.c (captured_main): Accept argument for --selftest.
3890 Update run_tests call.
3891 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
3892 when registering selftests.
3894 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
3896 * regcache.c (get_thread_regcache): Update code to use "std::vector"
3897 instead of "VEC" for "target_desc.reg_defs".
3898 (regcache_cpy): Likewise.
3899 (registers_to_string): Likewise.
3900 (registers_from_string): Likewise.
3901 (find_regno): Likewise.
3902 (supply_regblock): Likewise.
3903 (regcache_raw_read_unsigned): Likewise.
3904 * tdesc.c (init_target_desc): Likewise.
3905 (tdesc_create_reg): Likewise.
3906 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
3907 (struct target_desc) <reg_defs>: Convert to "std::vector".
3908 (target_desc): Do not initialize "reg_defs".
3909 (~target_desc): Update code to use "std::vector" instead of "VEC"
3910 for "target_desc.reg_defs".
3911 (operator==): Likewise.
3913 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3915 * inferiors.h (thread_to_gdb_id): Remove.
3916 * inferiors.c (thread_to_gdb_id): Remove.
3917 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
3918 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
3919 lynx_store_registers, lynx_read_memory, lynx_write_memory):
3921 * nto-low.c (nto_fetch_registers, nto_store_registers,
3922 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
3924 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3926 * inferiors.h (gdb_id_to_thread_id): Remove.
3927 * inferiors.c (gdb_id_to_thread_id): Remove.
3928 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
3929 removal. Move pid declaration closer to where it's used.
3931 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3933 * server.c (handle_detach): New function.
3934 (process_serial_event): Move code out, call handle_detach.
3936 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3938 * server.c (require_running): Rename to ...
3939 (require_running_or_return): ... this ...
3940 (require_running_or_break): ... and this.
3941 (handle_query, process_serial_event): Adjust.
3943 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3945 * linux-low.c (linux_set_resume_request): Remove unused
3948 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3950 * server.c (first_thread_of): Remove.
3951 (process_serial_event): Replace usage of first_thread_of with
3952 find_any_thread_of_pid.
3953 * tracepoint.c (same_process_p): Remove.
3954 (gdb_agent_about_to_close): Replace usage of same_process_p with
3955 find_any_thread_of_pid.
3956 * linux-x86-low.c (same_process_callback): Remove.
3957 (x86_arch_setup_process_callback): Replace usage of
3958 same_process_callback with find_any_thread_of_pid.
3959 * thread-db.c (any_thread_of): Remove.
3960 (switch_to_process): Replace usage of any_thread_of with
3961 find_any_thread_of_pid.
3962 * inferiors.c (thread_pid_matches_callback): Remove.
3963 (find_thread_process): Adjust to use find_any_thread_of_pid.
3965 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
3967 * regcache.c (get_thread_regcache): Guard calls to "memset"
3970 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
3972 * linux-low.c (handle_extended_wait): Use
3973 "allocate_target_description" instead of "XNEW".
3974 * linux-x86-low.c (initialize_low_arch): Likewise.
3976 2017-09-05 Yao Qi <yao.qi@linaro.org>
3978 * configure.srv (srv_i386_regobj): Remove.
3979 (srv_amd64_regobj): Remove.
3980 (srv_regobj): Set it to "" for x86 non-linux targets.
3981 * linux-x86-tdesc.c (i386_linux_read_description):
3982 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
3983 (init_registers_i386): Remove the declaration.
3984 (tdesc_i386): Remove the declaration.
3985 (lynx_i386_arch_setup): Call i386_create_target_description.
3986 * nto-x86-low.c: Likewise.
3987 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
3988 [!__x86_64__]: include arch/i386.h.
3989 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
3991 2017-09-05 Yao Qi <yao.qi@linaro.org>
3993 * configure.srv (srv_amd64_linux_xmlfiles): Remove
3994 i386/amd64-XXX-linux from it.
3996 2017-09-05 Yao Qi <yao.qi@linaro.org>
3998 * configure.srv: Empty srv_amd64_linux_regobj if $development is
4000 (ipa_amd64_linux_regobj): Remove.
4001 (ipa_x32_linux_regobj): Remove.
4003 2017-09-05 Yao Qi <yao.qi@linaro.org>
4005 * Makefile.in (arch-amd64.o): New rule.
4006 * configure.srv: Append arch-amd64.o.
4007 * linux-amd64-ipa.c: Include common/x86-xstate.h.
4008 (get_ipa_tdesc): Call amd64_linux_read_description.
4009 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
4010 and init_registers_amd64_XXX.
4011 * linux-x86-low.c (x86_linux_read_description): Call
4012 amd64_linux_read_description.
4013 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
4014 (initialize_low_arch): Don't call init_registers_x32_XXX and
4015 init_registers_amd64_XXX.
4016 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
4017 and tdesc_amd64_XXX.
4018 [__x86_64__] (amd64_tdesc_test): New function.
4019 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
4020 and init_registers_amd64_XXX.
4021 * linux-x86-tdesc.c: Include arch/amd64.h.
4022 (xcr0_to_tdesc_idx): New function.
4023 (i386_linux_read_description): New function.
4024 (amd64_get_ipa_tdesc_idx): New function.
4025 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
4026 (amd64_get_ipa_tdesc): Declare.
4028 2017-09-05 Yao Qi <yao.qi@linaro.org>
4030 * configure.srv (srv_i386_linux_xmlfiles): Remove
4031 i386/i386-XXX-linux.xml from it.
4033 2017-09-05 Yao Qi <yao.qi@linaro.org>
4035 * configure.srv: Set srv_i386_linux_regobj empty if $development
4037 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
4038 initialize_low_tdesc.
4039 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
4040 with #if initialize_low_tdesc.
4041 * linux-x86-tdesc-selftest.c: New file.
4042 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
4044 2017-09-05 Yao Qi <yao.qi@linaro.org>
4046 * Makefile.in (arch-i386.o): New rule.
4047 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
4048 (x86_64-*-linux*): Likewise.
4049 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
4050 include arch/i386.h.
4051 (i386_linux_read_description): Remove code and call
4052 i386_create_target_description.
4053 * tdesc.c (allocate_target_description): New function.
4054 * tdesc.h (set_tdesc_architecture): Remove declaration.
4055 (set_tdesc_osabi): Likewise.
4057 2017-09-05 Yao Qi <yao.qi@linaro.org>
4059 * linux-x86-tdesc.c: Don't include <inttypes.h>.
4060 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
4061 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
4063 * server.c (get_features_xml): Call tdesc_get_features_xml.
4064 * tdesc.c (set_tdesc_architecture): New function.
4065 (set_tdesc_osabi): New function.
4066 (tdesc_get_features_xml): New function.
4067 (tdesc_create_feature): Add an argument.
4068 * tdesc.h (struct target_desc) <features>: New field.
4069 <arch, osabi>: New field.
4070 (~target_desc): xfree features, arch, and osabi.
4071 (target_desc::oerator==): Don't compare .xmltarget.
4072 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
4073 (set_tdesc_osabi): Likewise.
4074 (tdesc_get_features_xml): Likewise.
4076 2017-09-05 Yao Qi <yao.qi@linaro.org>
4078 * linux-x86-tdesc.c: Include selftest.h.
4079 (i386_tdesc_test): New function.
4080 (initialize_low_tdesc): Call selftests::register_test.
4081 * tdesc.h: Include regdef.h.
4082 (target_desc): Override operator == and !=.
4084 2017-09-05 Yao Qi <yao.qi@linaro.org>
4086 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
4087 (ipa_obj): Likewise.
4088 * linux-i386-ipa.c: Include common/x86-xstate.h
4089 (get_ipa_tdesc): Call i386_linux_read_description.
4090 (initialize_low_tracepoint): Don't call init_registers_XXX
4091 functions, call initialize_low_tdesc instead.
4092 * linux-x86-low.c (x86_linux_read_description): Call
4093 i386_linux_read_description.
4094 (initialize_low_arch): Don't call init_registers_i386_XXX
4095 functions, call initialize_low_tdesc.
4096 * linux-x86-tdesc.c: New file.
4097 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
4098 (i386_get_ipa_tdesc_idx): Declare.
4099 (i386_get_ipa_tdesc): Declare.
4100 (initialize_low_tdesc): Declare.
4102 2017-09-05 Yao Qi <yao.qi@linaro.org>
4104 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
4107 2017-09-05 Yao Qi <yao.qi@linaro.org>
4109 * Makefile.in (IPA_OBJS): Add vec-ipa.o
4110 * regcache.c (get_thread_regcache): Use VEC_length.
4111 (init_register_cache): Likewise.
4112 (regcache_cpy): Likewise.
4113 (registers_to_string): Iterate reg_defs via VEC_iterate.
4114 (find_regno): Likewise.
4115 (find_register_by_number): Use VEC_index.
4116 (register_size): Call find_register_by_number.
4117 (register_data): Call find_register_by_number.
4118 (supply_regblock): Use VEC_length.
4119 (regcache_raw_read_unsigned): Likewise.
4120 * tdesc.c (init_target_desc): Iterate reg_defs via
4122 (default_description): Update initializer.
4123 (copy_target_description): Don't update field num_registers.
4124 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
4125 <num_registers>: Remove.
4127 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
4129 * Makefile.in (.SECONDARY): Define target.
4131 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
4133 * linux-low.c (linux_wait_1): Adjust.
4134 * server.c (queue_stop_reply_callback): Adjust.
4136 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
4138 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
4139 QEnvironmentUnset and QEnvironmentReset packets.
4140 (handle_query): Inform remote that QEnvironmentHexEncoded,
4141 QEnvironmentUnset and QEnvironmentReset are supported.
4143 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
4145 * inferiors.h (inferior_target_data): Rename to ...
4146 (thread_target_data): ... this.
4147 (inferior_regcache_data): Rename to ...
4148 (thread_regcache_data): ... this.
4149 (set_inferior_regcache_data): Rename to ...
4150 (set_thread_regcache_data): ... this.
4151 * inferiors.c (inferior_target_data): Rename to ...
4152 (thread_target_data): ... this.
4153 (inferior_regcache_data): Rename to ...
4154 (thread_regcache_data): ... this.
4155 (set_inferior_regcache_data): Rename to ...
4156 (set_thread_regcache_data): ... this.
4157 (free_one_thread): Update.
4158 * linux-low.h (get_thread_lwp): Update.
4159 * regcache.c (get_thread_regcache): Update.
4160 (regcache_invalidate_thread): Update.
4161 (free_register_cache_thread): Update.
4162 * win32-i386-low.c (update_debug_registers_callback): Update.
4163 (win32_get_current_dr): Update.
4164 * win32-low.c (thread_rec): Update.
4165 (delete_thread_info): Update.
4166 (continue_one_thread): Update.
4167 (suspend_one_thread): Update.
4169 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
4171 * inferiors.c (set_inferior_target_data): Remove.
4172 * inferiors.h (set_inferior_target_data): Remove.
4174 2017-08-18 Yao Qi <yao.qi@linaro.org>
4176 * Makefile.in (OBS): Add selftest.o.
4177 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
4178 * configure, config.in: Re-generated.
4179 * server.c: Include common/sefltest.h.
4180 (captured_main): Handle option --selftest.
4182 2017-08-09 Yao Qi <yao.qi@linaro.org>
4184 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
4185 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
4186 i386-avx-mpx.o and i386-mmx.o.
4187 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
4188 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
4189 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
4190 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
4191 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
4192 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
4193 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
4194 i386/amd64-avx-mpx.xml.
4196 2017-08-09 Yao Qi <yao.qi@linaro.org>
4198 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
4199 and x32-avx-avx512.o.
4200 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
4201 i386/x32-avx-avx512.xml.
4203 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
4205 * tracepoint.h (enum class fast_tpoint_collect_result): New
4207 (fast_tracepoint_collecting): Change return type to
4208 fast_tpoint_collect_result.
4209 * tracepoint.c (fast_tracepoint_collecting): Likewise.
4210 * linux-low.h: Include tracepoint.h.
4211 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
4212 fast_tpoint_collect_result.
4213 * linux-low.c (handle_tracepoints): Adjust.
4214 (linux_fast_tracepoint_collecting): Change return type to
4215 fast_tpoint_collect_result.
4216 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
4217 linux_wait_1, stuck_in_jump_pad_callback,
4218 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
4219 proceed_one_lwp): Adjust to type change.
4221 2017-07-10 Yao Qi <yao.qi@linaro.org>
4223 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
4225 2017-06-29 Yao Qi <yao.qi@linaro.org>
4227 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
4229 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
4231 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
4233 * Makefile.in (IPA_OBJS): Sort and format one item per line.
4235 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
4237 * linux-low.c (linux_create_inferior): Adjust code to access the
4238 environment information via 'gdb_environ' class.
4239 * lynx-low.c (lynx_create_inferior): Likewise.
4240 * server.c (our_environ): Make it an instance of 'gdb_environ'.
4241 (get_environ): Return a pointer to 'our_environ'.
4242 (captured_main): Initialize 'our_environ'.
4243 * server.h (get_environ): Adjust prototype.
4244 * spu-low.c (spu_create_inferior): Adjust code to access the
4245 environment information via 'gdb_environ' class.
4247 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4249 * linux-low.c (linux_read_memory, linux_write_memory): Remove
4250 usage of "register" keyword.
4252 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4254 * configure: Re-generate.
4256 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4258 * configure: Re-generate.
4260 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4262 * Makefile.in (COMPILE.pre): Add "-x c++".
4264 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
4266 * fork-child.c: Conditionally include <signal.h>.
4268 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4270 * server.c (handle_general_set): Handle new packet
4271 "QStartupWithShell".
4272 (handle_query): Add "QStartupWithShell" to the list of supported
4274 (gdbserver_usage): Add help text explaining the
4275 new "--startup-with-shell" and "--no-startup-with-shell" CLI
4277 (captured_main): Recognize and act upon the presence of the new
4280 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4281 Pedro Alves <palves@redhat.com>
4283 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
4284 * configure: Regenerate.
4285 * configure.srv (srv_linux_obj): Add "fork-child.o" and
4287 (i[34567]86-*-lynxos*): Likewise.
4288 (spu*-*-*): Likewise.
4289 * fork-child.c: New file.
4290 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
4292 (linux_ptrace_fun): New function.
4293 (linux_create_inferior): Adjust function prototype to reflect
4294 change on "target.h". Adjust function code to use
4296 (linux_request_interrupt): Delete "signal_pid".
4297 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
4298 (lynx_ptrace_fun): New function.
4299 (lynx_create_inferior): Adjust function prototype to reflect
4300 change on "target.h". Adjust function code to use
4302 * nto-low.c (nto_create_inferior): Adjust function prototype and
4303 code to reflect change on "target.h". Update comments.
4304 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
4305 "common-terminal.h" and "environ.h".
4306 (terminal_fd): Moved to fork-child.c.
4307 (old_foreground_pgrp): Likewise.
4308 (restore_old_foreground_pgrp): Likewise.
4309 (last_status): Make it global.
4310 (last_ptid): Likewise.
4311 (our_environ): New variable.
4312 (startup_with_shell): Likewise.
4313 (program_name): Likewise.
4314 (program_argv): Rename to...
4315 (program_args): ...this.
4316 (wrapper_argv): New variable.
4317 (start_inferior): Delete function.
4318 (get_exec_wrapper): New function.
4319 (get_exec_file): Likewise.
4320 (get_environ): Likewise.
4321 (prefork_hook): Likewise.
4322 (post_fork_inferior): Likewise.
4323 (postfork_hook): Likewise.
4324 (postfork_child_hook): Likewise.
4325 (handle_v_run): Update code to deal with arguments coming from the
4326 remote host. Update calls from "start_inferior" to
4328 (captured_main): Likewise. Initialize environment variable. Call
4330 * server.h (post_fork_inferior): New prototype.
4331 (get_environ): Likewise.
4332 (last_status): Declare.
4333 (last_ptid): Likewise.
4334 (signal_pid): Likewise.
4335 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
4336 (spu_ptrace_fun): New function.
4337 (spu_create_inferior): Adjust function prototype to reflect change
4338 on "target.h". Adjust function code to use "fork_inferior".
4339 * target.c (target_terminal_init): New function.
4340 (target_terminal_inferior): Likewise.
4341 (target_terminal_ours): Likewise.
4342 * target.h: Include <vector>.
4343 (struct target_ops) <create_inferior>: Update prototype.
4344 (create_inferior): Update macro.
4345 * utils.c (gdb_flush_out_err): New function.
4346 * win32-low.c (win32_create_inferior): Adjust function prototype
4347 and code to reflect change on "target.h".
4349 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4351 * inferiors.c (switch_to_thread): New function.
4353 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4355 * Makefile.in (SFILE): Add "common/job-control.c".
4356 (OBS): Add "job-control.o".
4358 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
4360 * Makefile: Remove "@host_makefile_frag@".
4362 2017-05-05 Pedro Alves <palves@redhat.com>
4364 * configure: Regenerate.
4366 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
4368 * configure: Regenerate.
4370 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
4372 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
4373 software_single_step change of return type to
4374 std::vector<CORE_ADDR>.
4375 * linux-low.c (install_software_single_step_breakpoints):
4377 * linux-low.h (install_software_single_step_breakpoints):
4380 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
4382 * remote-utils.c: Include "gdb_termios.h" instead of
4384 * terminal.h: Delete file.
4386 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
4388 * server.c: Include <vector>.
4389 <program_argv, wrapper_argv>: Convert to std::vector.
4390 (start_inferior): Rewrite function to use C++.
4391 (handle_v_run): Likewise. Update code that calculates the argv
4392 based on the vRun packet; use C++.
4393 (captured_main): Likewise.
4395 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
4397 * server.c (handle_v_cont): Initialize thread_resume::thread
4400 2017-04-05 Pedro Alves <palves@redhat.com>
4402 * configure: Regenerate.
4404 2017-04-05 Pedro Alves <palves@redhat.com>
4406 * gdbreplay.c (sync_error): Constify.
4407 * linux-x86-low.c (push_opcode): Constify.
4409 2017-04-05 Pedro Alves <palves@redhat.com>
4411 * win32-low.c (get_child_debug_event)
4412 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
4413 Report TARGET_WAITKIND_SPURIOUS instead.
4415 2017-04-05 Pedro Alves <palves@redhat.com>
4417 * remote-utils.c (remote_prepare, remote_open): Constify.
4418 * remote-utils.h (remote_prepare, remote_open): Constify.
4419 * server.c (captured_main): Constify 'port' handling.
4421 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
4423 * Makefile.in (clean): Clear .deps.
4425 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
4427 * .gitignore: Remove generated files, replace with wildcard.
4428 * (clean): Replace removal of generated files with wildcard.
4429 (version.c): Replace with...
4430 (version-generated.c): ...this.
4431 (xml-builtin.c): Replace with...
4432 (xml-builtin-generated.c): ...this.
4433 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
4434 (%.c: *regformats*): Replace with...
4435 (%-generated.c: *regformats*): ...this.
4437 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
4439 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
4440 (xtensa_fill_gregset): Call collect_register_by_name for
4442 (xtensa_store_gregset): Call supply_register_by_name for
4445 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
4447 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
4448 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
4449 (xtensa_store_gregset): Call supply_register for all registers in
4450 a0_regnum..a0_regnum + C0_NREGS range.
4452 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4454 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
4455 (ax-ipa.o: ax.c): Remove.
4456 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
4457 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
4458 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
4459 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
4460 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
4462 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4464 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
4465 (print-utils-ipa.o: ../common/print-utils.c): Remove.
4466 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
4467 (errors-ipa.o: ../common/errors.c): Remove.
4468 (format-ipa.o: ../common/format.c): Remove.
4469 (common-utils-ipa.o: ../common/common-utils.c): Remove.
4471 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4473 * Makefile.in (%-ipa.o: %.c): New rule.
4474 (tracepoint-ipa.o: tracepoint.c): Remove.
4475 (utils-ipa.o: utils.c): Remove.
4476 (remote-utils-ipa.o: remote-utils.c): Remove.
4477 (regcache-ipa.o: regcache.c): Remove.
4478 (i386-linux-ipa.o: i386-linux.c): Remove.
4479 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
4480 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
4481 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
4482 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
4483 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
4484 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
4485 (amd64-linux-ipa.o: amd64-linux.c): Remove.
4486 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
4487 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
4488 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
4489 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
4490 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
4491 (aarch64-ipa.o: aarch64.c): Remove.
4492 (s390-linux32-ipa.o: s390-linux32.c): Remove.
4493 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
4494 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
4495 (s390-linux64-ipa.o: s390-linux64.c): Remove.
4496 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
4497 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
4498 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
4499 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
4500 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
4501 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
4502 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
4503 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
4504 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
4505 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
4506 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
4507 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
4508 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
4509 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
4510 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
4511 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
4512 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
4513 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
4514 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
4515 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
4516 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
4517 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
4518 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
4519 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
4520 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
4521 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
4522 (tdesc-ipa.o: tdesc.c): Remove.
4523 (x32-linux-ipa.o: x32-linux.c): Remove.
4524 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
4525 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
4527 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4529 * Makefile.in (%.o: ../arch/%.c): New rule.
4530 (arm.o: ../arch/arm.c): Remove.
4531 (arm-linux.o: ../arch/arm-linux.c): Remove.
4532 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
4533 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
4535 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4537 * Makefile.in (%.o: ../nat/%.c): New rule.
4538 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
4539 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
4540 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
4541 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
4542 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
4543 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
4544 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
4545 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
4546 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
4547 (linux-personality.o: ../nat/linux-personality.c): Remove.
4548 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
4549 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
4550 (x86-linux.o: ../nat/x86-linux.c): Remove.
4551 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
4552 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
4554 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4556 * Makefile.in (%.o: ../common/%.c): New rule.
4557 (signals.o: ../common/signals.c): Remove.
4558 (print-utils.o: ../common/print-utils.c): Remove.
4559 (rsp-low.o: ../common/rsp-low.c): Remove.
4560 (common-utils.o: ../common/common-utils.c): Remove.
4561 (posix-strerror.o: ../common/posix-strerror.c): Remove.
4562 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
4563 (vec.o: ../common/vec.c): Remove.
4564 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
4565 (xml-utils.o: ../common/xml-utils.c): Remove.
4566 (ptid.o: ../common/ptid.c): Remove.
4567 (buffer.o: ../common/buffer.c): Remove.
4568 (format.o: ../common/format.c): Remove.
4569 (filestuff.o: ../common/filestuff.c): Remove.
4570 (agent.o: ../common/agent.c): Remove.
4571 (errors.o: ../common/errors.c): Remove.
4572 (environ.o: ../common/environ.c): Remove.
4573 (common-debug.o: ../common/common-debug.c): Remove.
4574 (cleanups.o: ../common/cleanups.c): Remove.
4575 (common-exceptions.o: ../common/common-exceptions.c): Remove.
4576 (fileio.o: ../common/fileio.c): Remove.
4577 (common-regcache.o: ../common/common-regcache.c): Remove.
4578 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
4579 (new-op.o: ../common/new-op.c): Remove.
4580 (btrace-common.o: ../common/btrace-common.c): Remove.
4582 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4584 * Makefile.in (%.o: ../target/%.c): New rule.
4585 (waitstatus.o: ../target/waitstatus.c): Remove.
4587 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4590 (%.c: ../regformats/%.dat,
4591 (%.c: ../regformats/arm/%.dat,
4592 (%.c: ../regformats/i386/%.dat,
4593 (%.c: ../regformats/rs6000/%.dat): New rules.
4594 (aarch64.c): Remove.
4595 (reg-arm.c): Remove.
4596 (arm-with-iwmmxt.c): Remove.
4597 (arm-with-vfpv2.c): Remove.
4598 (arm-with-vfpv3.c): Remove.
4599 (arm-with-neon.c): Remove.
4600 (reg-bfin.c): Remove.
4601 (reg-cris.c): Remove.
4602 (reg-crisv32.c): Remove.
4604 (i386-linux.c): Remove.
4605 (i386-avx.c): Remove.
4606 (i386-avx-linux.c): Remove.
4607 (i386-avx-avx512.c): Remove.
4608 (i386-avx-avx512-linux.c): Remove.
4609 (i386-mpx.c): Remove.
4610 (i386-mpx-linux.c): Remove.
4611 (i386-avx-mpx-avx512-pku.c): Remove.
4612 (i386-avx-mpx-avx512-pku-linux.c): Remove.
4613 (i386-avx-mpx.c): Remove.
4614 (i386-avx-mpx-linux.c): Remove.
4615 (i386-mmx.c): Remove.
4616 (i386-mmx-linux.c): Remove.
4617 (reg-ia64.c): Remove.
4618 (reg-m32r.c): Remove.
4619 (reg-m68k.c): Remove.
4621 (mips-linux.c): Remove.
4622 (mips-dsp-linux.c): Remove.
4623 (mips64-linux.c): Remove.
4624 (mips64-dsp-linux.c): Remove.
4625 (nios2-linux.c): Remove.
4626 (powerpc-32.c): Remove.
4627 (powerpc-32l.c): Remove.
4628 (powerpc-altivec32l.c): Remove.
4629 (powerpc-cell32l.c): Remove.
4630 (powerpc-vsx32l.c): Remove.
4631 (powerpc-isa205-32l.c): Remove.
4632 (powerpc-isa205-altivec32l.c): Remove.
4633 (powerpc-isa205-vsx32l.c): Remove.
4634 (powerpc-e500l.c): Remove.
4635 (powerpc-64l.c): Remove.
4636 (powerpc-altivec64l.c): Remove.
4637 (powerpc-cell64l.c): Remove.
4638 (powerpc-vsx64l.c): Remove.
4639 (powerpc-isa205-64l.c): Remove.
4640 (powerpc-isa205-altivec64l.c): Remove.
4641 (powerpc-isa205-vsx64l.c): Remove.
4642 (s390-linux32.c): Remove.
4643 (s390-linux32v1.c): Remove.
4644 (s390-linux32v2.c): Remove.
4645 (s390-linux64.c): Remove.
4646 (s390-linux64v1.c): Remove.
4647 (s390-linux64v2.c): Remove.
4648 (s390-te-linux64.c): Remove.
4649 (s390-vx-linux64.c): Remove.
4650 (s390-tevx-linux64.c): Remove.
4651 (s390x-linux64.c): Remove.
4652 (s390x-linux64v1.c): Remove.
4653 (s390x-linux64v2.c): Remove.
4654 (s390x-te-linux64.c): Remove.
4655 (s390x-vx-linux64.c): Remove.
4656 (s390x-tevx-linux64.c): Remove.
4657 (tic6x-c64xp-linux.c): Remove.
4658 (tic6x-c64x-linux.c): Remove.
4659 (tic6x-c62x-linux.c): Remove.
4661 (reg-sparc64.c): Remove.
4662 (reg-spu.c): Remove.
4664 (amd64-linux.c): Remove.
4665 (amd64-avx.c): Remove.
4666 (amd64-avx-linux.c): Remove.
4667 (amd64-avx-avx512.c): Remove.
4668 (amd64-avx-avx512-linux.c): Remove.
4669 (amd64-mpx.c): Remove.
4670 (amd64-mpx-linux.c): Remove.
4671 (amd64-avx-mpx-avx512-pku.c): Remove.
4672 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
4673 (amd64-avx-mpx.c): Remove.
4674 (amd64-avx-mpx-linux.c): Remove.
4676 (x32-linux.c): Remove.
4677 (x32-avx.c): Remove.
4678 (x32-avx-linux.c): Remove.
4679 (x32-avx-avx512.c): Remove.
4680 (x32-avx-avx512-linux.c): Remove.
4681 (reg-xtensa.c): Remove.
4682 (reg-tilegx.c): Remove.
4683 (reg-tilegx32.c): Remove.
4685 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
4687 * Makefile.in (SFILES): Add "common/environ.c".
4688 (OBJS): Add "common/environ.h".
4690 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
4692 * configure.ac: Check if the fs_base and gs_base members of
4693 `struct user_regs_struct' exist.
4694 * config.in: Regenerated.
4695 * configure: Likewise.
4697 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
4699 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
4701 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
4702 (get_next_pcs_syscall_next_pc): Likewise.
4704 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
4706 * win32-i386-low.c: Fix incorrect reference to a couple source files.
4707 * nto-x86-low.c: Likewise.
4709 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
4711 * Makefile.in: Include disable-implicit-rules.mk.
4713 2016-11-23 Pedro Alves <palves@redhat.com>
4715 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
4716 (debug_vprintf): Use std::chrono::steady_clock instead of
4717 gettimeofday. Use '.' instead of ':'.
4718 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
4719 (get_timestamp): Use std::chrono::steady_clock instead of
4722 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
4724 * Makefile.in: Fix whitespace formatting.
4726 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
4728 * Makefile.in (SFILES, OBS): Flatten list and order
4731 2016-11-23 Pedro Alves <palves@redhat.com>
4733 * event-loop.c (handle_file_event): Use warning.
4734 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
4735 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
4738 2016-11-23 Pedro Alves <palves@redhat.com>
4740 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
4742 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
4743 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
4744 debug_printf and debug_flush for debug output.
4745 * server.c (handle_general_set): Likewise.
4746 * thread-db.c (try_thread_db_load): Use debug_printf for debug
4749 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
4751 * Makefile.in (.c.o): Replace rule with ...
4752 (%.o: %.c): ... this one.
4754 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
4756 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
4757 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
4759 * configure.ac: Remove checks for the make program.
4760 * configure: Re-generate.
4762 2016-10-28 Pedro Alves <palves@redhat.com>
4764 * Makefile.in (CXX_DIALECT): Get from configure.
4765 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
4766 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
4767 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
4768 * config.in: Regenerate.
4769 * configure: Regenerate.
4771 2016-10-27 Yao Qi <yao.qi@linaro.org>
4773 * linux-low.c (linux_supports_range_stepping): Return true if
4774 can_software_single_step return true.
4776 2016-10-27 Yao Qi <yao.qi@linaro.org>
4778 * inferiors.c (find_inferior_in_random): New function.
4779 * inferiors.h (find_inferior_in_random): Declare.
4780 * linux-low.c (linux_wait_for_event_filtered): Call
4781 find_inferior_in_random instead of find_inferior.
4783 2016-10-27 Yao Qi <yao.qi@linaro.org>
4785 * linux-low.c (linux_wait_1): If single-step breakpoints are
4786 inserted, remove them.
4788 2016-10-26 Pedro Alves <palves@redhat.com>
4790 * linux-low.c (handle_extended_wait): Link parent/child fork
4792 (linux_wait_1): Unlink them.
4793 (linux_set_resume_request): Ignore resume requests for
4794 already-resumed and unhandled fork child threads.
4795 * linux-low.h (struct lwp_info) <fork_relative>: New field.
4796 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
4798 (handle_v_requests) <vCont>: Don't call require_running.
4799 * server.h (in_queued_stop_replies): New declaration.
4801 2016-10-24 Yao Qi <yao.qi@linaro.org>
4804 * linux-aarch64-low.c (append_insns): Cast the return value to
4807 2016-10-10 Yao Qi <yao.qi@linaro.org>
4809 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
4811 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
4813 * target.c (target_supports_multi_process): New function, moved
4815 * target.h (target_supports_multi_process): ... here. Remove
4818 2016-10-05 Tom Tromey <tom@tromey.com>
4821 * tracepoint.c (handle_tracepoint_bkpts): Check
4822 ipa_error_tracepoint, not ipa_stopping_tracepoint.
4824 2016-10-05 Yao Qi <yao.qi@linaro.org>
4826 * configure.srv: Update the path of arm-*.xml files.
4828 2016-10-05 Terry Guo <terry.guo@arm.com>
4829 Yao Qi <yao.qi@linaro.org>
4831 * Makefile.in: Adjust the path of rules.
4832 * configure.srv: Update the path of xml files.
4833 * regformats/arm-with-iwmmxt.dat: Regenerated.
4834 * regformats/arm-with-neon.dat: Likewise.
4835 * regformats/arm-with-vfpv2.dat: Likewise.
4836 * regformats/arm-with-vfpv3.dat Likewise.
4838 2016-09-30 Yao Qi <yao.qi@linaro.org>
4841 * target.c (target_stop_and_wait): Don't call
4842 target_continue_no_signal, use resume_stop instead.
4844 2016-09-26 Yao Qi <yao.qi@linaro.org>
4846 * linux-low.c (linux_wait_1): Call debug_exit.
4848 2016-09-23 Pedro Alves <palves@redhat.com>
4850 * Makefile.in (SFILES): Add common/new-op.c.
4851 (OBS): Add common/new-op.o.
4852 (new-op.o): New rule.
4854 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
4856 * .gitinore: Ignore more files.
4858 2016-09-21 Yao Qi <yao.qi@linaro.org>
4860 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
4863 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
4865 * server.c (start_inferior): Call target_mourn_inferior instead of
4866 mourn_inferior; pass ptid_t argument to it.
4868 (handle_target_event): Likewise.
4869 * target.c (target_mourn_inferior): New function.
4870 * target.h (mourn_inferior): Delete macro.
4872 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
4874 * linux-low.c (lwp_is_stepping): New function.
4876 2016-09-06 Carl Love <cel@us.ibm.com>
4878 * server.c (start_inferior): Fixed comment, requested comment change
4879 didn't get updated correctly. Removed reference to ptrace () call as
4880 it is only true on Linux systems.
4882 2016-09-06 Carl Love <cel@us.ibm.com>
4884 * server.c (start_inferior): Do not call
4885 function target_post_create_inferior () if the
4886 inferior process has already exited.
4888 2016-09-05 Pedro Alves <palves@redhat.com>
4890 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
4891 (COMPILE.pre, CC_LD): Use CXX directly.
4892 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
4893 * acinclude.m4: Don't include build-with-cxx.m4.
4894 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
4895 * configure: Regenerate.
4897 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
4900 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
4901 call writing data to own_buf.
4903 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
4905 * target.c (mywait): Call target_wait instead of
4907 (target_wait): New function.
4909 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
4911 * server.c (start_inferior): New variable 'ptid'. Replace calls
4912 to the_target->resume by target_continue{,_no_signal}, depending
4914 * target.c (target_stop_and_wait): Call target_continue_no_signal
4915 instead of the_target->resume.
4916 (target_continue): New function.
4918 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
4920 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
4922 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
4925 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
4927 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
4928 * linux-arm-low.c (ps_get_thread_area): Likewise.
4929 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
4930 * linux-m68k-low.c (ps_get_thread_area): Likewise.
4931 * linux-mips-low.c (ps_get_thread_area): Likewise.
4932 * linux-nios2-low.c (ps_get_thread_area): Likewise.
4933 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
4934 * linux-x86-low.c (ps_get_thread_area): Likewise.
4935 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
4937 2016-08-19 Pedro Alves <palves@redhat.com>
4939 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
4941 2016-08-19 Pedro Alves <palves@redhat.com>
4943 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
4944 comment. Use memcpy instead of casting through unsigned long.
4946 2016-08-19 Pedro Alves <palves@redhat.com>
4948 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
4949 allocating around 0x80000000.
4951 2016-08-19 Pedro Alves <palves@redhat.com>
4954 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
4955 (x32-avx512-linux-ipa.o): New rules.
4956 * configure.ac (x86_64-*-linux*): New x32 check.
4957 * configure.srv (ipa_x32_linux_regobj): New.
4958 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
4959 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
4961 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
4963 * configure: Regenerate.
4965 2016-08-09 Pedro Alves <palves@redhat.com>
4968 * Makefile.in (OBS): Add signals-state-save-restore.o.
4969 (signals-state-save-restore.o): New rule.
4970 * config.in: Regenerate.
4971 * configure: Regenerate.
4972 * linux-low.c: Include "signals-state-save-restore.h".
4973 (linux_create_inferior): Call
4974 restore_original_signals_state.
4975 * server.c: Include "dispositions-save-restore.h".
4976 (captured_main): Call save_original_signals_state.
4978 2016-08-05 Pedro Alves <palves@redhat.com>
4980 * configure: Regenerate.
4982 2016-08-04 Yao Qi <yao.qi@linaro.org>
4984 * linux-low.c (regsets_fetch_inferior_registers): Check
4985 errno is ESRCH or not.
4987 2016-08-02 Yao Qi <yao.qi@linaro.org>
4989 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
4990 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
4991 (thread_db_load_search): Update.
4992 (try_thread_db_load_1): Don't look for td_ta_event_addr,
4993 td_ta_set_event and td_ta_event_getmsg.
4995 2016-07-26 Pedro Alves <palves@redhat.com>
4998 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
4999 of unsigned long for 64-bit registers and use uint32_t instead of
5000 unsigned int for 32-bit registers.
5002 2016-07-26 Pedro Alves <palves@redhat.com>
5004 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
5007 2016-07-21 Tom Tromey <tom@tromey.com>
5009 * configure: Rebuild.
5011 2016-07-21 Yao Qi <yao.qi@linaro.org>
5013 * mem-break.c (find_gdb_breakpoint): Cast bp to
5014 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
5016 2016-07-21 Yao Qi <yao.qi@linaro.org>
5018 * server.c (handle_v_requests): Support s and S actions
5019 if target_supports_software_single_step return true.
5021 2016-07-21 Yao Qi <yao.qi@linaro.org>
5023 * linux-low.c (resume_stopped_resumed_lwps): If resume request
5024 is resume_step, call maybe_hw_step.
5025 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
5027 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
5029 (proceed_one_lwp): If resume request is resume_step, install
5030 reinsert breakpoints and call maybe_hw_step.
5032 2016-07-21 Yao Qi <yao.qi@linaro.org>
5034 * linux-low.c (proceed_one_lwp): Declare.
5035 (linux_resume_one_thread): Remove local variable 'step'.
5036 Lift code enqueue signal. Call proceed_one_lwp instead of
5037 linux_resume_one_lwp.
5039 2016-07-21 Yao Qi <yao.qi@linaro.org>
5041 * linux-low.c (linux_resume_one_thread): Call
5042 enqueue_pending_signal.
5044 2016-07-21 Yao Qi <yao.qi@linaro.org>
5046 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
5047 * inferiors.c (do_restore_current_thread_cleanup): New function.
5048 (make_cleanup_restore_current_thread): Likewise.
5049 * linux-low.c (install_software_single_step_breakpoints): Call
5050 make_cleanup_restore_current_thread. Switch current_thread to
5053 2016-07-21 Yao Qi <yao.qi@linaro.org>
5055 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
5056 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
5057 (clone_one_breakpoint): Likewise.
5058 (delete_reinsert_breakpoints): Change parameter to thread.
5060 (has_reinsert_breakpoints): Likewise.
5061 (uninsert_reinsert_breakpoints): Likewise.
5062 (reinsert_reinsert_breakpoints): Likewise.
5063 * mem-break.h (set_reinsert_breakpoint): Update declaration.
5064 (delete_reinsert_breakpoints): Likewise.
5065 (reinsert_reinsert_breakpoints): Likewise.
5066 (uninsert_reinsert_breakpoints): Likewise.
5067 (has_reinsert_breakpoints): Likewise.
5069 2016-07-21 Yao Qi <yao.qi@linaro.org>
5071 * inferiors.c (get_thread_process): Make parameter const.
5072 * inferiors.h (get_thread_process): Update declaration.
5073 * mem-break.c (clone_all_breakpoints): Remove all parameters.
5074 Add new parameters child_thread and parent_thread. Callers
5076 * mem-break.h (clone_all_breakpoints): Update declaration.
5078 2016-07-21 Yao Qi <yao.qi@linaro.org>
5080 * mem-break.c (struct breakpoint) <cond_list>: Remove.
5081 <command_list, handler>: Remove.
5082 (struct gdb_breakpoint): New.
5083 (struct other_breakpoint): New.
5084 (struct reinsert_breakpoint): New.
5085 (is_gdb_breakpoint): New function.
5086 (any_persistent_commands): Update command_list if
5087 is_gdb_breakpoint returns true.
5088 (set_breakpoint): Create breakpoints according to their types.
5089 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
5090 (set_gdb_breakpoint_1): Likewise.
5091 (set_gdb_breakpoint): Likewise.
5092 (clear_breakpoint_conditions): Change parameter type to
5093 'struct gdb_breakpoint *'.
5094 (clear_breakpoint_commands): Likewise.
5095 (clear_breakpoint_conditions_and_commands): Likewise.
5096 (add_condition_to_breakpoint): Likewise.
5097 (add_breakpoint_condition): Likewise.
5098 (add_commands_to_breakpoint): Likewise.
5099 (check_breakpoints): Check other_breakpoint.
5100 (clone_one_breakpoint): Clone breakpopint according to its type.
5101 * mem-break.h (struct gdb_breakpoint): Declare.
5102 (set_gdb_breakpoint): Update declaration.
5103 (clear_breakpoint_conditions_and_commands): Likewise.
5104 (add_breakpoint_condition): Likewise.
5105 (add_breakpoint_commands): Likewise.
5106 * server.c (process_point_options): Change parameter type to
5107 'struct gdb_breakpoint *'.
5109 2016-07-21 Yao Qi <yao.qi@linaro.org>
5111 * mem-break.c (set_breakpoint_at): Rename it to ...
5112 (set_breakpoint_type_at): ... it.
5113 (set_breakpoint_at): Call set_breakpoint_type_at.
5114 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
5115 * mem-break.h (set_breakpoint_at): Update comments.
5117 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
5119 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
5121 (nios2_store_gregset): Likewise.
5123 2016-07-01 Pedro Alves <palves@redhat.com>
5124 Antoine Tremblay <antoine.tremblay@ericsson.com>
5126 * linux-low.c: Change interface to take the target lwp_info
5127 pointer directly and return void. Handle detaching from a zombie
5129 (linux_detach_lwp_callback): New function.
5130 (linux_detach): Detach from the leader thread after detaching from
5133 2016-06-28 Yao Qi <yao.qi@linaro.org>
5135 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
5136 for variable new_offset.
5137 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
5138 (aarch64_ftrace_insn_reloc_cb): Likewise.
5139 (aarch64_ftrace_insn_reloc_tb): Likewise.
5140 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
5141 PRIx64 instead of PRIx32.
5143 2016-06-28 Yao Qi <yao.qi@linaro.org>
5145 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
5146 (the_low_target): Install arm_get_syscall_trapinfo.
5148 2016-06-28 Yao Qi <yao.qi@linaro.org>
5150 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
5152 (the_low_target): Install aarch64_get_syscall_trapinfo.
5154 2016-06-28 Yao Qi <yao.qi@linaro.org>
5156 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
5158 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
5159 Remove parameter sysno.
5160 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
5163 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5165 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
5166 (s390_emit_ne_goto): Likewise.
5167 (s390_emit_lt_goto): Likewise.
5168 (s390_emit_le_goto): Likewise.
5169 (s390_emit_gt_goto): Likewise.
5170 (s390_emit_ge_goto): Likewise.
5171 (s390x_emit_eq_goto): Likewise.
5172 (s390x_emit_ne_goto): Likewise.
5173 (s390x_emit_lt_goto): Likewise.
5174 (s390x_emit_le_goto): Likewise.
5175 (s390x_emit_gt_goto): Likewise.
5176 (s390x_emit_ge_goto): Likewise.
5177 (s390_emit_ops_impl): Mark variable static.
5178 (s390x_emit_ops): Likewise.
5180 2016-06-17 Yao Qi <yao.qi@linaro.org>
5182 * linux-low.c (handle_extended_wait): Call
5183 uninsert_reinsert_breakpoints for the parent process. Remove
5184 reinsert breakpoints from the child process. Reinsert them to
5185 the parent process when vfork is done.
5186 * mem-break.c (uninsert_reinsert_breakpoints): New function.
5187 (reinsert_reinsert_breakpoints): New function.
5188 * mem-break.h (uninsert_reinsert_breakpoints): Declare
5189 (reinsert_reinsert_breakpoints): Declare.
5191 2016-06-17 Yao Qi <yao.qi@linaro.org>
5193 * linux-low.c (handle_extended_wait): If the parent is doing
5194 step-over, remove the reinsert breakpoints from the forked child.
5196 2016-06-17 Yao Qi <yao.qi@linaro.org>
5198 * linux-low.c (unsuspend_all_lwps): Declare.
5199 (linux_low_filter_event): If thread exited, call finish_step_over.
5200 If step-over is finished, unsuspend other threads.
5202 2016-06-17 Yao Qi <yao.qi@linaro.org>
5204 * linux-low.c (linux_resume_one_lwp_throw): Assert
5205 has_reinsert_breakpoints returns false.
5206 * mem-break.c (delete_disabled_breakpoints): Assert
5207 bp type isn't reinsert_breakpoint.
5209 2016-06-17 Yao Qi <yao.qi@linaro.org>
5211 * linux-low.c (maybe_hw_step): New function.
5212 (linux_resume_one_lwp_throw): Call maybe_hw_step.
5213 (finish_step_over): Switch current_thread to lwp temporarily,
5214 and assert has_reinsert_breakpoints returns true.
5215 (proceed_one_lwp): Call maybe_hw_step.
5216 * mem-break.c (has_reinsert_breakpoints): New function.
5217 * mem-break.h (has_reinsert_breakpoints): Declare.
5219 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
5221 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
5223 2016-05-17 Yao Qi <yao.qi@linaro.org>
5225 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
5226 instead of find_inferior.
5228 2016-05-05 Yao Qi <yao.qi@linaro.org>
5230 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
5231 Initialize res to zero.
5233 2016-05-05 Yao Qi <yao.qi@linaro.org>
5235 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
5238 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
5240 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
5241 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
5242 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
5244 2016-04-28 Par Olsson <par.olsson@windriver.com>
5245 Simon Marchi <simon.marchi@ericsson.com>
5247 * tracepoint.c (write_inferior_int8): New function.
5248 (cmd_qtenable_disable): Write enable flag using
5249 write_inferior_int8.
5251 2016-04-25 Yao Qi <yao.qi@linaro.org>
5253 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
5254 (need_step_over_p): Return zero if the LWP has pending signals
5255 can be delivered on software single step target.
5257 2016-04-25 Yao Qi <yao.qi@linaro.org>
5259 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
5260 return instead of error.
5262 2016-04-22 Yao Qi <yao.qi@linaro.org>
5264 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
5267 2016-04-22 Yao Qi <yao.qi@linaro.org>
5269 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
5270 signal when stepping over breakpoint with software single
5273 2016-04-21 Pedro Alves <palves@redhat.com>
5275 * linux-s390-low.c (s390_collect_ptrace_register)
5276 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
5278 (s390_check_regset): Use void * instead of gdb_byte *.
5280 2016-04-20 Pedro Alves <palves@redhat.com>
5282 * configure: Renegerate.
5284 2016-04-20 Yao Qi <yao.qi@linaro.org>
5286 * linux-aarch32-low.c: Include "arch/arm-linux.h".
5287 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
5289 (arm_store_gregset): Likewise.
5291 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
5293 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
5294 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
5295 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
5296 (amd64-avx-mpx-linux.c): New rules.
5297 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
5298 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
5299 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
5300 (srv_amd64_regobj): Add amd64-avx-mpx.o.
5301 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
5302 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
5303 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
5304 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
5305 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
5306 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
5307 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
5308 * linux-x86-low.c (x86_linux_read_description): Add case for
5309 X86_XSTATE_AVX_MPX_MASK.
5310 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
5311 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
5312 init_registers_i386_avx_mpx_linux.
5313 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
5314 (initialize_low_tracepoint): Call
5315 init_registers_i386_avx_mpx_linux.
5316 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
5317 (initialize_low_tracepoint): Call
5318 init_registers_amd64_avx_mpx_linux.
5319 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
5320 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
5321 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
5324 2016-04-18 Pedro Alves <palves@redhat.com>
5326 * configure: Regenerate.
5328 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
5330 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
5331 (aarch64_emit_sub): Likewise.
5333 2016-04-12 Pedro Alves <palves@redhat.com>
5335 * utils.c (prepare_to_throw_exception): Delete.
5337 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
5339 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
5341 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
5343 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
5345 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
5347 * linux-aarch64-ipa.c: Add <elf.h> include.
5348 * linux-ppc-ipa.c: Add <elf.h> include.
5349 * linux-s390-ipa.c: Add <elf.h> include.
5351 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
5353 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
5354 (get_raw_reg_ptr): Likewise.
5355 (get_trace_state_variable_value_ptr): Likewise.
5356 (set_trace_state_variable_value_ptr): Likewise.
5357 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
5360 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
5361 Marcin Kościelnicki <koriakin@0x04.net>
5364 * linux-ppc-low.c (emit_insns): New function.
5365 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
5366 (ppc_emit_prologue): New function.
5367 (ppc_emit_epilogue): New function.
5368 (ppc_emit_add): New function.
5369 (ppc_emit_sub): New function.
5370 (ppc_emit_mul): New function.
5371 (ppc_emit_lsh): New function.
5372 (ppc_emit_rsh_signed): New function.
5373 (ppc_emit_rsh_unsigned): New function.
5374 (ppc_emit_ext): New function.
5375 (ppc_emit_zero_ext): New function.
5376 (ppc_emit_log_not): New function.
5377 (ppc_emit_bit_and): New function.
5378 (ppc_emit_bit_or): New function.
5379 (ppc_emit_bit_xor): New function.
5380 (ppc_emit_bit_not): New function.
5381 (ppc_emit_equal): New function.
5382 (ppc_emit_less_signed): New function.
5383 (ppc_emit_less_unsigned): New function.
5384 (ppc_emit_ref): New function.
5385 (ppc_emit_const): New function.
5386 (ppc_emit_reg): New function.
5387 (ppc_emit_pop): New function.
5388 (ppc_emit_stack_flush): New function.
5389 (ppc_emit_swap): New function.
5390 (ppc_emit_stack_adjust): New function.
5391 (ppc_emit_call): New function.
5392 (ppc_emit_int_call_1): New function.
5393 (ppc_emit_void_call_2): New function.
5394 (ppc_emit_if_goto): New function.
5395 (ppc_emit_goto): New function.
5396 (ppc_emit_eq_goto): New function.
5397 (ppc_emit_ne_goto): New function.
5398 (ppc_emit_lt_goto): New function.
5399 (ppc_emit_le_goto): New function.
5400 (ppc_emit_gt_goto): New function.
5401 (ppc_emit_ge_goto): New function.
5402 (ppc_write_goto_address): New function.
5403 (ppc_emit_ops_impl): New static variable.
5404 (ppc64v1_emit_prologue): New function.
5405 (ppc64v2_emit_prologue): New function.
5406 (ppc64_emit_epilogue): New function.
5407 (ppc64_emit_add): New function.
5408 (ppc64_emit_sub): New function.
5409 (ppc64_emit_mul): New function.
5410 (ppc64_emit_lsh): New function.
5411 (ppc64_emit_rsh_signed): New function.
5412 (ppc64_emit_rsh_unsigned): New function.
5413 (ppc64_emit_ext): New function.
5414 (ppc64_emit_zero_ext): New function.
5415 (ppc64_emit_log_not): New function.
5416 (ppc64_emit_bit_and): New function.
5417 (ppc64_emit_bit_or): New function.
5418 (ppc64_emit_bit_xor): New function.
5419 (ppc64_emit_bit_not): New function.
5420 (ppc64_emit_equal): New function.
5421 (ppc64_emit_less_signed): New function.
5422 (ppc64_emit_less_unsigned): New function.
5423 (ppc64_emit_ref): New function.
5424 (ppc64_emit_const): New function.
5425 (ppc64v1_emit_reg): New function.
5426 (ppc64v2_emit_reg): New function.
5427 (ppc64_emit_pop): New function.
5428 (ppc64_emit_stack_flush): New function.
5429 (ppc64_emit_swap): New function.
5430 (ppc64v1_emit_call): New function.
5431 (ppc64v2_emit_call): New function.
5432 (ppc64v1_emit_int_call_1): New function.
5433 (ppc64v2_emit_int_call_1): New function.
5434 (ppc64v1_emit_void_call_2): New function.
5435 (ppc64v2_emit_void_call_2): New function.
5436 (ppc64_emit_if_goto): New function.
5437 (ppc64_emit_eq_goto): New function.
5438 (ppc64_emit_ne_goto): New function.
5439 (ppc64_emit_lt_goto): New function.
5440 (ppc64_emit_le_goto): New function.
5441 (ppc64_emit_gt_goto): New function.
5442 (ppc64_emit_ge_goto): New function.
5443 (ppc64v1_emit_ops_impl): New static variable.
5444 (ppc64v2_emit_ops_impl): New static variable.
5445 (ppc_emit_ops): New function.
5446 (linux_low_target): Wire in ppc_emit_ops.
5448 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
5449 Marcin Kościelnicki <koriakin@0x04.net>
5452 * Makefile.in: Add powerpc-*-ipa.o
5453 * configure.srv: Add ipa_obj for powerpc*-linux.
5454 * linux-ppc-ipa.c: New file.
5455 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
5457 (PPC_FIELD): New macro.
5458 (PPC_SEXT): New macro.
5459 (PPC_OP6): New macro.
5460 (PPC_BO): New macro.
5461 (PPC_LI): New macro.
5462 (PPC_BD): New macro.
5463 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
5464 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
5465 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
5466 (ppc_get_thread_area): New function.
5467 (is_elfv2_inferior): New function.
5468 (gen_ds_form): New function.
5469 (GEN_STD): New macro.
5470 (GEN_STDU): New macro.
5471 (GEN_LD): New macro.
5472 (GEN_LDU): New macro.
5473 (gen_d_form): New function.
5474 (GEN_ADDI): New macro.
5475 (GEN_ADDIS): New macro.
5476 (GEN_LI): New macro.
5477 (GEN_LIS): New macro.
5478 (GEN_ORI): New macro.
5479 (GEN_ORIS): New macro.
5480 (GEN_LWZ): New macro.
5481 (GEN_STW): New macro.
5482 (GEN_STWU): New macro.
5483 (gen_xfx_form): New function.
5484 (GEN_MFSPR): New macro.
5485 (GEN_MTSPR): New macro.
5486 (GEN_MFCR): New macro.
5487 (GEN_MTCR): New macro.
5488 (GEN_SYNC): New macro.
5489 (GEN_LWSYNC): New macro.
5490 (gen_x_form): New function.
5491 (GEN_OR): New macro.
5492 (GEN_MR): New macro.
5493 (GEN_LWARX): New macro.
5494 (GEN_STWCX): New macro.
5495 (GEN_CMPW): New macro.
5496 (gen_md_form): New function.
5497 (GEN_RLDICL): New macro.
5498 (GEN_RLDICR): New macro.
5499 (gen_i_form): New function.
5501 (GEN_BL): New macro.
5502 (gen_b_form): New function.
5503 (GEN_BNE): New macro.
5504 (GEN_LOAD): New macro.
5505 (GEN_STORE): New macro.
5506 (gen_limm): New function.
5507 (gen_atomic_xchg): New function.
5508 (gen_call): New function.
5509 (ppc_relocate_instruction): New function.
5510 (ppc_install_fast_tracepoint_jump_pad): New function.
5511 (ppc_get_min_fast_tracepoint_insn_len): New function.
5512 (ppc_get_ipa_tdesc_idx): New function.
5513 (the_low_target): Wire in the new functions.
5514 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
5516 * linux-ppc-tdesc.h: New file.
5518 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
5520 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
5521 (alloc_jump_pad_buffer): New function.
5522 * linux-amd64-ipa.c: Add <sys/mman.h> include.
5523 (alloc_jump_pad_buffer): New function.
5524 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
5525 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
5526 (alloc_jump_pad_buffer): New function.
5527 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
5528 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
5529 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
5530 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
5532 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
5534 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
5535 * linux-amd64-ipa.c: Likewise.
5536 * linux-i386-ipa.c: Likewise.
5537 * linux-s390-ipa.c: Likewise.
5538 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
5539 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
5540 set_trace_state_variable_value_ptr.
5541 (struct ipa_sym_addresses): Likewise.
5542 (symbol_list): Likewise.
5543 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
5544 accessing gdb_collect directly.
5545 (gdb_collect_ptr_type): New typedef.
5546 (get_raw_reg_ptr_type): New typedef.
5547 (get_trace_state_variable_value_ptr_type): New typedef.
5548 (set_trace_state_variable_value_ptr_type): New typedef.
5549 (gdb_collect_ptr): New global.
5550 (get_raw_reg_ptr): New global.
5551 (get_trace_state_variable_value_ptr): New global.
5552 (set_trace_state_variable_value_ptr): New global.
5553 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
5554 accessing get_raw_reg directly.
5555 (get_get_tsv_func_addr): Likewise for
5556 get_trace_state_variable_value_ptr.
5557 (get_set_tsv_func_addr): Likewise for
5558 set_trace_state_variable_value_ptr.
5559 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
5561 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
5563 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
5565 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
5567 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
5569 (relocate_instruction): Remove own_buf.
5570 * server.c (own_buf): Make global.
5571 (handle_v_requests): Make global.
5572 * server.h (own_buf): New declaration.
5573 (handle_v_requests): New prototype.
5575 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
5578 * linux-s390-low.c (add_insns): New function.
5579 (s390_emit_prologue): New function.
5580 (s390_emit_epilogue): New function.
5581 (s390_emit_add): New function.
5582 (s390_emit_sub): New function.
5583 (s390_emit_mul): New function.
5584 (s390_emit_lsh): New function.
5585 (s390_emit_rsh_signed): New function.
5586 (s390_emit_rsh_unsigned): New function.
5587 (s390_emit_ext): New function.
5588 (s390_emit_log_not): New function.
5589 (s390_emit_bit_and): New function.
5590 (s390_emit_bit_or): New function.
5591 (s390_emit_bit_xor): New function.
5592 (s390_emit_bit_not): New function.
5593 (s390_emit_equal): New function.
5594 (s390_emit_less_signed): New function.
5595 (s390_emit_less_unsigned): New function.
5596 (s390_emit_ref): New function.
5597 (s390_emit_if_goto): New function.
5598 (s390_emit_goto): New function.
5599 (s390_write_goto_address): New function.
5600 (s390_emit_litpool): New function.
5601 (s390_emit_const): New function.
5602 (s390_emit_call): New function.
5603 (s390_emit_reg): New function.
5604 (s390_emit_pop): New function.
5605 (s390_emit_stack_flush): New function.
5606 (s390_emit_zero_ext): New function.
5607 (s390_emit_swap): New function.
5608 (s390_emit_stack_adjust): New function.
5609 (s390_emit_set_r2): New function.
5610 (s390_emit_int_call_1): New function.
5611 (s390_emit_void_call_2): New function.
5612 (s390_emit_eq_goto): New function.
5613 (s390_emit_ne_goto): New function.
5614 (s390_emit_lt_goto): New function.
5615 (s390_emit_le_goto): New function.
5616 (s390_emit_gt_goto): New function.
5617 (s390_emit_ge_goto): New function.
5618 (s390x_emit_prologue): New function.
5619 (s390x_emit_epilogue): New function.
5620 (s390x_emit_add): New function.
5621 (s390x_emit_sub): New function.
5622 (s390x_emit_mul): New function.
5623 (s390x_emit_lsh): New function.
5624 (s390x_emit_rsh_signed): New function.
5625 (s390x_emit_rsh_unsigned): New function.
5626 (s390x_emit_ext): New function.
5627 (s390x_emit_log_not): New function.
5628 (s390x_emit_bit_and): New function.
5629 (s390x_emit_bit_or): New function.
5630 (s390x_emit_bit_xor): New function.
5631 (s390x_emit_bit_not): New function.
5632 (s390x_emit_equal): New function.
5633 (s390x_emit_less_signed): New function.
5634 (s390x_emit_less_unsigned): New function.
5635 (s390x_emit_ref): New function.
5636 (s390x_emit_if_goto): New function.
5637 (s390x_emit_const): New function.
5638 (s390x_emit_call): New function.
5639 (s390x_emit_reg): New function.
5640 (s390x_emit_pop): New function.
5641 (s390x_emit_stack_flush): New function.
5642 (s390x_emit_zero_ext): New function.
5643 (s390x_emit_swap): New function.
5644 (s390x_emit_stack_adjust): New function.
5645 (s390x_emit_int_call_1): New function.
5646 (s390x_emit_void_call_2): New function.
5647 (s390x_emit_eq_goto): New function.
5648 (s390x_emit_ne_goto): New function.
5649 (s390x_emit_lt_goto): New function.
5650 (s390x_emit_le_goto): New function.
5651 (s390x_emit_gt_goto): New function.
5652 (s390x_emit_ge_goto): New function.
5653 (s390_emit_ops): New function.
5654 (struct linux_target_ops): Fill in emit_ops hook.
5656 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
5659 * Makefile.in: Add s390 IPA files.
5660 * configure.srv: Build IPA for s390.
5661 * linux-s390-ipa.c: New file.
5662 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
5663 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
5664 (tdesc_s390_linux32): Likewise.
5665 (init_registers_s390_linux32v1): Likewise.
5666 (tdesc_s390_linux32v1): Likewise.
5667 (init_registers_s390_linux32v2): Likewise.
5668 (tdesc_s390_linux32v2): Likewise.
5669 (init_registers_s390_linux64): Likewise.
5670 (tdesc_s390_linux64): Likewise.
5671 (init_registers_s390_linux64v1): Likewise.
5672 (tdesc_s390_linux64v1): Likewise.
5673 (init_registers_s390_linux64v2): Likewise.
5674 (tdesc_s390_linux64v2): Likewise.
5675 (init_registers_s390_te_linux64): Likewise.
5676 (tdesc_s390_te_linux64): Likewise.
5677 (init_registers_s390_vx_linux64): Likewise.
5678 (tdesc_s390_vx_linux64): Likewise.
5679 (init_registers_s390_tevx_linux64): Likewise.
5680 (tdesc_s390_tevx_linux64): Likewise.
5681 (init_registers_s390x_linux64): Likewise.
5682 (tdesc_s390x_linux64): Likewise.
5683 (init_registers_s390x_linux64v1): Likewise.
5684 (tdesc_s390x_linux64v1): Likewise.
5685 (init_registers_s390x_linux64v2): Likewise.
5686 (tdesc_s390x_linux64v2): Likewise.
5687 (init_registers_s390x_te_linux64): Likewise.
5688 (tdesc_s390x_te_linux64): Likewise.
5689 (init_registers_s390x_vx_linux64): Likewise.
5690 (tdesc_s390x_vx_linux64): Likewise.
5691 (init_registers_s390x_tevx_linux64): Likewise.
5692 (tdesc_s390x_tevx_linux64): Likewise.
5693 (have_hwcap_s390_vx): New static variable.
5694 (s390_arch_setup): Fill have_hwcap_s390_vx.
5695 (s390_get_thread_area): New function.
5696 (s390_ft_entry_gpr_esa): New const.
5697 (s390_ft_entry_gpr_zarch): New const.
5698 (s390_ft_entry_misc): New const.
5699 (s390_ft_entry_fr): New const.
5700 (s390_ft_entry_vr): New const.
5701 (s390_ft_main_31): New const.
5702 (s390_ft_main_64): New const.
5703 (s390_ft_exit_fr): New const.
5704 (s390_ft_exit_vr): New const.
5705 (s390_ft_exit_misc): New const.
5706 (s390_ft_exit_gpr_esa): New const.
5707 (s390_ft_exit_gpr_zarch): New const.
5708 (append_insns): New function.
5709 (s390_relocate_instruction): New function.
5710 (s390_install_fast_tracepoint_jump_pad): New function.
5711 (s390_get_min_fast_tracepoint_insn_len): New function.
5712 (s390_get_ipa_tdesc_idx): New function.
5713 (struct linux_target_ops): Wire in the above functions.
5714 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
5715 * linux-s390-tdesc.h: New file.
5717 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
5719 * linux-s390-low.c (s390_supports_tracepoints): New function.
5720 (struct linux_target_ops): Fill supports_tracepoints hook.
5722 2016-03-18 Yao Qi <yao.qi@linaro.org>
5724 * linux-low.c (lwp_signal_can_be_delivered): New function.
5725 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
5727 2016-03-18 Yao Qi <yao.qi@linaro.org>
5729 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
5730 0 if signal is enqueued. Remove 'signal' from one debugging
5731 message. Move one debugging message to some lines below.
5732 Remove code setting 'signal' to 0.
5734 2016-03-18 Yao Qi <yao.qi@linaro.org>
5736 * linux-low.c (linux_low_filter_event): Remove redundant
5737 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
5739 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
5741 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
5742 (struct linux_target_ops): Wire in the above.
5744 2016-03-03 Yao Qi <yao.qi@linaro.org>
5746 * linux-low.c: Update comments to start_step_over.
5748 2016-03-03 Yao Qi <yao.qi@linaro.org>
5751 * linux-low.c (handle_extended_wait): Set child suspended
5752 if event_lwp->bp_reinsert isn't zero.
5754 2016-03-02 Yao Qi <yao.qi@linaro.org>
5756 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
5757 enqueue_pending_signal.
5759 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
5761 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
5764 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
5766 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
5767 (s390_regmap_3264) [!__s390x__]: New global.
5768 (s390_collect_ptrace_register): Skip map entries containing -1.
5769 (s390_supply_ptrace_register): Ditto.
5770 (s390_fill_gprs_high): New function.
5771 (s390_store_gprs_high): New function.
5772 (s390_regsets): Add NT_S390_HIGH_GPRS.
5773 (s390_get_hwcap): Enable on 31-bit.
5774 (have_hwcap_s390_high_gprs): Enable on 31-bit.
5775 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
5776 Detect NT_S390_HIGH_GPRS.
5777 (s390_usrregs_info_3264): Enable on 31-bit.
5778 (s390_regs_info): Enable regs_info_3264 on 31-bit.
5779 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
5781 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
5784 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
5785 * configure.srv: Ditto.
5786 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
5787 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
5788 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
5789 (init_registers_amd64_linux): Remove prototype.
5790 (tdesc_amd64_linux): Remove declaration.
5791 (get_ipa_tdesc): New function.
5792 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
5793 initialize remaining tdescs.
5794 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
5795 (init_registers_i386_linux): Remove prototype.
5796 (tdesc_i386_linux): Remove declaration.
5797 (get_ipa_tdesc): New function.
5798 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
5799 initialize remaining tdescs.
5800 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
5801 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
5802 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
5803 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
5804 (x86_get_ipa_tdesc_idx): New function.
5805 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
5806 * linux-x86-tdesc.h: New file.
5807 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
5808 (target_get_ipa_tdesc_idx): New macro.
5809 * tracepoint.c (ipa_tdesc_idx): New macro.
5810 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
5811 (symbol_list): Add ipa_tdesc_idx.
5812 (cmd_qtstart): Write ipa_tdesc_idx in the target.
5813 (ipa_tdesc): Remove.
5814 (ipa_tdesc_idx): New variable.
5815 (get_context_regcache): Use get_ipa_tdesc.
5816 (gdb_collect): Ditto.
5818 * tracepoint.h (get_ipa_tdesc): New prototype.
5819 (ipa_tdesc): Remove.
5821 2016-02-24 Pedro Alves <palves@redhat.com>
5823 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
5824 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
5825 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
5826 Factor out common code between the USE_SIGTRAP_SIGINFO and
5827 !USE_SIGTRAP_SIGINFO blocks.
5828 (linux_low_filter_event): Call save_stop_reason instead of
5829 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
5831 (linux_wait_1): Update comments.
5833 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
5835 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
5836 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
5837 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
5838 ppc_insert_point, ppc_remove_point.
5840 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
5842 * linux-s390-low.c (s390_supports_z_point_type): New function.
5843 (struct linux_target_ops): Wire s390_supports_z_point_type in.
5845 2016-02-16 Yao Qi <yao.qi@linaro.org>
5847 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
5848 PC. Get pc from regcache_read_pc.
5850 2016-02-12 Yao Qi <yao.qi@linaro.org>
5852 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
5853 or linux_get_pc_32bit.
5854 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
5856 2016-02-12 Yao Qi <yao.qi@linaro.org>
5858 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
5859 arm_linux_get_next_pcs_fixup.
5861 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
5863 * tracepoint.c (x_tracepoint_action_download): Change
5864 write_inferior_data_ptr to write_inferior_data_pointer.
5865 (cmd_qtstart): Likewise.
5866 (write_inferior_data_ptr): Remove.
5867 (download_agent_expr): Change write_inferior_data_ptr to
5868 write_inferior_data_pointer.
5869 (download_tracepoint_1): Likewise.
5870 (download_tracepoint): Likewise.
5871 (download_trace_state_variables): Likewise.
5873 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
5874 Marcin Kościelnicki <koriakin@0x04.net>
5876 * tracepoint.c (struct tracepoint_action_ops): Remove.
5877 (struct tracepoint_action): Remove ops.
5878 (m_tracepoint_action_download, r_tracepoint_action_download)
5879 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
5880 size and offset accordingly.
5881 (m_tracepoint_action_ops, r_tracepoint_action_ops)
5882 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
5883 (tracepoint_action_send, tracepoint_action_download): New functions.
5884 Helpers for trace action handlers.
5885 (add_tracepoint_action): Remove setup actions ops.
5886 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
5888 2016-02-10 Yao Qi <yao.qi@linaro.org>
5890 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
5892 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
5894 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
5896 * configure: Regenerate.
5898 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
5900 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
5901 void * to gdb_byte *.
5902 * linux-low.c (siginfo_fixup): Likewise.
5903 (linux_xfer_siginfo): Likewise.
5904 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
5906 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
5908 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
5910 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
5912 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
5914 * linux-x86-low.c [__x86_64__]: Include
5915 "nat/amd64-linux-siginfo.h".
5916 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
5917 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
5918 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
5919 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
5920 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
5921 (cpt_si_fd, si_timerid, si_overrun): Move from
5922 nat/amd64-linux-siginfo.c.
5923 * Makefile.in (amd64-linux-siginfo.o:): New rule.
5925 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
5927 * server.c (skip_to_semicolon): Remove.
5928 (process_point_options): Use strchrnul instead of
5931 2016-01-26 Yao Qi <yao.qi@linaro.org>
5933 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
5934 * linux-low.c (install_software_single_step_breakpoints): Don't
5935 call regcache_read_pc.
5936 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
5939 2016-01-26 Yao Qi <yao.qi@linaro.org>
5941 * linux-low.c (install_software_single_step_breakpoints): Call
5942 regcache_read_pc instead of get_pc.
5944 2016-01-26 Yao Qi <yao.qi@linaro.org>
5946 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
5947 (unblock_async_io): Rename to ...
5948 (block_unblock_async_io): ... it. New function.
5949 (enable_async_io): Don't install SIGIO handler. Unblock it
5951 (disable_async_io): Don't ignore SIGIO. Block it instead.
5952 (initialize_async_io): Install SIGIO handler. Don't call
5955 2016-01-26 Yao Qi <yao.qi@linaro.org>
5957 * remote-utils.c (getpkt): If the buffer isn't empty, and the
5958 first character is '\003', call *the_target->request_interrupt.
5960 2016-01-25 Yao Qi <yao.qi@linaro.org>
5962 * remote-utils.c (new_thread_notify): Remove.
5963 (dead_thread_notify): Likewise.
5964 * remote-utils.h (new_thread_notify): Remove declaration.
5965 (dead_thread_notify): Likewise.
5967 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
5969 * gdb.trace/pending.exp: Fix expected message on continue.
5971 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
5973 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
5974 it works properly on big-endian machines where sizeof (CORE_ADDR)
5977 2016-01-21 Pedro Alves <palves@redhat.com>
5979 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
5980 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
5981 * configure: Regenerate.
5983 2016-01-21 Yao Qi <yao.qi@linaro.org>
5985 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
5986 is_thumb and set it according to CPSR saved on the stack.
5987 (get_next_pcs_syscall_next_pc): Pass is_thumb to
5988 arm_sigreturn_next_pc.
5990 2016-01-18 Yao Qi <yao.qi@linaro.org>
5992 * linux-low.c (linux_set_pc_64bit): New function.
5993 (linux_get_pc_64bit): New function.
5994 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
5996 * linux-sparc-low.c (debug_threads): Remove declaration.
5997 (sparc_get_pc): Remove.
5998 (the_low_target): Use linux_get_pc_64bit instead of
6000 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
6001 (the_low_target): Use linux_get_pc_64bit and
6004 2016-01-18 Yao Qi <yao.qi@linaro.org>
6006 * linux-arm-low.c (debug_threads): Remove declaration.
6007 (arm_get_pc, arm_set_pc): Remove.
6008 (the_low_target): Use linux_get_pc_32bit and
6010 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
6011 (the_low_target): Use linux_get_pc_32bit and
6013 * linux-cris-low.c (debug_threads): Remove declaration.
6014 (cris_get_pc, cris_set_pc,): Remove.
6015 (the_low_target): Use linux_get_pc_32bit and
6017 * linux-crisv32-low.c (debug_threads): Remove declaration.
6018 (cris_get_pc, cris_set_pc): Remove.
6019 (the_low_target): Use linux_get_pc_32bit and
6021 * linux-low.c: Include inttypes.h.
6022 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
6023 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
6024 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
6025 (the_low_target): Use linux_get_pc_32bit and
6027 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
6028 (the_low_target): Use linux_get_pc_32bit and
6030 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
6031 (the_low_target): Use linux_get_pc_32bit and
6033 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
6034 (the_low_target): Use linux_get_pc_32bit and
6036 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
6037 (the_low_target): Use linux_get_pc_32bit and
6040 2016-01-18 Gary Benson <gbenson@redhat.com>
6042 * configure.ac (AC_FUNC_FORK): New check.
6043 * config.in: Regenerate.
6044 * configure: Likewise.
6046 2016-01-14 Yao Qi <yao.qi@linaro.org>
6048 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
6049 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
6050 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
6051 arm_get_next_pcs_ctor.
6053 2016-01-12 Josh Stone <jistone@redhat.com>
6054 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6056 * inferiors.h: Include "gdb_vecs.h".
6057 (struct process_info): Add syscalls_to_catch.
6058 * inferiors.c (remove_process): Free syscalls_to_catch.
6059 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
6060 syscall_return stops.
6061 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
6062 * server.c (handle_general_set): Handle QCatchSyscalls.
6063 (handle_query): Report support for QCatchSyscalls.
6064 * target.h (struct target_ops): Add supports_catch_syscall.
6065 (target_supports_catch_syscall): New macro.
6066 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
6067 (struct lwp_info): Add syscall_state.
6068 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
6069 Maintain syscall_state and syscalls_to_catch across exec.
6070 (get_syscall_trapinfo): New function, proxy to the_low_target.
6071 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
6072 (linux_low_filter_event): Toggle syscall_state entry/return for
6073 syscall traps, and set it ignored for all others.
6074 (gdb_catching_syscalls_p): New function.
6075 (gdb_catch_this_syscall_p): New function.
6076 (linux_wait_1): Handle SYSCALL_SIGTRAP.
6077 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
6078 (linux_supports_catch_syscall): New function.
6079 (linux_target_ops): Install it.
6080 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
6081 (the_low_target): Install it.
6083 2016-01-12 Mike Frysinger <vapier@gentoo.org>
6085 * acinclude.m4: Include new ../warning.m4 file.
6086 * configure: Regenerated.
6087 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
6089 2016-01-12 Mike Frysinger <vapier@gentoo.org>
6091 * ax.c (is_goto_target): Mark static.
6092 * linux-low.c (register_addr): Likewise.
6093 (linux_fetch_registers, linux_store_registers): Likewise.
6094 * mem-break.c (any_persistent_commands): Fix old prototype.
6095 (add_commands_to_breakpoint): Mark static.
6096 * regcache.c (find_register_by_name): Delete unused func.
6097 * remote-utils.c (hex_or_minus_one): Mark static.
6098 * server.c (monitor_show_help): Mark static.
6099 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
6100 handle_v_requests): Likewise.
6102 2016-01-12 Pedro Alves <palves@redhat.com>
6104 Remove use of the registered trademark symbol throughout.
6106 2016-01-08 Yao Qi <yao.qi@linaro.org>
6108 * remote-utils.c (getpkt): If c is '\003', call target hook
6111 2016-01-06 Yao Qi <yao.qi@linaro.org>
6113 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
6114 linux-aarch32-low.c.
6115 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6116 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
6117 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
6118 (thumb2_breakpoint): Declare.
6119 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
6120 linux-aarch32-low.h.
6121 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6122 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
6123 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
6125 2016-01-01 Joel Brobecker <brobecker@adacore.com>
6127 * gdbreplay.c (gdbreplay_version): Change copyright year in
6129 * server.c (gdbserver_version): Likewise.
6131 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
6133 * server.c (crc32_table): Delete.
6134 (crc32): Use libiberty's xcrc32 function.
6136 2015-12-22 Joel Brobecker <brobecker@adacore.com>
6138 * lynx-low.c (lynx_delete_thread_callback): New function.
6139 (lynx_mourn): Properly delete our process and all of its
6140 threads. Remove call to clear_inferiors.
6142 2015-12-22 Joel Brobecker <brobecker@adacore.com>
6144 * target.c (thread_search_callback): Add check that
6145 the thread_stopped target callback is not NULL before
6148 2015-12-21 Yao Qi <yao.qi@linaro.org>
6150 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
6153 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6155 * server.c (handle_query): Call target_supports_software_single_step.
6157 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6159 * linux-low.c (single_step): New function.
6160 (linux_resume_one_lwp_throw): Call single_step.
6161 (start_step_over): Likewise.
6163 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6165 * Makefile.in (SFILES): Append arch/arm-linux.c,
6166 arch/arm-get-next-pcs.c.
6167 (arm-linux.o): New rule.
6168 (arm-get-next-pcs.o): New rule.
6169 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
6171 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
6172 to linux-aarch32-low.c.
6173 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6174 (arm_breakpoint_len, thumb_breakpoint): Likewise.
6175 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
6176 (thumb2_breakpoint_len): Likewise.
6177 (arm_is_thumb_mode): Make non-static.
6178 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
6179 from linux-aarch32-low.c.
6180 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6181 (arm_breakpoint_len, thumb_breakpoint): Likewise.
6182 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
6183 (thumb2_breakpoint_len): Likewise.
6184 (arm_is_thumb_mode): New declaration.
6185 * linux-arm-low.c: Include arch/arm-linux.h
6186 aarch/arm-get-next-pcs.h, sys/syscall.h.
6187 (get_next_pcs_ops): New struct.
6188 (get_next_pcs_addr_bits_remove): New function.
6189 (get_next_pcs_is_thumb): New function.
6190 (get_next_pcs_read_memory_unsigned_integer): Likewise.
6191 (arm_sigreturn_next_pc): Likewise.
6192 (get_next_pcs_syscall_next_pc): Likewise.
6193 (arm_gdbserver_get_next_pcs): Likewise.
6194 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
6196 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
6197 * server.h: Include gdb_vecs.h.
6199 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6201 * Makefile.in (SFILES): Append common/common-regcache.c.
6202 (OBS): Append common-regcache.o.
6203 (common-regcache.o): New rule.
6204 * regcache.c (init_register_cache): Initialize cache to
6206 (regcache_raw_read_unsigned): New function.
6207 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
6208 register_status enum.
6210 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6212 * linux-aarch64-low.c (the_low_targets): Rename
6213 breakpoint_reinsert_addr to get_next_pcs.
6214 * linux-arm-low.c (the_low_targets): Likewise.
6215 * linux-bfin-low.c (the_low_targets): Likewise.
6216 * linux-cris-low.c (the_low_targets): Likewise.
6217 * linux-crisv32-low.c (the_low_targets): Likewise.
6218 * linux-low.c (can_software_single_step): Likewise.
6219 (install_software_single_step_breakpoints): New function.
6220 (start_step_over): Use install_software_single_step_breakpoints.
6221 * linux-low.h: New CORE_ADDR vector.
6222 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
6224 * linux-mips-low.c (the_low_targets): Likewise.
6225 * linux-nios2-low.c (the_low_targets): Likewise.
6226 * linux-sparc-low.c (the_low_targets): Likewise.
6228 2015-12-17 Pedro Alves <palves@redhat.com>
6230 * linux-low.c (linux_kill_one_lwp): Remove references to
6232 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
6234 (linux_init_signals): Delete.
6235 (initialize_low): Adjust.
6236 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
6238 2015-12-16 Pedro Alves <palves@redhat.com>
6240 * configure.ac (compiler warning flags): When testing a
6241 -Wno-foo option, check whether -Wfoo works instead.
6242 * configure: Regenerate.
6244 2015-12-11 Don Breazeal <donb@codesourcery.com>
6246 * server.c (process_serial_event): Don't exit from gdbserver
6247 in remote mode if there are still active inferiors.
6249 2015-12-11 Yao Qi <yao.qi@linaro.org>
6251 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
6252 arm_breakpoint_at if the process is 32-bit.
6254 2015-12-11 Yao Qi <yao.qi@linaro.org>
6256 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
6259 2015-12-07 Yao Qi <yao.qi@linaro.org>
6261 * configure.srv: Append arm.o to srv_tgtobj for
6262 aarch64*-*-linux* target.
6263 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
6264 from linux-arm-low.c.
6265 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6266 (arm_breakpoint_len, thumb_breakpoint): Likewise.
6267 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
6268 (thumb2_breakpoint_len): Likewise.
6269 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
6270 (arm_breakpoint_kinds): Likewise.
6271 (arm_breakpoint_kind_from_pc): Likewise.
6272 (arm_sw_breakpoint_from_kind): Likewise.
6273 (arm_breakpoint_kind_from_current_state): Likewise.
6274 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
6275 (arm_sw_breakpoint_from_kind): Declare.
6276 (arm_breakpoint_kind_from_current_state): Declare.
6277 (arm_breakpoint_at): Declare.
6278 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
6279 arm_sw_breakpoint_from_kind if process is 32-bit.
6280 (aarch64_breakpoint_kind_from_pc): New function.
6281 (aarch64_breakpoint_kind_from_current_state): New function.
6282 (the_low_target): Initialize fields breakpoint_kind_from_pc
6283 and breakpoint_kind_from_current_state.
6284 * linux-arm-low.c (arm_breakpoint_kinds): Move to
6285 linux-aarch32-low.c.
6286 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
6287 (arm_breakpoint, arm_breakpoint_len): Likewise.
6288 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
6289 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
6290 (arm_is_thumb_mode): Likewise.
6291 (arm_breakpoint_at): Likewise.
6292 (arm_breakpoint_kind_from_pc): Likewise.
6293 (arm_sw_breakpoint_from_kind): Likewise.
6294 (arm_breakpoint_kind_from_current_state): Likewise.
6297 2015-08-04 Yao Qi <yao.qi@linaro.org>
6299 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
6300 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
6301 * server.c (extended_protocol): Remove "static".
6302 * server.h (extended_protocol): Declare it.
6304 2015-12-04 Josh Stone <jistone@redhat.com>
6306 * target.h (struct target_ops) <arch_setup>: Rename to ...
6307 (struct target_ops) <post_create_inferior>: ... this.
6308 (target_arch_setup): Rename to ...
6309 (target_post_create_inferior): ... this, calling post_create_inferior.
6310 * server.c (start_inferior): Update target_arch_setup calls to
6311 target_post_create_inferior.
6312 * linux-low.c (linux_low_ptrace_options): Forward declare.
6313 (linux_arch_setup): Update its comment for general use.
6314 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
6315 (struct linux_target_ops): Use linux_post_create_inferior.
6316 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
6317 to post_create_inferior.
6318 * nto-low.c (struct nto_target_ops): Likewise.
6319 * spu-low.c (struct spu_target_ops): Likewise.
6320 * win32-low.c (struct win32_target_ops): Likewise.
6322 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
6324 * linux-arm-low.c: Remove duplicate arch/arm.h include.
6326 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6328 * linux-arm-low.c (arm_reinsert_addr): Remove function.
6329 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
6330 * linux-cris-low.c (cris_reinsert_addr> Remove function.
6331 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6332 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
6333 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6334 * linux-mips-low.c (mips_reinsert_addr): Remove function.
6335 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6336 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
6337 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6338 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
6339 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6341 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6343 * linux-low.c (linux_look_up_symbols): Don't call
6344 linux_supports_traceclone.
6345 * linux-low.h (thread_db_init): Remove use_events argument.
6346 * thread-db.c (thread_db_use_event): Remove global variable.
6347 (struct thread_db) <td_thr_event_enable_p>: Remove field.
6348 (struct thread_db) <td_create_bp>: Remove field.
6349 (thread_db_create_event): Remove function.
6350 (thread_db_enable_reporting): Likewise.
6351 (find_one_thread): Don't check for thread_db_use_events.
6352 (attach_thread): Likewise.
6353 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
6354 (try_thread_db_load_1): Don't check for thread_db_use_events.
6355 (thread_db_init): Remove use_events argument and thread events
6357 (remove_thread_event_breakpoints): Remove function.
6358 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
6360 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6362 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
6364 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6365 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
6366 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6367 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
6368 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
6370 * linux-crisv32-low.c (cris_supports_hardware_single_step):
6372 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6373 * linux-low.c (can_hardware_single_step): Use
6374 supports_hardware_single_step.
6375 (can_software_single_step): New function.
6376 (start_step_over): Call can_software_single_step.
6377 (linux_supports_hardware_single_step): New function.
6378 (struct target_ops) <supports_software_single_step>: Initialize.
6379 * linux-low.h (struct linux_target_ops)
6380 <supports_hardware_single_step>: Initialize.
6381 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
6382 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6383 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
6384 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
6385 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
6386 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6387 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
6388 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6389 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
6390 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
6392 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
6393 (struct linux_target_ops) <tile_supports_hardware_single_step>:
6395 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
6396 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6397 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
6399 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6400 * target.h (struct target_ops): <supports_software_single_step>:
6402 (target_supports_software_single_step): New macro.
6404 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6406 * linux-low.c (linux_wait_1): Fix pc advance condition.
6407 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
6408 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
6410 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6412 * linux-arm-low.c (arm_is_thumb_mode): New function.
6413 (arm_breakpoint_at): Use arm_is_thumb_mode.
6414 (arm_breakpoint_kind_from_current_state): New function.
6415 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
6417 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
6418 (linux_breakpoint_kind_from_current_state): New function.
6419 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
6420 * linux-low.h (struct linux_target_ops)
6421 <breakpoint_kind_from_current_state>: New field.
6422 * target.h (struct target_ops): Likewise.
6423 (target_breakpoint_kind_from_current_state): New macro.
6425 2015-11-30 Pedro Alves <palves@redhat.com>
6427 * linux-low.c (linux_resume): Wake up the event loop before
6430 2015-11-30 Pedro Alves <palves@redhat.com>
6432 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
6434 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
6436 * target.c (struct thread_search): New structure.
6437 (thread_search_callback): New function.
6438 (prev_general_thread): New global.
6439 (prepare_to_access_memory, done_accessing_memory): New functions.
6440 * target.h (prepare_to_access_memory, done_accessing_memory):
6441 Replace macros with function declarations.
6443 2015-11-30 Pedro Alves <palves@redhat.com>
6446 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
6447 report TARGET_WAITKIND_NO_RESUMED.
6448 * remote-utils.c (prepare_resume_reply): Handle
6449 TARGET_WAITKIND_NO_RESUMED.
6450 * server.c (report_no_resumed): New global.
6451 (handle_query) <qSupported>: Handle "no-resumed+". Report
6452 "no-resumed+" support.
6453 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
6454 return error if the client doesn't support no-resumed events.
6455 (push_stop_notification): New function.
6456 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
6457 events if the client supports them.
6459 2015-11-30 Pedro Alves <palves@redhat.com>
6461 * linux-low.c (thread_still_has_status_pending_p): Don't check
6463 (lwp_resumed): New function.
6464 (status_pending_p_callback): Return early if the LWP is not
6465 supposed to be resumed.
6467 2015-11-30 Pedro Alves <palves@redhat.com>
6469 * linux-low.c (handle_extended_wait): Assert that the LWP's
6470 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
6471 thread create events, leave the new child's status pending.
6472 (linux_low_filter_event): If GDB wants to hear about thread exit
6473 events, leave the LWP marked dead and don't delete it.
6474 (linux_wait_for_event_filtered): Don't check for thread exit.
6475 (filter_exit_event): New function.
6476 (linux_wait_1): Use it, when returning an exit event.
6477 (linux_resume_one_lwp_throw): Assert that the LWP's
6478 waitstatus is TARGET_WAITKIND_IGNORE.
6479 * remote-utils.c (prepare_resume_reply): Handle
6480 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
6481 * server.c (report_thread_events): New global.
6482 (handle_general_set): Handle QThreadEvents.
6483 (handle_query) <qSupported>: Handle and report QThreadEvents+;
6484 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
6485 TARGET_WAITKIND_THREAD_EXITED.
6486 * server.h (report_thread_events): Declare.
6488 2015-11-30 Pedro Alves <palves@redhat.com>
6490 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
6491 the thread's last_resume_kind was resume_stop.
6493 2015-11-30 Pedro Alves <palves@redhat.com>
6495 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
6498 2015-11-30 Pedro Alves <palves@redhat.com>
6500 * server.c (handle_v_requests): Handle vCtrlC.
6502 2015-11-30 Pedro Alves <palves@redhat.com>
6504 * gdbthread.h (find_any_thread_of_pid): Declare.
6505 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
6507 * server.c (handle_query): If current_thread is NULL, look for
6508 another thread of the selected process.
6510 2015-11-26 Daniel Colascione <dancol@dancol.org>
6511 Simon Marchi <simon.marchi@ericsson.com>
6513 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
6514 * server.c (handle_qxfer_threads_worker): Refactor to include thread
6516 * target.h (struct target_ops) <thread_name>: New field.
6517 (target_thread_name): New macro.
6519 2015-11-23 Joel Brobecker <brobecker@adacore.com>
6521 * regcache.h (regcache_invalidate_pid): Add declaration.
6522 * regcache.c (regcache_invalidate_pid): New function, extracted
6523 from regcache_invalidate.
6524 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
6525 Add trivial documentation comment.
6526 * lynx-low.c: Use regcache_invalidate_pid instead of
6527 regcache_invalidate.
6529 2015-11-23 Joel Brobecker <brobecker@adacore.com>
6531 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
6532 and Elf64_auxv_t if the target is Android.
6534 2015-11-22 Doug Evans <xdje42@gmail.com>
6536 * target.h: #include <sys/types.h>.
6538 2015-11-19 Pedro Alves <palves@redhat.com>
6540 * linux-low.c (linux_process_qsupported): Change prototype.
6542 * linux-low.h (struct linux_target_ops) <process_qsupported>:
6544 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
6545 and adjust to loop over all features.
6546 * server.c (handle_query) <qSupported>: Adjust to call
6547 target_process_qsupported once, passing it a vector of unprocessed
6549 * target.h (struct target_ops) <process_qsupported>: Change
6551 (target_process_qsupported): Adjust.
6553 2015-11-19 Pedro Alves <palves@redhat.com>
6555 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
6557 * configure: Regenerate.
6559 2015-11-19 Pedro Alves <palves@redhat.com>
6561 * configure: Regenerate.
6563 2015-11-19 Yao Qi <yao.qi@linaro.org>
6565 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
6568 2015-11-19 Yao Qi <yao.qi@linaro.org>
6570 * linux-aarch64-low.c (enum aarch64_operand_type): New.
6571 (struct aarch64_operand): Move enum out.
6573 2015-11-19 Yao Qi <yao.qi@linaro.org>
6575 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
6576 struct user_fpsimd_state *.
6577 (aarch64_store_fpregset): Likewise.
6579 2015-11-19 Yao Qi <yao.qi@linaro.org>
6581 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
6582 struct user_pt_regs *.
6583 (aarch64_store_gregset): Likewise.
6585 2015-11-18 Pedro Alves <palves@redhat.com>
6587 * Makefile.in (all_object_files): Add $IPA_OBJS.
6589 2015-11-17 Pedro Alves <palves@redhat.com>
6591 * win32-low.c (win32_resume): Use gdb_signal_from_host,
6592 GDB_SIGNAL_0 and gdb_signal_to_string.
6594 2015-11-17 Pedro Alves <palves@redhat.com>
6596 * win32-low.c (handle_output_debug_string): Remove parameter.
6597 (win32_kill): Remove our_status local and adjust call to
6598 handle_output_debug_string.
6599 (get_child_debug_event): Adjust call to
6600 handle_output_debug_string.
6602 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6604 * linux-mips-low.c (mips_fill_gregset): Add cast.
6605 (mips_store_gregset): Likewise.
6606 (mips_fill_fpregset): Likewise.
6607 (mips_store_fpregset): Likewise.
6609 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6611 * linux-mips-low.c (mips_add_watchpoint): Rename private to
6614 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6616 * linux-mips-low.c (mips_linux_new_thread): Change type of
6617 watch_type to enum target_hw_bp_type.
6619 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6621 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
6622 Change return type to arm_hwbp_type.
6624 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6626 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
6627 (arm_store_gregset): Likewise.
6628 * linux-arm-low.c (arm_get_hwcap): Likewise.
6629 (arm_read_description): Likewise.
6631 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6633 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
6635 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6637 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
6638 (ppc_fill_vsxregset): Likewise.
6639 (ppc_store_vsxregset): Likewise.
6640 (ppc_fill_vrregset): Likewise.
6641 (ppc_store_vrregset): Likewise.
6642 (ppc_fill_evrregset): Likewise.
6643 (ppc_store_evrregset): Likewise.
6645 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6647 * linux-ppc-low.c (ppc_usrregs_info): Remove
6648 forward-declaration.
6649 (ppc_arch_setup): Move lower in file.
6651 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
6653 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
6654 (ps_pdwrite): Likewise.
6656 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
6658 * linux-arm-low.c (arm_new_thread): Move pointer dereference
6659 to after assert checks.
6661 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
6663 * proc-service.c (ps_pdread): Add/adjust casts.
6664 (ps_pdwrite): Add/adjust casts.
6666 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
6668 * server.c (handle_search_memory_1): Cast return value of
6671 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
6673 * server.c (write_qxfer_response): Change type of data to
6676 2015-10-29 Pedro Alves <palves@redhat.com>
6678 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
6680 2015-10-29 Pedro Alves <palves@redhat.com>
6682 * tracepoint.c (clear_installed_tracepoints): Add casts.
6684 2015-10-29 Pedro Alves <palves@redhat.com>
6686 * server.c (handle_v_cont, process_serial_event): Add enum
6687 gdb_signal casts to signal parsing code.
6689 2015-10-29 Pedro Alves <palves@redhat.com>
6691 * linux-low.h (NULL_REGSET): Define.
6692 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
6693 * linux-arm-low.c (arm_regsets): Likewise.
6694 * linux-crisv32-low.c (cris_regsets): Likewise.
6695 * linux-m68k-low.c (m68k_regsets): Likewise.
6696 * linux-mips-low.c (mips_regsets): Likewise.
6697 * linux-nios2-low.c (nios2_regsets): Likewise.
6698 * linux-ppc-low.c (ppc_regsets): Likewise.
6699 * linux-s390-low.c (s390_regsets): Likewise.
6700 * linux-sh-low.c (sh_regsets): Likewise.
6701 * linux-sparc-low.c (sparc_regsets): Likewise.
6702 * linux-tic6x-low.c (tic6x_regsets): Likewise.
6703 * linux-tile-low.c (tile_regsets): Likewise.
6704 * linux-x86-low.c (x86_regsets): Likewise.
6705 * linux-xtensa-low.c (xtensa_regsets): Likewise.
6707 2015-10-29 Pedro Alves <palves@redhat.com>
6709 * linux-low.h (NULL_REGSET): Define.
6710 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
6711 * linux-arm-low.c (arm_regsets): Likewise.
6712 * linux-crisv32-low.c (cris_regsets): Likewise.
6713 * linux-m68k-low.c (m68k_regsets): Likewise.
6714 * linux-mips-low.c (mips_regsets): Likewise.
6715 * linux-nios2-low.c (nios2_regsets): Likewise.
6716 * linux-ppc-low.c (ppc_regsets): Likewise.
6717 * linux-s390-low.c (s390_regsets): Likewise.
6718 * linux-sh-low.c (sh_regsets): Likewise.
6719 * linux-sparc-low.c (sparc_regsets): Likewise.
6720 * linux-tic6x-low.c (tic6x_regsets): Likewise.
6721 * linux-tile-low.c (tile_regsets): Likewise.
6722 * linux-x86-low.c (x86_regsets): Likewise.
6723 * linux-xtensa-low.c (xtensa_regsets): Likewise.
6725 2015-10-26 Doug Evans <dje@google.com>
6727 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
6729 2015-10-26 Doug Evans <dje@google.com>
6731 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
6733 2015-10-26 Doug Evans <dje@google.com>
6735 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
6737 (attach_thread, find_new_threads_callback): Ditto.
6739 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
6741 * mem-break.h (set_breakpoint_data): Remove.
6743 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
6745 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
6746 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
6747 (initialize_low): Remove set_breakpoint_data call.
6748 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
6749 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
6750 (initialize_low): Remove set_breakpoint_data call.
6751 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
6752 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
6753 (initialize_low): Remove set_breakpoint_data call.
6755 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
6757 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
6758 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
6759 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
6760 * target.h (target_breakpoint_kind_from_pc): New macro.
6762 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
6764 * linux-low.c (default_breakpoint_kind_from_pc): New function.
6765 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
6766 the default breakpoint kind.
6768 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6770 * linux-arm-low.c (arm_supports_z_point_type): Add software
6773 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6775 * linux-arm-low.c: Refactor breakpoint definitions.
6776 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
6777 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
6779 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6781 * Makefile.in: Add arm.c/o.
6782 * configure.srv: Likewise.
6783 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
6784 (arm_breakpoint_kind_from_pc): New function.
6785 (arm_sw_breakpoint_from_kind): Return proper kind.
6786 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
6788 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6790 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
6792 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
6793 (struct raw_breakpoint) <size>: Remove.
6794 (struct raw_breakpoint) <kind>: Add.
6795 (bp_size): New function.
6796 (bp_opcode): Likewise.
6797 (find_raw_breakpoint_at): Adjust for kind.
6798 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
6799 (remove_memory_breakpoint): Adjust for kind call bp_size.
6800 (set_raw_breakpoint_at): Adjust for kind.
6801 (set_breakpoint): Likewise.
6802 (set_breakpoint_at): Call breakpoint_kind_from_pc.
6803 (delete_raw_breakpoint): Adjust for kind.
6804 (delete_breakpoint): Likewise.
6805 (find_gdb_breakpoint): Likewise.
6806 (set_gdb_breakpoint_1): Likewise.
6807 (set_gdb_breakpoint): Likewise.
6808 (delete_gdb_breakpoint_1): Likewise.
6809 (delete_gdb_breakpoint): Likewise.
6810 (uninsert_raw_breakpoint): Likewise.
6811 (reinsert_raw_breakpoint): Likewise.
6812 (set_breakpoint_data): Remove.
6813 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
6814 (check_mem_read): Adjust for kind call bp_size.
6815 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
6816 (clone_one_breakpoint): Adjust for kind.
6817 * mem-break.h (set_gdb_breakpoint): Likewise.
6818 (delete_gdb_breakpoint): Likewise.
6819 * server.c (process_serial_event): Likewise.
6821 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6823 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
6824 (struct linux_target_ops) <breakpoint>: Remove.
6825 (struct linux_target_ops) <breakpoint_len>: Remove.
6826 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6827 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6828 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
6829 (arm_sw_breakpoint_from_kind): New function.
6830 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
6831 (struct linux_target_ops) <breakpoint>: Remove.
6832 (struct linux_target_ops) <breakpoint_len>: Remove.
6833 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6834 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6835 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
6836 (struct linux_target_ops) <breakpoint>: Remove.
6837 (struct linux_target_ops) <breakpoint_len>: Remove.
6838 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6839 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6840 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
6841 (struct linux_target_ops) <breakpoint>: Remove.
6842 (struct linux_target_ops) <breakpoint_len>: Remove.
6843 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6844 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6845 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
6846 and sw_breakpoint_from_kind to increment the pc.
6847 (linux_breakpoint_kind_from_pc): New function.
6848 (linux_sw_breakpoint_from_kind): New function.
6849 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
6850 (initialize_low): Call breakpoint_kind_from_pc and
6851 sw_breakpoint_from_kind to replace breakpoint_data/len.
6852 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
6854 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
6855 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
6856 (struct linux_target_ops) <breakpoint>: Remove.
6857 (struct linux_target_ops) <breakpoint_len>: Remove.
6858 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6859 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6860 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
6861 (struct linux_target_ops) <breakpoint>: Remove.
6862 (struct linux_target_ops) <breakpoint_len>: Remove.
6863 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6864 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6865 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
6866 (struct linux_target_ops) <breakpoint>: Remove.
6867 (struct linux_target_ops) <breakpoint_len>: Remove.
6868 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6869 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6870 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
6871 (struct linux_target_ops) <breakpoint>: Remove.
6872 (struct linux_target_ops) <breakpoint_len>: Remove.
6873 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6874 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6875 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
6876 (struct linux_target_ops) <breakpoint>: Remove.
6877 (struct linux_target_ops) <breakpoint_len>: Remove.
6878 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6879 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6880 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
6881 (struct linux_target_ops) <breakpoint>: Remove.
6882 (struct linux_target_ops) <breakpoint_len>: Remove.
6883 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6884 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6885 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
6886 (struct linux_target_ops) <breakpoint>: Remove.
6887 (struct linux_target_ops) <breakpoint_len>: Remove.
6888 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6889 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6890 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
6891 (struct linux_target_ops) <breakpoint>: Remove.
6892 (struct linux_target_ops) <breakpoint_len>: Remove.
6893 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6894 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6895 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
6896 (struct linux_target_ops) <breakpoint>: Remove.
6897 (struct linux_target_ops) <breakpoint_len>: Remove.
6898 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6899 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6900 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
6901 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
6902 (struct linux_target_ops) <breakpoint>: Remove.
6903 (struct linux_target_ops) <breakpoint_len>: Remove.
6904 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6905 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6906 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
6907 (struct linux_target_ops) <breakpoint>: Remove.
6908 (struct linux_target_ops) <breakpoint_len>: Remove.
6909 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6910 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6912 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6914 * linux-cris-low.c (cris_get_pc): Remove void arg.
6916 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
6918 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
6921 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
6923 * inferiors.c (thread_pid_matches_callback): New function.
6924 (find_thread_process): New function.
6925 (remove_thread): Reset current_thread.
6926 (remove_process): Assert threads have been removed first.
6928 2015-10-15 Yao Qi <yao.qi@linaro.org>
6930 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
6932 (aarch64_remove_point): Likewise.
6933 * regcache.c (regcache_register_size): New function.
6935 2015-10-12 Yao Qi <yao.qi@linaro.org>
6937 * linux-aarch64-low.c: Update all callers as emit_load_store
6938 is renamed to aarch64_emit_load_store.
6940 2015-10-12 Yao Qi <yao.qi@linaro.org>
6942 * linux-aarch64-low.c: Update all callers of function renaming
6943 from emit_insn to aarch64_emit_insn.
6945 2015-10-12 Yao Qi <yao.qi@linaro.org>
6947 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
6948 arch/aarch64-insn.h.
6949 (struct aarch64_memory_operand): Likewise.
6951 (emit_insn): Move to arch/aarch64-insn.c.
6952 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
6953 (emit_load_store): Move to arch/aarch64-insn.c.
6954 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
6955 (can_encode_int32): Remove.
6957 2015-10-12 Yao Qi <yao.qi@linaro.org>
6959 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
6960 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
6961 (aarch64_relocate_instruction): Likewise.
6962 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
6963 (struct aarch64_insn_visitor): Likewise.
6965 2015-10-12 Yao Qi <yao.qi@linaro.org>
6967 * linux-aarch64-low.c (struct aarch64_insn_data): New.
6968 (struct aarch64_insn_visitor): New.
6969 (struct aarch64_insn_relocation_data): New.
6970 (aarch64_ftrace_insn_reloc_b): New function.
6971 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
6972 (aarch64_ftrace_insn_reloc_cb): Likewise.
6973 (aarch64_ftrace_insn_reloc_tb): Likewise.
6974 (aarch64_ftrace_insn_reloc_adr): Likewise.
6975 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
6976 (aarch64_ftrace_insn_reloc_others): Likewise.
6978 (aarch64_relocate_instruction): Use visitor.
6980 2015-10-12 Yao Qi <yao.qi@linaro.org>
6982 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
6983 int. Add argument buf.
6984 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
6985 aarch64_relocate_instruction.
6987 2015-10-12 Yao Qi <yao.qi@linaro.org>
6989 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
6990 argument insn. Remove local variable insn. Don't call
6992 (aarch64_install_fast_tracepoint_jump_pad): Call
6995 2015-09-30 Yao Qi <yao.qi@linaro.org>
6997 * linux-aarch64-low.c (emit_movk): Shorten a long line.
6998 (emit_load_store_pair): Likewise.
7000 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
7002 * dll.c (match_dll): Add cast(s).
7003 (unloaded_dll): Likewise.
7004 * linux-low.c (second_thread_of_pid_p): Likewise.
7005 (delete_lwp_callback): Likewise.
7006 (count_events_callback): Likewise.
7007 (select_event_lwp_callback): Likewise.
7008 (linux_set_resume_request): Likewise.
7009 * server.c (accumulate_file_name_length): Likewise.
7010 (emit_dll_description): Likewise.
7011 (handle_qxfer_threads_worker): Likewise.
7012 (visit_actioned_threads): Likewise.
7013 * thread-db.c (any_thread_of): Likewise.
7014 * tracepoint.c (same_process_p): Likewise.
7015 (match_blocktype): Likewise.
7016 (build_traceframe_info_xml): Likewise.
7018 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
7020 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
7022 (gdb_unparse_agent_expr): Likewise.
7023 * hostio.c (require_data): Likewise.
7024 (handle_pread): Likewise.
7025 * linux-low.c (disable_regset): Likewise.
7026 (fetch_register): Likewise.
7027 (store_register): Likewise.
7028 (get_dynamic): Likewise.
7029 (linux_qxfer_libraries_svr4): Likewise.
7030 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
7031 (set_fast_tracepoint_jump): Likewise.
7032 (uninsert_fast_tracepoint_jumps_at): Likewise.
7033 (reinsert_fast_tracepoint_jumps_at): Likewise.
7034 (validate_inserted_breakpoint): Likewise.
7035 (clone_agent_expr): Likewise.
7036 * regcache.c (init_register_cache): Likewise.
7037 * remote-utils.c (putpkt_binary_1): Likewise.
7038 (decode_M_packet): Likewise.
7039 (decode_X_packet): Likewise.
7040 (look_up_one_symbol): Likewise.
7041 (relocate_instruction): Likewise.
7042 (monitor_output): Likewise.
7043 * server.c (handle_search_memory): Likewise.
7044 (handle_qxfer_exec_file): Likewise.
7045 (handle_qxfer_libraries): Likewise.
7046 (handle_qxfer): Likewise.
7047 (handle_query): Likewise.
7048 (handle_v_cont): Likewise.
7049 (handle_v_run): Likewise.
7050 (captured_main): Likewise.
7051 * target.c (write_inferior_memory): Likewise.
7052 * thread-db.c (try_thread_db_load_from_dir): Likewise.
7053 * tracepoint.c (init_trace_buffer): Likewise.
7054 (add_tracepoint_action): Likewise.
7055 (add_traceframe): Likewise.
7056 (add_traceframe_block): Likewise.
7057 (cmd_qtdpsrc): Likewise.
7058 (cmd_qtdv): Likewise.
7059 (cmd_qtstatus): Likewise.
7060 (response_source): Likewise.
7061 (response_tsv): Likewise.
7062 (cmd_qtnotes): Likewise.
7063 (gdb_collect): Likewise.
7064 (initialize_tracepoint): Likewise.
7066 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
7068 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
7069 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
7070 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
7072 (enum aarch64_condition_codes): New enum.
7073 (w0): New static global.
7076 (struct aarch64_memory_operand) <type>: New
7077 MEMORY_OPERAND_POSTINDEX type.
7078 (postindex_memory_operand): New helper function.
7079 (emit_ret): New function.
7080 (emit_load_store_pair): New function, factored out of emit_stp
7081 with support for MEMORY_OPERAND_POSTINDEX.
7082 (emit_stp): Rewrite using emit_load_store_pair.
7083 (emit_ldp): New function.
7084 (emit_load_store): Likewise.
7085 (emit_ldr): Mention post-index instruction in comment.
7086 (emit_ldrh): New function.
7087 (emit_ldrb): New function.
7088 (emit_ldrsw): Mention post-index instruction in comment.
7089 (emit_str): Likewise.
7090 (emit_subs): New function.
7091 (emit_cmp): Likewise.
7092 (emit_and): Likewise.
7093 (emit_orr): Likewise.
7094 (emit_orn): Likewise.
7095 (emit_eor): Likewise.
7096 (emit_mvn): Likewise.
7097 (emit_lslv): Likewise.
7098 (emit_lsrv): Likewise.
7099 (emit_asrv): Likewise.
7100 (emit_mul): Likewise.
7101 (emit_sbfm): Likewise.
7102 (emit_sbfx): Likewise.
7103 (emit_ubfm): Likewise.
7104 (emit_ubfx): Likewise.
7105 (emit_csinc): Likewise.
7106 (emit_cset): Likewise.
7107 (emit_nop): Likewise.
7108 (emit_ops_insns): New helper function.
7109 (emit_pop): Likewise.
7110 (emit_push): Likewise.
7111 (aarch64_emit_prologue): New function.
7112 (aarch64_emit_epilogue): Likewise.
7113 (aarch64_emit_add): Likewise.
7114 (aarch64_emit_sub): Likewise.
7115 (aarch64_emit_mul): Likewise.
7116 (aarch64_emit_lsh): Likewise.
7117 (aarch64_emit_rsh_signed): Likewise.
7118 (aarch64_emit_rsh_unsigned): Likewise.
7119 (aarch64_emit_ext): Likewise.
7120 (aarch64_emit_log_not): Likewise.
7121 (aarch64_emit_bit_and): Likewise.
7122 (aarch64_emit_bit_or): Likewise.
7123 (aarch64_emit_bit_xor): Likewise.
7124 (aarch64_emit_bit_not): Likewise.
7125 (aarch64_emit_equal): Likewise.
7126 (aarch64_emit_less_signed): Likewise.
7127 (aarch64_emit_less_unsigned): Likewise.
7128 (aarch64_emit_ref): Likewise.
7129 (aarch64_emit_if_goto): Likewise.
7130 (aarch64_emit_goto): Likewise.
7131 (aarch64_write_goto_address): Likewise.
7132 (aarch64_emit_const): Likewise.
7133 (aarch64_emit_call): Likewise.
7134 (aarch64_emit_reg): Likewise.
7135 (aarch64_emit_pop): Likewise.
7136 (aarch64_emit_stack_flush): Likewise.
7137 (aarch64_emit_zero_ext): Likewise.
7138 (aarch64_emit_swap): Likewise.
7139 (aarch64_emit_stack_adjust): Likewise.
7140 (aarch64_emit_int_call_1): Likewise.
7141 (aarch64_emit_void_call_2): Likewise.
7142 (aarch64_emit_eq_goto): Likewise.
7143 (aarch64_emit_ne_goto): Likewise.
7144 (aarch64_emit_lt_goto): Likewise.
7145 (aarch64_emit_le_goto): Likewise.
7146 (aarch64_emit_gt_goto): Likewise.
7147 (aarch64_emit_ge_got): Likewise.
7148 (aarch64_emit_ops_impl): New static global variable.
7149 (aarch64_emit_ops): New target function, return
7150 &aarch64_emit_ops_impl.
7151 (struct linux_target_ops): Install it.
7153 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
7155 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
7156 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
7158 * linux-aarch64-ipa.c: New file.
7159 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
7161 (aarch64_get_thread_area): New target method.
7162 (extract_signed_bitfield): New helper function.
7163 (aarch64_decode_ldr_literal): New function.
7164 (enum aarch64_opcodes): New enum.
7165 (struct aarch64_register): New struct.
7166 (struct aarch64_operand): New struct.
7167 (x0): New static global.
7176 (aarch64_register): New helper function.
7177 (register_operand): Likewise.
7178 (immediate_operand): Likewise.
7179 (struct aarch64_memory_operand): New struct.
7180 (offset_memory_operand): New helper function.
7181 (preindex_memory_operand): Likewise.
7182 (enum aarch64_system_control_registers): New enum.
7183 (ENCODE): New macro.
7184 (emit_insn): New helper function.
7185 (emit_b): New function.
7186 (emit_bcond): Likewise.
7187 (emit_cb): Likewise.
7188 (emit_tb): Likewise.
7189 (emit_blr): Likewise.
7190 (emit_stp): Likewise.
7191 (emit_ldp_q_offset): Likewise.
7192 (emit_stp_q_offset): Likewise.
7193 (emit_load_store): Likewise.
7194 (emit_ldr): Likewise.
7195 (emit_ldrsw): Likewise.
7196 (emit_str): Likewise.
7197 (emit_ldaxr): Likewise.
7198 (emit_stxr): Likewise.
7199 (emit_stlr): Likewise.
7200 (emit_data_processing_reg): Likewise.
7201 (emit_data_processing): Likewise.
7202 (emit_add): Likewise.
7203 (emit_sub): Likewise.
7204 (emit_mov): Likewise.
7205 (emit_movk): Likewise.
7206 (emit_mov_addr): Likewise.
7207 (emit_mrs): Likewise.
7208 (emit_msr): Likewise.
7209 (emit_sevl): Likewise.
7210 (emit_wfe): Likewise.
7211 (append_insns): Likewise.
7212 (can_encode_int32_in): New helper function.
7213 (aarch64_relocate_instruction): New function.
7214 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
7215 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
7216 (struct linux_target_ops): Install aarch64_get_thread_area,
7217 aarch64_install_fast_tracepoint_jump_pad and
7218 aarch64_get_min_fast_tracepoint_insn_len.
7220 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
7222 * Makefile.in (aarch64-insn.o): New rule.
7223 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
7225 2015-09-21 Yao Qi <yao.qi@linaro.org>
7227 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
7229 2015-09-21 Yao Qi <yao.qi@linaro.org>
7231 * tracepoint.c (max_jump_pad_size): Remove.
7233 2015-09-18 Yao Qi <yao.qi@linaro.org>
7235 * linux-aarch64-low.c: Don't include sys/uio.h.
7236 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
7238 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
7240 * tracepoint.c (eval_result_type): Change prototype.
7241 (condition_true_at_tracepoint): Fix argument to compiled_cond.
7243 2015-09-15 Pedro Alves <palves@redhat.com>
7245 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
7246 Check whether to report exec events instead of checking whether
7247 multiprocess is enabled.
7249 2015-09-15 Pedro Alves <palves@redhat.com>
7252 * remote-utils.c (prepare_resume_reply): Merge
7253 TARGET_WAITKIND_VFORK_DONE switch case with the
7254 TARGET_WAITKIND_FORKED case.
7256 2015-09-15 Yao Qi <yao.qi@linaro.org>
7258 * server.c (handle_query): Check string comparison using
7259 "else if" instead of "if".
7261 2015-09-15 Yao Qi <yao.qi@linaro.org>
7263 * server.c (vCont_supported): New global variable.
7264 (handle_query): Set vCont_supported to 1 if "vContSupported+"
7265 matches. Append ";vContSupported+" to own_buf.
7266 (handle_v_requests): Append ";s;S" to own_buf if target supports
7267 hardware single step or vCont_supported is false.
7268 (capture_main): Set vCont_supported to zero.
7270 2015-09-15 Yao Qi <yao.qi@linaro.org>
7272 * linux-low.c (linux_supports_conditional_breakpoints): Rename
7274 (linux_supports_hardware_single_step): ... New function.
7275 (linux_target_ops): Update.
7276 * lynx-low.c (lynx_target_ops): Set field
7277 supports_hardware_single_step to target_can_do_hardware_single_step.
7278 * nto-low.c (nto_target_ops): Likewise.
7279 * spu-low.c (spu_target_ops): Likewise.
7280 * win32-low.c (win32_target_ops): Likewise.
7281 * target.c (target_can_do_hardware_single_step): New function.
7282 * target.h (struct target_ops) <supports_conditional_breakpoints>:
7283 Remove. <supports_hardware_single_step>: New field.
7284 (target_supports_conditional_breakpoints): Remove.
7285 (target_supports_hardware_single_step): New macro.
7286 (target_can_do_hardware_single_step): Declare.
7287 * server.c (handle_query): Use target_supports_hardware_single_step
7288 instead of target_supports_conditional_breakpoints.
7290 2015-09-15 Yao Qi <yao.qi@linaro.org>
7292 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
7294 (struct linux_target_ops the_low_target): Install
7295 aarch64_linux_siginfo_fixup.
7297 2015-09-11 Don Breazeal <donb@codesourcery.com>
7298 Luis Machado <lgustavo@codesourcery.com>
7300 * linux-low.c (linux_mourn): Static declaration.
7301 (linux_arch_setup): Move in front of
7302 handle_extended_wait.
7303 (linux_arch_setup_thread): New function.
7304 (handle_extended_wait): Handle exec events. Call
7305 linux_arch_setup_thread. Make event_lwp argument a
7306 pointer-to-a-pointer.
7307 (check_zombie_leaders): Do not check stopped threads.
7308 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
7309 (linux_low_filter_event): Add lwp and thread for exec'ing
7310 non-leader thread if leader thread has been deleted.
7311 Refactor code into linux_arch_setup_thread and call it.
7312 Pass child lwp pointer by reference to handle_extended_wait.
7313 (linux_wait_for_event_filtered): Update comment.
7314 (linux_wait_1): Prevent clobbering exec event status.
7315 (linux_supports_exec_events): New function.
7316 (linux_target_ops) <supports_exec_events>: Initialize new member.
7317 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
7319 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
7320 * server.c (report_exec_events): New global variable.
7321 (handle_query): Handle qSupported query for exec-events feature.
7322 (captured_main): Initialize report_exec_events.
7323 * server.h (report_exec_events): Declare new global variable.
7324 * target.h (struct target_ops) <supports_exec_events>: New
7326 (target_supports_exec_events): New macro.
7327 * win32-low.c (win32_target_ops) <supports_exec_events>:
7328 Initialize new member.
7330 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
7332 * linux-low.c (linux_low_enable_btrace): Remove.
7333 (linux_target_ops): Replace linux_low_enable_btrace with
7334 linux_enable_btrace.
7336 2015-09-03 Yao Qi <yao.qi@linaro.org>
7338 * linux-aarch64-low.c (aarch64_insert_point): Call
7339 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
7342 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
7344 * linux-low.c (check_stopped_by_breakpoint): Use
7345 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
7347 2015-08-27 Pedro Alves <palves@redhat.com>
7349 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
7351 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
7353 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
7354 the XNEW-family equivalent.
7355 (compile_bytecodes): Likewise.
7356 * dll.c (loaded_dll): Likewise.
7357 * event-loop.c (append_callback_event): Likewise.
7358 (create_file_handler): Likewise.
7359 (create_file_event): Likewise.
7360 * hostio.c (handle_open): Likewise.
7361 * inferiors.c (add_thread): Likewise.
7362 (add_process): Likewise.
7363 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
7364 * linux-arm-low.c (arm_new_process): Likewise.
7365 (arm_new_thread): Likewise.
7366 * linux-low.c (add_to_pid_list): Likewise.
7367 (linux_add_process): Likewise.
7368 (handle_extended_wait): Likewise.
7369 (add_lwp): Likewise.
7370 (enqueue_one_deferred_signal): Likewise.
7371 (enqueue_pending_signal): Likewise.
7372 (linux_resume_one_lwp_throw): Likewise.
7373 (linux_resume_one_thread): Likewise.
7374 (linux_read_memory): Likewise.
7375 (linux_write_memory): Likewise.
7376 * linux-mips-low.c (mips_linux_new_process): Likewise.
7377 (mips_linux_new_thread): Likewise.
7378 (mips_add_watchpoint): Likewise.
7379 * linux-x86-low.c (initialize_low_arch): Likewise.
7380 * lynx-low.c (lynx_add_process): Likewise.
7381 * mem-break.c (set_raw_breakpoint_at): Likewise.
7382 (set_breakpoint): Likewise.
7383 (add_condition_to_breakpoint): Likewise.
7384 (add_commands_to_breakpoint): Likewise.
7385 (clone_agent_expr): Likewise.
7386 (clone_one_breakpoint): Likewise.
7387 * regcache.c (new_register_cache): Likewise.
7388 * remote-utils.c (look_up_one_symbol): Likewise.
7389 * server.c (queue_stop_reply): Likewise.
7390 (start_inferior): Likewise.
7391 (queue_stop_reply_callback): Likewise.
7392 (handle_target_event): Likewise.
7393 * spu-low.c (fetch_ppc_memory): Likewise.
7394 (store_ppc_memory): Likewise.
7395 * target.c (set_target_ops): Likewise.
7396 * thread-db.c (thread_db_load_search): Likewise.
7397 (try_thread_db_load_1): Likewise.
7398 * tracepoint.c (add_tracepoint): Likewise.
7399 (add_tracepoint_action): Likewise.
7400 (create_trace_state_variable): Likewise.
7401 (cmd_qtdpsrc): Likewise.
7402 (cmd_qtro): Likewise.
7403 (add_while_stepping_state): Likewise.
7404 * win32-low.c (child_add_thread): Likewise.
7405 (get_image_name): Likewise.
7407 2015-08-25 Yao Qi <yao.qi@linaro.org>
7409 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
7411 2015-08-25 Yao Qi <yao.qi@linaro.org>
7413 * Makefile.in (aarch64-linux.o): New rule.
7414 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
7416 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
7417 (aarch64_init_debug_reg_state): Make it extern.
7418 (aarch64_linux_prepare_to_resume): Remove.
7420 2015-08-25 Yao Qi <yao.qi@linaro.org>
7422 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
7423 lwp_arch_private_info and ptid_of_lwp.
7425 2015-08-25 Yao Qi <yao.qi@linaro.org>
7427 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
7428 Find proc_info by find_process_pid. All callers updated.
7430 2015-08-25 Yao Qi <yao.qi@linaro.org>
7432 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
7434 (debug_reg_change_callback): Remove.
7435 (aarch64_notify_debug_reg_change): Remove.
7437 2015-08-25 Yao Qi <yao.qi@linaro.org>
7439 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
7440 Call current_lwp_ptid.
7442 2015-08-25 Yao Qi <yao.qi@linaro.org>
7444 * linux-aarch64-low.c (debug_reg_change_callback): Use
7447 2015-08-25 Yao Qi <yao.qi@linaro.org>
7449 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
7451 2015-08-25 Yao Qi <yao.qi@linaro.org>
7453 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
7455 2015-08-25 Yao Qi <yao.qi@linaro.org>
7457 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
7460 2015-08-25 Yao Qi <yao.qi@linaro.org>
7462 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
7464 (debug_reg_change_callback): Remove argument entry and add argument
7465 lwp. Remove local variable thread. Don't print thread id in the
7466 debugging output. Don't check whether pid of thread equals to pid.
7467 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
7468 iterate_over_lwps instead find_inferior.
7470 2015-08-24 Pedro Alves <palves@redhat.com>
7472 * inferiors.c (get_first_process): New function.
7473 * inferiors.h (get_first_process): New declaration.
7474 * remote-utils.c (read_ptid): Default to the first process in the
7475 list, instead of to the current thread's process.
7477 2015-08-24 Pedro Alves <palves@redhat.com>
7479 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
7480 * event-loop.c: Likewise.
7481 * remote-utils.c: Likewise.
7482 * tracepoint.c: Likewise.
7484 2015-08-24 Pedro Alves <palves@redhat.com>
7486 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
7489 2015-08-21 Pedro Alves <palves@redhat.com>
7491 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
7492 instead of literal 1.
7494 2015-08-21 Pedro Alves <palves@redhat.com>
7496 * tdesc.c (default_description): Explicitly zero-initialize.
7498 2015-08-21 Pedro Alves <palves@redhat.com>
7501 * inferiors.c (remove_thread): Discard any pending stop reply for
7503 * server.c (remove_all_on_match_pid): Rename to ...
7504 (remove_all_on_match_ptid): ... this. Work with a filter ptid
7506 (discard_queued_stop_replies): Change parameter to a ptid. Now
7508 (handle_v_kill, kill_inferior_callback, captured_main)
7509 (process_serial_event): Adjust.
7510 * server.h (discard_queued_stop_replies): Declare.
7512 2015-08-21 Pedro Alves <palves@redhat.com>
7514 * linux-low.c (wait_for_sigstop): Always switch to no thread
7515 selected if the previously current thread dies.
7516 * lynx-low.c (lynx_request_interrupt): Use the first thread's
7517 process instead of the current thread's.
7518 * remote-utils.c (input_interrupt): Don't check if there's no
7520 * server.c (gdb_read_memory, gdb_write_memory): If setting the
7521 current thread to the general thread fails, error out.
7522 (handle_qxfer_auxv, handle_qxfer_libraries)
7523 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
7524 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
7525 (handle_query): Check if there's a thread selected instead of
7526 checking whether there's any thread in the thread list.
7527 (handle_qxfer_threads, handle_qxfer_btrace)
7528 (handle_qxfer_btrace_conf): Don't error out early if there's no
7529 thread in the thread list.
7530 (handle_v_cont, myresume): Don't set the current thread to the
7532 (process_serial_event) <Hg handling>: Also set thread_id if the
7533 previous general thread is still alive.
7534 (process_serial_event) <g/G handling>: If setting the current
7535 thread to the general thread fails, error out.
7536 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
7537 thread's lwp instead of the current thread's.
7538 * target.c (set_desired_thread): If the desired thread was not
7539 found, leave the current thread pointing to NULL. Return an int
7540 (boolean) indicating success.
7541 * target.h (set_desired_thread): Change return type to int.
7543 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
7545 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
7546 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
7548 (ps_get_thread_area): New function.
7550 2015-08-19 Gary Benson <gbenson@redhat.com>
7552 * hostio.c (handle_pread): Do not attempt to read more data
7553 than hostio_reply_with_data can fit in a packet.
7555 2015-08-18 Joel Brobecker <brobecker@adacore.com>
7557 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
7559 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
7561 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
7563 2015-08-06 Pedro Alves <palves@redhat.com>
7565 * tracepoint.c (expr_eval_result): Now an int.
7567 2015-08-06 Pedro Alves <palves@redhat.com>
7569 * gdbthread.h (struct regcache): Forward declare.
7570 (struct thread_info) <regcache_data>: Now a struct regcache
7572 * inferiors.c (inferior_regcache_data)
7573 (set_inferior_regcache_data): Now work with struct regcache
7575 * inferiors.h (struct regcache): Forward declare.
7576 (inferior_regcache_data, set_inferior_regcache_data): Now work
7577 with struct regcache pointers.
7578 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
7579 (free_register_cache_thread): Remove struct regcache pointer
7582 2015-08-06 Pedro Alves <palves@redhat.com>
7584 * server.c (captured_main): On error, print the exception message
7585 to stderr, and if run_once is set, throw a quit.
7587 2015-08-06 Pedro Alves <palves@redhat.com>
7589 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
7592 2015-08-06 Pedro Alves <palves@redhat.com>
7594 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
7595 reading beyond the passed in buffer length.
7597 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
7599 * tracepoint.c (symbol_list) <required>: Remove.
7601 2015-08-06 Pedro Alves <palves@redhat.com>
7603 * linux-low.c (handle_extended_wait): Set the fork child's suspend
7604 count if stopping and suspending threads.
7605 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
7606 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
7607 (linux_detach): Complete an ongoing step-over.
7608 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
7610 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
7611 (linux_wait_1): If passing a signal to the inferior after
7612 finishing a step-over, unsuspend and re-resume all lwps. If we
7613 see a single-step event but the thread should be continuing, don't
7614 pass the trap to gdb.
7615 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
7616 internal_error instead of gdb_assert.
7617 (enqueue_pending_signal): New function.
7618 (check_ptrace_stopped_lwp_gone): Add debug output.
7619 (start_step_over): Use internal_error instead of gdb_assert.
7620 (complete_ongoing_step_over): New function.
7621 (linux_resume_one_thread): Don't resume a suspended thread.
7622 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
7625 2015-08-06 Pedro Alves <palves@redhat.com>
7627 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
7628 (linux_thread_alive): Use lwp_is_marked_dead.
7629 (extended_event_reported): Delete.
7630 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
7631 instead of extended_event_reported.
7632 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
7634 (lwp_is_marked_dead): New function.
7635 (lwp_running): Use lwp_is_marked_dead.
7636 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
7639 2015-08-06 Pedro Alves <palves@redhat.com>
7641 * linux-low.c (linux_wait_1): Move fork event output out of the
7642 !report_to_gdb check. Pass event_child->waitstatus to
7643 target_waitstatus_to_string instead of ourstatus.
7645 2015-08-04 Yao Qi <yao.qi@linaro.org>
7647 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
7648 if current_thread is 32 bit.
7650 2015-08-04 Yao Qi <yao.qi@linaro.org>
7652 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
7653 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
7654 * server.c (extended_protocol): Remove "static".
7655 * server.h (extended_protocol): Declare it.
7657 2015-08-04 Yao Qi <yao.qi@linaro.org>
7659 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
7660 both aarch64 and aarch32.
7661 (aarch64_set_pc): Likewise.
7663 2015-08-04 Yao Qi <yao.qi@linaro.org>
7665 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
7666 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
7667 arm-with-neon.xml to srv_xmlfiles.
7668 * linux-aarch64-low.c: Include linux-aarch32-low.h.
7669 (is_64bit_tdesc): New function.
7670 (aarch64_linux_read_description): New function.
7671 (aarch64_arch_setup): Call aarch64_linux_read_description.
7672 (regs_info): Rename to regs_info_aarch64.
7673 (aarch64_regs_info): Return right regs_info.
7674 (initialize_low_arch): Call initialize_low_arch_aarch32.
7676 2015-08-04 Yao Qi <yao.qi@linaro.org>
7678 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
7679 * linux-aarch32-low.c: New file.
7680 * linux-aarch32-low.h: New file.
7681 * linux-arm-low.c (arm_fill_gregset): Move it to
7682 linux-aarch32-low.c.
7683 (arm_store_gregset): Likewise.
7684 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
7685 (arm_store_vfpregset): Call arm_store_vfpregset_num.
7686 (arm_arch_setup): Check if PTRACE_GETREGSET works.
7687 (regs_info): Rename to regs_info_arm.
7688 (arm_regs_info): Return regs_info_aarch32 if
7689 have_ptrace_getregset is 1 and target description is
7690 arm_with_neon or arm_with_vfpv3.
7691 (initialize_low_arch): Don't call init_registers_arm_with_neon.
7692 Call initialize_low_arch_aarch32 instead.
7694 2015-08-04 Yao Qi <yao.qi@linaro.org>
7696 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
7697 * linux-low.c: ... here.
7698 * linux-low.h (have_ptrace_getregset): Declare it.
7700 2015-08-04 Pedro Alves <palves@redhat.com>
7702 * thread-db.c (struct thread_db): Use new typedefs.
7703 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
7705 (disable_thread_event_reporting): Cast result of dlsym to
7706 destination function pointer type.
7707 (thread_db_mourn): Use td_ta_delete_ftype.
7709 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
7711 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
7713 (CDX_BREAKPOINT): Define for R2.
7714 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
7715 (the_low_target): Add comments.
7717 2015-07-30 Yao Qi <yao.qi@linaro.org>
7719 * linux-arm-low.c (arm_hwcap): Remove it.
7720 (arm_read_description): New local variable arm_hwcap. Don't
7721 set arm_hwcap to zero.
7723 2015-07-30 Yao Qi <yao.qi@linaro.org>
7725 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
7726 Use regcache->tdesc instead.
7727 (arm_store_wmmxregset): Likewise.
7728 (arm_fill_vfpregset): Likewise.
7729 (arm_store_vfpregset): Likewise.
7731 2015-07-30 Yao Qi <yao.qi@linaro.org>
7733 * linux-arm-low.c: Include arch/arm.h.
7734 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
7735 (arm_store_gregset): Likewise.
7737 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
7739 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
7740 ptrace's 4th parameter.
7742 2015-07-27 Yao Qi <yao.qi@linaro.org>
7744 * configure.srv (case aarch64*-*-linux*): Don't set
7747 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
7749 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
7751 * linux-arm-low.c: Likewise.
7752 * linux-cris-low.c: Likewise.
7753 * linux-crisv32-low.c: Likewise.
7754 * linux-low.c: Likewise.
7755 * linux-m68k-low.c: Likewise.
7756 * linux-mips-low.c: Likewise.
7757 * linux-nios2-low.c: Likewise.
7758 * linux-s390-low.c: Likewise.
7759 * linux-sparc-low.c: Likewise.
7760 * linux-tic6x-low.c: Likewise.
7761 * linux-tile-low.c: Likewise.
7762 * linux-x86-low.c: Likewise.
7764 2015-07-24 Pedro Alves <palves@redhat.com>
7766 * config.in: Regenerate.
7767 * configure: Regenerate.
7769 2015-07-24 Pedro Alves <palves@redhat.com>
7771 * acinclude.m4: Include ../ptrace.m4.
7772 * configure.ac: Call GDB_AC_PTRACE.
7773 * config.in, configure: Regenerate.
7775 2015-07-24 Yao Qi <yao.qi@linaro.org>
7777 * linux-low.c (linux_create_inferior): Remove setting to
7778 proc->priv->new_inferior.
7779 (linux_attach): Likewise.
7780 (linux_low_filter_event): Likewise.
7781 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
7783 2015-07-24 Yao Qi <yao.qi@linaro.org>
7785 * linux-low.c (linux_arch_setup): New function.
7786 (linux_low_filter_event): If proc->tdesc is NULL and
7787 proc->attached is true, call the_low_target.arch_setup.
7788 Otherwise, keep status pending, and return.
7789 (linux_resume_one_lwp_throw): Don't call get_pc if
7790 thread->while_stepping isn't NULL. Don't call
7791 get_thread_regcache if proc->tdesc is NULL.
7792 (need_step_over_p): Return 0 if proc->tdesc is NULL.
7793 (linux_target_ops): Install arch_setup.
7794 * server.c (start_inferior): Call the_target->arch_setup.
7795 * target.h (struct target_ops) <arch_setup>: New field.
7796 (target_arch_setup): New marco.
7797 * lynx-low.c (lynx_target_ops): Update.
7798 * nto-low.c (nto_target_ops): Update.
7799 * spu-low.c (spu_target_ops): Update.
7800 * win32-low.c (win32_target_ops): Update.
7802 2015-07-24 Yao Qi <yao.qi@linaro.org>
7804 * linux-low.c (linux_add_process): Don't set
7805 proc->priv->new_inferior.
7806 (linux_create_inferior): Set proc->priv->new_inferior to 1.
7807 (linux_attach): Likewise.
7809 2015-07-24 Yao Qi <yao.qi@linaro.org>
7811 * server.c (start_inferior): Code refactor.
7813 2015-07-24 Yao Qi <yao.qi@linaro.org>
7815 * server.c (process_serial_event): Set general_thread.
7817 2015-07-21 Yao Qi <yao.qi@linaro.org>
7819 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
7820 aarch64_linux_get_debug_reg_capacity.
7822 2015-07-17 Yao Qi <yao.qi@linaro.org>
7824 * Makefile.in (aarch64-linux-hw-point.o): New rule.
7825 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
7826 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
7827 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
7828 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
7829 (AARCH64_HWP_ALIGNMENT): Likewise.
7830 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
7831 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
7832 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
7833 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
7834 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
7835 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
7836 (struct aarch64_debug_reg_state): Likewise.
7837 (struct arch_lwp_info): Likewise.
7838 (aarch64_align_watchpoint): Likewise.
7839 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
7840 (aarch64_watchpoint_length): Likewise.
7841 (aarch64_point_encode_ctrl_reg): Likewise
7842 (aarch64_point_is_aligned): Likewise.
7843 (aarch64_align_watchpoint): Likewise.
7844 (aarch64_linux_set_debug_regs):
7845 (aarch64_dr_state_insert_one_point): Likewise.
7846 (aarch64_dr_state_remove_one_point): Likewise.
7847 (aarch64_handle_breakpoint): Likewise.
7848 (aarch64_handle_aligned_watchpoint): Likewise.
7849 (aarch64_handle_unaligned_watchpoint): Likewise.
7850 (aarch64_handle_watchpoint): Likewise.
7852 2015-07-17 Yao Qi <yao.qi@linaro.org>
7854 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
7855 and don't aarch64_get_debug_reg_state. All callers update.
7856 (aarch64_handle_aligned_watchpoint): Likewise.
7857 (aarch64_handle_unaligned_watchpoint): Likewise.
7858 (aarch64_handle_watchpoint): Likewise.
7859 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
7860 (aarch64_remove_point): Likewise.
7862 2015-07-17 Yao Qi <yao.qi@linaro.org>
7864 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
7866 (aarch64_handle_unaligned_watchpoint): Likewise.
7868 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
7870 Revert the previous 3 commits:
7871 Move gdb_regex* to common/
7872 Move linux_find_memory_regions_full & co.
7873 gdbserver build-id attribute generator
7875 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
7876 Jan Kratochvil <jan.kratochvil@redhat.com>
7878 gdbserver build-id attribute generator.
7879 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
7880 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
7881 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
7883 (get_dynamic): Use find_pdhr to traverse program headers.
7884 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
7885 (compare_mapping_entry_range, struct find_memory_region_callback_data)
7886 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
7887 (get_hex_build_id): New.
7888 (linux_qxfer_libraries_svr4): Add optional build-id attribute
7889 to reply XML document.
7891 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
7892 Jan Kratochvil <jan.kratochvil@redhat.com>
7894 * target.c: Include target/target-utils.h and fcntl.h.
7895 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
7896 (target_fileio_read_stralloc): New functions.
7898 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
7900 * Makefile.in (OBS): Add gdb_regex.o.
7902 * config.in: Rebuilt.
7903 * configure: Rebuilt.
7905 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
7906 Jan Kratochvil <jan.kratochvil@redhat.com>
7908 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
7909 * Makefile.in (OBS): Add target-utils.o.
7910 (linux-maps.o, target-utils.o): New.
7911 * configure.srv (srv_linux_obj): Add linux-maps.o.
7913 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
7915 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
7917 (the_low_target): Install it.
7919 2015-07-14 Pedro Alves <palves@redhat.com>
7921 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
7922 Instead, ignore ECHILD, and throw an error for other errnos.
7924 2015-07-10 Pedro Alves <palves@redhat.com>
7926 * event-loop.c (struct callback_event) <data>: Change type to
7927 gdb_client_data instance instead of gdb_client_data pointer.
7928 (append_callback_event): Adjust.
7930 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
7932 * linux-aarch64-low.c: Add comments for each linux_target_ops
7933 method. Remove comments already covered in target_ops and
7934 linux_target_ops definitions.
7935 (the_low_target): Add comments for each unimplemented method.
7937 2015-07-09 Yao Qi <yao.qi@linaro.org>
7939 * linux-aarch64-low.c (aarch64_regmap): Remove.
7940 (aarch64_usrregs_info): Remove.
7941 (regs_info): Set field usrregs to NULL.
7943 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
7945 * linux-low.c: Include "rsp-low.h"
7946 (linux_low_encode_pt_config, linux_low_encode_raw): New.
7947 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
7948 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
7949 (handle_btrace_enable_pt): New.
7950 (handle_btrace_general_set): Support "pt".
7951 (handle_btrace_conf_general_set): Support "pt:size".
7953 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
7955 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
7958 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
7960 * linux-aarch64-low.c: Remove comment about endianness.
7961 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
7962 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
7965 2015-06-24 Gary Benson <gbenson@redhat.com>
7967 * linux-i386-ipa.c (stdint.h): Do not include.
7968 * lynx-i386-low.c (stdint.h): Likewise.
7969 * lynx-ppc-low.c (stdint.h): Likewise.
7970 * mem-break.c (stdint.h): Likewise.
7971 * thread-db.c (stdint.h): Likewise.
7972 * tracepoint.c (stdint.h): Likewise.
7973 * win32-low.c (stdint.h): Likewise.
7975 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
7977 * server.c (write_qxfer_response): Update call to
7978 remote_escape_output.
7980 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
7981 Jan Kratochvil <jan.kratochvil@redhat.com>
7983 Merge multiple hex conversions.
7984 * gdbreplay.c (tohex): Rename to 'fromhex'.
7985 (logchar): Use fromhex.
7987 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
7989 * server.c (handle_qxfer_libraries): Set `version' attribute for
7992 2015-06-10 Gary Benson <gbenson@redhat.com>
7994 * target.h (struct target_ops) <multifs_open>: New field.
7995 <multifs_unlink>: Likewise.
7996 <multifs_readlink>: Likewise.
7997 * linux-low.c (nat/linux-namespaces.h): New include.
7998 (linux_target_ops): Initialize the_target->multifs_open,
7999 the_target->multifs_unlink and the_target->multifs_readlink.
8000 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
8001 * hostio.c (hostio_fs_pid): New static variable.
8002 (hostio_handle_new_gdb_connection): New function.
8003 (handle_setfs): Likewise.
8004 (handle_open): Use the_target->multifs_open as appropriate.
8005 (handle_unlink): Use the_target->multifs_unlink as appropriate.
8006 (handle_readlink): Use the_target->multifs_readlink as
8008 (handle_vFile): Handle vFile:setfs packets.
8009 * server.c (handle_query): Call hostio_handle_new_gdb_connection
8010 after target_handle_new_gdb_connection.
8012 2015-06-10 Gary Benson <gbenson@redhat.com>
8014 * configure.ac (AC_CHECK_FUNCS): Add setns.
8015 * config.in: Regenerate.
8016 * configure: Likewise.
8017 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
8018 (linux-namespaces.o): New rule.
8019 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
8021 2015-06-09 Gary Benson <gbenson@redhat.com>
8023 * hostio.c (handle_open): Process mode argument with
8024 fileio_to_host_mode.
8026 2015-06-01 Yao Qi <yao.qi@linaro.org>
8028 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
8029 * linux-x86-low.c: Likewise.
8031 2015-05-28 Don Breazeal <donb@codesourcery.com>
8033 * linux-low.c (handle_extended_wait): Initialize
8034 thread_info.last_resume_kind for new fork children.
8036 2015-05-15 Pedro Alves <palves@redhat.com>
8038 * target.h (target_handle_new_gdb_connection): Rewrite using if
8039 wrapped in do/while.
8041 2015-05-14 Joel Brobecker <brobecker@adacore.com>
8043 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
8044 * configure, config.in: Regenerate.
8045 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
8048 2015-05-12 Don Breazeal <donb@codesourcery.com>
8050 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
8051 PTRACE_EVENT_VFORK_DONE.
8052 (linux_low_ptrace_options, extended_event_reported): Add vfork
8054 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
8055 and "vforkdone" for RSP 'T' Stop Reply Packet.
8056 * server.h (report_vfork_events): Declare
8059 2015-05-12 Don Breazeal <donb@codesourcery.com>
8061 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
8062 (the_low_target) <new_fork>: Initialize new member.
8063 * linux-arm-low.c (arm_new_fork): New function.
8064 (the_low_target) <new_fork>: Initialize new member.
8065 * linux-low.c (handle_extended_wait): Call new target function
8067 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
8068 * linux-mips-low.c (mips_add_watchpoint): New function
8069 extracted from mips_insert_point.
8070 (the_low_target) <new_fork>: Initialize new member.
8071 (mips_linux_new_fork): New function.
8072 (mips_insert_point): Call mips_add_watchpoint.
8073 * linux-x86-low.c (x86_linux_new_fork): New function.
8074 (the_low_target) <new_fork>: Initialize new member.
8076 2015-05-12 Don Breazeal <donb@codesourcery.com>
8078 * linux-low.c (handle_extended_wait): Implement return value,
8079 rename argument 'event_child' to 'event_lwp', handle
8080 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
8081 (linux_low_ptrace_options): New function.
8082 (linux_low_filter_event): Call linux_low_ptrace_options,
8083 use different argument fo linux_enable_event_reporting,
8084 use return value from handle_extended_wait.
8085 (extended_event_reported): New function.
8086 (linux_wait_1): Call extended_event_reported and set
8087 status to report fork events.
8088 (linux_write_memory): Add pid to debug message.
8089 (reset_lwp_ptrace_options_callback): New function.
8090 (linux_handle_new_gdb_connection): New function.
8091 (linux_target_ops): Initialize new structure member.
8092 * linux-low.h (struct lwp_info) <waitstatus>: New member.
8093 * lynx-low.c: Initialize new structure member.
8094 * remote-utils.c (prepare_resume_reply): Implement stop reason
8095 "fork" for "T" stop message.
8096 * server.c (handle_query): Call handle_new_gdb_connection.
8097 * server.h (report_fork_events): Declare global flag.
8098 * target.h (struct target_ops) <handle_new_gdb_connection>:
8100 (target_handle_new_gdb_connection): New macro.
8101 * win32-low.c: Initialize new structure member.
8103 2015-05-12 Don Breazeal <donb@codesourcery.com>
8105 * mem-break.c (APPEND_TO_LIST): Define macro.
8106 (clone_agent_expr): New function.
8107 (clone_one_breakpoint): New function.
8108 (clone_all_breakpoints): New function.
8109 * mem-break.h: Declare new functions.
8111 2015-05-12 Don Breazeal <donb@codesourcery.com>
8113 * linux-low.c (linux_supports_fork_events): New function.
8114 (linux_supports_vfork_events): New function.
8115 (linux_target_ops): Initialize new structure members.
8116 (initialize_low): Call linux_check_ptrace_features.
8117 * lynx-low.c (lynx_target_ops): Initialize new structure
8119 * server.c (report_fork_events, report_vfork_events):
8121 (handle_query): Add new features to qSupported packet and
8123 (captured_main): Initialize new global variables.
8124 * target.h (struct target_ops) <supports_fork_events>:
8126 <supports_vfork_events>: New member.
8127 (target_supports_fork_events): New macro.
8128 (target_supports_vfork_events): New macro.
8129 * win32-low.c (win32_target_ops): Initialize new structure
8132 2015-05-12 Gary Benson <gbenson@redhat.com>
8134 * server.c (handle_qxfer_exec_file): Use current process
8137 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
8139 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
8140 Remove HAVE_PTRACE_GETREGS conditionals.
8141 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
8142 instead of PTRACE_GETREGS and PTRACE_SETREGS.
8144 2015-05-08 Yao Qi <yao.qi@linaro.org>
8146 * linux-low.c (linux_supports_conditional_breakpoints): New
8148 (linux_target_ops): Install new target method.
8149 * lynx-low.c (lynx_target_ops): Install NULL hook for
8150 supports_conditional_breakpoints.
8151 * nto-low.c (nto_target_ops): Likewise.
8152 * spu-low.c (spu_target_ops): Likewise.
8153 * win32-low.c (win32_target_ops): Likewise.
8154 * server.c (handle_query): Check
8155 target_supports_conditional_breakpoints.
8156 * target.h (struct target_ops) <supports_conditional_breakpoints>:
8158 (target_supports_conditional_breakpoints): New macro.
8160 2015-05-06 Pedro Alves <palves@redhat.com>
8163 * server.c (start_inferior): If the process exits, mourn it.
8165 2015-04-21 Gary Benson <gbenson@redhat.com>
8167 * hostio.c (fileio_open_flags_to_host): Factored out to
8168 fileio_to_host_openflags in common/fileio.c. Single use
8171 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
8173 * linux-xtensa-low.c (xtensa_fill_gregset)
8174 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
8177 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
8179 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
8180 (regs_info): Replace usrregs pointer with NULL.
8182 2015-04-17 Gary Benson <gbenson@redhat.com>
8184 * target.h (struct target_ops) <pid_to_exec_file>: New field.
8185 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
8186 * server.c (handle_qxfer_exec_file): New function.
8187 (qxfer_packets): Add exec-file entry.
8188 (handle_query): Report qXfer:exec-file:read as supported packet.
8190 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
8192 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
8194 2015-04-09 Gary Benson <gbenson@redhat.com>
8196 * hostio-errno.c (errno_to_fileio_error): Remove function.
8197 Update caller to use remote_fileio_to_fio_error.
8199 2015-04-09 Yao Qi <yao.qi@linaro.org>
8201 * linux-low.c (linux_insert_point): Call
8202 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
8203 (linux_remove_point): Call remove_memory_breakpoint if type is
8205 * linux-x86-low.c (x86_insert_point): Don't call
8206 insert_memory_breakpoint.
8207 (x86_remove_point): Don't call remove_memory_breakpoint.
8209 2015-04-01 Pedro Alves <palves@redhat.com>
8210 Cleber Rosa <crosa@redhat.com>
8212 * server.c (gdbserver_usage): Reorganize and extend the usage
8215 2015-03-24 Pedro Alves <palves@redhat.com>
8217 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
8218 output. Also dump TRAP_TRACE.
8219 (linux_low_filter_event): In debug output, distinguish a
8220 resume_stop SIGSTOP from a delayed SIGSTOP.
8222 2015-03-24 Gary Benson <gbenson@redhat.com>
8224 * linux-x86-low.c (x86_linux_new_thread): Moved to
8226 (x86_linux_prepare_to_resume): Likewise.
8228 2015-03-24 Gary Benson <gbenson@redhat.com>
8230 * Makefile.in (x86-linux-dregs.o): New rule.
8231 * configure.srv: Add x86-linux-dregs.o to relevant targets.
8232 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
8233 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
8234 (x86_linux_dr_get): Likewise.
8235 (x86_linux_dr_set): Likewise.
8236 (update_debug_registers_callback): Likewise.
8237 (x86_linux_dr_set_addr): Likewise.
8238 (x86_linux_dr_get_addr): Likewise.
8239 (x86_linux_dr_set_control): Likewise.
8240 (x86_linux_dr_get_control): Likewise.
8241 (x86_linux_dr_get_status): Likewise.
8242 (x86_linux_update_debug_registers): Likewise.
8244 2015-03-24 Gary Benson <gbenson@redhat.com>
8246 * linux-x86-low.c (x86_linux_update_debug_registers):
8247 New function, factored out from...
8248 (x86_linux_prepare_to_resume): ...this.
8250 2015-03-24 Gary Benson <gbenson@redhat.com>
8252 * linux-x86-low.c (x86_linux_dr_get): Update comments.
8253 (x86_linux_dr_set): Likewise.
8254 (update_debug_registers_callback): Likewise.
8255 (x86_linux_dr_set_addr): Likewise.
8256 (x86_linux_dr_get_addr): Likewise.
8257 (x86_linux_dr_set_control): Likewise.
8258 (x86_linux_dr_get_control): Likewise.
8259 (x86_linux_dr_get_status): Likewise.
8260 (x86_linux_prepare_to_resume): Likewise.
8262 2015-03-24 Gary Benson <gbenson@redhat.com>
8264 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
8265 Use perror_with_name. Pass string through gettext.
8266 (x86_linux_dr_set): Likewise.
8268 2015-03-24 Gary Benson <gbenson@redhat.com>
8270 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
8271 (x86_linux_dr_set_addr): ...this.
8272 (x86_dr_low_get_addr): Rename to...
8273 (x86_linux_dr_get_addr): ...this.
8274 (x86_dr_low_set_control): Rename to...
8275 (x86_linux_dr_set_control): ...this.
8276 (x86_dr_low_get_control): Rename to...
8277 (x86_linux_dr_get_control): ...this.
8278 (x86_dr_low_get_status): Rename to...
8279 (x86_linux_dr_get_status): ...this.
8280 (x86_dr_low): Update with new function names.
8282 2015-03-24 Gary Benson <gbenson@redhat.com>
8284 * Makefile.in (x86-linux.o): New rule.
8285 * configure.srv: Add x86-linux.o to relevant targets.
8286 * linux-low.c (lwp_set_arch_private_info): New function.
8287 (lwp_arch_private_info): Likewise.
8288 * linux-x86-low.c: Include nat/x86-linux.h.
8289 (arch_lwp_info): Removed structure.
8290 (update_debug_registers_callback):
8291 Use lwp_set_debug_registers_changed.
8292 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
8293 and lwp_set_debug_registers_changed.
8294 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
8296 2015-03-24 Gary Benson <gbenson@redhat.com>
8298 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
8299 * linux-arm-low.c (arm_new_thread): Likewise.
8300 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
8301 * linux-mips-low.c (mips_linux_new_thread): Likewise.
8302 * linux-x86-low.c (x86_linux_new_thread): Likewise.
8303 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
8305 2015-03-24 Gary Benson <gbenson@redhat.com>
8307 * linux-low.c (ptid_of_lwp): New function.
8308 (lwp_is_stopped): Likewise.
8309 (lwp_stop_reason): Likewise.
8310 * linux-x86-low.c (update_debug_registers_callback):
8312 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
8315 2015-03-24 Gary Benson <gbenson@redhat.com>
8317 * linux-low.h (linux_stop_lwp): Remove declaration.
8319 2015-03-24 Gary Benson <gbenson@redhat.com>
8321 * linux-low.h: Include nat/linux-nat.h.
8322 * linux-low.c (iterate_over_lwps_args): New structure.
8323 (iterate_over_lwps_filter): New function.
8324 (iterate_over_lwps): Likewise.
8325 * linux-x86-low.c (update_debug_registers_callback):
8326 Update signature to what iterate_over_lwps expects.
8327 Remove PID check that iterate_over_lwps now performs.
8328 (x86_dr_low_set_addr): Use iterate_over_lwps.
8329 (x86_dr_low_set_control): Likewise.
8331 2015-03-24 Gary Benson <gbenson@redhat.com>
8333 * linux-x86-low.c (x86_debug_reg_state): New function.
8334 (x86_linux_prepare_to_resume): Use the above.
8336 2015-03-24 Gary Benson <gbenson@redhat.com>
8338 * linux-low.c (current_lwp_ptid): New function.
8339 * linux-x86-low.c: Include nat/linux-nat.h.
8340 (x86_dr_low_get_addr): Use current_lwp_ptid.
8341 (x86_dr_low_get_control): Likewise.
8342 (x86_dr_low_get_status): Likewise.
8344 2015-03-20 Pedro Alves <palves@redhat.com>
8346 * tracepoint.c (cmd_qtstatus): Make "str" const.
8348 2015-03-20 Pedro Alves <palves@redhat.com>
8350 * server.c (handle_general_set): Make "req_str" const.
8352 2015-03-19 Pedro Alves <palves@redhat.com>
8354 * linux-low.c (linux_resume_one_lwp): Rename to ...
8355 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
8356 instead call perror_with_name.
8357 (check_ptrace_stopped_lwp_gone): New function.
8358 (linux_resume_one_lwp): Reimplement as wrapper around
8359 linux_resume_one_lwp_throw that swallows errors if the LWP is
8362 2015-03-19 Pedro Alves <palves@redhat.com>
8364 * linux-low.c (count_events_callback, select_event_lwp_callback):
8365 No longer check whether the thread has resume_stop as last resume
8368 2015-03-19 Pedro Alves <palves@redhat.com>
8370 * linux-low.c (count_events_callback, select_event_lwp_callback):
8371 Use the lwp's status_pending_p field, not the thread's.
8373 2015-03-19 Pedro Alves <palves@redhat.com>
8375 * linux-low.c (select_event_lwp_callback): Update comments to
8376 no longer mention SIGTRAP.
8378 2015-03-18 Gary Benson <gbenson@redhat.com>
8380 * server.c (handle_query): Do not report vFile:fstat as supported.
8382 2015-03-11 Gary Benson <gbenson@redhat.com>
8384 * hostio.c (sys/types.h): New include.
8385 (sys/stat.h): Likewise.
8386 (common-remote-fileio.h): Likewise.
8387 (handle_fstat): New function.
8388 (handle_vFile): Handle vFile:fstat packets.
8390 2015-03-11 Gary Benson <gbenson@redhat.com>
8392 * configure.ac (AC_CHECK_MEMBERS): Add checks for
8393 struct stat.st_blocks and struct stat.st_blksize.
8394 * configure: Regenerate.
8395 * config.in: Likewise.
8396 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
8397 (OBS): Add common-remote-fileio.o.
8398 (common-remote-fileio.o): New rule.
8400 2015-03-09 Pedro Alves <palves@redhat.com>
8402 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
8403 'struct sockaddr' pointer in 'accept' call.
8405 2015-03-09 Pedro Alves <palves@redhat.com>
8408 2015-03-07 Pedro Alves <palves@redhat.com>
8409 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
8410 or <winsock2.h> here. Instead include "gdb_socket.h".
8411 (remote_open): Use union gdb_sockaddr_u.
8412 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
8413 or <winsock2.h> here. Instead include "gdb_socket.h".
8414 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
8415 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
8417 (init_named_socket, gdb_agent_helper_thread): Use union
8420 2015-03-07 Pedro Alves <palves@redhat.com>
8422 * configure.ac (build_warnings): Move
8423 -Wdeclaration-after-statement to the C-specific set.
8424 * configure: Regenerate.
8426 2015-03-07 Pedro Alves <palves@redhat.com>
8428 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
8429 or <winsock2.h> here. Instead include "gdb_socket.h".
8430 (remote_open): Use union gdb_sockaddr_u.
8431 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
8432 or <winsock2.h> here. Instead include "gdb_socket.h".
8433 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
8434 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
8436 (init_named_socket, gdb_agent_helper_thread): Use union
8439 2015-03-07 Pedro Alves <palves@redhat.com>
8441 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
8444 2015-03-06 Yao Qi <yao.qi@linaro.org>
8446 * linux-aarch64-low.c (aarch64_insert_point): Use
8447 show_debug_regs as a boolean.
8448 (aarch64_remove_point): Likewise.
8450 2015-03-05 Pedro Alves <palves@redhat.com>
8452 * lynx-low.c (lynx_target_ops): Install NULL hooks for
8453 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
8454 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
8455 * nto-low.c (nto_target_ops): Likewise.
8456 * spu-low.c (spu_target_ops): Likewise.
8457 * win32-low.c (win32_target_ops): Likewise.
8459 2015-03-04 Pedro Alves <palves@redhat.com>
8461 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
8462 Decide whether a breakpoint triggered based on the SIGTRAP's
8464 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
8465 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
8466 (linux_low_filter_event): Check for breakpoints before checking
8468 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
8470 (linux_stopped_by_sw_breakpoint)
8471 (linux_supports_stopped_by_sw_breakpoint)
8472 (linux_stopped_by_hw_breakpoint)
8473 (linux_supports_stopped_by_hw_breakpoint): New functions.
8474 (linux_target_ops): Install new target methods.
8476 2015-03-04 Pedro Alves <palves@redhat.com>
8478 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
8479 * server.c (swbreak_feature, hwbreak_feature): New globals.
8480 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
8481 (captured_main): Clear swbreak_feature and hwbreak_feature.
8482 * server.h (swbreak_feature, hwbreak_feature): Declare.
8483 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
8484 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
8485 supports_stopped_by_hw_breakpoint>: New fields.
8486 (target_supports_stopped_by_sw_breakpoint)
8487 (target_stopped_by_sw_breakpoint)
8488 (target_supports_stopped_by_hw_breakpoint)
8489 (target_stopped_by_hw_breakpoint): Declare.
8491 2015-03-04 Pedro Alves <palves@redhat.com>
8493 enum lwp_stop_reason -> enum target_stop_reason
8494 * linux-low.c (check_stopped_by_breakpoint): Adjust.
8495 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
8496 (linux_wait_1, stuck_in_jump_pad_callback)
8497 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
8498 (linux_stopped_by_watchpoint):
8499 * linux-low.h (enum lwp_stop_reason): Delete.
8500 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
8501 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
8503 2015-03-04 Yao Qi <yao.qi@linaro.org>
8505 * Makefile.in (SFILES): Add linux-aarch64-low.c.
8507 2015-03-03 Gary Benson <gbenson@redhat.com>
8509 * hostio.c (handle_vFile): Fix prefix lengths.
8511 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
8513 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
8516 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
8518 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
8519 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
8520 (clean): Add "rm -f" for above C files.
8521 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
8522 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
8523 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
8524 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
8525 * linux-s390-low.c (HWCAP_S390_VX): New macro.
8526 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
8527 (init_registers_s390x_vx_linux64)
8528 (init_registers_s390x_tevx_linux64)
8529 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
8530 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
8532 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
8533 (s390_store_vxrs_high): New functions.
8534 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
8536 (s390_arch_setup): Add logic for selecting one of the new target
8537 descriptions. Activate the new vector regsets if applicable.
8538 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
8539 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
8540 and init_registers_s390x_tevx_linux64.
8542 2015-03-01 Pedro Alves <palves@redhat.com>
8544 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
8547 2015-02-27 Pedro Alves <palves@redhat.com>
8549 * linux-x86-low.c (u_debugreg_offset): New function.
8550 (x86_linux_dr_get, x86_linux_dr_set): Use it.
8552 2015-02-27 Pedro Alves <palves@redhat.com>
8554 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
8555 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
8556 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
8557 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
8558 (ps_lsetfpregs, ps_getpid)
8559 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
8560 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
8561 (ps_lsetxregs, ps_plog): Declare.
8563 2015-02-27 Pedro Alves <palves@redhat.com>
8565 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
8566 IP_AGENT_EXPORT_FUNC.
8567 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
8568 IP_AGENT_EXPORT_FUNC.
8569 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
8570 (IP_AGENT_EXPORT): Delete.
8571 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
8572 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
8573 (gdb_trampoline_buffer_error, collecting, gdb_collect)
8574 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
8575 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
8576 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
8577 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
8578 (traceframe_read_count, traceframe_write_count)
8579 (traceframes_created, trace_state_variables, get_raw_reg)
8580 (get_trace_state_variable_value, set_trace_state_variable_value)
8581 (ust_loaded, helper_thread_id, cmd_buf): Use
8582 IPA_SYM_EXPORTED_NAME.
8583 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
8584 (tracepoints) Use IP_AGENT_EXPORT_VAR.
8585 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
8586 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
8587 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
8588 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
8589 EXTERN_C_PUSH/EXTERN_C_POP.
8590 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
8591 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
8592 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
8593 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
8594 (traceframe_write_count, traceframe_read_count)
8595 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
8596 (about_to_request_buffer_space, get_trace_state_variable_value)
8597 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
8598 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
8599 EXTERN_C_PUSH/EXTERN_C_POP.
8600 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
8601 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
8602 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
8603 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
8604 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
8605 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
8606 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
8607 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
8609 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
8610 (IP_AGENT_EXPORT_VAR_DECL): Define.
8612 (gdb_agent_get_raw_reg): Declare.
8614 2015-02-27 Tom Tromey <tromey@redhat.com>
8615 Pedro Alves <palves@redhat.com>
8617 Rename symbols whose names are reserved C++ keywords throughout.
8619 2015-02-27 Pedro Alves <palves@redhat.com>
8621 * Makefile.in (COMPILER): New, get it from autoconf.
8622 (CXX): Get from autoconf instead.
8623 (COMPILE.pre): Use COMPILER.
8624 (CC-LD): Rename to ...
8625 (CC_LD): ... this. Use COMPILER.
8626 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
8627 (CXX_FOR_TARGET): Default to g++ instead of gcc.
8628 * acinclude.m4: Include build-with-cxx.m4.
8629 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
8630 Disable -Werror by default if building in C++ mode.
8631 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
8632 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
8633 the C++ compiler. Save/restore CXXFLAGS too.
8634 * configure: Regenerate.
8636 2015-02-27 Pedro Alves <palves@redhat.com>
8638 * acinclude.m4: Include libiberty.m4.
8639 * configure.ac: Call libiberty_INIT.
8640 * config.in, configure: Regenerate.
8642 2015-02-26 Pedro Alves <palves@redhat.com>
8644 * linux-low.c (linux_wait_1): When incrementing the PC past a
8645 program breakpoint always use the_low_target.breakpoint_len as
8646 increment, rather than the maximum between that and
8647 the_low_target.decr_pc_after_break.
8649 2015-02-23 Pedro Alves <palves@redhat.com>
8651 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
8652 thread was doing a step-over; always adjust the PC if
8653 we stepped over a permanent breakpoint.
8654 (linux_wait_1): If we stepped over breakpoint that was on top of a
8655 permanent breakpoint, manually advance the PC past it.
8657 2015-02-23 Pedro Alves <palves@redhat.com>
8659 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
8661 (x86_fill_gregset, x86_store_gregset): Use it when handling
8664 2015-02-20 Pedro Alves <palves@redhat.com>
8666 * thread-db.c: Include "nat/linux-procfs.h".
8667 (thread_db_init): Skip listing new threads if the kernel supports
8668 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
8670 2015-02-20 Pedro Alves <palves@redhat.com>
8672 * linux-low.c (status_pending_p_callback): Use ptid_match.
8674 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
8676 PR breakpoints/16812
8677 * linux-low.c (wstatus_maybe_breakpoint): Remove.
8678 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
8679 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
8681 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
8683 PR breakpoints/15956
8684 * tracepoint.c (cmd_qtinit): Add check for current_thread.
8686 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
8688 * linux-low.c (linux_low_btrace_conf): Print size.
8689 * server.c (handle_btrace_conf_general_set): New.
8690 (hanle_general_set): Call handle_btrace_conf_general_set.
8691 (handle_query): Report Qbtrace-conf:bts:size as supported.
8693 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
8695 * linux-low.c (linux_low_enable_btrace): Update parameters.
8696 (linux_low_btrace_conf): New.
8697 (linux_target_ops)<to_btrace_conf>: Initialize.
8698 * server.c (current_btrace_conf): New.
8699 (handle_btrace_enable): Rename to ...
8700 (handle_btrace_enable_bts): ... this. Pass ¤t_btrace_conf
8701 to target_enable_btrace. Update comment. Update users.
8702 (handle_qxfer_btrace_conf): New.
8703 (qxfer_packets): Add btrace-conf entry.
8704 (handle_query): Report qXfer:btrace-conf:read as supported packet.
8705 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
8706 (target_ops)<read_btrace_conf>: New.
8707 (target_enable_btrace): Update parameters.
8708 (target_read_btrace_conf): New.
8710 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
8712 * server.c (handle_btrace_general_set): Remove call to
8713 target_supports_btrace.
8714 (supported_btrace_packets): New.
8715 (handle_query): Call supported_btrace_packets.
8716 * target.h: include btrace-common.h.
8717 (btrace_target_info): Removed.
8718 (supports_btrace, target_supports_btrace): Update parameters.
8720 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
8722 * Makefile.in (SFILES): Add common/btrace-common.c.
8723 (OBS): Add common/btrace-common.o.
8724 (btrace-common.o): Add build rules.
8725 * linux-low: Include btrace-common.h.
8726 (linux_low_read_btrace): Use struct btrace_data. Call
8727 btrace_data_init and btrace_data_fini.
8729 2015-02-06 Pedro Alves <palves@redhat.com>
8731 * thread-db.c (find_new_threads_callback): Add debug output.
8733 2015-02-04 Pedro Alves <palves@redhat.com>
8735 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
8736 (resume_stopped_resumed_lwps): New function.
8737 (linux_wait_for_event_filtered): Use it.
8739 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
8741 * Makefile.in (SFILES): Add linux-personality.c.
8742 (linux-personality.o): New rule.
8743 * configure.srv (srv_linux_obj): Add linux-personality.o to the
8744 list of objects to be built.
8745 * linux-low.c: Include nat/linux-personality.h.
8746 (linux_create_inferior): Remove code to disable address space
8747 randomization (moved to ../nat/linux-personality.c). Create
8748 cleanup to disable address space randomization.
8750 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
8752 * Makefile.in (posix-strerror.o): New rule.
8753 (mingw-strerror.o): Likewise.
8754 * configure: Regenerated.
8755 * configure.ac: Source file ../common/common.host. Initialize new
8756 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
8758 2015-01-14 Yao Qi <yao@codesourcery.com>
8760 * Makefile.in (SFILES): Add nat/ppc-linux.c.
8761 (ppc-linux.o): New rule.
8762 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
8763 * configure.ac: AC_CHECK_FUNCS(getauxval).
8764 * config.in: Re-generated.
8765 * configure: Re-generated.
8766 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
8767 ppc64_64bit_inferior_p
8769 2015-01-14 Yao Qi <yao@codesourcery.com>
8771 * linux-ppc-low.c: Include "nat/ppc-linux.h".
8772 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
8773 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
8774 (PT_ORIG_R3, PT_TRAP): Likewise.
8775 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
8776 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
8777 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
8779 2015-01-10 Joel Brobecker <brobecker@adacore.com>
8781 * i387-fp.c (i387_cache_to_xsave): In look over
8782 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
8783 zmmh_low_space field by use of zmmh_high_space.
8785 2015-01-09 Pedro Alves <palves@redhat.com>
8787 * linux-low.c (step_over_bkpt): Move higher up in the file.
8788 (handle_extended_wait): Don't store the stop_pc here.
8789 (get_stop_pc): Adjust comments and rename to ...
8790 (check_stopped_by_breakpoint): ... this. Record whether the LWP
8791 stopped for a software breakpoint or hardware breakpoint.
8792 (thread_still_has_status_pending_p): New function.
8793 (status_pending_p_callback): Use
8794 thread_still_has_status_pending_p. If the event is no longer
8795 interesting, resume the LWP.
8796 (handle_tracepoints): Add assert.
8797 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
8798 (wstatus_maybe_breakpoint): New function.
8799 (cancel_breakpoint): Delete function.
8800 (check_stopped_by_watchpoint): New function, factored out from
8801 linux_low_filter_event.
8802 (lp_status_maybe_breakpoint): Delete function.
8803 (linux_low_filter_event): Remove filter_ptid argument.
8804 Leave thread group exits pending here. Store the LWP's stop PC.
8805 Always leave events pending.
8806 (linux_wait_for_event_filtered): Pull all events out of the
8807 kernel, and leave them all pending.
8808 (count_events_callback, select_event_lwp_callback): Consider all
8810 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
8811 (select_event_lwp): Only give preference to the stepping LWP in
8812 all-stop mode. Adjust comments.
8813 (ignore_event): New function.
8814 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
8815 references to cancel_breakpoints. Adjust to renames. Also give
8816 equal priority to all LWPs that have had events in non-stop mode.
8817 If reporting a software breakpoint event, unadjust the LWP's PC.
8818 (linux_wait): If linux_wait_1 returned an ignored event, retry.
8819 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
8821 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
8822 (resume_status_pending_p): Use thread_still_has_status_pending_p.
8823 (linux_stopped_by_watchpoint): Adjust.
8824 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
8825 * linux-low.h (enum lwp_stop_reason): New.
8826 (struct lwp_info) <stop_pc>: Adjust comment.
8827 <stopped_by_watchpoint>: Delete field.
8828 <stop_reason>: New field.
8829 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
8830 * mem-break.c (software_breakpoint_inserted_here)
8831 (hardware_breakpoint_inserted_here): New function.
8832 * mem-break.h (software_breakpoint_inserted_here)
8833 (hardware_breakpoint_inserted_here): Declare.
8834 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
8835 (cancel_breakpoints): Delete.
8836 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
8837 (upload_fast_traceframes): Remove references to
8840 2015-01-09 Pedro Alves <palves@redhat.com>
8842 * thread-db.c (find_new_threads_callback): Ignore thread if the
8843 kernel thread ID is -1.
8845 2015-01-09 Pedro Alves <palves@redhat.com>
8847 * linux-low.c (linux_attach_fail_reason_string): Move to
8848 nat/linux-ptrace.c, and rename.
8849 (linux_attach_lwp): Update comment.
8850 (attach_proc_task_lwp_callback): New function.
8851 (linux_attach): Adjust to rename and use
8852 linux_proc_attach_tgid_threads.
8853 (linux_attach_fail_reason_string): Delete declaration.
8855 2015-01-01 Joel Brobecker <brobecker@adacore.com>
8857 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
8858 * server.c (gdbserver_version): Likewise.
8860 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
8862 * remote-utils.c: Include ctype.h.
8863 (input_interrupt): Explicitly handle the case when the char
8864 received is the NUL byte. Improve the printing of non-ASCII
8867 2014-12-16 Joel Brobecker <brobecker@adacore.com>
8869 * linux-low.c (linux_low_filter_event): Update call to
8870 linux_enable_event_reporting following the addition of
8871 a new parameter to that function.
8873 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
8876 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
8877 (AARCH64_FPCR_REGNO): Likewise.
8878 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
8879 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
8880 (aarch64_store_fpregset): Likewise.
8882 2014-12-15 Joel Brobecker <brobecker@adacore.com>
8884 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
8885 Remove FIXME comment about assumption about N.
8887 2014-12-13 Joel Brobecker <brobecker@adacore.com>
8889 * configure.ac: If large-file support is disabled in GDBserver,
8890 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
8891 * configure: Regenerate.
8893 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
8895 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
8896 warning upon ENODATA from ptrace.
8897 * linux-s390-low.c (s390_store_tdb): New.
8898 (s390_regsets): Add regset for NT_S390_TDB.
8900 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
8902 * linux-low.c (regsets_store_inferior_registers): Skip regsets
8903 without a fill_function.
8904 * linux-s390-low.c (s390_fill_last_break): Remove.
8905 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
8906 (s390_arch_setup): Use regset's size instead of fill_function for
8909 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
8911 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
8912 the regset's store function when ptrace returned an error.
8913 * regcache.c (get_thread_regcache): Invalidate register cache
8914 before fetching inferior's registers.
8916 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
8918 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
8919 while-loop as for-loop.
8920 (regsets_store_inferior_registers): Likewise.
8922 2014-11-28 Yao Qi <yao@codesourcery.com>
8924 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
8925 * config.in, configure: Re-generate.
8926 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
8929 2014-11-21 Yao Qi <yao@codesourcery.com>
8931 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
8932 (AC_CHECK_HEADERS): Remove malloc.h.
8933 * configure: Re-generated.
8934 * config.in: Re-generated.
8935 * server.h: Don't include alloca.h and malloc.h.
8936 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
8937 Don't include malloc.h.
8939 2014-11-17 Joel Brobecker <brobecker@adacore.com>
8941 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
8942 corresponding ERRNO check in same block.
8944 2014-11-12 Pedro Alves <palves@redhat.com>
8946 * server.c (cont_thread): Update comment.
8947 (start_inferior, attach_inferior): No longer clear cont_thread.
8948 (handle_v_cont): No longer set cont_thread.
8949 (captured_main): Clear cont_thread each time a GDB connects.
8951 2014-11-12 Pedro Alves <palves@redhat.com>
8953 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
8954 thread, and don't resume all threads if the Hc thread has exited.
8956 2014-11-12 Pedro Alves <palves@redhat.com>
8958 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
8959 the process group instead of to a specific LWP.
8961 2014-10-15 Pedro Alves <palves@redhat.com>
8964 * win32-arm-low.c (arm_set_thread_context): Remove current_event
8966 (arm_set_thread_context): Delete.
8967 (the_low_target): Adjust.
8968 * win32-i386-low.c (debug_registers_changed)
8969 (debug_registers_used): Delete.
8970 (update_debug_registers_callback): New function.
8971 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
8972 needing to update their debug registers.
8973 (win32_get_current_dr): New function.
8974 (x86_dr_low_get_addr, x86_dr_low_get_control)
8975 (x86_dr_low_get_status): Fetch the debug register from the thread
8977 (i386_initial_stuff): Adjust.
8978 (i386_get_thread_context): Remove current_event parameter. Don't
8979 clear debug_registers_changed nor copy DR values to
8981 (i386_set_thread_context): Delete.
8982 (i386_prepare_to_resume): New function.
8983 (i386_thread_added): Mark the thread as needing to update irs
8985 (the_low_target): Remove i386_set_thread_context and install
8986 i386_prepare_to_resume.
8987 * win32-low.c (win32_get_thread_context): Adjust.
8988 (win32_set_thread_context): Use SetThreadContext
8990 (win32_prepare_to_resume): New function.
8991 (win32_require_context): New function, factored out from ...
8992 (thread_rec): ... this.
8993 (continue_one_thread): Call win32_prepare_to_resume on each thread
8994 we're about to continue.
8995 (win32_resume): Call win32_prepare_to_resume on the event thread.
8996 * win32-low.h (struct win32_thread_info)
8997 <debug_registers_changed>: New field.
8998 (struct win32_target_ops): Change prototype of set_thread_context,
8999 delete set_thread_context and add prepare_to_resume.
9000 (win32_require_context): New declaration.
9002 2014-10-08 Gary Benson <gbenson@redhat.com>
9004 * server.h: Do not include common-exceptions.h.
9006 2014-10-08 Gary Benson <gbenson@redhat.com>
9008 * server.h: Do not include cleanups.h.
9010 2014-09-30 James Hogan <james.hogan@imgtec.com>
9012 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
9015 2014-09-23 Yao Qi <yao@codesourcery.com>
9017 * linux-low.c (lp_status_maybe_breakpoint): New function.
9018 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
9019 (count_events_callback): Likewise.
9020 (select_event_lwp_callback): Likewise.
9021 (cancel_breakpoints_callback): Likewise.
9023 2014-09-19 Don Breazeal <donb@codesourcery.com>
9025 * linux-low.c (handle_extended_wait): Call
9026 linux_ptrace_get_extended_event.
9027 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
9028 linux_is_extended_waitstatus.
9030 2014-09-16 Joel Brobecker <brobecker@adacore.com>
9032 * Makefile.in (CPPFLAGS): Define.
9033 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
9034 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
9036 2014-09-16 Gary Benson <gbenson@redhat.com>
9038 * inferiors.h (current_inferior): Renamed as...
9039 (current_thread): New variable. All uses updated.
9040 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
9041 (maybe_move_out_of_jump_pad): Likewise.
9042 (cancel_breakpoint): Likewise.
9043 (linux_low_filter_event): Likewise.
9044 (wait_for_sigstop): Likewise.
9045 (linux_resume_one_lwp): Likewise.
9046 (need_step_over_p): Likewise.
9047 (start_step_over): Likewise.
9048 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
9049 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
9050 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
9051 and save_inferior as saved_thread.
9052 * regcache.c (get_thread_regcache): Renamed saved_inferior as
9054 (regcache_invalidate_thread): Likewise.
9055 * remote-utils.c (prepare_resume_reply): Likewise.
9056 * thread-db.c (thread_db_get_tls_address): Likewise.
9057 (disable_thread_event_reporting): Likewise.
9058 (remove_thread_event_breakpoints): Likewise.
9059 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
9061 * target.h (set_desired_inferior): Renamed as...
9062 (set_desired_thread): New declaration. All uses updated.
9063 * server.c (myresume): Updated comment to reference thread instead
9065 (handle_serial_event): Likewise.
9066 (handle_target_event): Likewise.
9068 2014-09-12 Tom Tromey <tromey@redhat.com>
9069 Gary Benson <gbenson@redhat.com>
9071 * regcache.h: Include common-regcache.h.
9072 (regcache_read_pc): Don't declare.
9073 * regcache.c (get_thread_regcache_for_ptid): New function.
9075 2014-09-11 Tom Tromey <tromey@redhat.com>
9076 Gary Benson <gbenson@redhat.com>
9078 * symbol.c: New file.
9079 * Makefile.in (SFILES): Add symbol.c.
9080 (OBS): Add symbol.o.
9082 2014-09-11 Gary Benson <gbenson@redhat.com>
9084 * target.c (target_stop_ptid, target_continue_ptid): New
9087 2014-09-11 Tom Tromey <tromey@redhat.com>
9088 Gary Benson <gbenson@redhat.com>
9090 * target.h: Include target/target.h.
9091 * target.c (target_read_memory, target_read_uint32)
9092 (target_write_memory): New functions.
9094 2014-09-11 Gary Benson <gbenson@redhat.com>
9096 * server.h (debug_hw_points): Don't declare.
9097 * server.c (debug_hw_points): Don't define. Replace all uses
9098 with show_debug_regs.
9099 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
9100 all uses with show_debug_regs.
9102 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
9104 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
9105 endianness into account.
9106 (ppc_supply_ptrace_register): Likewise.
9108 2014-09-03 James Hogan <james.hogan@imgtec.com>
9110 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
9111 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
9113 2014-09-03 Gary Benson <gbenson@redhat.com>
9115 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
9116 ALL_DEBUG_ADDRESS_REGISTERS.
9118 2014-09-02 Gary Benson <gbenson@redhat.com>
9120 * i386-low.h: Renamed as...
9121 * x86-low.h: New file. All type, function and variable name
9122 prefixes changed from "i386_" to "x86_". All references updated.
9123 * i386-low.c: Renamed as...
9124 * x86-low.c: New file. All type, function and variable name
9125 prefixes changed from "i386_" to "x86_". All references updated.
9127 2014-09-02 Gary Benson <gbenson@redhat.com>
9129 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
9130 (x86_linux_new_thread): Likewise.
9132 2014-08-29 Gary Benson <gbenson@redhat.com>
9134 * server.h (setjmp.h): Do not include.
9135 (toplevel): Do not declare.
9136 (common-exceptions.h): Include.
9137 (cleanups.h): Likewise.
9138 * server.c (toplevel): Do not define.
9139 (exit_code): New static global.
9140 (detach_or_kill_for_exit_cleanup): New function.
9141 (main): New function. Original main renamed to...
9142 (captured_main): New function.
9143 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
9145 2014-08-29 Gary Benson <gbenson@redhat.com>
9147 * Makefile.in (SFILES): Add common/common-exceptions.c.
9148 (OBS): Add common-exceptions.o.
9149 (common-exceptions.o): New rule.
9150 * utils.c (prepare_to_throw_exception): New function.
9152 2014-08-29 Gary Benson <gbenson@redhat.com>
9154 * config.in: Regenerate.
9155 * configure: Likewise.
9157 2014-08-29 Gary Benson <gbenson@redhat.com>
9159 * Makefile.in (SFILES): Add common/cleanups.c.
9161 (cleanups.o): New rule.
9163 2014-08-29 Gary Benson <gbenson@redhat.com>
9165 * utils.c (internal_vwarning): New function.
9167 2014-08-28 Gary Benson <gbenson@redhat.com>
9169 * utils.h (fatal): Remove declaration.
9170 * utils.c (fatal): Remove function.
9172 2014-08-28 Gary Benson <gbenson@redhat.com>
9174 * tracepoint.c (gdb_agent_init): Replace fatal with
9176 (initialize_tracepoint): Likewise.
9178 2014-08-28 Gary Benson <gbenson@redhat.com>
9180 * remote-utils.c (remote_prepare): Replace fatal with error.
9182 2014-08-28 Gary Benson <gbenson@redhat.com>
9184 * linux-low.c (linux_async): Replace fatal with warning.
9186 (linux_start_non_stop): Return -1 if linux_async failed.
9188 2014-08-28 Gary Benson <gbenson@redhat.com>
9190 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
9192 (i386_dr_low_get_addr): Remove vague comment.
9193 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
9196 2014-08-28 Gary Benson <gbenson@redhat.com>
9198 * inferiors.c (get_thread_process): Replace check with gdb_assert.
9199 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
9201 (linux_resume_one_lwp): Likewise.
9202 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
9204 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
9205 with internal_error.
9206 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
9207 (init_register_cache): Replace fatal with gdb_assert_not_reached.
9208 (find_register_by_name): Replace fatal with internal_error.
9209 (find_regno): Likewise.
9210 * tdesc.c (init_target_desc): Replace check with gdb_assert.
9211 * thread-db.c (thread_db_create_event): Likewise.
9212 (thread_db_load_search): Likewise.
9213 (try_thread_db_load_1): Likewise.
9214 * tracepoint.c (get_jump_space_head): Replace fatal with
9216 (claim_trampoline_space): Likewise.
9217 (have_fast_tracepoint_trampoline_buffer): Likewise.
9218 (cmd_qtstart): Likewise.
9219 (stop_tracing): Likewise.
9220 (fast_tracepoint_collecting): Likewise.
9221 (target_malloc): Likewise.
9222 (download_tracepoint): Likewise.
9223 (download_trace_state_variables): Replace check with gdb_assert.
9224 (upload_fast_traceframes): Replace fatal with internal_error.
9226 2014-08-19 Tom Tromey <tromey@redhat.com>
9227 Gary Benson <gbenson@redhat.com>
9229 * Makefile.in (SFILES): Add common/common-debug.c.
9230 (OBS): Add common-debug.o.
9231 (common-debug.o): New rule.
9232 * debug.h (debug_printf): Don't declare.
9233 * debug.c (debug_printf): Renamed and rewritten as...
9234 (debug_vprintf): New function.
9236 2014-08-19 Gary Benson <gbenson@redhat.com>
9238 * utils.h: Do not include print-utils.h.
9240 2014-08-19 Tom Tromey <tromey@redhat.com>
9241 Gary Benson <gbenson@redhat.com>
9243 * server.h: Add static assertion.
9244 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
9246 2014-08-19 Tom Tromey <tromey@redhat.com>
9247 Gary Benson <gbenson@redhat.com>
9249 * Makefile.in (SFILES): Add common/errors.c.
9250 (OBS): Add errors.o.
9251 (IPA_OBS): Add errors-ipa.o.
9252 (errors.o): New rule.
9253 (errors-ipa.o): Likewise.
9254 * utils.h (perror_with_name, error, warning): Don't declare.
9255 * utils.c (warning): Renamed and rewritten as...
9256 (vwarning): New function.
9257 (error): Renamed and rewritten as...
9258 (verror): New function.
9259 (internal_error): Renamed and rewritten as...
9260 (internal_verror): New function.
9262 2014-08-07 Gary Benson <gbenson@redhat.com>
9264 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
9265 * configure: Regenerate.
9266 * config.in: Likewise.
9267 * server.h: Do not include errno.h.
9268 * event-loop.c: Likewise.
9269 * hostio-errno.c: Likewise.
9270 * linux-low.c: Likewise.
9271 * remote-utils.c: Likewise.
9272 * spu-low.c: Likewise.
9273 * utils.c: Likewise.
9274 * gdbreplay.c: Unconditionally include errno.h.
9276 2014-08-07 Gary Benson <gbenson@redhat.com>
9278 * server.h: Do not include string.h.
9279 * event-loop.c: Likewise.
9280 * linux-low.c: Likewise.
9281 * regcache.c: Likewise.
9282 * remote-utils.c: Likewise.
9283 * spu-low.c: Likewise.
9284 * utils.c: Likewise.
9286 2014-08-07 Gary Benson <gbenson@redhat.com>
9288 * server.h: Do not include gdb_assert.h.
9290 2014-08-07 Gary Benson <gbenson@redhat.com>
9292 * server.h: Do not include common-utils.h.
9294 2014-08-07 Gary Benson <gbenson@redhat.com>
9296 * server.h: Do not include ptid.h.
9297 * notif.h: Likewise.
9299 2014-08-07 Gary Benson <gbenson@redhat.com>
9301 * server.h: Do not include gdb_locale.h.
9303 2014-08-07 Gary Benson <gbenson@redhat.com>
9305 * server.h: Do not include gdb/signals.h.
9306 * win32-low.c: Likewise.
9308 2014-08-07 Gary Benson <gbenson@redhat.com>
9310 * server.h: Do not include pathmax.h.
9312 2014-08-07 Gary Benson <gbenson@redhat.com>
9314 * server.h: Do not include libiberty.h.
9315 * linux-bfin-low.c: Likewise.
9317 2014-08-07 Gary Benson <gbenson@redhat.com>
9319 * server.h: Do not include ansidecl.h.
9321 2014-08-07 Gary Benson <gbenson@redhat.com>
9323 * linux-x86-low.c: Do not include stddef.h.
9324 * lynx-ppc-low.c: Likewise.
9325 * tracepoint.c: Likewise.
9327 2014-08-07 Gary Benson <gbenson@redhat.com>
9329 * server.h: Do not include stdarg.h.
9330 * nto-low.c: Likewise.
9332 2014-08-07 Gary Benson <gbenson@redhat.com>
9334 * server.h: Do not include stdlib.h.
9335 * inferiors.c: Likewise.
9336 * linux-low.c: Likewise.
9337 * regcache.c: Likewise.
9338 * spu-low.c: Likewise.
9339 * tracepoint.c: Likewise.
9340 * utils.c: Likewise.
9342 2014-08-07 Gary Benson <gbenson@redhat.com>
9344 * server.h: Do not include stdio.h.
9345 * linux-low.c: Likewise.
9346 * remote-utils.c: Likewise.
9347 * spu-low.c: Likewise.
9348 * utils.c: Likewise.
9349 * wincecompat.c: Likewise.
9351 2014-08-06 Gary Benson <gbenson@redhat.com>
9353 * regcache.c (init_register_cache): Move conditionals inside if.
9355 2014-08-06 Gary Benson <gbenson@redhat.com>
9357 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
9359 2014-07-31 Gary Benson <gbenson@redhat.com>
9361 * ax.h: Do not include server.h.
9362 * gdbthread.h: Likewise.
9363 * lynx-low.h: Likewise.
9364 * notif.h: Likewise.
9366 2014-07-30 Gary Benson <gbenson@redhat.com>
9368 * server.h: Include common-defs.h.
9369 Do not include config.h or build-gnulib-gdbserver/config.h.
9371 2014-07-30 Gary Benson <gbenson@redhat.com>
9373 * hostio-errno.c: Move server.h to top of includes list.
9374 * inferiors.c: Likewise.
9375 * linux-x86-low.c: Likewise.
9376 * notif.c: Include server.h.
9378 2014-07-24 Tom Tromey <tromey@redhat.com>
9379 Gary Benson <gbenson@redhat.com>
9381 * server.h (CORE_ADDR): Now unsigned.
9383 2014-07-16 Pedro Alves <palves@redhat.com>
9385 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
9387 2014-07-15 Pedro Alves <palves@redhat.com>
9389 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
9392 2014-07-11 Pedro Alves <palves@redhat.com>
9394 * linux-low.c (kill_wait_lwp): New function, based on
9395 kill_one_lwp_callback, but use my_waitpid directly.
9396 (kill_one_lwp_callback, linux_kill): Use it.
9398 2014-06-23 Pedro Alves <palves@redhat.com>
9400 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
9401 before setting DR0..DR3.
9403 2014-06-20 Gary Benson <gbenson@redhat.com>
9405 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
9406 * configure: Regenerated.
9407 * config.in: Likewise.
9409 2014-06-20 Gary Benson <gbenson@redhat.com>
9411 * Makefile.in (SFILES): Update locations for files moved
9413 (object file files): Reordered.
9415 2014-06-20 Gary Benson <gbenson@redhat.com>
9417 * i386-low.h (i386_dr_low_can_set_addr): Removed.
9418 (i386_dr_low_set_addr): Likewise.
9419 (i386_dr_low_get_addr): Likewise.
9420 (i386_dr_low_can_set_control): Likewise.
9421 (i386_dr_low_set_control): Likewise.
9422 (i386_dr_low_get_control): Likewise.
9423 (i386_dr_low_get_status): Likewise.
9424 (i386_get_debug_register_length): Likewise.
9425 * linux-x86-low.c (i386_dr_low_set_addr):
9426 Changed signature. Made static.
9427 (i386_dr_low_get_addr): Likewise.
9428 (i386_dr_low_set_control): Likewise.
9429 (i386_dr_low_get_control): Likewise.
9430 (i386_dr_low_get_status): Likewise.
9431 (i386_dr_low): New global variable.
9432 * win32-i386-low.c (i386_dr_low_set_addr):
9433 Changed signature. Made static.
9434 (i386_dr_low_get_addr): Likewise.
9435 (i386_dr_low_set_control): Likewise.
9436 (i386_dr_low_get_control): Likewise.
9437 (i386_dr_low_get_status): Likewise.
9438 (i386_dr_low): New global variable.
9440 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
9442 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
9443 * Makefile.in (AR, AR_FLAGS): Define.
9444 * configure: Regenerate.
9446 2014-06-19 Gary Benson <gbenson@redhat.com>
9448 * Makefile.in (i386-dregs.o): New rule.
9449 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
9450 * i386-low.c (target.h): Remove include.
9451 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
9452 (DR_CONTROL_SHIFT): Likewise.
9453 (DR_CONTROL_SIZE): Likewise.
9454 (DR_RW_EXECUTE): Likewise.
9455 (DR_RW_WRITE): Likewise.
9456 (DR_RW_READ): Likewise.
9457 (DR_RW_IORW): Likewise.
9458 (DR_LEN_1): Likewise.
9459 (DR_LEN_2): Likewise.
9460 (DR_LEN_4): Likewise.
9461 (DR_LEN_8): Likewise.
9462 (DR_LOCAL_ENABLE_SHIFT): Likewise.
9463 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
9464 (DR_ENABLE_SIZE): Likewise.
9465 (DR_LOCAL_SLOWDOWN): Likewise.
9466 (DR_GLOBAL_SLOWDOWN): Likewise.
9467 (DR_CONTROL_RESERVED): Likewise.
9468 (I386_DR_CONTROL_MASK): Likewise.
9469 (I386_DR_VACANT): Likewise.
9470 (I386_DR_LOCAL_ENABLE): Likewise.
9471 (I386_DR_GLOBAL_ENABLE): Likewise.
9472 (I386_DR_DISABLE): Likewise.
9473 (I386_DR_SET_RW_LEN): Likewise.
9474 (I386_DR_GET_RW_LEN): Likewise.
9475 (I386_DR_WATCH_HIT): Likewise.
9476 (i386_wp_op_t): Likewise.
9477 (i386_show_dr): Likewise.
9478 (i386_length_and_rw_bits): Likewise.
9479 (i386_insert_aligned_watchpoint): Likewise.
9480 (i386_remove_aligned_watchpoint): Likewise.
9481 (i386_handle_nonaligned_watchpoint): Likewise.
9482 i386_update_inferior_debug_regs(): Likewise.
9483 (i386_dr_insert_watchpoint): Likewise.
9484 (i386_dr_remove_watchpoint): Likewise.
9485 (i386_dr_region_ok_for_watchpoint): Likewise.
9486 (i386_dr_stopped_data_address): Likewise.
9487 (i386_dr_stopped_by_watchpoint): Likewise.
9489 2014-06-19 Gary Benson <gbenson@redhat.com>
9491 * i386-low.c (i386_dr_show): Renamed to
9492 i386_show_dr and made static. All uses updated.
9493 (i386_dr_length_and_rw_bits): Renamed to
9494 i386_length_and_rw_bits and made static.
9496 (i386_dr_insert_aligned_watchpoint): Renamed to
9497 i386_insert_aligned_watchpoint and made static.
9499 (i386_dr_remove_aligned_watchpoint): Renamed to
9500 i386_remove_aligned_watchpoint and made static.
9502 (i386_dr_update_inferior_debug_regs): Renamed to
9503 i386_update_inferior_debug_regs and made static.
9506 2014-06-18 Gary Benson <gbenson@redhat.com>
9508 * i386-low.h (i386_dr_low_can_set_addr): New macro.
9509 (i386_dr_low_can_set_control): Likewise.
9510 (i386_get_debug_register_length): Likewise.
9511 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
9512 (i386_dr_low_can_set_control): Likewise.
9513 (i386_get_debug_register_length): Likewise.
9515 2014-06-17 Gary Benson <gbenson@redhat.com>
9517 * i386-low.h (i386-dregs.h): New include.
9518 (DR_FIRSTADDR): Now in i386-dregs.h.
9519 (DR_LASTADDR): Likewise.
9520 (DR_NADDR): Likewise.
9521 (DR_STATUS): Likewise.
9522 (DR_CONTROL): Likewise.
9523 (i386_debug_reg_state): Likewise.
9524 (i386_dr_insert_watchpoint): Likewise.
9525 (i386_dr_remove_watchpoint): Likewise.
9526 (i386_dr_region_ok_for_watchpoint): Likewise.
9527 (i386_dr_stopped_data_address): Likewise.
9528 (i386_dr_stopped_by_watchpoint): Likewise.
9529 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
9531 2014-06-18 Gary Benson <gbenson@redhat.com>
9533 * i386-low.h (i386_low_insert_watchpoint): Renamed to
9534 i386_dr_insert_watchpoint.
9535 (i386_low_remove_watchpoint): Renamed to
9536 i386_dr_remove_watchpoint.
9537 (i386_low_region_ok_for_watchpoint): Renamed to
9538 i386_dr_region_ok_for_watchpoint.
9539 (i386_low_stopped_data_address): Renamed to
9540 i386_dr_stopped_data_address.
9541 (i386_low_stopped_by_watchpoint): Renamed to
9542 i386_dr_stopped_by_watchpoint.
9543 * i386-low.c (i386_show_dr): Renamed to
9544 i386_dr_show and made nonstatic. All uses updated.
9545 (i386_length_and_rw_bits): Renamed to
9546 i386_dr_length_and_rw_bits and made nonstatic.
9548 (i386_insert_aligned_watchpoint): Renamed to
9549 i386_dr_insert_aligned_watchpoint and made nonstatic.
9551 (i386_remove_aligned_watchpoint): Renamed to
9552 i386_dr_remove_aligned_watchpoint and made nonstatic.
9554 (i386_update_inferior_debug_regs): Renamed to
9555 i386_dr_update_inferior_debug_regs and made nonstatic.
9557 (i386_low_insert_watchpoint): Renamed to
9558 i386_dr_insert_watchpoint. All uses updated.
9559 (i386_low_remove_watchpoint): Renamed to
9560 i386_dr_remove_watchpoint. All uses updated.
9561 (i386_low_region_ok_for_watchpoint): Renamed to
9562 i386_dr_region_ok_for_watchpoint. All uses updated.
9563 (i386_low_stopped_data_address): Renamed to
9564 i386_dr_stopped_data_address. All uses updated.
9565 (i386_low_stopped_by_watchpoint): Renamed to
9566 i386_dr_stopped_by_watchpoint. All uses updated.
9568 2014-06-18 Gary Benson <gbenson@redhat.com>
9570 * i386-low.c (i386_dr_low_can_set_addr): New macro.
9571 (i386_dr_low_can_set_control): Likewise.
9572 (i386_insert_aligned_watchpoint): New check.
9574 2014-06-18 Gary Benson <gbenson@redhat.com>
9576 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
9579 2014-06-18 Gary Benson <gbenson@redhat.com>
9581 * i386-low.c (i386_length_and_rw_bits): Use internal_error
9582 instead of fatal and error.
9583 (i386_handle_nonaligned_watchpoint): Likewise.
9585 2014-06-18 Gary Benson <gbenson@redhat.com>
9587 * i386-low.c (i386_get_debug_register_length): New macro.
9588 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
9589 (i386_show_dr): Use debug_printf instead of fprintf. Use
9590 phex to format values.
9592 2014-06-18 Gary Benson <gbenson@redhat.com>
9594 * i386-low.h: Comment changes.
9595 * i386-low.c: Likewise.
9597 2014-06-18 Gary Benson <gbenson@redhat.com>
9599 * i386-low.c: Whitespace changes.
9601 2014-06-12 Tom Tromey <tromey@redhat.com>
9603 * utils.c (freeargv): Remove.
9605 2014-06-12 Tom Tromey <tromey@redhat.com>
9607 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
9608 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
9609 (parse_debug_format_options): Likewise.
9610 (gdbserver_usage): Likewise.
9611 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
9612 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
9613 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
9615 ($(LIBGNU)): Depend on libiberty.
9616 (all-lib): Recurse into all subdirs.
9617 (install-only): Invoke "install" target in subdirs.
9618 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
9620 * configure: Rebuild.
9621 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
9622 for vasprintf, vsnprintf, or gettimeofday.
9623 * configure.srv: Don't add safe-ctype.o or lbasename.o to
9626 2014-06-05 Joel Brobecker <brobecker@adacore.com>
9628 * development.sh: Delete.
9629 * Makefile.in (config.status): Adjust dependency on development.sh.
9630 * configure.ac: Adjust development.sh source call.
9631 * configure: Regenerate.
9633 2014-06-02 Pedro Alves <palves@redhat.com>
9635 * ax.c (gdb_free_agent_expr): New function.
9636 * ax.h (gdb_free_agent_expr): New declaration.
9637 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
9639 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
9641 (clear_breakpoint_conditions_and_commands): New function.
9642 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
9643 (clear_breakpoint_conditions_and_commands): New declaration.
9645 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
9647 * linux-aarch64-low.c (asm/ptrace.h): Include.
9649 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
9651 Fix TLS access for -static -pthread.
9652 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
9653 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
9654 (thread_db_load_search, try_thread_db_load_1): Initialize it.
9656 2014-05-20 Pedro Alves <palves@redhat.com>
9658 * linux-aarch64-low.c (aarch64_insert_point)
9659 (aarch64_remove_point): No longer check whether the type is
9660 supported here. Adjust to new interface.
9661 (the_low_target): Install aarch64_supports_z_point_type as
9662 supports_z_point_type method.
9663 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
9664 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
9665 instead of a Z packet char. Adjust.
9666 (arm_supports_z_point_type): New function.
9667 (arm_insert_point, arm_remove_point): Adjust to new interface.
9668 (the_low_target): Install arm_supports_z_point_type.
9669 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
9670 (cris_insert_point, cris_remove_point): Adjust to new interface.
9671 Don't check whether the type is supported here.
9672 (the_low_target): Install cris_supports_z_point_type.
9673 * linux-low.c (linux_supports_z_point_type): New function.
9674 (linux_insert_point, linux_remove_point): Adjust to new interface.
9675 * linux-low.h (struct linux_target_ops) <insert_point,
9676 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
9677 raw_breakpoint pointer parameter.
9678 <supports_z_point_type>: New method.
9679 * linux-mips-low.c (mips_supports_z_point_type): New function.
9680 (mips_insert_point, mips_remove_point): Adjust to new interface.
9681 Use mips_supports_z_point_type.
9682 (the_low_target): Install mips_supports_z_point_type.
9683 * linux-ppc-low.c (the_low_target): Install NULL as
9684 supports_z_point_type method.
9685 * linux-s390-low.c (the_low_target): Install NULL as
9686 supports_z_point_type method.
9687 * linux-sparc-low.c (the_low_target): Install NULL as
9688 supports_z_point_type method.
9689 * linux-x86-low.c (x86_supports_z_point_type): New function.
9690 (x86_insert_point): Adjust to new insert_point interface. Use
9691 insert_memory_breakpoint. Adjust to new
9692 i386_low_insert_watchpoint interface.
9693 (x86_remove_point): Adjust to remove_point interface. Use
9694 remove_memory_breakpoint. Adjust to new
9695 i386_low_remove_watchpoint interface.
9696 (the_low_target): Install x86_supports_z_point_type.
9697 * lynx-low.c (lynx_target_ops): Install NULL as
9698 supports_z_point_type callback.
9699 * nto-low.c (nto_supports_z_point_type): New.
9700 (nto_insert_point, nto_remove_point): Adjust to new interface.
9701 (nto_target_ops): Install nto_supports_z_point_type.
9702 * mem-break.c: Adjust intro comment.
9703 (struct raw_breakpoint) <raw_type, size>: New fields.
9704 <inserted>: Update comment.
9705 <shlib_disabled>: Delete field.
9706 (enum bkpt_type) <gdb_breakpoint>: Delete value.
9707 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
9708 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
9709 (raw_bkpt_type_to_target_hw_bp_type): New function.
9710 (find_enabled_raw_code_breakpoint_at): New function.
9711 (find_raw_breakpoint_at): New type and size parameters. Use them.
9712 (insert_memory_breakpoint): New function, based off
9713 set_raw_breakpoint_at.
9714 (remove_memory_breakpoint): New function.
9715 (set_raw_breakpoint_at): Reimplement.
9716 (set_breakpoint): New, based on set_breakpoint_at.
9717 (set_breakpoint_at): Reimplement.
9718 (delete_raw_breakpoint): Go through the_target->remove_point
9719 instead of assuming memory breakpoints.
9720 (find_gdb_breakpoint_at): Delete.
9721 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
9722 (find_gdb_breakpoint): New function.
9723 (set_gdb_breakpoint_at): Delete.
9724 (z_type_supported): New function.
9725 (set_gdb_breakpoint_1): New function, loosely based off
9726 set_gdb_breakpoint_at.
9727 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
9728 (delete_gdb_breakpoint_at): Delete.
9729 (delete_gdb_breakpoint_1): New function, loosely based off
9730 delete_gdb_breakpoint_at.
9731 (delete_gdb_breakpoint): New function.
9732 (clear_gdb_breakpoint_conditions): Rename to ...
9733 (clear_breakpoint_conditions): ... this. Don't handle a NULL
9735 (add_condition_to_breakpoint): Make static.
9736 (add_breakpoint_condition): Take a struct breakpoint pointer
9737 instead of an address. Adjust.
9738 (gdb_condition_true_at_breakpoint): Rename to ...
9739 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
9741 (gdb_condition_true_at_breakpoint): Reimplement.
9742 (add_breakpoint_commands): Take a struct breakpoint pointer
9743 instead of an address. Adjust.
9744 (gdb_no_commands_at_breakpoint): Rename to ...
9745 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
9746 parameter. Return true if no breakpoint was found. Change debug
9748 (gdb_no_commands_at_breakpoint): Reimplement.
9749 (run_breakpoint_commands): Rename to ...
9750 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
9751 and change return type to boolean.
9752 (run_breakpoint_commands): New function.
9753 (gdb_breakpoint_here): Also check for Z1 breakpoints.
9754 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
9755 breakpoint. Go through the_target->remove_point instead of
9756 assuming memory breakpoint.
9757 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
9758 software and hardware breakpoints.
9759 (reinsert_raw_breakpoint): Go through the_target->insert_point
9760 instead of assuming memory breakpoint.
9761 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
9762 software and hardware breakpoints.
9763 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
9764 Check both software and hardware breakpoints.
9765 (validate_inserted_breakpoint): Assert the breakpoint is a
9766 software breakpoint. Set the inserted flag to -1 instead of
9767 setting shlib_disabled.
9768 (delete_disabled_breakpoints): Adjust.
9769 (validate_breakpoints): Only validate software breakpoints.
9770 Adjust to inserted flag change.
9771 (check_mem_read, check_mem_write): Skip breakpoint types other
9772 than software breakpoints. Adjust to inserted flag change.
9773 * mem-break.h (enum raw_bkpt_type): New enum.
9774 (raw_breakpoint, struct process_info): Forward declare.
9775 (Z_packet_to_target_hw_bp_type): Delete declaration.
9776 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
9777 (set_gdb_breakpoint, delete_gdb_breakpoint)
9778 (clear_breakpoint_conditions): New declarations.
9779 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
9780 (breakpoint_inserted_here): Update comment.
9781 (add_breakpoint_condition, add_breakpoint_commands): Replace
9782 address parameter with a breakpoint pointer parameter.
9783 (gdb_breakpoint_here): Update comment.
9784 (delete_gdb_breakpoint_at): Delete.
9785 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
9786 * server.c (process_point_options): Take a struct breakpoint
9787 pointer instead of an address. Adjust.
9788 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
9789 delete_gdb_breakpoint.
9790 * spu-low.c (spu_target_ops): Install NULL as
9791 supports_z_point_type method.
9792 * target.h: Include mem-break.h.
9793 (struct target_ops) <prepare_to_access_memory>: Update comment.
9794 <supports_z_point_type>: New field.
9795 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
9796 instead of a char. Also take a raw breakpoint pointer.
9797 * win32-arm-low.c (the_low_target): Install NULL as
9798 supports_z_point_type.
9799 * win32-i386-low.c (i386_supports_z_point_type): New function.
9800 (i386_insert_point, i386_remove_point): Adjust to new interface.
9801 (the_low_target): Install i386_supports_z_point_type.
9802 * win32-low.c (win32_supports_z_point_type): New function.
9803 (win32_insert_point, win32_remove_point): Adjust to new interface.
9804 (win32_target_ops): Install win32_supports_z_point_type.
9805 * win32-low.h (struct win32_target_ops):
9806 <supports_z_point_type>: New method.
9807 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
9808 instead of a char. Also take a raw breakpoint pointer.
9810 2014-05-20 Pedro Alves <palves@redhat.com>
9812 * mem-break.h: Include break-common.h.
9813 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
9814 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
9815 (Z_packet_to_target_hw_bp_type): New declaration.
9816 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
9817 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
9818 (Z_PACKET_ACCESS_WP): Delete macros.
9819 (Z_packet_to_hw_type): Delete function.
9820 * i386-low.h: Don't include break-common.h here.
9821 (Z_packet_to_hw_type): Delete declaration.
9822 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
9823 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
9824 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
9825 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
9826 * linux-aarch64-low.c: Don't include break-common.h here.
9827 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
9828 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
9829 (Z_packet_to_target_hw_bp_type): Delete function.
9830 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
9832 (mips_insert_point, mips_remove_point): Use
9833 Z_packet_to_target_hw_bp_type.
9835 2014-05-20 Pedro Alves <palves@redhat.com>
9837 * linux-aarch64-low.c: Include break-common.h.
9838 (enum target_point_type): Delete.
9839 (Z_packet_to_point_type): Rename to ...
9840 (Z_packet_to_target_hw_bp_type): ... this, and return a
9841 target_hw_bp_type instead.
9842 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
9843 instead of an enum target_point_type.
9844 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
9846 (aarch64_dr_state_insert_one_point)
9847 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
9848 (aarch64_handle_aligned_watchpoint)
9849 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
9850 Take an enum target_hw_bp_type instead of an enum
9852 (aarch64_supports_z_point_type): New function.
9853 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
9854 use Z_packet_to_target_hw_bp_type.
9856 2014-05-20 Joel Brobecker <brobecker@adacore.com>
9858 * configure.ac: Only use -Werror by default when DEVELOPMENT
9860 * configure: Regenerate.
9862 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
9864 Fix gdbserver qGetTLSAddr for x86_64 -m32.
9865 * linux-x86-low.c (X86_64_USER_REGS): New.
9866 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
9868 2014-04-28 Yao Qi <yao@codesourcery.com>
9870 * Makefile.in (i386-avx512.c): Fix the typo of generated file
9873 2014-04-25 Pedro Alves <palves@redhat.com>
9876 * linux-low.c (linux_attach_fail_reason_string): New function.
9877 (linux_attach_lwp): Delete.
9878 (linux_attach_lwp_1): Rename to ...
9879 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
9880 argument. Remove "initial" parameter. Return int instead of
9881 void. Don't error or warn here.
9882 (linux_attach): Adjust to call linux_attach_lwp. Call error on
9883 failure to attach to the tgid. Call warning when failing to
9885 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
9886 argument. Remove "initial" parameter. Return int instead of
9887 void. Don't error or warn here.
9888 (linux_attach_fail_reason_string): New declaration.
9889 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
9890 interface change. Use linux_attach_fail_reason_string.
9892 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
9893 Walfred Tedeschi <walfred.tedeschi@intel.com>
9895 * Makefile.in: Added rules to handle new files
9896 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
9897 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
9898 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
9899 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
9900 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
9901 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
9903 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
9904 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
9905 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
9906 i386/x32-avx512.xml.
9907 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
9908 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
9909 i386/x32-avx512-linux.xml.
9910 * i387-fp.c (num_avx512_k_registers): New constant for number
9912 (num_avx512_zmmh_low_registers): New constant for number of
9913 lower ZMM registers (0-15).
9914 (num_avx512_zmmh_high_registers): New constant for number of
9915 higher ZMM registers (16-31).
9916 (num_avx512_ymmh_registers): New contant for number of higher
9917 YMM registers (ymm16-31 added by avx521 on x86_64).
9918 (num_avx512_xmm_registers): New constant for number of higher
9919 XMM registers (xmm16-31 added by AVX512 on x86_64).
9920 (struct i387_xsave): Add space for AVX512 registers.
9921 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
9922 Add code to handle AVX512 registers.
9923 (i387_xsave_to_cache): Add code to handle AVX512 registers.
9924 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
9925 prototypei from generated file.
9926 (tdesc_amd64_avx512_linux): Likewise.
9927 (init_registers_x32_avx512_linux): Likewise.
9928 (tdesc_x32_avx512_linux): Likewise.
9929 (init_registers_i386_avx512_linux): Likewise.
9930 (tdesc_i386_avx512_linux): Likewise.
9931 (x86_64_regmap): Add AVX512 registers.
9932 (x86_linux_read_description): Add code to handle AVX512 XSTATE
9934 (initialize_low_arch): Add code to initialize AVX512 registers.
9936 2014-04-23 Pedro Alves <palves@redhat.com>
9938 * mem-break.c (find_gdb_breakpoint_at): Make static.
9939 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
9941 2014-04-23 Pedro Alves <palves@redhat.com>
9943 * i386-low.c: Don't include break-common.h here.
9944 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
9945 prototype to take target_hw_bp_type as argument instead of a Z
9947 * i386-low.h: Include break-common.h here.
9948 (Z_packet_to_hw_type): Declare.
9949 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
9951 * linux-x86-low.c (x86_insert_point): Convert the packet number to
9952 a target_hw_bp_type before calling i386_low_insert_watchpoint.
9953 (x86_remove_point): Convert the packet number to a
9954 target_hw_bp_type before calling i386_low_remove_watchpoint.
9955 * win32-i386-low.c (i386_insert_point): Convert the packet number
9956 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
9957 (i386_remove_point): Convert the packet number to a
9958 target_hw_bp_type before calling i386_low_remove_watchpoint.
9960 2014-04-23 Pedro Alves <palves@redhat.com>
9962 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
9964 2014-04-10 Pedro Alves <palves@redhat.com>
9966 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
9967 Check if the condition or command is NULL before checking if the
9968 breakpoint is known. On success, return true.
9969 * mem-break.h (add_breakpoint_condition): Document return.
9970 (add_breakpoint_commands): Add describing comment.
9971 * server.c (skip_to_semicolon): New function.
9972 (process_point_options): Use it.
9974 2014-04-09 Pedro Alves <palves@redhat.com>
9976 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
9979 2014-02-27 Pedro Alves <palves@redhat.com>
9982 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
9984 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
9986 (last_thread_of_process_p): Take a PID argument instead of a
9988 (linux_wait_for_lwp): Delete.
9989 (num_lwps, check_zombie_leaders, not_stopped_callback): New
9991 (linux_low_filter_event): New function, party factored out from
9992 linux_wait_for_event.
9993 (linux_wait_for_event): Rename to ...
9994 (linux_wait_for_event_filtered): ... this. Add new filter ptid
9995 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
9996 sigsuspend. Check for zombie leaders.
9997 (linux_wait_for_event): Reimplement as wrapper around
9998 linux_wait_for_event_filtered.
9999 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
10000 a normal or signal exit is seen, it's the whole process exiting.
10001 (wait_for_sigstop): No longer a for_each_inferior callback.
10002 Rewrite on top of linux_wait_for_event_filtered.
10003 (stop_all_lwps): Call wait_for_sigstop directly.
10004 * server.c (resume, handle_target_event): Handle
10005 TARGET_WAITKIND_NO_RESUMED.
10007 2014-02-26 Joel Brobecker <brobecker@adacore.com>
10009 * win32-low.c (psapi_get_dll_name,
10010 * win32_CreateToolhelp32Snapshot): Delete.
10011 (win32_CreateToolhelp32Snapshot, win32_Module32First)
10012 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
10014 (handle_load_dll): Add function description.
10015 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
10017 2014-02-26 Joel Brobecker <brobecker@adacore.com>
10019 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
10021 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
10022 base address when calling win32_add_one_solib.
10023 (handle_load_dll): Delete local variable load_addr.
10024 Remove 0x1000 offset applied to DLL base address when calling
10025 win32_add_one_solib.
10026 (handle_unload_dll): Add comment.
10028 2014-02-26 Joel Brobecker <brobecker@adacore.com>
10030 * win32-low.c (win32_add_all_dlls): Renames
10031 win32_ensure_ntdll_loaded. Rewrite function documentation.
10032 Adjust implementation to always load all DLLs.
10033 Add 0x1000 offset to DLL base address when calling
10034 win32_add_one_solib.
10035 (child_initialization_done): New static global.
10036 (do_initial_child_stuff): Set child_initialization_done to
10037 zero during child initialization, and 1 after. Replace call
10038 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
10040 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
10041 (handle_unload_dll): Add function documentation.
10042 (get_child_debug_event): Ignore load and unload DLL events
10043 during child initialization.
10045 2014-02-20 Doug Evans <dje@google.com>
10047 Remove global all_lwps.
10048 * inferiors.h (ptid_of): Move here from linux-low.h.
10049 (pid_of, lwpid_of): Ditto.
10050 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
10051 parameter is a struct thread_info * now.
10052 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
10053 directly. Pass &all_threads to find_inferior instead of &all_lwps.
10054 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
10056 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
10057 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
10058 * linux-arm-low.c (update_registers_callback): Update, "entry"
10059 parameter is a struct thread_info * now.
10060 Fetch lwpid from current_inferior directly.
10061 (arm_insert_point): Pass &all_threads to find_inferior instead of
10063 (arm_remove_point): Ditto.
10064 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
10065 (arm_prepare_to_resume): Fetch pid from thread.
10066 (arm_read_description): Fetch lwpid from current_inferior directly.
10067 * linux-low.c (all_lwps): Delete.
10068 (delete_lwp): Delete call to remove_inferior.
10069 (handle_extended_wait): Fetch lwpid from thread.
10070 (add_lwp): Don't set lwp->entry.id. Remove call to
10071 add_inferior_to_list.
10072 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
10073 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
10074 (kill_one_lwp_callback): Ditto.
10075 (linux_kill): Don't dereference NULL pointer.
10076 Fetch ptid,lwpid from thread.
10077 (get_detach_signal): Fetch ptid from thread.
10078 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
10079 Simplify call to regcache_invalidate_thread.
10080 (delete_lwp_callback): Update, "entry" parameter is a
10081 struct thread_info * now. Fetch pid from thread.
10082 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
10083 (status_pending_p_callback): Update, "entry" parameter is a
10084 struct thread_info * now. Fetch ptid from thread.
10085 (find_lwp_pid): Update, "entry" parameter is a
10086 struct thread_info * now.
10087 (linux_wait_for_lwp): Fetch pid from thread.
10088 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
10089 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
10090 (enqueue_one_deferred_signal): Fetch lwpid from thread.
10091 (dequeue_one_deferred_signal): Ditto.
10092 (cancel_breakpoint): Fetch ptid from current_inferior.
10093 (linux_wait_for_event): Pass &all_threads to find_inferior,
10094 not &all_lwps. Fetch ptid, lwpid from thread.
10095 (count_events_callback): Update, "entry" parameter is a
10096 struct thread_info * now.
10097 (select_singlestep_lwp_callback): Ditto.
10098 (select_event_lwp_callback): Ditto.
10099 (cancel_breakpoints_callback): Ditto.
10100 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
10102 (select_event_lwp): Ditto. Fetch ptid from event_thread.
10103 (unsuspend_one_lwp): Update, "entry" parameter is a
10104 struct thread_info * now.
10105 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
10107 (linux_stabilize_threads): Ditto. And for for_each_inferior.
10108 Fetch lwpid from thread, not lwp.
10109 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
10110 Pass &all_threads to find_inferior, not &all_lwps.
10111 (send_sigstop): Fetch lwpid from thread, not lwp.
10112 (send_sigstop_callback): Update, "entry" parameter is a
10113 struct thread_info * now.
10114 (suspend_and_send_sigstop_callback): Ditto.
10115 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
10116 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
10117 struct thread_info * now.
10118 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
10120 (lwp_running): Update, "entry" parameter is a
10121 struct thread_info * now.
10122 (stop_all_lwps): Fetch ptid from thread.
10123 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
10124 (linux_resume_one_lwp): Fetch lwpid from thread.
10125 (linux_set_resume_request): Update, "entry" parameter is a
10126 struct thread_info * now. Fetch pid, lwpid from thread.
10127 (resume_status_pending_p): Update, "entry" parameter is a
10128 struct thread_info * now.
10129 (need_step_over_p): Ditto. Fetch lwpid from thread.
10130 (start_step_over): Fetch lwpid from thread.
10131 (linux_resume_one_thread): Update, "entry" parameter is a
10132 struct thread_info * now. Fetch lwpid from thread.
10133 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
10134 (proceed_one_lwp): Update, "entry" parameter is a
10135 struct thread_info * now. Fetch lwpid from thread.
10136 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
10137 struct thread_info * now.
10138 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
10139 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
10140 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
10142 (regsets_store_inferior_registers): Ditto.
10143 (fetch_register, store_register): Ditto.
10144 (linux_read_memory, linux_write_memory): Ditto.
10145 (linux_request_interrupt): Ditto.
10146 (linux_read_auxv): Ditto.
10147 (linux_xfer_siginfo): Ditto.
10148 (linux_qxfer_spu): Ditto.
10149 (linux_qxfer_libraries_svr4): Ditto.
10150 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
10151 moved to inferiors.h.
10153 (get_thread_lwp): Update.
10154 (struct lwp_info): Delete member "entry". Simplify comment for
10156 (all_lwps): Delete.
10157 * linux-mips-low.c (mips_read_description): Fetch lwpid from
10158 current_inferior directly.
10159 (update_watch_registers_callback): Update, "entry" parameter is a
10160 struct thread_info * now. Fetch pid from thread.
10161 (mips_linux_prepare_to_resume): Fetch ptid from thread.
10162 (mips_insert_point): Fetch lwpid from current_inferior.
10163 Pass &all_threads to find_inferior, not &all_lwps.
10164 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
10165 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
10167 (mips_stopped_data_address): Ditto.
10168 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
10170 * linux-tile-low.c (tile_arch_setup): Ditto.
10171 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
10172 (update_debug_registers_callback): Update, "entry" parameter is a
10173 struct thread_info * now. Fetch pid from thread.
10174 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
10175 Pass &all_threads to find_inferior, not &all_lwps.
10176 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
10177 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
10178 Pass &all_threads to find_inferior, not &all_lwps.
10179 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
10180 (i386_dr_low_get_status): Ditto.
10181 (x86_linux_prepare_to_resume): Fetch ptid from thread.
10182 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
10183 (x86_linux_read_description): Ditto.
10184 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
10186 2014-02-20 Doug Evans <dje@google.com>
10188 * inferiors.c (get_first_inferior): Fix buglet.
10190 2014-02-19 Doug Evans <dje@google.com>
10192 * gdbthread.h (add_thread): Change result type to struct thread_info *.
10193 * inferiors.c (add_thread): Change result type to struct thread_info *.
10194 All callers updated.
10195 (add_lwp): Call add_thread here instead of in callers.
10196 All callers updated.
10197 * linux-low.h (get_lwp_thread): Rewrite.
10198 (struct lwp_info): New member "thread".
10200 2014-02-19 Doug Evans <dje@google.com>
10202 * linux-low.c (add_lwp): Change result to struct lwp_info *.
10203 All callers updated.
10205 2014-02-19 Doug Evans <dje@google.com>
10207 * inferiors.c (add_thread): Fix whitespace.
10209 2014-02-19 Doug Evans <dje@google.com>
10211 * dll.c (clear_dlls): Replace accessing list implemention details
10213 * gdbthread.h (get_first_thread): Declare.
10214 * inferiors.c (for_each_inferior_with_data): New function.
10215 (get_first_thread): New function.
10216 (find_thread_ptid): Simplify.
10217 (get_first_inferior): New function.
10218 (clear_list): Delete.
10219 (one_inferior_p): New function.
10220 (clear_inferior_list): New function.
10221 (clear_inferiors): Update.
10222 * inferiors.h (for_each_inferior_with_data): Declare.
10223 (clear_inferior_list): Declare.
10224 (one_inferior_p): Declare.
10225 (get_first_inferior): Declare.
10226 * linux-low.c (linux_wait_for_event): Replace accessing list
10227 implemention details with API function.
10228 * server.c (target_running): Ditto.
10229 (accumulate_file_name_length): New function.
10230 (emit_dll_description): New function.
10231 (handle_qxfer_libraries): Replace accessing list implemention
10232 details with API function.
10233 (handle_qxfer_threads_worker): New function.
10234 (handle_qxfer_threads_proper): Replace accessing list implemention
10235 details with API function.
10236 (handle_query): Ditto.
10237 (visit_actioned_threads_callback_ftype): New typedef.
10238 (visit_actioned_threads_data): New struct.
10239 (visit_actioned_threads): Rewrite to be find_inferior callback.
10240 (resume): Call find_inferior.
10241 (handle_status): Replace accessing list implemention
10242 details with API function.
10243 (process_serial_event): Replace accessing list implemention details
10245 * target.c (set_desired_inferior): Replace accessing list implemention
10246 details with API function.
10247 * tracepoint.c (same_process_p): New function.
10248 (gdb_agent_about_to_close): Replace accessing list implemention
10249 details with API function.
10250 * win32-low.c (child_delete_thread): Replace accessing list
10251 implemention details with API function.
10252 (match_dll_by_basename): New function.
10253 (dll_is_loaded_by_basename): New function.
10254 (win32_ensure_ntdll_loaded): Replace accessing list implemention
10255 details call to dll_is_loaded_by_basename.
10257 2014-02-19 Doug Evans <dje@google.com>
10259 * dll.h (struct dll_info): Add comment.
10260 * gdbthread.h (struct thread_info): Add comment.
10261 (current_ptid): Simplify.
10262 * inferiors.c (add_process): Update.
10263 (remove_process): Update.
10264 * inferiors.h (struct process_info): Rename member "head" to "entry".
10265 * linux-low.c (delete_lwp): Update.
10267 (last_thread_of_process_p): Update.
10268 (kill_one_lwp_callback, linux_kill): Update.
10269 (status_pending_p_callback): Update.
10270 (wait_for_sigstop): Update. Simplify read of ptid.
10271 (start_step_over): Update.
10272 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
10273 (get_lwp_thread): Update.
10274 (struct lwp_info): Rename member "head" to "entry".
10275 * regcache.h (inferior_list_entry): Delete.
10276 * server.c (kill_inferior_callback): Update.
10277 (detach_or_kill_inferior_callback): Update.
10278 (print_started_pid): Update.
10279 (print_attached_pid): Update.
10280 (process_serial_event): Simplify read of ptid.
10281 * thread-db.c (thread_db_create_event): Update.
10282 (thread_db_get_tls_address): Update.
10283 * win32-low.c (current_inferior_ptid): Simplify.
10285 2014-02-19 Tom Tromey <tromey@redhat.com>
10287 * target.h (struct target_ops) <supports_btrace>: Add target_ops
10289 (target_supports_btrace): Update.
10291 2014-02-14 Yao Qi <yao@codesourcery.com>
10293 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
10294 (rsp-low-ipa.o): New target.
10296 2014-02-12 Tom Tromey <tromey@redhat.com>
10298 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
10299 convert_ascii_to_int.
10300 * regcache.c (registers_to_string): Likewise.
10301 * remote-utils.c (decode_M_packet): Likewise.
10302 * server.c (process_serial_event): Likewise.
10304 2014-02-12 Tom Tromey <tromey@redhat.com>
10306 * server.c (handle_query, handle_v_run): Use hex2bin, not
10308 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
10310 2014-02-12 Tom Tromey <tromey@redhat.com>
10312 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
10313 convert_int_to_ascii.
10314 * regcache.c (registers_to_string, collect_register_as_string):
10316 * remote-utils.c (look_up_one_symbol, relocate_instruction):
10318 * server.c (process_serial_event): Likewise.
10319 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
10320 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
10322 2014-02-12 Tom Tromey <tromey@redhat.com>
10324 * remote-utils.c (look_up_one_symbol, monitor_output): Use
10325 bin2hex, not hexify.
10326 * tracepoint.c (cmd_qtstatus): Likewise.
10328 2014-02-12 Tom Tromey <tromey@redhat.com>
10330 * remote-utils.c (monitor_output): Pass explicit length to
10333 2014-02-12 Tom Tromey <tromey@redhat.com>
10335 * tracepoint.c: Include rsp-low.h.
10336 * server.c: Include rsp-low.h.
10337 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
10338 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
10340 * remote-utils.c: Include rsp-low.h.
10341 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
10342 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
10343 (convert_int_to_ascii, convert_ascii_to_int): Move to
10345 * regcache.c: Include rsp-low.h.
10346 * ax.c: Include rsp-low.h.
10347 * Makefile.in (SFILES): Add common/rsp-low.c.
10348 (OBS): Add rsp-low.o.
10349 (rsp-low.o): New target.
10351 2014-02-12 Tom Tromey <tromey@redhat.com>
10353 * utils.h (pulongest, plongest, phex_nz): Don't declare.
10354 Include print-utils.h.
10355 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
10356 (plongest, thirty_two, phex_nz): Remove.
10357 * Makefile.in (SFILES): Add common/print-utils.c.
10358 (OBS): Add print-utils.o.
10359 (print-utils-ipa.o): New target.
10360 (print-utils.o): New target.
10361 (IPA_OBJS): Add print-utils-ipa.o.
10363 2014-02-06 Tom Tromey <tromey@redhat.com>
10365 * Makefile.in (SFILES): Fix indentation.
10367 2014-02-05 Doug Evans <dje@google.com>
10369 * linux-low.c (linux_wait_for_event): Improve comment.
10370 (linux_wait_1): Keep current_inferior in sync with event_child.
10372 2014-01-22 Doug Evans <dje@google.com>
10374 * gdbthread.h (gdb_id_to_thread): Delete, unused.
10376 2014-01-22 Doug Evans <dje@google.com>
10378 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
10379 * configure: Regenerate.
10380 * config.in: Regenerate.
10381 * Makefile.in (SFILES): Add debug.c.
10382 (OBS): Add debug.o.
10383 * debug.c: New file.
10384 * debug.h: New file.
10385 * linux-aarch64-low.c (*): Update all debugging printfs to use
10386 debug_printf instead of fprintf.
10387 * linux-arm-low.c (*): Ditto.
10388 * linux-cris-low.c (*): Ditto.
10389 * linux-crisv32-low.c (*): Ditto.
10390 * linux-m32r-low.c (*): Ditto.
10391 * linux-sparc-low.c (*): Ditto.
10392 * linux-x86.c (*): Ditto.
10393 * linux-low.c (*): Ditto.
10394 (linux_wait_1): Add calls to debug_enter, debug_exit.
10395 (linux_wait): Remove redundant debugging printf.
10396 (stop_all_lwps): Add calls to debug_enter, debug_exit.
10397 (linux_resume, unstop_all_lwps): Ditto.
10398 * mem-break.c (*): Update all debugging printfs to use
10399 debug_printf instead of fprintf.
10400 * remote-utils.c (*): Ditto.
10401 * thread-db.c (*): Ditto.
10402 * server.c #include <ctype.h>, "gdb_vecs.h".
10403 (debug_threads): Moved to debug.c.
10404 (*): Update all debugging printfs to use debug_printf instead of
10406 (start_inferior): Replace call to fflush with call to debug_flush.
10407 (monitor_show_help): Mention set debug-format.
10408 (parse_debug_format_options): New function.
10409 (handle_monitor_command): Handle "monitor set debug-format".
10410 (gdbserver_usage): Mention --debug-format.
10411 (main): Parse --debug-format.
10412 * server.h (debug_threads): Declaration moved to debug.h.
10413 #include "debug.h".
10414 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
10415 trace_debug_1 that uses debug_printf.
10416 (tracepoint_look_up_symbols): Update all debugging printfs to use
10417 debug_printf instead of fprintf.
10419 2014-01-20 Baruch Siach <baruch@tkos.co.il>
10421 * linux-xtensa-low.c: Include asm/ptrace.h instead of
10424 2014-01-17 Pedro Alves <palves@redhat.com>
10427 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
10428 defined after including gdb_proc_service.h.
10430 2014-01-16 Doug Evans <dje@google.com>
10432 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
10433 (match_dll): Use it.
10435 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
10437 * target.h (target_ops) <read_btrace>: Change parameters and
10438 return type to allow error reporting.
10439 * server.c (handle_qxfer_btrace): Support delta reads. Pass
10440 trace reading errors on.
10441 * linux-low.c (linux_low_read_btrace): Pass trace reading
10443 (linux_low_disable_btrace): New.
10445 2014-01-15 Doug Evans <dje@google.com>
10447 * inferiors.c (thread_id_to_gdb_id): Delete.
10448 * inferiors.h (thread_id_to_gdb_id): Delete.
10450 2014-01-13 Eli Zaretskii <eliz@gnu.org>
10452 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
10453 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
10456 2014-01-08 Pedro Alves <palves@redhat.com>
10458 * server.c (handle_status): Don't discard previous queued stop
10459 replies or thread's pending status here.
10460 (main) <disconnection>: Do it here instead.
10462 2014-01-08 Pedro Alves <palves@redhat.com>
10464 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
10465 * server.c (visit_actioned_threads, handle_pending_status): New
10467 (handle_v_cont): Factor out parts to ...
10468 (resume): ... this new function. If in all-stop, and a thread
10469 being resumed has a pending status, report it without actually
10471 (myresume): Adjust to use the new 'resume' function.
10472 (clear_pending_status_callback, set_pending_status_callback)
10473 (find_status_pending_thread_callback): New functions.
10474 (handle_status): Handle the case of multiple threads having
10475 interesting statuses to report. Report threads' real last signal
10476 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
10477 with an interesting thread to report the status for, instead of
10478 always reporting the status of the first thread.
10480 2014-01-01 Joel Brobecker <brobecker@adacore.com>
10482 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
10483 * gdbreplay.c (gdbreplay_version): Likewise.
10485 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
10487 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
10488 iov.iov_len with the real length in use.
10490 2013-12-13 Joel Brobecker <brobecker@adacore.com>
10492 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
10493 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
10494 for all targets that use win32-low.c.
10495 * win32-low.c (win32_ensure_ntdll_loaded): New function.
10496 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
10498 2013-12-13 Pedro Alves <palves@redhat.com>
10500 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
10501 if equal to TARGET_WAITKIND_LOADED.
10502 * win32-low.c (cached_status): New static global.
10503 (win32_wait): Add declaration.
10504 (do_initial_child_stuff): Flush all initial pending debug events
10505 up to the initial breakpoint.
10506 (win32_wait): If CACHED_STATUS was set, return that instead
10507 of doing a real wait. Remove the code resuming the execution
10508 of the inferior after receiving a TARGET_WAITKIND_LOADED event
10509 during the initial phase. Also remove the code changing
10510 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
10511 TARGET_WAITKIND_STOPPED.
10513 2013-12-11 Yao Qi <yao@codesourcery.com>
10515 * notif.c (handle_notif_ack): Return 0 if no notification
10518 2013-11-20 Doug Evans <dje@google.com>
10520 * linux-low.c (linux_set_resume_request): Fix comment.
10522 2013-11-20 Doug Evans <dje@google.com>
10524 * linux-low.c (resume_status_pending_p): Tweak comment.
10526 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
10528 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
10529 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
10530 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
10531 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
10532 (srv_amd64_regobj): Add amd64-mpx.o.
10533 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
10534 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
10535 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
10536 * i387-fp.c (num_pl_bnd_register) Added constant.
10537 (num_pl_bnd_cfg_registers) Added constant.
10538 (struct i387_xsave) Added reserved area and MPX fields.
10539 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
10540 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
10542 (tdesc_i386_mpx_linux): Add MPX amd64 target.
10543 (init_registers_amd64_mpx_linux): Declare new function.
10544 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
10545 (x86_64_regmap): Add MPX registers.
10546 (x86_linux_read_description): Add MPX case.
10547 (initialize_low_arch): Initialize MPX targets.
10549 2013-11-18 Tom Tromey <tromey@redhat.com>
10551 * configure: Rebuild.
10552 * configure.ac: Don't check for stdlib.h.
10553 * gdbreplay.c: Unconditionally include stdlib.h.
10555 2013-11-18 Tom Tromey <tromey@redhat.com>
10557 * config.in: Rebuild.
10558 * configure: Rebuild.
10559 * configure.ac: Don't use AC_HEADER_DIRENT.
10561 2013-11-18 Tom Tromey <tromey@redhat.com>
10563 * server.h: Don't check HAVE_STRING_H.
10564 * gdbreplay.c: Don't check HAVE_STRING_H.
10565 * configure: Rebuild.
10567 2013-11-18 Tom Tromey <tromey@redhat.com>
10569 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
10572 2013-11-08 Tom Tromey <tromey@redhat.com>
10574 * configure, config.in: Rebuild.
10575 * configure.ac: Remove unused configury.
10577 2013-11-08 Tom Tromey <tromey@redhat.com>
10579 * acinclude.m4: Include common.m4, codeset.m4.
10580 * configure, config.in: Rebuild.
10581 * configure.ac: Use GDB_AC_COMMON.
10583 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
10585 * linux-s390-low.c (HWCAP_S390_TE): New define.
10586 (s390_arch_setup): Consider the TE field in the HWCAP for
10587 determining 'have_regset_tdb'.
10589 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
10592 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
10595 2013-10-02 Pedro Alves <palves@redhat.com>
10597 * server.c (process_serial_event): Don't output "GDBserver
10598 exiting" if GDB is connected through stdio.
10599 * target.c (mywait): Likewise, be silent if GDB is connected
10602 2013-10-01 Joel Brobecker <brobecker@adacore.com>
10604 * lynx-low.c (lynx_add_threads_after_attach): New function.
10605 (lynx_attach): Remove call to add_thread. Add call to
10606 lynx_add_threads_after_attach instead.
10608 2013-09-28 Mike Frysinger <vapier@gentoo.org>
10610 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
10611 * config.in, configure: Regenerated.
10613 2013-09-18 Yao Qi <yao@codesourcery.com>
10616 * server.c (start_inferior): Clear 'resume_info'.
10618 2013-09-16 Jiong Wang <jiwang@tilera.com>
10620 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
10623 2013-09-16 Jiong Wang <jiwang@tilera.com>
10625 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
10626 linux-tile-low.o to srv_tgtobj.
10628 2013-09-16 Will Newton <will.newton@linaro.org>
10630 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
10633 2013-09-06 Pedro Alves <palves@redhat.com>
10635 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
10636 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
10637 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
10638 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
10639 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
10640 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
10642 2013-09-06 Pedro Alves <palves@redhat.com>
10644 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
10645 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
10647 2013-09-06 Pedro Alves <palves@redhat.com>
10649 * linux-amd64-ipa.c: Include tracepoint.h.
10650 * linux-i386-ipa.c: Include tracepoint.h.
10652 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
10654 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
10655 (ps_get_thread_area): New function.
10657 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
10659 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
10660 (initialize_low_arch): Call init_registers_crisv32 rather than
10661 init_register_crisv32.
10663 2013-09-05 Pedro Alves <palves@redhat.com>
10665 * server.h (handle_vFile, hostio_last_error_from_errno): Move
10667 * hostio.h: ... this new file.
10668 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
10669 win32-low.c: Include hostio.h.
10671 2013-09-05 Pedro Alves <palves@redhat.com>
10673 * server.h (gdb_client_data, handler_func, callback_handler_func)
10674 (delete_file_handler, add_file_handler, append_callback_event)
10675 (delete_callback_event, start_event_loop, initialize_event_loop):
10676 Move to event-loop.h and include it.
10677 * event-loop.h: New file.
10679 2013-09-05 Pedro Alves <palves@redhat.com>
10681 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
10682 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
10683 (loaded_dll, unloaded_dll): Move to ...
10684 * dll.h: ... this new file.
10685 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
10687 2013-09-05 Pedro Alves <palves@redhat.com>
10689 * server.h (current_process, get_thread_process, all_processes)
10690 (add_inferior_to_list, for_each_inferior, current_inferior)
10691 (remove_inferior, add_process, remove_process, find_process_pid)
10692 (have_started_inferiors_p, have_attached_inferiors_p)
10693 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
10694 (clear_inferiors, find_inferior, find_inferior_id)
10695 (inferior_target_data, set_inferior_target_data)
10696 (inferior_regcache_data, set_inferior_regcache_data): Move to
10697 inferiors.h, and include it.
10698 * inferiors.h: New file.
10700 2013-09-05 Pedro Alves <palves@redhat.com>
10702 * server.h (struct emit_ops, current_insn_ptr, emit_error):
10706 2013-09-05 Pedro Alves <palves@redhat.com>
10708 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
10710 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
10711 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
10712 (handle_tracepoint_general_set, handle_tracepoint_query)
10713 (tracepoint_finished_step, tracepoint_was_hit)
10714 (release_while_stepping_state_list, current_traceframe)
10715 (in_readonly_region, traceframe_read_mem)
10716 (fetch_traceframe_registers, traceframe_read_sdata)
10717 (traceframe_read_info, struct fast_tpoint_collect_status)
10718 (fast_tracepoint_collecting, force_unlock_trace_buffer)
10719 (handle_tracepoit_bkpts, initialize_low_tracepoint)
10720 (supply_fast_tracepoint_registers)
10721 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
10722 (ipa_tdesc, claim_trampoline_space)
10723 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
10724 (agent_mem_read, agent_get_trace_state_variable_value)
10725 (agent_set_trace_state_variable_value, agent_tsv_read)
10726 (agent_mem_read_string, get_raw_reg_func_addr)
10727 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
10728 * tracepoint.h: ... this new file.
10730 2013-09-05 Pedro Alves <palves@redhat.com>
10732 * server.h (perror_with_name, error, fatal, warning, paddress)
10733 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
10735 * utils.h: New file.
10737 2013-09-05 Pedro Alves <palves@redhat.com>
10739 * server.h (remote_debug, noack_mode, transport_is_reliable)
10740 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
10741 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
10742 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
10743 (write_enn, initialize_async_io, enable_async_io)
10744 (disable_async_io, check_remote_input_interrupt_request)
10745 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
10746 (dead_thread_notify, prepare_resume_reply)
10747 (decode_address_to_semicolon, decode_address, decode_m_packet)
10748 (decode_M_packet, decode_X_packet, decode_xfer_write)
10749 (decode_search_memory_packet, unhexify, hexify)
10750 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
10751 (look_up_one_symbol, relocate_instruction)
10752 (monitor_output): Move to remote-utils.h, and include it.
10753 * remote-utils.h: New file.
10755 2013-09-05 Pedro Alves <palves@redhat.com>
10757 * server.h (_): Delete.
10759 2013-09-02 Pedro Alves <palves@redhat.com>
10761 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
10762 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
10764 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
10766 2013-09-02 Pierre Muller <muller@sourceware.org>
10768 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
10769 or WriteProcessMemory complete successfully and handle
10770 ERROR_PARTIAL_COPY error.
10772 2013-09-02 Pedro Alves <palves@redhat.com>
10774 * server.c (gdb_read_memory): Return -1 on traceframe memory read
10775 error instead of EIO.
10777 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
10780 * linux-low.c: Include filestuff.h.
10781 (linux_create_inferior) <pid == 0>: Call close_most_fds.
10782 * lynx-low.c: Include filestuff.h.
10783 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
10784 * server.c: Include filestuff.h.
10785 (main): Call notice_open_fds.
10786 * spu-low.c: Include filestuff.h.
10787 (spu_create_inferior) <pid == 0>: Call close_most_fds.
10789 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
10791 * Makefile.in: Explain why ../target and ../nat are not
10792 listed as include file search paths.
10793 (linux-waitpid.o): New object file rule.
10794 * configure.srv (srv_native_linux_obj): New variable.
10795 Replace all occurrences of linux native object files with
10796 $srv_native_linux_obj.
10797 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
10798 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
10799 (linux_enable_event_reporting): Remove declaration.
10800 (my_waitpid): Moved to common/linux-waitpid.c.
10801 (linux_wait_for_event): Pass ptid when calling
10802 linux_enable_event_reporting.
10803 (linux_supports_tracefork_flag): Remove.
10804 (linux_enable_event_reporting): Likewise.
10805 (linux_tracefork_grandchild): Remove.
10806 (STACK_SIZE): Moved to common/linux-ptrace.c.
10807 (linux_tracefork_child): Remove.
10808 (linux_test_for_tracefork): Remove.
10809 (linux_look_up_symbols): Call linux_supports_traceclone.
10810 (initialize_low): Remove call to linux_test_for_tracefork.
10811 * linux-low.h (PTRACE_TYPE_ARG3): Move to
10812 common/linux-ptrace.h.
10813 (PTRACE_TYPE_ARG4): Likewise.
10814 Include linux-ptrace.h.
10816 2013-08-21 Pedro Alves <palves@redhat.com>
10818 * config.in: Renegerate.
10820 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
10822 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
10823 (SFILES): Remove $(srcdir)/common/target-common.c and
10824 add $(srcdir)/target/waitstatus.c.
10825 (OBS): Remove target-common.o and add waitstatus.o.
10826 (server_h): Remove $(srcdir)/../common/target-common.h and
10827 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
10828 and $(srcdir)/../target/waitstatus.h.
10829 (target-common.o): Remove.
10830 (waitstatus.o): New target object file.
10831 * target.h: Do not include target-common.h and
10832 include target/resume.h, target/wait.h and
10833 target/waitstatus.h.
10835 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
10837 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
10838 to PTRACE_TYPE_ARG3.
10839 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
10840 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
10842 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
10843 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
10845 2013-07-27 Jie Zhang <jie@codesourcery.com>
10846 Daniel Jacobowitz <dan@codesourcery.com>
10847 Yao Qi <yao@codesourcery.com>
10849 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
10850 (mips-linux-watch.o): New rule.
10851 (mips_linux_watch_h): New variable.
10852 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
10854 * linux-mips-low.c: Include mips-linux-watch.h.
10855 (struct arch_process_info, struct arch_lwp_info): New.
10856 (update_watch_registers_callback): New function.
10857 (mips_linux_new_process, mips_linux_new_thread) New functions.
10858 (mips_linux_prepare_to_resume, mips_insert_point): New
10860 (mips_remove_point, mips_stopped_by_watchpoint): New
10862 (rsp_bp_type_to_target_hw_bp_type): New function.
10863 (mips_stopped_data_address): New function.
10864 (the_low_target): Add watchpoint support functions.
10866 2013-07-27 Yao Qi <yao@codesourcery.com>
10868 * i386-low.c: Include break-common.h.
10869 (enum target_hw_bp_type): Remove.
10871 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
10873 * Makefile.in (SFILES): /common/target-common.c.
10874 (OBS): Add target-common.o.
10875 (server_h): Add $(srcdir)/../common/target-common.h.
10876 (target-common.o): New target.
10877 * server.c (queue_stop_reply_callback): Free
10878 status string after use.
10879 * target.c (target_waitstatus_to_string): Remove.
10880 * target.h: Include target-common.h.
10881 (resume_kind): Likewise.
10882 (target_waitkind): Likewise.
10883 (target_waitstatus): Likewise.
10884 (TARGET_WNOHANG): Likewise.
10886 2013-07-04 Yao Qi <yao@codesourcery.com>
10888 * Makefile.in (host_alias): Use @host_noncanonical@.
10889 (target_alias): Use @target_noncanonical@.
10890 * configure.ac: Use ACX_NONCANONICAL_TARGET and
10891 ACX_NONCANONICAL_HOST.
10892 * configure: Regenerated.
10895 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
10897 * configure.ac (version_host, version_target): Set and AC_SUBST them.
10898 * configure: Rebuild.
10899 * Makefile.in (version_host, version_target): Get from configure.
10900 (version.c): Use $(version_host) and $(version_target).
10902 2013-07-03 Pedro Alves <palves@redhat.com>
10904 * Makefile.in (config.status): Depend on development.sh.
10905 * acinclude.m4: Include libmcheck.m4.
10906 * configure: Regenerate.
10908 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
10910 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
10911 attribute inside the parentheses.
10912 (winapi_DebugSetProcessKillOnExit): Ditto.
10913 (winapi_DebugBreakProcess): Ditto.
10914 (winapi_GenerateConsoleCtrlEvent): Ditto.
10916 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
10918 * notif.h (notif_event): Add a dummy member to avoid compiler
10921 2013-07-01 Pedro Alves <palves@redhat.com>
10923 * hostio.c (HOSTIO_PATH_MAX): Define.
10924 (require_filename, handle_open, handle_unlink, handle_readlink):
10927 2013-07-01 Pedro Alves <palves@redhat.com>
10929 * server.h: Include "pathmax.h".
10930 * linux-low.c: Don't include sys/param.h.
10931 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
10933 * win32-low.c: Don't include sys/param.h.
10934 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
10936 2013-07-01 Pedro Alves <palves@redhat.com>
10938 * event-loop.c: Don't check HAVE_UNISTD_H before including
10940 * gdbreplay.c: Likewise.
10941 * remote-utils.c: Likewise.
10942 * server.c: Likewise.
10943 * configure.ac: Don't check for unistd.h.
10944 * configure: Regenerate.
10946 2013-06-28 Tom Tromey <tromey@redhat.com>
10948 * Makefile.in (version.c): Use version.in, not
10951 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
10953 * configure.ac (version_host, version_target): Set and AC_SUBST them.
10954 * configure: Rebuild.
10955 * Makefile.in (version_host, version_target): Get from configure.
10956 (version.c): Use $(version_host) and $(version_target).
10958 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
10960 Fix trace-status to output user name without trailing colon.
10961 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
10963 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
10965 Fix trace-status to output proper start-time and stop-time.
10966 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
10967 output start time and stop time in hex as gdb expects.
10969 2013-06-26 Pedro Alves <pedro@codesourcery.com>
10971 * tracepoint.c (build_traceframe_info_xml): Output trace state
10972 variables present in the trace buffer.
10974 2013-06-24 Tom Tromey <tromey@redhat.com>
10976 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
10978 (version.o): Remove.
10979 * gdbreplay.c: Include version.h.
10980 (version, host_name): Don't declare.
10981 * server.h: Include version.h.
10982 (version, host_name): Don't declare.
10984 2013-06-12 Pedro Alves <palves@redhat.com>
10986 * linux-x86-low.c (linux_is_elf64): Delete global.
10987 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
10988 with local linux_pid_exe_is_elf_64_file use.
10990 2013-06-11 Pedro Alves <palves@redhat.com>
10992 * linux-low.c (regset_disabled, disable_regset): New functions.
10993 (regsets_fetch_inferior_registers)
10994 (regsets_store_inferior_registers): Use them.
10995 (initialize_regsets_info); Don't allocate the disabled_regsets
10997 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
11000 2013-06-11 Pedro Alves <palves@redhat.com>
11002 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
11005 2013-06-11 Pedro Alves <palves@redhat.com>
11007 * linux-x86-low.c (initialize_low_arch): Call
11008 init_registers_x32_avx_linux.
11010 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
11012 Fix compatibility with Android Bionic.
11013 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
11016 2013-06-07 Pedro Alves <palves@redhat.com>
11019 * Makefile.in (OBS): Add tdesc.o.
11020 (IPA_OBJS): Add tdesc-ipa.o.
11021 (tdesc-ipa.o): New rule.
11022 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
11024 * linux-low.c (new_inferior): Delete.
11025 (disabled_regsets, num_regsets): Delete.
11026 (linux_add_process): Adjust to set the new per-process
11028 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
11029 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
11030 was a stop. When calling arch_setup, switch the current inferior
11031 to the thread that got an event.
11032 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
11033 (regsets_fetch_inferior_registers)
11034 (regsets_store_inferior_registers): New regsets_info parameter.
11036 (linux_register_in_regsets): New regs_info parameter. Adjust to
11038 (register_addr, fetch_register, store_register): New usrregs_info
11039 parameter. Adjust to use it.
11040 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
11041 parameter regs_info. Adjust to use it.
11042 (linux_fetch_registers): Get the current inferior's regs_info, and
11044 (linux_store_registers): Ditto.
11045 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
11046 (initialize_low): Don't initialize the target_regsets here. Call
11047 initialize_low_arch.
11048 * linux-low.h (target_regsets): Delete declaration.
11049 (struct regsets_info): New.
11050 (struct usrregs_info): New.
11051 (struct regs_info): New.
11052 (struct process_info_private) <new_inferior>: New field.
11053 (struct linux_target_ops): Delete the num_regs, regmap, and
11054 regset_bitmap fields. New field regs_info.
11055 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
11056 * i387-fp.c (num_xmm_registers): Delete.
11057 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
11058 calls to new interface.
11059 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
11060 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
11061 Infer the number of xmm registers from the regcache's target
11063 * i387-fp.h (num_xmm_registers): Delete.
11064 * inferiors.c (add_thread): Don't install the thread's regcache
11066 * proc-service.c (gregset_info): Fetch the current inferior's
11067 regs_info. Adjust to use it.
11068 * regcache.c: Include tdesc.h.
11069 (register_bytes, reg_defs, num_registers)
11070 (gdbserver_expedite_regs): Delete.
11071 (get_thread_regcache): If the thread doesn't have a regcache yet,
11072 create one, instead of aborting gdbserver.
11073 (regcache_invalidate_one): Rename to ...
11074 (regcache_invalidate_thread): ... this.
11075 (regcache_invalidate_one): New.
11076 (regcache_invalidate): Only invalidate registers of the current
11078 (init_register_cache): Add target_desc parameter, and use it.
11079 (new_register_cache): Ditto. Assert the target description has a
11080 non zero registers_size.
11081 (regcache_cpy): Add assertions. Adjust.
11082 (realloc_register_cache, set_register_cache): Delete.
11083 (registers_to_string, registers_from_string): Adjust.
11084 (find_register_by_name, find_regno, find_register_by_number)
11085 (register_cache_size): Add target_desc parameter, and use it.
11086 (free_register_cache_thread, free_register_cache_thread_one)
11087 (regcache_release, register_cache_size): New.
11088 (register_size): Add target_desc parameter, and use it.
11089 (register_data, supply_register, supply_register_zeroed)
11090 (supply_regblock, supply_register_by_name, collect_register)
11091 (collect_register_as_string, collect_register_by_name): Adjust.
11092 * regcache.h (struct target_desc): Forward declare.
11093 (struct regcache) <tdesc>: New field.
11094 (init_register_cache, new_register_cache): Add target_desc
11096 (regcache_invalidate_thread): Declare.
11097 (regcache_invalidate_one): Delete declaration.
11098 (regcache_release): Declare.
11099 (find_register_by_number, register_cache_size, register_size)
11100 (find_regno): Add target_desc parameter.
11101 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
11103 * remote-utils.c: Include tdesc.h.
11104 (outreg, prepare_resume_reply): Adjust.
11105 * server.c: Include tdesc.h.
11106 (gdbserver_xmltarget): Delete declaration.
11107 (get_features_xml, process_serial_event): Adjust.
11108 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
11110 (struct process_info) <tdesc>: New field.
11111 (ipa_tdesc): Declare.
11112 * tdesc.c: New file.
11113 * tdesc.h: New file.
11114 * tracepoint.c: Include tdesc.h.
11115 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
11116 (get_context_regcache): Adjust to pass ipa_tdesc down.
11117 (do_action_at_tracepoint): Adjust to get the register cache size
11118 from the context regcache's description.
11119 (traceframe_walk_blocks): Adjust to get the register cache size
11120 from the current trace frame's description.
11121 (traceframe_get_pc): Adjust to get current trace frame's
11122 description and pass it down.
11123 (gdb_collect): Adjust to get the register cache size from the
11125 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
11126 (gdbserver_xmltarget): Delete.
11127 (initialize_low_tracepoint): Set the ipa's target description.
11128 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
11129 (initialize_low_tracepoint): Set the ipa's target description.
11130 * linux-x86-low.c: Include tdesc.h.
11131 [__x86_64__] (is_64bit_tdesc): New.
11132 (ps_get_thread_area, x86_get_thread_area): Use it.
11133 (i386_cannot_store_register): Rename to ...
11134 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
11135 (i386_cannot_fetch_register): Rename to ...
11136 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
11137 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
11139 (target_regsets): Rename to ...
11140 (x86_regsets): ... this.
11141 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
11143 (x86_siginfo_fixup): Use is_64bit_tdesc.
11144 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
11145 (tdesc_x32_avx_linux, tdesc_x32_linux)
11146 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
11148 (x86_linux_update_xmltarget): Delete.
11149 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
11150 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
11151 (AMD64_LINUX_USER64_CS): New.
11152 (x86_linux_read_description): New, based on
11153 x86_linux_update_xmltarget.
11154 (same_process_callback): New.
11155 (x86_arch_setup_process_callback): New.
11156 (x86_linux_update_xmltarget): New.
11157 (x86_regsets_info): New.
11158 (amd64_linux_regs_info): New.
11159 (i386_linux_usrregs_info): New.
11160 (i386_linux_regs_info): New.
11161 (x86_linux_regs_info): New.
11162 (x86_arch_setup): Reimplement.
11163 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
11164 (x86_emit_ops): Ditto.
11165 (the_low_target): Adjust. Install x86_linux_regs_info,
11166 x86_cannot_fetch_register, and x86_cannot_store_register.
11167 (initialize_low_arch): New.
11168 * linux-ia64-low.c (tdesc_ia64): Declare.
11169 (ia64_fetch_register): Adjust.
11170 (ia64_usrregs_info, regs_info): New globals.
11171 (ia64_regs_info): New function.
11172 (the_low_target): Adjust.
11173 (initialize_low_arch): New function.
11174 * linux-sparc-low.c (tdesc_sparc64): Declare.
11175 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
11177 (sparc_arch_setup): New function.
11178 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
11179 (the_low_target): Adjust.
11180 (initialize_low_arch): New function.
11181 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
11182 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
11183 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
11184 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
11185 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
11186 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
11187 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
11188 (tdesc_powerpc_isa205_vsx64l): Declare.
11189 (ppc_cannot_store_register, ppc_collect_ptrace_register)
11190 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
11191 (ppc_set_pc, ppc_get_hwcap): Adjust.
11192 (ppc_usrregs_info): Forward declare.
11193 (!__powerpc64__) ppc_regmap_adjusted: New global.
11194 (ppc_arch_setup): Adjust to the current process'es target
11196 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
11197 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
11198 (ppc_store_evrregset): Adjust.
11199 (target_regsets): Rename to ...
11200 (ppc_regsets): ... this, and make static.
11201 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
11202 (ppc_regs_info): New function.
11203 (the_low_target): Adjust.
11204 (initialize_low_arch): New function.
11205 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
11206 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
11207 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
11208 (tdesc_s390x_linux64v2): Declare.
11209 (s390_collect_ptrace_register, s390_supply_ptrace_register)
11210 (s390_fill_gregset, s390_store_last_break): Adjust.
11211 (target_regsets): Rename to ...
11212 (s390_regsets): ... this, and make static.
11213 (s390_get_pc, s390_set_pc): Adjust.
11214 (s390_get_hwcap): New target_desc parameter, and use it.
11215 [__s390x__] (have_hwcap_s390_high_gprs): New global.
11216 (s390_arch_setup): Adjust to set the current process'es target
11217 description. Don't adjust the regmap.
11218 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
11219 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
11220 (regs_info_3264): New globals.
11221 (s390_regs_info): New function.
11222 (the_low_target): Adjust.
11223 (initialize_low_arch): New function.
11224 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
11225 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
11226 [__mips64] (init_registers_mips_linux)
11227 (init_registers_mips_dsp_linux): Delete defines.
11228 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
11229 (have_dsp): New global.
11230 (mips_read_description): New, based on mips_arch_setup.
11231 (mips_arch_setup): Reimplement.
11232 (get_usrregs_info): New function.
11233 (mips_cannot_fetch_register, mips_cannot_store_register)
11234 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
11235 (mips_fill_fpregset, mips_store_fpregset): Adjust.
11236 (target_regsets): Rename to ...
11237 (mips_regsets): ... this, and make static.
11238 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
11239 (dsp_regs_info, regs_info): New globals.
11240 (mips_regs_info): New function.
11241 (the_low_target): Adjust.
11242 (initialize_low_arch): New function.
11243 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
11244 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
11246 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
11247 (arm_read_description): New, with bits factored from
11249 (arm_arch_setup): Reimplement.
11250 (target_regsets): Rename to ...
11251 (arm_regsets): ... this, and make static.
11252 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
11253 (arm_regs_info): New function.
11254 (the_low_target): Adjust.
11255 (initialize_low_arch): New function.
11256 * linux-m68k-low.c (tdesc_m68k): Declare.
11257 (target_regsets): Rename to ...
11258 (m68k_regsets): ... this, and make static.
11259 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
11260 (m68k_regs_info): New function.
11261 (m68k_arch_setup): New function.
11262 (the_low_target): Adjust.
11263 (initialize_low_arch): New function.
11264 * linux-sh-low.c (tdesc_sharch): Declare.
11265 (target_regsets): Rename to ...
11266 (sh_regsets): ... this, and make static.
11267 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
11268 (sh_regs_info, sh_arch_setup): New functions.
11269 (the_low_target): Adjust.
11270 (initialize_low_arch): New function.
11271 * linux-bfin-low.c (tdesc_bfin): Declare.
11272 (bfin_arch_setup): New function.
11273 (bfin_usrregs_info, regs_info): New globals.
11274 (bfin_regs_info): New function.
11275 (the_low_target): Adjust.
11276 (initialize_low_arch): New function.
11277 * linux-cris-low.c (tdesc_cris): Declare.
11278 (cris_arch_setup): New function.
11279 (cris_usrregs_info, regs_info): New globals.
11280 (cris_regs_info): New function.
11281 (the_low_target): Adjust.
11282 (initialize_low_arch): New function.
11283 * linux-cris-low.c (tdesc_crisv32): Declare.
11284 (cris_arch_setup): New function.
11285 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
11286 (cris_regs_info): New function.
11287 (the_low_target): Adjust.
11288 (initialize_low_arch): New function.
11289 * linux-m32r-low.c (tdesc_m32r): Declare.
11290 (m32r_arch_setup): New function.
11291 (m32r_usrregs_info, regs_info): New globals.
11292 (m32r_regs_info): Adjust.
11293 (initialize_low_arch): New function.
11294 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
11295 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
11296 (tic6x_usrregs_info): Forward declare.
11297 (tic6x_read_description): New function, based on ...
11298 (tic6x_arch_setup): ... this. Reimplement.
11299 (target_regsets): Rename to ...
11300 (tic6x_regsets): ... this, and make static.
11301 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
11302 (tic6x_regs_info): New function.
11303 (the_low_target): Adjust.
11304 (initialize_low_arch): New function.
11305 * linux-xtensa-low.c (tdesc_xtensa): Declare.
11306 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
11307 (target_regsets): Rename to ...
11308 (xtensa_regsets): ... this, and make static.
11309 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
11311 (xtensa_arch_setup, xtensa_regs_info): New functions.
11312 (the_low_target): Adjust.
11313 (initialize_low_arch): New function.
11314 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
11315 (nios2_arch_setup): Set the current process'es tdesc.
11316 (target_regsets): Rename to ...
11317 (nios2_regsets): ... this.
11318 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
11319 (nios2_regs_info): New function.
11320 (the_low_target): Adjust.
11321 (initialize_low_arch): New function.
11322 * linux-aarch64-low.c (tdesc_aarch64): Declare.
11323 (aarch64_arch_setup): Set the current process'es tdesc.
11324 (target_regsets): Rename to ...
11325 (aarch64_regsets): ... this.
11326 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
11327 (aarch64_regs_info): New function.
11328 (the_low_target): Adjust.
11329 (initialize_low_arch): New function.
11330 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
11332 (target_regsets): Rename to ...
11333 (tile_regsets): ... this.
11334 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
11335 (tile_regs_info): New function.
11336 (tile_arch_setup): Set the current process'es tdesc.
11337 (the_low_target): Adjust.
11338 (initialize_low_arch): New function.
11339 * spu-low.c (tdesc_spu): Declare.
11340 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
11341 * win32-arm-low.c (tdesc_arm): Declare.
11342 (arm_arch_setup): New function.
11343 (the_low_target): Install arm_arch_setup instead of
11344 init_registers_arm.
11345 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
11346 (init_windows_x86): Rename to ...
11347 (i386_arch_setup): ... this. Set `win32_tdesc'.
11348 (the_low_target): Adjust.
11349 * win32-low.c (win32_tdesc): New global.
11350 (child_add_thread): Don't create the thread cache here.
11351 (do_initial_child_stuff): Set the new process'es tdesc.
11352 * win32-low.h (struct target_desc): Forward declare.
11353 (win32_tdesc): Declare.
11354 * lynx-i386-low.c (tdesc_i386): Declare global.
11355 (lynx_i386_arch_setup): Set `lynx_tdesc'.
11356 * lynx-low.c (lynx_tdesc): New global.
11357 (lynx_add_process): Set the new process'es tdesc.
11358 * lynx-low.h (struct target_desc): Forward declare.
11359 (lynx_tdesc): Declare global.
11360 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
11361 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
11362 * nto-low.c (nto_tdesc): New global.
11363 (do_attach): Set the new process'es tdesc.
11364 * nto-low.h (struct target_desc): Forward declare.
11365 (nto_tdesc): Declare.
11366 * nto-x86-low.c (tdesc_i386): Declare.
11367 (nto_x86_arch_setup): Set `nto_tdesc'.
11369 2013-06-04 Gary Benson <gbenson@redhat.com>
11371 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
11372 to qSupported response when appropriate.
11373 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
11374 with nonzero-length annex.
11375 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
11376 arguments supplied in annex.
11378 2013-05-31 Doug Evans <dje@google.com>
11381 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
11382 64 bits in 64-cross-32 environment.
11384 2013-05-28 Pedro Alves <palves@redhat.com>
11386 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
11387 (aarch64-without-fpu.c): Delete rule.
11388 * configure.srv (aarch64*-*-linux*): Remove references to
11389 aarch64-without-fpu.o and aarch64-without-fpu.xml.
11390 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
11393 2013-05-24 Pedro Alves <palves@redhat.com>
11395 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
11396 instead of strchr/decode_address. Error if the range isn't split
11397 with a ','. Don't assume there's be a ':' in the action.
11399 2013-05-23 Yao Qi <yao@codesourcery.com>
11400 Pedro Alves <palves@redhat.com>
11402 * linux-low.c (lwp_in_step_range): New function.
11403 (linux_wait_1): If the thread was range stepping and stopped
11404 outside the stepping range, report the stop to GDB. Otherwise,
11405 continue stepping. Add range stepping debug output.
11406 (linux_set_resume_request): Copy the step range from the resume
11407 request to the lwp.
11408 (linux_supports_range_stepping): New.
11409 (linux_target_ops) <supports_range_stepping>: Set to
11410 linux_supports_range_stepping.
11411 * linux-low.h (struct linux_target_ops)
11412 <supports_range_stepping>: New field.
11413 (struct lwp_info) <step_range_start, step_range_end>: New fields.
11414 * linux-x86-low.c (x86_supports_range_stepping): New.
11415 (the_low_target) <supports_range_stepping>: Set to
11416 x86_supports_range_stepping.
11417 * server.c (handle_v_cont): Handle 'r' action.
11418 (handle_v_requests): Append ";r" if the target supports range
11420 * target.h (struct thread_resume) <step_range_start,
11421 step_range_end>: New fields.
11422 (struct target_ops) <supports_range_stepping>:
11424 (target_supports_range_stepping): New macro.
11426 2013-05-17 Joel Brobecker <brobecker@adacore.com>
11428 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
11429 confusion in comment.
11431 2013-05-17 Joel Brobecker <brobecker@adacore.com>
11433 * lynx-low.c (struct process_info_private): New type.
11434 (lynx_add_process): New function.
11435 (lynx_create_inferior, lynx_attach): Replace calls to
11436 add_process by calls to lynx_add_process.
11437 (lynx_resume): If PTID is null, then try using
11438 current_process()->private->last_wait_event_ptid.
11440 (lynx_clear_inferiors): Delete. The contents of that function
11441 has been inlined in lynx_mourn;
11442 (lynx_wait_1): Save the ptid in the process's private data.
11443 (lynx_mourn): Free the process' private data. Replace call
11444 to lynx_clear_inferiors by call to clear_inferiors.
11446 2013-05-17 Yao Qi <yao@codesourcery.com>
11448 * i386-low.c (i386_length_and_rw_bits): Move the comment to
11451 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
11453 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
11454 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
11455 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
11456 PT_TEXT_END_ADDR guards. Update comments.
11457 (linux_target_op) <read_offsets>: Conditionally define to
11458 linux_read_offsets if the target is UCLIBC and if it defines
11459 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
11461 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
11462 Andrew Jenner <andrew@codesourcery.com>
11464 * Makefile.in (SFILES): Add linux-nios2-low.c.
11465 (clean): Add action to delete nios2-linux.c.
11466 (nios2-linux.c): New rule.
11467 * configure.srv: Add nios2*-*-linux*.
11468 * linux-nios2-low.c: New.
11470 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
11472 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
11474 2013-04-25 Hui Zhu <hui@codesourcery.com>
11477 * ax.c (ax_printf): Add fflush.
11479 2013-04-22 Tom Tromey <tromey@redhat.com>
11481 * Makefile.in (SFILES): Add filestuff.c.
11482 (OBS): Add filestuff.o.
11483 (filestuff.o): New target.
11484 * config.in, configure: Rebuild.
11485 * configure.ac: Check for fdwalk, pipe2.
11487 2013-04-17 Pedro Alves <palves@redhat.com>
11489 * configure.ac (USE_THREAD_DB): Delete variable.
11490 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
11491 Don't AC_SUBST USE_THREAD_DB.
11492 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
11493 * config.in, configure: Regenerate.
11495 2013-04-16 Pedro Alves <palves@redhat.com>
11497 * linux-low.h (struct lwp_info) <thread_known>: Move under
11498 the USE_THREAD_DB #ifdef.
11500 2013-04-16 Pedro Alves <palves@redhat.com>
11502 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
11503 (linux-low.o): Delete rule.
11504 * linux-low.h: Always include "gdb_thread_db.h" instead of
11505 conditionally including thread_db.h.
11506 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
11509 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
11511 * Makefile.in (install-only): Fix make install regression.
11513 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
11515 Convert man pages to texinfo, new gdbinit.5 texinfo page.
11516 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
11518 * gdbserver.1: Remove.
11520 2013-03-22 Pedro Alves <palves@redhat.com>
11522 * linux-low.c (handle_extended_wait): Don't call
11523 linux_enable_event_reporting.
11525 2013-03-15 Tony Theodore <tonyt@logyst.com>
11528 * Makefile.in (SHELL): Use @SHELL@.
11530 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
11532 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
11535 2013-03-13 Joel Brobecker <brobecker@adacore.com>
11537 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
11538 Remove extraneous NULL element.
11540 2013-03-13 Yao Qi <yao@codesourcery.com>
11542 * tracepoint.c (traceframe_read_tsv): Look for the last matched
11543 'V' block in trace frame.
11545 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
11547 * target.h (struct target_ops): Add btrace ops.
11548 (target_supports_btrace): New macro.
11549 (target_enable_btrace): New macro.
11550 (target_disable_btrace): New macro.
11551 (target_read_btrace): New macro.
11552 * gdbthread.h (struct thread_info): Add btrace field.
11553 * server.c: Include btrace-common.h.
11554 (handle_btrace_general_set): New function.
11555 (handle_btrace_enable): New function.
11556 (handle_btrace_disable): New function.
11557 (handle_general_set): Call handle_btrace_general_set.
11558 (handle_qxfer_btrace): New function.
11559 (struct qxfer qxfer_packets[]): Add btrace entry.
11560 * inferiors.c (remove_thread): Disable btrace.
11561 * linux-low: Include linux-btrace.h.
11562 (linux_low_enable_btrace): New function.
11563 (linux_low_read_btrace): New function.
11564 (linux_target_ops): Add btrace ops.
11565 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
11566 Add srv_linux_btrace=yes.
11567 (x86_64-*-linux*): Add linux-btrace.o.
11568 Add srv_linux_btrace=yes.
11569 * configure.ac: Define HAVE_LINUX_BTRACE.
11570 * config.in: Regenerated.
11571 * configure: Regenerated.
11573 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
11575 * server.c (handle_qxfer): Preserve error message if -3 is
11577 (qxfer): Document the -3 return value.
11579 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
11581 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
11582 (linux_btrace_h): New variable.
11583 (linux-btrace.o): New rule.
11585 2013-03-08 Stan Shebs <stan@codesourcery.com>
11586 Hafiz Abid Qadeer <abidh@codesourcery.com>
11588 * tracepoint.c (trace_buffer_size): New global.
11589 (DEFAULT_TRACE_BUFFER_SIZE): New define.
11590 (init_trace_buffer): Change to one-argument function. Allocate
11591 trace buffer memory.
11592 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
11593 handle QTBuffer:size packet.
11594 (cmd_bigqtbuffer_size): New function.
11595 (initialize_tracepoint): Call init_trace_buffer with
11596 DEFAULT_TRACE_BUFFER_SIZE.
11597 * server.c (handle_query): Add QTBuffer:size in the
11600 2013-03-07 Yao Qi <yao@codesourcery.com>
11602 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
11603 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
11605 (cmd_qtsp): Adjust condition. Do post increment.
11606 Set cur_action and cur_step_action back to 0.
11608 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
11611 * linux-low.c (linux_write_memory): Return early success if LEN is
11614 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
11616 * configure.srv: Add x86_64-*-cygwin* as target.
11618 2013-02-28 Tom Tromey <tromey@redhat.com>
11620 * configure.ac: Invoke AC_SYS_LARGEFILE.
11621 * configure, config.in: Rebuild.
11623 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
11625 * win32-low.c: Throughout, fix format strings and casts of
11626 printf-like functions to avoid type related warnings on all
11628 (get_child_debug_event): Print dwDebugEventCode as hex since
11629 that's how it's usually documented.
11631 2013-02-28 Yao Qi <yao@codesourcery.com>
11633 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
11636 2013-02-27 Jiong Wang <jiwang@tilera.com>
11638 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
11639 (reg-tilegx32.c): New rule.
11640 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
11641 * linux-tile-low.c (tile_arch_setup): New function. Invoke
11642 different register info initializer according to elf class.
11643 (init_registers_tilgx32): New function. The tilegx32 register info
11645 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
11646 (tile_store_gregset): Likewise.
11648 2013-02-27 Yao Qi <yao@codesourcery.com>
11650 * server.c (process_point_options): Print debug message when
11651 debug_threads is true.
11653 2013-02-26 Yao Qi <yao@codesourcery.com>
11655 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
11657 2013-02-19 Pedro Alves <palves@redhat.com>
11658 Kai Tietz <ktietz@redhat.com>
11662 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
11663 instead of strtoul to extract address from packet.
11664 (process_serial_event) <'z'>: Likewise.
11666 2013-02-18 Yao Qi <yao@codesourcery.com>
11668 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
11670 2013-02-14 Pedro Alves <palves@redhat.com>
11674 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
11675 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
11677 2013-02-14 Pedro Alves <palves@redhat.com>
11679 * tracepoint.c (cmd_qtdpsrc): Use savestring.
11681 2013-02-14 Pedro Alves <palves@redhat.com>
11683 * tracepoint.c (save_string): Delete.
11684 (add_tracepoint_action): Use savestring instead of save_string.
11686 2013-02-12 Pedro Alves <palves@redhat.com>
11688 * linux-xtensa-low.c: Ditto.
11689 * xtensa-xtregs.c: Ditto.
11691 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
11693 * thread-db.c (thread_db_get_tls_address): NULL pointer check
11696 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
11698 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
11699 aarch64_num_wp_regs and aarch64_num_bp_regs to
11700 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
11702 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
11704 * linux-aarch64-low.c (ps_get_thread_area): Replace
11705 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
11707 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
11708 Marcus Shawcroft <marcus.shawcroft@arm.com>
11709 Nigel Stephens <nigel.stephens@arm.com>
11710 Yufeng Zhang <yufeng.zhang@arm.com>
11712 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
11713 (aarch64.c, aarch64-without-fpu.c): New targets.
11714 * configure.srv (aarch64*-*-linux*): New.
11715 * linux-aarch64-low.c: New file.
11717 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
11719 * linux-low.c (handle_extended_wait, linux_create_inferior)
11720 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
11721 (dequeue_one_deferred_signal, linux_resume_one_thread)
11722 (fetch_register, linux_write_memory, linux_enable_event_reporting)
11723 (linux_tracefork_grandchild, linux_test_for_tracefork)
11724 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
11725 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
11726 where the argument is 0.
11728 2013-01-25 Yao Qi <yao@codesourcery.com>
11730 * event-loop.c: Include "queue.h".
11731 (gdb_event_p): New typedef.
11732 (struct gdb_event) <next_event>: Remove.
11733 (event_queue): Change to QUEUE(gdb_event_p).
11734 (async_queue_event): Remove.
11735 (gdb_event_xfree): New.
11736 (initialize_event_loop): New.
11737 (process_event): Use API from QUEUE.
11738 (wait_for_event): Likewise.
11739 * server.c (main): Call initialize_event_loop.
11740 * server.h (initialize_event_loop): Declare.
11742 2013-01-18 Yao Qi <yao@codesourcery.com>
11744 * ax.h (struct eval_agent_expr_context): New.
11745 (gdb_eval_agent_expr): Update declaration.
11746 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
11747 TFRAME. Add new argument CTX.
11748 * server.h (struct eval_agent_expr_context): Declare.
11749 (agent_mem_read, agent_tsv_read): Update declaration.
11750 (agent_mem_read_string): Likewise.
11751 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
11752 (add_traceframe_block): Add new argument TPOINT.
11753 Increase TPOINT->traceframe_usage.
11754 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
11755 eval_tracepoint_agent_expr.
11756 (condition_true_at_tracepoint): Likewise.
11757 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
11758 (agent_mem_read_string, agent_tsv_read): Likewise.
11760 2013-01-16 Yao Qi <yao@codesourcery.com>
11762 * linux-low.c (linux_resume_one_lwp): Don't check
11763 'lwp->bp_reinsert != 0'.
11765 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11766 Pedro Alves <palves@redhat.com>
11768 * lynx-low.c (ptrace_request_to_str): Define a temporary
11769 macro and use it to simplify this function's implementation.
11771 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11773 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
11776 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11778 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
11780 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11782 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
11784 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11786 * lynx-low.c (lynx_resume): Use the resume_info parameter
11787 to determine the ptid for the lynx_ptrace call, unless
11788 it is equal to minus_one_ptid, in which case we use the
11789 ptid of the current_inferior.
11790 (lynx_wait_1): After having received a thread create/exit
11791 event, resume the inferior's execution using the signaling
11792 thread's ptid, rather than the old ptid.
11794 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11796 * lynx-low.c (lynx_resume): Delete variable ret.
11798 2013-01-01 Joel Brobecker <brobecker@adacore.com>
11800 * gdbreplay.c (gdbreplay_version): Update copyright year.
11801 * server.c (gdbserver_version): Likewise.
11803 2012-12-17 Joel Brobecker <brobecker@adacore.com>
11805 * lynx-low.c (lynx_wait_1): Add debug trace before adding
11808 2012-12-17 Joel Brobecker <brobecker@adacore.com>
11810 * lynx-low.c (ptrace_request_to_str): Add handling for
11811 PTRACE_GETTRACESIG.
11813 2012-12-17 Joel Brobecker <brobecker@adacore.com>
11815 * lynx-low.c (lynx_attach): Delete variable new_process.
11817 2012-12-17 Joel Brobecker <brobecker@adacore.com>
11819 * lynx-low.c (lynx_create_inferior): Delete variable
11822 2012-12-17 Joel Brobecker <brobecker@adacore.com>
11824 * lynx-low.c (ptrace_request_to_str): Do not handle
11825 PTRACE_GETTHREADLIST if this macro does not exist.
11827 2012-12-15 Yao Qi <yao@codesourcery.com>
11829 * Makefile.in (OBS): Add notif.o.
11830 * notif.c, notif.h: New.
11831 * server.c: Include "notif.h".
11832 (struct vstop_notif) <next>: Remove.
11834 (queue_stop_reply): Update.
11835 (push_event, send_next_stop_reply): Remove.
11836 (discard_queued_stop_replies): Update.
11837 (notif_stop): New variable.
11838 (handle_v_stopped): Remove.
11839 (handle_v_requests): Don't call handle_v_stopped. Call
11840 handle_ack_notif instead.
11841 (queue_stop_reply_callback): Call notif_event_enque instead
11842 of queue_stop_reply.
11843 (handle_status): Don't call send_next_stop_reply, call
11844 notif_write_event instead.
11845 (kill_inferior_callback): Likewise.
11846 (detach_or_kill_inferior_callback): Likewise.
11847 (main): Call initialize_notif.
11848 (process_serial_event): Call QUEUE_is_empty.
11849 (handle_target_event): Call notif_push instead of push event.
11850 * server.h (push_event): Remove declaration.
11852 2012-12-10 Tom Tromey <tromey@redhat.com>
11854 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
11855 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
11858 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
11859 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
11860 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
11861 (amd64-linux-ipa.o, ax.o): Rewrite.
11862 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
11863 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
11864 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
11865 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
11866 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
11867 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
11868 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
11869 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
11870 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
11871 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
11872 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
11873 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
11874 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
11875 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
11876 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
11877 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
11878 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
11879 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
11880 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
11881 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
11882 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
11883 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
11884 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
11885 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
11886 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
11887 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
11888 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
11889 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
11890 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
11891 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
11892 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
11893 (reg-tilegx.o): Remove.
11894 (all_object_files): New macro.
11895 Include .deps files.
11896 * aclocal.m4, configure: Rebuild.
11897 * acinclude.m4: Include depstand.m4, lead-dot.m4.
11898 * configure.ac: Invoke ZW_CREATE_DEPDIR,
11899 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
11901 2012-12-05 Tom Tromey <tromey@redhat.com>
11904 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
11906 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
11908 * configure.ac: Check for linux/perf_event.h.
11909 * config.in: Regenerated.
11910 * configure: Regenerated.
11912 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
11914 * hostio.c (handle_readlink): Decrease buffer size
11915 parameter passed to readlink by one byte.
11917 2012-11-26 Yao Qi <yao@codesourcery.com>
11919 * configure.ac (build_warnings): Append '-Wempty-body'.
11920 * configure: Regenerated.
11921 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
11924 2012-11-15 Pierre Muller <muller@sourceware.org>
11926 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
11927 * config.in: Regenerate.
11928 * configure: Regenerate.
11929 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
11930 Use "gdb_wait.h" header instead of <sys/wait.h> header.
11931 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
11932 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
11934 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
11935 instead of <sys/wait.h> header.
11936 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
11938 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
11940 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
11941 (various make rules): Remove -DGDBSERVER
11943 2012-11-09 Yao Qi <yao@codesourcery.com>
11945 * spu-low.c (current_ptid): Move it to ..
11946 * gdbthread.h: ... here. New.
11947 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
11948 * server.c (myresume, process_serial_event): Likewise.
11949 * thread-db.c (thread_db_find_new_threads): Likewise.
11950 * tracepoint.c (run_inferior_command): Likewise.
11952 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
11954 * server.c (handle_search_memory_1): Include access length in
11957 2012-09-05 Michael Brandt <michael.brandt@axis.com>
11959 * linux-crisv32-low.c: Fix compile errors.
11961 2012-09-04 Yao Qi <yao@codesourcery.com>
11963 * tracepoint.c (cmd_qtsv): Adjust debug message.
11964 Don't check CUR_TPOINT.
11966 2012-08-28 Yao Qi <yao@codesourcery.com>
11968 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
11969 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
11970 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
11971 Remove declarations of xmalloc, xreallloc, xstrdup and
11973 * Makefile.in (libiberty_h): New.
11974 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
11975 (linux-bfin-low.o): Append dependency 'libiberty.h'.
11977 2012-08-23 Yao Qi <yao@codesourcery.com>
11979 * server.h: Remove declaration of 'xsnprintf'.
11981 2012-08-22 Keith Seitz <keiths@redhat.com>
11983 * server.h: Include build-gnulib-gbserver/config.h.
11984 * gdbreplay.c: Likewise.
11986 2012-08-08 Doug Evans <dje@google.com>
11988 * Makefile.in (SFILES): Add gdb_vecs.c.
11989 (OBS): Add gdb_vecs.o.
11990 (gdb_vecs_h, host_defs_h): New variables.
11991 (thread-db.o): Add $(gdb_vecs_h) dependency.
11992 (gdb_vecs.o): New rule.
11993 * thread-db.c: #include "gdb_vecs.h".
11994 (thread_db_load_search): Use a vector to iterate over path elements.
11995 Handle text appearing after "$pdir".
11997 * configure.ac: Add check for strstr.
11998 * config.in: Regenerate.
11999 * configure: Regenerate.
12001 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
12003 * hostio.c (handle_pread): If pread fails, fall back to attempting
12005 (handle_pwrite): Likewise for pwrite.
12007 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
12009 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
12010 between unsupported TYPE and unimplementable ADDR/LEN combination.
12011 (arm_insert_point): Act on new return value.
12013 2012-07-31 Pedro Alves <palves@redhat.com>
12015 * server.c (process_point_options): Only skip tokens if we find
12016 one that is unrecognized. Don't treat 'X' specially while
12017 skipping unrecognized tokens.
12019 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
12021 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
12022 to 4-byte-align HW breakpoint addresses for Thumb.
12024 2012-07-27 Yao Qi <yao@codesourcery.com>
12028 * server.h: Declare gdb_agent_about_to_close.
12029 * target.c (kill_inferior): Include "agent.h".
12030 New. Send command 'kill'.
12031 * target.h (kill_inferior): Removed macro.
12032 * tracepoint.c (gdb_agent_about_to_close): New.
12033 (gdb_agent_helper_thread): Handle command 'close'.
12034 Wait endlessly until the inferior stops.
12035 Install gdb_agent_remove_socket to atexit hook.
12036 (agent_socket_name): New static variable.
12037 (gdb_agent_socket_init): Replace local variable 'name' with
12038 'agent_socket_name'.
12039 (gdb_agent_remove_socket): New.
12041 2012-07-27 Yao Qi <yao@codesourcery.com>
12043 * server.c (process_point_options): Stop at 'X' when parsing.
12045 2012-07-19 Michael Eager <eager@eagercon.com>
12047 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
12049 * linux-x86-low.c (x86_insert_point, x86_remove_point):
12050 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
12051 hardware breakpoint.
12053 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
12055 * gdbserver/linux-low.c (initialize_low): Call
12056 linux_ptrace_init_warnings.
12058 2012-07-02 Doug Evans <dje@google.com>
12060 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
12063 2012-07-02 Stan Shebs <stan@codesourcery.com>
12065 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
12066 (ax.o): Add it to build rule.
12068 (OBS): Add format.o.
12069 (IPA_OBS): Add format.o.
12070 * server.c (handle_query): Claim support for breakpoint commands.
12071 (process_point_options): Add command case.
12072 (process_serial_event): Leave running if there are printfs in
12074 * mem-break.h (any_persistent_commands): Declare.
12075 (add_breakpoint_commands): Declare.
12076 (gdb_no_commands_at_breakpoint): Declare.
12077 (run_breakpoint_commands): Declare.
12078 * mem-break.c (struct point_command_list): New struct.
12079 (struct breakpoint): New field command_list.
12080 (any_persistent_commands): New function.
12081 (add_commands_to_breakpoint): New function.
12082 (add_breakpoint_commands): New function.
12083 (gdb_no_commands_at_breakpoint): New function.
12084 (run_breakpoint_commands): New function.
12085 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
12087 * ax.c: Include format.h.
12088 (ax_printf): New function.
12089 (gdb_eval_agent_expr): Add printf opcode.
12091 2012-06-13 Yao Qi <yao@codesourcery.com>
12093 * server.c (start_inferior): Remove duplicated writes to fields
12094 'last_resume_kind' and 'last_status' of 'current_inferior'.
12096 2012-06-12 Yao Qi <yao@codesourcery.com>
12097 Pedro Alves <palves@redhat.com>
12099 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
12101 * server.c (handle_v_cont): Extend comment.
12103 2012-06-11 Yao Qi <yao@codesourcery.com>
12105 * linux-low.c (linux_attach): Add 'static'.
12107 2012-06-06 Yao Qi <yao@codesourcery.com>
12109 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
12111 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
12113 Fix gcc -flto compilation warning.
12114 * server.c (main): Make variable multi_mode and attach volatile.
12116 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
12118 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
12119 if the platform doesn't know about it.
12121 2012-05-30 Jeff Kenton <jkenton@tilera.com>
12123 * Makefile.in (SFILES): Add linux-tile-low.c.
12124 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
12125 * configure.srv: Handle tilegx-*-linux*.
12126 * linux-tile-low.c: New file.
12128 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12130 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
12132 2012-05-24 Pedro Alves <palves@redhat.com>
12136 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
12138 2012-05-24 Pedro Alves <palves@redhat.com>
12142 Replace target_signal with gdb_signal throughout.
12144 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
12146 * linux-low.c (linux_store_registers): Avoid the copying sequence
12147 when no data has been retrieved by ptrace.
12149 2012-05-22 Will Deacon <will.deacon@arm.com>
12151 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
12152 Include asm/ptrace.h.
12153 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
12156 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
12158 * linux-low.c (linux_store_registers): Don't re-retrieve data
12159 with ptrace that has already been obtained from /proc. Always
12160 copy any data retrieved with ptrace to the buffer supplied.
12162 2012-05-11 Yao Qi <yao@codesourcery.com>
12163 Pedro Alves <palves@redhat.com>
12165 * linux-low.c (enum stopping_threads_kind): New.
12166 (stopping_threads): Change type to `enum stopping_threads_kind'.
12167 (handle_extended_wait): If stopping and suspending threads, leave
12168 the new_lwp suspended too.
12169 (linux_wait_for_event): Adjust.
12170 (stop_all_lwps): Set `stopping_threads' to
12171 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
12172 whether we're suspending threads or just stopping them. Assert no
12175 2012-04-29 Yao Qi <yao@codesourcery.com>
12177 * server.h: Move some code to ...
12178 * gdbthread.h: ... here. New.
12179 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
12180 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
12181 (nto-low.o, win32-low.o): Likewise.
12182 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
12183 * regcache.c, remote-utils.c, server.c: Likewise.
12184 * target.c, tracepoint.c, win32-low.c: Likewise.
12186 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
12188 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
12189 (PTRACE_ARG4_TYPE): Likewise.
12190 (PTRACE_XFER_TYPE): Likewise.
12191 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
12192 ptrace to PTRACE_ARG3_TYPE.
12193 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
12194 (PTRACE_ARG4_TYPE): Likewise.
12195 (PTRACE_XFER_TYPE): Likewise.
12196 (linux_detach_one_lwp): Cast fourth argument of
12197 ptrace to long then PTRACE_ARG4_TYPE.
12198 (regsets_fetch_inferior_registers): Cast third argument of
12199 ptrace to long then PTRACE_ARG3_TYPE.
12200 (regsets_store_inferior_registers): Likewise.
12202 2012-04-20 Pedro Alves <palves@redhat.com>
12204 * configure: Regenerate.
12206 2012-04-19 Pedro Alves <palves@redhat.com>
12208 * Makefile.in (GNULIB_BUILDDIR): New.
12209 (LIBGNU, INCGNU, GNULIB_H): Adjust.
12210 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
12211 (all, install-only, uninstall, clean-info, all-lib, clean): No
12212 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
12213 (maintainer-clean realclean distclean): Use subdir_do.
12215 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
12216 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
12217 * acinclude.m4: Include acx_configure_dir.m4.
12218 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
12219 calls. Call AC_PROG_RANLIB. Configure gnulib using
12222 (GNULIB_STDINT_H): Adjust.
12223 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
12224 * gdbreplay.c: Include build-gnulib/config.h.
12225 * server.h: Likewise.
12226 * aclocal.m4: Regenerate.
12227 * config.in: Regenerate.
12228 * configure: Regenerate.
12230 2012-04-19 Pedro Alves <palves@redhat.com>
12232 * Makefile.in (LIBGNU, INCGNU): Adjust.
12233 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
12234 (all, install-only, uninstall, clean-info, all-lib, clean)
12235 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
12236 * configure.ac: Adjust AC_OUTPUT output.
12237 * aclocal.m4: Regenerate.
12238 * configure: Regenerate.
12240 2012-04-19 Pedro Alves <palves@redhat.com>
12242 * Makefile.in (generated_files): New.
12243 (server_h): Remove the explicit dependency on config.h, and depend
12244 on $generated_files.
12246 2012-04-19 Pedro Alves <palves@redhat.com>
12248 * Makefile.in (INCGNU): Add -Ignulib.
12250 2012-04-19 Pedro Alves <palves@redhat.com>
12252 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
12253 (INCGNU): ... this, and spell out -I here.
12254 (GNULIB_LIB): Rename to ...
12255 (LIBGNU): ... this.
12256 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
12258 2012-04-19 Pedro Alves <palves@redhat.com>
12260 * config.in: Regenerate.
12262 2012-04-19 Pedro Alves <palves@redhat.com>
12264 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
12265 * server.h (memmem): Remove declaration.
12266 * config.in: Regenerate.
12267 * configure: Regenerate.
12269 2012-04-19 Yao Qi <yao@codesourcery.com>
12271 * Makefile.in (SFILES): Add common/vec.c.
12275 2012-04-19 Yao Qi <yao@codesourcery.com>
12277 * remote-utils.c (prepare_resume_reply): Replace with macro
12278 target_core_of_thread.
12279 * server.c (handle_qxfer_threads_proper): Likewise.
12280 * target.h (traget_core_of_thread): New macro.
12282 2012-04-18 Pedro Alves <palves@redhat.com>
12284 * aclocal.m4: Regenerate.
12285 * configure: Regenerate.
12287 2012-04-16 Yao Qi <yao@codesourcery.com>
12289 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
12290 duplicated on address.
12292 2012-04-16 Yao Qi <yao@codesourcery.com>
12294 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
12295 (struct tracepoint_action_ops) <send>: New field.
12296 (m_tracepoint_action_send, r_tracepoint_action_send): New.
12297 (agent_expr_send, x_tracepoint_action_send): New.
12298 (l_tracepoint_action_send): New.
12299 (cmd_qtdp): Download and install tracepoint
12300 according to `use_agent'.
12301 (run_inferior_command): Add one more parameter `len'.
12303 (tracepoint_send_agent): New.
12304 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
12306 2012-04-16 Yao Qi <yao@codesourcery.com>
12308 * tracepoint.c (download_tracepoints): Moved to ...
12309 (cmd_qtstart): ... here.
12311 2012-04-14 Yao Qi <yao@codesourcery.com>
12313 * tracepoint.c: Include inttypes.h.
12314 (struct collect_memory_action): Use sized types.
12315 (struct tracepoint): Likewise.
12316 (cmd_qtdp, stop_tracing): Update print specifiers.
12317 (cmd_qtp, response_tracepoint): Likewise.
12318 (collect_data_at_tracepoint): Likewise.
12319 (collect_data_at_step): Likewise.
12321 2012-04-14 Yao Qi <yao@codesourcery.com>
12323 Import gnulib module inttypes.
12324 * aclocal.m4, config.in, configure: Regenerated.
12326 2012-04-14 Yao Qi <yao@codesourcery.com>
12328 * Makefile.in (maintainer-clean, realclean, distclean): Remove
12329 Makefile and config.status at last.
12331 2012-04-13 Yao Qi <yao@codesourcery.com>
12333 * tracepoint.c: Include stdint.h unconditionally.
12335 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
12337 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
12338 on BFD_HAVE_SYS_PROCFS_TYPE.
12339 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
12340 * configure: Regenerate.
12341 * config.in: Likewise.
12343 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
12345 * Makefile.in (clean): Also remove x32.c x32-linux.c
12346 x32-avx.c x32-avx-linux.c.
12347 (x32.o): New target.
12349 (x32-linux.o): Likewise.
12350 (x32-linux.c): Likewise.
12351 (x32-avx.o): Likewise.
12352 (x32-avx.c): Likewise.
12353 (x32-avx-linux.o): Likewise.
12354 (x32-avx-linux.c): Likewise.
12356 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
12357 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
12358 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
12359 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
12360 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
12361 i386/x32-avx-linux.xml.
12363 * linux-x86-low.c (init_registers_x32_linux): New prototype.
12364 (init_registers_x32_avx_linux): Likwise.
12365 (x86_linux_update_xmltarget): Call init_registers_x32_linux
12366 or init_registers_x32_avx_linux if linux_is_elf64 is false.
12368 2012-04-13 Pedro Alves <palves@redhat.com>
12370 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
12371 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
12372 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
12373 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
12376 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
12378 * linux-x86-low.c (compat_x32_clock_t): New.
12379 (compat_x32_siginfo_t): Likewise.
12380 (compat_x32_siginfo_from_siginfo): Likewise.
12381 (siginfo_from_compat_x32_siginfo): Likewise.
12382 (linux_is_elf64): Likewise.
12383 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
12384 and siginfo_from_compat_x32_siginfo for x32.
12385 (x86_arch_setup): Set linux_is_elf64.
12387 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
12390 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
12392 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
12393 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
12394 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
12395 compatible with process.
12397 2012-04-12 Yao Qi <yao@codesourcery.com>
12399 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
12400 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
12401 (install-only, install-info, clean): Handle sub dir gnulib.
12402 (all-lib, am--refresh): New targets.
12403 (memmem.o): Remove target.
12404 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
12405 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
12406 (AC_REPLACE_FUNCS): Remove memmem.
12407 Invoke gl_INIT and AM_INIT_AUTOMAKE.
12408 (AC_OUTPUT): Generate Makefile in gnulib/.
12409 * aclocal.m4, config.in, configure: Regenerated.
12411 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
12413 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
12415 2012-04-05 Pedro Alves <palves@redhat.com>
12417 -Werror=strict-aliasing
12419 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
12422 2012-04-04 Pedro Alves <palves@redhat.com>
12424 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
12425 (sparc_store_gregset_from_stack, sparc_store_gregset)
12426 (sparc_breakpoint_at): Fix formatting.
12428 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
12430 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
12432 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
12433 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
12434 * config.in: Regenerate.
12435 * configure: Likewise.
12437 2012-03-29 Pedro Alves <palves@redhat.com>
12439 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
12440 Correct ptrace arguments.
12442 2012-03-28 Pedro Alves <palves@redhat.com>
12444 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
12445 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
12446 (IA64_FR1_REGNUM): New defines.
12447 (ia64_fetch_register): New.
12448 (the_low_target): Install it.
12449 * linux-low.h (struct linux_target_ops) <fetch_register>: New
12451 * linux-low.c (linux_fetch_registers): Try the
12452 the_low_target.fetch_register hook first.
12454 * linux-arm-low.c (the_low_target): Adjust.
12455 * linux-bfin-low.c (the_low_target): Adjust.
12456 * linux-cris-low.c (the_low_target): Adjust.
12457 * linux-crisv32-low.c (the_low_target): Adjust.
12458 * linux-m32r-low.c (the_low_target): Adjust.
12459 * linux-m68k-low.c (the_low_target): Adjust.
12460 * linux-mips-low.c (the_low_target): Adjust.
12461 * linux-ppc-low.c (the_low_target): Adjust.
12462 * linux-s390-low.c (the_low_target): Adjust.
12463 * linux-sh-low.c (the_low_target): Adjust.
12464 * linux-sparc-low.c (the_low_target): Adjust.
12465 * linux-tic6x-low.c (the_low_target): Adjust.
12466 * linux-x86-low.c (the_low_target): Adjust.
12467 * linux-xtensa-low.c (the_low_target): Adjust.
12469 2012-03-26 Pedro Alves <palves@redhat.com>
12471 * server.c (handle_qxfer_libraries): Don't bail early if
12472 the_target->qxfer_libraries_svr4 is not NULL.
12474 2012-03-26 Pedro Alves <palves@redhat.com>
12476 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
12478 2012-03-23 Pedro Alves <palves@redhat.com>
12480 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
12481 "library-list-svr4" element's start tag when the the DSO list is
12484 2012-03-23 Pedro Alves <palves@redhat.com>
12486 * linux-low.c (read_one_ptr): Read the inferior's pointer through
12487 a variable whose type size is the same as the inferior's pointer
12490 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
12492 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
12494 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
12495 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
12496 * linux-low.h: Include <signal.h>.
12497 (struct siginfo): Remove forward declaration.
12498 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
12501 2012-03-21 Mike Frysinger <vapier@gentoo.org>
12503 * .gitignore: Ignore more files.
12505 2012-03-19 Pedro Alves <palves@redhat.com>
12506 Jan Kratochvil <jan.kratochvil@redhat.com>
12508 * server.c (cont_thread, general_thread): Add describing comments.
12509 (start_inferior): Clear `cont_thread'.
12510 (handle_v_cont): Don't set `cont_thread' if resuming all threads
12513 2012-03-15 Yao Qi <yao@codesourcery.com>
12515 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
12517 (cmd_qtdp): ... here.
12519 2012-03-15 Yao Qi <yao@codesourcery.com>
12521 * tracepoint.c (struct tracepoint_action_ops): New.
12522 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
12523 (m_tracepoint_action_download): New.
12524 (r_tracepoint_action_download): New.
12525 (x_tracepoint_action_download): New.
12526 (l_tracepoint_action_download): New.
12527 (add_tracepoint_action): Install `action->ops' according type.
12528 (download_tracepoint_1): Move code `download' function pointer
12529 of various tracepoint_action_ops.
12531 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
12533 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
12534 linux_ptrace_attach_warnings.
12536 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
12538 * Makefile.in (linux-ptrace.o): New.
12539 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
12540 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
12541 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
12542 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
12543 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
12545 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
12547 2012-03-08 Yao Qi <yao@codesourcery.com>
12548 Pedro Alves <palves@redhat.com>
12550 Fix PR server/13392.
12551 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
12552 offset of JMP insn.
12553 * tracepoint.c (remove_tracepoint): New.
12554 (cmd_qtdp): Call remove_tracepoint when failed to install.
12556 2012-03-07 Pedro Alves <palves@redhat.com>
12558 * linux-low.c (get_detach_signal): New.
12559 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
12560 Pass on pending signals to PTRACE_DETACH. Check the result of the
12562 * server.c (program_signals, program_signals_p): New.
12563 (handle_general_set): Handle QProgramSignals.
12564 * server.h (program_signals, program_signals_p): Declare.
12566 2012-03-05 Pedro Alves <palves@redhat.com>
12567 Jan Kratochvil <jan.kratochvil@redhat.com>
12569 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
12572 2012-03-03 Yao Qi <yao@codesourcery.com>
12574 * tracepoint.c (tracepoint_look_up_symbols): Update call to
12575 agent_look_up_symbols.
12577 2012-03-03 Yao Qi <yao@codesourcery.com>
12579 * Makefile.in (linux-low.o): Keep dependence on agent.h.
12580 (linux-x86-low.o): Likewise.
12581 * server.h: Remove in_process_agent_loaded.
12582 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
12586 2012-03-03 Yao Qi <yao@codesourcery.com>
12588 * tracepoint.c (gdb_agent_capability): New global.
12589 (in_process_agent_loaded_ust): Renamed to
12590 `in_process_agent_supports_ust'.
12592 (in_process_agent_supports_ust): Call agent_capability_check.
12593 (clear_installed_tracepoints): Assert that agent supports
12596 2012-03-03 Yao Qi <yao@codesourcery.com>
12598 * linux-low.c (linux_supports_agent): New.
12599 (linux_target_ops): Initialize field `supports_agent' with
12600 linux_supports_agent.
12601 * target.h (struct target_ops) <supports_agent>: New.
12602 (target_supports_agent): New macro.
12603 * server.c (handle_general_set): Handle packet 'QAgent'.
12604 (handle_query): Send `QAgent+'.
12605 * Makefile.in (server.o): Depends on agent.h.
12607 2012-03-03 Yao Qi <yao@codesourcery.com>
12609 * Makefile.in (OBS): Add agent.o.
12610 Add new rule for agent.o.
12611 Track dependence of tracepoint.c on agent.h.
12612 * tracepoint.c (run_inferior_command_1):
12613 (run_inferior_command): Call agent_run_command.
12614 (gdb_ust_connect_sync_socket): Deleted. Move it to
12616 (resume_thread, stop_thread): Likewise.
12617 (gdb_ust_socket_init): Renamed to ...
12618 (gdb_agent_socket_init): ... New.
12619 (gdb_ust_thread): Renamed to ...
12620 (gdb_agent_helper_thread): ... New.
12621 (gdb_ust_init): Move some code to ...
12622 (gdb_agent_init): ... here. New.
12623 [HAVE_UST]: Call gdb_ust_init.
12624 (initialize_tracepoint_ftlib): Call gdb_agent_init.
12625 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
12626 * config.in, configure: Regenerated.
12628 2012-03-02 Pedro Alves <palves@redhat.com>
12630 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
12631 * linux-low.c (struct simple_pid_list): New.
12632 (stopped_pids): New a struct simple_pid_list pointer.
12633 (add_to_pid_list, pull_pid_from_list): New.
12634 (handle_extended_wait): Don't assume the first signal new children
12635 report is SIGSTOP. Adjust call to pull_pid_from_list.
12636 (linux_wait_for_lwp): Adjust.
12638 2012-03-02 Yao Qi <yao@codesourcery.com>
12640 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
12643 2012-03-02 Yao Qi <yao@codesourcery.com>
12645 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
12646 `stop_pc' and `tpoint'. Update caller.
12648 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
12650 * linux-low.h (linux_target_ops): Add regset_bitmap member.
12651 * linux-low.c (use_linux_regsets): New macro.
12652 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
12653 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
12654 (linux_register_in_regsets): New function.
12655 (usr_fetch_inferior_registers): Skip registers covered by
12657 (usr_store_inferior_registers): Likewise.
12658 (usr_fetch_inferior_registers): New macro.
12659 (usr_store_inferior_registers): Likewise.
12660 (linux_fetch_registers): Handle mixed regset/non-regset targets.
12661 (linux_store_registers): Likewise.
12662 * linux-mips-low.c (init_registers_mips_dsp_linux): New
12664 (init_registers_mips64_dsp_linux): Likewise.
12665 (init_registers_mips_linux): New macro.
12666 (init_registers_mips_dsp_linux): Likewise.
12667 (mips_dsp_num_regs): Likewise.
12668 (DSP_BASE, DSP_CONTROL): New fallback macros.
12669 (mips_base_regs): New macro.
12670 (mips_regmap): Use it. Fix the size.
12671 (mips_dsp_regmap): New variable.
12672 (mips_dsp_regset_bitmap): Likewise.
12673 (mips_arch_setup): New function.
12674 (mips_cannot_fetch_register): Use the_low_target.regmap rather
12676 (mips_cannot_store_register): Likewise.
12677 (the_low_target): Update .arch_setup, .num_regs and .regmap
12678 initializers. Add .regset_bitmap initializer.
12679 * linux-arm-low.c (the_low_target): Add .regset_bitmap
12681 * linux-bfin-low.c (the_low_target): Likewise.
12682 * linux-cris-low.c (the_low_target): Likewise.
12683 * linux-crisv32-low.c (the_low_target): Likewise.
12684 * linux-ia64-low.c (the_low_target): Likewise.
12685 * linux-m32r-low.c (the_low_target): Likewise.
12686 * linux-m68k-low.c (the_low_target): Likewise.
12687 * linux-ppc-low.c (the_low_target): Likewise.
12688 * linux-s390-low.c (the_low_target): Likewise.
12689 * linux-sh-low.c (the_low_target): Likewise.
12690 * linux-sparc-low.c (the_low_target): Likewise.
12691 * linux-tic6x-low.c (the_low_target): Likewise.
12692 * linux-x86-low.c (the_low_target): Likewise.
12693 * linux-xtensa-low.c (the_low_target): Likewise.
12694 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
12695 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
12696 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
12698 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
12699 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
12701 2012-02-29 Yao Qi <yao@codesourcery.com>
12702 Pedro Alves <palves@redhat.com>
12704 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
12705 `step_over_finished' is true.
12707 2012-02-27 Pedro Alves <palves@redhat.com>
12709 * linux-low.c (pid_is_stopped): Delete, moved to common/.
12710 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
12712 2012-02-27 Pedro Alves <palves@redhat.com>
12715 * linux-low.c (pid_is_stopped): New.
12716 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
12718 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
12720 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
12723 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
12725 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
12727 2012-02-24 Luis Machado <lgustavo@codesourcery>
12729 * server.c (handle_query): Advertise support for target-side
12730 breakpoint condition evaluation.
12731 (process_point_options): New function.
12732 (process_serial_event): When inserting a breakpoint, check for
12733 a target-side condition that should be evaluated.
12735 * mem-break.c: Include regcache.h and ax.h.
12736 (point_cond_list_t): New data structure.
12737 (breakpoint) <cond_list>: New field.
12738 (find_gdb_breakpoint_at): Make non-static.
12739 (delete_gdb_breakpoint_at): Clear any target-side
12741 (clear_gdb_breakpoint_conditions): New function.
12742 (add_condition_to_breakpoint): Likewise.
12743 (add_breakpoint_condition): Likewise.
12744 (gdb_condition_true_at_breakpoint): Likewise.
12745 (gdb_breakpoint_here): Return result directly instead
12746 of going through a local variable.
12748 * mem-break.h (find_gdb_breakpoint_at): New prototype.
12749 (clear_gdb_breakpoint_conditions): Likewise.
12750 (add_breakpoint_condition): Likewise.
12751 (gdb_condition_true_at_breakpoint): Likewise.
12753 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
12754 (need_step_over_p): Take target-side breakpoint condition into
12757 2012-02-24 Luis Machado <lgustavo@codesourcery>
12759 * server.h: Include tracepoint.h.
12760 (agent_mem_read, agent_get_trace_state_variable_value,
12761 agent_set_trace_state_variable_value,
12762 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
12763 get_set_tsv_func_addr): New prototypes.
12765 * ax.h: New include file.
12766 * ax.c: New source file.
12768 * tracepoint.c: Include ax.h.
12769 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
12770 agent_expr, eval_result_type): Move to ax.h.
12771 (parse_agent_expr): Rename to ...
12772 (gdb_parse_agent_expr): ... this, make it non-static and move
12774 (unparse_agent_expr) Rename to ...
12775 (gdb_unparse_agent_expr): ... this, make it non-static and move
12777 (eval_agent_expr): Rename to ...
12778 (eval_tracepoint_agent_expr): ... this.
12779 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
12780 forward declarations.
12781 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
12782 (agent_get_trace_state_variable_value): New function.
12783 (agent_set_trace_state_variable_value): New function.
12784 (cmd_qtdp): Call gdb_parse_agent_expr (...).
12785 (response_tracepoint): Call gdb_unparse_agent_expr (...).
12786 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
12787 (condition_true_at_tracepoint): Likewise.
12788 (parse_agent_expr): Rename to ...
12789 (gdb_parse_agent_expr): ... this and move to ax.c.
12790 (unparse_agent_expr): Rename to ...
12791 (gdb_unparse_agent_expr): ... this and move to ax.c.
12792 (gdb_agent_op_name): Move to ax.c.
12793 (eval_agent_expr): Rename to ...
12794 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
12796 (eval_tracepoint_agent_expr): New function.
12797 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
12799 (current_insn_ptr, emit_error, struct bytecode_address): Move to
12801 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
12802 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
12803 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
12804 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
12805 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
12806 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
12807 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
12808 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
12809 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
12810 (compile_bytecodes): Remove forward declaration.
12811 (is_goto_target): Move to ax.c.
12812 (compile_bytecodes): Move to ax.c and call
12813 agent_get_trace_state_variable_value (...) and
12814 agent_set_trace_state_variable_value (...).
12816 * Makefile.in: Update ax.c and IPA dependencies.
12818 2012-02-24 Pedro Alves <palves@redhat.com>
12820 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
12821 (cmd_bigqtbuffer_circular): ... this. Only handle
12822 'QTBuffer:circular:'.
12823 (handle_tracepoint_general_set): Adjust.
12825 2012-02-16 Yao Qi <yao@codesourcery.com>
12827 * inferiors.c: Move code to ...
12828 * dll.c: .... here. New.
12829 * server.h: Declare clear_dlls.
12830 * Makefile.in (SFILES): Add dll.c.
12834 2012-02-11 Yao Qi <yao@codesourcery.com>
12836 * server.c: (handle_monitor_command): Add a new parameter
12838 (handle_query): Update caller.
12840 2012-02-09 Joel Brobecker <brobecker@adacore.com>
12842 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
12843 * configure, config.in: Regenerate.
12844 * hostio.c: Provide an alternate implementation if HAVE_READLINK
12847 2012-02-02 Pedro Alves <palves@redhat.com>
12849 Try SIGKILL first, then PTRACE_KILL.
12850 * linux-low.c (linux_kill_one_lwp): New.
12851 (linux_kill_one_lwp): Rename to ...
12852 (kill_one_lwp_callback): ... this. Use the new
12853 linux_kill_one_lwp.
12855 2012-02-02 Pedro Alves <palves@redhat.com>
12857 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
12860 2012-01-27 Pedro Alves <palves@redhat.com>
12862 * linux-low.c (linux_child_pid_to_exec_file): Delete.
12863 (elf_64_file_p): Make static.
12864 (linux_pid_exe_is_elf_64_file): New.
12865 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
12866 Delete declarations.
12867 (linux_pid_exe_is_elf_64_file): Declare.
12868 * linux-x86-low.c (x86_arch_setup): Use
12869 linux_pid_exe_is_elf_64_file.
12871 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
12873 * linux-low.c (linux_wait_for_event_1): Rename to ...
12874 (linux_wait_for_event): ... here and merge it with former
12875 linux_wait_for_event - new variable wait_ptid, use it.
12876 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
12878 2012-01-23 Pedro Alves <palves@redhat.com>
12880 * server.c (main): Avoid yet another case of infinite loop while
12881 detaching/killing after a longjmp.
12883 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12886 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
12888 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
12890 * hostio.c (handle_readlink): New function.
12891 (handle_vFile): Call it to handle "vFile:readlink" packets.
12893 2012-01-20 Pedro Alves <palves@redhat.com>
12894 Ulrich Weigand <ulrich.weigand@linaro.org>
12896 * server.c (handle_v_requests): Only support vAttach and vRun to
12897 start multiple processes when in extended protocol mode.
12899 2012-01-17 Pedro Alves <palves@redhat.com>
12901 * tracepoint.c (initialize_tracepoint): Use mmap instead of
12902 memalign plus mprotect to allocate the scratch buffer.
12904 2012-01-13 Pedro Alves <palves@redhat.com>
12906 * server.c (attach_inferior): Clear `cont_thread'.
12908 2012-01-13 Pedro Alves <palves@redhat.com>
12910 * server.c (main): Avoid infinite loop while detaching/killing
12913 2012-01-09 Doug Evans <dje@google.com>
12915 * server.c (start_inferior): Set last_ptid in --wrapper case.
12917 2012-01-06 Yao Qi <yao@codesourcery.com>
12919 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
12921 [IN_PROCESS_AGENT] (debug_agent): New global variable.
12923 2012-01-04 Yao Qi <yao@codesourcery.com>
12925 * tracepoint.c (cmd_qtdp): Print debug message
12926 for static tracepoint.
12928 2012-01-04 Yao Qi <yao@codesourcery.com>
12930 * tracepoint.c (trace_vdebug): Differentiate debug message
12931 between gdbserver and IPA.
12933 2012-01-03 Yao Qi <yao@codesourcery.com>
12935 * tracepoint.c (tracepoint_was_hit): Don't collect for
12938 2012-01-02 Joel Brobecker <brobecker@adacore.com>
12940 * terminal.h: Reformat copyright header.
12942 2012-01-02 Joel Brobecker <brobecker@adacore.com>
12944 * server.c (gdbserver_version): Update copyright year.
12945 * gdbreplay.c (gdbreplay_version): Likewise.
12947 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
12949 * linux-low.c (linux_create_inferior): Put empty if clause for write.
12952 2011-12-18 Hui Zhu <teawater@gmail.com>
12953 * linux-low.c (linux_create_inferior): Save return value to ret.
12955 2011-12-18 Hui Zhu <teawater@gmail.com>
12957 * linux-low.c (linux_create_inferior): Save return value to ret.
12959 2011-12-16 Doug Evans <dje@google.com>
12961 * linux-low.c (linux_create_inferior): If stdio connection,
12962 redirect stdin from /dev/null, stdout to stderr.
12963 * remote-utils.c (remote_is_stdio): New static global.
12964 (remote_connection_is_stdio): New function.
12965 (remote_prepare): Handle stdio connection.
12966 (remote_open): Ditto.
12967 (remote_close): Don't close stdin for stdio connections.
12968 (read_prim,write_prim): New functions. Replace all calls to
12969 read/write to these.
12970 * server.c (main): Watch for "-" argument. Move call to
12971 remote_prepare before start_inferior.
12972 * server.h (STDIO_CONNECTION_NAME): New macro.
12973 (remote_connection_is_stdio): Declare.
12975 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
12976 in debugging output.
12978 2011-12-15 Yao Qi <yao@codesourcery.com>
12980 * tracepoint.c: Include sys/syscall.h.
12981 (gdb_ust_thread): Remove preprocessor conditional.
12983 2011-12-14 Pedro Alves <pedro@codesourcery.com>
12985 * linux-low.c (linux_detach_one_lwp): Call
12986 the_low_target.prepare_to_resume before detaching.
12988 2011-12-14 Yao Qi <yao@codesourcery.com>
12990 * tracepoint.c (gdb_ust_thread): Don't ignore return value
12993 2011-12-14 Yao Qi <yao@codesourcery.com>
12995 * i386-low.c (i386_low_stopped_data_address): Initialize local
12996 variable `control'.
12998 2011-12-13 Pedro Alves <pedro@codesourcery.com>
13002 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
13003 DR_CONTROL unless necessary. Extend comments.
13004 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
13005 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
13007 2011-12-13 Yao Qi <yao@codesourcery.com>
13009 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
13011 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
13013 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
13015 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
13016 Print new debug message for such case.
13018 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
13020 Fix overlapping memcpy.
13021 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
13022 the read_inferior_memory transfer.
13023 (delete_fast_tracepoint_jump): New variable buf. Use it for the
13024 write_inferior_memory transfer.
13025 (set_fast_tracepoint_jump): New variable buf. Use it for the
13026 read_inferior_memory and write_inferior_memory transfers.
13027 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
13028 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
13029 Use it for the write_inferior_memory transfer.
13030 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
13033 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
13035 * linux-low.c (fetch_register, store_register): Make code
13036 consistent, fix formatting.
13038 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
13040 * linux-low.c (usr_store_inferior_registers): Factor out code
13041 to handle individual registers into...
13042 (store_register): ... this new function.
13044 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
13046 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
13047 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
13048 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
13049 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
13050 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
13051 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
13052 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
13053 (srv_xmlfiles): Add new XML files.
13055 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
13057 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
13058 (init_registers_s390_linux32v1): Add prototype.
13059 (init_registers_s390_linux32v2): Likewise.
13060 (init_registers_s390_linux64v1): Likewise.
13061 (init_registers_s390_linux64v2): Likewise.
13062 (init_registers_s390x_linux64v1): Likewise.
13063 (init_registers_s390x_linux64v2): Likewise.
13064 (s390_num_regs): Increment to 52.
13065 (s390_regmap): Add orig_r2 register.
13066 (s390_num_regs_3264): Increment to 68.
13067 (s390_regmap_3264): Add orig_r2 register.
13068 (s390_collect_ptrace_register): Handle orig_r2 register.
13069 (s390_supply_ptrace_register): Likewise.
13070 (s390_fill_last_break): New function.
13071 (s390_store_last_break): Likewise.
13072 (s390_fill_system_call): New function.
13073 (s390_store_system_call): Likewise.
13074 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
13076 (s390_check_regset): New function.
13077 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
13078 NT_S390_SYSTEM_CALL regsets and use appropriate description.
13079 Update target_regsets for available register sets.
13081 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
13082 Jan Kratochvil <jan.kratochvil@redhat.com>
13084 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
13085 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
13087 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
13088 * linux-low.h (struct process_info_private): New member r_debug.
13089 * server.c (handle_qxfer_libraries): Call
13090 the_target->qxfer_libraries_svr4.
13091 (handle_qxfer_libraries_svr4): New function.
13092 (qxfer_packets): New entry "libraries-svr4".
13093 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
13094 * target.h (struct target_ops): New member qxfer_libraries_svr4.
13095 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
13096 PACKET_qXfer_libraries_svr4.
13098 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
13100 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
13101 PSW address/mask between 8-byte and 16-byte formats.
13102 (s390_supply_ptrace_register): Likewise.
13103 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
13104 basic addressing mode bit.
13106 2011-11-24 Stan Shebs <stan@codesourcery.com>
13108 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
13110 2011-11-17 Stan Shebs <stan@codesourcery.com>
13112 * tracepoint.c (struct tracepoint): New field traceframe_usage.
13113 (tracing_start_time): New global.
13114 (tracing_stop_time): New global.
13115 (tracing_user_name): New global.
13116 (tracing_notes): New global.
13117 (tracing_stop_note): New global.
13118 (cmd_qtstart): Set traceframe_usage, start_time.
13119 (stop_tracing): Set stop_time.
13120 (cmd_qtstatus): Report additional status.
13121 (cmd_qtp): New function.
13122 (handle_tracepoint_query): Call it.
13123 (cmd_qtnotes): New function.
13124 (handle_tracepoint_general_set): Call it.
13125 (get_timestamp): Rename from tsv_get_timestamp.
13127 2011-11-14 Stan Shebs <stan@codesourcery.com>
13128 Kwok Cheung Yeung <kcy@codesourcery.com>
13130 * linux-x86-low.c (small_jump_insn): New.
13131 (i386_install_fast_tracepoint_jump_pad): Add arguments for
13132 trampoline and error message, build a trampoline and issue a small
13133 jump instruction to it.
13134 (x86_install_fast_tracepoint_jump_pad): Add arguments for
13135 trampoline and error message.
13136 (x86_get_min_fast_tracepoint_insn_len): New.
13137 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
13138 * linux-low.h (struct linux_target_ops): Add arguments to
13139 install_fast_tracepoint_jump_pad operation, add new operation.
13140 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
13142 (linux_get_min_fast_tracepoint_insn_len): New function.
13143 (linux_target_op): Add new operation.
13144 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
13145 (gdb_trampoline_buffer_end): Ditto.
13146 (gdb_trampoline_buffer_error): Ditto.
13147 (struct ipa_sym_addresses): Add fields for new IPA variables.
13148 (symbol_list): Add entries for new IPA variables.
13149 (struct tracepoint): Add fields to hold the address range of the
13150 trampoline used by the tracepoint.
13151 (trampoline_buffer_head): New static variable.
13152 (trampoline_buffer_tail): Ditto.
13153 (claim_trampoline_space): New function.
13154 (have_fast_tracepoint_trampoline_buffer): New function.
13155 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
13157 (install_fast_tracepoint): Ditto, also add error buffer argument.
13158 (cmd_qtminftpilen): New function.
13159 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
13160 (fast_tracepoint_from_trampoline_address): New function.
13161 (fast_tracepoint_collecting): Handle trampoline as part of jump
13163 (set_trampoline_buffer_space): New function.
13164 (initialize_tracepoint): Initialize new IPA variables.
13165 * target.h (struct target_ops): Add arguments to
13166 install_fast_tracepoint_jump_pad operation, add new
13167 get_min_fast_tracepoint_insn_len operation.
13168 (target_get_min_fast_tracepoint_insn_len): New.
13169 (install_fast_tracepoint_jump_pad): Add arguments.
13170 * server.h (IPA_BUFSIZ): Define.
13171 * linux-i386-ipa.c: Include extra header files.
13172 (initialize_fast_tracepoint_trampoline_buffer): New function.
13173 (initialize_low_tracepoint): Call it.
13174 * server.h (set_trampoline_buffer_space): Declare.
13175 (claim_trampoline_space): Ditto.
13176 (have_fast_tracepoint_trampoline_buffer): Ditto.
13178 2011-11-14 Yao Qi <yao@codesourcery.com>
13180 * server.c (handle_query): Handle InstallInTrace for qSupported.
13181 * tracepoint.c (add_tracepoint): Sort list.
13182 (install_tracepoint, download_tracepoint): New.
13183 (cmd_qtdp): Call them to install and download tracepoints.
13184 (sort_tracepoints): Removed.
13185 (cmd_qtstart): Update.
13187 2011-11-14 Yao Qi <yao@codesourcery.com>
13189 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
13190 * mem-break.h: Declare.
13191 * tracepoint.c (cmd_qtstart): Move some code to ...
13192 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
13194 (download_tracepoints): Move some code to ...
13195 (download_tracepoint_1): ... here. New.
13197 2011-11-08 Yao Qi <yao@codesourcery.com>
13199 * remote-utils.c (relocate_instruction): A comment fix.
13201 2011-11-07 Joel Brobecker <brobecker@adacore.com>
13203 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
13204 (i386_dr_low_get_control, i386_dr_low_get_status): Use
13205 dr_status_mirror and dr_control_mirror from debug_reg_state.
13206 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
13207 (i386_initial_stuff): Remove use of deleted globals.
13208 (i386_get_thread_context, i386_set_thread_context,
13209 i386_thread_added): Use dr_status_mirror and dr_control_mirror
13210 from debug_reg_state.
13212 2011-11-05 Yao Qi <yao@codesourcery.com>
13214 * tracepoint.c (gdb_collect): Loop over tracepoints of same
13215 address as TPOINT's.
13217 2011-11-02 Stan Shebs <stan@codesourcery.com>
13219 * tracepoint.c (agent_mem_read_string): New function.
13220 (eval_agent_expr): Call it for tracenz.
13221 * server.c (handle_query): Report support for tracenz.
13223 2011-11-02 Yao Qi <yao@codesourcery.com>
13225 * tracepoint.c (cmd_qtstart): Remove unused local variables.
13227 2011-11-02 Yao Qi <yao@codesourcery.com>
13229 * target.h: Fix a typo in comment.
13231 2011-10-31 Pedro Alves <pedro@codesourcery.com>
13233 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
13234 clobber the breakpoints' shadows with fast tracepoint jumps.
13235 * mem-break.h (check_mem_write): Add `myaddr' parameter.
13236 * target.c (write_inferior_memory): Also pass MYADDR down to
13239 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
13241 * configure.ac: Check support for personality routine.
13242 * configure: Regenerate.
13243 * config.in: Likewise.
13244 * linux-low.c: Include <sys/personality.h>.
13245 Define ADDR_NO_RANDOMIZE if necessary.
13246 (linux_create_inferior): Disable address space randomization when
13247 forking inferior, if requested.
13248 (linux_supports_disable_randomization): New function.
13249 (linux_target_ops): Install it.
13250 * server.h (disable_randomization): Declare.
13251 * server.c (disable_randomization): New global variable.
13252 (handle_general_set): Handle QDisableRandomization.
13253 (handle_query): Likewise for qSupported.
13254 (main): Support --disable-randomization and --no-disable-randomization
13255 command line arguments.
13256 * target.h (struct target_ops): Add supports_disable_randomization.
13257 (target_supports_disable_randomization): New macro.
13259 2011-09-29 Mike Frysinger <vapier@gentoo.org>
13261 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
13263 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
13264 [!PT_GETDSBT] (target_loadmap): New definition.
13265 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
13266 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
13267 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
13268 and PT_GETDSBT to LINUX_LOADMAP.
13269 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
13270 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
13272 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
13274 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
13275 (arm_linux_hwbp_cap): New static variable.
13276 (arm_linux_get_hwbp_cap): Replace by ...
13277 (arm_linux_init_hwbp_cap): ... this new function.
13278 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
13279 (arm_linux_get_hw_watchpoint_count): Likewise.
13280 (arm_linux_get_hw_watchpoint_max_length): Likewise.
13281 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
13282 (arm_prepare_to_resume): Use perror_with_name instead of error.
13284 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
13286 * linux-arm-low.c: Include <signal.h>.
13287 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
13288 (struct arm_linux_hwbp_cap): New data type.
13289 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
13290 (struct arm_linux_hw_breakpoint): New data type.
13291 (MAX_BPTS, MAX_WPTS): Define.
13292 (struct arch_process_info, struct arch_lwp_info): New data types.
13293 (arm_linux_get_hwbp_cap): New function.
13294 (arm_linux_get_hw_breakpoint_count): Likewise.
13295 (arm_linux_get_hw_watchpoint_count): Likewise.
13296 (arm_linux_get_hw_watchpoint_max_length): Likewise.
13297 (arm_hwbp_control_initialize): Likewise.
13298 (arm_hwbp_control_is_enabled): Likewise.
13299 (arm_hwbp_control_is_initialized): Likewise.
13300 (arm_hwbp_control_disable): Likewise.
13301 (arm_linux_hw_breakpoint_equal): Likewise.
13302 (arm_linux_hw_point_initialize): Likewise.
13303 (struct update_registers_data): New data structure.
13304 (update_registers_callback: New function.
13305 (arm_insert_point): Likewise.
13306 (arm_remove_point): Likewise.
13307 (arm_stopped_by_watchpoint): Likewise.
13308 (arm_stopped_data_address): Likewise.
13309 (arm_new_process): Likewise.
13310 (arm_new_thread): Likewise.
13311 (arm_prepare_to_resume): Likewise.
13312 (the_low_target): Register arm_insert_point, arm_remove_point,
13313 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
13314 arm_new_thread, and arm_prepare_to_resume.
13316 2011-09-15 Stan Shebs <stan@codesourcery.com>
13318 * server.h (struct emit_ops): Add compare-goto fields.
13319 * tracepoint.c (gdb_agent_op_sizes): New table.
13320 (emit_eq_goto): New function.
13321 (emit_ne_goto): New function.
13322 (emit_lt_goto): New function.
13323 (emit_le_goto): New function.
13324 (emit_gt_goto): New function.
13325 (emit_ge_goto): New function.
13326 (is_goto_target): New function.
13327 (compile_bytecodes): Recognize special cases of compare-goto
13328 combinations and call specialized emitters for them.
13329 * linux-x86-low.c (amd64_emit_eq_goto): New function.
13330 (amd64_emit_ne_goto): New function.
13331 (amd64_emit_lt_goto): New function.
13332 (amd64_emit_le_goto): New function.
13333 (amd64_emit_gt_goto): New function.
13334 (amd64_emit_ge_goto): New function.
13335 (amd64_emit_ops): Add the new functions.
13336 (i386_emit_eq_goto): New function.
13337 (i386_emit_ne_goto): New function.
13338 (i386_emit_lt_goto): New function.
13339 (i386_emit_le_goto): New function.
13340 (i386_emit_gt_goto): New function.
13341 (i386_emit_ge_goto): New function.
13342 (i386_emit_ops): Add the new functions.
13344 2011-09-08 Stan Shebs <stan@codesourcery.com>
13346 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
13347 (i386_emit_epilogue): Restore %ebx.
13349 2011-08-31 Jie Zhang <jzhang918@gmail.com>
13351 * server.c (step_thread): Remove definition.
13352 (process_serial_event): Don't handle Hs.
13353 * server.h (step_thread): Remove declaration.
13354 * target.c (set_desired_inferior): Remove use of step_thread.
13356 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
13358 * linux-low.c: Include linux-procfs.h.
13359 (linux_attach_lwp_1): Update comments.
13360 (linux_attach): Scan for existing threads when attaching to a
13361 process that is the tgid.
13362 * Makefile.in: Update dependencies.
13364 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
13366 * configure.srv: Add linux-procfs.o dependencies.
13368 2011-08-14 Yao Qi <yao@codesourcery.com>
13370 * target.h (struct target_ops): Fix indent.
13371 * win32-low.c (win32_target_ops): Fix comment.
13373 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
13374 Yao Qi <yao@codesourcery.com>
13376 * Makefile.in (clean): Remove tic6x-*.c files.
13377 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
13378 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
13379 (tic6x-c64xp-linux.c): Likewise.
13380 * configure.srv: Add support for tic6x-*-uclinux.
13381 * linux-tic6x-low.c: New.
13382 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
13384 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
13385 Yao Qi <yao@codesourcery.com>
13387 * target.h (struct target_ops): Add read_loadmap.
13388 * linux-low.c (struct target_loadseg): New type.
13389 (struct target_loadmap): New type.
13390 (linux_read_loadmap): New function.
13391 (linux_target_ops): Add linux_read_loadmap.
13392 * server.c (handle_query): Support qXfer:fdpic:read packet.
13393 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
13396 2011-08-05 Eli Zaretskii <eliz@gnu.org>
13398 * win32-low.c: Include <stdint.h>.
13400 2011-07-22 Pedro Alves <pedro@codesourcery.com>
13402 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
13403 to the inferior here.
13404 (i386_remove_aligned_watchpoint): Ditto.
13405 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
13406 fit part of the watchpoint in the debug registers.
13407 (i386_update_inferior_debug_regs): New.
13408 (i386_low_insert_watchpoint): Work on a local mirror of the debug
13409 registers, and only update the inferior on success.
13410 (i386_low_remove_watchpoint): Ditto.
13412 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
13414 * linux-low.c (compare_ints, unique, list_threads, show_process,
13415 linux_core_of_thread): Delete.
13416 (linux_target_ops): Change linux_core_of_thread to
13417 linux_common_core_of_thread.
13418 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
13419 * utils.c (malloc_failure): Change type of argument.
13420 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
13421 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
13422 common/linux-osdata.c, common/ptid.c and common/buffer.c.
13423 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
13424 (IPA_OBJS): Add common-utils-ipa.o.
13425 (ptid_h, linux_osdata_h): New macros.
13426 (server_h): Add common/common-utils.h, common/xml-utils.h,
13427 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
13429 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
13430 ptid.o, buffer.o): New rules.
13431 (linux-low.o): Add common/linux-osdata.h as a dependency.
13432 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
13433 * configure.ac: Add AC_HEADER_DIRENT check.
13434 * config.in: Regenerate.
13435 * configure: Regenerate.
13436 * remote-utils.c (xml_escape_text): Delete.
13437 (buffer_grow, buffer_free, buffer_init, buffer_finish,
13438 buffer_xml_printf): Move to common/buffer.c.
13439 * server.c (main): Remove call to initialize_inferiors.
13440 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
13441 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
13442 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
13443 internal_error, gdb_assert, gdb_assert_fail): Delete.
13444 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
13445 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
13447 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
13448 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
13449 initialize_inferiors): Delete.
13451 2011-07-20 Pedro Alves <pedro@codesourcery.com>
13453 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
13456 2011-05-31 Pedro Alves <pedro@codesourcery.com>
13458 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
13460 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
13462 2011-05-26 Yao Qi <yao@codesourcery.com>
13464 * Makefile.in (thread-db.o): Track dependence to
13465 common/gdb_thread_db.h.
13466 * thread-db.c: include gdb_thread_db.h from right place.
13468 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
13470 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
13471 __FILE__ and __LINE__ to internal_error.
13473 2011-05-13 Doug Evans <dje@google.com>
13475 * thread-db.c (try_thread_db_load_from_sdir): New function.
13476 (try_thread_db_load_from_dir): New function.
13477 (thread_db_load_search): Handle $sdir, ignore $pdir.
13478 Remove trying of system directories if search of
13479 libthread-db-search-path fails, that is now done via $sdir.
13481 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
13483 * server.c (handle_query): Add EnableDisableTracepoints to the list
13484 of supported features.
13485 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
13487 (cmd_qtenable_disable): New.
13488 (cmd_qtstart): Install tracepoints even if disabled.
13489 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
13490 receiving a QTEnable or QTDisable packet.
13491 (gdb_collect): Skip data collection if fast tracepoint is disabled.
13492 (ust_marker_to_static_tracepoint): Do not ignore disabled static
13494 (gdb_probe): Skip data collection if static tracepoint is disabled.
13496 2011-05-10 Doug Evans <dje@google.com>
13498 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
13500 2011-05-04 Doug Evans <dje@google.com>
13502 * linux-low.c (linux_join): Skip process lookup.
13503 * spu-low.c (spu_join): Ditto.
13504 * server.c (join_inferiors_callback): Delete.
13505 (process_serial_event): For 'D' packet (detach) call join_inferior
13508 2011-05-04 Joseph Myers <joseph@codesourcery.com>
13510 * README: Don't mention xscale*-*-linux*.
13511 * configure.srv (xscale*-*-linux*): Don't handle target.
13513 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
13515 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
13517 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
13518 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
13519 (i386_emit_void_call_2): Likewise.
13521 2011-04-26 Yao Qi <yao@codesourcery.com>
13523 * linux-low.c: Move common macros to linux-ptrace.h.
13524 Include linux-ptrace.h.
13525 * Makefile.in (linux_ptrace_h): New.
13526 (linux-low.o): Depends on linux-ptrace.h.
13528 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
13530 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
13531 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
13532 (remote_prepare): New function with most of the TCP code from ...
13533 (remote_open): ... here. Detect PORT here unconditionally. Move also
13534 setting transport_is_reliable.
13535 * server.c (run_once): New variable.
13536 (gdbserver_usage): Document it.
13537 (main): Set run_once for `--once'. Call remote_prepare. Exit after
13538 the first run if RUN_ONCE.
13539 * server.h (run_once, remote_prepare): New declarations.
13541 2011-04-19 Tom Tromey <tromey@redhat.com>
13543 * win32-low.c (handle_load_dll): Remove duplicate "the".
13545 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
13547 Remove support for old Cygwin 1.5 versions.
13548 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
13549 function to avoid warning.
13550 (win32_add_one_solib): Use cygwin_conv_path function to avoid
13553 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
13555 * gdbserver/server.h (Macro _): Define it if not available.
13557 2011-03-14 Michael Snyder <msnyder@vmware.com>
13559 * hostio.c (handle_close): Remove unnecessary null test.
13561 2011-03-10 Joel Brobecker <brobecker@adacore.com>
13563 * Makefile.in (maintainer-clean realclean distclean): Remove
13564 "make ... subdir_do" command.
13566 2011-03-10 Michael Snyder <msnyder@vmware.com>
13568 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
13570 * server.c (handle_v_run): Free alloced buffer on early return.
13572 2011-03-09 Yao Qi <yao@codesourcery.com>
13575 2011-03-04 Yao Qi <yao@codesourcery.com>
13577 * Makefile.in: Remove GNU make feature --directory.
13579 2011-03-05 Yao Qi <yao@codesourcery.com>
13581 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
13582 (subdir_do): New make target. Copied from gdb/Makefile.
13583 (maintainer-clean, realclean, distclean, clean): Call corresponding
13584 make targets in common/Makefile.
13586 2011-02-11 Yao Qi <yao@codesourcery.com>
13588 * configure.ac: Call AC_PROG_RANLIB.
13589 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
13590 * configure: Regenerate.
13592 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
13594 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
13596 2011-03-06 Yao Qi <yao@codesourcery.com>
13598 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
13600 2011-03-05 Yao Qi <yao@codesourcery.com>
13602 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
13603 (subdir_do): New make target. Copied from gdb/Makefile.
13604 (maintainer-clean, realclean, distclean, clean): Call corresponding
13605 make targets in common/Makefile.
13607 2011-03-04 Yao Qi <yao@codesourcery.com>
13609 * Makefile.in: Remove GNU make feature --directory.
13611 2011-03-04 Michael Snyder <msnyder@vmware.com>
13613 * server.c (queue_stop_reply): Call xmalloc not malloc.
13615 2011-03-02 Michael Snyder <msnyder@vmware.com>
13617 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
13619 2011-02-28 Michael Snyder <msnyder@vmware.com>
13621 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
13622 (cmd_qtframe): Ditto.
13623 (cmd_qtbuffer): Ditto.
13624 (cmd_bigqtbuffer): Ditto.
13626 * utils.c (decimal2str): Initialize 'width' to nine, then
13627 don't mess with it.
13629 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
13631 * hostio.c (require_data): Free *data, not data.
13633 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13635 * hostio.c (require_data): Use free, not xfree.
13637 2011-02-27 Michael Snyder <msnyder@vmware.com>
13639 * server.c (handle_query): Discard unused value.
13641 * hostio.c (require_data): Free malloc memory before returning
13644 2011-02-26 Michael Snyder <msnyder@vmware.com>
13646 * linux-low.c (list_threads): Call closedir for dirent.
13648 2011-02-27 Michael Snyder <msnyder@vmware.com>
13650 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
13651 a case statement falls through.
13653 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
13655 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
13658 2011-02-26 Michael Snyder <msnyder@vmware.com>
13660 * utils.c (decimal2str): Eliminate dead code and dead param.
13661 (pulongest): Drop dead param from call to decimal2str.
13664 2011-02-24 Joel Brobecker <brobecker@adacore.com>
13666 Revert the following patch (not approved yet):
13667 2011-02-21 Hui Zhu <teawater@gmail.com>
13668 * tracepoint.c (tp_printf): New function.
13669 (eval_agent_expr): Handle gdb_agent_op_printf.
13671 2011-02-21 Hui Zhu <teawater@gmail.com>
13673 * tracepoint.c (tp_printf): New function.
13674 (eval_agent_expr): Handle gdb_agent_op_printf.
13676 2011-02-18 Tom Tromey <tromey@redhat.com>
13678 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
13679 (tracepoint.o): Likewise.
13680 * tracepoint.c (enum gdb_agent_op): Use ax.def.
13681 (gdb_agent_op_names): Likewise.
13683 2011-02-18 Tom Tromey <tromey@redhat.com>
13685 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
13686 gdb_agent_op_rot>: New constants.
13687 (gdb_agent_op_names): Add pick and roll.
13688 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
13691 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
13693 * aclocal.m4: Regenerated with aclocal-1.11.1.
13695 2011-02-14 Pedro Alves <pedro@codesourcery.com>
13697 * server.c (handle_qxfer_traceframe_info): New.
13698 (qxfer_packets): Register "traceframe-info".
13699 (handle_query): Report support for qXfer:traceframe-info:read+.
13700 * tracepoint.c (match_blocktype): New.
13701 (traceframe_find_block_type): Rename to ...
13702 (traceframe_walk_blocks): ... this. Add callback filter argument,
13704 (traceframe_find_block_type): New, reimplemented on top of
13705 traceframe_walk_blocks.
13706 (build_traceframe_info_xml): New.
13707 (traceframe_read_info): New.
13708 * server.h (traceframe_read_info): Declare.
13710 2011-02-11 Yao Qi <yao@codesourcery.com>
13712 * configure.ac: Call AC_PROG_RANLIB.
13713 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
13714 * configure: Regenerate.
13716 2011-02-07 Pedro Alves <pedro@codesourcery.com>
13718 * server.c (gdb_read_memory): Change return semantics to allow
13720 (handle_search_memory_1): Adjust.
13721 (process_serial_event) <'m' packet>: Handle partial transfers.
13722 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
13724 2011-01-28 Pedro Alves <pedro@codesourcery.com>
13726 * regcache.c (init_register_cache): Initialize
13727 regcache->register_status.
13728 (free_register_cache): Release regcache->register_status.
13729 (regcache_cpy): Copy register_status.
13730 (registers_to_string): Print 'x's for unavailable registers.
13731 (supply_register): Mark the register's status valid or
13732 unavailable, depending on whether a buffer was passed in or not.
13733 (supply_register_zeroed): New.
13734 (supply_regblock): Mark the registers' status valid or
13735 unavailable, depending on whether a buffer was passed in or not.
13736 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
13737 (struct regcache): New `register_status' field.
13738 (supply_register_zeroed): Declare.
13739 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
13740 supply_register_zeroed, rather than passing a NULL buffer to
13742 * tracepoint.c (fetch_traceframe_registers): Update comment.
13744 2011-01-28 Pedro Alves <pedro@codesourcery.com>
13746 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
13749 2011-01-25 Pedro Alves <pedro@codesourcery.com>
13751 * server.h (decode_xfer_write): Change prototype.
13752 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
13753 and don't extract the annex here.
13754 * server.c (decode_xfer_read): Remove `annex' parameter,
13755 and don't extract the annex here.
13756 (decode_xfer): New.
13757 (struct qxfer): New.
13758 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
13759 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
13760 (handle_qxfer_statictrace): New functions, abstracted out from
13761 handle_query, and made to use the struct qxfer interface.
13762 (handle_threads_qxfer_proper): Rename to ...
13763 (handle_qxfer_threads_proper): ... this.
13764 (handle_threads_qxfer): Rename to ...
13765 (handle_qxfer_threads): ... this. Adjust.
13766 (qxfer_packets): New array.
13767 (handle_qxfer): New function.
13768 (handle_query): Use handle_qxfer.
13770 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
13772 * gdbreplay.c: Shorten lines of >= 80 columns.
13773 * linux-low.c: Ditto.
13774 * linux-ppc-low.c: Ditto.
13775 * linux-s390-low.c: Ditto.
13776 * linux-sparc-low.c: Ditto.
13777 * linux-x86-low.c: Ditto.
13778 * linux-xtensa-low.c: Ditto.
13779 * mem-break.c: Ditto.
13780 * nto-low.c: Ditto.
13781 * regcache.h: Ditto.
13782 * remote-utils.c: Ditto.
13785 * thread-db.c: Ditto.
13786 * tracepoint.c: Ditto.
13788 * win32-low.h: Ditto.
13790 2011-01-05 Joel Brobecker <brobecker@adacore.com>
13792 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
13795 2011-01-01 Joel Brobecker <brobecker@adacore.com>
13797 * server.c (gdbserver_version): Update copyright year in version
13799 * gdbreplay.c (gdbreplay_version): Ditto.
13801 2010-12-29 Jie Zhang <jie.zhang@analog.com>
13803 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
13804 * linux-bfin-low.c: New file.
13805 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
13806 PT_DATA_ADDR for BFIN targets.
13807 * Makefile.in (SFILES): Add linux-bfin-low.c.
13808 (clean): Remove reg-bfin.c.
13809 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
13810 * README: Mention supported Blackfin targets.
13812 2010-12-23 Mike Frysinger <vapier@gentoo.org>
13814 * .gitignore: New file.
13816 2010-11-16 Mike Frysinger <vapier@gentoo.org>
13818 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
13820 2010-10-22 Jie Zhang <jie@codesourcery.com>
13822 * Makefile.in: Add FLAGS_TO_PASS variable.
13823 (install): Remove dependency of install-only and recursively
13824 invoke make for install-only.
13826 2010-10-04 Doug Evans <dje@google.com>
13828 * Makefile.in (uninstall): Use $(DESTDIR).
13830 2010-09-24 Pedro Alves <pedro@codesourcery.com>
13834 * linux-x86-low.c (compat_siginfo_from_siginfo)
13835 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
13836 si_code is < 0. Check for si_code == SI_TIMER before checking for
13839 2010-09-13 Joel Brobecker <brobecker@adacore.com>
13841 * lynx-i386-low.c: New file.
13842 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
13844 2010-09-13 Joel Brobecker <brobecker@adacore.com>
13846 * lynx-low.c (ptrace_request_to_str): Remove handling for
13847 request values that have been removed in LynxOS 5.x.
13849 2010-09-13 Joel Brobecker <brobecker@adacore.com>
13851 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
13854 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
13856 * configure.ac: Add --enable-inprocess-agent option.
13857 * configure: Rebuilt.
13859 2010-09-06 Yao Qi <yao@codesourcery.com>
13861 * linux-low.c (linux_kill): Remove unused variable.
13862 (linux_stabilize_threads): Likewise.
13863 * server.c (start_inferior): Likewise.
13864 (queue_stop_reply_callback): Likewise.
13865 * tracepoint.c (do_action_at_tracepoint): Likewise.
13867 2010-09-06 Yao Qi <yao@codesourcery.com>
13869 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
13872 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
13874 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
13876 2010-09-06 Pedro Alves <pedro@codesourcery.com>
13878 * Makefile.in (install-only): Replace $IPA_DEPFILES with
13881 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13883 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
13884 gdbserver/lynx-ppc-low.c: New files.
13885 * Makefile.in (lynx_low_h): New variable.
13886 (lynx-low.o, lynx-ppc-low.o): New rules.
13887 * configure.ac: On LynxOS, link with -lnetinet.
13888 * configure.srv: Add handling of powerpc-*-lynxos* targets.
13889 * configure: regenerate.
13891 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13893 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
13894 * configure.ac: Add check for vasprintf and vsnprintf.
13895 * configure, config.in: Regenerate.
13896 * server.h (vasprintf, vsnprintf): Add conditional declarations.
13898 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13900 * gdbreplay.c: Move include of alloca.h up, next to include of
13902 * server.h: Add include of malloc.h.
13903 * mem-break.c: Remove include of malloc.h.
13904 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
13906 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13908 * Makefile.in (memmem.o): Build with -Wno-error.
13910 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13912 * utils.c (xsnprintf): Make non-static.
13913 * server.h: Add xsnprintf declaration.
13914 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
13915 replace calls to snprintf by calls to xsnprintf throughout.
13917 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13919 * configure.ac: Add configure check for alloca.
13920 * configure, config.in: Regenerate.
13921 * server.h: Include alloca.h if it exists.
13922 * gdbreplay.c: Include alloca.h if it exists.
13924 2010-08-28 Pedro Alves <pedro@codesourcery.com>
13926 * linux-low.c (__SIGRTMIN): Define if not already defined.
13927 (linux_create_inferior): Check for __ANDROID__ rather than
13929 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
13930 are already deferred.
13931 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
13932 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
13933 stopped and already has a pending signal to report.
13934 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
13935 a pending signal to report or is moving out of a jump pad.
13936 (linux_init_signals): Check for __ANDROID__ rather than
13939 2010-08-28 Pedro Alves <pedro@codesourcery.com>
13941 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
13942 debug_threads check. Avoid a linear search when not doing debug
13945 2010-08-27 Pedro Alves <pedro@codesourcery.com>
13947 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
13948 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
13949 (struct file_handler) <fd>: Change type to gdb_fildes_t.
13950 (process_event): Change local fd's type to gdb_fildes_t.
13951 (create_file_handler): Adjust prototype.
13952 (delete_file_handler): Adjust prototype.
13953 (handle_file_event): Adjust prototype. Use pfildes.
13954 (create_file_event): Adjsut prototype.
13955 * remote-utils.c (remote_desc, listen_desc): Change type to
13957 * server.h: New gdb_fildes_t typedef.
13958 [USE_WIN32API]: Include winsock2.h.
13959 (delete_file_handler, add_file_handler): Adjust prototypes.
13960 (pfildes): Declare.
13961 * utils.c (pfildes): New.
13963 2010-08-27 Pedro Alves <pedro@codesourcery.com>
13965 * configure.ac (build_warnings): Add -Wno-char-subscripts.
13966 * configure: Regenerate.
13968 2010-08-27 Pedro Alves <pedro@codesourcery.com>
13970 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
13971 (linux_done_accessing_memory): ... this.
13972 (linux_target_ops): Adjust.
13973 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
13974 * nto-low.c (nto_target_ops): Adjust comment.
13975 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
13976 * spu-low.c (spu_target_ops): Adjust comment.
13977 * target.h (target_ops): Rename unprepare_to_access_memory field
13978 to done_accessing_memory.
13979 (unprepare_to_access_memory): Rename to ...
13980 (done_accessing_memory): ... this.
13982 2010-08-26 Pedro Alves <pedro@codesourcery.com>
13984 * linux-low.c (linux_prepare_to_access_memory): New.
13985 (linux_unprepare_to_access_memory): New.
13986 (linux_target_ops): Install them.
13987 * server.c (read_memory): Rename to ...
13988 (gdb_read_memory): ... this. Use
13989 prepare_to_access_memory/prepare_to_access_memory.
13990 (write_memory): Rename to ...
13991 (gdb_write_memory): ... this. Use
13992 prepare_to_access_memory/prepare_to_access_memory.
13993 (handle_search_memory_1): Adjust.
13994 (process_serial_event): Adjust.
13995 * target.h (struct target_ops): New fields
13996 prepare_to_access_memory and unprepare_to_access_memory.
13997 (prepare_to_access_memory, unprepare_to_access_memory): New.
13998 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
13999 prepare_to_access_memory/prepare_to_access_memory.
14000 * nto-low.c (nto_target_ops): Adjust.
14001 * spu-low.c (spu_target_ops): Adjust.
14002 * win32-low.c (win32_target_ops): Adjust.
14004 2010-08-26 Pedro Alves <pedro@codesourcery.com>
14006 * Makefile.in (WARN_CFLAGS): Get it from configure.
14007 (WERROR_CFLAGS): New.
14008 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
14009 * configure.ac: Introduce --enable-werror, which adds -Werror to
14010 the compiler command line. Enabled by default. Disable with
14011 --disable-werror. Add -Wdeclaration-after-statement
14012 Wpointer-arith and -Wformat-nonliteral to warning flags.
14013 * configure: Regenerate.
14015 2010-08-26 Pedro Alves <pedro@codesourcery.com>
14017 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
14019 2010-08-26 Pedro Alves <pedro@codesourcery.com>
14021 * gdbreplay.c (remote_error): New.
14023 (expect): Use gdbchar. Check for error reading from GDB.
14024 Clarify sync error output.
14025 (play): Check for errors writing to GDB.
14026 * linux-low.c (sigchld_handler): Really ignore `write' errors.
14027 * remote-utils.c (getpkt): Check for errors writing to the remote
14030 2010-08-25 Pedro Alves <pedro@codesourcery.com>
14032 * linux-low.c (linux_wait_1): Move non-debugging code out of
14033 `debug_threads' control.
14035 2010-08-25 Pedro Alves <pedro@codesourcery.com>
14037 * linux-low.c (linux_wait_1): Don't set last_status here.
14038 * server.c (push_event, queue_stop_reply_callback): Assert we're
14039 not pushing a TARGET_WAITKIND_IGNORE event.
14040 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
14041 (myresume, handle_target_event): Set the thread's last_resume_kind
14042 and last_status from the target returned status.
14044 2010-08-25 Pedro Alves <pedro@codesourcery.com>
14048 * linux-x86-low.c (update_debug_registers_callback): New.
14049 (i386_dr_low_set_addr): Use it.
14050 (i386_dr_low_get_addr): New.
14051 (i386_dr_low_set_control): Use update_debug_registers_callback.
14052 (i386_dr_low_get_control): New.
14053 (i386_dr_low_get_status): Adjust.
14054 * linux-low.c (linux_stop_lwp): New.
14055 * linux-low.h (linux_stop_lwp): Declare.
14057 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
14058 argument instead of a i386_debug_reg_state.
14059 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
14060 a i386_debug_reg_state.
14061 (i386_insert_aligned_watchpoint): Adjust.
14062 (i386_remove_aligned_watchpoint): Adjust.
14063 (i386_low_stopped_data_address): Read the debug registers from the
14064 inferior instead of from the mirrors.
14065 * i386-low.h (struct i386_debug_reg_state): Extend comment.
14066 (i386_dr_low_get_addr): Declare.
14067 (i386_dr_low_get_control): Declare.
14068 (i386_dr_low_get_status): Change prototype.
14070 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
14071 (i386_dr_low_get_addr): New.
14072 (i386_dr_low_get_control): New.
14073 (i386_dr_low_get_status): Adjust prototype. Return
14075 (i386_initial_stuff): Clear dr_status_mirror and
14077 (i386_get_thread_context): Adjust.
14078 (i386_set_thread_context): Adjust.
14079 (i386_thread_added): Adjust.
14081 2010-08-24 Pedro Alves <pedro@codesourcery.com>
14083 * linux-low.h (linux_thread_area): Delete declaration.
14085 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
14087 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
14088 after its termination.
14090 2010-08-09 Pedro Alves <pedro@codesourcery.com>
14092 * linux-low.c (gdb_wants_lwp_stopped): Delete.
14093 (gdb_wants_all_stopped): Delete.
14094 (linux_wait_1): Don't call them.
14095 * server.c (handle_v_cont): Tag all threads as want-stopped.
14096 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
14097 stopped as "client-wants-stopped".
14099 2010-07-31 Pedro Alves <pedro@codesourcery.com>
14101 * Makefile.in (signals_h): New.
14102 (server_h): Depend on it.
14103 (server.o): Don't depend on $(signals_def).
14104 (signals.o): Depend on $(signals_def).
14106 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
14108 * Makefile.in (signals_def): New.
14109 (server_h): Append include/gdb/signals.h and signals_def.
14110 (server.o): Append signals_def.
14112 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
14114 * server.c (handle_target_event): Use target_signal_to_host for
14115 resume_info.sig initialization.
14116 * target.h (struct thread_resume) <sig>: New comment.
14118 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
14120 * server.c (handle_query): strcpy() the returned string from paddress()
14121 instead of sprintf().
14122 * utils.c (paddress): Return phex_nz().
14124 2010-07-07 Joel Brobecker <brobecker@adacore.com>
14126 * server.c (handle_v_cont): Call mourn_inferior if process
14128 (myresume): Likewise.
14130 2010-07-01 Pedro Alves <pedro@codesourcery.com>
14132 Static tracepoints, and integration with UST.
14134 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
14135 * mem-break.c (uninsert_all_breakpoints)
14136 (reinsert_all_breakpoints): New.
14137 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
14138 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
14139 (gdb_agent_ust_loaded, helper_thread_id)
14140 (gdb_agent_helper_thread_id): New macros.
14141 (struct ipa_sym_addresses): Add addr_ust_loaded,
14142 addr_helper_thread_id, addr_cmd_buf.
14143 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
14144 (in_process_agent_loaded_ust): New.
14145 (write_e_ust_not_loaded): New.
14146 (maybe_write_ipa_ust_not_loaded): New.
14147 (struct collect_static_trace_data_action): New.
14148 (enum tracepoint_type) <static_tracepoint>: New.
14149 (struct tracepoint) <handle>: Mention static tracepoints.
14150 (struct static_tracepoint_ctx): New.
14151 (CMD_BUF_SIZE): New.
14152 (add_tracepoint_action): Handle static tracepoint actions.
14153 (unprobe_marker_at): New.
14154 (clear_installed_tracepoints): Handle static tracepoints.
14155 (cmd_qtdp): Handle static tracepoints.
14156 (probe_marker_at): New.
14157 (cmd_qtstart): Handle static tracepoints.
14158 (response_tracepoint): Handle static tracepoints.
14159 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
14160 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
14161 (get_context_regcache): Handle static tracepoints.
14162 (do_action_at_tracepoint): Handle static tracepoint actions.
14163 (traceframe_find_block_type): Handle static trace data blocks.
14164 (traceframe_read_sdata): New.
14165 (download_tracepoints): Download static tracepoint actions.
14166 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
14167 (GDB_PROBE_NAME): New.
14169 (GET_UST_SYM): New.
14172 (ust_marker_to_static_tracepoint): New.
14174 (collect_ust_data_at_tracepoint): New.
14175 (gdb_ust_probe): New.
14176 (UNIX_PATH_MAX, SOCK_DIR): New.
14177 (gdb_ust_connect_sync_socket): New.
14178 (resume_thread, stop_thread): New.
14179 (run_inferior_command): New.
14180 (init_named_socket): New.
14181 (gdb_ust_socket_init): New.
14182 (cstr_to_hexstr): New.
14184 (first_marker, next_marker): New.
14185 (response_ust_marker): New.
14186 (cmd_qtfstm, cmd_qtsstm): New.
14187 (unprobe_marker_at, probe_marker_at): New.
14188 (cmd_qtstmat, gdb_ust_thread): New.
14189 (gdb_ust_init): New.
14190 (initialize_tracepoint_ftlib): Call gdb_ust_init.
14191 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
14192 (ST_REGENTRY): New.
14193 (x86_64_st_collect_regmap): New.
14194 (X86_64_NUM_ST_COLLECT_GREGS): New.
14195 (AMD64_RIP_REGNUM): New.
14196 (supply_static_tracepoint_registers): New.
14197 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
14198 (ST_REGENTRY): New.
14199 (i386_st_collect_regmap): New.
14200 (i386_NUM_ST_COLLECT_GREGS): New.
14201 (supply_static_tracepoint_registers): New.
14202 * server.c (handle_query): Handle qXfer:statictrace:read.
14203 <qSupported>: Report support for StaticTracepoints, and
14204 qXfer:statictrace:read features.
14205 * server.h (traceframe_read_sdata)
14206 (supply_static_tracepoint_registers): Declare.
14207 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
14208 (unpack_varlen_hex): Include in IPA build.
14209 * Makefile.in (ustlibs, ustinc): New.
14210 (IPA_OBJS): Add remote-utils-ipa.o.
14211 ($(IPA_LIB)): Link -ldl and -lpthread.
14213 (IPAGENT_CFLAGS): Add UST_CFLAGS.
14214 * config.in, configure: Regenerate.
14216 2010-06-20 Ian Lance Taylor <iant@google.com>
14217 Pedro Alves <pedro@codesourcery.com>
14219 * linux-x86-low.c (always_true): Delete.
14220 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
14221 trying to fool the compiler with always_true.
14223 2010-06-20 Pedro Alves <pedro@codesourcery.com>
14225 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
14226 conditions in gdbserver.
14228 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
14230 * spu-low.c (spu_read_memory): Wrap around local store limit.
14231 (spu_write_memory): Likewise.
14233 2010-06-15 Pedro Alves <pedro@codesourcery.com>
14235 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
14236 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
14238 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
14240 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
14241 uses with LONGEST uses.
14243 2010-06-14 Stan Shebs <stan@codesourcery.com>
14244 Pedro Alves <pedro@codesourcery.com>
14248 * linux-x86-low.c: Include limits.h.
14250 (always_true): New.
14253 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
14254 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
14255 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
14256 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
14257 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
14258 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
14259 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
14260 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
14261 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
14262 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
14263 (amd64_emit_void_call_2): New.
14264 (amd64_emit_ops): New.
14265 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
14266 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
14267 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
14268 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
14269 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
14270 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
14271 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
14272 (i386_emit_call, i386_emit_reg, i386_emit_pop)
14273 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
14274 (i386_emit_stack_adjust, i386_emit_int_call_1)
14275 (i386_emit_void_call_2): New.
14276 (i386_emit_ops): New.
14277 (x86_emit_ops): New.
14278 (the_low_target): Install x86_emit_ops.
14279 * server.h (struct emit_ops): New.
14280 (get_raw_reg_func_addr): Declare.
14281 (current_insn_ptr, emit_error): Declare.
14282 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
14283 (set_trace_state_variable_value): New defines.
14284 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
14285 addr_get_trace_state_variable_value and
14286 addr_set_trace_state_variable_value.
14287 (symbol_list): New fields for get_raw_reg,
14288 get_trace_state_variable_value and set_trace_state_variable_value.
14289 (condfn): New typedef.
14290 (struct tracepoint): New field `compiled_cond'.
14291 (do_action_at_tracepoint): Clear compiled_cond.
14292 (get_trace_state_variable_value, set_trace_state_variable_value):
14294 (condition_true_at_tracepoint): If there's a compiled condition,
14296 (current_insn_ptr, emit_error): New globals.
14297 (struct bytecode_address): New.
14298 (get_raw_reg_func_addr): New.
14299 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
14300 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
14301 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
14302 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
14303 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
14304 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
14305 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
14306 (compile_tracepoint_condition, compile_bytecodes): New.
14307 * target.h (emit_ops): Forward declare.
14308 (struct target_ops): New field emit_ops.
14309 (target_emit_ops): New.
14310 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
14311 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
14312 * linux-low.c (linux_emit_ops): New.
14313 (linux_target_ops): Install it.
14314 * linux-low.h (struct linux_target_ops): New field emit_ops.
14316 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
14318 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
14319 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
14321 2010-06-01 Pedro Alves <pedro@codesourcery.com>
14322 Stan Shebs <stan@codesourcery.com>
14324 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
14325 (all): Depend on $(extra_libraries).
14326 (install-only): Install the IPA.
14327 (IPA_OBJS, IPA_LIB): New.
14328 (clean): Remove the IPA lib.
14329 (IPAGENT_CFLAGS): New.
14330 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
14331 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
14332 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
14333 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
14334 * configure.ac: Check for atomic builtins support in the compiler.
14335 (IPA_DEPFILES, extra_libraries): Define.
14336 * configure.srv (ipa_obj): Add description.
14337 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
14338 (i[34567]86-*-linux*): Set ipa_obj.
14339 (x86_64-*-linux*): Set ipa_obj.
14340 * linux-low.c (stabilizing_threads): New.
14341 (supports_fast_tracepoints): New.
14342 (linux_detach): Stabilize threads before detaching.
14343 (handle_tracepoints): Handle internal tracing breakpoints. Assert
14344 the lwp is either not stabilizing, or is moving out of a jump pad.
14345 (linux_fast_tracepoint_collecting): New.
14346 (maybe_move_out_of_jump_pad): New.
14347 (enqueue_one_deferred_signal): New.
14348 (dequeue_one_deferred_signal): New.
14349 (linux_wait_for_event_1): If moving out of a jump pad, defer
14350 pending signals to later.
14351 (linux_stabilize_threads): New.
14352 (linux_wait_1): Check if threads need moving out of jump pads, and
14354 (stuck_in_jump_pad_callback): New.
14355 (move_out_of_jump_pad_callback): New.
14356 (lwp_running): New.
14357 (linux_resume_one_lwp): Handle moving out of jump pads.
14358 (linux_set_resume_request): Dequeue deferred signals.
14359 (need_step_over_p): Also step over fast tracepoint jumps.
14360 (start_step_over): Also uninsert fast tracepoint jumps.
14361 (finish_step_over): Also reinsert fast tracepoint jumps.
14362 (linux_install_fast_tracepoint_jump): New.
14363 (linux_target_ops): Install linux_stabilize_threads and
14364 linux_install_fast_tracepoint_jump_pad.
14365 * linux-low.h (linux_target_ops) <get_thread_area,
14366 install_fast_tracepoint_jump_pad>: New fields.
14367 (struct lwp_info) <collecting_fast_tracepoint,
14368 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
14369 (linux_get_thread_area): Declare.
14370 * linux-x86-low.c (jump_insn): New.
14371 (x86_get_thread_area): New.
14372 (append_insns): New.
14373 (push_opcode): New.
14374 (amd64_install_fast_tracepoint_jump_pad): New.
14375 (i386_install_fast_tracepoint_jump_pad): New.
14376 (x86_install_fast_tracepoint_jump_pad): New.
14377 (the_low_target): Install x86_get_thread_area and
14378 x86_install_fast_tracepoint_jump_pad.
14379 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
14380 (struct fast_tracepoint_jump): New.
14381 (fast_tracepoint_jump_insn): New.
14382 (fast_tracepoint_jump_shadow): New.
14383 (find_fast_tracepoint_jump_at): New.
14384 (fast_tracepoint_jump_here): New.
14385 (delete_fast_tracepoint_jump): New.
14386 (set_fast_tracepoint_jump): New.
14387 (uninsert_fast_tracepoint_jumps_at): New.
14388 (reinsert_fast_tracepoint_jumps_at): New.
14389 (set_breakpoint_at): Use write_inferior_memory.
14390 (uninsert_raw_breakpoint): Use write_inferior_memory.
14391 (check_mem_read): Mask out fast tracepoint jumps.
14392 (check_mem_write): Mask out fast tracepoint jumps.
14393 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
14394 (set_fast_tracepoint_jump): Declare.
14395 (delete_fast_tracepoint_jump)
14396 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
14397 (reinsert_fast_tracepoint_jumps_at): Declare.
14398 * regcache.c: Don't compile many functions when building the
14399 in-process agent library.
14400 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
14401 the register buffer in the heap.
14402 (free_register_cache): If the register buffer isn't owned by the
14403 regcache, don't free it.
14404 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
14405 pre-existing register caches.
14406 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
14408 (convert_ascii_to_int): : Constify `from' parameter type.
14409 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
14410 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
14411 the needed buffer in-place.
14412 (relocate_instruction): New.
14413 * server.c (handle_query) <qSymbols>: If the target supports
14414 tracepoints, give it a chance of looking up symbols. Report
14415 support for fast tracepoints.
14416 (handle_status): Stabilize threads.
14417 (process_serial_event): Adjust.
14418 * server.h (struct fast_tracepoint_jump): Forward declare.
14419 (struct process_info) <fast_tracepoint_jumps>: New field.
14420 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
14421 (decode_X_packet, decode_M_packet): Adjust.
14422 (relocate_instruction): Declare.
14423 (in_process_agent_loaded): Declare.
14424 (tracepoint_look_up_symbols): Declare.
14425 (struct fast_tpoint_collect_status): Declare.
14426 (fast_tracepoint_collecting): Declare.
14427 (force_unlock_trace_buffer): Declare.
14428 (handle_tracepoint_bkpts): Declare.
14429 (initialize_low_tracepoint)
14430 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
14431 * target.h (struct target_ops) <stabilize_threads,
14432 install_fast_tracepoint_jump_pad>: New fields.
14433 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
14434 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
14435 [HAVE_STDINT_H]: Include stdint.h.
14436 (trace_debug_1): Rename to ...
14437 (trace_vdebug): ... this.
14438 (trace_debug): Rename to ...
14439 (trace_debug_1): ... this. Add `level' parameter.
14440 (trace_debug): New.
14441 (ATTR_USED, ATTR_NOINLINE): New.
14442 (IP_AGENT_EXPORT): New.
14443 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
14444 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
14445 (about_to_request_buffer_space, trace_buffer_is_full)
14446 (stopping_tracepoint, expr_eval_result, error_tracepoint)
14447 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
14448 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
14449 (traceframe_write_count, traceframes_created)
14450 (trace_state_variables)
14451 New renaming defines.
14452 (struct ipa_sym_addresses): New.
14453 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
14454 (symbol_list): New.
14455 (ipa_sym_addrs): New.
14456 (all_tracepoint_symbols_looked_up): New.
14457 (in_process_agent_loaded): New.
14458 (write_e_ipa_not_loaded): New.
14459 (maybe_write_ipa_not_loaded): New.
14460 (tracepoint_look_up_symbols): New.
14461 (debug_threads) [IN_PROCESS_AGENT]: New.
14462 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
14463 (UNKNOWN_SIDE_EFFECTS): New.
14464 (stop_tracing): New.
14465 (flush_trace_buffer): New.
14466 (stop_tracing_bkpt): New.
14467 (flush_trace_buffer_bkpt): New.
14468 (read_inferior_integer): New.
14469 (read_inferior_uinteger): New.
14470 (read_inferior_data_pointer): New.
14471 (write_inferior_data_pointer): New.
14472 (write_inferior_integer): New.
14473 (write_inferior_uinteger): New.
14474 (struct collect_static_trace_data_action): Delete.
14475 (enum tracepoint_type): New.
14476 (struct tracepoint) <type>: New field `type'.
14477 <actions_str, step_actions, step_actions_str>: Only include in
14479 <orig_size, obj_addr_on_target, adjusted_insn_addr>
14480 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
14481 (tracepoints): Use IP_AGENT_EXPORT.
14482 (last_tracepoint): Don't include in the IPA.
14483 (stopping_tracepoint): Use IP_AGENT_EXPORT.
14484 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
14485 (alloced_trace_state_variables): New.
14486 (trace_state_variables): Use IP_AGENT_EXPORT.
14487 (traceframe_t): Delete unused variable.
14488 (circular_trace_buffer): Don't include in the IPA.
14489 (trace_buffer_start): Delete.
14490 (struct trace_buffer_control): New.
14491 (trace_buffer_free): Delete.
14492 (struct ipa_trace_buffer_control): New.
14493 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
14494 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
14496 (trace_buffer_ctrl): New.
14497 (TRACE_BUFFER_CTRL_CURR): New.
14498 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
14499 Reimplement as macros.
14500 (trace_buffer_wrap): Delete.
14501 (traceframe_write_count, traceframe_read_count)
14502 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
14503 (struct tracepoint_hit_ctx) <type>: New field.
14504 (struct fast_tracepoint_ctx): New.
14505 (memory_barrier): New.
14507 (record_tracepoint_error): Update atomically in the IPA.
14508 (clear_inferior_trace_buffer): New.
14509 (about_to_request_buffer_space): New.
14510 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
14511 updating the same buffer.
14512 (add_tracepoint): Default the tracepoint's type to trap
14513 tracepoint, and orig_size to -1.
14514 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
14515 internal variables.
14516 (create_trace_state_variable): New parameter `gdb'. Handle it.
14517 (clear_installed_tracepoints): Clear fast tracepoint jumps.
14518 (cmd_qtdp): Handle fast tracepoints.
14519 (cmd_qtdv): Adjust.
14520 (max_jump_pad_size): New.
14521 (gdb_jump_pad_head): New.
14522 (get_jump_space_head): New.
14523 (claim_jump_space): New.
14524 (sort_tracepoints): New.
14525 (MAX_JUMP_SIZE): New.
14526 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
14528 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
14529 support. Upload fast traceframes, and delete internal IPA
14531 (stop_tracing_handler): New.
14532 (flush_trace_buffer_handler): New.
14533 (cmd_qtstop): Upload fast tracepoints.
14534 (response_tracepoint): Handle fast tracepoints.
14535 (tracepoint_finished_step): Upload fast traceframes. Set the
14536 tracepoint hit context's tracepoint type.
14537 (handle_tracepoint_bkpts): New.
14538 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
14539 type. Add comment about fast tracepoints.
14540 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
14541 non-existing action_str field.
14542 (get_context_regcache): Handle fast tracepoints.
14543 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
14545 (fast_tracepoint_from_jump_pad_address): New.
14546 (fast_tracepoint_from_ipa_tpoint_address): New.
14547 (collecting_t): New.
14548 (force_unlock_trace_buffer): New.
14549 (fast_tracepoint_collecting): New.
14551 (gdb_collect): New.
14552 (write_inferior_data_ptr): New.
14553 (target_tp_heap): New.
14554 (target_malloc): New.
14555 (download_agent_expr): New.
14557 (download_tracepoints): New.
14558 (download_trace_state_variables): New.
14559 (upload_fast_traceframes): New.
14560 (IPA_FIRST_TRACEFRAME): New.
14561 (IPA_NEXT_TRACEFRAME_1): New.
14562 (IPA_NEXT_TRACEFRAME): New.
14563 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
14564 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
14565 (gdb_jump_pad_buffer_end): New.
14566 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
14567 (initialize_tracepoint): Adjust.
14568 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
14569 buffer. Initialize the low module.
14570 * utils.c (PREFIX, TOOLNAME): New.
14571 (malloc_failure): Use PREFIX.
14572 (error): In the IPA, an error causes an exit.
14573 (fatal, warning): Use PREFIX.
14574 (internal_error): Use TOOLNAME.
14575 (NUMCELLS): Increase to 10.
14576 * configure, config.in: Regenerate.
14578 2010-06-01 Pedro Alves <pedro@codesourcery.com>
14580 * server.c (handle_query) <qSupported>: Do two passes over the
14581 qSupported string to avoid nesting strtok.
14583 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
14585 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
14587 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
14588 -Wl,--dynamic-list.
14589 * configure: Regenerate.
14590 * proc-service.list: New.
14592 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
14594 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
14597 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
14599 * gdbreplay.c (remote_open): Check error return from socket() call by
14600 its equality to -1 not by it being negative.
14601 * remote-utils.c (remote_open): Likewise.
14603 2010-05-23 Pedro Alves <pedro@codesourcery.com>
14605 * config.h: Regenerate.
14607 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
14609 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
14610 doesn't provide PTRACE_GET_THREAD_AREA.
14612 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
14614 * linux-m68k-low.c: Include <asm/ptrace.h>
14615 (ps_get_thread_area): Implement.
14617 2010-05-03 Doug Evans <dje@google.com>
14619 * event-loop.c (struct callback_event): New struct.
14620 (callback_list): New global.
14621 (append_callback_event, delete_callback_event): New functions.
14622 (process_callback): New function.
14623 (start_event_loop): Call it.
14624 * remote-utils.c (NOT_SCHEDULED): Define.
14625 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
14626 moved out of readchar.
14627 (readchar): Rewrite. Call reschedule before returning.
14628 (reset_readchar): New function.
14629 (remote_close): Call it.
14630 (process_remaining, reschedule): New functions.
14631 * server.h (callback_handler_func): New typedef.
14632 (append_callback_event, delete_callback_event): Declare.
14634 2010-05-03 Pedro Alves <pedro@codesourcery.com>
14636 * proc-service.c (ps_pglobal_lookup): Use
14637 thread_db_look_up_one_symbol.
14638 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
14639 parameter. Use it instead of all_symbols_looked_up.
14640 * server.h (struct process_info) <all_symbols_looked_up>: Delete
14642 (all_symbols_looked_up): Don't declare.
14643 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
14644 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
14646 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
14647 Set all_symbols_looked_up here.
14648 (thread_db_look_up_one_symbol): New.
14649 (thread_db_get_tls_address): Adjust.
14650 (thread_db_load_search, try_thread_db_load_1): Always allocate the
14651 thread_db object on the heap, and tentatively set it in the
14653 (thread_db_init): Don't set all_symbols_looked_up here.
14654 * linux-low.h (thread_db_look_up_one_symbol): Declare.
14656 2010-05-03 Pedro Alves <pedro@codesourcery.com>
14658 * linux-low.c (linux_kill, linux_detach): Adjust.
14659 (status_pending_p_callback): Remove redundant statement. Check
14660 for !TARGET_WAITIKIND_IGNORE, instead of
14661 TARGET_WAITKIND_STOPPED.
14662 (handle_tracepoints): Make sure LWP is locked. Adjust.
14663 (linux_wait_for_event_1): Adjust.
14664 (linux_cancel_breakpoints): New.
14665 (unsuspend_one_lwp): New.
14666 (unsuspend_all_lwps): New.
14667 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
14668 (send_sigstop_callback): Change return type to int, add new
14669 `except' parameter and handle it.
14670 (suspend_and_send_sigstop_callback): New.
14671 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
14672 pass them down. If SUSPEND, also increment the lwp's suspend
14674 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
14675 (need_step_over_p): Don't consider suspended LWPs.
14676 (start_step_over): Adjust.
14677 (proceed_one_lwp): Change return type to int, add new `except'
14678 parameter and handle it.
14679 (unsuspend_and_proceed_one_lwp): New.
14680 (proceed_all_lwps): Use find_inferior instead of
14682 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
14683 also decrement the suspend count of LWPs. Pass `except' down,
14684 instead of hacking its suspend count.
14685 (linux_pause_all): Add `freeze' parameter. Adjust.
14686 (linux_unpause_all): New.
14687 (linux_target_ops): Install linux_unpause_all.
14688 * server.c (handle_status): Adjust.
14689 * target.h (struct target_ops): New fields `unpause_all' and
14690 `cancel_breakpoints'. Add new parameter to `pause_all'.
14691 (pause_all): Add new `freeze' parameter.
14692 (unpause_all): New.
14693 (cancel_breakpoints): New.
14694 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
14695 cancel breakpoints.
14696 (cmd_qtstart): Pause threads.
14697 (stop_tracing): Pause threads, and cancel breakpoints.
14698 * win32-low.c (win32_target_ops): Adjust.
14700 2010-05-03 Pedro Alves <pedro@codesourcery.com>
14702 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
14703 the inferior right away from here...
14704 (linux_wait_1): ... to here, and adjust to check the thread's
14705 last_resume_kind instead of the lwp's step or stop_expected flags.
14707 2010-05-02 Pedro Alves <pedro@codesourcery.com>
14709 * README: Use consistent `GDB' and `GDBserver' spellings.
14711 2010-05-02 Pedro Alves <pedro@codesourcery.com>
14713 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
14714 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
14715 (linux_detach_one_lwp): Assume the lwp is stopped.
14716 (any_thread_of): Delete.
14717 (linux_detach): Stop all lwps here. Don't blindly delete all
14719 (delete_lwp_callback): New.
14720 (linux_mourn): Delete all lwps of the process that is gone.
14721 (linux_wait_1): Don't delete the last lwp of the process here.
14722 * mem-break.h (mark_breakpoints_out): Declare.
14723 * mem-break.c (mark_breakpoints_out): New.
14724 (free_all_breakpoints): Use it.
14725 * server.c (handle_target_event): If the process is gone, mark
14727 * thread-db.c (struct thread_db) <create_bp>: New field.
14728 (thread_db_enable_reporting): Fix prototype. Store a thread event
14729 breakpoint reference in the thread_db struct.
14730 (thread_db_load_search): Clear the thread_db object.
14731 (try_thread_db_load_1): Ditto.
14732 (switch_to_process): New.
14733 (disable_thread_event_reporting): Use it.
14734 (remove_thread_event_breakpoints): New.
14735 (thread_db_detach, thread_db_mourn): Use it.
14737 2010-05-01 Pedro Alves <pedro@codesourcery.com>
14739 * linux-low.c (linux_enable_event_reporting): New.
14740 (linux_wait_for_event_1, handle_extended_wait): Use it.
14742 2010-04-30 Pedro Alves <pedro@codesourcery.com>
14744 * linux-low.c (linux_kill_one_lwp, linux_kill)
14745 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
14746 (send_sigstop): Take an lwp_info as parameter instead. Queue a
14747 SIGSTOP even if the LWP is stopped.
14748 (send_sigstop_callback): New.
14749 (stop_all_lwps): Use send_sigstop_callback instead.
14750 (linux_resume_one_thread): Adjust.
14751 (proceed_one_lwp): Still proceed an LWP that the client has
14752 requested to stop, if we haven't reported it as stopped yet. Make
14753 sure that LWPs the client want stopped, have a pending SIGSTOP.
14755 2010-04-26 Doug Evans <dje@google.com>
14757 * server.c (handle_general_set): Make static.
14759 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
14760 Print received char after testing for error/eof instead of before.
14761 (input_interrupt): Tweak comment.
14763 2010-04-23 Doug Evans <dje@google.com>
14765 * server.c (start_inferior): Print inferior argv if --debug.
14767 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
14769 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
14770 * nto-x86-low.c: Include server.h
14772 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
14774 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
14775 be consistent with other sources of this directory.
14776 (init_registers_amd64): Correct name of source file of this function
14779 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
14781 * configure.srv (x86_64-*-mingw*): New configuration for Windows
14782 64-bit executables.
14784 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
14786 * win32-i386-low.c: Add 64-bit support.
14787 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
14788 (init_registers_amd64): Declare.
14789 (mappings): Add 64-bit version of array.
14790 (init_windows_x86): New function.
14791 (the_low_target): Change init_arch field to init_windows_x86.
14793 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
14795 * win32-low.c: Adapt to support also 64-bit architecture.
14796 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
14797 (get_image_name): Use SIZE_T type for local variable `done'.
14798 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
14799 (toolhelp_get_dll_name): Idem.
14800 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
14801 Use uintptr_t typecast to avoid warning.
14802 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
14803 (handle_exception): Use phex_nz to avoid warning.
14804 (win32_wait): Remove unused local variable `process'.
14806 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
14808 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
14811 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
14813 * configure.ac: Use `ws2_32' library for srv_mingw.
14814 * configure: Regenerate.
14815 * gdbreplay.c: Include winsock2.h instead of winsock.h.
14816 * remote-utils.c: Likewise.
14818 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
14820 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
14821 if __x86_64__ is defined.
14823 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
14825 * configure: Regenerate.
14827 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
14829 * server.c (handle_query): Handle 'qGetTIBAddr' query.
14830 * target.h (target_ops): New get_tib_address field.
14831 * win32-low.h (win32_thread_info): Add thread_local_base field.
14832 * win32-low.c (child_add_thread): Add tlb argument.
14833 Set thread_local_base field to TLB.
14834 (get_child_debug_event): Adapt to child_add_thread change.
14835 (win32_get_tib_address): New function.
14836 (win32_target_ops): Set get_tib_address field to
14837 win32_get_tib_address.
14838 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
14840 2010-04-12 Pedro Alves <pedro@codesourcery.com>
14842 * linux-low.c (linux_mourn): Also remove the process.
14843 * server.c (handle_target_event): Don't remove the process here.
14844 * nto-low.c (nto_mourn): New.
14845 (nto_target_ops): Install it.
14846 * spu-low.c (spu_mourn): New.
14847 (spu_target_ops): Install it.
14848 * win32-low.c (win32_mourn): New.
14849 (win32_target_ops): Install it.
14851 2010-04-12 Pedro Alves <pedro@codesourcery.com>
14853 * server.h (buffer_xml_printf): Remove redundant `;'.
14855 2010-04-12 Pedro Alves <pedro@codesourcery.com>
14857 * regcache.c (set_register_cache): Invalidate regcaches before
14858 changing the register cache layout.
14859 (regcache_invalidate_one): Allow a NULL regcache.
14860 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
14861 regcaches before changing the register cache layout or the target
14864 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
14866 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
14867 variable warning on Linux/x86-64.
14869 2010-04-11 Pedro Alves <pedro@codesourcery.com>
14871 GDBserver disconnected tracing support.
14873 * linux-low.c (linux_remove_process): Delete.
14874 (add_lwp): Don't set last_resume_kind here.
14875 (linux_kill): Use `mourn'.
14876 (linux_detach): Use `thread_db_detach', and `mourn'.
14877 (linux_mourn): New.
14878 (linux_attach_lwp_1): Adjust comment.
14879 (linux_attach): last_resume_kind moved the thread_info; adjust.
14880 (status_pending_p_callback): Adjust.
14881 (linux_wait_for_event_1): Adjust.
14882 (count_events_callback, select_singlestep_lwp_callback)
14883 (select_event_lwp_callback, cancel_breakpoints_callback)
14884 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
14885 (proceed_one_lwp): Adjust.
14886 (linux_async): Add debug output.
14887 (linux_thread_stopped): New.
14888 (linux_pause_all): New.
14889 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
14891 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
14892 (thread_db_free): Delete declaration.
14893 (thread_db_detach, thread_db_mourn): Declare.
14894 * thread-db.c (thread_db_init): Use thread_db_mourn.
14895 (thread_db_free): Delete, split in two.
14896 (disable_thread_event_reporting): New.
14897 (thread_db_detach): New.
14898 (thread_db_mourn): New.
14900 * server.h (struct thread_info) <last_resume_kind>: New field.
14901 <attached>: Add comment.
14902 <gdb_detached>: New field.
14903 (handler_func): Change return type to int.
14904 (handle_serial_event, handle_target_event): Ditto.
14905 (gdb_connected): Declare.
14907 (disconnected_tracing): Declare.
14908 (stop_tracing): Declare.
14910 * server.c (handle_query) <qSupported>: Report support for
14911 disconnected tracing.
14912 (queue_stop_reply_callback): Account for running threads.
14913 (gdb_wants_thread_stopped): New.
14914 (gdb_wants_all_threads_stopped): New.
14915 (gdb_reattached_process): New.
14916 (handle_status): Clear the `gdb_detached' flag of all processes.
14917 In all-stop, stop all threads.
14918 (main): Be sure to leave tfind mode. Handle disconnected tracing.
14919 (process_serial_event): If the remote connection breaks, or if an
14920 exit was forced with "monitor exit", force an event loop exit.
14921 Handle disconnected tracing on detach.
14922 (handle_serial_event): Adjust.
14923 (handle_target_event): If GDB isn't connected, forward events back
14924 to the inferior, unless the last process exited, in which case,
14925 exit gdbserver. Adjust interface.
14927 * remote-utils.c (remote_open): Don't block in accept. Instead
14928 register an event loop source on the listen socket file
14929 descriptor. Refactor bits into ...
14930 (listen_desc): ... this new global.
14931 (gdb_connected): ... this new function.
14932 (enable_async_notification): ... this new function.
14933 (handle_accept_event): ... this new function.
14934 (remote_close): Clear remote_desc.
14936 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
14938 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
14940 (mourn_inferior): Define.
14941 (target_process_qsupported): Avoid the dangling else problem.
14942 (thread_stopped): Define.
14943 (pause_all): Define.
14944 (target_waitstatus_to_string): Declare.
14945 * target.c (target_waitstatus_to_string): New.
14947 * tracepoint.c (tracing): Make extern.
14948 (disconnected_tracing): New.
14949 (stop_tracing): Make extern. Handle tracing stops due to GDB
14951 (cmd_qtdisconnected): New.
14952 (cmd_qtstatus): Report disconnected tracing status in trace reply.
14953 (handle_tracepoint_general_set): Handle QTDisconnected.
14955 * event-loop.c (event_handler_func): Change return type to int.
14956 (process_event): Bail out if the event handler wants the event
14958 (handle_file_event): Ditto.
14959 (start_event_loop): Bail out if the event handler wants the event
14962 * nto-low.c (nto_target_ops): Adjust.
14963 * spu-low.c (spu_wait): Don't remove the process here.
14964 (spu_target_ops): Adjust.
14965 * win32-low.c (win32_wait): Don't remove the process here.
14966 (win32_target_ops): Adjust.
14968 2010-04-11 Pedro Alves <pedro@codesourcery.com>
14970 * regcache.c (realloc_register_cache): Invalidate inferior's
14971 regcache before recreating it.
14973 2010-04-09 Pedro Alves <pedro@codesourcery.com>
14975 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
14977 2010-04-09 Stan Shebs <stan@codesourcery.com>
14978 Pedro Alves <pedro@codesourcery.com>
14980 * server.h (LONGEST): New.
14981 (struct thread_info) <while_stepping>: New field.
14982 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
14984 (initialize_tracepoint, handle_tracepoint_general_set)
14985 (handle_tracepoint_query, tracepoint_finished_step)
14986 (tracepoint_was_hit, release_while_stepping_state_list):
14987 (current_traceframe): Declare.
14988 * server.c (handle_general_set): Handle tracepoint packets.
14989 (read_memory): New.
14990 (write_memory): New.
14991 (handle_search_memory_1): Use read_memory.
14992 (handle_query): Report support for conditional tracepoints, trace
14993 state variables, and tracepoint sources. Handle tracepoint
14995 (main): Initialize the tracepoints module.
14996 (process_serial_event): Handle traceframe reads/writes.
14998 * linux-low.c (handle_tracepoints): New.
14999 (linux_wait_1): Call it.
15000 (linux_resume_one_lwp): Handle while-stepping.
15001 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
15002 (linux_target_ops): Install them.
15003 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
15005 * linux-x86-low.c (x86_supports_tracepoints): New.
15006 (the_low_target). Install it.
15008 * mem-break.h (delete_breakpoint): Declare.
15009 * mem-break.c (delete_breakpoint): Make external.
15011 * target.h (struct target_ops): Add `supports_tracepoints',
15012 `read_pc', and `write_pc' fields.
15013 (target_supports_tracepoints): Define.
15014 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
15017 * regcache.h (struct regcache) <registers_owned>: New field.
15018 (init_register_cache, regcache_cpy): Declare.
15019 (regcache_read_pc, regcache_write_pc): Declare.
15020 (register_cache_size): Declare.
15021 (supply_regblock): Declare.
15022 * regcache.c (init_register_cache): New.
15023 (new_register_cache): Use it.
15024 (regcache_cpy): New.
15025 (register_cache_size): New.
15026 (supply_regblock): New.
15027 (regcache_read_pc, regcache_write_pc): New.
15029 * tracepoint.c: New.
15031 * Makefile.in (OBS): Add tracepoint.o.
15032 (tracepoint.o): New rule.
15034 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
15036 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
15038 (i386-mmx.c): Likewise.
15039 (i386-mmx-linux.o): Likewise.
15040 (i386-mmx-linux.c): Likewise.
15042 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
15043 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
15044 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
15045 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
15047 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
15048 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
15049 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
15051 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
15053 * Makefile.in (clean): Updated.
15055 (i386-avx.c): Likewise.
15056 (i386-avx-linux.o): Likewise.
15057 (i386-avx-linux.c): Likewise.
15058 (amd64-avx.o): Likewise.
15059 (amd64-avx.c): Likewise.
15060 (amd64-avx-linux.o): Likewise.
15061 (amd64-avx-linux.c): Likewise.
15063 * configure.srv (srv_i386_regobj): Add i386-avx.o.
15064 (srv_i386_linux_regobj): Add i386-avx-linux.o.
15065 (srv_amd64_regobj): Add amd64-avx.o.
15066 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
15067 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
15068 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
15069 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
15070 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
15071 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
15072 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
15074 * i387-fp.c: Include "i386-xstate.h".
15076 (i387_cache_to_xsave): Likewise.
15077 (i387_xsave_to_cache): Likewise.
15078 (x86_xcr0): Likewise.
15080 * i387-fp.h (i387_cache_to_xsave): Likewise.
15081 (i387_xsave_to_cache): Likewise.
15082 (x86_xcr0): Likewise.
15084 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
15085 * linux-crisv32-low.c (target_regsets): Likewise.
15086 * linux-m68k-low.c (target_regsets): Likewise.
15087 * linux-mips-low.c (target_regsets): Likewise.
15088 * linux-ppc-low.c (target_regsets): Likewise.
15089 * linux-s390-low.c (target_regsets): Likewise.
15090 * linux-sh-low.c (target_regsets): Likewise.
15091 * linux-sparc-low.c (target_regsets): Likewise.
15092 * linux-xtensa-low.c (target_regsets): Likewise.
15094 * linux-low.c: Include <sys/uio.h>.
15095 (regsets_fetch_inferior_registers): Support nt_type.
15096 (regsets_store_inferior_registers): Likewise.
15097 (linux_process_qsupported): New.
15098 (linux_target_ops): Add linux_process_qsupported.
15100 * linux-low.h (regset_info): Add nt_type.
15101 (linux_target_ops): Add process_qsupported.
15103 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
15105 (init_registers_i386_avx_linux): New.
15106 (init_registers_amd64_avx_linux): Likewise.
15107 (xmltarget_i386_linux_no_xml): Likewise.
15108 (xmltarget_amd64_linux_no_xml): Likewise.
15109 (PTRACE_GETREGSET): Likewise.
15110 (PTRACE_SETREGSET): Likewise.
15111 (x86_fill_xstateregset): Likewise.
15112 (x86_store_xstateregset): Likewise.
15113 (use_xml): Likewise.
15114 (x86_linux_update_xmltarget): Likewise.
15115 (x86_linux_process_qsupported): Likewise.
15116 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
15117 (x86_arch_setup): Don't call init_registers_amd64_linux nor
15118 init_registers_i386_linux here. Call
15119 x86_linux_update_xmltarget.
15120 (the_low_target): Add x86_linux_process_qsupported.
15122 * server.c (handle_query): Call target_process_qsupported.
15124 * target.h (target_ops): Add process_qsupported.
15125 (target_process_qsupported): New.
15127 2010-04-03 Pedro Alves <pedro@codesourcery.com>
15129 * inferiors.c (add_thread): Set last_status kind to
15130 TARGET_WAITKIND_IGNORE.
15131 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
15132 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
15133 (linux_wait_1): Move `thread' local definition to block that uses
15134 it. Don't NULL initialize `event_child'.
15135 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
15136 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
15137 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
15139 2010-04-01 Pedro Alves <pedro@codesourcery.com>
15141 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
15142 an extended waitstatus, or by a watchpoint.
15143 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
15144 thread was stepping or has been stopped by a watchpoint.
15146 2010-04-01 Pedro Alves <pedro@codesourcery.com>
15148 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
15149 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
15150 of another, then delete the previous, and validate all
15152 (validate_inserted_breakpoint): New.
15153 (delete_disabled_breakpoints): New.
15154 (validate_breakpoints): New.
15155 (check_mem_read): Validate breakpoints before trusting their
15156 shadow. Delete disabled breakpoints.
15157 (check_mem_write): Validate breakpoints before trusting they
15158 should be inserted. Delete disabled breakpoints.
15159 * mem-break.h (validate_breakpoints):
15160 * server.c (handle_query): Validate breakpoints when we see a
15163 2010-04-01 Pedro Alves <pedro@codesourcery.com>
15165 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
15166 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
15167 if we could tell there's a GDB breakpoint at stop_pc.
15168 (need_step_over_p): Don't do a step over if we find a GDB
15169 breakpoint at the resume PC.
15171 * mem-break.c (struct raw_breakpoint): New.
15172 (enum bkpt_type): New type `gdb_breakpoint'.
15173 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
15174 fields. New field `raw'.
15175 (find_raw_breakpoint_at): New.
15176 (set_raw_breakpoint_at): Handle refcounting. Create a raw
15177 breakpoint instead.
15178 (set_breakpoint_at): Adjust.
15179 (delete_raw_breakpoint): New.
15180 (release_breakpoint): New.
15181 (delete_breakpoint): Rename to...
15182 (delete_breakpoint_1): ... this. Add proc parameter. Use
15183 release_breakpoint. Return ENOENT.
15184 (delete_breakpoint): Reimplement.
15185 (find_breakpoint_at): Delete.
15186 (find_gdb_breakpoint_at): New.
15187 (delete_breakpoint_at): Delete.
15188 (set_gdb_breakpoint_at): New.
15189 (delete_gdb_breakpoint_at): New.
15190 (gdb_breakpoint_here): New.
15191 (set_reinsert_breakpoint): Use release_breakpoint.
15192 (uninsert_breakpoint): Rename to ...
15193 (uninsert_raw_breakpoint): ... this.
15194 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
15195 (reinsert_raw_breakpoint): Change parameter type to
15197 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
15199 (check_breakpoints): Adjust. Use release_breakpoint.
15200 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
15201 (breakpoint_inserted_here): Ditto.
15202 (check_mem_read): Adjust to iterate over raw breakpoints instead.
15203 Don't trust the breakpoint's shadow if it is not inserted.
15204 (check_mem_write): Adjust to iterate over raw breakpoints instead.
15205 (delete_all_breakpoints): Adjust.
15206 (free_all_breakpoints): Mark all breakpoints as uninserted, and
15207 use delete_breakpoint_1.
15209 * mem-break.h (breakpoints_supported): Delete declaration.
15210 (set_gdb_breakpoint_at): Declare.
15211 (gdb_breakpoint_here): Declare.
15212 (delete_breakpoint_at): Delete.
15213 (delete_gdb_breakpoint_at): Declare.
15215 * server.h (struct raw_breakpoint): Forward declare.
15216 (struct process_info): New field `raw_breakpoints'.
15218 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
15221 2010-03-24 Pedro Alves <pedro@codesourcery.com>
15223 * linux-low.c (status_pending_p_callback): Fix comment.
15224 (linux_wait_for_event_1): Move most of the internal breakpoint
15225 handling from here...
15226 (linux_wait_1): ... to here.
15227 (count_events_callback): New.
15228 (select_singlestep_lwp_callback): New.
15229 (select_event_lwp_callback): New.
15230 (cancel_breakpoints_callback): New.
15231 (select_event_lwp): New.
15232 (linux_wait_1): Simplify internal breakpoint handling. Give equal
15233 priority to all LWPs that have had events that should be reported
15234 to the client. Cancel breakpoints when about to reporting the
15235 event to the client, not while stopping lwps. No longer cancel
15236 finished single-steps here.
15237 (cancel_finished_single_step): Delete.
15238 (cancel_finished_single_steps): Delete.
15240 2010-03-24 Pedro Alves <pedro@codesourcery.com>
15242 * mem-break.c (enum bkpt_type): New.
15243 (struct breakpoint): New field `type'.
15244 (set_breakpoint_at): Change return type to struct breakpoint
15245 pointer. Set type to `other_breakpoint' by default.
15246 (delete_breakpoint): Rewrite, supporting more than one breakpoint
15247 in the breakpoint list.
15248 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
15249 (reinsert_breakpoint): Rename to ...
15250 (reinsert_raw_breakpoint): ... this.
15251 (reinsert_breakpoints_at): Adjust.
15252 * mem-break.h (struct breakpoint): Declare.
15253 (set_breakpoint_at): Change return type to struct breakpoint
15256 2010-03-24 Pedro Alves <pedro@codesourcery.com>
15258 * server.c (handle_query): Assign, not compare.
15260 2010-03-24 Pedro Alves <pedro@codesourcery.com>
15262 Teach linux gdbserver to step-over-breakpoints.
15264 * linux-low.c (can_hardware_single_step): New.
15265 (supports_breakpoints): New.
15266 (handle_extended_wait): If stopping threads, read the stop pc of
15267 the new cloned LWP.
15269 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
15270 low target doesn't support retrieving the PC.
15271 (add_lwp): Set last_resume_kind to resume_continue.
15272 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
15273 (linux_attach): Don't clear stop_expected. Set the lwp's
15274 last_resume_kind to resume_stop.
15275 (linux_detach_one_lwp): Don't check for removed breakpoints.
15276 (check_removed_breakpoint): Delete.
15277 (status_pending_p): Rename to ...
15278 (status_pending_p_callback): ... this. Don't check for removed
15279 breakpoints. Don't consider threads that are stopped from GDB's
15281 (linux_wait_for_lwp): Always read the stop_pc here.
15282 (cancel_breakpoint): New.
15283 (step_over_bkpt): New global.
15284 (linux_wait_for_event_1): Implement stepping over breakpoints.
15285 (gdb_wants_lwp_stopped): New.
15286 (gdb_wants_all_stopped): New.
15287 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
15288 single-step traps here. Store the thread's last reported target
15290 (send_sigstop): Don't clear stop_expected. Always set it,
15292 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
15293 (cancel_finished_single_step): New.
15294 (cancel_finished_single_steps): New.
15295 (wait_for_sigstop): Don't cancel finished single-step traps here.
15296 (linux_resume_one_lwp): Don't check for removed breakpoints.
15297 Don't set `step' on non-hardware step archs.
15298 (linux_set_resume_request): Ignore resume_stop requests if already
15299 stopping or stopped. Set the lwp's last_resume_kind.
15300 (resume_status_pending_p): Don't check for removed breakpoints.
15301 (need_step_over_p): New.
15302 (start_step_over): New.
15303 (finish_step_over): New.
15304 (linux_resume_one_thread): Always queue a sigstop for resume_stop
15305 requests. Clear the thread's last reported target waitstatus.
15306 Don't use the `suspended' flag. Don't consider pending breakpoints.
15307 (linux_resume): Start a step-over if necessary.
15308 (proceed_one_lwp): New.
15309 (proceed_all_lwps): New.
15310 (unstop_all_lwps): New.
15311 * linux-low.h (struct lwp_info): Rewrite comment for the
15312 `suspended' flag. Add the `stop_pc' field. Delete the
15313 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
15314 Add `'last_resume_kind' and `need_step_over' fields.
15315 * inferiors.c (struct thread_info): Delete, moved elsewhere.
15316 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
15317 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
15318 (set_raw_breakpoint_at): New.
15319 (set_breakpoint_at): Rewrite to use it.
15320 (reinsert_breakpoint_handler): Delete.
15321 (set_reinsert_breakpoint): New.
15322 (reinsert_breakpoint_by_bp): Delete.
15323 (delete_reinsert_breakpoints): New.
15324 (uninsert_breakpoint): Rewrite.
15325 (uninsert_breakpoints_at): New.
15326 (reinsert_breakpoint): Rewrite.
15327 (reinsert_breakpoints_at): New.
15328 (check_breakpoints): Rewrite.
15329 (breakpoint_here): New.
15330 (breakpoint_inserted_here): New.
15331 (check_mem_read): Adjust.
15332 * mem-break.h (breakpoints_supported, breakpoint_here)
15333 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
15334 (reinsert_breakpoint_by_bp): Delete declaration.
15335 (delete_reinsert_breakpoints): Declare.
15336 (reinsert_breakpoint): Delete declaration.
15337 (reinsert_breakpoints_at): Declare.
15338 (uninsert_breakpoint): Delete declaration.
15339 (uninsert_breakpoints_at): Declare.
15340 (check_breakpoints): Adjust prototype.
15341 * server.h: Adjust include order.
15342 (struct thread_info): Declare here. Add a `last_status' field.
15344 2010-03-23 Michael Snyder <msnyder@vmware.com>
15346 * server.c (crc32): New function.
15347 (handle_query): Add handling for 'qCRC:' request.
15349 2010-03-23 Pedro Alves <pedro@codesourcery.com>
15351 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
15352 lwp had been stopped by a watchpoint.
15354 2010-03-16 Pedro Alves <pedro@codesourcery.com>
15356 * server.h (internal_error): Declare.
15357 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
15358 * utils.c (internal_error): New function.
15360 2010-03-15 Andreas Schwab <schwab@redhat.com>
15362 * configure.srv: Fix typo setting srv_regobj.
15364 2010-03-15 Pedro Alves <pedro@codesourcery.com>
15366 * linux-low.c (fetch_register): Avoid passing a non string literal
15368 (usr_store_inferior_registers): Ditto.
15370 2010-03-14 Pedro Alves <pedro@codesourcery.com>
15372 * linux-low.c (linux_write_memory): Bail out early if peeking
15375 2010-03-14 Pedro Alves <pedro@codesourcery.com>
15377 * linux-low.h (struct lwp_info): New fields
15378 `stopped_by_watchpoint' and `stopped_data_address'.
15379 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
15380 here, and cache them in the lwp object.
15381 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
15383 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
15385 (linux_stopped_by_watchpoint): Rewrite.
15386 (linux_stopped_data_address): Rewrite.
15388 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
15390 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
15391 switching the current inferior, not before.
15393 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
15395 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
15396 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
15397 i386-linux.c and amd64-linux.c.
15398 (reg-i386.o): Removed.
15399 (reg-i386.c): Likewise.
15400 (reg-i386-linux.o): Likewise.
15401 (reg-i386-linux.c): Likewise.
15402 (reg-x86-64.o): Likewise.
15403 (reg-x86-64.c): Likewise.
15404 (reg-x86-64-linux.o): Likewise.
15405 (reg-x86-64-linux.c): Likewise.
15407 (i386.c): Likewise.
15408 (i386-linux.o): Likewise.
15409 (i386-linux.c): Likewise.
15410 (amd64.o): Likewise.
15411 (amd64.c): Likewise.
15412 (amd64-linux.o): Likewise.
15413 (amd64-linux.c): Likewise.
15415 * configure.srv (srv_i386_regobj): New.
15416 (srv_i386_linux_regobj): Likewise.
15417 (srv_amd64_regobj): Likewise.
15418 (srv_amd64_linux_regobj): Likewise.
15419 (srv_i386_32bit_xmlfiles): Likewise.
15420 (srv_i386_64bit_xmlfiles): Likewise.
15421 (srv_i386_xmlfiles): Likewise.
15422 (srv_amd64_xmlfiles): Likewise.
15423 (srv_i386_linux_xmlfiles): Likewise.
15424 (srv_amd64_linux_xmlfiles): Likewise.
15425 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
15426 srv_xmlfiles to $srv_i386_xmlfiles.
15427 (i[34567]86-*-mingw32ce*): Likewise.
15428 (i[34567]86-*-mingw*): Likewise.
15429 (i[34567]86-*-nto*): Likewise.
15430 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
15431 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
15432 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
15433 (x86_64-*-linux*): Likewise.
15435 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
15436 (init_registers_amd64_linux): New.
15437 (x86_arch_setup): Replace init_registers_x86_64_linux with
15438 init_registers_amd64_linux.
15440 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
15442 * configure.ac: Check for libdl. If it is not available link against
15443 static libthread_db.
15444 * configure: Regenerate.
15446 2010-02-22 Pedro Alves <pedro@codesourcery.com>
15450 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
15451 handing a read watchpoint.
15452 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
15454 2010-02-12 Doug Evans <dje@google.com>
15456 * linux-low.c (linux_supports_tracefork_flag): Document.
15457 (linux_look_up_symbols): Add comment.
15459 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
15461 * regcache.c (supply_register): Clear regcache if buf is NULL.
15463 2010-02-02 Nicolas Roche <roche@sourceware.org>
15464 Joel Brobecker <brobecker@adacore.com>
15466 * inferiors.c (find_inferior): Add function documentation.
15467 (unloaded_dll): Handle the case where the unloaded dll has not
15468 been previously registered in the dll list.
15470 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
15472 * linux-arm-low.c (thumb_breakpoint_len): Delete.
15473 (thumb2_breakpoint): New.
15474 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
15476 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
15478 * linux-low.c (get_stop_pc): Check for SIGTRAP.
15479 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
15482 2010-01-21 Pedro Alves <pedro@codesourcery.com>
15484 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
15486 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
15488 * linux-s390-low.c (s390_collect_ptrace_register)
15489 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
15491 2010-01-21 Doug Evans <dje@google.com>
15493 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
15494 (PTRACE_ARG4_TYPE): New macro.
15495 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
15496 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
15497 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
15498 (usr_store_inferior_registers): Ditto.
15499 (linux_read_memory, linux_write_memory): Ditto.
15500 (linux_test_for_tracefork): Ditto.
15502 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
15503 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
15505 2010-01-21 Pedro Alves <pedro@codesourcery.com>
15507 * proc-service.c (ps_lgetregs): Don't refetch registers from the
15510 2010-01-21 Pedro Alves <pedro@codesourcery.com>
15512 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
15513 prototype to take a regcache. Adjust.
15515 2010-01-20 Pedro Alves <pedro@codesourcery.com>
15517 * regcache.h (struct thread_info): Forward declare.
15518 (struct regcache): New.
15519 (new_register_cache): Adjust prototype.
15520 (get_thread_regcache): Declare.
15521 (free_register_cache): Adjust prototype.
15522 (registers_to_string, registers_from_string): Ditto.
15523 (supply_register, supply_register_by_name, collect_register)
15524 (collect_register_as_string, collect_register_by_name): Ditto.
15525 * regcache.c (struct inferior_regcache_data): Delete.
15526 (get_regcache): Rename to ...
15527 (get_thread_regcache): ... this. Adjust. Switch inferior before
15528 fetching registers.
15529 (regcache_invalidate_one): Adjust.
15530 (regcache_invalidate): Fix prototype.
15531 (new_register_cache): Return the new register cache.
15532 (free_register_cache): Change prototype.
15533 (realloc_register_cache): Adjust.
15534 (registers_to_string): Change prototype to take a regcache. Adjust.
15535 (registers_from_string): Ditto.
15536 (register_data): Ditto.
15537 (supply_register): Ditto.
15538 (supply_register_by_name): Ditto.
15539 (collect_register): Ditto.
15540 (collect_register_as_string): Ditto.
15541 (collect_register_by_name): Ditto.
15542 * server.c (process_serial_event): Adjust.
15543 * linux-low.h (regset_fill_func, regset_store_func): Change
15545 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
15547 * linux-low.c (get_stop_pc): Adjust.
15548 (check_removed_breakpoint): Adjust.
15549 (linux_wait_for_event): Adjust.
15550 (linux_resume_one_lwp): Adjust.
15551 (fetch_register): Add regcache parameter. Adjust.
15552 (usr_store_inferior_registers): Ditto.
15553 (regsets_fetch_inferior_registers): Ditto.
15554 (regsets_store_inferior_registers): Ditto.
15555 (linux_fetch_registers, linux_store_registers): Ditto.
15556 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
15558 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
15560 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
15561 prototype to take a regcache.
15562 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
15563 * remote-utils.c (convert_ascii_to_int, outreg)
15564 (prepare_resume_reply): Change prototype to take a regcache.
15566 * target.h (struct target_ops) <fetch_registers, store_registers>:
15567 Change prototype to take a regcache.
15568 (fetch_inferior_registers, store_inferior_registers): Change
15569 prototype to take a regcache. Adjust.
15570 * proc-service.c (ps_lgetregs): Adjust.
15571 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
15572 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
15573 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
15574 take a regcache. Adjust.
15575 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
15576 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
15577 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
15578 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
15579 * linux-cris-low.c (cris_get_pc, cris_set_pc)
15580 (cris_cannot_fetch_register):
15581 (cris_breakpoint_at): Change prototype to take a regcache.
15583 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
15584 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
15585 to take a regcache. Adjust.
15586 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
15588 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
15589 take a regcache. Adjust.
15590 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
15591 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
15592 (m68k_set_pc): Change prototype to take a regcache. Adjust.
15593 * linux-mips-low.c (mips_get_pc):
15594 (mips_set_pc): Change prototype to take a regcache. Adjust.
15595 (mips_reinsert_addr): Adjust.
15596 (mips_collect_register): Change prototype to take a regcache.
15598 (mips_supply_register):
15599 (mips_collect_register_32bit, mips_supply_register_32bit)
15600 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
15601 (mips_store_fpregset): Ditto.
15602 * linux-ppc-low.c (ppc_supply_ptrace_register)
15603 (ppc_supply_ptrace_register): Ditto.
15604 (parse_spufs_run): Adjust.
15605 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
15606 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
15607 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
15608 take a regcache. Adjust.
15609 * linux-s390-low.c (s390_collect_ptrace_register)
15610 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
15611 (s390_set_pc): Change prototype to take a regcache. Adjust.
15612 (s390_arch_setup): Adjust.
15613 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
15614 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
15615 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
15616 (sparc_fill_gregset, sparc_store_gregset_from_stack)
15617 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
15619 (sparc_breakpoint_at): Adjust.
15620 * linux-xtensa-low.c (xtensa_fill_gregset):
15621 (xtensa_store_gregset):
15622 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
15623 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
15624 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
15625 prototype to take a regcache. Adjust.
15626 * win32-arm-low.c (arm_fetch_inferior_register)
15627 (arm_store_inferior_register): Change prototype to take a
15629 * win32-i386-low.c (i386_fetch_inferior_register)
15630 (i386_store_inferior_register): Change prototype to take a
15632 * win32-low.c (child_fetch_inferior_registers)
15633 (child_store_inferior_registers): Change prototype to take a
15635 (win32_wait): Adjust.
15636 (win32_fetch_inferior_registers): Change prototype to take a
15638 (win32_store_inferior_registers): Adjust.
15639 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
15640 store_inferior_register>: Change prototype to take a regcache.
15642 2010-01-20 Doug Evans <dje@google.com>
15644 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
15646 (linux_wait_for_event1, linux_init_signals): Ditto.
15647 (W_STOPCODE): Provide definition if missing.
15649 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
15651 * linux-low.c (linux_core_of_thread): New.
15652 (compare_ints, show_process, list_threads): New.
15653 (linux_qxfer_osdata): Report threads and cores.
15654 (linux_target_op): Register linux_core_of_thread.
15655 * remote-utils.c (prepare_resume_reply): Report the core.
15656 (buffer_xml_printf): Support %d specifier.
15657 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
15659 (handle_query): Handle qXfer:threads. Announce availability
15661 * target.h (struct target_ops): New field core_of_thread.
15663 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
15665 * Makefile.in (clean): Remove new generated files.
15666 (reg-s390.o, reg-s390.c): Remove rules.
15667 (reg-s390x.o, reg-s390x.c): Likewise.
15668 (s390-linux32.o, s390-linux32.c): Add rules.
15669 (s390-linux64.o, s390-linux64.c): Likewise.
15670 (s390x-linux64.o, s390x-linux64.c): Likewise.
15671 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
15672 * linux-s390-low.c: Include <elf.h>.
15673 (HWCAP_S390_HIGH_GPRS): Define if undefined.
15674 (init_registers_s390): Remove prototype.
15675 (init_registers_s390x): Likewise.
15676 (init_registers_s390_linux32): Add prototype.
15677 (init_registers_s390_linux64): Likewise.
15678 (init_registers_s390x_linux64): Likewise.
15679 (s390_num_regs_3264): New define.
15680 (s390_regmap_3264): New global variable.
15681 (s390_cannot_fetch_register): Remove obsolete check.
15682 (s390_cannot_store_register): Likewise.
15683 (s390_collect_ptrace_register): Handle upper/lower register halves.
15684 (s390_supply_ptrace_register): Likewise.
15685 (s390_fill_gregset): Update to register number changes.
15686 (s390_get_hwcap): New routine.
15687 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
15688 Install appropriate regmap and register set.
15690 2010-01-01 Joel Brobecker <brobecker@adacore.com>
15692 * server.c (gdbserver_version): Update copyright year to 2010.
15693 * gdbreplay.c (gdbreplay_version): Likewise.
15695 2009-12-28 Doug Evans <dje@google.com>
15697 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
15698 elf/external.h. Include <elf.h> instead but only if necessary.
15700 2009-12-28 Pedro Alves <pedro@codesourcery.com>
15702 * linux-low.c (linux_remove_process): Remove `detaching'
15703 parameter. Don't release/detach from thread_db here.
15704 (linux_kill): Release/detach from thread_db here, ...
15705 (linux_detach): ... and here, before actually detaching.
15706 (linux_wait_1): ... and here, when a process exits.
15707 * thread-db.c (any_thread_of): New.
15708 (thread_db_free): Switch the current inferior to a thread of the
15711 2009-12-21 Doug Evans <dje@google.com>
15713 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
15715 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
15716 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
15717 warning ifndef __NR_tkill. Move setting of errno there too.
15718 Delete unnecessary resetting of errno after syscall.
15719 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
15721 * configure.ac: Check for dladdr.
15722 * config.in: Regenerate.
15723 * configure: Regenerate.
15724 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
15725 (try_thread_db_load): Update.
15727 * linux-low.c (my_waitpid): Delete unnecessary prototype.
15729 2009-12-18 Doug Evans <dje@google.com>
15731 * event-loop.c: Include unistd.h if it exists.
15733 * linux-low.c (my_waitpid): Move definition away from being in
15734 between linux_tracefork_child/linux_test_for_tracefork.
15736 * gdb_proc_service.h (psaddr_t): Fix type.
15737 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
15738 signature to match glibc.
15740 2009-12-16 Doug Evans <dje@google.com>
15742 * linux-low.c (linux_read_memory): Fix argument to read.
15744 2009-11-26 Pedro Alves <pedro@codesourcery.com>
15746 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
15747 events, don't leave current_inferior pointing at null.
15749 2009-11-26 Pedro Alves <pedro@codesourcery.com>
15751 * win32-low.c (LOG): Delete.
15752 (OUTMSG): Output to stderr.
15753 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
15754 on compile time LOG macro.
15755 (win32_wait): Fix debug output.
15757 2009-11-26 Pedro Alves <pedro@codesourcery.com>
15759 * win32-low.c (win32_add_one_solib): If the dll name is
15760 "ntdll.dll", prepend the system directory to the dll path.
15762 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
15764 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
15766 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
15767 Vladimir Prus <vladimir@codesourcery.com>
15769 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
15770 * configure.ac: Check for __mcoldfire__ and set
15771 gdb_cv_m68k_is_coldfire.
15772 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
15773 reg-cf.o and reg-m68k.o.
15774 * configure: Regenerated.
15776 2009-11-16 Pedro Alves <pedro@codesourcery.com>
15778 * linux-low.c (linux_remove_process): Add `detaching' parameter.
15779 Pass it to thread_db_free.
15780 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
15781 proper `detaching' argument to linux_remove_process.
15782 * linux-low.h (thread_db_free): Add `detaching' parameter.
15783 * thread-db.c (thread_db_init): Pass false as `detaching' argument
15785 (thread_db_free): Add `detaching' parameter. Only
15786 call td_ta_clear_event if detaching from process.
15788 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
15790 * thread-db.c (thread_db_free): Fix typo.
15792 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
15795 * thread-db.c (thread_db_free): Call td_ta_clear_event.
15797 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
15799 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
15800 with an i686 compiler.
15801 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
15803 * configure: Rebuilt.
15805 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
15809 * server.c (handle_search_memory_1): Correct read_addr initialization
15810 in loop for searching subsequent chunks.
15812 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
15814 * configure.ac: New --with-libthread-db option.
15815 * thread-db.c: Allow direct dependence on libthread_db.
15816 (thread_db_free): Adjust.
15817 * config.in: Regenerate.
15818 * configure: Likewise.
15820 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
15823 * thread-db.c (attach_thread): New function.
15824 (maybe_attach_thread): Return success/failure.
15825 (find_new_threads_callback): Adjust.
15826 (thread_db_find_new_threads): Loop until no new threads.
15828 2009-10-13 Pedro Alves <pedro@codesourcery.com>
15830 * proc-service.c (ps_lgetregs): Formatting.
15832 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
15834 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
15835 * configure.ac: Adjust.
15836 * linux-low.h (struct process_info_private): Move members to struct
15838 (thread_db_free, thread_db_handle_monitor_command): New prototype.
15839 * linux-low.c (linux_remove_process): Adjust.
15840 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
15841 * server.c (handle_query): Move code ...
15842 (handle_monitor_command): ... here. New function.
15843 * target.h (struct target_ops): New member.
15844 * thread-db.c (struct thread_db): New.
15845 (libthread_db_search_path): New variable.
15846 (thread_db_create_event, thread_db_enable_reporting)
15847 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
15848 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
15849 (try_thread_db_load_1, dladdr_to_soname): New functions.
15850 (try_thread_db_load, thread_db_load_search): New functions.
15851 (thread_db_init): Search for libthread_db.
15852 (thread_db_free): New function.
15853 (thread_db_handle_monitor_command): Likewise.
15854 * config.in: Regenerate.
15855 * configure: Regenerate.
15857 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
15859 * spu-low.c (spu_kill): Wait for inferior to terminate.
15860 Call clear_inferiors.
15861 (spu_detach): Call clear_inferiors.
15863 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15865 * aclocal.m4: Regenerate.
15866 * config.in: Likewise.
15867 * configure: Likewise.
15869 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
15871 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
15872 (parse_spufs_run): New function.
15873 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
15874 (ppc_breakpoint_at): Handle SPU breakpoints.
15876 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
15878 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
15879 (SPUFS_MAGIC): Define.
15880 (spu_enumerate_spu_ids): New function.
15881 (linux_qxfer_spu): New function.
15882 (linux_target_ops): Install linux_qxfer_spu.
15884 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
15886 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
15887 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
15888 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
15889 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
15890 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
15891 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
15892 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
15893 (init_registers_powerpc_cell32l): Add prototype.
15894 (init_registers_powerpc_cell64l): Likewise.
15895 (ppc_arch_setup): Detect Cell/B.E. architecture.
15897 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15899 * Makefile.in (datarootdir): New variable.
15901 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
15903 * linux-low.c (linux_write_memory): Update debugging output.
15904 * Makefile.in (clean): Add new descriptions.
15905 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
15906 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
15907 * configure.srv: Add new files for arm*-*-linux*.
15908 * linux-arm-low.c: Add new declarations.
15909 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
15910 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
15911 (HWCAP_VFPv3D16): New.
15912 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
15913 instead of __IWMMXT__.
15914 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
15915 (arm_arch_setup): New.
15916 (target_regsets): Remove #ifdef. Add VFP regset.
15917 (the_low_target): Use arm_arch_setup.
15919 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
15921 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
15922 the main thread again.
15924 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
15926 Adding Neutrino gdbserver.
15927 * configure: Regenerated.
15928 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
15929 * configure.srv (i[34567]86-*-nto*): New target.
15930 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
15931 * remote-utils.c [__QNX__]: Include sys/iomgr.h
15932 (nto_comctrl) [__QNX__]: New function.
15933 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
15935 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
15937 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
15940 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
15941 Pedro Alves <pedro@codesourcery.com>
15943 * win32-i386-low.c (i386_get_thread_context): Handle systems that
15944 don't support CONTEXT_EXTENDED_REGISTERS.
15945 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
15946 (the_low_target): Install them.
15947 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
15948 failing with ERROR_PIPE_NOT_CONNECTED.
15950 2009-06-30 Doug Evans <dje@google.com>
15951 Pierre Muller <muller@ics.u-strasbg.fr>
15953 Add h/w watchpoint support to x86-linux, win32-i386.
15954 * Makefile.in (SFILES): Add i386-low.c
15955 (i386_low_h): Define.
15956 (i386-low.o): Add dependencies.
15957 (linux-x86-low.o): Add i386-low.h dependency.
15958 (win32-i386-low.o): Ditto.
15959 * i386-low.c: New file.
15960 * i386-low.h: New file.
15961 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
15962 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
15963 * linux-low.c (linux_add_process): Initialize arch_private.
15964 (linux_remove_process): Free arch_private.
15965 (add_lwp): Initialize arch_private.
15966 (delete_lwp): Free arch_private.
15967 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
15969 * linux-low.h (process_info_private): New member arch_private.
15970 (lwp_info): New member arch_private.
15971 (linux_target_ops): New members new_process, new_thread,
15973 (ptid_of): New macro.
15974 * linux-x86-low.c: Include stddef.h, i386-low.h.
15975 (arch_process_info): New struct.
15976 (arch_lwp_info): New struct.
15977 (x86_linux_dr_get, x86_linux_dr_set): New functions.
15978 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
15979 (i386_dr_low_get_status): New function.
15980 (x86_insert_point, x86_remove_point): New functions.
15981 (x86_stopped_by_watchpoint): New function.
15982 (x86_stopped_data_address): New function.
15983 (x86_linux_new_process, x86_linux_new_thread): New functions.
15984 (x86_linux_prepare_to_resume): New function.
15985 (the_low_target): Add entries for insert_point, remove_point,
15986 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
15988 * server.c (debug_hw_points): New global.
15989 (monitor_show_help): Document set debug-hw-points.
15990 (handle_query): Process "set debug-hw-points".
15991 * server.h (debug_hw_points): Declare.
15992 (paddress): Declare.
15993 * utils.c (NUMCELLS, CELLSIZE): New macros.
15994 (get_sell, xsnprintf, paddress): New functions.
15995 * win32-arm-low.c (the_low_target): Add entries for insert_point,
15996 remove_point, stopped_by_watchpoint, stopped_data_address.
15997 * win32-i386-low.c: Include i386-low.h.
15998 (debug_reg_state): Replaces dr.
15999 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
16000 (i386_dr_low_get_status): New function.
16001 (i386_insert_point, i386_remove_point): New functions.
16002 (i386_stopped_by_watchpoint): New function.
16003 (i386_stopped_data_address): New function.
16004 (i386_initial_stuff): Update.
16005 (get_thread_context,set_thread_context,i386_thread_added): Update.
16006 (the_low_target): Add entries for insert_point,
16007 remove_point, stopped_by_watchpoint, stopped_data_address.
16008 * win32-low.c (win32_insert_watchpoint): New function.
16009 (win32_remove_watchpoint): New function.
16010 (win32_stopped_by_watchpoint): New function.
16011 (win32_stopped_data_address): New function.
16012 (win32_target_ops): Add entries for insert_watchpoint,
16013 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
16014 * win32-low.h (win32_target_ops): New members insert_point,
16015 remove_point, stopped_by_watchpoint, stopped_data_address.
16017 2009-06-25 Pedro Alves <pedro@codesourcery.com>
16019 * server.c (process_serial_event): Re-return unsupported, not
16020 error, if the type isn't recognized. Re-allow supporting only
16021 insert or remove packets. Also call require_running for
16022 breakpoints. Add missing break statement to default case. Tidy.
16023 * target.h (struct target_ops): Rename insert_watchpoint to
16024 insert_point, and remove_watchpoint to remove_point.
16026 * linux-low.h (struct linux_target_ops): Likewise.
16027 * linux-low.c (linux_insert_watchpoint): Rename to ...
16028 (linux_insert_point): ... this. Adjust.
16029 (linux_remove_watchpoint): Rename to ...
16030 (linux_remove_point): ... this. Adjust.
16031 (linux_target_ops): Adjust.
16032 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
16033 (cris_insert_point): ... this.
16034 (cris_remove_watchpoint): Rename to ...
16035 (cris_remove_point): ... this.
16036 (the_low_target): Adjust.
16038 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
16040 * server.c (handle_v_kill): Pass signal_pid to
16041 kill_inferior if multi_process is zero.
16043 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
16045 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
16046 * target.h (target_ops): Comment for *_watchpoint to make it clear
16047 the functions can get types '0' and '1'.
16049 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
16051 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
16052 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
16053 * regcache.c (get_regcache): Likewise.
16054 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
16055 * win32-low.c (child_fetch_inferior_registers): Remove check for
16058 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
16059 Pedro Alves <pedro@codesourcery.com>
16061 * target.h (struct target_ops) <supports_multi_process>: New
16063 (target_supports_multi_process): New.
16064 * server.c (handle_query): Even if GDB reports support, only
16065 enable multi-process if the target also supports it. Report
16066 multi-process support only if the target backend supports it.
16067 * linux-low.c (linux_supports_multi_process): New function.
16068 (linux_target_ops): Install it as target_supports_multi_process
16071 2009-05-24 Doug Evans <dje@google.com>
16073 Global renaming of find_thread_pid to find_thread_ptid.
16074 * server.h (find_thread_ptid): Renamed from find_thread_pid.
16075 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
16076 All callers updated.
16078 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
16079 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
16082 * linux-low.c (get_stop_pc): Print pc if debug_threads.
16083 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
16084 (linux_resume_one_lwp): Ditto.
16086 2009-05-23 Doug Evans <dje@google.com>
16088 * linux-low.c (linux_resume_one_lwp): Change type of first arg
16089 from struct inferior_list_entry * to struct lwp_info *.
16090 All callers updated.
16092 2009-05-13 Doug Evans <dje@google.com>
16094 * linux-x86-low.c: Don't include assert.h.
16095 (x86_siginfo_fixup): Use fatal, not assert.
16096 (x86_arch_setup): Fix comment.
16098 2009-05-12 Doug Evans <dje@google.com>
16100 Biarch support for i386/amd64 gdbserver.
16101 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
16102 Add linux-x86-low.c.
16103 (linux-i386-low.o, linux-x86-64-low.o): Delete.
16104 (linux-x86-low.o): Add.
16105 * linux-x86-64-low.c: Delete.
16106 * linux-i386-low.c: Delete.
16107 * linux-x86-low.c: New file.
16108 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
16110 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
16112 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
16113 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
16114 (linux_child_pid_to_exec_file): New function.
16115 (elf_64_header_p, elf_64_file_p): New functions.
16116 (siginfo_fixup): New function.
16117 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
16118 give target a chance to convert layout.
16119 * linux-low.h (linux_target_ops): New member siginfo_fixup.
16120 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
16122 2009-05-07 Doug Evans <dje@google.com>
16124 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
16125 (regsets_store_inferior_registers): Ditto.
16127 2009-05-06 Pedro Alves <pedro@codesourcery.com>
16131 * linux-low.c (must_set_ptrace_flags): Delete.
16132 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
16134 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
16135 `lwp->must_set_ptrace_flags' instead.
16136 (linux_wait_for_event_1): Set ptrace options here.
16137 (linux_wait_1): ... not here.
16139 2009-04-30 Doug Evans <dje@google.com>
16141 * inferiors.c (started_inferior_callback): New function.
16142 (attached_inferior_callback): New function.
16143 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
16144 * server.c (print_started_pid, print_attached_pid): New functions.
16145 (detach_or_kill_for_exit): New function.
16146 (main): Call it instead of for_each_inferior (kill_inferior_callback).
16147 * server.h (have_started_inferiors_p): Declare.
16148 (have_attached_inferiors_p): Declare.
16150 * inferiors.c (remove_process): Fix memory leak, free process.
16151 * linux-low.c (linux_remove_process): New function.
16152 (linux_kill): Call it instead of remove_process.
16153 (linux_detach, linux_wait_1): Ditto.
16155 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
16157 * configure.srv: Add x86 Windows CE target.
16159 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
16161 * inferiors.c (get_thread_process): Make global.
16162 * server.h (get_thread_process): Add prototype.
16163 * thread-db.c (find_one_thread): Use get_thread_process
16164 instead of current_process.
16165 (thread_db_get_tls_address): Do not crash if called when
16166 thread layer is not yet initialized.
16168 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
16170 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
16171 * spu-low.c (current_tid): Rename to ...
16172 (current_ptid): ... this.
16173 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
16174 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
16175 ptid_get_lwp (current_ptid) instead of current_tid.
16176 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
16177 instead of current_tid. Use find_process_pid to verify pid
16178 argument is valid. Pass proper argument to remove_process.
16179 (spu_thread_alive): Compare current_ptid instead of current_tid.
16180 (spu_resume): Likewise.
16182 2009-04-02 Pedro Alves <pedro@codesourcery.com>
16184 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
16187 2009-04-01 Pedro Alves <pedro@codesourcery.com>
16189 Implement the multiprocess extensions, and add linux multiprocess
16192 * server.h (ULONGEST): Declare.
16193 (struct ptid, ptid_t): New.
16194 (minus_one_ptid, null_ptid): Declare.
16195 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
16196 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
16197 (struct inferior_list_entry): Change `id' type from unsigned from
16199 (struct sym_cache, struct breakpoint, struct
16200 process_info_private): Forward declare.
16201 (struct process_info): Declare.
16202 (current_process): Declare.
16203 (all_processes): Declare.
16204 (initialize_inferiors): Declare.
16205 (add_thread): Adjust to use ptid_t.
16206 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
16207 (add_process, remove_process, find_thread_pid): Declare.
16208 (find_inferior_id): Adjust to use ptid_t.
16209 (cont_thread, general_thread, step_thread): Change type to ptid_t.
16210 (multi_process): Declare.
16211 (push_event): Adjust to use ptid_t.
16212 (read_ptid, write_ptid): Declare.
16213 (prepare_resume_reply): Adjust to use ptid_t.
16214 (clear_symbol_cache): Declare.
16215 * inferiors.c (all_processes): New.
16216 (null_ptid, minus_one_ptid): New.
16217 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
16218 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
16219 (add_thread): Change unsigned long to ptid. Remove gdb_id
16221 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
16222 (gdb_id_to_thread): Rename to ...
16223 (find_thread_pid): ... this. Change unsigned long to ptid.
16224 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
16225 (loaded_dll, pull_pid_from_list): Adjust.
16226 (add_process, remove_process, find_process_pid)
16227 (get_thread_process, current_process, initialize_inferiors): New.
16228 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
16229 (struct target_waitstatus) <related_pid>: Ditto.
16230 (struct target_ops) <kill, detach>: Add `pid' argument. Change
16231 return type to int.
16232 (struct target_ops) <join>: Add `pid' argument.
16233 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
16234 (struct target_ops) <wait>: Add `ptid' field. Change return type
16236 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
16237 (mywait): Add `ptid' argument. Change return type to ptid_t.
16238 (target_pid_to_str): Declare.
16239 * target.c (set_desired_inferior): Adjust to use ptids.
16240 (mywait): Add new `ptid' argument. Adjust.
16241 (target_pid_to_str): New.
16242 * mem-break.h (free_all_breakpoints): Declare.
16243 * mem-break.c (breakpoints): Delelete.
16244 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
16245 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
16246 to use per-process breakpoint list.
16247 (free_all_breakpoints): New.
16248 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
16249 (symbol_cache, all_symbols_looked_up): Delete.
16251 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
16253 (prepare_resume_reply): Change ptid argument's type from unsigned
16254 long to ptid_t. Adjust. Implement W;process and X;process.
16255 (free_sym_cache, clear_symbol_cache): New.
16256 (look_up_one_symbol): Adjust to per-process symbol cache. *
16257 * server.c (cont_thread, general_thread, step_thread): Change type
16259 (attached): Delete.
16260 (multi_process): New.
16261 (last_ptid): Change type to ptid_t.
16262 (struct vstop_notif) <ptid>: Change type to ptid_t.
16263 (queue_stop_reply, push_event): Change `ptid' argument's type to
16265 (discard_queued_stop_replies): Add `pid' argument.
16266 (start_inferior): Adjust to use ptids. Adjust to mywait interface
16267 changes. Don't reference the `attached' global.
16268 (attach_inferior): Adjust to mywait interface changes.
16269 (handle_query): Adjust to use ptids. Parse GDB's qSupported
16270 features. Handle and report "multiprocess+". Handle
16272 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
16274 (handle_v_kill): New.
16275 (handle_v_stopped): Adjust to use target_pid_to_str.
16276 (handle_v_requests): Allow multiple attaches and runs when
16277 multiprocess extensions are in effect. Handle "vKill".
16278 (myresume): Adjust to use ptids.
16279 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
16280 (handle_status): Adjust to discard_queued_stop_replies interface
16282 (first_thread_of, kill_inferior_callback)
16283 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
16284 (main): Call initialize_inferiors. Adjust to use ptids, killing
16285 and detaching from all inferiors. Handle multiprocess packet
16287 * linux-low.h: Include gdb_proc_service.h.
16288 (struct process_info_private): New.
16289 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
16290 <lwpid_of>: Use ptid_get_lwp.
16291 (get_lwp_thread): Adjust.
16292 (struct lwp_info): Add `dead' member.
16293 (find_lwp_pid): Declare.
16294 * linux-low.c (thread_db_active): Delete.
16295 (new_inferior): Adjust comment.
16296 (inferior_pid): Delete.
16297 (linux_add_process): New.
16298 (handle_extended_wait): Adjust.
16299 (add_lwp): Change unsigned long to ptid.
16300 (linux_create_inferior): Add process to processes table. Adjust
16301 to use ptids. Don't set new_inferior here.
16302 (linux_attach_lwp): Rename to ...
16303 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
16304 it. Adjust to use ptids.
16305 (linux_attach_lwp): New.
16306 (linux_attach): Add process to processes table. Don't set
16308 (struct counter): New.
16309 (second_thread_of_pid_p, last_thread_of_process_p): New.
16310 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
16311 multiple processes.
16312 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
16313 processes. Remove process from process table.
16314 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
16315 to multiple processes.
16316 (any_thread_of): New.
16317 (linux_detach): Add `pid' argument, and handle it. Remove process
16318 from processes table.
16319 (linux_join): Add `pid' argument. Handle it.
16320 (linux_thread_alive): Change unsighed long argument to ptid_t.
16321 Consider dead lwps as not being alive.
16322 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
16323 threads we're not interested in.
16324 (same_lwp, find_lwp_pid): New.
16325 (linux_wait_for_lwp): Change `pid' argument's type from int to
16327 (linux_wait_for_event): Rename to ...
16328 (linux_wait_for_event_1): ... this. Change `pid' argument's type
16329 from int to ptid_t. Adjust.
16330 (linux_wait_for_event): New.
16331 (linux_wait_1): Add `ptid' argument. Change return type to
16332 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
16333 that exit from the process table.
16334 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
16336 (mark_lwp_dead): New.
16337 (wait_for_sigstop): Adjust to use ptids. If a process exits while
16338 stopping all threads, mark its main lwp as dead.
16339 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
16341 (fetch_register, usr_store_inferior_registers)
16342 (regsets_fetch_inferior_registers)
16343 (regsets_store_inferior_registers, linux_read_memory)
16344 (linux_write_memory): Inline `inferior_pid'.
16345 (linux_look_up_symbols): Adjust to use per-process
16346 `thread_db_active'.
16347 (linux_request_interrupt): Adjust to use ptids.
16348 (linux_read_auxv): Inline `inferior_pid'.
16349 (initialize_low): Don't reference thread_db_active.
16350 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
16351 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
16352 (ps_getpid): Return the pid of the current inferior.
16353 * thread-db.c (proc_handle, thread_agent): Delete.
16354 (thread_db_create_event, thread_db_enable_reporting): Adjust to
16356 (find_one_thread): Change argument type to ptid_t. Adjust to
16358 (maybe_attach_thread): Adjust to per-process data and ptids.
16359 (thread_db_find_new_threads): Ditto.
16360 (thread_db_init): Ditto.
16361 * spu-low.c (spu_create_inferior, spu_attach): Add process to
16362 processes table. Adjust to use ptids.
16363 (spu_kill, spu_detach): Adjust interface. Remove process from
16365 (spu_join, spu_thread_alive): Adjust interface.
16366 (spu_wait): Adjust interface. Remove process from processes
16367 table. Adjust to use ptids.
16368 * win32-low.c (current_inferior_tid): Delete.
16369 (current_inferior_ptid): New.
16370 (debug_event_ptid): New.
16371 (thread_rec): Take a ptid. Adjust.
16372 (child_add_thread): Add `pid' argument. Adjust to use ptids.
16373 (child_delete_thread): Ditto.
16374 (do_initial_child_stuff): Add `attached' argument. Add process to
16376 (child_fetch_inferior_registers, child_store_inferior_registers):
16378 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
16379 (win32_attach): Pass 1 to do_initial_child_stuff.
16380 (win32_kill): Adjust interface. Remove process from processes
16382 (win32_detach): Ditto.
16383 (win32_join): Adjust interface.
16384 (win32_thread_alive): Take a ptid.
16385 (win32_resume): Adjust to use ptids.
16386 (get_child_debug_event): Ditto.
16387 (win32_wait): Adjust interface. Remove exiting process from
16390 2009-04-01 Pedro Alves <pedro@codesourcery.com>
16392 Non-stop mode support.
16394 * server.h (non_stop): Declare.
16395 (gdb_client_data, handler_func): Declare.
16396 (delete_file_handler, add_file_handler, start_event_loop):
16398 (handle_serial_event, handle_target_event, push_event)
16399 (putpkt_notif): Declare.
16400 * target.h (enum resume_kind): New.
16401 (struct thread_resume): Replace `step' field by `kind' field.
16402 (TARGET_WNOHANG): Define.
16403 (struct target_ops) <wait>: Add `options' argument.
16404 <supports_non_stop, async, start_non_stop>: New fields.
16405 (target_supports_non_stop, target_async): New.
16406 (start_non_stop): Declare.
16407 (mywait): Add `options' argument.
16408 * target.c (mywait): Add `options' argument. Print child exit
16409 notifications here.
16410 (start_non_stop): New.
16411 * server.c (non_stop, own_buf, mem_buf): New globals.
16412 (struct vstop_notif): New.
16413 (notif_queue): New global.
16414 (queue_stop_reply, push_event, discard_queued_stop_replies)
16415 (send_next_stop_reply): New.
16416 (start_inferior): Adjust to use resume_kind. Adjust to mywait
16418 (attach_inferior): In non-stop mode, don't wait for the target
16420 (handle_general_set): Handle QNonStop.
16421 (handle_query): When handling qC, return the current general
16422 thread, instead of the first thread of the list.
16423 (handle_query): If the backend supports non-stop mode, include
16424 QNonStop+ in the qSupported query response.
16425 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
16427 (handle_v_attach, handle_v_run): Handle non-stop mode.
16428 (handle_v_stopped): New.
16429 (handle_v_requests): Report support for vCont;t. Handle vStopped.
16430 (myresume): Adjust to use resume_kind. Handle non-stop.
16431 (queue_stop_reply_callback): New.
16432 (handle_status): Handle non-stop mode.
16433 (main): Clear non_stop flag on reconnection. Use the event-loop.
16434 Refactor serial protocol handling from here ...
16435 (process_serial_event): ... to this new function. When GDB
16436 selects any thread, select one here. In non-stop mode, wait until
16437 GDB acks all pending events before exiting.
16438 (handle_serial_event, handle_target_event): New.
16439 * remote-utils.c (remote_open): Install remote_desc in the event
16441 (remote_close): Remove remote_desc from the event loop.
16442 (putpkt_binary): Rename to...
16443 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
16444 (putpkt_binary): New as wrapper around putpkt_binary_1.
16445 (putpkt_notif): New.
16446 (prepare_resume_reply): In non-stop mode, don't change the
16448 * event-loop.c: New.
16449 * Makefile.in (OBJ): Add event-loop.o.
16450 (event-loop.o): New rule.
16452 * linux-low.h (pid_of): Moved here.
16454 (get_lwp_thread): Use lwpid_of.
16455 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
16456 * linux-low.c (pid_of): Delete.
16457 (inferior_pid): Use lwpid_of.
16458 (linux_event_pipe): New.
16459 (target_is_async_p): New.
16461 (handle_extended_wait): Use lwpid_of.
16462 (add_lwp): Don't set lwpid field.
16463 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
16464 (linux_kill_one_lwp): If killing a running lwp, stop it first.
16465 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
16466 (linux_detach_one_lwp): If detaching from a running lwp, stop it
16467 first. Adjust to linux_wait_for_event interface changes. Use
16469 (linux_detach): Don't delete the main lwp here.
16470 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
16471 (status_pending_p): Don't consider explicitly suspended lwps.
16472 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
16473 pointer. Add OPTIONS argument. Change return type to int. Use
16474 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
16475 (linux_wait_for_event): Take an integer pid instead of a lwp_info
16476 pointer. Add status pointer argument. Return a pid instead of a
16477 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
16478 changes. In non-stop mode, don't switch to a random thread.
16479 (linux_wait): Rename to...
16480 (linux_wait_1): ... this. Add target_options argument, and handle
16481 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
16482 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
16483 clean exit and signal exit code. Don't stop all threads in
16484 non-stop mode. In all-stop mode, only stop all threads when
16485 reporting a stop to GDB. Handle explicit thread stop requests.
16486 (async_file_flush, async_file_mark): New.
16488 (send_sigstop): Use lwpid_of.
16489 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
16490 interface changes. In non-stop mode, don't switch to a random
16492 (linux_resume_one_lwp): Use lwpid_of.
16493 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
16494 (linux_resume_one_thread): ... this. Handle resume_stop. In
16495 non-stop mode, don't look for pending flag in all threads.
16496 (resume_status_pending_p): Don't consider explicitly suspended
16498 (my_waitpid): Reimplement. Emulate __WALL.
16499 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
16501 (sigchld_handler, linux_supports_non_stop, linux_async)
16502 (linux_start_non_stop): New.
16503 (linux_target_ops): Register linux_supports_non_stop, linux_async
16504 and linux_start_non_stop.
16505 (initialize_low): Install SIGCHLD handler.
16506 * thread-db.c (thread_db_create_event, find_one_thread)
16507 (thread_db_get_tls_address): Use lwpid_of.
16508 * win32-low.c (win32_detach): Adjust to use resume_kind.
16509 (win32_wait): Add `options' argument.
16510 * spu-low.c (spu_resume): Adjust to use resume_kind.
16511 (spu_wait): Add `options' argument.
16513 2009-04-01 Pedro Alves <pedro@codesourcery.com>
16515 Decouple target code from remote protocol.
16517 * target.h (enum target_waitkind): New.
16518 (struct target_waitstatus): New.
16519 (struct target_ops) <wait>: Return an unsigned long. Take a
16520 target_waitstatus pointer instead of a char pointer.
16521 (mywait): Likewise.
16522 * target.c (mywait): Change prototype to return an unsigned long.
16523 Take a target_waitstatus pointer instead of a char pointer. Adjust.
16524 * server.h (thread_from_wait, old_thread_from_wait): Delete
16526 (prepare_resume_reply): Change prototype to take a
16528 * server.c (thread_from_wait, old_thread_from_wait): Delete.
16529 (last_status, last_ptid): New.
16530 (start_inferior): Remove "statusptr" argument. Adjust. Return a
16531 pid instead of a signal.
16532 (attach_inferior): Remove "status" and "signal" parameters.
16534 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
16536 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
16537 (handle_v_requests, myresume): Remove "status" and "signal"
16538 parameters. Adjust.
16539 (handle_status): New.
16540 (main): Delete local `status'. Adjust.
16541 * remote-utils.c: Include target.h.
16542 (prepare_resume_reply): Change prototype to take a
16543 target_waitstatus. Adjust.
16545 * linux-low.c (linux_wait): Adjust to new target_ops->wait
16547 * spu-low.c (spu_wait): Adjust.
16548 * win32-low.c (enum target_waitkind, struct target_waitstatus):
16550 (win32_wait): Adjust.
16552 2009-04-01 Pedro Alves <pedro@codesourcery.com>
16554 * target.h (struct thread_resume): Delete leave_stopped member.
16555 (struct target_ops): Add a `n' argument to the `resume' callback.
16556 * server.c (start_inferior): Adjust.
16557 (handle_v_cont, myresume): Adjust.
16558 * linux-low.c (check_removed_breakpoint): Adjust to resume
16559 interface change, and to removed leave_stopped field.
16560 (resume_ptr): Delete.
16561 (struct thread_resume_array): New.
16562 (linux_set_resume_request): Add new `arg' parameter. Adjust to
16563 resume interface change.
16564 (linux_continue_one_thread, linux_queue_one_thread)
16565 (resume_status_pending_p): Check if the resume field is NULL
16566 instead of checking the leave_stopped member.
16567 (linux_resume): Adjust to the target resume interface change.
16568 * spu-low.c (spu_resume): Adjust to the target resume interface
16570 * win32-low.c (win32_detach, win32_resume): Ditto.
16572 2009-04-01 Pedro Alves <pedro@codesourcery.com>
16574 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
16576 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
16578 (linux_continue_one_thread): Only preserve the stepping flag if
16579 there's a pending breakpoint.
16581 2009-03-31 Pedro Alves <pedro@codesourcery.com>
16583 * server.c (main): After the inferior having exited, call
16584 remote_close before exiting gdbserver.
16586 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
16588 Fix size of FPSCR in Power 7 processors.
16589 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
16590 (PPC_FEATURE_HAS_DFP): New #define.
16591 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
16594 2009-03-23 Pedro Alves <pedro@codesourcery.com>
16596 * server.c (handle_query) Whitespace and formatting.
16598 2009-03-22 Pedro Alves <pedro@codesourcery.com>
16600 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
16601 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
16602 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
16603 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
16604 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
16605 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
16606 Makefile.in, configure.ac: Fix whitespace throughout.
16607 * configure: Regenerate.
16609 2009-03-22 Pedro Alves <pedro@codesourcery.com>
16611 * inferiors.c (find_inferior): Make it safe for the callback
16612 function to delete the currently iterated inferior.
16614 2009-03-22 Pedro Alves <pedro@codesourcery.com>
16616 * Makefile.in (linuw_low_h): Move higher.
16617 (thread-db.o): Depend on $(linux_low_h).
16619 2009-03-17 Pedro Alves <pedro@codesourcery.com>
16621 Rename "process" to "lwp" throughout.
16623 * linux-low.c (all_processes): Rename to...
16624 (all_lwps): ... this.
16625 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
16626 (add_process): Rename to ...
16627 (add_lwp): ... this. Adjust.
16628 (linux_create_inferior): Adjust.
16629 (linux_attach_lwp): Adjust.
16630 (linux_attach): Adjust.
16631 (linux_kill_one_process): Rename to ...
16632 (linux_kill_one_lwp): ... this. Adjust.
16633 (linux_kill): Adjust.
16634 (linux_detach_one_process): Rename to ...
16635 (linux_detach_one_lwp): ... this. Adjust.
16636 (linux_detach): Adjust.
16637 (check_removed_breakpoint): Adjust.
16638 (status_pending_p): Adjust.
16639 (linux_wait_for_process): Rename to ...
16640 (linux_wait_for_lwp): ... this. Adjust.
16641 (linux_wait_for_event): Adjust.
16642 (send_sigstop): Adjust.
16643 (wait_for_sigstop): Adjust.
16644 (stop_all_processes): Rename to ...
16645 (stop_all_lwps): ... this.
16646 (linux_resume_one_process): Rename to ...
16647 (linux_resume_one_lwp): ... this. Adjust.
16648 (linux_set_resume_request, linux_continue_one_thread)
16649 (linux_queue_one_thread, resume_status_pending_p)
16650 (usr_store_inferior_registers, regsets_store_inferior_registers)
16651 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
16653 * linux-low.h (get_process): Rename to ...
16654 (get_lwp): ... this. Adjust.
16655 (get_thread_process): Rename to ...
16656 (get_thread_lwp): ... this. Adjust.
16657 (get_process_thread): Rename to ...
16658 (get_lwp_thread): ... this. Adjust.
16659 (struct process_info): Rename to ...
16660 (struct lwp_info): ... this.
16661 (all_processes): Rename to ...
16662 (all_lwps): ... this.
16663 * proc-service.c (ps_lgetregs): Adjust.
16664 * thread-db.c (thread_db_create_event, find_one_thread)
16665 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
16667 2009-03-14 Pedro Alves <pedro@codesourcery.com>
16669 * server.c (handle_query): Handle "qAttached".
16671 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
16673 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
16674 GPLv3, update license URL.
16676 2009-03-01 Doug Evans <dje@google.com>
16678 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
16679 (server_h): Add gdb_signals.h.
16680 (signals.o): Update.
16681 * server.h (target_signal_from_host,target_signal_to_host_p)
16682 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
16684 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
16686 * remote-utils.c (getpkt): Also generate remote-debug
16687 information if noack_mode is set.
16689 2009-02-06 Pedro Alves <pedro@codesourcery.com>
16691 * server.c (handle_query): Report qXfer:siginfo:read and
16692 qXfer:siginfo:write as supported and handle them.
16693 * target.h (struct target_ops) <qxfer_siginfo>: New field.
16694 * linux-low.c (linux_xfer_siginfo): New.
16695 (linux_target_ops): Set it.
16697 2009-01-26 Pedro Alves <pedro@codesourcery.com>
16699 * server.c (gdbserver_usage): Mention --remote-debug.
16700 (main): Accept '--remote-debug' switch.
16702 2009-01-18 Doug Evans <dje@google.com>
16704 * regcache.c (new_register_cache): No need to check result of xcalloc.
16705 * server.c (handle_search_memory): Back out calls to xmalloc,
16706 result is checked and error is returned to user upon failure.
16707 (handle_query): Ditto. Add more checks for result of malloc.
16708 (handle_v_cont): Check result of malloc, report error back to
16710 (handle_v_run): Ditto. Call freeargv.
16711 * server.h (freeargv): Declare.
16712 * utils.c (freeargv): New fn.
16714 2009-01-15 Doug Evans <dje@google.com>
16716 * gdbreplay.c (perror_with_name): Make arg const char *.
16717 * server.h (target_signal_to_name): Make return type const char *.
16718 * thread-db.c (thread_db_err_str): Make return type const char *.
16719 * utils.c (perror_with_name): Make arg const char *.
16721 2009-01-14 Pedro Alves <pedro@codesourcery.com>
16723 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
16724 when handling a EXIT_PROCESS_DEBUG_EVENT.
16726 2009-01-06 Joel Brobecker <brobecker@adacore.com>
16728 * gdbreplay.c (gdbreplay_version): Update copyright year.
16729 * server.c (gdbserver_version): Likewise.
16731 2009-01-05 Doug Evans <dje@google.com>
16733 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
16734 (handle_extended_wait): Improve comment.
16736 2008-12-13 Doug Evans <dje@google.com>
16738 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
16739 * server.h (ATTR_MALLOC): New macro.
16740 (xmalloc,xcalloc,xstrdup): Declare.
16741 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
16742 * inferiors.c: Ditto.
16743 * linux-low.c: Ditto.
16744 * mem-break.c: Ditto.
16745 * regcache.c: Ditto.
16746 * remote-utils.c: Ditto.
16749 * win32-low.c: Ditto.
16751 2008-12-12 Doug Evans <dje@google.com>
16753 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
16754 in debugging printf.
16756 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
16758 2008-12-09 Doug Evans <dje@google.com>
16760 * linux-low.h (struct process_info): Delete member tid, unused.
16761 * thread-db.c (find_one_thread): Update.
16762 (maybe_attach_thread): Update.
16764 2008-12-02 Pedro Alves <pedro@codesourcery.com>
16766 * target.h (struct target_ops): Add qxfer_osdata member.
16767 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
16769 (linux_qxfer_osdata): New functions.
16770 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
16772 * server.c (handle_query): Handle "qXfer:osdata:read:".
16773 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
16774 (buffer_xml_printf): New functions.
16775 * server.h (struct buffer): New.
16776 (buffer_grow_str, buffer_grow_str0): New macros.
16777 (buffer_grow, buffer_free, buffer_init, buffer_finish)
16778 (buffer_xml_printf): Declare.
16780 2008-11-24 Doug Evans <dje@google.com>
16782 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
16784 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
16786 * server.c (handle_v_run): Always use the supplied argument list.
16788 2008-11-19 Bob Wilson <bob.wilson@acm.org>
16790 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
16791 (xtensa_regmap_table): Add entry for scompare1.
16793 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
16795 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
16796 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
16797 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
16798 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
16799 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
16800 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
16801 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
16802 XML target descriptions.
16803 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
16804 when inferior is running on an ISA 2.05 or later processor. Add
16805 special case to return offset for full 64-bit slot of FPSCR when
16808 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
16810 * Makefile.in (SFILES, clean): Added sparc64 files.
16811 (reg-sparc64.o, reg-sparc64.c): New.
16812 * configure.srv (sparc*-*-linux*): New configuration.
16813 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
16814 syscall arguments for SPARC.
16815 (regsets_store_inferior_registers): Likewise.
16816 * linux-sparc-low.c: New file.
16818 2008-10-21 Doug Evans <dje@google.com>
16820 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
16821 (READLINE_DIR,READLINE_DEP): Delete.
16822 (INTERNAL_CFLAGS): Update.
16823 (LINTFLAGS): Update.
16825 2008-10-10 Pedro Alves <pedro@codesourcery.com>
16827 * server.c (handle_v_run): If GDB didn't specify an argv, use the
16828 whole argv from the last run, not just argv[0].
16830 2008-09-08 Pedro Alves <pedro@codesourcery.com>
16832 * regcache.c (new_register_cache): Return NULL if the register
16833 cache size isn't known yet.
16834 (free_register_cache): Avoid dereferencing a NULL regcache.
16836 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
16838 * configure.srv: Merge MIPS and MIPS64.
16840 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
16842 * Makefile.in (uninstall): Apply $(EXEEXT) too.
16844 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
16846 * Makefile.in: Add required vsx dependencies.
16848 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
16849 Declare init_registers_powerpc_vsx32l.
16850 Declare init_registers_powerpc_vsx64l.
16851 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
16852 (ppc_arch_setup): Check for VSX in hwcap.
16853 (ppc_fill_vsxregset): New function.
16854 (ppc_store_vsxregset): New function.
16855 Add new VSX entry in regset_info target_regsets.
16857 * configure.srv: Add new VSX dependencies.
16859 2008-08-12 Pedro Alves <pedro@codesourcery.com>
16861 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
16862 (remote_open): Set or clear transport_is_reliable.
16863 (putpkt_binary): Don't expect acks in noack mode.
16864 (getpkt): Don't send ack/nac in noack mode.
16865 * server.c (handle_general_set): Handle QStartNoAckMode.
16866 (handle_query): If connected by tcp pass QStartNoAckMode+ in
16868 (main): Reset noack_mode on every connection.
16869 * server.h (noack_mode): Declare.
16871 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
16873 * Makefile.in (GDBREPLAY_OBS): New variable.
16874 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
16876 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
16877 Daniel Jacobowitz <dan@codesourcery.com>
16879 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
16880 (usr_store_inferior_registers): Likewise.
16881 (regsets_store_inferior_registers): Likewise.
16883 2008-07-31 Rolf Jansen <rj@surtec.com>
16884 Pedro Alves <pedro@codesourcery.com>
16886 * configure.ac: Check for memmem declaration.
16887 * server.c [HAVE_MALLOC_H]: Include malloc.h.
16888 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
16889 (disable_packet_qfThreadInfo): Unconditionally compile.
16890 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
16891 * configure, config.in: Regenerate.
16893 2008-07-28 Doug Kwan <dougkwan@google.com>
16895 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
16896 (linux_write_memory): Remove declaration of errno.
16898 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
16900 * linux-low.c (handle_extended_wait): Do not use "status"
16901 variable uninitialized.
16903 2008-07-07 Pedro Alves <pedro@codesourcery.com>
16905 * server.c (handle_v_attach): Inhibit reporting dll changes.
16907 2008-06-27 Pedro Alves <pedro@codesourcery.com>
16909 * remote-utils.c (prepare_resume_reply): If requested, don't
16910 output "thread:TID" in the T stop reply.
16912 * server.c (disable_packet_vCont, disable_packet_Tthread)
16913 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
16914 (handle_query): If requested, disable support for qC, qfThreadInfo
16916 (handle_v_requests): If requested, disable support for vCont.
16917 (gdbserver_show_disableable): New.
16918 (main): Handle --disable-packet and --disable-packet=LIST.
16920 * server.h (disable_packet_vCont, disable_packet_Tthread)
16921 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
16923 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
16925 * server.c (gdbserver_usage): Mention --version.
16927 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
16929 * Makefile.in (gdbreplay.o): New rule.
16931 2008-06-06 Joseph Myers <joseph@codesourcery.com>
16933 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
16934 message, not gdbserver.
16936 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
16937 Nathan Sidwell <nathan@codesourcery.com>
16938 Joseph Myers <joseph@codesourcery.com>
16940 * acinclude.m4: Include ../../config/acx.m4.
16941 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
16942 * configure, config.in: Regenerate.
16943 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
16944 * server.c (gdbserver_version): Print PKGVERSION.
16945 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
16946 (main): Adjust gdbserver_usage calls.
16947 * gdbreplay.c (version, host_name): Add declarations.
16948 (gdbreplay_version, gdbreplay_usage): New.
16949 (main): Accept --version and --help options.
16951 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
16953 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
16954 (arm_breakpoint_at): Handle Thumb.
16955 (the_low_target): Add comment.
16957 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
16959 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
16961 2008-05-09 Doug Evans <dje@google.com>
16963 * server.h (decode_search_memory_packet): Declare.
16964 * remote-utils.c (decode_search_memory_packet): New fn.
16965 * server.c (handle_search_memory_1): New fn.
16966 (handle_search_memory): New fn.
16967 (handle_query): Process qSearch:memory packets.
16969 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
16971 * regcache.c (registers_length): Remove.
16972 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
16973 full register packet.
16974 * regcache.h (registers_length): Remove prototype.
16975 * server.h (PBUFSIZ): Define to 16384.
16977 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
16979 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
16980 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
16981 powerpc-64l.o, and powerpc-altivec64l.o.
16982 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
16983 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
16984 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
16985 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
16986 rs6000/power-linux.xml, and rs6000/power64-linux.xml
16989 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
16990 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
16991 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
16992 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
16993 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
16994 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
16995 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
16996 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
16997 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
16998 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
17001 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
17002 (init_registers_powerpc_32l): ... this new prototype.
17003 (init_registers_powerpc_32): Remove, replace by ...
17004 (init_registers_powerpc_altivec32l): ... this new prototype.
17005 (init_registers_powerpc_e500): Remove, replace by ...
17006 (init_registers_powerpc_e500l): ... this new prototype.
17007 (init_registers_ppc64): Remove, replace by ...
17008 (init_registers_powerpc_64l): ... this new prototype.
17009 (init_registers_powerpc_64): Remove, replace by ...
17010 (init_registers_powerpc_altivec64l): ... this new prototype.
17011 (ppc_num_regs): Set to 73.
17012 (PT_ORIG_R3, PT_TRAP): Define if necessary.
17013 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
17014 (ppc_cannot_store_register): Handle orig_r3 and trap.
17015 (ppc_arch_setup): Update init_registers_... calls.
17016 (ppc_fill_gregset): Handle orig_r3 and trap.
17018 * inferiors.c (clear_inferiors): Reset current_inferior.
17020 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
17022 * acinclude.m4: Add override.m4.
17023 * configure: Regenerate.
17025 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
17027 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
17028 initial call to init_register_ppc64.
17030 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
17032 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
17033 single powerpc*-*-linux* case.
17034 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
17036 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
17038 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
17039 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
17041 * linux-ppc-low.c: Include <elf.h>.
17042 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
17043 (ppc_hwcap): New global variable.
17044 (ppc_regmap): Remove __SPE__ #ifdef sections.
17045 (ppc_regmap_e500): New global variable.
17046 (ppc_cannot_store_register): Update __SPE__ special case.
17047 (ppc_get_hwcap): New function.
17048 (ppc_arch_setup): Use it to determine whether inferior supports
17049 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
17050 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
17051 Do not access registers if target does not support AltiVec.
17052 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
17053 Do not access registers if target does not support SPE.
17054 (target_regsets): Unconditionally include AltiVec and SPE regsets.
17056 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
17058 * linux-low.c (disabled_regsets, num_regsets): New.
17059 (use_regsets_p): Delete.
17060 (linux_wait_for_process): Clear disabled_regsets.
17061 (regsets_fetch_inferior_registers): Check and set it.
17062 (regsets_store_inferior_registers): Likewise.
17063 (linux_fetch_registers, linux_store_registers): Do not use
17065 (initialize_low): Allocate disabled_regsets.
17067 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
17069 * Makefile.in (LIBOBJS): New.
17070 (OBS): Use LIBOBJS.
17071 (memmem.o): New rule.
17072 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
17073 * configure: Regenerated.
17075 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
17077 * server.c (handle_query): Never return "unsupported" for
17078 qXfer:features:read queries.
17080 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
17082 * server.c (get_features_xml): Fix inverted condition.
17083 (handle_query): Always support qXfer:feature:read.
17085 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
17087 * server.c (wrapper_argv): New.
17088 (start_inferior): Handle wrapper_argv. If set, expect an extra
17090 (gdbserver_usage): Document --wrapper.
17091 (main): Parse --wrapper.
17093 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
17095 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
17096 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
17097 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
17098 (ppc_set_pc): Likewise.
17099 (ppc_arch_setup): New function.
17100 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
17101 of collect_register.
17102 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
17104 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
17106 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
17107 instead of linux-ppc64-low.o.
17108 * linux-ppc64-low.c: Remove file.
17109 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
17110 (linux-ppc64-low.o): Remove rule.
17112 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
17113 (init_registers_powerpc_64): Likewise.
17114 (ppc_regmap): Conditionally define depending on __powerpc64__.
17115 (ppc_cannot_store_register): Do not special-case "fpscr" when
17116 compiled on __powerpc64__.
17117 (ppc_collect_ptrace_register): New function.
17118 (ppc_supply_ptrace_register): New function.
17119 (ppc_breakpoint): Change type to "unsigned int".
17120 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
17121 (the_low_target): Conditionally provide initializers for the
17122 arch_setup member depending on __powerpc64__. Install
17123 collect_ptrace_register and supply_ptrace_register members.
17125 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
17127 * regcache.h (gdbserver_xmltarget): Add extern declaration.
17128 * server.c (gdbserver_xmltarget): Define.
17129 (get_features_xml): Use it to replace "target.xml" and arch_string.
17131 * configure.srv: Remove srv_xmltarget. Add XML files that were
17132 mentioned there to srv_xmlfiles instead. Remove conditional tests
17133 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
17134 srv_xmlfiles and srv_regobj to include all possible choices.
17135 * configure.ac (srv_xmltarget): Remove.
17136 (srv_xmlfiles): Do not add "target.xml".
17137 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
17138 checks for supplementary target information.
17139 * configure: Regenerate.
17140 * Makefile.in (XML_TARGET): Remove.
17141 (target.xml): Remove rule.
17142 (clean): Do not clean up target.xml.
17143 (.PRECIOUS): Do not mention target.xml.
17145 * target.h (struct target_ops): Remove arch_string member.
17146 * linux-low.c (linux_arch_string): Remove.
17147 (linux_target_ops): Remove arch_string initializer.
17148 * linux-low.h (struct linux_target_ops): Remove arch_string member.
17149 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
17150 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
17151 * spu-low.c (spu_arch_string): Remove.
17152 (spu_target_ops): Remove arch_string initializer.
17153 * win32-low.c (win32_arch_string): Remove.
17154 (win32_target_ops): Remove arch_string initializer.
17155 * win32-low.h (struct win32_target_ops): Remove arch_string member.
17156 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
17157 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
17159 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
17161 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
17162 by collect_ptrace_register and supply_ptrace_register hooks.
17163 * linux-low.c (fetch_register): Use supply_ptrace_register callback
17164 instead of checking for the_low_target.left_pad_xfer.
17165 (usr_store_inferior_registers): Use collect_ptrace_register callback
17166 instead of checking for the_low_target.left_pad_xfer.
17168 * linux-s390-low.c (s390_collect_ptrace_register): New function.
17169 (s390_supply_ptrace_register): Likewise.
17170 (s390_fill_gregset): Call s390_collect_ptrace_register.
17171 (the_low_target): Update.
17173 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
17174 (ppc_supply_ptrace_register): Likewise.
17175 (the_low_target): Update.
17177 * linux-i386-low.c (the_low_target): Update.
17178 * linux-x86-64-low.c (the_low_target): Update.
17180 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
17182 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
17183 reg-s390.o and reg-s390x.o.
17185 * linux-low.c (new_inferior): New global variable.
17186 (linux_create_inferior, linux_attach): Set it.
17187 (linux_wait_for_process): Call the_low_target.arch_setup after the
17188 target has stopped for the first time.
17189 (initialize_low): Do not call the_low_target.arch_setup.
17191 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
17192 (s390_set_pc): Likewise.
17193 (s390_arch_setup): New function.
17194 (the_low_target): Use s390_arch_setup as arch_setup routine.
17196 * regcache.c (realloc_register_cache): New function.
17197 (set_register_cache): Call it for each existing regcache.
17199 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
17201 * server.h (init_registers): Remove prototype.
17203 * linux-low.h (struct linux_target_ops): Add arch_setup field.
17204 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
17205 instead of init_registers ().
17206 * linux-arm-low.c (init_registers_arm): Add prototype.
17207 (init_registers_arm_with_iwmmxt): Likewise.
17208 (the_low_target): Add initializer for arch_setup field.
17209 * linux-cris-low.c (init_registers_cris): Add prototype.
17210 (the_low_target): Add initializer for arch_setup field.
17211 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
17212 (the_low_target): Add initializer for arch_setup field.
17213 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
17214 (the_low_target): Add initializer for arch_setup field.
17215 * linux-ia64-low.c (init_registers_ia64): Add prototype.
17216 (the_low_target): Add initializer for arch_setup field.
17217 * linux-m32r-low.c (init_registers_m32r): Add prototype.
17218 (the_low_target): Add initializer for arch_setup field.
17219 * linux-m68k-low.c (init_registers_m68k): Add prototype.
17220 (the_low_target): Add initializer for arch_setup field.
17221 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
17222 (init_registers_mips64_linux): Likewise.
17223 (the_low_target): Add initializer for arch_setup field.
17224 * linux-ppc-low.c (init_registers_ppc): Add prototype.
17225 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
17226 (the_low_target): Add initializer for arch_setup field.
17227 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
17228 (init_registers_powerpc_64): Likewise.
17229 (the_low_target): Add initializer for arch_setup field.
17230 * linux-s390-low.c (init_registers_s390): Add prototype.
17231 (init_registers_s390x): Likewise.
17232 (the_low_target): Add initializer for arch_setup field.
17233 * linux-sh-low.c (init_registers_sh): Add prototype.
17234 (the_low_target): Add initializer for arch_setup field.
17235 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
17236 (the_low_target): Add initializer for arch_setup field.
17237 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
17238 (the_low_target): Add initializer for arch_setup field.
17240 * win32-low.h (struct win32_target_ops): Add arch_setup field.
17241 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
17242 instead of init_registers ().
17243 * win32-arm-low.c (init_registers_arm): Add prototype.
17244 (the_low_target): Add initializer for arch_setup field.
17245 * win32-i386-low.c (init_registers_i386): Add prototype.
17246 (the_low_target): Add initializer for arch_setup field.
17248 * spu-low.c (init_registers_spu): Add prototype.
17249 (initialize_low): Call initialie_registers_spu () instead of
17250 initialize_registers ().
17252 2008-02-19 Pedro Alves <pedro@codesourcery.com>
17254 * server.c (handle_v_requests): When handling the vRun and vAttach
17255 packets, if already debugging a process, don't kill it. Return an
17258 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
17260 * server.c (handle_query): Correct length check.
17262 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
17264 * win32-low.c (do_initial_child_stuff): Add process handle
17265 parameter. Set current_process_handle and current_process_id from the
17266 parameters. Clear globals.
17267 (win32_create_inferior): Don't set current_process_handle and
17268 current_process_id here. Instead pass them on the call to
17269 do_initial_child_stuff.
17270 (win32_attach): Likewise.
17271 (win32_clear_inferiors): New.
17272 (win32_kill): Don't close the current process handle or the
17273 current thread handle here. Instead call win32_clear_inferiors.
17274 (win32_detach): Don't open a new handle to the process. Call
17275 win32_clear_inferiors.
17276 (win32_join): Don't rely on current_process_handle; open a new
17277 handle using the process id.
17278 (win32_wait): Call win32_clear_inferiors when the inferior process
17281 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
17283 * server.c (monitor_show_help): Add "exit".
17285 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
17287 * Makefile.in (SFILES): Add linux-xtensa-low.c.
17288 (clean): Add reg-xtensa.c.
17289 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
17290 * configure.srv (xtensa*-*-linux*) New target.
17291 * linux-xtensa-low.c: New.
17292 * xtensa-xtregs.c: New.
17294 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
17296 * hostio.c: Don't include errno.h.
17297 (errno_to_fileio_errno): Move to hostio-errno.
17298 * hostio.c: (hostio_error): Remove the error parameter. Defer the
17299 error number outputting to the target->hostio_last_error callback.
17300 (hostio_packet_error): Use FILEIO_EINVAL directly.
17301 (handle_open, handle_pread, hostio_error, handle_unlink): Update
17302 calls to hostio_error.
17303 * hostio-errno.c: New.
17304 * server.h (hostio_last_error_from_errno): Declare.
17305 * target.h (target_ops): Add hostio_last_error member.
17306 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
17307 as hostio_last_error handler.
17308 * spu-low.c (spu_target_ops): Likewise.
17309 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
17310 (wince_hostio_last_error): New functions.
17311 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
17312 as hostio_last_error handler.
17313 (win32_target_ops) [!_WIN32_WCE]: Register
17314 hostio_last_error_from_errno as hostio_last_error handler.
17315 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
17316 (hostio-errno.o): New rule.
17317 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
17318 * configure.srv (srv_hostio_err_objs): New variable. Default to
17320 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
17321 * configure: Regenerate.
17323 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
17325 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
17326 (linux_kill, linux_detach): Clean up the process list.
17327 * remote-utils.c (remote_open): Improve port number parsing.
17328 (putpkt_binary, input_interrupt): Only send interrupts if the target
17330 * server.c (extended_protocol): Make static.
17331 (attached): Define earlier.
17332 (exit_requested, response_needed, program_argv): New variables.
17333 (target_running): New.
17334 (start_inferior): Clear attached here.
17335 (attach_inferior): Set attached here.
17336 (require_running): Define.
17337 (handle_query): Use require_running and target_running. Implement
17339 (handle_v_attach, handle_v_run): New.
17340 (handle_v_requests): Use require_running. Handle vAttach and vRun.
17341 (gdbserver_usage): Update.
17342 (main): Redo argument parsing. Handle --debug and --multi. Handle
17343 --attach along with other options or after the port. Save
17344 program_argv. Support no initial program. Resynchronize
17345 communication with GDB after an error. Handle "monitor exit".
17346 Use require_running and target_running. Always allow the extended
17347 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
17348 restart in extended mode.
17349 * README: Refer to the GDB manual. Update --attach usage.
17351 2007-12-20 Andreas Schwab <schwab@suse.de>
17353 * linux-low.c (STACK_SIZE): Define.
17354 (linux_tracefork_child): Use it. Use __clone2 on ia64.
17355 (linux_test_for_tracefork): Likewise.
17357 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
17359 * linux-low.c (linux_wait_for_event): Update messages. Do not
17360 reinsert auto-delete breakpoints.
17361 * mem-break.c (struct breakpoint): Change return type of handler to
17363 (set_breakpoint_at): Update handler type.
17364 (reinsert_breakpoint_handler): Return 1 instead of calling
17366 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
17368 (check_breakpoints): Delete auto-delete breakpoints and return 2.
17369 * mem-break.h (set_breakpoint_at): Update handler type.
17370 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
17371 * win32-low.c (auto_delete_breakpoint): New.
17372 (get_child_debug_event): Use it.
17374 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
17376 * configure.ac: Check for pread and pwrite.
17377 * hostio.c (handle_pread): Fall back to lseek and read.
17378 (handle_pwrite): Fall back to lseek and write.
17379 * config.in, configure: Regenerated.
17381 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
17383 * server.c (myresume): Add own_buf argument.
17384 (main): Update calls.
17386 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
17388 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
17389 * remote-utils.c (remote_open): Do not call disable_async_io.
17390 (block_async_io): Delete.
17391 (unblock_async_io): Make static.
17392 (initialize_async_io): New.
17393 * server.c (handle_v_cont): Handle async I/O here.
17394 (myresume): Likewise. Move other common resume tasks here...
17395 (main): ... from here. Call initialize_async_io. Disable async
17396 I/O before the main loop.
17397 * server.h (initialize_async_io): Declare.
17398 (block_async_io, unblock_async_io): Delete prototypes.
17399 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
17401 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
17403 * remote-utils.c (readchar): Allow binary data in received messages.
17405 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17407 * win32-low.c (attaching): New global.
17408 (win32_create_inferior): Clear the `attaching' global.
17409 (win32_attach): Set the `attaching' global.
17410 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
17411 attaching. Only set a breakpoint at the entry point if not
17414 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17416 * server.c (main): Don't report dll events on the initial
17417 connection on attaches.
17419 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17421 * server.c (main): Relax numerical bases supported for the pid of
17422 the --attach command line argument.
17424 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17426 * win32-low.c (win32_attach): Call OpenProcess before
17427 DebugActiveProcess, not after. Add last error output to error
17430 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17432 * win32-low.c (win32_get_thread_context)
17433 (win32_set_thread_context): New functions.
17434 (thread_rec): Use win32_get_thread_context.
17435 (continue_one_thread, win32_resume): Use win32_set_thread_context.
17436 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
17439 2007-12-03 Leo Zayas
17440 Pedro Alves <pedro_alves@portugalmail.pt>
17442 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
17444 (child_add_thread): Minor cleanup.
17445 (child_continue): Resume artificially suspended threads before
17446 calling ContinueDebugEvent.
17447 (suspend_one_thread): New.
17448 (fake_breakpoint_event): New.
17449 (get_child_debug_event): Change return type to int. Check here if
17450 gdb sent an interrupt request. If a soft interrupt was requested,
17451 fake a breakpoint event. Return 0 if there is no event to handle,
17453 (win32_wait): Don't check here if gdb sent an interrupt request.
17454 Ensure there is a valid event to handle.
17455 (win32_request_interrupt): Add soft interruption method as last
17458 2007-12-03 Leo Zayas
17459 Pedro Alves <pedro_alves@portugalmail.pt>
17461 * win32-low.h (win32_thread_info): Add descriptions to the
17462 structure members. Replace `suspend_count' counter by a
17464 * win32-low.c (thread_rec): Update condition of when to get the
17465 context from the inferior. Rely on ContextFlags being set if it
17466 has already been retrieved. Only suspend the inferior thread if
17467 we haven't already. Warn if that fails.
17468 (continue_one_thread): s/suspend_count/suspended/. Only call
17469 ResumeThread once. Warn if that fails.
17471 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
17473 * win32-low.c (win32_wait): Don't read from the inferior when it
17474 has already exited.
17476 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
17478 * Makefile.in (win32_low_h): New variable.
17479 (win32-low.o): Add dependency on $(win32_low_h).
17480 (win32-arm-low.o, win32-i386-low.o): New rules.
17482 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
17484 * hostio.c: Correct copyright year.
17486 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
17488 * Makefile.in (OBS): Add hostio.o.
17489 (hostio.o): New rule.
17490 * server.h (handle_vFile): Declare.
17491 * hostio.c: New file.
17492 * server.c (handle_v_requests): Take packet_len and new_packet_len
17493 for binary packets. Call handle_vFile.
17494 (main): Update call to handle_v_requests.
17496 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
17498 * linux-low.c: Include <sched.h>.
17500 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
17502 * linux-low.c (linux_tracefork_grandchild): New.
17503 (linux_tracefork_child): Use clone.
17504 (linux_test_for_tracefork): Use clone; allocate and free a stack.
17506 2007-10-31 Joel Brobecker <brobecker@adacore.com>
17508 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
17510 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
17512 * linux-low.c (handle_extended_wait): Handle unexpected signals.
17514 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
17516 * inferiors.c (change_inferior_id): Delete.
17517 (add_pid_to_list, pull_pid_from_list): New.
17518 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
17519 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
17520 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
17521 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
17522 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
17523 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
17524 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
17525 (using_threads): Always set to 1.
17526 (handle_extended_wait): New.
17527 (add_process): Do not set TID.
17528 (linux_create_inferior): Set must_set_ptrace_flags.
17529 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
17530 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
17531 (linux_thread_alive): Rename TID argument to LWPID.
17532 (linux_wait_for_process): Handle unknown processes. Do not use TID.
17533 (linux_wait_for_event): Do not use TID or check using_threads. Update
17534 call to dead_thread_notify. Call handle_extended_wait.
17535 (linux_create_inferior): Use PTRACE_SETOPTIONS.
17536 (send_sigstop): Delete sigstop_sent.
17537 (wait_for_sigstop): Avoid TID.
17538 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
17539 (linux_test_for_tracefork): New.
17540 (linux_lookup_signals): Use thread_db_active and
17541 linux_supports_tracefork_flag.
17542 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
17543 * linux-low.h (get_process_thread): Avoid TID.
17544 (struct process_ifo): Move thread_known and tid to the end. Remove
17546 (linux_attach_lwp, thread_db_init): Update prototypes.
17547 * server.h (change_inferior_id): Delete prototype.
17548 (add_pid_to_list, pull_pid_from_list): New prototypes.
17549 * thread-db.c (thread_db_use_events): New.
17550 (find_first_thread): Rename to...
17551 (find_one_thread): ...this. Update callers and messages. Do not
17552 call fatal. Check thread_db_use_events. Do not call
17553 change_inferior_id or new_thread_notify.
17554 (maybe_attach_thread): Update. Do not call new_thread_notify.
17555 (thread_db_init): Set thread_db_use_events. Check use_events.
17556 * utils.c (fatal, warning): Correct message prefix.
17558 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
17560 * Makefile.in (clean): Remove new files.
17561 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
17562 (powerpc-64.o, powerpc-64.c): New rules.
17563 * configure.srv: Use alternate register sets for powerpc64-*-linux*
17564 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
17566 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
17568 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
17569 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
17570 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
17571 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
17572 (target_regsets): Add AltiVec and SPE register sets.
17573 * configure.ac: Check for AltiVec and SPE.
17574 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
17575 (ppc_fill_vrregset, ppc_store_vrregset): New.
17576 (target_regsets): Add AltiVec register set.
17577 * configure: Regenerated.
17579 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
17581 * linux-low.c (O_LARGEFILE): Define.
17582 (linux_read_memory): Use /proc/PID/mem.
17583 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
17584 * configure, config.in: Regenerated.
17586 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
17588 * linux-low.c (linux_wait_for_event): Do not pass signals while
17591 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
17593 * win32-low.c (create_process): New.
17594 (win32_create_inferior): Use create_process instead of
17595 CreateProcess. If create_process failed retry appending an ".exe"
17596 suffix. Store the GetLastError result immediatelly after
17597 create_process calls and use it on the call to error.
17599 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
17601 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
17603 2007-08-23 Joel Brobecker <brobecker@adacore.com>
17605 * configure.ac: Switch license to GPLv3.
17607 2007-08-01 Michael Snyder <msnyder@access-company.com>
17609 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
17611 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
17613 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
17615 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
17616 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
17617 CloseToolhelp32Snapshot.
17618 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
17619 CloseToolhelp32Snapshot.
17621 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
17623 * server.c (main): Check for inferior exit before main loop.
17625 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
17627 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
17628 instead of on tmp_desc.
17630 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
17631 Daniel Jacobowitz <dan@codesourcery.com>
17633 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
17634 (add_thread): Minor cleanups.
17635 (clear_inferiors): Move lower in the file. Clear the DLL
17637 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
17638 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
17639 (xml_escape_text): New.
17640 * server.c (handle_query): Handle qXfer:libraries:read. Report it
17642 (handle_v_cont): Report errors.
17643 (gdbserver_version): Update.
17644 (main): Correct size of own_buf. Do not report initial DLL events.
17645 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
17646 (unloaded_dll, xml_escape_text): New.
17647 * win32-low.c (enum target_waitkind): Update comments.
17648 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
17649 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
17650 (win32_EnumProcessModules, win32_GetModuleInformation)
17651 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
17652 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
17653 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
17654 (win32_Module32First, win32_Module32Next, load_toolhelp)
17655 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
17656 (get_child_debug_event): Handle DLL events.
17657 (win32_wait): Likewise.
17659 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
17661 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
17662 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
17664 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
17666 * win32-low.c (handle_output_debug_string): Ignore event if not
17669 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
17671 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
17673 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
17675 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
17677 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
17679 * inferiors.c (change_inferior_id): Add comment.
17680 * linux-low.c (check_removed_breakpoint): Add an early
17681 prototype. Improve debug output.
17682 (linux_attach): Doc update.
17683 (linux_detach_one_process, linux_detach): Clean up before releasing
17685 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
17686 * linux-low.h (struct process_info): Doc improvement.
17687 * mem-break.c (delete_all_breakpoints): New.
17688 * mem-break.h (delete_all_breakpoints): New prototype.
17689 * thread-db.c (find_first_thread): New.
17690 (thread_db_create_event): Call it instead of
17691 thread_db_find_new_threads. Clean up unused variables.
17692 (maybe_attach_thread): Remove first thread handling.
17693 (thread_db_find_new_threads): Use find_first_thread.
17694 (thread_db_get_tls_address): Likewise.
17696 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
17698 * thread-db.c (thread_db_find_new_threads): Add prototype.
17699 (thread_db_create_event): Check for the main thread before adding
17701 (maybe_attach_thread): Only enable event reporting if TID == 0.
17702 (thread_db_get_tls_address): Check for new threads.
17704 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
17706 * linux-low.c (linux_create_inferior): Try execv before execvp.
17707 * spu-low.c (spu_create_inferior): Likewise.
17709 2007-06-13 Mike Frysinger <vapier@gentoo.org>
17711 * linux-low.c (linux_create_inferior): Change execv to execvp.
17712 * spu-low.c (spu_create_inferior): Likewies.
17714 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
17716 * Makefile.in (clean): Clean new files instead of deleted ones.
17717 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
17718 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
17720 * configure.srv: Specify XML files and new regformats for MIPS and
17722 * linux-mips-low.c (mips_num_regs): Set to only used registers.
17723 (mips_regmap): Do not fetch $0. Remove unused registers. Add
17724 an entry for the restart register.
17725 (mips_cannot_fetch_register, mips_cannot_store_register)
17726 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
17727 register names to match the XML descriptions.
17728 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
17729 restart register instead of $0.
17731 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
17732 Markus Deuling <deuling@de.ibm.com>
17734 * remote-utils.c (decode_xfer_write): New function.
17735 * server.h (decode_xfer_write): Add prototype.
17736 * server.c (handle_query): Add PACKET_LEN argument. Support
17737 qXfer:spu:read and qXfer:spu:write packets.
17738 (main): Pass packet_len to handle_query.
17739 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
17740 * target.h (target_ops): Add qxfer_spu.
17742 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
17744 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
17745 accessing non-seekable spufs files.
17747 2007-05-16 Markus Deuling <deuling@de.ibm.com>
17749 * server.c (handle_query): Add reply for qC packet.
17751 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17752 Leo Zayas <lerele@champenstudios@com>
17754 * server.h (check_remote_input_interrupt_request): New function.
17755 * remote_utils.c (INVALID_DESCRIPTOR): New define.
17756 (remote_desc): Initialize with INVALID_DESCRIPTOR.
17757 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
17758 (check_remote_input_interrupt_request): New function.
17759 * server.h (check_remote_input_interrupt_request): Declare.
17760 * win32-low.c (winapi_DebugBreakProcess,
17761 winapi_GenerateConsoleCtrlEvent): New typedefs.
17762 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
17764 (win32_wait): Check for remote interrupt request
17765 with check_remote_input_interrupt_request.
17766 (win32_request_interrupt): New function.
17767 (win32_target_op): Set request_interrupt to win32_request_interrupt.
17769 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17771 * win32-low.c (debug_registers_changed,
17772 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
17773 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
17774 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
17775 (thread_rec): Get context using the low target.
17776 (child_add_thread): Call thread_added on the low target,
17777 which does the same thing.
17779 (do_initial_child_stuff): Remove debug registers references.
17780 Set context using the low target. Resume threads after
17781 setting the contexts.
17782 (child_continue): Remove dead variable. Remove debug
17783 registers references.
17784 (child_fetch_inferior_registers): Go through the low target.
17785 (do_child_store_inferior_registers): Remove.
17786 (child_store_inferior_registers): Go through the low target.
17787 (win32_resume): Remove debug registers references.
17788 Set context using the low target.
17789 (handle_exception): Change return type to void. Don't record
17790 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
17791 first chance exception.
17792 (get_child_debug_event): Change return type to void. Remove
17793 goto loop. Always return after waiting for debug event.
17794 (win32_wait): Convert to switch statement. Handle spurious
17797 * win32-i386-low.c (debug_registers_changed,
17798 debug_registers_used): New.
17799 (initial_stuff): Rename to ...
17800 (i386_initial_stuff): ... this. Clear debug registers
17802 (store_debug_registers): Delete.
17803 (i386_get_thread_context): New.
17804 (load_debug_registers): Delete.
17805 (i386_set_thread_context): New.
17806 (i386_thread_added): New.
17807 (single_step): Rename to ...
17808 (i386_single_step): ... this.
17809 (do_fetch_inferior_registers): Rename to ...
17810 (i386_fetch_inferior_register): ... this.
17811 (i386_store_inferior_register): New.
17812 (the_low_target): Adapt to new interface.
17814 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
17815 (arm_get_thread_context): New.
17816 (arm_set_thread_context): New.
17818 (do_fetch_inferior_registers): Rename to ...
17819 (arm_fetch_inferior_register): ... this.
17820 (arm_store_inferior_register): New.
17821 (arm_wince_breakpoint): Reimplement as unsigned long.
17822 (arm_wince_breakpoint_len): Define.
17823 (the_low_target): Adapt to new interface.
17825 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
17826 load_debug_registers. Add get_thread_context, set_thread_context,
17827 thread_added and store_inferior_register. Rename
17828 fetch_inferior_registers to fetch_inferior_register.
17829 (regptr): Remove declaration.
17831 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17833 * linux-low.c (linux_detach): Change return type to int. Return 0.
17834 * spu-low.c (spu_detach): Likewise.
17836 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17838 * target.h (target_ops): Change return type of detach to int.
17840 (join_inferior): New.
17841 * server.c (main): Don't skip detach support on mingw32.
17842 If the inferior doesn't support detaching return error.
17843 Call join_inferior instead of using waitpid.
17844 * linux-low.c (linux_join): New.
17845 (linux_target_op): Add linux_join.
17846 * spu-low.c (spu_join): New.
17847 (spu_target_ops): Add spu_join.
17848 * win32-low.c (win32_detach): Adapt to new interface.
17849 Reopen current_process_handle before detaching. Issue a child
17850 resume before detaching.
17852 (win32_target_op): Add win32_join.
17854 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17856 * win32-low.c (win32-attach): Fix return value.
17857 * target.h (target_ops): Describe ATTACH return values.
17859 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17861 * win32-low.c (GETPROCADDRESS): Define.
17862 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
17863 (winapi_DebugSetProcessKillOnExit): Likewise.
17864 (win32_create_inferior): Force usage of ansi CreateProcessA.
17865 (win32_attach): Use GETPROCADDRESS.
17866 (win32_detach): Likewise.
17868 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17870 * win32-low.c (win32_wait): Don't use WSTOPSIG.
17872 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
17874 * win32-low.c: Commit leftover changes from 2007-03-29.
17876 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
17878 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
17879 fields short instead of int. Add explicit padding.
17880 (i387_cache_to_fsave): Remove unnecessary casts.
17881 (i387_fsave_to_cache): Doc fix.
17882 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
17884 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
17886 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
17887 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
17889 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
17891 * configure.srv (arm*-*-mingw32ce*): Move near the other
17894 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
17896 * configure.ac: Add errno checking.
17897 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
17898 sys/file.h and malloc.h.
17899 (AC_CHECK_DECLS): Add perror.
17900 (srv_mingwce): Handle.
17901 * configure.srv (i[34567]86-*-cygwin*): Add
17902 win32-i386-low.o to srv_tgtobj.
17903 (i[34567]86-*-mingw*): Likewise.
17904 (arm*-*-mingw32ce*): Add case.
17905 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
17906 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
17907 [__MINGW32CE__] (strerror): New function.
17908 [__MINGW32CE__] (errno): Define to GetLastError.
17909 [__MINGW32CE__] (COUNTOF): New macro.
17910 (remote_open): Remove extra close call.
17911 * mem-break.c (delete_breakpoint_at): New function.
17912 * mem-break.h (delete_breakpoint_at): Declare.
17913 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
17914 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
17915 [USE_WIN32API] (read, write): Add char* casts.
17916 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
17917 * server.h: Include wincecompat.h on Windows CE.
17918 [HAVE_ERRNO_H]: Check.
17919 (perror): Declare if not declared.
17920 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
17921 (perror_with_name): Remove errno declaration.
17922 * wincecompat.h: New.
17923 * wincecompat.c: New.
17924 * win32-low.h: New.
17925 * win32-arm-low.c: New.
17926 * win32-i386-low.c: New.
17927 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
17928 (OUTMSG2): Make it safe.
17930 (COUNTOF): New macro.
17931 (NUM_REGS): Get it from the low target.
17932 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
17933 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
17934 (thread_rec): Let low target handle debug registers.
17935 (child_add_thread): Likewise.
17936 (child_init_thread_list): Likewise.
17937 (continue_one_thread): Likewise.
17939 (do_child_fetch_inferior_registers): Move to ...
17940 * win32-i386-low.c: ... here, and rename to ...
17941 (do_fetch_inferior_registers): ... this.
17942 * win32-low.c (child_fetch_inferior_registers):
17943 Go through the low target.
17944 (do_child_store_inferior_registers): Use regptr.
17945 (strwinerror): New function.
17946 (win32_create_inferior): Handle Windows CE.
17947 Use strwinerror instead of strerror on Windows error
17948 codes. Add program to the error output.
17949 Don't close the main thread handle on Windows CE.
17950 (win32_attach): Use coredll.dll on Windows CE.
17951 (win32_kill): Close current process and current
17953 (win32_detach): Use coredll.dll on Windows CE.
17954 (win32_resume): Let low target handle debug registers, and
17956 (handle_exception): Add/Remove initial breakpoint. Avoid
17957 non-existant WSTOPSIG on Windows CE.
17958 (win32_read_inferior_memory): Cast to remove warning.
17959 (win32_arch_string): Go through the low target.
17960 (initialize_low): Call set_breakpoint_data with the low
17961 target's breakpoint.
17962 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
17963 FOP_REGNUM, mappings): Move to ...
17964 * win32-i386-low.c: ... here.
17965 * win32-low.c (win32_thread_info): Move to ...
17966 * win32-low.h: ... here.
17967 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
17968 win32-arm-low.c and wincecompat.c.
17969 (all:): Add $EXEEXT.
17970 (install-only:): Likewise.
17971 (gdbserver:): Likewise.
17972 (gdbreplay:): Likewise.
17973 * config.in: Regenerate.
17974 * configure: Regenerate.
17976 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
17978 * win32-low.c: Rename typedef thread_info to
17979 win32_thread_info throughout.
17981 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
17983 * win32-i386-low.c: Rename to ...
17984 * win32-low.c: ... this.
17985 * configure.srv: Replace win32-i386-low.o with win32-low.o.
17986 * Makefile.in: Likewise.
17988 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
17990 * remote-utils.c (monitor_output): Constify msg parameter.
17991 * server.h (monitor_output): Likewise.
17992 * win32-i386-low.c (handle_output_debug_string): New.
17993 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
17994 handle_output_debug_string.
17995 (get_child_debug_event): Likewise.
17997 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
17999 * server.c (main): Correct strtoul check.
18001 2007-03-27 Jon Ringle <jon@ringle.org>
18003 * linux-low.c: Check __ARCH_HAS_MMU__ also.
18005 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
18007 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
18009 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
18011 * terminal.h: Check HAVE_SGTTY_H.
18013 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
18015 * remote-utils.c (remote_open): Print out the assigned port number.
18017 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
18019 * remote-utils.c (monitor_output): New function.
18020 * server.c (debug_threads): Define here.
18021 (monitor_show_help): New function.
18022 (handle_query): Handle qRcmd.
18023 (main): Do not handle 'd' packet.
18024 * server.h (debug_threads, remote_debug, monitor_output): Declare.
18025 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
18028 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
18030 * Makefile.in (EXEEXT): New.
18031 (clean): Use $(EXEEXT).
18033 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
18035 * target.h (target_ops): Rename send_signal to request_interrupt,
18036 and remove enum target_signal parameter.
18037 * linux-low.c (linux_request_interrupt): Rename from
18038 linux_send_signal, and always send SIGINT.
18039 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
18040 and always send SIGINT.
18041 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
18043 (input_interrupt): Likewise.
18045 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
18047 * server.c (get_features_xml): Check if target implemented
18049 * win32-i386-low.c (win32_arch_string): New.
18050 (win32_target_ops): Add win32_arch_string as arch_string member.
18052 2007-02-22 Markus Deuling <deuling@de.ibm.com>
18054 * spu-low.c (spu_arch_string): New.
18055 (spu_target_ops): Add spu_arch_string.
18057 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
18059 * remote-utils.c: Remove HAVE_TERMINAL_H check.
18060 * configure.ac: Do not check for terminal.h.
18061 * configure, config.in: Regenerated.
18063 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
18065 * Makefile.in (OBS): Add $(XML_BUILTIN).
18066 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
18068 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
18069 (arm-with-iwmmxt.c): New.
18070 * config.in, configure: Regenerate.
18071 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
18072 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
18073 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
18074 (arm*-*-linux*): Add iWMMXt and regset support.
18075 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
18076 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
18077 (arm_store_wmmxregset, target_regsets): New.
18078 * server.c (get_features_xml): Take annex argument. Check builtin
18080 (handle_query): Handle multiple annexes.
18082 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
18084 * remote-utils.c [USE_WIN32API] (read, write): Define.
18085 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
18088 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
18090 * linux-i386-low.c (the_low_target): Set arch_string.
18091 * linux-x86-64-low.c (the_low_target): Likewise.
18092 * linux-low.c (linux_arch_string): New.
18093 (linux_target_ops): Add it.
18094 * linux-low.h (struct linux_target_ops): Add arch_string.
18095 * server.c (write_qxfer_response): Use const void * for DATA.
18096 (get_features_xml): New.
18097 (handle_query): Handle qXfer:features:read. Report it for qSupported.
18098 * target.h (struct target_ops): Add arch_string method.
18100 2007-01-03 Denis Pilat <denis.pilat@st.com>
18101 Daniel Jacobowitz <dan@codesourcery.com>
18103 * linux-low.c (linux_kill): Handle being called with no threads.
18104 * win32-i386-low.c (win32_kill): Likewise.
18105 (get_child_debug_event): Clear current_process_handle.
18107 2006-12-30 Denis PILAT <denis.pilat@st.com>
18108 Daniel Jacobowitz <dan@codesourcery.com>
18110 * remote-utils.c (remote_open): Check the type of specified
18111 serial port devices before opening them.
18112 * server.c (main): Kill the inferior if an error occurs during
18113 the first remote_open.
18115 2006-12-05 Markus Deuling <deuling@de.ibm.com>
18117 * README: Update supported targets.
18119 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
18121 * Makefile.in (clean): Remove reg-mips64.c.
18122 (reg-mips64.c, reg-mips64.o): New rules.
18123 * configure.srv: Handle mips64. Include regset support for mips.
18124 * linux-mips-low.c (union mips_register): New.
18125 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
18126 (mips_breakpoint, mips_breakpoint_at): Use int.
18127 (mips_collect_register, mips_supply_register)
18128 (mips_collect_register_32bit, mips_supply_register_32bit)
18129 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
18130 (mips_store_fpregset, target_regsets): New.
18131 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
18133 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
18135 * configure.srv: Add target "spu*-*-*".
18136 * Makefile.in (clean): Remove reg-spu.c.
18137 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
18138 * spu-low.c: New file.
18140 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
18142 * configure.ac: Correct td_thr_tls_get_addr test.
18143 * configure: Regenerated.
18145 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
18147 * linux-low.c (linux_wait_for_event): Reformat. Use the
18148 pass_signals array.
18149 * remote-utils.c (decode_address_to_semicolon): New.
18150 * server.c (pass_signals, handle_general_set): New.
18151 (handle_query): Mention QPassSignals for qSupported.
18152 (main): Call handle_general_set.
18153 * server.h (pass_signals, decode_address_to_semicolon): New.
18155 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
18157 * server.c (handle_query): Correct error handling for read_auxv.
18159 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
18161 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
18162 and srv_linux_thread_db to yes.
18163 * linux-s390-low.c (s390_fill_gregset): New function.
18164 (target_regsets): Define data structure.
18166 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
18168 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
18169 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
18170 * config.in, configure: Regenerated.
18171 * inferiors.c (gdb_id_to_thread): New function.
18172 (gdb_id_to_thread_id): Use it.
18173 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
18174 * linux-low.h (struct process_info): Add th member.
18175 (thread_db_get_tls_address): New prototype.
18176 * remote-utils.c (decode_address): Make non-static.
18177 * server.c (handle_query): Handle qGetTLSAddr.
18178 * server.h (gdb_id_to_thread, decode_address): New prototypes.
18179 * target.h (struct target_ops): Add get_tls_address.
18180 * thread-db.c (maybe_attach_thread): Save the thread handle.
18181 (thread_db_get_tls_address): New.
18183 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
18185 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
18186 (linux_resume_one_process): Take a siginfo_t *. Update all
18187 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
18188 (struct pending_signals): Add a siginfo_t.
18189 (linux_wait_for_process): Always set last_status.
18190 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
18191 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
18192 * linux-low.h (struct process_info): Add last_status.
18194 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
18196 * remote-utils.c (try_rle): New function.
18197 (putpkt_binary): Use it.
18199 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
18201 * Makefile.in (clean): Clean reg-x86-64-linux.c.
18202 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
18203 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
18204 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
18205 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
18208 2006-08-08 Richard Sandiford <richard@codesourcery.com>
18210 * server.c (terminal_fd): New variable.
18211 (old_foreground_pgrp): Likewise.
18212 (restore_old_foreground_pgrp): New function.
18213 (start_inferior): Record the terminal file descriptor in terminal_fd
18214 and its original foreground group in old_foreground_pgrp. Register
18215 restore_old_foreground_pgrp with atexit().
18217 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
18219 * server.c (handle_query): Correct qPart to qXfer.
18221 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
18223 * configure.ac: Check for more headers which are missing on
18224 Windows. Automatically supply -lwsock32 and USE_WIN32API.
18225 * configure.srv: Add Cygwin and mingw32.
18226 * remote-utils.c: Don't include headers unconditionally which
18227 are missing on mingw32. Include <winsock.h> for mingw32.
18228 (remote_open): Adjust for mingw32 support. Flush
18229 standard error after writing to it.
18230 (remote_close, putpkt_binary, input_interrupt, block_async_io)
18231 (unblock_async_io, enable_async_io, disable_async_io)
18232 (readchar, getpkt): Update for Winsock support.
18233 (prepare_resume_reply): Expect a protocol signal number.
18234 * server.c: Disable <sys/wait.h> on mingw32.
18235 (start_inferior): Adjust for mingw32 support. Flush
18236 standard error after writing to it.
18237 (attach_inferior): Likewise. Use protocol signal
18239 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
18241 * win32-i386-low.c: New file.
18242 * Makefile.in (XM_CLIBS): Set.
18243 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
18244 (win32-i386-low.o): New dependency rule.
18245 * linux-low.c (linux_wait): Use target signal numbers.
18246 * target.h (struct target_ops): Doc fix.
18247 * server.h (target_signal_to_name): New prototype.
18248 * gdbreplay.c: Don't include headers unconditionally which
18249 are missing on mingw32. Include <winsock.h> for mingw32.
18250 (remote_close, remote_open): Adjust for Winsock support.
18251 * configure, config.in: Regenerated.
18253 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
18255 * server.c (decode_xfer_read, write_qxfer_response): New.
18256 (handle_query): Take a packet length argument. Handle
18257 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
18258 the qSupported response.
18259 (main): Update call to handle_query.
18261 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
18263 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
18264 (putpkt_binary): Renamed from putpkt and adjusted for binary
18266 (putpkt): New wrapper for putpkt_binary.
18267 (readchar): Don't mask off the high bit.
18268 (decode_X_packet): New function.
18269 * server.c (main): Call putpkt_binary if a handler sets the packet
18270 length. Save the length of the incoming packet. Handle 'X'.
18271 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
18273 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
18275 * server.c (handle_query): Handle qSupported.
18277 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
18279 * remote-utils.c (all_symbols_looked_up): New variable.
18280 (look_up_one_symbol): Check it.
18281 * server.h (look_up_one_symbol): New declaration.
18282 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
18284 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
18286 * Makefile.in (linux-arm-low.o): Update dependencies.
18287 * linux-arm-low.c: Include "gdb_proc_service.h".
18288 (PTRACE_GET_THREAD_AREA): Define.
18289 (ps_get_thread_area): New function.
18291 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
18293 * configure.srv (m68k*-*-uclinux*): New target.
18294 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
18295 (linux_resume_one_process): Remove extraneous cast.
18296 (linux_read_offsets): New.
18297 (linux_target_op): Add linux_read_offsets on mmuless systems.
18298 * server.c (handle_query): Add qOffsets logic.
18299 * target.h (struct target_ops): Add read_offsets.
18301 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
18303 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
18304 (PTRACE_GET_THREAD_AREA): Define.
18305 (ps_get_thread_area): New function.
18306 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
18307 (linux-x86-64-low.o): Update.
18309 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
18311 * configure.ac: Remove checks for prfpregset_t.
18312 * gdb_proc_service.h: New file.
18313 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
18314 new "gdb_proc_service.h".
18315 * proc-service.c: Likewise.
18316 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
18317 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
18318 * Makefile.in (gdb_proc_service_h): Updated.
18319 * configure, config.in: Regenerated.
18321 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
18323 * remote-utils.c (prepare_resume_reply): Move declaration
18324 of gdb_id_from_wait to the top of the block.
18326 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
18328 * linux-low.c (regsets_store_inferior_registers): Read the regset
18329 from the target before filling it.
18331 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
18333 * server.c (attach_inferior): Return SIGTRAP for a successful
18336 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
18338 * Makefile.in (OBS): Add version.o.
18339 (STAGESTUFF): Delete.
18340 (version.o): Add dependencies.
18341 (version.c): Replace rule.
18342 (clean): Remove version.c.
18343 * server.c (gdbserver_version): New.
18344 (gdbserver_usage): Use printf.
18345 (main): Handle --version and --help.
18346 * server.h (version, host_name): Add declarations.
18348 2005-12-23 Eli Zaretskii <eliz@gnu.org>
18360 * linux-x86-64-low.c:
18362 * linux-s390-low.c:
18363 * linux-ppc64-low.c:
18365 * linux-mips-low.c:
18366 * linux-m68k-low.c:
18367 * linux-m32r-low.c:
18370 * linux-ia64-low.c:
18371 * linux-i386-low.c:
18372 * linux-crisv32-low.c:
18384 * gdbserver.1: Add (C) after Copyright. Update the FSF
18387 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
18389 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
18390 (arm_breakpoint_at): Recognize both breakpoints.
18391 (the_low_target): Use the correct breakpoint instruction.
18393 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
18395 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
18396 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
18397 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
18398 (the_low_target): Update.
18400 2005-10-25 Andreas Schwab <schwab@suse.de>
18402 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
18404 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
18405 (ia64_num_regs): Reduce to 462.
18407 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
18409 * acinclude.m4: Correct quoting.
18410 * aclocal.m4: Regenerated.
18412 Suggested by SZOKOVACS Robert <szo@ies.hu>:
18413 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
18414 (thread_db_init): Call thread_db_err_str.
18415 * configure.ac: Check for TD_VERSION.
18416 * config.in, configure: Regenerated.
18418 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
18420 * server.h (error, fatal, warning): Add ATTR_FORMAT.
18422 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
18424 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
18425 is not available. Define HAVE_PTRACE_GETREGS if it is.
18426 * config.in, configure: Regenerated.
18427 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
18428 * linux-i386-low.c, linux-m68k-low.c: Update to use
18429 HAVE_PTRACE_GETREGS.
18430 * linux-low.c (regsets_fetch_inferior_registers)
18431 (regsets_store_inferior_registers): Only return 0 if we processed
18433 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
18434 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
18436 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
18438 * inferiors.c (struct thread_info): Add gdb_id.
18439 (add_thread): Add gdb_id argument.
18440 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
18441 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
18442 calls to add_thread.
18443 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
18444 * server.c (handle_query): Use thread_to_gdb_id.
18445 (handle_v_cont, main): Use gdb_id_to_thread_id.
18446 * server.h (add_thread): Update prototype.
18447 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
18450 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
18452 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
18453 left-padded registers.
18454 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
18455 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
18457 2005-07-01 Steve Ellcey <sje@cup.hp.com>
18459 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
18460 * configure: Regenerate.
18461 * config.in: Regenerate.
18462 * server.h (NEED_DECLARATION_STRERROR):
18463 Replace with !HAVE_DECL_STRERROR.
18465 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
18467 * linux-low.c (linux_wait, linux_send_signal): Don't test
18468 an unsigned long variable for > 0 if it could be MAX_ULONG.
18469 * server.c (myresume): Likewise.
18470 * target.c (set_desired_inferior): Likewise.
18472 2005-06-13 Mark Kettenis <kettenis@gnu.org>
18474 * configure.ac: Simplify and improve check for socklen_t.
18475 * configure, config.in: Regenerate.
18477 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
18479 * acconfig.h: Remove.
18480 * configure.ac: Add a test for socklen_t. Use three-argument
18481 AC_DEFINE throughout.
18482 * config.in: Regenerated using autoheader 2.59.
18483 * configure: Regenerated.
18485 * gdbreplay.c (socklen_t): Provide a default.
18486 (remote_open): Use socklen_t.
18487 * remote-utils.c (socklen_t): Provide a default.
18488 (remote_open): Use socklen_t.
18489 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
18492 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
18494 * linux-low.c (linux_read_memory, linux_write_memory)
18495 (linux_read_auxv): Likewise.
18496 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
18497 (check_mem_write): Likewise.
18498 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
18500 * regcache.c (struct inferior_rgcache_data, registers_to_string)
18501 (registers_from_string, register_data): Likewise.
18502 * server.c (handle_query, main): Likewise.
18503 * server.h (convert_ascii_to_int, convert_int_to_ascii)
18504 (decode_M_packet): Likewise.
18505 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
18506 * target.h (struct target_ops): Update read_memory, write_memory,
18508 (read_inferior_memory, write_inferior_memory): Update.
18509 * linux-low.h (struct linux_target_ops): Change type of breakpoint
18510 to unsigned char *.
18511 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
18512 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
18513 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
18514 linux-s390-low.c, linux-sh-low.c: Update for changes in
18515 read_inferior_memory and the_low_target->breakpoint.
18517 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
18519 * Makefile.in (SFILES): Add linux-ppc64-low.c.
18520 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
18521 * configure.srv: Add powerpc64-*-linux*.
18522 * linux-ppc64-low.c: New file.
18524 2005-05-23 Orjan Friberg <orjanf@axis.com>
18526 * linux-cris-low.c: New file with support for CRIS.
18527 * linux-crisv32-low.c: Ditto for CRISv32.
18528 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
18529 (clean): Add reg-cris.c and reg-crisv32.c.
18530 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
18531 reg-crisv32.o, and reg-crisv32.c to make rules.
18532 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
18533 recognized targets.
18535 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
18537 * linux-low.c (fetch_register): Ensure buffer size is a multiple
18538 of sizeof (PTRACE_XFER_TYPE).
18539 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
18541 2005-05-12 Orjan Friberg <orjanf@axis.com>
18543 * target.h (struct target_ops): Add insert_watchpoint,
18544 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
18545 pointers for hardware watchpoint support.
18546 * linux-low.h (struct linux_target_ops): Ditto.
18547 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
18548 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
18549 to linux_target_ops.
18550 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
18552 * server.c (main): Recognize 'Z' and 'z' packets.
18554 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
18556 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
18557 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
18558 (the_low_target): Add new members.
18560 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
18562 * proc-service.c (ps_lgetregs): Search all_processes instead of
18565 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
18567 * server.c (start_inferior): Change return type to int.
18568 (attach_inferior): Change sigptr to int *.
18569 (handle_v_cont, handle_v_requests): Change signal to int *.
18570 (main): Change signal to int.
18572 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
18574 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
18575 * configure.srv: Add m32r*-*-linux*.
18576 * linux-m32r-low.c: New file.
18578 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
18580 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
18582 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
18584 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
18585 Take unsigned long arguments for PIDs.
18586 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
18587 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
18588 (wait_for_sigstop, linux_resume_one_process)
18589 (regsets_fetch_inferior_registers, linux_send_signal)
18590 (linux_read_auxv): Likewise. Update the types of variables holding
18591 PIDs. Update format string specifiers.
18592 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
18593 * remote-utils.c (prepare_resume_reply): Likewise.
18594 * server.c (cont_thread, general_thread, step_thread)
18595 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
18597 (handle_query): Update format specifiers.
18598 (handle_v_cont, main): Use strtoul for thread IDs.
18599 * server.h (struct inferior_list_entry): Use unsigned long for ID.
18600 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
18601 (general_thread, step_thread, thread_from_wait)
18602 (old_thread_from_wait): Update.
18603 * target.h (struct thread_resume): Use unsigned long for THREAD.
18604 (struct target_ops): Use unsigned long for arguments to attach and
18607 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
18609 * acinclude.m4: Include bfd/bfd.m4 directly.
18610 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
18611 <agriffis@toolchain.org>.
18612 * aclocal.m4, configure: Regenerated.
18614 2005-01-07 Andrew Cagney <cagney@gnu.org>
18616 * configure.ac: Rename configure.in, require autoconf 2.59.
18617 * configure: Re-generate.
18619 2004-12-08 Daniel Jacobowitz <dan@debian.org>
18621 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
18622 LIBS when finished.
18623 * aclocal.m4: Regenerated.
18624 * configure: Regenerated.
18626 2004-11-21 Andreas Schwab <schwab@suse.de>
18628 * linux-m68k-low.c (m68k_num_gregs): Define.
18629 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
18630 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
18631 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
18632 (m68k_breakpoint_at): New. Add to the_low_target.
18634 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
18635 srv_linux_thread_db to yes.
18637 2004-10-20 Joel Brobecker <brobecker@gnat.com>
18639 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
18640 (ARCH_SET_FS): Likewise.
18641 (ARCH_GET_FS): Likewise.
18642 (ARCH_GET_GS): Likewise.
18644 2004-10-16 Daniel Jacobowitz <dan@debian.org>
18646 * linux-i386-low.c (ps_get_thread_area): New.
18647 * linux-x86-64-low.c (ps_get_thread_area): New.
18648 * linux-low.c: Include <sys/syscall.h>.
18649 (linux_kill_one_process): Don't kill the first thread here.
18650 (linux_kill): Kill the first thread here.
18651 (kill_lwp): New function.
18652 (send_sigstop, linux_send_signal): Use it.
18653 * proc-service.c: Clean up #ifdefs.
18654 (fpregset_info): Delete.
18655 (ps_lgetregs): Update and enable implementation.
18656 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
18658 * remote-utils.c (struct sym_cache, symbol_cache): New.
18659 (input_interrupt): Print a clearer message.
18660 (async_io_enabled): New variable.
18661 (enable_async_io, disable_async_io): Use it. Update comments.
18662 (look_up_one_symbol): Use the symbol cache.
18663 * thread-db.c (thread_db_look_up_symbols): New function.
18664 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
18666 2004-10-16 Daniel Jacobowitz <dan@debian.org>
18668 * configure.in: Test for -rdynamic.
18669 * configure: Regenerated.
18670 * Makefile (INTERNAL_LDFLAGS): New.
18671 (gdbserver, gdbreplay): Use it.
18673 2004-09-02 Andrew Cagney <cagney@gnu.org>
18675 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
18677 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
18679 * linux-low.c (linux_wait): Clear all_processes list also.
18681 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
18683 * linux-low.c: Include <errno.h>. Remove extern declaration of
18686 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
18688 * gdbreplay.c, server.h, utils.c: Update copyright years.
18690 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
18692 * server.c (main): Print child status or termination signal from
18693 variable 'signal', not 'sig'.
18695 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
18697 * linux-low.c (linux_read_memory): Change return type to
18698 int. Check for and return error from ptrace().
18699 * target.c (read_inferior_memory): Change return type to int. Pass
18700 back return status from the_target->read_memory().
18701 * target.h (struct target_ops): Adapt *read_memory() prototype.
18703 (read_inferior_memory): Adapt prototype.
18704 * server.c (main): Return an error packet if
18705 read_inferior_memory() returns an error.
18707 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
18709 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
18710 Unify with other clean targets.
18712 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
18714 * server.c (handle_v_cont): Call set_desired_inferior.
18716 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
18718 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
18720 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
18722 * linux-low.c (linux_wait): Unblock async I/O.
18723 (linux_resume): Block and enable async I/O.
18724 * remote-utils.c (block_async_io, unblock_async_io): New functions.
18725 * server.h (block_async_io, unblock_async_io): Add prototypes.
18727 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
18729 * remote-utils.c (remote_open): Print a status notice after
18730 opening a TCP port.
18731 * server.c (attach_inferior): Print a status notice after
18734 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
18736 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
18738 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
18740 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
18742 * server.c, target.h: Update copyright years.
18744 2004-02-25 Roland McGrath <roland@redhat.com>
18746 * target.h (struct target_ops): New member `read_auxv'.
18747 * server.c (handle_query): Handle qPart:auxv:read: query using that.
18748 * linux-low.c (linux_read_auxv): New function.
18749 (linux_target_ops): Initialize `read_auxv' member to that.
18751 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
18753 Committed by Jim Blandy <jimb@redhat.com>.
18755 * linux-s390-low.c (s390_num_regs): Update.
18756 (s390_regmap): Remove control registers. Use __s390x__ predefine
18757 instead of GPR_SIZE to distiguish s390 and s390x targets.
18759 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
18761 * linux-low.c: Update copyright year.
18762 (check_removed_breakpoint): Clear pending_is_breakpoint.
18763 (linux_set_resume_request, linux_queue_one_thread)
18764 (resume_status_pending_p): New functions.
18765 (linux_continue_one_thread): Use process->resume.
18766 (linux_resume): Only resume threads if there are no pending events.
18767 * linux-low.h (struct process_info): Add resume request
18770 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
18772 * regcache.c (new_register_cache): Clear the allocated register
18773 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
18775 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
18777 * linux-low.c (linux_resume): Take a struct thread_resume *
18779 (linux_wait): Update call.
18780 (resume_ptr): New static variable.
18781 (linux_continue_one_thread): Renamed from
18782 linux_continue_one_process. Use resume_ptr.
18783 (linux_resume): Use linux_continue_one_thread.
18784 * server.c (handle_v_cont, handle_v_requests): New functions.
18785 (myresume): New function.
18786 (main): Handle 'v' case.
18787 * target.h (struct thread_resume): New type.
18788 (struct target_ops): Change argument of "resume" to struct
18790 (myresume): Delete macro.
18792 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
18794 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
18795 (uninstall): Support DESTDIR.
18797 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
18799 * configure.srv: Add xscale*linux copy of arm*linux entry.
18801 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
18803 * linux-arm-low.c (arm_reinsert_addr): New function.
18804 (the_low_target): Add arm_reinsert_addr.
18806 2003-07-08 Mark Kettenis <kettenis@gnu.org>
18808 * mem-break.c: Remove whitespace at end of file.
18810 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
18812 * configure.in: Check whether we need to prototype strerror.
18813 * server.h: Optionally prototype strerror.
18814 * gdbreplay.c (perror_with_name): Use strerror.
18815 * linux-low.c (linux_attach_lwp): Use strerror.
18816 * utils.c (perror_with_name): Use strerror.
18817 * config.in, configure: Regenerated.
18819 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
18821 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
18822 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
18824 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
18826 * Makefile.in (SFILES): Update.
18827 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
18828 low-sun3.c: Remove files.
18830 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
18832 * linux-low.c: Move comment to linux_thread_alive where it belonged.
18833 (linux_detach_one_process, linux_detach): New functions.
18834 (linux_target_ops): Add linux_detach.
18835 * server.c (main): Handle 'D' packet.
18836 * target.h (struct target_ops): Add "detach" member.
18837 (detach_inferior): Define.
18839 2003-06-13 Mark Kettenis <kettenis@gnu.org>
18841 From Kelley Cook <kelleycook@wideopenwest.com>:
18842 * configure.srv: Accept i[34567]86 variants.
18844 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
18846 * linux-low.c (linux_wait_for_event): Correct comment typos.
18847 (linux_resume_one_process): Call check_removed_breakpoint.
18848 (linux_send_signal): New function.
18849 (linux_target_ops): Add linux_send_signal.
18850 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
18852 * target.h (struct target_ops): Add send_signal.
18854 2003-05-29 Jim Blandy <jimb@redhat.com>
18856 * linux-low.c (usr_store_inferior_registers): Transfer buf in
18857 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
18858 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
18859 away part of the register's value.
18861 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
18863 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
18864 (linux_wait_for_event, linux_init_signals): Likewise.
18866 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
18868 * configure.in: Check for stdlib.h.
18869 * configure: Regenerated.
18870 * config.in: Regenerated.
18872 2003-01-04 Andreas Schwab <schwab@suse.de>
18874 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
18876 2003-01-02 Andrew Cagney <ac131313@redhat.com>
18878 * Makefile.in: Remove obsolete code.
18880 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
18882 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
18883 defined(PT_FPR0_HI).
18885 2002-11-17 Stuart Hughes <seh@zee2.com>
18887 * linux-arm-low.c (arm_num_regs): Increase.
18888 (arm_regmap): Include status register.
18890 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
18892 * linux-low.c (register_addr): Remove incorrect -1 check.
18894 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
18896 * linux-low.c (linux_create_inferior): Call setpgid. Return
18898 (unstopped_p, linux_signal_pid): Remove.
18899 (linux_target_ops): Remove linux_signal_pid.
18900 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
18901 global instead of target method.
18902 * target.h (struct target_ops): Remove signal_pid. Update comment
18903 for create_inferior.
18904 * server.c (signal_pid): New variable.
18905 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
18906 gdbserver. Set the child to be the foreground process group.
18907 (attach_inferior): Set signal_pid.
18909 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
18911 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
18913 2002-08-20 Jim Blandy <jimb@redhat.com>
18915 * Makefile.in (LDFLAGS): Allow the configure script to establish a
18918 2002-08-01 Andrew Cagney <cagney@redhat.com>
18920 * Makefile.in: Make chill references obsolete.
18922 2002-07-24 Kevin Buettner <kevinb@redhat.com>
18924 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
18925 * configure: Regenerate.
18926 * config.in: Regenerate.
18928 2002-07-09 David O'Brien <obrien@FreeBSD.org>
18930 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
18931 (perror_with_name, remote_close, remote_open, expect, play): Static.
18933 2002-07-04 Michal Ludvig <mludvig@suse.cz>
18935 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
18936 byte offsets instead of an array of indexes.
18937 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
18939 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
18941 * regcache.c: Add comment.
18943 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
18945 * thread-db.c: New file.
18946 * proc-service.c: New file.
18947 * acinclude.m4: New file.
18948 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
18949 proc-service.o, and thread-db.o.
18950 (linux-low.o): Add USE_THREAD_DB.
18951 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
18952 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
18953 * aclocal.m4: Regenerated.
18954 * config.in: Regenerated.
18955 * configure: Regenerated.
18956 * configure.in: Check for proc_service.h, sys/procfs.h,
18957 thread_db.h, and linux/elf.h headrs.
18958 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
18959 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
18960 Check for -lthread_db and thread support.
18961 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
18962 PowerPC, and SuperH.
18963 * i387-fp.c: Constify arguments.
18964 * i387-fp.h: Likewise.
18965 * inferiors.c: (struct thread_info): Renamed from
18966 `struct inferior_info'. Remove PID member. Use generic inferior
18967 list header. All uses updated.
18968 (inferiors, signal_pid): Removed.
18969 (all_threads): New variable.
18970 (get_thread): Define.
18971 (add_inferior_to_list): New function.
18972 (for_each_inferior): New function.
18973 (change_inferior_id): New function.
18974 (add_inferior): Removed.
18975 (remove_inferior): New function.
18976 (add_thread): New function.
18977 (free_one_thread): New function.
18978 (remove_thread): New function.
18979 (clear_inferiors): Use for_each_inferior and free_one_thread.
18980 (find_inferior): New function.
18981 (find_inferior_id): New function.
18982 (inferior_target_data): Update argument type.
18983 (set_inferior_target_data): Likewise.
18984 (inferior_regcache_data): Likewise.
18985 (set_inferior_regcache_data): Likewise.
18986 * linux-low.c (linux_bp_reinsert): Remove.
18987 (all_processes, stopping_threads, using_thrads)
18988 (struct pending_signals, debug_threads, pid_of): New.
18989 (inferior_pid): Replace with macro.
18990 (struct inferior_linux_data): Remove.
18991 (get_stop_pc, add_process): New functions.
18992 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
18993 Use add_process and add_thread.
18994 (linux_attach_lwp): New function, based on old linux_attach. Use
18995 add_process and add_thread. Set stop_expected for new threads.
18996 (linux_attach): New function.
18997 (linux_kill_one_process): New function.
18998 (linux_kill): Kill all LWPs.
18999 (linux_thread_alive): Use find_inferior_id.
19000 (check_removed_breakpoints, status_pending_p): New functions.
19001 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
19002 Update. Use WNOHANG. Wait for cloned processes also. Update process
19003 struct for the found process.
19004 (linux_wait_for_event): New function.
19005 (linux_wait): Use it. Support LWPs.
19006 (send_sigstop, wait_for_sigstop, stop_all_processes)
19007 (linux_resume_one_process, linux_continue_one_process): New functions.
19008 (linux_resume): Support LWPs.
19009 (REGISTER_RAW_SIZE): Remove.
19010 (fetch_register): Use register_size instead. Call supply_register.
19011 (usr_store_inferior_registers): Likewise. Call collect_register.
19012 Fix recursive case.
19013 (regsets_fetch_inferior_registers): Improve error message.
19014 (regsets_store_inferior_registers): Add debugging.
19015 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
19016 (unstopped_p, linux_signal_pid): New functions.
19017 (linux_target_ops): Add linux_signal_pid.
19018 (linux_init_signals): New function.
19019 (initialize_low): Call it. Initialize using_threads.
19020 * regcache.c (inferior_regcache_data): Add valid
19022 (get_regcache): Fetch registers lazily. Add fetch argument
19023 and update all callers.
19024 (regcache_invalidate_one, regcache_invalidate): New
19026 (new_register_cache): Renamed from create_register_cache.
19027 Return the new regcache.
19028 (free_register_cache): Change argument to a void *.
19029 (registers_to_string, registers_from_string): Call get_regcache
19030 with fetch flag set.
19031 (register_data): Make static. Pass fetch flag to get_regcache.
19032 (supply_register): Call get_regcache with fetch flag clear.
19033 (collect_register): Call get_regcache with fetch flag set.
19034 (collect_register_as_string): New function.
19035 * regcache.h: Update.
19036 * remote-utils.c (putpkt): Flush after debug output and use
19038 Handle input interrupts while waiting for an ACK.
19039 (input_interrupt): Use signal_pid method.
19040 (getpkt): Flush after debug output and use stderr.
19041 (outreg): Use collect_register_as_string.
19042 (new_thread_notify, dead_thread_notify): New functions.
19043 (prepare_resume_reply): Check using_threads. Set thread_from_wait
19044 and general_thread.
19045 (look_up_one_symbol): Flush after debug output.
19046 * server.c (step_thread, server_waiting): New variables.
19047 (start_inferior): Don't use signal_pid. Update call to mywait.
19048 (attach_inferior): Update call to mywait.
19049 (handle_query): Handle qfThreadInfo and qsThreadInfo.
19050 (main): Don't fetch/store registers explicitly. Use
19051 set_desired_inferior. Support proposed ``Hs'' packet. Update
19053 * server.h: Update.
19054 (struct inferior_list, struct_inferior_list_entry): New.
19055 * target.c (set_desired_inferior): New.
19056 (write_inferior_memory): Constify.
19057 (mywait): New function.
19058 * target.h: Update.
19059 (struct target_ops): New signal_pid method.
19060 (mywait): Removed macro, added prototype.
19062 * linux-low.h (regset_func): Removed.
19063 (regset_fill_func, regset_store_func): New.
19064 (enum regset_type): New.
19065 (struct regset_info): Add type field. Use new operation types.
19066 (struct linux_target_ops): stop_pc renamed to get_pc.
19067 Add decr_pc_after_break and breakpoint_at.
19068 (get_process, get_thread_proess, get_process_thread)
19069 (strut process_info, all_processes, linux_attach_lwp)
19070 (thread_db_init): New.
19072 * linux-arm-low.c (arm_get_pc, arm_set_pc,
19073 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
19074 (the_low_target): Add new members.
19075 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
19076 (i386_store_fpxregset): Constify.
19077 (target_regsets): Add new kind identifier.
19078 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
19079 (i386_set_pc): Add debugging.
19080 (i386_breakpoint_at): New function.
19081 (the_low_target): Add new members.
19082 * linux-mips-low.c (mips_get_pc, mips_set_pc)
19083 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
19084 (mips_breakpoint_at): New.
19085 (the_low_target): Add new members.
19086 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
19087 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
19088 (the_low_target): Add new members.
19089 * linux-sh-low.c (sh_get_pc, sh_set_pc)
19090 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
19091 (the_low_target): Add new members.
19092 * linux-x86-64-low.c (target_regsets): Add new kind
19095 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
19097 From Martin Pool <mbp@samba.org>:
19098 * server.c (gdbserver_usage): New function.
19101 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
19103 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
19104 stop_at -> stop_pc.
19106 2002-05-04 Andrew Cagney <ac131313@redhat.com>
19108 * Makefile.in: Remove obsolete code.
19110 2002-04-24 Michal Ludvig <mludvig@suse.cz>
19112 * linux-low.c (regsets_fetch_inferior_registers),
19113 (regsets_store_inferior_registers): Removed cast to int from
19115 * regcache.h: Added declaration of struct inferior_info.
19117 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
19119 * inferiors.c (struct inferior_info): Add regcache_data.
19120 (add_inferior): Call create_register_cache.
19121 (clear_inferiors): Call free_register_cache.
19122 (inferior_regcache_data, set_inferior_regcache_data): New functions.
19123 * regcache.c (struct inferior_regcache_data): New.
19124 (registers): Remove.
19125 (get_regcache): New function.
19126 (create_register_cache, free_register_cache): New functions.
19127 (set_register_cache): Don't initialize the register cache here.
19128 (registers_to_string, registers_from_string, register_data): Call
19130 * regcache.h: Add prototypes.
19131 * server.h: Likewise.
19133 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
19135 * mem-break.c: New file.
19136 * mem-break.h: New file.
19137 * Makefile.in: Add mem-break.o rule; update server.h
19139 * inferiors.c (struct inferior_info): Add target_data
19141 (clear_inferiors): Free target_data member if set.
19142 (inferior_target_data, set_inferior_target_data): New functions.
19143 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
19144 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
19145 * linux-low.c (linux_bp_reinsert): New variable.
19146 (struct inferior_linux_data): New.
19147 (linux_create_inferior): Use set_inferior_target_data.
19148 (linux_attach): Likewise. Call add_inferior.
19149 (linux_wait_for_one_inferior): New function.
19150 (linux_wait): Call it.
19151 (linux_write_memory): Add const.
19152 (initialize_low): Call set_breakpoint_data.
19153 * linux-low.h (struct linux_target_ops): Add breakpoint
19155 * server.c (attach_inferior): Remove extra add_inferior
19157 * server.h: Include mem-break.h. Update inferior.c
19159 * target.c (read_inferior_memory)
19160 (write_inferior_memory): New functions.
19161 * target.h (read_inferior_memory)
19162 (write_inferior_memory): Change macros to prototypes.
19163 (struct target_ops): Update comments. Add const to write_memory
19166 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
19168 * linux-low.c (usr_store_inferior_registers): Support
19169 registers which are allowed to fail to store.
19170 * linux-low.h (linux_target_ops): Likewise.
19171 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
19172 (ppc_cannot_store_register): FPSCR may not be storable.
19174 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
19176 * server.h: Include <string.h> if HAVE_STRING_H.
19177 * ChangeLog: Correct paths in last ChangeLog entry.
19179 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
19181 * linux-low.h: Remove obsolete prototypes.
19182 (struct linux_target_ops): New.
19183 (extern the_low_target): New.
19184 * linux-low.c (num_regs, regmap): Remove declarations.
19185 (register_addr): Use the_low_target explicitly.
19186 (fetch_register): Likewise.
19187 (usr_fetch_inferior_registers): Likewise.
19188 (usr_store_inferior_registers): Likewise.
19189 * linux-arm-low.c (num_regs): Remove.
19190 (arm_num_regs): Define.
19191 (arm_regmap): Renamed from regmap, made static.
19192 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
19194 (arm_cannot_store_register): Renamed from cannot_store_register,
19196 (the_low_target): New.
19197 * linux-i386-low.c (num_regs): Remove.
19198 (i386_num_regs): Define.
19199 (i386_regmap): Renamed from regmap, made static.
19200 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
19202 (i386_cannot_store_register): Renamed from cannot_store_register,
19204 (the_low_target): New.
19205 * linux-ia64-low.c (num_regs): Remove.
19206 (ia64_num_regs): Define.
19207 (ia64_regmap): Renamed from regmap, made static.
19208 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
19210 (ia64_cannot_store_register): Renamed from cannot_store_register,
19212 (the_low_target): New.
19213 * linux-m68k-low.c (num_regs): Remove.
19214 (m68k_num_regs): Define.
19215 (m68k_regmap): Renamed from regmap, made static.
19216 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
19218 (m68k_cannot_store_register): Renamed from cannot_store_register,
19220 (the_low_target): New.
19221 * linux-mips-low.c (num_regs): Remove.
19222 (mips_num_regs): Define.
19223 (mips_regmap): Renamed from regmap, made static.
19224 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
19226 (mips_cannot_store_register): Renamed from cannot_store_register,
19228 (the_low_target): New.
19229 * linux-ppc-low.c (num_regs): Remove.
19230 (ppc_num_regs): Define.
19231 (ppc_regmap): Renamed from regmap, made static.
19232 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
19234 (ppc_cannot_store_register): Renamed from cannot_store_register,
19236 (the_low_target): New.
19237 * linux-s390-low.c (num_regs): Remove.
19238 (s390_num_regs): Define.
19239 (s390_regmap): Renamed from regmap, made static.
19240 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
19242 (s390_cannot_store_register): Renamed from cannot_store_register,
19244 (the_low_target): New.
19245 * linux-sh-low.c (num_regs): Remove.
19246 (sh_num_regs): Define.
19247 (sh_regmap): Renamed from regmap, made static.
19248 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
19250 (sh_cannot_store_register): Renamed from cannot_store_register,
19252 (the_low_target): New.
19253 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
19254 (the_low_target): New.
19256 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
19258 * Makefile.in: Add stamp-h target.
19259 * configure.in: Create stamp-h.
19260 * configure: Regenerated.
19262 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
19264 * inferiors.c: New file.
19265 * target.c: New file.
19266 * target.h: New file.
19267 * Makefile.in: Add target.o and inferiors.o. Update
19269 * linux-low.c (inferior_pid): New static variable,
19270 moved from server.c.
19271 (linux_create_inferior): Renamed from create_inferior.
19272 Call add_inferior. Return 0 on success instead of a PID.
19273 (linux_attach): Renamed from myattach.
19274 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
19275 (linux_thread_alive): Renamed from mythread_alive.
19276 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
19278 (linux_resume): Renamed from myresume. Add missing ``return 0''.
19279 (regsets_store_inferior_registers): Correct error message.
19280 Add missing ``return 0''.
19281 (linux_fetch_registers): Renamed from fetch_inferior_registers.
19282 (linux_store_registers): Renamed from store_inferior_registers.
19283 (linux_read_memory): Renamed from read_inferior_memory.
19284 (linux_write_memory): Renamed from write_inferior_memory.
19285 (linux_target_ops): New structure.
19286 (initialize_low): Call set_target_ops ().
19287 * remote-utils.c (unhexify): New function.
19288 (hexify): New function.
19289 (input_interrupt): Send signals to ``signal_pid''.
19290 * server.c (inferior_pid): Remove.
19291 (start_inferior): Update create_inferior call.
19292 (attach_inferior): Call add_inferior.
19293 (handle_query): New function.
19294 (main): Call handle_query for `q' packets.
19295 * server.h: Include "target.h". Remove obsolete prototypes.
19296 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
19298 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
19300 * Makefile.in: Add WARN_CFLAGS. Update configury
19302 * configure.in: Check for <string.h>
19303 * configure: Regenerate.
19304 * config.in: Regenerate.
19305 * gdbreplay.c: Include needed system headers.
19306 (remote_open): Remove strchr prototype.
19307 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
19308 * regcache.c (supply_register): Change buf argument to const void *.
19309 (supply_register_by_name): Likewise.
19310 (collect_register): Change buf argument to void *.
19311 (collect_register_by_name): Likewise.
19312 * regcache.h: Add missing prototypes.
19313 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
19314 * server.c (handle_query): New function.
19315 (attached): New static variable, moved out of main.
19316 (main): Quiet longjmp clobber warnings.
19317 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
19318 * utils.c (error): Remove NORETURN.