1 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3 Turn process_stratum_target's stabilize_threads op into a
4 method of process_target.
6 * target.h (struct process_stratum_target): Remove the target op.
7 (class process_target): Add the target op.
8 (target_stabilize_threads): Update the macro.
9 * target.cc (process_target::stabilize_threads): Define.
11 Update the derived classes and callers below.
13 * server.cc (handle_status): Update.
14 * tracepoint.cc (cmd_qtdp): Update.
15 (cmd_qtstart): Update.
16 * linux-low.cc (linux_target_ops): Update.
17 (linux_stabilize_threads): Turn into ...
18 (linux_process_target::stabilize_threads): ... this.
19 (linux_wait_1): Update.
20 * linux-low.h (class linux_process_target): Update.
21 * lynx-low.cc (lynx_target_ops): Update.
22 * nto-low.cc (nto_target_ops): Update.
23 * win32-low.cc (win32_target_ops): Update.
25 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
27 Turn process_stratum_target's pause_all and unpause_all ops
28 into methods of process_target.
30 * target.h (struct process_stratum_target): Remove the target ops.
31 (class process_target): Add the target ops.
32 (pause_all): Update the macro and rename to...
33 (target_pause_all): ... this.
34 (unpause_all): Update the macro and rename to...
35 (target_unpause_all): ... this.
36 * target.cc (process_target::pause_all): Define.
37 (process_target::unpause_all): Define.
39 Update the derived classes and callers below.
41 * server.cc (handle_status): Update.
42 * tracepoint.cc (clear_installed_tracepoints): Update.
44 (cmd_qtstart): Update.
45 (stop_tracing): Update.
46 (cmd_qtstatus): Update.
47 (upload_fast_traceframes): Update.
48 (run_inferior_command): Update.
49 * linux-low.cc (linux_target_ops): Update.
50 (linux_pause_all): Turn into ...
51 (linux_process_target::pause_all): ... this.
52 (linux_unpause_all): Turn into ...
53 (linux_process_target::unpause_all): ... this.
54 (linux_process_target::prepare_to_access_memory): Update.
55 (linux_process_target::done_accessing_memory): Update.
56 * linux-low.h (class linux_process_target): Update.
57 * lynx-low.cc (lynx_target_ops): Update.
58 * nto-low.cc (nto_target_ops): Update.
59 * win32-low.cc (win32_target_ops): Update.
61 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
63 Turn process_stratum_target's get_tib_address op into a method of
66 * target.h (struct process_stratum_target): Remove the target op.
67 (class process_target): Add the target op. Also add
68 'supports_get_tib_address'.
69 * target.cc (process_target::get_tib_address): Define.
70 (process_target::supports_get_tib_address): Define.
72 Update the derived classes and callers below.
74 * server.cc (handle_query): Update.
75 * linux-low.cc (win32_target_ops): Update.
76 * lynx-low.cc (lynx_target_ops): Update.
77 * nto-low.cc (nto_target_ops): Update.
78 * win32-low.cc (win32_target_ops): Update.
79 (win32_process_target::supports_get_tib_address): Define.
80 (win32_get_tib_address): Turn into ...
81 (win32_process_target::get_tib_address): ... this.
82 * win32-low.h (class win32_process_target): Update.
84 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
86 Turn process_stratum_target's thread_stopped op into a method of
89 * target.h (struct process_stratum_target): Remove the target op.
90 (class process_target): Add the target op. Also add
91 'supports_thread_stopped'.
92 (target_thread_stopped): Update the macro.
93 * target.cc (process_target::thread_stopped): Define.
94 (process_target::supports_thread_stopped): Define.
95 (prepare_to_access_memory): Update.
97 Update the derived classes and callers below.
99 * server.cc (queue_stop_reply_callback): Update.
100 * linux-low.cc (linux_target_ops): Update.
101 (linux_process_target::supports_thread_stopped): Define.
102 (linux_thread_stopped): Turn into ...
103 (linux_process_target::thread_stopped): ... this.
104 * linux-low.h (class linux_process_target): Update.
105 * lynx-low.cc (lynx_target_ops): Update.
106 * nto-low.cc (nto_target_ops): Update.
107 * win32-low.cc (win32_target_ops): Update.
109 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
111 Turn process_stratum_target's read_pc and write_pc ops into
112 methods of process_target.
114 * target.h (struct process_stratum_target): Remove the target ops.
115 (class process_target): Add the target ops.
116 * target.cc (process_target::read_pc): Define.
117 (process_target::write_pc): Define.
119 Update the derived classes and callers below.
121 * regcache.cc (regcache_read_pc): Update.
122 (regcache_write_pc): Update.
123 * linux-low.cc (linux_target_ops): Update.
124 (linux_read_pc): Turn into ...
125 (linux_process_target::read_pc): ... this.
126 (linux_write_pc): Turn into ...
127 (linux_process_target::write_pc): ... this.
128 * linux-low.h (class linux_process_target): Update.
129 * lynx-low.cc (lynx_target_ops): Update.
130 * nto-low.cc (nto_target_ops): Update.
131 * win32-low.cc (win32_target_ops): Update.
133 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
135 Turn process_stratum_target's supports_tracepoints op into a
136 method of process_target.
138 * target.h (struct process_stratum_target): Remove the target op.
139 (class process_target): Add the target op.
140 (target_supports_tracepoints): Update the macro.
141 * target.cc (process_target::supports_tracepoints): Define.
143 Update the derived classes and callers below.
145 * linux-low.cc (linux_target_ops): Update.
146 (linux_supports_tracepoints): Turn into ...
147 (linux_process_target::supports_tracepoints): ... this.
148 * linux-low.h (class linux_process_target): Update.
149 * lynx-low.cc (lynx_target_ops): Update.
150 * nto-low.cc (nto_target_ops): Update.
151 * win32-low.cc (win32_target_ops): Update.
153 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
155 Turn process_stratum_target's process_qsupported op into a method
158 * target.h (struct process_stratum_target): Remove the target op.
159 (class process_target): Add the target op.
160 (target_process_qsupported): Update the macro.
161 * target.cc (process_target::process_qsupported): Define.
163 Update the derived classes and callers below.
165 * linux-low.cc (linux_target_ops): Update.
166 (linux_process_qsupported): Turn into ...
167 (linux_process_target::process_qsupported): ... this.
168 * linux-low.h (class linux_process_target): Update.
169 * lynx-low.cc (lynx_target_ops): Update.
170 * nto-low.cc (nto_target_ops): Update.
171 * win32-low.cc (win32_target_ops): Update.
173 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
175 Turn process_stratum_target's read_loadmap op into a method of
178 * target.h (struct process_stratum_target): Remove the target op.
179 (class process_target): Add the target op. Also add
180 'supports_read_loadmap'.
181 * target.cc (process_target::read_loadmap): Define.
182 (process_target::supports_read_loadmap): Define.
184 Update the derived classes and callers below.
186 * server.cc (handle_qxfer_fdpic): Update.
187 (handle_query): Update.
188 * linux-low.cc (linux_target_ops): Update.
189 (linux_process_target::supports_read_loadmap): Define.
190 (linux_read_loadmap): Turn into ...
191 (linux_process_target::read_loadmap): ... this.
192 * linux-low.h (class linux_process_target): Update.
193 * lynx-low.cc (lynx_target_ops): Update.
194 * nto-low.cc (nto_target_ops): Update.
195 * win32-low.cc (win32_target_ops): Update.
197 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
199 Turn process_stratum_target's core_of_thread op into a method of
202 * target.h (struct process_stratum_target): Remove the target op.
203 (class process_target): Add the target op.
204 (target_core_of_thread): Update the macro.
205 * target.cc (process_target::core_of_thread): Define.
207 Update the derived classes and callers below.
209 * linux-low.cc (linux_target_ops): Update.
210 (linux_process_target::core_of_thread): Define.
211 * linux-low.h (class linux_process_target): Update.
212 * lynx-low.cc (lynx_target_ops): Update.
213 * nto-low.cc (nto_target_ops): Update.
214 * win32-low.cc (win32_target_ops): Update.
216 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
218 Turn process_stratum_target's handle_monitor_command op into a
219 method of process_target.
221 * target.h (struct process_stratum_target): Remove the target op.
222 (class process_target): Add the target op.
223 (target_handle_monitor_command): Update the macro.
224 * target.cc (process_target::handle_monitor_command): Define.
226 Update the derived classes and callers below.
228 * server.cc (handle_query): Update.
229 * linux-low.cc (linux_target_ops): Update.
230 (linux_process_target::handle_monitor_command): Define.
231 * linux-low.h (class linux_process_target): Update.
232 * lynx-low.cc (lynx_target_ops): Update.
233 * nto-low.cc (nto_target_ops): Update.
234 * win32-low.cc (win32_target_ops): Update.
236 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
238 Turn process_stratum_target's handle_new_gdb_connection op into a
239 method of process_target.
241 * target.h (struct process_stratum_target): Remove the target op.
242 (class process_target): Add the target op.
243 (target_handle_new_gdb_connection): Update the macro.
244 * target.cc (process_target::handle_new_gdb_connection): Define.
246 Update the derived classes and callers below.
248 * linux-low.cc (linux_target_ops): Update.
249 (linux_handle_new_gdb_connection): Turn into ...
250 (linux_process_target::handle_new_gdb_connection): ... this.
251 * linux-low.h (class linux_process_target): Update.
252 * lynx-low.cc (lynx_target_ops): Update.
253 * nto-low.cc (nto_target_ops): Update.
254 * win32-low.cc (win32_target_ops): Update.
256 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
258 Turn process_stratum_target's supports_fork_events,
259 supports_vfork_events, and supports_exec_events ops into methods
262 * target.h (struct process_stratum_target): Remove the target ops.
263 (class process_target): Add the target ops.
264 (target_supports_fork_events): Update the macro.
265 (target_supports_vfork_events): Update the macro.
266 (target_supports_exec_events): Update the macro.
267 * target.cc (process_target::supports_fork_events): Define.
268 (process_target::supports_vfork_events): Define.
269 (process_target::supports_exec_events): Define.
271 Update the derived classes and callers below.
273 * linux-low.cc (linux_target_ops): Update.
274 (linux_supports_fork_events): Turn into ...
275 (linux_process_target::supports_fork_events): ... this.
276 (linux_supports_vfork_events): Turn into ...
277 (linux_process_target::supports_vfork_events): ... this.
278 (linux_supports_exec_events): Turn into ...
279 (linux_process_target::supports_exec_events): ... this.
280 * linux-low.h (class linux_process_target): Update.
281 * lynx-low.cc (lynx_target_ops): Update.
282 * nto-low.cc (nto_target_ops): Update.
283 * win32-low.cc (win32_target_ops): Update.
285 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
287 Turn process_stratum_target's supports_multi_process op into a
288 method of process_target.
290 * target.h (struct process_stratum_target): Remove the target op.
291 (class process_target): Add the target op.
292 * target.cc (process_target::supports_multi_process): Define.
293 (target_supports_multi_process): Update.
295 Update the derived classes and callers below.
297 * linux-low.cc (linux_target_ops): Update.
298 (linux_supports_multi_process): Turn into ...
299 (linux_process_target::supports_multi_process): ... this.
300 * linux-low.h (class linux_process_target): Update.
301 * lynx-low.cc (lynx_target_ops): Update.
302 * nto-low.cc (nto_target_ops): Update.
303 * win32-low.cc (win32_target_ops): Update.
305 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
307 Turn process_stratum_target's supports_non_stop, async, and
308 start_non_stop ops into methods of process_target.
310 * target.h (struct process_stratum_target): Remove the target ops.
311 (class process_target): Add the target ops.
312 (target_supports_non_stop): Update the macro.
313 (target_async): Update the macro.
314 (start_non_stop): Remove declaration.
315 * target.cc (process_target::supports_non_stop): Define.
316 (process_target::async): Define.
317 (process_target::start_non_stop): Define.
318 (start_non_stop): Remove.
320 Update the derived classes and callers below.
322 * server.cc (handle_qxfer_siginfo): Update.
323 (handle_query): Update.
324 * linux-low.cc (linux_target_ops): Update.
325 (linux_supports_non_stop): Turn into ...
326 (linux_process_target::supports_non_stop): ... this.
327 (linux_async): Turn into ...
328 (linux_process_target::async): ... this.
329 (linux_start_non_stop): Turn into ...
330 (linux_process_target::start_non_stop): ... this.
331 * linux-low.h (class linux_process_target): Update.
332 * lynx-low.cc (lynx_target_ops): Update.
333 * nto-low.cc (nto_target_ops): Update.
334 (nto_supports_non_stop): Remove; rely on the default behavior
336 * win32-low.cc (win32_target_ops): Update.
338 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
340 Turn process_stratum_target's qxfer_siginfo op into a method of
343 * target.h (struct process_stratum_target): Remove the target op.
344 (class process_target): Add the target op. Also add
345 'supports_qxfer_siginfo'.
346 * target.cc (process_target::qxfer_siginfo): Define.
347 (process_target::supports_qxfer_siginfo): Define.
349 Update the derived classes and callers below.
351 * server.cc (handle_qxfer_siginfo): Update.
352 (handle_query): Update.
353 * linux-low.cc (linux_target_ops): Update.
354 (linux_process_target::supports_qxfer_siginfo): Define.
355 (linux_xfer_siginfo): Turn into ...
356 (linux_process_target::qxfer_siginfo): ... this.
357 * linux-low.h (class linux_process_target): Update.
358 * lynx-low.cc (lynx_target_ops): Update.
359 * nto-low.cc (nto_target_ops): Update.
360 * win32-low.cc (win32_target_ops): Update.
362 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
364 Turn process_stratum_target's qxfer_osdata op into a method of
367 * target.h (struct process_stratum_target): Remove the target op.
368 (class process_target): Add the target op. Also add
369 'supports_qxfer_osdata'.
370 * target.cc (process_target::qxfer_osdata): Define.
371 (process_target::supports_qxfer_osdata): Define.
373 Update the derived classes and callers below.
375 * server.cc (handle_qxfer_osdata): Update.
376 (handle_query): Update.
377 * linux-low.cc (linux_target_ops): Update.
378 (linux_process_target::supports_qxfer_osdata): Define.
379 (linux_qxfer_osdata): Turn into ...
380 (linux_process_target::qxfer_osdata): ... this.
381 * linux-low.h (class linux_process_target): Update.
382 * lynx-low.cc (lynx_target_ops): Update.
383 * nto-low.cc (nto_target_ops): Update.
384 * win32-low.cc (win32_target_ops): Update.
386 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
388 Turn process_stratum_target's hostio_last_error op into a
389 method of process_target.
391 * target.h (struct process_stratum_target): Remove the target op.
392 (class process_target): Add the target op.
393 * target.cc: Add "hostio.h" to includes.
394 (process_target::hostio_last_error): Define.
396 Update the derived classes and callers below.
398 * hostio.cc (hostio_error): Update.
399 * linux-low.cc: Remove "hostio.h" from includes.
400 (linux_target_ops): Update.
401 * lynx-low.cc (lynx_target_ops): Update.
402 * nto-low.cc (nto_target_ops): Update.
403 * win32-low.h (class win32_process_target): Update.
404 * win32-low.cc (win32_target_ops): Update.
405 (wince_hostio_last_error): Turn into ...
406 (win32_process_target::hostio_last_error): ... this.
408 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
410 Turn process_stratum_target's get_tls_address op into a method of
413 * target.h (struct process_stratum_target): Remove the target op.
414 (class process_target): Add the target op. Also add
415 'supports_get_tls_address'.
416 * target.cc (process_target::get_tls_address): Define.
417 (process_target::supports_get_tls_address): Define.
419 Update the derived classes and callers below.
421 * server.cc (handle_query): Update.
422 * linux-low.cc (linux_target_ops): Update.
423 (linux_process_target::supports_get_tls_address): Define.
424 (linux_process_target::get_tls_address): Define.
425 * linux-low.h (class linux_process_target): Update.
426 * lynx-low.cc (lynx_target_ops): Update.
427 * nto-low.cc (nto_target_ops): Update.
428 * win32-low.cc (win32_target_ops): Update.
430 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
432 Turn process_stratum_target's read_offsets op into a method of
435 * target.h (struct process_stratum_target): Remove the target op.
436 (class process_target): Add the target op. Also add
437 'supports_read_offsets'.
438 * target.cc (process_target::read_offsets): Define.
439 (process_target::supports_read_offsets): Define.
441 Update the derived classes and callers below.
443 * server.cc (handle_query): Update.
444 * linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
445 (linux_target_ops): Update.
446 (linux_process_target::supports_read_offsets): Define.
447 (linux_read_offsets): Turn into ...
448 (linux_process_target::read_offsets): ... this.
449 * linux-low.h (class linux_process_target): Update.
450 * lynx-low.cc (lynx_target_ops): Update.
451 * nto-low.cc (nto_target_ops): Update.
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 stopped_by_watchpoint and
457 stopped_data_address ops into methods of process_target.
459 * target.h (struct process_stratum_target): Remove the target ops.
460 (class process_target): Add the target ops.
461 * target.cc (process_target::stopped_by_watchpoint): Define.
462 (process_target::stopped_data_address): Define.
464 Update the derived classes and callers below.
466 * remote-utils.cc (prepare_resume_reply): Update.
467 * linux-low.cc (linux_target_ops): Update.
468 (linux_stopped_by_watchpoint): Turn into ...
469 (linux_process_target::stopped_by_watchpoint): ... this.
470 (linux_stopped_data_address): Turn into ...
471 (linux_process_target::stopped_data_address): ... this.
472 * linux-low.h (class linux_process_target): Update.
473 * lynx-low.cc (lynx_target_ops): Update.
474 * nto-low.cc (nto_target_ops): Update.
475 (nto_stopped_by_watchpoint): Turn into ...
476 (nto_process_target::stopped_by_watchpoint): ... this.
477 (nto_stopped_data_address): Turn into ...
478 (nto_process_target::stopped_data_address): ... this.
479 * nto-low.h (class nto_process_target): Update.
480 * win32-low.cc (win32_target_ops): Update.
481 (win32_stopped_by_watchpoint): Turn into ...
482 (win32_process_target::stopped_by_watchpoint): ... this.
483 (win32_stopped_data_address): Turn into ...
484 (win32_process_target::stopped_data_address): ... this.
485 * win32-low.h (class win32_process_target): Update.
487 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
489 Turn process_stratum_target's supports_hardware_single_step op into
490 a method of process_target.
492 * target.h (struct process_stratum_target): Remove the target op.
493 (class process_target): Add the target op.
494 (target_supports_hardware_single_step): Update the macro.
495 (target_can_do_hardware_single_step): Remove declaration.
496 * target.cc (process_target::supports_hardware_single_step): Define.
497 (target_can_do_hardware_single_step): Remove.
499 Update the derived classes and callers below.
501 * linux-low.h (class linux_process_target): Update.
502 * linux-low.cc (linux_target_ops): Update.
503 (linux_supports_hardware_single_step): Turn into ...
504 (linux_process_target::supports_hardware_single_step): ... this.
505 * lynx-low.h (class lynx_process_target): Update.
506 * lynx-low.cc (lynx_target_ops): Update.
507 (lynx_process_target::supports_hardware_single_step): Define.
508 * nto-low.h (class nto_process_target): Update.
509 * nto-low.cc (nto_target_ops): Update.
510 (nto_process_target::supports_hardware_single_step): Define.
511 * win32-low.h (class win32_process_target): Update.
512 * win32-low.cc (win32_target_ops): Update.
513 (win32_process_target::supports_hardware_single_step): Define.
515 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
517 Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
518 ops into methods of process_target.
520 * target.h (struct process_stratum_target): Remove the target ops.
521 (class process_target): Add the target ops.
522 (target_stopped_by_hw_breakpoint): Update the macro.
523 (target_supports_stopped_by_hw_breakpoint): Update the macro.
524 * target.cc (process_target::stopped_by_hw_breakpoint): Define.
525 (process_target::supports_stopped_by_hw_breakpoint): Define.
527 Update the derived classes and callers below.
529 * linux-low.cc (linux_target_ops): Update.
530 (linux_stopped_by_hw_breakpoint): Turn into ...
531 (linux_process_target::stopped_by_hw_breakpoint): ... this.
532 (linux_supports_stopped_by_hw_breakpoint): Turn into ...
533 (linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
534 * linux-low.h (class linux_process_target): Update.
535 * lynx-low.cc (lynx_target_ops): Update.
536 * nto-low.cc (nto_target_ops): Update.
537 * win32-low.cc (win32_target_ops): Update.
539 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
541 Turn process_stratum_target's {supports_}stopped_by_sw_breakpoint
542 ops into methods of process_target.
544 * target.h (struct process_stratum_target): Remove the target ops.
545 (class process_target): Add the target ops.
546 (target_stopped_by_sw_breakpoint): Update the macro.
547 (target_supports_stopped_by_sw_breakpoint): Update the macro.
548 * target.cc (process_target::stopped_by_sw_breakpoint): Define.
549 (process_target::supports_stopped_by_sw_breakpoint): Define.
551 Update the derived classes and callers below.
553 * linux-low.cc (linux_target_ops): Update.
554 (linux_stopped_by_sw_breakpoint): Turn into ...
555 (linux_process_target::stopped_by_sw_breakpoint): ... this.
556 (linux_supports_stopped_by_sw_breakpoint): Turn into ...
557 (linux_process_target::supports_stopped_by_sw_breakpoint): ... this.
558 * linux-low.h (class linux_process_target): Update.
559 * lynx-low.cc (lynx_target_ops): Update.
560 * nto-low.cc (nto_target_ops): Update.
561 * win32-low.cc (win32_target_ops): Update.
563 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
565 Turn process_stratum_target's insert_point and remove_point ops
566 into methods of process_target.
568 * target.h (struct process_stratum_target): Remove the target ops.
569 (class process_target): Add the target ops.
570 * target.cc (process_target::insert_point): Define.
571 (process_target::remove_point): Define.
573 Update the derived classes and callers below.
575 * mem-break.cc (set_raw_breakpoint_at): Update.
576 (delete_raw_breakpoint): Update.
577 (uninsert_raw_breakpoint): Update.
578 (reinsert_raw_breakpoint): Update.
579 * linux-low.cc (linux_target_ops): Update.
580 (linux_insert_point): Turn into ...
581 (linux_process_target::insert_point): ... this.
582 (linux_remove_point): Turn into ...
583 (linux_process_target::remove_point): ... this.
584 * linux-low.h (class linux_process_target): Update.
585 * lynx-low.cc (lynx_target_ops): Update.
586 * nto-low.cc (nto_target_ops): Update.
587 (nto_insert_point): Turn into ...
588 (nto_process_target::insert_point): ... this.
589 (nto_remove_point): Turn into ...
590 (nto_process_target::remove_point): ... this.
591 * nto-low.h (class nto_process_target): Update.
592 * win32-low.cc (win32_target_ops): Update.
593 (win32_insert_point): Turn into ...
594 (win32_process_target::insert_point): ... this.
595 (win32_remove_point): Turn into ...
596 (win32_process_target::remove_point): ... this.
597 * win32-low.h (class win32_process_target): Update.
599 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
601 Turn process_stratum_target's supports_z_point_type op into a
602 method of process_target.
604 * target.h (struct process_stratum_target): Remove the target op.
605 (class process_target): Add the target op.
606 * target.cc (process_target::supports_z_point_type): Define.
608 Update the derived classes and callers below.
610 * mem-break.cc (z_type_supported): Update.
611 * linux-low.cc (linux_target_ops): Update.
612 (linux_supports_z_point_type): Turn into ...
613 (linux_process_target::supports_z_point_type): ... this.
614 * linux-low.h (class linux_process_target): Update.
615 * lynx-low.cc (lynx_target_ops): Update.
616 * nto-low.cc (nto_target_ops): Update.
617 (nto_supports_z_point_type): Turn into ...
618 (nto_process_target::supports_z_point_type): ... this.
619 * nto-low.h (class nto_process_target): Update.
620 * win32-low.cc (win32_target_ops): Update.
621 (win32_supports_z_point_type): Turn into ...
622 (win32_process_target::supports_z_point_type): ... this.
623 * win32-low.h (class win32_process_target): Update.
625 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
627 Turn process_stratum_target's read_auxv op into a method of
630 * target.h (class process_stratum_target): Remove the target op.
631 (struct process_target): Add the target op. Also add
632 'supports_read_auxv'.
633 * target.cc (process_target::read_auxv): Define.
634 (process_target::supports_read_auxv): Define.
636 Update the derived classes and callers below.
638 * server.cc (handle_qxfer_auxv): Update.
639 (handle_query): Update.
640 * linux-low.cc (linux_target_ops): Update.
641 (linux_process_target::supports_read_auxv): Define.
642 (linux_read_auxv): Turn into ...
643 (linux_process_target::read_auxv): ... this.
644 * linux-low.h (class linux_process_target): Update.
645 * lynx-low.cc (lynx_target_ops): Update.
646 * nto-low.cc (nto_target_ops): Update.
647 (nto_process_target::supports_read_auxv): Define.
648 (nto_read_auxv): Turn into ...
649 (nto_process_target::read_auxv): ... this.
650 * nto-low.h (class nto_process_target): Update.
651 * win32-low.cc (win32_target_ops): Update.
653 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
655 Turn process_stratum_target's request_interrupt op into a method of
658 * target.h (struct process_stratum_target): Remove the target op.
659 (class process_target): Add the target op.
661 Update the derived classes and callers below.
663 * remote-utils.cc (putpkt_binary_1): Update.
664 (input_interrupt): Update.
666 * server.cc (handle_v_requests): Update.
667 * linux-low.cc (linux_target_ops): Update.
668 (linux_request_interrupt): Turn into ...
669 (linux_process_target::request_interrupt): ... this.
670 * linux-low.h (class linux_process_target): Update.
671 * lynx-low.cc (lynx_target_ops): Update.
672 (lynx_request_interrupt): Turn into ...
673 (lynx_process_target::request_interrupt): ... this.
674 * lynx-low.h (class lynx_process_target): Update.
675 * nto-low.cc (nto_target_ops): Update.
676 (nto_request_interrupt): Turn into ...
677 (nto_process_target::request_interrupt): ... this.
678 * nto-low.h (class nto_process_target): Update.
679 * win32-low.cc (win32_target_ops): Update.
680 (win32_request_interrupt): Turn into ...
681 (win32_process_target::request_interrupt): ... this.
682 * win32-low.h (class win32_process_target): Update.
684 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
686 Turn process_stratum_target's look_up_symbols op into a method of
689 * target.h (struct process_stratum_target): Remove the target op.
690 (class process_target): Add the target op.
691 * target.cc (process_target::look_up_symbols): Define.
693 Update the derived classes and callers below.
695 * server.cc (handle_query): Update.
696 * linux-low.cc (linux_target_ops): Update.
697 (linux_look_up_symbols): Turn into ...
698 (linux_process_target::look_up_symbols): ... this.
699 * linux-low.h (class linux_process_target): Update.
700 * lynx-low.cc (lynx_target_ops): Update.
701 * nto-low.cc (nto_target_ops): Update.
702 * win32-low.cc (win32_target_ops): Update.
704 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
706 Turn process_stratum_target's read_memory and write_memory
707 ops into methods of process_target.
709 * target.h (struct process_stratum_target): Remove the target ops.
710 (class process_target): Add the target ops.
712 Update the derived classes and callers below.
714 * linux-aarch32-low.cc (arm_breakpoint_at): Update.
715 * linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
716 * linux-arm-low.cc (arm_sigreturn_next_pc): Update.
717 (arm_get_syscall_trapinfo): Update.
718 * linux-cris-low.cc (cris_breakpoint_at): Update.
719 * linux-crisv32-low.cc (cris_breakpoint_at): Update.
720 * linux-m32r-low.cc (m32r_breakpoint_at): Update.
721 * linux-mips-low.cc (mips_breakpoint_at): Update.
722 * linux-nios2-low.cc (nios2_breakpoint_at): Update.
723 * linux-ppc-low.cc (ppc_breakpoint_at): Update.
724 * linux-sh-low.cc (sh_breakpoint_at): Update.
725 * linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
726 (sparc_store_gregset_from_stack): Update.
727 (sparc_breakpoint_at): Update.
728 * linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
729 * linux-tile-low.cc (tile_breakpoint_at): Update.
730 * linux-x86-low.cc (x86_breakpoint_at): Update.
731 * linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
732 * mem-brea.cc (insert_memory_breakpoint): Update.
733 (validate_inserted_breakpoint): Update.
734 * target.cc (read_inferior_memory): Update.
735 (target_write_memory): Update.
736 * linux-low.cc (linux_target_ops): Update.
737 (linux_read_memory): Make a wrapper around the read_memory target
739 (linux_process_target::read_memory): Rename from linux_read_memory.
740 (linux_write_memory): Turn into ...
741 (linux_process_target::write_memory): ... this.
742 * linux-low.h (class linux_process_target): Update.
743 * lynx-low.cc (lynx_target_ops): Update.
744 (lynx_read_memory): Turn into ...
745 (lynx_process_target::read_memory): ... this.
746 (lynx_write_memory): Turn into ...
747 (lynx_process_target::write_memory): ... this.
748 * lynx-low.h (class lynx_process_target): Update.
749 * nto-low.cc (nto_target_ops): Update.
750 (nto_read_memory): Turn into ...
751 (nto_process_target::read_memory): ... this.
752 (nto_write_memory): Turn into ...
753 (nto_process_target::write_memory): ... this.
754 * nto-low.h (class nto_process_target): Update.
755 * win32-low.cc (win32_target_ops): Update.
756 (win32_read_inferior_memory): Turn into ...
757 (win32_process_target::read_memory): ... this.
758 (win32_write_inferior_memory): Turn into ...
759 (win32_process_target::write_memory): ... this.
760 * win32-low.h (class win32_process_target): Update.
762 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
764 Turn process_stratum_target's prepare_to_access_memory and
765 done_accessing_memory ops into methods of process_target.
767 * target.h (struct process_stratum_target): Remove the target ops.
768 (class process_target): Add the target ops.
769 * target.cc (process_target::prepare_to_access_memory): Define.
770 (process_target::done_accessing_memory): Define.
771 (prepare_to_access_memory): Update.
772 (done_accessing_memory): Update.
774 Update the derived classes and callers below.
776 * linux-low.cc (linux_target_ops): Update.
777 (linux_prepare_to_access_memory): Turn into ...
778 (linux_process_target::prepare_to_access_memory): ... this.
779 (linux_done_accessing_memory): Turn into ...
780 (linux_process_target::done_accessing_memory): ... this.
781 * linux-low.h (class linux_process_target): Update.
782 * lynx-low.cc (lynx_target_ops): Update.
783 * nto-low.cc (nto_target_ops): Update.
784 * win32-low.cc (win32_target_ops): Update.
786 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
788 Turn process_stratum_target's fetch_registers and store_registers
789 ops into methods of process_target.
791 * target.h (struct process_stratum_target): Remove the target ops.
792 (class process_target): Add the target ops.
793 (fetch_inferior_registers): Update the macro.
794 (store_inferior_registers): Update the macro.
796 Update the derived classes and callers below.
798 * linux-low.cc (linux_target_ops): Update.
799 (linux_fetch_registers): Turn into ...
800 (linux_process_target::fetch_registers): ... this.
801 (linux_store_registers): Turn into ...
802 (linux_process_target::store_registers): ... this.
803 * linux-low.h (class linux_process_target): Update.
804 * lynx-low.cc (lynx_target_ops): Update.
805 (lynx_fetch_registers): Turn into ...
806 (lynx_process_target::fetch_registers): ... this.
807 (lynx_store_registers): Turn into ...
808 (lynx_process_target::store_registers): ... this.
809 * lynx-low.h (class lynx_process_target): Update.
810 * nto-low.cc (nto_target_ops): Update.
811 (nto_fetch_registers): Turn into ...
812 (nto_process_target::fetch_registers): ... this.
813 (nto_store_registers): Turn into ...
814 (nto_process_target::store_registers): ... this.
815 * nto-low.h (class nto_process_target): Update.
816 * win32-low.cc (win32_target_ops): Update.
817 (win32_fetch_inferior_registers): Turn into ...
818 (win32_process_target::fetch_registers): ... this.
819 (win32_store_inferior_registers): Turn into ...
820 (win32_process_target::store_registers): ... this.
821 * win32-low.h (class win32_process_target): Update.
823 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
825 Turn process_stratum_target's wait op into a method of
828 * target.h (struct process_stratum_target): Remove the target op.
829 (class process_target): Add the target op.
831 Update the derived classes and callers below.
833 * target.cc (target_wait): Update.
834 * linux-low.cc (linux_target_ops): Update.
835 (linux_wait): Turn into ...
836 (linux_process_target::wait): ... this.
837 * linux-low.h (class linux_process_target): Update.
838 * lynx-low.cc (lynx_target_ops): Update.
839 (lynx_wait): Turn into ...
840 (lynx_process_target::wait): ... this.
841 * lynx-low.h (class lynx_process_target): Update.
842 * nto-low.cc (nto_target_ops): Update.
843 (nto_wait): Turn into ...
844 (nto_process_target::wait): ... this.
845 * nto-low.h (class nto_process_target): Update.
846 * win32-low.cc (win32_target_ops): Update.
847 (win32_wait): Turn into ...
848 (win32_process_target::wait): ... this.
849 (do_initial_child_stuff): Update.
850 * win32-low.h (class win32_process_target): Update.
852 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
854 Turn process_stratum_target's resume op into a method of
857 * target.h (struct process_stratum_target): Remove the target op.
858 (class process_target): Add the target op.
860 Update the derived classes and callers below.
862 * server.cc (resume): Update.
863 * target.cc (target_stop_and_wait): Update.
864 (target_continue_no_signal): Update.
865 (target_continue): Update.
866 * linux-low.cc (linux_target_ops): Update.
867 (linux_resume): Turn into ...
868 (linux_process_target::resume): ... this.
869 * linux-low.h (class linux_process_target): Update.
870 * lynx-low.cc (lynx_target_ops): Update.
871 (lynx_resume): Turn into ...
872 (lynx_process_target::resume): ... this.
873 * lynx-low.h (class lynx_process_target): Update.
874 * nto-low.cc (nto_target_ops): Update.
875 (nto_resume): Turn into ...
876 (nto_process_target::resume): ... this.
877 * nto-low.h (class nto_process_target): Update.
878 * win32-low.cc (win32_target_ops): Update.
879 (win32_resume): Turn into ...
880 (win32_process_target::resume): ... this.
881 (win32_process_target::detach): Update.
882 (do_initial_child_stuff): Update.
883 * win32-low.h (class win32_process_target): Update.
885 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
887 Turn process_stratum_target's thread_alive op into a method of
890 * target.h (struct process_stratum_target): Remove the target op.
891 (class process_target): Add the target op.
892 (mythread_alive): Update the macro.
894 Update the derived classes and callers below.
896 * linux-low.cc (linux_target_ops): Update.
897 (linux_thread_alive): Turn into ...
898 (linux_process_target::thread_alive): ... this.
899 (wait_for_sigstop): Update.
900 * linux-low.h (class linux_process_target): Update.
901 * lynx-low.cc (lynx_target_ops): Update.
902 (lynx_thread_alive): Turn into ...
903 (lynx_process_target::thread_alive): ... this.
904 * lynx-low.h (class lynx_process_target): Update.
905 * nto-low.cc (nto_target_ops): Update.
906 (nto_thread_alive): Turn into ...
907 (nto_process_target::thread_alive): ... this.
908 * nto-low.h (class nto_process_target): Update.
909 * win32-low.cc (win32_target_ops): Update.
910 (win32_thread_alive): Turn into ...
911 (win32_process_target::thread_alive): ... this.
912 * win32-low.h (class win32_process_target): Update.
914 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
916 Turn process_stratum_target's join op into a method of
919 * target.h (struct process_stratum_target): Remove the target op.
920 (class process_target): Add the target op.
921 (join_inferior): Update the macro.
923 Update the derived classes and callers below.
925 * linux-low.cc (linux_target_ops): Update.
926 (linux_join): Turn into ...
927 (linux_process_target::join): ... this.
928 * linux-low.h (class linux_process_target): Update.
929 * lynx-low.cc (lynx_target_ops): Update.
930 (lynx_join): Turn into ...
931 (lynx_process_target::join): ... this.
932 * lynx-low.h (class lynx_process_target): Update.
933 * nto-low.cc (nto_target_ops): Update.
934 (nto_process_target::join): Define.
935 * nto-low.h (class nto_process_target): Update.
936 * win32-low.cc (win32_target_ops): Update.
937 (win32_join): Turn into ...
938 (win32_process_target::join): ... this.
939 * win32-low.h (class win32_process_target): Update.
941 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
943 Turn process_stratum_target's mourn op into a method of
946 * target.h (struct process_stratum_target): Remove the target op.
947 (class process_target): Add the target op.
949 Update the derived classes and callers below.
951 * target.cc (target_mourn_inferior): Update.
952 * linux-low.cc (linux_target_ops): Update.
953 (linux_mourn): Turn into ...
954 (linux_process_target::mourn): ... this.
955 (handle_extended_wait): Update.
956 (linux_process_target::kill): Update.
957 (linux_process_target::detach): Update.
958 * linux-low.h (class linux_process_target): Update.
959 * lynx-low.cc (lynx_target_ops): Update.
960 (lynx_mourn): Turn into ...
961 (lynx_process_target::mourn): ... this.
962 * lynx-low.h (class lynx_process_target): Update.
963 * nto-low.cc (nto_target_ops): Update.
964 (nto_mourn): Turn into ...
965 (nto_process_target::mourn): ... this.
966 * nto-low.h (class nto_process_target): Update.
967 * win32-low.cc (win32_target_ops): Update.
968 (win32_mourn): Turn into ...
969 (win32_process_target::mourn): ... this.
970 * win32-low.h (class win32_process_target): Update.
972 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
974 Turn process_stratum_target's detach op into a method of
977 * target.h (struct process_stratum_target): Remove the target op.
978 (class process_target): Add the target op.
979 (detach_inferior): Update the macro.
981 Update the derived classes and callers below.
983 * linux-low.cc (linux_target_ops): Update.
984 (linux_detach): Turn into ...
985 (linux_process_target::detach): ... this.
986 * linux-low.h (class linux_process_target): Update.
987 * lynx-low.cc (lynx_target_ops): Update.
988 (lynx_detach): Turn into ...
989 (lynx_process_target::detach): ... this.
990 * lynx-low.h (class lynx_process_target): Update.
991 * nto-low.cc (nto_target_ops): Update.
992 (nto_detach): Turn into ...
993 (nto_process_target::detach): ... this.
994 * nto-low.h (class nto_process_target): Update.
995 * win32-low.cc (win32_target_ops): Update.
996 (win32_detach): Turn into ...
997 (win32_process_target::detach): ... this.
998 * win32-low.h (class win32_process_target): Update.
1000 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1002 Turn process_stratum_target's kill op into a method of
1005 * target.h (struct process_stratum_target): Remove the target op.
1006 (class process_target): Add the target op.
1008 Update the derived classes and callers below.
1010 * target.cc (kill_inferior): Update.
1011 * linux-low.cc (linux_target_ops): Update.
1012 (linux_kill): Turn into ...
1013 (linux_process_target::kill): ... this.
1014 * linux-low.h (class linux_process_target): Update.
1015 * lynx-low.cc (lynx_target_ops): Update.
1016 (lynx_kill): Turn into ...
1017 (lynx_process_target::kill): ... this.
1018 * lynx-low.h (class lynx_process_target): Update.
1019 * nto-low.cc (nto_target_ops): Update.
1020 (nto_kill): Turn into ...
1021 (nto_process_target::kill): ... this.
1022 * nto-low.h (class nto_process_target): Update.
1023 * win32-low.cc (win32_target_ops): Update.
1024 (win32_kill): Turn into ...
1025 (win32_process_target::kill): ... this.
1026 * win32-low.h (class win32_process_target): Update.
1028 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1030 Turn process_stratum_target's attach op into a method of
1033 * target.h (struct process_stratum_target): Remove the target op.
1034 (class process_target): Add the target op.
1035 (myattach): Update the macro.
1037 Update the derived classes and callers below.
1039 * linux-low.cc (linux_target_ops): Update.
1040 (linux_attach): Turn into ...
1041 (linux_process_target::attach): ... this.
1042 * linux-low.h (class linux_process_target): Update.
1043 * lynx-low.cc (lynx_target_ops): Update.
1044 (lynx_attach): Turn into ...
1045 (lynx_process_target::attach): ... this.
1046 * lynx-low.h (class lynx_process_target): Update.
1047 * nto-low.cc (nto_target_ops): Update.
1048 (nto_attach): Turn into ...
1049 (nto_process_target::attach): ... this.
1050 * nto-low.h (class nto_process_target): Update.
1051 * win32-low.cc (win32_target_ops): Update.
1052 (win32_attach): Turn into ...
1053 (win32_process_target::attach): ... this.
1054 * win32-low.h (class win32_process_target): Update.
1056 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1058 Turn process_stratum_target's post_create_inferior op into a method
1061 * target.h (struct process_stratum_target): Remove the target op.
1062 (class process_target): Add the target op.
1063 (target_post_create_inferior): Update the macro.
1064 * target.cc (process_target::post_create_inferior): Define.
1066 Update the derived classes and callers below.
1068 * linux-low.cc (linux_target_ops): Update.
1069 (linux_post_create_inferior): Turn into ...
1070 (linux_process_target::post_create_inferior): ... this.
1071 * linux-low.h (class linux_process_target): Update.
1072 * lynx-low.cc (lynx_target_ops): Update.
1073 * nto-low.cc (nto_target_ops): Update.
1074 * win32-low.cc (win32_target_ops): Update.
1076 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1078 Turn process_stratum_target's create_inferior op into a method of
1081 * target.h (struct process_stratum_target): Remove the target op.
1082 (class process_target): Add the target op.
1083 (create_inferior): Rename the macro to ...
1084 (target_create_inferior): ... this.
1086 Update the derived classes and callers below.
1088 * server.cc (handle_v_run): Update.
1089 (captured_main): Update.
1090 (process_serial_event): Update.
1091 * linux-low.cc (linux_target_ops): Update.
1092 (linux_create_inferior): Turn into ...
1093 (linux_process_target::create_inferior): ... this.
1094 * linux-low.h (class linux_process_target): Update.
1095 * lynx-low.cc (lynx_target_ops): Update.
1096 (lynx_create_inferior): Turn into ...
1097 (lynx_process_target::create_inferior): ... this.
1098 * lynx-low.h (class lynx_process_target): Update.
1099 * nto-low.cc (nto_target_ops): Update.
1100 (nto_create_inferior): Turn into ...
1101 (nto_process_target::create_inferior): ... this.
1102 * nto-low.h (class nto_process_target): Update.
1103 * win32-low.cc (win32_target_ops): Update.
1104 (win32_create_inferior): Turn into ...
1105 (win32_process_target::create_inferior): ... this.
1106 * win32-low.h (class win32_process_target): Update.
1108 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1110 * target.h (class process_target): New class definition.
1111 (struct process_stratum_target) <pt>: New field with type
1113 * linux-low.h (class linux_process_target): Define as a derived
1114 class of 'process_target'.
1115 * linux-low.cc (linux_target_ops): Add a linux_process_target*
1117 * lynx-low.h (class lynx_process_target): Define as a derived
1118 class of 'process_target'.
1119 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
1121 * nto-low.h (class nto_process_target): Define as a derived
1122 class of 'process_target'.
1123 * nto-low.cc (nto_target_ops): Add an nto_process_target*
1125 * win32-low.h (class win32_process_target): Define as a derived
1126 class of 'process_target'.
1127 * win32-low.cc (win32_target_ops): Add a win32_process_target*
1130 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
1132 * configure: Regenerate.
1134 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
1135 Andrew Burgess <andrew.burgess@embecosm.com>
1137 * linux-riscv-low.cc: New file.
1138 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
1139 and nat/riscv-linux-tdesc.c.
1140 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
1141 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
1144 2020-02-14 Tom Tromey <tom@tromey.com>
1146 * acinclude.m4: Don't include acx_configure_dir.m4.
1147 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
1148 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
1149 (all, install-only, uninstall, clean-info, clean)
1150 (maintainer-clean): Don't recurse.
1151 (subdir_do, all-lib): Remove.
1152 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
1154 (generated_files): Update.
1155 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
1156 * configure: Rebuild.
1157 * configure.ac: Don't configure gnulib or libiberty.
1160 2020-02-14 Eli Zaretskii <eliz@gnu.org>
1162 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
1163 preparing the command line for CreateProcess.
1164 (win32_create_inferior): Reflect the program name in debugging
1165 output that shows the process and its command line.
1167 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
1169 * Makefile.in: Rename source files from .c to .cc.
1170 * %.c: Rename to %.cc.
1171 * configure.ac: Rename server.c to server.cc.
1172 * configure: Re-generate.
1174 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
1176 * Makefile.in: Rename gdbsupport source files from .c to .cc.
1178 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
1180 * win32-low.c (win32_create_inferior): Set signal_pid.
1182 2020-02-12 Maciej W. Rozycki <macro@wdc.com>
1183 Pedro Alves <palves@redhat.com>
1185 Skip building gdbserver in a cross-configuration.
1186 * configure.srv: Set $gdbserver_host depending on whether $target
1187 is $host. Use $gdbserver_host instead of $host.
1189 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
1191 * configure: Re-generate.
1193 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
1195 * configure: Re-generate.
1197 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
1199 * acinclude.m4: Update warning.m4 path.
1201 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
1203 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
1204 (handle_exception): Set siginfo_er.
1205 (win32_xfer_siginfo): New function.
1207 2020-02-07 Tom Tromey <tom@tromey.com>
1208 Pedro Alves <palves@redhat.com>
1210 * README: Update build documentation.
1211 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
1213 * configure.ac: Update paths.
1214 * configure: Rebuild.
1215 * acinclude.m4: Update paths.
1216 * Makefile.in: Update include paths.
1217 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
1218 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
1219 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
1220 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
1221 (%-generated.c): Update paths.
1222 * Move entire directory from ../gdb/gdbserver.
1224 2020-01-29 Maciej W. Rozycki <macro@wdc.com>
1226 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
1228 2020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1230 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
1231 assignment instead of srv_linux_obj.
1233 2020-01-28 Hannes Domani <ssbssa@yahoo.de>
1235 * server.c (handle_qxfer_libraries): Write segment-address with
1238 2020-01-24 Hannes Domani <ssbssa@yahoo.de>
1240 * Makefile.in (install-strip): New target.
1241 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
1242 * aclocal.m4: Regenerate.
1243 * configure: Regenerate.
1244 * configure.ac: Add AM_PROG_INSTALL_STRIP.
1246 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
1248 * Makefile.in (SFILES): Adjust paths to point to real files.
1249 (OBS): Move waitstatus.o to target/waitstatus.o.
1250 (TAGS): Transform paths appropriately.
1252 (nat/%.o): ... this pattern rule.
1254 (target/%.o): ... this pattern rule.
1255 * configure.srv: Adjust paths throughout to include nat/ prefix
1256 with the revant files.
1257 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
1258 * configure: Regenerate.
1260 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
1262 * Makefile.in (TAGS): Remove config files from the recipe.
1264 2020-01-14 Tom Tromey <tom@tromey.com>
1266 * configure: Rebuild.
1267 * configure.ac: Remove any checks that were added to common.m4.
1268 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
1271 2020-01-14 Tom Tromey <tom@tromey.com>
1273 * server.h: Include config.h.
1274 * gdbreplay.c: Include config.h.
1275 * configure: Rebuild.
1276 * configure.ac: Don't source common.host.
1277 * acinclude.m4: Update path.
1278 * Makefile.in (INCSUPPORT): New variable.
1279 (INCLUDE_CFLAGS): Add INCSUPPORT.
1280 (SFILES): Update paths.
1281 (version-generated.c): Update path to create-version.sh.
1282 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
1284 2020-01-14 Tom Tromey <tom@tromey.com>
1286 * configure.ac (LIBS): Use WIN32APILIBS.
1287 (USE_WIN32API): Don't define.
1288 * configure: Rebuild.
1290 2020-01-14 Tom Tromey <tom@tromey.com>
1292 * configure: Rebuild.
1294 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1296 * Makefile.in (%-generated.c): Remove rule for files from
1299 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1301 * configure: Re-generate.
1303 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1305 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
1307 * tracepoint.c (stop_tracing, flush_trace_buffer,
1308 about_to_request_buffer_space, get_trace_state_variable_value,
1309 set_trace_state_variable_value, gdb_collect): Add declaration.
1311 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1313 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
1314 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
1315 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
1316 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
1317 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
1320 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1322 * inferiors.c: Include gdbsupport/common-inferior.h.
1324 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1326 * hostio-errno.c: Include hostio.h.
1328 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1330 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
1333 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
1335 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
1336 * linux-arm-tdesc.h: Include arch/arm.h.
1338 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
1340 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
1342 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
1344 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
1345 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
1347 2020-01-10 Pedro Alves <palves@redhat.com>
1349 * fork-child.c (post_fork_inferior): Pass target down to
1351 * inferiors.c (switch_to_thread): Add process_stratum_target
1353 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
1354 * nto-low.c (nto_target_ops): Now a process_stratum_target.
1355 * linux-low.c (linux_target_ops): Now a process_stratum_target.
1356 * remote-utils.c (prepare_resume_reply): Pass the target to
1358 * target.c (the_target): Now a process_stratum_target.
1359 (done_accessing_memory): Pass the target to switch_to_thread.
1360 (set_target_ops): Ajust to use process_stratum_target.
1361 * target.h (struct target_ops): Rename to ...
1362 (struct process_stratum_target): ... this.
1363 (the_target, set_target_ops): Adjust.
1364 (prepare_to_access_memory): Adjust comment.
1365 * win32-low.c (child_xfer_memory): Adjust to use
1366 process_stratum_target.
1367 (win32_target_ops): Now a process_stratum_target.
1369 2020-01-06 Eli Zaretskii <eliz@gnu.org>
1370 Pedro Alves <palves@redhat.com>
1372 * win32-low.c (get_child_debug_event): Extract the fatal exception
1373 from the exit status and convert to the equivalent Posix signal
1375 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
1376 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
1378 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
1380 * Makefile.in: Use INSTALL_PROGRAM_ENV.
1382 2020-01-01 Joel Brobecker <brobecker@adacore.com>
1384 * server.c (gdbserver_version): Change copyright year to 2020.
1385 * gdbreplay.c (gdbreplay_version): Likewise.
1387 2019-12-19 Christian Biesinger <cbiesinger@google.com>
1389 * configure: Regenerate.
1390 * configure.ac: Quote variable arguments of test.
1392 2019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
1394 * Makefile.in: Fix build with GNU Make 3.81
1396 2019-12-16 Tom Tromey <tromey@adacore.com>
1398 * server.c (get_exec_file): Constify result.
1400 2019-12-10 Christian Biesinger <cbiesinger@google.com>
1402 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
1403 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
1404 * config.in: Regenerate.
1405 * configure: Regenerate.
1406 * configure.ac: Don't check for strerror.
1407 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
1408 Call safe_strerror instead of strerror.
1409 * server.h (strerror): Remove this now-unnecessary declaration.
1410 * tracepoint.c (init_named_socket): Call safe_strerror instead of
1412 (gdb_agent_helper_thread): Likewise.
1413 * utils.c (perror_with_name): Likewise.
1415 2019-11-26 Tom Tromey <tom@tromey.com>
1417 * configure, config.in: Rebuild.
1419 2019-11-26 Tom Tromey <tom@tromey.com>
1421 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
1422 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
1424 * configure, config.in: Rebuild.
1426 2019-11-26 Tom Tromey <tom@tromey.com>
1428 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
1429 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
1430 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
1431 * acinclude.m4: Include ax_pthread.m4.
1432 * config.in, configure: Rebuild.
1434 2019-11-26 Christian Biesinger <cbiesinger@google.com>
1436 * debug.c (debug_set_output): Call safe_strerror instead of
1438 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
1439 (linux_kill_one_lwp): Likewise.
1440 (linux_detach_one_lwp): Likewise.
1441 (linux_wait_for_event_filtered): Likewise.
1442 (store_register): Likewise.
1443 * lynx-low.c (lynx_attach): Likewise.
1444 * mem-break.c (insert_memory_breakpoint): Likewise.
1445 (remove_memory_breakpoint): Likewise.
1446 (delete_fast_tracepoint_jump): Likewise.
1447 (set_fast_tracepoint_jump): Likewise.
1448 (uninsert_fast_tracepoint_jumps_at): Likewise.
1449 (reinsert_fast_tracepoint_jumps_at): Likewise.
1450 * nto-low.c (nto_xfer_memory): Likewise.
1451 (nto_resume): Likewise.
1453 2019-11-20 Luis Machado <luis.machado@linaro.org>
1455 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
1456 instead of register count.
1457 * tdesc.c (tdesc_contains_feature): New function.
1458 * tdesc.h (tdesc_contains_feature): New prototype.
1460 2019-11-15 Christian Biesinger <cbiesinger@google.com>
1462 * Makefile.in: Add safe-strerror.c.
1463 * configure: Regenerate.
1464 * configure.ac: Don't source common.host.
1466 2019-11-15 Christian Biesinger <cbiesinger@google.com>
1468 * config.in: Regenerate.
1469 * configure: Regenerate.
1471 2019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
1473 * ax.c (ax_printf): Handle size_t_arg.
1475 2019-11-06 Christian Biesinger <cbiesinger@google.com>
1477 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
1478 * mi/mi-main.c (output_cores): Likewise.
1479 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
1480 (linux_xfer_osdata_modules): Likewise.
1481 * remote.c (register_remote_support_xml): Likewise.
1482 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
1483 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
1485 2019-11-01 Christian Biesinger <cbiesinger@google.com>
1487 * configure: Regenerate.
1488 * configure.ac: Remove check for strerror_r.
1490 2019-10-31 Christian Biesinger <cbiesinger@google.com>
1492 * config.in: Regenerate.
1493 * configure: Regenerate.
1494 * configure.ac: Also check for strerror_r.
1496 2019-10-31 Christian Biesinger <cbiesinger@google.com>
1498 * ax.h (debug_agent): Remove duplicate declaration.
1500 2019-10-26 Tom de Vries <tdevries@suse.de>
1502 * linux-aarch64-low.c: Fix typos in comments.
1503 * linux-arm-low.c: Same.
1504 * linux-low.c: Same.
1505 * linux-ppc-low.c: Same.
1506 * proc-service.c: Same.
1509 * tracepoint.c: Same.
1510 * win32-low.c: Same.
1512 2019-10-25 Tom Tromey <tromey@adacore.com>
1514 * utils.c (xstrdup): Remove.
1516 2019-10-23 Tom Tromey <tom@tromey.com>
1518 * configure, config.in: Rebuild.
1520 2019-10-23 Tom Tromey <tom@tromey.com>
1522 * configure: Rebuild.
1523 * acinclude.m4: Use m4_include, not sinclude.
1525 2019-10-17 Tom Tromey <tromey@adacore.com>
1527 * configure: Rebuild.
1528 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
1529 in AC_CONFIG_FILES invocation.
1530 * Makefile.in (stamp-h, Makefile): Use new-style config.status
1533 2019-10-16 Christian Biesinger <cbiesinger@google.com>
1535 * server.c: Include xml-builtin.h.
1536 (get_xml_features): Don't declare xml_builtins here.
1538 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
1540 * Makefile.in: Remove references to vec-ipa.o.
1542 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
1544 * Makefile.in: Remove references to vec.c.
1546 2019-10-02 Christian Biesinger <cbiesinger@google.com>
1548 * server.c (server_waiting): Change to bool.
1549 (extended_protocol): Likewise.
1550 (response_needed): Likewise.
1551 (exit_requested): Likewise.
1552 (run_once): Likewise.
1553 (report_no_resumed): Likewise.
1554 (non_stop): Likewise.
1555 (disable_packet_vCont): Likewise.
1556 (disable_packet_Tthread): Likewise.
1557 (disable_packet_qC): Likewise.
1558 (disable_packet_qfThreadInfo): Likewise.
1559 (handle_general_set): Update.
1560 (handle_detach): Update.
1561 (handle_monitor_command): Update.
1562 (handle_query): Update.
1563 (captured_main): Update.
1564 (process_serial_event): Update.
1565 * server.h (server_waiting): Change to bool.
1566 (disable_packet_vCont): Likewise.
1567 (disable_packet_Tthread): Likewise.
1568 (disable_packet_qC): Likewise.
1569 (disable_packet_qfThreadInfo): Likewise.
1570 (run_once): Likewise.
1571 (non_stop): Likewise.
1572 * target.c (target_stop_and_wait): Update.
1574 2019-10-02 Tom Tromey <tromey@adacore.com>
1576 * Makefile.in (SFILES): Add common-inferior.c.
1577 (OBS): Add common-inferior.o.
1578 * server.c (startup_with_shell): Don't define.
1580 2019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
1582 * linux-low.c (linux_low_read_btrace): Update for change to
1585 2019-09-20 Christian Biesinger <cbiesinger@google.com>
1587 * debug.c (debug_threads): Remove comment in favor of the header.
1588 * debug.h (using_threads): Add declaration.
1589 (debug_threads): Add comment.
1590 * linux-aarch64-low.c: Include debug.h and remove declaration of
1592 * nto-low.c: Likewise.
1593 * remote-utils.c: Likewise.
1594 * thread-db.c: Likewise.
1596 2019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
1598 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
1599 and powerpc-cell64l-ipa.o.
1600 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
1601 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
1602 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
1605 * spu-low.c: Remove file.
1607 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
1608 (parse_spufs_run): Remove.
1609 (ppc_get_pc): Remove Cell/B.E. support.
1610 (ppc_set_pc): Likewise.
1611 (ppc_breakpoint_at): Likewise.
1612 (ppc_arch_setup): Likewise.
1613 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
1614 tdesc_powerpc_cell32l.
1615 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
1616 or init_registers_powerpc_cell32l.
1617 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
1618 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
1619 or init_registers_powerpc_cell32l.
1620 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
1621 (init_registers_powerpc_cell32l): Remove prototype.
1622 (init_registers_powerpc_cell64l): Likewise.
1624 * target.h (struct target_ops): Remove qxfer_spu member.
1625 * server.c (handle_qxfer_spu): Remove.
1626 (qxfer_packets): Remove entry for "spu".
1627 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
1628 * linux-low.c (SPUFS_MAGIC): Remove.
1629 (spu_enumerate_spu_ids): Remove.
1630 (linux_qxfer_spu): Remove.
1631 (linux_target_ops): Remove qxfer_spu member.
1632 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
1633 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
1634 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
1636 2019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
1638 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
1639 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
1640 * config.in: Regenerate.
1641 * configure: Regenerate.
1643 2019-08-15 Tom Tromey <tromey@adacore.com>
1645 * target.c (target_write_memory): Use gdb::byte_vector.
1647 2019-08-15 Tom Tromey <tromey@adacore.com>
1649 * tracepoint.c (write_inferior_data_pointer)
1650 (write_inferior_integer, write_inferior_int8)
1651 (write_inferior_uinteger, m_tracepoint_action_download)
1652 (r_tracepoint_action_download, x_tracepoint_action_download)
1653 (l_tracepoint_action_download, clear_inferior_trace_buffer)
1654 (download_agent_expr, download_tracepoint_1)
1655 (download_trace_state_variables, upload_fast_traceframes): Update.
1656 * server.c (gdb_write_memory): Update.
1657 * remote-utils.c (relocate_instruction): Update.
1658 * proc-service.c (ps_pdwrite): Update.
1659 * mem-break.c (remove_memory_breakpoint)
1660 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
1661 (uninsert_fast_tracepoint_jumps_at)
1662 (reinsert_fast_tracepoint_jumps_at): Update.
1663 * linux-x86-low.c (append_insns)
1664 (i386_install_fast_tracepoint_jump_pad)
1665 (amd64_write_goto_address, i386_write_goto_address): Update.
1666 * linux-s390-low.c (append_insns, s390_write_goto_address):
1668 * linux-ppc-low.c (ppc_relocate_instruction)
1669 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
1670 (ppc_write_goto_address): Update.
1671 * linux-aarch64-low.c (append_insns): Update.
1672 * target.h (struct target_ops): Update.
1673 (write_inferior_memory): Don't declare.
1674 * target.c (target_write_memory): Rename from
1675 write_inferior_memory. Remove old target_write_memory.
1677 2019-08-15 Tom Tromey <tromey@adacore.com>
1679 * target.c (write_inferior_memory): Use std::vector.
1681 2019-08-06 Frank Ch. Eigler <fche@redhat.com>
1684 * configure.ac: Drop enable-libmcheck support.
1685 * configure, config.in: Rebuild.
1686 * acinclude.m4: Don't include it.
1688 2019-07-19 Alan Hayward <alan.hayward@arm.com>
1690 * configure.srv: Remove Arm xml files.
1692 2019-07-19 Alan Hayward <alan.hayward@arm.com>
1694 * configure.srv: Add new files. Remove xml generated files.
1695 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
1697 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
1698 * linux-aarch32-tdesc.c: New file.
1699 * linux-aarch32-tdesc.h: New file.
1700 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
1701 * linux-arm-low.c (init_registers_arm, tdesc_arm)
1702 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
1703 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
1704 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
1705 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
1706 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
1707 (arm_read_description): Call arm_linux_read_description.
1708 (initialize_low_arch): Don't init registers.
1709 * linux-arm-tdesc.c: New file.
1710 * linux-arm-tdesc.h: New file.
1712 2019-07-10 Alan Hayward <alan.hayward@arm.com>
1714 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
1715 Move counter inside for.
1716 (arm_read_description): Check ptrace earlier.
1717 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
1719 2019-07-09 Tom Tromey <tom@tromey.com>
1721 * configure: Rebuild.
1722 * configure.ac: Change common to gdbsupport.
1723 * acinclude.m4: Change common to gdbsupport.
1724 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
1725 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
1726 common to gdbsupport.
1727 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
1728 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
1729 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
1730 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
1731 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
1732 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
1733 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
1734 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
1735 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
1736 common to gdbsupport.
1738 2019-07-04 Alan Hayward <alan.hayward@arm.com>
1740 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
1742 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
1744 2019-07-04 Alan Hayward <alan.hayward@arm.com>
1746 * configure.srv: Remove legacy xml.
1747 * linux-aarch64-low.c (initialize_low_arch): Remove
1748 initialize_low_tdesc call.
1749 * linux-aarch64-tdesc-selftest.c: Remove file.
1750 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
1751 * linux-x86-low.c (initialize_low_arch): Remove
1752 initialize_low_tdesc call.
1753 * linux-x86-tdesc-selftest.c: Remove file.
1754 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
1756 2019-06-20 Tom de Vries <tdevries@suse.de>
1758 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
1759 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
1761 2019-06-19 Tom de Vries <tdevries@suse.de>
1763 * debug.h (debug_write): Change return type to ssize_t.
1764 * debug.c (debug_write): Same.
1766 2019-06-14 Tom Tromey <tom@tromey.com>
1768 * configure.ac: Use new path to gnulib.
1769 * configure: Rebuild.
1770 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
1773 2019-06-11 Tom Tromey <tom@tromey.com>
1775 * Makefile.in (SFILES): Add alloc.c.
1777 (IPA_OBJS): Add alloc-ipa.o.
1778 (alloc-ipa.o): New target.
1779 (%.o: ../%.c): New pattern rule.
1781 2019-06-10 Tom Tromey <tromey@adacore.com>
1783 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
1784 end warning with a newline.
1785 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
1787 * thread-db.c (attach_thread): Don't end warning with a newline.
1788 (thread_db_notice_clone): Likewise.
1789 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
1791 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
1792 end warning with a newline.
1794 2019-06-04 Pedro Alves <palves@redhat.com>
1796 * server.c (captured_main): Use make_unique_xstrdup.
1798 2019-06-02 Tom Tromey <tom@tromey.com>
1800 * gdbreplay.c (fromhex): Remove.
1801 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
1803 2019-05-29 Tom Tromey <tromey@adacore.com>
1805 * configure: Rebuild.
1807 2019-05-06 Kevin Buettner <kevinb@redhat.com>
1809 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
1810 sign extension code on 32-bit builds.
1812 2019-05-03 Eli Zaretskii <eliz@gnu.org>
1815 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
1817 2019-04-19 Tom Tromey <tom@tromey.com>
1819 * server.c (struct vstop_notif): Derive from notif_event.
1821 (queue_stop_reply): Update.
1822 (remove_all_on_match_ptid): Change type. Rewrite.
1823 (discard_queued_stop_replies): Rewrite.
1824 (in_queued_stop_replies_ptid): Change type.
1825 (in_queued_stop_replies): Rewrite.
1826 (notif_stop): Update.
1827 (queue_stop_reply_callback): Update.
1828 (captured_main): Don't call initialize_notif.
1829 (push_stop_notification): Update.
1830 * notif.c (notif_write_event, handle_notif_ack)
1831 (notif_event_enque, notif_push): Update.
1832 (notif_event_xfree, initialize_notif): Remove.
1833 * notif.h (struct notif_event): Include <list>, not
1835 (struct notif_server) <queue>: Now a std::list.
1836 (notif_event_p): Remove typedef.
1837 (initialize_notif): Don't declare.
1838 (struct notif_event): Add virtual destructor.
1840 2019-04-17 Alan Hayward <alan.hayward@arm.com>
1842 * ax.c (ax_vdebug): Call debug_printf.
1843 * debug.c (debug_write): New function.
1844 * debug.h (debug_write): New declaration.
1845 * linux-low.c (sigchld_handler): Call debug_write.
1847 2019-04-17 Alan Hayward <alan.hayward@arm.com>
1849 * debug.c (debug_set_output): New function.
1850 (debug_vprintf): Send output to debug_file.
1851 (debug_flush): Likewise.
1852 * debug.h (debug_set_output): New declaration.
1853 * server.c (handle_monitor_command): Add debug-file option.
1854 (captured_main): Likewise.
1856 2019-04-17 Alan Hayward <alan.hayward@arm.com>
1858 * debug.c (remote_debug): Add definition.
1859 * debug.h (remote_debug): Add declaration.
1860 * hostio.c (remote_debug): Remove declaration.
1861 * remote-utils.c (struct ui_file): Likewise.
1862 (remote_debug): Likewise.
1863 * remote-utils.h (remote_debug): Likewise,
1864 * server.c (remote_debug): Remove definition.
1866 2019-04-10 Kevin Buettner <kevinb@redhat.com>
1868 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
1869 when using a 64-bit gdbserver.
1871 2019-04-09 Tom Tromey <tromey@adacore.com>
1873 * linux-low.c (select_event_lwp): Use find_thread_in_random.
1875 2019-04-08 Tom Tromey <tom@tromey.com>
1877 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
1879 (linux_resume_one_lwp): Likewise.
1881 2019-04-08 Tom Tromey <tom@tromey.com>
1883 * gdbreplay.c: Update.
1884 * linux-low.c: Update.
1887 2019-04-08 Tom Tromey <tom@tromey.com>
1889 * server.c: Use C++ exception handling.
1890 * linux-low.c: Use C++ exception handling.
1891 * gdbreplay.c: Use C++ exception handling.
1893 2019-04-08 Tom Tromey <tom@tromey.com>
1895 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
1896 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
1897 (captured_main, main): Update.
1898 * gdbreplay.c (main): Update.
1900 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1902 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
1903 value in argument pointer, return 1 if the entry is found and 0
1904 otherwise. Move comment.
1905 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
1906 * linux-low.h (linux_get_auxv): Declare.
1907 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
1909 2019-04-05 Tom Tromey <tromey@adacore.com>
1911 * server.c (gdbserver_usage): Use upper-case for metasyntactic
1914 2019-03-28 Alan Hayward <alan.hayward@arm.com>
1916 * linux-low.c (AT_HWCAP2): Add define if not already included.
1918 2019-03-26 Alan Hayward <alan.hayward@arm.com>
1920 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
1921 (aarch64_arch_setup): Call linux_get_hwcap.
1922 * linux-arm-low.c (arm_get_hwcap): Remove function.
1923 (arm_read_description): Call linux_get_hwcap.
1924 * linux-low.c (linux_get_auxv): New function.
1925 (linux_get_hwcap): Likewise.
1926 (linux_get_hwcap2): Likewise.
1927 * linux-low.h (linux_get_hwcap): New declaration.
1928 (linux_get_hwcap2): Likewise.
1929 * linux-ppc-low.c (ppc_get_auxv): Remove function.
1930 (ppc_arch_setup): Call linux_get_hwcap.
1931 * linux-s390-low.c (s390_get_hwcap): Remove function.
1932 (s390_arch_setup): Call linux_get_hwcap.
1934 2019-03-22 Alan Hayward <alan.hayward@arm.com>
1935 Jiong Wang <jiong.wang@arm.com>
1937 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
1938 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
1940 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
1942 2019-03-22 Alan Hayward <alan.hayward@arm.com>
1943 Jiong Wang <jiong.wang@arm.com>
1945 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
1946 (aarch64_get_hwcap): New function.
1947 (aarch64_arch_setup): Read APIA hwcap.
1949 2019-03-22 Alan Hayward <alan.hayward@arm.com>
1950 Jiong Wang <jiong.wang@arm.com>
1952 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
1953 (initialize_low_tracepoint): Likewise.
1954 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
1955 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
1956 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
1957 (aarch64_linux_read_description): Likewise.
1958 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
1960 2019-03-12 John Baldwin <jhb@FreeBSD.org>
1962 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
1963 i386_create_target_description for 'segments' parameter.
1964 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
1965 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
1966 * win32-i386-low.c (i386_arch_setup): Likewise.
1968 2019-03-12 Tom Tromey <tromey@adacore.com>
1970 * linux-low.c (iterate_over_lwps): Update.
1972 2019-03-06 Tom Tromey <tom@tromey.com>
1974 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
1975 (captured_main): Use SCOPE_EXIT.
1977 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
1979 * configure.srv: Use '$enable_unittest' instead of '$development'
1980 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
1983 2019-02-27 Tom Tromey <tromey@adacore.com>
1985 * gdbreplay.c (logchar): Handle \r\n.
1987 2019-02-07 Alan Hayward <alan.hayward@arm.com>
1989 * linux-low.c (linux_attach): Add process before lwp.
1990 * server.c (attach_inferior): Check if already attached.
1992 2019-02-07 Tom Tromey <tom@tromey.com>
1994 * x86-tdesc.h: Rename include guard.
1995 * x86-low.h: Add include guard.
1996 * wincecompat.h: Rename include guard.
1997 * win32-low.h: Add include guard.
1998 * utils.h: Rename include guard.
1999 * tracepoint.h: Rename include guard.
2000 * tdesc.h: Rename include guard.
2001 * target.h: Rename include guard.
2002 * server.h: Rename include guard.
2003 * remote-utils.h: Rename include guard.
2004 * regcache.h: Rename include guard.
2005 * nto-low.h: Rename include guard.
2006 * notif.h: Add include guard.
2007 * mem-break.h: Rename include guard.
2008 * lynx-low.h: Add include guard.
2009 * linux-x86-tdesc.h: Add include guard.
2010 * linux-s390-tdesc.h: Add include guard.
2011 * linux-ppc-tdesc-init.h: Add include guard.
2012 * linux-low.h: Add include guard.
2013 * linux-aarch64-tdesc.h: Add include guard.
2014 * linux-aarch32-low.h: Add include guard.
2015 * inferiors.h: Rename include guard.
2016 * i387-fp.h: Rename include guard.
2017 * hostio.h: Rename include guard.
2018 * gdbthread.h: Rename include guard.
2019 * gdb_proc_service.h: Rename include guard.
2020 * event-loop.h: Rename include guard.
2021 * dll.h: Rename include guard.
2022 * debug.h: Rename include guard.
2023 * ax.h: Rename include guard.
2025 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
2028 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
2029 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
2031 2019-01-25 Tom Tromey <tom@tromey.com>
2033 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
2035 2019-01-25 Tom Tromey <tom@tromey.com>
2037 * win32-low.c: Fix common/ includes.
2038 * win32-i386-low.c: Fix common/ includes.
2039 * tracepoint.c: Fix common/ includes.
2040 * thread-db.c: Fix common/ includes.
2041 * target.h: Fix common/ includes.
2042 * symbol.c: Fix common/ includes.
2043 * spu-low.c: Fix common/ includes.
2044 * server.h: Fix common/ includes.
2045 * server.c: Fix common/ includes.
2046 * remote-utils.c: Fix common/ includes.
2047 * regcache.h: Fix common/ includes.
2048 * regcache.c: Fix common/ includes.
2049 * nto-x86-low.c: Fix common/ includes.
2050 * notif.h: Fix common/ includes.
2051 * mem-break.h: Fix common/ includes.
2052 * lynx-low.c: Fix common/ includes.
2053 * lynx-i386-low.c: Fix common/ includes.
2054 * linux-x86-tdesc-selftest.c: Fix common/ includes.
2055 * linux-x86-low.c: Fix common/ includes.
2056 * linux-low.c: Fix common/ includes.
2057 * inferiors.h: Fix common/ includes.
2058 * i387-fp.c: Fix common/ includes.
2059 * hostio.c: Fix common/ includes.
2060 * hostio-errno.c: Fix common/ includes.
2061 * gdbthread.h: Fix common/ includes.
2062 * gdbreplay.c: Fix common/ includes.
2063 * fork-child.c: Fix common/ includes.
2064 * event-loop.c: Fix common/ includes.
2066 (enum gdb_agent_op): Fix common/ includes.
2068 2019-01-21 Tom Tromey <tom@tromey.com>
2070 * tracepoint.c: Fix includes.
2071 * remote-utils.c: Fix includes.
2072 * linux-x86-low.c: Fix includes.
2074 2019-01-01 Joel Brobecker <brobecker@adacore.com>
2076 * gdbreplay.c (gdbreplay_version): Update copyright year in
2078 * server.c (gdbserver_version): Likewise.
2080 2018-12-05 Alan Hayward <alan.hayward@arm.com>
2082 * linux-low.c (add_lwp): Switch ordering.
2084 2018-11-29 Tom Tromey <tom@tromey.com>
2086 * win32-low.c (win32_join): Take pid, not process.
2087 * target.h (struct target_ops) <join>: Change argument type.
2088 (join_inferior): Change argument name.
2089 * spu-low.c (spu_join): Take pid, not process.
2090 * server.c (handle_detach): Preserve pid before destroying
2092 * lynx-low.c (lynx_join): Take pid, not process.
2093 * linux-low.c (linux_join): Take pid, not process.
2095 2018-11-23 Alan Hayward <alan.hayward@arm.com>
2097 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
2098 (aarch64_cannot_fetch_register): Likewise.
2099 (struct linux_target_ops): Update references.
2101 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2103 * linux-ppc-low.c: Include nat/linux-ptrace.h.
2105 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2107 * configure.srv (ipa_ppc_linux_regobj): Add
2108 powerpc-isa207-htm-vsx32l-ipa.o and
2109 powerpc-isa207-htm-vsx64l-ipa.o.
2110 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
2111 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
2112 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
2113 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
2114 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
2115 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
2116 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
2117 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
2118 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
2119 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
2120 (init_registers_powerpc_isa207_htm_vsx32l)
2121 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
2122 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
2123 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
2124 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
2125 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
2126 (ppc_store_tm_ctarregset): New functions.
2127 (ppc_regsets): Add entries for HTM regsets.
2128 (ppc_arch_setup): Set htm in features struct when needed. Set
2129 sizes for the HTM regsets.
2130 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
2131 (initialize_low_arch): Call
2132 init_registers_powerpc_isa207_htm_vsx32l and
2133 init_registers_powerpc_isa207_htm_vsx64l.
2134 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
2135 PPC_TDESC_ISA207_HTM_VSX.
2136 (initialize_low_tracepoint): Call
2137 init_registers_powerpc_isa207_htm_vsx32l and
2138 init_registers_powerpc_isa207_htm_vsx64l.
2140 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2142 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
2143 rs6000/power-linux-pmu.xml to srv_xmlfiles.
2144 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
2145 (ppc_store_pmuregset): New functions.
2146 (ppc_regsets): Add entries for ebb and pmu regsets.
2147 (ppc_arch_setup): Set isa207 in features struct if the ebb and
2148 pmu regsets are available. Set sizes for these regsets.
2150 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2152 * configure.srv (ipa_ppc_linux_regobj): Add
2153 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
2154 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
2155 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
2156 rs6000/powerpc-isa207-vsx32l.xml, and
2157 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
2158 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
2159 <PPC_TDESC_ISA207_VSX>: New enum value.
2160 (init_registers_powerpc_isa207_vsx32l): Declare.
2161 (init_registers_powerpc_isa207_vsx64l): Declare.
2162 * linux-ppc-low.c (ppc_fill_tarregset): New function.
2163 (ppc_store_tarregset): New function.
2164 (ppc_regsets): Add entry for the TAR regset.
2165 (ppc_arch_setup): Set isa207 in features struct when needed. Set
2166 size for the TAR regsets.
2167 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
2168 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
2169 and init_registers_powerpc_isa207_vsx64l.
2170 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
2171 (initialize_low_tracepoint): Call
2172 init_registers_powerpc_isa207_vsx32l and
2173 init_registers_powerpc_isa207_vsx64l.
2175 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
2176 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2178 * configure.srv (ipa_ppc_linux_regobj): Add
2179 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
2180 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
2181 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
2182 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
2183 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
2184 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
2185 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
2186 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
2187 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
2188 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
2189 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
2190 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
2191 (ppc_hwcap): Add comment.
2192 (ppc_hwcap2): New global.
2193 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
2194 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
2195 (ppc_regsets): Add entries for the DSCR and PPR regsets.
2196 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
2197 when needed. Set sizes for the the DSCR and PPR regsets.
2198 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
2199 (initialize_low_arch): Call
2200 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
2201 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
2202 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
2203 PPC_TDESC_ISA205_PPR_DSCR_VSX.
2204 (initialize_low_tracepoint): Call
2205 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
2206 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
2208 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2210 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
2212 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
2213 Simon Marchi <simark@simark.ca>
2215 * acinclude.m4: Include "../selftest.m4".
2216 * configure: Regenerate.
2217 * configure.ac: Use "GDB_AC_SELFTEST".
2218 * configure.srv: Use "$enable_unittests" instead of
2219 "$development" when checking whether unit tests have been
2221 * server.c (captured_main): Update message informing that
2222 selftests have been disabled.
2224 2018-10-04 Tom Tromey <tom@tromey.com>
2226 * configure: Rebuild.
2228 2018-10-04 Tom Tromey <tom@tromey.com>
2230 * server.c (handle_status): Rename inner "thread".
2231 (process_serial_event): Declare "res" in 'm' case.
2232 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
2233 (iterate_over_lwps): Rename inner "thread".
2234 (linux_qxfer_libraries_svr4): Rename inner "len".
2235 * gdbthread.h (find_thread_in_random): Rename inner "thread".
2237 2018-10-01 Gary Benson <gbenson@redhat.com>
2239 * gdb_proc_service.h: Moved common code to
2240 common/gdb_proc_service.h.
2242 2018-10-01 Gary Benson <gbenson@redhat.com>
2244 * gdb_proc_service.h: Synchronize comments and whitespace with
2245 GDB's version of this file.
2247 2018-09-25 Tom Tromey <tom@tromey.com>
2249 * configure: Rebuild.
2250 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
2252 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
2254 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
2255 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
2256 ($(IPA_LIB)): Sort IPA_OBJS.
2258 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
2260 * Makefile.in: Remove references to $(ADD_DEPS).
2262 2018-09-16 Tom Tromey <tom@tromey.com>
2264 * remote-utils.c (remote_open): Use GNU style for metasyntactic
2266 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
2269 2018-09-05 Tom Tromey <tom@tromey.com>
2271 * configure: Rebuild.
2273 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
2276 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
2278 2018-08-27 Tom Tromey <tom@tromey.com>
2281 * configure: Rebuild.
2283 2018-08-27 Tom Tromey <tom@tromey.com>
2285 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
2286 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
2287 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
2288 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
2289 (s390x_emit_stack_adjust): Add casts to unsigned char.
2291 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
2295 * server.h (struct client_state) <disable_randomization>:
2298 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2300 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
2302 (mips_supply_ptrace_register): Likewise.
2304 2018-07-22 Tom Tromey <tom@tromey.com>
2306 * configure: Rebuild.
2308 2018-07-22 Tom Tromey <tom@tromey.com>
2310 * win32-low.c (win32_create_inferior): Remove unused variables.
2311 * gdbreplay.c (remote_open): Remove unused variable.
2312 * remote-utils.c (remote_prepare): Remove unused variable.
2313 * x86-tdesc.h (X86_TDESC_H): Define.
2314 (amd64_expedite_regs): Define conditionally.
2315 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
2316 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
2317 * remote-utils.c (readchar): Remove unused variable.
2319 2018-07-13 Pedro Alves <palves@redhat.com>
2321 * linux-low.c (linux_kill): Change parameter to process_info
2322 pointer instead of pid. Adjust.
2323 * lynx-low.c (lynx_kill): Likewise.
2324 * nto-low.c (nto_kill): Likewise.
2325 * spu-low.c (spu_kill): Likewise.
2326 * win32-low.c (win32_kill): Likewise.
2327 * server.c (handle_v_kill, kill_inferior_callback)
2328 (detach_or_kill_for_exit): Adjust.
2329 * target.c (kill_inferior): Change parameter to process_info
2330 pointer instead of pid. Adjust.
2331 * target.h (struct target_ops) <kill>: Change parameter to
2332 process_info pointer instead of pid. Adjust all implementations
2334 (kill_inferior): Likewise.
2336 2018-07-13 Pedro Alves <palves@redhat.com>
2338 * linux-low.c (linux_detach, linux_join): Change parameter to
2339 process_info pointer instead of pid. Adjust.
2340 * lynx-low.c (lynx_detach, lynx_join): Likewise.
2341 * nto-low.c (nto_detach): Likewise.
2342 * spu-low.c (spu_detach, spu_join): Likewise.
2343 * win32-low.c (win32_detach, win32_join): Likewise.
2344 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
2345 * target.h (struct target_ops) <detach, join>: Change parameter to
2346 process_info pointer instead of pid. Adjust all implementations
2348 (detach_inferior, join_inferior): Rename 'pid' parameter to
2351 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
2352 Jan Kratochvil <jan.kratochvil@redhat.com>
2353 Paul Fertser <fercerpav@gmail.com>
2354 Tsutomu Seki <sekiriki@gmail.com>
2356 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
2357 (OBS): Add 'common/netstuff.o'.
2358 (GDBREPLAY_OBS): Likewise.
2359 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
2360 (remote_open): Implement support for IPv6
2362 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
2364 (handle_accept_event): Accept connections from IPv6 sources.
2365 (remote_prepare): Handle IPv6-style hostnames; implement
2366 support for IPv6 connections.
2367 (remote_open): Implement support for printing connections from
2370 2018-07-11 Pedro Alves <palves@redhat.com>
2373 * mem-break.c (any_persistent_commands): Add process_info
2374 parameter and use it instead of relying on the current process.
2375 Change return type to bool.
2376 * mem-break.h (any_persistent_commands): Add process_info
2377 parameter and change return type to bool.
2378 * server.c (handle_detach): Remove require_running_or_return call.
2379 Look up the process_info for the process we're about to detach.
2380 If not found, return back error to GDB. Adjust
2381 any_persistent_commands call to pass down a process pointer.
2383 2018-07-11 Pedro Alves <palves@redhat.com>
2385 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
2386 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
2387 instead of collect_register_by_name.
2388 * regcache.c (regcache_raw_get_unsigned_by_name): New.
2389 * regcache.h (regcache_raw_get_unsigned_by_name): New.
2391 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
2392 Pedro Alves <palves@redhat.com>
2394 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
2396 2018-07-03 Tom Tromey <tom@tromey.com>
2398 * linux-low.c: Update.
2399 * lynx-low.c: Update.
2400 * mem-break.c: Update.
2401 * nto-low.c: Update.
2402 * remote-utils.c: Update.
2404 * spu-low.c: Update.
2406 * win32-low.c: Update.
2408 2018-07-03 Tom Tromey <tom@tromey.com>
2412 2018-07-03 Tom Tromey <tom@tromey.com>
2414 * linux-low.c: Update.
2416 2018-07-03 Tom Tromey <tom@tromey.com>
2420 2018-07-03 Tom Tromey <tom@tromey.com>
2422 * linux-low.c: Update.
2423 * linux-mips-low.c: Update.
2424 * lynx-low.c: Update.
2425 * nto-low.c: Update.
2426 * remote-utils.c: Update.
2428 * spu-low.c: Update.
2430 * thread-db.c: Update.
2432 2018-07-03 Tom Tromey <tom@tromey.com>
2434 * linux-low.c: Update.
2435 * linux-mips-low.c: Update.
2436 * lynx-low.c: Update.
2437 * mem-break.c: Update.
2438 * nto-low.c: Update.
2439 * remote-utils.c: Update.
2441 * spu-low.c: Update.
2443 * tracepoint.c: Update.
2445 2018-07-03 Tom Tromey <tom@tromey.com>
2447 * linux-low.c: Update.
2448 * linux-ppc-low.c: Update.
2449 * linux-x86-low.c: Update.
2450 * proc-service.c: Update.
2452 * spu-low.c: Update.
2453 * thread-db.c: Update.
2454 * win32-low.c: Update.
2456 2018-07-03 Tom Tromey <tom@tromey.com>
2458 * linux-low.c: Update.
2459 * lynx-low.c: Update.
2460 * nto-low.c: Update.
2461 * remote-utils.c: Update.
2462 * spu-low.c: Update.
2463 * thread-db.c: Update.
2464 * win32-low.c: Update.
2466 2018-06-29 Joel Brobecker <brobecker@adacore.com>
2468 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
2469 parameter in call to 'amd64_create_target_description'.
2471 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
2473 * x86-tdesc.h: Remove executable permission flag.
2475 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
2477 * configure.ac: Remove AC_PREREQ, add missing quoting.
2478 * configure: Re-generate.
2479 * config.in: Re-generate.
2480 * aclocal.m4: Re-generate.
2482 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
2484 * tracepoint.h (current_traceframe): Remove declaration.
2486 2018-06-18 Alan Hayward <alan.hayward@arm.com>
2488 * linux-aarch64-low.c (is_sve_tdesc): New function.
2489 (aarch64_sve_regs_copy_to_regcache): Likewise.
2490 (aarch64_sve_regs_copy_from_regcache): Likewise.
2491 (aarch64_regs_info): Add SVE checks.
2492 (initialize_low_arch): Initialize SVE.
2494 2018-06-18 Alan Hayward <alan.hayward@arm.com>
2496 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
2498 2018-06-11 Alan Hayward <alan.hayward@arm.com>
2500 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
2501 (initialize_low_tracepoint): Likewise
2502 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
2503 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
2505 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
2507 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
2509 2018-06-11 Alan Hayward <alan.hayward@arm.com>
2511 * server.h (PBUFSIZ): Increase size
2513 2018-06-11 Alan Hayward <alan.hayward@arm.com>
2515 * regcache.c (regcache::raw_compare): New function.
2516 * regcache.h (regcache::raw_compare): New declaration.
2518 2018-06-11 Alan Hayward <alan.hayward@arm.com>
2520 * regcache.c (new_register_cache): Use new.
2521 (free_register_cache): Use delete.
2522 (register_data): Use const.
2523 (supply_register): Move body inside regcache.
2524 (regcache::raw_supply): New override function.
2525 (collect_register): Move body inside regcache.
2526 (regcache::raw_collect): New override function.
2527 (regcache::get_register_status): New override function.
2528 * regcache.h (struct regcache): Inherit from reg_buffer_common.
2530 2018-06-09 Tom Tromey <tom@tromey.com>
2532 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
2534 (event_queue): Use std::queue.
2535 (gdb_event_xfree): Remove.
2536 (initialize_event_loop, process_event, wait_for_event): Update.
2538 2018-06-08 Stan Cox <scox@redhat.com>
2540 * win32-low.c (win32_create_inferior): last_ptid and last_status
2541 moved to client_state.
2543 2018-06-08 Pedro Alves <palves@redhat.com>
2545 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
2546 common/common-exceptions.o, common/common-utils.o,
2547 common/errors.o, common/print-utils.o and utils.o.
2548 * gdbreplay.c: Include "common-defs.h" instead of the two
2549 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
2550 string.h or alloca.h.
2551 (perror_with_name): Delete.
2552 (remote_open): Use xstrdup instead of strdup.
2553 (main): Rename to ...
2554 (captured_main): ... this.
2557 2018-06-08 Tom Tromey <tom@tromey.com>
2559 * linux-low.c (linux_low_read_btrace): Update.
2561 2018-06-04 Stan Cox <scox@redhat.com>
2563 * server.h (struct client_state): New.
2564 * server.c (cont_thread, general_thread, multi_process)
2565 (report_fork_events, report_vfork_events, report_exec_events)
2566 (report_thread_events, swbreak_feature, hwbreak_feature)
2567 (vCont_supported, disable_randomization, pass_signals)
2568 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
2569 Moved to client_state.
2570 * remote-utils.c (remote_debug, noack_mode)
2571 (transport_is_reliable): Moved to client_state.
2572 * tracepoint.c (current_traceframe): Moved to client_state.
2575 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
2576 linux-low.c, remote-utils.h, target.c: Use client_state.
2578 2018-05-31 Alan Hayward <alan.hayward@arm.com>
2580 * configure.srv: Add new c/h file.
2582 2018-05-31 Alan Hayward <alan.hayward@arm.com>
2584 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
2587 2018-05-25 Maciej W. Rozycki <macro@mips.com>
2589 * gdb.arch/mips-fpregset-core.exp: New test.
2590 * gdb.arch/mips-fpregset-core.c: New test source.
2592 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
2595 * hostio.c (require_int): Do not report overflow for integers
2596 between 0xfffffff and 0x7fffffff.
2598 2018-05-22 Maciej W. Rozycki <macro@mips.com>
2600 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
2601 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
2602 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
2604 (the_low_target): Wire them.
2606 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2608 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
2609 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
2610 mode. Call collect_register_by_name with vscr using
2611 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
2612 (ppc_store_vrregset): Add and set vscr_offset variable as in
2613 ppc_fill_vrregset. Call supply_register_by_name with vscr using
2616 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2618 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
2619 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
2620 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
2622 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2624 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
2625 (ppc_store_vsxregset): Likewise.
2626 (ppc_fill_vrregset): Likewise.
2627 (ppc_store_vrregset): Likewise.
2628 (ppc_fill_evrregset): Likewise.
2629 (ppc_store_evrregset): Likewise.
2630 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
2631 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
2634 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2636 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
2637 wordsize of the inferior. Call ppc_linux_target_wordsize.
2639 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2641 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
2642 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
2643 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
2644 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
2645 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
2646 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
2647 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
2648 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
2649 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
2650 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
2651 (tdesc_powerpc_e500l): Remove.
2652 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
2653 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
2654 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
2655 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
2657 (ppc_arch_setup): Remove target description matching code. Fill a
2658 ppc_linux_features struct and call ppc_linux_match_description
2661 2018-05-22 Maciej W. Rozycki <macro@mips.com>
2663 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
2664 width of the requested register exceeds the width of the
2666 (mips_cannot_store_register): Likewise.
2668 2018-05-21 Maciej W. Rozycki <macro@mips.com>
2670 * linux-mips-low.c (mips_fetch_register): New function. Update
2672 (mips_store_gregset): Supply 0 rather than $restart for $zero.
2673 (the_low_target): Wire `mips_fetch_register'.
2675 2018-05-10 Joel Brobecker <brobecker@adacore.com>
2677 * lynx-i386-low.c (LYNXOS_178): New macro.
2678 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
2679 the layout on LynxOS-178.
2680 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
2681 handle floating point registers that are not supported by
2684 2018-05-10 Tom Tromey <tom@tromey.com>
2686 * configure: Rebuild.
2688 2018-05-10 Joel Brobecker <brobecker@adacore.com>
2691 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
2692 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
2693 Use it to set the expedite_regs field in the given tdesc.
2694 * x86-tdesc.h: New file.
2695 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
2696 Adjust following the addition of the new expedite_regs parameter
2697 to init_target_desc.
2698 * linux-tic6x-low.c (tic6x_read_description): Likewise.
2699 * linux-x86-tdesc.c: #include "x86-tdesc.h".
2700 (i386_linux_read_description, amd64_linux_read_description):
2701 Adjust following the addition of the new expedite_regs parameter
2702 to init_target_desc.
2703 * lynx-i386-low.c: #include "x86-tdesc.h".
2704 (lynx_i386_arch_setup): Adjust following the addition of the new
2705 expedite_regs parameter to init_target_desc.
2706 * nto-x86-low.c: #include "x86-tdesc.h".
2707 (nto_x86_arch_setup): Adjust following the addition of the new
2708 expedite_regs parameter to init_target_desc.
2709 * win32-i386-low.c: #include "x86-tdesc.h".
2710 (i386_arch_setup): Adjust following the addition of the new
2711 expedite_regs parameter to init_target_desc.
2713 2018-05-10 Joel Brobecker <brobecker@adacore.com>
2716 * win32-low.c (win32_create_inferior): Add call to my_wait
2717 setting last_status global.
2719 2018-05-10 Joel Brobecker <brobecker@adacore.com>
2722 * win32-low.c (create_process): Only call gdb_tilde_expand if
2723 inferior_cwd is not NULL.
2725 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
2727 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
2728 registers to the cache if their values have changed.
2729 (i387_xsave_to_cache): Provide default values for x87 control
2730 registers when these features are available, but disabled.
2731 * regcache.c (supply_register_by_name_zeroed): New function.
2732 * regcache.h (supply_register_by_name_zeroed): Declare new
2735 2018-05-07 Tom Tromey <tom@tromey.com>
2737 * configure: Rebuild.
2739 2018-05-04 Tom Tromey <tom@tromey.com>
2741 * configure: Rebuild.
2743 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
2744 Pedro Alves <palves@redhat.com>
2746 * linux-aarch64-low.c (aarch64_stopped_data_address):
2749 2018-04-27 Tom Tromey <tom@tromey.com>
2751 * configure: Rebuild.
2753 2018-04-23 Tom Tromey <tom@tromey.com>
2755 * configure: Rebuild.
2757 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
2759 * Makefile.in (depcomp): Add "..".
2760 (all_deps_files): New and use it.
2762 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2764 * configure.srv (aarch64*-*-linux*): Don't include xml.
2765 (i[34567]86-*-cygwin*): Likewise.
2766 (i[34567]86-*-linux*): Likewise.
2767 (i[34567]86-*-lynxos*): Likewise.
2768 (i[34567]86-*-mingw32ce*): Likewise.
2769 (i[34567]86-*-mingw*): Likewise.
2770 (i[34567]86-*-nto*): Likewise.
2771 (tic6x-*-uclinux): Likewise.
2772 (x86_64-*-linux*): Likewise.
2773 (x86_64-*-mingw*): Likewise.
2774 (x86_64-*-cygwin*): Likewise.
2776 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2778 * tdesc.c: Remove xml parameter.
2780 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2782 * server.c (get_features_xml): Remove cast.
2783 * tdesc.c (void target_desc::accept): Fill in function.
2784 (tdesc_get_features_xml): Remove old xml creation.
2785 (print_xml_feature::visit_pre): Add xml vistor.
2786 * tdesc.h (struct target_desc): Make xmltarget mutable.
2787 (tdesc_get_features_xml): Remove declaration.
2789 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2791 * tdesc.c (tdesc_architecture_name): Add new function.
2792 (tdesc_osabi_name): Likewise.
2793 (tdesc_get_features_xml): Use new functions.
2795 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2797 * tdesc.c (tdesc_create_flags): Remove.
2798 (tdesc_add_flag): Likewise.
2799 (tdesc_named_type): Likewise.
2800 (tdesc_create_union): Likewise.
2801 (tdesc_create_struct): Likewise.
2802 (tdesc_create_vector): Likewise.
2803 (tdesc_add_bitfield): Likewise.
2804 (tdesc_add_field): Likewise.
2805 (tdesc_set_struct_size): Likewise.
2807 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2809 * tdesc.c (~target_desc): Remove implictly deleted items.
2810 (init_target_desc): Iterate all features.
2811 (tdesc_get_features_xml): Use vector.
2812 (tdesc_create_feature): Create feature.
2813 * tdesc.h (tdesc_feature) Remove
2814 (target_desc): Add features.
2816 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2818 * Makefile.in: Add common/tdesc.c
2819 * tdesc.c (init_target_desc): init all reg_defs from register
2821 (tdesc_create_reg): Create tdesc_reg.
2822 * tdesc.h (tdesc_feature): Add register vector.
2824 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
2826 * tdesc.h (struct target_desc) <features>: Change type to
2827 std::vector<std::string>.
2828 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
2830 (tdesc_get_features_xml): Likewise.
2831 (tdesc_create_feature): Likewise.
2833 2018-03-26 Alan Hayward <alan.hayward@arm.com>
2835 * regcache.c (find_register_by_number): Return a ref.
2836 (find_regno): Use references.
2837 (register_size): Likewise.
2838 (register_data): Likewise.
2839 * tdesc.c (target_desc::~target_desc): Remove free calls.
2840 (target_desc::operator==): Use std::vector compare.
2841 (init_target_desc): Use reference.
2842 (tdesc_create_reg): Use reg constructors.
2843 * tdesc.h (struct target_desc): Replace pointer with object.
2845 2018-03-23 Alan Hayward <alan.hayward@arm.com>
2847 * regcache.c (find_register_by_number): Make static.
2848 (find_regno): Use find_register_by_number
2849 * regcache.h (struct reg): Remove declaration.
2851 2018-03-23 Alan Hayward <alan.hayward@arm.com>
2853 * tdesc.c (target_desc::~target_desc): Move to here.
2854 (target_desc::operator==): Likewise.
2855 * tdesc.h (target_desc::~target_desc): Move from here.
2856 (target_desc::operator==): Likewise.
2858 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
2860 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
2862 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
2864 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
2866 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
2867 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
2868 and init_registers_s390_gs_linux64.
2870 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
2872 * linux-s390-low.c (s390_fill_gs): Remove function.
2873 (s390_fill_gsbc): Remove function.
2874 (s390_regsets): Set fill functions for the guarded storage regsets
2877 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
2879 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
2880 the word size. Add comment.
2881 (s390_get_wordsize): New function.
2882 (s390_arch_setup): No longer select a temporary tdesc to fetch the
2883 pswm with it. Instead, use s390_get_wordsize to determine the
2884 word size first and derive the correct tdesc from that directly.
2886 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
2888 * Makefile.in: Include silent-rules.mk.
2889 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
2890 (COMPILE): Add ECHO_CXX.
2891 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
2892 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
2893 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
2894 (version-generated.c): Add ECHO_GEN.
2895 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
2896 (IPAGENT_COMPILE): Add ECHO_CXX.
2897 (%-generated.c): Add ECHO_REGDAT.
2899 2018-03-14 Tom Tromey <tom@tromey.com>
2902 * ax.c (ax_printf): Special case for NULL.
2904 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
2906 * linux-low.c (linux_qxfer_libraries_svr4): Use
2907 xml_escape_text_append.
2909 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
2911 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
2913 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
2915 * server.c (handle_general_set): Remove unnecessary xstrdup.
2917 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
2919 * server.c (parse_debug_format_options): Adjust to
2920 delim_string_to_char_ptr_vec changes.
2921 * thread-db.c (thread_db_load_search): Adjust to
2922 dirnames_to_char_ptr_vec changes.
2924 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
2926 * target.h (target_enable_btrace, target_disable_btrace)
2927 (target_read_btrace, target_read_btrace_conf): Turn macro into
2928 inline function. Throw error if target method is not defined.
2929 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
2930 check for btrace target method. Be prepared to handle exceptions
2931 from btrace target methods.
2933 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
2935 * server.c (captured_main): Change order of error message printed
2936 when the current working directory cannot be found.
2938 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
2940 * server.c: Include "filenames.h" and "pathstuff.h".
2941 (program_name): Delete variable.
2942 (program_path): New anonymous class.
2943 (get_exec_wrapper): Use "program_path" instead of
2945 (handle_v_run): Likewise.
2946 (captured_main): Likewise.
2947 (process_serial_event): Likewise.
2949 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
2951 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
2952 (OBJS): Add "pathstuff.o".
2953 * server.c (current_directory): New global variable.
2954 (captured_main): Initialize "current_directory".
2956 2018-02-26 Alan Hayward <alan.hayward@arm.com>
2958 * tdesc.c: Use common/tdesc.h.
2959 * tdesc.h: Likewise.
2961 2018-02-20 Alan Hayward <alan.hayward@arm.com>
2962 Simon Marchi <simon.marchi@ericsson.com>
2964 * Makefile.in: Switch order of make rules.
2966 2018-02-19 Alan Hayward <alan.hayward@arm.com>
2968 * Makefile.in: Add common directory in build.
2969 * configure.ac: Add common reference.
2970 * configure: Regenerate.
2972 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
2974 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
2975 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
2976 * spu-low.c (spu_target_ops): Likewise.
2977 * win32-low.c (win32_target_ops): Likewise.
2978 * server.c (supported_btrace_packets): Report packets unconditionally.
2979 * target.h (target_ops) <supports_btrace>: Remove.
2980 (target_supports_btrace): Remove.
2982 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
2984 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
2985 (handle_btrace_disable): Change return type to void. Use exceptions
2987 (handle_btrace_general_set): Catch exception and copy message to
2990 2018-02-08 Tom Tromey <tom@tromey.com>
2992 * linux-low.c (install_software_single_step_breakpoints): Use
2993 make_scoped_restore.
2994 * inferiors.c (make_cleanup_restore_current_thread): Remove.
2995 (do_restore_current_thread_cleanup): Remove.
2996 * gdbthread.h (make_cleanup_restore_current_thread): Don't
2999 2018-02-08 Tom Tromey <tom@tromey.com>
3001 * mem-break.c (set_raw_breakpoint_at): Use
3002 gdb::unique_xmalloc_ptr.
3004 2018-01-30 Pedro Alves <palves@redhat.com>
3007 * target.c (target_terminal::terminal_state): Rename to ...
3008 (target_terminal::m_terminal_state): ... this.
3010 2018-01-19 James Clarke <jrtc27@jrtc27.com>
3012 * linux-low.c (handle_extended_wait): Surround call to
3013 thread_db_notice_clone with #ifdef USE_THREAD_DB.
3015 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
3017 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
3018 linux_ptrace_attach_fail_reason_string now returning an
3020 (linux_attach): Likewise.
3021 * thread-db.c (attach_thread): Likewise.
3023 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
3026 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
3027 checking for fs_base/gs_base fields in struct user_regs_struct.
3028 * configure: Regenerate.
3030 2018-01-16 Yao Qi <yao.qi@linaro.org>
3033 * linux-low.c (fetch_register): Call supply_register instead of
3036 2018-01-08 Yao Qi <yao.qi@linaro.org>
3037 Simon Marchi <simon.marchi@ericsson.com>
3039 * Makefile.in (OBS): Remove selftest.o.
3040 * configure.ac: Set srv_selftest_objs if $development is true.
3041 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
3042 * configure: Re-generated.
3043 * server.c (captured_main): Wrap variable selftest_filter with
3046 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
3048 * server.c (parse_debug_format_options): Return std::string.
3049 (handle_monitor_command, captured_main): Adjust.
3051 2018-01-05 Pedro Alves <palves@redhat.com>
3054 * server.c (captured_main): Pass quiet=false to
3055 save_original_signals_state.
3057 2018-01-01 Joel Brobecker <brobecker@adacore.com>
3059 * gdbreplay.c (gdbreplay_version): Update copyright year in
3061 * server.c (gdbserver_version): Likewise.
3063 2017-12-08 Tom Tromey <tom@tromey.com>
3065 * ax.c (ax_printf): Update.
3067 2017-12-07 Yao Qi <yao.qi@linaro.org>
3069 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
3070 aarch64_linux_read_description.
3071 * linux-amd64-ipa.c (idx2mask): New array.
3072 (get_ipa_tdesc): Move idx2mask out.
3073 (initialize_low_tracepoint): Initialize target descriptions.
3074 * linux-i386-ipa.c (idx2mask): New array.
3075 (get_ipa_tdesc): Move idx2mask out.
3076 (initialize_low_tracepoint): Initialize target descriptions.
3078 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
3080 * tdesc.c (struct tdesc_type): Change return type.
3081 (tdesc_add_flag): Change parameter type.
3082 (tdesc_add_bitfield): Likewise.
3083 (tdesc_add_field): Likewise.
3084 (tdesc_set_struct_size): Likewise.
3086 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
3088 * regcache.c (registers_to_string): Remove unused variable.
3090 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3092 * inferiors.c (for_each_inferior_with_data): Remove.
3093 * inferiors.h (for_each_inferior_with_data): Remove.
3094 * server.c (handle_qxfer_threads_worker): Change parameter type.
3095 (handle_qxfer_threads_proper): Use for_each_thread.
3097 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3099 * inferiors.c (for_each_inferior): Remove.
3100 (clear_inferiors): Use for_each_thread.
3101 * inferiors.h (for_each_inferior): Remove.
3102 * linux-low.c (linux_wait_for_event_filtered): Use
3104 (linux_stabilize_threads): Likewise.
3105 * regcache.c (regcache_release): Likewise.
3106 * server.c (gdb_wants_all_threads_stopped): Likewise.
3107 (clear_pending_status_callback): Remove.
3108 (handle_status): Use for_each_thread.
3109 (captured_main): Likewise.
3110 * win32-low.c (child_init_thread_list): Likewise.
3111 (win32_clear_inferiors): Likewise.
3112 (fake_breakpoint_event): Likewise.
3114 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3116 * inferiors.h (find_inferior): Remove.
3117 * inferiors.c (find_inferior): Remove.
3119 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3121 * linux-low.c (resume_status_pending_p): Update comment.
3122 (need_step_over_p): Update comment.
3124 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3126 * linux-low.c (proceed_one_lwp): Return void, change parameter
3128 (unsuspend_and_proceed_one_lwp): Likewise.
3129 (proceed_all_lwps): Use for_each_thread.
3130 (unstop_all_lwps): Likewise.
3132 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3134 * linux-low.c (linux_resume_one_thread): Return void, take
3136 (linux_resume): Use for_each_thread.
3138 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3140 * linux-low.c (send_sigstop_callback): Return void, change
3141 parameter type. Rename to...
3142 (send_sigstop): ... this.
3143 (suspend_and_send_sigstop_callback): Return void, change parameter
3145 (suspend_and_send_sigstop): ... this.
3146 (stop_all_lwps): Use for_each_thread.
3148 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3150 * linux-low.c (lwp_running): Return bool, remove unused
3152 (linux_stabilize_threads): Use find_thread.
3154 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3156 * linux-low.c (select_singlestep_lwp_callback): Remove.
3157 (count_events_callback): Remove.
3158 (select_event_lwp_callback): Remove.
3159 (select_event_lwp): Use find_thread/for_each_thread.
3161 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3163 * linux-low.c (not_stopped_callback): Return bool, take filter
3165 (linux_wait_for_event_filtered): Use find_thread.
3166 (linux_wait_1): Likewise.
3168 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3170 * linux-low.c (same_lwp): Remove.
3171 (find_lwp_pid): Use find_thread.
3173 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3175 * linux-low.c (delete_lwp_callback): Remove.
3176 (linux_mourn): Use for_each_thread.
3178 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3180 * linux-low.c (linux_detach_lwp_callback): Return void, remove
3181 args parameter, don't check for pid.
3182 (linux_detach): Use for_each_thread.
3184 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3186 * linux-low.c (struct counter): Remove.
3187 (second_thread_of_pid_p): Remove.
3188 (last_thread_of_process_p): Use find_thread.
3190 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3192 * inferiors.c (find_inferior_in_random): Remove.
3193 * inferiors.h (find_inferior_in_random): Remove.
3194 * linux-low.c (status_pending_p_callback): Return bool, accept
3195 parameter ptid directly.
3196 (linux_wait_for_event_filtered): Use find_thread_in_random.
3197 (linux_wait_1): Likewise.
3199 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3201 * inferiors.c (find_inferior_id): Remove.
3202 (find_thread_ptid): Move implemention from find_inferior_id to
3204 * inferiors.h (find_inferior_id): Remove.
3205 * server.c (handle_status): Use find_thread_ptid.
3206 (process_serial_event): Likewise.
3207 * thread-db.c (find_one_thread): Likewise.
3208 (thread_db_thread_handle): Likewise.
3209 * win32-low.c (thread_rec): Likewise.
3210 (child_delete_thread): Likewise.
3211 (win32_thread_alive): Likewise.
3212 (get_child_debug_event): Likewise.
3214 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3216 * linux-mips-low.c (update_watch_registers_callback): Return
3217 void, remove pid_p parameter, don't check for pid.
3218 (mips_insert_point, mips_remove_point): Use for_each_thread.
3220 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3222 * lynx.low (lynx_delete_thread_callback): Remove.
3223 (lynx_mourn): Use for_each_thread.
3225 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3227 * regcache.c (regcache_invalidate_one): Remove.
3228 (regcache_invalidate_pid): use for_each_thread.
3230 2017-11-26 Tom Tromey <tom@tromey.com>
3232 * linux-low.c (linux_create_inferior): Update.
3234 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
3236 * spu-low.c (spu_create_inferior): Fix typo in argument name.
3238 2017-11-24 Alan Hayward <alan.hayward@arm.com>
3240 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
3241 * linux-aarch64-low.c (initialize_low_arch): Call init func.
3242 * linux-aarch64-tdesc-selftest.c: New file.
3243 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
3245 2017-11-24 Alan Hayward <alan.hayward@arm.com>
3247 * configure.srv: Add new file.
3248 * linux-aarch64-low.c (initialize_low_arch): Call init func.
3249 * linux-aarch64-tdesc-selftest.c: New file.
3250 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
3252 2017-11-24 Alan Hayward <alan.hayward@arm.com>
3254 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
3255 * linux-aarch64-low.c (initialize_low_arch): Remove init.
3256 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
3258 2017-11-24 Alan Hayward <alan.hayward@arm.com>
3260 * configure.srv: Add new files.
3261 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
3262 aarch64_linux_read_description.
3263 * linux-aarch64-low.c (aarch64_linux_read_description):
3264 Merge with aarch64_arch_setup.
3265 (aarch64_arch_setup): Call aarch64_linux_read_description.
3266 * linux-aarch64-tdesc.c: New file.
3267 * linux-aarch64-tdesc.h: New file.
3269 2017-11-24 Yao Qi <yao.qi@linaro.org>
3271 * configure.srv: Set $srv_regobj for tic6x-linux.
3272 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
3273 (tic6x_read_description): Move some code to tic6x_arch_setup.
3274 (tic6x_tdesc_test): New function.
3275 (initialize_low_arch): Call selftests::register_test.
3277 2017-11-22 Yao Qi <yao.qi@linaro.org>
3279 * remote-utils.c (prepare_resume_reply): Use memcpy.
3281 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3283 * linux-low.c (kill_one_lwp_callback): Return void, take
3284 argument directly, don't filter on pid.
3285 (linux_kill): Use for_each_thread.
3287 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3289 * linux-low.c (need_step_over_p): Return bool, remove dummy
3291 (linux_resume, proceed_all_lwps): Use find_thread.
3293 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3295 * linux-low.c (resume_status_pending_p): Return bool, remove
3297 (linux_resume): Use find_thread.
3299 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3301 * linux-low.c (struct thread_resume_array): Remove.
3302 (linux_set_resume_request): Return void, take arguments
3304 (linux_resume): Use for_each_thread.
3306 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3308 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
3309 return bool, remove data argument.
3310 (linux_stabilize_threads): Use find_thread.
3312 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3314 * linux-low.c (unsuspend_one_lwp): Remove.
3315 (unsuspend_all_lwps): Use for_each_thread, inline code from
3318 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3320 * gdbthread.h (find_thread): Add overload with ptid_t filter.
3321 * linux-low.c (struct iterate_over_lwps_args): Remove.
3322 (iterate_over_lwps_filter): Remove.
3323 (iterate_over_lwps): Use find_thread.
3325 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3327 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
3328 (linux_handle_new_gdb_connection): Use for_each_thread, inline
3329 code from reset_lwp_ptrace_options_callback.
3331 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3333 * linux-arm-low.c (struct update_registers_data): Remove.
3334 (update_registers_callback): Return void, take arguments
3335 directly, don't check thread's pid.
3336 (arm_insert_point, arm_remove_point): Use for_each_thread.
3338 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3340 * win32-low.c (continue_one_thread): Return void, take argument
3342 (child_continue): Use for_each_thread.
3344 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3346 * win32-i386-low.c (update_debug_registers_callback): Rename
3348 (update_debug_registers): ... this, return void, remove pid_p arg.
3349 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
3351 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
3353 * inferiors.h (struct process_info): Add constructor, initialize
3355 <syscalls_to_catch>: Change type to std::vector<int>.
3356 * inferiors.c (add_process): Allocate process_info with new.
3357 (remove_process): Free process_info with delete.
3358 * linux-low.c (handle_extended_wait): Adjust.
3359 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
3360 * server.c (handle_general_set): Adjust.
3362 2017-11-16 Pedro Alves <palves@redhat.com>
3364 * remote-utils.c (remote_close): Block SIGIO signals instead of
3365 uninstalling the SIGIO handler.
3367 2017-11-16 Alan Hayward <alan.hayward@arm.com>
3369 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
3371 2017-11-16 Yao Qi <yao.qi@linaro.org>
3373 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
3374 (tic6x_store_gregset): Likewise.
3375 (tic6x_usrregs_info): Move it up.
3377 2017-11-15 Alan Hayward <alan.hayward@arm.com>
3379 * Makefile.in: Update arch rules.
3380 * configure.srv: Explicitly mark arch/ files.
3382 2017-11-13 Andreas Schwab <schwab@suse.de>
3384 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
3386 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
3388 2017-11-06 Pedro Alves <palves@redhat.com>
3390 * config.in, configure: Regenerate.
3392 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3394 * target.c (struct thread_search): Remove.
3395 (thread_search_callback): Remove.
3396 (prepare_to_access_memory): Use for_each_thread instead of
3397 find_inferior. Inline code from thread_search_callback.
3399 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3401 * server.c (struct visit_actioned_threads_data): Remove.
3402 (visit_actioned_threads): Change prototype to take arguments
3404 (resume): Use find_thread instead of find_inferior.
3406 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3408 * server.c (queue_stop_reply_callback): Change prototype, return
3410 (find_status_pending_thread_callback): Remove.
3411 (handle_status): Replace find_inferior with find_thread and
3414 2017-10-25 Alan Hayward <alan.hayward@arm.com>
3416 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
3418 (aarch64_store_gregset): Likewise.
3419 (aarch64_fill_fpregset): Likewise.
3420 (aarch64_store_fpregset): Likewise.
3422 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
3424 * gdbthread.h (find_thread, for_each_thread): New functions.
3425 * inferiors.c (thread_of_pid): Remove.
3426 (find_any_thread_of_pid): Use find_thread.
3427 * linux-low.c (num_lwps): Use for_each_thread.
3429 2017-10-17 Yao Qi <yao.qi@linaro.org>
3431 * Makefile.in: Remove one rule.
3432 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
3434 2017-10-17 Yao Qi <yao.qi@linaro.org>
3436 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
3437 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
3439 2017-10-17 Yao Qi <yao.qi@linaro.org>
3441 * configure.srv: Rename arm.o with arch/arm.o.
3443 2017-10-17 Yao Qi <yao.qi@linaro.org>
3445 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
3446 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
3447 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
3448 (arch-i386.o, arch-amd64.o): Remove rules.
3449 (arch/%.o): New rule.
3450 Update POSTCOMPILE and COMPILE.pre.
3451 * configure.ac: Invoke AC_CONFIG_COMMANDS.
3452 * configure: Re-generated.
3453 * configure.srv: Replace arch-i386.o with arch/i386.o.
3454 Replace arch-amd64.o with arch/amd64.o.
3456 2017-10-16 Yao Qi <yao.qi@linaro.org>
3458 * configure: Regenerated.
3460 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3462 * inferiors.h: (struct inferior_list): Remove.
3463 (struct inferior_list_entry); Remove.
3464 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
3465 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
3466 get_first_inferior): Remove.
3467 (for_each_inferior, for_each_inferior_with_data, find_inferior,
3468 find_inferior_id, find_inferior_in_random): Change signature.
3469 * inferiors.c (all_threads): Change type to
3470 std::list<thread_info *>.
3471 (get_thread): Remove macro.
3472 (find_inferior, find_inferior_id): Change signature, implement
3474 (find_inferior_in_random): Change signature, implement using
3475 find_thread_in_random.
3476 (for_each_inferior, for_each_inferior_with_data): Change
3477 signature, implement using for_each_thread.
3478 (add_inferior_to_list, remove_inferior): Remove.
3479 (add_thread, get_first_thread, thread_of_pid,
3480 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
3481 (get_first_inferior, one_inferior_p, clear_inferior_list):
3483 (clear_inferiors, get_thread_process): Update.
3484 * gdbthread.h: Include <list>.
3485 (struct thread_info) <entry>: Remove field.
3487 (all_threads): Change type to std::list<thread_info *>.
3488 (get_first_inferior): Add doc.
3489 (find_thread, for_each_thread, find_thread_in_random): New
3491 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
3492 * linux-arm-low.c (update_registers_callback): Update.
3493 * linux-low.c (second_thread_of_pid_p): Update.
3494 (kill_one_lwp_callback, linux_detach_lwp_callback,
3495 delete_lwp_callback, status_pending_p_callback, same_lwp,
3496 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
3497 iterate_over_lwps, not_stopped_callback,
3498 resume_stopped_resumed_lwps, count_events_callback,
3499 select_singlestep_lwp_callback, select_event_lwp_callback,
3500 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
3501 suspend_and_send_sigstop_callback, wait_for_sigstop,
3502 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
3503 lwp_running, linux_set_resume_request, resume_status_pending_p,
3504 need_step_over_p, start_step_over, linux_resume_one_thread,
3505 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
3506 reset_lwp_ptrace_options_callback): Update.
3507 * linux-mips-low.c (update_watch_registers_callback): Update.
3508 * regcache.c (regcache_invalidate_one, regcache_invalidate):
3510 (free_register_cache_thread_one): Remove.
3511 (regcache_release): Update.
3512 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
3513 handle_qxfer_threads_worker): Update.
3514 (handle_query): Update, use list iterator.
3515 (visit_actioned_threads, handle_pending_status,
3516 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
3517 clear_pending_status_callback, set_pending_status_callback,
3518 find_status_pending_thread_callback, handle_status,
3519 process_serial_event): Update.
3520 * target.c (thread_search_callback): Update.
3521 * thread-db.c (thread_db_get_tls_address): Update.
3522 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
3524 * win32-i386-low.c (update_debug_registers_callback): Update.
3525 * win32-low.c (delete_thread_info, child_delete_thread,
3526 continue_one_thread, suspend_one_thread,
3527 get_child_debug_event): Adjust.
3529 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3531 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
3532 * inferiors.h: Include <list>.
3533 (struct process_info) <entry>: Remove field.
3535 (pid_of): Change macro to function.
3536 (ptid_of, lwpid_of): Remove macro.
3537 (all_processes): Change type to std::list<process_info *>.
3538 (ALL_PROCESSES): Remove macro.
3539 (for_each_process, find_process): New function.
3540 * inferiors.c (all_processes): Change type to
3541 std::list<process_info *>.
3542 (find_thread_process): Adjust.
3543 (add_process): Likewise.
3544 (remove_process): Likewise.
3545 (find_process_pid): Likewise.
3546 (get_first_process): Likewise.
3547 (started_inferior_callback): Remove.
3548 (have_started_inferiors_p): Adjust.
3549 (attached_inferior_callback): Remove.
3550 (have_attached_inferiors_p): Adjust.
3551 * linux-low.c (check_zombie_leaders): Likewise.
3552 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
3553 (x86_linux_update_xmltarget): Adjust.
3554 * server.c (handle_query): Likewise.
3555 (gdb_reattached_process): Remove.
3556 (handle_status): Adjust.
3557 (kill_inferior_callback): Likewise.
3558 (detach_or_kill_inferior): Remove.
3559 (print_started_pid): Likewise.
3560 (print_attached_pid): Likewise.
3561 (detach_or_kill_for_exit): Update.
3562 (process_serial_event): Likewise.
3563 * linux-arm-low.c (arm_new_fork): Likewise.
3565 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3567 * dll.h: Include <list>.
3568 (struct dll_info): Add constructor.
3569 <entry>: Remove field.
3570 (all_dlls): Change type to std::list<dll_info>.
3571 * dll.c: Include <algorithm>.
3572 (get_dll): Remove macro.
3573 (all_dlls): Change type to std::list<dll_info *>.
3574 (free_one_dll): Remove.
3575 (match_dll): Likewise.
3576 (loaded_dll): Adjust.
3577 (unloaded_dll): Adjust to all_dlls type change, use
3578 std::find_if. Inline code from match_dll.
3579 (clear_dlls): Adjust to all_dlls type change.
3580 * server.c (emit_dll_description): Remove.
3581 (handle_qxfer_libraries): Adjust to all_dlls type change,
3582 integrate emit_dll_description's functionality.
3584 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
3586 * linux-low.h (struct linux_target_ops) <delete_process>: New
3588 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
3589 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
3590 (struct linux_target_ops): Add delete_process callback.
3591 * linux-arm-low.c (arm_delete_process): New.
3592 (struct linux_target_ops): Add delete_process callback.
3593 * linux-bfin-low.c (struct linux_target_ops): Likewise.
3594 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
3595 * linux-m32r-low.c (struct linux_target_ops): Likewise.
3596 * linux-mips-low.c (mips_linux_delete_process): New.
3597 (struct linux_target_ops): Add delete_process callback.
3598 * linux-ppc-low.c (struct linux_target_ops): Likewise.
3599 * linux-s390-low.c (struct linux_target_ops): Likewise.
3600 * linux-sh-low.c (struct linux_target_ops): Likewise.
3601 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
3602 * linux-tile-low.c (struct linux_target_ops): Likewise.
3603 * linux-x86-low.c (x86_linux_delete_process): New.
3604 (struct linux_target_ops): Add delete_process callback.
3605 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
3607 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
3609 * linux-aarch64-low.c (the_low_target): Add thread delete
3611 * linux-arm-low.c (arm_delete_thread): New function.
3612 (the_low_target): Add thread delete callback.
3613 * linux-bfin-low.c (the_low_target): Likewise.
3614 * linux-crisv32-low.c (the_low_target): Likewise.
3615 * linux-low.c (delete_lwp): Invoke delete_thread callback if
3617 * linux-low.h (struct linux_target_ops) <delete_thread>: New
3619 * linux-m32r-low.c (the_low_target): Add thread delete callback.
3620 * linux-mips-low.c (mips_linux_delete_thread): New function.
3621 (the_low_target): Add thread delete callback.
3622 * linux-ppc-low.c (the_low_target): Likewise.
3623 * linux-s390-low.c (the_low_target): Likewise.
3624 * linux-sh-low.c (the_low_target): Likewise.
3625 * linux-tic6x-low.c (the_low_target): Likewise.
3626 * linux-tile-low.c (the_low_target): Likewise.
3627 * linux-x86-low.c (the_low_target): Likewise.
3628 * linux-xtensa-low.c (the_low_target): Likewise.
3630 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
3632 * win32-low.c: Include "common-inferior.h".
3634 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3636 * inferiors.c (set_inferior_cwd): New function.
3637 * server.c (handle_general_set): Handle QSetWorkingDir packet.
3638 (handle_query): Inform that QSetWorkingDir is supported.
3639 * win32-low.c (create_process): Pass the inferior's cwd to
3642 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3644 * inferiors.c (current_inferior_cwd): New global variable.
3645 (get_inferior_cwd): New function.
3646 * inferiors.h (struct process_info) <cwd>: New field.
3648 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3650 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
3651 (OBS): Add gdb_tilde_expand.o.
3653 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
3655 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
3656 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
3658 2017-09-29 Pedro Alves <palves@redhat.com>
3660 * ax.c (gdb_parse_agent_expr): Constify.
3661 * ax.h (gdb_parse_agent_expr): Constify.
3662 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
3664 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
3665 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
3666 * remote-utils.h (read_ptid): Constify.
3667 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
3668 (process_point_options, process_serial_event): Constify.
3669 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
3670 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
3671 (cmd_qtbuffer): Constify.
3673 2017-09-29 Pedro Alves <palves@redhat.com>
3675 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
3678 2017-09-29 Pedro Alves <palves@redhat.com>
3680 * linux-low.c (handle_extended_wait): Pass parent thread instead
3681 of process to thread_db_notice_clone.
3682 * linux-low.h (thread_db_notice_clone): Replace parent process
3683 parameter with parent thread parameter.
3684 * thread-db.c (find_one_thread): Add comment.
3685 (thread_db_notice_clone): Replace parent process parameter with
3686 parent thread parameter. Temporarily switch to the parent thread.
3688 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
3690 * gdbthread.h: Include "common-gdbthread.h".
3691 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
3692 "if" when validating the ptid.
3693 * remote-utils.c: Include "gdbthread.h".
3694 (prepare_resume_reply): Use "switch_to_thread".
3695 * target.c (done_accessing_memory): Likewise.
3697 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
3699 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
3700 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
3701 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
3702 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
3703 s390x-gs-linux64-ipa.o to ipa_obj.
3704 * linux-s390-low.c (HWCAP_S390_GS): New define.
3705 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
3707 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
3708 (s390_arch_setup): Check for guarded-storage support and choose
3710 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
3711 init_registers_s390x_gs_linux64.
3712 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
3714 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
3715 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
3717 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
3719 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
3721 2017-09-21 Kevin Buettner <kevinb@redhat.com>
3723 * linux-low.h (struct lwp_info): Add new field, thread_handle.
3724 (thread_db_thread_handle): Declare.
3725 * linux-low.c (linux_target_ops): Initialize thread_handle.
3726 * server.c (handle_qxfer_threads_worker): Add support for
3728 * target.h (struct target_ops): Add new function pointer,
3730 (target_thread_handle): Define.
3731 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
3733 (thread_db_thread_handle): New function.
3735 2017-09-21 Kevin Buettner <kevinb@redhat.com>
3737 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
3738 * linux-low.h (thread_db_notice_clone): Declare.
3739 * thread-db.c (thread_db_notice_clone): New function.
3741 2017-09-21 Pedro Alves <palves@redhat.com>
3743 * server.c (gdb_read_memory, handle_status, process_serial_event)
3744 (handle_serial_event, handle_target_event): Adjust to
3745 set_desired_thread prototype change.
3746 * target.c (set_desired_thread): Remove 'use_general' parameter
3748 * target.h (set_desired_thread): Remove 'use_general' parameter.
3750 2017-09-20 Tom Tromey <tom@tromey.com>
3752 * target.c (target_terminal::terminal_state): Define.
3753 (target_terminal::init): Rename from target_terminal_init.
3754 (target_terminal::inferior): Rename from
3755 target_terminal_inferior.
3756 (target_terminal::ours): Rename from target_terminal_ours.
3757 (target_terminal::ours_for_output, target_terminal::info): New.
3759 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3761 * server.c (accumulate_file_name_length): Remove.
3762 (emit_dll_description): Adjust to std::string change.
3763 (handle_qxfer_libraries): Use std::string to hold document.
3765 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3767 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
3768 return type of xml_escape_text.
3769 * server.c (emit_dll_description): Likewise.
3771 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3773 * server.c (captured_main): Accept argument for --selftest.
3774 Update run_tests call.
3775 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
3776 when registering selftests.
3778 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
3780 * regcache.c (get_thread_regcache): Update code to use "std::vector"
3781 instead of "VEC" for "target_desc.reg_defs".
3782 (regcache_cpy): Likewise.
3783 (registers_to_string): Likewise.
3784 (registers_from_string): Likewise.
3785 (find_regno): Likewise.
3786 (supply_regblock): Likewise.
3787 (regcache_raw_read_unsigned): Likewise.
3788 * tdesc.c (init_target_desc): Likewise.
3789 (tdesc_create_reg): Likewise.
3790 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
3791 (struct target_desc) <reg_defs>: Convert to "std::vector".
3792 (target_desc): Do not initialize "reg_defs".
3793 (~target_desc): Update code to use "std::vector" instead of "VEC"
3794 for "target_desc.reg_defs".
3795 (operator==): Likewise.
3797 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3799 * inferiors.h (thread_to_gdb_id): Remove.
3800 * inferiors.c (thread_to_gdb_id): Remove.
3801 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
3802 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
3803 lynx_store_registers, lynx_read_memory, lynx_write_memory):
3805 * nto-low.c (nto_fetch_registers, nto_store_registers,
3806 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
3808 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3810 * inferiors.h (gdb_id_to_thread_id): Remove.
3811 * inferiors.c (gdb_id_to_thread_id): Remove.
3812 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
3813 removal. Move pid declaration closer to where it's used.
3815 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3817 * server.c (handle_detach): New function.
3818 (process_serial_event): Move code out, call handle_detach.
3820 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3822 * server.c (require_running): Rename to ...
3823 (require_running_or_return): ... this ...
3824 (require_running_or_break): ... and this.
3825 (handle_query, process_serial_event): Adjust.
3827 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3829 * linux-low.c (linux_set_resume_request): Remove unused
3832 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3834 * server.c (first_thread_of): Remove.
3835 (process_serial_event): Replace usage of first_thread_of with
3836 find_any_thread_of_pid.
3837 * tracepoint.c (same_process_p): Remove.
3838 (gdb_agent_about_to_close): Replace usage of same_process_p with
3839 find_any_thread_of_pid.
3840 * linux-x86-low.c (same_process_callback): Remove.
3841 (x86_arch_setup_process_callback): Replace usage of
3842 same_process_callback with find_any_thread_of_pid.
3843 * thread-db.c (any_thread_of): Remove.
3844 (switch_to_process): Replace usage of any_thread_of with
3845 find_any_thread_of_pid.
3846 * inferiors.c (thread_pid_matches_callback): Remove.
3847 (find_thread_process): Adjust to use find_any_thread_of_pid.
3849 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
3851 * regcache.c (get_thread_regcache): Guard calls to "memset"
3854 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
3856 * linux-low.c (handle_extended_wait): Use
3857 "allocate_target_description" instead of "XNEW".
3858 * linux-x86-low.c (initialize_low_arch): Likewise.
3860 2017-09-05 Yao Qi <yao.qi@linaro.org>
3862 * configure.srv (srv_i386_regobj): Remove.
3863 (srv_amd64_regobj): Remove.
3864 (srv_regobj): Set it to "" for x86 non-linux targets.
3865 * linux-x86-tdesc.c (i386_linux_read_description):
3866 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
3867 (init_registers_i386): Remove the declaration.
3868 (tdesc_i386): Remove the declaration.
3869 (lynx_i386_arch_setup): Call i386_create_target_description.
3870 * nto-x86-low.c: Likewise.
3871 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
3872 [!__x86_64__]: include arch/i386.h.
3873 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
3875 2017-09-05 Yao Qi <yao.qi@linaro.org>
3877 * configure.srv (srv_amd64_linux_xmlfiles): Remove
3878 i386/amd64-XXX-linux from it.
3880 2017-09-05 Yao Qi <yao.qi@linaro.org>
3882 * configure.srv: Empty srv_amd64_linux_regobj if $development is
3884 (ipa_amd64_linux_regobj): Remove.
3885 (ipa_x32_linux_regobj): Remove.
3887 2017-09-05 Yao Qi <yao.qi@linaro.org>
3889 * Makefile.in (arch-amd64.o): New rule.
3890 * configure.srv: Append arch-amd64.o.
3891 * linux-amd64-ipa.c: Include common/x86-xstate.h.
3892 (get_ipa_tdesc): Call amd64_linux_read_description.
3893 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
3894 and init_registers_amd64_XXX.
3895 * linux-x86-low.c (x86_linux_read_description): Call
3896 amd64_linux_read_description.
3897 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
3898 (initialize_low_arch): Don't call init_registers_x32_XXX and
3899 init_registers_amd64_XXX.
3900 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
3901 and tdesc_amd64_XXX.
3902 [__x86_64__] (amd64_tdesc_test): New function.
3903 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
3904 and init_registers_amd64_XXX.
3905 * linux-x86-tdesc.c: Include arch/amd64.h.
3906 (xcr0_to_tdesc_idx): New function.
3907 (i386_linux_read_description): New function.
3908 (amd64_get_ipa_tdesc_idx): New function.
3909 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
3910 (amd64_get_ipa_tdesc): Declare.
3912 2017-09-05 Yao Qi <yao.qi@linaro.org>
3914 * configure.srv (srv_i386_linux_xmlfiles): Remove
3915 i386/i386-XXX-linux.xml from it.
3917 2017-09-05 Yao Qi <yao.qi@linaro.org>
3919 * configure.srv: Set srv_i386_linux_regobj empty if $development
3921 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
3922 initialize_low_tdesc.
3923 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
3924 with #if initialize_low_tdesc.
3925 * linux-x86-tdesc-selftest.c: New file.
3926 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
3928 2017-09-05 Yao Qi <yao.qi@linaro.org>
3930 * Makefile.in (arch-i386.o): New rule.
3931 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
3932 (x86_64-*-linux*): Likewise.
3933 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
3934 include arch/i386.h.
3935 (i386_linux_read_description): Remove code and call
3936 i386_create_target_description.
3937 * tdesc.c (allocate_target_description): New function.
3938 * tdesc.h (set_tdesc_architecture): Remove declaration.
3939 (set_tdesc_osabi): Likewise.
3941 2017-09-05 Yao Qi <yao.qi@linaro.org>
3943 * linux-x86-tdesc.c: Don't include <inttypes.h>.
3944 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
3945 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
3947 * server.c (get_features_xml): Call tdesc_get_features_xml.
3948 * tdesc.c (set_tdesc_architecture): New function.
3949 (set_tdesc_osabi): New function.
3950 (tdesc_get_features_xml): New function.
3951 (tdesc_create_feature): Add an argument.
3952 * tdesc.h (struct target_desc) <features>: New field.
3953 <arch, osabi>: New field.
3954 (~target_desc): xfree features, arch, and osabi.
3955 (target_desc::oerator==): Don't compare .xmltarget.
3956 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
3957 (set_tdesc_osabi): Likewise.
3958 (tdesc_get_features_xml): Likewise.
3960 2017-09-05 Yao Qi <yao.qi@linaro.org>
3962 * linux-x86-tdesc.c: Include selftest.h.
3963 (i386_tdesc_test): New function.
3964 (initialize_low_tdesc): Call selftests::register_test.
3965 * tdesc.h: Include regdef.h.
3966 (target_desc): Override operator == and !=.
3968 2017-09-05 Yao Qi <yao.qi@linaro.org>
3970 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
3971 (ipa_obj): Likewise.
3972 * linux-i386-ipa.c: Include common/x86-xstate.h
3973 (get_ipa_tdesc): Call i386_linux_read_description.
3974 (initialize_low_tracepoint): Don't call init_registers_XXX
3975 functions, call initialize_low_tdesc instead.
3976 * linux-x86-low.c (x86_linux_read_description): Call
3977 i386_linux_read_description.
3978 (initialize_low_arch): Don't call init_registers_i386_XXX
3979 functions, call initialize_low_tdesc.
3980 * linux-x86-tdesc.c: New file.
3981 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
3982 (i386_get_ipa_tdesc_idx): Declare.
3983 (i386_get_ipa_tdesc): Declare.
3984 (initialize_low_tdesc): Declare.
3986 2017-09-05 Yao Qi <yao.qi@linaro.org>
3988 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
3991 2017-09-05 Yao Qi <yao.qi@linaro.org>
3993 * Makefile.in (IPA_OBJS): Add vec-ipa.o
3994 * regcache.c (get_thread_regcache): Use VEC_length.
3995 (init_register_cache): Likewise.
3996 (regcache_cpy): Likewise.
3997 (registers_to_string): Iterate reg_defs via VEC_iterate.
3998 (find_regno): Likewise.
3999 (find_register_by_number): Use VEC_index.
4000 (register_size): Call find_register_by_number.
4001 (register_data): Call find_register_by_number.
4002 (supply_regblock): Use VEC_length.
4003 (regcache_raw_read_unsigned): Likewise.
4004 * tdesc.c (init_target_desc): Iterate reg_defs via
4006 (default_description): Update initializer.
4007 (copy_target_description): Don't update field num_registers.
4008 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
4009 <num_registers>: Remove.
4011 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
4013 * Makefile.in (.SECONDARY): Define target.
4015 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
4017 * linux-low.c (linux_wait_1): Adjust.
4018 * server.c (queue_stop_reply_callback): Adjust.
4020 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
4022 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
4023 QEnvironmentUnset and QEnvironmentReset packets.
4024 (handle_query): Inform remote that QEnvironmentHexEncoded,
4025 QEnvironmentUnset and QEnvironmentReset are supported.
4027 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
4029 * inferiors.h (inferior_target_data): Rename to ...
4030 (thread_target_data): ... this.
4031 (inferior_regcache_data): Rename to ...
4032 (thread_regcache_data): ... this.
4033 (set_inferior_regcache_data): Rename to ...
4034 (set_thread_regcache_data): ... this.
4035 * inferiors.c (inferior_target_data): Rename to ...
4036 (thread_target_data): ... this.
4037 (inferior_regcache_data): Rename to ...
4038 (thread_regcache_data): ... this.
4039 (set_inferior_regcache_data): Rename to ...
4040 (set_thread_regcache_data): ... this.
4041 (free_one_thread): Update.
4042 * linux-low.h (get_thread_lwp): Update.
4043 * regcache.c (get_thread_regcache): Update.
4044 (regcache_invalidate_thread): Update.
4045 (free_register_cache_thread): Update.
4046 * win32-i386-low.c (update_debug_registers_callback): Update.
4047 (win32_get_current_dr): Update.
4048 * win32-low.c (thread_rec): Update.
4049 (delete_thread_info): Update.
4050 (continue_one_thread): Update.
4051 (suspend_one_thread): Update.
4053 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
4055 * inferiors.c (set_inferior_target_data): Remove.
4056 * inferiors.h (set_inferior_target_data): Remove.
4058 2017-08-18 Yao Qi <yao.qi@linaro.org>
4060 * Makefile.in (OBS): Add selftest.o.
4061 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
4062 * configure, config.in: Re-generated.
4063 * server.c: Include common/sefltest.h.
4064 (captured_main): Handle option --selftest.
4066 2017-08-09 Yao Qi <yao.qi@linaro.org>
4068 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
4069 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
4070 i386-avx-mpx.o and i386-mmx.o.
4071 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
4072 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
4073 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
4074 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
4075 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
4076 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
4077 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
4078 i386/amd64-avx-mpx.xml.
4080 2017-08-09 Yao Qi <yao.qi@linaro.org>
4082 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
4083 and x32-avx-avx512.o.
4084 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
4085 i386/x32-avx-avx512.xml.
4087 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
4089 * tracepoint.h (enum class fast_tpoint_collect_result): New
4091 (fast_tracepoint_collecting): Change return type to
4092 fast_tpoint_collect_result.
4093 * tracepoint.c (fast_tracepoint_collecting): Likewise.
4094 * linux-low.h: Include tracepoint.h.
4095 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
4096 fast_tpoint_collect_result.
4097 * linux-low.c (handle_tracepoints): Adjust.
4098 (linux_fast_tracepoint_collecting): Change return type to
4099 fast_tpoint_collect_result.
4100 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
4101 linux_wait_1, stuck_in_jump_pad_callback,
4102 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
4103 proceed_one_lwp): Adjust to type change.
4105 2017-07-10 Yao Qi <yao.qi@linaro.org>
4107 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
4109 2017-06-29 Yao Qi <yao.qi@linaro.org>
4111 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
4113 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
4115 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
4117 * Makefile.in (IPA_OBJS): Sort and format one item per line.
4119 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
4121 * linux-low.c (linux_create_inferior): Adjust code to access the
4122 environment information via 'gdb_environ' class.
4123 * lynx-low.c (lynx_create_inferior): Likewise.
4124 * server.c (our_environ): Make it an instance of 'gdb_environ'.
4125 (get_environ): Return a pointer to 'our_environ'.
4126 (captured_main): Initialize 'our_environ'.
4127 * server.h (get_environ): Adjust prototype.
4128 * spu-low.c (spu_create_inferior): Adjust code to access the
4129 environment information via 'gdb_environ' class.
4131 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4133 * linux-low.c (linux_read_memory, linux_write_memory): Remove
4134 usage of "register" keyword.
4136 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4138 * configure: Re-generate.
4140 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4142 * configure: Re-generate.
4144 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4146 * Makefile.in (COMPILE.pre): Add "-x c++".
4148 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
4150 * fork-child.c: Conditionally include <signal.h>.
4152 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4154 * server.c (handle_general_set): Handle new packet
4155 "QStartupWithShell".
4156 (handle_query): Add "QStartupWithShell" to the list of supported
4158 (gdbserver_usage): Add help text explaining the
4159 new "--startup-with-shell" and "--no-startup-with-shell" CLI
4161 (captured_main): Recognize and act upon the presence of the new
4164 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4165 Pedro Alves <palves@redhat.com>
4167 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
4168 * configure: Regenerate.
4169 * configure.srv (srv_linux_obj): Add "fork-child.o" and
4171 (i[34567]86-*-lynxos*): Likewise.
4172 (spu*-*-*): Likewise.
4173 * fork-child.c: New file.
4174 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
4176 (linux_ptrace_fun): New function.
4177 (linux_create_inferior): Adjust function prototype to reflect
4178 change on "target.h". Adjust function code to use
4180 (linux_request_interrupt): Delete "signal_pid".
4181 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
4182 (lynx_ptrace_fun): New function.
4183 (lynx_create_inferior): Adjust function prototype to reflect
4184 change on "target.h". Adjust function code to use
4186 * nto-low.c (nto_create_inferior): Adjust function prototype and
4187 code to reflect change on "target.h". Update comments.
4188 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
4189 "common-terminal.h" and "environ.h".
4190 (terminal_fd): Moved to fork-child.c.
4191 (old_foreground_pgrp): Likewise.
4192 (restore_old_foreground_pgrp): Likewise.
4193 (last_status): Make it global.
4194 (last_ptid): Likewise.
4195 (our_environ): New variable.
4196 (startup_with_shell): Likewise.
4197 (program_name): Likewise.
4198 (program_argv): Rename to...
4199 (program_args): ...this.
4200 (wrapper_argv): New variable.
4201 (start_inferior): Delete function.
4202 (get_exec_wrapper): New function.
4203 (get_exec_file): Likewise.
4204 (get_environ): Likewise.
4205 (prefork_hook): Likewise.
4206 (post_fork_inferior): Likewise.
4207 (postfork_hook): Likewise.
4208 (postfork_child_hook): Likewise.
4209 (handle_v_run): Update code to deal with arguments coming from the
4210 remote host. Update calls from "start_inferior" to
4212 (captured_main): Likewise. Initialize environment variable. Call
4214 * server.h (post_fork_inferior): New prototype.
4215 (get_environ): Likewise.
4216 (last_status): Declare.
4217 (last_ptid): Likewise.
4218 (signal_pid): Likewise.
4219 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
4220 (spu_ptrace_fun): New function.
4221 (spu_create_inferior): Adjust function prototype to reflect change
4222 on "target.h". Adjust function code to use "fork_inferior".
4223 * target.c (target_terminal_init): New function.
4224 (target_terminal_inferior): Likewise.
4225 (target_terminal_ours): Likewise.
4226 * target.h: Include <vector>.
4227 (struct target_ops) <create_inferior>: Update prototype.
4228 (create_inferior): Update macro.
4229 * utils.c (gdb_flush_out_err): New function.
4230 * win32-low.c (win32_create_inferior): Adjust function prototype
4231 and code to reflect change on "target.h".
4233 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4235 * inferiors.c (switch_to_thread): New function.
4237 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4239 * Makefile.in (SFILE): Add "common/job-control.c".
4240 (OBS): Add "job-control.o".
4242 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
4244 * Makefile: Remove "@host_makefile_frag@".
4246 2017-05-05 Pedro Alves <palves@redhat.com>
4248 * configure: Regenerate.
4250 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
4252 * configure: Regenerate.
4254 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
4256 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
4257 software_single_step change of return type to
4258 std::vector<CORE_ADDR>.
4259 * linux-low.c (install_software_single_step_breakpoints):
4261 * linux-low.h (install_software_single_step_breakpoints):
4264 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
4266 * remote-utils.c: Include "gdb_termios.h" instead of
4268 * terminal.h: Delete file.
4270 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
4272 * server.c: Include <vector>.
4273 <program_argv, wrapper_argv>: Convert to std::vector.
4274 (start_inferior): Rewrite function to use C++.
4275 (handle_v_run): Likewise. Update code that calculates the argv
4276 based on the vRun packet; use C++.
4277 (captured_main): Likewise.
4279 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
4281 * server.c (handle_v_cont): Initialize thread_resume::thread
4284 2017-04-05 Pedro Alves <palves@redhat.com>
4286 * configure: Regenerate.
4288 2017-04-05 Pedro Alves <palves@redhat.com>
4290 * gdbreplay.c (sync_error): Constify.
4291 * linux-x86-low.c (push_opcode): Constify.
4293 2017-04-05 Pedro Alves <palves@redhat.com>
4295 * win32-low.c (get_child_debug_event)
4296 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
4297 Report TARGET_WAITKIND_SPURIOUS instead.
4299 2017-04-05 Pedro Alves <palves@redhat.com>
4301 * remote-utils.c (remote_prepare, remote_open): Constify.
4302 * remote-utils.h (remote_prepare, remote_open): Constify.
4303 * server.c (captured_main): Constify 'port' handling.
4305 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
4307 * Makefile.in (clean): Clear .deps.
4309 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
4311 * .gitignore: Remove generated files, replace with wildcard.
4312 * (clean): Replace removal of generated files with wildcard.
4313 (version.c): Replace with...
4314 (version-generated.c): ...this.
4315 (xml-builtin.c): Replace with...
4316 (xml-builtin-generated.c): ...this.
4317 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
4318 (%.c: *regformats*): Replace with...
4319 (%-generated.c: *regformats*): ...this.
4321 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
4323 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
4324 (xtensa_fill_gregset): Call collect_register_by_name for
4326 (xtensa_store_gregset): Call supply_register_by_name for
4329 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
4331 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
4332 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
4333 (xtensa_store_gregset): Call supply_register for all registers in
4334 a0_regnum..a0_regnum + C0_NREGS range.
4336 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4338 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
4339 (ax-ipa.o: ax.c): Remove.
4340 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
4341 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
4342 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
4343 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
4344 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
4346 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4348 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
4349 (print-utils-ipa.o: ../common/print-utils.c): Remove.
4350 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
4351 (errors-ipa.o: ../common/errors.c): Remove.
4352 (format-ipa.o: ../common/format.c): Remove.
4353 (common-utils-ipa.o: ../common/common-utils.c): Remove.
4355 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4357 * Makefile.in (%-ipa.o: %.c): New rule.
4358 (tracepoint-ipa.o: tracepoint.c): Remove.
4359 (utils-ipa.o: utils.c): Remove.
4360 (remote-utils-ipa.o: remote-utils.c): Remove.
4361 (regcache-ipa.o: regcache.c): Remove.
4362 (i386-linux-ipa.o: i386-linux.c): Remove.
4363 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
4364 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
4365 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
4366 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
4367 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
4368 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
4369 (amd64-linux-ipa.o: amd64-linux.c): Remove.
4370 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
4371 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
4372 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
4373 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
4374 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
4375 (aarch64-ipa.o: aarch64.c): Remove.
4376 (s390-linux32-ipa.o: s390-linux32.c): Remove.
4377 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
4378 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
4379 (s390-linux64-ipa.o: s390-linux64.c): Remove.
4380 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
4381 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
4382 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
4383 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
4384 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
4385 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
4386 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
4387 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
4388 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
4389 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
4390 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
4391 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
4392 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
4393 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
4394 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
4395 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
4396 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
4397 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
4398 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
4399 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
4400 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
4401 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
4402 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
4403 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
4404 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
4405 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
4406 (tdesc-ipa.o: tdesc.c): Remove.
4407 (x32-linux-ipa.o: x32-linux.c): Remove.
4408 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
4409 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
4411 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4413 * Makefile.in (%.o: ../arch/%.c): New rule.
4414 (arm.o: ../arch/arm.c): Remove.
4415 (arm-linux.o: ../arch/arm-linux.c): Remove.
4416 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
4417 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
4419 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4421 * Makefile.in (%.o: ../nat/%.c): New rule.
4422 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
4423 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
4424 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
4425 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
4426 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
4427 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
4428 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
4429 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
4430 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
4431 (linux-personality.o: ../nat/linux-personality.c): Remove.
4432 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
4433 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
4434 (x86-linux.o: ../nat/x86-linux.c): Remove.
4435 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
4436 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
4438 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4440 * Makefile.in (%.o: ../common/%.c): New rule.
4441 (signals.o: ../common/signals.c): Remove.
4442 (print-utils.o: ../common/print-utils.c): Remove.
4443 (rsp-low.o: ../common/rsp-low.c): Remove.
4444 (common-utils.o: ../common/common-utils.c): Remove.
4445 (posix-strerror.o: ../common/posix-strerror.c): Remove.
4446 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
4447 (vec.o: ../common/vec.c): Remove.
4448 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
4449 (xml-utils.o: ../common/xml-utils.c): Remove.
4450 (ptid.o: ../common/ptid.c): Remove.
4451 (buffer.o: ../common/buffer.c): Remove.
4452 (format.o: ../common/format.c): Remove.
4453 (filestuff.o: ../common/filestuff.c): Remove.
4454 (agent.o: ../common/agent.c): Remove.
4455 (errors.o: ../common/errors.c): Remove.
4456 (environ.o: ../common/environ.c): Remove.
4457 (common-debug.o: ../common/common-debug.c): Remove.
4458 (cleanups.o: ../common/cleanups.c): Remove.
4459 (common-exceptions.o: ../common/common-exceptions.c): Remove.
4460 (fileio.o: ../common/fileio.c): Remove.
4461 (common-regcache.o: ../common/common-regcache.c): Remove.
4462 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
4463 (new-op.o: ../common/new-op.c): Remove.
4464 (btrace-common.o: ../common/btrace-common.c): Remove.
4466 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4468 * Makefile.in (%.o: ../target/%.c): New rule.
4469 (waitstatus.o: ../target/waitstatus.c): Remove.
4471 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4474 (%.c: ../regformats/%.dat,
4475 (%.c: ../regformats/arm/%.dat,
4476 (%.c: ../regformats/i386/%.dat,
4477 (%.c: ../regformats/rs6000/%.dat): New rules.
4478 (aarch64.c): Remove.
4479 (reg-arm.c): Remove.
4480 (arm-with-iwmmxt.c): Remove.
4481 (arm-with-vfpv2.c): Remove.
4482 (arm-with-vfpv3.c): Remove.
4483 (arm-with-neon.c): Remove.
4484 (reg-bfin.c): Remove.
4485 (reg-cris.c): Remove.
4486 (reg-crisv32.c): Remove.
4488 (i386-linux.c): Remove.
4489 (i386-avx.c): Remove.
4490 (i386-avx-linux.c): Remove.
4491 (i386-avx-avx512.c): Remove.
4492 (i386-avx-avx512-linux.c): Remove.
4493 (i386-mpx.c): Remove.
4494 (i386-mpx-linux.c): Remove.
4495 (i386-avx-mpx-avx512-pku.c): Remove.
4496 (i386-avx-mpx-avx512-pku-linux.c): Remove.
4497 (i386-avx-mpx.c): Remove.
4498 (i386-avx-mpx-linux.c): Remove.
4499 (i386-mmx.c): Remove.
4500 (i386-mmx-linux.c): Remove.
4501 (reg-ia64.c): Remove.
4502 (reg-m32r.c): Remove.
4503 (reg-m68k.c): Remove.
4505 (mips-linux.c): Remove.
4506 (mips-dsp-linux.c): Remove.
4507 (mips64-linux.c): Remove.
4508 (mips64-dsp-linux.c): Remove.
4509 (nios2-linux.c): Remove.
4510 (powerpc-32.c): Remove.
4511 (powerpc-32l.c): Remove.
4512 (powerpc-altivec32l.c): Remove.
4513 (powerpc-cell32l.c): Remove.
4514 (powerpc-vsx32l.c): Remove.
4515 (powerpc-isa205-32l.c): Remove.
4516 (powerpc-isa205-altivec32l.c): Remove.
4517 (powerpc-isa205-vsx32l.c): Remove.
4518 (powerpc-e500l.c): Remove.
4519 (powerpc-64l.c): Remove.
4520 (powerpc-altivec64l.c): Remove.
4521 (powerpc-cell64l.c): Remove.
4522 (powerpc-vsx64l.c): Remove.
4523 (powerpc-isa205-64l.c): Remove.
4524 (powerpc-isa205-altivec64l.c): Remove.
4525 (powerpc-isa205-vsx64l.c): Remove.
4526 (s390-linux32.c): Remove.
4527 (s390-linux32v1.c): Remove.
4528 (s390-linux32v2.c): Remove.
4529 (s390-linux64.c): Remove.
4530 (s390-linux64v1.c): Remove.
4531 (s390-linux64v2.c): Remove.
4532 (s390-te-linux64.c): Remove.
4533 (s390-vx-linux64.c): Remove.
4534 (s390-tevx-linux64.c): Remove.
4535 (s390x-linux64.c): Remove.
4536 (s390x-linux64v1.c): Remove.
4537 (s390x-linux64v2.c): Remove.
4538 (s390x-te-linux64.c): Remove.
4539 (s390x-vx-linux64.c): Remove.
4540 (s390x-tevx-linux64.c): Remove.
4541 (tic6x-c64xp-linux.c): Remove.
4542 (tic6x-c64x-linux.c): Remove.
4543 (tic6x-c62x-linux.c): Remove.
4545 (reg-sparc64.c): Remove.
4546 (reg-spu.c): Remove.
4548 (amd64-linux.c): Remove.
4549 (amd64-avx.c): Remove.
4550 (amd64-avx-linux.c): Remove.
4551 (amd64-avx-avx512.c): Remove.
4552 (amd64-avx-avx512-linux.c): Remove.
4553 (amd64-mpx.c): Remove.
4554 (amd64-mpx-linux.c): Remove.
4555 (amd64-avx-mpx-avx512-pku.c): Remove.
4556 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
4557 (amd64-avx-mpx.c): Remove.
4558 (amd64-avx-mpx-linux.c): Remove.
4560 (x32-linux.c): Remove.
4561 (x32-avx.c): Remove.
4562 (x32-avx-linux.c): Remove.
4563 (x32-avx-avx512.c): Remove.
4564 (x32-avx-avx512-linux.c): Remove.
4565 (reg-xtensa.c): Remove.
4566 (reg-tilegx.c): Remove.
4567 (reg-tilegx32.c): Remove.
4569 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
4571 * Makefile.in (SFILES): Add "common/environ.c".
4572 (OBJS): Add "common/environ.h".
4574 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
4576 * configure.ac: Check if the fs_base and gs_base members of
4577 `struct user_regs_struct' exist.
4578 * config.in: Regenerated.
4579 * configure: Likewise.
4581 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
4583 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
4585 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
4586 (get_next_pcs_syscall_next_pc): Likewise.
4588 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
4590 * win32-i386-low.c: Fix incorrect reference to a couple source files.
4591 * nto-x86-low.c: Likewise.
4593 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
4595 * Makefile.in: Include disable-implicit-rules.mk.
4597 2016-11-23 Pedro Alves <palves@redhat.com>
4599 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
4600 (debug_vprintf): Use std::chrono::steady_clock instead of
4601 gettimeofday. Use '.' instead of ':'.
4602 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
4603 (get_timestamp): Use std::chrono::steady_clock instead of
4606 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
4608 * Makefile.in: Fix whitespace formatting.
4610 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
4612 * Makefile.in (SFILES, OBS): Flatten list and order
4615 2016-11-23 Pedro Alves <palves@redhat.com>
4617 * event-loop.c (handle_file_event): Use warning.
4618 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
4619 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
4622 2016-11-23 Pedro Alves <palves@redhat.com>
4624 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
4626 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
4627 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
4628 debug_printf and debug_flush for debug output.
4629 * server.c (handle_general_set): Likewise.
4630 * thread-db.c (try_thread_db_load): Use debug_printf for debug
4633 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
4635 * Makefile.in (.c.o): Replace rule with ...
4636 (%.o: %.c): ... this one.
4638 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
4640 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
4641 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
4643 * configure.ac: Remove checks for the make program.
4644 * configure: Re-generate.
4646 2016-10-28 Pedro Alves <palves@redhat.com>
4648 * Makefile.in (CXX_DIALECT): Get from configure.
4649 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
4650 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
4651 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
4652 * config.in: Regenerate.
4653 * configure: Regenerate.
4655 2016-10-27 Yao Qi <yao.qi@linaro.org>
4657 * linux-low.c (linux_supports_range_stepping): Return true if
4658 can_software_single_step return true.
4660 2016-10-27 Yao Qi <yao.qi@linaro.org>
4662 * inferiors.c (find_inferior_in_random): New function.
4663 * inferiors.h (find_inferior_in_random): Declare.
4664 * linux-low.c (linux_wait_for_event_filtered): Call
4665 find_inferior_in_random instead of find_inferior.
4667 2016-10-27 Yao Qi <yao.qi@linaro.org>
4669 * linux-low.c (linux_wait_1): If single-step breakpoints are
4670 inserted, remove them.
4672 2016-10-26 Pedro Alves <palves@redhat.com>
4674 * linux-low.c (handle_extended_wait): Link parent/child fork
4676 (linux_wait_1): Unlink them.
4677 (linux_set_resume_request): Ignore resume requests for
4678 already-resumed and unhandled fork child threads.
4679 * linux-low.h (struct lwp_info) <fork_relative>: New field.
4680 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
4682 (handle_v_requests) <vCont>: Don't call require_running.
4683 * server.h (in_queued_stop_replies): New declaration.
4685 2016-10-24 Yao Qi <yao.qi@linaro.org>
4688 * linux-aarch64-low.c (append_insns): Cast the return value to
4691 2016-10-10 Yao Qi <yao.qi@linaro.org>
4693 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
4695 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
4697 * target.c (target_supports_multi_process): New function, moved
4699 * target.h (target_supports_multi_process): ... here. Remove
4702 2016-10-05 Tom Tromey <tom@tromey.com>
4705 * tracepoint.c (handle_tracepoint_bkpts): Check
4706 ipa_error_tracepoint, not ipa_stopping_tracepoint.
4708 2016-10-05 Yao Qi <yao.qi@linaro.org>
4710 * configure.srv: Update the path of arm-*.xml files.
4712 2016-10-05 Terry Guo <terry.guo@arm.com>
4713 Yao Qi <yao.qi@linaro.org>
4715 * Makefile.in: Adjust the path of rules.
4716 * configure.srv: Update the path of xml files.
4717 * regformats/arm-with-iwmmxt.dat: Regenerated.
4718 * regformats/arm-with-neon.dat: Likewise.
4719 * regformats/arm-with-vfpv2.dat: Likewise.
4720 * regformats/arm-with-vfpv3.dat Likewise.
4722 2016-09-30 Yao Qi <yao.qi@linaro.org>
4725 * target.c (target_stop_and_wait): Don't call
4726 target_continue_no_signal, use resume_stop instead.
4728 2016-09-26 Yao Qi <yao.qi@linaro.org>
4730 * linux-low.c (linux_wait_1): Call debug_exit.
4732 2016-09-23 Pedro Alves <palves@redhat.com>
4734 * Makefile.in (SFILES): Add common/new-op.c.
4735 (OBS): Add common/new-op.o.
4736 (new-op.o): New rule.
4738 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
4740 * .gitinore: Ignore more files.
4742 2016-09-21 Yao Qi <yao.qi@linaro.org>
4744 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
4747 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
4749 * server.c (start_inferior): Call target_mourn_inferior instead of
4750 mourn_inferior; pass ptid_t argument to it.
4752 (handle_target_event): Likewise.
4753 * target.c (target_mourn_inferior): New function.
4754 * target.h (mourn_inferior): Delete macro.
4756 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
4758 * linux-low.c (lwp_is_stepping): New function.
4760 2016-09-06 Carl Love <cel@us.ibm.com>
4762 * server.c (start_inferior): Fixed comment, requested comment change
4763 didn't get updated correctly. Removed reference to ptrace () call as
4764 it is only true on Linux systems.
4766 2016-09-06 Carl Love <cel@us.ibm.com>
4768 * server.c (start_inferior): Do not call
4769 function target_post_create_inferior () if the
4770 inferior process has already exited.
4772 2016-09-05 Pedro Alves <palves@redhat.com>
4774 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
4775 (COMPILE.pre, CC_LD): Use CXX directly.
4776 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
4777 * acinclude.m4: Don't include build-with-cxx.m4.
4778 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
4779 * configure: Regenerate.
4781 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
4784 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
4785 call writing data to own_buf.
4787 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
4789 * target.c (mywait): Call target_wait instead of
4791 (target_wait): New function.
4793 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
4795 * server.c (start_inferior): New variable 'ptid'. Replace calls
4796 to the_target->resume by target_continue{,_no_signal}, depending
4798 * target.c (target_stop_and_wait): Call target_continue_no_signal
4799 instead of the_target->resume.
4800 (target_continue): New function.
4802 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
4804 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
4806 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
4809 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
4811 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
4812 * linux-arm-low.c (ps_get_thread_area): Likewise.
4813 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
4814 * linux-m68k-low.c (ps_get_thread_area): Likewise.
4815 * linux-mips-low.c (ps_get_thread_area): Likewise.
4816 * linux-nios2-low.c (ps_get_thread_area): Likewise.
4817 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
4818 * linux-x86-low.c (ps_get_thread_area): Likewise.
4819 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
4821 2016-08-19 Pedro Alves <palves@redhat.com>
4823 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
4825 2016-08-19 Pedro Alves <palves@redhat.com>
4827 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
4828 comment. Use memcpy instead of casting through unsigned long.
4830 2016-08-19 Pedro Alves <palves@redhat.com>
4832 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
4833 allocating around 0x80000000.
4835 2016-08-19 Pedro Alves <palves@redhat.com>
4838 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
4839 (x32-avx512-linux-ipa.o): New rules.
4840 * configure.ac (x86_64-*-linux*): New x32 check.
4841 * configure.srv (ipa_x32_linux_regobj): New.
4842 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
4843 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
4845 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
4847 * configure: Regenerate.
4849 2016-08-09 Pedro Alves <palves@redhat.com>
4852 * Makefile.in (OBS): Add signals-state-save-restore.o.
4853 (signals-state-save-restore.o): New rule.
4854 * config.in: Regenerate.
4855 * configure: Regenerate.
4856 * linux-low.c: Include "signals-state-save-restore.h".
4857 (linux_create_inferior): Call
4858 restore_original_signals_state.
4859 * server.c: Include "dispositions-save-restore.h".
4860 (captured_main): Call save_original_signals_state.
4862 2016-08-05 Pedro Alves <palves@redhat.com>
4864 * configure: Regenerate.
4866 2016-08-04 Yao Qi <yao.qi@linaro.org>
4868 * linux-low.c (regsets_fetch_inferior_registers): Check
4869 errno is ESRCH or not.
4871 2016-08-02 Yao Qi <yao.qi@linaro.org>
4873 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
4874 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
4875 (thread_db_load_search): Update.
4876 (try_thread_db_load_1): Don't look for td_ta_event_addr,
4877 td_ta_set_event and td_ta_event_getmsg.
4879 2016-07-26 Pedro Alves <palves@redhat.com>
4882 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
4883 of unsigned long for 64-bit registers and use uint32_t instead of
4884 unsigned int for 32-bit registers.
4886 2016-07-26 Pedro Alves <palves@redhat.com>
4888 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
4891 2016-07-21 Tom Tromey <tom@tromey.com>
4893 * configure: Rebuild.
4895 2016-07-21 Yao Qi <yao.qi@linaro.org>
4897 * mem-break.c (find_gdb_breakpoint): Cast bp to
4898 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
4900 2016-07-21 Yao Qi <yao.qi@linaro.org>
4902 * server.c (handle_v_requests): Support s and S actions
4903 if target_supports_software_single_step return true.
4905 2016-07-21 Yao Qi <yao.qi@linaro.org>
4907 * linux-low.c (resume_stopped_resumed_lwps): If resume request
4908 is resume_step, call maybe_hw_step.
4909 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
4911 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
4913 (proceed_one_lwp): If resume request is resume_step, install
4914 reinsert breakpoints and call maybe_hw_step.
4916 2016-07-21 Yao Qi <yao.qi@linaro.org>
4918 * linux-low.c (proceed_one_lwp): Declare.
4919 (linux_resume_one_thread): Remove local variable 'step'.
4920 Lift code enqueue signal. Call proceed_one_lwp instead of
4921 linux_resume_one_lwp.
4923 2016-07-21 Yao Qi <yao.qi@linaro.org>
4925 * linux-low.c (linux_resume_one_thread): Call
4926 enqueue_pending_signal.
4928 2016-07-21 Yao Qi <yao.qi@linaro.org>
4930 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
4931 * inferiors.c (do_restore_current_thread_cleanup): New function.
4932 (make_cleanup_restore_current_thread): Likewise.
4933 * linux-low.c (install_software_single_step_breakpoints): Call
4934 make_cleanup_restore_current_thread. Switch current_thread to
4937 2016-07-21 Yao Qi <yao.qi@linaro.org>
4939 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
4940 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
4941 (clone_one_breakpoint): Likewise.
4942 (delete_reinsert_breakpoints): Change parameter to thread.
4944 (has_reinsert_breakpoints): Likewise.
4945 (uninsert_reinsert_breakpoints): Likewise.
4946 (reinsert_reinsert_breakpoints): Likewise.
4947 * mem-break.h (set_reinsert_breakpoint): Update declaration.
4948 (delete_reinsert_breakpoints): Likewise.
4949 (reinsert_reinsert_breakpoints): Likewise.
4950 (uninsert_reinsert_breakpoints): Likewise.
4951 (has_reinsert_breakpoints): Likewise.
4953 2016-07-21 Yao Qi <yao.qi@linaro.org>
4955 * inferiors.c (get_thread_process): Make parameter const.
4956 * inferiors.h (get_thread_process): Update declaration.
4957 * mem-break.c (clone_all_breakpoints): Remove all parameters.
4958 Add new parameters child_thread and parent_thread. Callers
4960 * mem-break.h (clone_all_breakpoints): Update declaration.
4962 2016-07-21 Yao Qi <yao.qi@linaro.org>
4964 * mem-break.c (struct breakpoint) <cond_list>: Remove.
4965 <command_list, handler>: Remove.
4966 (struct gdb_breakpoint): New.
4967 (struct other_breakpoint): New.
4968 (struct reinsert_breakpoint): New.
4969 (is_gdb_breakpoint): New function.
4970 (any_persistent_commands): Update command_list if
4971 is_gdb_breakpoint returns true.
4972 (set_breakpoint): Create breakpoints according to their types.
4973 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
4974 (set_gdb_breakpoint_1): Likewise.
4975 (set_gdb_breakpoint): Likewise.
4976 (clear_breakpoint_conditions): Change parameter type to
4977 'struct gdb_breakpoint *'.
4978 (clear_breakpoint_commands): Likewise.
4979 (clear_breakpoint_conditions_and_commands): Likewise.
4980 (add_condition_to_breakpoint): Likewise.
4981 (add_breakpoint_condition): Likewise.
4982 (add_commands_to_breakpoint): Likewise.
4983 (check_breakpoints): Check other_breakpoint.
4984 (clone_one_breakpoint): Clone breakpopint according to its type.
4985 * mem-break.h (struct gdb_breakpoint): Declare.
4986 (set_gdb_breakpoint): Update declaration.
4987 (clear_breakpoint_conditions_and_commands): Likewise.
4988 (add_breakpoint_condition): Likewise.
4989 (add_breakpoint_commands): Likewise.
4990 * server.c (process_point_options): Change parameter type to
4991 'struct gdb_breakpoint *'.
4993 2016-07-21 Yao Qi <yao.qi@linaro.org>
4995 * mem-break.c (set_breakpoint_at): Rename it to ...
4996 (set_breakpoint_type_at): ... it.
4997 (set_breakpoint_at): Call set_breakpoint_type_at.
4998 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
4999 * mem-break.h (set_breakpoint_at): Update comments.
5001 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
5003 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
5005 (nios2_store_gregset): Likewise.
5007 2016-07-01 Pedro Alves <palves@redhat.com>
5008 Antoine Tremblay <antoine.tremblay@ericsson.com>
5010 * linux-low.c: Change interface to take the target lwp_info
5011 pointer directly and return void. Handle detaching from a zombie
5013 (linux_detach_lwp_callback): New function.
5014 (linux_detach): Detach from the leader thread after detaching from
5017 2016-06-28 Yao Qi <yao.qi@linaro.org>
5019 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
5020 for variable new_offset.
5021 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
5022 (aarch64_ftrace_insn_reloc_cb): Likewise.
5023 (aarch64_ftrace_insn_reloc_tb): Likewise.
5024 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
5025 PRIx64 instead of PRIx32.
5027 2016-06-28 Yao Qi <yao.qi@linaro.org>
5029 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
5030 (the_low_target): Install arm_get_syscall_trapinfo.
5032 2016-06-28 Yao Qi <yao.qi@linaro.org>
5034 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
5036 (the_low_target): Install aarch64_get_syscall_trapinfo.
5038 2016-06-28 Yao Qi <yao.qi@linaro.org>
5040 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
5042 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
5043 Remove parameter sysno.
5044 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
5047 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5049 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
5050 (s390_emit_ne_goto): Likewise.
5051 (s390_emit_lt_goto): Likewise.
5052 (s390_emit_le_goto): Likewise.
5053 (s390_emit_gt_goto): Likewise.
5054 (s390_emit_ge_goto): Likewise.
5055 (s390x_emit_eq_goto): Likewise.
5056 (s390x_emit_ne_goto): Likewise.
5057 (s390x_emit_lt_goto): Likewise.
5058 (s390x_emit_le_goto): Likewise.
5059 (s390x_emit_gt_goto): Likewise.
5060 (s390x_emit_ge_goto): Likewise.
5061 (s390_emit_ops_impl): Mark variable static.
5062 (s390x_emit_ops): Likewise.
5064 2016-06-17 Yao Qi <yao.qi@linaro.org>
5066 * linux-low.c (handle_extended_wait): Call
5067 uninsert_reinsert_breakpoints for the parent process. Remove
5068 reinsert breakpoints from the child process. Reinsert them to
5069 the parent process when vfork is done.
5070 * mem-break.c (uninsert_reinsert_breakpoints): New function.
5071 (reinsert_reinsert_breakpoints): New function.
5072 * mem-break.h (uninsert_reinsert_breakpoints): Declare
5073 (reinsert_reinsert_breakpoints): Declare.
5075 2016-06-17 Yao Qi <yao.qi@linaro.org>
5077 * linux-low.c (handle_extended_wait): If the parent is doing
5078 step-over, remove the reinsert breakpoints from the forked child.
5080 2016-06-17 Yao Qi <yao.qi@linaro.org>
5082 * linux-low.c (unsuspend_all_lwps): Declare.
5083 (linux_low_filter_event): If thread exited, call finish_step_over.
5084 If step-over is finished, unsuspend other threads.
5086 2016-06-17 Yao Qi <yao.qi@linaro.org>
5088 * linux-low.c (linux_resume_one_lwp_throw): Assert
5089 has_reinsert_breakpoints returns false.
5090 * mem-break.c (delete_disabled_breakpoints): Assert
5091 bp type isn't reinsert_breakpoint.
5093 2016-06-17 Yao Qi <yao.qi@linaro.org>
5095 * linux-low.c (maybe_hw_step): New function.
5096 (linux_resume_one_lwp_throw): Call maybe_hw_step.
5097 (finish_step_over): Switch current_thread to lwp temporarily,
5098 and assert has_reinsert_breakpoints returns true.
5099 (proceed_one_lwp): Call maybe_hw_step.
5100 * mem-break.c (has_reinsert_breakpoints): New function.
5101 * mem-break.h (has_reinsert_breakpoints): Declare.
5103 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
5105 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
5107 2016-05-17 Yao Qi <yao.qi@linaro.org>
5109 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
5110 instead of find_inferior.
5112 2016-05-05 Yao Qi <yao.qi@linaro.org>
5114 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
5115 Initialize res to zero.
5117 2016-05-05 Yao Qi <yao.qi@linaro.org>
5119 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
5122 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
5124 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
5125 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
5126 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
5128 2016-04-28 Par Olsson <par.olsson@windriver.com>
5129 Simon Marchi <simon.marchi@ericsson.com>
5131 * tracepoint.c (write_inferior_int8): New function.
5132 (cmd_qtenable_disable): Write enable flag using
5133 write_inferior_int8.
5135 2016-04-25 Yao Qi <yao.qi@linaro.org>
5137 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
5138 (need_step_over_p): Return zero if the LWP has pending signals
5139 can be delivered on software single step target.
5141 2016-04-25 Yao Qi <yao.qi@linaro.org>
5143 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
5144 return instead of error.
5146 2016-04-22 Yao Qi <yao.qi@linaro.org>
5148 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
5151 2016-04-22 Yao Qi <yao.qi@linaro.org>
5153 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
5154 signal when stepping over breakpoint with software single
5157 2016-04-21 Pedro Alves <palves@redhat.com>
5159 * linux-s390-low.c (s390_collect_ptrace_register)
5160 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
5162 (s390_check_regset): Use void * instead of gdb_byte *.
5164 2016-04-20 Pedro Alves <palves@redhat.com>
5166 * configure: Renegerate.
5168 2016-04-20 Yao Qi <yao.qi@linaro.org>
5170 * linux-aarch32-low.c: Include "arch/arm-linux.h".
5171 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
5173 (arm_store_gregset): Likewise.
5175 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
5177 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
5178 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
5179 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
5180 (amd64-avx-mpx-linux.c): New rules.
5181 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
5182 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
5183 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
5184 (srv_amd64_regobj): Add amd64-avx-mpx.o.
5185 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
5186 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
5187 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
5188 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
5189 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
5190 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
5191 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
5192 * linux-x86-low.c (x86_linux_read_description): Add case for
5193 X86_XSTATE_AVX_MPX_MASK.
5194 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
5195 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
5196 init_registers_i386_avx_mpx_linux.
5197 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
5198 (initialize_low_tracepoint): Call
5199 init_registers_i386_avx_mpx_linux.
5200 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
5201 (initialize_low_tracepoint): Call
5202 init_registers_amd64_avx_mpx_linux.
5203 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
5204 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
5205 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
5208 2016-04-18 Pedro Alves <palves@redhat.com>
5210 * configure: Regenerate.
5212 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
5214 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
5215 (aarch64_emit_sub): Likewise.
5217 2016-04-12 Pedro Alves <palves@redhat.com>
5219 * utils.c (prepare_to_throw_exception): Delete.
5221 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
5223 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
5225 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
5227 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
5229 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
5231 * linux-aarch64-ipa.c: Add <elf.h> include.
5232 * linux-ppc-ipa.c: Add <elf.h> include.
5233 * linux-s390-ipa.c: Add <elf.h> include.
5235 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
5237 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
5238 (get_raw_reg_ptr): Likewise.
5239 (get_trace_state_variable_value_ptr): Likewise.
5240 (set_trace_state_variable_value_ptr): Likewise.
5241 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
5244 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
5245 Marcin Kościelnicki <koriakin@0x04.net>
5248 * linux-ppc-low.c (emit_insns): New function.
5249 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
5250 (ppc_emit_prologue): New function.
5251 (ppc_emit_epilogue): New function.
5252 (ppc_emit_add): New function.
5253 (ppc_emit_sub): New function.
5254 (ppc_emit_mul): New function.
5255 (ppc_emit_lsh): New function.
5256 (ppc_emit_rsh_signed): New function.
5257 (ppc_emit_rsh_unsigned): New function.
5258 (ppc_emit_ext): New function.
5259 (ppc_emit_zero_ext): New function.
5260 (ppc_emit_log_not): New function.
5261 (ppc_emit_bit_and): New function.
5262 (ppc_emit_bit_or): New function.
5263 (ppc_emit_bit_xor): New function.
5264 (ppc_emit_bit_not): New function.
5265 (ppc_emit_equal): New function.
5266 (ppc_emit_less_signed): New function.
5267 (ppc_emit_less_unsigned): New function.
5268 (ppc_emit_ref): New function.
5269 (ppc_emit_const): New function.
5270 (ppc_emit_reg): New function.
5271 (ppc_emit_pop): New function.
5272 (ppc_emit_stack_flush): New function.
5273 (ppc_emit_swap): New function.
5274 (ppc_emit_stack_adjust): New function.
5275 (ppc_emit_call): New function.
5276 (ppc_emit_int_call_1): New function.
5277 (ppc_emit_void_call_2): New function.
5278 (ppc_emit_if_goto): New function.
5279 (ppc_emit_goto): New function.
5280 (ppc_emit_eq_goto): New function.
5281 (ppc_emit_ne_goto): New function.
5282 (ppc_emit_lt_goto): New function.
5283 (ppc_emit_le_goto): New function.
5284 (ppc_emit_gt_goto): New function.
5285 (ppc_emit_ge_goto): New function.
5286 (ppc_write_goto_address): New function.
5287 (ppc_emit_ops_impl): New static variable.
5288 (ppc64v1_emit_prologue): New function.
5289 (ppc64v2_emit_prologue): New function.
5290 (ppc64_emit_epilogue): New function.
5291 (ppc64_emit_add): New function.
5292 (ppc64_emit_sub): New function.
5293 (ppc64_emit_mul): New function.
5294 (ppc64_emit_lsh): New function.
5295 (ppc64_emit_rsh_signed): New function.
5296 (ppc64_emit_rsh_unsigned): New function.
5297 (ppc64_emit_ext): New function.
5298 (ppc64_emit_zero_ext): New function.
5299 (ppc64_emit_log_not): New function.
5300 (ppc64_emit_bit_and): New function.
5301 (ppc64_emit_bit_or): New function.
5302 (ppc64_emit_bit_xor): New function.
5303 (ppc64_emit_bit_not): New function.
5304 (ppc64_emit_equal): New function.
5305 (ppc64_emit_less_signed): New function.
5306 (ppc64_emit_less_unsigned): New function.
5307 (ppc64_emit_ref): New function.
5308 (ppc64_emit_const): New function.
5309 (ppc64v1_emit_reg): New function.
5310 (ppc64v2_emit_reg): New function.
5311 (ppc64_emit_pop): New function.
5312 (ppc64_emit_stack_flush): New function.
5313 (ppc64_emit_swap): New function.
5314 (ppc64v1_emit_call): New function.
5315 (ppc64v2_emit_call): New function.
5316 (ppc64v1_emit_int_call_1): New function.
5317 (ppc64v2_emit_int_call_1): New function.
5318 (ppc64v1_emit_void_call_2): New function.
5319 (ppc64v2_emit_void_call_2): New function.
5320 (ppc64_emit_if_goto): New function.
5321 (ppc64_emit_eq_goto): New function.
5322 (ppc64_emit_ne_goto): New function.
5323 (ppc64_emit_lt_goto): New function.
5324 (ppc64_emit_le_goto): New function.
5325 (ppc64_emit_gt_goto): New function.
5326 (ppc64_emit_ge_goto): New function.
5327 (ppc64v1_emit_ops_impl): New static variable.
5328 (ppc64v2_emit_ops_impl): New static variable.
5329 (ppc_emit_ops): New function.
5330 (linux_low_target): Wire in ppc_emit_ops.
5332 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
5333 Marcin Kościelnicki <koriakin@0x04.net>
5336 * Makefile.in: Add powerpc-*-ipa.o
5337 * configure.srv: Add ipa_obj for powerpc*-linux.
5338 * linux-ppc-ipa.c: New file.
5339 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
5341 (PPC_FIELD): New macro.
5342 (PPC_SEXT): New macro.
5343 (PPC_OP6): New macro.
5344 (PPC_BO): New macro.
5345 (PPC_LI): New macro.
5346 (PPC_BD): New macro.
5347 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
5348 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
5349 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
5350 (ppc_get_thread_area): New function.
5351 (is_elfv2_inferior): New function.
5352 (gen_ds_form): New function.
5353 (GEN_STD): New macro.
5354 (GEN_STDU): New macro.
5355 (GEN_LD): New macro.
5356 (GEN_LDU): New macro.
5357 (gen_d_form): New function.
5358 (GEN_ADDI): New macro.
5359 (GEN_ADDIS): New macro.
5360 (GEN_LI): New macro.
5361 (GEN_LIS): New macro.
5362 (GEN_ORI): New macro.
5363 (GEN_ORIS): New macro.
5364 (GEN_LWZ): New macro.
5365 (GEN_STW): New macro.
5366 (GEN_STWU): New macro.
5367 (gen_xfx_form): New function.
5368 (GEN_MFSPR): New macro.
5369 (GEN_MTSPR): New macro.
5370 (GEN_MFCR): New macro.
5371 (GEN_MTCR): New macro.
5372 (GEN_SYNC): New macro.
5373 (GEN_LWSYNC): New macro.
5374 (gen_x_form): New function.
5375 (GEN_OR): New macro.
5376 (GEN_MR): New macro.
5377 (GEN_LWARX): New macro.
5378 (GEN_STWCX): New macro.
5379 (GEN_CMPW): New macro.
5380 (gen_md_form): New function.
5381 (GEN_RLDICL): New macro.
5382 (GEN_RLDICR): New macro.
5383 (gen_i_form): New function.
5385 (GEN_BL): New macro.
5386 (gen_b_form): New function.
5387 (GEN_BNE): New macro.
5388 (GEN_LOAD): New macro.
5389 (GEN_STORE): New macro.
5390 (gen_limm): New function.
5391 (gen_atomic_xchg): New function.
5392 (gen_call): New function.
5393 (ppc_relocate_instruction): New function.
5394 (ppc_install_fast_tracepoint_jump_pad): New function.
5395 (ppc_get_min_fast_tracepoint_insn_len): New function.
5396 (ppc_get_ipa_tdesc_idx): New function.
5397 (the_low_target): Wire in the new functions.
5398 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
5400 * linux-ppc-tdesc.h: New file.
5402 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
5404 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
5405 (alloc_jump_pad_buffer): New function.
5406 * linux-amd64-ipa.c: Add <sys/mman.h> include.
5407 (alloc_jump_pad_buffer): New function.
5408 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
5409 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
5410 (alloc_jump_pad_buffer): New function.
5411 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
5412 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
5413 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
5414 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
5416 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
5418 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
5419 * linux-amd64-ipa.c: Likewise.
5420 * linux-i386-ipa.c: Likewise.
5421 * linux-s390-ipa.c: Likewise.
5422 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
5423 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
5424 set_trace_state_variable_value_ptr.
5425 (struct ipa_sym_addresses): Likewise.
5426 (symbol_list): Likewise.
5427 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
5428 accessing gdb_collect directly.
5429 (gdb_collect_ptr_type): New typedef.
5430 (get_raw_reg_ptr_type): New typedef.
5431 (get_trace_state_variable_value_ptr_type): New typedef.
5432 (set_trace_state_variable_value_ptr_type): New typedef.
5433 (gdb_collect_ptr): New global.
5434 (get_raw_reg_ptr): New global.
5435 (get_trace_state_variable_value_ptr): New global.
5436 (set_trace_state_variable_value_ptr): New global.
5437 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
5438 accessing get_raw_reg directly.
5439 (get_get_tsv_func_addr): Likewise for
5440 get_trace_state_variable_value_ptr.
5441 (get_set_tsv_func_addr): Likewise for
5442 set_trace_state_variable_value_ptr.
5443 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
5445 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
5447 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
5449 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
5451 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
5453 (relocate_instruction): Remove own_buf.
5454 * server.c (own_buf): Make global.
5455 (handle_v_requests): Make global.
5456 * server.h (own_buf): New declaration.
5457 (handle_v_requests): New prototype.
5459 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
5462 * linux-s390-low.c (add_insns): New function.
5463 (s390_emit_prologue): New function.
5464 (s390_emit_epilogue): New function.
5465 (s390_emit_add): New function.
5466 (s390_emit_sub): New function.
5467 (s390_emit_mul): New function.
5468 (s390_emit_lsh): New function.
5469 (s390_emit_rsh_signed): New function.
5470 (s390_emit_rsh_unsigned): New function.
5471 (s390_emit_ext): New function.
5472 (s390_emit_log_not): New function.
5473 (s390_emit_bit_and): New function.
5474 (s390_emit_bit_or): New function.
5475 (s390_emit_bit_xor): New function.
5476 (s390_emit_bit_not): New function.
5477 (s390_emit_equal): New function.
5478 (s390_emit_less_signed): New function.
5479 (s390_emit_less_unsigned): New function.
5480 (s390_emit_ref): New function.
5481 (s390_emit_if_goto): New function.
5482 (s390_emit_goto): New function.
5483 (s390_write_goto_address): New function.
5484 (s390_emit_litpool): New function.
5485 (s390_emit_const): New function.
5486 (s390_emit_call): New function.
5487 (s390_emit_reg): New function.
5488 (s390_emit_pop): New function.
5489 (s390_emit_stack_flush): New function.
5490 (s390_emit_zero_ext): New function.
5491 (s390_emit_swap): New function.
5492 (s390_emit_stack_adjust): New function.
5493 (s390_emit_set_r2): New function.
5494 (s390_emit_int_call_1): New function.
5495 (s390_emit_void_call_2): New function.
5496 (s390_emit_eq_goto): New function.
5497 (s390_emit_ne_goto): New function.
5498 (s390_emit_lt_goto): New function.
5499 (s390_emit_le_goto): New function.
5500 (s390_emit_gt_goto): New function.
5501 (s390_emit_ge_goto): New function.
5502 (s390x_emit_prologue): New function.
5503 (s390x_emit_epilogue): New function.
5504 (s390x_emit_add): New function.
5505 (s390x_emit_sub): New function.
5506 (s390x_emit_mul): New function.
5507 (s390x_emit_lsh): New function.
5508 (s390x_emit_rsh_signed): New function.
5509 (s390x_emit_rsh_unsigned): New function.
5510 (s390x_emit_ext): New function.
5511 (s390x_emit_log_not): New function.
5512 (s390x_emit_bit_and): New function.
5513 (s390x_emit_bit_or): New function.
5514 (s390x_emit_bit_xor): New function.
5515 (s390x_emit_bit_not): New function.
5516 (s390x_emit_equal): New function.
5517 (s390x_emit_less_signed): New function.
5518 (s390x_emit_less_unsigned): New function.
5519 (s390x_emit_ref): New function.
5520 (s390x_emit_if_goto): New function.
5521 (s390x_emit_const): New function.
5522 (s390x_emit_call): New function.
5523 (s390x_emit_reg): New function.
5524 (s390x_emit_pop): New function.
5525 (s390x_emit_stack_flush): New function.
5526 (s390x_emit_zero_ext): New function.
5527 (s390x_emit_swap): New function.
5528 (s390x_emit_stack_adjust): New function.
5529 (s390x_emit_int_call_1): New function.
5530 (s390x_emit_void_call_2): New function.
5531 (s390x_emit_eq_goto): New function.
5532 (s390x_emit_ne_goto): New function.
5533 (s390x_emit_lt_goto): New function.
5534 (s390x_emit_le_goto): New function.
5535 (s390x_emit_gt_goto): New function.
5536 (s390x_emit_ge_goto): New function.
5537 (s390_emit_ops): New function.
5538 (struct linux_target_ops): Fill in emit_ops hook.
5540 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
5543 * Makefile.in: Add s390 IPA files.
5544 * configure.srv: Build IPA for s390.
5545 * linux-s390-ipa.c: New file.
5546 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
5547 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
5548 (tdesc_s390_linux32): Likewise.
5549 (init_registers_s390_linux32v1): Likewise.
5550 (tdesc_s390_linux32v1): Likewise.
5551 (init_registers_s390_linux32v2): Likewise.
5552 (tdesc_s390_linux32v2): Likewise.
5553 (init_registers_s390_linux64): Likewise.
5554 (tdesc_s390_linux64): Likewise.
5555 (init_registers_s390_linux64v1): Likewise.
5556 (tdesc_s390_linux64v1): Likewise.
5557 (init_registers_s390_linux64v2): Likewise.
5558 (tdesc_s390_linux64v2): Likewise.
5559 (init_registers_s390_te_linux64): Likewise.
5560 (tdesc_s390_te_linux64): Likewise.
5561 (init_registers_s390_vx_linux64): Likewise.
5562 (tdesc_s390_vx_linux64): Likewise.
5563 (init_registers_s390_tevx_linux64): Likewise.
5564 (tdesc_s390_tevx_linux64): Likewise.
5565 (init_registers_s390x_linux64): Likewise.
5566 (tdesc_s390x_linux64): Likewise.
5567 (init_registers_s390x_linux64v1): Likewise.
5568 (tdesc_s390x_linux64v1): Likewise.
5569 (init_registers_s390x_linux64v2): Likewise.
5570 (tdesc_s390x_linux64v2): Likewise.
5571 (init_registers_s390x_te_linux64): Likewise.
5572 (tdesc_s390x_te_linux64): Likewise.
5573 (init_registers_s390x_vx_linux64): Likewise.
5574 (tdesc_s390x_vx_linux64): Likewise.
5575 (init_registers_s390x_tevx_linux64): Likewise.
5576 (tdesc_s390x_tevx_linux64): Likewise.
5577 (have_hwcap_s390_vx): New static variable.
5578 (s390_arch_setup): Fill have_hwcap_s390_vx.
5579 (s390_get_thread_area): New function.
5580 (s390_ft_entry_gpr_esa): New const.
5581 (s390_ft_entry_gpr_zarch): New const.
5582 (s390_ft_entry_misc): New const.
5583 (s390_ft_entry_fr): New const.
5584 (s390_ft_entry_vr): New const.
5585 (s390_ft_main_31): New const.
5586 (s390_ft_main_64): New const.
5587 (s390_ft_exit_fr): New const.
5588 (s390_ft_exit_vr): New const.
5589 (s390_ft_exit_misc): New const.
5590 (s390_ft_exit_gpr_esa): New const.
5591 (s390_ft_exit_gpr_zarch): New const.
5592 (append_insns): New function.
5593 (s390_relocate_instruction): New function.
5594 (s390_install_fast_tracepoint_jump_pad): New function.
5595 (s390_get_min_fast_tracepoint_insn_len): New function.
5596 (s390_get_ipa_tdesc_idx): New function.
5597 (struct linux_target_ops): Wire in the above functions.
5598 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
5599 * linux-s390-tdesc.h: New file.
5601 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
5603 * linux-s390-low.c (s390_supports_tracepoints): New function.
5604 (struct linux_target_ops): Fill supports_tracepoints hook.
5606 2016-03-18 Yao Qi <yao.qi@linaro.org>
5608 * linux-low.c (lwp_signal_can_be_delivered): New function.
5609 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
5611 2016-03-18 Yao Qi <yao.qi@linaro.org>
5613 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
5614 0 if signal is enqueued. Remove 'signal' from one debugging
5615 message. Move one debugging message to some lines below.
5616 Remove code setting 'signal' to 0.
5618 2016-03-18 Yao Qi <yao.qi@linaro.org>
5620 * linux-low.c (linux_low_filter_event): Remove redundant
5621 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
5623 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
5625 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
5626 (struct linux_target_ops): Wire in the above.
5628 2016-03-03 Yao Qi <yao.qi@linaro.org>
5630 * linux-low.c: Update comments to start_step_over.
5632 2016-03-03 Yao Qi <yao.qi@linaro.org>
5635 * linux-low.c (handle_extended_wait): Set child suspended
5636 if event_lwp->bp_reinsert isn't zero.
5638 2016-03-02 Yao Qi <yao.qi@linaro.org>
5640 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
5641 enqueue_pending_signal.
5643 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
5645 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
5648 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
5650 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
5651 (s390_regmap_3264) [!__s390x__]: New global.
5652 (s390_collect_ptrace_register): Skip map entries containing -1.
5653 (s390_supply_ptrace_register): Ditto.
5654 (s390_fill_gprs_high): New function.
5655 (s390_store_gprs_high): New function.
5656 (s390_regsets): Add NT_S390_HIGH_GPRS.
5657 (s390_get_hwcap): Enable on 31-bit.
5658 (have_hwcap_s390_high_gprs): Enable on 31-bit.
5659 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
5660 Detect NT_S390_HIGH_GPRS.
5661 (s390_usrregs_info_3264): Enable on 31-bit.
5662 (s390_regs_info): Enable regs_info_3264 on 31-bit.
5663 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
5665 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
5668 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
5669 * configure.srv: Ditto.
5670 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
5671 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
5672 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
5673 (init_registers_amd64_linux): Remove prototype.
5674 (tdesc_amd64_linux): Remove declaration.
5675 (get_ipa_tdesc): New function.
5676 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
5677 initialize remaining tdescs.
5678 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
5679 (init_registers_i386_linux): Remove prototype.
5680 (tdesc_i386_linux): Remove declaration.
5681 (get_ipa_tdesc): New function.
5682 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
5683 initialize remaining tdescs.
5684 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
5685 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
5686 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
5687 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
5688 (x86_get_ipa_tdesc_idx): New function.
5689 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
5690 * linux-x86-tdesc.h: New file.
5691 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
5692 (target_get_ipa_tdesc_idx): New macro.
5693 * tracepoint.c (ipa_tdesc_idx): New macro.
5694 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
5695 (symbol_list): Add ipa_tdesc_idx.
5696 (cmd_qtstart): Write ipa_tdesc_idx in the target.
5697 (ipa_tdesc): Remove.
5698 (ipa_tdesc_idx): New variable.
5699 (get_context_regcache): Use get_ipa_tdesc.
5700 (gdb_collect): Ditto.
5702 * tracepoint.h (get_ipa_tdesc): New prototype.
5703 (ipa_tdesc): Remove.
5705 2016-02-24 Pedro Alves <palves@redhat.com>
5707 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
5708 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
5709 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
5710 Factor out common code between the USE_SIGTRAP_SIGINFO and
5711 !USE_SIGTRAP_SIGINFO blocks.
5712 (linux_low_filter_event): Call save_stop_reason instead of
5713 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
5715 (linux_wait_1): Update comments.
5717 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
5719 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
5720 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
5721 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
5722 ppc_insert_point, ppc_remove_point.
5724 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
5726 * linux-s390-low.c (s390_supports_z_point_type): New function.
5727 (struct linux_target_ops): Wire s390_supports_z_point_type in.
5729 2016-02-16 Yao Qi <yao.qi@linaro.org>
5731 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
5732 PC. Get pc from regcache_read_pc.
5734 2016-02-12 Yao Qi <yao.qi@linaro.org>
5736 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
5737 or linux_get_pc_32bit.
5738 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
5740 2016-02-12 Yao Qi <yao.qi@linaro.org>
5742 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
5743 arm_linux_get_next_pcs_fixup.
5745 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
5747 * tracepoint.c (x_tracepoint_action_download): Change
5748 write_inferior_data_ptr to write_inferior_data_pointer.
5749 (cmd_qtstart): Likewise.
5750 (write_inferior_data_ptr): Remove.
5751 (download_agent_expr): Change write_inferior_data_ptr to
5752 write_inferior_data_pointer.
5753 (download_tracepoint_1): Likewise.
5754 (download_tracepoint): Likewise.
5755 (download_trace_state_variables): Likewise.
5757 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
5758 Marcin Kościelnicki <koriakin@0x04.net>
5760 * tracepoint.c (struct tracepoint_action_ops): Remove.
5761 (struct tracepoint_action): Remove ops.
5762 (m_tracepoint_action_download, r_tracepoint_action_download)
5763 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
5764 size and offset accordingly.
5765 (m_tracepoint_action_ops, r_tracepoint_action_ops)
5766 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
5767 (tracepoint_action_send, tracepoint_action_download): New functions.
5768 Helpers for trace action handlers.
5769 (add_tracepoint_action): Remove setup actions ops.
5770 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
5772 2016-02-10 Yao Qi <yao.qi@linaro.org>
5774 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
5776 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
5778 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
5780 * configure: Regenerate.
5782 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
5784 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
5785 void * to gdb_byte *.
5786 * linux-low.c (siginfo_fixup): Likewise.
5787 (linux_xfer_siginfo): Likewise.
5788 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
5790 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
5792 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
5794 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
5796 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
5798 * linux-x86-low.c [__x86_64__]: Include
5799 "nat/amd64-linux-siginfo.h".
5800 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
5801 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
5802 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
5803 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
5804 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
5805 (cpt_si_fd, si_timerid, si_overrun): Move from
5806 nat/amd64-linux-siginfo.c.
5807 * Makefile.in (amd64-linux-siginfo.o:): New rule.
5809 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
5811 * server.c (skip_to_semicolon): Remove.
5812 (process_point_options): Use strchrnul instead of
5815 2016-01-26 Yao Qi <yao.qi@linaro.org>
5817 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
5818 * linux-low.c (install_software_single_step_breakpoints): Don't
5819 call regcache_read_pc.
5820 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
5823 2016-01-26 Yao Qi <yao.qi@linaro.org>
5825 * linux-low.c (install_software_single_step_breakpoints): Call
5826 regcache_read_pc instead of get_pc.
5828 2016-01-26 Yao Qi <yao.qi@linaro.org>
5830 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
5831 (unblock_async_io): Rename to ...
5832 (block_unblock_async_io): ... it. New function.
5833 (enable_async_io): Don't install SIGIO handler. Unblock it
5835 (disable_async_io): Don't ignore SIGIO. Block it instead.
5836 (initialize_async_io): Install SIGIO handler. Don't call
5839 2016-01-26 Yao Qi <yao.qi@linaro.org>
5841 * remote-utils.c (getpkt): If the buffer isn't empty, and the
5842 first character is '\003', call *the_target->request_interrupt.
5844 2016-01-25 Yao Qi <yao.qi@linaro.org>
5846 * remote-utils.c (new_thread_notify): Remove.
5847 (dead_thread_notify): Likewise.
5848 * remote-utils.h (new_thread_notify): Remove declaration.
5849 (dead_thread_notify): Likewise.
5851 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
5853 * gdb.trace/pending.exp: Fix expected message on continue.
5855 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
5857 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
5858 it works properly on big-endian machines where sizeof (CORE_ADDR)
5861 2016-01-21 Pedro Alves <palves@redhat.com>
5863 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
5864 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
5865 * configure: Regenerate.
5867 2016-01-21 Yao Qi <yao.qi@linaro.org>
5869 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
5870 is_thumb and set it according to CPSR saved on the stack.
5871 (get_next_pcs_syscall_next_pc): Pass is_thumb to
5872 arm_sigreturn_next_pc.
5874 2016-01-18 Yao Qi <yao.qi@linaro.org>
5876 * linux-low.c (linux_set_pc_64bit): New function.
5877 (linux_get_pc_64bit): New function.
5878 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
5880 * linux-sparc-low.c (debug_threads): Remove declaration.
5881 (sparc_get_pc): Remove.
5882 (the_low_target): Use linux_get_pc_64bit instead of
5884 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
5885 (the_low_target): Use linux_get_pc_64bit and
5888 2016-01-18 Yao Qi <yao.qi@linaro.org>
5890 * linux-arm-low.c (debug_threads): Remove declaration.
5891 (arm_get_pc, arm_set_pc): Remove.
5892 (the_low_target): Use linux_get_pc_32bit and
5894 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
5895 (the_low_target): Use linux_get_pc_32bit and
5897 * linux-cris-low.c (debug_threads): Remove declaration.
5898 (cris_get_pc, cris_set_pc,): Remove.
5899 (the_low_target): Use linux_get_pc_32bit and
5901 * linux-crisv32-low.c (debug_threads): Remove declaration.
5902 (cris_get_pc, cris_set_pc): Remove.
5903 (the_low_target): Use linux_get_pc_32bit and
5905 * linux-low.c: Include inttypes.h.
5906 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
5907 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
5908 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
5909 (the_low_target): Use linux_get_pc_32bit and
5911 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
5912 (the_low_target): Use linux_get_pc_32bit and
5914 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
5915 (the_low_target): Use linux_get_pc_32bit and
5917 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
5918 (the_low_target): Use linux_get_pc_32bit and
5920 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
5921 (the_low_target): Use linux_get_pc_32bit and
5924 2016-01-18 Gary Benson <gbenson@redhat.com>
5926 * configure.ac (AC_FUNC_FORK): New check.
5927 * config.in: Regenerate.
5928 * configure: Likewise.
5930 2016-01-14 Yao Qi <yao.qi@linaro.org>
5932 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
5933 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
5934 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
5935 arm_get_next_pcs_ctor.
5937 2016-01-12 Josh Stone <jistone@redhat.com>
5938 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5940 * inferiors.h: Include "gdb_vecs.h".
5941 (struct process_info): Add syscalls_to_catch.
5942 * inferiors.c (remove_process): Free syscalls_to_catch.
5943 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
5944 syscall_return stops.
5945 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
5946 * server.c (handle_general_set): Handle QCatchSyscalls.
5947 (handle_query): Report support for QCatchSyscalls.
5948 * target.h (struct target_ops): Add supports_catch_syscall.
5949 (target_supports_catch_syscall): New macro.
5950 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
5951 (struct lwp_info): Add syscall_state.
5952 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
5953 Maintain syscall_state and syscalls_to_catch across exec.
5954 (get_syscall_trapinfo): New function, proxy to the_low_target.
5955 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
5956 (linux_low_filter_event): Toggle syscall_state entry/return for
5957 syscall traps, and set it ignored for all others.
5958 (gdb_catching_syscalls_p): New function.
5959 (gdb_catch_this_syscall_p): New function.
5960 (linux_wait_1): Handle SYSCALL_SIGTRAP.
5961 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
5962 (linux_supports_catch_syscall): New function.
5963 (linux_target_ops): Install it.
5964 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
5965 (the_low_target): Install it.
5967 2016-01-12 Mike Frysinger <vapier@gentoo.org>
5969 * acinclude.m4: Include new ../warning.m4 file.
5970 * configure: Regenerated.
5971 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
5973 2016-01-12 Mike Frysinger <vapier@gentoo.org>
5975 * ax.c (is_goto_target): Mark static.
5976 * linux-low.c (register_addr): Likewise.
5977 (linux_fetch_registers, linux_store_registers): Likewise.
5978 * mem-break.c (any_persistent_commands): Fix old prototype.
5979 (add_commands_to_breakpoint): Mark static.
5980 * regcache.c (find_register_by_name): Delete unused func.
5981 * remote-utils.c (hex_or_minus_one): Mark static.
5982 * server.c (monitor_show_help): Mark static.
5983 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
5984 handle_v_requests): Likewise.
5986 2016-01-12 Pedro Alves <palves@redhat.com>
5988 Remove use of the registered trademark symbol throughout.
5990 2016-01-08 Yao Qi <yao.qi@linaro.org>
5992 * remote-utils.c (getpkt): If c is '\003', call target hook
5995 2016-01-06 Yao Qi <yao.qi@linaro.org>
5997 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
5998 linux-aarch32-low.c.
5999 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6000 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
6001 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
6002 (thumb2_breakpoint): Declare.
6003 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
6004 linux-aarch32-low.h.
6005 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6006 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
6007 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
6009 2016-01-01 Joel Brobecker <brobecker@adacore.com>
6011 * gdbreplay.c (gdbreplay_version): Change copyright year in
6013 * server.c (gdbserver_version): Likewise.
6015 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
6017 * server.c (crc32_table): Delete.
6018 (crc32): Use libiberty's xcrc32 function.
6020 2015-12-22 Joel Brobecker <brobecker@adacore.com>
6022 * lynx-low.c (lynx_delete_thread_callback): New function.
6023 (lynx_mourn): Properly delete our process and all of its
6024 threads. Remove call to clear_inferiors.
6026 2015-12-22 Joel Brobecker <brobecker@adacore.com>
6028 * target.c (thread_search_callback): Add check that
6029 the thread_stopped target callback is not NULL before
6032 2015-12-21 Yao Qi <yao.qi@linaro.org>
6034 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
6037 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6039 * server.c (handle_query): Call target_supports_software_single_step.
6041 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6043 * linux-low.c (single_step): New function.
6044 (linux_resume_one_lwp_throw): Call single_step.
6045 (start_step_over): Likewise.
6047 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6049 * Makefile.in (SFILES): Append arch/arm-linux.c,
6050 arch/arm-get-next-pcs.c.
6051 (arm-linux.o): New rule.
6052 (arm-get-next-pcs.o): New rule.
6053 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
6055 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
6056 to linux-aarch32-low.c.
6057 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6058 (arm_breakpoint_len, thumb_breakpoint): Likewise.
6059 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
6060 (thumb2_breakpoint_len): Likewise.
6061 (arm_is_thumb_mode): Make non-static.
6062 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
6063 from linux-aarch32-low.c.
6064 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6065 (arm_breakpoint_len, thumb_breakpoint): Likewise.
6066 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
6067 (thumb2_breakpoint_len): Likewise.
6068 (arm_is_thumb_mode): New declaration.
6069 * linux-arm-low.c: Include arch/arm-linux.h
6070 aarch/arm-get-next-pcs.h, sys/syscall.h.
6071 (get_next_pcs_ops): New struct.
6072 (get_next_pcs_addr_bits_remove): New function.
6073 (get_next_pcs_is_thumb): New function.
6074 (get_next_pcs_read_memory_unsigned_integer): Likewise.
6075 (arm_sigreturn_next_pc): Likewise.
6076 (get_next_pcs_syscall_next_pc): Likewise.
6077 (arm_gdbserver_get_next_pcs): Likewise.
6078 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
6080 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
6081 * server.h: Include gdb_vecs.h.
6083 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6085 * Makefile.in (SFILES): Append common/common-regcache.c.
6086 (OBS): Append common-regcache.o.
6087 (common-regcache.o): New rule.
6088 * regcache.c (init_register_cache): Initialize cache to
6090 (regcache_raw_read_unsigned): New function.
6091 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
6092 register_status enum.
6094 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6096 * linux-aarch64-low.c (the_low_targets): Rename
6097 breakpoint_reinsert_addr to get_next_pcs.
6098 * linux-arm-low.c (the_low_targets): Likewise.
6099 * linux-bfin-low.c (the_low_targets): Likewise.
6100 * linux-cris-low.c (the_low_targets): Likewise.
6101 * linux-crisv32-low.c (the_low_targets): Likewise.
6102 * linux-low.c (can_software_single_step): Likewise.
6103 (install_software_single_step_breakpoints): New function.
6104 (start_step_over): Use install_software_single_step_breakpoints.
6105 * linux-low.h: New CORE_ADDR vector.
6106 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
6108 * linux-mips-low.c (the_low_targets): Likewise.
6109 * linux-nios2-low.c (the_low_targets): Likewise.
6110 * linux-sparc-low.c (the_low_targets): Likewise.
6112 2015-12-17 Pedro Alves <palves@redhat.com>
6114 * linux-low.c (linux_kill_one_lwp): Remove references to
6116 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
6118 (linux_init_signals): Delete.
6119 (initialize_low): Adjust.
6120 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
6122 2015-12-16 Pedro Alves <palves@redhat.com>
6124 * configure.ac (compiler warning flags): When testing a
6125 -Wno-foo option, check whether -Wfoo works instead.
6126 * configure: Regenerate.
6128 2015-12-11 Don Breazeal <donb@codesourcery.com>
6130 * server.c (process_serial_event): Don't exit from gdbserver
6131 in remote mode if there are still active inferiors.
6133 2015-12-11 Yao Qi <yao.qi@linaro.org>
6135 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
6136 arm_breakpoint_at if the process is 32-bit.
6138 2015-12-11 Yao Qi <yao.qi@linaro.org>
6140 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
6143 2015-12-07 Yao Qi <yao.qi@linaro.org>
6145 * configure.srv: Append arm.o to srv_tgtobj for
6146 aarch64*-*-linux* target.
6147 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
6148 from linux-arm-low.c.
6149 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6150 (arm_breakpoint_len, thumb_breakpoint): Likewise.
6151 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
6152 (thumb2_breakpoint_len): Likewise.
6153 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
6154 (arm_breakpoint_kinds): Likewise.
6155 (arm_breakpoint_kind_from_pc): Likewise.
6156 (arm_sw_breakpoint_from_kind): Likewise.
6157 (arm_breakpoint_kind_from_current_state): Likewise.
6158 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
6159 (arm_sw_breakpoint_from_kind): Declare.
6160 (arm_breakpoint_kind_from_current_state): Declare.
6161 (arm_breakpoint_at): Declare.
6162 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
6163 arm_sw_breakpoint_from_kind if process is 32-bit.
6164 (aarch64_breakpoint_kind_from_pc): New function.
6165 (aarch64_breakpoint_kind_from_current_state): New function.
6166 (the_low_target): Initialize fields breakpoint_kind_from_pc
6167 and breakpoint_kind_from_current_state.
6168 * linux-arm-low.c (arm_breakpoint_kinds): Move to
6169 linux-aarch32-low.c.
6170 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
6171 (arm_breakpoint, arm_breakpoint_len): Likewise.
6172 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
6173 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
6174 (arm_is_thumb_mode): Likewise.
6175 (arm_breakpoint_at): Likewise.
6176 (arm_breakpoint_kind_from_pc): Likewise.
6177 (arm_sw_breakpoint_from_kind): Likewise.
6178 (arm_breakpoint_kind_from_current_state): Likewise.
6181 2015-08-04 Yao Qi <yao.qi@linaro.org>
6183 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
6184 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
6185 * server.c (extended_protocol): Remove "static".
6186 * server.h (extended_protocol): Declare it.
6188 2015-12-04 Josh Stone <jistone@redhat.com>
6190 * target.h (struct target_ops) <arch_setup>: Rename to ...
6191 (struct target_ops) <post_create_inferior>: ... this.
6192 (target_arch_setup): Rename to ...
6193 (target_post_create_inferior): ... this, calling post_create_inferior.
6194 * server.c (start_inferior): Update target_arch_setup calls to
6195 target_post_create_inferior.
6196 * linux-low.c (linux_low_ptrace_options): Forward declare.
6197 (linux_arch_setup): Update its comment for general use.
6198 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
6199 (struct linux_target_ops): Use linux_post_create_inferior.
6200 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
6201 to post_create_inferior.
6202 * nto-low.c (struct nto_target_ops): Likewise.
6203 * spu-low.c (struct spu_target_ops): Likewise.
6204 * win32-low.c (struct win32_target_ops): Likewise.
6206 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
6208 * linux-arm-low.c: Remove duplicate arch/arm.h include.
6210 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6212 * linux-arm-low.c (arm_reinsert_addr): Remove function.
6213 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
6214 * linux-cris-low.c (cris_reinsert_addr> Remove function.
6215 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6216 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
6217 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6218 * linux-mips-low.c (mips_reinsert_addr): Remove function.
6219 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6220 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
6221 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6222 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
6223 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6225 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6227 * linux-low.c (linux_look_up_symbols): Don't call
6228 linux_supports_traceclone.
6229 * linux-low.h (thread_db_init): Remove use_events argument.
6230 * thread-db.c (thread_db_use_event): Remove global variable.
6231 (struct thread_db) <td_thr_event_enable_p>: Remove field.
6232 (struct thread_db) <td_create_bp>: Remove field.
6233 (thread_db_create_event): Remove function.
6234 (thread_db_enable_reporting): Likewise.
6235 (find_one_thread): Don't check for thread_db_use_events.
6236 (attach_thread): Likewise.
6237 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
6238 (try_thread_db_load_1): Don't check for thread_db_use_events.
6239 (thread_db_init): Remove use_events argument and thread events
6241 (remove_thread_event_breakpoints): Remove function.
6242 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
6244 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6246 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
6248 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6249 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
6250 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6251 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
6252 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
6254 * linux-crisv32-low.c (cris_supports_hardware_single_step):
6256 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6257 * linux-low.c (can_hardware_single_step): Use
6258 supports_hardware_single_step.
6259 (can_software_single_step): New function.
6260 (start_step_over): Call can_software_single_step.
6261 (linux_supports_hardware_single_step): New function.
6262 (struct target_ops) <supports_software_single_step>: Initialize.
6263 * linux-low.h (struct linux_target_ops)
6264 <supports_hardware_single_step>: Initialize.
6265 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
6266 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6267 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
6268 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
6269 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
6270 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6271 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
6272 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6273 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
6274 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
6276 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
6277 (struct linux_target_ops) <tile_supports_hardware_single_step>:
6279 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
6280 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6281 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
6283 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6284 * target.h (struct target_ops): <supports_software_single_step>:
6286 (target_supports_software_single_step): New macro.
6288 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6290 * linux-low.c (linux_wait_1): Fix pc advance condition.
6291 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
6292 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
6294 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6296 * linux-arm-low.c (arm_is_thumb_mode): New function.
6297 (arm_breakpoint_at): Use arm_is_thumb_mode.
6298 (arm_breakpoint_kind_from_current_state): New function.
6299 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
6301 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
6302 (linux_breakpoint_kind_from_current_state): New function.
6303 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
6304 * linux-low.h (struct linux_target_ops)
6305 <breakpoint_kind_from_current_state>: New field.
6306 * target.h (struct target_ops): Likewise.
6307 (target_breakpoint_kind_from_current_state): New macro.
6309 2015-11-30 Pedro Alves <palves@redhat.com>
6311 * linux-low.c (linux_resume): Wake up the event loop before
6314 2015-11-30 Pedro Alves <palves@redhat.com>
6316 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
6318 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
6320 * target.c (struct thread_search): New structure.
6321 (thread_search_callback): New function.
6322 (prev_general_thread): New global.
6323 (prepare_to_access_memory, done_accessing_memory): New functions.
6324 * target.h (prepare_to_access_memory, done_accessing_memory):
6325 Replace macros with function declarations.
6327 2015-11-30 Pedro Alves <palves@redhat.com>
6330 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
6331 report TARGET_WAITKIND_NO_RESUMED.
6332 * remote-utils.c (prepare_resume_reply): Handle
6333 TARGET_WAITKIND_NO_RESUMED.
6334 * server.c (report_no_resumed): New global.
6335 (handle_query) <qSupported>: Handle "no-resumed+". Report
6336 "no-resumed+" support.
6337 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
6338 return error if the client doesn't support no-resumed events.
6339 (push_stop_notification): New function.
6340 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
6341 events if the client supports them.
6343 2015-11-30 Pedro Alves <palves@redhat.com>
6345 * linux-low.c (thread_still_has_status_pending_p): Don't check
6347 (lwp_resumed): New function.
6348 (status_pending_p_callback): Return early if the LWP is not
6349 supposed to be resumed.
6351 2015-11-30 Pedro Alves <palves@redhat.com>
6353 * linux-low.c (handle_extended_wait): Assert that the LWP's
6354 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
6355 thread create events, leave the new child's status pending.
6356 (linux_low_filter_event): If GDB wants to hear about thread exit
6357 events, leave the LWP marked dead and don't delete it.
6358 (linux_wait_for_event_filtered): Don't check for thread exit.
6359 (filter_exit_event): New function.
6360 (linux_wait_1): Use it, when returning an exit event.
6361 (linux_resume_one_lwp_throw): Assert that the LWP's
6362 waitstatus is TARGET_WAITKIND_IGNORE.
6363 * remote-utils.c (prepare_resume_reply): Handle
6364 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
6365 * server.c (report_thread_events): New global.
6366 (handle_general_set): Handle QThreadEvents.
6367 (handle_query) <qSupported>: Handle and report QThreadEvents+;
6368 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
6369 TARGET_WAITKIND_THREAD_EXITED.
6370 * server.h (report_thread_events): Declare.
6372 2015-11-30 Pedro Alves <palves@redhat.com>
6374 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
6375 the thread's last_resume_kind was resume_stop.
6377 2015-11-30 Pedro Alves <palves@redhat.com>
6379 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
6382 2015-11-30 Pedro Alves <palves@redhat.com>
6384 * server.c (handle_v_requests): Handle vCtrlC.
6386 2015-11-30 Pedro Alves <palves@redhat.com>
6388 * gdbthread.h (find_any_thread_of_pid): Declare.
6389 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
6391 * server.c (handle_query): If current_thread is NULL, look for
6392 another thread of the selected process.
6394 2015-11-26 Daniel Colascione <dancol@dancol.org>
6395 Simon Marchi <simon.marchi@ericsson.com>
6397 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
6398 * server.c (handle_qxfer_threads_worker): Refactor to include thread
6400 * target.h (struct target_ops) <thread_name>: New field.
6401 (target_thread_name): New macro.
6403 2015-11-23 Joel Brobecker <brobecker@adacore.com>
6405 * regcache.h (regcache_invalidate_pid): Add declaration.
6406 * regcache.c (regcache_invalidate_pid): New function, extracted
6407 from regcache_invalidate.
6408 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
6409 Add trivial documentation comment.
6410 * lynx-low.c: Use regcache_invalidate_pid instead of
6411 regcache_invalidate.
6413 2015-11-23 Joel Brobecker <brobecker@adacore.com>
6415 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
6416 and Elf64_auxv_t if the target is Android.
6418 2015-11-22 Doug Evans <xdje42@gmail.com>
6420 * target.h: #include <sys/types.h>.
6422 2015-11-19 Pedro Alves <palves@redhat.com>
6424 * linux-low.c (linux_process_qsupported): Change prototype.
6426 * linux-low.h (struct linux_target_ops) <process_qsupported>:
6428 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
6429 and adjust to loop over all features.
6430 * server.c (handle_query) <qSupported>: Adjust to call
6431 target_process_qsupported once, passing it a vector of unprocessed
6433 * target.h (struct target_ops) <process_qsupported>: Change
6435 (target_process_qsupported): Adjust.
6437 2015-11-19 Pedro Alves <palves@redhat.com>
6439 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
6441 * configure: Regenerate.
6443 2015-11-19 Pedro Alves <palves@redhat.com>
6445 * configure: Regenerate.
6447 2015-11-19 Yao Qi <yao.qi@linaro.org>
6449 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
6452 2015-11-19 Yao Qi <yao.qi@linaro.org>
6454 * linux-aarch64-low.c (enum aarch64_operand_type): New.
6455 (struct aarch64_operand): Move enum out.
6457 2015-11-19 Yao Qi <yao.qi@linaro.org>
6459 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
6460 struct user_fpsimd_state *.
6461 (aarch64_store_fpregset): Likewise.
6463 2015-11-19 Yao Qi <yao.qi@linaro.org>
6465 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
6466 struct user_pt_regs *.
6467 (aarch64_store_gregset): Likewise.
6469 2015-11-18 Pedro Alves <palves@redhat.com>
6471 * Makefile.in (all_object_files): Add $IPA_OBJS.
6473 2015-11-17 Pedro Alves <palves@redhat.com>
6475 * win32-low.c (win32_resume): Use gdb_signal_from_host,
6476 GDB_SIGNAL_0 and gdb_signal_to_string.
6478 2015-11-17 Pedro Alves <palves@redhat.com>
6480 * win32-low.c (handle_output_debug_string): Remove parameter.
6481 (win32_kill): Remove our_status local and adjust call to
6482 handle_output_debug_string.
6483 (get_child_debug_event): Adjust call to
6484 handle_output_debug_string.
6486 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6488 * linux-mips-low.c (mips_fill_gregset): Add cast.
6489 (mips_store_gregset): Likewise.
6490 (mips_fill_fpregset): Likewise.
6491 (mips_store_fpregset): Likewise.
6493 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6495 * linux-mips-low.c (mips_add_watchpoint): Rename private to
6498 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6500 * linux-mips-low.c (mips_linux_new_thread): Change type of
6501 watch_type to enum target_hw_bp_type.
6503 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6505 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
6506 Change return type to arm_hwbp_type.
6508 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6510 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
6511 (arm_store_gregset): Likewise.
6512 * linux-arm-low.c (arm_get_hwcap): Likewise.
6513 (arm_read_description): Likewise.
6515 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6517 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
6519 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6521 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
6522 (ppc_fill_vsxregset): Likewise.
6523 (ppc_store_vsxregset): Likewise.
6524 (ppc_fill_vrregset): Likewise.
6525 (ppc_store_vrregset): Likewise.
6526 (ppc_fill_evrregset): Likewise.
6527 (ppc_store_evrregset): Likewise.
6529 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6531 * linux-ppc-low.c (ppc_usrregs_info): Remove
6532 forward-declaration.
6533 (ppc_arch_setup): Move lower in file.
6535 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
6537 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
6538 (ps_pdwrite): Likewise.
6540 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
6542 * linux-arm-low.c (arm_new_thread): Move pointer dereference
6543 to after assert checks.
6545 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
6547 * proc-service.c (ps_pdread): Add/adjust casts.
6548 (ps_pdwrite): Add/adjust casts.
6550 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
6552 * server.c (handle_search_memory_1): Cast return value of
6555 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
6557 * server.c (write_qxfer_response): Change type of data to
6560 2015-10-29 Pedro Alves <palves@redhat.com>
6562 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
6564 2015-10-29 Pedro Alves <palves@redhat.com>
6566 * tracepoint.c (clear_installed_tracepoints): Add casts.
6568 2015-10-29 Pedro Alves <palves@redhat.com>
6570 * server.c (handle_v_cont, process_serial_event): Add enum
6571 gdb_signal casts to signal parsing code.
6573 2015-10-29 Pedro Alves <palves@redhat.com>
6575 * linux-low.h (NULL_REGSET): Define.
6576 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
6577 * linux-arm-low.c (arm_regsets): Likewise.
6578 * linux-crisv32-low.c (cris_regsets): Likewise.
6579 * linux-m68k-low.c (m68k_regsets): Likewise.
6580 * linux-mips-low.c (mips_regsets): Likewise.
6581 * linux-nios2-low.c (nios2_regsets): Likewise.
6582 * linux-ppc-low.c (ppc_regsets): Likewise.
6583 * linux-s390-low.c (s390_regsets): Likewise.
6584 * linux-sh-low.c (sh_regsets): Likewise.
6585 * linux-sparc-low.c (sparc_regsets): Likewise.
6586 * linux-tic6x-low.c (tic6x_regsets): Likewise.
6587 * linux-tile-low.c (tile_regsets): Likewise.
6588 * linux-x86-low.c (x86_regsets): Likewise.
6589 * linux-xtensa-low.c (xtensa_regsets): Likewise.
6591 2015-10-29 Pedro Alves <palves@redhat.com>
6593 * linux-low.h (NULL_REGSET): Define.
6594 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
6595 * linux-arm-low.c (arm_regsets): Likewise.
6596 * linux-crisv32-low.c (cris_regsets): Likewise.
6597 * linux-m68k-low.c (m68k_regsets): Likewise.
6598 * linux-mips-low.c (mips_regsets): Likewise.
6599 * linux-nios2-low.c (nios2_regsets): Likewise.
6600 * linux-ppc-low.c (ppc_regsets): Likewise.
6601 * linux-s390-low.c (s390_regsets): Likewise.
6602 * linux-sh-low.c (sh_regsets): Likewise.
6603 * linux-sparc-low.c (sparc_regsets): Likewise.
6604 * linux-tic6x-low.c (tic6x_regsets): Likewise.
6605 * linux-tile-low.c (tile_regsets): Likewise.
6606 * linux-x86-low.c (x86_regsets): Likewise.
6607 * linux-xtensa-low.c (xtensa_regsets): Likewise.
6609 2015-10-26 Doug Evans <dje@google.com>
6611 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
6613 2015-10-26 Doug Evans <dje@google.com>
6615 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
6617 2015-10-26 Doug Evans <dje@google.com>
6619 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
6621 (attach_thread, find_new_threads_callback): Ditto.
6623 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
6625 * mem-break.h (set_breakpoint_data): Remove.
6627 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
6629 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
6630 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
6631 (initialize_low): Remove set_breakpoint_data call.
6632 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
6633 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
6634 (initialize_low): Remove set_breakpoint_data call.
6635 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
6636 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
6637 (initialize_low): Remove set_breakpoint_data call.
6639 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
6641 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
6642 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
6643 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
6644 * target.h (target_breakpoint_kind_from_pc): New macro.
6646 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
6648 * linux-low.c (default_breakpoint_kind_from_pc): New function.
6649 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
6650 the default breakpoint kind.
6652 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6654 * linux-arm-low.c (arm_supports_z_point_type): Add software
6657 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6659 * linux-arm-low.c: Refactor breakpoint definitions.
6660 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
6661 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
6663 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6665 * Makefile.in: Add arm.c/o.
6666 * configure.srv: Likewise.
6667 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
6668 (arm_breakpoint_kind_from_pc): New function.
6669 (arm_sw_breakpoint_from_kind): Return proper kind.
6670 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
6672 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6674 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
6676 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
6677 (struct raw_breakpoint) <size>: Remove.
6678 (struct raw_breakpoint) <kind>: Add.
6679 (bp_size): New function.
6680 (bp_opcode): Likewise.
6681 (find_raw_breakpoint_at): Adjust for kind.
6682 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
6683 (remove_memory_breakpoint): Adjust for kind call bp_size.
6684 (set_raw_breakpoint_at): Adjust for kind.
6685 (set_breakpoint): Likewise.
6686 (set_breakpoint_at): Call breakpoint_kind_from_pc.
6687 (delete_raw_breakpoint): Adjust for kind.
6688 (delete_breakpoint): Likewise.
6689 (find_gdb_breakpoint): Likewise.
6690 (set_gdb_breakpoint_1): Likewise.
6691 (set_gdb_breakpoint): Likewise.
6692 (delete_gdb_breakpoint_1): Likewise.
6693 (delete_gdb_breakpoint): Likewise.
6694 (uninsert_raw_breakpoint): Likewise.
6695 (reinsert_raw_breakpoint): Likewise.
6696 (set_breakpoint_data): Remove.
6697 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
6698 (check_mem_read): Adjust for kind call bp_size.
6699 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
6700 (clone_one_breakpoint): Adjust for kind.
6701 * mem-break.h (set_gdb_breakpoint): Likewise.
6702 (delete_gdb_breakpoint): Likewise.
6703 * server.c (process_serial_event): Likewise.
6705 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6707 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
6708 (struct linux_target_ops) <breakpoint>: Remove.
6709 (struct linux_target_ops) <breakpoint_len>: Remove.
6710 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6711 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6712 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
6713 (arm_sw_breakpoint_from_kind): New function.
6714 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
6715 (struct linux_target_ops) <breakpoint>: Remove.
6716 (struct linux_target_ops) <breakpoint_len>: Remove.
6717 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6718 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6719 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
6720 (struct linux_target_ops) <breakpoint>: Remove.
6721 (struct linux_target_ops) <breakpoint_len>: Remove.
6722 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6723 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6724 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
6725 (struct linux_target_ops) <breakpoint>: Remove.
6726 (struct linux_target_ops) <breakpoint_len>: Remove.
6727 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6728 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6729 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
6730 and sw_breakpoint_from_kind to increment the pc.
6731 (linux_breakpoint_kind_from_pc): New function.
6732 (linux_sw_breakpoint_from_kind): New function.
6733 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
6734 (initialize_low): Call breakpoint_kind_from_pc and
6735 sw_breakpoint_from_kind to replace breakpoint_data/len.
6736 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
6738 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
6739 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
6740 (struct linux_target_ops) <breakpoint>: Remove.
6741 (struct linux_target_ops) <breakpoint_len>: Remove.
6742 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6743 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6744 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
6745 (struct linux_target_ops) <breakpoint>: Remove.
6746 (struct linux_target_ops) <breakpoint_len>: Remove.
6747 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6748 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6749 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
6750 (struct linux_target_ops) <breakpoint>: Remove.
6751 (struct linux_target_ops) <breakpoint_len>: Remove.
6752 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6753 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6754 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
6755 (struct linux_target_ops) <breakpoint>: Remove.
6756 (struct linux_target_ops) <breakpoint_len>: Remove.
6757 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6758 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6759 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
6760 (struct linux_target_ops) <breakpoint>: Remove.
6761 (struct linux_target_ops) <breakpoint_len>: Remove.
6762 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6763 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6764 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
6765 (struct linux_target_ops) <breakpoint>: Remove.
6766 (struct linux_target_ops) <breakpoint_len>: Remove.
6767 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6768 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6769 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
6770 (struct linux_target_ops) <breakpoint>: Remove.
6771 (struct linux_target_ops) <breakpoint_len>: Remove.
6772 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6773 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6774 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
6775 (struct linux_target_ops) <breakpoint>: Remove.
6776 (struct linux_target_ops) <breakpoint_len>: Remove.
6777 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6778 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6779 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
6780 (struct linux_target_ops) <breakpoint>: Remove.
6781 (struct linux_target_ops) <breakpoint_len>: Remove.
6782 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6783 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6784 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
6785 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
6786 (struct linux_target_ops) <breakpoint>: Remove.
6787 (struct linux_target_ops) <breakpoint_len>: Remove.
6788 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6789 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6790 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
6791 (struct linux_target_ops) <breakpoint>: Remove.
6792 (struct linux_target_ops) <breakpoint_len>: Remove.
6793 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6794 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6796 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6798 * linux-cris-low.c (cris_get_pc): Remove void arg.
6800 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
6802 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
6805 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
6807 * inferiors.c (thread_pid_matches_callback): New function.
6808 (find_thread_process): New function.
6809 (remove_thread): Reset current_thread.
6810 (remove_process): Assert threads have been removed first.
6812 2015-10-15 Yao Qi <yao.qi@linaro.org>
6814 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
6816 (aarch64_remove_point): Likewise.
6817 * regcache.c (regcache_register_size): New function.
6819 2015-10-12 Yao Qi <yao.qi@linaro.org>
6821 * linux-aarch64-low.c: Update all callers as emit_load_store
6822 is renamed to aarch64_emit_load_store.
6824 2015-10-12 Yao Qi <yao.qi@linaro.org>
6826 * linux-aarch64-low.c: Update all callers of function renaming
6827 from emit_insn to aarch64_emit_insn.
6829 2015-10-12 Yao Qi <yao.qi@linaro.org>
6831 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
6832 arch/aarch64-insn.h.
6833 (struct aarch64_memory_operand): Likewise.
6835 (emit_insn): Move to arch/aarch64-insn.c.
6836 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
6837 (emit_load_store): Move to arch/aarch64-insn.c.
6838 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
6839 (can_encode_int32): Remove.
6841 2015-10-12 Yao Qi <yao.qi@linaro.org>
6843 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
6844 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
6845 (aarch64_relocate_instruction): Likewise.
6846 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
6847 (struct aarch64_insn_visitor): Likewise.
6849 2015-10-12 Yao Qi <yao.qi@linaro.org>
6851 * linux-aarch64-low.c (struct aarch64_insn_data): New.
6852 (struct aarch64_insn_visitor): New.
6853 (struct aarch64_insn_relocation_data): New.
6854 (aarch64_ftrace_insn_reloc_b): New function.
6855 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
6856 (aarch64_ftrace_insn_reloc_cb): Likewise.
6857 (aarch64_ftrace_insn_reloc_tb): Likewise.
6858 (aarch64_ftrace_insn_reloc_adr): Likewise.
6859 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
6860 (aarch64_ftrace_insn_reloc_others): Likewise.
6862 (aarch64_relocate_instruction): Use visitor.
6864 2015-10-12 Yao Qi <yao.qi@linaro.org>
6866 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
6867 int. Add argument buf.
6868 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
6869 aarch64_relocate_instruction.
6871 2015-10-12 Yao Qi <yao.qi@linaro.org>
6873 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
6874 argument insn. Remove local variable insn. Don't call
6876 (aarch64_install_fast_tracepoint_jump_pad): Call
6879 2015-09-30 Yao Qi <yao.qi@linaro.org>
6881 * linux-aarch64-low.c (emit_movk): Shorten a long line.
6882 (emit_load_store_pair): Likewise.
6884 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
6886 * dll.c (match_dll): Add cast(s).
6887 (unloaded_dll): Likewise.
6888 * linux-low.c (second_thread_of_pid_p): Likewise.
6889 (delete_lwp_callback): Likewise.
6890 (count_events_callback): Likewise.
6891 (select_event_lwp_callback): Likewise.
6892 (linux_set_resume_request): Likewise.
6893 * server.c (accumulate_file_name_length): Likewise.
6894 (emit_dll_description): Likewise.
6895 (handle_qxfer_threads_worker): Likewise.
6896 (visit_actioned_threads): Likewise.
6897 * thread-db.c (any_thread_of): Likewise.
6898 * tracepoint.c (same_process_p): Likewise.
6899 (match_blocktype): Likewise.
6900 (build_traceframe_info_xml): Likewise.
6902 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
6904 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
6906 (gdb_unparse_agent_expr): Likewise.
6907 * hostio.c (require_data): Likewise.
6908 (handle_pread): Likewise.
6909 * linux-low.c (disable_regset): Likewise.
6910 (fetch_register): Likewise.
6911 (store_register): Likewise.
6912 (get_dynamic): Likewise.
6913 (linux_qxfer_libraries_svr4): Likewise.
6914 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
6915 (set_fast_tracepoint_jump): Likewise.
6916 (uninsert_fast_tracepoint_jumps_at): Likewise.
6917 (reinsert_fast_tracepoint_jumps_at): Likewise.
6918 (validate_inserted_breakpoint): Likewise.
6919 (clone_agent_expr): Likewise.
6920 * regcache.c (init_register_cache): Likewise.
6921 * remote-utils.c (putpkt_binary_1): Likewise.
6922 (decode_M_packet): Likewise.
6923 (decode_X_packet): Likewise.
6924 (look_up_one_symbol): Likewise.
6925 (relocate_instruction): Likewise.
6926 (monitor_output): Likewise.
6927 * server.c (handle_search_memory): Likewise.
6928 (handle_qxfer_exec_file): Likewise.
6929 (handle_qxfer_libraries): Likewise.
6930 (handle_qxfer): Likewise.
6931 (handle_query): Likewise.
6932 (handle_v_cont): Likewise.
6933 (handle_v_run): Likewise.
6934 (captured_main): Likewise.
6935 * target.c (write_inferior_memory): Likewise.
6936 * thread-db.c (try_thread_db_load_from_dir): Likewise.
6937 * tracepoint.c (init_trace_buffer): Likewise.
6938 (add_tracepoint_action): Likewise.
6939 (add_traceframe): Likewise.
6940 (add_traceframe_block): Likewise.
6941 (cmd_qtdpsrc): Likewise.
6942 (cmd_qtdv): Likewise.
6943 (cmd_qtstatus): Likewise.
6944 (response_source): Likewise.
6945 (response_tsv): Likewise.
6946 (cmd_qtnotes): Likewise.
6947 (gdb_collect): Likewise.
6948 (initialize_tracepoint): Likewise.
6950 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
6952 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
6953 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
6954 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
6956 (enum aarch64_condition_codes): New enum.
6957 (w0): New static global.
6960 (struct aarch64_memory_operand) <type>: New
6961 MEMORY_OPERAND_POSTINDEX type.
6962 (postindex_memory_operand): New helper function.
6963 (emit_ret): New function.
6964 (emit_load_store_pair): New function, factored out of emit_stp
6965 with support for MEMORY_OPERAND_POSTINDEX.
6966 (emit_stp): Rewrite using emit_load_store_pair.
6967 (emit_ldp): New function.
6968 (emit_load_store): Likewise.
6969 (emit_ldr): Mention post-index instruction in comment.
6970 (emit_ldrh): New function.
6971 (emit_ldrb): New function.
6972 (emit_ldrsw): Mention post-index instruction in comment.
6973 (emit_str): Likewise.
6974 (emit_subs): New function.
6975 (emit_cmp): Likewise.
6976 (emit_and): Likewise.
6977 (emit_orr): Likewise.
6978 (emit_orn): Likewise.
6979 (emit_eor): Likewise.
6980 (emit_mvn): Likewise.
6981 (emit_lslv): Likewise.
6982 (emit_lsrv): Likewise.
6983 (emit_asrv): Likewise.
6984 (emit_mul): Likewise.
6985 (emit_sbfm): Likewise.
6986 (emit_sbfx): Likewise.
6987 (emit_ubfm): Likewise.
6988 (emit_ubfx): Likewise.
6989 (emit_csinc): Likewise.
6990 (emit_cset): Likewise.
6991 (emit_nop): Likewise.
6992 (emit_ops_insns): New helper function.
6993 (emit_pop): Likewise.
6994 (emit_push): Likewise.
6995 (aarch64_emit_prologue): New function.
6996 (aarch64_emit_epilogue): Likewise.
6997 (aarch64_emit_add): Likewise.
6998 (aarch64_emit_sub): Likewise.
6999 (aarch64_emit_mul): Likewise.
7000 (aarch64_emit_lsh): Likewise.
7001 (aarch64_emit_rsh_signed): Likewise.
7002 (aarch64_emit_rsh_unsigned): Likewise.
7003 (aarch64_emit_ext): Likewise.
7004 (aarch64_emit_log_not): Likewise.
7005 (aarch64_emit_bit_and): Likewise.
7006 (aarch64_emit_bit_or): Likewise.
7007 (aarch64_emit_bit_xor): Likewise.
7008 (aarch64_emit_bit_not): Likewise.
7009 (aarch64_emit_equal): Likewise.
7010 (aarch64_emit_less_signed): Likewise.
7011 (aarch64_emit_less_unsigned): Likewise.
7012 (aarch64_emit_ref): Likewise.
7013 (aarch64_emit_if_goto): Likewise.
7014 (aarch64_emit_goto): Likewise.
7015 (aarch64_write_goto_address): Likewise.
7016 (aarch64_emit_const): Likewise.
7017 (aarch64_emit_call): Likewise.
7018 (aarch64_emit_reg): Likewise.
7019 (aarch64_emit_pop): Likewise.
7020 (aarch64_emit_stack_flush): Likewise.
7021 (aarch64_emit_zero_ext): Likewise.
7022 (aarch64_emit_swap): Likewise.
7023 (aarch64_emit_stack_adjust): Likewise.
7024 (aarch64_emit_int_call_1): Likewise.
7025 (aarch64_emit_void_call_2): Likewise.
7026 (aarch64_emit_eq_goto): Likewise.
7027 (aarch64_emit_ne_goto): Likewise.
7028 (aarch64_emit_lt_goto): Likewise.
7029 (aarch64_emit_le_goto): Likewise.
7030 (aarch64_emit_gt_goto): Likewise.
7031 (aarch64_emit_ge_got): Likewise.
7032 (aarch64_emit_ops_impl): New static global variable.
7033 (aarch64_emit_ops): New target function, return
7034 &aarch64_emit_ops_impl.
7035 (struct linux_target_ops): Install it.
7037 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
7039 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
7040 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
7042 * linux-aarch64-ipa.c: New file.
7043 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
7045 (aarch64_get_thread_area): New target method.
7046 (extract_signed_bitfield): New helper function.
7047 (aarch64_decode_ldr_literal): New function.
7048 (enum aarch64_opcodes): New enum.
7049 (struct aarch64_register): New struct.
7050 (struct aarch64_operand): New struct.
7051 (x0): New static global.
7060 (aarch64_register): New helper function.
7061 (register_operand): Likewise.
7062 (immediate_operand): Likewise.
7063 (struct aarch64_memory_operand): New struct.
7064 (offset_memory_operand): New helper function.
7065 (preindex_memory_operand): Likewise.
7066 (enum aarch64_system_control_registers): New enum.
7067 (ENCODE): New macro.
7068 (emit_insn): New helper function.
7069 (emit_b): New function.
7070 (emit_bcond): Likewise.
7071 (emit_cb): Likewise.
7072 (emit_tb): Likewise.
7073 (emit_blr): Likewise.
7074 (emit_stp): Likewise.
7075 (emit_ldp_q_offset): Likewise.
7076 (emit_stp_q_offset): Likewise.
7077 (emit_load_store): Likewise.
7078 (emit_ldr): Likewise.
7079 (emit_ldrsw): Likewise.
7080 (emit_str): Likewise.
7081 (emit_ldaxr): Likewise.
7082 (emit_stxr): Likewise.
7083 (emit_stlr): Likewise.
7084 (emit_data_processing_reg): Likewise.
7085 (emit_data_processing): Likewise.
7086 (emit_add): Likewise.
7087 (emit_sub): Likewise.
7088 (emit_mov): Likewise.
7089 (emit_movk): Likewise.
7090 (emit_mov_addr): Likewise.
7091 (emit_mrs): Likewise.
7092 (emit_msr): Likewise.
7093 (emit_sevl): Likewise.
7094 (emit_wfe): Likewise.
7095 (append_insns): Likewise.
7096 (can_encode_int32_in): New helper function.
7097 (aarch64_relocate_instruction): New function.
7098 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
7099 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
7100 (struct linux_target_ops): Install aarch64_get_thread_area,
7101 aarch64_install_fast_tracepoint_jump_pad and
7102 aarch64_get_min_fast_tracepoint_insn_len.
7104 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
7106 * Makefile.in (aarch64-insn.o): New rule.
7107 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
7109 2015-09-21 Yao Qi <yao.qi@linaro.org>
7111 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
7113 2015-09-21 Yao Qi <yao.qi@linaro.org>
7115 * tracepoint.c (max_jump_pad_size): Remove.
7117 2015-09-18 Yao Qi <yao.qi@linaro.org>
7119 * linux-aarch64-low.c: Don't include sys/uio.h.
7120 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
7122 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
7124 * tracepoint.c (eval_result_type): Change prototype.
7125 (condition_true_at_tracepoint): Fix argument to compiled_cond.
7127 2015-09-15 Pedro Alves <palves@redhat.com>
7129 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
7130 Check whether to report exec events instead of checking whether
7131 multiprocess is enabled.
7133 2015-09-15 Pedro Alves <palves@redhat.com>
7136 * remote-utils.c (prepare_resume_reply): Merge
7137 TARGET_WAITKIND_VFORK_DONE switch case with the
7138 TARGET_WAITKIND_FORKED case.
7140 2015-09-15 Yao Qi <yao.qi@linaro.org>
7142 * server.c (handle_query): Check string comparison using
7143 "else if" instead of "if".
7145 2015-09-15 Yao Qi <yao.qi@linaro.org>
7147 * server.c (vCont_supported): New global variable.
7148 (handle_query): Set vCont_supported to 1 if "vContSupported+"
7149 matches. Append ";vContSupported+" to own_buf.
7150 (handle_v_requests): Append ";s;S" to own_buf if target supports
7151 hardware single step or vCont_supported is false.
7152 (capture_main): Set vCont_supported to zero.
7154 2015-09-15 Yao Qi <yao.qi@linaro.org>
7156 * linux-low.c (linux_supports_conditional_breakpoints): Rename
7158 (linux_supports_hardware_single_step): ... New function.
7159 (linux_target_ops): Update.
7160 * lynx-low.c (lynx_target_ops): Set field
7161 supports_hardware_single_step to target_can_do_hardware_single_step.
7162 * nto-low.c (nto_target_ops): Likewise.
7163 * spu-low.c (spu_target_ops): Likewise.
7164 * win32-low.c (win32_target_ops): Likewise.
7165 * target.c (target_can_do_hardware_single_step): New function.
7166 * target.h (struct target_ops) <supports_conditional_breakpoints>:
7167 Remove. <supports_hardware_single_step>: New field.
7168 (target_supports_conditional_breakpoints): Remove.
7169 (target_supports_hardware_single_step): New macro.
7170 (target_can_do_hardware_single_step): Declare.
7171 * server.c (handle_query): Use target_supports_hardware_single_step
7172 instead of target_supports_conditional_breakpoints.
7174 2015-09-15 Yao Qi <yao.qi@linaro.org>
7176 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
7178 (struct linux_target_ops the_low_target): Install
7179 aarch64_linux_siginfo_fixup.
7181 2015-09-11 Don Breazeal <donb@codesourcery.com>
7182 Luis Machado <lgustavo@codesourcery.com>
7184 * linux-low.c (linux_mourn): Static declaration.
7185 (linux_arch_setup): Move in front of
7186 handle_extended_wait.
7187 (linux_arch_setup_thread): New function.
7188 (handle_extended_wait): Handle exec events. Call
7189 linux_arch_setup_thread. Make event_lwp argument a
7190 pointer-to-a-pointer.
7191 (check_zombie_leaders): Do not check stopped threads.
7192 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
7193 (linux_low_filter_event): Add lwp and thread for exec'ing
7194 non-leader thread if leader thread has been deleted.
7195 Refactor code into linux_arch_setup_thread and call it.
7196 Pass child lwp pointer by reference to handle_extended_wait.
7197 (linux_wait_for_event_filtered): Update comment.
7198 (linux_wait_1): Prevent clobbering exec event status.
7199 (linux_supports_exec_events): New function.
7200 (linux_target_ops) <supports_exec_events>: Initialize new member.
7201 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
7203 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
7204 * server.c (report_exec_events): New global variable.
7205 (handle_query): Handle qSupported query for exec-events feature.
7206 (captured_main): Initialize report_exec_events.
7207 * server.h (report_exec_events): Declare new global variable.
7208 * target.h (struct target_ops) <supports_exec_events>: New
7210 (target_supports_exec_events): New macro.
7211 * win32-low.c (win32_target_ops) <supports_exec_events>:
7212 Initialize new member.
7214 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
7216 * linux-low.c (linux_low_enable_btrace): Remove.
7217 (linux_target_ops): Replace linux_low_enable_btrace with
7218 linux_enable_btrace.
7220 2015-09-03 Yao Qi <yao.qi@linaro.org>
7222 * linux-aarch64-low.c (aarch64_insert_point): Call
7223 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
7226 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
7228 * linux-low.c (check_stopped_by_breakpoint): Use
7229 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
7231 2015-08-27 Pedro Alves <palves@redhat.com>
7233 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
7235 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
7237 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
7238 the XNEW-family equivalent.
7239 (compile_bytecodes): Likewise.
7240 * dll.c (loaded_dll): Likewise.
7241 * event-loop.c (append_callback_event): Likewise.
7242 (create_file_handler): Likewise.
7243 (create_file_event): Likewise.
7244 * hostio.c (handle_open): Likewise.
7245 * inferiors.c (add_thread): Likewise.
7246 (add_process): Likewise.
7247 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
7248 * linux-arm-low.c (arm_new_process): Likewise.
7249 (arm_new_thread): Likewise.
7250 * linux-low.c (add_to_pid_list): Likewise.
7251 (linux_add_process): Likewise.
7252 (handle_extended_wait): Likewise.
7253 (add_lwp): Likewise.
7254 (enqueue_one_deferred_signal): Likewise.
7255 (enqueue_pending_signal): Likewise.
7256 (linux_resume_one_lwp_throw): Likewise.
7257 (linux_resume_one_thread): Likewise.
7258 (linux_read_memory): Likewise.
7259 (linux_write_memory): Likewise.
7260 * linux-mips-low.c (mips_linux_new_process): Likewise.
7261 (mips_linux_new_thread): Likewise.
7262 (mips_add_watchpoint): Likewise.
7263 * linux-x86-low.c (initialize_low_arch): Likewise.
7264 * lynx-low.c (lynx_add_process): Likewise.
7265 * mem-break.c (set_raw_breakpoint_at): Likewise.
7266 (set_breakpoint): Likewise.
7267 (add_condition_to_breakpoint): Likewise.
7268 (add_commands_to_breakpoint): Likewise.
7269 (clone_agent_expr): Likewise.
7270 (clone_one_breakpoint): Likewise.
7271 * regcache.c (new_register_cache): Likewise.
7272 * remote-utils.c (look_up_one_symbol): Likewise.
7273 * server.c (queue_stop_reply): Likewise.
7274 (start_inferior): Likewise.
7275 (queue_stop_reply_callback): Likewise.
7276 (handle_target_event): Likewise.
7277 * spu-low.c (fetch_ppc_memory): Likewise.
7278 (store_ppc_memory): Likewise.
7279 * target.c (set_target_ops): Likewise.
7280 * thread-db.c (thread_db_load_search): Likewise.
7281 (try_thread_db_load_1): Likewise.
7282 * tracepoint.c (add_tracepoint): Likewise.
7283 (add_tracepoint_action): Likewise.
7284 (create_trace_state_variable): Likewise.
7285 (cmd_qtdpsrc): Likewise.
7286 (cmd_qtro): Likewise.
7287 (add_while_stepping_state): Likewise.
7288 * win32-low.c (child_add_thread): Likewise.
7289 (get_image_name): Likewise.
7291 2015-08-25 Yao Qi <yao.qi@linaro.org>
7293 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
7295 2015-08-25 Yao Qi <yao.qi@linaro.org>
7297 * Makefile.in (aarch64-linux.o): New rule.
7298 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
7300 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
7301 (aarch64_init_debug_reg_state): Make it extern.
7302 (aarch64_linux_prepare_to_resume): Remove.
7304 2015-08-25 Yao Qi <yao.qi@linaro.org>
7306 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
7307 lwp_arch_private_info and ptid_of_lwp.
7309 2015-08-25 Yao Qi <yao.qi@linaro.org>
7311 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
7312 Find proc_info by find_process_pid. All callers updated.
7314 2015-08-25 Yao Qi <yao.qi@linaro.org>
7316 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
7318 (debug_reg_change_callback): Remove.
7319 (aarch64_notify_debug_reg_change): Remove.
7321 2015-08-25 Yao Qi <yao.qi@linaro.org>
7323 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
7324 Call current_lwp_ptid.
7326 2015-08-25 Yao Qi <yao.qi@linaro.org>
7328 * linux-aarch64-low.c (debug_reg_change_callback): Use
7331 2015-08-25 Yao Qi <yao.qi@linaro.org>
7333 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
7335 2015-08-25 Yao Qi <yao.qi@linaro.org>
7337 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
7339 2015-08-25 Yao Qi <yao.qi@linaro.org>
7341 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
7344 2015-08-25 Yao Qi <yao.qi@linaro.org>
7346 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
7348 (debug_reg_change_callback): Remove argument entry and add argument
7349 lwp. Remove local variable thread. Don't print thread id in the
7350 debugging output. Don't check whether pid of thread equals to pid.
7351 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
7352 iterate_over_lwps instead find_inferior.
7354 2015-08-24 Pedro Alves <palves@redhat.com>
7356 * inferiors.c (get_first_process): New function.
7357 * inferiors.h (get_first_process): New declaration.
7358 * remote-utils.c (read_ptid): Default to the first process in the
7359 list, instead of to the current thread's process.
7361 2015-08-24 Pedro Alves <palves@redhat.com>
7363 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
7364 * event-loop.c: Likewise.
7365 * remote-utils.c: Likewise.
7366 * tracepoint.c: Likewise.
7368 2015-08-24 Pedro Alves <palves@redhat.com>
7370 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
7373 2015-08-21 Pedro Alves <palves@redhat.com>
7375 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
7376 instead of literal 1.
7378 2015-08-21 Pedro Alves <palves@redhat.com>
7380 * tdesc.c (default_description): Explicitly zero-initialize.
7382 2015-08-21 Pedro Alves <palves@redhat.com>
7385 * inferiors.c (remove_thread): Discard any pending stop reply for
7387 * server.c (remove_all_on_match_pid): Rename to ...
7388 (remove_all_on_match_ptid): ... this. Work with a filter ptid
7390 (discard_queued_stop_replies): Change parameter to a ptid. Now
7392 (handle_v_kill, kill_inferior_callback, captured_main)
7393 (process_serial_event): Adjust.
7394 * server.h (discard_queued_stop_replies): Declare.
7396 2015-08-21 Pedro Alves <palves@redhat.com>
7398 * linux-low.c (wait_for_sigstop): Always switch to no thread
7399 selected if the previously current thread dies.
7400 * lynx-low.c (lynx_request_interrupt): Use the first thread's
7401 process instead of the current thread's.
7402 * remote-utils.c (input_interrupt): Don't check if there's no
7404 * server.c (gdb_read_memory, gdb_write_memory): If setting the
7405 current thread to the general thread fails, error out.
7406 (handle_qxfer_auxv, handle_qxfer_libraries)
7407 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
7408 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
7409 (handle_query): Check if there's a thread selected instead of
7410 checking whether there's any thread in the thread list.
7411 (handle_qxfer_threads, handle_qxfer_btrace)
7412 (handle_qxfer_btrace_conf): Don't error out early if there's no
7413 thread in the thread list.
7414 (handle_v_cont, myresume): Don't set the current thread to the
7416 (process_serial_event) <Hg handling>: Also set thread_id if the
7417 previous general thread is still alive.
7418 (process_serial_event) <g/G handling>: If setting the current
7419 thread to the general thread fails, error out.
7420 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
7421 thread's lwp instead of the current thread's.
7422 * target.c (set_desired_thread): If the desired thread was not
7423 found, leave the current thread pointing to NULL. Return an int
7424 (boolean) indicating success.
7425 * target.h (set_desired_thread): Change return type to int.
7427 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
7429 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
7430 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
7432 (ps_get_thread_area): New function.
7434 2015-08-19 Gary Benson <gbenson@redhat.com>
7436 * hostio.c (handle_pread): Do not attempt to read more data
7437 than hostio_reply_with_data can fit in a packet.
7439 2015-08-18 Joel Brobecker <brobecker@adacore.com>
7441 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
7443 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
7445 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
7447 2015-08-06 Pedro Alves <palves@redhat.com>
7449 * tracepoint.c (expr_eval_result): Now an int.
7451 2015-08-06 Pedro Alves <palves@redhat.com>
7453 * gdbthread.h (struct regcache): Forward declare.
7454 (struct thread_info) <regcache_data>: Now a struct regcache
7456 * inferiors.c (inferior_regcache_data)
7457 (set_inferior_regcache_data): Now work with struct regcache
7459 * inferiors.h (struct regcache): Forward declare.
7460 (inferior_regcache_data, set_inferior_regcache_data): Now work
7461 with struct regcache pointers.
7462 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
7463 (free_register_cache_thread): Remove struct regcache pointer
7466 2015-08-06 Pedro Alves <palves@redhat.com>
7468 * server.c (captured_main): On error, print the exception message
7469 to stderr, and if run_once is set, throw a quit.
7471 2015-08-06 Pedro Alves <palves@redhat.com>
7473 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
7476 2015-08-06 Pedro Alves <palves@redhat.com>
7478 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
7479 reading beyond the passed in buffer length.
7481 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
7483 * tracepoint.c (symbol_list) <required>: Remove.
7485 2015-08-06 Pedro Alves <palves@redhat.com>
7487 * linux-low.c (handle_extended_wait): Set the fork child's suspend
7488 count if stopping and suspending threads.
7489 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
7490 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
7491 (linux_detach): Complete an ongoing step-over.
7492 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
7494 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
7495 (linux_wait_1): If passing a signal to the inferior after
7496 finishing a step-over, unsuspend and re-resume all lwps. If we
7497 see a single-step event but the thread should be continuing, don't
7498 pass the trap to gdb.
7499 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
7500 internal_error instead of gdb_assert.
7501 (enqueue_pending_signal): New function.
7502 (check_ptrace_stopped_lwp_gone): Add debug output.
7503 (start_step_over): Use internal_error instead of gdb_assert.
7504 (complete_ongoing_step_over): New function.
7505 (linux_resume_one_thread): Don't resume a suspended thread.
7506 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
7509 2015-08-06 Pedro Alves <palves@redhat.com>
7511 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
7512 (linux_thread_alive): Use lwp_is_marked_dead.
7513 (extended_event_reported): Delete.
7514 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
7515 instead of extended_event_reported.
7516 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
7518 (lwp_is_marked_dead): New function.
7519 (lwp_running): Use lwp_is_marked_dead.
7520 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
7523 2015-08-06 Pedro Alves <palves@redhat.com>
7525 * linux-low.c (linux_wait_1): Move fork event output out of the
7526 !report_to_gdb check. Pass event_child->waitstatus to
7527 target_waitstatus_to_string instead of ourstatus.
7529 2015-08-04 Yao Qi <yao.qi@linaro.org>
7531 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
7532 if current_thread is 32 bit.
7534 2015-08-04 Yao Qi <yao.qi@linaro.org>
7536 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
7537 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
7538 * server.c (extended_protocol): Remove "static".
7539 * server.h (extended_protocol): Declare it.
7541 2015-08-04 Yao Qi <yao.qi@linaro.org>
7543 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
7544 both aarch64 and aarch32.
7545 (aarch64_set_pc): Likewise.
7547 2015-08-04 Yao Qi <yao.qi@linaro.org>
7549 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
7550 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
7551 arm-with-neon.xml to srv_xmlfiles.
7552 * linux-aarch64-low.c: Include linux-aarch32-low.h.
7553 (is_64bit_tdesc): New function.
7554 (aarch64_linux_read_description): New function.
7555 (aarch64_arch_setup): Call aarch64_linux_read_description.
7556 (regs_info): Rename to regs_info_aarch64.
7557 (aarch64_regs_info): Return right regs_info.
7558 (initialize_low_arch): Call initialize_low_arch_aarch32.
7560 2015-08-04 Yao Qi <yao.qi@linaro.org>
7562 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
7563 * linux-aarch32-low.c: New file.
7564 * linux-aarch32-low.h: New file.
7565 * linux-arm-low.c (arm_fill_gregset): Move it to
7566 linux-aarch32-low.c.
7567 (arm_store_gregset): Likewise.
7568 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
7569 (arm_store_vfpregset): Call arm_store_vfpregset_num.
7570 (arm_arch_setup): Check if PTRACE_GETREGSET works.
7571 (regs_info): Rename to regs_info_arm.
7572 (arm_regs_info): Return regs_info_aarch32 if
7573 have_ptrace_getregset is 1 and target description is
7574 arm_with_neon or arm_with_vfpv3.
7575 (initialize_low_arch): Don't call init_registers_arm_with_neon.
7576 Call initialize_low_arch_aarch32 instead.
7578 2015-08-04 Yao Qi <yao.qi@linaro.org>
7580 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
7581 * linux-low.c: ... here.
7582 * linux-low.h (have_ptrace_getregset): Declare it.
7584 2015-08-04 Pedro Alves <palves@redhat.com>
7586 * thread-db.c (struct thread_db): Use new typedefs.
7587 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
7589 (disable_thread_event_reporting): Cast result of dlsym to
7590 destination function pointer type.
7591 (thread_db_mourn): Use td_ta_delete_ftype.
7593 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
7595 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
7597 (CDX_BREAKPOINT): Define for R2.
7598 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
7599 (the_low_target): Add comments.
7601 2015-07-30 Yao Qi <yao.qi@linaro.org>
7603 * linux-arm-low.c (arm_hwcap): Remove it.
7604 (arm_read_description): New local variable arm_hwcap. Don't
7605 set arm_hwcap to zero.
7607 2015-07-30 Yao Qi <yao.qi@linaro.org>
7609 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
7610 Use regcache->tdesc instead.
7611 (arm_store_wmmxregset): Likewise.
7612 (arm_fill_vfpregset): Likewise.
7613 (arm_store_vfpregset): Likewise.
7615 2015-07-30 Yao Qi <yao.qi@linaro.org>
7617 * linux-arm-low.c: Include arch/arm.h.
7618 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
7619 (arm_store_gregset): Likewise.
7621 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
7623 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
7624 ptrace's 4th parameter.
7626 2015-07-27 Yao Qi <yao.qi@linaro.org>
7628 * configure.srv (case aarch64*-*-linux*): Don't set
7631 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
7633 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
7635 * linux-arm-low.c: Likewise.
7636 * linux-cris-low.c: Likewise.
7637 * linux-crisv32-low.c: Likewise.
7638 * linux-low.c: Likewise.
7639 * linux-m68k-low.c: Likewise.
7640 * linux-mips-low.c: Likewise.
7641 * linux-nios2-low.c: Likewise.
7642 * linux-s390-low.c: Likewise.
7643 * linux-sparc-low.c: Likewise.
7644 * linux-tic6x-low.c: Likewise.
7645 * linux-tile-low.c: Likewise.
7646 * linux-x86-low.c: Likewise.
7648 2015-07-24 Pedro Alves <palves@redhat.com>
7650 * config.in: Regenerate.
7651 * configure: Regenerate.
7653 2015-07-24 Pedro Alves <palves@redhat.com>
7655 * acinclude.m4: Include ../ptrace.m4.
7656 * configure.ac: Call GDB_AC_PTRACE.
7657 * config.in, configure: Regenerate.
7659 2015-07-24 Yao Qi <yao.qi@linaro.org>
7661 * linux-low.c (linux_create_inferior): Remove setting to
7662 proc->priv->new_inferior.
7663 (linux_attach): Likewise.
7664 (linux_low_filter_event): Likewise.
7665 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
7667 2015-07-24 Yao Qi <yao.qi@linaro.org>
7669 * linux-low.c (linux_arch_setup): New function.
7670 (linux_low_filter_event): If proc->tdesc is NULL and
7671 proc->attached is true, call the_low_target.arch_setup.
7672 Otherwise, keep status pending, and return.
7673 (linux_resume_one_lwp_throw): Don't call get_pc if
7674 thread->while_stepping isn't NULL. Don't call
7675 get_thread_regcache if proc->tdesc is NULL.
7676 (need_step_over_p): Return 0 if proc->tdesc is NULL.
7677 (linux_target_ops): Install arch_setup.
7678 * server.c (start_inferior): Call the_target->arch_setup.
7679 * target.h (struct target_ops) <arch_setup>: New field.
7680 (target_arch_setup): New marco.
7681 * lynx-low.c (lynx_target_ops): Update.
7682 * nto-low.c (nto_target_ops): Update.
7683 * spu-low.c (spu_target_ops): Update.
7684 * win32-low.c (win32_target_ops): Update.
7686 2015-07-24 Yao Qi <yao.qi@linaro.org>
7688 * linux-low.c (linux_add_process): Don't set
7689 proc->priv->new_inferior.
7690 (linux_create_inferior): Set proc->priv->new_inferior to 1.
7691 (linux_attach): Likewise.
7693 2015-07-24 Yao Qi <yao.qi@linaro.org>
7695 * server.c (start_inferior): Code refactor.
7697 2015-07-24 Yao Qi <yao.qi@linaro.org>
7699 * server.c (process_serial_event): Set general_thread.
7701 2015-07-21 Yao Qi <yao.qi@linaro.org>
7703 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
7704 aarch64_linux_get_debug_reg_capacity.
7706 2015-07-17 Yao Qi <yao.qi@linaro.org>
7708 * Makefile.in (aarch64-linux-hw-point.o): New rule.
7709 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
7710 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
7711 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
7712 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
7713 (AARCH64_HWP_ALIGNMENT): Likewise.
7714 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
7715 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
7716 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
7717 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
7718 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
7719 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
7720 (struct aarch64_debug_reg_state): Likewise.
7721 (struct arch_lwp_info): Likewise.
7722 (aarch64_align_watchpoint): Likewise.
7723 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
7724 (aarch64_watchpoint_length): Likewise.
7725 (aarch64_point_encode_ctrl_reg): Likewise
7726 (aarch64_point_is_aligned): Likewise.
7727 (aarch64_align_watchpoint): Likewise.
7728 (aarch64_linux_set_debug_regs):
7729 (aarch64_dr_state_insert_one_point): Likewise.
7730 (aarch64_dr_state_remove_one_point): Likewise.
7731 (aarch64_handle_breakpoint): Likewise.
7732 (aarch64_handle_aligned_watchpoint): Likewise.
7733 (aarch64_handle_unaligned_watchpoint): Likewise.
7734 (aarch64_handle_watchpoint): Likewise.
7736 2015-07-17 Yao Qi <yao.qi@linaro.org>
7738 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
7739 and don't aarch64_get_debug_reg_state. All callers update.
7740 (aarch64_handle_aligned_watchpoint): Likewise.
7741 (aarch64_handle_unaligned_watchpoint): Likewise.
7742 (aarch64_handle_watchpoint): Likewise.
7743 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
7744 (aarch64_remove_point): Likewise.
7746 2015-07-17 Yao Qi <yao.qi@linaro.org>
7748 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
7750 (aarch64_handle_unaligned_watchpoint): Likewise.
7752 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
7754 Revert the previous 3 commits:
7755 Move gdb_regex* to common/
7756 Move linux_find_memory_regions_full & co.
7757 gdbserver build-id attribute generator
7759 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
7760 Jan Kratochvil <jan.kratochvil@redhat.com>
7762 gdbserver build-id attribute generator.
7763 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
7764 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
7765 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
7767 (get_dynamic): Use find_pdhr to traverse program headers.
7768 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
7769 (compare_mapping_entry_range, struct find_memory_region_callback_data)
7770 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
7771 (get_hex_build_id): New.
7772 (linux_qxfer_libraries_svr4): Add optional build-id attribute
7773 to reply XML document.
7775 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
7776 Jan Kratochvil <jan.kratochvil@redhat.com>
7778 * target.c: Include target/target-utils.h and fcntl.h.
7779 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
7780 (target_fileio_read_stralloc): New functions.
7782 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
7784 * Makefile.in (OBS): Add gdb_regex.o.
7786 * config.in: Rebuilt.
7787 * configure: Rebuilt.
7789 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
7790 Jan Kratochvil <jan.kratochvil@redhat.com>
7792 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
7793 * Makefile.in (OBS): Add target-utils.o.
7794 (linux-maps.o, target-utils.o): New.
7795 * configure.srv (srv_linux_obj): Add linux-maps.o.
7797 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
7799 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
7801 (the_low_target): Install it.
7803 2015-07-14 Pedro Alves <palves@redhat.com>
7805 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
7806 Instead, ignore ECHILD, and throw an error for other errnos.
7808 2015-07-10 Pedro Alves <palves@redhat.com>
7810 * event-loop.c (struct callback_event) <data>: Change type to
7811 gdb_client_data instance instead of gdb_client_data pointer.
7812 (append_callback_event): Adjust.
7814 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
7816 * linux-aarch64-low.c: Add comments for each linux_target_ops
7817 method. Remove comments already covered in target_ops and
7818 linux_target_ops definitions.
7819 (the_low_target): Add comments for each unimplemented method.
7821 2015-07-09 Yao Qi <yao.qi@linaro.org>
7823 * linux-aarch64-low.c (aarch64_regmap): Remove.
7824 (aarch64_usrregs_info): Remove.
7825 (regs_info): Set field usrregs to NULL.
7827 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
7829 * linux-low.c: Include "rsp-low.h"
7830 (linux_low_encode_pt_config, linux_low_encode_raw): New.
7831 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
7832 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
7833 (handle_btrace_enable_pt): New.
7834 (handle_btrace_general_set): Support "pt".
7835 (handle_btrace_conf_general_set): Support "pt:size".
7837 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
7839 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
7842 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
7844 * linux-aarch64-low.c: Remove comment about endianness.
7845 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
7846 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
7849 2015-06-24 Gary Benson <gbenson@redhat.com>
7851 * linux-i386-ipa.c (stdint.h): Do not include.
7852 * lynx-i386-low.c (stdint.h): Likewise.
7853 * lynx-ppc-low.c (stdint.h): Likewise.
7854 * mem-break.c (stdint.h): Likewise.
7855 * thread-db.c (stdint.h): Likewise.
7856 * tracepoint.c (stdint.h): Likewise.
7857 * win32-low.c (stdint.h): Likewise.
7859 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
7861 * server.c (write_qxfer_response): Update call to
7862 remote_escape_output.
7864 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
7865 Jan Kratochvil <jan.kratochvil@redhat.com>
7867 Merge multiple hex conversions.
7868 * gdbreplay.c (tohex): Rename to 'fromhex'.
7869 (logchar): Use fromhex.
7871 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
7873 * server.c (handle_qxfer_libraries): Set `version' attribute for
7876 2015-06-10 Gary Benson <gbenson@redhat.com>
7878 * target.h (struct target_ops) <multifs_open>: New field.
7879 <multifs_unlink>: Likewise.
7880 <multifs_readlink>: Likewise.
7881 * linux-low.c (nat/linux-namespaces.h): New include.
7882 (linux_target_ops): Initialize the_target->multifs_open,
7883 the_target->multifs_unlink and the_target->multifs_readlink.
7884 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
7885 * hostio.c (hostio_fs_pid): New static variable.
7886 (hostio_handle_new_gdb_connection): New function.
7887 (handle_setfs): Likewise.
7888 (handle_open): Use the_target->multifs_open as appropriate.
7889 (handle_unlink): Use the_target->multifs_unlink as appropriate.
7890 (handle_readlink): Use the_target->multifs_readlink as
7892 (handle_vFile): Handle vFile:setfs packets.
7893 * server.c (handle_query): Call hostio_handle_new_gdb_connection
7894 after target_handle_new_gdb_connection.
7896 2015-06-10 Gary Benson <gbenson@redhat.com>
7898 * configure.ac (AC_CHECK_FUNCS): Add setns.
7899 * config.in: Regenerate.
7900 * configure: Likewise.
7901 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
7902 (linux-namespaces.o): New rule.
7903 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
7905 2015-06-09 Gary Benson <gbenson@redhat.com>
7907 * hostio.c (handle_open): Process mode argument with
7908 fileio_to_host_mode.
7910 2015-06-01 Yao Qi <yao.qi@linaro.org>
7912 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
7913 * linux-x86-low.c: Likewise.
7915 2015-05-28 Don Breazeal <donb@codesourcery.com>
7917 * linux-low.c (handle_extended_wait): Initialize
7918 thread_info.last_resume_kind for new fork children.
7920 2015-05-15 Pedro Alves <palves@redhat.com>
7922 * target.h (target_handle_new_gdb_connection): Rewrite using if
7923 wrapped in do/while.
7925 2015-05-14 Joel Brobecker <brobecker@adacore.com>
7927 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
7928 * configure, config.in: Regenerate.
7929 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
7932 2015-05-12 Don Breazeal <donb@codesourcery.com>
7934 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
7935 PTRACE_EVENT_VFORK_DONE.
7936 (linux_low_ptrace_options, extended_event_reported): Add vfork
7938 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
7939 and "vforkdone" for RSP 'T' Stop Reply Packet.
7940 * server.h (report_vfork_events): Declare
7943 2015-05-12 Don Breazeal <donb@codesourcery.com>
7945 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
7946 (the_low_target) <new_fork>: Initialize new member.
7947 * linux-arm-low.c (arm_new_fork): New function.
7948 (the_low_target) <new_fork>: Initialize new member.
7949 * linux-low.c (handle_extended_wait): Call new target function
7951 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
7952 * linux-mips-low.c (mips_add_watchpoint): New function
7953 extracted from mips_insert_point.
7954 (the_low_target) <new_fork>: Initialize new member.
7955 (mips_linux_new_fork): New function.
7956 (mips_insert_point): Call mips_add_watchpoint.
7957 * linux-x86-low.c (x86_linux_new_fork): New function.
7958 (the_low_target) <new_fork>: Initialize new member.
7960 2015-05-12 Don Breazeal <donb@codesourcery.com>
7962 * linux-low.c (handle_extended_wait): Implement return value,
7963 rename argument 'event_child' to 'event_lwp', handle
7964 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
7965 (linux_low_ptrace_options): New function.
7966 (linux_low_filter_event): Call linux_low_ptrace_options,
7967 use different argument fo linux_enable_event_reporting,
7968 use return value from handle_extended_wait.
7969 (extended_event_reported): New function.
7970 (linux_wait_1): Call extended_event_reported and set
7971 status to report fork events.
7972 (linux_write_memory): Add pid to debug message.
7973 (reset_lwp_ptrace_options_callback): New function.
7974 (linux_handle_new_gdb_connection): New function.
7975 (linux_target_ops): Initialize new structure member.
7976 * linux-low.h (struct lwp_info) <waitstatus>: New member.
7977 * lynx-low.c: Initialize new structure member.
7978 * remote-utils.c (prepare_resume_reply): Implement stop reason
7979 "fork" for "T" stop message.
7980 * server.c (handle_query): Call handle_new_gdb_connection.
7981 * server.h (report_fork_events): Declare global flag.
7982 * target.h (struct target_ops) <handle_new_gdb_connection>:
7984 (target_handle_new_gdb_connection): New macro.
7985 * win32-low.c: Initialize new structure member.
7987 2015-05-12 Don Breazeal <donb@codesourcery.com>
7989 * mem-break.c (APPEND_TO_LIST): Define macro.
7990 (clone_agent_expr): New function.
7991 (clone_one_breakpoint): New function.
7992 (clone_all_breakpoints): New function.
7993 * mem-break.h: Declare new functions.
7995 2015-05-12 Don Breazeal <donb@codesourcery.com>
7997 * linux-low.c (linux_supports_fork_events): New function.
7998 (linux_supports_vfork_events): New function.
7999 (linux_target_ops): Initialize new structure members.
8000 (initialize_low): Call linux_check_ptrace_features.
8001 * lynx-low.c (lynx_target_ops): Initialize new structure
8003 * server.c (report_fork_events, report_vfork_events):
8005 (handle_query): Add new features to qSupported packet and
8007 (captured_main): Initialize new global variables.
8008 * target.h (struct target_ops) <supports_fork_events>:
8010 <supports_vfork_events>: New member.
8011 (target_supports_fork_events): New macro.
8012 (target_supports_vfork_events): New macro.
8013 * win32-low.c (win32_target_ops): Initialize new structure
8016 2015-05-12 Gary Benson <gbenson@redhat.com>
8018 * server.c (handle_qxfer_exec_file): Use current process
8021 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
8023 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
8024 Remove HAVE_PTRACE_GETREGS conditionals.
8025 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
8026 instead of PTRACE_GETREGS and PTRACE_SETREGS.
8028 2015-05-08 Yao Qi <yao.qi@linaro.org>
8030 * linux-low.c (linux_supports_conditional_breakpoints): New
8032 (linux_target_ops): Install new target method.
8033 * lynx-low.c (lynx_target_ops): Install NULL hook for
8034 supports_conditional_breakpoints.
8035 * nto-low.c (nto_target_ops): Likewise.
8036 * spu-low.c (spu_target_ops): Likewise.
8037 * win32-low.c (win32_target_ops): Likewise.
8038 * server.c (handle_query): Check
8039 target_supports_conditional_breakpoints.
8040 * target.h (struct target_ops) <supports_conditional_breakpoints>:
8042 (target_supports_conditional_breakpoints): New macro.
8044 2015-05-06 Pedro Alves <palves@redhat.com>
8047 * server.c (start_inferior): If the process exits, mourn it.
8049 2015-04-21 Gary Benson <gbenson@redhat.com>
8051 * hostio.c (fileio_open_flags_to_host): Factored out to
8052 fileio_to_host_openflags in common/fileio.c. Single use
8055 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
8057 * linux-xtensa-low.c (xtensa_fill_gregset)
8058 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
8061 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
8063 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
8064 (regs_info): Replace usrregs pointer with NULL.
8066 2015-04-17 Gary Benson <gbenson@redhat.com>
8068 * target.h (struct target_ops) <pid_to_exec_file>: New field.
8069 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
8070 * server.c (handle_qxfer_exec_file): New function.
8071 (qxfer_packets): Add exec-file entry.
8072 (handle_query): Report qXfer:exec-file:read as supported packet.
8074 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
8076 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
8078 2015-04-09 Gary Benson <gbenson@redhat.com>
8080 * hostio-errno.c (errno_to_fileio_error): Remove function.
8081 Update caller to use remote_fileio_to_fio_error.
8083 2015-04-09 Yao Qi <yao.qi@linaro.org>
8085 * linux-low.c (linux_insert_point): Call
8086 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
8087 (linux_remove_point): Call remove_memory_breakpoint if type is
8089 * linux-x86-low.c (x86_insert_point): Don't call
8090 insert_memory_breakpoint.
8091 (x86_remove_point): Don't call remove_memory_breakpoint.
8093 2015-04-01 Pedro Alves <palves@redhat.com>
8094 Cleber Rosa <crosa@redhat.com>
8096 * server.c (gdbserver_usage): Reorganize and extend the usage
8099 2015-03-24 Pedro Alves <palves@redhat.com>
8101 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
8102 output. Also dump TRAP_TRACE.
8103 (linux_low_filter_event): In debug output, distinguish a
8104 resume_stop SIGSTOP from a delayed SIGSTOP.
8106 2015-03-24 Gary Benson <gbenson@redhat.com>
8108 * linux-x86-low.c (x86_linux_new_thread): Moved to
8110 (x86_linux_prepare_to_resume): Likewise.
8112 2015-03-24 Gary Benson <gbenson@redhat.com>
8114 * Makefile.in (x86-linux-dregs.o): New rule.
8115 * configure.srv: Add x86-linux-dregs.o to relevant targets.
8116 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
8117 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
8118 (x86_linux_dr_get): Likewise.
8119 (x86_linux_dr_set): Likewise.
8120 (update_debug_registers_callback): Likewise.
8121 (x86_linux_dr_set_addr): Likewise.
8122 (x86_linux_dr_get_addr): Likewise.
8123 (x86_linux_dr_set_control): Likewise.
8124 (x86_linux_dr_get_control): Likewise.
8125 (x86_linux_dr_get_status): Likewise.
8126 (x86_linux_update_debug_registers): Likewise.
8128 2015-03-24 Gary Benson <gbenson@redhat.com>
8130 * linux-x86-low.c (x86_linux_update_debug_registers):
8131 New function, factored out from...
8132 (x86_linux_prepare_to_resume): ...this.
8134 2015-03-24 Gary Benson <gbenson@redhat.com>
8136 * linux-x86-low.c (x86_linux_dr_get): Update comments.
8137 (x86_linux_dr_set): Likewise.
8138 (update_debug_registers_callback): Likewise.
8139 (x86_linux_dr_set_addr): Likewise.
8140 (x86_linux_dr_get_addr): Likewise.
8141 (x86_linux_dr_set_control): Likewise.
8142 (x86_linux_dr_get_control): Likewise.
8143 (x86_linux_dr_get_status): Likewise.
8144 (x86_linux_prepare_to_resume): Likewise.
8146 2015-03-24 Gary Benson <gbenson@redhat.com>
8148 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
8149 Use perror_with_name. Pass string through gettext.
8150 (x86_linux_dr_set): Likewise.
8152 2015-03-24 Gary Benson <gbenson@redhat.com>
8154 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
8155 (x86_linux_dr_set_addr): ...this.
8156 (x86_dr_low_get_addr): Rename to...
8157 (x86_linux_dr_get_addr): ...this.
8158 (x86_dr_low_set_control): Rename to...
8159 (x86_linux_dr_set_control): ...this.
8160 (x86_dr_low_get_control): Rename to...
8161 (x86_linux_dr_get_control): ...this.
8162 (x86_dr_low_get_status): Rename to...
8163 (x86_linux_dr_get_status): ...this.
8164 (x86_dr_low): Update with new function names.
8166 2015-03-24 Gary Benson <gbenson@redhat.com>
8168 * Makefile.in (x86-linux.o): New rule.
8169 * configure.srv: Add x86-linux.o to relevant targets.
8170 * linux-low.c (lwp_set_arch_private_info): New function.
8171 (lwp_arch_private_info): Likewise.
8172 * linux-x86-low.c: Include nat/x86-linux.h.
8173 (arch_lwp_info): Removed structure.
8174 (update_debug_registers_callback):
8175 Use lwp_set_debug_registers_changed.
8176 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
8177 and lwp_set_debug_registers_changed.
8178 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
8180 2015-03-24 Gary Benson <gbenson@redhat.com>
8182 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
8183 * linux-arm-low.c (arm_new_thread): Likewise.
8184 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
8185 * linux-mips-low.c (mips_linux_new_thread): Likewise.
8186 * linux-x86-low.c (x86_linux_new_thread): Likewise.
8187 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
8189 2015-03-24 Gary Benson <gbenson@redhat.com>
8191 * linux-low.c (ptid_of_lwp): New function.
8192 (lwp_is_stopped): Likewise.
8193 (lwp_stop_reason): Likewise.
8194 * linux-x86-low.c (update_debug_registers_callback):
8196 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
8199 2015-03-24 Gary Benson <gbenson@redhat.com>
8201 * linux-low.h (linux_stop_lwp): Remove declaration.
8203 2015-03-24 Gary Benson <gbenson@redhat.com>
8205 * linux-low.h: Include nat/linux-nat.h.
8206 * linux-low.c (iterate_over_lwps_args): New structure.
8207 (iterate_over_lwps_filter): New function.
8208 (iterate_over_lwps): Likewise.
8209 * linux-x86-low.c (update_debug_registers_callback):
8210 Update signature to what iterate_over_lwps expects.
8211 Remove PID check that iterate_over_lwps now performs.
8212 (x86_dr_low_set_addr): Use iterate_over_lwps.
8213 (x86_dr_low_set_control): Likewise.
8215 2015-03-24 Gary Benson <gbenson@redhat.com>
8217 * linux-x86-low.c (x86_debug_reg_state): New function.
8218 (x86_linux_prepare_to_resume): Use the above.
8220 2015-03-24 Gary Benson <gbenson@redhat.com>
8222 * linux-low.c (current_lwp_ptid): New function.
8223 * linux-x86-low.c: Include nat/linux-nat.h.
8224 (x86_dr_low_get_addr): Use current_lwp_ptid.
8225 (x86_dr_low_get_control): Likewise.
8226 (x86_dr_low_get_status): Likewise.
8228 2015-03-20 Pedro Alves <palves@redhat.com>
8230 * tracepoint.c (cmd_qtstatus): Make "str" const.
8232 2015-03-20 Pedro Alves <palves@redhat.com>
8234 * server.c (handle_general_set): Make "req_str" const.
8236 2015-03-19 Pedro Alves <palves@redhat.com>
8238 * linux-low.c (linux_resume_one_lwp): Rename to ...
8239 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
8240 instead call perror_with_name.
8241 (check_ptrace_stopped_lwp_gone): New function.
8242 (linux_resume_one_lwp): Reimplement as wrapper around
8243 linux_resume_one_lwp_throw that swallows errors if the LWP is
8246 2015-03-19 Pedro Alves <palves@redhat.com>
8248 * linux-low.c (count_events_callback, select_event_lwp_callback):
8249 No longer check whether the thread has resume_stop as last resume
8252 2015-03-19 Pedro Alves <palves@redhat.com>
8254 * linux-low.c (count_events_callback, select_event_lwp_callback):
8255 Use the lwp's status_pending_p field, not the thread's.
8257 2015-03-19 Pedro Alves <palves@redhat.com>
8259 * linux-low.c (select_event_lwp_callback): Update comments to
8260 no longer mention SIGTRAP.
8262 2015-03-18 Gary Benson <gbenson@redhat.com>
8264 * server.c (handle_query): Do not report vFile:fstat as supported.
8266 2015-03-11 Gary Benson <gbenson@redhat.com>
8268 * hostio.c (sys/types.h): New include.
8269 (sys/stat.h): Likewise.
8270 (common-remote-fileio.h): Likewise.
8271 (handle_fstat): New function.
8272 (handle_vFile): Handle vFile:fstat packets.
8274 2015-03-11 Gary Benson <gbenson@redhat.com>
8276 * configure.ac (AC_CHECK_MEMBERS): Add checks for
8277 struct stat.st_blocks and struct stat.st_blksize.
8278 * configure: Regenerate.
8279 * config.in: Likewise.
8280 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
8281 (OBS): Add common-remote-fileio.o.
8282 (common-remote-fileio.o): New rule.
8284 2015-03-09 Pedro Alves <palves@redhat.com>
8286 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
8287 'struct sockaddr' pointer in 'accept' call.
8289 2015-03-09 Pedro Alves <palves@redhat.com>
8292 2015-03-07 Pedro Alves <palves@redhat.com>
8293 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
8294 or <winsock2.h> here. Instead include "gdb_socket.h".
8295 (remote_open): Use union gdb_sockaddr_u.
8296 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
8297 or <winsock2.h> here. Instead include "gdb_socket.h".
8298 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
8299 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
8301 (init_named_socket, gdb_agent_helper_thread): Use union
8304 2015-03-07 Pedro Alves <palves@redhat.com>
8306 * configure.ac (build_warnings): Move
8307 -Wdeclaration-after-statement to the C-specific set.
8308 * configure: Regenerate.
8310 2015-03-07 Pedro Alves <palves@redhat.com>
8312 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
8313 or <winsock2.h> here. Instead include "gdb_socket.h".
8314 (remote_open): Use union gdb_sockaddr_u.
8315 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
8316 or <winsock2.h> here. Instead include "gdb_socket.h".
8317 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
8318 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
8320 (init_named_socket, gdb_agent_helper_thread): Use union
8323 2015-03-07 Pedro Alves <palves@redhat.com>
8325 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
8328 2015-03-06 Yao Qi <yao.qi@linaro.org>
8330 * linux-aarch64-low.c (aarch64_insert_point): Use
8331 show_debug_regs as a boolean.
8332 (aarch64_remove_point): Likewise.
8334 2015-03-05 Pedro Alves <palves@redhat.com>
8336 * lynx-low.c (lynx_target_ops): Install NULL hooks for
8337 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
8338 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
8339 * nto-low.c (nto_target_ops): Likewise.
8340 * spu-low.c (spu_target_ops): Likewise.
8341 * win32-low.c (win32_target_ops): Likewise.
8343 2015-03-04 Pedro Alves <palves@redhat.com>
8345 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
8346 Decide whether a breakpoint triggered based on the SIGTRAP's
8348 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
8349 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
8350 (linux_low_filter_event): Check for breakpoints before checking
8352 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
8354 (linux_stopped_by_sw_breakpoint)
8355 (linux_supports_stopped_by_sw_breakpoint)
8356 (linux_stopped_by_hw_breakpoint)
8357 (linux_supports_stopped_by_hw_breakpoint): New functions.
8358 (linux_target_ops): Install new target methods.
8360 2015-03-04 Pedro Alves <palves@redhat.com>
8362 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
8363 * server.c (swbreak_feature, hwbreak_feature): New globals.
8364 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
8365 (captured_main): Clear swbreak_feature and hwbreak_feature.
8366 * server.h (swbreak_feature, hwbreak_feature): Declare.
8367 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
8368 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
8369 supports_stopped_by_hw_breakpoint>: New fields.
8370 (target_supports_stopped_by_sw_breakpoint)
8371 (target_stopped_by_sw_breakpoint)
8372 (target_supports_stopped_by_hw_breakpoint)
8373 (target_stopped_by_hw_breakpoint): Declare.
8375 2015-03-04 Pedro Alves <palves@redhat.com>
8377 enum lwp_stop_reason -> enum target_stop_reason
8378 * linux-low.c (check_stopped_by_breakpoint): Adjust.
8379 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
8380 (linux_wait_1, stuck_in_jump_pad_callback)
8381 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
8382 (linux_stopped_by_watchpoint):
8383 * linux-low.h (enum lwp_stop_reason): Delete.
8384 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
8385 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
8387 2015-03-04 Yao Qi <yao.qi@linaro.org>
8389 * Makefile.in (SFILES): Add linux-aarch64-low.c.
8391 2015-03-03 Gary Benson <gbenson@redhat.com>
8393 * hostio.c (handle_vFile): Fix prefix lengths.
8395 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
8397 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
8400 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
8402 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
8403 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
8404 (clean): Add "rm -f" for above C files.
8405 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
8406 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
8407 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
8408 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
8409 * linux-s390-low.c (HWCAP_S390_VX): New macro.
8410 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
8411 (init_registers_s390x_vx_linux64)
8412 (init_registers_s390x_tevx_linux64)
8413 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
8414 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
8416 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
8417 (s390_store_vxrs_high): New functions.
8418 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
8420 (s390_arch_setup): Add logic for selecting one of the new target
8421 descriptions. Activate the new vector regsets if applicable.
8422 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
8423 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
8424 and init_registers_s390x_tevx_linux64.
8426 2015-03-01 Pedro Alves <palves@redhat.com>
8428 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
8431 2015-02-27 Pedro Alves <palves@redhat.com>
8433 * linux-x86-low.c (u_debugreg_offset): New function.
8434 (x86_linux_dr_get, x86_linux_dr_set): Use it.
8436 2015-02-27 Pedro Alves <palves@redhat.com>
8438 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
8439 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
8440 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
8441 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
8442 (ps_lsetfpregs, ps_getpid)
8443 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
8444 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
8445 (ps_lsetxregs, ps_plog): Declare.
8447 2015-02-27 Pedro Alves <palves@redhat.com>
8449 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
8450 IP_AGENT_EXPORT_FUNC.
8451 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
8452 IP_AGENT_EXPORT_FUNC.
8453 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
8454 (IP_AGENT_EXPORT): Delete.
8455 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
8456 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
8457 (gdb_trampoline_buffer_error, collecting, gdb_collect)
8458 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
8459 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
8460 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
8461 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
8462 (traceframe_read_count, traceframe_write_count)
8463 (traceframes_created, trace_state_variables, get_raw_reg)
8464 (get_trace_state_variable_value, set_trace_state_variable_value)
8465 (ust_loaded, helper_thread_id, cmd_buf): Use
8466 IPA_SYM_EXPORTED_NAME.
8467 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
8468 (tracepoints) Use IP_AGENT_EXPORT_VAR.
8469 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
8470 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
8471 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
8472 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
8473 EXTERN_C_PUSH/EXTERN_C_POP.
8474 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
8475 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
8476 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
8477 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
8478 (traceframe_write_count, traceframe_read_count)
8479 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
8480 (about_to_request_buffer_space, get_trace_state_variable_value)
8481 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
8482 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
8483 EXTERN_C_PUSH/EXTERN_C_POP.
8484 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
8485 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
8486 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
8487 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
8488 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
8489 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
8490 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
8491 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
8493 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
8494 (IP_AGENT_EXPORT_VAR_DECL): Define.
8496 (gdb_agent_get_raw_reg): Declare.
8498 2015-02-27 Tom Tromey <tromey@redhat.com>
8499 Pedro Alves <palves@redhat.com>
8501 Rename symbols whose names are reserved C++ keywords throughout.
8503 2015-02-27 Pedro Alves <palves@redhat.com>
8505 * Makefile.in (COMPILER): New, get it from autoconf.
8506 (CXX): Get from autoconf instead.
8507 (COMPILE.pre): Use COMPILER.
8508 (CC-LD): Rename to ...
8509 (CC_LD): ... this. Use COMPILER.
8510 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
8511 (CXX_FOR_TARGET): Default to g++ instead of gcc.
8512 * acinclude.m4: Include build-with-cxx.m4.
8513 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
8514 Disable -Werror by default if building in C++ mode.
8515 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
8516 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
8517 the C++ compiler. Save/restore CXXFLAGS too.
8518 * configure: Regenerate.
8520 2015-02-27 Pedro Alves <palves@redhat.com>
8522 * acinclude.m4: Include libiberty.m4.
8523 * configure.ac: Call libiberty_INIT.
8524 * config.in, configure: Regenerate.
8526 2015-02-26 Pedro Alves <palves@redhat.com>
8528 * linux-low.c (linux_wait_1): When incrementing the PC past a
8529 program breakpoint always use the_low_target.breakpoint_len as
8530 increment, rather than the maximum between that and
8531 the_low_target.decr_pc_after_break.
8533 2015-02-23 Pedro Alves <palves@redhat.com>
8535 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
8536 thread was doing a step-over; always adjust the PC if
8537 we stepped over a permanent breakpoint.
8538 (linux_wait_1): If we stepped over breakpoint that was on top of a
8539 permanent breakpoint, manually advance the PC past it.
8541 2015-02-23 Pedro Alves <palves@redhat.com>
8543 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
8545 (x86_fill_gregset, x86_store_gregset): Use it when handling
8548 2015-02-20 Pedro Alves <palves@redhat.com>
8550 * thread-db.c: Include "nat/linux-procfs.h".
8551 (thread_db_init): Skip listing new threads if the kernel supports
8552 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
8554 2015-02-20 Pedro Alves <palves@redhat.com>
8556 * linux-low.c (status_pending_p_callback): Use ptid_match.
8558 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
8560 PR breakpoints/16812
8561 * linux-low.c (wstatus_maybe_breakpoint): Remove.
8562 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
8563 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
8565 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
8567 PR breakpoints/15956
8568 * tracepoint.c (cmd_qtinit): Add check for current_thread.
8570 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
8572 * linux-low.c (linux_low_btrace_conf): Print size.
8573 * server.c (handle_btrace_conf_general_set): New.
8574 (hanle_general_set): Call handle_btrace_conf_general_set.
8575 (handle_query): Report Qbtrace-conf:bts:size as supported.
8577 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
8579 * linux-low.c (linux_low_enable_btrace): Update parameters.
8580 (linux_low_btrace_conf): New.
8581 (linux_target_ops)<to_btrace_conf>: Initialize.
8582 * server.c (current_btrace_conf): New.
8583 (handle_btrace_enable): Rename to ...
8584 (handle_btrace_enable_bts): ... this. Pass ¤t_btrace_conf
8585 to target_enable_btrace. Update comment. Update users.
8586 (handle_qxfer_btrace_conf): New.
8587 (qxfer_packets): Add btrace-conf entry.
8588 (handle_query): Report qXfer:btrace-conf:read as supported packet.
8589 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
8590 (target_ops)<read_btrace_conf>: New.
8591 (target_enable_btrace): Update parameters.
8592 (target_read_btrace_conf): New.
8594 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
8596 * server.c (handle_btrace_general_set): Remove call to
8597 target_supports_btrace.
8598 (supported_btrace_packets): New.
8599 (handle_query): Call supported_btrace_packets.
8600 * target.h: include btrace-common.h.
8601 (btrace_target_info): Removed.
8602 (supports_btrace, target_supports_btrace): Update parameters.
8604 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
8606 * Makefile.in (SFILES): Add common/btrace-common.c.
8607 (OBS): Add common/btrace-common.o.
8608 (btrace-common.o): Add build rules.
8609 * linux-low: Include btrace-common.h.
8610 (linux_low_read_btrace): Use struct btrace_data. Call
8611 btrace_data_init and btrace_data_fini.
8613 2015-02-06 Pedro Alves <palves@redhat.com>
8615 * thread-db.c (find_new_threads_callback): Add debug output.
8617 2015-02-04 Pedro Alves <palves@redhat.com>
8619 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
8620 (resume_stopped_resumed_lwps): New function.
8621 (linux_wait_for_event_filtered): Use it.
8623 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
8625 * Makefile.in (SFILES): Add linux-personality.c.
8626 (linux-personality.o): New rule.
8627 * configure.srv (srv_linux_obj): Add linux-personality.o to the
8628 list of objects to be built.
8629 * linux-low.c: Include nat/linux-personality.h.
8630 (linux_create_inferior): Remove code to disable address space
8631 randomization (moved to ../nat/linux-personality.c). Create
8632 cleanup to disable address space randomization.
8634 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
8636 * Makefile.in (posix-strerror.o): New rule.
8637 (mingw-strerror.o): Likewise.
8638 * configure: Regenerated.
8639 * configure.ac: Source file ../common/common.host. Initialize new
8640 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
8642 2015-01-14 Yao Qi <yao@codesourcery.com>
8644 * Makefile.in (SFILES): Add nat/ppc-linux.c.
8645 (ppc-linux.o): New rule.
8646 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
8647 * configure.ac: AC_CHECK_FUNCS(getauxval).
8648 * config.in: Re-generated.
8649 * configure: Re-generated.
8650 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
8651 ppc64_64bit_inferior_p
8653 2015-01-14 Yao Qi <yao@codesourcery.com>
8655 * linux-ppc-low.c: Include "nat/ppc-linux.h".
8656 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
8657 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
8658 (PT_ORIG_R3, PT_TRAP): Likewise.
8659 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
8660 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
8661 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
8663 2015-01-10 Joel Brobecker <brobecker@adacore.com>
8665 * i387-fp.c (i387_cache_to_xsave): In look over
8666 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
8667 zmmh_low_space field by use of zmmh_high_space.
8669 2015-01-09 Pedro Alves <palves@redhat.com>
8671 * linux-low.c (step_over_bkpt): Move higher up in the file.
8672 (handle_extended_wait): Don't store the stop_pc here.
8673 (get_stop_pc): Adjust comments and rename to ...
8674 (check_stopped_by_breakpoint): ... this. Record whether the LWP
8675 stopped for a software breakpoint or hardware breakpoint.
8676 (thread_still_has_status_pending_p): New function.
8677 (status_pending_p_callback): Use
8678 thread_still_has_status_pending_p. If the event is no longer
8679 interesting, resume the LWP.
8680 (handle_tracepoints): Add assert.
8681 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
8682 (wstatus_maybe_breakpoint): New function.
8683 (cancel_breakpoint): Delete function.
8684 (check_stopped_by_watchpoint): New function, factored out from
8685 linux_low_filter_event.
8686 (lp_status_maybe_breakpoint): Delete function.
8687 (linux_low_filter_event): Remove filter_ptid argument.
8688 Leave thread group exits pending here. Store the LWP's stop PC.
8689 Always leave events pending.
8690 (linux_wait_for_event_filtered): Pull all events out of the
8691 kernel, and leave them all pending.
8692 (count_events_callback, select_event_lwp_callback): Consider all
8694 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
8695 (select_event_lwp): Only give preference to the stepping LWP in
8696 all-stop mode. Adjust comments.
8697 (ignore_event): New function.
8698 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
8699 references to cancel_breakpoints. Adjust to renames. Also give
8700 equal priority to all LWPs that have had events in non-stop mode.
8701 If reporting a software breakpoint event, unadjust the LWP's PC.
8702 (linux_wait): If linux_wait_1 returned an ignored event, retry.
8703 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
8705 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
8706 (resume_status_pending_p): Use thread_still_has_status_pending_p.
8707 (linux_stopped_by_watchpoint): Adjust.
8708 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
8709 * linux-low.h (enum lwp_stop_reason): New.
8710 (struct lwp_info) <stop_pc>: Adjust comment.
8711 <stopped_by_watchpoint>: Delete field.
8712 <stop_reason>: New field.
8713 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
8714 * mem-break.c (software_breakpoint_inserted_here)
8715 (hardware_breakpoint_inserted_here): New function.
8716 * mem-break.h (software_breakpoint_inserted_here)
8717 (hardware_breakpoint_inserted_here): Declare.
8718 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
8719 (cancel_breakpoints): Delete.
8720 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
8721 (upload_fast_traceframes): Remove references to
8724 2015-01-09 Pedro Alves <palves@redhat.com>
8726 * thread-db.c (find_new_threads_callback): Ignore thread if the
8727 kernel thread ID is -1.
8729 2015-01-09 Pedro Alves <palves@redhat.com>
8731 * linux-low.c (linux_attach_fail_reason_string): Move to
8732 nat/linux-ptrace.c, and rename.
8733 (linux_attach_lwp): Update comment.
8734 (attach_proc_task_lwp_callback): New function.
8735 (linux_attach): Adjust to rename and use
8736 linux_proc_attach_tgid_threads.
8737 (linux_attach_fail_reason_string): Delete declaration.
8739 2015-01-01 Joel Brobecker <brobecker@adacore.com>
8741 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
8742 * server.c (gdbserver_version): Likewise.
8744 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
8746 * remote-utils.c: Include ctype.h.
8747 (input_interrupt): Explicitly handle the case when the char
8748 received is the NUL byte. Improve the printing of non-ASCII
8751 2014-12-16 Joel Brobecker <brobecker@adacore.com>
8753 * linux-low.c (linux_low_filter_event): Update call to
8754 linux_enable_event_reporting following the addition of
8755 a new parameter to that function.
8757 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
8760 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
8761 (AARCH64_FPCR_REGNO): Likewise.
8762 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
8763 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
8764 (aarch64_store_fpregset): Likewise.
8766 2014-12-15 Joel Brobecker <brobecker@adacore.com>
8768 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
8769 Remove FIXME comment about assumption about N.
8771 2014-12-13 Joel Brobecker <brobecker@adacore.com>
8773 * configure.ac: If large-file support is disabled in GDBserver,
8774 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
8775 * configure: Regenerate.
8777 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
8779 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
8780 warning upon ENODATA from ptrace.
8781 * linux-s390-low.c (s390_store_tdb): New.
8782 (s390_regsets): Add regset for NT_S390_TDB.
8784 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
8786 * linux-low.c (regsets_store_inferior_registers): Skip regsets
8787 without a fill_function.
8788 * linux-s390-low.c (s390_fill_last_break): Remove.
8789 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
8790 (s390_arch_setup): Use regset's size instead of fill_function for
8793 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
8795 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
8796 the regset's store function when ptrace returned an error.
8797 * regcache.c (get_thread_regcache): Invalidate register cache
8798 before fetching inferior's registers.
8800 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
8802 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
8803 while-loop as for-loop.
8804 (regsets_store_inferior_registers): Likewise.
8806 2014-11-28 Yao Qi <yao@codesourcery.com>
8808 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
8809 * config.in, configure: Re-generate.
8810 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
8813 2014-11-21 Yao Qi <yao@codesourcery.com>
8815 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
8816 (AC_CHECK_HEADERS): Remove malloc.h.
8817 * configure: Re-generated.
8818 * config.in: Re-generated.
8819 * server.h: Don't include alloca.h and malloc.h.
8820 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
8821 Don't include malloc.h.
8823 2014-11-17 Joel Brobecker <brobecker@adacore.com>
8825 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
8826 corresponding ERRNO check in same block.
8828 2014-11-12 Pedro Alves <palves@redhat.com>
8830 * server.c (cont_thread): Update comment.
8831 (start_inferior, attach_inferior): No longer clear cont_thread.
8832 (handle_v_cont): No longer set cont_thread.
8833 (captured_main): Clear cont_thread each time a GDB connects.
8835 2014-11-12 Pedro Alves <palves@redhat.com>
8837 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
8838 thread, and don't resume all threads if the Hc thread has exited.
8840 2014-11-12 Pedro Alves <palves@redhat.com>
8842 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
8843 the process group instead of to a specific LWP.
8845 2014-10-15 Pedro Alves <palves@redhat.com>
8848 * win32-arm-low.c (arm_set_thread_context): Remove current_event
8850 (arm_set_thread_context): Delete.
8851 (the_low_target): Adjust.
8852 * win32-i386-low.c (debug_registers_changed)
8853 (debug_registers_used): Delete.
8854 (update_debug_registers_callback): New function.
8855 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
8856 needing to update their debug registers.
8857 (win32_get_current_dr): New function.
8858 (x86_dr_low_get_addr, x86_dr_low_get_control)
8859 (x86_dr_low_get_status): Fetch the debug register from the thread
8861 (i386_initial_stuff): Adjust.
8862 (i386_get_thread_context): Remove current_event parameter. Don't
8863 clear debug_registers_changed nor copy DR values to
8865 (i386_set_thread_context): Delete.
8866 (i386_prepare_to_resume): New function.
8867 (i386_thread_added): Mark the thread as needing to update irs
8869 (the_low_target): Remove i386_set_thread_context and install
8870 i386_prepare_to_resume.
8871 * win32-low.c (win32_get_thread_context): Adjust.
8872 (win32_set_thread_context): Use SetThreadContext
8874 (win32_prepare_to_resume): New function.
8875 (win32_require_context): New function, factored out from ...
8876 (thread_rec): ... this.
8877 (continue_one_thread): Call win32_prepare_to_resume on each thread
8878 we're about to continue.
8879 (win32_resume): Call win32_prepare_to_resume on the event thread.
8880 * win32-low.h (struct win32_thread_info)
8881 <debug_registers_changed>: New field.
8882 (struct win32_target_ops): Change prototype of set_thread_context,
8883 delete set_thread_context and add prepare_to_resume.
8884 (win32_require_context): New declaration.
8886 2014-10-08 Gary Benson <gbenson@redhat.com>
8888 * server.h: Do not include common-exceptions.h.
8890 2014-10-08 Gary Benson <gbenson@redhat.com>
8892 * server.h: Do not include cleanups.h.
8894 2014-09-30 James Hogan <james.hogan@imgtec.com>
8896 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
8899 2014-09-23 Yao Qi <yao@codesourcery.com>
8901 * linux-low.c (lp_status_maybe_breakpoint): New function.
8902 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
8903 (count_events_callback): Likewise.
8904 (select_event_lwp_callback): Likewise.
8905 (cancel_breakpoints_callback): Likewise.
8907 2014-09-19 Don Breazeal <donb@codesourcery.com>
8909 * linux-low.c (handle_extended_wait): Call
8910 linux_ptrace_get_extended_event.
8911 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
8912 linux_is_extended_waitstatus.
8914 2014-09-16 Joel Brobecker <brobecker@adacore.com>
8916 * Makefile.in (CPPFLAGS): Define.
8917 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
8918 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
8920 2014-09-16 Gary Benson <gbenson@redhat.com>
8922 * inferiors.h (current_inferior): Renamed as...
8923 (current_thread): New variable. All uses updated.
8924 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
8925 (maybe_move_out_of_jump_pad): Likewise.
8926 (cancel_breakpoint): Likewise.
8927 (linux_low_filter_event): Likewise.
8928 (wait_for_sigstop): Likewise.
8929 (linux_resume_one_lwp): Likewise.
8930 (need_step_over_p): Likewise.
8931 (start_step_over): Likewise.
8932 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
8933 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
8934 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
8935 and save_inferior as saved_thread.
8936 * regcache.c (get_thread_regcache): Renamed saved_inferior as
8938 (regcache_invalidate_thread): Likewise.
8939 * remote-utils.c (prepare_resume_reply): Likewise.
8940 * thread-db.c (thread_db_get_tls_address): Likewise.
8941 (disable_thread_event_reporting): Likewise.
8942 (remove_thread_event_breakpoints): Likewise.
8943 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
8945 * target.h (set_desired_inferior): Renamed as...
8946 (set_desired_thread): New declaration. All uses updated.
8947 * server.c (myresume): Updated comment to reference thread instead
8949 (handle_serial_event): Likewise.
8950 (handle_target_event): Likewise.
8952 2014-09-12 Tom Tromey <tromey@redhat.com>
8953 Gary Benson <gbenson@redhat.com>
8955 * regcache.h: Include common-regcache.h.
8956 (regcache_read_pc): Don't declare.
8957 * regcache.c (get_thread_regcache_for_ptid): New function.
8959 2014-09-11 Tom Tromey <tromey@redhat.com>
8960 Gary Benson <gbenson@redhat.com>
8962 * symbol.c: New file.
8963 * Makefile.in (SFILES): Add symbol.c.
8964 (OBS): Add symbol.o.
8966 2014-09-11 Gary Benson <gbenson@redhat.com>
8968 * target.c (target_stop_ptid, target_continue_ptid): New
8971 2014-09-11 Tom Tromey <tromey@redhat.com>
8972 Gary Benson <gbenson@redhat.com>
8974 * target.h: Include target/target.h.
8975 * target.c (target_read_memory, target_read_uint32)
8976 (target_write_memory): New functions.
8978 2014-09-11 Gary Benson <gbenson@redhat.com>
8980 * server.h (debug_hw_points): Don't declare.
8981 * server.c (debug_hw_points): Don't define. Replace all uses
8982 with show_debug_regs.
8983 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
8984 all uses with show_debug_regs.
8986 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
8988 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
8989 endianness into account.
8990 (ppc_supply_ptrace_register): Likewise.
8992 2014-09-03 James Hogan <james.hogan@imgtec.com>
8994 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
8995 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
8997 2014-09-03 Gary Benson <gbenson@redhat.com>
8999 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
9000 ALL_DEBUG_ADDRESS_REGISTERS.
9002 2014-09-02 Gary Benson <gbenson@redhat.com>
9004 * i386-low.h: Renamed as...
9005 * x86-low.h: New file. All type, function and variable name
9006 prefixes changed from "i386_" to "x86_". All references updated.
9007 * i386-low.c: Renamed as...
9008 * x86-low.c: New file. All type, function and variable name
9009 prefixes changed from "i386_" to "x86_". All references updated.
9011 2014-09-02 Gary Benson <gbenson@redhat.com>
9013 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
9014 (x86_linux_new_thread): Likewise.
9016 2014-08-29 Gary Benson <gbenson@redhat.com>
9018 * server.h (setjmp.h): Do not include.
9019 (toplevel): Do not declare.
9020 (common-exceptions.h): Include.
9021 (cleanups.h): Likewise.
9022 * server.c (toplevel): Do not define.
9023 (exit_code): New static global.
9024 (detach_or_kill_for_exit_cleanup): New function.
9025 (main): New function. Original main renamed to...
9026 (captured_main): New function.
9027 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
9029 2014-08-29 Gary Benson <gbenson@redhat.com>
9031 * Makefile.in (SFILES): Add common/common-exceptions.c.
9032 (OBS): Add common-exceptions.o.
9033 (common-exceptions.o): New rule.
9034 * utils.c (prepare_to_throw_exception): New function.
9036 2014-08-29 Gary Benson <gbenson@redhat.com>
9038 * config.in: Regenerate.
9039 * configure: Likewise.
9041 2014-08-29 Gary Benson <gbenson@redhat.com>
9043 * Makefile.in (SFILES): Add common/cleanups.c.
9045 (cleanups.o): New rule.
9047 2014-08-29 Gary Benson <gbenson@redhat.com>
9049 * utils.c (internal_vwarning): New function.
9051 2014-08-28 Gary Benson <gbenson@redhat.com>
9053 * utils.h (fatal): Remove declaration.
9054 * utils.c (fatal): Remove function.
9056 2014-08-28 Gary Benson <gbenson@redhat.com>
9058 * tracepoint.c (gdb_agent_init): Replace fatal with
9060 (initialize_tracepoint): Likewise.
9062 2014-08-28 Gary Benson <gbenson@redhat.com>
9064 * remote-utils.c (remote_prepare): Replace fatal with error.
9066 2014-08-28 Gary Benson <gbenson@redhat.com>
9068 * linux-low.c (linux_async): Replace fatal with warning.
9070 (linux_start_non_stop): Return -1 if linux_async failed.
9072 2014-08-28 Gary Benson <gbenson@redhat.com>
9074 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
9076 (i386_dr_low_get_addr): Remove vague comment.
9077 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
9080 2014-08-28 Gary Benson <gbenson@redhat.com>
9082 * inferiors.c (get_thread_process): Replace check with gdb_assert.
9083 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
9085 (linux_resume_one_lwp): Likewise.
9086 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
9088 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
9089 with internal_error.
9090 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
9091 (init_register_cache): Replace fatal with gdb_assert_not_reached.
9092 (find_register_by_name): Replace fatal with internal_error.
9093 (find_regno): Likewise.
9094 * tdesc.c (init_target_desc): Replace check with gdb_assert.
9095 * thread-db.c (thread_db_create_event): Likewise.
9096 (thread_db_load_search): Likewise.
9097 (try_thread_db_load_1): Likewise.
9098 * tracepoint.c (get_jump_space_head): Replace fatal with
9100 (claim_trampoline_space): Likewise.
9101 (have_fast_tracepoint_trampoline_buffer): Likewise.
9102 (cmd_qtstart): Likewise.
9103 (stop_tracing): Likewise.
9104 (fast_tracepoint_collecting): Likewise.
9105 (target_malloc): Likewise.
9106 (download_tracepoint): Likewise.
9107 (download_trace_state_variables): Replace check with gdb_assert.
9108 (upload_fast_traceframes): Replace fatal with internal_error.
9110 2014-08-19 Tom Tromey <tromey@redhat.com>
9111 Gary Benson <gbenson@redhat.com>
9113 * Makefile.in (SFILES): Add common/common-debug.c.
9114 (OBS): Add common-debug.o.
9115 (common-debug.o): New rule.
9116 * debug.h (debug_printf): Don't declare.
9117 * debug.c (debug_printf): Renamed and rewritten as...
9118 (debug_vprintf): New function.
9120 2014-08-19 Gary Benson <gbenson@redhat.com>
9122 * utils.h: Do not include print-utils.h.
9124 2014-08-19 Tom Tromey <tromey@redhat.com>
9125 Gary Benson <gbenson@redhat.com>
9127 * server.h: Add static assertion.
9128 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
9130 2014-08-19 Tom Tromey <tromey@redhat.com>
9131 Gary Benson <gbenson@redhat.com>
9133 * Makefile.in (SFILES): Add common/errors.c.
9134 (OBS): Add errors.o.
9135 (IPA_OBS): Add errors-ipa.o.
9136 (errors.o): New rule.
9137 (errors-ipa.o): Likewise.
9138 * utils.h (perror_with_name, error, warning): Don't declare.
9139 * utils.c (warning): Renamed and rewritten as...
9140 (vwarning): New function.
9141 (error): Renamed and rewritten as...
9142 (verror): New function.
9143 (internal_error): Renamed and rewritten as...
9144 (internal_verror): New function.
9146 2014-08-07 Gary Benson <gbenson@redhat.com>
9148 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
9149 * configure: Regenerate.
9150 * config.in: Likewise.
9151 * server.h: Do not include errno.h.
9152 * event-loop.c: Likewise.
9153 * hostio-errno.c: Likewise.
9154 * linux-low.c: Likewise.
9155 * remote-utils.c: Likewise.
9156 * spu-low.c: Likewise.
9157 * utils.c: Likewise.
9158 * gdbreplay.c: Unconditionally include errno.h.
9160 2014-08-07 Gary Benson <gbenson@redhat.com>
9162 * server.h: Do not include string.h.
9163 * event-loop.c: Likewise.
9164 * linux-low.c: Likewise.
9165 * regcache.c: Likewise.
9166 * remote-utils.c: Likewise.
9167 * spu-low.c: Likewise.
9168 * utils.c: Likewise.
9170 2014-08-07 Gary Benson <gbenson@redhat.com>
9172 * server.h: Do not include gdb_assert.h.
9174 2014-08-07 Gary Benson <gbenson@redhat.com>
9176 * server.h: Do not include common-utils.h.
9178 2014-08-07 Gary Benson <gbenson@redhat.com>
9180 * server.h: Do not include ptid.h.
9181 * notif.h: Likewise.
9183 2014-08-07 Gary Benson <gbenson@redhat.com>
9185 * server.h: Do not include gdb_locale.h.
9187 2014-08-07 Gary Benson <gbenson@redhat.com>
9189 * server.h: Do not include gdb/signals.h.
9190 * win32-low.c: Likewise.
9192 2014-08-07 Gary Benson <gbenson@redhat.com>
9194 * server.h: Do not include pathmax.h.
9196 2014-08-07 Gary Benson <gbenson@redhat.com>
9198 * server.h: Do not include libiberty.h.
9199 * linux-bfin-low.c: Likewise.
9201 2014-08-07 Gary Benson <gbenson@redhat.com>
9203 * server.h: Do not include ansidecl.h.
9205 2014-08-07 Gary Benson <gbenson@redhat.com>
9207 * linux-x86-low.c: Do not include stddef.h.
9208 * lynx-ppc-low.c: Likewise.
9209 * tracepoint.c: Likewise.
9211 2014-08-07 Gary Benson <gbenson@redhat.com>
9213 * server.h: Do not include stdarg.h.
9214 * nto-low.c: Likewise.
9216 2014-08-07 Gary Benson <gbenson@redhat.com>
9218 * server.h: Do not include stdlib.h.
9219 * inferiors.c: Likewise.
9220 * linux-low.c: Likewise.
9221 * regcache.c: Likewise.
9222 * spu-low.c: Likewise.
9223 * tracepoint.c: Likewise.
9224 * utils.c: Likewise.
9226 2014-08-07 Gary Benson <gbenson@redhat.com>
9228 * server.h: Do not include stdio.h.
9229 * linux-low.c: Likewise.
9230 * remote-utils.c: Likewise.
9231 * spu-low.c: Likewise.
9232 * utils.c: Likewise.
9233 * wincecompat.c: Likewise.
9235 2014-08-06 Gary Benson <gbenson@redhat.com>
9237 * regcache.c (init_register_cache): Move conditionals inside if.
9239 2014-08-06 Gary Benson <gbenson@redhat.com>
9241 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
9243 2014-07-31 Gary Benson <gbenson@redhat.com>
9245 * ax.h: Do not include server.h.
9246 * gdbthread.h: Likewise.
9247 * lynx-low.h: Likewise.
9248 * notif.h: Likewise.
9250 2014-07-30 Gary Benson <gbenson@redhat.com>
9252 * server.h: Include common-defs.h.
9253 Do not include config.h or build-gnulib-gdbserver/config.h.
9255 2014-07-30 Gary Benson <gbenson@redhat.com>
9257 * hostio-errno.c: Move server.h to top of includes list.
9258 * inferiors.c: Likewise.
9259 * linux-x86-low.c: Likewise.
9260 * notif.c: Include server.h.
9262 2014-07-24 Tom Tromey <tromey@redhat.com>
9263 Gary Benson <gbenson@redhat.com>
9265 * server.h (CORE_ADDR): Now unsigned.
9267 2014-07-16 Pedro Alves <palves@redhat.com>
9269 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
9271 2014-07-15 Pedro Alves <palves@redhat.com>
9273 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
9276 2014-07-11 Pedro Alves <palves@redhat.com>
9278 * linux-low.c (kill_wait_lwp): New function, based on
9279 kill_one_lwp_callback, but use my_waitpid directly.
9280 (kill_one_lwp_callback, linux_kill): Use it.
9282 2014-06-23 Pedro Alves <palves@redhat.com>
9284 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
9285 before setting DR0..DR3.
9287 2014-06-20 Gary Benson <gbenson@redhat.com>
9289 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
9290 * configure: Regenerated.
9291 * config.in: Likewise.
9293 2014-06-20 Gary Benson <gbenson@redhat.com>
9295 * Makefile.in (SFILES): Update locations for files moved
9297 (object file files): Reordered.
9299 2014-06-20 Gary Benson <gbenson@redhat.com>
9301 * i386-low.h (i386_dr_low_can_set_addr): Removed.
9302 (i386_dr_low_set_addr): Likewise.
9303 (i386_dr_low_get_addr): Likewise.
9304 (i386_dr_low_can_set_control): Likewise.
9305 (i386_dr_low_set_control): Likewise.
9306 (i386_dr_low_get_control): Likewise.
9307 (i386_dr_low_get_status): Likewise.
9308 (i386_get_debug_register_length): Likewise.
9309 * linux-x86-low.c (i386_dr_low_set_addr):
9310 Changed signature. Made static.
9311 (i386_dr_low_get_addr): Likewise.
9312 (i386_dr_low_set_control): Likewise.
9313 (i386_dr_low_get_control): Likewise.
9314 (i386_dr_low_get_status): Likewise.
9315 (i386_dr_low): New global variable.
9316 * win32-i386-low.c (i386_dr_low_set_addr):
9317 Changed signature. Made static.
9318 (i386_dr_low_get_addr): Likewise.
9319 (i386_dr_low_set_control): Likewise.
9320 (i386_dr_low_get_control): Likewise.
9321 (i386_dr_low_get_status): Likewise.
9322 (i386_dr_low): New global variable.
9324 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
9326 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
9327 * Makefile.in (AR, AR_FLAGS): Define.
9328 * configure: Regenerate.
9330 2014-06-19 Gary Benson <gbenson@redhat.com>
9332 * Makefile.in (i386-dregs.o): New rule.
9333 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
9334 * i386-low.c (target.h): Remove include.
9335 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
9336 (DR_CONTROL_SHIFT): Likewise.
9337 (DR_CONTROL_SIZE): Likewise.
9338 (DR_RW_EXECUTE): Likewise.
9339 (DR_RW_WRITE): Likewise.
9340 (DR_RW_READ): Likewise.
9341 (DR_RW_IORW): Likewise.
9342 (DR_LEN_1): Likewise.
9343 (DR_LEN_2): Likewise.
9344 (DR_LEN_4): Likewise.
9345 (DR_LEN_8): Likewise.
9346 (DR_LOCAL_ENABLE_SHIFT): Likewise.
9347 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
9348 (DR_ENABLE_SIZE): Likewise.
9349 (DR_LOCAL_SLOWDOWN): Likewise.
9350 (DR_GLOBAL_SLOWDOWN): Likewise.
9351 (DR_CONTROL_RESERVED): Likewise.
9352 (I386_DR_CONTROL_MASK): Likewise.
9353 (I386_DR_VACANT): Likewise.
9354 (I386_DR_LOCAL_ENABLE): Likewise.
9355 (I386_DR_GLOBAL_ENABLE): Likewise.
9356 (I386_DR_DISABLE): Likewise.
9357 (I386_DR_SET_RW_LEN): Likewise.
9358 (I386_DR_GET_RW_LEN): Likewise.
9359 (I386_DR_WATCH_HIT): Likewise.
9360 (i386_wp_op_t): Likewise.
9361 (i386_show_dr): Likewise.
9362 (i386_length_and_rw_bits): Likewise.
9363 (i386_insert_aligned_watchpoint): Likewise.
9364 (i386_remove_aligned_watchpoint): Likewise.
9365 (i386_handle_nonaligned_watchpoint): Likewise.
9366 i386_update_inferior_debug_regs(): Likewise.
9367 (i386_dr_insert_watchpoint): Likewise.
9368 (i386_dr_remove_watchpoint): Likewise.
9369 (i386_dr_region_ok_for_watchpoint): Likewise.
9370 (i386_dr_stopped_data_address): Likewise.
9371 (i386_dr_stopped_by_watchpoint): Likewise.
9373 2014-06-19 Gary Benson <gbenson@redhat.com>
9375 * i386-low.c (i386_dr_show): Renamed to
9376 i386_show_dr and made static. All uses updated.
9377 (i386_dr_length_and_rw_bits): Renamed to
9378 i386_length_and_rw_bits and made static.
9380 (i386_dr_insert_aligned_watchpoint): Renamed to
9381 i386_insert_aligned_watchpoint and made static.
9383 (i386_dr_remove_aligned_watchpoint): Renamed to
9384 i386_remove_aligned_watchpoint and made static.
9386 (i386_dr_update_inferior_debug_regs): Renamed to
9387 i386_update_inferior_debug_regs and made static.
9390 2014-06-18 Gary Benson <gbenson@redhat.com>
9392 * i386-low.h (i386_dr_low_can_set_addr): New macro.
9393 (i386_dr_low_can_set_control): Likewise.
9394 (i386_get_debug_register_length): Likewise.
9395 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
9396 (i386_dr_low_can_set_control): Likewise.
9397 (i386_get_debug_register_length): Likewise.
9399 2014-06-17 Gary Benson <gbenson@redhat.com>
9401 * i386-low.h (i386-dregs.h): New include.
9402 (DR_FIRSTADDR): Now in i386-dregs.h.
9403 (DR_LASTADDR): Likewise.
9404 (DR_NADDR): Likewise.
9405 (DR_STATUS): Likewise.
9406 (DR_CONTROL): Likewise.
9407 (i386_debug_reg_state): Likewise.
9408 (i386_dr_insert_watchpoint): Likewise.
9409 (i386_dr_remove_watchpoint): Likewise.
9410 (i386_dr_region_ok_for_watchpoint): Likewise.
9411 (i386_dr_stopped_data_address): Likewise.
9412 (i386_dr_stopped_by_watchpoint): Likewise.
9413 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
9415 2014-06-18 Gary Benson <gbenson@redhat.com>
9417 * i386-low.h (i386_low_insert_watchpoint): Renamed to
9418 i386_dr_insert_watchpoint.
9419 (i386_low_remove_watchpoint): Renamed to
9420 i386_dr_remove_watchpoint.
9421 (i386_low_region_ok_for_watchpoint): Renamed to
9422 i386_dr_region_ok_for_watchpoint.
9423 (i386_low_stopped_data_address): Renamed to
9424 i386_dr_stopped_data_address.
9425 (i386_low_stopped_by_watchpoint): Renamed to
9426 i386_dr_stopped_by_watchpoint.
9427 * i386-low.c (i386_show_dr): Renamed to
9428 i386_dr_show and made nonstatic. All uses updated.
9429 (i386_length_and_rw_bits): Renamed to
9430 i386_dr_length_and_rw_bits and made nonstatic.
9432 (i386_insert_aligned_watchpoint): Renamed to
9433 i386_dr_insert_aligned_watchpoint and made nonstatic.
9435 (i386_remove_aligned_watchpoint): Renamed to
9436 i386_dr_remove_aligned_watchpoint and made nonstatic.
9438 (i386_update_inferior_debug_regs): Renamed to
9439 i386_dr_update_inferior_debug_regs and made nonstatic.
9441 (i386_low_insert_watchpoint): Renamed to
9442 i386_dr_insert_watchpoint. All uses updated.
9443 (i386_low_remove_watchpoint): Renamed to
9444 i386_dr_remove_watchpoint. All uses updated.
9445 (i386_low_region_ok_for_watchpoint): Renamed to
9446 i386_dr_region_ok_for_watchpoint. All uses updated.
9447 (i386_low_stopped_data_address): Renamed to
9448 i386_dr_stopped_data_address. All uses updated.
9449 (i386_low_stopped_by_watchpoint): Renamed to
9450 i386_dr_stopped_by_watchpoint. All uses updated.
9452 2014-06-18 Gary Benson <gbenson@redhat.com>
9454 * i386-low.c (i386_dr_low_can_set_addr): New macro.
9455 (i386_dr_low_can_set_control): Likewise.
9456 (i386_insert_aligned_watchpoint): New check.
9458 2014-06-18 Gary Benson <gbenson@redhat.com>
9460 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
9463 2014-06-18 Gary Benson <gbenson@redhat.com>
9465 * i386-low.c (i386_length_and_rw_bits): Use internal_error
9466 instead of fatal and error.
9467 (i386_handle_nonaligned_watchpoint): Likewise.
9469 2014-06-18 Gary Benson <gbenson@redhat.com>
9471 * i386-low.c (i386_get_debug_register_length): New macro.
9472 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
9473 (i386_show_dr): Use debug_printf instead of fprintf. Use
9474 phex to format values.
9476 2014-06-18 Gary Benson <gbenson@redhat.com>
9478 * i386-low.h: Comment changes.
9479 * i386-low.c: Likewise.
9481 2014-06-18 Gary Benson <gbenson@redhat.com>
9483 * i386-low.c: Whitespace changes.
9485 2014-06-12 Tom Tromey <tromey@redhat.com>
9487 * utils.c (freeargv): Remove.
9489 2014-06-12 Tom Tromey <tromey@redhat.com>
9491 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
9492 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
9493 (parse_debug_format_options): Likewise.
9494 (gdbserver_usage): Likewise.
9495 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
9496 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
9497 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
9499 ($(LIBGNU)): Depend on libiberty.
9500 (all-lib): Recurse into all subdirs.
9501 (install-only): Invoke "install" target in subdirs.
9502 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
9504 * configure: Rebuild.
9505 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
9506 for vasprintf, vsnprintf, or gettimeofday.
9507 * configure.srv: Don't add safe-ctype.o or lbasename.o to
9510 2014-06-05 Joel Brobecker <brobecker@adacore.com>
9512 * development.sh: Delete.
9513 * Makefile.in (config.status): Adjust dependency on development.sh.
9514 * configure.ac: Adjust development.sh source call.
9515 * configure: Regenerate.
9517 2014-06-02 Pedro Alves <palves@redhat.com>
9519 * ax.c (gdb_free_agent_expr): New function.
9520 * ax.h (gdb_free_agent_expr): New declaration.
9521 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
9523 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
9525 (clear_breakpoint_conditions_and_commands): New function.
9526 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
9527 (clear_breakpoint_conditions_and_commands): New declaration.
9529 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
9531 * linux-aarch64-low.c (asm/ptrace.h): Include.
9533 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
9535 Fix TLS access for -static -pthread.
9536 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
9537 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
9538 (thread_db_load_search, try_thread_db_load_1): Initialize it.
9540 2014-05-20 Pedro Alves <palves@redhat.com>
9542 * linux-aarch64-low.c (aarch64_insert_point)
9543 (aarch64_remove_point): No longer check whether the type is
9544 supported here. Adjust to new interface.
9545 (the_low_target): Install aarch64_supports_z_point_type as
9546 supports_z_point_type method.
9547 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
9548 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
9549 instead of a Z packet char. Adjust.
9550 (arm_supports_z_point_type): New function.
9551 (arm_insert_point, arm_remove_point): Adjust to new interface.
9552 (the_low_target): Install arm_supports_z_point_type.
9553 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
9554 (cris_insert_point, cris_remove_point): Adjust to new interface.
9555 Don't check whether the type is supported here.
9556 (the_low_target): Install cris_supports_z_point_type.
9557 * linux-low.c (linux_supports_z_point_type): New function.
9558 (linux_insert_point, linux_remove_point): Adjust to new interface.
9559 * linux-low.h (struct linux_target_ops) <insert_point,
9560 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
9561 raw_breakpoint pointer parameter.
9562 <supports_z_point_type>: New method.
9563 * linux-mips-low.c (mips_supports_z_point_type): New function.
9564 (mips_insert_point, mips_remove_point): Adjust to new interface.
9565 Use mips_supports_z_point_type.
9566 (the_low_target): Install mips_supports_z_point_type.
9567 * linux-ppc-low.c (the_low_target): Install NULL as
9568 supports_z_point_type method.
9569 * linux-s390-low.c (the_low_target): Install NULL as
9570 supports_z_point_type method.
9571 * linux-sparc-low.c (the_low_target): Install NULL as
9572 supports_z_point_type method.
9573 * linux-x86-low.c (x86_supports_z_point_type): New function.
9574 (x86_insert_point): Adjust to new insert_point interface. Use
9575 insert_memory_breakpoint. Adjust to new
9576 i386_low_insert_watchpoint interface.
9577 (x86_remove_point): Adjust to remove_point interface. Use
9578 remove_memory_breakpoint. Adjust to new
9579 i386_low_remove_watchpoint interface.
9580 (the_low_target): Install x86_supports_z_point_type.
9581 * lynx-low.c (lynx_target_ops): Install NULL as
9582 supports_z_point_type callback.
9583 * nto-low.c (nto_supports_z_point_type): New.
9584 (nto_insert_point, nto_remove_point): Adjust to new interface.
9585 (nto_target_ops): Install nto_supports_z_point_type.
9586 * mem-break.c: Adjust intro comment.
9587 (struct raw_breakpoint) <raw_type, size>: New fields.
9588 <inserted>: Update comment.
9589 <shlib_disabled>: Delete field.
9590 (enum bkpt_type) <gdb_breakpoint>: Delete value.
9591 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
9592 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
9593 (raw_bkpt_type_to_target_hw_bp_type): New function.
9594 (find_enabled_raw_code_breakpoint_at): New function.
9595 (find_raw_breakpoint_at): New type and size parameters. Use them.
9596 (insert_memory_breakpoint): New function, based off
9597 set_raw_breakpoint_at.
9598 (remove_memory_breakpoint): New function.
9599 (set_raw_breakpoint_at): Reimplement.
9600 (set_breakpoint): New, based on set_breakpoint_at.
9601 (set_breakpoint_at): Reimplement.
9602 (delete_raw_breakpoint): Go through the_target->remove_point
9603 instead of assuming memory breakpoints.
9604 (find_gdb_breakpoint_at): Delete.
9605 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
9606 (find_gdb_breakpoint): New function.
9607 (set_gdb_breakpoint_at): Delete.
9608 (z_type_supported): New function.
9609 (set_gdb_breakpoint_1): New function, loosely based off
9610 set_gdb_breakpoint_at.
9611 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
9612 (delete_gdb_breakpoint_at): Delete.
9613 (delete_gdb_breakpoint_1): New function, loosely based off
9614 delete_gdb_breakpoint_at.
9615 (delete_gdb_breakpoint): New function.
9616 (clear_gdb_breakpoint_conditions): Rename to ...
9617 (clear_breakpoint_conditions): ... this. Don't handle a NULL
9619 (add_condition_to_breakpoint): Make static.
9620 (add_breakpoint_condition): Take a struct breakpoint pointer
9621 instead of an address. Adjust.
9622 (gdb_condition_true_at_breakpoint): Rename to ...
9623 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
9625 (gdb_condition_true_at_breakpoint): Reimplement.
9626 (add_breakpoint_commands): Take a struct breakpoint pointer
9627 instead of an address. Adjust.
9628 (gdb_no_commands_at_breakpoint): Rename to ...
9629 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
9630 parameter. Return true if no breakpoint was found. Change debug
9632 (gdb_no_commands_at_breakpoint): Reimplement.
9633 (run_breakpoint_commands): Rename to ...
9634 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
9635 and change return type to boolean.
9636 (run_breakpoint_commands): New function.
9637 (gdb_breakpoint_here): Also check for Z1 breakpoints.
9638 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
9639 breakpoint. Go through the_target->remove_point instead of
9640 assuming memory breakpoint.
9641 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
9642 software and hardware breakpoints.
9643 (reinsert_raw_breakpoint): Go through the_target->insert_point
9644 instead of assuming memory breakpoint.
9645 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
9646 software and hardware breakpoints.
9647 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
9648 Check both software and hardware breakpoints.
9649 (validate_inserted_breakpoint): Assert the breakpoint is a
9650 software breakpoint. Set the inserted flag to -1 instead of
9651 setting shlib_disabled.
9652 (delete_disabled_breakpoints): Adjust.
9653 (validate_breakpoints): Only validate software breakpoints.
9654 Adjust to inserted flag change.
9655 (check_mem_read, check_mem_write): Skip breakpoint types other
9656 than software breakpoints. Adjust to inserted flag change.
9657 * mem-break.h (enum raw_bkpt_type): New enum.
9658 (raw_breakpoint, struct process_info): Forward declare.
9659 (Z_packet_to_target_hw_bp_type): Delete declaration.
9660 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
9661 (set_gdb_breakpoint, delete_gdb_breakpoint)
9662 (clear_breakpoint_conditions): New declarations.
9663 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
9664 (breakpoint_inserted_here): Update comment.
9665 (add_breakpoint_condition, add_breakpoint_commands): Replace
9666 address parameter with a breakpoint pointer parameter.
9667 (gdb_breakpoint_here): Update comment.
9668 (delete_gdb_breakpoint_at): Delete.
9669 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
9670 * server.c (process_point_options): Take a struct breakpoint
9671 pointer instead of an address. Adjust.
9672 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
9673 delete_gdb_breakpoint.
9674 * spu-low.c (spu_target_ops): Install NULL as
9675 supports_z_point_type method.
9676 * target.h: Include mem-break.h.
9677 (struct target_ops) <prepare_to_access_memory>: Update comment.
9678 <supports_z_point_type>: New field.
9679 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
9680 instead of a char. Also take a raw breakpoint pointer.
9681 * win32-arm-low.c (the_low_target): Install NULL as
9682 supports_z_point_type.
9683 * win32-i386-low.c (i386_supports_z_point_type): New function.
9684 (i386_insert_point, i386_remove_point): Adjust to new interface.
9685 (the_low_target): Install i386_supports_z_point_type.
9686 * win32-low.c (win32_supports_z_point_type): New function.
9687 (win32_insert_point, win32_remove_point): Adjust to new interface.
9688 (win32_target_ops): Install win32_supports_z_point_type.
9689 * win32-low.h (struct win32_target_ops):
9690 <supports_z_point_type>: New method.
9691 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
9692 instead of a char. Also take a raw breakpoint pointer.
9694 2014-05-20 Pedro Alves <palves@redhat.com>
9696 * mem-break.h: Include break-common.h.
9697 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
9698 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
9699 (Z_packet_to_target_hw_bp_type): New declaration.
9700 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
9701 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
9702 (Z_PACKET_ACCESS_WP): Delete macros.
9703 (Z_packet_to_hw_type): Delete function.
9704 * i386-low.h: Don't include break-common.h here.
9705 (Z_packet_to_hw_type): Delete declaration.
9706 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
9707 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
9708 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
9709 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
9710 * linux-aarch64-low.c: Don't include break-common.h here.
9711 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
9712 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
9713 (Z_packet_to_target_hw_bp_type): Delete function.
9714 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
9716 (mips_insert_point, mips_remove_point): Use
9717 Z_packet_to_target_hw_bp_type.
9719 2014-05-20 Pedro Alves <palves@redhat.com>
9721 * linux-aarch64-low.c: Include break-common.h.
9722 (enum target_point_type): Delete.
9723 (Z_packet_to_point_type): Rename to ...
9724 (Z_packet_to_target_hw_bp_type): ... this, and return a
9725 target_hw_bp_type instead.
9726 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
9727 instead of an enum target_point_type.
9728 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
9730 (aarch64_dr_state_insert_one_point)
9731 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
9732 (aarch64_handle_aligned_watchpoint)
9733 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
9734 Take an enum target_hw_bp_type instead of an enum
9736 (aarch64_supports_z_point_type): New function.
9737 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
9738 use Z_packet_to_target_hw_bp_type.
9740 2014-05-20 Joel Brobecker <brobecker@adacore.com>
9742 * configure.ac: Only use -Werror by default when DEVELOPMENT
9744 * configure: Regenerate.
9746 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
9748 Fix gdbserver qGetTLSAddr for x86_64 -m32.
9749 * linux-x86-low.c (X86_64_USER_REGS): New.
9750 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
9752 2014-04-28 Yao Qi <yao@codesourcery.com>
9754 * Makefile.in (i386-avx512.c): Fix the typo of generated file
9757 2014-04-25 Pedro Alves <palves@redhat.com>
9760 * linux-low.c (linux_attach_fail_reason_string): New function.
9761 (linux_attach_lwp): Delete.
9762 (linux_attach_lwp_1): Rename to ...
9763 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
9764 argument. Remove "initial" parameter. Return int instead of
9765 void. Don't error or warn here.
9766 (linux_attach): Adjust to call linux_attach_lwp. Call error on
9767 failure to attach to the tgid. Call warning when failing to
9769 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
9770 argument. Remove "initial" parameter. Return int instead of
9771 void. Don't error or warn here.
9772 (linux_attach_fail_reason_string): New declaration.
9773 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
9774 interface change. Use linux_attach_fail_reason_string.
9776 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
9777 Walfred Tedeschi <walfred.tedeschi@intel.com>
9779 * Makefile.in: Added rules to handle new files
9780 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
9781 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
9782 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
9783 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
9784 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
9785 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
9787 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
9788 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
9789 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
9790 i386/x32-avx512.xml.
9791 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
9792 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
9793 i386/x32-avx512-linux.xml.
9794 * i387-fp.c (num_avx512_k_registers): New constant for number
9796 (num_avx512_zmmh_low_registers): New constant for number of
9797 lower ZMM registers (0-15).
9798 (num_avx512_zmmh_high_registers): New constant for number of
9799 higher ZMM registers (16-31).
9800 (num_avx512_ymmh_registers): New contant for number of higher
9801 YMM registers (ymm16-31 added by avx521 on x86_64).
9802 (num_avx512_xmm_registers): New constant for number of higher
9803 XMM registers (xmm16-31 added by AVX512 on x86_64).
9804 (struct i387_xsave): Add space for AVX512 registers.
9805 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
9806 Add code to handle AVX512 registers.
9807 (i387_xsave_to_cache): Add code to handle AVX512 registers.
9808 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
9809 prototypei from generated file.
9810 (tdesc_amd64_avx512_linux): Likewise.
9811 (init_registers_x32_avx512_linux): Likewise.
9812 (tdesc_x32_avx512_linux): Likewise.
9813 (init_registers_i386_avx512_linux): Likewise.
9814 (tdesc_i386_avx512_linux): Likewise.
9815 (x86_64_regmap): Add AVX512 registers.
9816 (x86_linux_read_description): Add code to handle AVX512 XSTATE
9818 (initialize_low_arch): Add code to initialize AVX512 registers.
9820 2014-04-23 Pedro Alves <palves@redhat.com>
9822 * mem-break.c (find_gdb_breakpoint_at): Make static.
9823 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
9825 2014-04-23 Pedro Alves <palves@redhat.com>
9827 * i386-low.c: Don't include break-common.h here.
9828 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
9829 prototype to take target_hw_bp_type as argument instead of a Z
9831 * i386-low.h: Include break-common.h here.
9832 (Z_packet_to_hw_type): Declare.
9833 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
9835 * linux-x86-low.c (x86_insert_point): Convert the packet number to
9836 a target_hw_bp_type before calling i386_low_insert_watchpoint.
9837 (x86_remove_point): Convert the packet number to a
9838 target_hw_bp_type before calling i386_low_remove_watchpoint.
9839 * win32-i386-low.c (i386_insert_point): Convert the packet number
9840 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
9841 (i386_remove_point): Convert the packet number to a
9842 target_hw_bp_type before calling i386_low_remove_watchpoint.
9844 2014-04-23 Pedro Alves <palves@redhat.com>
9846 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
9848 2014-04-10 Pedro Alves <palves@redhat.com>
9850 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
9851 Check if the condition or command is NULL before checking if the
9852 breakpoint is known. On success, return true.
9853 * mem-break.h (add_breakpoint_condition): Document return.
9854 (add_breakpoint_commands): Add describing comment.
9855 * server.c (skip_to_semicolon): New function.
9856 (process_point_options): Use it.
9858 2014-04-09 Pedro Alves <palves@redhat.com>
9860 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
9863 2014-02-27 Pedro Alves <palves@redhat.com>
9866 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
9868 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
9870 (last_thread_of_process_p): Take a PID argument instead of a
9872 (linux_wait_for_lwp): Delete.
9873 (num_lwps, check_zombie_leaders, not_stopped_callback): New
9875 (linux_low_filter_event): New function, party factored out from
9876 linux_wait_for_event.
9877 (linux_wait_for_event): Rename to ...
9878 (linux_wait_for_event_filtered): ... this. Add new filter ptid
9879 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
9880 sigsuspend. Check for zombie leaders.
9881 (linux_wait_for_event): Reimplement as wrapper around
9882 linux_wait_for_event_filtered.
9883 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
9884 a normal or signal exit is seen, it's the whole process exiting.
9885 (wait_for_sigstop): No longer a for_each_inferior callback.
9886 Rewrite on top of linux_wait_for_event_filtered.
9887 (stop_all_lwps): Call wait_for_sigstop directly.
9888 * server.c (resume, handle_target_event): Handle
9889 TARGET_WAITKIND_NO_RESUMED.
9891 2014-02-26 Joel Brobecker <brobecker@adacore.com>
9893 * win32-low.c (psapi_get_dll_name,
9894 * win32_CreateToolhelp32Snapshot): Delete.
9895 (win32_CreateToolhelp32Snapshot, win32_Module32First)
9896 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
9898 (handle_load_dll): Add function description.
9899 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
9901 2014-02-26 Joel Brobecker <brobecker@adacore.com>
9903 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
9905 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
9906 base address when calling win32_add_one_solib.
9907 (handle_load_dll): Delete local variable load_addr.
9908 Remove 0x1000 offset applied to DLL base address when calling
9909 win32_add_one_solib.
9910 (handle_unload_dll): Add comment.
9912 2014-02-26 Joel Brobecker <brobecker@adacore.com>
9914 * win32-low.c (win32_add_all_dlls): Renames
9915 win32_ensure_ntdll_loaded. Rewrite function documentation.
9916 Adjust implementation to always load all DLLs.
9917 Add 0x1000 offset to DLL base address when calling
9918 win32_add_one_solib.
9919 (child_initialization_done): New static global.
9920 (do_initial_child_stuff): Set child_initialization_done to
9921 zero during child initialization, and 1 after. Replace call
9922 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
9924 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
9925 (handle_unload_dll): Add function documentation.
9926 (get_child_debug_event): Ignore load and unload DLL events
9927 during child initialization.
9929 2014-02-20 Doug Evans <dje@google.com>
9931 Remove global all_lwps.
9932 * inferiors.h (ptid_of): Move here from linux-low.h.
9933 (pid_of, lwpid_of): Ditto.
9934 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
9935 parameter is a struct thread_info * now.
9936 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
9937 directly. Pass &all_threads to find_inferior instead of &all_lwps.
9938 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
9940 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
9941 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
9942 * linux-arm-low.c (update_registers_callback): Update, "entry"
9943 parameter is a struct thread_info * now.
9944 Fetch lwpid from current_inferior directly.
9945 (arm_insert_point): Pass &all_threads to find_inferior instead of
9947 (arm_remove_point): Ditto.
9948 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
9949 (arm_prepare_to_resume): Fetch pid from thread.
9950 (arm_read_description): Fetch lwpid from current_inferior directly.
9951 * linux-low.c (all_lwps): Delete.
9952 (delete_lwp): Delete call to remove_inferior.
9953 (handle_extended_wait): Fetch lwpid from thread.
9954 (add_lwp): Don't set lwp->entry.id. Remove call to
9955 add_inferior_to_list.
9956 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
9957 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
9958 (kill_one_lwp_callback): Ditto.
9959 (linux_kill): Don't dereference NULL pointer.
9960 Fetch ptid,lwpid from thread.
9961 (get_detach_signal): Fetch ptid from thread.
9962 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
9963 Simplify call to regcache_invalidate_thread.
9964 (delete_lwp_callback): Update, "entry" parameter is a
9965 struct thread_info * now. Fetch pid from thread.
9966 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
9967 (status_pending_p_callback): Update, "entry" parameter is a
9968 struct thread_info * now. Fetch ptid from thread.
9969 (find_lwp_pid): Update, "entry" parameter is a
9970 struct thread_info * now.
9971 (linux_wait_for_lwp): Fetch pid from thread.
9972 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
9973 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
9974 (enqueue_one_deferred_signal): Fetch lwpid from thread.
9975 (dequeue_one_deferred_signal): Ditto.
9976 (cancel_breakpoint): Fetch ptid from current_inferior.
9977 (linux_wait_for_event): Pass &all_threads to find_inferior,
9978 not &all_lwps. Fetch ptid, lwpid from thread.
9979 (count_events_callback): Update, "entry" parameter is a
9980 struct thread_info * now.
9981 (select_singlestep_lwp_callback): Ditto.
9982 (select_event_lwp_callback): Ditto.
9983 (cancel_breakpoints_callback): Ditto.
9984 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
9986 (select_event_lwp): Ditto. Fetch ptid from event_thread.
9987 (unsuspend_one_lwp): Update, "entry" parameter is a
9988 struct thread_info * now.
9989 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
9991 (linux_stabilize_threads): Ditto. And for for_each_inferior.
9992 Fetch lwpid from thread, not lwp.
9993 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
9994 Pass &all_threads to find_inferior, not &all_lwps.
9995 (send_sigstop): Fetch lwpid from thread, not lwp.
9996 (send_sigstop_callback): Update, "entry" parameter is a
9997 struct thread_info * now.
9998 (suspend_and_send_sigstop_callback): Ditto.
9999 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
10000 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
10001 struct thread_info * now.
10002 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
10004 (lwp_running): Update, "entry" parameter is a
10005 struct thread_info * now.
10006 (stop_all_lwps): Fetch ptid from thread.
10007 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
10008 (linux_resume_one_lwp): Fetch lwpid from thread.
10009 (linux_set_resume_request): Update, "entry" parameter is a
10010 struct thread_info * now. Fetch pid, lwpid from thread.
10011 (resume_status_pending_p): Update, "entry" parameter is a
10012 struct thread_info * now.
10013 (need_step_over_p): Ditto. Fetch lwpid from thread.
10014 (start_step_over): Fetch lwpid from thread.
10015 (linux_resume_one_thread): Update, "entry" parameter is a
10016 struct thread_info * now. Fetch lwpid from thread.
10017 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
10018 (proceed_one_lwp): Update, "entry" parameter is a
10019 struct thread_info * now. Fetch lwpid from thread.
10020 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
10021 struct thread_info * now.
10022 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
10023 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
10024 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
10026 (regsets_store_inferior_registers): Ditto.
10027 (fetch_register, store_register): Ditto.
10028 (linux_read_memory, linux_write_memory): Ditto.
10029 (linux_request_interrupt): Ditto.
10030 (linux_read_auxv): Ditto.
10031 (linux_xfer_siginfo): Ditto.
10032 (linux_qxfer_spu): Ditto.
10033 (linux_qxfer_libraries_svr4): Ditto.
10034 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
10035 moved to inferiors.h.
10037 (get_thread_lwp): Update.
10038 (struct lwp_info): Delete member "entry". Simplify comment for
10040 (all_lwps): Delete.
10041 * linux-mips-low.c (mips_read_description): Fetch lwpid from
10042 current_inferior directly.
10043 (update_watch_registers_callback): Update, "entry" parameter is a
10044 struct thread_info * now. Fetch pid from thread.
10045 (mips_linux_prepare_to_resume): Fetch ptid from thread.
10046 (mips_insert_point): Fetch lwpid from current_inferior.
10047 Pass &all_threads to find_inferior, not &all_lwps.
10048 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
10049 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
10051 (mips_stopped_data_address): Ditto.
10052 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
10054 * linux-tile-low.c (tile_arch_setup): Ditto.
10055 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
10056 (update_debug_registers_callback): Update, "entry" parameter is a
10057 struct thread_info * now. Fetch pid from thread.
10058 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
10059 Pass &all_threads to find_inferior, not &all_lwps.
10060 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
10061 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
10062 Pass &all_threads to find_inferior, not &all_lwps.
10063 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
10064 (i386_dr_low_get_status): Ditto.
10065 (x86_linux_prepare_to_resume): Fetch ptid from thread.
10066 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
10067 (x86_linux_read_description): Ditto.
10068 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
10070 2014-02-20 Doug Evans <dje@google.com>
10072 * inferiors.c (get_first_inferior): Fix buglet.
10074 2014-02-19 Doug Evans <dje@google.com>
10076 * gdbthread.h (add_thread): Change result type to struct thread_info *.
10077 * inferiors.c (add_thread): Change result type to struct thread_info *.
10078 All callers updated.
10079 (add_lwp): Call add_thread here instead of in callers.
10080 All callers updated.
10081 * linux-low.h (get_lwp_thread): Rewrite.
10082 (struct lwp_info): New member "thread".
10084 2014-02-19 Doug Evans <dje@google.com>
10086 * linux-low.c (add_lwp): Change result to struct lwp_info *.
10087 All callers updated.
10089 2014-02-19 Doug Evans <dje@google.com>
10091 * inferiors.c (add_thread): Fix whitespace.
10093 2014-02-19 Doug Evans <dje@google.com>
10095 * dll.c (clear_dlls): Replace accessing list implemention details
10097 * gdbthread.h (get_first_thread): Declare.
10098 * inferiors.c (for_each_inferior_with_data): New function.
10099 (get_first_thread): New function.
10100 (find_thread_ptid): Simplify.
10101 (get_first_inferior): New function.
10102 (clear_list): Delete.
10103 (one_inferior_p): New function.
10104 (clear_inferior_list): New function.
10105 (clear_inferiors): Update.
10106 * inferiors.h (for_each_inferior_with_data): Declare.
10107 (clear_inferior_list): Declare.
10108 (one_inferior_p): Declare.
10109 (get_first_inferior): Declare.
10110 * linux-low.c (linux_wait_for_event): Replace accessing list
10111 implemention details with API function.
10112 * server.c (target_running): Ditto.
10113 (accumulate_file_name_length): New function.
10114 (emit_dll_description): New function.
10115 (handle_qxfer_libraries): Replace accessing list implemention
10116 details with API function.
10117 (handle_qxfer_threads_worker): New function.
10118 (handle_qxfer_threads_proper): Replace accessing list implemention
10119 details with API function.
10120 (handle_query): Ditto.
10121 (visit_actioned_threads_callback_ftype): New typedef.
10122 (visit_actioned_threads_data): New struct.
10123 (visit_actioned_threads): Rewrite to be find_inferior callback.
10124 (resume): Call find_inferior.
10125 (handle_status): Replace accessing list implemention
10126 details with API function.
10127 (process_serial_event): Replace accessing list implemention details
10129 * target.c (set_desired_inferior): Replace accessing list implemention
10130 details with API function.
10131 * tracepoint.c (same_process_p): New function.
10132 (gdb_agent_about_to_close): Replace accessing list implemention
10133 details with API function.
10134 * win32-low.c (child_delete_thread): Replace accessing list
10135 implemention details with API function.
10136 (match_dll_by_basename): New function.
10137 (dll_is_loaded_by_basename): New function.
10138 (win32_ensure_ntdll_loaded): Replace accessing list implemention
10139 details call to dll_is_loaded_by_basename.
10141 2014-02-19 Doug Evans <dje@google.com>
10143 * dll.h (struct dll_info): Add comment.
10144 * gdbthread.h (struct thread_info): Add comment.
10145 (current_ptid): Simplify.
10146 * inferiors.c (add_process): Update.
10147 (remove_process): Update.
10148 * inferiors.h (struct process_info): Rename member "head" to "entry".
10149 * linux-low.c (delete_lwp): Update.
10151 (last_thread_of_process_p): Update.
10152 (kill_one_lwp_callback, linux_kill): Update.
10153 (status_pending_p_callback): Update.
10154 (wait_for_sigstop): Update. Simplify read of ptid.
10155 (start_step_over): Update.
10156 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
10157 (get_lwp_thread): Update.
10158 (struct lwp_info): Rename member "head" to "entry".
10159 * regcache.h (inferior_list_entry): Delete.
10160 * server.c (kill_inferior_callback): Update.
10161 (detach_or_kill_inferior_callback): Update.
10162 (print_started_pid): Update.
10163 (print_attached_pid): Update.
10164 (process_serial_event): Simplify read of ptid.
10165 * thread-db.c (thread_db_create_event): Update.
10166 (thread_db_get_tls_address): Update.
10167 * win32-low.c (current_inferior_ptid): Simplify.
10169 2014-02-19 Tom Tromey <tromey@redhat.com>
10171 * target.h (struct target_ops) <supports_btrace>: Add target_ops
10173 (target_supports_btrace): Update.
10175 2014-02-14 Yao Qi <yao@codesourcery.com>
10177 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
10178 (rsp-low-ipa.o): New target.
10180 2014-02-12 Tom Tromey <tromey@redhat.com>
10182 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
10183 convert_ascii_to_int.
10184 * regcache.c (registers_to_string): Likewise.
10185 * remote-utils.c (decode_M_packet): Likewise.
10186 * server.c (process_serial_event): Likewise.
10188 2014-02-12 Tom Tromey <tromey@redhat.com>
10190 * server.c (handle_query, handle_v_run): Use hex2bin, not
10192 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
10194 2014-02-12 Tom Tromey <tromey@redhat.com>
10196 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
10197 convert_int_to_ascii.
10198 * regcache.c (registers_to_string, collect_register_as_string):
10200 * remote-utils.c (look_up_one_symbol, relocate_instruction):
10202 * server.c (process_serial_event): Likewise.
10203 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
10204 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
10206 2014-02-12 Tom Tromey <tromey@redhat.com>
10208 * remote-utils.c (look_up_one_symbol, monitor_output): Use
10209 bin2hex, not hexify.
10210 * tracepoint.c (cmd_qtstatus): Likewise.
10212 2014-02-12 Tom Tromey <tromey@redhat.com>
10214 * remote-utils.c (monitor_output): Pass explicit length to
10217 2014-02-12 Tom Tromey <tromey@redhat.com>
10219 * tracepoint.c: Include rsp-low.h.
10220 * server.c: Include rsp-low.h.
10221 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
10222 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
10224 * remote-utils.c: Include rsp-low.h.
10225 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
10226 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
10227 (convert_int_to_ascii, convert_ascii_to_int): Move to
10229 * regcache.c: Include rsp-low.h.
10230 * ax.c: Include rsp-low.h.
10231 * Makefile.in (SFILES): Add common/rsp-low.c.
10232 (OBS): Add rsp-low.o.
10233 (rsp-low.o): New target.
10235 2014-02-12 Tom Tromey <tromey@redhat.com>
10237 * utils.h (pulongest, plongest, phex_nz): Don't declare.
10238 Include print-utils.h.
10239 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
10240 (plongest, thirty_two, phex_nz): Remove.
10241 * Makefile.in (SFILES): Add common/print-utils.c.
10242 (OBS): Add print-utils.o.
10243 (print-utils-ipa.o): New target.
10244 (print-utils.o): New target.
10245 (IPA_OBJS): Add print-utils-ipa.o.
10247 2014-02-06 Tom Tromey <tromey@redhat.com>
10249 * Makefile.in (SFILES): Fix indentation.
10251 2014-02-05 Doug Evans <dje@google.com>
10253 * linux-low.c (linux_wait_for_event): Improve comment.
10254 (linux_wait_1): Keep current_inferior in sync with event_child.
10256 2014-01-22 Doug Evans <dje@google.com>
10258 * gdbthread.h (gdb_id_to_thread): Delete, unused.
10260 2014-01-22 Doug Evans <dje@google.com>
10262 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
10263 * configure: Regenerate.
10264 * config.in: Regenerate.
10265 * Makefile.in (SFILES): Add debug.c.
10266 (OBS): Add debug.o.
10267 * debug.c: New file.
10268 * debug.h: New file.
10269 * linux-aarch64-low.c (*): Update all debugging printfs to use
10270 debug_printf instead of fprintf.
10271 * linux-arm-low.c (*): Ditto.
10272 * linux-cris-low.c (*): Ditto.
10273 * linux-crisv32-low.c (*): Ditto.
10274 * linux-m32r-low.c (*): Ditto.
10275 * linux-sparc-low.c (*): Ditto.
10276 * linux-x86.c (*): Ditto.
10277 * linux-low.c (*): Ditto.
10278 (linux_wait_1): Add calls to debug_enter, debug_exit.
10279 (linux_wait): Remove redundant debugging printf.
10280 (stop_all_lwps): Add calls to debug_enter, debug_exit.
10281 (linux_resume, unstop_all_lwps): Ditto.
10282 * mem-break.c (*): Update all debugging printfs to use
10283 debug_printf instead of fprintf.
10284 * remote-utils.c (*): Ditto.
10285 * thread-db.c (*): Ditto.
10286 * server.c #include <ctype.h>, "gdb_vecs.h".
10287 (debug_threads): Moved to debug.c.
10288 (*): Update all debugging printfs to use debug_printf instead of
10290 (start_inferior): Replace call to fflush with call to debug_flush.
10291 (monitor_show_help): Mention set debug-format.
10292 (parse_debug_format_options): New function.
10293 (handle_monitor_command): Handle "monitor set debug-format".
10294 (gdbserver_usage): Mention --debug-format.
10295 (main): Parse --debug-format.
10296 * server.h (debug_threads): Declaration moved to debug.h.
10297 #include "debug.h".
10298 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
10299 trace_debug_1 that uses debug_printf.
10300 (tracepoint_look_up_symbols): Update all debugging printfs to use
10301 debug_printf instead of fprintf.
10303 2014-01-20 Baruch Siach <baruch@tkos.co.il>
10305 * linux-xtensa-low.c: Include asm/ptrace.h instead of
10308 2014-01-17 Pedro Alves <palves@redhat.com>
10311 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
10312 defined after including gdb_proc_service.h.
10314 2014-01-16 Doug Evans <dje@google.com>
10316 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
10317 (match_dll): Use it.
10319 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
10321 * target.h (target_ops) <read_btrace>: Change parameters and
10322 return type to allow error reporting.
10323 * server.c (handle_qxfer_btrace): Support delta reads. Pass
10324 trace reading errors on.
10325 * linux-low.c (linux_low_read_btrace): Pass trace reading
10327 (linux_low_disable_btrace): New.
10329 2014-01-15 Doug Evans <dje@google.com>
10331 * inferiors.c (thread_id_to_gdb_id): Delete.
10332 * inferiors.h (thread_id_to_gdb_id): Delete.
10334 2014-01-13 Eli Zaretskii <eliz@gnu.org>
10336 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
10337 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
10340 2014-01-08 Pedro Alves <palves@redhat.com>
10342 * server.c (handle_status): Don't discard previous queued stop
10343 replies or thread's pending status here.
10344 (main) <disconnection>: Do it here instead.
10346 2014-01-08 Pedro Alves <palves@redhat.com>
10348 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
10349 * server.c (visit_actioned_threads, handle_pending_status): New
10351 (handle_v_cont): Factor out parts to ...
10352 (resume): ... this new function. If in all-stop, and a thread
10353 being resumed has a pending status, report it without actually
10355 (myresume): Adjust to use the new 'resume' function.
10356 (clear_pending_status_callback, set_pending_status_callback)
10357 (find_status_pending_thread_callback): New functions.
10358 (handle_status): Handle the case of multiple threads having
10359 interesting statuses to report. Report threads' real last signal
10360 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
10361 with an interesting thread to report the status for, instead of
10362 always reporting the status of the first thread.
10364 2014-01-01 Joel Brobecker <brobecker@adacore.com>
10366 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
10367 * gdbreplay.c (gdbreplay_version): Likewise.
10369 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
10371 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
10372 iov.iov_len with the real length in use.
10374 2013-12-13 Joel Brobecker <brobecker@adacore.com>
10376 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
10377 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
10378 for all targets that use win32-low.c.
10379 * win32-low.c (win32_ensure_ntdll_loaded): New function.
10380 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
10382 2013-12-13 Pedro Alves <palves@redhat.com>
10384 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
10385 if equal to TARGET_WAITKIND_LOADED.
10386 * win32-low.c (cached_status): New static global.
10387 (win32_wait): Add declaration.
10388 (do_initial_child_stuff): Flush all initial pending debug events
10389 up to the initial breakpoint.
10390 (win32_wait): If CACHED_STATUS was set, return that instead
10391 of doing a real wait. Remove the code resuming the execution
10392 of the inferior after receiving a TARGET_WAITKIND_LOADED event
10393 during the initial phase. Also remove the code changing
10394 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
10395 TARGET_WAITKIND_STOPPED.
10397 2013-12-11 Yao Qi <yao@codesourcery.com>
10399 * notif.c (handle_notif_ack): Return 0 if no notification
10402 2013-11-20 Doug Evans <dje@google.com>
10404 * linux-low.c (linux_set_resume_request): Fix comment.
10406 2013-11-20 Doug Evans <dje@google.com>
10408 * linux-low.c (resume_status_pending_p): Tweak comment.
10410 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
10412 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
10413 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
10414 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
10415 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
10416 (srv_amd64_regobj): Add amd64-mpx.o.
10417 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
10418 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
10419 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
10420 * i387-fp.c (num_pl_bnd_register) Added constant.
10421 (num_pl_bnd_cfg_registers) Added constant.
10422 (struct i387_xsave) Added reserved area and MPX fields.
10423 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
10424 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
10426 (tdesc_i386_mpx_linux): Add MPX amd64 target.
10427 (init_registers_amd64_mpx_linux): Declare new function.
10428 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
10429 (x86_64_regmap): Add MPX registers.
10430 (x86_linux_read_description): Add MPX case.
10431 (initialize_low_arch): Initialize MPX targets.
10433 2013-11-18 Tom Tromey <tromey@redhat.com>
10435 * configure: Rebuild.
10436 * configure.ac: Don't check for stdlib.h.
10437 * gdbreplay.c: Unconditionally include stdlib.h.
10439 2013-11-18 Tom Tromey <tromey@redhat.com>
10441 * config.in: Rebuild.
10442 * configure: Rebuild.
10443 * configure.ac: Don't use AC_HEADER_DIRENT.
10445 2013-11-18 Tom Tromey <tromey@redhat.com>
10447 * server.h: Don't check HAVE_STRING_H.
10448 * gdbreplay.c: Don't check HAVE_STRING_H.
10449 * configure: Rebuild.
10451 2013-11-18 Tom Tromey <tromey@redhat.com>
10453 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
10456 2013-11-08 Tom Tromey <tromey@redhat.com>
10458 * configure, config.in: Rebuild.
10459 * configure.ac: Remove unused configury.
10461 2013-11-08 Tom Tromey <tromey@redhat.com>
10463 * acinclude.m4: Include common.m4, codeset.m4.
10464 * configure, config.in: Rebuild.
10465 * configure.ac: Use GDB_AC_COMMON.
10467 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
10469 * linux-s390-low.c (HWCAP_S390_TE): New define.
10470 (s390_arch_setup): Consider the TE field in the HWCAP for
10471 determining 'have_regset_tdb'.
10473 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
10476 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
10479 2013-10-02 Pedro Alves <palves@redhat.com>
10481 * server.c (process_serial_event): Don't output "GDBserver
10482 exiting" if GDB is connected through stdio.
10483 * target.c (mywait): Likewise, be silent if GDB is connected
10486 2013-10-01 Joel Brobecker <brobecker@adacore.com>
10488 * lynx-low.c (lynx_add_threads_after_attach): New function.
10489 (lynx_attach): Remove call to add_thread. Add call to
10490 lynx_add_threads_after_attach instead.
10492 2013-09-28 Mike Frysinger <vapier@gentoo.org>
10494 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
10495 * config.in, configure: Regenerated.
10497 2013-09-18 Yao Qi <yao@codesourcery.com>
10500 * server.c (start_inferior): Clear 'resume_info'.
10502 2013-09-16 Jiong Wang <jiwang@tilera.com>
10504 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
10507 2013-09-16 Jiong Wang <jiwang@tilera.com>
10509 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
10510 linux-tile-low.o to srv_tgtobj.
10512 2013-09-16 Will Newton <will.newton@linaro.org>
10514 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
10517 2013-09-06 Pedro Alves <palves@redhat.com>
10519 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
10520 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
10521 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
10522 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
10523 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
10524 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
10526 2013-09-06 Pedro Alves <palves@redhat.com>
10528 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
10529 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
10531 2013-09-06 Pedro Alves <palves@redhat.com>
10533 * linux-amd64-ipa.c: Include tracepoint.h.
10534 * linux-i386-ipa.c: Include tracepoint.h.
10536 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
10538 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
10539 (ps_get_thread_area): New function.
10541 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
10543 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
10544 (initialize_low_arch): Call init_registers_crisv32 rather than
10545 init_register_crisv32.
10547 2013-09-05 Pedro Alves <palves@redhat.com>
10549 * server.h (handle_vFile, hostio_last_error_from_errno): Move
10551 * hostio.h: ... this new file.
10552 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
10553 win32-low.c: Include hostio.h.
10555 2013-09-05 Pedro Alves <palves@redhat.com>
10557 * server.h (gdb_client_data, handler_func, callback_handler_func)
10558 (delete_file_handler, add_file_handler, append_callback_event)
10559 (delete_callback_event, start_event_loop, initialize_event_loop):
10560 Move to event-loop.h and include it.
10561 * event-loop.h: New file.
10563 2013-09-05 Pedro Alves <palves@redhat.com>
10565 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
10566 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
10567 (loaded_dll, unloaded_dll): Move to ...
10568 * dll.h: ... this new file.
10569 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
10571 2013-09-05 Pedro Alves <palves@redhat.com>
10573 * server.h (current_process, get_thread_process, all_processes)
10574 (add_inferior_to_list, for_each_inferior, current_inferior)
10575 (remove_inferior, add_process, remove_process, find_process_pid)
10576 (have_started_inferiors_p, have_attached_inferiors_p)
10577 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
10578 (clear_inferiors, find_inferior, find_inferior_id)
10579 (inferior_target_data, set_inferior_target_data)
10580 (inferior_regcache_data, set_inferior_regcache_data): Move to
10581 inferiors.h, and include it.
10582 * inferiors.h: New file.
10584 2013-09-05 Pedro Alves <palves@redhat.com>
10586 * server.h (struct emit_ops, current_insn_ptr, emit_error):
10590 2013-09-05 Pedro Alves <palves@redhat.com>
10592 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
10594 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
10595 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
10596 (handle_tracepoint_general_set, handle_tracepoint_query)
10597 (tracepoint_finished_step, tracepoint_was_hit)
10598 (release_while_stepping_state_list, current_traceframe)
10599 (in_readonly_region, traceframe_read_mem)
10600 (fetch_traceframe_registers, traceframe_read_sdata)
10601 (traceframe_read_info, struct fast_tpoint_collect_status)
10602 (fast_tracepoint_collecting, force_unlock_trace_buffer)
10603 (handle_tracepoit_bkpts, initialize_low_tracepoint)
10604 (supply_fast_tracepoint_registers)
10605 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
10606 (ipa_tdesc, claim_trampoline_space)
10607 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
10608 (agent_mem_read, agent_get_trace_state_variable_value)
10609 (agent_set_trace_state_variable_value, agent_tsv_read)
10610 (agent_mem_read_string, get_raw_reg_func_addr)
10611 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
10612 * tracepoint.h: ... this new file.
10614 2013-09-05 Pedro Alves <palves@redhat.com>
10616 * server.h (perror_with_name, error, fatal, warning, paddress)
10617 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
10619 * utils.h: New file.
10621 2013-09-05 Pedro Alves <palves@redhat.com>
10623 * server.h (remote_debug, noack_mode, transport_is_reliable)
10624 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
10625 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
10626 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
10627 (write_enn, initialize_async_io, enable_async_io)
10628 (disable_async_io, check_remote_input_interrupt_request)
10629 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
10630 (dead_thread_notify, prepare_resume_reply)
10631 (decode_address_to_semicolon, decode_address, decode_m_packet)
10632 (decode_M_packet, decode_X_packet, decode_xfer_write)
10633 (decode_search_memory_packet, unhexify, hexify)
10634 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
10635 (look_up_one_symbol, relocate_instruction)
10636 (monitor_output): Move to remote-utils.h, and include it.
10637 * remote-utils.h: New file.
10639 2013-09-05 Pedro Alves <palves@redhat.com>
10641 * server.h (_): Delete.
10643 2013-09-02 Pedro Alves <palves@redhat.com>
10645 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
10646 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
10648 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
10650 2013-09-02 Pierre Muller <muller@sourceware.org>
10652 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
10653 or WriteProcessMemory complete successfully and handle
10654 ERROR_PARTIAL_COPY error.
10656 2013-09-02 Pedro Alves <palves@redhat.com>
10658 * server.c (gdb_read_memory): Return -1 on traceframe memory read
10659 error instead of EIO.
10661 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
10664 * linux-low.c: Include filestuff.h.
10665 (linux_create_inferior) <pid == 0>: Call close_most_fds.
10666 * lynx-low.c: Include filestuff.h.
10667 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
10668 * server.c: Include filestuff.h.
10669 (main): Call notice_open_fds.
10670 * spu-low.c: Include filestuff.h.
10671 (spu_create_inferior) <pid == 0>: Call close_most_fds.
10673 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
10675 * Makefile.in: Explain why ../target and ../nat are not
10676 listed as include file search paths.
10677 (linux-waitpid.o): New object file rule.
10678 * configure.srv (srv_native_linux_obj): New variable.
10679 Replace all occurrences of linux native object files with
10680 $srv_native_linux_obj.
10681 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
10682 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
10683 (linux_enable_event_reporting): Remove declaration.
10684 (my_waitpid): Moved to common/linux-waitpid.c.
10685 (linux_wait_for_event): Pass ptid when calling
10686 linux_enable_event_reporting.
10687 (linux_supports_tracefork_flag): Remove.
10688 (linux_enable_event_reporting): Likewise.
10689 (linux_tracefork_grandchild): Remove.
10690 (STACK_SIZE): Moved to common/linux-ptrace.c.
10691 (linux_tracefork_child): Remove.
10692 (linux_test_for_tracefork): Remove.
10693 (linux_look_up_symbols): Call linux_supports_traceclone.
10694 (initialize_low): Remove call to linux_test_for_tracefork.
10695 * linux-low.h (PTRACE_TYPE_ARG3): Move to
10696 common/linux-ptrace.h.
10697 (PTRACE_TYPE_ARG4): Likewise.
10698 Include linux-ptrace.h.
10700 2013-08-21 Pedro Alves <palves@redhat.com>
10702 * config.in: Renegerate.
10704 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
10706 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
10707 (SFILES): Remove $(srcdir)/common/target-common.c and
10708 add $(srcdir)/target/waitstatus.c.
10709 (OBS): Remove target-common.o and add waitstatus.o.
10710 (server_h): Remove $(srcdir)/../common/target-common.h and
10711 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
10712 and $(srcdir)/../target/waitstatus.h.
10713 (target-common.o): Remove.
10714 (waitstatus.o): New target object file.
10715 * target.h: Do not include target-common.h and
10716 include target/resume.h, target/wait.h and
10717 target/waitstatus.h.
10719 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
10721 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
10722 to PTRACE_TYPE_ARG3.
10723 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
10724 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
10726 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
10727 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
10729 2013-07-27 Jie Zhang <jie@codesourcery.com>
10730 Daniel Jacobowitz <dan@codesourcery.com>
10731 Yao Qi <yao@codesourcery.com>
10733 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
10734 (mips-linux-watch.o): New rule.
10735 (mips_linux_watch_h): New variable.
10736 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
10738 * linux-mips-low.c: Include mips-linux-watch.h.
10739 (struct arch_process_info, struct arch_lwp_info): New.
10740 (update_watch_registers_callback): New function.
10741 (mips_linux_new_process, mips_linux_new_thread) New functions.
10742 (mips_linux_prepare_to_resume, mips_insert_point): New
10744 (mips_remove_point, mips_stopped_by_watchpoint): New
10746 (rsp_bp_type_to_target_hw_bp_type): New function.
10747 (mips_stopped_data_address): New function.
10748 (the_low_target): Add watchpoint support functions.
10750 2013-07-27 Yao Qi <yao@codesourcery.com>
10752 * i386-low.c: Include break-common.h.
10753 (enum target_hw_bp_type): Remove.
10755 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
10757 * Makefile.in (SFILES): /common/target-common.c.
10758 (OBS): Add target-common.o.
10759 (server_h): Add $(srcdir)/../common/target-common.h.
10760 (target-common.o): New target.
10761 * server.c (queue_stop_reply_callback): Free
10762 status string after use.
10763 * target.c (target_waitstatus_to_string): Remove.
10764 * target.h: Include target-common.h.
10765 (resume_kind): Likewise.
10766 (target_waitkind): Likewise.
10767 (target_waitstatus): Likewise.
10768 (TARGET_WNOHANG): Likewise.
10770 2013-07-04 Yao Qi <yao@codesourcery.com>
10772 * Makefile.in (host_alias): Use @host_noncanonical@.
10773 (target_alias): Use @target_noncanonical@.
10774 * configure.ac: Use ACX_NONCANONICAL_TARGET and
10775 ACX_NONCANONICAL_HOST.
10776 * configure: Regenerated.
10779 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
10781 * configure.ac (version_host, version_target): Set and AC_SUBST them.
10782 * configure: Rebuild.
10783 * Makefile.in (version_host, version_target): Get from configure.
10784 (version.c): Use $(version_host) and $(version_target).
10786 2013-07-03 Pedro Alves <palves@redhat.com>
10788 * Makefile.in (config.status): Depend on development.sh.
10789 * acinclude.m4: Include libmcheck.m4.
10790 * configure: Regenerate.
10792 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
10794 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
10795 attribute inside the parentheses.
10796 (winapi_DebugSetProcessKillOnExit): Ditto.
10797 (winapi_DebugBreakProcess): Ditto.
10798 (winapi_GenerateConsoleCtrlEvent): Ditto.
10800 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
10802 * notif.h (notif_event): Add a dummy member to avoid compiler
10805 2013-07-01 Pedro Alves <palves@redhat.com>
10807 * hostio.c (HOSTIO_PATH_MAX): Define.
10808 (require_filename, handle_open, handle_unlink, handle_readlink):
10811 2013-07-01 Pedro Alves <palves@redhat.com>
10813 * server.h: Include "pathmax.h".
10814 * linux-low.c: Don't include sys/param.h.
10815 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
10817 * win32-low.c: Don't include sys/param.h.
10818 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
10820 2013-07-01 Pedro Alves <palves@redhat.com>
10822 * event-loop.c: Don't check HAVE_UNISTD_H before including
10824 * gdbreplay.c: Likewise.
10825 * remote-utils.c: Likewise.
10826 * server.c: Likewise.
10827 * configure.ac: Don't check for unistd.h.
10828 * configure: Regenerate.
10830 2013-06-28 Tom Tromey <tromey@redhat.com>
10832 * Makefile.in (version.c): Use version.in, not
10835 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
10837 * configure.ac (version_host, version_target): Set and AC_SUBST them.
10838 * configure: Rebuild.
10839 * Makefile.in (version_host, version_target): Get from configure.
10840 (version.c): Use $(version_host) and $(version_target).
10842 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
10844 Fix trace-status to output user name without trailing colon.
10845 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
10847 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
10849 Fix trace-status to output proper start-time and stop-time.
10850 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
10851 output start time and stop time in hex as gdb expects.
10853 2013-06-26 Pedro Alves <pedro@codesourcery.com>
10855 * tracepoint.c (build_traceframe_info_xml): Output trace state
10856 variables present in the trace buffer.
10858 2013-06-24 Tom Tromey <tromey@redhat.com>
10860 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
10862 (version.o): Remove.
10863 * gdbreplay.c: Include version.h.
10864 (version, host_name): Don't declare.
10865 * server.h: Include version.h.
10866 (version, host_name): Don't declare.
10868 2013-06-12 Pedro Alves <palves@redhat.com>
10870 * linux-x86-low.c (linux_is_elf64): Delete global.
10871 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
10872 with local linux_pid_exe_is_elf_64_file use.
10874 2013-06-11 Pedro Alves <palves@redhat.com>
10876 * linux-low.c (regset_disabled, disable_regset): New functions.
10877 (regsets_fetch_inferior_registers)
10878 (regsets_store_inferior_registers): Use them.
10879 (initialize_regsets_info); Don't allocate the disabled_regsets
10881 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
10884 2013-06-11 Pedro Alves <palves@redhat.com>
10886 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
10889 2013-06-11 Pedro Alves <palves@redhat.com>
10891 * linux-x86-low.c (initialize_low_arch): Call
10892 init_registers_x32_avx_linux.
10894 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
10896 Fix compatibility with Android Bionic.
10897 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
10900 2013-06-07 Pedro Alves <palves@redhat.com>
10903 * Makefile.in (OBS): Add tdesc.o.
10904 (IPA_OBJS): Add tdesc-ipa.o.
10905 (tdesc-ipa.o): New rule.
10906 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
10908 * linux-low.c (new_inferior): Delete.
10909 (disabled_regsets, num_regsets): Delete.
10910 (linux_add_process): Adjust to set the new per-process
10912 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
10913 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
10914 was a stop. When calling arch_setup, switch the current inferior
10915 to the thread that got an event.
10916 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
10917 (regsets_fetch_inferior_registers)
10918 (regsets_store_inferior_registers): New regsets_info parameter.
10920 (linux_register_in_regsets): New regs_info parameter. Adjust to
10922 (register_addr, fetch_register, store_register): New usrregs_info
10923 parameter. Adjust to use it.
10924 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
10925 parameter regs_info. Adjust to use it.
10926 (linux_fetch_registers): Get the current inferior's regs_info, and
10928 (linux_store_registers): Ditto.
10929 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
10930 (initialize_low): Don't initialize the target_regsets here. Call
10931 initialize_low_arch.
10932 * linux-low.h (target_regsets): Delete declaration.
10933 (struct regsets_info): New.
10934 (struct usrregs_info): New.
10935 (struct regs_info): New.
10936 (struct process_info_private) <new_inferior>: New field.
10937 (struct linux_target_ops): Delete the num_regs, regmap, and
10938 regset_bitmap fields. New field regs_info.
10939 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
10940 * i387-fp.c (num_xmm_registers): Delete.
10941 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
10942 calls to new interface.
10943 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
10944 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
10945 Infer the number of xmm registers from the regcache's target
10947 * i387-fp.h (num_xmm_registers): Delete.
10948 * inferiors.c (add_thread): Don't install the thread's regcache
10950 * proc-service.c (gregset_info): Fetch the current inferior's
10951 regs_info. Adjust to use it.
10952 * regcache.c: Include tdesc.h.
10953 (register_bytes, reg_defs, num_registers)
10954 (gdbserver_expedite_regs): Delete.
10955 (get_thread_regcache): If the thread doesn't have a regcache yet,
10956 create one, instead of aborting gdbserver.
10957 (regcache_invalidate_one): Rename to ...
10958 (regcache_invalidate_thread): ... this.
10959 (regcache_invalidate_one): New.
10960 (regcache_invalidate): Only invalidate registers of the current
10962 (init_register_cache): Add target_desc parameter, and use it.
10963 (new_register_cache): Ditto. Assert the target description has a
10964 non zero registers_size.
10965 (regcache_cpy): Add assertions. Adjust.
10966 (realloc_register_cache, set_register_cache): Delete.
10967 (registers_to_string, registers_from_string): Adjust.
10968 (find_register_by_name, find_regno, find_register_by_number)
10969 (register_cache_size): Add target_desc parameter, and use it.
10970 (free_register_cache_thread, free_register_cache_thread_one)
10971 (regcache_release, register_cache_size): New.
10972 (register_size): Add target_desc parameter, and use it.
10973 (register_data, supply_register, supply_register_zeroed)
10974 (supply_regblock, supply_register_by_name, collect_register)
10975 (collect_register_as_string, collect_register_by_name): Adjust.
10976 * regcache.h (struct target_desc): Forward declare.
10977 (struct regcache) <tdesc>: New field.
10978 (init_register_cache, new_register_cache): Add target_desc
10980 (regcache_invalidate_thread): Declare.
10981 (regcache_invalidate_one): Delete declaration.
10982 (regcache_release): Declare.
10983 (find_register_by_number, register_cache_size, register_size)
10984 (find_regno): Add target_desc parameter.
10985 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
10987 * remote-utils.c: Include tdesc.h.
10988 (outreg, prepare_resume_reply): Adjust.
10989 * server.c: Include tdesc.h.
10990 (gdbserver_xmltarget): Delete declaration.
10991 (get_features_xml, process_serial_event): Adjust.
10992 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
10994 (struct process_info) <tdesc>: New field.
10995 (ipa_tdesc): Declare.
10996 * tdesc.c: New file.
10997 * tdesc.h: New file.
10998 * tracepoint.c: Include tdesc.h.
10999 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
11000 (get_context_regcache): Adjust to pass ipa_tdesc down.
11001 (do_action_at_tracepoint): Adjust to get the register cache size
11002 from the context regcache's description.
11003 (traceframe_walk_blocks): Adjust to get the register cache size
11004 from the current trace frame's description.
11005 (traceframe_get_pc): Adjust to get current trace frame's
11006 description and pass it down.
11007 (gdb_collect): Adjust to get the register cache size from the
11009 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
11010 (gdbserver_xmltarget): Delete.
11011 (initialize_low_tracepoint): Set the ipa's target description.
11012 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
11013 (initialize_low_tracepoint): Set the ipa's target description.
11014 * linux-x86-low.c: Include tdesc.h.
11015 [__x86_64__] (is_64bit_tdesc): New.
11016 (ps_get_thread_area, x86_get_thread_area): Use it.
11017 (i386_cannot_store_register): Rename to ...
11018 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
11019 (i386_cannot_fetch_register): Rename to ...
11020 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
11021 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
11023 (target_regsets): Rename to ...
11024 (x86_regsets): ... this.
11025 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
11027 (x86_siginfo_fixup): Use is_64bit_tdesc.
11028 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
11029 (tdesc_x32_avx_linux, tdesc_x32_linux)
11030 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
11032 (x86_linux_update_xmltarget): Delete.
11033 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
11034 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
11035 (AMD64_LINUX_USER64_CS): New.
11036 (x86_linux_read_description): New, based on
11037 x86_linux_update_xmltarget.
11038 (same_process_callback): New.
11039 (x86_arch_setup_process_callback): New.
11040 (x86_linux_update_xmltarget): New.
11041 (x86_regsets_info): New.
11042 (amd64_linux_regs_info): New.
11043 (i386_linux_usrregs_info): New.
11044 (i386_linux_regs_info): New.
11045 (x86_linux_regs_info): New.
11046 (x86_arch_setup): Reimplement.
11047 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
11048 (x86_emit_ops): Ditto.
11049 (the_low_target): Adjust. Install x86_linux_regs_info,
11050 x86_cannot_fetch_register, and x86_cannot_store_register.
11051 (initialize_low_arch): New.
11052 * linux-ia64-low.c (tdesc_ia64): Declare.
11053 (ia64_fetch_register): Adjust.
11054 (ia64_usrregs_info, regs_info): New globals.
11055 (ia64_regs_info): New function.
11056 (the_low_target): Adjust.
11057 (initialize_low_arch): New function.
11058 * linux-sparc-low.c (tdesc_sparc64): Declare.
11059 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
11061 (sparc_arch_setup): New function.
11062 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
11063 (the_low_target): Adjust.
11064 (initialize_low_arch): New function.
11065 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
11066 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
11067 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
11068 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
11069 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
11070 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
11071 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
11072 (tdesc_powerpc_isa205_vsx64l): Declare.
11073 (ppc_cannot_store_register, ppc_collect_ptrace_register)
11074 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
11075 (ppc_set_pc, ppc_get_hwcap): Adjust.
11076 (ppc_usrregs_info): Forward declare.
11077 (!__powerpc64__) ppc_regmap_adjusted: New global.
11078 (ppc_arch_setup): Adjust to the current process'es target
11080 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
11081 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
11082 (ppc_store_evrregset): Adjust.
11083 (target_regsets): Rename to ...
11084 (ppc_regsets): ... this, and make static.
11085 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
11086 (ppc_regs_info): New function.
11087 (the_low_target): Adjust.
11088 (initialize_low_arch): New function.
11089 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
11090 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
11091 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
11092 (tdesc_s390x_linux64v2): Declare.
11093 (s390_collect_ptrace_register, s390_supply_ptrace_register)
11094 (s390_fill_gregset, s390_store_last_break): Adjust.
11095 (target_regsets): Rename to ...
11096 (s390_regsets): ... this, and make static.
11097 (s390_get_pc, s390_set_pc): Adjust.
11098 (s390_get_hwcap): New target_desc parameter, and use it.
11099 [__s390x__] (have_hwcap_s390_high_gprs): New global.
11100 (s390_arch_setup): Adjust to set the current process'es target
11101 description. Don't adjust the regmap.
11102 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
11103 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
11104 (regs_info_3264): New globals.
11105 (s390_regs_info): New function.
11106 (the_low_target): Adjust.
11107 (initialize_low_arch): New function.
11108 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
11109 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
11110 [__mips64] (init_registers_mips_linux)
11111 (init_registers_mips_dsp_linux): Delete defines.
11112 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
11113 (have_dsp): New global.
11114 (mips_read_description): New, based on mips_arch_setup.
11115 (mips_arch_setup): Reimplement.
11116 (get_usrregs_info): New function.
11117 (mips_cannot_fetch_register, mips_cannot_store_register)
11118 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
11119 (mips_fill_fpregset, mips_store_fpregset): Adjust.
11120 (target_regsets): Rename to ...
11121 (mips_regsets): ... this, and make static.
11122 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
11123 (dsp_regs_info, regs_info): New globals.
11124 (mips_regs_info): New function.
11125 (the_low_target): Adjust.
11126 (initialize_low_arch): New function.
11127 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
11128 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
11130 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
11131 (arm_read_description): New, with bits factored from
11133 (arm_arch_setup): Reimplement.
11134 (target_regsets): Rename to ...
11135 (arm_regsets): ... this, and make static.
11136 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
11137 (arm_regs_info): New function.
11138 (the_low_target): Adjust.
11139 (initialize_low_arch): New function.
11140 * linux-m68k-low.c (tdesc_m68k): Declare.
11141 (target_regsets): Rename to ...
11142 (m68k_regsets): ... this, and make static.
11143 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
11144 (m68k_regs_info): New function.
11145 (m68k_arch_setup): New function.
11146 (the_low_target): Adjust.
11147 (initialize_low_arch): New function.
11148 * linux-sh-low.c (tdesc_sharch): Declare.
11149 (target_regsets): Rename to ...
11150 (sh_regsets): ... this, and make static.
11151 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
11152 (sh_regs_info, sh_arch_setup): New functions.
11153 (the_low_target): Adjust.
11154 (initialize_low_arch): New function.
11155 * linux-bfin-low.c (tdesc_bfin): Declare.
11156 (bfin_arch_setup): New function.
11157 (bfin_usrregs_info, regs_info): New globals.
11158 (bfin_regs_info): New function.
11159 (the_low_target): Adjust.
11160 (initialize_low_arch): New function.
11161 * linux-cris-low.c (tdesc_cris): Declare.
11162 (cris_arch_setup): New function.
11163 (cris_usrregs_info, regs_info): New globals.
11164 (cris_regs_info): New function.
11165 (the_low_target): Adjust.
11166 (initialize_low_arch): New function.
11167 * linux-cris-low.c (tdesc_crisv32): Declare.
11168 (cris_arch_setup): New function.
11169 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
11170 (cris_regs_info): New function.
11171 (the_low_target): Adjust.
11172 (initialize_low_arch): New function.
11173 * linux-m32r-low.c (tdesc_m32r): Declare.
11174 (m32r_arch_setup): New function.
11175 (m32r_usrregs_info, regs_info): New globals.
11176 (m32r_regs_info): Adjust.
11177 (initialize_low_arch): New function.
11178 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
11179 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
11180 (tic6x_usrregs_info): Forward declare.
11181 (tic6x_read_description): New function, based on ...
11182 (tic6x_arch_setup): ... this. Reimplement.
11183 (target_regsets): Rename to ...
11184 (tic6x_regsets): ... this, and make static.
11185 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
11186 (tic6x_regs_info): New function.
11187 (the_low_target): Adjust.
11188 (initialize_low_arch): New function.
11189 * linux-xtensa-low.c (tdesc_xtensa): Declare.
11190 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
11191 (target_regsets): Rename to ...
11192 (xtensa_regsets): ... this, and make static.
11193 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
11195 (xtensa_arch_setup, xtensa_regs_info): New functions.
11196 (the_low_target): Adjust.
11197 (initialize_low_arch): New function.
11198 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
11199 (nios2_arch_setup): Set the current process'es tdesc.
11200 (target_regsets): Rename to ...
11201 (nios2_regsets): ... this.
11202 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
11203 (nios2_regs_info): New function.
11204 (the_low_target): Adjust.
11205 (initialize_low_arch): New function.
11206 * linux-aarch64-low.c (tdesc_aarch64): Declare.
11207 (aarch64_arch_setup): Set the current process'es tdesc.
11208 (target_regsets): Rename to ...
11209 (aarch64_regsets): ... this.
11210 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
11211 (aarch64_regs_info): New function.
11212 (the_low_target): Adjust.
11213 (initialize_low_arch): New function.
11214 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
11216 (target_regsets): Rename to ...
11217 (tile_regsets): ... this.
11218 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
11219 (tile_regs_info): New function.
11220 (tile_arch_setup): Set the current process'es tdesc.
11221 (the_low_target): Adjust.
11222 (initialize_low_arch): New function.
11223 * spu-low.c (tdesc_spu): Declare.
11224 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
11225 * win32-arm-low.c (tdesc_arm): Declare.
11226 (arm_arch_setup): New function.
11227 (the_low_target): Install arm_arch_setup instead of
11228 init_registers_arm.
11229 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
11230 (init_windows_x86): Rename to ...
11231 (i386_arch_setup): ... this. Set `win32_tdesc'.
11232 (the_low_target): Adjust.
11233 * win32-low.c (win32_tdesc): New global.
11234 (child_add_thread): Don't create the thread cache here.
11235 (do_initial_child_stuff): Set the new process'es tdesc.
11236 * win32-low.h (struct target_desc): Forward declare.
11237 (win32_tdesc): Declare.
11238 * lynx-i386-low.c (tdesc_i386): Declare global.
11239 (lynx_i386_arch_setup): Set `lynx_tdesc'.
11240 * lynx-low.c (lynx_tdesc): New global.
11241 (lynx_add_process): Set the new process'es tdesc.
11242 * lynx-low.h (struct target_desc): Forward declare.
11243 (lynx_tdesc): Declare global.
11244 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
11245 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
11246 * nto-low.c (nto_tdesc): New global.
11247 (do_attach): Set the new process'es tdesc.
11248 * nto-low.h (struct target_desc): Forward declare.
11249 (nto_tdesc): Declare.
11250 * nto-x86-low.c (tdesc_i386): Declare.
11251 (nto_x86_arch_setup): Set `nto_tdesc'.
11253 2013-06-04 Gary Benson <gbenson@redhat.com>
11255 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
11256 to qSupported response when appropriate.
11257 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
11258 with nonzero-length annex.
11259 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
11260 arguments supplied in annex.
11262 2013-05-31 Doug Evans <dje@google.com>
11265 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
11266 64 bits in 64-cross-32 environment.
11268 2013-05-28 Pedro Alves <palves@redhat.com>
11270 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
11271 (aarch64-without-fpu.c): Delete rule.
11272 * configure.srv (aarch64*-*-linux*): Remove references to
11273 aarch64-without-fpu.o and aarch64-without-fpu.xml.
11274 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
11277 2013-05-24 Pedro Alves <palves@redhat.com>
11279 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
11280 instead of strchr/decode_address. Error if the range isn't split
11281 with a ','. Don't assume there's be a ':' in the action.
11283 2013-05-23 Yao Qi <yao@codesourcery.com>
11284 Pedro Alves <palves@redhat.com>
11286 * linux-low.c (lwp_in_step_range): New function.
11287 (linux_wait_1): If the thread was range stepping and stopped
11288 outside the stepping range, report the stop to GDB. Otherwise,
11289 continue stepping. Add range stepping debug output.
11290 (linux_set_resume_request): Copy the step range from the resume
11291 request to the lwp.
11292 (linux_supports_range_stepping): New.
11293 (linux_target_ops) <supports_range_stepping>: Set to
11294 linux_supports_range_stepping.
11295 * linux-low.h (struct linux_target_ops)
11296 <supports_range_stepping>: New field.
11297 (struct lwp_info) <step_range_start, step_range_end>: New fields.
11298 * linux-x86-low.c (x86_supports_range_stepping): New.
11299 (the_low_target) <supports_range_stepping>: Set to
11300 x86_supports_range_stepping.
11301 * server.c (handle_v_cont): Handle 'r' action.
11302 (handle_v_requests): Append ";r" if the target supports range
11304 * target.h (struct thread_resume) <step_range_start,
11305 step_range_end>: New fields.
11306 (struct target_ops) <supports_range_stepping>:
11308 (target_supports_range_stepping): New macro.
11310 2013-05-17 Joel Brobecker <brobecker@adacore.com>
11312 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
11313 confusion in comment.
11315 2013-05-17 Joel Brobecker <brobecker@adacore.com>
11317 * lynx-low.c (struct process_info_private): New type.
11318 (lynx_add_process): New function.
11319 (lynx_create_inferior, lynx_attach): Replace calls to
11320 add_process by calls to lynx_add_process.
11321 (lynx_resume): If PTID is null, then try using
11322 current_process()->private->last_wait_event_ptid.
11324 (lynx_clear_inferiors): Delete. The contents of that function
11325 has been inlined in lynx_mourn;
11326 (lynx_wait_1): Save the ptid in the process's private data.
11327 (lynx_mourn): Free the process' private data. Replace call
11328 to lynx_clear_inferiors by call to clear_inferiors.
11330 2013-05-17 Yao Qi <yao@codesourcery.com>
11332 * i386-low.c (i386_length_and_rw_bits): Move the comment to
11335 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
11337 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
11338 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
11339 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
11340 PT_TEXT_END_ADDR guards. Update comments.
11341 (linux_target_op) <read_offsets>: Conditionally define to
11342 linux_read_offsets if the target is UCLIBC and if it defines
11343 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
11345 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
11346 Andrew Jenner <andrew@codesourcery.com>
11348 * Makefile.in (SFILES): Add linux-nios2-low.c.
11349 (clean): Add action to delete nios2-linux.c.
11350 (nios2-linux.c): New rule.
11351 * configure.srv: Add nios2*-*-linux*.
11352 * linux-nios2-low.c: New.
11354 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
11356 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
11358 2013-04-25 Hui Zhu <hui@codesourcery.com>
11361 * ax.c (ax_printf): Add fflush.
11363 2013-04-22 Tom Tromey <tromey@redhat.com>
11365 * Makefile.in (SFILES): Add filestuff.c.
11366 (OBS): Add filestuff.o.
11367 (filestuff.o): New target.
11368 * config.in, configure: Rebuild.
11369 * configure.ac: Check for fdwalk, pipe2.
11371 2013-04-17 Pedro Alves <palves@redhat.com>
11373 * configure.ac (USE_THREAD_DB): Delete variable.
11374 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
11375 Don't AC_SUBST USE_THREAD_DB.
11376 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
11377 * config.in, configure: Regenerate.
11379 2013-04-16 Pedro Alves <palves@redhat.com>
11381 * linux-low.h (struct lwp_info) <thread_known>: Move under
11382 the USE_THREAD_DB #ifdef.
11384 2013-04-16 Pedro Alves <palves@redhat.com>
11386 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
11387 (linux-low.o): Delete rule.
11388 * linux-low.h: Always include "gdb_thread_db.h" instead of
11389 conditionally including thread_db.h.
11390 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
11393 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
11395 * Makefile.in (install-only): Fix make install regression.
11397 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
11399 Convert man pages to texinfo, new gdbinit.5 texinfo page.
11400 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
11402 * gdbserver.1: Remove.
11404 2013-03-22 Pedro Alves <palves@redhat.com>
11406 * linux-low.c (handle_extended_wait): Don't call
11407 linux_enable_event_reporting.
11409 2013-03-15 Tony Theodore <tonyt@logyst.com>
11412 * Makefile.in (SHELL): Use @SHELL@.
11414 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
11416 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
11419 2013-03-13 Joel Brobecker <brobecker@adacore.com>
11421 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
11422 Remove extraneous NULL element.
11424 2013-03-13 Yao Qi <yao@codesourcery.com>
11426 * tracepoint.c (traceframe_read_tsv): Look for the last matched
11427 'V' block in trace frame.
11429 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
11431 * target.h (struct target_ops): Add btrace ops.
11432 (target_supports_btrace): New macro.
11433 (target_enable_btrace): New macro.
11434 (target_disable_btrace): New macro.
11435 (target_read_btrace): New macro.
11436 * gdbthread.h (struct thread_info): Add btrace field.
11437 * server.c: Include btrace-common.h.
11438 (handle_btrace_general_set): New function.
11439 (handle_btrace_enable): New function.
11440 (handle_btrace_disable): New function.
11441 (handle_general_set): Call handle_btrace_general_set.
11442 (handle_qxfer_btrace): New function.
11443 (struct qxfer qxfer_packets[]): Add btrace entry.
11444 * inferiors.c (remove_thread): Disable btrace.
11445 * linux-low: Include linux-btrace.h.
11446 (linux_low_enable_btrace): New function.
11447 (linux_low_read_btrace): New function.
11448 (linux_target_ops): Add btrace ops.
11449 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
11450 Add srv_linux_btrace=yes.
11451 (x86_64-*-linux*): Add linux-btrace.o.
11452 Add srv_linux_btrace=yes.
11453 * configure.ac: Define HAVE_LINUX_BTRACE.
11454 * config.in: Regenerated.
11455 * configure: Regenerated.
11457 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
11459 * server.c (handle_qxfer): Preserve error message if -3 is
11461 (qxfer): Document the -3 return value.
11463 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
11465 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
11466 (linux_btrace_h): New variable.
11467 (linux-btrace.o): New rule.
11469 2013-03-08 Stan Shebs <stan@codesourcery.com>
11470 Hafiz Abid Qadeer <abidh@codesourcery.com>
11472 * tracepoint.c (trace_buffer_size): New global.
11473 (DEFAULT_TRACE_BUFFER_SIZE): New define.
11474 (init_trace_buffer): Change to one-argument function. Allocate
11475 trace buffer memory.
11476 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
11477 handle QTBuffer:size packet.
11478 (cmd_bigqtbuffer_size): New function.
11479 (initialize_tracepoint): Call init_trace_buffer with
11480 DEFAULT_TRACE_BUFFER_SIZE.
11481 * server.c (handle_query): Add QTBuffer:size in the
11484 2013-03-07 Yao Qi <yao@codesourcery.com>
11486 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
11487 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
11489 (cmd_qtsp): Adjust condition. Do post increment.
11490 Set cur_action and cur_step_action back to 0.
11492 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
11495 * linux-low.c (linux_write_memory): Return early success if LEN is
11498 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
11500 * configure.srv: Add x86_64-*-cygwin* as target.
11502 2013-02-28 Tom Tromey <tromey@redhat.com>
11504 * configure.ac: Invoke AC_SYS_LARGEFILE.
11505 * configure, config.in: Rebuild.
11507 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
11509 * win32-low.c: Throughout, fix format strings and casts of
11510 printf-like functions to avoid type related warnings on all
11512 (get_child_debug_event): Print dwDebugEventCode as hex since
11513 that's how it's usually documented.
11515 2013-02-28 Yao Qi <yao@codesourcery.com>
11517 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
11520 2013-02-27 Jiong Wang <jiwang@tilera.com>
11522 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
11523 (reg-tilegx32.c): New rule.
11524 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
11525 * linux-tile-low.c (tile_arch_setup): New function. Invoke
11526 different register info initializer according to elf class.
11527 (init_registers_tilgx32): New function. The tilegx32 register info
11529 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
11530 (tile_store_gregset): Likewise.
11532 2013-02-27 Yao Qi <yao@codesourcery.com>
11534 * server.c (process_point_options): Print debug message when
11535 debug_threads is true.
11537 2013-02-26 Yao Qi <yao@codesourcery.com>
11539 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
11541 2013-02-19 Pedro Alves <palves@redhat.com>
11542 Kai Tietz <ktietz@redhat.com>
11546 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
11547 instead of strtoul to extract address from packet.
11548 (process_serial_event) <'z'>: Likewise.
11550 2013-02-18 Yao Qi <yao@codesourcery.com>
11552 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
11554 2013-02-14 Pedro Alves <palves@redhat.com>
11558 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
11559 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
11561 2013-02-14 Pedro Alves <palves@redhat.com>
11563 * tracepoint.c (cmd_qtdpsrc): Use savestring.
11565 2013-02-14 Pedro Alves <palves@redhat.com>
11567 * tracepoint.c (save_string): Delete.
11568 (add_tracepoint_action): Use savestring instead of save_string.
11570 2013-02-12 Pedro Alves <palves@redhat.com>
11572 * linux-xtensa-low.c: Ditto.
11573 * xtensa-xtregs.c: Ditto.
11575 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
11577 * thread-db.c (thread_db_get_tls_address): NULL pointer check
11580 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
11582 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
11583 aarch64_num_wp_regs and aarch64_num_bp_regs to
11584 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
11586 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
11588 * linux-aarch64-low.c (ps_get_thread_area): Replace
11589 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
11591 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
11592 Marcus Shawcroft <marcus.shawcroft@arm.com>
11593 Nigel Stephens <nigel.stephens@arm.com>
11594 Yufeng Zhang <yufeng.zhang@arm.com>
11596 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
11597 (aarch64.c, aarch64-without-fpu.c): New targets.
11598 * configure.srv (aarch64*-*-linux*): New.
11599 * linux-aarch64-low.c: New file.
11601 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
11603 * linux-low.c (handle_extended_wait, linux_create_inferior)
11604 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
11605 (dequeue_one_deferred_signal, linux_resume_one_thread)
11606 (fetch_register, linux_write_memory, linux_enable_event_reporting)
11607 (linux_tracefork_grandchild, linux_test_for_tracefork)
11608 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
11609 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
11610 where the argument is 0.
11612 2013-01-25 Yao Qi <yao@codesourcery.com>
11614 * event-loop.c: Include "queue.h".
11615 (gdb_event_p): New typedef.
11616 (struct gdb_event) <next_event>: Remove.
11617 (event_queue): Change to QUEUE(gdb_event_p).
11618 (async_queue_event): Remove.
11619 (gdb_event_xfree): New.
11620 (initialize_event_loop): New.
11621 (process_event): Use API from QUEUE.
11622 (wait_for_event): Likewise.
11623 * server.c (main): Call initialize_event_loop.
11624 * server.h (initialize_event_loop): Declare.
11626 2013-01-18 Yao Qi <yao@codesourcery.com>
11628 * ax.h (struct eval_agent_expr_context): New.
11629 (gdb_eval_agent_expr): Update declaration.
11630 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
11631 TFRAME. Add new argument CTX.
11632 * server.h (struct eval_agent_expr_context): Declare.
11633 (agent_mem_read, agent_tsv_read): Update declaration.
11634 (agent_mem_read_string): Likewise.
11635 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
11636 (add_traceframe_block): Add new argument TPOINT.
11637 Increase TPOINT->traceframe_usage.
11638 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
11639 eval_tracepoint_agent_expr.
11640 (condition_true_at_tracepoint): Likewise.
11641 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
11642 (agent_mem_read_string, agent_tsv_read): Likewise.
11644 2013-01-16 Yao Qi <yao@codesourcery.com>
11646 * linux-low.c (linux_resume_one_lwp): Don't check
11647 'lwp->bp_reinsert != 0'.
11649 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11650 Pedro Alves <palves@redhat.com>
11652 * lynx-low.c (ptrace_request_to_str): Define a temporary
11653 macro and use it to simplify this function's implementation.
11655 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11657 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
11660 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11662 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
11664 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11666 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
11668 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11670 * lynx-low.c (lynx_resume): Use the resume_info parameter
11671 to determine the ptid for the lynx_ptrace call, unless
11672 it is equal to minus_one_ptid, in which case we use the
11673 ptid of the current_inferior.
11674 (lynx_wait_1): After having received a thread create/exit
11675 event, resume the inferior's execution using the signaling
11676 thread's ptid, rather than the old ptid.
11678 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11680 * lynx-low.c (lynx_resume): Delete variable ret.
11682 2013-01-01 Joel Brobecker <brobecker@adacore.com>
11684 * gdbreplay.c (gdbreplay_version): Update copyright year.
11685 * server.c (gdbserver_version): Likewise.
11687 2012-12-17 Joel Brobecker <brobecker@adacore.com>
11689 * lynx-low.c (lynx_wait_1): Add debug trace before adding
11692 2012-12-17 Joel Brobecker <brobecker@adacore.com>
11694 * lynx-low.c (ptrace_request_to_str): Add handling for
11695 PTRACE_GETTRACESIG.
11697 2012-12-17 Joel Brobecker <brobecker@adacore.com>
11699 * lynx-low.c (lynx_attach): Delete variable new_process.
11701 2012-12-17 Joel Brobecker <brobecker@adacore.com>
11703 * lynx-low.c (lynx_create_inferior): Delete variable
11706 2012-12-17 Joel Brobecker <brobecker@adacore.com>
11708 * lynx-low.c (ptrace_request_to_str): Do not handle
11709 PTRACE_GETTHREADLIST if this macro does not exist.
11711 2012-12-15 Yao Qi <yao@codesourcery.com>
11713 * Makefile.in (OBS): Add notif.o.
11714 * notif.c, notif.h: New.
11715 * server.c: Include "notif.h".
11716 (struct vstop_notif) <next>: Remove.
11718 (queue_stop_reply): Update.
11719 (push_event, send_next_stop_reply): Remove.
11720 (discard_queued_stop_replies): Update.
11721 (notif_stop): New variable.
11722 (handle_v_stopped): Remove.
11723 (handle_v_requests): Don't call handle_v_stopped. Call
11724 handle_ack_notif instead.
11725 (queue_stop_reply_callback): Call notif_event_enque instead
11726 of queue_stop_reply.
11727 (handle_status): Don't call send_next_stop_reply, call
11728 notif_write_event instead.
11729 (kill_inferior_callback): Likewise.
11730 (detach_or_kill_inferior_callback): Likewise.
11731 (main): Call initialize_notif.
11732 (process_serial_event): Call QUEUE_is_empty.
11733 (handle_target_event): Call notif_push instead of push event.
11734 * server.h (push_event): Remove declaration.
11736 2012-12-10 Tom Tromey <tromey@redhat.com>
11738 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
11739 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
11742 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
11743 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
11744 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
11745 (amd64-linux-ipa.o, ax.o): Rewrite.
11746 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
11747 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
11748 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
11749 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
11750 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
11751 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
11752 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
11753 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
11754 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
11755 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
11756 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
11757 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
11758 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
11759 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
11760 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
11761 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
11762 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
11763 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
11764 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
11765 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
11766 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
11767 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
11768 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
11769 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
11770 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
11771 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
11772 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
11773 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
11774 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
11775 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
11776 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
11777 (reg-tilegx.o): Remove.
11778 (all_object_files): New macro.
11779 Include .deps files.
11780 * aclocal.m4, configure: Rebuild.
11781 * acinclude.m4: Include depstand.m4, lead-dot.m4.
11782 * configure.ac: Invoke ZW_CREATE_DEPDIR,
11783 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
11785 2012-12-05 Tom Tromey <tromey@redhat.com>
11788 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
11790 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
11792 * configure.ac: Check for linux/perf_event.h.
11793 * config.in: Regenerated.
11794 * configure: Regenerated.
11796 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
11798 * hostio.c (handle_readlink): Decrease buffer size
11799 parameter passed to readlink by one byte.
11801 2012-11-26 Yao Qi <yao@codesourcery.com>
11803 * configure.ac (build_warnings): Append '-Wempty-body'.
11804 * configure: Regenerated.
11805 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
11808 2012-11-15 Pierre Muller <muller@sourceware.org>
11810 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
11811 * config.in: Regenerate.
11812 * configure: Regenerate.
11813 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
11814 Use "gdb_wait.h" header instead of <sys/wait.h> header.
11815 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
11816 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
11818 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
11819 instead of <sys/wait.h> header.
11820 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
11822 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
11824 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
11825 (various make rules): Remove -DGDBSERVER
11827 2012-11-09 Yao Qi <yao@codesourcery.com>
11829 * spu-low.c (current_ptid): Move it to ..
11830 * gdbthread.h: ... here. New.
11831 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
11832 * server.c (myresume, process_serial_event): Likewise.
11833 * thread-db.c (thread_db_find_new_threads): Likewise.
11834 * tracepoint.c (run_inferior_command): Likewise.
11836 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
11838 * server.c (handle_search_memory_1): Include access length in
11841 2012-09-05 Michael Brandt <michael.brandt@axis.com>
11843 * linux-crisv32-low.c: Fix compile errors.
11845 2012-09-04 Yao Qi <yao@codesourcery.com>
11847 * tracepoint.c (cmd_qtsv): Adjust debug message.
11848 Don't check CUR_TPOINT.
11850 2012-08-28 Yao Qi <yao@codesourcery.com>
11852 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
11853 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
11854 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
11855 Remove declarations of xmalloc, xreallloc, xstrdup and
11857 * Makefile.in (libiberty_h): New.
11858 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
11859 (linux-bfin-low.o): Append dependency 'libiberty.h'.
11861 2012-08-23 Yao Qi <yao@codesourcery.com>
11863 * server.h: Remove declaration of 'xsnprintf'.
11865 2012-08-22 Keith Seitz <keiths@redhat.com>
11867 * server.h: Include build-gnulib-gbserver/config.h.
11868 * gdbreplay.c: Likewise.
11870 2012-08-08 Doug Evans <dje@google.com>
11872 * Makefile.in (SFILES): Add gdb_vecs.c.
11873 (OBS): Add gdb_vecs.o.
11874 (gdb_vecs_h, host_defs_h): New variables.
11875 (thread-db.o): Add $(gdb_vecs_h) dependency.
11876 (gdb_vecs.o): New rule.
11877 * thread-db.c: #include "gdb_vecs.h".
11878 (thread_db_load_search): Use a vector to iterate over path elements.
11879 Handle text appearing after "$pdir".
11881 * configure.ac: Add check for strstr.
11882 * config.in: Regenerate.
11883 * configure: Regenerate.
11885 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
11887 * hostio.c (handle_pread): If pread fails, fall back to attempting
11889 (handle_pwrite): Likewise for pwrite.
11891 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
11893 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
11894 between unsupported TYPE and unimplementable ADDR/LEN combination.
11895 (arm_insert_point): Act on new return value.
11897 2012-07-31 Pedro Alves <palves@redhat.com>
11899 * server.c (process_point_options): Only skip tokens if we find
11900 one that is unrecognized. Don't treat 'X' specially while
11901 skipping unrecognized tokens.
11903 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
11905 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
11906 to 4-byte-align HW breakpoint addresses for Thumb.
11908 2012-07-27 Yao Qi <yao@codesourcery.com>
11912 * server.h: Declare gdb_agent_about_to_close.
11913 * target.c (kill_inferior): Include "agent.h".
11914 New. Send command 'kill'.
11915 * target.h (kill_inferior): Removed macro.
11916 * tracepoint.c (gdb_agent_about_to_close): New.
11917 (gdb_agent_helper_thread): Handle command 'close'.
11918 Wait endlessly until the inferior stops.
11919 Install gdb_agent_remove_socket to atexit hook.
11920 (agent_socket_name): New static variable.
11921 (gdb_agent_socket_init): Replace local variable 'name' with
11922 'agent_socket_name'.
11923 (gdb_agent_remove_socket): New.
11925 2012-07-27 Yao Qi <yao@codesourcery.com>
11927 * server.c (process_point_options): Stop at 'X' when parsing.
11929 2012-07-19 Michael Eager <eager@eagercon.com>
11931 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
11933 * linux-x86-low.c (x86_insert_point, x86_remove_point):
11934 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
11935 hardware breakpoint.
11937 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
11939 * gdbserver/linux-low.c (initialize_low): Call
11940 linux_ptrace_init_warnings.
11942 2012-07-02 Doug Evans <dje@google.com>
11944 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
11947 2012-07-02 Stan Shebs <stan@codesourcery.com>
11949 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
11950 (ax.o): Add it to build rule.
11952 (OBS): Add format.o.
11953 (IPA_OBS): Add format.o.
11954 * server.c (handle_query): Claim support for breakpoint commands.
11955 (process_point_options): Add command case.
11956 (process_serial_event): Leave running if there are printfs in
11958 * mem-break.h (any_persistent_commands): Declare.
11959 (add_breakpoint_commands): Declare.
11960 (gdb_no_commands_at_breakpoint): Declare.
11961 (run_breakpoint_commands): Declare.
11962 * mem-break.c (struct point_command_list): New struct.
11963 (struct breakpoint): New field command_list.
11964 (any_persistent_commands): New function.
11965 (add_commands_to_breakpoint): New function.
11966 (add_breakpoint_commands): New function.
11967 (gdb_no_commands_at_breakpoint): New function.
11968 (run_breakpoint_commands): New function.
11969 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
11971 * ax.c: Include format.h.
11972 (ax_printf): New function.
11973 (gdb_eval_agent_expr): Add printf opcode.
11975 2012-06-13 Yao Qi <yao@codesourcery.com>
11977 * server.c (start_inferior): Remove duplicated writes to fields
11978 'last_resume_kind' and 'last_status' of 'current_inferior'.
11980 2012-06-12 Yao Qi <yao@codesourcery.com>
11981 Pedro Alves <palves@redhat.com>
11983 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
11985 * server.c (handle_v_cont): Extend comment.
11987 2012-06-11 Yao Qi <yao@codesourcery.com>
11989 * linux-low.c (linux_attach): Add 'static'.
11991 2012-06-06 Yao Qi <yao@codesourcery.com>
11993 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
11995 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
11997 Fix gcc -flto compilation warning.
11998 * server.c (main): Make variable multi_mode and attach volatile.
12000 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
12002 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
12003 if the platform doesn't know about it.
12005 2012-05-30 Jeff Kenton <jkenton@tilera.com>
12007 * Makefile.in (SFILES): Add linux-tile-low.c.
12008 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
12009 * configure.srv: Handle tilegx-*-linux*.
12010 * linux-tile-low.c: New file.
12012 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12014 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
12016 2012-05-24 Pedro Alves <palves@redhat.com>
12020 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
12022 2012-05-24 Pedro Alves <palves@redhat.com>
12026 Replace target_signal with gdb_signal throughout.
12028 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
12030 * linux-low.c (linux_store_registers): Avoid the copying sequence
12031 when no data has been retrieved by ptrace.
12033 2012-05-22 Will Deacon <will.deacon@arm.com>
12035 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
12036 Include asm/ptrace.h.
12037 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
12040 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
12042 * linux-low.c (linux_store_registers): Don't re-retrieve data
12043 with ptrace that has already been obtained from /proc. Always
12044 copy any data retrieved with ptrace to the buffer supplied.
12046 2012-05-11 Yao Qi <yao@codesourcery.com>
12047 Pedro Alves <palves@redhat.com>
12049 * linux-low.c (enum stopping_threads_kind): New.
12050 (stopping_threads): Change type to `enum stopping_threads_kind'.
12051 (handle_extended_wait): If stopping and suspending threads, leave
12052 the new_lwp suspended too.
12053 (linux_wait_for_event): Adjust.
12054 (stop_all_lwps): Set `stopping_threads' to
12055 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
12056 whether we're suspending threads or just stopping them. Assert no
12059 2012-04-29 Yao Qi <yao@codesourcery.com>
12061 * server.h: Move some code to ...
12062 * gdbthread.h: ... here. New.
12063 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
12064 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
12065 (nto-low.o, win32-low.o): Likewise.
12066 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
12067 * regcache.c, remote-utils.c, server.c: Likewise.
12068 * target.c, tracepoint.c, win32-low.c: Likewise.
12070 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
12072 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
12073 (PTRACE_ARG4_TYPE): Likewise.
12074 (PTRACE_XFER_TYPE): Likewise.
12075 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
12076 ptrace to PTRACE_ARG3_TYPE.
12077 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
12078 (PTRACE_ARG4_TYPE): Likewise.
12079 (PTRACE_XFER_TYPE): Likewise.
12080 (linux_detach_one_lwp): Cast fourth argument of
12081 ptrace to long then PTRACE_ARG4_TYPE.
12082 (regsets_fetch_inferior_registers): Cast third argument of
12083 ptrace to long then PTRACE_ARG3_TYPE.
12084 (regsets_store_inferior_registers): Likewise.
12086 2012-04-20 Pedro Alves <palves@redhat.com>
12088 * configure: Regenerate.
12090 2012-04-19 Pedro Alves <palves@redhat.com>
12092 * Makefile.in (GNULIB_BUILDDIR): New.
12093 (LIBGNU, INCGNU, GNULIB_H): Adjust.
12094 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
12095 (all, install-only, uninstall, clean-info, all-lib, clean): No
12096 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
12097 (maintainer-clean realclean distclean): Use subdir_do.
12099 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
12100 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
12101 * acinclude.m4: Include acx_configure_dir.m4.
12102 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
12103 calls. Call AC_PROG_RANLIB. Configure gnulib using
12106 (GNULIB_STDINT_H): Adjust.
12107 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
12108 * gdbreplay.c: Include build-gnulib/config.h.
12109 * server.h: Likewise.
12110 * aclocal.m4: Regenerate.
12111 * config.in: Regenerate.
12112 * configure: Regenerate.
12114 2012-04-19 Pedro Alves <palves@redhat.com>
12116 * Makefile.in (LIBGNU, INCGNU): Adjust.
12117 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
12118 (all, install-only, uninstall, clean-info, all-lib, clean)
12119 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
12120 * configure.ac: Adjust AC_OUTPUT output.
12121 * aclocal.m4: Regenerate.
12122 * configure: Regenerate.
12124 2012-04-19 Pedro Alves <palves@redhat.com>
12126 * Makefile.in (generated_files): New.
12127 (server_h): Remove the explicit dependency on config.h, and depend
12128 on $generated_files.
12130 2012-04-19 Pedro Alves <palves@redhat.com>
12132 * Makefile.in (INCGNU): Add -Ignulib.
12134 2012-04-19 Pedro Alves <palves@redhat.com>
12136 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
12137 (INCGNU): ... this, and spell out -I here.
12138 (GNULIB_LIB): Rename to ...
12139 (LIBGNU): ... this.
12140 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
12142 2012-04-19 Pedro Alves <palves@redhat.com>
12144 * config.in: Regenerate.
12146 2012-04-19 Pedro Alves <palves@redhat.com>
12148 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
12149 * server.h (memmem): Remove declaration.
12150 * config.in: Regenerate.
12151 * configure: Regenerate.
12153 2012-04-19 Yao Qi <yao@codesourcery.com>
12155 * Makefile.in (SFILES): Add common/vec.c.
12159 2012-04-19 Yao Qi <yao@codesourcery.com>
12161 * remote-utils.c (prepare_resume_reply): Replace with macro
12162 target_core_of_thread.
12163 * server.c (handle_qxfer_threads_proper): Likewise.
12164 * target.h (traget_core_of_thread): New macro.
12166 2012-04-18 Pedro Alves <palves@redhat.com>
12168 * aclocal.m4: Regenerate.
12169 * configure: Regenerate.
12171 2012-04-16 Yao Qi <yao@codesourcery.com>
12173 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
12174 duplicated on address.
12176 2012-04-16 Yao Qi <yao@codesourcery.com>
12178 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
12179 (struct tracepoint_action_ops) <send>: New field.
12180 (m_tracepoint_action_send, r_tracepoint_action_send): New.
12181 (agent_expr_send, x_tracepoint_action_send): New.
12182 (l_tracepoint_action_send): New.
12183 (cmd_qtdp): Download and install tracepoint
12184 according to `use_agent'.
12185 (run_inferior_command): Add one more parameter `len'.
12187 (tracepoint_send_agent): New.
12188 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
12190 2012-04-16 Yao Qi <yao@codesourcery.com>
12192 * tracepoint.c (download_tracepoints): Moved to ...
12193 (cmd_qtstart): ... here.
12195 2012-04-14 Yao Qi <yao@codesourcery.com>
12197 * tracepoint.c: Include inttypes.h.
12198 (struct collect_memory_action): Use sized types.
12199 (struct tracepoint): Likewise.
12200 (cmd_qtdp, stop_tracing): Update print specifiers.
12201 (cmd_qtp, response_tracepoint): Likewise.
12202 (collect_data_at_tracepoint): Likewise.
12203 (collect_data_at_step): Likewise.
12205 2012-04-14 Yao Qi <yao@codesourcery.com>
12207 Import gnulib module inttypes.
12208 * aclocal.m4, config.in, configure: Regenerated.
12210 2012-04-14 Yao Qi <yao@codesourcery.com>
12212 * Makefile.in (maintainer-clean, realclean, distclean): Remove
12213 Makefile and config.status at last.
12215 2012-04-13 Yao Qi <yao@codesourcery.com>
12217 * tracepoint.c: Include stdint.h unconditionally.
12219 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
12221 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
12222 on BFD_HAVE_SYS_PROCFS_TYPE.
12223 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
12224 * configure: Regenerate.
12225 * config.in: Likewise.
12227 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
12229 * Makefile.in (clean): Also remove x32.c x32-linux.c
12230 x32-avx.c x32-avx-linux.c.
12231 (x32.o): New target.
12233 (x32-linux.o): Likewise.
12234 (x32-linux.c): Likewise.
12235 (x32-avx.o): Likewise.
12236 (x32-avx.c): Likewise.
12237 (x32-avx-linux.o): Likewise.
12238 (x32-avx-linux.c): Likewise.
12240 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
12241 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
12242 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
12243 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
12244 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
12245 i386/x32-avx-linux.xml.
12247 * linux-x86-low.c (init_registers_x32_linux): New prototype.
12248 (init_registers_x32_avx_linux): Likwise.
12249 (x86_linux_update_xmltarget): Call init_registers_x32_linux
12250 or init_registers_x32_avx_linux if linux_is_elf64 is false.
12252 2012-04-13 Pedro Alves <palves@redhat.com>
12254 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
12255 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
12256 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
12257 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
12260 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
12262 * linux-x86-low.c (compat_x32_clock_t): New.
12263 (compat_x32_siginfo_t): Likewise.
12264 (compat_x32_siginfo_from_siginfo): Likewise.
12265 (siginfo_from_compat_x32_siginfo): Likewise.
12266 (linux_is_elf64): Likewise.
12267 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
12268 and siginfo_from_compat_x32_siginfo for x32.
12269 (x86_arch_setup): Set linux_is_elf64.
12271 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
12274 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
12276 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
12277 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
12278 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
12279 compatible with process.
12281 2012-04-12 Yao Qi <yao@codesourcery.com>
12283 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
12284 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
12285 (install-only, install-info, clean): Handle sub dir gnulib.
12286 (all-lib, am--refresh): New targets.
12287 (memmem.o): Remove target.
12288 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
12289 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
12290 (AC_REPLACE_FUNCS): Remove memmem.
12291 Invoke gl_INIT and AM_INIT_AUTOMAKE.
12292 (AC_OUTPUT): Generate Makefile in gnulib/.
12293 * aclocal.m4, config.in, configure: Regenerated.
12295 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
12297 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
12299 2012-04-05 Pedro Alves <palves@redhat.com>
12301 -Werror=strict-aliasing
12303 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
12306 2012-04-04 Pedro Alves <palves@redhat.com>
12308 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
12309 (sparc_store_gregset_from_stack, sparc_store_gregset)
12310 (sparc_breakpoint_at): Fix formatting.
12312 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
12314 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
12316 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
12317 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
12318 * config.in: Regenerate.
12319 * configure: Likewise.
12321 2012-03-29 Pedro Alves <palves@redhat.com>
12323 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
12324 Correct ptrace arguments.
12326 2012-03-28 Pedro Alves <palves@redhat.com>
12328 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
12329 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
12330 (IA64_FR1_REGNUM): New defines.
12331 (ia64_fetch_register): New.
12332 (the_low_target): Install it.
12333 * linux-low.h (struct linux_target_ops) <fetch_register>: New
12335 * linux-low.c (linux_fetch_registers): Try the
12336 the_low_target.fetch_register hook first.
12338 * linux-arm-low.c (the_low_target): Adjust.
12339 * linux-bfin-low.c (the_low_target): Adjust.
12340 * linux-cris-low.c (the_low_target): Adjust.
12341 * linux-crisv32-low.c (the_low_target): Adjust.
12342 * linux-m32r-low.c (the_low_target): Adjust.
12343 * linux-m68k-low.c (the_low_target): Adjust.
12344 * linux-mips-low.c (the_low_target): Adjust.
12345 * linux-ppc-low.c (the_low_target): Adjust.
12346 * linux-s390-low.c (the_low_target): Adjust.
12347 * linux-sh-low.c (the_low_target): Adjust.
12348 * linux-sparc-low.c (the_low_target): Adjust.
12349 * linux-tic6x-low.c (the_low_target): Adjust.
12350 * linux-x86-low.c (the_low_target): Adjust.
12351 * linux-xtensa-low.c (the_low_target): Adjust.
12353 2012-03-26 Pedro Alves <palves@redhat.com>
12355 * server.c (handle_qxfer_libraries): Don't bail early if
12356 the_target->qxfer_libraries_svr4 is not NULL.
12358 2012-03-26 Pedro Alves <palves@redhat.com>
12360 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
12362 2012-03-23 Pedro Alves <palves@redhat.com>
12364 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
12365 "library-list-svr4" element's start tag when the the DSO list is
12368 2012-03-23 Pedro Alves <palves@redhat.com>
12370 * linux-low.c (read_one_ptr): Read the inferior's pointer through
12371 a variable whose type size is the same as the inferior's pointer
12374 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
12376 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
12378 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
12379 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
12380 * linux-low.h: Include <signal.h>.
12381 (struct siginfo): Remove forward declaration.
12382 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
12385 2012-03-21 Mike Frysinger <vapier@gentoo.org>
12387 * .gitignore: Ignore more files.
12389 2012-03-19 Pedro Alves <palves@redhat.com>
12390 Jan Kratochvil <jan.kratochvil@redhat.com>
12392 * server.c (cont_thread, general_thread): Add describing comments.
12393 (start_inferior): Clear `cont_thread'.
12394 (handle_v_cont): Don't set `cont_thread' if resuming all threads
12397 2012-03-15 Yao Qi <yao@codesourcery.com>
12399 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
12401 (cmd_qtdp): ... here.
12403 2012-03-15 Yao Qi <yao@codesourcery.com>
12405 * tracepoint.c (struct tracepoint_action_ops): New.
12406 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
12407 (m_tracepoint_action_download): New.
12408 (r_tracepoint_action_download): New.
12409 (x_tracepoint_action_download): New.
12410 (l_tracepoint_action_download): New.
12411 (add_tracepoint_action): Install `action->ops' according type.
12412 (download_tracepoint_1): Move code `download' function pointer
12413 of various tracepoint_action_ops.
12415 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
12417 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
12418 linux_ptrace_attach_warnings.
12420 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
12422 * Makefile.in (linux-ptrace.o): New.
12423 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
12424 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
12425 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
12426 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
12427 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
12429 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
12431 2012-03-08 Yao Qi <yao@codesourcery.com>
12432 Pedro Alves <palves@redhat.com>
12434 Fix PR server/13392.
12435 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
12436 offset of JMP insn.
12437 * tracepoint.c (remove_tracepoint): New.
12438 (cmd_qtdp): Call remove_tracepoint when failed to install.
12440 2012-03-07 Pedro Alves <palves@redhat.com>
12442 * linux-low.c (get_detach_signal): New.
12443 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
12444 Pass on pending signals to PTRACE_DETACH. Check the result of the
12446 * server.c (program_signals, program_signals_p): New.
12447 (handle_general_set): Handle QProgramSignals.
12448 * server.h (program_signals, program_signals_p): Declare.
12450 2012-03-05 Pedro Alves <palves@redhat.com>
12451 Jan Kratochvil <jan.kratochvil@redhat.com>
12453 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
12456 2012-03-03 Yao Qi <yao@codesourcery.com>
12458 * tracepoint.c (tracepoint_look_up_symbols): Update call to
12459 agent_look_up_symbols.
12461 2012-03-03 Yao Qi <yao@codesourcery.com>
12463 * Makefile.in (linux-low.o): Keep dependence on agent.h.
12464 (linux-x86-low.o): Likewise.
12465 * server.h: Remove in_process_agent_loaded.
12466 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
12470 2012-03-03 Yao Qi <yao@codesourcery.com>
12472 * tracepoint.c (gdb_agent_capability): New global.
12473 (in_process_agent_loaded_ust): Renamed to
12474 `in_process_agent_supports_ust'.
12476 (in_process_agent_supports_ust): Call agent_capability_check.
12477 (clear_installed_tracepoints): Assert that agent supports
12480 2012-03-03 Yao Qi <yao@codesourcery.com>
12482 * linux-low.c (linux_supports_agent): New.
12483 (linux_target_ops): Initialize field `supports_agent' with
12484 linux_supports_agent.
12485 * target.h (struct target_ops) <supports_agent>: New.
12486 (target_supports_agent): New macro.
12487 * server.c (handle_general_set): Handle packet 'QAgent'.
12488 (handle_query): Send `QAgent+'.
12489 * Makefile.in (server.o): Depends on agent.h.
12491 2012-03-03 Yao Qi <yao@codesourcery.com>
12493 * Makefile.in (OBS): Add agent.o.
12494 Add new rule for agent.o.
12495 Track dependence of tracepoint.c on agent.h.
12496 * tracepoint.c (run_inferior_command_1):
12497 (run_inferior_command): Call agent_run_command.
12498 (gdb_ust_connect_sync_socket): Deleted. Move it to
12500 (resume_thread, stop_thread): Likewise.
12501 (gdb_ust_socket_init): Renamed to ...
12502 (gdb_agent_socket_init): ... New.
12503 (gdb_ust_thread): Renamed to ...
12504 (gdb_agent_helper_thread): ... New.
12505 (gdb_ust_init): Move some code to ...
12506 (gdb_agent_init): ... here. New.
12507 [HAVE_UST]: Call gdb_ust_init.
12508 (initialize_tracepoint_ftlib): Call gdb_agent_init.
12509 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
12510 * config.in, configure: Regenerated.
12512 2012-03-02 Pedro Alves <palves@redhat.com>
12514 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
12515 * linux-low.c (struct simple_pid_list): New.
12516 (stopped_pids): New a struct simple_pid_list pointer.
12517 (add_to_pid_list, pull_pid_from_list): New.
12518 (handle_extended_wait): Don't assume the first signal new children
12519 report is SIGSTOP. Adjust call to pull_pid_from_list.
12520 (linux_wait_for_lwp): Adjust.
12522 2012-03-02 Yao Qi <yao@codesourcery.com>
12524 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
12527 2012-03-02 Yao Qi <yao@codesourcery.com>
12529 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
12530 `stop_pc' and `tpoint'. Update caller.
12532 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
12534 * linux-low.h (linux_target_ops): Add regset_bitmap member.
12535 * linux-low.c (use_linux_regsets): New macro.
12536 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
12537 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
12538 (linux_register_in_regsets): New function.
12539 (usr_fetch_inferior_registers): Skip registers covered by
12541 (usr_store_inferior_registers): Likewise.
12542 (usr_fetch_inferior_registers): New macro.
12543 (usr_store_inferior_registers): Likewise.
12544 (linux_fetch_registers): Handle mixed regset/non-regset targets.
12545 (linux_store_registers): Likewise.
12546 * linux-mips-low.c (init_registers_mips_dsp_linux): New
12548 (init_registers_mips64_dsp_linux): Likewise.
12549 (init_registers_mips_linux): New macro.
12550 (init_registers_mips_dsp_linux): Likewise.
12551 (mips_dsp_num_regs): Likewise.
12552 (DSP_BASE, DSP_CONTROL): New fallback macros.
12553 (mips_base_regs): New macro.
12554 (mips_regmap): Use it. Fix the size.
12555 (mips_dsp_regmap): New variable.
12556 (mips_dsp_regset_bitmap): Likewise.
12557 (mips_arch_setup): New function.
12558 (mips_cannot_fetch_register): Use the_low_target.regmap rather
12560 (mips_cannot_store_register): Likewise.
12561 (the_low_target): Update .arch_setup, .num_regs and .regmap
12562 initializers. Add .regset_bitmap initializer.
12563 * linux-arm-low.c (the_low_target): Add .regset_bitmap
12565 * linux-bfin-low.c (the_low_target): Likewise.
12566 * linux-cris-low.c (the_low_target): Likewise.
12567 * linux-crisv32-low.c (the_low_target): Likewise.
12568 * linux-ia64-low.c (the_low_target): Likewise.
12569 * linux-m32r-low.c (the_low_target): Likewise.
12570 * linux-m68k-low.c (the_low_target): Likewise.
12571 * linux-ppc-low.c (the_low_target): Likewise.
12572 * linux-s390-low.c (the_low_target): Likewise.
12573 * linux-sh-low.c (the_low_target): Likewise.
12574 * linux-sparc-low.c (the_low_target): Likewise.
12575 * linux-tic6x-low.c (the_low_target): Likewise.
12576 * linux-x86-low.c (the_low_target): Likewise.
12577 * linux-xtensa-low.c (the_low_target): Likewise.
12578 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
12579 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
12580 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
12582 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
12583 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
12585 2012-02-29 Yao Qi <yao@codesourcery.com>
12586 Pedro Alves <palves@redhat.com>
12588 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
12589 `step_over_finished' is true.
12591 2012-02-27 Pedro Alves <palves@redhat.com>
12593 * linux-low.c (pid_is_stopped): Delete, moved to common/.
12594 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
12596 2012-02-27 Pedro Alves <palves@redhat.com>
12599 * linux-low.c (pid_is_stopped): New.
12600 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
12602 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
12604 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
12607 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
12609 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
12611 2012-02-24 Luis Machado <lgustavo@codesourcery>
12613 * server.c (handle_query): Advertise support for target-side
12614 breakpoint condition evaluation.
12615 (process_point_options): New function.
12616 (process_serial_event): When inserting a breakpoint, check for
12617 a target-side condition that should be evaluated.
12619 * mem-break.c: Include regcache.h and ax.h.
12620 (point_cond_list_t): New data structure.
12621 (breakpoint) <cond_list>: New field.
12622 (find_gdb_breakpoint_at): Make non-static.
12623 (delete_gdb_breakpoint_at): Clear any target-side
12625 (clear_gdb_breakpoint_conditions): New function.
12626 (add_condition_to_breakpoint): Likewise.
12627 (add_breakpoint_condition): Likewise.
12628 (gdb_condition_true_at_breakpoint): Likewise.
12629 (gdb_breakpoint_here): Return result directly instead
12630 of going through a local variable.
12632 * mem-break.h (find_gdb_breakpoint_at): New prototype.
12633 (clear_gdb_breakpoint_conditions): Likewise.
12634 (add_breakpoint_condition): Likewise.
12635 (gdb_condition_true_at_breakpoint): Likewise.
12637 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
12638 (need_step_over_p): Take target-side breakpoint condition into
12641 2012-02-24 Luis Machado <lgustavo@codesourcery>
12643 * server.h: Include tracepoint.h.
12644 (agent_mem_read, agent_get_trace_state_variable_value,
12645 agent_set_trace_state_variable_value,
12646 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
12647 get_set_tsv_func_addr): New prototypes.
12649 * ax.h: New include file.
12650 * ax.c: New source file.
12652 * tracepoint.c: Include ax.h.
12653 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
12654 agent_expr, eval_result_type): Move to ax.h.
12655 (parse_agent_expr): Rename to ...
12656 (gdb_parse_agent_expr): ... this, make it non-static and move
12658 (unparse_agent_expr) Rename to ...
12659 (gdb_unparse_agent_expr): ... this, make it non-static and move
12661 (eval_agent_expr): Rename to ...
12662 (eval_tracepoint_agent_expr): ... this.
12663 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
12664 forward declarations.
12665 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
12666 (agent_get_trace_state_variable_value): New function.
12667 (agent_set_trace_state_variable_value): New function.
12668 (cmd_qtdp): Call gdb_parse_agent_expr (...).
12669 (response_tracepoint): Call gdb_unparse_agent_expr (...).
12670 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
12671 (condition_true_at_tracepoint): Likewise.
12672 (parse_agent_expr): Rename to ...
12673 (gdb_parse_agent_expr): ... this and move to ax.c.
12674 (unparse_agent_expr): Rename to ...
12675 (gdb_unparse_agent_expr): ... this and move to ax.c.
12676 (gdb_agent_op_name): Move to ax.c.
12677 (eval_agent_expr): Rename to ...
12678 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
12680 (eval_tracepoint_agent_expr): New function.
12681 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
12683 (current_insn_ptr, emit_error, struct bytecode_address): Move to
12685 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
12686 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
12687 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
12688 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
12689 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
12690 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
12691 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
12692 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
12693 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
12694 (compile_bytecodes): Remove forward declaration.
12695 (is_goto_target): Move to ax.c.
12696 (compile_bytecodes): Move to ax.c and call
12697 agent_get_trace_state_variable_value (...) and
12698 agent_set_trace_state_variable_value (...).
12700 * Makefile.in: Update ax.c and IPA dependencies.
12702 2012-02-24 Pedro Alves <palves@redhat.com>
12704 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
12705 (cmd_bigqtbuffer_circular): ... this. Only handle
12706 'QTBuffer:circular:'.
12707 (handle_tracepoint_general_set): Adjust.
12709 2012-02-16 Yao Qi <yao@codesourcery.com>
12711 * inferiors.c: Move code to ...
12712 * dll.c: .... here. New.
12713 * server.h: Declare clear_dlls.
12714 * Makefile.in (SFILES): Add dll.c.
12718 2012-02-11 Yao Qi <yao@codesourcery.com>
12720 * server.c: (handle_monitor_command): Add a new parameter
12722 (handle_query): Update caller.
12724 2012-02-09 Joel Brobecker <brobecker@adacore.com>
12726 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
12727 * configure, config.in: Regenerate.
12728 * hostio.c: Provide an alternate implementation if HAVE_READLINK
12731 2012-02-02 Pedro Alves <palves@redhat.com>
12733 Try SIGKILL first, then PTRACE_KILL.
12734 * linux-low.c (linux_kill_one_lwp): New.
12735 (linux_kill_one_lwp): Rename to ...
12736 (kill_one_lwp_callback): ... this. Use the new
12737 linux_kill_one_lwp.
12739 2012-02-02 Pedro Alves <palves@redhat.com>
12741 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
12744 2012-01-27 Pedro Alves <palves@redhat.com>
12746 * linux-low.c (linux_child_pid_to_exec_file): Delete.
12747 (elf_64_file_p): Make static.
12748 (linux_pid_exe_is_elf_64_file): New.
12749 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
12750 Delete declarations.
12751 (linux_pid_exe_is_elf_64_file): Declare.
12752 * linux-x86-low.c (x86_arch_setup): Use
12753 linux_pid_exe_is_elf_64_file.
12755 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
12757 * linux-low.c (linux_wait_for_event_1): Rename to ...
12758 (linux_wait_for_event): ... here and merge it with former
12759 linux_wait_for_event - new variable wait_ptid, use it.
12760 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
12762 2012-01-23 Pedro Alves <palves@redhat.com>
12764 * server.c (main): Avoid yet another case of infinite loop while
12765 detaching/killing after a longjmp.
12767 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12770 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
12772 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
12774 * hostio.c (handle_readlink): New function.
12775 (handle_vFile): Call it to handle "vFile:readlink" packets.
12777 2012-01-20 Pedro Alves <palves@redhat.com>
12778 Ulrich Weigand <ulrich.weigand@linaro.org>
12780 * server.c (handle_v_requests): Only support vAttach and vRun to
12781 start multiple processes when in extended protocol mode.
12783 2012-01-17 Pedro Alves <palves@redhat.com>
12785 * tracepoint.c (initialize_tracepoint): Use mmap instead of
12786 memalign plus mprotect to allocate the scratch buffer.
12788 2012-01-13 Pedro Alves <palves@redhat.com>
12790 * server.c (attach_inferior): Clear `cont_thread'.
12792 2012-01-13 Pedro Alves <palves@redhat.com>
12794 * server.c (main): Avoid infinite loop while detaching/killing
12797 2012-01-09 Doug Evans <dje@google.com>
12799 * server.c (start_inferior): Set last_ptid in --wrapper case.
12801 2012-01-06 Yao Qi <yao@codesourcery.com>
12803 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
12805 [IN_PROCESS_AGENT] (debug_agent): New global variable.
12807 2012-01-04 Yao Qi <yao@codesourcery.com>
12809 * tracepoint.c (cmd_qtdp): Print debug message
12810 for static tracepoint.
12812 2012-01-04 Yao Qi <yao@codesourcery.com>
12814 * tracepoint.c (trace_vdebug): Differentiate debug message
12815 between gdbserver and IPA.
12817 2012-01-03 Yao Qi <yao@codesourcery.com>
12819 * tracepoint.c (tracepoint_was_hit): Don't collect for
12822 2012-01-02 Joel Brobecker <brobecker@adacore.com>
12824 * terminal.h: Reformat copyright header.
12826 2012-01-02 Joel Brobecker <brobecker@adacore.com>
12828 * server.c (gdbserver_version): Update copyright year.
12829 * gdbreplay.c (gdbreplay_version): Likewise.
12831 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
12833 * linux-low.c (linux_create_inferior): Put empty if clause for write.
12836 2011-12-18 Hui Zhu <teawater@gmail.com>
12837 * linux-low.c (linux_create_inferior): Save return value to ret.
12839 2011-12-18 Hui Zhu <teawater@gmail.com>
12841 * linux-low.c (linux_create_inferior): Save return value to ret.
12843 2011-12-16 Doug Evans <dje@google.com>
12845 * linux-low.c (linux_create_inferior): If stdio connection,
12846 redirect stdin from /dev/null, stdout to stderr.
12847 * remote-utils.c (remote_is_stdio): New static global.
12848 (remote_connection_is_stdio): New function.
12849 (remote_prepare): Handle stdio connection.
12850 (remote_open): Ditto.
12851 (remote_close): Don't close stdin for stdio connections.
12852 (read_prim,write_prim): New functions. Replace all calls to
12853 read/write to these.
12854 * server.c (main): Watch for "-" argument. Move call to
12855 remote_prepare before start_inferior.
12856 * server.h (STDIO_CONNECTION_NAME): New macro.
12857 (remote_connection_is_stdio): Declare.
12859 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
12860 in debugging output.
12862 2011-12-15 Yao Qi <yao@codesourcery.com>
12864 * tracepoint.c: Include sys/syscall.h.
12865 (gdb_ust_thread): Remove preprocessor conditional.
12867 2011-12-14 Pedro Alves <pedro@codesourcery.com>
12869 * linux-low.c (linux_detach_one_lwp): Call
12870 the_low_target.prepare_to_resume before detaching.
12872 2011-12-14 Yao Qi <yao@codesourcery.com>
12874 * tracepoint.c (gdb_ust_thread): Don't ignore return value
12877 2011-12-14 Yao Qi <yao@codesourcery.com>
12879 * i386-low.c (i386_low_stopped_data_address): Initialize local
12880 variable `control'.
12882 2011-12-13 Pedro Alves <pedro@codesourcery.com>
12886 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
12887 DR_CONTROL unless necessary. Extend comments.
12888 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
12889 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
12891 2011-12-13 Yao Qi <yao@codesourcery.com>
12893 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
12895 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
12897 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
12899 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
12900 Print new debug message for such case.
12902 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
12904 Fix overlapping memcpy.
12905 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
12906 the read_inferior_memory transfer.
12907 (delete_fast_tracepoint_jump): New variable buf. Use it for the
12908 write_inferior_memory transfer.
12909 (set_fast_tracepoint_jump): New variable buf. Use it for the
12910 read_inferior_memory and write_inferior_memory transfers.
12911 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
12912 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
12913 Use it for the write_inferior_memory transfer.
12914 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
12917 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
12919 * linux-low.c (fetch_register, store_register): Make code
12920 consistent, fix formatting.
12922 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
12924 * linux-low.c (usr_store_inferior_registers): Factor out code
12925 to handle individual registers into...
12926 (store_register): ... this new function.
12928 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
12930 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
12931 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
12932 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
12933 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
12934 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
12935 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
12936 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
12937 (srv_xmlfiles): Add new XML files.
12939 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
12941 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
12942 (init_registers_s390_linux32v1): Add prototype.
12943 (init_registers_s390_linux32v2): Likewise.
12944 (init_registers_s390_linux64v1): Likewise.
12945 (init_registers_s390_linux64v2): Likewise.
12946 (init_registers_s390x_linux64v1): Likewise.
12947 (init_registers_s390x_linux64v2): Likewise.
12948 (s390_num_regs): Increment to 52.
12949 (s390_regmap): Add orig_r2 register.
12950 (s390_num_regs_3264): Increment to 68.
12951 (s390_regmap_3264): Add orig_r2 register.
12952 (s390_collect_ptrace_register): Handle orig_r2 register.
12953 (s390_supply_ptrace_register): Likewise.
12954 (s390_fill_last_break): New function.
12955 (s390_store_last_break): Likewise.
12956 (s390_fill_system_call): New function.
12957 (s390_store_system_call): Likewise.
12958 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
12960 (s390_check_regset): New function.
12961 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
12962 NT_S390_SYSTEM_CALL regsets and use appropriate description.
12963 Update target_regsets for available register sets.
12965 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
12966 Jan Kratochvil <jan.kratochvil@redhat.com>
12968 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
12969 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
12971 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
12972 * linux-low.h (struct process_info_private): New member r_debug.
12973 * server.c (handle_qxfer_libraries): Call
12974 the_target->qxfer_libraries_svr4.
12975 (handle_qxfer_libraries_svr4): New function.
12976 (qxfer_packets): New entry "libraries-svr4".
12977 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
12978 * target.h (struct target_ops): New member qxfer_libraries_svr4.
12979 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
12980 PACKET_qXfer_libraries_svr4.
12982 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
12984 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
12985 PSW address/mask between 8-byte and 16-byte formats.
12986 (s390_supply_ptrace_register): Likewise.
12987 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
12988 basic addressing mode bit.
12990 2011-11-24 Stan Shebs <stan@codesourcery.com>
12992 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
12994 2011-11-17 Stan Shebs <stan@codesourcery.com>
12996 * tracepoint.c (struct tracepoint): New field traceframe_usage.
12997 (tracing_start_time): New global.
12998 (tracing_stop_time): New global.
12999 (tracing_user_name): New global.
13000 (tracing_notes): New global.
13001 (tracing_stop_note): New global.
13002 (cmd_qtstart): Set traceframe_usage, start_time.
13003 (stop_tracing): Set stop_time.
13004 (cmd_qtstatus): Report additional status.
13005 (cmd_qtp): New function.
13006 (handle_tracepoint_query): Call it.
13007 (cmd_qtnotes): New function.
13008 (handle_tracepoint_general_set): Call it.
13009 (get_timestamp): Rename from tsv_get_timestamp.
13011 2011-11-14 Stan Shebs <stan@codesourcery.com>
13012 Kwok Cheung Yeung <kcy@codesourcery.com>
13014 * linux-x86-low.c (small_jump_insn): New.
13015 (i386_install_fast_tracepoint_jump_pad): Add arguments for
13016 trampoline and error message, build a trampoline and issue a small
13017 jump instruction to it.
13018 (x86_install_fast_tracepoint_jump_pad): Add arguments for
13019 trampoline and error message.
13020 (x86_get_min_fast_tracepoint_insn_len): New.
13021 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
13022 * linux-low.h (struct linux_target_ops): Add arguments to
13023 install_fast_tracepoint_jump_pad operation, add new operation.
13024 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
13026 (linux_get_min_fast_tracepoint_insn_len): New function.
13027 (linux_target_op): Add new operation.
13028 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
13029 (gdb_trampoline_buffer_end): Ditto.
13030 (gdb_trampoline_buffer_error): Ditto.
13031 (struct ipa_sym_addresses): Add fields for new IPA variables.
13032 (symbol_list): Add entries for new IPA variables.
13033 (struct tracepoint): Add fields to hold the address range of the
13034 trampoline used by the tracepoint.
13035 (trampoline_buffer_head): New static variable.
13036 (trampoline_buffer_tail): Ditto.
13037 (claim_trampoline_space): New function.
13038 (have_fast_tracepoint_trampoline_buffer): New function.
13039 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
13041 (install_fast_tracepoint): Ditto, also add error buffer argument.
13042 (cmd_qtminftpilen): New function.
13043 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
13044 (fast_tracepoint_from_trampoline_address): New function.
13045 (fast_tracepoint_collecting): Handle trampoline as part of jump
13047 (set_trampoline_buffer_space): New function.
13048 (initialize_tracepoint): Initialize new IPA variables.
13049 * target.h (struct target_ops): Add arguments to
13050 install_fast_tracepoint_jump_pad operation, add new
13051 get_min_fast_tracepoint_insn_len operation.
13052 (target_get_min_fast_tracepoint_insn_len): New.
13053 (install_fast_tracepoint_jump_pad): Add arguments.
13054 * server.h (IPA_BUFSIZ): Define.
13055 * linux-i386-ipa.c: Include extra header files.
13056 (initialize_fast_tracepoint_trampoline_buffer): New function.
13057 (initialize_low_tracepoint): Call it.
13058 * server.h (set_trampoline_buffer_space): Declare.
13059 (claim_trampoline_space): Ditto.
13060 (have_fast_tracepoint_trampoline_buffer): Ditto.
13062 2011-11-14 Yao Qi <yao@codesourcery.com>
13064 * server.c (handle_query): Handle InstallInTrace for qSupported.
13065 * tracepoint.c (add_tracepoint): Sort list.
13066 (install_tracepoint, download_tracepoint): New.
13067 (cmd_qtdp): Call them to install and download tracepoints.
13068 (sort_tracepoints): Removed.
13069 (cmd_qtstart): Update.
13071 2011-11-14 Yao Qi <yao@codesourcery.com>
13073 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
13074 * mem-break.h: Declare.
13075 * tracepoint.c (cmd_qtstart): Move some code to ...
13076 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
13078 (download_tracepoints): Move some code to ...
13079 (download_tracepoint_1): ... here. New.
13081 2011-11-08 Yao Qi <yao@codesourcery.com>
13083 * remote-utils.c (relocate_instruction): A comment fix.
13085 2011-11-07 Joel Brobecker <brobecker@adacore.com>
13087 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
13088 (i386_dr_low_get_control, i386_dr_low_get_status): Use
13089 dr_status_mirror and dr_control_mirror from debug_reg_state.
13090 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
13091 (i386_initial_stuff): Remove use of deleted globals.
13092 (i386_get_thread_context, i386_set_thread_context,
13093 i386_thread_added): Use dr_status_mirror and dr_control_mirror
13094 from debug_reg_state.
13096 2011-11-05 Yao Qi <yao@codesourcery.com>
13098 * tracepoint.c (gdb_collect): Loop over tracepoints of same
13099 address as TPOINT's.
13101 2011-11-02 Stan Shebs <stan@codesourcery.com>
13103 * tracepoint.c (agent_mem_read_string): New function.
13104 (eval_agent_expr): Call it for tracenz.
13105 * server.c (handle_query): Report support for tracenz.
13107 2011-11-02 Yao Qi <yao@codesourcery.com>
13109 * tracepoint.c (cmd_qtstart): Remove unused local variables.
13111 2011-11-02 Yao Qi <yao@codesourcery.com>
13113 * target.h: Fix a typo in comment.
13115 2011-10-31 Pedro Alves <pedro@codesourcery.com>
13117 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
13118 clobber the breakpoints' shadows with fast tracepoint jumps.
13119 * mem-break.h (check_mem_write): Add `myaddr' parameter.
13120 * target.c (write_inferior_memory): Also pass MYADDR down to
13123 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
13125 * configure.ac: Check support for personality routine.
13126 * configure: Regenerate.
13127 * config.in: Likewise.
13128 * linux-low.c: Include <sys/personality.h>.
13129 Define ADDR_NO_RANDOMIZE if necessary.
13130 (linux_create_inferior): Disable address space randomization when
13131 forking inferior, if requested.
13132 (linux_supports_disable_randomization): New function.
13133 (linux_target_ops): Install it.
13134 * server.h (disable_randomization): Declare.
13135 * server.c (disable_randomization): New global variable.
13136 (handle_general_set): Handle QDisableRandomization.
13137 (handle_query): Likewise for qSupported.
13138 (main): Support --disable-randomization and --no-disable-randomization
13139 command line arguments.
13140 * target.h (struct target_ops): Add supports_disable_randomization.
13141 (target_supports_disable_randomization): New macro.
13143 2011-09-29 Mike Frysinger <vapier@gentoo.org>
13145 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
13147 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
13148 [!PT_GETDSBT] (target_loadmap): New definition.
13149 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
13150 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
13151 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
13152 and PT_GETDSBT to LINUX_LOADMAP.
13153 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
13154 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
13156 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
13158 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
13159 (arm_linux_hwbp_cap): New static variable.
13160 (arm_linux_get_hwbp_cap): Replace by ...
13161 (arm_linux_init_hwbp_cap): ... this new function.
13162 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
13163 (arm_linux_get_hw_watchpoint_count): Likewise.
13164 (arm_linux_get_hw_watchpoint_max_length): Likewise.
13165 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
13166 (arm_prepare_to_resume): Use perror_with_name instead of error.
13168 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
13170 * linux-arm-low.c: Include <signal.h>.
13171 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
13172 (struct arm_linux_hwbp_cap): New data type.
13173 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
13174 (struct arm_linux_hw_breakpoint): New data type.
13175 (MAX_BPTS, MAX_WPTS): Define.
13176 (struct arch_process_info, struct arch_lwp_info): New data types.
13177 (arm_linux_get_hwbp_cap): New function.
13178 (arm_linux_get_hw_breakpoint_count): Likewise.
13179 (arm_linux_get_hw_watchpoint_count): Likewise.
13180 (arm_linux_get_hw_watchpoint_max_length): Likewise.
13181 (arm_hwbp_control_initialize): Likewise.
13182 (arm_hwbp_control_is_enabled): Likewise.
13183 (arm_hwbp_control_is_initialized): Likewise.
13184 (arm_hwbp_control_disable): Likewise.
13185 (arm_linux_hw_breakpoint_equal): Likewise.
13186 (arm_linux_hw_point_initialize): Likewise.
13187 (struct update_registers_data): New data structure.
13188 (update_registers_callback: New function.
13189 (arm_insert_point): Likewise.
13190 (arm_remove_point): Likewise.
13191 (arm_stopped_by_watchpoint): Likewise.
13192 (arm_stopped_data_address): Likewise.
13193 (arm_new_process): Likewise.
13194 (arm_new_thread): Likewise.
13195 (arm_prepare_to_resume): Likewise.
13196 (the_low_target): Register arm_insert_point, arm_remove_point,
13197 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
13198 arm_new_thread, and arm_prepare_to_resume.
13200 2011-09-15 Stan Shebs <stan@codesourcery.com>
13202 * server.h (struct emit_ops): Add compare-goto fields.
13203 * tracepoint.c (gdb_agent_op_sizes): New table.
13204 (emit_eq_goto): New function.
13205 (emit_ne_goto): New function.
13206 (emit_lt_goto): New function.
13207 (emit_le_goto): New function.
13208 (emit_gt_goto): New function.
13209 (emit_ge_goto): New function.
13210 (is_goto_target): New function.
13211 (compile_bytecodes): Recognize special cases of compare-goto
13212 combinations and call specialized emitters for them.
13213 * linux-x86-low.c (amd64_emit_eq_goto): New function.
13214 (amd64_emit_ne_goto): New function.
13215 (amd64_emit_lt_goto): New function.
13216 (amd64_emit_le_goto): New function.
13217 (amd64_emit_gt_goto): New function.
13218 (amd64_emit_ge_goto): New function.
13219 (amd64_emit_ops): Add the new functions.
13220 (i386_emit_eq_goto): New function.
13221 (i386_emit_ne_goto): New function.
13222 (i386_emit_lt_goto): New function.
13223 (i386_emit_le_goto): New function.
13224 (i386_emit_gt_goto): New function.
13225 (i386_emit_ge_goto): New function.
13226 (i386_emit_ops): Add the new functions.
13228 2011-09-08 Stan Shebs <stan@codesourcery.com>
13230 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
13231 (i386_emit_epilogue): Restore %ebx.
13233 2011-08-31 Jie Zhang <jzhang918@gmail.com>
13235 * server.c (step_thread): Remove definition.
13236 (process_serial_event): Don't handle Hs.
13237 * server.h (step_thread): Remove declaration.
13238 * target.c (set_desired_inferior): Remove use of step_thread.
13240 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
13242 * linux-low.c: Include linux-procfs.h.
13243 (linux_attach_lwp_1): Update comments.
13244 (linux_attach): Scan for existing threads when attaching to a
13245 process that is the tgid.
13246 * Makefile.in: Update dependencies.
13248 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
13250 * configure.srv: Add linux-procfs.o dependencies.
13252 2011-08-14 Yao Qi <yao@codesourcery.com>
13254 * target.h (struct target_ops): Fix indent.
13255 * win32-low.c (win32_target_ops): Fix comment.
13257 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
13258 Yao Qi <yao@codesourcery.com>
13260 * Makefile.in (clean): Remove tic6x-*.c files.
13261 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
13262 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
13263 (tic6x-c64xp-linux.c): Likewise.
13264 * configure.srv: Add support for tic6x-*-uclinux.
13265 * linux-tic6x-low.c: New.
13266 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
13268 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
13269 Yao Qi <yao@codesourcery.com>
13271 * target.h (struct target_ops): Add read_loadmap.
13272 * linux-low.c (struct target_loadseg): New type.
13273 (struct target_loadmap): New type.
13274 (linux_read_loadmap): New function.
13275 (linux_target_ops): Add linux_read_loadmap.
13276 * server.c (handle_query): Support qXfer:fdpic:read packet.
13277 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
13280 2011-08-05 Eli Zaretskii <eliz@gnu.org>
13282 * win32-low.c: Include <stdint.h>.
13284 2011-07-22 Pedro Alves <pedro@codesourcery.com>
13286 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
13287 to the inferior here.
13288 (i386_remove_aligned_watchpoint): Ditto.
13289 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
13290 fit part of the watchpoint in the debug registers.
13291 (i386_update_inferior_debug_regs): New.
13292 (i386_low_insert_watchpoint): Work on a local mirror of the debug
13293 registers, and only update the inferior on success.
13294 (i386_low_remove_watchpoint): Ditto.
13296 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
13298 * linux-low.c (compare_ints, unique, list_threads, show_process,
13299 linux_core_of_thread): Delete.
13300 (linux_target_ops): Change linux_core_of_thread to
13301 linux_common_core_of_thread.
13302 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
13303 * utils.c (malloc_failure): Change type of argument.
13304 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
13305 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
13306 common/linux-osdata.c, common/ptid.c and common/buffer.c.
13307 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
13308 (IPA_OBJS): Add common-utils-ipa.o.
13309 (ptid_h, linux_osdata_h): New macros.
13310 (server_h): Add common/common-utils.h, common/xml-utils.h,
13311 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
13313 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
13314 ptid.o, buffer.o): New rules.
13315 (linux-low.o): Add common/linux-osdata.h as a dependency.
13316 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
13317 * configure.ac: Add AC_HEADER_DIRENT check.
13318 * config.in: Regenerate.
13319 * configure: Regenerate.
13320 * remote-utils.c (xml_escape_text): Delete.
13321 (buffer_grow, buffer_free, buffer_init, buffer_finish,
13322 buffer_xml_printf): Move to common/buffer.c.
13323 * server.c (main): Remove call to initialize_inferiors.
13324 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
13325 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
13326 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
13327 internal_error, gdb_assert, gdb_assert_fail): Delete.
13328 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
13329 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
13331 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
13332 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
13333 initialize_inferiors): Delete.
13335 2011-07-20 Pedro Alves <pedro@codesourcery.com>
13337 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
13340 2011-05-31 Pedro Alves <pedro@codesourcery.com>
13342 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
13344 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
13346 2011-05-26 Yao Qi <yao@codesourcery.com>
13348 * Makefile.in (thread-db.o): Track dependence to
13349 common/gdb_thread_db.h.
13350 * thread-db.c: include gdb_thread_db.h from right place.
13352 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
13354 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
13355 __FILE__ and __LINE__ to internal_error.
13357 2011-05-13 Doug Evans <dje@google.com>
13359 * thread-db.c (try_thread_db_load_from_sdir): New function.
13360 (try_thread_db_load_from_dir): New function.
13361 (thread_db_load_search): Handle $sdir, ignore $pdir.
13362 Remove trying of system directories if search of
13363 libthread-db-search-path fails, that is now done via $sdir.
13365 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
13367 * server.c (handle_query): Add EnableDisableTracepoints to the list
13368 of supported features.
13369 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
13371 (cmd_qtenable_disable): New.
13372 (cmd_qtstart): Install tracepoints even if disabled.
13373 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
13374 receiving a QTEnable or QTDisable packet.
13375 (gdb_collect): Skip data collection if fast tracepoint is disabled.
13376 (ust_marker_to_static_tracepoint): Do not ignore disabled static
13378 (gdb_probe): Skip data collection if static tracepoint is disabled.
13380 2011-05-10 Doug Evans <dje@google.com>
13382 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
13384 2011-05-04 Doug Evans <dje@google.com>
13386 * linux-low.c (linux_join): Skip process lookup.
13387 * spu-low.c (spu_join): Ditto.
13388 * server.c (join_inferiors_callback): Delete.
13389 (process_serial_event): For 'D' packet (detach) call join_inferior
13392 2011-05-04 Joseph Myers <joseph@codesourcery.com>
13394 * README: Don't mention xscale*-*-linux*.
13395 * configure.srv (xscale*-*-linux*): Don't handle target.
13397 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
13399 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
13401 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
13402 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
13403 (i386_emit_void_call_2): Likewise.
13405 2011-04-26 Yao Qi <yao@codesourcery.com>
13407 * linux-low.c: Move common macros to linux-ptrace.h.
13408 Include linux-ptrace.h.
13409 * Makefile.in (linux_ptrace_h): New.
13410 (linux-low.o): Depends on linux-ptrace.h.
13412 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
13414 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
13415 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
13416 (remote_prepare): New function with most of the TCP code from ...
13417 (remote_open): ... here. Detect PORT here unconditionally. Move also
13418 setting transport_is_reliable.
13419 * server.c (run_once): New variable.
13420 (gdbserver_usage): Document it.
13421 (main): Set run_once for `--once'. Call remote_prepare. Exit after
13422 the first run if RUN_ONCE.
13423 * server.h (run_once, remote_prepare): New declarations.
13425 2011-04-19 Tom Tromey <tromey@redhat.com>
13427 * win32-low.c (handle_load_dll): Remove duplicate "the".
13429 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
13431 Remove support for old Cygwin 1.5 versions.
13432 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
13433 function to avoid warning.
13434 (win32_add_one_solib): Use cygwin_conv_path function to avoid
13437 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
13439 * gdbserver/server.h (Macro _): Define it if not available.
13441 2011-03-14 Michael Snyder <msnyder@vmware.com>
13443 * hostio.c (handle_close): Remove unnecessary null test.
13445 2011-03-10 Joel Brobecker <brobecker@adacore.com>
13447 * Makefile.in (maintainer-clean realclean distclean): Remove
13448 "make ... subdir_do" command.
13450 2011-03-10 Michael Snyder <msnyder@vmware.com>
13452 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
13454 * server.c (handle_v_run): Free alloced buffer on early return.
13456 2011-03-09 Yao Qi <yao@codesourcery.com>
13459 2011-03-04 Yao Qi <yao@codesourcery.com>
13461 * Makefile.in: Remove GNU make feature --directory.
13463 2011-03-05 Yao Qi <yao@codesourcery.com>
13465 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
13466 (subdir_do): New make target. Copied from gdb/Makefile.
13467 (maintainer-clean, realclean, distclean, clean): Call corresponding
13468 make targets in common/Makefile.
13470 2011-02-11 Yao Qi <yao@codesourcery.com>
13472 * configure.ac: Call AC_PROG_RANLIB.
13473 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
13474 * configure: Regenerate.
13476 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
13478 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
13480 2011-03-06 Yao Qi <yao@codesourcery.com>
13482 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
13484 2011-03-05 Yao Qi <yao@codesourcery.com>
13486 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
13487 (subdir_do): New make target. Copied from gdb/Makefile.
13488 (maintainer-clean, realclean, distclean, clean): Call corresponding
13489 make targets in common/Makefile.
13491 2011-03-04 Yao Qi <yao@codesourcery.com>
13493 * Makefile.in: Remove GNU make feature --directory.
13495 2011-03-04 Michael Snyder <msnyder@vmware.com>
13497 * server.c (queue_stop_reply): Call xmalloc not malloc.
13499 2011-03-02 Michael Snyder <msnyder@vmware.com>
13501 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
13503 2011-02-28 Michael Snyder <msnyder@vmware.com>
13505 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
13506 (cmd_qtframe): Ditto.
13507 (cmd_qtbuffer): Ditto.
13508 (cmd_bigqtbuffer): Ditto.
13510 * utils.c (decimal2str): Initialize 'width' to nine, then
13511 don't mess with it.
13513 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
13515 * hostio.c (require_data): Free *data, not data.
13517 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13519 * hostio.c (require_data): Use free, not xfree.
13521 2011-02-27 Michael Snyder <msnyder@vmware.com>
13523 * server.c (handle_query): Discard unused value.
13525 * hostio.c (require_data): Free malloc memory before returning
13528 2011-02-26 Michael Snyder <msnyder@vmware.com>
13530 * linux-low.c (list_threads): Call closedir for dirent.
13532 2011-02-27 Michael Snyder <msnyder@vmware.com>
13534 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
13535 a case statement falls through.
13537 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
13539 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
13542 2011-02-26 Michael Snyder <msnyder@vmware.com>
13544 * utils.c (decimal2str): Eliminate dead code and dead param.
13545 (pulongest): Drop dead param from call to decimal2str.
13548 2011-02-24 Joel Brobecker <brobecker@adacore.com>
13550 Revert the following patch (not approved yet):
13551 2011-02-21 Hui Zhu <teawater@gmail.com>
13552 * tracepoint.c (tp_printf): New function.
13553 (eval_agent_expr): Handle gdb_agent_op_printf.
13555 2011-02-21 Hui Zhu <teawater@gmail.com>
13557 * tracepoint.c (tp_printf): New function.
13558 (eval_agent_expr): Handle gdb_agent_op_printf.
13560 2011-02-18 Tom Tromey <tromey@redhat.com>
13562 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
13563 (tracepoint.o): Likewise.
13564 * tracepoint.c (enum gdb_agent_op): Use ax.def.
13565 (gdb_agent_op_names): Likewise.
13567 2011-02-18 Tom Tromey <tromey@redhat.com>
13569 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
13570 gdb_agent_op_rot>: New constants.
13571 (gdb_agent_op_names): Add pick and roll.
13572 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
13575 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
13577 * aclocal.m4: Regenerated with aclocal-1.11.1.
13579 2011-02-14 Pedro Alves <pedro@codesourcery.com>
13581 * server.c (handle_qxfer_traceframe_info): New.
13582 (qxfer_packets): Register "traceframe-info".
13583 (handle_query): Report support for qXfer:traceframe-info:read+.
13584 * tracepoint.c (match_blocktype): New.
13585 (traceframe_find_block_type): Rename to ...
13586 (traceframe_walk_blocks): ... this. Add callback filter argument,
13588 (traceframe_find_block_type): New, reimplemented on top of
13589 traceframe_walk_blocks.
13590 (build_traceframe_info_xml): New.
13591 (traceframe_read_info): New.
13592 * server.h (traceframe_read_info): Declare.
13594 2011-02-11 Yao Qi <yao@codesourcery.com>
13596 * configure.ac: Call AC_PROG_RANLIB.
13597 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
13598 * configure: Regenerate.
13600 2011-02-07 Pedro Alves <pedro@codesourcery.com>
13602 * server.c (gdb_read_memory): Change return semantics to allow
13604 (handle_search_memory_1): Adjust.
13605 (process_serial_event) <'m' packet>: Handle partial transfers.
13606 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
13608 2011-01-28 Pedro Alves <pedro@codesourcery.com>
13610 * regcache.c (init_register_cache): Initialize
13611 regcache->register_status.
13612 (free_register_cache): Release regcache->register_status.
13613 (regcache_cpy): Copy register_status.
13614 (registers_to_string): Print 'x's for unavailable registers.
13615 (supply_register): Mark the register's status valid or
13616 unavailable, depending on whether a buffer was passed in or not.
13617 (supply_register_zeroed): New.
13618 (supply_regblock): Mark the registers' status valid or
13619 unavailable, depending on whether a buffer was passed in or not.
13620 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
13621 (struct regcache): New `register_status' field.
13622 (supply_register_zeroed): Declare.
13623 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
13624 supply_register_zeroed, rather than passing a NULL buffer to
13626 * tracepoint.c (fetch_traceframe_registers): Update comment.
13628 2011-01-28 Pedro Alves <pedro@codesourcery.com>
13630 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
13633 2011-01-25 Pedro Alves <pedro@codesourcery.com>
13635 * server.h (decode_xfer_write): Change prototype.
13636 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
13637 and don't extract the annex here.
13638 * server.c (decode_xfer_read): Remove `annex' parameter,
13639 and don't extract the annex here.
13640 (decode_xfer): New.
13641 (struct qxfer): New.
13642 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
13643 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
13644 (handle_qxfer_statictrace): New functions, abstracted out from
13645 handle_query, and made to use the struct qxfer interface.
13646 (handle_threads_qxfer_proper): Rename to ...
13647 (handle_qxfer_threads_proper): ... this.
13648 (handle_threads_qxfer): Rename to ...
13649 (handle_qxfer_threads): ... this. Adjust.
13650 (qxfer_packets): New array.
13651 (handle_qxfer): New function.
13652 (handle_query): Use handle_qxfer.
13654 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
13656 * gdbreplay.c: Shorten lines of >= 80 columns.
13657 * linux-low.c: Ditto.
13658 * linux-ppc-low.c: Ditto.
13659 * linux-s390-low.c: Ditto.
13660 * linux-sparc-low.c: Ditto.
13661 * linux-x86-low.c: Ditto.
13662 * linux-xtensa-low.c: Ditto.
13663 * mem-break.c: Ditto.
13664 * nto-low.c: Ditto.
13665 * regcache.h: Ditto.
13666 * remote-utils.c: Ditto.
13669 * thread-db.c: Ditto.
13670 * tracepoint.c: Ditto.
13672 * win32-low.h: Ditto.
13674 2011-01-05 Joel Brobecker <brobecker@adacore.com>
13676 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
13679 2011-01-01 Joel Brobecker <brobecker@adacore.com>
13681 * server.c (gdbserver_version): Update copyright year in version
13683 * gdbreplay.c (gdbreplay_version): Ditto.
13685 2010-12-29 Jie Zhang <jie.zhang@analog.com>
13687 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
13688 * linux-bfin-low.c: New file.
13689 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
13690 PT_DATA_ADDR for BFIN targets.
13691 * Makefile.in (SFILES): Add linux-bfin-low.c.
13692 (clean): Remove reg-bfin.c.
13693 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
13694 * README: Mention supported Blackfin targets.
13696 2010-12-23 Mike Frysinger <vapier@gentoo.org>
13698 * .gitignore: New file.
13700 2010-11-16 Mike Frysinger <vapier@gentoo.org>
13702 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
13704 2010-10-22 Jie Zhang <jie@codesourcery.com>
13706 * Makefile.in: Add FLAGS_TO_PASS variable.
13707 (install): Remove dependency of install-only and recursively
13708 invoke make for install-only.
13710 2010-10-04 Doug Evans <dje@google.com>
13712 * Makefile.in (uninstall): Use $(DESTDIR).
13714 2010-09-24 Pedro Alves <pedro@codesourcery.com>
13718 * linux-x86-low.c (compat_siginfo_from_siginfo)
13719 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
13720 si_code is < 0. Check for si_code == SI_TIMER before checking for
13723 2010-09-13 Joel Brobecker <brobecker@adacore.com>
13725 * lynx-i386-low.c: New file.
13726 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
13728 2010-09-13 Joel Brobecker <brobecker@adacore.com>
13730 * lynx-low.c (ptrace_request_to_str): Remove handling for
13731 request values that have been removed in LynxOS 5.x.
13733 2010-09-13 Joel Brobecker <brobecker@adacore.com>
13735 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
13738 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
13740 * configure.ac: Add --enable-inprocess-agent option.
13741 * configure: Rebuilt.
13743 2010-09-06 Yao Qi <yao@codesourcery.com>
13745 * linux-low.c (linux_kill): Remove unused variable.
13746 (linux_stabilize_threads): Likewise.
13747 * server.c (start_inferior): Likewise.
13748 (queue_stop_reply_callback): Likewise.
13749 * tracepoint.c (do_action_at_tracepoint): Likewise.
13751 2010-09-06 Yao Qi <yao@codesourcery.com>
13753 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
13756 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
13758 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
13760 2010-09-06 Pedro Alves <pedro@codesourcery.com>
13762 * Makefile.in (install-only): Replace $IPA_DEPFILES with
13765 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13767 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
13768 gdbserver/lynx-ppc-low.c: New files.
13769 * Makefile.in (lynx_low_h): New variable.
13770 (lynx-low.o, lynx-ppc-low.o): New rules.
13771 * configure.ac: On LynxOS, link with -lnetinet.
13772 * configure.srv: Add handling of powerpc-*-lynxos* targets.
13773 * configure: regenerate.
13775 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13777 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
13778 * configure.ac: Add check for vasprintf and vsnprintf.
13779 * configure, config.in: Regenerate.
13780 * server.h (vasprintf, vsnprintf): Add conditional declarations.
13782 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13784 * gdbreplay.c: Move include of alloca.h up, next to include of
13786 * server.h: Add include of malloc.h.
13787 * mem-break.c: Remove include of malloc.h.
13788 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
13790 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13792 * Makefile.in (memmem.o): Build with -Wno-error.
13794 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13796 * utils.c (xsnprintf): Make non-static.
13797 * server.h: Add xsnprintf declaration.
13798 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
13799 replace calls to snprintf by calls to xsnprintf throughout.
13801 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13803 * configure.ac: Add configure check for alloca.
13804 * configure, config.in: Regenerate.
13805 * server.h: Include alloca.h if it exists.
13806 * gdbreplay.c: Include alloca.h if it exists.
13808 2010-08-28 Pedro Alves <pedro@codesourcery.com>
13810 * linux-low.c (__SIGRTMIN): Define if not already defined.
13811 (linux_create_inferior): Check for __ANDROID__ rather than
13813 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
13814 are already deferred.
13815 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
13816 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
13817 stopped and already has a pending signal to report.
13818 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
13819 a pending signal to report or is moving out of a jump pad.
13820 (linux_init_signals): Check for __ANDROID__ rather than
13823 2010-08-28 Pedro Alves <pedro@codesourcery.com>
13825 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
13826 debug_threads check. Avoid a linear search when not doing debug
13829 2010-08-27 Pedro Alves <pedro@codesourcery.com>
13831 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
13832 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
13833 (struct file_handler) <fd>: Change type to gdb_fildes_t.
13834 (process_event): Change local fd's type to gdb_fildes_t.
13835 (create_file_handler): Adjust prototype.
13836 (delete_file_handler): Adjust prototype.
13837 (handle_file_event): Adjust prototype. Use pfildes.
13838 (create_file_event): Adjsut prototype.
13839 * remote-utils.c (remote_desc, listen_desc): Change type to
13841 * server.h: New gdb_fildes_t typedef.
13842 [USE_WIN32API]: Include winsock2.h.
13843 (delete_file_handler, add_file_handler): Adjust prototypes.
13844 (pfildes): Declare.
13845 * utils.c (pfildes): New.
13847 2010-08-27 Pedro Alves <pedro@codesourcery.com>
13849 * configure.ac (build_warnings): Add -Wno-char-subscripts.
13850 * configure: Regenerate.
13852 2010-08-27 Pedro Alves <pedro@codesourcery.com>
13854 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
13855 (linux_done_accessing_memory): ... this.
13856 (linux_target_ops): Adjust.
13857 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
13858 * nto-low.c (nto_target_ops): Adjust comment.
13859 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
13860 * spu-low.c (spu_target_ops): Adjust comment.
13861 * target.h (target_ops): Rename unprepare_to_access_memory field
13862 to done_accessing_memory.
13863 (unprepare_to_access_memory): Rename to ...
13864 (done_accessing_memory): ... this.
13866 2010-08-26 Pedro Alves <pedro@codesourcery.com>
13868 * linux-low.c (linux_prepare_to_access_memory): New.
13869 (linux_unprepare_to_access_memory): New.
13870 (linux_target_ops): Install them.
13871 * server.c (read_memory): Rename to ...
13872 (gdb_read_memory): ... this. Use
13873 prepare_to_access_memory/prepare_to_access_memory.
13874 (write_memory): Rename to ...
13875 (gdb_write_memory): ... this. Use
13876 prepare_to_access_memory/prepare_to_access_memory.
13877 (handle_search_memory_1): Adjust.
13878 (process_serial_event): Adjust.
13879 * target.h (struct target_ops): New fields
13880 prepare_to_access_memory and unprepare_to_access_memory.
13881 (prepare_to_access_memory, unprepare_to_access_memory): New.
13882 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
13883 prepare_to_access_memory/prepare_to_access_memory.
13884 * nto-low.c (nto_target_ops): Adjust.
13885 * spu-low.c (spu_target_ops): Adjust.
13886 * win32-low.c (win32_target_ops): Adjust.
13888 2010-08-26 Pedro Alves <pedro@codesourcery.com>
13890 * Makefile.in (WARN_CFLAGS): Get it from configure.
13891 (WERROR_CFLAGS): New.
13892 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
13893 * configure.ac: Introduce --enable-werror, which adds -Werror to
13894 the compiler command line. Enabled by default. Disable with
13895 --disable-werror. Add -Wdeclaration-after-statement
13896 Wpointer-arith and -Wformat-nonliteral to warning flags.
13897 * configure: Regenerate.
13899 2010-08-26 Pedro Alves <pedro@codesourcery.com>
13901 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
13903 2010-08-26 Pedro Alves <pedro@codesourcery.com>
13905 * gdbreplay.c (remote_error): New.
13907 (expect): Use gdbchar. Check for error reading from GDB.
13908 Clarify sync error output.
13909 (play): Check for errors writing to GDB.
13910 * linux-low.c (sigchld_handler): Really ignore `write' errors.
13911 * remote-utils.c (getpkt): Check for errors writing to the remote
13914 2010-08-25 Pedro Alves <pedro@codesourcery.com>
13916 * linux-low.c (linux_wait_1): Move non-debugging code out of
13917 `debug_threads' control.
13919 2010-08-25 Pedro Alves <pedro@codesourcery.com>
13921 * linux-low.c (linux_wait_1): Don't set last_status here.
13922 * server.c (push_event, queue_stop_reply_callback): Assert we're
13923 not pushing a TARGET_WAITKIND_IGNORE event.
13924 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
13925 (myresume, handle_target_event): Set the thread's last_resume_kind
13926 and last_status from the target returned status.
13928 2010-08-25 Pedro Alves <pedro@codesourcery.com>
13932 * linux-x86-low.c (update_debug_registers_callback): New.
13933 (i386_dr_low_set_addr): Use it.
13934 (i386_dr_low_get_addr): New.
13935 (i386_dr_low_set_control): Use update_debug_registers_callback.
13936 (i386_dr_low_get_control): New.
13937 (i386_dr_low_get_status): Adjust.
13938 * linux-low.c (linux_stop_lwp): New.
13939 * linux-low.h (linux_stop_lwp): Declare.
13941 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
13942 argument instead of a i386_debug_reg_state.
13943 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
13944 a i386_debug_reg_state.
13945 (i386_insert_aligned_watchpoint): Adjust.
13946 (i386_remove_aligned_watchpoint): Adjust.
13947 (i386_low_stopped_data_address): Read the debug registers from the
13948 inferior instead of from the mirrors.
13949 * i386-low.h (struct i386_debug_reg_state): Extend comment.
13950 (i386_dr_low_get_addr): Declare.
13951 (i386_dr_low_get_control): Declare.
13952 (i386_dr_low_get_status): Change prototype.
13954 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
13955 (i386_dr_low_get_addr): New.
13956 (i386_dr_low_get_control): New.
13957 (i386_dr_low_get_status): Adjust prototype. Return
13959 (i386_initial_stuff): Clear dr_status_mirror and
13961 (i386_get_thread_context): Adjust.
13962 (i386_set_thread_context): Adjust.
13963 (i386_thread_added): Adjust.
13965 2010-08-24 Pedro Alves <pedro@codesourcery.com>
13967 * linux-low.h (linux_thread_area): Delete declaration.
13969 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
13971 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
13972 after its termination.
13974 2010-08-09 Pedro Alves <pedro@codesourcery.com>
13976 * linux-low.c (gdb_wants_lwp_stopped): Delete.
13977 (gdb_wants_all_stopped): Delete.
13978 (linux_wait_1): Don't call them.
13979 * server.c (handle_v_cont): Tag all threads as want-stopped.
13980 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
13981 stopped as "client-wants-stopped".
13983 2010-07-31 Pedro Alves <pedro@codesourcery.com>
13985 * Makefile.in (signals_h): New.
13986 (server_h): Depend on it.
13987 (server.o): Don't depend on $(signals_def).
13988 (signals.o): Depend on $(signals_def).
13990 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
13992 * Makefile.in (signals_def): New.
13993 (server_h): Append include/gdb/signals.h and signals_def.
13994 (server.o): Append signals_def.
13996 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
13998 * server.c (handle_target_event): Use target_signal_to_host for
13999 resume_info.sig initialization.
14000 * target.h (struct thread_resume) <sig>: New comment.
14002 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
14004 * server.c (handle_query): strcpy() the returned string from paddress()
14005 instead of sprintf().
14006 * utils.c (paddress): Return phex_nz().
14008 2010-07-07 Joel Brobecker <brobecker@adacore.com>
14010 * server.c (handle_v_cont): Call mourn_inferior if process
14012 (myresume): Likewise.
14014 2010-07-01 Pedro Alves <pedro@codesourcery.com>
14016 Static tracepoints, and integration with UST.
14018 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
14019 * mem-break.c (uninsert_all_breakpoints)
14020 (reinsert_all_breakpoints): New.
14021 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
14022 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
14023 (gdb_agent_ust_loaded, helper_thread_id)
14024 (gdb_agent_helper_thread_id): New macros.
14025 (struct ipa_sym_addresses): Add addr_ust_loaded,
14026 addr_helper_thread_id, addr_cmd_buf.
14027 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
14028 (in_process_agent_loaded_ust): New.
14029 (write_e_ust_not_loaded): New.
14030 (maybe_write_ipa_ust_not_loaded): New.
14031 (struct collect_static_trace_data_action): New.
14032 (enum tracepoint_type) <static_tracepoint>: New.
14033 (struct tracepoint) <handle>: Mention static tracepoints.
14034 (struct static_tracepoint_ctx): New.
14035 (CMD_BUF_SIZE): New.
14036 (add_tracepoint_action): Handle static tracepoint actions.
14037 (unprobe_marker_at): New.
14038 (clear_installed_tracepoints): Handle static tracepoints.
14039 (cmd_qtdp): Handle static tracepoints.
14040 (probe_marker_at): New.
14041 (cmd_qtstart): Handle static tracepoints.
14042 (response_tracepoint): Handle static tracepoints.
14043 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
14044 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
14045 (get_context_regcache): Handle static tracepoints.
14046 (do_action_at_tracepoint): Handle static tracepoint actions.
14047 (traceframe_find_block_type): Handle static trace data blocks.
14048 (traceframe_read_sdata): New.
14049 (download_tracepoints): Download static tracepoint actions.
14050 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
14051 (GDB_PROBE_NAME): New.
14053 (GET_UST_SYM): New.
14056 (ust_marker_to_static_tracepoint): New.
14058 (collect_ust_data_at_tracepoint): New.
14059 (gdb_ust_probe): New.
14060 (UNIX_PATH_MAX, SOCK_DIR): New.
14061 (gdb_ust_connect_sync_socket): New.
14062 (resume_thread, stop_thread): New.
14063 (run_inferior_command): New.
14064 (init_named_socket): New.
14065 (gdb_ust_socket_init): New.
14066 (cstr_to_hexstr): New.
14068 (first_marker, next_marker): New.
14069 (response_ust_marker): New.
14070 (cmd_qtfstm, cmd_qtsstm): New.
14071 (unprobe_marker_at, probe_marker_at): New.
14072 (cmd_qtstmat, gdb_ust_thread): New.
14073 (gdb_ust_init): New.
14074 (initialize_tracepoint_ftlib): Call gdb_ust_init.
14075 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
14076 (ST_REGENTRY): New.
14077 (x86_64_st_collect_regmap): New.
14078 (X86_64_NUM_ST_COLLECT_GREGS): New.
14079 (AMD64_RIP_REGNUM): New.
14080 (supply_static_tracepoint_registers): New.
14081 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
14082 (ST_REGENTRY): New.
14083 (i386_st_collect_regmap): New.
14084 (i386_NUM_ST_COLLECT_GREGS): New.
14085 (supply_static_tracepoint_registers): New.
14086 * server.c (handle_query): Handle qXfer:statictrace:read.
14087 <qSupported>: Report support for StaticTracepoints, and
14088 qXfer:statictrace:read features.
14089 * server.h (traceframe_read_sdata)
14090 (supply_static_tracepoint_registers): Declare.
14091 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
14092 (unpack_varlen_hex): Include in IPA build.
14093 * Makefile.in (ustlibs, ustinc): New.
14094 (IPA_OBJS): Add remote-utils-ipa.o.
14095 ($(IPA_LIB)): Link -ldl and -lpthread.
14097 (IPAGENT_CFLAGS): Add UST_CFLAGS.
14098 * config.in, configure: Regenerate.
14100 2010-06-20 Ian Lance Taylor <iant@google.com>
14101 Pedro Alves <pedro@codesourcery.com>
14103 * linux-x86-low.c (always_true): Delete.
14104 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
14105 trying to fool the compiler with always_true.
14107 2010-06-20 Pedro Alves <pedro@codesourcery.com>
14109 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
14110 conditions in gdbserver.
14112 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
14114 * spu-low.c (spu_read_memory): Wrap around local store limit.
14115 (spu_write_memory): Likewise.
14117 2010-06-15 Pedro Alves <pedro@codesourcery.com>
14119 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
14120 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
14122 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
14124 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
14125 uses with LONGEST uses.
14127 2010-06-14 Stan Shebs <stan@codesourcery.com>
14128 Pedro Alves <pedro@codesourcery.com>
14132 * linux-x86-low.c: Include limits.h.
14134 (always_true): New.
14137 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
14138 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
14139 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
14140 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
14141 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
14142 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
14143 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
14144 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
14145 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
14146 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
14147 (amd64_emit_void_call_2): New.
14148 (amd64_emit_ops): New.
14149 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
14150 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
14151 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
14152 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
14153 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
14154 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
14155 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
14156 (i386_emit_call, i386_emit_reg, i386_emit_pop)
14157 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
14158 (i386_emit_stack_adjust, i386_emit_int_call_1)
14159 (i386_emit_void_call_2): New.
14160 (i386_emit_ops): New.
14161 (x86_emit_ops): New.
14162 (the_low_target): Install x86_emit_ops.
14163 * server.h (struct emit_ops): New.
14164 (get_raw_reg_func_addr): Declare.
14165 (current_insn_ptr, emit_error): Declare.
14166 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
14167 (set_trace_state_variable_value): New defines.
14168 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
14169 addr_get_trace_state_variable_value and
14170 addr_set_trace_state_variable_value.
14171 (symbol_list): New fields for get_raw_reg,
14172 get_trace_state_variable_value and set_trace_state_variable_value.
14173 (condfn): New typedef.
14174 (struct tracepoint): New field `compiled_cond'.
14175 (do_action_at_tracepoint): Clear compiled_cond.
14176 (get_trace_state_variable_value, set_trace_state_variable_value):
14178 (condition_true_at_tracepoint): If there's a compiled condition,
14180 (current_insn_ptr, emit_error): New globals.
14181 (struct bytecode_address): New.
14182 (get_raw_reg_func_addr): New.
14183 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
14184 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
14185 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
14186 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
14187 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
14188 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
14189 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
14190 (compile_tracepoint_condition, compile_bytecodes): New.
14191 * target.h (emit_ops): Forward declare.
14192 (struct target_ops): New field emit_ops.
14193 (target_emit_ops): New.
14194 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
14195 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
14196 * linux-low.c (linux_emit_ops): New.
14197 (linux_target_ops): Install it.
14198 * linux-low.h (struct linux_target_ops): New field emit_ops.
14200 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
14202 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
14203 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
14205 2010-06-01 Pedro Alves <pedro@codesourcery.com>
14206 Stan Shebs <stan@codesourcery.com>
14208 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
14209 (all): Depend on $(extra_libraries).
14210 (install-only): Install the IPA.
14211 (IPA_OBJS, IPA_LIB): New.
14212 (clean): Remove the IPA lib.
14213 (IPAGENT_CFLAGS): New.
14214 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
14215 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
14216 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
14217 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
14218 * configure.ac: Check for atomic builtins support in the compiler.
14219 (IPA_DEPFILES, extra_libraries): Define.
14220 * configure.srv (ipa_obj): Add description.
14221 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
14222 (i[34567]86-*-linux*): Set ipa_obj.
14223 (x86_64-*-linux*): Set ipa_obj.
14224 * linux-low.c (stabilizing_threads): New.
14225 (supports_fast_tracepoints): New.
14226 (linux_detach): Stabilize threads before detaching.
14227 (handle_tracepoints): Handle internal tracing breakpoints. Assert
14228 the lwp is either not stabilizing, or is moving out of a jump pad.
14229 (linux_fast_tracepoint_collecting): New.
14230 (maybe_move_out_of_jump_pad): New.
14231 (enqueue_one_deferred_signal): New.
14232 (dequeue_one_deferred_signal): New.
14233 (linux_wait_for_event_1): If moving out of a jump pad, defer
14234 pending signals to later.
14235 (linux_stabilize_threads): New.
14236 (linux_wait_1): Check if threads need moving out of jump pads, and
14238 (stuck_in_jump_pad_callback): New.
14239 (move_out_of_jump_pad_callback): New.
14240 (lwp_running): New.
14241 (linux_resume_one_lwp): Handle moving out of jump pads.
14242 (linux_set_resume_request): Dequeue deferred signals.
14243 (need_step_over_p): Also step over fast tracepoint jumps.
14244 (start_step_over): Also uninsert fast tracepoint jumps.
14245 (finish_step_over): Also reinsert fast tracepoint jumps.
14246 (linux_install_fast_tracepoint_jump): New.
14247 (linux_target_ops): Install linux_stabilize_threads and
14248 linux_install_fast_tracepoint_jump_pad.
14249 * linux-low.h (linux_target_ops) <get_thread_area,
14250 install_fast_tracepoint_jump_pad>: New fields.
14251 (struct lwp_info) <collecting_fast_tracepoint,
14252 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
14253 (linux_get_thread_area): Declare.
14254 * linux-x86-low.c (jump_insn): New.
14255 (x86_get_thread_area): New.
14256 (append_insns): New.
14257 (push_opcode): New.
14258 (amd64_install_fast_tracepoint_jump_pad): New.
14259 (i386_install_fast_tracepoint_jump_pad): New.
14260 (x86_install_fast_tracepoint_jump_pad): New.
14261 (the_low_target): Install x86_get_thread_area and
14262 x86_install_fast_tracepoint_jump_pad.
14263 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
14264 (struct fast_tracepoint_jump): New.
14265 (fast_tracepoint_jump_insn): New.
14266 (fast_tracepoint_jump_shadow): New.
14267 (find_fast_tracepoint_jump_at): New.
14268 (fast_tracepoint_jump_here): New.
14269 (delete_fast_tracepoint_jump): New.
14270 (set_fast_tracepoint_jump): New.
14271 (uninsert_fast_tracepoint_jumps_at): New.
14272 (reinsert_fast_tracepoint_jumps_at): New.
14273 (set_breakpoint_at): Use write_inferior_memory.
14274 (uninsert_raw_breakpoint): Use write_inferior_memory.
14275 (check_mem_read): Mask out fast tracepoint jumps.
14276 (check_mem_write): Mask out fast tracepoint jumps.
14277 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
14278 (set_fast_tracepoint_jump): Declare.
14279 (delete_fast_tracepoint_jump)
14280 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
14281 (reinsert_fast_tracepoint_jumps_at): Declare.
14282 * regcache.c: Don't compile many functions when building the
14283 in-process agent library.
14284 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
14285 the register buffer in the heap.
14286 (free_register_cache): If the register buffer isn't owned by the
14287 regcache, don't free it.
14288 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
14289 pre-existing register caches.
14290 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
14292 (convert_ascii_to_int): : Constify `from' parameter type.
14293 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
14294 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
14295 the needed buffer in-place.
14296 (relocate_instruction): New.
14297 * server.c (handle_query) <qSymbols>: If the target supports
14298 tracepoints, give it a chance of looking up symbols. Report
14299 support for fast tracepoints.
14300 (handle_status): Stabilize threads.
14301 (process_serial_event): Adjust.
14302 * server.h (struct fast_tracepoint_jump): Forward declare.
14303 (struct process_info) <fast_tracepoint_jumps>: New field.
14304 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
14305 (decode_X_packet, decode_M_packet): Adjust.
14306 (relocate_instruction): Declare.
14307 (in_process_agent_loaded): Declare.
14308 (tracepoint_look_up_symbols): Declare.
14309 (struct fast_tpoint_collect_status): Declare.
14310 (fast_tracepoint_collecting): Declare.
14311 (force_unlock_trace_buffer): Declare.
14312 (handle_tracepoint_bkpts): Declare.
14313 (initialize_low_tracepoint)
14314 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
14315 * target.h (struct target_ops) <stabilize_threads,
14316 install_fast_tracepoint_jump_pad>: New fields.
14317 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
14318 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
14319 [HAVE_STDINT_H]: Include stdint.h.
14320 (trace_debug_1): Rename to ...
14321 (trace_vdebug): ... this.
14322 (trace_debug): Rename to ...
14323 (trace_debug_1): ... this. Add `level' parameter.
14324 (trace_debug): New.
14325 (ATTR_USED, ATTR_NOINLINE): New.
14326 (IP_AGENT_EXPORT): New.
14327 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
14328 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
14329 (about_to_request_buffer_space, trace_buffer_is_full)
14330 (stopping_tracepoint, expr_eval_result, error_tracepoint)
14331 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
14332 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
14333 (traceframe_write_count, traceframes_created)
14334 (trace_state_variables)
14335 New renaming defines.
14336 (struct ipa_sym_addresses): New.
14337 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
14338 (symbol_list): New.
14339 (ipa_sym_addrs): New.
14340 (all_tracepoint_symbols_looked_up): New.
14341 (in_process_agent_loaded): New.
14342 (write_e_ipa_not_loaded): New.
14343 (maybe_write_ipa_not_loaded): New.
14344 (tracepoint_look_up_symbols): New.
14345 (debug_threads) [IN_PROCESS_AGENT]: New.
14346 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
14347 (UNKNOWN_SIDE_EFFECTS): New.
14348 (stop_tracing): New.
14349 (flush_trace_buffer): New.
14350 (stop_tracing_bkpt): New.
14351 (flush_trace_buffer_bkpt): New.
14352 (read_inferior_integer): New.
14353 (read_inferior_uinteger): New.
14354 (read_inferior_data_pointer): New.
14355 (write_inferior_data_pointer): New.
14356 (write_inferior_integer): New.
14357 (write_inferior_uinteger): New.
14358 (struct collect_static_trace_data_action): Delete.
14359 (enum tracepoint_type): New.
14360 (struct tracepoint) <type>: New field `type'.
14361 <actions_str, step_actions, step_actions_str>: Only include in
14363 <orig_size, obj_addr_on_target, adjusted_insn_addr>
14364 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
14365 (tracepoints): Use IP_AGENT_EXPORT.
14366 (last_tracepoint): Don't include in the IPA.
14367 (stopping_tracepoint): Use IP_AGENT_EXPORT.
14368 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
14369 (alloced_trace_state_variables): New.
14370 (trace_state_variables): Use IP_AGENT_EXPORT.
14371 (traceframe_t): Delete unused variable.
14372 (circular_trace_buffer): Don't include in the IPA.
14373 (trace_buffer_start): Delete.
14374 (struct trace_buffer_control): New.
14375 (trace_buffer_free): Delete.
14376 (struct ipa_trace_buffer_control): New.
14377 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
14378 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
14380 (trace_buffer_ctrl): New.
14381 (TRACE_BUFFER_CTRL_CURR): New.
14382 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
14383 Reimplement as macros.
14384 (trace_buffer_wrap): Delete.
14385 (traceframe_write_count, traceframe_read_count)
14386 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
14387 (struct tracepoint_hit_ctx) <type>: New field.
14388 (struct fast_tracepoint_ctx): New.
14389 (memory_barrier): New.
14391 (record_tracepoint_error): Update atomically in the IPA.
14392 (clear_inferior_trace_buffer): New.
14393 (about_to_request_buffer_space): New.
14394 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
14395 updating the same buffer.
14396 (add_tracepoint): Default the tracepoint's type to trap
14397 tracepoint, and orig_size to -1.
14398 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
14399 internal variables.
14400 (create_trace_state_variable): New parameter `gdb'. Handle it.
14401 (clear_installed_tracepoints): Clear fast tracepoint jumps.
14402 (cmd_qtdp): Handle fast tracepoints.
14403 (cmd_qtdv): Adjust.
14404 (max_jump_pad_size): New.
14405 (gdb_jump_pad_head): New.
14406 (get_jump_space_head): New.
14407 (claim_jump_space): New.
14408 (sort_tracepoints): New.
14409 (MAX_JUMP_SIZE): New.
14410 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
14412 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
14413 support. Upload fast traceframes, and delete internal IPA
14415 (stop_tracing_handler): New.
14416 (flush_trace_buffer_handler): New.
14417 (cmd_qtstop): Upload fast tracepoints.
14418 (response_tracepoint): Handle fast tracepoints.
14419 (tracepoint_finished_step): Upload fast traceframes. Set the
14420 tracepoint hit context's tracepoint type.
14421 (handle_tracepoint_bkpts): New.
14422 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
14423 type. Add comment about fast tracepoints.
14424 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
14425 non-existing action_str field.
14426 (get_context_regcache): Handle fast tracepoints.
14427 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
14429 (fast_tracepoint_from_jump_pad_address): New.
14430 (fast_tracepoint_from_ipa_tpoint_address): New.
14431 (collecting_t): New.
14432 (force_unlock_trace_buffer): New.
14433 (fast_tracepoint_collecting): New.
14435 (gdb_collect): New.
14436 (write_inferior_data_ptr): New.
14437 (target_tp_heap): New.
14438 (target_malloc): New.
14439 (download_agent_expr): New.
14441 (download_tracepoints): New.
14442 (download_trace_state_variables): New.
14443 (upload_fast_traceframes): New.
14444 (IPA_FIRST_TRACEFRAME): New.
14445 (IPA_NEXT_TRACEFRAME_1): New.
14446 (IPA_NEXT_TRACEFRAME): New.
14447 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
14448 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
14449 (gdb_jump_pad_buffer_end): New.
14450 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
14451 (initialize_tracepoint): Adjust.
14452 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
14453 buffer. Initialize the low module.
14454 * utils.c (PREFIX, TOOLNAME): New.
14455 (malloc_failure): Use PREFIX.
14456 (error): In the IPA, an error causes an exit.
14457 (fatal, warning): Use PREFIX.
14458 (internal_error): Use TOOLNAME.
14459 (NUMCELLS): Increase to 10.
14460 * configure, config.in: Regenerate.
14462 2010-06-01 Pedro Alves <pedro@codesourcery.com>
14464 * server.c (handle_query) <qSupported>: Do two passes over the
14465 qSupported string to avoid nesting strtok.
14467 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
14469 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
14471 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
14472 -Wl,--dynamic-list.
14473 * configure: Regenerate.
14474 * proc-service.list: New.
14476 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
14478 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
14481 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
14483 * gdbreplay.c (remote_open): Check error return from socket() call by
14484 its equality to -1 not by it being negative.
14485 * remote-utils.c (remote_open): Likewise.
14487 2010-05-23 Pedro Alves <pedro@codesourcery.com>
14489 * config.h: Regenerate.
14491 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
14493 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
14494 doesn't provide PTRACE_GET_THREAD_AREA.
14496 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
14498 * linux-m68k-low.c: Include <asm/ptrace.h>
14499 (ps_get_thread_area): Implement.
14501 2010-05-03 Doug Evans <dje@google.com>
14503 * event-loop.c (struct callback_event): New struct.
14504 (callback_list): New global.
14505 (append_callback_event, delete_callback_event): New functions.
14506 (process_callback): New function.
14507 (start_event_loop): Call it.
14508 * remote-utils.c (NOT_SCHEDULED): Define.
14509 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
14510 moved out of readchar.
14511 (readchar): Rewrite. Call reschedule before returning.
14512 (reset_readchar): New function.
14513 (remote_close): Call it.
14514 (process_remaining, reschedule): New functions.
14515 * server.h (callback_handler_func): New typedef.
14516 (append_callback_event, delete_callback_event): Declare.
14518 2010-05-03 Pedro Alves <pedro@codesourcery.com>
14520 * proc-service.c (ps_pglobal_lookup): Use
14521 thread_db_look_up_one_symbol.
14522 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
14523 parameter. Use it instead of all_symbols_looked_up.
14524 * server.h (struct process_info) <all_symbols_looked_up>: Delete
14526 (all_symbols_looked_up): Don't declare.
14527 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
14528 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
14530 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
14531 Set all_symbols_looked_up here.
14532 (thread_db_look_up_one_symbol): New.
14533 (thread_db_get_tls_address): Adjust.
14534 (thread_db_load_search, try_thread_db_load_1): Always allocate the
14535 thread_db object on the heap, and tentatively set it in the
14537 (thread_db_init): Don't set all_symbols_looked_up here.
14538 * linux-low.h (thread_db_look_up_one_symbol): Declare.
14540 2010-05-03 Pedro Alves <pedro@codesourcery.com>
14542 * linux-low.c (linux_kill, linux_detach): Adjust.
14543 (status_pending_p_callback): Remove redundant statement. Check
14544 for !TARGET_WAITIKIND_IGNORE, instead of
14545 TARGET_WAITKIND_STOPPED.
14546 (handle_tracepoints): Make sure LWP is locked. Adjust.
14547 (linux_wait_for_event_1): Adjust.
14548 (linux_cancel_breakpoints): New.
14549 (unsuspend_one_lwp): New.
14550 (unsuspend_all_lwps): New.
14551 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
14552 (send_sigstop_callback): Change return type to int, add new
14553 `except' parameter and handle it.
14554 (suspend_and_send_sigstop_callback): New.
14555 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
14556 pass them down. If SUSPEND, also increment the lwp's suspend
14558 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
14559 (need_step_over_p): Don't consider suspended LWPs.
14560 (start_step_over): Adjust.
14561 (proceed_one_lwp): Change return type to int, add new `except'
14562 parameter and handle it.
14563 (unsuspend_and_proceed_one_lwp): New.
14564 (proceed_all_lwps): Use find_inferior instead of
14566 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
14567 also decrement the suspend count of LWPs. Pass `except' down,
14568 instead of hacking its suspend count.
14569 (linux_pause_all): Add `freeze' parameter. Adjust.
14570 (linux_unpause_all): New.
14571 (linux_target_ops): Install linux_unpause_all.
14572 * server.c (handle_status): Adjust.
14573 * target.h (struct target_ops): New fields `unpause_all' and
14574 `cancel_breakpoints'. Add new parameter to `pause_all'.
14575 (pause_all): Add new `freeze' parameter.
14576 (unpause_all): New.
14577 (cancel_breakpoints): New.
14578 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
14579 cancel breakpoints.
14580 (cmd_qtstart): Pause threads.
14581 (stop_tracing): Pause threads, and cancel breakpoints.
14582 * win32-low.c (win32_target_ops): Adjust.
14584 2010-05-03 Pedro Alves <pedro@codesourcery.com>
14586 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
14587 the inferior right away from here...
14588 (linux_wait_1): ... to here, and adjust to check the thread's
14589 last_resume_kind instead of the lwp's step or stop_expected flags.
14591 2010-05-02 Pedro Alves <pedro@codesourcery.com>
14593 * README: Use consistent `GDB' and `GDBserver' spellings.
14595 2010-05-02 Pedro Alves <pedro@codesourcery.com>
14597 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
14598 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
14599 (linux_detach_one_lwp): Assume the lwp is stopped.
14600 (any_thread_of): Delete.
14601 (linux_detach): Stop all lwps here. Don't blindly delete all
14603 (delete_lwp_callback): New.
14604 (linux_mourn): Delete all lwps of the process that is gone.
14605 (linux_wait_1): Don't delete the last lwp of the process here.
14606 * mem-break.h (mark_breakpoints_out): Declare.
14607 * mem-break.c (mark_breakpoints_out): New.
14608 (free_all_breakpoints): Use it.
14609 * server.c (handle_target_event): If the process is gone, mark
14611 * thread-db.c (struct thread_db) <create_bp>: New field.
14612 (thread_db_enable_reporting): Fix prototype. Store a thread event
14613 breakpoint reference in the thread_db struct.
14614 (thread_db_load_search): Clear the thread_db object.
14615 (try_thread_db_load_1): Ditto.
14616 (switch_to_process): New.
14617 (disable_thread_event_reporting): Use it.
14618 (remove_thread_event_breakpoints): New.
14619 (thread_db_detach, thread_db_mourn): Use it.
14621 2010-05-01 Pedro Alves <pedro@codesourcery.com>
14623 * linux-low.c (linux_enable_event_reporting): New.
14624 (linux_wait_for_event_1, handle_extended_wait): Use it.
14626 2010-04-30 Pedro Alves <pedro@codesourcery.com>
14628 * linux-low.c (linux_kill_one_lwp, linux_kill)
14629 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
14630 (send_sigstop): Take an lwp_info as parameter instead. Queue a
14631 SIGSTOP even if the LWP is stopped.
14632 (send_sigstop_callback): New.
14633 (stop_all_lwps): Use send_sigstop_callback instead.
14634 (linux_resume_one_thread): Adjust.
14635 (proceed_one_lwp): Still proceed an LWP that the client has
14636 requested to stop, if we haven't reported it as stopped yet. Make
14637 sure that LWPs the client want stopped, have a pending SIGSTOP.
14639 2010-04-26 Doug Evans <dje@google.com>
14641 * server.c (handle_general_set): Make static.
14643 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
14644 Print received char after testing for error/eof instead of before.
14645 (input_interrupt): Tweak comment.
14647 2010-04-23 Doug Evans <dje@google.com>
14649 * server.c (start_inferior): Print inferior argv if --debug.
14651 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
14653 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
14654 * nto-x86-low.c: Include server.h
14656 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
14658 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
14659 be consistent with other sources of this directory.
14660 (init_registers_amd64): Correct name of source file of this function
14663 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
14665 * configure.srv (x86_64-*-mingw*): New configuration for Windows
14666 64-bit executables.
14668 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
14670 * win32-i386-low.c: Add 64-bit support.
14671 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
14672 (init_registers_amd64): Declare.
14673 (mappings): Add 64-bit version of array.
14674 (init_windows_x86): New function.
14675 (the_low_target): Change init_arch field to init_windows_x86.
14677 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
14679 * win32-low.c: Adapt to support also 64-bit architecture.
14680 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
14681 (get_image_name): Use SIZE_T type for local variable `done'.
14682 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
14683 (toolhelp_get_dll_name): Idem.
14684 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
14685 Use uintptr_t typecast to avoid warning.
14686 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
14687 (handle_exception): Use phex_nz to avoid warning.
14688 (win32_wait): Remove unused local variable `process'.
14690 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
14692 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
14695 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
14697 * configure.ac: Use `ws2_32' library for srv_mingw.
14698 * configure: Regenerate.
14699 * gdbreplay.c: Include winsock2.h instead of winsock.h.
14700 * remote-utils.c: Likewise.
14702 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
14704 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
14705 if __x86_64__ is defined.
14707 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
14709 * configure: Regenerate.
14711 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
14713 * server.c (handle_query): Handle 'qGetTIBAddr' query.
14714 * target.h (target_ops): New get_tib_address field.
14715 * win32-low.h (win32_thread_info): Add thread_local_base field.
14716 * win32-low.c (child_add_thread): Add tlb argument.
14717 Set thread_local_base field to TLB.
14718 (get_child_debug_event): Adapt to child_add_thread change.
14719 (win32_get_tib_address): New function.
14720 (win32_target_ops): Set get_tib_address field to
14721 win32_get_tib_address.
14722 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
14724 2010-04-12 Pedro Alves <pedro@codesourcery.com>
14726 * linux-low.c (linux_mourn): Also remove the process.
14727 * server.c (handle_target_event): Don't remove the process here.
14728 * nto-low.c (nto_mourn): New.
14729 (nto_target_ops): Install it.
14730 * spu-low.c (spu_mourn): New.
14731 (spu_target_ops): Install it.
14732 * win32-low.c (win32_mourn): New.
14733 (win32_target_ops): Install it.
14735 2010-04-12 Pedro Alves <pedro@codesourcery.com>
14737 * server.h (buffer_xml_printf): Remove redundant `;'.
14739 2010-04-12 Pedro Alves <pedro@codesourcery.com>
14741 * regcache.c (set_register_cache): Invalidate regcaches before
14742 changing the register cache layout.
14743 (regcache_invalidate_one): Allow a NULL regcache.
14744 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
14745 regcaches before changing the register cache layout or the target
14748 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
14750 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
14751 variable warning on Linux/x86-64.
14753 2010-04-11 Pedro Alves <pedro@codesourcery.com>
14755 GDBserver disconnected tracing support.
14757 * linux-low.c (linux_remove_process): Delete.
14758 (add_lwp): Don't set last_resume_kind here.
14759 (linux_kill): Use `mourn'.
14760 (linux_detach): Use `thread_db_detach', and `mourn'.
14761 (linux_mourn): New.
14762 (linux_attach_lwp_1): Adjust comment.
14763 (linux_attach): last_resume_kind moved the thread_info; adjust.
14764 (status_pending_p_callback): Adjust.
14765 (linux_wait_for_event_1): Adjust.
14766 (count_events_callback, select_singlestep_lwp_callback)
14767 (select_event_lwp_callback, cancel_breakpoints_callback)
14768 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
14769 (proceed_one_lwp): Adjust.
14770 (linux_async): Add debug output.
14771 (linux_thread_stopped): New.
14772 (linux_pause_all): New.
14773 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
14775 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
14776 (thread_db_free): Delete declaration.
14777 (thread_db_detach, thread_db_mourn): Declare.
14778 * thread-db.c (thread_db_init): Use thread_db_mourn.
14779 (thread_db_free): Delete, split in two.
14780 (disable_thread_event_reporting): New.
14781 (thread_db_detach): New.
14782 (thread_db_mourn): New.
14784 * server.h (struct thread_info) <last_resume_kind>: New field.
14785 <attached>: Add comment.
14786 <gdb_detached>: New field.
14787 (handler_func): Change return type to int.
14788 (handle_serial_event, handle_target_event): Ditto.
14789 (gdb_connected): Declare.
14791 (disconnected_tracing): Declare.
14792 (stop_tracing): Declare.
14794 * server.c (handle_query) <qSupported>: Report support for
14795 disconnected tracing.
14796 (queue_stop_reply_callback): Account for running threads.
14797 (gdb_wants_thread_stopped): New.
14798 (gdb_wants_all_threads_stopped): New.
14799 (gdb_reattached_process): New.
14800 (handle_status): Clear the `gdb_detached' flag of all processes.
14801 In all-stop, stop all threads.
14802 (main): Be sure to leave tfind mode. Handle disconnected tracing.
14803 (process_serial_event): If the remote connection breaks, or if an
14804 exit was forced with "monitor exit", force an event loop exit.
14805 Handle disconnected tracing on detach.
14806 (handle_serial_event): Adjust.
14807 (handle_target_event): If GDB isn't connected, forward events back
14808 to the inferior, unless the last process exited, in which case,
14809 exit gdbserver. Adjust interface.
14811 * remote-utils.c (remote_open): Don't block in accept. Instead
14812 register an event loop source on the listen socket file
14813 descriptor. Refactor bits into ...
14814 (listen_desc): ... this new global.
14815 (gdb_connected): ... this new function.
14816 (enable_async_notification): ... this new function.
14817 (handle_accept_event): ... this new function.
14818 (remote_close): Clear remote_desc.
14820 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
14822 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
14824 (mourn_inferior): Define.
14825 (target_process_qsupported): Avoid the dangling else problem.
14826 (thread_stopped): Define.
14827 (pause_all): Define.
14828 (target_waitstatus_to_string): Declare.
14829 * target.c (target_waitstatus_to_string): New.
14831 * tracepoint.c (tracing): Make extern.
14832 (disconnected_tracing): New.
14833 (stop_tracing): Make extern. Handle tracing stops due to GDB
14835 (cmd_qtdisconnected): New.
14836 (cmd_qtstatus): Report disconnected tracing status in trace reply.
14837 (handle_tracepoint_general_set): Handle QTDisconnected.
14839 * event-loop.c (event_handler_func): Change return type to int.
14840 (process_event): Bail out if the event handler wants the event
14842 (handle_file_event): Ditto.
14843 (start_event_loop): Bail out if the event handler wants the event
14846 * nto-low.c (nto_target_ops): Adjust.
14847 * spu-low.c (spu_wait): Don't remove the process here.
14848 (spu_target_ops): Adjust.
14849 * win32-low.c (win32_wait): Don't remove the process here.
14850 (win32_target_ops): Adjust.
14852 2010-04-11 Pedro Alves <pedro@codesourcery.com>
14854 * regcache.c (realloc_register_cache): Invalidate inferior's
14855 regcache before recreating it.
14857 2010-04-09 Pedro Alves <pedro@codesourcery.com>
14859 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
14861 2010-04-09 Stan Shebs <stan@codesourcery.com>
14862 Pedro Alves <pedro@codesourcery.com>
14864 * server.h (LONGEST): New.
14865 (struct thread_info) <while_stepping>: New field.
14866 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
14868 (initialize_tracepoint, handle_tracepoint_general_set)
14869 (handle_tracepoint_query, tracepoint_finished_step)
14870 (tracepoint_was_hit, release_while_stepping_state_list):
14871 (current_traceframe): Declare.
14872 * server.c (handle_general_set): Handle tracepoint packets.
14873 (read_memory): New.
14874 (write_memory): New.
14875 (handle_search_memory_1): Use read_memory.
14876 (handle_query): Report support for conditional tracepoints, trace
14877 state variables, and tracepoint sources. Handle tracepoint
14879 (main): Initialize the tracepoints module.
14880 (process_serial_event): Handle traceframe reads/writes.
14882 * linux-low.c (handle_tracepoints): New.
14883 (linux_wait_1): Call it.
14884 (linux_resume_one_lwp): Handle while-stepping.
14885 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
14886 (linux_target_ops): Install them.
14887 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
14889 * linux-x86-low.c (x86_supports_tracepoints): New.
14890 (the_low_target). Install it.
14892 * mem-break.h (delete_breakpoint): Declare.
14893 * mem-break.c (delete_breakpoint): Make external.
14895 * target.h (struct target_ops): Add `supports_tracepoints',
14896 `read_pc', and `write_pc' fields.
14897 (target_supports_tracepoints): Define.
14898 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
14901 * regcache.h (struct regcache) <registers_owned>: New field.
14902 (init_register_cache, regcache_cpy): Declare.
14903 (regcache_read_pc, regcache_write_pc): Declare.
14904 (register_cache_size): Declare.
14905 (supply_regblock): Declare.
14906 * regcache.c (init_register_cache): New.
14907 (new_register_cache): Use it.
14908 (regcache_cpy): New.
14909 (register_cache_size): New.
14910 (supply_regblock): New.
14911 (regcache_read_pc, regcache_write_pc): New.
14913 * tracepoint.c: New.
14915 * Makefile.in (OBS): Add tracepoint.o.
14916 (tracepoint.o): New rule.
14918 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
14920 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
14922 (i386-mmx.c): Likewise.
14923 (i386-mmx-linux.o): Likewise.
14924 (i386-mmx-linux.c): Likewise.
14926 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
14927 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
14928 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
14929 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
14931 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
14932 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
14933 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
14935 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
14937 * Makefile.in (clean): Updated.
14939 (i386-avx.c): Likewise.
14940 (i386-avx-linux.o): Likewise.
14941 (i386-avx-linux.c): Likewise.
14942 (amd64-avx.o): Likewise.
14943 (amd64-avx.c): Likewise.
14944 (amd64-avx-linux.o): Likewise.
14945 (amd64-avx-linux.c): Likewise.
14947 * configure.srv (srv_i386_regobj): Add i386-avx.o.
14948 (srv_i386_linux_regobj): Add i386-avx-linux.o.
14949 (srv_amd64_regobj): Add amd64-avx.o.
14950 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
14951 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
14952 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
14953 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
14954 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
14955 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
14956 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
14958 * i387-fp.c: Include "i386-xstate.h".
14960 (i387_cache_to_xsave): Likewise.
14961 (i387_xsave_to_cache): Likewise.
14962 (x86_xcr0): Likewise.
14964 * i387-fp.h (i387_cache_to_xsave): Likewise.
14965 (i387_xsave_to_cache): Likewise.
14966 (x86_xcr0): Likewise.
14968 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
14969 * linux-crisv32-low.c (target_regsets): Likewise.
14970 * linux-m68k-low.c (target_regsets): Likewise.
14971 * linux-mips-low.c (target_regsets): Likewise.
14972 * linux-ppc-low.c (target_regsets): Likewise.
14973 * linux-s390-low.c (target_regsets): Likewise.
14974 * linux-sh-low.c (target_regsets): Likewise.
14975 * linux-sparc-low.c (target_regsets): Likewise.
14976 * linux-xtensa-low.c (target_regsets): Likewise.
14978 * linux-low.c: Include <sys/uio.h>.
14979 (regsets_fetch_inferior_registers): Support nt_type.
14980 (regsets_store_inferior_registers): Likewise.
14981 (linux_process_qsupported): New.
14982 (linux_target_ops): Add linux_process_qsupported.
14984 * linux-low.h (regset_info): Add nt_type.
14985 (linux_target_ops): Add process_qsupported.
14987 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
14989 (init_registers_i386_avx_linux): New.
14990 (init_registers_amd64_avx_linux): Likewise.
14991 (xmltarget_i386_linux_no_xml): Likewise.
14992 (xmltarget_amd64_linux_no_xml): Likewise.
14993 (PTRACE_GETREGSET): Likewise.
14994 (PTRACE_SETREGSET): Likewise.
14995 (x86_fill_xstateregset): Likewise.
14996 (x86_store_xstateregset): Likewise.
14997 (use_xml): Likewise.
14998 (x86_linux_update_xmltarget): Likewise.
14999 (x86_linux_process_qsupported): Likewise.
15000 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
15001 (x86_arch_setup): Don't call init_registers_amd64_linux nor
15002 init_registers_i386_linux here. Call
15003 x86_linux_update_xmltarget.
15004 (the_low_target): Add x86_linux_process_qsupported.
15006 * server.c (handle_query): Call target_process_qsupported.
15008 * target.h (target_ops): Add process_qsupported.
15009 (target_process_qsupported): New.
15011 2010-04-03 Pedro Alves <pedro@codesourcery.com>
15013 * inferiors.c (add_thread): Set last_status kind to
15014 TARGET_WAITKIND_IGNORE.
15015 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
15016 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
15017 (linux_wait_1): Move `thread' local definition to block that uses
15018 it. Don't NULL initialize `event_child'.
15019 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
15020 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
15021 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
15023 2010-04-01 Pedro Alves <pedro@codesourcery.com>
15025 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
15026 an extended waitstatus, or by a watchpoint.
15027 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
15028 thread was stepping or has been stopped by a watchpoint.
15030 2010-04-01 Pedro Alves <pedro@codesourcery.com>
15032 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
15033 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
15034 of another, then delete the previous, and validate all
15036 (validate_inserted_breakpoint): New.
15037 (delete_disabled_breakpoints): New.
15038 (validate_breakpoints): New.
15039 (check_mem_read): Validate breakpoints before trusting their
15040 shadow. Delete disabled breakpoints.
15041 (check_mem_write): Validate breakpoints before trusting they
15042 should be inserted. Delete disabled breakpoints.
15043 * mem-break.h (validate_breakpoints):
15044 * server.c (handle_query): Validate breakpoints when we see a
15047 2010-04-01 Pedro Alves <pedro@codesourcery.com>
15049 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
15050 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
15051 if we could tell there's a GDB breakpoint at stop_pc.
15052 (need_step_over_p): Don't do a step over if we find a GDB
15053 breakpoint at the resume PC.
15055 * mem-break.c (struct raw_breakpoint): New.
15056 (enum bkpt_type): New type `gdb_breakpoint'.
15057 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
15058 fields. New field `raw'.
15059 (find_raw_breakpoint_at): New.
15060 (set_raw_breakpoint_at): Handle refcounting. Create a raw
15061 breakpoint instead.
15062 (set_breakpoint_at): Adjust.
15063 (delete_raw_breakpoint): New.
15064 (release_breakpoint): New.
15065 (delete_breakpoint): Rename to...
15066 (delete_breakpoint_1): ... this. Add proc parameter. Use
15067 release_breakpoint. Return ENOENT.
15068 (delete_breakpoint): Reimplement.
15069 (find_breakpoint_at): Delete.
15070 (find_gdb_breakpoint_at): New.
15071 (delete_breakpoint_at): Delete.
15072 (set_gdb_breakpoint_at): New.
15073 (delete_gdb_breakpoint_at): New.
15074 (gdb_breakpoint_here): New.
15075 (set_reinsert_breakpoint): Use release_breakpoint.
15076 (uninsert_breakpoint): Rename to ...
15077 (uninsert_raw_breakpoint): ... this.
15078 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
15079 (reinsert_raw_breakpoint): Change parameter type to
15081 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
15083 (check_breakpoints): Adjust. Use release_breakpoint.
15084 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
15085 (breakpoint_inserted_here): Ditto.
15086 (check_mem_read): Adjust to iterate over raw breakpoints instead.
15087 Don't trust the breakpoint's shadow if it is not inserted.
15088 (check_mem_write): Adjust to iterate over raw breakpoints instead.
15089 (delete_all_breakpoints): Adjust.
15090 (free_all_breakpoints): Mark all breakpoints as uninserted, and
15091 use delete_breakpoint_1.
15093 * mem-break.h (breakpoints_supported): Delete declaration.
15094 (set_gdb_breakpoint_at): Declare.
15095 (gdb_breakpoint_here): Declare.
15096 (delete_breakpoint_at): Delete.
15097 (delete_gdb_breakpoint_at): Declare.
15099 * server.h (struct raw_breakpoint): Forward declare.
15100 (struct process_info): New field `raw_breakpoints'.
15102 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
15105 2010-03-24 Pedro Alves <pedro@codesourcery.com>
15107 * linux-low.c (status_pending_p_callback): Fix comment.
15108 (linux_wait_for_event_1): Move most of the internal breakpoint
15109 handling from here...
15110 (linux_wait_1): ... to here.
15111 (count_events_callback): New.
15112 (select_singlestep_lwp_callback): New.
15113 (select_event_lwp_callback): New.
15114 (cancel_breakpoints_callback): New.
15115 (select_event_lwp): New.
15116 (linux_wait_1): Simplify internal breakpoint handling. Give equal
15117 priority to all LWPs that have had events that should be reported
15118 to the client. Cancel breakpoints when about to reporting the
15119 event to the client, not while stopping lwps. No longer cancel
15120 finished single-steps here.
15121 (cancel_finished_single_step): Delete.
15122 (cancel_finished_single_steps): Delete.
15124 2010-03-24 Pedro Alves <pedro@codesourcery.com>
15126 * mem-break.c (enum bkpt_type): New.
15127 (struct breakpoint): New field `type'.
15128 (set_breakpoint_at): Change return type to struct breakpoint
15129 pointer. Set type to `other_breakpoint' by default.
15130 (delete_breakpoint): Rewrite, supporting more than one breakpoint
15131 in the breakpoint list.
15132 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
15133 (reinsert_breakpoint): Rename to ...
15134 (reinsert_raw_breakpoint): ... this.
15135 (reinsert_breakpoints_at): Adjust.
15136 * mem-break.h (struct breakpoint): Declare.
15137 (set_breakpoint_at): Change return type to struct breakpoint
15140 2010-03-24 Pedro Alves <pedro@codesourcery.com>
15142 * server.c (handle_query): Assign, not compare.
15144 2010-03-24 Pedro Alves <pedro@codesourcery.com>
15146 Teach linux gdbserver to step-over-breakpoints.
15148 * linux-low.c (can_hardware_single_step): New.
15149 (supports_breakpoints): New.
15150 (handle_extended_wait): If stopping threads, read the stop pc of
15151 the new cloned LWP.
15153 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
15154 low target doesn't support retrieving the PC.
15155 (add_lwp): Set last_resume_kind to resume_continue.
15156 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
15157 (linux_attach): Don't clear stop_expected. Set the lwp's
15158 last_resume_kind to resume_stop.
15159 (linux_detach_one_lwp): Don't check for removed breakpoints.
15160 (check_removed_breakpoint): Delete.
15161 (status_pending_p): Rename to ...
15162 (status_pending_p_callback): ... this. Don't check for removed
15163 breakpoints. Don't consider threads that are stopped from GDB's
15165 (linux_wait_for_lwp): Always read the stop_pc here.
15166 (cancel_breakpoint): New.
15167 (step_over_bkpt): New global.
15168 (linux_wait_for_event_1): Implement stepping over breakpoints.
15169 (gdb_wants_lwp_stopped): New.
15170 (gdb_wants_all_stopped): New.
15171 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
15172 single-step traps here. Store the thread's last reported target
15174 (send_sigstop): Don't clear stop_expected. Always set it,
15176 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
15177 (cancel_finished_single_step): New.
15178 (cancel_finished_single_steps): New.
15179 (wait_for_sigstop): Don't cancel finished single-step traps here.
15180 (linux_resume_one_lwp): Don't check for removed breakpoints.
15181 Don't set `step' on non-hardware step archs.
15182 (linux_set_resume_request): Ignore resume_stop requests if already
15183 stopping or stopped. Set the lwp's last_resume_kind.
15184 (resume_status_pending_p): Don't check for removed breakpoints.
15185 (need_step_over_p): New.
15186 (start_step_over): New.
15187 (finish_step_over): New.
15188 (linux_resume_one_thread): Always queue a sigstop for resume_stop
15189 requests. Clear the thread's last reported target waitstatus.
15190 Don't use the `suspended' flag. Don't consider pending breakpoints.
15191 (linux_resume): Start a step-over if necessary.
15192 (proceed_one_lwp): New.
15193 (proceed_all_lwps): New.
15194 (unstop_all_lwps): New.
15195 * linux-low.h (struct lwp_info): Rewrite comment for the
15196 `suspended' flag. Add the `stop_pc' field. Delete the
15197 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
15198 Add `'last_resume_kind' and `need_step_over' fields.
15199 * inferiors.c (struct thread_info): Delete, moved elsewhere.
15200 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
15201 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
15202 (set_raw_breakpoint_at): New.
15203 (set_breakpoint_at): Rewrite to use it.
15204 (reinsert_breakpoint_handler): Delete.
15205 (set_reinsert_breakpoint): New.
15206 (reinsert_breakpoint_by_bp): Delete.
15207 (delete_reinsert_breakpoints): New.
15208 (uninsert_breakpoint): Rewrite.
15209 (uninsert_breakpoints_at): New.
15210 (reinsert_breakpoint): Rewrite.
15211 (reinsert_breakpoints_at): New.
15212 (check_breakpoints): Rewrite.
15213 (breakpoint_here): New.
15214 (breakpoint_inserted_here): New.
15215 (check_mem_read): Adjust.
15216 * mem-break.h (breakpoints_supported, breakpoint_here)
15217 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
15218 (reinsert_breakpoint_by_bp): Delete declaration.
15219 (delete_reinsert_breakpoints): Declare.
15220 (reinsert_breakpoint): Delete declaration.
15221 (reinsert_breakpoints_at): Declare.
15222 (uninsert_breakpoint): Delete declaration.
15223 (uninsert_breakpoints_at): Declare.
15224 (check_breakpoints): Adjust prototype.
15225 * server.h: Adjust include order.
15226 (struct thread_info): Declare here. Add a `last_status' field.
15228 2010-03-23 Michael Snyder <msnyder@vmware.com>
15230 * server.c (crc32): New function.
15231 (handle_query): Add handling for 'qCRC:' request.
15233 2010-03-23 Pedro Alves <pedro@codesourcery.com>
15235 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
15236 lwp had been stopped by a watchpoint.
15238 2010-03-16 Pedro Alves <pedro@codesourcery.com>
15240 * server.h (internal_error): Declare.
15241 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
15242 * utils.c (internal_error): New function.
15244 2010-03-15 Andreas Schwab <schwab@redhat.com>
15246 * configure.srv: Fix typo setting srv_regobj.
15248 2010-03-15 Pedro Alves <pedro@codesourcery.com>
15250 * linux-low.c (fetch_register): Avoid passing a non string literal
15252 (usr_store_inferior_registers): Ditto.
15254 2010-03-14 Pedro Alves <pedro@codesourcery.com>
15256 * linux-low.c (linux_write_memory): Bail out early if peeking
15259 2010-03-14 Pedro Alves <pedro@codesourcery.com>
15261 * linux-low.h (struct lwp_info): New fields
15262 `stopped_by_watchpoint' and `stopped_data_address'.
15263 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
15264 here, and cache them in the lwp object.
15265 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
15267 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
15269 (linux_stopped_by_watchpoint): Rewrite.
15270 (linux_stopped_data_address): Rewrite.
15272 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
15274 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
15275 switching the current inferior, not before.
15277 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
15279 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
15280 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
15281 i386-linux.c and amd64-linux.c.
15282 (reg-i386.o): Removed.
15283 (reg-i386.c): Likewise.
15284 (reg-i386-linux.o): Likewise.
15285 (reg-i386-linux.c): Likewise.
15286 (reg-x86-64.o): Likewise.
15287 (reg-x86-64.c): Likewise.
15288 (reg-x86-64-linux.o): Likewise.
15289 (reg-x86-64-linux.c): Likewise.
15291 (i386.c): Likewise.
15292 (i386-linux.o): Likewise.
15293 (i386-linux.c): Likewise.
15294 (amd64.o): Likewise.
15295 (amd64.c): Likewise.
15296 (amd64-linux.o): Likewise.
15297 (amd64-linux.c): Likewise.
15299 * configure.srv (srv_i386_regobj): New.
15300 (srv_i386_linux_regobj): Likewise.
15301 (srv_amd64_regobj): Likewise.
15302 (srv_amd64_linux_regobj): Likewise.
15303 (srv_i386_32bit_xmlfiles): Likewise.
15304 (srv_i386_64bit_xmlfiles): Likewise.
15305 (srv_i386_xmlfiles): Likewise.
15306 (srv_amd64_xmlfiles): Likewise.
15307 (srv_i386_linux_xmlfiles): Likewise.
15308 (srv_amd64_linux_xmlfiles): Likewise.
15309 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
15310 srv_xmlfiles to $srv_i386_xmlfiles.
15311 (i[34567]86-*-mingw32ce*): Likewise.
15312 (i[34567]86-*-mingw*): Likewise.
15313 (i[34567]86-*-nto*): Likewise.
15314 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
15315 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
15316 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
15317 (x86_64-*-linux*): Likewise.
15319 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
15320 (init_registers_amd64_linux): New.
15321 (x86_arch_setup): Replace init_registers_x86_64_linux with
15322 init_registers_amd64_linux.
15324 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
15326 * configure.ac: Check for libdl. If it is not available link against
15327 static libthread_db.
15328 * configure: Regenerate.
15330 2010-02-22 Pedro Alves <pedro@codesourcery.com>
15334 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
15335 handing a read watchpoint.
15336 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
15338 2010-02-12 Doug Evans <dje@google.com>
15340 * linux-low.c (linux_supports_tracefork_flag): Document.
15341 (linux_look_up_symbols): Add comment.
15343 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
15345 * regcache.c (supply_register): Clear regcache if buf is NULL.
15347 2010-02-02 Nicolas Roche <roche@sourceware.org>
15348 Joel Brobecker <brobecker@adacore.com>
15350 * inferiors.c (find_inferior): Add function documentation.
15351 (unloaded_dll): Handle the case where the unloaded dll has not
15352 been previously registered in the dll list.
15354 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
15356 * linux-arm-low.c (thumb_breakpoint_len): Delete.
15357 (thumb2_breakpoint): New.
15358 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
15360 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
15362 * linux-low.c (get_stop_pc): Check for SIGTRAP.
15363 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
15366 2010-01-21 Pedro Alves <pedro@codesourcery.com>
15368 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
15370 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
15372 * linux-s390-low.c (s390_collect_ptrace_register)
15373 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
15375 2010-01-21 Doug Evans <dje@google.com>
15377 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
15378 (PTRACE_ARG4_TYPE): New macro.
15379 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
15380 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
15381 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
15382 (usr_store_inferior_registers): Ditto.
15383 (linux_read_memory, linux_write_memory): Ditto.
15384 (linux_test_for_tracefork): Ditto.
15386 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
15387 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
15389 2010-01-21 Pedro Alves <pedro@codesourcery.com>
15391 * proc-service.c (ps_lgetregs): Don't refetch registers from the
15394 2010-01-21 Pedro Alves <pedro@codesourcery.com>
15396 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
15397 prototype to take a regcache. Adjust.
15399 2010-01-20 Pedro Alves <pedro@codesourcery.com>
15401 * regcache.h (struct thread_info): Forward declare.
15402 (struct regcache): New.
15403 (new_register_cache): Adjust prototype.
15404 (get_thread_regcache): Declare.
15405 (free_register_cache): Adjust prototype.
15406 (registers_to_string, registers_from_string): Ditto.
15407 (supply_register, supply_register_by_name, collect_register)
15408 (collect_register_as_string, collect_register_by_name): Ditto.
15409 * regcache.c (struct inferior_regcache_data): Delete.
15410 (get_regcache): Rename to ...
15411 (get_thread_regcache): ... this. Adjust. Switch inferior before
15412 fetching registers.
15413 (regcache_invalidate_one): Adjust.
15414 (regcache_invalidate): Fix prototype.
15415 (new_register_cache): Return the new register cache.
15416 (free_register_cache): Change prototype.
15417 (realloc_register_cache): Adjust.
15418 (registers_to_string): Change prototype to take a regcache. Adjust.
15419 (registers_from_string): Ditto.
15420 (register_data): Ditto.
15421 (supply_register): Ditto.
15422 (supply_register_by_name): Ditto.
15423 (collect_register): Ditto.
15424 (collect_register_as_string): Ditto.
15425 (collect_register_by_name): Ditto.
15426 * server.c (process_serial_event): Adjust.
15427 * linux-low.h (regset_fill_func, regset_store_func): Change
15429 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
15431 * linux-low.c (get_stop_pc): Adjust.
15432 (check_removed_breakpoint): Adjust.
15433 (linux_wait_for_event): Adjust.
15434 (linux_resume_one_lwp): Adjust.
15435 (fetch_register): Add regcache parameter. Adjust.
15436 (usr_store_inferior_registers): Ditto.
15437 (regsets_fetch_inferior_registers): Ditto.
15438 (regsets_store_inferior_registers): Ditto.
15439 (linux_fetch_registers, linux_store_registers): Ditto.
15440 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
15442 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
15444 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
15445 prototype to take a regcache.
15446 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
15447 * remote-utils.c (convert_ascii_to_int, outreg)
15448 (prepare_resume_reply): Change prototype to take a regcache.
15450 * target.h (struct target_ops) <fetch_registers, store_registers>:
15451 Change prototype to take a regcache.
15452 (fetch_inferior_registers, store_inferior_registers): Change
15453 prototype to take a regcache. Adjust.
15454 * proc-service.c (ps_lgetregs): Adjust.
15455 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
15456 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
15457 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
15458 take a regcache. Adjust.
15459 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
15460 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
15461 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
15462 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
15463 * linux-cris-low.c (cris_get_pc, cris_set_pc)
15464 (cris_cannot_fetch_register):
15465 (cris_breakpoint_at): Change prototype to take a regcache.
15467 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
15468 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
15469 to take a regcache. Adjust.
15470 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
15472 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
15473 take a regcache. Adjust.
15474 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
15475 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
15476 (m68k_set_pc): Change prototype to take a regcache. Adjust.
15477 * linux-mips-low.c (mips_get_pc):
15478 (mips_set_pc): Change prototype to take a regcache. Adjust.
15479 (mips_reinsert_addr): Adjust.
15480 (mips_collect_register): Change prototype to take a regcache.
15482 (mips_supply_register):
15483 (mips_collect_register_32bit, mips_supply_register_32bit)
15484 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
15485 (mips_store_fpregset): Ditto.
15486 * linux-ppc-low.c (ppc_supply_ptrace_register)
15487 (ppc_supply_ptrace_register): Ditto.
15488 (parse_spufs_run): Adjust.
15489 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
15490 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
15491 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
15492 take a regcache. Adjust.
15493 * linux-s390-low.c (s390_collect_ptrace_register)
15494 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
15495 (s390_set_pc): Change prototype to take a regcache. Adjust.
15496 (s390_arch_setup): Adjust.
15497 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
15498 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
15499 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
15500 (sparc_fill_gregset, sparc_store_gregset_from_stack)
15501 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
15503 (sparc_breakpoint_at): Adjust.
15504 * linux-xtensa-low.c (xtensa_fill_gregset):
15505 (xtensa_store_gregset):
15506 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
15507 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
15508 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
15509 prototype to take a regcache. Adjust.
15510 * win32-arm-low.c (arm_fetch_inferior_register)
15511 (arm_store_inferior_register): Change prototype to take a
15513 * win32-i386-low.c (i386_fetch_inferior_register)
15514 (i386_store_inferior_register): Change prototype to take a
15516 * win32-low.c (child_fetch_inferior_registers)
15517 (child_store_inferior_registers): Change prototype to take a
15519 (win32_wait): Adjust.
15520 (win32_fetch_inferior_registers): Change prototype to take a
15522 (win32_store_inferior_registers): Adjust.
15523 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
15524 store_inferior_register>: Change prototype to take a regcache.
15526 2010-01-20 Doug Evans <dje@google.com>
15528 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
15530 (linux_wait_for_event1, linux_init_signals): Ditto.
15531 (W_STOPCODE): Provide definition if missing.
15533 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
15535 * linux-low.c (linux_core_of_thread): New.
15536 (compare_ints, show_process, list_threads): New.
15537 (linux_qxfer_osdata): Report threads and cores.
15538 (linux_target_op): Register linux_core_of_thread.
15539 * remote-utils.c (prepare_resume_reply): Report the core.
15540 (buffer_xml_printf): Support %d specifier.
15541 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
15543 (handle_query): Handle qXfer:threads. Announce availability
15545 * target.h (struct target_ops): New field core_of_thread.
15547 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
15549 * Makefile.in (clean): Remove new generated files.
15550 (reg-s390.o, reg-s390.c): Remove rules.
15551 (reg-s390x.o, reg-s390x.c): Likewise.
15552 (s390-linux32.o, s390-linux32.c): Add rules.
15553 (s390-linux64.o, s390-linux64.c): Likewise.
15554 (s390x-linux64.o, s390x-linux64.c): Likewise.
15555 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
15556 * linux-s390-low.c: Include <elf.h>.
15557 (HWCAP_S390_HIGH_GPRS): Define if undefined.
15558 (init_registers_s390): Remove prototype.
15559 (init_registers_s390x): Likewise.
15560 (init_registers_s390_linux32): Add prototype.
15561 (init_registers_s390_linux64): Likewise.
15562 (init_registers_s390x_linux64): Likewise.
15563 (s390_num_regs_3264): New define.
15564 (s390_regmap_3264): New global variable.
15565 (s390_cannot_fetch_register): Remove obsolete check.
15566 (s390_cannot_store_register): Likewise.
15567 (s390_collect_ptrace_register): Handle upper/lower register halves.
15568 (s390_supply_ptrace_register): Likewise.
15569 (s390_fill_gregset): Update to register number changes.
15570 (s390_get_hwcap): New routine.
15571 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
15572 Install appropriate regmap and register set.
15574 2010-01-01 Joel Brobecker <brobecker@adacore.com>
15576 * server.c (gdbserver_version): Update copyright year to 2010.
15577 * gdbreplay.c (gdbreplay_version): Likewise.
15579 2009-12-28 Doug Evans <dje@google.com>
15581 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
15582 elf/external.h. Include <elf.h> instead but only if necessary.
15584 2009-12-28 Pedro Alves <pedro@codesourcery.com>
15586 * linux-low.c (linux_remove_process): Remove `detaching'
15587 parameter. Don't release/detach from thread_db here.
15588 (linux_kill): Release/detach from thread_db here, ...
15589 (linux_detach): ... and here, before actually detaching.
15590 (linux_wait_1): ... and here, when a process exits.
15591 * thread-db.c (any_thread_of): New.
15592 (thread_db_free): Switch the current inferior to a thread of the
15595 2009-12-21 Doug Evans <dje@google.com>
15597 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
15599 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
15600 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
15601 warning ifndef __NR_tkill. Move setting of errno there too.
15602 Delete unnecessary resetting of errno after syscall.
15603 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
15605 * configure.ac: Check for dladdr.
15606 * config.in: Regenerate.
15607 * configure: Regenerate.
15608 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
15609 (try_thread_db_load): Update.
15611 * linux-low.c (my_waitpid): Delete unnecessary prototype.
15613 2009-12-18 Doug Evans <dje@google.com>
15615 * event-loop.c: Include unistd.h if it exists.
15617 * linux-low.c (my_waitpid): Move definition away from being in
15618 between linux_tracefork_child/linux_test_for_tracefork.
15620 * gdb_proc_service.h (psaddr_t): Fix type.
15621 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
15622 signature to match glibc.
15624 2009-12-16 Doug Evans <dje@google.com>
15626 * linux-low.c (linux_read_memory): Fix argument to read.
15628 2009-11-26 Pedro Alves <pedro@codesourcery.com>
15630 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
15631 events, don't leave current_inferior pointing at null.
15633 2009-11-26 Pedro Alves <pedro@codesourcery.com>
15635 * win32-low.c (LOG): Delete.
15636 (OUTMSG): Output to stderr.
15637 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
15638 on compile time LOG macro.
15639 (win32_wait): Fix debug output.
15641 2009-11-26 Pedro Alves <pedro@codesourcery.com>
15643 * win32-low.c (win32_add_one_solib): If the dll name is
15644 "ntdll.dll", prepend the system directory to the dll path.
15646 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
15648 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
15650 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
15651 Vladimir Prus <vladimir@codesourcery.com>
15653 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
15654 * configure.ac: Check for __mcoldfire__ and set
15655 gdb_cv_m68k_is_coldfire.
15656 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
15657 reg-cf.o and reg-m68k.o.
15658 * configure: Regenerated.
15660 2009-11-16 Pedro Alves <pedro@codesourcery.com>
15662 * linux-low.c (linux_remove_process): Add `detaching' parameter.
15663 Pass it to thread_db_free.
15664 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
15665 proper `detaching' argument to linux_remove_process.
15666 * linux-low.h (thread_db_free): Add `detaching' parameter.
15667 * thread-db.c (thread_db_init): Pass false as `detaching' argument
15669 (thread_db_free): Add `detaching' parameter. Only
15670 call td_ta_clear_event if detaching from process.
15672 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
15674 * thread-db.c (thread_db_free): Fix typo.
15676 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
15679 * thread-db.c (thread_db_free): Call td_ta_clear_event.
15681 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
15683 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
15684 with an i686 compiler.
15685 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
15687 * configure: Rebuilt.
15689 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
15693 * server.c (handle_search_memory_1): Correct read_addr initialization
15694 in loop for searching subsequent chunks.
15696 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
15698 * configure.ac: New --with-libthread-db option.
15699 * thread-db.c: Allow direct dependence on libthread_db.
15700 (thread_db_free): Adjust.
15701 * config.in: Regenerate.
15702 * configure: Likewise.
15704 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
15707 * thread-db.c (attach_thread): New function.
15708 (maybe_attach_thread): Return success/failure.
15709 (find_new_threads_callback): Adjust.
15710 (thread_db_find_new_threads): Loop until no new threads.
15712 2009-10-13 Pedro Alves <pedro@codesourcery.com>
15714 * proc-service.c (ps_lgetregs): Formatting.
15716 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
15718 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
15719 * configure.ac: Adjust.
15720 * linux-low.h (struct process_info_private): Move members to struct
15722 (thread_db_free, thread_db_handle_monitor_command): New prototype.
15723 * linux-low.c (linux_remove_process): Adjust.
15724 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
15725 * server.c (handle_query): Move code ...
15726 (handle_monitor_command): ... here. New function.
15727 * target.h (struct target_ops): New member.
15728 * thread-db.c (struct thread_db): New.
15729 (libthread_db_search_path): New variable.
15730 (thread_db_create_event, thread_db_enable_reporting)
15731 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
15732 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
15733 (try_thread_db_load_1, dladdr_to_soname): New functions.
15734 (try_thread_db_load, thread_db_load_search): New functions.
15735 (thread_db_init): Search for libthread_db.
15736 (thread_db_free): New function.
15737 (thread_db_handle_monitor_command): Likewise.
15738 * config.in: Regenerate.
15739 * configure: Regenerate.
15741 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
15743 * spu-low.c (spu_kill): Wait for inferior to terminate.
15744 Call clear_inferiors.
15745 (spu_detach): Call clear_inferiors.
15747 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15749 * aclocal.m4: Regenerate.
15750 * config.in: Likewise.
15751 * configure: Likewise.
15753 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
15755 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
15756 (parse_spufs_run): New function.
15757 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
15758 (ppc_breakpoint_at): Handle SPU breakpoints.
15760 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
15762 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
15763 (SPUFS_MAGIC): Define.
15764 (spu_enumerate_spu_ids): New function.
15765 (linux_qxfer_spu): New function.
15766 (linux_target_ops): Install linux_qxfer_spu.
15768 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
15770 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
15771 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
15772 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
15773 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
15774 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
15775 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
15776 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
15777 (init_registers_powerpc_cell32l): Add prototype.
15778 (init_registers_powerpc_cell64l): Likewise.
15779 (ppc_arch_setup): Detect Cell/B.E. architecture.
15781 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15783 * Makefile.in (datarootdir): New variable.
15785 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
15787 * linux-low.c (linux_write_memory): Update debugging output.
15788 * Makefile.in (clean): Add new descriptions.
15789 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
15790 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
15791 * configure.srv: Add new files for arm*-*-linux*.
15792 * linux-arm-low.c: Add new declarations.
15793 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
15794 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
15795 (HWCAP_VFPv3D16): New.
15796 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
15797 instead of __IWMMXT__.
15798 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
15799 (arm_arch_setup): New.
15800 (target_regsets): Remove #ifdef. Add VFP regset.
15801 (the_low_target): Use arm_arch_setup.
15803 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
15805 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
15806 the main thread again.
15808 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
15810 Adding Neutrino gdbserver.
15811 * configure: Regenerated.
15812 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
15813 * configure.srv (i[34567]86-*-nto*): New target.
15814 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
15815 * remote-utils.c [__QNX__]: Include sys/iomgr.h
15816 (nto_comctrl) [__QNX__]: New function.
15817 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
15819 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
15821 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
15824 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
15825 Pedro Alves <pedro@codesourcery.com>
15827 * win32-i386-low.c (i386_get_thread_context): Handle systems that
15828 don't support CONTEXT_EXTENDED_REGISTERS.
15829 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
15830 (the_low_target): Install them.
15831 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
15832 failing with ERROR_PIPE_NOT_CONNECTED.
15834 2009-06-30 Doug Evans <dje@google.com>
15835 Pierre Muller <muller@ics.u-strasbg.fr>
15837 Add h/w watchpoint support to x86-linux, win32-i386.
15838 * Makefile.in (SFILES): Add i386-low.c
15839 (i386_low_h): Define.
15840 (i386-low.o): Add dependencies.
15841 (linux-x86-low.o): Add i386-low.h dependency.
15842 (win32-i386-low.o): Ditto.
15843 * i386-low.c: New file.
15844 * i386-low.h: New file.
15845 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
15846 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
15847 * linux-low.c (linux_add_process): Initialize arch_private.
15848 (linux_remove_process): Free arch_private.
15849 (add_lwp): Initialize arch_private.
15850 (delete_lwp): Free arch_private.
15851 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
15853 * linux-low.h (process_info_private): New member arch_private.
15854 (lwp_info): New member arch_private.
15855 (linux_target_ops): New members new_process, new_thread,
15857 (ptid_of): New macro.
15858 * linux-x86-low.c: Include stddef.h, i386-low.h.
15859 (arch_process_info): New struct.
15860 (arch_lwp_info): New struct.
15861 (x86_linux_dr_get, x86_linux_dr_set): New functions.
15862 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
15863 (i386_dr_low_get_status): New function.
15864 (x86_insert_point, x86_remove_point): New functions.
15865 (x86_stopped_by_watchpoint): New function.
15866 (x86_stopped_data_address): New function.
15867 (x86_linux_new_process, x86_linux_new_thread): New functions.
15868 (x86_linux_prepare_to_resume): New function.
15869 (the_low_target): Add entries for insert_point, remove_point,
15870 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
15872 * server.c (debug_hw_points): New global.
15873 (monitor_show_help): Document set debug-hw-points.
15874 (handle_query): Process "set debug-hw-points".
15875 * server.h (debug_hw_points): Declare.
15876 (paddress): Declare.
15877 * utils.c (NUMCELLS, CELLSIZE): New macros.
15878 (get_sell, xsnprintf, paddress): New functions.
15879 * win32-arm-low.c (the_low_target): Add entries for insert_point,
15880 remove_point, stopped_by_watchpoint, stopped_data_address.
15881 * win32-i386-low.c: Include i386-low.h.
15882 (debug_reg_state): Replaces dr.
15883 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
15884 (i386_dr_low_get_status): New function.
15885 (i386_insert_point, i386_remove_point): New functions.
15886 (i386_stopped_by_watchpoint): New function.
15887 (i386_stopped_data_address): New function.
15888 (i386_initial_stuff): Update.
15889 (get_thread_context,set_thread_context,i386_thread_added): Update.
15890 (the_low_target): Add entries for insert_point,
15891 remove_point, stopped_by_watchpoint, stopped_data_address.
15892 * win32-low.c (win32_insert_watchpoint): New function.
15893 (win32_remove_watchpoint): New function.
15894 (win32_stopped_by_watchpoint): New function.
15895 (win32_stopped_data_address): New function.
15896 (win32_target_ops): Add entries for insert_watchpoint,
15897 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
15898 * win32-low.h (win32_target_ops): New members insert_point,
15899 remove_point, stopped_by_watchpoint, stopped_data_address.
15901 2009-06-25 Pedro Alves <pedro@codesourcery.com>
15903 * server.c (process_serial_event): Re-return unsupported, not
15904 error, if the type isn't recognized. Re-allow supporting only
15905 insert or remove packets. Also call require_running for
15906 breakpoints. Add missing break statement to default case. Tidy.
15907 * target.h (struct target_ops): Rename insert_watchpoint to
15908 insert_point, and remove_watchpoint to remove_point.
15910 * linux-low.h (struct linux_target_ops): Likewise.
15911 * linux-low.c (linux_insert_watchpoint): Rename to ...
15912 (linux_insert_point): ... this. Adjust.
15913 (linux_remove_watchpoint): Rename to ...
15914 (linux_remove_point): ... this. Adjust.
15915 (linux_target_ops): Adjust.
15916 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
15917 (cris_insert_point): ... this.
15918 (cris_remove_watchpoint): Rename to ...
15919 (cris_remove_point): ... this.
15920 (the_low_target): Adjust.
15922 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
15924 * server.c (handle_v_kill): Pass signal_pid to
15925 kill_inferior if multi_process is zero.
15927 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
15929 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
15930 * target.h (target_ops): Comment for *_watchpoint to make it clear
15931 the functions can get types '0' and '1'.
15933 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
15935 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
15936 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
15937 * regcache.c (get_regcache): Likewise.
15938 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
15939 * win32-low.c (child_fetch_inferior_registers): Remove check for
15942 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
15943 Pedro Alves <pedro@codesourcery.com>
15945 * target.h (struct target_ops) <supports_multi_process>: New
15947 (target_supports_multi_process): New.
15948 * server.c (handle_query): Even if GDB reports support, only
15949 enable multi-process if the target also supports it. Report
15950 multi-process support only if the target backend supports it.
15951 * linux-low.c (linux_supports_multi_process): New function.
15952 (linux_target_ops): Install it as target_supports_multi_process
15955 2009-05-24 Doug Evans <dje@google.com>
15957 Global renaming of find_thread_pid to find_thread_ptid.
15958 * server.h (find_thread_ptid): Renamed from find_thread_pid.
15959 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
15960 All callers updated.
15962 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
15963 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
15966 * linux-low.c (get_stop_pc): Print pc if debug_threads.
15967 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
15968 (linux_resume_one_lwp): Ditto.
15970 2009-05-23 Doug Evans <dje@google.com>
15972 * linux-low.c (linux_resume_one_lwp): Change type of first arg
15973 from struct inferior_list_entry * to struct lwp_info *.
15974 All callers updated.
15976 2009-05-13 Doug Evans <dje@google.com>
15978 * linux-x86-low.c: Don't include assert.h.
15979 (x86_siginfo_fixup): Use fatal, not assert.
15980 (x86_arch_setup): Fix comment.
15982 2009-05-12 Doug Evans <dje@google.com>
15984 Biarch support for i386/amd64 gdbserver.
15985 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
15986 Add linux-x86-low.c.
15987 (linux-i386-low.o, linux-x86-64-low.o): Delete.
15988 (linux-x86-low.o): Add.
15989 * linux-x86-64-low.c: Delete.
15990 * linux-i386-low.c: Delete.
15991 * linux-x86-low.c: New file.
15992 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
15994 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
15996 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
15997 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
15998 (linux_child_pid_to_exec_file): New function.
15999 (elf_64_header_p, elf_64_file_p): New functions.
16000 (siginfo_fixup): New function.
16001 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
16002 give target a chance to convert layout.
16003 * linux-low.h (linux_target_ops): New member siginfo_fixup.
16004 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
16006 2009-05-07 Doug Evans <dje@google.com>
16008 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
16009 (regsets_store_inferior_registers): Ditto.
16011 2009-05-06 Pedro Alves <pedro@codesourcery.com>
16015 * linux-low.c (must_set_ptrace_flags): Delete.
16016 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
16018 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
16019 `lwp->must_set_ptrace_flags' instead.
16020 (linux_wait_for_event_1): Set ptrace options here.
16021 (linux_wait_1): ... not here.
16023 2009-04-30 Doug Evans <dje@google.com>
16025 * inferiors.c (started_inferior_callback): New function.
16026 (attached_inferior_callback): New function.
16027 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
16028 * server.c (print_started_pid, print_attached_pid): New functions.
16029 (detach_or_kill_for_exit): New function.
16030 (main): Call it instead of for_each_inferior (kill_inferior_callback).
16031 * server.h (have_started_inferiors_p): Declare.
16032 (have_attached_inferiors_p): Declare.
16034 * inferiors.c (remove_process): Fix memory leak, free process.
16035 * linux-low.c (linux_remove_process): New function.
16036 (linux_kill): Call it instead of remove_process.
16037 (linux_detach, linux_wait_1): Ditto.
16039 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
16041 * configure.srv: Add x86 Windows CE target.
16043 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
16045 * inferiors.c (get_thread_process): Make global.
16046 * server.h (get_thread_process): Add prototype.
16047 * thread-db.c (find_one_thread): Use get_thread_process
16048 instead of current_process.
16049 (thread_db_get_tls_address): Do not crash if called when
16050 thread layer is not yet initialized.
16052 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
16054 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
16055 * spu-low.c (current_tid): Rename to ...
16056 (current_ptid): ... this.
16057 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
16058 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
16059 ptid_get_lwp (current_ptid) instead of current_tid.
16060 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
16061 instead of current_tid. Use find_process_pid to verify pid
16062 argument is valid. Pass proper argument to remove_process.
16063 (spu_thread_alive): Compare current_ptid instead of current_tid.
16064 (spu_resume): Likewise.
16066 2009-04-02 Pedro Alves <pedro@codesourcery.com>
16068 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
16071 2009-04-01 Pedro Alves <pedro@codesourcery.com>
16073 Implement the multiprocess extensions, and add linux multiprocess
16076 * server.h (ULONGEST): Declare.
16077 (struct ptid, ptid_t): New.
16078 (minus_one_ptid, null_ptid): Declare.
16079 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
16080 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
16081 (struct inferior_list_entry): Change `id' type from unsigned from
16083 (struct sym_cache, struct breakpoint, struct
16084 process_info_private): Forward declare.
16085 (struct process_info): Declare.
16086 (current_process): Declare.
16087 (all_processes): Declare.
16088 (initialize_inferiors): Declare.
16089 (add_thread): Adjust to use ptid_t.
16090 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
16091 (add_process, remove_process, find_thread_pid): Declare.
16092 (find_inferior_id): Adjust to use ptid_t.
16093 (cont_thread, general_thread, step_thread): Change type to ptid_t.
16094 (multi_process): Declare.
16095 (push_event): Adjust to use ptid_t.
16096 (read_ptid, write_ptid): Declare.
16097 (prepare_resume_reply): Adjust to use ptid_t.
16098 (clear_symbol_cache): Declare.
16099 * inferiors.c (all_processes): New.
16100 (null_ptid, minus_one_ptid): New.
16101 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
16102 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
16103 (add_thread): Change unsigned long to ptid. Remove gdb_id
16105 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
16106 (gdb_id_to_thread): Rename to ...
16107 (find_thread_pid): ... this. Change unsigned long to ptid.
16108 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
16109 (loaded_dll, pull_pid_from_list): Adjust.
16110 (add_process, remove_process, find_process_pid)
16111 (get_thread_process, current_process, initialize_inferiors): New.
16112 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
16113 (struct target_waitstatus) <related_pid>: Ditto.
16114 (struct target_ops) <kill, detach>: Add `pid' argument. Change
16115 return type to int.
16116 (struct target_ops) <join>: Add `pid' argument.
16117 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
16118 (struct target_ops) <wait>: Add `ptid' field. Change return type
16120 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
16121 (mywait): Add `ptid' argument. Change return type to ptid_t.
16122 (target_pid_to_str): Declare.
16123 * target.c (set_desired_inferior): Adjust to use ptids.
16124 (mywait): Add new `ptid' argument. Adjust.
16125 (target_pid_to_str): New.
16126 * mem-break.h (free_all_breakpoints): Declare.
16127 * mem-break.c (breakpoints): Delelete.
16128 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
16129 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
16130 to use per-process breakpoint list.
16131 (free_all_breakpoints): New.
16132 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
16133 (symbol_cache, all_symbols_looked_up): Delete.
16135 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
16137 (prepare_resume_reply): Change ptid argument's type from unsigned
16138 long to ptid_t. Adjust. Implement W;process and X;process.
16139 (free_sym_cache, clear_symbol_cache): New.
16140 (look_up_one_symbol): Adjust to per-process symbol cache. *
16141 * server.c (cont_thread, general_thread, step_thread): Change type
16143 (attached): Delete.
16144 (multi_process): New.
16145 (last_ptid): Change type to ptid_t.
16146 (struct vstop_notif) <ptid>: Change type to ptid_t.
16147 (queue_stop_reply, push_event): Change `ptid' argument's type to
16149 (discard_queued_stop_replies): Add `pid' argument.
16150 (start_inferior): Adjust to use ptids. Adjust to mywait interface
16151 changes. Don't reference the `attached' global.
16152 (attach_inferior): Adjust to mywait interface changes.
16153 (handle_query): Adjust to use ptids. Parse GDB's qSupported
16154 features. Handle and report "multiprocess+". Handle
16156 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
16158 (handle_v_kill): New.
16159 (handle_v_stopped): Adjust to use target_pid_to_str.
16160 (handle_v_requests): Allow multiple attaches and runs when
16161 multiprocess extensions are in effect. Handle "vKill".
16162 (myresume): Adjust to use ptids.
16163 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
16164 (handle_status): Adjust to discard_queued_stop_replies interface
16166 (first_thread_of, kill_inferior_callback)
16167 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
16168 (main): Call initialize_inferiors. Adjust to use ptids, killing
16169 and detaching from all inferiors. Handle multiprocess packet
16171 * linux-low.h: Include gdb_proc_service.h.
16172 (struct process_info_private): New.
16173 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
16174 <lwpid_of>: Use ptid_get_lwp.
16175 (get_lwp_thread): Adjust.
16176 (struct lwp_info): Add `dead' member.
16177 (find_lwp_pid): Declare.
16178 * linux-low.c (thread_db_active): Delete.
16179 (new_inferior): Adjust comment.
16180 (inferior_pid): Delete.
16181 (linux_add_process): New.
16182 (handle_extended_wait): Adjust.
16183 (add_lwp): Change unsigned long to ptid.
16184 (linux_create_inferior): Add process to processes table. Adjust
16185 to use ptids. Don't set new_inferior here.
16186 (linux_attach_lwp): Rename to ...
16187 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
16188 it. Adjust to use ptids.
16189 (linux_attach_lwp): New.
16190 (linux_attach): Add process to processes table. Don't set
16192 (struct counter): New.
16193 (second_thread_of_pid_p, last_thread_of_process_p): New.
16194 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
16195 multiple processes.
16196 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
16197 processes. Remove process from process table.
16198 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
16199 to multiple processes.
16200 (any_thread_of): New.
16201 (linux_detach): Add `pid' argument, and handle it. Remove process
16202 from processes table.
16203 (linux_join): Add `pid' argument. Handle it.
16204 (linux_thread_alive): Change unsighed long argument to ptid_t.
16205 Consider dead lwps as not being alive.
16206 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
16207 threads we're not interested in.
16208 (same_lwp, find_lwp_pid): New.
16209 (linux_wait_for_lwp): Change `pid' argument's type from int to
16211 (linux_wait_for_event): Rename to ...
16212 (linux_wait_for_event_1): ... this. Change `pid' argument's type
16213 from int to ptid_t. Adjust.
16214 (linux_wait_for_event): New.
16215 (linux_wait_1): Add `ptid' argument. Change return type to
16216 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
16217 that exit from the process table.
16218 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
16220 (mark_lwp_dead): New.
16221 (wait_for_sigstop): Adjust to use ptids. If a process exits while
16222 stopping all threads, mark its main lwp as dead.
16223 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
16225 (fetch_register, usr_store_inferior_registers)
16226 (regsets_fetch_inferior_registers)
16227 (regsets_store_inferior_registers, linux_read_memory)
16228 (linux_write_memory): Inline `inferior_pid'.
16229 (linux_look_up_symbols): Adjust to use per-process
16230 `thread_db_active'.
16231 (linux_request_interrupt): Adjust to use ptids.
16232 (linux_read_auxv): Inline `inferior_pid'.
16233 (initialize_low): Don't reference thread_db_active.
16234 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
16235 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
16236 (ps_getpid): Return the pid of the current inferior.
16237 * thread-db.c (proc_handle, thread_agent): Delete.
16238 (thread_db_create_event, thread_db_enable_reporting): Adjust to
16240 (find_one_thread): Change argument type to ptid_t. Adjust to
16242 (maybe_attach_thread): Adjust to per-process data and ptids.
16243 (thread_db_find_new_threads): Ditto.
16244 (thread_db_init): Ditto.
16245 * spu-low.c (spu_create_inferior, spu_attach): Add process to
16246 processes table. Adjust to use ptids.
16247 (spu_kill, spu_detach): Adjust interface. Remove process from
16249 (spu_join, spu_thread_alive): Adjust interface.
16250 (spu_wait): Adjust interface. Remove process from processes
16251 table. Adjust to use ptids.
16252 * win32-low.c (current_inferior_tid): Delete.
16253 (current_inferior_ptid): New.
16254 (debug_event_ptid): New.
16255 (thread_rec): Take a ptid. Adjust.
16256 (child_add_thread): Add `pid' argument. Adjust to use ptids.
16257 (child_delete_thread): Ditto.
16258 (do_initial_child_stuff): Add `attached' argument. Add process to
16260 (child_fetch_inferior_registers, child_store_inferior_registers):
16262 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
16263 (win32_attach): Pass 1 to do_initial_child_stuff.
16264 (win32_kill): Adjust interface. Remove process from processes
16266 (win32_detach): Ditto.
16267 (win32_join): Adjust interface.
16268 (win32_thread_alive): Take a ptid.
16269 (win32_resume): Adjust to use ptids.
16270 (get_child_debug_event): Ditto.
16271 (win32_wait): Adjust interface. Remove exiting process from
16274 2009-04-01 Pedro Alves <pedro@codesourcery.com>
16276 Non-stop mode support.
16278 * server.h (non_stop): Declare.
16279 (gdb_client_data, handler_func): Declare.
16280 (delete_file_handler, add_file_handler, start_event_loop):
16282 (handle_serial_event, handle_target_event, push_event)
16283 (putpkt_notif): Declare.
16284 * target.h (enum resume_kind): New.
16285 (struct thread_resume): Replace `step' field by `kind' field.
16286 (TARGET_WNOHANG): Define.
16287 (struct target_ops) <wait>: Add `options' argument.
16288 <supports_non_stop, async, start_non_stop>: New fields.
16289 (target_supports_non_stop, target_async): New.
16290 (start_non_stop): Declare.
16291 (mywait): Add `options' argument.
16292 * target.c (mywait): Add `options' argument. Print child exit
16293 notifications here.
16294 (start_non_stop): New.
16295 * server.c (non_stop, own_buf, mem_buf): New globals.
16296 (struct vstop_notif): New.
16297 (notif_queue): New global.
16298 (queue_stop_reply, push_event, discard_queued_stop_replies)
16299 (send_next_stop_reply): New.
16300 (start_inferior): Adjust to use resume_kind. Adjust to mywait
16302 (attach_inferior): In non-stop mode, don't wait for the target
16304 (handle_general_set): Handle QNonStop.
16305 (handle_query): When handling qC, return the current general
16306 thread, instead of the first thread of the list.
16307 (handle_query): If the backend supports non-stop mode, include
16308 QNonStop+ in the qSupported query response.
16309 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
16311 (handle_v_attach, handle_v_run): Handle non-stop mode.
16312 (handle_v_stopped): New.
16313 (handle_v_requests): Report support for vCont;t. Handle vStopped.
16314 (myresume): Adjust to use resume_kind. Handle non-stop.
16315 (queue_stop_reply_callback): New.
16316 (handle_status): Handle non-stop mode.
16317 (main): Clear non_stop flag on reconnection. Use the event-loop.
16318 Refactor serial protocol handling from here ...
16319 (process_serial_event): ... to this new function. When GDB
16320 selects any thread, select one here. In non-stop mode, wait until
16321 GDB acks all pending events before exiting.
16322 (handle_serial_event, handle_target_event): New.
16323 * remote-utils.c (remote_open): Install remote_desc in the event
16325 (remote_close): Remove remote_desc from the event loop.
16326 (putpkt_binary): Rename to...
16327 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
16328 (putpkt_binary): New as wrapper around putpkt_binary_1.
16329 (putpkt_notif): New.
16330 (prepare_resume_reply): In non-stop mode, don't change the
16332 * event-loop.c: New.
16333 * Makefile.in (OBJ): Add event-loop.o.
16334 (event-loop.o): New rule.
16336 * linux-low.h (pid_of): Moved here.
16338 (get_lwp_thread): Use lwpid_of.
16339 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
16340 * linux-low.c (pid_of): Delete.
16341 (inferior_pid): Use lwpid_of.
16342 (linux_event_pipe): New.
16343 (target_is_async_p): New.
16345 (handle_extended_wait): Use lwpid_of.
16346 (add_lwp): Don't set lwpid field.
16347 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
16348 (linux_kill_one_lwp): If killing a running lwp, stop it first.
16349 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
16350 (linux_detach_one_lwp): If detaching from a running lwp, stop it
16351 first. Adjust to linux_wait_for_event interface changes. Use
16353 (linux_detach): Don't delete the main lwp here.
16354 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
16355 (status_pending_p): Don't consider explicitly suspended lwps.
16356 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
16357 pointer. Add OPTIONS argument. Change return type to int. Use
16358 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
16359 (linux_wait_for_event): Take an integer pid instead of a lwp_info
16360 pointer. Add status pointer argument. Return a pid instead of a
16361 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
16362 changes. In non-stop mode, don't switch to a random thread.
16363 (linux_wait): Rename to...
16364 (linux_wait_1): ... this. Add target_options argument, and handle
16365 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
16366 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
16367 clean exit and signal exit code. Don't stop all threads in
16368 non-stop mode. In all-stop mode, only stop all threads when
16369 reporting a stop to GDB. Handle explicit thread stop requests.
16370 (async_file_flush, async_file_mark): New.
16372 (send_sigstop): Use lwpid_of.
16373 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
16374 interface changes. In non-stop mode, don't switch to a random
16376 (linux_resume_one_lwp): Use lwpid_of.
16377 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
16378 (linux_resume_one_thread): ... this. Handle resume_stop. In
16379 non-stop mode, don't look for pending flag in all threads.
16380 (resume_status_pending_p): Don't consider explicitly suspended
16382 (my_waitpid): Reimplement. Emulate __WALL.
16383 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
16385 (sigchld_handler, linux_supports_non_stop, linux_async)
16386 (linux_start_non_stop): New.
16387 (linux_target_ops): Register linux_supports_non_stop, linux_async
16388 and linux_start_non_stop.
16389 (initialize_low): Install SIGCHLD handler.
16390 * thread-db.c (thread_db_create_event, find_one_thread)
16391 (thread_db_get_tls_address): Use lwpid_of.
16392 * win32-low.c (win32_detach): Adjust to use resume_kind.
16393 (win32_wait): Add `options' argument.
16394 * spu-low.c (spu_resume): Adjust to use resume_kind.
16395 (spu_wait): Add `options' argument.
16397 2009-04-01 Pedro Alves <pedro@codesourcery.com>
16399 Decouple target code from remote protocol.
16401 * target.h (enum target_waitkind): New.
16402 (struct target_waitstatus): New.
16403 (struct target_ops) <wait>: Return an unsigned long. Take a
16404 target_waitstatus pointer instead of a char pointer.
16405 (mywait): Likewise.
16406 * target.c (mywait): Change prototype to return an unsigned long.
16407 Take a target_waitstatus pointer instead of a char pointer. Adjust.
16408 * server.h (thread_from_wait, old_thread_from_wait): Delete
16410 (prepare_resume_reply): Change prototype to take a
16412 * server.c (thread_from_wait, old_thread_from_wait): Delete.
16413 (last_status, last_ptid): New.
16414 (start_inferior): Remove "statusptr" argument. Adjust. Return a
16415 pid instead of a signal.
16416 (attach_inferior): Remove "status" and "signal" parameters.
16418 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
16420 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
16421 (handle_v_requests, myresume): Remove "status" and "signal"
16422 parameters. Adjust.
16423 (handle_status): New.
16424 (main): Delete local `status'. Adjust.
16425 * remote-utils.c: Include target.h.
16426 (prepare_resume_reply): Change prototype to take a
16427 target_waitstatus. Adjust.
16429 * linux-low.c (linux_wait): Adjust to new target_ops->wait
16431 * spu-low.c (spu_wait): Adjust.
16432 * win32-low.c (enum target_waitkind, struct target_waitstatus):
16434 (win32_wait): Adjust.
16436 2009-04-01 Pedro Alves <pedro@codesourcery.com>
16438 * target.h (struct thread_resume): Delete leave_stopped member.
16439 (struct target_ops): Add a `n' argument to the `resume' callback.
16440 * server.c (start_inferior): Adjust.
16441 (handle_v_cont, myresume): Adjust.
16442 * linux-low.c (check_removed_breakpoint): Adjust to resume
16443 interface change, and to removed leave_stopped field.
16444 (resume_ptr): Delete.
16445 (struct thread_resume_array): New.
16446 (linux_set_resume_request): Add new `arg' parameter. Adjust to
16447 resume interface change.
16448 (linux_continue_one_thread, linux_queue_one_thread)
16449 (resume_status_pending_p): Check if the resume field is NULL
16450 instead of checking the leave_stopped member.
16451 (linux_resume): Adjust to the target resume interface change.
16452 * spu-low.c (spu_resume): Adjust to the target resume interface
16454 * win32-low.c (win32_detach, win32_resume): Ditto.
16456 2009-04-01 Pedro Alves <pedro@codesourcery.com>
16458 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
16460 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
16462 (linux_continue_one_thread): Only preserve the stepping flag if
16463 there's a pending breakpoint.
16465 2009-03-31 Pedro Alves <pedro@codesourcery.com>
16467 * server.c (main): After the inferior having exited, call
16468 remote_close before exiting gdbserver.
16470 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
16472 Fix size of FPSCR in Power 7 processors.
16473 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
16474 (PPC_FEATURE_HAS_DFP): New #define.
16475 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
16478 2009-03-23 Pedro Alves <pedro@codesourcery.com>
16480 * server.c (handle_query) Whitespace and formatting.
16482 2009-03-22 Pedro Alves <pedro@codesourcery.com>
16484 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
16485 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
16486 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
16487 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
16488 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
16489 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
16490 Makefile.in, configure.ac: Fix whitespace throughout.
16491 * configure: Regenerate.
16493 2009-03-22 Pedro Alves <pedro@codesourcery.com>
16495 * inferiors.c (find_inferior): Make it safe for the callback
16496 function to delete the currently iterated inferior.
16498 2009-03-22 Pedro Alves <pedro@codesourcery.com>
16500 * Makefile.in (linuw_low_h): Move higher.
16501 (thread-db.o): Depend on $(linux_low_h).
16503 2009-03-17 Pedro Alves <pedro@codesourcery.com>
16505 Rename "process" to "lwp" throughout.
16507 * linux-low.c (all_processes): Rename to...
16508 (all_lwps): ... this.
16509 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
16510 (add_process): Rename to ...
16511 (add_lwp): ... this. Adjust.
16512 (linux_create_inferior): Adjust.
16513 (linux_attach_lwp): Adjust.
16514 (linux_attach): Adjust.
16515 (linux_kill_one_process): Rename to ...
16516 (linux_kill_one_lwp): ... this. Adjust.
16517 (linux_kill): Adjust.
16518 (linux_detach_one_process): Rename to ...
16519 (linux_detach_one_lwp): ... this. Adjust.
16520 (linux_detach): Adjust.
16521 (check_removed_breakpoint): Adjust.
16522 (status_pending_p): Adjust.
16523 (linux_wait_for_process): Rename to ...
16524 (linux_wait_for_lwp): ... this. Adjust.
16525 (linux_wait_for_event): Adjust.
16526 (send_sigstop): Adjust.
16527 (wait_for_sigstop): Adjust.
16528 (stop_all_processes): Rename to ...
16529 (stop_all_lwps): ... this.
16530 (linux_resume_one_process): Rename to ...
16531 (linux_resume_one_lwp): ... this. Adjust.
16532 (linux_set_resume_request, linux_continue_one_thread)
16533 (linux_queue_one_thread, resume_status_pending_p)
16534 (usr_store_inferior_registers, regsets_store_inferior_registers)
16535 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
16537 * linux-low.h (get_process): Rename to ...
16538 (get_lwp): ... this. Adjust.
16539 (get_thread_process): Rename to ...
16540 (get_thread_lwp): ... this. Adjust.
16541 (get_process_thread): Rename to ...
16542 (get_lwp_thread): ... this. Adjust.
16543 (struct process_info): Rename to ...
16544 (struct lwp_info): ... this.
16545 (all_processes): Rename to ...
16546 (all_lwps): ... this.
16547 * proc-service.c (ps_lgetregs): Adjust.
16548 * thread-db.c (thread_db_create_event, find_one_thread)
16549 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
16551 2009-03-14 Pedro Alves <pedro@codesourcery.com>
16553 * server.c (handle_query): Handle "qAttached".
16555 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
16557 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
16558 GPLv3, update license URL.
16560 2009-03-01 Doug Evans <dje@google.com>
16562 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
16563 (server_h): Add gdb_signals.h.
16564 (signals.o): Update.
16565 * server.h (target_signal_from_host,target_signal_to_host_p)
16566 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
16568 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
16570 * remote-utils.c (getpkt): Also generate remote-debug
16571 information if noack_mode is set.
16573 2009-02-06 Pedro Alves <pedro@codesourcery.com>
16575 * server.c (handle_query): Report qXfer:siginfo:read and
16576 qXfer:siginfo:write as supported and handle them.
16577 * target.h (struct target_ops) <qxfer_siginfo>: New field.
16578 * linux-low.c (linux_xfer_siginfo): New.
16579 (linux_target_ops): Set it.
16581 2009-01-26 Pedro Alves <pedro@codesourcery.com>
16583 * server.c (gdbserver_usage): Mention --remote-debug.
16584 (main): Accept '--remote-debug' switch.
16586 2009-01-18 Doug Evans <dje@google.com>
16588 * regcache.c (new_register_cache): No need to check result of xcalloc.
16589 * server.c (handle_search_memory): Back out calls to xmalloc,
16590 result is checked and error is returned to user upon failure.
16591 (handle_query): Ditto. Add more checks for result of malloc.
16592 (handle_v_cont): Check result of malloc, report error back to
16594 (handle_v_run): Ditto. Call freeargv.
16595 * server.h (freeargv): Declare.
16596 * utils.c (freeargv): New fn.
16598 2009-01-15 Doug Evans <dje@google.com>
16600 * gdbreplay.c (perror_with_name): Make arg const char *.
16601 * server.h (target_signal_to_name): Make return type const char *.
16602 * thread-db.c (thread_db_err_str): Make return type const char *.
16603 * utils.c (perror_with_name): Make arg const char *.
16605 2009-01-14 Pedro Alves <pedro@codesourcery.com>
16607 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
16608 when handling a EXIT_PROCESS_DEBUG_EVENT.
16610 2009-01-06 Joel Brobecker <brobecker@adacore.com>
16612 * gdbreplay.c (gdbreplay_version): Update copyright year.
16613 * server.c (gdbserver_version): Likewise.
16615 2009-01-05 Doug Evans <dje@google.com>
16617 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
16618 (handle_extended_wait): Improve comment.
16620 2008-12-13 Doug Evans <dje@google.com>
16622 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
16623 * server.h (ATTR_MALLOC): New macro.
16624 (xmalloc,xcalloc,xstrdup): Declare.
16625 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
16626 * inferiors.c: Ditto.
16627 * linux-low.c: Ditto.
16628 * mem-break.c: Ditto.
16629 * regcache.c: Ditto.
16630 * remote-utils.c: Ditto.
16633 * win32-low.c: Ditto.
16635 2008-12-12 Doug Evans <dje@google.com>
16637 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
16638 in debugging printf.
16640 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
16642 2008-12-09 Doug Evans <dje@google.com>
16644 * linux-low.h (struct process_info): Delete member tid, unused.
16645 * thread-db.c (find_one_thread): Update.
16646 (maybe_attach_thread): Update.
16648 2008-12-02 Pedro Alves <pedro@codesourcery.com>
16650 * target.h (struct target_ops): Add qxfer_osdata member.
16651 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
16653 (linux_qxfer_osdata): New functions.
16654 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
16656 * server.c (handle_query): Handle "qXfer:osdata:read:".
16657 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
16658 (buffer_xml_printf): New functions.
16659 * server.h (struct buffer): New.
16660 (buffer_grow_str, buffer_grow_str0): New macros.
16661 (buffer_grow, buffer_free, buffer_init, buffer_finish)
16662 (buffer_xml_printf): Declare.
16664 2008-11-24 Doug Evans <dje@google.com>
16666 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
16668 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
16670 * server.c (handle_v_run): Always use the supplied argument list.
16672 2008-11-19 Bob Wilson <bob.wilson@acm.org>
16674 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
16675 (xtensa_regmap_table): Add entry for scompare1.
16677 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
16679 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
16680 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
16681 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
16682 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
16683 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
16684 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
16685 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
16686 XML target descriptions.
16687 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
16688 when inferior is running on an ISA 2.05 or later processor. Add
16689 special case to return offset for full 64-bit slot of FPSCR when
16692 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
16694 * Makefile.in (SFILES, clean): Added sparc64 files.
16695 (reg-sparc64.o, reg-sparc64.c): New.
16696 * configure.srv (sparc*-*-linux*): New configuration.
16697 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
16698 syscall arguments for SPARC.
16699 (regsets_store_inferior_registers): Likewise.
16700 * linux-sparc-low.c: New file.
16702 2008-10-21 Doug Evans <dje@google.com>
16704 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
16705 (READLINE_DIR,READLINE_DEP): Delete.
16706 (INTERNAL_CFLAGS): Update.
16707 (LINTFLAGS): Update.
16709 2008-10-10 Pedro Alves <pedro@codesourcery.com>
16711 * server.c (handle_v_run): If GDB didn't specify an argv, use the
16712 whole argv from the last run, not just argv[0].
16714 2008-09-08 Pedro Alves <pedro@codesourcery.com>
16716 * regcache.c (new_register_cache): Return NULL if the register
16717 cache size isn't known yet.
16718 (free_register_cache): Avoid dereferencing a NULL regcache.
16720 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
16722 * configure.srv: Merge MIPS and MIPS64.
16724 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
16726 * Makefile.in (uninstall): Apply $(EXEEXT) too.
16728 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
16730 * Makefile.in: Add required vsx dependencies.
16732 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
16733 Declare init_registers_powerpc_vsx32l.
16734 Declare init_registers_powerpc_vsx64l.
16735 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
16736 (ppc_arch_setup): Check for VSX in hwcap.
16737 (ppc_fill_vsxregset): New function.
16738 (ppc_store_vsxregset): New function.
16739 Add new VSX entry in regset_info target_regsets.
16741 * configure.srv: Add new VSX dependencies.
16743 2008-08-12 Pedro Alves <pedro@codesourcery.com>
16745 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
16746 (remote_open): Set or clear transport_is_reliable.
16747 (putpkt_binary): Don't expect acks in noack mode.
16748 (getpkt): Don't send ack/nac in noack mode.
16749 * server.c (handle_general_set): Handle QStartNoAckMode.
16750 (handle_query): If connected by tcp pass QStartNoAckMode+ in
16752 (main): Reset noack_mode on every connection.
16753 * server.h (noack_mode): Declare.
16755 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
16757 * Makefile.in (GDBREPLAY_OBS): New variable.
16758 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
16760 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
16761 Daniel Jacobowitz <dan@codesourcery.com>
16763 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
16764 (usr_store_inferior_registers): Likewise.
16765 (regsets_store_inferior_registers): Likewise.
16767 2008-07-31 Rolf Jansen <rj@surtec.com>
16768 Pedro Alves <pedro@codesourcery.com>
16770 * configure.ac: Check for memmem declaration.
16771 * server.c [HAVE_MALLOC_H]: Include malloc.h.
16772 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
16773 (disable_packet_qfThreadInfo): Unconditionally compile.
16774 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
16775 * configure, config.in: Regenerate.
16777 2008-07-28 Doug Kwan <dougkwan@google.com>
16779 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
16780 (linux_write_memory): Remove declaration of errno.
16782 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
16784 * linux-low.c (handle_extended_wait): Do not use "status"
16785 variable uninitialized.
16787 2008-07-07 Pedro Alves <pedro@codesourcery.com>
16789 * server.c (handle_v_attach): Inhibit reporting dll changes.
16791 2008-06-27 Pedro Alves <pedro@codesourcery.com>
16793 * remote-utils.c (prepare_resume_reply): If requested, don't
16794 output "thread:TID" in the T stop reply.
16796 * server.c (disable_packet_vCont, disable_packet_Tthread)
16797 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
16798 (handle_query): If requested, disable support for qC, qfThreadInfo
16800 (handle_v_requests): If requested, disable support for vCont.
16801 (gdbserver_show_disableable): New.
16802 (main): Handle --disable-packet and --disable-packet=LIST.
16804 * server.h (disable_packet_vCont, disable_packet_Tthread)
16805 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
16807 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
16809 * server.c (gdbserver_usage): Mention --version.
16811 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
16813 * Makefile.in (gdbreplay.o): New rule.
16815 2008-06-06 Joseph Myers <joseph@codesourcery.com>
16817 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
16818 message, not gdbserver.
16820 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
16821 Nathan Sidwell <nathan@codesourcery.com>
16822 Joseph Myers <joseph@codesourcery.com>
16824 * acinclude.m4: Include ../../config/acx.m4.
16825 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
16826 * configure, config.in: Regenerate.
16827 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
16828 * server.c (gdbserver_version): Print PKGVERSION.
16829 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
16830 (main): Adjust gdbserver_usage calls.
16831 * gdbreplay.c (version, host_name): Add declarations.
16832 (gdbreplay_version, gdbreplay_usage): New.
16833 (main): Accept --version and --help options.
16835 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
16837 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
16838 (arm_breakpoint_at): Handle Thumb.
16839 (the_low_target): Add comment.
16841 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
16843 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
16845 2008-05-09 Doug Evans <dje@google.com>
16847 * server.h (decode_search_memory_packet): Declare.
16848 * remote-utils.c (decode_search_memory_packet): New fn.
16849 * server.c (handle_search_memory_1): New fn.
16850 (handle_search_memory): New fn.
16851 (handle_query): Process qSearch:memory packets.
16853 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
16855 * regcache.c (registers_length): Remove.
16856 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
16857 full register packet.
16858 * regcache.h (registers_length): Remove prototype.
16859 * server.h (PBUFSIZ): Define to 16384.
16861 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
16863 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
16864 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
16865 powerpc-64l.o, and powerpc-altivec64l.o.
16866 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
16867 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
16868 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
16869 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
16870 rs6000/power-linux.xml, and rs6000/power64-linux.xml
16873 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
16874 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
16875 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
16876 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
16877 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
16878 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
16879 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
16880 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
16881 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
16882 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
16885 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
16886 (init_registers_powerpc_32l): ... this new prototype.
16887 (init_registers_powerpc_32): Remove, replace by ...
16888 (init_registers_powerpc_altivec32l): ... this new prototype.
16889 (init_registers_powerpc_e500): Remove, replace by ...
16890 (init_registers_powerpc_e500l): ... this new prototype.
16891 (init_registers_ppc64): Remove, replace by ...
16892 (init_registers_powerpc_64l): ... this new prototype.
16893 (init_registers_powerpc_64): Remove, replace by ...
16894 (init_registers_powerpc_altivec64l): ... this new prototype.
16895 (ppc_num_regs): Set to 73.
16896 (PT_ORIG_R3, PT_TRAP): Define if necessary.
16897 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
16898 (ppc_cannot_store_register): Handle orig_r3 and trap.
16899 (ppc_arch_setup): Update init_registers_... calls.
16900 (ppc_fill_gregset): Handle orig_r3 and trap.
16902 * inferiors.c (clear_inferiors): Reset current_inferior.
16904 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
16906 * acinclude.m4: Add override.m4.
16907 * configure: Regenerate.
16909 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
16911 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
16912 initial call to init_register_ppc64.
16914 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
16916 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
16917 single powerpc*-*-linux* case.
16918 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
16920 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
16922 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
16923 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
16925 * linux-ppc-low.c: Include <elf.h>.
16926 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
16927 (ppc_hwcap): New global variable.
16928 (ppc_regmap): Remove __SPE__ #ifdef sections.
16929 (ppc_regmap_e500): New global variable.
16930 (ppc_cannot_store_register): Update __SPE__ special case.
16931 (ppc_get_hwcap): New function.
16932 (ppc_arch_setup): Use it to determine whether inferior supports
16933 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
16934 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
16935 Do not access registers if target does not support AltiVec.
16936 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
16937 Do not access registers if target does not support SPE.
16938 (target_regsets): Unconditionally include AltiVec and SPE regsets.
16940 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
16942 * linux-low.c (disabled_regsets, num_regsets): New.
16943 (use_regsets_p): Delete.
16944 (linux_wait_for_process): Clear disabled_regsets.
16945 (regsets_fetch_inferior_registers): Check and set it.
16946 (regsets_store_inferior_registers): Likewise.
16947 (linux_fetch_registers, linux_store_registers): Do not use
16949 (initialize_low): Allocate disabled_regsets.
16951 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
16953 * Makefile.in (LIBOBJS): New.
16954 (OBS): Use LIBOBJS.
16955 (memmem.o): New rule.
16956 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
16957 * configure: Regenerated.
16959 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
16961 * server.c (handle_query): Never return "unsupported" for
16962 qXfer:features:read queries.
16964 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
16966 * server.c (get_features_xml): Fix inverted condition.
16967 (handle_query): Always support qXfer:feature:read.
16969 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
16971 * server.c (wrapper_argv): New.
16972 (start_inferior): Handle wrapper_argv. If set, expect an extra
16974 (gdbserver_usage): Document --wrapper.
16975 (main): Parse --wrapper.
16977 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
16979 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
16980 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
16981 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
16982 (ppc_set_pc): Likewise.
16983 (ppc_arch_setup): New function.
16984 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
16985 of collect_register.
16986 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
16988 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
16990 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
16991 instead of linux-ppc64-low.o.
16992 * linux-ppc64-low.c: Remove file.
16993 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
16994 (linux-ppc64-low.o): Remove rule.
16996 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
16997 (init_registers_powerpc_64): Likewise.
16998 (ppc_regmap): Conditionally define depending on __powerpc64__.
16999 (ppc_cannot_store_register): Do not special-case "fpscr" when
17000 compiled on __powerpc64__.
17001 (ppc_collect_ptrace_register): New function.
17002 (ppc_supply_ptrace_register): New function.
17003 (ppc_breakpoint): Change type to "unsigned int".
17004 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
17005 (the_low_target): Conditionally provide initializers for the
17006 arch_setup member depending on __powerpc64__. Install
17007 collect_ptrace_register and supply_ptrace_register members.
17009 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
17011 * regcache.h (gdbserver_xmltarget): Add extern declaration.
17012 * server.c (gdbserver_xmltarget): Define.
17013 (get_features_xml): Use it to replace "target.xml" and arch_string.
17015 * configure.srv: Remove srv_xmltarget. Add XML files that were
17016 mentioned there to srv_xmlfiles instead. Remove conditional tests
17017 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
17018 srv_xmlfiles and srv_regobj to include all possible choices.
17019 * configure.ac (srv_xmltarget): Remove.
17020 (srv_xmlfiles): Do not add "target.xml".
17021 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
17022 checks for supplementary target information.
17023 * configure: Regenerate.
17024 * Makefile.in (XML_TARGET): Remove.
17025 (target.xml): Remove rule.
17026 (clean): Do not clean up target.xml.
17027 (.PRECIOUS): Do not mention target.xml.
17029 * target.h (struct target_ops): Remove arch_string member.
17030 * linux-low.c (linux_arch_string): Remove.
17031 (linux_target_ops): Remove arch_string initializer.
17032 * linux-low.h (struct linux_target_ops): Remove arch_string member.
17033 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
17034 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
17035 * spu-low.c (spu_arch_string): Remove.
17036 (spu_target_ops): Remove arch_string initializer.
17037 * win32-low.c (win32_arch_string): Remove.
17038 (win32_target_ops): Remove arch_string initializer.
17039 * win32-low.h (struct win32_target_ops): Remove arch_string member.
17040 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
17041 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
17043 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
17045 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
17046 by collect_ptrace_register and supply_ptrace_register hooks.
17047 * linux-low.c (fetch_register): Use supply_ptrace_register callback
17048 instead of checking for the_low_target.left_pad_xfer.
17049 (usr_store_inferior_registers): Use collect_ptrace_register callback
17050 instead of checking for the_low_target.left_pad_xfer.
17052 * linux-s390-low.c (s390_collect_ptrace_register): New function.
17053 (s390_supply_ptrace_register): Likewise.
17054 (s390_fill_gregset): Call s390_collect_ptrace_register.
17055 (the_low_target): Update.
17057 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
17058 (ppc_supply_ptrace_register): Likewise.
17059 (the_low_target): Update.
17061 * linux-i386-low.c (the_low_target): Update.
17062 * linux-x86-64-low.c (the_low_target): Update.
17064 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
17066 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
17067 reg-s390.o and reg-s390x.o.
17069 * linux-low.c (new_inferior): New global variable.
17070 (linux_create_inferior, linux_attach): Set it.
17071 (linux_wait_for_process): Call the_low_target.arch_setup after the
17072 target has stopped for the first time.
17073 (initialize_low): Do not call the_low_target.arch_setup.
17075 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
17076 (s390_set_pc): Likewise.
17077 (s390_arch_setup): New function.
17078 (the_low_target): Use s390_arch_setup as arch_setup routine.
17080 * regcache.c (realloc_register_cache): New function.
17081 (set_register_cache): Call it for each existing regcache.
17083 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
17085 * server.h (init_registers): Remove prototype.
17087 * linux-low.h (struct linux_target_ops): Add arch_setup field.
17088 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
17089 instead of init_registers ().
17090 * linux-arm-low.c (init_registers_arm): Add prototype.
17091 (init_registers_arm_with_iwmmxt): Likewise.
17092 (the_low_target): Add initializer for arch_setup field.
17093 * linux-cris-low.c (init_registers_cris): Add prototype.
17094 (the_low_target): Add initializer for arch_setup field.
17095 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
17096 (the_low_target): Add initializer for arch_setup field.
17097 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
17098 (the_low_target): Add initializer for arch_setup field.
17099 * linux-ia64-low.c (init_registers_ia64): Add prototype.
17100 (the_low_target): Add initializer for arch_setup field.
17101 * linux-m32r-low.c (init_registers_m32r): Add prototype.
17102 (the_low_target): Add initializer for arch_setup field.
17103 * linux-m68k-low.c (init_registers_m68k): Add prototype.
17104 (the_low_target): Add initializer for arch_setup field.
17105 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
17106 (init_registers_mips64_linux): Likewise.
17107 (the_low_target): Add initializer for arch_setup field.
17108 * linux-ppc-low.c (init_registers_ppc): Add prototype.
17109 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
17110 (the_low_target): Add initializer for arch_setup field.
17111 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
17112 (init_registers_powerpc_64): Likewise.
17113 (the_low_target): Add initializer for arch_setup field.
17114 * linux-s390-low.c (init_registers_s390): Add prototype.
17115 (init_registers_s390x): Likewise.
17116 (the_low_target): Add initializer for arch_setup field.
17117 * linux-sh-low.c (init_registers_sh): Add prototype.
17118 (the_low_target): Add initializer for arch_setup field.
17119 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
17120 (the_low_target): Add initializer for arch_setup field.
17121 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
17122 (the_low_target): Add initializer for arch_setup field.
17124 * win32-low.h (struct win32_target_ops): Add arch_setup field.
17125 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
17126 instead of init_registers ().
17127 * win32-arm-low.c (init_registers_arm): Add prototype.
17128 (the_low_target): Add initializer for arch_setup field.
17129 * win32-i386-low.c (init_registers_i386): Add prototype.
17130 (the_low_target): Add initializer for arch_setup field.
17132 * spu-low.c (init_registers_spu): Add prototype.
17133 (initialize_low): Call initialie_registers_spu () instead of
17134 initialize_registers ().
17136 2008-02-19 Pedro Alves <pedro@codesourcery.com>
17138 * server.c (handle_v_requests): When handling the vRun and vAttach
17139 packets, if already debugging a process, don't kill it. Return an
17142 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
17144 * server.c (handle_query): Correct length check.
17146 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
17148 * win32-low.c (do_initial_child_stuff): Add process handle
17149 parameter. Set current_process_handle and current_process_id from the
17150 parameters. Clear globals.
17151 (win32_create_inferior): Don't set current_process_handle and
17152 current_process_id here. Instead pass them on the call to
17153 do_initial_child_stuff.
17154 (win32_attach): Likewise.
17155 (win32_clear_inferiors): New.
17156 (win32_kill): Don't close the current process handle or the
17157 current thread handle here. Instead call win32_clear_inferiors.
17158 (win32_detach): Don't open a new handle to the process. Call
17159 win32_clear_inferiors.
17160 (win32_join): Don't rely on current_process_handle; open a new
17161 handle using the process id.
17162 (win32_wait): Call win32_clear_inferiors when the inferior process
17165 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
17167 * server.c (monitor_show_help): Add "exit".
17169 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
17171 * Makefile.in (SFILES): Add linux-xtensa-low.c.
17172 (clean): Add reg-xtensa.c.
17173 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
17174 * configure.srv (xtensa*-*-linux*) New target.
17175 * linux-xtensa-low.c: New.
17176 * xtensa-xtregs.c: New.
17178 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
17180 * hostio.c: Don't include errno.h.
17181 (errno_to_fileio_errno): Move to hostio-errno.
17182 * hostio.c: (hostio_error): Remove the error parameter. Defer the
17183 error number outputting to the target->hostio_last_error callback.
17184 (hostio_packet_error): Use FILEIO_EINVAL directly.
17185 (handle_open, handle_pread, hostio_error, handle_unlink): Update
17186 calls to hostio_error.
17187 * hostio-errno.c: New.
17188 * server.h (hostio_last_error_from_errno): Declare.
17189 * target.h (target_ops): Add hostio_last_error member.
17190 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
17191 as hostio_last_error handler.
17192 * spu-low.c (spu_target_ops): Likewise.
17193 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
17194 (wince_hostio_last_error): New functions.
17195 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
17196 as hostio_last_error handler.
17197 (win32_target_ops) [!_WIN32_WCE]: Register
17198 hostio_last_error_from_errno as hostio_last_error handler.
17199 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
17200 (hostio-errno.o): New rule.
17201 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
17202 * configure.srv (srv_hostio_err_objs): New variable. Default to
17204 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
17205 * configure: Regenerate.
17207 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
17209 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
17210 (linux_kill, linux_detach): Clean up the process list.
17211 * remote-utils.c (remote_open): Improve port number parsing.
17212 (putpkt_binary, input_interrupt): Only send interrupts if the target
17214 * server.c (extended_protocol): Make static.
17215 (attached): Define earlier.
17216 (exit_requested, response_needed, program_argv): New variables.
17217 (target_running): New.
17218 (start_inferior): Clear attached here.
17219 (attach_inferior): Set attached here.
17220 (require_running): Define.
17221 (handle_query): Use require_running and target_running. Implement
17223 (handle_v_attach, handle_v_run): New.
17224 (handle_v_requests): Use require_running. Handle vAttach and vRun.
17225 (gdbserver_usage): Update.
17226 (main): Redo argument parsing. Handle --debug and --multi. Handle
17227 --attach along with other options or after the port. Save
17228 program_argv. Support no initial program. Resynchronize
17229 communication with GDB after an error. Handle "monitor exit".
17230 Use require_running and target_running. Always allow the extended
17231 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
17232 restart in extended mode.
17233 * README: Refer to the GDB manual. Update --attach usage.
17235 2007-12-20 Andreas Schwab <schwab@suse.de>
17237 * linux-low.c (STACK_SIZE): Define.
17238 (linux_tracefork_child): Use it. Use __clone2 on ia64.
17239 (linux_test_for_tracefork): Likewise.
17241 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
17243 * linux-low.c (linux_wait_for_event): Update messages. Do not
17244 reinsert auto-delete breakpoints.
17245 * mem-break.c (struct breakpoint): Change return type of handler to
17247 (set_breakpoint_at): Update handler type.
17248 (reinsert_breakpoint_handler): Return 1 instead of calling
17250 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
17252 (check_breakpoints): Delete auto-delete breakpoints and return 2.
17253 * mem-break.h (set_breakpoint_at): Update handler type.
17254 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
17255 * win32-low.c (auto_delete_breakpoint): New.
17256 (get_child_debug_event): Use it.
17258 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
17260 * configure.ac: Check for pread and pwrite.
17261 * hostio.c (handle_pread): Fall back to lseek and read.
17262 (handle_pwrite): Fall back to lseek and write.
17263 * config.in, configure: Regenerated.
17265 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
17267 * server.c (myresume): Add own_buf argument.
17268 (main): Update calls.
17270 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
17272 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
17273 * remote-utils.c (remote_open): Do not call disable_async_io.
17274 (block_async_io): Delete.
17275 (unblock_async_io): Make static.
17276 (initialize_async_io): New.
17277 * server.c (handle_v_cont): Handle async I/O here.
17278 (myresume): Likewise. Move other common resume tasks here...
17279 (main): ... from here. Call initialize_async_io. Disable async
17280 I/O before the main loop.
17281 * server.h (initialize_async_io): Declare.
17282 (block_async_io, unblock_async_io): Delete prototypes.
17283 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
17285 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
17287 * remote-utils.c (readchar): Allow binary data in received messages.
17289 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17291 * win32-low.c (attaching): New global.
17292 (win32_create_inferior): Clear the `attaching' global.
17293 (win32_attach): Set the `attaching' global.
17294 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
17295 attaching. Only set a breakpoint at the entry point if not
17298 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17300 * server.c (main): Don't report dll events on the initial
17301 connection on attaches.
17303 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17305 * server.c (main): Relax numerical bases supported for the pid of
17306 the --attach command line argument.
17308 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17310 * win32-low.c (win32_attach): Call OpenProcess before
17311 DebugActiveProcess, not after. Add last error output to error
17314 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17316 * win32-low.c (win32_get_thread_context)
17317 (win32_set_thread_context): New functions.
17318 (thread_rec): Use win32_get_thread_context.
17319 (continue_one_thread, win32_resume): Use win32_set_thread_context.
17320 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
17323 2007-12-03 Leo Zayas
17324 Pedro Alves <pedro_alves@portugalmail.pt>
17326 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
17328 (child_add_thread): Minor cleanup.
17329 (child_continue): Resume artificially suspended threads before
17330 calling ContinueDebugEvent.
17331 (suspend_one_thread): New.
17332 (fake_breakpoint_event): New.
17333 (get_child_debug_event): Change return type to int. Check here if
17334 gdb sent an interrupt request. If a soft interrupt was requested,
17335 fake a breakpoint event. Return 0 if there is no event to handle,
17337 (win32_wait): Don't check here if gdb sent an interrupt request.
17338 Ensure there is a valid event to handle.
17339 (win32_request_interrupt): Add soft interruption method as last
17342 2007-12-03 Leo Zayas
17343 Pedro Alves <pedro_alves@portugalmail.pt>
17345 * win32-low.h (win32_thread_info): Add descriptions to the
17346 structure members. Replace `suspend_count' counter by a
17348 * win32-low.c (thread_rec): Update condition of when to get the
17349 context from the inferior. Rely on ContextFlags being set if it
17350 has already been retrieved. Only suspend the inferior thread if
17351 we haven't already. Warn if that fails.
17352 (continue_one_thread): s/suspend_count/suspended/. Only call
17353 ResumeThread once. Warn if that fails.
17355 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
17357 * win32-low.c (win32_wait): Don't read from the inferior when it
17358 has already exited.
17360 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
17362 * Makefile.in (win32_low_h): New variable.
17363 (win32-low.o): Add dependency on $(win32_low_h).
17364 (win32-arm-low.o, win32-i386-low.o): New rules.
17366 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
17368 * hostio.c: Correct copyright year.
17370 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
17372 * Makefile.in (OBS): Add hostio.o.
17373 (hostio.o): New rule.
17374 * server.h (handle_vFile): Declare.
17375 * hostio.c: New file.
17376 * server.c (handle_v_requests): Take packet_len and new_packet_len
17377 for binary packets. Call handle_vFile.
17378 (main): Update call to handle_v_requests.
17380 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
17382 * linux-low.c: Include <sched.h>.
17384 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
17386 * linux-low.c (linux_tracefork_grandchild): New.
17387 (linux_tracefork_child): Use clone.
17388 (linux_test_for_tracefork): Use clone; allocate and free a stack.
17390 2007-10-31 Joel Brobecker <brobecker@adacore.com>
17392 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
17394 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
17396 * linux-low.c (handle_extended_wait): Handle unexpected signals.
17398 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
17400 * inferiors.c (change_inferior_id): Delete.
17401 (add_pid_to_list, pull_pid_from_list): New.
17402 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
17403 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
17404 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
17405 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
17406 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
17407 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
17408 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
17409 (using_threads): Always set to 1.
17410 (handle_extended_wait): New.
17411 (add_process): Do not set TID.
17412 (linux_create_inferior): Set must_set_ptrace_flags.
17413 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
17414 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
17415 (linux_thread_alive): Rename TID argument to LWPID.
17416 (linux_wait_for_process): Handle unknown processes. Do not use TID.
17417 (linux_wait_for_event): Do not use TID or check using_threads. Update
17418 call to dead_thread_notify. Call handle_extended_wait.
17419 (linux_create_inferior): Use PTRACE_SETOPTIONS.
17420 (send_sigstop): Delete sigstop_sent.
17421 (wait_for_sigstop): Avoid TID.
17422 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
17423 (linux_test_for_tracefork): New.
17424 (linux_lookup_signals): Use thread_db_active and
17425 linux_supports_tracefork_flag.
17426 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
17427 * linux-low.h (get_process_thread): Avoid TID.
17428 (struct process_ifo): Move thread_known and tid to the end. Remove
17430 (linux_attach_lwp, thread_db_init): Update prototypes.
17431 * server.h (change_inferior_id): Delete prototype.
17432 (add_pid_to_list, pull_pid_from_list): New prototypes.
17433 * thread-db.c (thread_db_use_events): New.
17434 (find_first_thread): Rename to...
17435 (find_one_thread): ...this. Update callers and messages. Do not
17436 call fatal. Check thread_db_use_events. Do not call
17437 change_inferior_id or new_thread_notify.
17438 (maybe_attach_thread): Update. Do not call new_thread_notify.
17439 (thread_db_init): Set thread_db_use_events. Check use_events.
17440 * utils.c (fatal, warning): Correct message prefix.
17442 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
17444 * Makefile.in (clean): Remove new files.
17445 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
17446 (powerpc-64.o, powerpc-64.c): New rules.
17447 * configure.srv: Use alternate register sets for powerpc64-*-linux*
17448 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
17450 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
17452 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
17453 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
17454 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
17455 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
17456 (target_regsets): Add AltiVec and SPE register sets.
17457 * configure.ac: Check for AltiVec and SPE.
17458 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
17459 (ppc_fill_vrregset, ppc_store_vrregset): New.
17460 (target_regsets): Add AltiVec register set.
17461 * configure: Regenerated.
17463 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
17465 * linux-low.c (O_LARGEFILE): Define.
17466 (linux_read_memory): Use /proc/PID/mem.
17467 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
17468 * configure, config.in: Regenerated.
17470 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
17472 * linux-low.c (linux_wait_for_event): Do not pass signals while
17475 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
17477 * win32-low.c (create_process): New.
17478 (win32_create_inferior): Use create_process instead of
17479 CreateProcess. If create_process failed retry appending an ".exe"
17480 suffix. Store the GetLastError result immediatelly after
17481 create_process calls and use it on the call to error.
17483 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
17485 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
17487 2007-08-23 Joel Brobecker <brobecker@adacore.com>
17489 * configure.ac: Switch license to GPLv3.
17491 2007-08-01 Michael Snyder <msnyder@access-company.com>
17493 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
17495 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
17497 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
17499 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
17500 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
17501 CloseToolhelp32Snapshot.
17502 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
17503 CloseToolhelp32Snapshot.
17505 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
17507 * server.c (main): Check for inferior exit before main loop.
17509 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
17511 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
17512 instead of on tmp_desc.
17514 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
17515 Daniel Jacobowitz <dan@codesourcery.com>
17517 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
17518 (add_thread): Minor cleanups.
17519 (clear_inferiors): Move lower in the file. Clear the DLL
17521 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
17522 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
17523 (xml_escape_text): New.
17524 * server.c (handle_query): Handle qXfer:libraries:read. Report it
17526 (handle_v_cont): Report errors.
17527 (gdbserver_version): Update.
17528 (main): Correct size of own_buf. Do not report initial DLL events.
17529 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
17530 (unloaded_dll, xml_escape_text): New.
17531 * win32-low.c (enum target_waitkind): Update comments.
17532 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
17533 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
17534 (win32_EnumProcessModules, win32_GetModuleInformation)
17535 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
17536 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
17537 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
17538 (win32_Module32First, win32_Module32Next, load_toolhelp)
17539 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
17540 (get_child_debug_event): Handle DLL events.
17541 (win32_wait): Likewise.
17543 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
17545 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
17546 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
17548 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
17550 * win32-low.c (handle_output_debug_string): Ignore event if not
17553 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
17555 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
17557 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
17559 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
17561 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
17563 * inferiors.c (change_inferior_id): Add comment.
17564 * linux-low.c (check_removed_breakpoint): Add an early
17565 prototype. Improve debug output.
17566 (linux_attach): Doc update.
17567 (linux_detach_one_process, linux_detach): Clean up before releasing
17569 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
17570 * linux-low.h (struct process_info): Doc improvement.
17571 * mem-break.c (delete_all_breakpoints): New.
17572 * mem-break.h (delete_all_breakpoints): New prototype.
17573 * thread-db.c (find_first_thread): New.
17574 (thread_db_create_event): Call it instead of
17575 thread_db_find_new_threads. Clean up unused variables.
17576 (maybe_attach_thread): Remove first thread handling.
17577 (thread_db_find_new_threads): Use find_first_thread.
17578 (thread_db_get_tls_address): Likewise.
17580 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
17582 * thread-db.c (thread_db_find_new_threads): Add prototype.
17583 (thread_db_create_event): Check for the main thread before adding
17585 (maybe_attach_thread): Only enable event reporting if TID == 0.
17586 (thread_db_get_tls_address): Check for new threads.
17588 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
17590 * linux-low.c (linux_create_inferior): Try execv before execvp.
17591 * spu-low.c (spu_create_inferior): Likewise.
17593 2007-06-13 Mike Frysinger <vapier@gentoo.org>
17595 * linux-low.c (linux_create_inferior): Change execv to execvp.
17596 * spu-low.c (spu_create_inferior): Likewies.
17598 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
17600 * Makefile.in (clean): Clean new files instead of deleted ones.
17601 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
17602 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
17604 * configure.srv: Specify XML files and new regformats for MIPS and
17606 * linux-mips-low.c (mips_num_regs): Set to only used registers.
17607 (mips_regmap): Do not fetch $0. Remove unused registers. Add
17608 an entry for the restart register.
17609 (mips_cannot_fetch_register, mips_cannot_store_register)
17610 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
17611 register names to match the XML descriptions.
17612 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
17613 restart register instead of $0.
17615 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
17616 Markus Deuling <deuling@de.ibm.com>
17618 * remote-utils.c (decode_xfer_write): New function.
17619 * server.h (decode_xfer_write): Add prototype.
17620 * server.c (handle_query): Add PACKET_LEN argument. Support
17621 qXfer:spu:read and qXfer:spu:write packets.
17622 (main): Pass packet_len to handle_query.
17623 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
17624 * target.h (target_ops): Add qxfer_spu.
17626 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
17628 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
17629 accessing non-seekable spufs files.
17631 2007-05-16 Markus Deuling <deuling@de.ibm.com>
17633 * server.c (handle_query): Add reply for qC packet.
17635 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17636 Leo Zayas <lerele@champenstudios@com>
17638 * server.h (check_remote_input_interrupt_request): New function.
17639 * remote_utils.c (INVALID_DESCRIPTOR): New define.
17640 (remote_desc): Initialize with INVALID_DESCRIPTOR.
17641 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
17642 (check_remote_input_interrupt_request): New function.
17643 * server.h (check_remote_input_interrupt_request): Declare.
17644 * win32-low.c (winapi_DebugBreakProcess,
17645 winapi_GenerateConsoleCtrlEvent): New typedefs.
17646 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
17648 (win32_wait): Check for remote interrupt request
17649 with check_remote_input_interrupt_request.
17650 (win32_request_interrupt): New function.
17651 (win32_target_op): Set request_interrupt to win32_request_interrupt.
17653 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17655 * win32-low.c (debug_registers_changed,
17656 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
17657 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
17658 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
17659 (thread_rec): Get context using the low target.
17660 (child_add_thread): Call thread_added on the low target,
17661 which does the same thing.
17663 (do_initial_child_stuff): Remove debug registers references.
17664 Set context using the low target. Resume threads after
17665 setting the contexts.
17666 (child_continue): Remove dead variable. Remove debug
17667 registers references.
17668 (child_fetch_inferior_registers): Go through the low target.
17669 (do_child_store_inferior_registers): Remove.
17670 (child_store_inferior_registers): Go through the low target.
17671 (win32_resume): Remove debug registers references.
17672 Set context using the low target.
17673 (handle_exception): Change return type to void. Don't record
17674 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
17675 first chance exception.
17676 (get_child_debug_event): Change return type to void. Remove
17677 goto loop. Always return after waiting for debug event.
17678 (win32_wait): Convert to switch statement. Handle spurious
17681 * win32-i386-low.c (debug_registers_changed,
17682 debug_registers_used): New.
17683 (initial_stuff): Rename to ...
17684 (i386_initial_stuff): ... this. Clear debug registers
17686 (store_debug_registers): Delete.
17687 (i386_get_thread_context): New.
17688 (load_debug_registers): Delete.
17689 (i386_set_thread_context): New.
17690 (i386_thread_added): New.
17691 (single_step): Rename to ...
17692 (i386_single_step): ... this.
17693 (do_fetch_inferior_registers): Rename to ...
17694 (i386_fetch_inferior_register): ... this.
17695 (i386_store_inferior_register): New.
17696 (the_low_target): Adapt to new interface.
17698 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
17699 (arm_get_thread_context): New.
17700 (arm_set_thread_context): New.
17702 (do_fetch_inferior_registers): Rename to ...
17703 (arm_fetch_inferior_register): ... this.
17704 (arm_store_inferior_register): New.
17705 (arm_wince_breakpoint): Reimplement as unsigned long.
17706 (arm_wince_breakpoint_len): Define.
17707 (the_low_target): Adapt to new interface.
17709 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
17710 load_debug_registers. Add get_thread_context, set_thread_context,
17711 thread_added and store_inferior_register. Rename
17712 fetch_inferior_registers to fetch_inferior_register.
17713 (regptr): Remove declaration.
17715 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17717 * linux-low.c (linux_detach): Change return type to int. Return 0.
17718 * spu-low.c (spu_detach): Likewise.
17720 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17722 * target.h (target_ops): Change return type of detach to int.
17724 (join_inferior): New.
17725 * server.c (main): Don't skip detach support on mingw32.
17726 If the inferior doesn't support detaching return error.
17727 Call join_inferior instead of using waitpid.
17728 * linux-low.c (linux_join): New.
17729 (linux_target_op): Add linux_join.
17730 * spu-low.c (spu_join): New.
17731 (spu_target_ops): Add spu_join.
17732 * win32-low.c (win32_detach): Adapt to new interface.
17733 Reopen current_process_handle before detaching. Issue a child
17734 resume before detaching.
17736 (win32_target_op): Add win32_join.
17738 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17740 * win32-low.c (win32-attach): Fix return value.
17741 * target.h (target_ops): Describe ATTACH return values.
17743 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17745 * win32-low.c (GETPROCADDRESS): Define.
17746 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
17747 (winapi_DebugSetProcessKillOnExit): Likewise.
17748 (win32_create_inferior): Force usage of ansi CreateProcessA.
17749 (win32_attach): Use GETPROCADDRESS.
17750 (win32_detach): Likewise.
17752 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17754 * win32-low.c (win32_wait): Don't use WSTOPSIG.
17756 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
17758 * win32-low.c: Commit leftover changes from 2007-03-29.
17760 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
17762 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
17763 fields short instead of int. Add explicit padding.
17764 (i387_cache_to_fsave): Remove unnecessary casts.
17765 (i387_fsave_to_cache): Doc fix.
17766 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
17768 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
17770 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
17771 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
17773 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
17775 * configure.srv (arm*-*-mingw32ce*): Move near the other
17778 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
17780 * configure.ac: Add errno checking.
17781 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
17782 sys/file.h and malloc.h.
17783 (AC_CHECK_DECLS): Add perror.
17784 (srv_mingwce): Handle.
17785 * configure.srv (i[34567]86-*-cygwin*): Add
17786 win32-i386-low.o to srv_tgtobj.
17787 (i[34567]86-*-mingw*): Likewise.
17788 (arm*-*-mingw32ce*): Add case.
17789 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
17790 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
17791 [__MINGW32CE__] (strerror): New function.
17792 [__MINGW32CE__] (errno): Define to GetLastError.
17793 [__MINGW32CE__] (COUNTOF): New macro.
17794 (remote_open): Remove extra close call.
17795 * mem-break.c (delete_breakpoint_at): New function.
17796 * mem-break.h (delete_breakpoint_at): Declare.
17797 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
17798 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
17799 [USE_WIN32API] (read, write): Add char* casts.
17800 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
17801 * server.h: Include wincecompat.h on Windows CE.
17802 [HAVE_ERRNO_H]: Check.
17803 (perror): Declare if not declared.
17804 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
17805 (perror_with_name): Remove errno declaration.
17806 * wincecompat.h: New.
17807 * wincecompat.c: New.
17808 * win32-low.h: New.
17809 * win32-arm-low.c: New.
17810 * win32-i386-low.c: New.
17811 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
17812 (OUTMSG2): Make it safe.
17814 (COUNTOF): New macro.
17815 (NUM_REGS): Get it from the low target.
17816 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
17817 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
17818 (thread_rec): Let low target handle debug registers.
17819 (child_add_thread): Likewise.
17820 (child_init_thread_list): Likewise.
17821 (continue_one_thread): Likewise.
17823 (do_child_fetch_inferior_registers): Move to ...
17824 * win32-i386-low.c: ... here, and rename to ...
17825 (do_fetch_inferior_registers): ... this.
17826 * win32-low.c (child_fetch_inferior_registers):
17827 Go through the low target.
17828 (do_child_store_inferior_registers): Use regptr.
17829 (strwinerror): New function.
17830 (win32_create_inferior): Handle Windows CE.
17831 Use strwinerror instead of strerror on Windows error
17832 codes. Add program to the error output.
17833 Don't close the main thread handle on Windows CE.
17834 (win32_attach): Use coredll.dll on Windows CE.
17835 (win32_kill): Close current process and current
17837 (win32_detach): Use coredll.dll on Windows CE.
17838 (win32_resume): Let low target handle debug registers, and
17840 (handle_exception): Add/Remove initial breakpoint. Avoid
17841 non-existant WSTOPSIG on Windows CE.
17842 (win32_read_inferior_memory): Cast to remove warning.
17843 (win32_arch_string): Go through the low target.
17844 (initialize_low): Call set_breakpoint_data with the low
17845 target's breakpoint.
17846 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
17847 FOP_REGNUM, mappings): Move to ...
17848 * win32-i386-low.c: ... here.
17849 * win32-low.c (win32_thread_info): Move to ...
17850 * win32-low.h: ... here.
17851 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
17852 win32-arm-low.c and wincecompat.c.
17853 (all:): Add $EXEEXT.
17854 (install-only:): Likewise.
17855 (gdbserver:): Likewise.
17856 (gdbreplay:): Likewise.
17857 * config.in: Regenerate.
17858 * configure: Regenerate.
17860 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
17862 * win32-low.c: Rename typedef thread_info to
17863 win32_thread_info throughout.
17865 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
17867 * win32-i386-low.c: Rename to ...
17868 * win32-low.c: ... this.
17869 * configure.srv: Replace win32-i386-low.o with win32-low.o.
17870 * Makefile.in: Likewise.
17872 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
17874 * remote-utils.c (monitor_output): Constify msg parameter.
17875 * server.h (monitor_output): Likewise.
17876 * win32-i386-low.c (handle_output_debug_string): New.
17877 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
17878 handle_output_debug_string.
17879 (get_child_debug_event): Likewise.
17881 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
17883 * server.c (main): Correct strtoul check.
17885 2007-03-27 Jon Ringle <jon@ringle.org>
17887 * linux-low.c: Check __ARCH_HAS_MMU__ also.
17889 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
17891 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
17893 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
17895 * terminal.h: Check HAVE_SGTTY_H.
17897 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
17899 * remote-utils.c (remote_open): Print out the assigned port number.
17901 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
17903 * remote-utils.c (monitor_output): New function.
17904 * server.c (debug_threads): Define here.
17905 (monitor_show_help): New function.
17906 (handle_query): Handle qRcmd.
17907 (main): Do not handle 'd' packet.
17908 * server.h (debug_threads, remote_debug, monitor_output): Declare.
17909 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
17912 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
17914 * Makefile.in (EXEEXT): New.
17915 (clean): Use $(EXEEXT).
17917 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
17919 * target.h (target_ops): Rename send_signal to request_interrupt,
17920 and remove enum target_signal parameter.
17921 * linux-low.c (linux_request_interrupt): Rename from
17922 linux_send_signal, and always send SIGINT.
17923 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
17924 and always send SIGINT.
17925 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
17927 (input_interrupt): Likewise.
17929 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
17931 * server.c (get_features_xml): Check if target implemented
17933 * win32-i386-low.c (win32_arch_string): New.
17934 (win32_target_ops): Add win32_arch_string as arch_string member.
17936 2007-02-22 Markus Deuling <deuling@de.ibm.com>
17938 * spu-low.c (spu_arch_string): New.
17939 (spu_target_ops): Add spu_arch_string.
17941 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
17943 * remote-utils.c: Remove HAVE_TERMINAL_H check.
17944 * configure.ac: Do not check for terminal.h.
17945 * configure, config.in: Regenerated.
17947 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
17949 * Makefile.in (OBS): Add $(XML_BUILTIN).
17950 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
17952 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
17953 (arm-with-iwmmxt.c): New.
17954 * config.in, configure: Regenerate.
17955 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
17956 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
17957 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
17958 (arm*-*-linux*): Add iWMMXt and regset support.
17959 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
17960 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
17961 (arm_store_wmmxregset, target_regsets): New.
17962 * server.c (get_features_xml): Take annex argument. Check builtin
17964 (handle_query): Handle multiple annexes.
17966 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
17968 * remote-utils.c [USE_WIN32API] (read, write): Define.
17969 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
17972 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
17974 * linux-i386-low.c (the_low_target): Set arch_string.
17975 * linux-x86-64-low.c (the_low_target): Likewise.
17976 * linux-low.c (linux_arch_string): New.
17977 (linux_target_ops): Add it.
17978 * linux-low.h (struct linux_target_ops): Add arch_string.
17979 * server.c (write_qxfer_response): Use const void * for DATA.
17980 (get_features_xml): New.
17981 (handle_query): Handle qXfer:features:read. Report it for qSupported.
17982 * target.h (struct target_ops): Add arch_string method.
17984 2007-01-03 Denis Pilat <denis.pilat@st.com>
17985 Daniel Jacobowitz <dan@codesourcery.com>
17987 * linux-low.c (linux_kill): Handle being called with no threads.
17988 * win32-i386-low.c (win32_kill): Likewise.
17989 (get_child_debug_event): Clear current_process_handle.
17991 2006-12-30 Denis PILAT <denis.pilat@st.com>
17992 Daniel Jacobowitz <dan@codesourcery.com>
17994 * remote-utils.c (remote_open): Check the type of specified
17995 serial port devices before opening them.
17996 * server.c (main): Kill the inferior if an error occurs during
17997 the first remote_open.
17999 2006-12-05 Markus Deuling <deuling@de.ibm.com>
18001 * README: Update supported targets.
18003 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
18005 * Makefile.in (clean): Remove reg-mips64.c.
18006 (reg-mips64.c, reg-mips64.o): New rules.
18007 * configure.srv: Handle mips64. Include regset support for mips.
18008 * linux-mips-low.c (union mips_register): New.
18009 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
18010 (mips_breakpoint, mips_breakpoint_at): Use int.
18011 (mips_collect_register, mips_supply_register)
18012 (mips_collect_register_32bit, mips_supply_register_32bit)
18013 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
18014 (mips_store_fpregset, target_regsets): New.
18015 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
18017 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
18019 * configure.srv: Add target "spu*-*-*".
18020 * Makefile.in (clean): Remove reg-spu.c.
18021 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
18022 * spu-low.c: New file.
18024 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
18026 * configure.ac: Correct td_thr_tls_get_addr test.
18027 * configure: Regenerated.
18029 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
18031 * linux-low.c (linux_wait_for_event): Reformat. Use the
18032 pass_signals array.
18033 * remote-utils.c (decode_address_to_semicolon): New.
18034 * server.c (pass_signals, handle_general_set): New.
18035 (handle_query): Mention QPassSignals for qSupported.
18036 (main): Call handle_general_set.
18037 * server.h (pass_signals, decode_address_to_semicolon): New.
18039 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
18041 * server.c (handle_query): Correct error handling for read_auxv.
18043 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
18045 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
18046 and srv_linux_thread_db to yes.
18047 * linux-s390-low.c (s390_fill_gregset): New function.
18048 (target_regsets): Define data structure.
18050 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
18052 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
18053 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
18054 * config.in, configure: Regenerated.
18055 * inferiors.c (gdb_id_to_thread): New function.
18056 (gdb_id_to_thread_id): Use it.
18057 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
18058 * linux-low.h (struct process_info): Add th member.
18059 (thread_db_get_tls_address): New prototype.
18060 * remote-utils.c (decode_address): Make non-static.
18061 * server.c (handle_query): Handle qGetTLSAddr.
18062 * server.h (gdb_id_to_thread, decode_address): New prototypes.
18063 * target.h (struct target_ops): Add get_tls_address.
18064 * thread-db.c (maybe_attach_thread): Save the thread handle.
18065 (thread_db_get_tls_address): New.
18067 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
18069 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
18070 (linux_resume_one_process): Take a siginfo_t *. Update all
18071 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
18072 (struct pending_signals): Add a siginfo_t.
18073 (linux_wait_for_process): Always set last_status.
18074 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
18075 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
18076 * linux-low.h (struct process_info): Add last_status.
18078 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
18080 * remote-utils.c (try_rle): New function.
18081 (putpkt_binary): Use it.
18083 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
18085 * Makefile.in (clean): Clean reg-x86-64-linux.c.
18086 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
18087 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
18088 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
18089 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
18092 2006-08-08 Richard Sandiford <richard@codesourcery.com>
18094 * server.c (terminal_fd): New variable.
18095 (old_foreground_pgrp): Likewise.
18096 (restore_old_foreground_pgrp): New function.
18097 (start_inferior): Record the terminal file descriptor in terminal_fd
18098 and its original foreground group in old_foreground_pgrp. Register
18099 restore_old_foreground_pgrp with atexit().
18101 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
18103 * server.c (handle_query): Correct qPart to qXfer.
18105 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
18107 * configure.ac: Check for more headers which are missing on
18108 Windows. Automatically supply -lwsock32 and USE_WIN32API.
18109 * configure.srv: Add Cygwin and mingw32.
18110 * remote-utils.c: Don't include headers unconditionally which
18111 are missing on mingw32. Include <winsock.h> for mingw32.
18112 (remote_open): Adjust for mingw32 support. Flush
18113 standard error after writing to it.
18114 (remote_close, putpkt_binary, input_interrupt, block_async_io)
18115 (unblock_async_io, enable_async_io, disable_async_io)
18116 (readchar, getpkt): Update for Winsock support.
18117 (prepare_resume_reply): Expect a protocol signal number.
18118 * server.c: Disable <sys/wait.h> on mingw32.
18119 (start_inferior): Adjust for mingw32 support. Flush
18120 standard error after writing to it.
18121 (attach_inferior): Likewise. Use protocol signal
18123 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
18125 * win32-i386-low.c: New file.
18126 * Makefile.in (XM_CLIBS): Set.
18127 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
18128 (win32-i386-low.o): New dependency rule.
18129 * linux-low.c (linux_wait): Use target signal numbers.
18130 * target.h (struct target_ops): Doc fix.
18131 * server.h (target_signal_to_name): New prototype.
18132 * gdbreplay.c: Don't include headers unconditionally which
18133 are missing on mingw32. Include <winsock.h> for mingw32.
18134 (remote_close, remote_open): Adjust for Winsock support.
18135 * configure, config.in: Regenerated.
18137 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
18139 * server.c (decode_xfer_read, write_qxfer_response): New.
18140 (handle_query): Take a packet length argument. Handle
18141 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
18142 the qSupported response.
18143 (main): Update call to handle_query.
18145 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
18147 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
18148 (putpkt_binary): Renamed from putpkt and adjusted for binary
18150 (putpkt): New wrapper for putpkt_binary.
18151 (readchar): Don't mask off the high bit.
18152 (decode_X_packet): New function.
18153 * server.c (main): Call putpkt_binary if a handler sets the packet
18154 length. Save the length of the incoming packet. Handle 'X'.
18155 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
18157 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
18159 * server.c (handle_query): Handle qSupported.
18161 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
18163 * remote-utils.c (all_symbols_looked_up): New variable.
18164 (look_up_one_symbol): Check it.
18165 * server.h (look_up_one_symbol): New declaration.
18166 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
18168 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
18170 * Makefile.in (linux-arm-low.o): Update dependencies.
18171 * linux-arm-low.c: Include "gdb_proc_service.h".
18172 (PTRACE_GET_THREAD_AREA): Define.
18173 (ps_get_thread_area): New function.
18175 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
18177 * configure.srv (m68k*-*-uclinux*): New target.
18178 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
18179 (linux_resume_one_process): Remove extraneous cast.
18180 (linux_read_offsets): New.
18181 (linux_target_op): Add linux_read_offsets on mmuless systems.
18182 * server.c (handle_query): Add qOffsets logic.
18183 * target.h (struct target_ops): Add read_offsets.
18185 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
18187 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
18188 (PTRACE_GET_THREAD_AREA): Define.
18189 (ps_get_thread_area): New function.
18190 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
18191 (linux-x86-64-low.o): Update.
18193 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
18195 * configure.ac: Remove checks for prfpregset_t.
18196 * gdb_proc_service.h: New file.
18197 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
18198 new "gdb_proc_service.h".
18199 * proc-service.c: Likewise.
18200 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
18201 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
18202 * Makefile.in (gdb_proc_service_h): Updated.
18203 * configure, config.in: Regenerated.
18205 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
18207 * remote-utils.c (prepare_resume_reply): Move declaration
18208 of gdb_id_from_wait to the top of the block.
18210 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
18212 * linux-low.c (regsets_store_inferior_registers): Read the regset
18213 from the target before filling it.
18215 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
18217 * server.c (attach_inferior): Return SIGTRAP for a successful
18220 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
18222 * Makefile.in (OBS): Add version.o.
18223 (STAGESTUFF): Delete.
18224 (version.o): Add dependencies.
18225 (version.c): Replace rule.
18226 (clean): Remove version.c.
18227 * server.c (gdbserver_version): New.
18228 (gdbserver_usage): Use printf.
18229 (main): Handle --version and --help.
18230 * server.h (version, host_name): Add declarations.
18232 2005-12-23 Eli Zaretskii <eliz@gnu.org>
18244 * linux-x86-64-low.c:
18246 * linux-s390-low.c:
18247 * linux-ppc64-low.c:
18249 * linux-mips-low.c:
18250 * linux-m68k-low.c:
18251 * linux-m32r-low.c:
18254 * linux-ia64-low.c:
18255 * linux-i386-low.c:
18256 * linux-crisv32-low.c:
18268 * gdbserver.1: Add (C) after Copyright. Update the FSF
18271 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
18273 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
18274 (arm_breakpoint_at): Recognize both breakpoints.
18275 (the_low_target): Use the correct breakpoint instruction.
18277 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
18279 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
18280 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
18281 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
18282 (the_low_target): Update.
18284 2005-10-25 Andreas Schwab <schwab@suse.de>
18286 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
18288 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
18289 (ia64_num_regs): Reduce to 462.
18291 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
18293 * acinclude.m4: Correct quoting.
18294 * aclocal.m4: Regenerated.
18296 Suggested by SZOKOVACS Robert <szo@ies.hu>:
18297 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
18298 (thread_db_init): Call thread_db_err_str.
18299 * configure.ac: Check for TD_VERSION.
18300 * config.in, configure: Regenerated.
18302 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
18304 * server.h (error, fatal, warning): Add ATTR_FORMAT.
18306 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
18308 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
18309 is not available. Define HAVE_PTRACE_GETREGS if it is.
18310 * config.in, configure: Regenerated.
18311 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
18312 * linux-i386-low.c, linux-m68k-low.c: Update to use
18313 HAVE_PTRACE_GETREGS.
18314 * linux-low.c (regsets_fetch_inferior_registers)
18315 (regsets_store_inferior_registers): Only return 0 if we processed
18317 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
18318 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
18320 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
18322 * inferiors.c (struct thread_info): Add gdb_id.
18323 (add_thread): Add gdb_id argument.
18324 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
18325 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
18326 calls to add_thread.
18327 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
18328 * server.c (handle_query): Use thread_to_gdb_id.
18329 (handle_v_cont, main): Use gdb_id_to_thread_id.
18330 * server.h (add_thread): Update prototype.
18331 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
18334 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
18336 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
18337 left-padded registers.
18338 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
18339 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
18341 2005-07-01 Steve Ellcey <sje@cup.hp.com>
18343 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
18344 * configure: Regenerate.
18345 * config.in: Regenerate.
18346 * server.h (NEED_DECLARATION_STRERROR):
18347 Replace with !HAVE_DECL_STRERROR.
18349 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
18351 * linux-low.c (linux_wait, linux_send_signal): Don't test
18352 an unsigned long variable for > 0 if it could be MAX_ULONG.
18353 * server.c (myresume): Likewise.
18354 * target.c (set_desired_inferior): Likewise.
18356 2005-06-13 Mark Kettenis <kettenis@gnu.org>
18358 * configure.ac: Simplify and improve check for socklen_t.
18359 * configure, config.in: Regenerate.
18361 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
18363 * acconfig.h: Remove.
18364 * configure.ac: Add a test for socklen_t. Use three-argument
18365 AC_DEFINE throughout.
18366 * config.in: Regenerated using autoheader 2.59.
18367 * configure: Regenerated.
18369 * gdbreplay.c (socklen_t): Provide a default.
18370 (remote_open): Use socklen_t.
18371 * remote-utils.c (socklen_t): Provide a default.
18372 (remote_open): Use socklen_t.
18373 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
18376 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
18378 * linux-low.c (linux_read_memory, linux_write_memory)
18379 (linux_read_auxv): Likewise.
18380 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
18381 (check_mem_write): Likewise.
18382 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
18384 * regcache.c (struct inferior_rgcache_data, registers_to_string)
18385 (registers_from_string, register_data): Likewise.
18386 * server.c (handle_query, main): Likewise.
18387 * server.h (convert_ascii_to_int, convert_int_to_ascii)
18388 (decode_M_packet): Likewise.
18389 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
18390 * target.h (struct target_ops): Update read_memory, write_memory,
18392 (read_inferior_memory, write_inferior_memory): Update.
18393 * linux-low.h (struct linux_target_ops): Change type of breakpoint
18394 to unsigned char *.
18395 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
18396 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
18397 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
18398 linux-s390-low.c, linux-sh-low.c: Update for changes in
18399 read_inferior_memory and the_low_target->breakpoint.
18401 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
18403 * Makefile.in (SFILES): Add linux-ppc64-low.c.
18404 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
18405 * configure.srv: Add powerpc64-*-linux*.
18406 * linux-ppc64-low.c: New file.
18408 2005-05-23 Orjan Friberg <orjanf@axis.com>
18410 * linux-cris-low.c: New file with support for CRIS.
18411 * linux-crisv32-low.c: Ditto for CRISv32.
18412 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
18413 (clean): Add reg-cris.c and reg-crisv32.c.
18414 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
18415 reg-crisv32.o, and reg-crisv32.c to make rules.
18416 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
18417 recognized targets.
18419 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
18421 * linux-low.c (fetch_register): Ensure buffer size is a multiple
18422 of sizeof (PTRACE_XFER_TYPE).
18423 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
18425 2005-05-12 Orjan Friberg <orjanf@axis.com>
18427 * target.h (struct target_ops): Add insert_watchpoint,
18428 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
18429 pointers for hardware watchpoint support.
18430 * linux-low.h (struct linux_target_ops): Ditto.
18431 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
18432 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
18433 to linux_target_ops.
18434 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
18436 * server.c (main): Recognize 'Z' and 'z' packets.
18438 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
18440 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
18441 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
18442 (the_low_target): Add new members.
18444 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
18446 * proc-service.c (ps_lgetregs): Search all_processes instead of
18449 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
18451 * server.c (start_inferior): Change return type to int.
18452 (attach_inferior): Change sigptr to int *.
18453 (handle_v_cont, handle_v_requests): Change signal to int *.
18454 (main): Change signal to int.
18456 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
18458 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
18459 * configure.srv: Add m32r*-*-linux*.
18460 * linux-m32r-low.c: New file.
18462 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
18464 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
18466 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
18468 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
18469 Take unsigned long arguments for PIDs.
18470 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
18471 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
18472 (wait_for_sigstop, linux_resume_one_process)
18473 (regsets_fetch_inferior_registers, linux_send_signal)
18474 (linux_read_auxv): Likewise. Update the types of variables holding
18475 PIDs. Update format string specifiers.
18476 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
18477 * remote-utils.c (prepare_resume_reply): Likewise.
18478 * server.c (cont_thread, general_thread, step_thread)
18479 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
18481 (handle_query): Update format specifiers.
18482 (handle_v_cont, main): Use strtoul for thread IDs.
18483 * server.h (struct inferior_list_entry): Use unsigned long for ID.
18484 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
18485 (general_thread, step_thread, thread_from_wait)
18486 (old_thread_from_wait): Update.
18487 * target.h (struct thread_resume): Use unsigned long for THREAD.
18488 (struct target_ops): Use unsigned long for arguments to attach and
18491 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
18493 * acinclude.m4: Include bfd/bfd.m4 directly.
18494 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
18495 <agriffis@toolchain.org>.
18496 * aclocal.m4, configure: Regenerated.
18498 2005-01-07 Andrew Cagney <cagney@gnu.org>
18500 * configure.ac: Rename configure.in, require autoconf 2.59.
18501 * configure: Re-generate.
18503 2004-12-08 Daniel Jacobowitz <dan@debian.org>
18505 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
18506 LIBS when finished.
18507 * aclocal.m4: Regenerated.
18508 * configure: Regenerated.
18510 2004-11-21 Andreas Schwab <schwab@suse.de>
18512 * linux-m68k-low.c (m68k_num_gregs): Define.
18513 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
18514 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
18515 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
18516 (m68k_breakpoint_at): New. Add to the_low_target.
18518 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
18519 srv_linux_thread_db to yes.
18521 2004-10-20 Joel Brobecker <brobecker@gnat.com>
18523 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
18524 (ARCH_SET_FS): Likewise.
18525 (ARCH_GET_FS): Likewise.
18526 (ARCH_GET_GS): Likewise.
18528 2004-10-16 Daniel Jacobowitz <dan@debian.org>
18530 * linux-i386-low.c (ps_get_thread_area): New.
18531 * linux-x86-64-low.c (ps_get_thread_area): New.
18532 * linux-low.c: Include <sys/syscall.h>.
18533 (linux_kill_one_process): Don't kill the first thread here.
18534 (linux_kill): Kill the first thread here.
18535 (kill_lwp): New function.
18536 (send_sigstop, linux_send_signal): Use it.
18537 * proc-service.c: Clean up #ifdefs.
18538 (fpregset_info): Delete.
18539 (ps_lgetregs): Update and enable implementation.
18540 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
18542 * remote-utils.c (struct sym_cache, symbol_cache): New.
18543 (input_interrupt): Print a clearer message.
18544 (async_io_enabled): New variable.
18545 (enable_async_io, disable_async_io): Use it. Update comments.
18546 (look_up_one_symbol): Use the symbol cache.
18547 * thread-db.c (thread_db_look_up_symbols): New function.
18548 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
18550 2004-10-16 Daniel Jacobowitz <dan@debian.org>
18552 * configure.in: Test for -rdynamic.
18553 * configure: Regenerated.
18554 * Makefile (INTERNAL_LDFLAGS): New.
18555 (gdbserver, gdbreplay): Use it.
18557 2004-09-02 Andrew Cagney <cagney@gnu.org>
18559 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
18561 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
18563 * linux-low.c (linux_wait): Clear all_processes list also.
18565 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
18567 * linux-low.c: Include <errno.h>. Remove extern declaration of
18570 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
18572 * gdbreplay.c, server.h, utils.c: Update copyright years.
18574 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
18576 * server.c (main): Print child status or termination signal from
18577 variable 'signal', not 'sig'.
18579 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
18581 * linux-low.c (linux_read_memory): Change return type to
18582 int. Check for and return error from ptrace().
18583 * target.c (read_inferior_memory): Change return type to int. Pass
18584 back return status from the_target->read_memory().
18585 * target.h (struct target_ops): Adapt *read_memory() prototype.
18587 (read_inferior_memory): Adapt prototype.
18588 * server.c (main): Return an error packet if
18589 read_inferior_memory() returns an error.
18591 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
18593 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
18594 Unify with other clean targets.
18596 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
18598 * server.c (handle_v_cont): Call set_desired_inferior.
18600 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
18602 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
18604 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
18606 * linux-low.c (linux_wait): Unblock async I/O.
18607 (linux_resume): Block and enable async I/O.
18608 * remote-utils.c (block_async_io, unblock_async_io): New functions.
18609 * server.h (block_async_io, unblock_async_io): Add prototypes.
18611 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
18613 * remote-utils.c (remote_open): Print a status notice after
18614 opening a TCP port.
18615 * server.c (attach_inferior): Print a status notice after
18618 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
18620 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
18622 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
18624 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
18626 * server.c, target.h: Update copyright years.
18628 2004-02-25 Roland McGrath <roland@redhat.com>
18630 * target.h (struct target_ops): New member `read_auxv'.
18631 * server.c (handle_query): Handle qPart:auxv:read: query using that.
18632 * linux-low.c (linux_read_auxv): New function.
18633 (linux_target_ops): Initialize `read_auxv' member to that.
18635 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
18637 Committed by Jim Blandy <jimb@redhat.com>.
18639 * linux-s390-low.c (s390_num_regs): Update.
18640 (s390_regmap): Remove control registers. Use __s390x__ predefine
18641 instead of GPR_SIZE to distiguish s390 and s390x targets.
18643 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
18645 * linux-low.c: Update copyright year.
18646 (check_removed_breakpoint): Clear pending_is_breakpoint.
18647 (linux_set_resume_request, linux_queue_one_thread)
18648 (resume_status_pending_p): New functions.
18649 (linux_continue_one_thread): Use process->resume.
18650 (linux_resume): Only resume threads if there are no pending events.
18651 * linux-low.h (struct process_info): Add resume request
18654 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
18656 * regcache.c (new_register_cache): Clear the allocated register
18657 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
18659 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
18661 * linux-low.c (linux_resume): Take a struct thread_resume *
18663 (linux_wait): Update call.
18664 (resume_ptr): New static variable.
18665 (linux_continue_one_thread): Renamed from
18666 linux_continue_one_process. Use resume_ptr.
18667 (linux_resume): Use linux_continue_one_thread.
18668 * server.c (handle_v_cont, handle_v_requests): New functions.
18669 (myresume): New function.
18670 (main): Handle 'v' case.
18671 * target.h (struct thread_resume): New type.
18672 (struct target_ops): Change argument of "resume" to struct
18674 (myresume): Delete macro.
18676 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
18678 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
18679 (uninstall): Support DESTDIR.
18681 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
18683 * configure.srv: Add xscale*linux copy of arm*linux entry.
18685 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
18687 * linux-arm-low.c (arm_reinsert_addr): New function.
18688 (the_low_target): Add arm_reinsert_addr.
18690 2003-07-08 Mark Kettenis <kettenis@gnu.org>
18692 * mem-break.c: Remove whitespace at end of file.
18694 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
18696 * configure.in: Check whether we need to prototype strerror.
18697 * server.h: Optionally prototype strerror.
18698 * gdbreplay.c (perror_with_name): Use strerror.
18699 * linux-low.c (linux_attach_lwp): Use strerror.
18700 * utils.c (perror_with_name): Use strerror.
18701 * config.in, configure: Regenerated.
18703 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
18705 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
18706 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
18708 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
18710 * Makefile.in (SFILES): Update.
18711 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
18712 low-sun3.c: Remove files.
18714 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
18716 * linux-low.c: Move comment to linux_thread_alive where it belonged.
18717 (linux_detach_one_process, linux_detach): New functions.
18718 (linux_target_ops): Add linux_detach.
18719 * server.c (main): Handle 'D' packet.
18720 * target.h (struct target_ops): Add "detach" member.
18721 (detach_inferior): Define.
18723 2003-06-13 Mark Kettenis <kettenis@gnu.org>
18725 From Kelley Cook <kelleycook@wideopenwest.com>:
18726 * configure.srv: Accept i[34567]86 variants.
18728 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
18730 * linux-low.c (linux_wait_for_event): Correct comment typos.
18731 (linux_resume_one_process): Call check_removed_breakpoint.
18732 (linux_send_signal): New function.
18733 (linux_target_ops): Add linux_send_signal.
18734 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
18736 * target.h (struct target_ops): Add send_signal.
18738 2003-05-29 Jim Blandy <jimb@redhat.com>
18740 * linux-low.c (usr_store_inferior_registers): Transfer buf in
18741 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
18742 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
18743 away part of the register's value.
18745 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
18747 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
18748 (linux_wait_for_event, linux_init_signals): Likewise.
18750 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
18752 * configure.in: Check for stdlib.h.
18753 * configure: Regenerated.
18754 * config.in: Regenerated.
18756 2003-01-04 Andreas Schwab <schwab@suse.de>
18758 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
18760 2003-01-02 Andrew Cagney <ac131313@redhat.com>
18762 * Makefile.in: Remove obsolete code.
18764 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
18766 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
18767 defined(PT_FPR0_HI).
18769 2002-11-17 Stuart Hughes <seh@zee2.com>
18771 * linux-arm-low.c (arm_num_regs): Increase.
18772 (arm_regmap): Include status register.
18774 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
18776 * linux-low.c (register_addr): Remove incorrect -1 check.
18778 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
18780 * linux-low.c (linux_create_inferior): Call setpgid. Return
18782 (unstopped_p, linux_signal_pid): Remove.
18783 (linux_target_ops): Remove linux_signal_pid.
18784 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
18785 global instead of target method.
18786 * target.h (struct target_ops): Remove signal_pid. Update comment
18787 for create_inferior.
18788 * server.c (signal_pid): New variable.
18789 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
18790 gdbserver. Set the child to be the foreground process group.
18791 (attach_inferior): Set signal_pid.
18793 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
18795 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
18797 2002-08-20 Jim Blandy <jimb@redhat.com>
18799 * Makefile.in (LDFLAGS): Allow the configure script to establish a
18802 2002-08-01 Andrew Cagney <cagney@redhat.com>
18804 * Makefile.in: Make chill references obsolete.
18806 2002-07-24 Kevin Buettner <kevinb@redhat.com>
18808 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
18809 * configure: Regenerate.
18810 * config.in: Regenerate.
18812 2002-07-09 David O'Brien <obrien@FreeBSD.org>
18814 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
18815 (perror_with_name, remote_close, remote_open, expect, play): Static.
18817 2002-07-04 Michal Ludvig <mludvig@suse.cz>
18819 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
18820 byte offsets instead of an array of indexes.
18821 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
18823 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
18825 * regcache.c: Add comment.
18827 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
18829 * thread-db.c: New file.
18830 * proc-service.c: New file.
18831 * acinclude.m4: New file.
18832 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
18833 proc-service.o, and thread-db.o.
18834 (linux-low.o): Add USE_THREAD_DB.
18835 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
18836 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
18837 * aclocal.m4: Regenerated.
18838 * config.in: Regenerated.
18839 * configure: Regenerated.
18840 * configure.in: Check for proc_service.h, sys/procfs.h,
18841 thread_db.h, and linux/elf.h headrs.
18842 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
18843 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
18844 Check for -lthread_db and thread support.
18845 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
18846 PowerPC, and SuperH.
18847 * i387-fp.c: Constify arguments.
18848 * i387-fp.h: Likewise.
18849 * inferiors.c: (struct thread_info): Renamed from
18850 `struct inferior_info'. Remove PID member. Use generic inferior
18851 list header. All uses updated.
18852 (inferiors, signal_pid): Removed.
18853 (all_threads): New variable.
18854 (get_thread): Define.
18855 (add_inferior_to_list): New function.
18856 (for_each_inferior): New function.
18857 (change_inferior_id): New function.
18858 (add_inferior): Removed.
18859 (remove_inferior): New function.
18860 (add_thread): New function.
18861 (free_one_thread): New function.
18862 (remove_thread): New function.
18863 (clear_inferiors): Use for_each_inferior and free_one_thread.
18864 (find_inferior): New function.
18865 (find_inferior_id): New function.
18866 (inferior_target_data): Update argument type.
18867 (set_inferior_target_data): Likewise.
18868 (inferior_regcache_data): Likewise.
18869 (set_inferior_regcache_data): Likewise.
18870 * linux-low.c (linux_bp_reinsert): Remove.
18871 (all_processes, stopping_threads, using_thrads)
18872 (struct pending_signals, debug_threads, pid_of): New.
18873 (inferior_pid): Replace with macro.
18874 (struct inferior_linux_data): Remove.
18875 (get_stop_pc, add_process): New functions.
18876 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
18877 Use add_process and add_thread.
18878 (linux_attach_lwp): New function, based on old linux_attach. Use
18879 add_process and add_thread. Set stop_expected for new threads.
18880 (linux_attach): New function.
18881 (linux_kill_one_process): New function.
18882 (linux_kill): Kill all LWPs.
18883 (linux_thread_alive): Use find_inferior_id.
18884 (check_removed_breakpoints, status_pending_p): New functions.
18885 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
18886 Update. Use WNOHANG. Wait for cloned processes also. Update process
18887 struct for the found process.
18888 (linux_wait_for_event): New function.
18889 (linux_wait): Use it. Support LWPs.
18890 (send_sigstop, wait_for_sigstop, stop_all_processes)
18891 (linux_resume_one_process, linux_continue_one_process): New functions.
18892 (linux_resume): Support LWPs.
18893 (REGISTER_RAW_SIZE): Remove.
18894 (fetch_register): Use register_size instead. Call supply_register.
18895 (usr_store_inferior_registers): Likewise. Call collect_register.
18896 Fix recursive case.
18897 (regsets_fetch_inferior_registers): Improve error message.
18898 (regsets_store_inferior_registers): Add debugging.
18899 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
18900 (unstopped_p, linux_signal_pid): New functions.
18901 (linux_target_ops): Add linux_signal_pid.
18902 (linux_init_signals): New function.
18903 (initialize_low): Call it. Initialize using_threads.
18904 * regcache.c (inferior_regcache_data): Add valid
18906 (get_regcache): Fetch registers lazily. Add fetch argument
18907 and update all callers.
18908 (regcache_invalidate_one, regcache_invalidate): New
18910 (new_register_cache): Renamed from create_register_cache.
18911 Return the new regcache.
18912 (free_register_cache): Change argument to a void *.
18913 (registers_to_string, registers_from_string): Call get_regcache
18914 with fetch flag set.
18915 (register_data): Make static. Pass fetch flag to get_regcache.
18916 (supply_register): Call get_regcache with fetch flag clear.
18917 (collect_register): Call get_regcache with fetch flag set.
18918 (collect_register_as_string): New function.
18919 * regcache.h: Update.
18920 * remote-utils.c (putpkt): Flush after debug output and use
18922 Handle input interrupts while waiting for an ACK.
18923 (input_interrupt): Use signal_pid method.
18924 (getpkt): Flush after debug output and use stderr.
18925 (outreg): Use collect_register_as_string.
18926 (new_thread_notify, dead_thread_notify): New functions.
18927 (prepare_resume_reply): Check using_threads. Set thread_from_wait
18928 and general_thread.
18929 (look_up_one_symbol): Flush after debug output.
18930 * server.c (step_thread, server_waiting): New variables.
18931 (start_inferior): Don't use signal_pid. Update call to mywait.
18932 (attach_inferior): Update call to mywait.
18933 (handle_query): Handle qfThreadInfo and qsThreadInfo.
18934 (main): Don't fetch/store registers explicitly. Use
18935 set_desired_inferior. Support proposed ``Hs'' packet. Update
18937 * server.h: Update.
18938 (struct inferior_list, struct_inferior_list_entry): New.
18939 * target.c (set_desired_inferior): New.
18940 (write_inferior_memory): Constify.
18941 (mywait): New function.
18942 * target.h: Update.
18943 (struct target_ops): New signal_pid method.
18944 (mywait): Removed macro, added prototype.
18946 * linux-low.h (regset_func): Removed.
18947 (regset_fill_func, regset_store_func): New.
18948 (enum regset_type): New.
18949 (struct regset_info): Add type field. Use new operation types.
18950 (struct linux_target_ops): stop_pc renamed to get_pc.
18951 Add decr_pc_after_break and breakpoint_at.
18952 (get_process, get_thread_proess, get_process_thread)
18953 (strut process_info, all_processes, linux_attach_lwp)
18954 (thread_db_init): New.
18956 * linux-arm-low.c (arm_get_pc, arm_set_pc,
18957 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
18958 (the_low_target): Add new members.
18959 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
18960 (i386_store_fpxregset): Constify.
18961 (target_regsets): Add new kind identifier.
18962 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
18963 (i386_set_pc): Add debugging.
18964 (i386_breakpoint_at): New function.
18965 (the_low_target): Add new members.
18966 * linux-mips-low.c (mips_get_pc, mips_set_pc)
18967 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
18968 (mips_breakpoint_at): New.
18969 (the_low_target): Add new members.
18970 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
18971 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
18972 (the_low_target): Add new members.
18973 * linux-sh-low.c (sh_get_pc, sh_set_pc)
18974 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
18975 (the_low_target): Add new members.
18976 * linux-x86-64-low.c (target_regsets): Add new kind
18979 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
18981 From Martin Pool <mbp@samba.org>:
18982 * server.c (gdbserver_usage): New function.
18985 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
18987 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
18988 stop_at -> stop_pc.
18990 2002-05-04 Andrew Cagney <ac131313@redhat.com>
18992 * Makefile.in: Remove obsolete code.
18994 2002-04-24 Michal Ludvig <mludvig@suse.cz>
18996 * linux-low.c (regsets_fetch_inferior_registers),
18997 (regsets_store_inferior_registers): Removed cast to int from
18999 * regcache.h: Added declaration of struct inferior_info.
19001 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
19003 * inferiors.c (struct inferior_info): Add regcache_data.
19004 (add_inferior): Call create_register_cache.
19005 (clear_inferiors): Call free_register_cache.
19006 (inferior_regcache_data, set_inferior_regcache_data): New functions.
19007 * regcache.c (struct inferior_regcache_data): New.
19008 (registers): Remove.
19009 (get_regcache): New function.
19010 (create_register_cache, free_register_cache): New functions.
19011 (set_register_cache): Don't initialize the register cache here.
19012 (registers_to_string, registers_from_string, register_data): Call
19014 * regcache.h: Add prototypes.
19015 * server.h: Likewise.
19017 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
19019 * mem-break.c: New file.
19020 * mem-break.h: New file.
19021 * Makefile.in: Add mem-break.o rule; update server.h
19023 * inferiors.c (struct inferior_info): Add target_data
19025 (clear_inferiors): Free target_data member if set.
19026 (inferior_target_data, set_inferior_target_data): New functions.
19027 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
19028 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
19029 * linux-low.c (linux_bp_reinsert): New variable.
19030 (struct inferior_linux_data): New.
19031 (linux_create_inferior): Use set_inferior_target_data.
19032 (linux_attach): Likewise. Call add_inferior.
19033 (linux_wait_for_one_inferior): New function.
19034 (linux_wait): Call it.
19035 (linux_write_memory): Add const.
19036 (initialize_low): Call set_breakpoint_data.
19037 * linux-low.h (struct linux_target_ops): Add breakpoint
19039 * server.c (attach_inferior): Remove extra add_inferior
19041 * server.h: Include mem-break.h. Update inferior.c
19043 * target.c (read_inferior_memory)
19044 (write_inferior_memory): New functions.
19045 * target.h (read_inferior_memory)
19046 (write_inferior_memory): Change macros to prototypes.
19047 (struct target_ops): Update comments. Add const to write_memory
19050 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
19052 * linux-low.c (usr_store_inferior_registers): Support
19053 registers which are allowed to fail to store.
19054 * linux-low.h (linux_target_ops): Likewise.
19055 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
19056 (ppc_cannot_store_register): FPSCR may not be storable.
19058 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
19060 * server.h: Include <string.h> if HAVE_STRING_H.
19061 * ChangeLog: Correct paths in last ChangeLog entry.
19063 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
19065 * linux-low.h: Remove obsolete prototypes.
19066 (struct linux_target_ops): New.
19067 (extern the_low_target): New.
19068 * linux-low.c (num_regs, regmap): Remove declarations.
19069 (register_addr): Use the_low_target explicitly.
19070 (fetch_register): Likewise.
19071 (usr_fetch_inferior_registers): Likewise.
19072 (usr_store_inferior_registers): Likewise.
19073 * linux-arm-low.c (num_regs): Remove.
19074 (arm_num_regs): Define.
19075 (arm_regmap): Renamed from regmap, made static.
19076 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
19078 (arm_cannot_store_register): Renamed from cannot_store_register,
19080 (the_low_target): New.
19081 * linux-i386-low.c (num_regs): Remove.
19082 (i386_num_regs): Define.
19083 (i386_regmap): Renamed from regmap, made static.
19084 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
19086 (i386_cannot_store_register): Renamed from cannot_store_register,
19088 (the_low_target): New.
19089 * linux-ia64-low.c (num_regs): Remove.
19090 (ia64_num_regs): Define.
19091 (ia64_regmap): Renamed from regmap, made static.
19092 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
19094 (ia64_cannot_store_register): Renamed from cannot_store_register,
19096 (the_low_target): New.
19097 * linux-m68k-low.c (num_regs): Remove.
19098 (m68k_num_regs): Define.
19099 (m68k_regmap): Renamed from regmap, made static.
19100 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
19102 (m68k_cannot_store_register): Renamed from cannot_store_register,
19104 (the_low_target): New.
19105 * linux-mips-low.c (num_regs): Remove.
19106 (mips_num_regs): Define.
19107 (mips_regmap): Renamed from regmap, made static.
19108 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
19110 (mips_cannot_store_register): Renamed from cannot_store_register,
19112 (the_low_target): New.
19113 * linux-ppc-low.c (num_regs): Remove.
19114 (ppc_num_regs): Define.
19115 (ppc_regmap): Renamed from regmap, made static.
19116 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
19118 (ppc_cannot_store_register): Renamed from cannot_store_register,
19120 (the_low_target): New.
19121 * linux-s390-low.c (num_regs): Remove.
19122 (s390_num_regs): Define.
19123 (s390_regmap): Renamed from regmap, made static.
19124 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
19126 (s390_cannot_store_register): Renamed from cannot_store_register,
19128 (the_low_target): New.
19129 * linux-sh-low.c (num_regs): Remove.
19130 (sh_num_regs): Define.
19131 (sh_regmap): Renamed from regmap, made static.
19132 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
19134 (sh_cannot_store_register): Renamed from cannot_store_register,
19136 (the_low_target): New.
19137 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
19138 (the_low_target): New.
19140 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
19142 * Makefile.in: Add stamp-h target.
19143 * configure.in: Create stamp-h.
19144 * configure: Regenerated.
19146 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
19148 * inferiors.c: New file.
19149 * target.c: New file.
19150 * target.h: New file.
19151 * Makefile.in: Add target.o and inferiors.o. Update
19153 * linux-low.c (inferior_pid): New static variable,
19154 moved from server.c.
19155 (linux_create_inferior): Renamed from create_inferior.
19156 Call add_inferior. Return 0 on success instead of a PID.
19157 (linux_attach): Renamed from myattach.
19158 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
19159 (linux_thread_alive): Renamed from mythread_alive.
19160 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
19162 (linux_resume): Renamed from myresume. Add missing ``return 0''.
19163 (regsets_store_inferior_registers): Correct error message.
19164 Add missing ``return 0''.
19165 (linux_fetch_registers): Renamed from fetch_inferior_registers.
19166 (linux_store_registers): Renamed from store_inferior_registers.
19167 (linux_read_memory): Renamed from read_inferior_memory.
19168 (linux_write_memory): Renamed from write_inferior_memory.
19169 (linux_target_ops): New structure.
19170 (initialize_low): Call set_target_ops ().
19171 * remote-utils.c (unhexify): New function.
19172 (hexify): New function.
19173 (input_interrupt): Send signals to ``signal_pid''.
19174 * server.c (inferior_pid): Remove.
19175 (start_inferior): Update create_inferior call.
19176 (attach_inferior): Call add_inferior.
19177 (handle_query): New function.
19178 (main): Call handle_query for `q' packets.
19179 * server.h: Include "target.h". Remove obsolete prototypes.
19180 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
19182 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
19184 * Makefile.in: Add WARN_CFLAGS. Update configury
19186 * configure.in: Check for <string.h>
19187 * configure: Regenerate.
19188 * config.in: Regenerate.
19189 * gdbreplay.c: Include needed system headers.
19190 (remote_open): Remove strchr prototype.
19191 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
19192 * regcache.c (supply_register): Change buf argument to const void *.
19193 (supply_register_by_name): Likewise.
19194 (collect_register): Change buf argument to void *.
19195 (collect_register_by_name): Likewise.
19196 * regcache.h: Add missing prototypes.
19197 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
19198 * server.c (handle_query): New function.
19199 (attached): New static variable, moved out of main.
19200 (main): Quiet longjmp clobber warnings.
19201 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
19202 * utils.c (error): Remove NORETURN.