1 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3 Turn process_stratum_target's handle_monitor_command 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_handle_monitor_command): Update the macro.
9 * target.cc (process_target::handle_monitor_command): Define.
11 Update the derived classes and callers below.
13 * server.cc (handle_query): Update.
14 * linux-low.cc (linux_target_ops): Update.
15 (linux_process_target::handle_monitor_command): Define.
16 * linux-low.h (class linux_process_target): Update.
17 * lynx-low.cc (lynx_target_ops): Update.
18 * nto-low.cc (nto_target_ops): Update.
19 * win32-low.cc (win32_target_ops): Update.
21 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
23 Turn process_stratum_target's handle_new_gdb_connection op into a
24 method of process_target.
26 * target.h (struct process_stratum_target): Remove the target op.
27 (class process_target): Add the target op.
28 (target_handle_new_gdb_connection): Update the macro.
29 * target.cc (process_target::handle_new_gdb_connection): Define.
31 Update the derived classes and callers below.
33 * linux-low.cc (linux_target_ops): Update.
34 (linux_handle_new_gdb_connection): Turn into ...
35 (linux_process_target::handle_new_gdb_connection): ... this.
36 * linux-low.h (class linux_process_target): Update.
37 * lynx-low.cc (lynx_target_ops): Update.
38 * nto-low.cc (nto_target_ops): Update.
39 * win32-low.cc (win32_target_ops): Update.
41 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
43 Turn process_stratum_target's supports_fork_events,
44 supports_vfork_events, and supports_exec_events ops into methods
47 * target.h (struct process_stratum_target): Remove the target ops.
48 (class process_target): Add the target ops.
49 (target_supports_fork_events): Update the macro.
50 (target_supports_vfork_events): Update the macro.
51 (target_supports_exec_events): Update the macro.
52 * target.cc (process_target::supports_fork_events): Define.
53 (process_target::supports_vfork_events): Define.
54 (process_target::supports_exec_events): Define.
56 Update the derived classes and callers below.
58 * linux-low.cc (linux_target_ops): Update.
59 (linux_supports_fork_events): Turn into ...
60 (linux_process_target::supports_fork_events): ... this.
61 (linux_supports_vfork_events): Turn into ...
62 (linux_process_target::supports_vfork_events): ... this.
63 (linux_supports_exec_events): Turn into ...
64 (linux_process_target::supports_exec_events): ... this.
65 * linux-low.h (class linux_process_target): Update.
66 * lynx-low.cc (lynx_target_ops): Update.
67 * nto-low.cc (nto_target_ops): Update.
68 * win32-low.cc (win32_target_ops): Update.
70 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
72 Turn process_stratum_target's supports_multi_process op into a
73 method of process_target.
75 * target.h (struct process_stratum_target): Remove the target op.
76 (class process_target): Add the target op.
77 * target.cc (process_target::supports_multi_process): Define.
78 (target_supports_multi_process): Update.
80 Update the derived classes and callers below.
82 * linux-low.cc (linux_target_ops): Update.
83 (linux_supports_multi_process): Turn into ...
84 (linux_process_target::supports_multi_process): ... this.
85 * linux-low.h (class linux_process_target): Update.
86 * lynx-low.cc (lynx_target_ops): Update.
87 * nto-low.cc (nto_target_ops): Update.
88 * win32-low.cc (win32_target_ops): Update.
90 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
92 Turn process_stratum_target's supports_non_stop, async, and
93 start_non_stop ops into methods of process_target.
95 * target.h (struct process_stratum_target): Remove the target ops.
96 (class process_target): Add the target ops.
97 (target_supports_non_stop): Update the macro.
98 (target_async): Update the macro.
99 (start_non_stop): Remove declaration.
100 * target.cc (process_target::supports_non_stop): Define.
101 (process_target::async): Define.
102 (process_target::start_non_stop): Define.
103 (start_non_stop): Remove.
105 Update the derived classes and callers below.
107 * server.cc (handle_qxfer_siginfo): Update.
108 (handle_query): Update.
109 * linux-low.cc (linux_target_ops): Update.
110 (linux_supports_non_stop): Turn into ...
111 (linux_process_target::supports_non_stop): ... this.
112 (linux_async): Turn into ...
113 (linux_process_target::async): ... this.
114 (linux_start_non_stop): Turn into ...
115 (linux_process_target::start_non_stop): ... this.
116 * linux-low.h (class linux_process_target): Update.
117 * lynx-low.cc (lynx_target_ops): Update.
118 * nto-low.cc (nto_target_ops): Update.
119 (nto_supports_non_stop): Remove; rely on the default behavior
121 * win32-low.cc (win32_target_ops): Update.
123 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
125 Turn process_stratum_target's qxfer_siginfo op into a method of
128 * target.h (struct process_stratum_target): Remove the target op.
129 (class process_target): Add the target op. Also add
130 'supports_qxfer_siginfo'.
131 * target.cc (process_target::qxfer_siginfo): Define.
132 (process_target::supports_qxfer_siginfo): Define.
134 Update the derived classes and callers below.
136 * server.cc (handle_qxfer_siginfo): Update.
137 (handle_query): Update.
138 * linux-low.cc (linux_target_ops): Update.
139 (linux_process_target::supports_qxfer_siginfo): Define.
140 (linux_xfer_siginfo): Turn into ...
141 (linux_process_target::qxfer_siginfo): ... this.
142 * linux-low.h (class linux_process_target): Update.
143 * lynx-low.cc (lynx_target_ops): Update.
144 * nto-low.cc (nto_target_ops): Update.
145 * win32-low.cc (win32_target_ops): Update.
147 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
149 Turn process_stratum_target's qxfer_osdata op into a method of
152 * target.h (struct process_stratum_target): Remove the target op.
153 (class process_target): Add the target op. Also add
154 'supports_qxfer_osdata'.
155 * target.cc (process_target::qxfer_osdata): Define.
156 (process_target::supports_qxfer_osdata): Define.
158 Update the derived classes and callers below.
160 * server.cc (handle_qxfer_osdata): Update.
161 (handle_query): Update.
162 * linux-low.cc (linux_target_ops): Update.
163 (linux_process_target::supports_qxfer_osdata): Define.
164 (linux_qxfer_osdata): Turn into ...
165 (linux_process_target::qxfer_osdata): ... this.
166 * linux-low.h (class linux_process_target): Update.
167 * lynx-low.cc (lynx_target_ops): Update.
168 * nto-low.cc (nto_target_ops): Update.
169 * win32-low.cc (win32_target_ops): Update.
171 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
173 Turn process_stratum_target's hostio_last_error op into a
174 method of process_target.
176 * target.h (struct process_stratum_target): Remove the target op.
177 (class process_target): Add the target op.
178 * target.cc: Add "hostio.h" to includes.
179 (process_target::hostio_last_error): Define.
181 Update the derived classes and callers below.
183 * hostio.cc (hostio_error): Update.
184 * linux-low.cc: Remove "hostio.h" from includes.
185 (linux_target_ops): Update.
186 * lynx-low.cc (lynx_target_ops): Update.
187 * nto-low.cc (nto_target_ops): Update.
188 * win32-low.h (class win32_process_target): Update.
189 * win32-low.cc (win32_target_ops): Update.
190 (wince_hostio_last_error): Turn into ...
191 (win32_process_target::hostio_last_error): ... this.
193 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
195 Turn process_stratum_target's get_tls_address op into a method of
198 * target.h (struct process_stratum_target): Remove the target op.
199 (class process_target): Add the target op. Also add
200 'supports_get_tls_address'.
201 * target.cc (process_target::get_tls_address): Define.
202 (process_target::supports_get_tls_address): Define.
204 Update the derived classes and callers below.
206 * server.cc (handle_query): Update.
207 * linux-low.cc (linux_target_ops): Update.
208 (linux_process_target::supports_get_tls_address): Define.
209 (linux_process_target::get_tls_address): Define.
210 * linux-low.h (class linux_process_target): Update.
211 * lynx-low.cc (lynx_target_ops): Update.
212 * nto-low.cc (nto_target_ops): Update.
213 * win32-low.cc (win32_target_ops): Update.
215 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
217 Turn process_stratum_target's read_offsets op into a method of
220 * target.h (struct process_stratum_target): Remove the target op.
221 (class process_target): Add the target op. Also add
222 'supports_read_offsets'.
223 * target.cc (process_target::read_offsets): Define.
224 (process_target::supports_read_offsets): Define.
226 Update the derived classes and callers below.
228 * server.cc (handle_query): Update.
229 * linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
230 (linux_target_ops): Update.
231 (linux_process_target::supports_read_offsets): Define.
232 (linux_read_offsets): Turn into ...
233 (linux_process_target::read_offsets): ... this.
234 * linux-low.h (class linux_process_target): Update.
235 * lynx-low.cc (lynx_target_ops): Update.
236 * nto-low.cc (nto_target_ops): Update.
237 * win32-low.cc (win32_target_ops): Update.
239 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
241 Turn process_stratum_target's stopped_by_watchpoint and
242 stopped_data_address ops into methods of process_target.
244 * target.h (struct process_stratum_target): Remove the target ops.
245 (class process_target): Add the target ops.
246 * target.cc (process_target::stopped_by_watchpoint): Define.
247 (process_target::stopped_data_address): Define.
249 Update the derived classes and callers below.
251 * remote-utils.cc (prepare_resume_reply): Update.
252 * linux-low.cc (linux_target_ops): Update.
253 (linux_stopped_by_watchpoint): Turn into ...
254 (linux_process_target::stopped_by_watchpoint): ... this.
255 (linux_stopped_data_address): Turn into ...
256 (linux_process_target::stopped_data_address): ... this.
257 * linux-low.h (class linux_process_target): Update.
258 * lynx-low.cc (lynx_target_ops): Update.
259 * nto-low.cc (nto_target_ops): Update.
260 (nto_stopped_by_watchpoint): Turn into ...
261 (nto_process_target::stopped_by_watchpoint): ... this.
262 (nto_stopped_data_address): Turn into ...
263 (nto_process_target::stopped_data_address): ... this.
264 * nto-low.h (class nto_process_target): Update.
265 * win32-low.cc (win32_target_ops): Update.
266 (win32_stopped_by_watchpoint): Turn into ...
267 (win32_process_target::stopped_by_watchpoint): ... this.
268 (win32_stopped_data_address): Turn into ...
269 (win32_process_target::stopped_data_address): ... this.
270 * win32-low.h (class win32_process_target): Update.
272 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
274 Turn process_stratum_target's supports_hardware_single_step op into
275 a method of process_target.
277 * target.h (struct process_stratum_target): Remove the target op.
278 (class process_target): Add the target op.
279 (target_supports_hardware_single_step): Update the macro.
280 (target_can_do_hardware_single_step): Remove declaration.
281 * target.cc (process_target::supports_hardware_single_step): Define.
282 (target_can_do_hardware_single_step): Remove.
284 Update the derived classes and callers below.
286 * linux-low.h (class linux_process_target): Update.
287 * linux-low.cc (linux_target_ops): Update.
288 (linux_supports_hardware_single_step): Turn into ...
289 (linux_process_target::supports_hardware_single_step): ... this.
290 * lynx-low.h (class lynx_process_target): Update.
291 * lynx-low.cc (lynx_target_ops): Update.
292 (lynx_process_target::supports_hardware_single_step): Define.
293 * nto-low.h (class nto_process_target): Update.
294 * nto-low.cc (nto_target_ops): Update.
295 (nto_process_target::supports_hardware_single_step): Define.
296 * win32-low.h (class win32_process_target): Update.
297 * win32-low.cc (win32_target_ops): Update.
298 (win32_process_target::supports_hardware_single_step): Define.
300 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
302 Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
303 ops into methods of process_target.
305 * target.h (struct process_stratum_target): Remove the target ops.
306 (class process_target): Add the target ops.
307 (target_stopped_by_hw_breakpoint): Update the macro.
308 (target_supports_stopped_by_hw_breakpoint): Update the macro.
309 * target.cc (process_target::stopped_by_hw_breakpoint): Define.
310 (process_target::supports_stopped_by_hw_breakpoint): Define.
312 Update the derived classes and callers below.
314 * linux-low.cc (linux_target_ops): Update.
315 (linux_stopped_by_hw_breakpoint): Turn into ...
316 (linux_process_target::stopped_by_hw_breakpoint): ... this.
317 (linux_supports_stopped_by_hw_breakpoint): Turn into ...
318 (linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
319 * linux-low.h (class linux_process_target): Update.
320 * lynx-low.cc (lynx_target_ops): Update.
321 * nto-low.cc (nto_target_ops): Update.
322 * win32-low.cc (win32_target_ops): Update.
324 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
326 Turn process_stratum_target's {supports_}stopped_by_sw_breakpoint
327 ops into methods of process_target.
329 * target.h (struct process_stratum_target): Remove the target ops.
330 (class process_target): Add the target ops.
331 (target_stopped_by_sw_breakpoint): Update the macro.
332 (target_supports_stopped_by_sw_breakpoint): Update the macro.
333 * target.cc (process_target::stopped_by_sw_breakpoint): Define.
334 (process_target::supports_stopped_by_sw_breakpoint): Define.
336 Update the derived classes and callers below.
338 * linux-low.cc (linux_target_ops): Update.
339 (linux_stopped_by_sw_breakpoint): Turn into ...
340 (linux_process_target::stopped_by_sw_breakpoint): ... this.
341 (linux_supports_stopped_by_sw_breakpoint): Turn into ...
342 (linux_process_target::supports_stopped_by_sw_breakpoint): ... this.
343 * linux-low.h (class linux_process_target): Update.
344 * lynx-low.cc (lynx_target_ops): Update.
345 * nto-low.cc (nto_target_ops): Update.
346 * win32-low.cc (win32_target_ops): Update.
348 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
350 Turn process_stratum_target's insert_point and remove_point ops
351 into methods of process_target.
353 * target.h (struct process_stratum_target): Remove the target ops.
354 (class process_target): Add the target ops.
355 * target.cc (process_target::insert_point): Define.
356 (process_target::remove_point): Define.
358 Update the derived classes and callers below.
360 * mem-break.cc (set_raw_breakpoint_at): Update.
361 (delete_raw_breakpoint): Update.
362 (uninsert_raw_breakpoint): Update.
363 (reinsert_raw_breakpoint): Update.
364 * linux-low.cc (linux_target_ops): Update.
365 (linux_insert_point): Turn into ...
366 (linux_process_target::insert_point): ... this.
367 (linux_remove_point): Turn into ...
368 (linux_process_target::remove_point): ... this.
369 * linux-low.h (class linux_process_target): Update.
370 * lynx-low.cc (lynx_target_ops): Update.
371 * nto-low.cc (nto_target_ops): Update.
372 (nto_insert_point): Turn into ...
373 (nto_process_target::insert_point): ... this.
374 (nto_remove_point): Turn into ...
375 (nto_process_target::remove_point): ... this.
376 * nto-low.h (class nto_process_target): Update.
377 * win32-low.cc (win32_target_ops): Update.
378 (win32_insert_point): Turn into ...
379 (win32_process_target::insert_point): ... this.
380 (win32_remove_point): Turn into ...
381 (win32_process_target::remove_point): ... this.
382 * win32-low.h (class win32_process_target): Update.
384 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
386 Turn process_stratum_target's supports_z_point_type op into a
387 method of process_target.
389 * target.h (struct process_stratum_target): Remove the target op.
390 (class process_target): Add the target op.
391 * target.cc (process_target::supports_z_point_type): Define.
393 Update the derived classes and callers below.
395 * mem-break.cc (z_type_supported): Update.
396 * linux-low.cc (linux_target_ops): Update.
397 (linux_supports_z_point_type): Turn into ...
398 (linux_process_target::supports_z_point_type): ... this.
399 * linux-low.h (class linux_process_target): Update.
400 * lynx-low.cc (lynx_target_ops): Update.
401 * nto-low.cc (nto_target_ops): Update.
402 (nto_supports_z_point_type): Turn into ...
403 (nto_process_target::supports_z_point_type): ... this.
404 * nto-low.h (class nto_process_target): Update.
405 * win32-low.cc (win32_target_ops): Update.
406 (win32_supports_z_point_type): Turn into ...
407 (win32_process_target::supports_z_point_type): ... this.
408 * win32-low.h (class win32_process_target): Update.
410 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
412 Turn process_stratum_target's read_auxv op into a method of
415 * target.h (class process_stratum_target): Remove the target op.
416 (struct process_target): Add the target op. Also add
417 'supports_read_auxv'.
418 * target.cc (process_target::read_auxv): Define.
419 (process_target::supports_read_auxv): Define.
421 Update the derived classes and callers below.
423 * server.cc (handle_qxfer_auxv): Update.
424 (handle_query): Update.
425 * linux-low.cc (linux_target_ops): Update.
426 (linux_process_target::supports_read_auxv): Define.
427 (linux_read_auxv): Turn into ...
428 (linux_process_target::read_auxv): ... this.
429 * linux-low.h (class linux_process_target): Update.
430 * lynx-low.cc (lynx_target_ops): Update.
431 * nto-low.cc (nto_target_ops): Update.
432 (nto_process_target::supports_read_auxv): Define.
433 (nto_read_auxv): Turn into ...
434 (nto_process_target::read_auxv): ... this.
435 * nto-low.h (class nto_process_target): Update.
436 * win32-low.cc (win32_target_ops): Update.
438 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
440 Turn process_stratum_target's request_interrupt op into a method of
443 * target.h (struct process_stratum_target): Remove the target op.
444 (class process_target): Add the target op.
446 Update the derived classes and callers below.
448 * remote-utils.cc (putpkt_binary_1): Update.
449 (input_interrupt): Update.
451 * server.cc (handle_v_requests): Update.
452 * linux-low.cc (linux_target_ops): Update.
453 (linux_request_interrupt): Turn into ...
454 (linux_process_target::request_interrupt): ... this.
455 * linux-low.h (class linux_process_target): Update.
456 * lynx-low.cc (lynx_target_ops): Update.
457 (lynx_request_interrupt): Turn into ...
458 (lynx_process_target::request_interrupt): ... this.
459 * lynx-low.h (class lynx_process_target): Update.
460 * nto-low.cc (nto_target_ops): Update.
461 (nto_request_interrupt): Turn into ...
462 (nto_process_target::request_interrupt): ... this.
463 * nto-low.h (class nto_process_target): Update.
464 * win32-low.cc (win32_target_ops): Update.
465 (win32_request_interrupt): Turn into ...
466 (win32_process_target::request_interrupt): ... this.
467 * win32-low.h (class win32_process_target): Update.
469 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
471 Turn process_stratum_target's look_up_symbols op into a method of
474 * target.h (struct process_stratum_target): Remove the target op.
475 (class process_target): Add the target op.
476 * target.cc (process_target::look_up_symbols): Define.
478 Update the derived classes and callers below.
480 * server.cc (handle_query): Update.
481 * linux-low.cc (linux_target_ops): Update.
482 (linux_look_up_symbols): Turn into ...
483 (linux_process_target::look_up_symbols): ... this.
484 * linux-low.h (class linux_process_target): Update.
485 * lynx-low.cc (lynx_target_ops): Update.
486 * nto-low.cc (nto_target_ops): Update.
487 * win32-low.cc (win32_target_ops): Update.
489 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
491 Turn process_stratum_target's read_memory and write_memory
492 ops into methods of process_target.
494 * target.h (struct process_stratum_target): Remove the target ops.
495 (class process_target): Add the target ops.
497 Update the derived classes and callers below.
499 * linux-aarch32-low.cc (arm_breakpoint_at): Update.
500 * linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
501 * linux-arm-low.cc (arm_sigreturn_next_pc): Update.
502 (arm_get_syscall_trapinfo): Update.
503 * linux-cris-low.cc (cris_breakpoint_at): Update.
504 * linux-crisv32-low.cc (cris_breakpoint_at): Update.
505 * linux-m32r-low.cc (m32r_breakpoint_at): Update.
506 * linux-mips-low.cc (mips_breakpoint_at): Update.
507 * linux-nios2-low.cc (nios2_breakpoint_at): Update.
508 * linux-ppc-low.cc (ppc_breakpoint_at): Update.
509 * linux-sh-low.cc (sh_breakpoint_at): Update.
510 * linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
511 (sparc_store_gregset_from_stack): Update.
512 (sparc_breakpoint_at): Update.
513 * linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
514 * linux-tile-low.cc (tile_breakpoint_at): Update.
515 * linux-x86-low.cc (x86_breakpoint_at): Update.
516 * linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
517 * mem-brea.cc (insert_memory_breakpoint): Update.
518 (validate_inserted_breakpoint): Update.
519 * target.cc (read_inferior_memory): Update.
520 (target_write_memory): Update.
521 * linux-low.cc (linux_target_ops): Update.
522 (linux_read_memory): Make a wrapper around the read_memory target
524 (linux_process_target::read_memory): Rename from linux_read_memory.
525 (linux_write_memory): Turn into ...
526 (linux_process_target::write_memory): ... this.
527 * linux-low.h (class linux_process_target): Update.
528 * lynx-low.cc (lynx_target_ops): Update.
529 (lynx_read_memory): Turn into ...
530 (lynx_process_target::read_memory): ... this.
531 (lynx_write_memory): Turn into ...
532 (lynx_process_target::write_memory): ... this.
533 * lynx-low.h (class lynx_process_target): Update.
534 * nto-low.cc (nto_target_ops): Update.
535 (nto_read_memory): Turn into ...
536 (nto_process_target::read_memory): ... this.
537 (nto_write_memory): Turn into ...
538 (nto_process_target::write_memory): ... this.
539 * nto-low.h (class nto_process_target): Update.
540 * win32-low.cc (win32_target_ops): Update.
541 (win32_read_inferior_memory): Turn into ...
542 (win32_process_target::read_memory): ... this.
543 (win32_write_inferior_memory): Turn into ...
544 (win32_process_target::write_memory): ... this.
545 * win32-low.h (class win32_process_target): Update.
547 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
549 Turn process_stratum_target's prepare_to_access_memory and
550 done_accessing_memory ops into methods of process_target.
552 * target.h (struct process_stratum_target): Remove the target ops.
553 (class process_target): Add the target ops.
554 * target.cc (process_target::prepare_to_access_memory): Define.
555 (process_target::done_accessing_memory): Define.
556 (prepare_to_access_memory): Update.
557 (done_accessing_memory): Update.
559 Update the derived classes and callers below.
561 * linux-low.cc (linux_target_ops): Update.
562 (linux_prepare_to_access_memory): Turn into ...
563 (linux_process_target::prepare_to_access_memory): ... this.
564 (linux_done_accessing_memory): Turn into ...
565 (linux_process_target::done_accessing_memory): ... this.
566 * linux-low.h (class linux_process_target): Update.
567 * lynx-low.cc (lynx_target_ops): Update.
568 * nto-low.cc (nto_target_ops): Update.
569 * win32-low.cc (win32_target_ops): Update.
571 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
573 Turn process_stratum_target's fetch_registers and store_registers
574 ops into methods of process_target.
576 * target.h (struct process_stratum_target): Remove the target ops.
577 (class process_target): Add the target ops.
578 (fetch_inferior_registers): Update the macro.
579 (store_inferior_registers): Update the macro.
581 Update the derived classes and callers below.
583 * linux-low.cc (linux_target_ops): Update.
584 (linux_fetch_registers): Turn into ...
585 (linux_process_target::fetch_registers): ... this.
586 (linux_store_registers): Turn into ...
587 (linux_process_target::store_registers): ... this.
588 * linux-low.h (class linux_process_target): Update.
589 * lynx-low.cc (lynx_target_ops): Update.
590 (lynx_fetch_registers): Turn into ...
591 (lynx_process_target::fetch_registers): ... this.
592 (lynx_store_registers): Turn into ...
593 (lynx_process_target::store_registers): ... this.
594 * lynx-low.h (class lynx_process_target): Update.
595 * nto-low.cc (nto_target_ops): Update.
596 (nto_fetch_registers): Turn into ...
597 (nto_process_target::fetch_registers): ... this.
598 (nto_store_registers): Turn into ...
599 (nto_process_target::store_registers): ... this.
600 * nto-low.h (class nto_process_target): Update.
601 * win32-low.cc (win32_target_ops): Update.
602 (win32_fetch_inferior_registers): Turn into ...
603 (win32_process_target::fetch_registers): ... this.
604 (win32_store_inferior_registers): Turn into ...
605 (win32_process_target::store_registers): ... this.
606 * win32-low.h (class win32_process_target): Update.
608 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
610 Turn process_stratum_target's wait op into a method of
613 * target.h (struct process_stratum_target): Remove the target op.
614 (class process_target): Add the target op.
616 Update the derived classes and callers below.
618 * target.cc (target_wait): Update.
619 * linux-low.cc (linux_target_ops): Update.
620 (linux_wait): Turn into ...
621 (linux_process_target::wait): ... this.
622 * linux-low.h (class linux_process_target): Update.
623 * lynx-low.cc (lynx_target_ops): Update.
624 (lynx_wait): Turn into ...
625 (lynx_process_target::wait): ... this.
626 * lynx-low.h (class lynx_process_target): Update.
627 * nto-low.cc (nto_target_ops): Update.
628 (nto_wait): Turn into ...
629 (nto_process_target::wait): ... this.
630 * nto-low.h (class nto_process_target): Update.
631 * win32-low.cc (win32_target_ops): Update.
632 (win32_wait): Turn into ...
633 (win32_process_target::wait): ... this.
634 (do_initial_child_stuff): Update.
635 * win32-low.h (class win32_process_target): Update.
637 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
639 Turn process_stratum_target's resume op into a method of
642 * target.h (struct process_stratum_target): Remove the target op.
643 (class process_target): Add the target op.
645 Update the derived classes and callers below.
647 * server.cc (resume): Update.
648 * target.cc (target_stop_and_wait): Update.
649 (target_continue_no_signal): Update.
650 (target_continue): Update.
651 * linux-low.cc (linux_target_ops): Update.
652 (linux_resume): Turn into ...
653 (linux_process_target::resume): ... this.
654 * linux-low.h (class linux_process_target): Update.
655 * lynx-low.cc (lynx_target_ops): Update.
656 (lynx_resume): Turn into ...
657 (lynx_process_target::resume): ... this.
658 * lynx-low.h (class lynx_process_target): Update.
659 * nto-low.cc (nto_target_ops): Update.
660 (nto_resume): Turn into ...
661 (nto_process_target::resume): ... this.
662 * nto-low.h (class nto_process_target): Update.
663 * win32-low.cc (win32_target_ops): Update.
664 (win32_resume): Turn into ...
665 (win32_process_target::resume): ... this.
666 (win32_process_target::detach): Update.
667 (do_initial_child_stuff): Update.
668 * win32-low.h (class win32_process_target): Update.
670 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
672 Turn process_stratum_target's thread_alive op into a method of
675 * target.h (struct process_stratum_target): Remove the target op.
676 (class process_target): Add the target op.
677 (mythread_alive): Update the macro.
679 Update the derived classes and callers below.
681 * linux-low.cc (linux_target_ops): Update.
682 (linux_thread_alive): Turn into ...
683 (linux_process_target::thread_alive): ... this.
684 (wait_for_sigstop): Update.
685 * linux-low.h (class linux_process_target): Update.
686 * lynx-low.cc (lynx_target_ops): Update.
687 (lynx_thread_alive): Turn into ...
688 (lynx_process_target::thread_alive): ... this.
689 * lynx-low.h (class lynx_process_target): Update.
690 * nto-low.cc (nto_target_ops): Update.
691 (nto_thread_alive): Turn into ...
692 (nto_process_target::thread_alive): ... this.
693 * nto-low.h (class nto_process_target): Update.
694 * win32-low.cc (win32_target_ops): Update.
695 (win32_thread_alive): Turn into ...
696 (win32_process_target::thread_alive): ... this.
697 * win32-low.h (class win32_process_target): Update.
699 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
701 Turn process_stratum_target's join op into a method of
704 * target.h (struct process_stratum_target): Remove the target op.
705 (class process_target): Add the target op.
706 (join_inferior): Update the macro.
708 Update the derived classes and callers below.
710 * linux-low.cc (linux_target_ops): Update.
711 (linux_join): Turn into ...
712 (linux_process_target::join): ... this.
713 * linux-low.h (class linux_process_target): Update.
714 * lynx-low.cc (lynx_target_ops): Update.
715 (lynx_join): Turn into ...
716 (lynx_process_target::join): ... this.
717 * lynx-low.h (class lynx_process_target): Update.
718 * nto-low.cc (nto_target_ops): Update.
719 (nto_process_target::join): Define.
720 * nto-low.h (class nto_process_target): Update.
721 * win32-low.cc (win32_target_ops): Update.
722 (win32_join): Turn into ...
723 (win32_process_target::join): ... this.
724 * win32-low.h (class win32_process_target): Update.
726 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
728 Turn process_stratum_target's mourn op into a method of
731 * target.h (struct process_stratum_target): Remove the target op.
732 (class process_target): Add the target op.
734 Update the derived classes and callers below.
736 * target.cc (target_mourn_inferior): Update.
737 * linux-low.cc (linux_target_ops): Update.
738 (linux_mourn): Turn into ...
739 (linux_process_target::mourn): ... this.
740 (handle_extended_wait): Update.
741 (linux_process_target::kill): Update.
742 (linux_process_target::detach): Update.
743 * linux-low.h (class linux_process_target): Update.
744 * lynx-low.cc (lynx_target_ops): Update.
745 (lynx_mourn): Turn into ...
746 (lynx_process_target::mourn): ... this.
747 * lynx-low.h (class lynx_process_target): Update.
748 * nto-low.cc (nto_target_ops): Update.
749 (nto_mourn): Turn into ...
750 (nto_process_target::mourn): ... this.
751 * nto-low.h (class nto_process_target): Update.
752 * win32-low.cc (win32_target_ops): Update.
753 (win32_mourn): Turn into ...
754 (win32_process_target::mourn): ... this.
755 * win32-low.h (class win32_process_target): Update.
757 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
759 Turn process_stratum_target's detach op into a method of
762 * target.h (struct process_stratum_target): Remove the target op.
763 (class process_target): Add the target op.
764 (detach_inferior): Update the macro.
766 Update the derived classes and callers below.
768 * linux-low.cc (linux_target_ops): Update.
769 (linux_detach): Turn into ...
770 (linux_process_target::detach): ... this.
771 * linux-low.h (class linux_process_target): Update.
772 * lynx-low.cc (lynx_target_ops): Update.
773 (lynx_detach): Turn into ...
774 (lynx_process_target::detach): ... this.
775 * lynx-low.h (class lynx_process_target): Update.
776 * nto-low.cc (nto_target_ops): Update.
777 (nto_detach): Turn into ...
778 (nto_process_target::detach): ... this.
779 * nto-low.h (class nto_process_target): Update.
780 * win32-low.cc (win32_target_ops): Update.
781 (win32_detach): Turn into ...
782 (win32_process_target::detach): ... this.
783 * win32-low.h (class win32_process_target): Update.
785 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
787 Turn process_stratum_target's kill op into a method of
790 * target.h (struct process_stratum_target): Remove the target op.
791 (class process_target): Add the target op.
793 Update the derived classes and callers below.
795 * target.cc (kill_inferior): Update.
796 * linux-low.cc (linux_target_ops): Update.
797 (linux_kill): Turn into ...
798 (linux_process_target::kill): ... this.
799 * linux-low.h (class linux_process_target): Update.
800 * lynx-low.cc (lynx_target_ops): Update.
801 (lynx_kill): Turn into ...
802 (lynx_process_target::kill): ... this.
803 * lynx-low.h (class lynx_process_target): Update.
804 * nto-low.cc (nto_target_ops): Update.
805 (nto_kill): Turn into ...
806 (nto_process_target::kill): ... this.
807 * nto-low.h (class nto_process_target): Update.
808 * win32-low.cc (win32_target_ops): Update.
809 (win32_kill): Turn into ...
810 (win32_process_target::kill): ... this.
811 * win32-low.h (class win32_process_target): Update.
813 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
815 Turn process_stratum_target's attach op into a method of
818 * target.h (struct process_stratum_target): Remove the target op.
819 (class process_target): Add the target op.
820 (myattach): Update the macro.
822 Update the derived classes and callers below.
824 * linux-low.cc (linux_target_ops): Update.
825 (linux_attach): Turn into ...
826 (linux_process_target::attach): ... this.
827 * linux-low.h (class linux_process_target): Update.
828 * lynx-low.cc (lynx_target_ops): Update.
829 (lynx_attach): Turn into ...
830 (lynx_process_target::attach): ... this.
831 * lynx-low.h (class lynx_process_target): Update.
832 * nto-low.cc (nto_target_ops): Update.
833 (nto_attach): Turn into ...
834 (nto_process_target::attach): ... this.
835 * nto-low.h (class nto_process_target): Update.
836 * win32-low.cc (win32_target_ops): Update.
837 (win32_attach): Turn into ...
838 (win32_process_target::attach): ... this.
839 * win32-low.h (class win32_process_target): Update.
841 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
843 Turn process_stratum_target's post_create_inferior op into a method
846 * target.h (struct process_stratum_target): Remove the target op.
847 (class process_target): Add the target op.
848 (target_post_create_inferior): Update the macro.
849 * target.cc (process_target::post_create_inferior): Define.
851 Update the derived classes and callers below.
853 * linux-low.cc (linux_target_ops): Update.
854 (linux_post_create_inferior): Turn into ...
855 (linux_process_target::post_create_inferior): ... this.
856 * linux-low.h (class linux_process_target): Update.
857 * lynx-low.cc (lynx_target_ops): Update.
858 * nto-low.cc (nto_target_ops): Update.
859 * win32-low.cc (win32_target_ops): Update.
861 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
863 Turn process_stratum_target's create_inferior op into a method of
866 * target.h (struct process_stratum_target): Remove the target op.
867 (class process_target): Add the target op.
868 (create_inferior): Rename the macro to ...
869 (target_create_inferior): ... this.
871 Update the derived classes and callers below.
873 * server.cc (handle_v_run): Update.
874 (captured_main): Update.
875 (process_serial_event): Update.
876 * linux-low.cc (linux_target_ops): Update.
877 (linux_create_inferior): Turn into ...
878 (linux_process_target::create_inferior): ... this.
879 * linux-low.h (class linux_process_target): Update.
880 * lynx-low.cc (lynx_target_ops): Update.
881 (lynx_create_inferior): Turn into ...
882 (lynx_process_target::create_inferior): ... this.
883 * lynx-low.h (class lynx_process_target): Update.
884 * nto-low.cc (nto_target_ops): Update.
885 (nto_create_inferior): Turn into ...
886 (nto_process_target::create_inferior): ... this.
887 * nto-low.h (class nto_process_target): Update.
888 * win32-low.cc (win32_target_ops): Update.
889 (win32_create_inferior): Turn into ...
890 (win32_process_target::create_inferior): ... this.
891 * win32-low.h (class win32_process_target): Update.
893 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
895 * target.h (class process_target): New class definition.
896 (struct process_stratum_target) <pt>: New field with type
898 * linux-low.h (class linux_process_target): Define as a derived
899 class of 'process_target'.
900 * linux-low.cc (linux_target_ops): Add a linux_process_target*
902 * lynx-low.h (class lynx_process_target): Define as a derived
903 class of 'process_target'.
904 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
906 * nto-low.h (class nto_process_target): Define as a derived
907 class of 'process_target'.
908 * nto-low.cc (nto_target_ops): Add an nto_process_target*
910 * win32-low.h (class win32_process_target): Define as a derived
911 class of 'process_target'.
912 * win32-low.cc (win32_target_ops): Add a win32_process_target*
915 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
917 * configure: Regenerate.
919 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
920 Andrew Burgess <andrew.burgess@embecosm.com>
922 * linux-riscv-low.cc: New file.
923 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
924 and nat/riscv-linux-tdesc.c.
925 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
926 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
929 2020-02-14 Tom Tromey <tom@tromey.com>
931 * acinclude.m4: Don't include acx_configure_dir.m4.
932 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
933 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
934 (all, install-only, uninstall, clean-info, clean)
935 (maintainer-clean): Don't recurse.
936 (subdir_do, all-lib): Remove.
937 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
939 (generated_files): Update.
940 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
941 * configure: Rebuild.
942 * configure.ac: Don't configure gnulib or libiberty.
945 2020-02-14 Eli Zaretskii <eliz@gnu.org>
947 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
948 preparing the command line for CreateProcess.
949 (win32_create_inferior): Reflect the program name in debugging
950 output that shows the process and its command line.
952 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
954 * Makefile.in: Rename source files from .c to .cc.
955 * %.c: Rename to %.cc.
956 * configure.ac: Rename server.c to server.cc.
957 * configure: Re-generate.
959 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
961 * Makefile.in: Rename gdbsupport source files from .c to .cc.
963 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
965 * win32-low.c (win32_create_inferior): Set signal_pid.
967 2020-02-12 Maciej W. Rozycki <macro@wdc.com>
968 Pedro Alves <palves@redhat.com>
970 Skip building gdbserver in a cross-configuration.
971 * configure.srv: Set $gdbserver_host depending on whether $target
972 is $host. Use $gdbserver_host instead of $host.
974 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
976 * configure: Re-generate.
978 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
980 * configure: Re-generate.
982 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
984 * acinclude.m4: Update warning.m4 path.
986 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
988 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
989 (handle_exception): Set siginfo_er.
990 (win32_xfer_siginfo): New function.
992 2020-02-07 Tom Tromey <tom@tromey.com>
993 Pedro Alves <palves@redhat.com>
995 * README: Update build documentation.
996 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
998 * configure.ac: Update paths.
999 * configure: Rebuild.
1000 * acinclude.m4: Update paths.
1001 * Makefile.in: Update include paths.
1002 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
1003 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
1004 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
1005 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
1006 (%-generated.c): Update paths.
1007 * Move entire directory from ../gdb/gdbserver.
1009 2020-01-29 Maciej W. Rozycki <macro@wdc.com>
1011 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
1013 2020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1015 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
1016 assignment instead of srv_linux_obj.
1018 2020-01-28 Hannes Domani <ssbssa@yahoo.de>
1020 * server.c (handle_qxfer_libraries): Write segment-address with
1023 2020-01-24 Hannes Domani <ssbssa@yahoo.de>
1025 * Makefile.in (install-strip): New target.
1026 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
1027 * aclocal.m4: Regenerate.
1028 * configure: Regenerate.
1029 * configure.ac: Add AM_PROG_INSTALL_STRIP.
1031 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
1033 * Makefile.in (SFILES): Adjust paths to point to real files.
1034 (OBS): Move waitstatus.o to target/waitstatus.o.
1035 (TAGS): Transform paths appropriately.
1037 (nat/%.o): ... this pattern rule.
1039 (target/%.o): ... this pattern rule.
1040 * configure.srv: Adjust paths throughout to include nat/ prefix
1041 with the revant files.
1042 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
1043 * configure: Regenerate.
1045 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
1047 * Makefile.in (TAGS): Remove config files from the recipe.
1049 2020-01-14 Tom Tromey <tom@tromey.com>
1051 * configure: Rebuild.
1052 * configure.ac: Remove any checks that were added to common.m4.
1053 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
1056 2020-01-14 Tom Tromey <tom@tromey.com>
1058 * server.h: Include config.h.
1059 * gdbreplay.c: Include config.h.
1060 * configure: Rebuild.
1061 * configure.ac: Don't source common.host.
1062 * acinclude.m4: Update path.
1063 * Makefile.in (INCSUPPORT): New variable.
1064 (INCLUDE_CFLAGS): Add INCSUPPORT.
1065 (SFILES): Update paths.
1066 (version-generated.c): Update path to create-version.sh.
1067 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
1069 2020-01-14 Tom Tromey <tom@tromey.com>
1071 * configure.ac (LIBS): Use WIN32APILIBS.
1072 (USE_WIN32API): Don't define.
1073 * configure: Rebuild.
1075 2020-01-14 Tom Tromey <tom@tromey.com>
1077 * configure: Rebuild.
1079 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1081 * Makefile.in (%-generated.c): Remove rule for files from
1084 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1086 * configure: Re-generate.
1088 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1090 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
1092 * tracepoint.c (stop_tracing, flush_trace_buffer,
1093 about_to_request_buffer_space, get_trace_state_variable_value,
1094 set_trace_state_variable_value, gdb_collect): Add declaration.
1096 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1098 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
1099 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
1100 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
1101 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
1102 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
1105 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1107 * inferiors.c: Include gdbsupport/common-inferior.h.
1109 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1111 * hostio-errno.c: Include hostio.h.
1113 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1115 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
1118 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
1120 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
1121 * linux-arm-tdesc.h: Include arch/arm.h.
1123 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
1125 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
1127 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
1129 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
1130 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
1132 2020-01-10 Pedro Alves <palves@redhat.com>
1134 * fork-child.c (post_fork_inferior): Pass target down to
1136 * inferiors.c (switch_to_thread): Add process_stratum_target
1138 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
1139 * nto-low.c (nto_target_ops): Now a process_stratum_target.
1140 * linux-low.c (linux_target_ops): Now a process_stratum_target.
1141 * remote-utils.c (prepare_resume_reply): Pass the target to
1143 * target.c (the_target): Now a process_stratum_target.
1144 (done_accessing_memory): Pass the target to switch_to_thread.
1145 (set_target_ops): Ajust to use process_stratum_target.
1146 * target.h (struct target_ops): Rename to ...
1147 (struct process_stratum_target): ... this.
1148 (the_target, set_target_ops): Adjust.
1149 (prepare_to_access_memory): Adjust comment.
1150 * win32-low.c (child_xfer_memory): Adjust to use
1151 process_stratum_target.
1152 (win32_target_ops): Now a process_stratum_target.
1154 2020-01-06 Eli Zaretskii <eliz@gnu.org>
1155 Pedro Alves <palves@redhat.com>
1157 * win32-low.c (get_child_debug_event): Extract the fatal exception
1158 from the exit status and convert to the equivalent Posix signal
1160 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
1161 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
1163 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
1165 * Makefile.in: Use INSTALL_PROGRAM_ENV.
1167 2020-01-01 Joel Brobecker <brobecker@adacore.com>
1169 * server.c (gdbserver_version): Change copyright year to 2020.
1170 * gdbreplay.c (gdbreplay_version): Likewise.
1172 2019-12-19 Christian Biesinger <cbiesinger@google.com>
1174 * configure: Regenerate.
1175 * configure.ac: Quote variable arguments of test.
1177 2019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
1179 * Makefile.in: Fix build with GNU Make 3.81
1181 2019-12-16 Tom Tromey <tromey@adacore.com>
1183 * server.c (get_exec_file): Constify result.
1185 2019-12-10 Christian Biesinger <cbiesinger@google.com>
1187 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
1188 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
1189 * config.in: Regenerate.
1190 * configure: Regenerate.
1191 * configure.ac: Don't check for strerror.
1192 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
1193 Call safe_strerror instead of strerror.
1194 * server.h (strerror): Remove this now-unnecessary declaration.
1195 * tracepoint.c (init_named_socket): Call safe_strerror instead of
1197 (gdb_agent_helper_thread): Likewise.
1198 * utils.c (perror_with_name): Likewise.
1200 2019-11-26 Tom Tromey <tom@tromey.com>
1202 * configure, config.in: Rebuild.
1204 2019-11-26 Tom Tromey <tom@tromey.com>
1206 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
1207 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
1209 * configure, config.in: Rebuild.
1211 2019-11-26 Tom Tromey <tom@tromey.com>
1213 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
1214 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
1215 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
1216 * acinclude.m4: Include ax_pthread.m4.
1217 * config.in, configure: Rebuild.
1219 2019-11-26 Christian Biesinger <cbiesinger@google.com>
1221 * debug.c (debug_set_output): Call safe_strerror instead of
1223 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
1224 (linux_kill_one_lwp): Likewise.
1225 (linux_detach_one_lwp): Likewise.
1226 (linux_wait_for_event_filtered): Likewise.
1227 (store_register): Likewise.
1228 * lynx-low.c (lynx_attach): Likewise.
1229 * mem-break.c (insert_memory_breakpoint): Likewise.
1230 (remove_memory_breakpoint): Likewise.
1231 (delete_fast_tracepoint_jump): Likewise.
1232 (set_fast_tracepoint_jump): Likewise.
1233 (uninsert_fast_tracepoint_jumps_at): Likewise.
1234 (reinsert_fast_tracepoint_jumps_at): Likewise.
1235 * nto-low.c (nto_xfer_memory): Likewise.
1236 (nto_resume): Likewise.
1238 2019-11-20 Luis Machado <luis.machado@linaro.org>
1240 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
1241 instead of register count.
1242 * tdesc.c (tdesc_contains_feature): New function.
1243 * tdesc.h (tdesc_contains_feature): New prototype.
1245 2019-11-15 Christian Biesinger <cbiesinger@google.com>
1247 * Makefile.in: Add safe-strerror.c.
1248 * configure: Regenerate.
1249 * configure.ac: Don't source common.host.
1251 2019-11-15 Christian Biesinger <cbiesinger@google.com>
1253 * config.in: Regenerate.
1254 * configure: Regenerate.
1256 2019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
1258 * ax.c (ax_printf): Handle size_t_arg.
1260 2019-11-06 Christian Biesinger <cbiesinger@google.com>
1262 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
1263 * mi/mi-main.c (output_cores): Likewise.
1264 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
1265 (linux_xfer_osdata_modules): Likewise.
1266 * remote.c (register_remote_support_xml): Likewise.
1267 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
1268 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
1270 2019-11-01 Christian Biesinger <cbiesinger@google.com>
1272 * configure: Regenerate.
1273 * configure.ac: Remove check for strerror_r.
1275 2019-10-31 Christian Biesinger <cbiesinger@google.com>
1277 * config.in: Regenerate.
1278 * configure: Regenerate.
1279 * configure.ac: Also check for strerror_r.
1281 2019-10-31 Christian Biesinger <cbiesinger@google.com>
1283 * ax.h (debug_agent): Remove duplicate declaration.
1285 2019-10-26 Tom de Vries <tdevries@suse.de>
1287 * linux-aarch64-low.c: Fix typos in comments.
1288 * linux-arm-low.c: Same.
1289 * linux-low.c: Same.
1290 * linux-ppc-low.c: Same.
1291 * proc-service.c: Same.
1294 * tracepoint.c: Same.
1295 * win32-low.c: Same.
1297 2019-10-25 Tom Tromey <tromey@adacore.com>
1299 * utils.c (xstrdup): Remove.
1301 2019-10-23 Tom Tromey <tom@tromey.com>
1303 * configure, config.in: Rebuild.
1305 2019-10-23 Tom Tromey <tom@tromey.com>
1307 * configure: Rebuild.
1308 * acinclude.m4: Use m4_include, not sinclude.
1310 2019-10-17 Tom Tromey <tromey@adacore.com>
1312 * configure: Rebuild.
1313 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
1314 in AC_CONFIG_FILES invocation.
1315 * Makefile.in (stamp-h, Makefile): Use new-style config.status
1318 2019-10-16 Christian Biesinger <cbiesinger@google.com>
1320 * server.c: Include xml-builtin.h.
1321 (get_xml_features): Don't declare xml_builtins here.
1323 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
1325 * Makefile.in: Remove references to vec-ipa.o.
1327 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
1329 * Makefile.in: Remove references to vec.c.
1331 2019-10-02 Christian Biesinger <cbiesinger@google.com>
1333 * server.c (server_waiting): Change to bool.
1334 (extended_protocol): Likewise.
1335 (response_needed): Likewise.
1336 (exit_requested): Likewise.
1337 (run_once): Likewise.
1338 (report_no_resumed): Likewise.
1339 (non_stop): Likewise.
1340 (disable_packet_vCont): Likewise.
1341 (disable_packet_Tthread): Likewise.
1342 (disable_packet_qC): Likewise.
1343 (disable_packet_qfThreadInfo): Likewise.
1344 (handle_general_set): Update.
1345 (handle_detach): Update.
1346 (handle_monitor_command): Update.
1347 (handle_query): Update.
1348 (captured_main): Update.
1349 (process_serial_event): Update.
1350 * server.h (server_waiting): Change to bool.
1351 (disable_packet_vCont): Likewise.
1352 (disable_packet_Tthread): Likewise.
1353 (disable_packet_qC): Likewise.
1354 (disable_packet_qfThreadInfo): Likewise.
1355 (run_once): Likewise.
1356 (non_stop): Likewise.
1357 * target.c (target_stop_and_wait): Update.
1359 2019-10-02 Tom Tromey <tromey@adacore.com>
1361 * Makefile.in (SFILES): Add common-inferior.c.
1362 (OBS): Add common-inferior.o.
1363 * server.c (startup_with_shell): Don't define.
1365 2019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
1367 * linux-low.c (linux_low_read_btrace): Update for change to
1370 2019-09-20 Christian Biesinger <cbiesinger@google.com>
1372 * debug.c (debug_threads): Remove comment in favor of the header.
1373 * debug.h (using_threads): Add declaration.
1374 (debug_threads): Add comment.
1375 * linux-aarch64-low.c: Include debug.h and remove declaration of
1377 * nto-low.c: Likewise.
1378 * remote-utils.c: Likewise.
1379 * thread-db.c: Likewise.
1381 2019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
1383 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
1384 and powerpc-cell64l-ipa.o.
1385 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
1386 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
1387 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
1390 * spu-low.c: Remove file.
1392 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
1393 (parse_spufs_run): Remove.
1394 (ppc_get_pc): Remove Cell/B.E. support.
1395 (ppc_set_pc): Likewise.
1396 (ppc_breakpoint_at): Likewise.
1397 (ppc_arch_setup): Likewise.
1398 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
1399 tdesc_powerpc_cell32l.
1400 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
1401 or init_registers_powerpc_cell32l.
1402 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
1403 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
1404 or init_registers_powerpc_cell32l.
1405 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
1406 (init_registers_powerpc_cell32l): Remove prototype.
1407 (init_registers_powerpc_cell64l): Likewise.
1409 * target.h (struct target_ops): Remove qxfer_spu member.
1410 * server.c (handle_qxfer_spu): Remove.
1411 (qxfer_packets): Remove entry for "spu".
1412 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
1413 * linux-low.c (SPUFS_MAGIC): Remove.
1414 (spu_enumerate_spu_ids): Remove.
1415 (linux_qxfer_spu): Remove.
1416 (linux_target_ops): Remove qxfer_spu member.
1417 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
1418 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
1419 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
1421 2019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
1423 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
1424 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
1425 * config.in: Regenerate.
1426 * configure: Regenerate.
1428 2019-08-15 Tom Tromey <tromey@adacore.com>
1430 * target.c (target_write_memory): Use gdb::byte_vector.
1432 2019-08-15 Tom Tromey <tromey@adacore.com>
1434 * tracepoint.c (write_inferior_data_pointer)
1435 (write_inferior_integer, write_inferior_int8)
1436 (write_inferior_uinteger, m_tracepoint_action_download)
1437 (r_tracepoint_action_download, x_tracepoint_action_download)
1438 (l_tracepoint_action_download, clear_inferior_trace_buffer)
1439 (download_agent_expr, download_tracepoint_1)
1440 (download_trace_state_variables, upload_fast_traceframes): Update.
1441 * server.c (gdb_write_memory): Update.
1442 * remote-utils.c (relocate_instruction): Update.
1443 * proc-service.c (ps_pdwrite): Update.
1444 * mem-break.c (remove_memory_breakpoint)
1445 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
1446 (uninsert_fast_tracepoint_jumps_at)
1447 (reinsert_fast_tracepoint_jumps_at): Update.
1448 * linux-x86-low.c (append_insns)
1449 (i386_install_fast_tracepoint_jump_pad)
1450 (amd64_write_goto_address, i386_write_goto_address): Update.
1451 * linux-s390-low.c (append_insns, s390_write_goto_address):
1453 * linux-ppc-low.c (ppc_relocate_instruction)
1454 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
1455 (ppc_write_goto_address): Update.
1456 * linux-aarch64-low.c (append_insns): Update.
1457 * target.h (struct target_ops): Update.
1458 (write_inferior_memory): Don't declare.
1459 * target.c (target_write_memory): Rename from
1460 write_inferior_memory. Remove old target_write_memory.
1462 2019-08-15 Tom Tromey <tromey@adacore.com>
1464 * target.c (write_inferior_memory): Use std::vector.
1466 2019-08-06 Frank Ch. Eigler <fche@redhat.com>
1469 * configure.ac: Drop enable-libmcheck support.
1470 * configure, config.in: Rebuild.
1471 * acinclude.m4: Don't include it.
1473 2019-07-19 Alan Hayward <alan.hayward@arm.com>
1475 * configure.srv: Remove Arm xml files.
1477 2019-07-19 Alan Hayward <alan.hayward@arm.com>
1479 * configure.srv: Add new files. Remove xml generated files.
1480 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
1482 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
1483 * linux-aarch32-tdesc.c: New file.
1484 * linux-aarch32-tdesc.h: New file.
1485 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
1486 * linux-arm-low.c (init_registers_arm, tdesc_arm)
1487 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
1488 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
1489 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
1490 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
1491 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
1492 (arm_read_description): Call arm_linux_read_description.
1493 (initialize_low_arch): Don't init registers.
1494 * linux-arm-tdesc.c: New file.
1495 * linux-arm-tdesc.h: New file.
1497 2019-07-10 Alan Hayward <alan.hayward@arm.com>
1499 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
1500 Move counter inside for.
1501 (arm_read_description): Check ptrace earlier.
1502 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
1504 2019-07-09 Tom Tromey <tom@tromey.com>
1506 * configure: Rebuild.
1507 * configure.ac: Change common to gdbsupport.
1508 * acinclude.m4: Change common to gdbsupport.
1509 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
1510 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
1511 common to gdbsupport.
1512 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
1513 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
1514 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
1515 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
1516 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
1517 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
1518 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
1519 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
1520 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
1521 common to gdbsupport.
1523 2019-07-04 Alan Hayward <alan.hayward@arm.com>
1525 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
1527 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
1529 2019-07-04 Alan Hayward <alan.hayward@arm.com>
1531 * configure.srv: Remove legacy xml.
1532 * linux-aarch64-low.c (initialize_low_arch): Remove
1533 initialize_low_tdesc call.
1534 * linux-aarch64-tdesc-selftest.c: Remove file.
1535 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
1536 * linux-x86-low.c (initialize_low_arch): Remove
1537 initialize_low_tdesc call.
1538 * linux-x86-tdesc-selftest.c: Remove file.
1539 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
1541 2019-06-20 Tom de Vries <tdevries@suse.de>
1543 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
1544 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
1546 2019-06-19 Tom de Vries <tdevries@suse.de>
1548 * debug.h (debug_write): Change return type to ssize_t.
1549 * debug.c (debug_write): Same.
1551 2019-06-14 Tom Tromey <tom@tromey.com>
1553 * configure.ac: Use new path to gnulib.
1554 * configure: Rebuild.
1555 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
1558 2019-06-11 Tom Tromey <tom@tromey.com>
1560 * Makefile.in (SFILES): Add alloc.c.
1562 (IPA_OBJS): Add alloc-ipa.o.
1563 (alloc-ipa.o): New target.
1564 (%.o: ../%.c): New pattern rule.
1566 2019-06-10 Tom Tromey <tromey@adacore.com>
1568 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
1569 end warning with a newline.
1570 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
1572 * thread-db.c (attach_thread): Don't end warning with a newline.
1573 (thread_db_notice_clone): Likewise.
1574 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
1576 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
1577 end warning with a newline.
1579 2019-06-04 Pedro Alves <palves@redhat.com>
1581 * server.c (captured_main): Use make_unique_xstrdup.
1583 2019-06-02 Tom Tromey <tom@tromey.com>
1585 * gdbreplay.c (fromhex): Remove.
1586 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
1588 2019-05-29 Tom Tromey <tromey@adacore.com>
1590 * configure: Rebuild.
1592 2019-05-06 Kevin Buettner <kevinb@redhat.com>
1594 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
1595 sign extension code on 32-bit builds.
1597 2019-05-03 Eli Zaretskii <eliz@gnu.org>
1600 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
1602 2019-04-19 Tom Tromey <tom@tromey.com>
1604 * server.c (struct vstop_notif): Derive from notif_event.
1606 (queue_stop_reply): Update.
1607 (remove_all_on_match_ptid): Change type. Rewrite.
1608 (discard_queued_stop_replies): Rewrite.
1609 (in_queued_stop_replies_ptid): Change type.
1610 (in_queued_stop_replies): Rewrite.
1611 (notif_stop): Update.
1612 (queue_stop_reply_callback): Update.
1613 (captured_main): Don't call initialize_notif.
1614 (push_stop_notification): Update.
1615 * notif.c (notif_write_event, handle_notif_ack)
1616 (notif_event_enque, notif_push): Update.
1617 (notif_event_xfree, initialize_notif): Remove.
1618 * notif.h (struct notif_event): Include <list>, not
1620 (struct notif_server) <queue>: Now a std::list.
1621 (notif_event_p): Remove typedef.
1622 (initialize_notif): Don't declare.
1623 (struct notif_event): Add virtual destructor.
1625 2019-04-17 Alan Hayward <alan.hayward@arm.com>
1627 * ax.c (ax_vdebug): Call debug_printf.
1628 * debug.c (debug_write): New function.
1629 * debug.h (debug_write): New declaration.
1630 * linux-low.c (sigchld_handler): Call debug_write.
1632 2019-04-17 Alan Hayward <alan.hayward@arm.com>
1634 * debug.c (debug_set_output): New function.
1635 (debug_vprintf): Send output to debug_file.
1636 (debug_flush): Likewise.
1637 * debug.h (debug_set_output): New declaration.
1638 * server.c (handle_monitor_command): Add debug-file option.
1639 (captured_main): Likewise.
1641 2019-04-17 Alan Hayward <alan.hayward@arm.com>
1643 * debug.c (remote_debug): Add definition.
1644 * debug.h (remote_debug): Add declaration.
1645 * hostio.c (remote_debug): Remove declaration.
1646 * remote-utils.c (struct ui_file): Likewise.
1647 (remote_debug): Likewise.
1648 * remote-utils.h (remote_debug): Likewise,
1649 * server.c (remote_debug): Remove definition.
1651 2019-04-10 Kevin Buettner <kevinb@redhat.com>
1653 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
1654 when using a 64-bit gdbserver.
1656 2019-04-09 Tom Tromey <tromey@adacore.com>
1658 * linux-low.c (select_event_lwp): Use find_thread_in_random.
1660 2019-04-08 Tom Tromey <tom@tromey.com>
1662 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
1664 (linux_resume_one_lwp): Likewise.
1666 2019-04-08 Tom Tromey <tom@tromey.com>
1668 * gdbreplay.c: Update.
1669 * linux-low.c: Update.
1672 2019-04-08 Tom Tromey <tom@tromey.com>
1674 * server.c: Use C++ exception handling.
1675 * linux-low.c: Use C++ exception handling.
1676 * gdbreplay.c: Use C++ exception handling.
1678 2019-04-08 Tom Tromey <tom@tromey.com>
1680 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
1681 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
1682 (captured_main, main): Update.
1683 * gdbreplay.c (main): Update.
1685 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1687 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
1688 value in argument pointer, return 1 if the entry is found and 0
1689 otherwise. Move comment.
1690 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
1691 * linux-low.h (linux_get_auxv): Declare.
1692 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
1694 2019-04-05 Tom Tromey <tromey@adacore.com>
1696 * server.c (gdbserver_usage): Use upper-case for metasyntactic
1699 2019-03-28 Alan Hayward <alan.hayward@arm.com>
1701 * linux-low.c (AT_HWCAP2): Add define if not already included.
1703 2019-03-26 Alan Hayward <alan.hayward@arm.com>
1705 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
1706 (aarch64_arch_setup): Call linux_get_hwcap.
1707 * linux-arm-low.c (arm_get_hwcap): Remove function.
1708 (arm_read_description): Call linux_get_hwcap.
1709 * linux-low.c (linux_get_auxv): New function.
1710 (linux_get_hwcap): Likewise.
1711 (linux_get_hwcap2): Likewise.
1712 * linux-low.h (linux_get_hwcap): New declaration.
1713 (linux_get_hwcap2): Likewise.
1714 * linux-ppc-low.c (ppc_get_auxv): Remove function.
1715 (ppc_arch_setup): Call linux_get_hwcap.
1716 * linux-s390-low.c (s390_get_hwcap): Remove function.
1717 (s390_arch_setup): Call linux_get_hwcap.
1719 2019-03-22 Alan Hayward <alan.hayward@arm.com>
1720 Jiong Wang <jiong.wang@arm.com>
1722 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
1723 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
1725 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
1727 2019-03-22 Alan Hayward <alan.hayward@arm.com>
1728 Jiong Wang <jiong.wang@arm.com>
1730 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
1731 (aarch64_get_hwcap): New function.
1732 (aarch64_arch_setup): Read APIA hwcap.
1734 2019-03-22 Alan Hayward <alan.hayward@arm.com>
1735 Jiong Wang <jiong.wang@arm.com>
1737 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
1738 (initialize_low_tracepoint): Likewise.
1739 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
1740 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
1741 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
1742 (aarch64_linux_read_description): Likewise.
1743 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
1745 2019-03-12 John Baldwin <jhb@FreeBSD.org>
1747 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
1748 i386_create_target_description for 'segments' parameter.
1749 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
1750 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
1751 * win32-i386-low.c (i386_arch_setup): Likewise.
1753 2019-03-12 Tom Tromey <tromey@adacore.com>
1755 * linux-low.c (iterate_over_lwps): Update.
1757 2019-03-06 Tom Tromey <tom@tromey.com>
1759 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
1760 (captured_main): Use SCOPE_EXIT.
1762 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
1764 * configure.srv: Use '$enable_unittest' instead of '$development'
1765 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
1768 2019-02-27 Tom Tromey <tromey@adacore.com>
1770 * gdbreplay.c (logchar): Handle \r\n.
1772 2019-02-07 Alan Hayward <alan.hayward@arm.com>
1774 * linux-low.c (linux_attach): Add process before lwp.
1775 * server.c (attach_inferior): Check if already attached.
1777 2019-02-07 Tom Tromey <tom@tromey.com>
1779 * x86-tdesc.h: Rename include guard.
1780 * x86-low.h: Add include guard.
1781 * wincecompat.h: Rename include guard.
1782 * win32-low.h: Add include guard.
1783 * utils.h: Rename include guard.
1784 * tracepoint.h: Rename include guard.
1785 * tdesc.h: Rename include guard.
1786 * target.h: Rename include guard.
1787 * server.h: Rename include guard.
1788 * remote-utils.h: Rename include guard.
1789 * regcache.h: Rename include guard.
1790 * nto-low.h: Rename include guard.
1791 * notif.h: Add include guard.
1792 * mem-break.h: Rename include guard.
1793 * lynx-low.h: Add include guard.
1794 * linux-x86-tdesc.h: Add include guard.
1795 * linux-s390-tdesc.h: Add include guard.
1796 * linux-ppc-tdesc-init.h: Add include guard.
1797 * linux-low.h: Add include guard.
1798 * linux-aarch64-tdesc.h: Add include guard.
1799 * linux-aarch32-low.h: Add include guard.
1800 * inferiors.h: Rename include guard.
1801 * i387-fp.h: Rename include guard.
1802 * hostio.h: Rename include guard.
1803 * gdbthread.h: Rename include guard.
1804 * gdb_proc_service.h: Rename include guard.
1805 * event-loop.h: Rename include guard.
1806 * dll.h: Rename include guard.
1807 * debug.h: Rename include guard.
1808 * ax.h: Rename include guard.
1810 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
1813 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
1814 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
1816 2019-01-25 Tom Tromey <tom@tromey.com>
1818 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
1820 2019-01-25 Tom Tromey <tom@tromey.com>
1822 * win32-low.c: Fix common/ includes.
1823 * win32-i386-low.c: Fix common/ includes.
1824 * tracepoint.c: Fix common/ includes.
1825 * thread-db.c: Fix common/ includes.
1826 * target.h: Fix common/ includes.
1827 * symbol.c: Fix common/ includes.
1828 * spu-low.c: Fix common/ includes.
1829 * server.h: Fix common/ includes.
1830 * server.c: Fix common/ includes.
1831 * remote-utils.c: Fix common/ includes.
1832 * regcache.h: Fix common/ includes.
1833 * regcache.c: Fix common/ includes.
1834 * nto-x86-low.c: Fix common/ includes.
1835 * notif.h: Fix common/ includes.
1836 * mem-break.h: Fix common/ includes.
1837 * lynx-low.c: Fix common/ includes.
1838 * lynx-i386-low.c: Fix common/ includes.
1839 * linux-x86-tdesc-selftest.c: Fix common/ includes.
1840 * linux-x86-low.c: Fix common/ includes.
1841 * linux-low.c: Fix common/ includes.
1842 * inferiors.h: Fix common/ includes.
1843 * i387-fp.c: Fix common/ includes.
1844 * hostio.c: Fix common/ includes.
1845 * hostio-errno.c: Fix common/ includes.
1846 * gdbthread.h: Fix common/ includes.
1847 * gdbreplay.c: Fix common/ includes.
1848 * fork-child.c: Fix common/ includes.
1849 * event-loop.c: Fix common/ includes.
1851 (enum gdb_agent_op): Fix common/ includes.
1853 2019-01-21 Tom Tromey <tom@tromey.com>
1855 * tracepoint.c: Fix includes.
1856 * remote-utils.c: Fix includes.
1857 * linux-x86-low.c: Fix includes.
1859 2019-01-01 Joel Brobecker <brobecker@adacore.com>
1861 * gdbreplay.c (gdbreplay_version): Update copyright year in
1863 * server.c (gdbserver_version): Likewise.
1865 2018-12-05 Alan Hayward <alan.hayward@arm.com>
1867 * linux-low.c (add_lwp): Switch ordering.
1869 2018-11-29 Tom Tromey <tom@tromey.com>
1871 * win32-low.c (win32_join): Take pid, not process.
1872 * target.h (struct target_ops) <join>: Change argument type.
1873 (join_inferior): Change argument name.
1874 * spu-low.c (spu_join): Take pid, not process.
1875 * server.c (handle_detach): Preserve pid before destroying
1877 * lynx-low.c (lynx_join): Take pid, not process.
1878 * linux-low.c (linux_join): Take pid, not process.
1880 2018-11-23 Alan Hayward <alan.hayward@arm.com>
1882 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
1883 (aarch64_cannot_fetch_register): Likewise.
1884 (struct linux_target_ops): Update references.
1886 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1888 * linux-ppc-low.c: Include nat/linux-ptrace.h.
1890 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1892 * configure.srv (ipa_ppc_linux_regobj): Add
1893 powerpc-isa207-htm-vsx32l-ipa.o and
1894 powerpc-isa207-htm-vsx64l-ipa.o.
1895 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
1896 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
1897 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
1898 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
1899 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
1900 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
1901 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
1902 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
1903 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
1904 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
1905 (init_registers_powerpc_isa207_htm_vsx32l)
1906 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
1907 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
1908 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
1909 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
1910 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
1911 (ppc_store_tm_ctarregset): New functions.
1912 (ppc_regsets): Add entries for HTM regsets.
1913 (ppc_arch_setup): Set htm in features struct when needed. Set
1914 sizes for the HTM regsets.
1915 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
1916 (initialize_low_arch): Call
1917 init_registers_powerpc_isa207_htm_vsx32l and
1918 init_registers_powerpc_isa207_htm_vsx64l.
1919 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
1920 PPC_TDESC_ISA207_HTM_VSX.
1921 (initialize_low_tracepoint): Call
1922 init_registers_powerpc_isa207_htm_vsx32l and
1923 init_registers_powerpc_isa207_htm_vsx64l.
1925 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1927 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
1928 rs6000/power-linux-pmu.xml to srv_xmlfiles.
1929 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
1930 (ppc_store_pmuregset): New functions.
1931 (ppc_regsets): Add entries for ebb and pmu regsets.
1932 (ppc_arch_setup): Set isa207 in features struct if the ebb and
1933 pmu regsets are available. Set sizes for these regsets.
1935 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1937 * configure.srv (ipa_ppc_linux_regobj): Add
1938 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
1939 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
1940 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
1941 rs6000/powerpc-isa207-vsx32l.xml, and
1942 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
1943 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
1944 <PPC_TDESC_ISA207_VSX>: New enum value.
1945 (init_registers_powerpc_isa207_vsx32l): Declare.
1946 (init_registers_powerpc_isa207_vsx64l): Declare.
1947 * linux-ppc-low.c (ppc_fill_tarregset): New function.
1948 (ppc_store_tarregset): New function.
1949 (ppc_regsets): Add entry for the TAR regset.
1950 (ppc_arch_setup): Set isa207 in features struct when needed. Set
1951 size for the TAR regsets.
1952 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
1953 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
1954 and init_registers_powerpc_isa207_vsx64l.
1955 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
1956 (initialize_low_tracepoint): Call
1957 init_registers_powerpc_isa207_vsx32l and
1958 init_registers_powerpc_isa207_vsx64l.
1960 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
1961 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1963 * configure.srv (ipa_ppc_linux_regobj): Add
1964 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
1965 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
1966 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
1967 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
1968 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
1969 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
1970 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
1971 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
1972 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
1973 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
1974 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
1975 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
1976 (ppc_hwcap): Add comment.
1977 (ppc_hwcap2): New global.
1978 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
1979 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
1980 (ppc_regsets): Add entries for the DSCR and PPR regsets.
1981 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
1982 when needed. Set sizes for the the DSCR and PPR regsets.
1983 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
1984 (initialize_low_arch): Call
1985 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
1986 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
1987 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
1988 PPC_TDESC_ISA205_PPR_DSCR_VSX.
1989 (initialize_low_tracepoint): Call
1990 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
1991 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
1993 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1995 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
1997 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
1998 Simon Marchi <simark@simark.ca>
2000 * acinclude.m4: Include "../selftest.m4".
2001 * configure: Regenerate.
2002 * configure.ac: Use "GDB_AC_SELFTEST".
2003 * configure.srv: Use "$enable_unittests" instead of
2004 "$development" when checking whether unit tests have been
2006 * server.c (captured_main): Update message informing that
2007 selftests have been disabled.
2009 2018-10-04 Tom Tromey <tom@tromey.com>
2011 * configure: Rebuild.
2013 2018-10-04 Tom Tromey <tom@tromey.com>
2015 * server.c (handle_status): Rename inner "thread".
2016 (process_serial_event): Declare "res" in 'm' case.
2017 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
2018 (iterate_over_lwps): Rename inner "thread".
2019 (linux_qxfer_libraries_svr4): Rename inner "len".
2020 * gdbthread.h (find_thread_in_random): Rename inner "thread".
2022 2018-10-01 Gary Benson <gbenson@redhat.com>
2024 * gdb_proc_service.h: Moved common code to
2025 common/gdb_proc_service.h.
2027 2018-10-01 Gary Benson <gbenson@redhat.com>
2029 * gdb_proc_service.h: Synchronize comments and whitespace with
2030 GDB's version of this file.
2032 2018-09-25 Tom Tromey <tom@tromey.com>
2034 * configure: Rebuild.
2035 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
2037 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
2039 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
2040 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
2041 ($(IPA_LIB)): Sort IPA_OBJS.
2043 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
2045 * Makefile.in: Remove references to $(ADD_DEPS).
2047 2018-09-16 Tom Tromey <tom@tromey.com>
2049 * remote-utils.c (remote_open): Use GNU style for metasyntactic
2051 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
2054 2018-09-05 Tom Tromey <tom@tromey.com>
2056 * configure: Rebuild.
2058 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
2061 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
2063 2018-08-27 Tom Tromey <tom@tromey.com>
2066 * configure: Rebuild.
2068 2018-08-27 Tom Tromey <tom@tromey.com>
2070 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
2071 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
2072 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
2073 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
2074 (s390x_emit_stack_adjust): Add casts to unsigned char.
2076 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
2080 * server.h (struct client_state) <disable_randomization>:
2083 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2085 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
2087 (mips_supply_ptrace_register): Likewise.
2089 2018-07-22 Tom Tromey <tom@tromey.com>
2091 * configure: Rebuild.
2093 2018-07-22 Tom Tromey <tom@tromey.com>
2095 * win32-low.c (win32_create_inferior): Remove unused variables.
2096 * gdbreplay.c (remote_open): Remove unused variable.
2097 * remote-utils.c (remote_prepare): Remove unused variable.
2098 * x86-tdesc.h (X86_TDESC_H): Define.
2099 (amd64_expedite_regs): Define conditionally.
2100 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
2101 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
2102 * remote-utils.c (readchar): Remove unused variable.
2104 2018-07-13 Pedro Alves <palves@redhat.com>
2106 * linux-low.c (linux_kill): Change parameter to process_info
2107 pointer instead of pid. Adjust.
2108 * lynx-low.c (lynx_kill): Likewise.
2109 * nto-low.c (nto_kill): Likewise.
2110 * spu-low.c (spu_kill): Likewise.
2111 * win32-low.c (win32_kill): Likewise.
2112 * server.c (handle_v_kill, kill_inferior_callback)
2113 (detach_or_kill_for_exit): Adjust.
2114 * target.c (kill_inferior): Change parameter to process_info
2115 pointer instead of pid. Adjust.
2116 * target.h (struct target_ops) <kill>: Change parameter to
2117 process_info pointer instead of pid. Adjust all implementations
2119 (kill_inferior): Likewise.
2121 2018-07-13 Pedro Alves <palves@redhat.com>
2123 * linux-low.c (linux_detach, linux_join): Change parameter to
2124 process_info pointer instead of pid. Adjust.
2125 * lynx-low.c (lynx_detach, lynx_join): Likewise.
2126 * nto-low.c (nto_detach): Likewise.
2127 * spu-low.c (spu_detach, spu_join): Likewise.
2128 * win32-low.c (win32_detach, win32_join): Likewise.
2129 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
2130 * target.h (struct target_ops) <detach, join>: Change parameter to
2131 process_info pointer instead of pid. Adjust all implementations
2133 (detach_inferior, join_inferior): Rename 'pid' parameter to
2136 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
2137 Jan Kratochvil <jan.kratochvil@redhat.com>
2138 Paul Fertser <fercerpav@gmail.com>
2139 Tsutomu Seki <sekiriki@gmail.com>
2141 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
2142 (OBS): Add 'common/netstuff.o'.
2143 (GDBREPLAY_OBS): Likewise.
2144 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
2145 (remote_open): Implement support for IPv6
2147 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
2149 (handle_accept_event): Accept connections from IPv6 sources.
2150 (remote_prepare): Handle IPv6-style hostnames; implement
2151 support for IPv6 connections.
2152 (remote_open): Implement support for printing connections from
2155 2018-07-11 Pedro Alves <palves@redhat.com>
2158 * mem-break.c (any_persistent_commands): Add process_info
2159 parameter and use it instead of relying on the current process.
2160 Change return type to bool.
2161 * mem-break.h (any_persistent_commands): Add process_info
2162 parameter and change return type to bool.
2163 * server.c (handle_detach): Remove require_running_or_return call.
2164 Look up the process_info for the process we're about to detach.
2165 If not found, return back error to GDB. Adjust
2166 any_persistent_commands call to pass down a process pointer.
2168 2018-07-11 Pedro Alves <palves@redhat.com>
2170 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
2171 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
2172 instead of collect_register_by_name.
2173 * regcache.c (regcache_raw_get_unsigned_by_name): New.
2174 * regcache.h (regcache_raw_get_unsigned_by_name): New.
2176 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
2177 Pedro Alves <palves@redhat.com>
2179 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
2181 2018-07-03 Tom Tromey <tom@tromey.com>
2183 * linux-low.c: Update.
2184 * lynx-low.c: Update.
2185 * mem-break.c: Update.
2186 * nto-low.c: Update.
2187 * remote-utils.c: Update.
2189 * spu-low.c: Update.
2191 * win32-low.c: Update.
2193 2018-07-03 Tom Tromey <tom@tromey.com>
2197 2018-07-03 Tom Tromey <tom@tromey.com>
2199 * linux-low.c: Update.
2201 2018-07-03 Tom Tromey <tom@tromey.com>
2205 2018-07-03 Tom Tromey <tom@tromey.com>
2207 * linux-low.c: Update.
2208 * linux-mips-low.c: Update.
2209 * lynx-low.c: Update.
2210 * nto-low.c: Update.
2211 * remote-utils.c: Update.
2213 * spu-low.c: Update.
2215 * thread-db.c: Update.
2217 2018-07-03 Tom Tromey <tom@tromey.com>
2219 * linux-low.c: Update.
2220 * linux-mips-low.c: Update.
2221 * lynx-low.c: Update.
2222 * mem-break.c: Update.
2223 * nto-low.c: Update.
2224 * remote-utils.c: Update.
2226 * spu-low.c: Update.
2228 * tracepoint.c: Update.
2230 2018-07-03 Tom Tromey <tom@tromey.com>
2232 * linux-low.c: Update.
2233 * linux-ppc-low.c: Update.
2234 * linux-x86-low.c: Update.
2235 * proc-service.c: Update.
2237 * spu-low.c: Update.
2238 * thread-db.c: Update.
2239 * win32-low.c: Update.
2241 2018-07-03 Tom Tromey <tom@tromey.com>
2243 * linux-low.c: Update.
2244 * lynx-low.c: Update.
2245 * nto-low.c: Update.
2246 * remote-utils.c: Update.
2247 * spu-low.c: Update.
2248 * thread-db.c: Update.
2249 * win32-low.c: Update.
2251 2018-06-29 Joel Brobecker <brobecker@adacore.com>
2253 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
2254 parameter in call to 'amd64_create_target_description'.
2256 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
2258 * x86-tdesc.h: Remove executable permission flag.
2260 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
2262 * configure.ac: Remove AC_PREREQ, add missing quoting.
2263 * configure: Re-generate.
2264 * config.in: Re-generate.
2265 * aclocal.m4: Re-generate.
2267 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
2269 * tracepoint.h (current_traceframe): Remove declaration.
2271 2018-06-18 Alan Hayward <alan.hayward@arm.com>
2273 * linux-aarch64-low.c (is_sve_tdesc): New function.
2274 (aarch64_sve_regs_copy_to_regcache): Likewise.
2275 (aarch64_sve_regs_copy_from_regcache): Likewise.
2276 (aarch64_regs_info): Add SVE checks.
2277 (initialize_low_arch): Initialize SVE.
2279 2018-06-18 Alan Hayward <alan.hayward@arm.com>
2281 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
2283 2018-06-11 Alan Hayward <alan.hayward@arm.com>
2285 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
2286 (initialize_low_tracepoint): Likewise
2287 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
2288 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
2290 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
2292 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
2294 2018-06-11 Alan Hayward <alan.hayward@arm.com>
2296 * server.h (PBUFSIZ): Increase size
2298 2018-06-11 Alan Hayward <alan.hayward@arm.com>
2300 * regcache.c (regcache::raw_compare): New function.
2301 * regcache.h (regcache::raw_compare): New declaration.
2303 2018-06-11 Alan Hayward <alan.hayward@arm.com>
2305 * regcache.c (new_register_cache): Use new.
2306 (free_register_cache): Use delete.
2307 (register_data): Use const.
2308 (supply_register): Move body inside regcache.
2309 (regcache::raw_supply): New override function.
2310 (collect_register): Move body inside regcache.
2311 (regcache::raw_collect): New override function.
2312 (regcache::get_register_status): New override function.
2313 * regcache.h (struct regcache): Inherit from reg_buffer_common.
2315 2018-06-09 Tom Tromey <tom@tromey.com>
2317 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
2319 (event_queue): Use std::queue.
2320 (gdb_event_xfree): Remove.
2321 (initialize_event_loop, process_event, wait_for_event): Update.
2323 2018-06-08 Stan Cox <scox@redhat.com>
2325 * win32-low.c (win32_create_inferior): last_ptid and last_status
2326 moved to client_state.
2328 2018-06-08 Pedro Alves <palves@redhat.com>
2330 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
2331 common/common-exceptions.o, common/common-utils.o,
2332 common/errors.o, common/print-utils.o and utils.o.
2333 * gdbreplay.c: Include "common-defs.h" instead of the two
2334 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
2335 string.h or alloca.h.
2336 (perror_with_name): Delete.
2337 (remote_open): Use xstrdup instead of strdup.
2338 (main): Rename to ...
2339 (captured_main): ... this.
2342 2018-06-08 Tom Tromey <tom@tromey.com>
2344 * linux-low.c (linux_low_read_btrace): Update.
2346 2018-06-04 Stan Cox <scox@redhat.com>
2348 * server.h (struct client_state): New.
2349 * server.c (cont_thread, general_thread, multi_process)
2350 (report_fork_events, report_vfork_events, report_exec_events)
2351 (report_thread_events, swbreak_feature, hwbreak_feature)
2352 (vCont_supported, disable_randomization, pass_signals)
2353 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
2354 Moved to client_state.
2355 * remote-utils.c (remote_debug, noack_mode)
2356 (transport_is_reliable): Moved to client_state.
2357 * tracepoint.c (current_traceframe): Moved to client_state.
2360 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
2361 linux-low.c, remote-utils.h, target.c: Use client_state.
2363 2018-05-31 Alan Hayward <alan.hayward@arm.com>
2365 * configure.srv: Add new c/h file.
2367 2018-05-31 Alan Hayward <alan.hayward@arm.com>
2369 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
2372 2018-05-25 Maciej W. Rozycki <macro@mips.com>
2374 * gdb.arch/mips-fpregset-core.exp: New test.
2375 * gdb.arch/mips-fpregset-core.c: New test source.
2377 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
2380 * hostio.c (require_int): Do not report overflow for integers
2381 between 0xfffffff and 0x7fffffff.
2383 2018-05-22 Maciej W. Rozycki <macro@mips.com>
2385 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
2386 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
2387 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
2389 (the_low_target): Wire them.
2391 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2393 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
2394 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
2395 mode. Call collect_register_by_name with vscr using
2396 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
2397 (ppc_store_vrregset): Add and set vscr_offset variable as in
2398 ppc_fill_vrregset. Call supply_register_by_name with vscr using
2401 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2403 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
2404 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
2405 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
2407 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2409 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
2410 (ppc_store_vsxregset): Likewise.
2411 (ppc_fill_vrregset): Likewise.
2412 (ppc_store_vrregset): Likewise.
2413 (ppc_fill_evrregset): Likewise.
2414 (ppc_store_evrregset): Likewise.
2415 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
2416 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
2419 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2421 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
2422 wordsize of the inferior. Call ppc_linux_target_wordsize.
2424 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2426 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
2427 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
2428 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
2429 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
2430 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
2431 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
2432 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
2433 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
2434 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
2435 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
2436 (tdesc_powerpc_e500l): Remove.
2437 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
2438 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
2439 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
2440 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
2442 (ppc_arch_setup): Remove target description matching code. Fill a
2443 ppc_linux_features struct and call ppc_linux_match_description
2446 2018-05-22 Maciej W. Rozycki <macro@mips.com>
2448 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
2449 width of the requested register exceeds the width of the
2451 (mips_cannot_store_register): Likewise.
2453 2018-05-21 Maciej W. Rozycki <macro@mips.com>
2455 * linux-mips-low.c (mips_fetch_register): New function. Update
2457 (mips_store_gregset): Supply 0 rather than $restart for $zero.
2458 (the_low_target): Wire `mips_fetch_register'.
2460 2018-05-10 Joel Brobecker <brobecker@adacore.com>
2462 * lynx-i386-low.c (LYNXOS_178): New macro.
2463 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
2464 the layout on LynxOS-178.
2465 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
2466 handle floating point registers that are not supported by
2469 2018-05-10 Tom Tromey <tom@tromey.com>
2471 * configure: Rebuild.
2473 2018-05-10 Joel Brobecker <brobecker@adacore.com>
2476 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
2477 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
2478 Use it to set the expedite_regs field in the given tdesc.
2479 * x86-tdesc.h: New file.
2480 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
2481 Adjust following the addition of the new expedite_regs parameter
2482 to init_target_desc.
2483 * linux-tic6x-low.c (tic6x_read_description): Likewise.
2484 * linux-x86-tdesc.c: #include "x86-tdesc.h".
2485 (i386_linux_read_description, amd64_linux_read_description):
2486 Adjust following the addition of the new expedite_regs parameter
2487 to init_target_desc.
2488 * lynx-i386-low.c: #include "x86-tdesc.h".
2489 (lynx_i386_arch_setup): Adjust following the addition of the new
2490 expedite_regs parameter to init_target_desc.
2491 * nto-x86-low.c: #include "x86-tdesc.h".
2492 (nto_x86_arch_setup): Adjust following the addition of the new
2493 expedite_regs parameter to init_target_desc.
2494 * win32-i386-low.c: #include "x86-tdesc.h".
2495 (i386_arch_setup): Adjust following the addition of the new
2496 expedite_regs parameter to init_target_desc.
2498 2018-05-10 Joel Brobecker <brobecker@adacore.com>
2501 * win32-low.c (win32_create_inferior): Add call to my_wait
2502 setting last_status global.
2504 2018-05-10 Joel Brobecker <brobecker@adacore.com>
2507 * win32-low.c (create_process): Only call gdb_tilde_expand if
2508 inferior_cwd is not NULL.
2510 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
2512 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
2513 registers to the cache if their values have changed.
2514 (i387_xsave_to_cache): Provide default values for x87 control
2515 registers when these features are available, but disabled.
2516 * regcache.c (supply_register_by_name_zeroed): New function.
2517 * regcache.h (supply_register_by_name_zeroed): Declare new
2520 2018-05-07 Tom Tromey <tom@tromey.com>
2522 * configure: Rebuild.
2524 2018-05-04 Tom Tromey <tom@tromey.com>
2526 * configure: Rebuild.
2528 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
2529 Pedro Alves <palves@redhat.com>
2531 * linux-aarch64-low.c (aarch64_stopped_data_address):
2534 2018-04-27 Tom Tromey <tom@tromey.com>
2536 * configure: Rebuild.
2538 2018-04-23 Tom Tromey <tom@tromey.com>
2540 * configure: Rebuild.
2542 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
2544 * Makefile.in (depcomp): Add "..".
2545 (all_deps_files): New and use it.
2547 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2549 * configure.srv (aarch64*-*-linux*): Don't include xml.
2550 (i[34567]86-*-cygwin*): Likewise.
2551 (i[34567]86-*-linux*): Likewise.
2552 (i[34567]86-*-lynxos*): Likewise.
2553 (i[34567]86-*-mingw32ce*): Likewise.
2554 (i[34567]86-*-mingw*): Likewise.
2555 (i[34567]86-*-nto*): Likewise.
2556 (tic6x-*-uclinux): Likewise.
2557 (x86_64-*-linux*): Likewise.
2558 (x86_64-*-mingw*): Likewise.
2559 (x86_64-*-cygwin*): Likewise.
2561 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2563 * tdesc.c: Remove xml parameter.
2565 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2567 * server.c (get_features_xml): Remove cast.
2568 * tdesc.c (void target_desc::accept): Fill in function.
2569 (tdesc_get_features_xml): Remove old xml creation.
2570 (print_xml_feature::visit_pre): Add xml vistor.
2571 * tdesc.h (struct target_desc): Make xmltarget mutable.
2572 (tdesc_get_features_xml): Remove declaration.
2574 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2576 * tdesc.c (tdesc_architecture_name): Add new function.
2577 (tdesc_osabi_name): Likewise.
2578 (tdesc_get_features_xml): Use new functions.
2580 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2582 * tdesc.c (tdesc_create_flags): Remove.
2583 (tdesc_add_flag): Likewise.
2584 (tdesc_named_type): Likewise.
2585 (tdesc_create_union): Likewise.
2586 (tdesc_create_struct): Likewise.
2587 (tdesc_create_vector): Likewise.
2588 (tdesc_add_bitfield): Likewise.
2589 (tdesc_add_field): Likewise.
2590 (tdesc_set_struct_size): Likewise.
2592 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2594 * tdesc.c (~target_desc): Remove implictly deleted items.
2595 (init_target_desc): Iterate all features.
2596 (tdesc_get_features_xml): Use vector.
2597 (tdesc_create_feature): Create feature.
2598 * tdesc.h (tdesc_feature) Remove
2599 (target_desc): Add features.
2601 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2603 * Makefile.in: Add common/tdesc.c
2604 * tdesc.c (init_target_desc): init all reg_defs from register
2606 (tdesc_create_reg): Create tdesc_reg.
2607 * tdesc.h (tdesc_feature): Add register vector.
2609 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
2611 * tdesc.h (struct target_desc) <features>: Change type to
2612 std::vector<std::string>.
2613 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
2615 (tdesc_get_features_xml): Likewise.
2616 (tdesc_create_feature): Likewise.
2618 2018-03-26 Alan Hayward <alan.hayward@arm.com>
2620 * regcache.c (find_register_by_number): Return a ref.
2621 (find_regno): Use references.
2622 (register_size): Likewise.
2623 (register_data): Likewise.
2624 * tdesc.c (target_desc::~target_desc): Remove free calls.
2625 (target_desc::operator==): Use std::vector compare.
2626 (init_target_desc): Use reference.
2627 (tdesc_create_reg): Use reg constructors.
2628 * tdesc.h (struct target_desc): Replace pointer with object.
2630 2018-03-23 Alan Hayward <alan.hayward@arm.com>
2632 * regcache.c (find_register_by_number): Make static.
2633 (find_regno): Use find_register_by_number
2634 * regcache.h (struct reg): Remove declaration.
2636 2018-03-23 Alan Hayward <alan.hayward@arm.com>
2638 * tdesc.c (target_desc::~target_desc): Move to here.
2639 (target_desc::operator==): Likewise.
2640 * tdesc.h (target_desc::~target_desc): Move from here.
2641 (target_desc::operator==): Likewise.
2643 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
2645 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
2647 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
2649 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
2651 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
2652 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
2653 and init_registers_s390_gs_linux64.
2655 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
2657 * linux-s390-low.c (s390_fill_gs): Remove function.
2658 (s390_fill_gsbc): Remove function.
2659 (s390_regsets): Set fill functions for the guarded storage regsets
2662 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
2664 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
2665 the word size. Add comment.
2666 (s390_get_wordsize): New function.
2667 (s390_arch_setup): No longer select a temporary tdesc to fetch the
2668 pswm with it. Instead, use s390_get_wordsize to determine the
2669 word size first and derive the correct tdesc from that directly.
2671 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
2673 * Makefile.in: Include silent-rules.mk.
2674 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
2675 (COMPILE): Add ECHO_CXX.
2676 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
2677 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
2678 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
2679 (version-generated.c): Add ECHO_GEN.
2680 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
2681 (IPAGENT_COMPILE): Add ECHO_CXX.
2682 (%-generated.c): Add ECHO_REGDAT.
2684 2018-03-14 Tom Tromey <tom@tromey.com>
2687 * ax.c (ax_printf): Special case for NULL.
2689 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
2691 * linux-low.c (linux_qxfer_libraries_svr4): Use
2692 xml_escape_text_append.
2694 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
2696 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
2698 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
2700 * server.c (handle_general_set): Remove unnecessary xstrdup.
2702 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
2704 * server.c (parse_debug_format_options): Adjust to
2705 delim_string_to_char_ptr_vec changes.
2706 * thread-db.c (thread_db_load_search): Adjust to
2707 dirnames_to_char_ptr_vec changes.
2709 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
2711 * target.h (target_enable_btrace, target_disable_btrace)
2712 (target_read_btrace, target_read_btrace_conf): Turn macro into
2713 inline function. Throw error if target method is not defined.
2714 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
2715 check for btrace target method. Be prepared to handle exceptions
2716 from btrace target methods.
2718 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
2720 * server.c (captured_main): Change order of error message printed
2721 when the current working directory cannot be found.
2723 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
2725 * server.c: Include "filenames.h" and "pathstuff.h".
2726 (program_name): Delete variable.
2727 (program_path): New anonymous class.
2728 (get_exec_wrapper): Use "program_path" instead of
2730 (handle_v_run): Likewise.
2731 (captured_main): Likewise.
2732 (process_serial_event): Likewise.
2734 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
2736 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
2737 (OBJS): Add "pathstuff.o".
2738 * server.c (current_directory): New global variable.
2739 (captured_main): Initialize "current_directory".
2741 2018-02-26 Alan Hayward <alan.hayward@arm.com>
2743 * tdesc.c: Use common/tdesc.h.
2744 * tdesc.h: Likewise.
2746 2018-02-20 Alan Hayward <alan.hayward@arm.com>
2747 Simon Marchi <simon.marchi@ericsson.com>
2749 * Makefile.in: Switch order of make rules.
2751 2018-02-19 Alan Hayward <alan.hayward@arm.com>
2753 * Makefile.in: Add common directory in build.
2754 * configure.ac: Add common reference.
2755 * configure: Regenerate.
2757 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
2759 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
2760 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
2761 * spu-low.c (spu_target_ops): Likewise.
2762 * win32-low.c (win32_target_ops): Likewise.
2763 * server.c (supported_btrace_packets): Report packets unconditionally.
2764 * target.h (target_ops) <supports_btrace>: Remove.
2765 (target_supports_btrace): Remove.
2767 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
2769 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
2770 (handle_btrace_disable): Change return type to void. Use exceptions
2772 (handle_btrace_general_set): Catch exception and copy message to
2775 2018-02-08 Tom Tromey <tom@tromey.com>
2777 * linux-low.c (install_software_single_step_breakpoints): Use
2778 make_scoped_restore.
2779 * inferiors.c (make_cleanup_restore_current_thread): Remove.
2780 (do_restore_current_thread_cleanup): Remove.
2781 * gdbthread.h (make_cleanup_restore_current_thread): Don't
2784 2018-02-08 Tom Tromey <tom@tromey.com>
2786 * mem-break.c (set_raw_breakpoint_at): Use
2787 gdb::unique_xmalloc_ptr.
2789 2018-01-30 Pedro Alves <palves@redhat.com>
2792 * target.c (target_terminal::terminal_state): Rename to ...
2793 (target_terminal::m_terminal_state): ... this.
2795 2018-01-19 James Clarke <jrtc27@jrtc27.com>
2797 * linux-low.c (handle_extended_wait): Surround call to
2798 thread_db_notice_clone with #ifdef USE_THREAD_DB.
2800 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
2802 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
2803 linux_ptrace_attach_fail_reason_string now returning an
2805 (linux_attach): Likewise.
2806 * thread-db.c (attach_thread): Likewise.
2808 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
2811 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
2812 checking for fs_base/gs_base fields in struct user_regs_struct.
2813 * configure: Regenerate.
2815 2018-01-16 Yao Qi <yao.qi@linaro.org>
2818 * linux-low.c (fetch_register): Call supply_register instead of
2821 2018-01-08 Yao Qi <yao.qi@linaro.org>
2822 Simon Marchi <simon.marchi@ericsson.com>
2824 * Makefile.in (OBS): Remove selftest.o.
2825 * configure.ac: Set srv_selftest_objs if $development is true.
2826 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
2827 * configure: Re-generated.
2828 * server.c (captured_main): Wrap variable selftest_filter with
2831 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
2833 * server.c (parse_debug_format_options): Return std::string.
2834 (handle_monitor_command, captured_main): Adjust.
2836 2018-01-05 Pedro Alves <palves@redhat.com>
2839 * server.c (captured_main): Pass quiet=false to
2840 save_original_signals_state.
2842 2018-01-01 Joel Brobecker <brobecker@adacore.com>
2844 * gdbreplay.c (gdbreplay_version): Update copyright year in
2846 * server.c (gdbserver_version): Likewise.
2848 2017-12-08 Tom Tromey <tom@tromey.com>
2850 * ax.c (ax_printf): Update.
2852 2017-12-07 Yao Qi <yao.qi@linaro.org>
2854 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
2855 aarch64_linux_read_description.
2856 * linux-amd64-ipa.c (idx2mask): New array.
2857 (get_ipa_tdesc): Move idx2mask out.
2858 (initialize_low_tracepoint): Initialize target descriptions.
2859 * linux-i386-ipa.c (idx2mask): New array.
2860 (get_ipa_tdesc): Move idx2mask out.
2861 (initialize_low_tracepoint): Initialize target descriptions.
2863 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
2865 * tdesc.c (struct tdesc_type): Change return type.
2866 (tdesc_add_flag): Change parameter type.
2867 (tdesc_add_bitfield): Likewise.
2868 (tdesc_add_field): Likewise.
2869 (tdesc_set_struct_size): Likewise.
2871 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
2873 * regcache.c (registers_to_string): Remove unused variable.
2875 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2877 * inferiors.c (for_each_inferior_with_data): Remove.
2878 * inferiors.h (for_each_inferior_with_data): Remove.
2879 * server.c (handle_qxfer_threads_worker): Change parameter type.
2880 (handle_qxfer_threads_proper): Use for_each_thread.
2882 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2884 * inferiors.c (for_each_inferior): Remove.
2885 (clear_inferiors): Use for_each_thread.
2886 * inferiors.h (for_each_inferior): Remove.
2887 * linux-low.c (linux_wait_for_event_filtered): Use
2889 (linux_stabilize_threads): Likewise.
2890 * regcache.c (regcache_release): Likewise.
2891 * server.c (gdb_wants_all_threads_stopped): Likewise.
2892 (clear_pending_status_callback): Remove.
2893 (handle_status): Use for_each_thread.
2894 (captured_main): Likewise.
2895 * win32-low.c (child_init_thread_list): Likewise.
2896 (win32_clear_inferiors): Likewise.
2897 (fake_breakpoint_event): Likewise.
2899 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2901 * inferiors.h (find_inferior): Remove.
2902 * inferiors.c (find_inferior): Remove.
2904 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2906 * linux-low.c (resume_status_pending_p): Update comment.
2907 (need_step_over_p): Update comment.
2909 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2911 * linux-low.c (proceed_one_lwp): Return void, change parameter
2913 (unsuspend_and_proceed_one_lwp): Likewise.
2914 (proceed_all_lwps): Use for_each_thread.
2915 (unstop_all_lwps): Likewise.
2917 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2919 * linux-low.c (linux_resume_one_thread): Return void, take
2921 (linux_resume): Use for_each_thread.
2923 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2925 * linux-low.c (send_sigstop_callback): Return void, change
2926 parameter type. Rename to...
2927 (send_sigstop): ... this.
2928 (suspend_and_send_sigstop_callback): Return void, change parameter
2930 (suspend_and_send_sigstop): ... this.
2931 (stop_all_lwps): Use for_each_thread.
2933 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2935 * linux-low.c (lwp_running): Return bool, remove unused
2937 (linux_stabilize_threads): Use find_thread.
2939 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2941 * linux-low.c (select_singlestep_lwp_callback): Remove.
2942 (count_events_callback): Remove.
2943 (select_event_lwp_callback): Remove.
2944 (select_event_lwp): Use find_thread/for_each_thread.
2946 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2948 * linux-low.c (not_stopped_callback): Return bool, take filter
2950 (linux_wait_for_event_filtered): Use find_thread.
2951 (linux_wait_1): Likewise.
2953 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2955 * linux-low.c (same_lwp): Remove.
2956 (find_lwp_pid): Use find_thread.
2958 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2960 * linux-low.c (delete_lwp_callback): Remove.
2961 (linux_mourn): Use for_each_thread.
2963 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2965 * linux-low.c (linux_detach_lwp_callback): Return void, remove
2966 args parameter, don't check for pid.
2967 (linux_detach): Use for_each_thread.
2969 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2971 * linux-low.c (struct counter): Remove.
2972 (second_thread_of_pid_p): Remove.
2973 (last_thread_of_process_p): Use find_thread.
2975 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2977 * inferiors.c (find_inferior_in_random): Remove.
2978 * inferiors.h (find_inferior_in_random): Remove.
2979 * linux-low.c (status_pending_p_callback): Return bool, accept
2980 parameter ptid directly.
2981 (linux_wait_for_event_filtered): Use find_thread_in_random.
2982 (linux_wait_1): Likewise.
2984 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2986 * inferiors.c (find_inferior_id): Remove.
2987 (find_thread_ptid): Move implemention from find_inferior_id to
2989 * inferiors.h (find_inferior_id): Remove.
2990 * server.c (handle_status): Use find_thread_ptid.
2991 (process_serial_event): Likewise.
2992 * thread-db.c (find_one_thread): Likewise.
2993 (thread_db_thread_handle): Likewise.
2994 * win32-low.c (thread_rec): Likewise.
2995 (child_delete_thread): Likewise.
2996 (win32_thread_alive): Likewise.
2997 (get_child_debug_event): Likewise.
2999 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3001 * linux-mips-low.c (update_watch_registers_callback): Return
3002 void, remove pid_p parameter, don't check for pid.
3003 (mips_insert_point, mips_remove_point): Use for_each_thread.
3005 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3007 * lynx.low (lynx_delete_thread_callback): Remove.
3008 (lynx_mourn): Use for_each_thread.
3010 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3012 * regcache.c (regcache_invalidate_one): Remove.
3013 (regcache_invalidate_pid): use for_each_thread.
3015 2017-11-26 Tom Tromey <tom@tromey.com>
3017 * linux-low.c (linux_create_inferior): Update.
3019 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
3021 * spu-low.c (spu_create_inferior): Fix typo in argument name.
3023 2017-11-24 Alan Hayward <alan.hayward@arm.com>
3025 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
3026 * linux-aarch64-low.c (initialize_low_arch): Call init func.
3027 * linux-aarch64-tdesc-selftest.c: New file.
3028 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
3030 2017-11-24 Alan Hayward <alan.hayward@arm.com>
3032 * configure.srv: Add new file.
3033 * linux-aarch64-low.c (initialize_low_arch): Call init func.
3034 * linux-aarch64-tdesc-selftest.c: New file.
3035 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
3037 2017-11-24 Alan Hayward <alan.hayward@arm.com>
3039 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
3040 * linux-aarch64-low.c (initialize_low_arch): Remove init.
3041 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
3043 2017-11-24 Alan Hayward <alan.hayward@arm.com>
3045 * configure.srv: Add new files.
3046 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
3047 aarch64_linux_read_description.
3048 * linux-aarch64-low.c (aarch64_linux_read_description):
3049 Merge with aarch64_arch_setup.
3050 (aarch64_arch_setup): Call aarch64_linux_read_description.
3051 * linux-aarch64-tdesc.c: New file.
3052 * linux-aarch64-tdesc.h: New file.
3054 2017-11-24 Yao Qi <yao.qi@linaro.org>
3056 * configure.srv: Set $srv_regobj for tic6x-linux.
3057 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
3058 (tic6x_read_description): Move some code to tic6x_arch_setup.
3059 (tic6x_tdesc_test): New function.
3060 (initialize_low_arch): Call selftests::register_test.
3062 2017-11-22 Yao Qi <yao.qi@linaro.org>
3064 * remote-utils.c (prepare_resume_reply): Use memcpy.
3066 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3068 * linux-low.c (kill_one_lwp_callback): Return void, take
3069 argument directly, don't filter on pid.
3070 (linux_kill): Use for_each_thread.
3072 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3074 * linux-low.c (need_step_over_p): Return bool, remove dummy
3076 (linux_resume, proceed_all_lwps): Use find_thread.
3078 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3080 * linux-low.c (resume_status_pending_p): Return bool, remove
3082 (linux_resume): Use find_thread.
3084 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3086 * linux-low.c (struct thread_resume_array): Remove.
3087 (linux_set_resume_request): Return void, take arguments
3089 (linux_resume): Use for_each_thread.
3091 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3093 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
3094 return bool, remove data argument.
3095 (linux_stabilize_threads): Use find_thread.
3097 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3099 * linux-low.c (unsuspend_one_lwp): Remove.
3100 (unsuspend_all_lwps): Use for_each_thread, inline code from
3103 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3105 * gdbthread.h (find_thread): Add overload with ptid_t filter.
3106 * linux-low.c (struct iterate_over_lwps_args): Remove.
3107 (iterate_over_lwps_filter): Remove.
3108 (iterate_over_lwps): Use find_thread.
3110 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3112 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
3113 (linux_handle_new_gdb_connection): Use for_each_thread, inline
3114 code from reset_lwp_ptrace_options_callback.
3116 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3118 * linux-arm-low.c (struct update_registers_data): Remove.
3119 (update_registers_callback): Return void, take arguments
3120 directly, don't check thread's pid.
3121 (arm_insert_point, arm_remove_point): Use for_each_thread.
3123 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3125 * win32-low.c (continue_one_thread): Return void, take argument
3127 (child_continue): Use for_each_thread.
3129 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3131 * win32-i386-low.c (update_debug_registers_callback): Rename
3133 (update_debug_registers): ... this, return void, remove pid_p arg.
3134 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
3136 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
3138 * inferiors.h (struct process_info): Add constructor, initialize
3140 <syscalls_to_catch>: Change type to std::vector<int>.
3141 * inferiors.c (add_process): Allocate process_info with new.
3142 (remove_process): Free process_info with delete.
3143 * linux-low.c (handle_extended_wait): Adjust.
3144 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
3145 * server.c (handle_general_set): Adjust.
3147 2017-11-16 Pedro Alves <palves@redhat.com>
3149 * remote-utils.c (remote_close): Block SIGIO signals instead of
3150 uninstalling the SIGIO handler.
3152 2017-11-16 Alan Hayward <alan.hayward@arm.com>
3154 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
3156 2017-11-16 Yao Qi <yao.qi@linaro.org>
3158 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
3159 (tic6x_store_gregset): Likewise.
3160 (tic6x_usrregs_info): Move it up.
3162 2017-11-15 Alan Hayward <alan.hayward@arm.com>
3164 * Makefile.in: Update arch rules.
3165 * configure.srv: Explicitly mark arch/ files.
3167 2017-11-13 Andreas Schwab <schwab@suse.de>
3169 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
3171 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
3173 2017-11-06 Pedro Alves <palves@redhat.com>
3175 * config.in, configure: Regenerate.
3177 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3179 * target.c (struct thread_search): Remove.
3180 (thread_search_callback): Remove.
3181 (prepare_to_access_memory): Use for_each_thread instead of
3182 find_inferior. Inline code from thread_search_callback.
3184 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3186 * server.c (struct visit_actioned_threads_data): Remove.
3187 (visit_actioned_threads): Change prototype to take arguments
3189 (resume): Use find_thread instead of find_inferior.
3191 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3193 * server.c (queue_stop_reply_callback): Change prototype, return
3195 (find_status_pending_thread_callback): Remove.
3196 (handle_status): Replace find_inferior with find_thread and
3199 2017-10-25 Alan Hayward <alan.hayward@arm.com>
3201 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
3203 (aarch64_store_gregset): Likewise.
3204 (aarch64_fill_fpregset): Likewise.
3205 (aarch64_store_fpregset): Likewise.
3207 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
3209 * gdbthread.h (find_thread, for_each_thread): New functions.
3210 * inferiors.c (thread_of_pid): Remove.
3211 (find_any_thread_of_pid): Use find_thread.
3212 * linux-low.c (num_lwps): Use for_each_thread.
3214 2017-10-17 Yao Qi <yao.qi@linaro.org>
3216 * Makefile.in: Remove one rule.
3217 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
3219 2017-10-17 Yao Qi <yao.qi@linaro.org>
3221 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
3222 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
3224 2017-10-17 Yao Qi <yao.qi@linaro.org>
3226 * configure.srv: Rename arm.o with arch/arm.o.
3228 2017-10-17 Yao Qi <yao.qi@linaro.org>
3230 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
3231 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
3232 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
3233 (arch-i386.o, arch-amd64.o): Remove rules.
3234 (arch/%.o): New rule.
3235 Update POSTCOMPILE and COMPILE.pre.
3236 * configure.ac: Invoke AC_CONFIG_COMMANDS.
3237 * configure: Re-generated.
3238 * configure.srv: Replace arch-i386.o with arch/i386.o.
3239 Replace arch-amd64.o with arch/amd64.o.
3241 2017-10-16 Yao Qi <yao.qi@linaro.org>
3243 * configure: Regenerated.
3245 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3247 * inferiors.h: (struct inferior_list): Remove.
3248 (struct inferior_list_entry); Remove.
3249 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
3250 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
3251 get_first_inferior): Remove.
3252 (for_each_inferior, for_each_inferior_with_data, find_inferior,
3253 find_inferior_id, find_inferior_in_random): Change signature.
3254 * inferiors.c (all_threads): Change type to
3255 std::list<thread_info *>.
3256 (get_thread): Remove macro.
3257 (find_inferior, find_inferior_id): Change signature, implement
3259 (find_inferior_in_random): Change signature, implement using
3260 find_thread_in_random.
3261 (for_each_inferior, for_each_inferior_with_data): Change
3262 signature, implement using for_each_thread.
3263 (add_inferior_to_list, remove_inferior): Remove.
3264 (add_thread, get_first_thread, thread_of_pid,
3265 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
3266 (get_first_inferior, one_inferior_p, clear_inferior_list):
3268 (clear_inferiors, get_thread_process): Update.
3269 * gdbthread.h: Include <list>.
3270 (struct thread_info) <entry>: Remove field.
3272 (all_threads): Change type to std::list<thread_info *>.
3273 (get_first_inferior): Add doc.
3274 (find_thread, for_each_thread, find_thread_in_random): New
3276 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
3277 * linux-arm-low.c (update_registers_callback): Update.
3278 * linux-low.c (second_thread_of_pid_p): Update.
3279 (kill_one_lwp_callback, linux_detach_lwp_callback,
3280 delete_lwp_callback, status_pending_p_callback, same_lwp,
3281 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
3282 iterate_over_lwps, not_stopped_callback,
3283 resume_stopped_resumed_lwps, count_events_callback,
3284 select_singlestep_lwp_callback, select_event_lwp_callback,
3285 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
3286 suspend_and_send_sigstop_callback, wait_for_sigstop,
3287 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
3288 lwp_running, linux_set_resume_request, resume_status_pending_p,
3289 need_step_over_p, start_step_over, linux_resume_one_thread,
3290 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
3291 reset_lwp_ptrace_options_callback): Update.
3292 * linux-mips-low.c (update_watch_registers_callback): Update.
3293 * regcache.c (regcache_invalidate_one, regcache_invalidate):
3295 (free_register_cache_thread_one): Remove.
3296 (regcache_release): Update.
3297 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
3298 handle_qxfer_threads_worker): Update.
3299 (handle_query): Update, use list iterator.
3300 (visit_actioned_threads, handle_pending_status,
3301 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
3302 clear_pending_status_callback, set_pending_status_callback,
3303 find_status_pending_thread_callback, handle_status,
3304 process_serial_event): Update.
3305 * target.c (thread_search_callback): Update.
3306 * thread-db.c (thread_db_get_tls_address): Update.
3307 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
3309 * win32-i386-low.c (update_debug_registers_callback): Update.
3310 * win32-low.c (delete_thread_info, child_delete_thread,
3311 continue_one_thread, suspend_one_thread,
3312 get_child_debug_event): Adjust.
3314 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3316 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
3317 * inferiors.h: Include <list>.
3318 (struct process_info) <entry>: Remove field.
3320 (pid_of): Change macro to function.
3321 (ptid_of, lwpid_of): Remove macro.
3322 (all_processes): Change type to std::list<process_info *>.
3323 (ALL_PROCESSES): Remove macro.
3324 (for_each_process, find_process): New function.
3325 * inferiors.c (all_processes): Change type to
3326 std::list<process_info *>.
3327 (find_thread_process): Adjust.
3328 (add_process): Likewise.
3329 (remove_process): Likewise.
3330 (find_process_pid): Likewise.
3331 (get_first_process): Likewise.
3332 (started_inferior_callback): Remove.
3333 (have_started_inferiors_p): Adjust.
3334 (attached_inferior_callback): Remove.
3335 (have_attached_inferiors_p): Adjust.
3336 * linux-low.c (check_zombie_leaders): Likewise.
3337 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
3338 (x86_linux_update_xmltarget): Adjust.
3339 * server.c (handle_query): Likewise.
3340 (gdb_reattached_process): Remove.
3341 (handle_status): Adjust.
3342 (kill_inferior_callback): Likewise.
3343 (detach_or_kill_inferior): Remove.
3344 (print_started_pid): Likewise.
3345 (print_attached_pid): Likewise.
3346 (detach_or_kill_for_exit): Update.
3347 (process_serial_event): Likewise.
3348 * linux-arm-low.c (arm_new_fork): Likewise.
3350 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3352 * dll.h: Include <list>.
3353 (struct dll_info): Add constructor.
3354 <entry>: Remove field.
3355 (all_dlls): Change type to std::list<dll_info>.
3356 * dll.c: Include <algorithm>.
3357 (get_dll): Remove macro.
3358 (all_dlls): Change type to std::list<dll_info *>.
3359 (free_one_dll): Remove.
3360 (match_dll): Likewise.
3361 (loaded_dll): Adjust.
3362 (unloaded_dll): Adjust to all_dlls type change, use
3363 std::find_if. Inline code from match_dll.
3364 (clear_dlls): Adjust to all_dlls type change.
3365 * server.c (emit_dll_description): Remove.
3366 (handle_qxfer_libraries): Adjust to all_dlls type change,
3367 integrate emit_dll_description's functionality.
3369 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
3371 * linux-low.h (struct linux_target_ops) <delete_process>: New
3373 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
3374 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
3375 (struct linux_target_ops): Add delete_process callback.
3376 * linux-arm-low.c (arm_delete_process): New.
3377 (struct linux_target_ops): Add delete_process callback.
3378 * linux-bfin-low.c (struct linux_target_ops): Likewise.
3379 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
3380 * linux-m32r-low.c (struct linux_target_ops): Likewise.
3381 * linux-mips-low.c (mips_linux_delete_process): New.
3382 (struct linux_target_ops): Add delete_process callback.
3383 * linux-ppc-low.c (struct linux_target_ops): Likewise.
3384 * linux-s390-low.c (struct linux_target_ops): Likewise.
3385 * linux-sh-low.c (struct linux_target_ops): Likewise.
3386 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
3387 * linux-tile-low.c (struct linux_target_ops): Likewise.
3388 * linux-x86-low.c (x86_linux_delete_process): New.
3389 (struct linux_target_ops): Add delete_process callback.
3390 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
3392 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
3394 * linux-aarch64-low.c (the_low_target): Add thread delete
3396 * linux-arm-low.c (arm_delete_thread): New function.
3397 (the_low_target): Add thread delete callback.
3398 * linux-bfin-low.c (the_low_target): Likewise.
3399 * linux-crisv32-low.c (the_low_target): Likewise.
3400 * linux-low.c (delete_lwp): Invoke delete_thread callback if
3402 * linux-low.h (struct linux_target_ops) <delete_thread>: New
3404 * linux-m32r-low.c (the_low_target): Add thread delete callback.
3405 * linux-mips-low.c (mips_linux_delete_thread): New function.
3406 (the_low_target): Add thread delete callback.
3407 * linux-ppc-low.c (the_low_target): Likewise.
3408 * linux-s390-low.c (the_low_target): Likewise.
3409 * linux-sh-low.c (the_low_target): Likewise.
3410 * linux-tic6x-low.c (the_low_target): Likewise.
3411 * linux-tile-low.c (the_low_target): Likewise.
3412 * linux-x86-low.c (the_low_target): Likewise.
3413 * linux-xtensa-low.c (the_low_target): Likewise.
3415 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
3417 * win32-low.c: Include "common-inferior.h".
3419 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3421 * inferiors.c (set_inferior_cwd): New function.
3422 * server.c (handle_general_set): Handle QSetWorkingDir packet.
3423 (handle_query): Inform that QSetWorkingDir is supported.
3424 * win32-low.c (create_process): Pass the inferior's cwd to
3427 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3429 * inferiors.c (current_inferior_cwd): New global variable.
3430 (get_inferior_cwd): New function.
3431 * inferiors.h (struct process_info) <cwd>: New field.
3433 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3435 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
3436 (OBS): Add gdb_tilde_expand.o.
3438 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
3440 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
3441 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
3443 2017-09-29 Pedro Alves <palves@redhat.com>
3445 * ax.c (gdb_parse_agent_expr): Constify.
3446 * ax.h (gdb_parse_agent_expr): Constify.
3447 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
3449 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
3450 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
3451 * remote-utils.h (read_ptid): Constify.
3452 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
3453 (process_point_options, process_serial_event): Constify.
3454 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
3455 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
3456 (cmd_qtbuffer): Constify.
3458 2017-09-29 Pedro Alves <palves@redhat.com>
3460 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
3463 2017-09-29 Pedro Alves <palves@redhat.com>
3465 * linux-low.c (handle_extended_wait): Pass parent thread instead
3466 of process to thread_db_notice_clone.
3467 * linux-low.h (thread_db_notice_clone): Replace parent process
3468 parameter with parent thread parameter.
3469 * thread-db.c (find_one_thread): Add comment.
3470 (thread_db_notice_clone): Replace parent process parameter with
3471 parent thread parameter. Temporarily switch to the parent thread.
3473 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
3475 * gdbthread.h: Include "common-gdbthread.h".
3476 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
3477 "if" when validating the ptid.
3478 * remote-utils.c: Include "gdbthread.h".
3479 (prepare_resume_reply): Use "switch_to_thread".
3480 * target.c (done_accessing_memory): Likewise.
3482 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
3484 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
3485 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
3486 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
3487 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
3488 s390x-gs-linux64-ipa.o to ipa_obj.
3489 * linux-s390-low.c (HWCAP_S390_GS): New define.
3490 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
3492 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
3493 (s390_arch_setup): Check for guarded-storage support and choose
3495 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
3496 init_registers_s390x_gs_linux64.
3497 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
3499 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
3500 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
3502 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
3504 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
3506 2017-09-21 Kevin Buettner <kevinb@redhat.com>
3508 * linux-low.h (struct lwp_info): Add new field, thread_handle.
3509 (thread_db_thread_handle): Declare.
3510 * linux-low.c (linux_target_ops): Initialize thread_handle.
3511 * server.c (handle_qxfer_threads_worker): Add support for
3513 * target.h (struct target_ops): Add new function pointer,
3515 (target_thread_handle): Define.
3516 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
3518 (thread_db_thread_handle): New function.
3520 2017-09-21 Kevin Buettner <kevinb@redhat.com>
3522 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
3523 * linux-low.h (thread_db_notice_clone): Declare.
3524 * thread-db.c (thread_db_notice_clone): New function.
3526 2017-09-21 Pedro Alves <palves@redhat.com>
3528 * server.c (gdb_read_memory, handle_status, process_serial_event)
3529 (handle_serial_event, handle_target_event): Adjust to
3530 set_desired_thread prototype change.
3531 * target.c (set_desired_thread): Remove 'use_general' parameter
3533 * target.h (set_desired_thread): Remove 'use_general' parameter.
3535 2017-09-20 Tom Tromey <tom@tromey.com>
3537 * target.c (target_terminal::terminal_state): Define.
3538 (target_terminal::init): Rename from target_terminal_init.
3539 (target_terminal::inferior): Rename from
3540 target_terminal_inferior.
3541 (target_terminal::ours): Rename from target_terminal_ours.
3542 (target_terminal::ours_for_output, target_terminal::info): New.
3544 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3546 * server.c (accumulate_file_name_length): Remove.
3547 (emit_dll_description): Adjust to std::string change.
3548 (handle_qxfer_libraries): Use std::string to hold document.
3550 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3552 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
3553 return type of xml_escape_text.
3554 * server.c (emit_dll_description): Likewise.
3556 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3558 * server.c (captured_main): Accept argument for --selftest.
3559 Update run_tests call.
3560 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
3561 when registering selftests.
3563 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
3565 * regcache.c (get_thread_regcache): Update code to use "std::vector"
3566 instead of "VEC" for "target_desc.reg_defs".
3567 (regcache_cpy): Likewise.
3568 (registers_to_string): Likewise.
3569 (registers_from_string): Likewise.
3570 (find_regno): Likewise.
3571 (supply_regblock): Likewise.
3572 (regcache_raw_read_unsigned): Likewise.
3573 * tdesc.c (init_target_desc): Likewise.
3574 (tdesc_create_reg): Likewise.
3575 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
3576 (struct target_desc) <reg_defs>: Convert to "std::vector".
3577 (target_desc): Do not initialize "reg_defs".
3578 (~target_desc): Update code to use "std::vector" instead of "VEC"
3579 for "target_desc.reg_defs".
3580 (operator==): Likewise.
3582 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3584 * inferiors.h (thread_to_gdb_id): Remove.
3585 * inferiors.c (thread_to_gdb_id): Remove.
3586 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
3587 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
3588 lynx_store_registers, lynx_read_memory, lynx_write_memory):
3590 * nto-low.c (nto_fetch_registers, nto_store_registers,
3591 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
3593 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3595 * inferiors.h (gdb_id_to_thread_id): Remove.
3596 * inferiors.c (gdb_id_to_thread_id): Remove.
3597 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
3598 removal. Move pid declaration closer to where it's used.
3600 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3602 * server.c (handle_detach): New function.
3603 (process_serial_event): Move code out, call handle_detach.
3605 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3607 * server.c (require_running): Rename to ...
3608 (require_running_or_return): ... this ...
3609 (require_running_or_break): ... and this.
3610 (handle_query, process_serial_event): Adjust.
3612 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3614 * linux-low.c (linux_set_resume_request): Remove unused
3617 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3619 * server.c (first_thread_of): Remove.
3620 (process_serial_event): Replace usage of first_thread_of with
3621 find_any_thread_of_pid.
3622 * tracepoint.c (same_process_p): Remove.
3623 (gdb_agent_about_to_close): Replace usage of same_process_p with
3624 find_any_thread_of_pid.
3625 * linux-x86-low.c (same_process_callback): Remove.
3626 (x86_arch_setup_process_callback): Replace usage of
3627 same_process_callback with find_any_thread_of_pid.
3628 * thread-db.c (any_thread_of): Remove.
3629 (switch_to_process): Replace usage of any_thread_of with
3630 find_any_thread_of_pid.
3631 * inferiors.c (thread_pid_matches_callback): Remove.
3632 (find_thread_process): Adjust to use find_any_thread_of_pid.
3634 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
3636 * regcache.c (get_thread_regcache): Guard calls to "memset"
3639 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
3641 * linux-low.c (handle_extended_wait): Use
3642 "allocate_target_description" instead of "XNEW".
3643 * linux-x86-low.c (initialize_low_arch): Likewise.
3645 2017-09-05 Yao Qi <yao.qi@linaro.org>
3647 * configure.srv (srv_i386_regobj): Remove.
3648 (srv_amd64_regobj): Remove.
3649 (srv_regobj): Set it to "" for x86 non-linux targets.
3650 * linux-x86-tdesc.c (i386_linux_read_description):
3651 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
3652 (init_registers_i386): Remove the declaration.
3653 (tdesc_i386): Remove the declaration.
3654 (lynx_i386_arch_setup): Call i386_create_target_description.
3655 * nto-x86-low.c: Likewise.
3656 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
3657 [!__x86_64__]: include arch/i386.h.
3658 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
3660 2017-09-05 Yao Qi <yao.qi@linaro.org>
3662 * configure.srv (srv_amd64_linux_xmlfiles): Remove
3663 i386/amd64-XXX-linux from it.
3665 2017-09-05 Yao Qi <yao.qi@linaro.org>
3667 * configure.srv: Empty srv_amd64_linux_regobj if $development is
3669 (ipa_amd64_linux_regobj): Remove.
3670 (ipa_x32_linux_regobj): Remove.
3672 2017-09-05 Yao Qi <yao.qi@linaro.org>
3674 * Makefile.in (arch-amd64.o): New rule.
3675 * configure.srv: Append arch-amd64.o.
3676 * linux-amd64-ipa.c: Include common/x86-xstate.h.
3677 (get_ipa_tdesc): Call amd64_linux_read_description.
3678 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
3679 and init_registers_amd64_XXX.
3680 * linux-x86-low.c (x86_linux_read_description): Call
3681 amd64_linux_read_description.
3682 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
3683 (initialize_low_arch): Don't call init_registers_x32_XXX and
3684 init_registers_amd64_XXX.
3685 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
3686 and tdesc_amd64_XXX.
3687 [__x86_64__] (amd64_tdesc_test): New function.
3688 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
3689 and init_registers_amd64_XXX.
3690 * linux-x86-tdesc.c: Include arch/amd64.h.
3691 (xcr0_to_tdesc_idx): New function.
3692 (i386_linux_read_description): New function.
3693 (amd64_get_ipa_tdesc_idx): New function.
3694 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
3695 (amd64_get_ipa_tdesc): Declare.
3697 2017-09-05 Yao Qi <yao.qi@linaro.org>
3699 * configure.srv (srv_i386_linux_xmlfiles): Remove
3700 i386/i386-XXX-linux.xml from it.
3702 2017-09-05 Yao Qi <yao.qi@linaro.org>
3704 * configure.srv: Set srv_i386_linux_regobj empty if $development
3706 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
3707 initialize_low_tdesc.
3708 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
3709 with #if initialize_low_tdesc.
3710 * linux-x86-tdesc-selftest.c: New file.
3711 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
3713 2017-09-05 Yao Qi <yao.qi@linaro.org>
3715 * Makefile.in (arch-i386.o): New rule.
3716 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
3717 (x86_64-*-linux*): Likewise.
3718 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
3719 include arch/i386.h.
3720 (i386_linux_read_description): Remove code and call
3721 i386_create_target_description.
3722 * tdesc.c (allocate_target_description): New function.
3723 * tdesc.h (set_tdesc_architecture): Remove declaration.
3724 (set_tdesc_osabi): Likewise.
3726 2017-09-05 Yao Qi <yao.qi@linaro.org>
3728 * linux-x86-tdesc.c: Don't include <inttypes.h>.
3729 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
3730 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
3732 * server.c (get_features_xml): Call tdesc_get_features_xml.
3733 * tdesc.c (set_tdesc_architecture): New function.
3734 (set_tdesc_osabi): New function.
3735 (tdesc_get_features_xml): New function.
3736 (tdesc_create_feature): Add an argument.
3737 * tdesc.h (struct target_desc) <features>: New field.
3738 <arch, osabi>: New field.
3739 (~target_desc): xfree features, arch, and osabi.
3740 (target_desc::oerator==): Don't compare .xmltarget.
3741 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
3742 (set_tdesc_osabi): Likewise.
3743 (tdesc_get_features_xml): Likewise.
3745 2017-09-05 Yao Qi <yao.qi@linaro.org>
3747 * linux-x86-tdesc.c: Include selftest.h.
3748 (i386_tdesc_test): New function.
3749 (initialize_low_tdesc): Call selftests::register_test.
3750 * tdesc.h: Include regdef.h.
3751 (target_desc): Override operator == and !=.
3753 2017-09-05 Yao Qi <yao.qi@linaro.org>
3755 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
3756 (ipa_obj): Likewise.
3757 * linux-i386-ipa.c: Include common/x86-xstate.h
3758 (get_ipa_tdesc): Call i386_linux_read_description.
3759 (initialize_low_tracepoint): Don't call init_registers_XXX
3760 functions, call initialize_low_tdesc instead.
3761 * linux-x86-low.c (x86_linux_read_description): Call
3762 i386_linux_read_description.
3763 (initialize_low_arch): Don't call init_registers_i386_XXX
3764 functions, call initialize_low_tdesc.
3765 * linux-x86-tdesc.c: New file.
3766 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
3767 (i386_get_ipa_tdesc_idx): Declare.
3768 (i386_get_ipa_tdesc): Declare.
3769 (initialize_low_tdesc): Declare.
3771 2017-09-05 Yao Qi <yao.qi@linaro.org>
3773 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
3776 2017-09-05 Yao Qi <yao.qi@linaro.org>
3778 * Makefile.in (IPA_OBJS): Add vec-ipa.o
3779 * regcache.c (get_thread_regcache): Use VEC_length.
3780 (init_register_cache): Likewise.
3781 (regcache_cpy): Likewise.
3782 (registers_to_string): Iterate reg_defs via VEC_iterate.
3783 (find_regno): Likewise.
3784 (find_register_by_number): Use VEC_index.
3785 (register_size): Call find_register_by_number.
3786 (register_data): Call find_register_by_number.
3787 (supply_regblock): Use VEC_length.
3788 (regcache_raw_read_unsigned): Likewise.
3789 * tdesc.c (init_target_desc): Iterate reg_defs via
3791 (default_description): Update initializer.
3792 (copy_target_description): Don't update field num_registers.
3793 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
3794 <num_registers>: Remove.
3796 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
3798 * Makefile.in (.SECONDARY): Define target.
3800 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
3802 * linux-low.c (linux_wait_1): Adjust.
3803 * server.c (queue_stop_reply_callback): Adjust.
3805 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
3807 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
3808 QEnvironmentUnset and QEnvironmentReset packets.
3809 (handle_query): Inform remote that QEnvironmentHexEncoded,
3810 QEnvironmentUnset and QEnvironmentReset are supported.
3812 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
3814 * inferiors.h (inferior_target_data): Rename to ...
3815 (thread_target_data): ... this.
3816 (inferior_regcache_data): Rename to ...
3817 (thread_regcache_data): ... this.
3818 (set_inferior_regcache_data): Rename to ...
3819 (set_thread_regcache_data): ... this.
3820 * inferiors.c (inferior_target_data): Rename to ...
3821 (thread_target_data): ... this.
3822 (inferior_regcache_data): Rename to ...
3823 (thread_regcache_data): ... this.
3824 (set_inferior_regcache_data): Rename to ...
3825 (set_thread_regcache_data): ... this.
3826 (free_one_thread): Update.
3827 * linux-low.h (get_thread_lwp): Update.
3828 * regcache.c (get_thread_regcache): Update.
3829 (regcache_invalidate_thread): Update.
3830 (free_register_cache_thread): Update.
3831 * win32-i386-low.c (update_debug_registers_callback): Update.
3832 (win32_get_current_dr): Update.
3833 * win32-low.c (thread_rec): Update.
3834 (delete_thread_info): Update.
3835 (continue_one_thread): Update.
3836 (suspend_one_thread): Update.
3838 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
3840 * inferiors.c (set_inferior_target_data): Remove.
3841 * inferiors.h (set_inferior_target_data): Remove.
3843 2017-08-18 Yao Qi <yao.qi@linaro.org>
3845 * Makefile.in (OBS): Add selftest.o.
3846 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
3847 * configure, config.in: Re-generated.
3848 * server.c: Include common/sefltest.h.
3849 (captured_main): Handle option --selftest.
3851 2017-08-09 Yao Qi <yao.qi@linaro.org>
3853 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
3854 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
3855 i386-avx-mpx.o and i386-mmx.o.
3856 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
3857 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
3858 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
3859 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
3860 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
3861 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
3862 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
3863 i386/amd64-avx-mpx.xml.
3865 2017-08-09 Yao Qi <yao.qi@linaro.org>
3867 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
3868 and x32-avx-avx512.o.
3869 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
3870 i386/x32-avx-avx512.xml.
3872 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
3874 * tracepoint.h (enum class fast_tpoint_collect_result): New
3876 (fast_tracepoint_collecting): Change return type to
3877 fast_tpoint_collect_result.
3878 * tracepoint.c (fast_tracepoint_collecting): Likewise.
3879 * linux-low.h: Include tracepoint.h.
3880 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
3881 fast_tpoint_collect_result.
3882 * linux-low.c (handle_tracepoints): Adjust.
3883 (linux_fast_tracepoint_collecting): Change return type to
3884 fast_tpoint_collect_result.
3885 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
3886 linux_wait_1, stuck_in_jump_pad_callback,
3887 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
3888 proceed_one_lwp): Adjust to type change.
3890 2017-07-10 Yao Qi <yao.qi@linaro.org>
3892 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
3894 2017-06-29 Yao Qi <yao.qi@linaro.org>
3896 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
3898 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
3900 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
3902 * Makefile.in (IPA_OBJS): Sort and format one item per line.
3904 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
3906 * linux-low.c (linux_create_inferior): Adjust code to access the
3907 environment information via 'gdb_environ' class.
3908 * lynx-low.c (lynx_create_inferior): Likewise.
3909 * server.c (our_environ): Make it an instance of 'gdb_environ'.
3910 (get_environ): Return a pointer to 'our_environ'.
3911 (captured_main): Initialize 'our_environ'.
3912 * server.h (get_environ): Adjust prototype.
3913 * spu-low.c (spu_create_inferior): Adjust code to access the
3914 environment information via 'gdb_environ' class.
3916 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
3918 * linux-low.c (linux_read_memory, linux_write_memory): Remove
3919 usage of "register" keyword.
3921 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
3923 * configure: Re-generate.
3925 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
3927 * configure: Re-generate.
3929 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
3931 * Makefile.in (COMPILE.pre): Add "-x c++".
3933 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
3935 * fork-child.c: Conditionally include <signal.h>.
3937 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
3939 * server.c (handle_general_set): Handle new packet
3940 "QStartupWithShell".
3941 (handle_query): Add "QStartupWithShell" to the list of supported
3943 (gdbserver_usage): Add help text explaining the
3944 new "--startup-with-shell" and "--no-startup-with-shell" CLI
3946 (captured_main): Recognize and act upon the presence of the new
3949 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
3950 Pedro Alves <palves@redhat.com>
3952 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
3953 * configure: Regenerate.
3954 * configure.srv (srv_linux_obj): Add "fork-child.o" and
3956 (i[34567]86-*-lynxos*): Likewise.
3957 (spu*-*-*): Likewise.
3958 * fork-child.c: New file.
3959 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
3961 (linux_ptrace_fun): New function.
3962 (linux_create_inferior): Adjust function prototype to reflect
3963 change on "target.h". Adjust function code to use
3965 (linux_request_interrupt): Delete "signal_pid".
3966 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
3967 (lynx_ptrace_fun): New function.
3968 (lynx_create_inferior): Adjust function prototype to reflect
3969 change on "target.h". Adjust function code to use
3971 * nto-low.c (nto_create_inferior): Adjust function prototype and
3972 code to reflect change on "target.h". Update comments.
3973 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
3974 "common-terminal.h" and "environ.h".
3975 (terminal_fd): Moved to fork-child.c.
3976 (old_foreground_pgrp): Likewise.
3977 (restore_old_foreground_pgrp): Likewise.
3978 (last_status): Make it global.
3979 (last_ptid): Likewise.
3980 (our_environ): New variable.
3981 (startup_with_shell): Likewise.
3982 (program_name): Likewise.
3983 (program_argv): Rename to...
3984 (program_args): ...this.
3985 (wrapper_argv): New variable.
3986 (start_inferior): Delete function.
3987 (get_exec_wrapper): New function.
3988 (get_exec_file): Likewise.
3989 (get_environ): Likewise.
3990 (prefork_hook): Likewise.
3991 (post_fork_inferior): Likewise.
3992 (postfork_hook): Likewise.
3993 (postfork_child_hook): Likewise.
3994 (handle_v_run): Update code to deal with arguments coming from the
3995 remote host. Update calls from "start_inferior" to
3997 (captured_main): Likewise. Initialize environment variable. Call
3999 * server.h (post_fork_inferior): New prototype.
4000 (get_environ): Likewise.
4001 (last_status): Declare.
4002 (last_ptid): Likewise.
4003 (signal_pid): Likewise.
4004 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
4005 (spu_ptrace_fun): New function.
4006 (spu_create_inferior): Adjust function prototype to reflect change
4007 on "target.h". Adjust function code to use "fork_inferior".
4008 * target.c (target_terminal_init): New function.
4009 (target_terminal_inferior): Likewise.
4010 (target_terminal_ours): Likewise.
4011 * target.h: Include <vector>.
4012 (struct target_ops) <create_inferior>: Update prototype.
4013 (create_inferior): Update macro.
4014 * utils.c (gdb_flush_out_err): New function.
4015 * win32-low.c (win32_create_inferior): Adjust function prototype
4016 and code to reflect change on "target.h".
4018 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4020 * inferiors.c (switch_to_thread): New function.
4022 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4024 * Makefile.in (SFILE): Add "common/job-control.c".
4025 (OBS): Add "job-control.o".
4027 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
4029 * Makefile: Remove "@host_makefile_frag@".
4031 2017-05-05 Pedro Alves <palves@redhat.com>
4033 * configure: Regenerate.
4035 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
4037 * configure: Regenerate.
4039 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
4041 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
4042 software_single_step change of return type to
4043 std::vector<CORE_ADDR>.
4044 * linux-low.c (install_software_single_step_breakpoints):
4046 * linux-low.h (install_software_single_step_breakpoints):
4049 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
4051 * remote-utils.c: Include "gdb_termios.h" instead of
4053 * terminal.h: Delete file.
4055 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
4057 * server.c: Include <vector>.
4058 <program_argv, wrapper_argv>: Convert to std::vector.
4059 (start_inferior): Rewrite function to use C++.
4060 (handle_v_run): Likewise. Update code that calculates the argv
4061 based on the vRun packet; use C++.
4062 (captured_main): Likewise.
4064 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
4066 * server.c (handle_v_cont): Initialize thread_resume::thread
4069 2017-04-05 Pedro Alves <palves@redhat.com>
4071 * configure: Regenerate.
4073 2017-04-05 Pedro Alves <palves@redhat.com>
4075 * gdbreplay.c (sync_error): Constify.
4076 * linux-x86-low.c (push_opcode): Constify.
4078 2017-04-05 Pedro Alves <palves@redhat.com>
4080 * win32-low.c (get_child_debug_event)
4081 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
4082 Report TARGET_WAITKIND_SPURIOUS instead.
4084 2017-04-05 Pedro Alves <palves@redhat.com>
4086 * remote-utils.c (remote_prepare, remote_open): Constify.
4087 * remote-utils.h (remote_prepare, remote_open): Constify.
4088 * server.c (captured_main): Constify 'port' handling.
4090 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
4092 * Makefile.in (clean): Clear .deps.
4094 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
4096 * .gitignore: Remove generated files, replace with wildcard.
4097 * (clean): Replace removal of generated files with wildcard.
4098 (version.c): Replace with...
4099 (version-generated.c): ...this.
4100 (xml-builtin.c): Replace with...
4101 (xml-builtin-generated.c): ...this.
4102 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
4103 (%.c: *regformats*): Replace with...
4104 (%-generated.c: *regformats*): ...this.
4106 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
4108 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
4109 (xtensa_fill_gregset): Call collect_register_by_name for
4111 (xtensa_store_gregset): Call supply_register_by_name for
4114 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
4116 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
4117 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
4118 (xtensa_store_gregset): Call supply_register for all registers in
4119 a0_regnum..a0_regnum + C0_NREGS range.
4121 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4123 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
4124 (ax-ipa.o: ax.c): Remove.
4125 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
4126 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
4127 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
4128 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
4129 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
4131 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4133 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
4134 (print-utils-ipa.o: ../common/print-utils.c): Remove.
4135 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
4136 (errors-ipa.o: ../common/errors.c): Remove.
4137 (format-ipa.o: ../common/format.c): Remove.
4138 (common-utils-ipa.o: ../common/common-utils.c): Remove.
4140 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4142 * Makefile.in (%-ipa.o: %.c): New rule.
4143 (tracepoint-ipa.o: tracepoint.c): Remove.
4144 (utils-ipa.o: utils.c): Remove.
4145 (remote-utils-ipa.o: remote-utils.c): Remove.
4146 (regcache-ipa.o: regcache.c): Remove.
4147 (i386-linux-ipa.o: i386-linux.c): Remove.
4148 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
4149 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
4150 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
4151 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
4152 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
4153 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
4154 (amd64-linux-ipa.o: amd64-linux.c): Remove.
4155 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
4156 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
4157 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
4158 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
4159 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
4160 (aarch64-ipa.o: aarch64.c): Remove.
4161 (s390-linux32-ipa.o: s390-linux32.c): Remove.
4162 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
4163 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
4164 (s390-linux64-ipa.o: s390-linux64.c): Remove.
4165 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
4166 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
4167 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
4168 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
4169 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
4170 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
4171 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
4172 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
4173 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
4174 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
4175 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
4176 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
4177 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
4178 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
4179 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
4180 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
4181 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
4182 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
4183 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
4184 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
4185 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
4186 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
4187 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
4188 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
4189 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
4190 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
4191 (tdesc-ipa.o: tdesc.c): Remove.
4192 (x32-linux-ipa.o: x32-linux.c): Remove.
4193 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
4194 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
4196 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4198 * Makefile.in (%.o: ../arch/%.c): New rule.
4199 (arm.o: ../arch/arm.c): Remove.
4200 (arm-linux.o: ../arch/arm-linux.c): Remove.
4201 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
4202 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
4204 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4206 * Makefile.in (%.o: ../nat/%.c): New rule.
4207 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
4208 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
4209 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
4210 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
4211 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
4212 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
4213 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
4214 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
4215 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
4216 (linux-personality.o: ../nat/linux-personality.c): Remove.
4217 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
4218 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
4219 (x86-linux.o: ../nat/x86-linux.c): Remove.
4220 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
4221 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
4223 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4225 * Makefile.in (%.o: ../common/%.c): New rule.
4226 (signals.o: ../common/signals.c): Remove.
4227 (print-utils.o: ../common/print-utils.c): Remove.
4228 (rsp-low.o: ../common/rsp-low.c): Remove.
4229 (common-utils.o: ../common/common-utils.c): Remove.
4230 (posix-strerror.o: ../common/posix-strerror.c): Remove.
4231 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
4232 (vec.o: ../common/vec.c): Remove.
4233 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
4234 (xml-utils.o: ../common/xml-utils.c): Remove.
4235 (ptid.o: ../common/ptid.c): Remove.
4236 (buffer.o: ../common/buffer.c): Remove.
4237 (format.o: ../common/format.c): Remove.
4238 (filestuff.o: ../common/filestuff.c): Remove.
4239 (agent.o: ../common/agent.c): Remove.
4240 (errors.o: ../common/errors.c): Remove.
4241 (environ.o: ../common/environ.c): Remove.
4242 (common-debug.o: ../common/common-debug.c): Remove.
4243 (cleanups.o: ../common/cleanups.c): Remove.
4244 (common-exceptions.o: ../common/common-exceptions.c): Remove.
4245 (fileio.o: ../common/fileio.c): Remove.
4246 (common-regcache.o: ../common/common-regcache.c): Remove.
4247 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
4248 (new-op.o: ../common/new-op.c): Remove.
4249 (btrace-common.o: ../common/btrace-common.c): Remove.
4251 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4253 * Makefile.in (%.o: ../target/%.c): New rule.
4254 (waitstatus.o: ../target/waitstatus.c): Remove.
4256 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4259 (%.c: ../regformats/%.dat,
4260 (%.c: ../regformats/arm/%.dat,
4261 (%.c: ../regformats/i386/%.dat,
4262 (%.c: ../regformats/rs6000/%.dat): New rules.
4263 (aarch64.c): Remove.
4264 (reg-arm.c): Remove.
4265 (arm-with-iwmmxt.c): Remove.
4266 (arm-with-vfpv2.c): Remove.
4267 (arm-with-vfpv3.c): Remove.
4268 (arm-with-neon.c): Remove.
4269 (reg-bfin.c): Remove.
4270 (reg-cris.c): Remove.
4271 (reg-crisv32.c): Remove.
4273 (i386-linux.c): Remove.
4274 (i386-avx.c): Remove.
4275 (i386-avx-linux.c): Remove.
4276 (i386-avx-avx512.c): Remove.
4277 (i386-avx-avx512-linux.c): Remove.
4278 (i386-mpx.c): Remove.
4279 (i386-mpx-linux.c): Remove.
4280 (i386-avx-mpx-avx512-pku.c): Remove.
4281 (i386-avx-mpx-avx512-pku-linux.c): Remove.
4282 (i386-avx-mpx.c): Remove.
4283 (i386-avx-mpx-linux.c): Remove.
4284 (i386-mmx.c): Remove.
4285 (i386-mmx-linux.c): Remove.
4286 (reg-ia64.c): Remove.
4287 (reg-m32r.c): Remove.
4288 (reg-m68k.c): Remove.
4290 (mips-linux.c): Remove.
4291 (mips-dsp-linux.c): Remove.
4292 (mips64-linux.c): Remove.
4293 (mips64-dsp-linux.c): Remove.
4294 (nios2-linux.c): Remove.
4295 (powerpc-32.c): Remove.
4296 (powerpc-32l.c): Remove.
4297 (powerpc-altivec32l.c): Remove.
4298 (powerpc-cell32l.c): Remove.
4299 (powerpc-vsx32l.c): Remove.
4300 (powerpc-isa205-32l.c): Remove.
4301 (powerpc-isa205-altivec32l.c): Remove.
4302 (powerpc-isa205-vsx32l.c): Remove.
4303 (powerpc-e500l.c): Remove.
4304 (powerpc-64l.c): Remove.
4305 (powerpc-altivec64l.c): Remove.
4306 (powerpc-cell64l.c): Remove.
4307 (powerpc-vsx64l.c): Remove.
4308 (powerpc-isa205-64l.c): Remove.
4309 (powerpc-isa205-altivec64l.c): Remove.
4310 (powerpc-isa205-vsx64l.c): Remove.
4311 (s390-linux32.c): Remove.
4312 (s390-linux32v1.c): Remove.
4313 (s390-linux32v2.c): Remove.
4314 (s390-linux64.c): Remove.
4315 (s390-linux64v1.c): Remove.
4316 (s390-linux64v2.c): Remove.
4317 (s390-te-linux64.c): Remove.
4318 (s390-vx-linux64.c): Remove.
4319 (s390-tevx-linux64.c): Remove.
4320 (s390x-linux64.c): Remove.
4321 (s390x-linux64v1.c): Remove.
4322 (s390x-linux64v2.c): Remove.
4323 (s390x-te-linux64.c): Remove.
4324 (s390x-vx-linux64.c): Remove.
4325 (s390x-tevx-linux64.c): Remove.
4326 (tic6x-c64xp-linux.c): Remove.
4327 (tic6x-c64x-linux.c): Remove.
4328 (tic6x-c62x-linux.c): Remove.
4330 (reg-sparc64.c): Remove.
4331 (reg-spu.c): Remove.
4333 (amd64-linux.c): Remove.
4334 (amd64-avx.c): Remove.
4335 (amd64-avx-linux.c): Remove.
4336 (amd64-avx-avx512.c): Remove.
4337 (amd64-avx-avx512-linux.c): Remove.
4338 (amd64-mpx.c): Remove.
4339 (amd64-mpx-linux.c): Remove.
4340 (amd64-avx-mpx-avx512-pku.c): Remove.
4341 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
4342 (amd64-avx-mpx.c): Remove.
4343 (amd64-avx-mpx-linux.c): Remove.
4345 (x32-linux.c): Remove.
4346 (x32-avx.c): Remove.
4347 (x32-avx-linux.c): Remove.
4348 (x32-avx-avx512.c): Remove.
4349 (x32-avx-avx512-linux.c): Remove.
4350 (reg-xtensa.c): Remove.
4351 (reg-tilegx.c): Remove.
4352 (reg-tilegx32.c): Remove.
4354 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
4356 * Makefile.in (SFILES): Add "common/environ.c".
4357 (OBJS): Add "common/environ.h".
4359 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
4361 * configure.ac: Check if the fs_base and gs_base members of
4362 `struct user_regs_struct' exist.
4363 * config.in: Regenerated.
4364 * configure: Likewise.
4366 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
4368 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
4370 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
4371 (get_next_pcs_syscall_next_pc): Likewise.
4373 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
4375 * win32-i386-low.c: Fix incorrect reference to a couple source files.
4376 * nto-x86-low.c: Likewise.
4378 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
4380 * Makefile.in: Include disable-implicit-rules.mk.
4382 2016-11-23 Pedro Alves <palves@redhat.com>
4384 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
4385 (debug_vprintf): Use std::chrono::steady_clock instead of
4386 gettimeofday. Use '.' instead of ':'.
4387 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
4388 (get_timestamp): Use std::chrono::steady_clock instead of
4391 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
4393 * Makefile.in: Fix whitespace formatting.
4395 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
4397 * Makefile.in (SFILES, OBS): Flatten list and order
4400 2016-11-23 Pedro Alves <palves@redhat.com>
4402 * event-loop.c (handle_file_event): Use warning.
4403 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
4404 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
4407 2016-11-23 Pedro Alves <palves@redhat.com>
4409 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
4411 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
4412 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
4413 debug_printf and debug_flush for debug output.
4414 * server.c (handle_general_set): Likewise.
4415 * thread-db.c (try_thread_db_load): Use debug_printf for debug
4418 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
4420 * Makefile.in (.c.o): Replace rule with ...
4421 (%.o: %.c): ... this one.
4423 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
4425 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
4426 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
4428 * configure.ac: Remove checks for the make program.
4429 * configure: Re-generate.
4431 2016-10-28 Pedro Alves <palves@redhat.com>
4433 * Makefile.in (CXX_DIALECT): Get from configure.
4434 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
4435 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
4436 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
4437 * config.in: Regenerate.
4438 * configure: Regenerate.
4440 2016-10-27 Yao Qi <yao.qi@linaro.org>
4442 * linux-low.c (linux_supports_range_stepping): Return true if
4443 can_software_single_step return true.
4445 2016-10-27 Yao Qi <yao.qi@linaro.org>
4447 * inferiors.c (find_inferior_in_random): New function.
4448 * inferiors.h (find_inferior_in_random): Declare.
4449 * linux-low.c (linux_wait_for_event_filtered): Call
4450 find_inferior_in_random instead of find_inferior.
4452 2016-10-27 Yao Qi <yao.qi@linaro.org>
4454 * linux-low.c (linux_wait_1): If single-step breakpoints are
4455 inserted, remove them.
4457 2016-10-26 Pedro Alves <palves@redhat.com>
4459 * linux-low.c (handle_extended_wait): Link parent/child fork
4461 (linux_wait_1): Unlink them.
4462 (linux_set_resume_request): Ignore resume requests for
4463 already-resumed and unhandled fork child threads.
4464 * linux-low.h (struct lwp_info) <fork_relative>: New field.
4465 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
4467 (handle_v_requests) <vCont>: Don't call require_running.
4468 * server.h (in_queued_stop_replies): New declaration.
4470 2016-10-24 Yao Qi <yao.qi@linaro.org>
4473 * linux-aarch64-low.c (append_insns): Cast the return value to
4476 2016-10-10 Yao Qi <yao.qi@linaro.org>
4478 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
4480 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
4482 * target.c (target_supports_multi_process): New function, moved
4484 * target.h (target_supports_multi_process): ... here. Remove
4487 2016-10-05 Tom Tromey <tom@tromey.com>
4490 * tracepoint.c (handle_tracepoint_bkpts): Check
4491 ipa_error_tracepoint, not ipa_stopping_tracepoint.
4493 2016-10-05 Yao Qi <yao.qi@linaro.org>
4495 * configure.srv: Update the path of arm-*.xml files.
4497 2016-10-05 Terry Guo <terry.guo@arm.com>
4498 Yao Qi <yao.qi@linaro.org>
4500 * Makefile.in: Adjust the path of rules.
4501 * configure.srv: Update the path of xml files.
4502 * regformats/arm-with-iwmmxt.dat: Regenerated.
4503 * regformats/arm-with-neon.dat: Likewise.
4504 * regformats/arm-with-vfpv2.dat: Likewise.
4505 * regformats/arm-with-vfpv3.dat Likewise.
4507 2016-09-30 Yao Qi <yao.qi@linaro.org>
4510 * target.c (target_stop_and_wait): Don't call
4511 target_continue_no_signal, use resume_stop instead.
4513 2016-09-26 Yao Qi <yao.qi@linaro.org>
4515 * linux-low.c (linux_wait_1): Call debug_exit.
4517 2016-09-23 Pedro Alves <palves@redhat.com>
4519 * Makefile.in (SFILES): Add common/new-op.c.
4520 (OBS): Add common/new-op.o.
4521 (new-op.o): New rule.
4523 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
4525 * .gitinore: Ignore more files.
4527 2016-09-21 Yao Qi <yao.qi@linaro.org>
4529 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
4532 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
4534 * server.c (start_inferior): Call target_mourn_inferior instead of
4535 mourn_inferior; pass ptid_t argument to it.
4537 (handle_target_event): Likewise.
4538 * target.c (target_mourn_inferior): New function.
4539 * target.h (mourn_inferior): Delete macro.
4541 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
4543 * linux-low.c (lwp_is_stepping): New function.
4545 2016-09-06 Carl Love <cel@us.ibm.com>
4547 * server.c (start_inferior): Fixed comment, requested comment change
4548 didn't get updated correctly. Removed reference to ptrace () call as
4549 it is only true on Linux systems.
4551 2016-09-06 Carl Love <cel@us.ibm.com>
4553 * server.c (start_inferior): Do not call
4554 function target_post_create_inferior () if the
4555 inferior process has already exited.
4557 2016-09-05 Pedro Alves <palves@redhat.com>
4559 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
4560 (COMPILE.pre, CC_LD): Use CXX directly.
4561 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
4562 * acinclude.m4: Don't include build-with-cxx.m4.
4563 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
4564 * configure: Regenerate.
4566 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
4569 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
4570 call writing data to own_buf.
4572 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
4574 * target.c (mywait): Call target_wait instead of
4576 (target_wait): New function.
4578 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
4580 * server.c (start_inferior): New variable 'ptid'. Replace calls
4581 to the_target->resume by target_continue{,_no_signal}, depending
4583 * target.c (target_stop_and_wait): Call target_continue_no_signal
4584 instead of the_target->resume.
4585 (target_continue): New function.
4587 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
4589 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
4591 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
4594 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
4596 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
4597 * linux-arm-low.c (ps_get_thread_area): Likewise.
4598 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
4599 * linux-m68k-low.c (ps_get_thread_area): Likewise.
4600 * linux-mips-low.c (ps_get_thread_area): Likewise.
4601 * linux-nios2-low.c (ps_get_thread_area): Likewise.
4602 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
4603 * linux-x86-low.c (ps_get_thread_area): Likewise.
4604 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
4606 2016-08-19 Pedro Alves <palves@redhat.com>
4608 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
4610 2016-08-19 Pedro Alves <palves@redhat.com>
4612 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
4613 comment. Use memcpy instead of casting through unsigned long.
4615 2016-08-19 Pedro Alves <palves@redhat.com>
4617 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
4618 allocating around 0x80000000.
4620 2016-08-19 Pedro Alves <palves@redhat.com>
4623 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
4624 (x32-avx512-linux-ipa.o): New rules.
4625 * configure.ac (x86_64-*-linux*): New x32 check.
4626 * configure.srv (ipa_x32_linux_regobj): New.
4627 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
4628 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
4630 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
4632 * configure: Regenerate.
4634 2016-08-09 Pedro Alves <palves@redhat.com>
4637 * Makefile.in (OBS): Add signals-state-save-restore.o.
4638 (signals-state-save-restore.o): New rule.
4639 * config.in: Regenerate.
4640 * configure: Regenerate.
4641 * linux-low.c: Include "signals-state-save-restore.h".
4642 (linux_create_inferior): Call
4643 restore_original_signals_state.
4644 * server.c: Include "dispositions-save-restore.h".
4645 (captured_main): Call save_original_signals_state.
4647 2016-08-05 Pedro Alves <palves@redhat.com>
4649 * configure: Regenerate.
4651 2016-08-04 Yao Qi <yao.qi@linaro.org>
4653 * linux-low.c (regsets_fetch_inferior_registers): Check
4654 errno is ESRCH or not.
4656 2016-08-02 Yao Qi <yao.qi@linaro.org>
4658 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
4659 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
4660 (thread_db_load_search): Update.
4661 (try_thread_db_load_1): Don't look for td_ta_event_addr,
4662 td_ta_set_event and td_ta_event_getmsg.
4664 2016-07-26 Pedro Alves <palves@redhat.com>
4667 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
4668 of unsigned long for 64-bit registers and use uint32_t instead of
4669 unsigned int for 32-bit registers.
4671 2016-07-26 Pedro Alves <palves@redhat.com>
4673 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
4676 2016-07-21 Tom Tromey <tom@tromey.com>
4678 * configure: Rebuild.
4680 2016-07-21 Yao Qi <yao.qi@linaro.org>
4682 * mem-break.c (find_gdb_breakpoint): Cast bp to
4683 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
4685 2016-07-21 Yao Qi <yao.qi@linaro.org>
4687 * server.c (handle_v_requests): Support s and S actions
4688 if target_supports_software_single_step return true.
4690 2016-07-21 Yao Qi <yao.qi@linaro.org>
4692 * linux-low.c (resume_stopped_resumed_lwps): If resume request
4693 is resume_step, call maybe_hw_step.
4694 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
4696 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
4698 (proceed_one_lwp): If resume request is resume_step, install
4699 reinsert breakpoints and call maybe_hw_step.
4701 2016-07-21 Yao Qi <yao.qi@linaro.org>
4703 * linux-low.c (proceed_one_lwp): Declare.
4704 (linux_resume_one_thread): Remove local variable 'step'.
4705 Lift code enqueue signal. Call proceed_one_lwp instead of
4706 linux_resume_one_lwp.
4708 2016-07-21 Yao Qi <yao.qi@linaro.org>
4710 * linux-low.c (linux_resume_one_thread): Call
4711 enqueue_pending_signal.
4713 2016-07-21 Yao Qi <yao.qi@linaro.org>
4715 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
4716 * inferiors.c (do_restore_current_thread_cleanup): New function.
4717 (make_cleanup_restore_current_thread): Likewise.
4718 * linux-low.c (install_software_single_step_breakpoints): Call
4719 make_cleanup_restore_current_thread. Switch current_thread to
4722 2016-07-21 Yao Qi <yao.qi@linaro.org>
4724 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
4725 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
4726 (clone_one_breakpoint): Likewise.
4727 (delete_reinsert_breakpoints): Change parameter to thread.
4729 (has_reinsert_breakpoints): Likewise.
4730 (uninsert_reinsert_breakpoints): Likewise.
4731 (reinsert_reinsert_breakpoints): Likewise.
4732 * mem-break.h (set_reinsert_breakpoint): Update declaration.
4733 (delete_reinsert_breakpoints): Likewise.
4734 (reinsert_reinsert_breakpoints): Likewise.
4735 (uninsert_reinsert_breakpoints): Likewise.
4736 (has_reinsert_breakpoints): Likewise.
4738 2016-07-21 Yao Qi <yao.qi@linaro.org>
4740 * inferiors.c (get_thread_process): Make parameter const.
4741 * inferiors.h (get_thread_process): Update declaration.
4742 * mem-break.c (clone_all_breakpoints): Remove all parameters.
4743 Add new parameters child_thread and parent_thread. Callers
4745 * mem-break.h (clone_all_breakpoints): Update declaration.
4747 2016-07-21 Yao Qi <yao.qi@linaro.org>
4749 * mem-break.c (struct breakpoint) <cond_list>: Remove.
4750 <command_list, handler>: Remove.
4751 (struct gdb_breakpoint): New.
4752 (struct other_breakpoint): New.
4753 (struct reinsert_breakpoint): New.
4754 (is_gdb_breakpoint): New function.
4755 (any_persistent_commands): Update command_list if
4756 is_gdb_breakpoint returns true.
4757 (set_breakpoint): Create breakpoints according to their types.
4758 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
4759 (set_gdb_breakpoint_1): Likewise.
4760 (set_gdb_breakpoint): Likewise.
4761 (clear_breakpoint_conditions): Change parameter type to
4762 'struct gdb_breakpoint *'.
4763 (clear_breakpoint_commands): Likewise.
4764 (clear_breakpoint_conditions_and_commands): Likewise.
4765 (add_condition_to_breakpoint): Likewise.
4766 (add_breakpoint_condition): Likewise.
4767 (add_commands_to_breakpoint): Likewise.
4768 (check_breakpoints): Check other_breakpoint.
4769 (clone_one_breakpoint): Clone breakpopint according to its type.
4770 * mem-break.h (struct gdb_breakpoint): Declare.
4771 (set_gdb_breakpoint): Update declaration.
4772 (clear_breakpoint_conditions_and_commands): Likewise.
4773 (add_breakpoint_condition): Likewise.
4774 (add_breakpoint_commands): Likewise.
4775 * server.c (process_point_options): Change parameter type to
4776 'struct gdb_breakpoint *'.
4778 2016-07-21 Yao Qi <yao.qi@linaro.org>
4780 * mem-break.c (set_breakpoint_at): Rename it to ...
4781 (set_breakpoint_type_at): ... it.
4782 (set_breakpoint_at): Call set_breakpoint_type_at.
4783 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
4784 * mem-break.h (set_breakpoint_at): Update comments.
4786 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
4788 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
4790 (nios2_store_gregset): Likewise.
4792 2016-07-01 Pedro Alves <palves@redhat.com>
4793 Antoine Tremblay <antoine.tremblay@ericsson.com>
4795 * linux-low.c: Change interface to take the target lwp_info
4796 pointer directly and return void. Handle detaching from a zombie
4798 (linux_detach_lwp_callback): New function.
4799 (linux_detach): Detach from the leader thread after detaching from
4802 2016-06-28 Yao Qi <yao.qi@linaro.org>
4804 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
4805 for variable new_offset.
4806 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
4807 (aarch64_ftrace_insn_reloc_cb): Likewise.
4808 (aarch64_ftrace_insn_reloc_tb): Likewise.
4809 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
4810 PRIx64 instead of PRIx32.
4812 2016-06-28 Yao Qi <yao.qi@linaro.org>
4814 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
4815 (the_low_target): Install arm_get_syscall_trapinfo.
4817 2016-06-28 Yao Qi <yao.qi@linaro.org>
4819 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
4821 (the_low_target): Install aarch64_get_syscall_trapinfo.
4823 2016-06-28 Yao Qi <yao.qi@linaro.org>
4825 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
4827 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
4828 Remove parameter sysno.
4829 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
4832 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
4834 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
4835 (s390_emit_ne_goto): Likewise.
4836 (s390_emit_lt_goto): Likewise.
4837 (s390_emit_le_goto): Likewise.
4838 (s390_emit_gt_goto): Likewise.
4839 (s390_emit_ge_goto): Likewise.
4840 (s390x_emit_eq_goto): Likewise.
4841 (s390x_emit_ne_goto): Likewise.
4842 (s390x_emit_lt_goto): Likewise.
4843 (s390x_emit_le_goto): Likewise.
4844 (s390x_emit_gt_goto): Likewise.
4845 (s390x_emit_ge_goto): Likewise.
4846 (s390_emit_ops_impl): Mark variable static.
4847 (s390x_emit_ops): Likewise.
4849 2016-06-17 Yao Qi <yao.qi@linaro.org>
4851 * linux-low.c (handle_extended_wait): Call
4852 uninsert_reinsert_breakpoints for the parent process. Remove
4853 reinsert breakpoints from the child process. Reinsert them to
4854 the parent process when vfork is done.
4855 * mem-break.c (uninsert_reinsert_breakpoints): New function.
4856 (reinsert_reinsert_breakpoints): New function.
4857 * mem-break.h (uninsert_reinsert_breakpoints): Declare
4858 (reinsert_reinsert_breakpoints): Declare.
4860 2016-06-17 Yao Qi <yao.qi@linaro.org>
4862 * linux-low.c (handle_extended_wait): If the parent is doing
4863 step-over, remove the reinsert breakpoints from the forked child.
4865 2016-06-17 Yao Qi <yao.qi@linaro.org>
4867 * linux-low.c (unsuspend_all_lwps): Declare.
4868 (linux_low_filter_event): If thread exited, call finish_step_over.
4869 If step-over is finished, unsuspend other threads.
4871 2016-06-17 Yao Qi <yao.qi@linaro.org>
4873 * linux-low.c (linux_resume_one_lwp_throw): Assert
4874 has_reinsert_breakpoints returns false.
4875 * mem-break.c (delete_disabled_breakpoints): Assert
4876 bp type isn't reinsert_breakpoint.
4878 2016-06-17 Yao Qi <yao.qi@linaro.org>
4880 * linux-low.c (maybe_hw_step): New function.
4881 (linux_resume_one_lwp_throw): Call maybe_hw_step.
4882 (finish_step_over): Switch current_thread to lwp temporarily,
4883 and assert has_reinsert_breakpoints returns true.
4884 (proceed_one_lwp): Call maybe_hw_step.
4885 * mem-break.c (has_reinsert_breakpoints): New function.
4886 * mem-break.h (has_reinsert_breakpoints): Declare.
4888 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
4890 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
4892 2016-05-17 Yao Qi <yao.qi@linaro.org>
4894 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
4895 instead of find_inferior.
4897 2016-05-05 Yao Qi <yao.qi@linaro.org>
4899 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
4900 Initialize res to zero.
4902 2016-05-05 Yao Qi <yao.qi@linaro.org>
4904 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
4907 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
4909 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
4910 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
4911 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
4913 2016-04-28 Par Olsson <par.olsson@windriver.com>
4914 Simon Marchi <simon.marchi@ericsson.com>
4916 * tracepoint.c (write_inferior_int8): New function.
4917 (cmd_qtenable_disable): Write enable flag using
4918 write_inferior_int8.
4920 2016-04-25 Yao Qi <yao.qi@linaro.org>
4922 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
4923 (need_step_over_p): Return zero if the LWP has pending signals
4924 can be delivered on software single step target.
4926 2016-04-25 Yao Qi <yao.qi@linaro.org>
4928 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
4929 return instead of error.
4931 2016-04-22 Yao Qi <yao.qi@linaro.org>
4933 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
4936 2016-04-22 Yao Qi <yao.qi@linaro.org>
4938 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
4939 signal when stepping over breakpoint with software single
4942 2016-04-21 Pedro Alves <palves@redhat.com>
4944 * linux-s390-low.c (s390_collect_ptrace_register)
4945 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
4947 (s390_check_regset): Use void * instead of gdb_byte *.
4949 2016-04-20 Pedro Alves <palves@redhat.com>
4951 * configure: Renegerate.
4953 2016-04-20 Yao Qi <yao.qi@linaro.org>
4955 * linux-aarch32-low.c: Include "arch/arm-linux.h".
4956 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
4958 (arm_store_gregset): Likewise.
4960 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
4962 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
4963 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
4964 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
4965 (amd64-avx-mpx-linux.c): New rules.
4966 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
4967 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
4968 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
4969 (srv_amd64_regobj): Add amd64-avx-mpx.o.
4970 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
4971 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
4972 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
4973 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
4974 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
4975 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
4976 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
4977 * linux-x86-low.c (x86_linux_read_description): Add case for
4978 X86_XSTATE_AVX_MPX_MASK.
4979 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
4980 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
4981 init_registers_i386_avx_mpx_linux.
4982 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
4983 (initialize_low_tracepoint): Call
4984 init_registers_i386_avx_mpx_linux.
4985 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
4986 (initialize_low_tracepoint): Call
4987 init_registers_amd64_avx_mpx_linux.
4988 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
4989 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
4990 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
4993 2016-04-18 Pedro Alves <palves@redhat.com>
4995 * configure: Regenerate.
4997 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
4999 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
5000 (aarch64_emit_sub): Likewise.
5002 2016-04-12 Pedro Alves <palves@redhat.com>
5004 * utils.c (prepare_to_throw_exception): Delete.
5006 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
5008 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
5010 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
5012 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
5014 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
5016 * linux-aarch64-ipa.c: Add <elf.h> include.
5017 * linux-ppc-ipa.c: Add <elf.h> include.
5018 * linux-s390-ipa.c: Add <elf.h> include.
5020 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
5022 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
5023 (get_raw_reg_ptr): Likewise.
5024 (get_trace_state_variable_value_ptr): Likewise.
5025 (set_trace_state_variable_value_ptr): Likewise.
5026 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
5029 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
5030 Marcin Kościelnicki <koriakin@0x04.net>
5033 * linux-ppc-low.c (emit_insns): New function.
5034 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
5035 (ppc_emit_prologue): New function.
5036 (ppc_emit_epilogue): New function.
5037 (ppc_emit_add): New function.
5038 (ppc_emit_sub): New function.
5039 (ppc_emit_mul): New function.
5040 (ppc_emit_lsh): New function.
5041 (ppc_emit_rsh_signed): New function.
5042 (ppc_emit_rsh_unsigned): New function.
5043 (ppc_emit_ext): New function.
5044 (ppc_emit_zero_ext): New function.
5045 (ppc_emit_log_not): New function.
5046 (ppc_emit_bit_and): New function.
5047 (ppc_emit_bit_or): New function.
5048 (ppc_emit_bit_xor): New function.
5049 (ppc_emit_bit_not): New function.
5050 (ppc_emit_equal): New function.
5051 (ppc_emit_less_signed): New function.
5052 (ppc_emit_less_unsigned): New function.
5053 (ppc_emit_ref): New function.
5054 (ppc_emit_const): New function.
5055 (ppc_emit_reg): New function.
5056 (ppc_emit_pop): New function.
5057 (ppc_emit_stack_flush): New function.
5058 (ppc_emit_swap): New function.
5059 (ppc_emit_stack_adjust): New function.
5060 (ppc_emit_call): New function.
5061 (ppc_emit_int_call_1): New function.
5062 (ppc_emit_void_call_2): New function.
5063 (ppc_emit_if_goto): New function.
5064 (ppc_emit_goto): New function.
5065 (ppc_emit_eq_goto): New function.
5066 (ppc_emit_ne_goto): New function.
5067 (ppc_emit_lt_goto): New function.
5068 (ppc_emit_le_goto): New function.
5069 (ppc_emit_gt_goto): New function.
5070 (ppc_emit_ge_goto): New function.
5071 (ppc_write_goto_address): New function.
5072 (ppc_emit_ops_impl): New static variable.
5073 (ppc64v1_emit_prologue): New function.
5074 (ppc64v2_emit_prologue): New function.
5075 (ppc64_emit_epilogue): New function.
5076 (ppc64_emit_add): New function.
5077 (ppc64_emit_sub): New function.
5078 (ppc64_emit_mul): New function.
5079 (ppc64_emit_lsh): New function.
5080 (ppc64_emit_rsh_signed): New function.
5081 (ppc64_emit_rsh_unsigned): New function.
5082 (ppc64_emit_ext): New function.
5083 (ppc64_emit_zero_ext): New function.
5084 (ppc64_emit_log_not): New function.
5085 (ppc64_emit_bit_and): New function.
5086 (ppc64_emit_bit_or): New function.
5087 (ppc64_emit_bit_xor): New function.
5088 (ppc64_emit_bit_not): New function.
5089 (ppc64_emit_equal): New function.
5090 (ppc64_emit_less_signed): New function.
5091 (ppc64_emit_less_unsigned): New function.
5092 (ppc64_emit_ref): New function.
5093 (ppc64_emit_const): New function.
5094 (ppc64v1_emit_reg): New function.
5095 (ppc64v2_emit_reg): New function.
5096 (ppc64_emit_pop): New function.
5097 (ppc64_emit_stack_flush): New function.
5098 (ppc64_emit_swap): New function.
5099 (ppc64v1_emit_call): New function.
5100 (ppc64v2_emit_call): New function.
5101 (ppc64v1_emit_int_call_1): New function.
5102 (ppc64v2_emit_int_call_1): New function.
5103 (ppc64v1_emit_void_call_2): New function.
5104 (ppc64v2_emit_void_call_2): New function.
5105 (ppc64_emit_if_goto): New function.
5106 (ppc64_emit_eq_goto): New function.
5107 (ppc64_emit_ne_goto): New function.
5108 (ppc64_emit_lt_goto): New function.
5109 (ppc64_emit_le_goto): New function.
5110 (ppc64_emit_gt_goto): New function.
5111 (ppc64_emit_ge_goto): New function.
5112 (ppc64v1_emit_ops_impl): New static variable.
5113 (ppc64v2_emit_ops_impl): New static variable.
5114 (ppc_emit_ops): New function.
5115 (linux_low_target): Wire in ppc_emit_ops.
5117 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
5118 Marcin Kościelnicki <koriakin@0x04.net>
5121 * Makefile.in: Add powerpc-*-ipa.o
5122 * configure.srv: Add ipa_obj for powerpc*-linux.
5123 * linux-ppc-ipa.c: New file.
5124 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
5126 (PPC_FIELD): New macro.
5127 (PPC_SEXT): New macro.
5128 (PPC_OP6): New macro.
5129 (PPC_BO): New macro.
5130 (PPC_LI): New macro.
5131 (PPC_BD): New macro.
5132 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
5133 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
5134 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
5135 (ppc_get_thread_area): New function.
5136 (is_elfv2_inferior): New function.
5137 (gen_ds_form): New function.
5138 (GEN_STD): New macro.
5139 (GEN_STDU): New macro.
5140 (GEN_LD): New macro.
5141 (GEN_LDU): New macro.
5142 (gen_d_form): New function.
5143 (GEN_ADDI): New macro.
5144 (GEN_ADDIS): New macro.
5145 (GEN_LI): New macro.
5146 (GEN_LIS): New macro.
5147 (GEN_ORI): New macro.
5148 (GEN_ORIS): New macro.
5149 (GEN_LWZ): New macro.
5150 (GEN_STW): New macro.
5151 (GEN_STWU): New macro.
5152 (gen_xfx_form): New function.
5153 (GEN_MFSPR): New macro.
5154 (GEN_MTSPR): New macro.
5155 (GEN_MFCR): New macro.
5156 (GEN_MTCR): New macro.
5157 (GEN_SYNC): New macro.
5158 (GEN_LWSYNC): New macro.
5159 (gen_x_form): New function.
5160 (GEN_OR): New macro.
5161 (GEN_MR): New macro.
5162 (GEN_LWARX): New macro.
5163 (GEN_STWCX): New macro.
5164 (GEN_CMPW): New macro.
5165 (gen_md_form): New function.
5166 (GEN_RLDICL): New macro.
5167 (GEN_RLDICR): New macro.
5168 (gen_i_form): New function.
5170 (GEN_BL): New macro.
5171 (gen_b_form): New function.
5172 (GEN_BNE): New macro.
5173 (GEN_LOAD): New macro.
5174 (GEN_STORE): New macro.
5175 (gen_limm): New function.
5176 (gen_atomic_xchg): New function.
5177 (gen_call): New function.
5178 (ppc_relocate_instruction): New function.
5179 (ppc_install_fast_tracepoint_jump_pad): New function.
5180 (ppc_get_min_fast_tracepoint_insn_len): New function.
5181 (ppc_get_ipa_tdesc_idx): New function.
5182 (the_low_target): Wire in the new functions.
5183 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
5185 * linux-ppc-tdesc.h: New file.
5187 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
5189 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
5190 (alloc_jump_pad_buffer): New function.
5191 * linux-amd64-ipa.c: Add <sys/mman.h> include.
5192 (alloc_jump_pad_buffer): New function.
5193 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
5194 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
5195 (alloc_jump_pad_buffer): New function.
5196 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
5197 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
5198 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
5199 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
5201 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
5203 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
5204 * linux-amd64-ipa.c: Likewise.
5205 * linux-i386-ipa.c: Likewise.
5206 * linux-s390-ipa.c: Likewise.
5207 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
5208 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
5209 set_trace_state_variable_value_ptr.
5210 (struct ipa_sym_addresses): Likewise.
5211 (symbol_list): Likewise.
5212 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
5213 accessing gdb_collect directly.
5214 (gdb_collect_ptr_type): New typedef.
5215 (get_raw_reg_ptr_type): New typedef.
5216 (get_trace_state_variable_value_ptr_type): New typedef.
5217 (set_trace_state_variable_value_ptr_type): New typedef.
5218 (gdb_collect_ptr): New global.
5219 (get_raw_reg_ptr): New global.
5220 (get_trace_state_variable_value_ptr): New global.
5221 (set_trace_state_variable_value_ptr): New global.
5222 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
5223 accessing get_raw_reg directly.
5224 (get_get_tsv_func_addr): Likewise for
5225 get_trace_state_variable_value_ptr.
5226 (get_set_tsv_func_addr): Likewise for
5227 set_trace_state_variable_value_ptr.
5228 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
5230 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
5232 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
5234 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
5236 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
5238 (relocate_instruction): Remove own_buf.
5239 * server.c (own_buf): Make global.
5240 (handle_v_requests): Make global.
5241 * server.h (own_buf): New declaration.
5242 (handle_v_requests): New prototype.
5244 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
5247 * linux-s390-low.c (add_insns): New function.
5248 (s390_emit_prologue): New function.
5249 (s390_emit_epilogue): New function.
5250 (s390_emit_add): New function.
5251 (s390_emit_sub): New function.
5252 (s390_emit_mul): New function.
5253 (s390_emit_lsh): New function.
5254 (s390_emit_rsh_signed): New function.
5255 (s390_emit_rsh_unsigned): New function.
5256 (s390_emit_ext): New function.
5257 (s390_emit_log_not): New function.
5258 (s390_emit_bit_and): New function.
5259 (s390_emit_bit_or): New function.
5260 (s390_emit_bit_xor): New function.
5261 (s390_emit_bit_not): New function.
5262 (s390_emit_equal): New function.
5263 (s390_emit_less_signed): New function.
5264 (s390_emit_less_unsigned): New function.
5265 (s390_emit_ref): New function.
5266 (s390_emit_if_goto): New function.
5267 (s390_emit_goto): New function.
5268 (s390_write_goto_address): New function.
5269 (s390_emit_litpool): New function.
5270 (s390_emit_const): New function.
5271 (s390_emit_call): New function.
5272 (s390_emit_reg): New function.
5273 (s390_emit_pop): New function.
5274 (s390_emit_stack_flush): New function.
5275 (s390_emit_zero_ext): New function.
5276 (s390_emit_swap): New function.
5277 (s390_emit_stack_adjust): New function.
5278 (s390_emit_set_r2): New function.
5279 (s390_emit_int_call_1): New function.
5280 (s390_emit_void_call_2): New function.
5281 (s390_emit_eq_goto): New function.
5282 (s390_emit_ne_goto): New function.
5283 (s390_emit_lt_goto): New function.
5284 (s390_emit_le_goto): New function.
5285 (s390_emit_gt_goto): New function.
5286 (s390_emit_ge_goto): New function.
5287 (s390x_emit_prologue): New function.
5288 (s390x_emit_epilogue): New function.
5289 (s390x_emit_add): New function.
5290 (s390x_emit_sub): New function.
5291 (s390x_emit_mul): New function.
5292 (s390x_emit_lsh): New function.
5293 (s390x_emit_rsh_signed): New function.
5294 (s390x_emit_rsh_unsigned): New function.
5295 (s390x_emit_ext): New function.
5296 (s390x_emit_log_not): New function.
5297 (s390x_emit_bit_and): New function.
5298 (s390x_emit_bit_or): New function.
5299 (s390x_emit_bit_xor): New function.
5300 (s390x_emit_bit_not): New function.
5301 (s390x_emit_equal): New function.
5302 (s390x_emit_less_signed): New function.
5303 (s390x_emit_less_unsigned): New function.
5304 (s390x_emit_ref): New function.
5305 (s390x_emit_if_goto): New function.
5306 (s390x_emit_const): New function.
5307 (s390x_emit_call): New function.
5308 (s390x_emit_reg): New function.
5309 (s390x_emit_pop): New function.
5310 (s390x_emit_stack_flush): New function.
5311 (s390x_emit_zero_ext): New function.
5312 (s390x_emit_swap): New function.
5313 (s390x_emit_stack_adjust): New function.
5314 (s390x_emit_int_call_1): New function.
5315 (s390x_emit_void_call_2): New function.
5316 (s390x_emit_eq_goto): New function.
5317 (s390x_emit_ne_goto): New function.
5318 (s390x_emit_lt_goto): New function.
5319 (s390x_emit_le_goto): New function.
5320 (s390x_emit_gt_goto): New function.
5321 (s390x_emit_ge_goto): New function.
5322 (s390_emit_ops): New function.
5323 (struct linux_target_ops): Fill in emit_ops hook.
5325 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
5328 * Makefile.in: Add s390 IPA files.
5329 * configure.srv: Build IPA for s390.
5330 * linux-s390-ipa.c: New file.
5331 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
5332 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
5333 (tdesc_s390_linux32): Likewise.
5334 (init_registers_s390_linux32v1): Likewise.
5335 (tdesc_s390_linux32v1): Likewise.
5336 (init_registers_s390_linux32v2): Likewise.
5337 (tdesc_s390_linux32v2): Likewise.
5338 (init_registers_s390_linux64): Likewise.
5339 (tdesc_s390_linux64): Likewise.
5340 (init_registers_s390_linux64v1): Likewise.
5341 (tdesc_s390_linux64v1): Likewise.
5342 (init_registers_s390_linux64v2): Likewise.
5343 (tdesc_s390_linux64v2): Likewise.
5344 (init_registers_s390_te_linux64): Likewise.
5345 (tdesc_s390_te_linux64): Likewise.
5346 (init_registers_s390_vx_linux64): Likewise.
5347 (tdesc_s390_vx_linux64): Likewise.
5348 (init_registers_s390_tevx_linux64): Likewise.
5349 (tdesc_s390_tevx_linux64): Likewise.
5350 (init_registers_s390x_linux64): Likewise.
5351 (tdesc_s390x_linux64): Likewise.
5352 (init_registers_s390x_linux64v1): Likewise.
5353 (tdesc_s390x_linux64v1): Likewise.
5354 (init_registers_s390x_linux64v2): Likewise.
5355 (tdesc_s390x_linux64v2): Likewise.
5356 (init_registers_s390x_te_linux64): Likewise.
5357 (tdesc_s390x_te_linux64): Likewise.
5358 (init_registers_s390x_vx_linux64): Likewise.
5359 (tdesc_s390x_vx_linux64): Likewise.
5360 (init_registers_s390x_tevx_linux64): Likewise.
5361 (tdesc_s390x_tevx_linux64): Likewise.
5362 (have_hwcap_s390_vx): New static variable.
5363 (s390_arch_setup): Fill have_hwcap_s390_vx.
5364 (s390_get_thread_area): New function.
5365 (s390_ft_entry_gpr_esa): New const.
5366 (s390_ft_entry_gpr_zarch): New const.
5367 (s390_ft_entry_misc): New const.
5368 (s390_ft_entry_fr): New const.
5369 (s390_ft_entry_vr): New const.
5370 (s390_ft_main_31): New const.
5371 (s390_ft_main_64): New const.
5372 (s390_ft_exit_fr): New const.
5373 (s390_ft_exit_vr): New const.
5374 (s390_ft_exit_misc): New const.
5375 (s390_ft_exit_gpr_esa): New const.
5376 (s390_ft_exit_gpr_zarch): New const.
5377 (append_insns): New function.
5378 (s390_relocate_instruction): New function.
5379 (s390_install_fast_tracepoint_jump_pad): New function.
5380 (s390_get_min_fast_tracepoint_insn_len): New function.
5381 (s390_get_ipa_tdesc_idx): New function.
5382 (struct linux_target_ops): Wire in the above functions.
5383 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
5384 * linux-s390-tdesc.h: New file.
5386 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
5388 * linux-s390-low.c (s390_supports_tracepoints): New function.
5389 (struct linux_target_ops): Fill supports_tracepoints hook.
5391 2016-03-18 Yao Qi <yao.qi@linaro.org>
5393 * linux-low.c (lwp_signal_can_be_delivered): New function.
5394 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
5396 2016-03-18 Yao Qi <yao.qi@linaro.org>
5398 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
5399 0 if signal is enqueued. Remove 'signal' from one debugging
5400 message. Move one debugging message to some lines below.
5401 Remove code setting 'signal' to 0.
5403 2016-03-18 Yao Qi <yao.qi@linaro.org>
5405 * linux-low.c (linux_low_filter_event): Remove redundant
5406 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
5408 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
5410 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
5411 (struct linux_target_ops): Wire in the above.
5413 2016-03-03 Yao Qi <yao.qi@linaro.org>
5415 * linux-low.c: Update comments to start_step_over.
5417 2016-03-03 Yao Qi <yao.qi@linaro.org>
5420 * linux-low.c (handle_extended_wait): Set child suspended
5421 if event_lwp->bp_reinsert isn't zero.
5423 2016-03-02 Yao Qi <yao.qi@linaro.org>
5425 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
5426 enqueue_pending_signal.
5428 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
5430 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
5433 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
5435 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
5436 (s390_regmap_3264) [!__s390x__]: New global.
5437 (s390_collect_ptrace_register): Skip map entries containing -1.
5438 (s390_supply_ptrace_register): Ditto.
5439 (s390_fill_gprs_high): New function.
5440 (s390_store_gprs_high): New function.
5441 (s390_regsets): Add NT_S390_HIGH_GPRS.
5442 (s390_get_hwcap): Enable on 31-bit.
5443 (have_hwcap_s390_high_gprs): Enable on 31-bit.
5444 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
5445 Detect NT_S390_HIGH_GPRS.
5446 (s390_usrregs_info_3264): Enable on 31-bit.
5447 (s390_regs_info): Enable regs_info_3264 on 31-bit.
5448 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
5450 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
5453 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
5454 * configure.srv: Ditto.
5455 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
5456 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
5457 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
5458 (init_registers_amd64_linux): Remove prototype.
5459 (tdesc_amd64_linux): Remove declaration.
5460 (get_ipa_tdesc): New function.
5461 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
5462 initialize remaining tdescs.
5463 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
5464 (init_registers_i386_linux): Remove prototype.
5465 (tdesc_i386_linux): Remove declaration.
5466 (get_ipa_tdesc): New function.
5467 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
5468 initialize remaining tdescs.
5469 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
5470 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
5471 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
5472 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
5473 (x86_get_ipa_tdesc_idx): New function.
5474 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
5475 * linux-x86-tdesc.h: New file.
5476 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
5477 (target_get_ipa_tdesc_idx): New macro.
5478 * tracepoint.c (ipa_tdesc_idx): New macro.
5479 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
5480 (symbol_list): Add ipa_tdesc_idx.
5481 (cmd_qtstart): Write ipa_tdesc_idx in the target.
5482 (ipa_tdesc): Remove.
5483 (ipa_tdesc_idx): New variable.
5484 (get_context_regcache): Use get_ipa_tdesc.
5485 (gdb_collect): Ditto.
5487 * tracepoint.h (get_ipa_tdesc): New prototype.
5488 (ipa_tdesc): Remove.
5490 2016-02-24 Pedro Alves <palves@redhat.com>
5492 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
5493 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
5494 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
5495 Factor out common code between the USE_SIGTRAP_SIGINFO and
5496 !USE_SIGTRAP_SIGINFO blocks.
5497 (linux_low_filter_event): Call save_stop_reason instead of
5498 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
5500 (linux_wait_1): Update comments.
5502 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
5504 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
5505 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
5506 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
5507 ppc_insert_point, ppc_remove_point.
5509 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
5511 * linux-s390-low.c (s390_supports_z_point_type): New function.
5512 (struct linux_target_ops): Wire s390_supports_z_point_type in.
5514 2016-02-16 Yao Qi <yao.qi@linaro.org>
5516 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
5517 PC. Get pc from regcache_read_pc.
5519 2016-02-12 Yao Qi <yao.qi@linaro.org>
5521 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
5522 or linux_get_pc_32bit.
5523 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
5525 2016-02-12 Yao Qi <yao.qi@linaro.org>
5527 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
5528 arm_linux_get_next_pcs_fixup.
5530 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
5532 * tracepoint.c (x_tracepoint_action_download): Change
5533 write_inferior_data_ptr to write_inferior_data_pointer.
5534 (cmd_qtstart): Likewise.
5535 (write_inferior_data_ptr): Remove.
5536 (download_agent_expr): Change write_inferior_data_ptr to
5537 write_inferior_data_pointer.
5538 (download_tracepoint_1): Likewise.
5539 (download_tracepoint): Likewise.
5540 (download_trace_state_variables): Likewise.
5542 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
5543 Marcin Kościelnicki <koriakin@0x04.net>
5545 * tracepoint.c (struct tracepoint_action_ops): Remove.
5546 (struct tracepoint_action): Remove ops.
5547 (m_tracepoint_action_download, r_tracepoint_action_download)
5548 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
5549 size and offset accordingly.
5550 (m_tracepoint_action_ops, r_tracepoint_action_ops)
5551 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
5552 (tracepoint_action_send, tracepoint_action_download): New functions.
5553 Helpers for trace action handlers.
5554 (add_tracepoint_action): Remove setup actions ops.
5555 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
5557 2016-02-10 Yao Qi <yao.qi@linaro.org>
5559 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
5561 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
5563 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
5565 * configure: Regenerate.
5567 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
5569 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
5570 void * to gdb_byte *.
5571 * linux-low.c (siginfo_fixup): Likewise.
5572 (linux_xfer_siginfo): Likewise.
5573 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
5575 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
5577 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
5579 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
5581 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
5583 * linux-x86-low.c [__x86_64__]: Include
5584 "nat/amd64-linux-siginfo.h".
5585 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
5586 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
5587 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
5588 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
5589 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
5590 (cpt_si_fd, si_timerid, si_overrun): Move from
5591 nat/amd64-linux-siginfo.c.
5592 * Makefile.in (amd64-linux-siginfo.o:): New rule.
5594 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
5596 * server.c (skip_to_semicolon): Remove.
5597 (process_point_options): Use strchrnul instead of
5600 2016-01-26 Yao Qi <yao.qi@linaro.org>
5602 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
5603 * linux-low.c (install_software_single_step_breakpoints): Don't
5604 call regcache_read_pc.
5605 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
5608 2016-01-26 Yao Qi <yao.qi@linaro.org>
5610 * linux-low.c (install_software_single_step_breakpoints): Call
5611 regcache_read_pc instead of get_pc.
5613 2016-01-26 Yao Qi <yao.qi@linaro.org>
5615 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
5616 (unblock_async_io): Rename to ...
5617 (block_unblock_async_io): ... it. New function.
5618 (enable_async_io): Don't install SIGIO handler. Unblock it
5620 (disable_async_io): Don't ignore SIGIO. Block it instead.
5621 (initialize_async_io): Install SIGIO handler. Don't call
5624 2016-01-26 Yao Qi <yao.qi@linaro.org>
5626 * remote-utils.c (getpkt): If the buffer isn't empty, and the
5627 first character is '\003', call *the_target->request_interrupt.
5629 2016-01-25 Yao Qi <yao.qi@linaro.org>
5631 * remote-utils.c (new_thread_notify): Remove.
5632 (dead_thread_notify): Likewise.
5633 * remote-utils.h (new_thread_notify): Remove declaration.
5634 (dead_thread_notify): Likewise.
5636 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
5638 * gdb.trace/pending.exp: Fix expected message on continue.
5640 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
5642 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
5643 it works properly on big-endian machines where sizeof (CORE_ADDR)
5646 2016-01-21 Pedro Alves <palves@redhat.com>
5648 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
5649 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
5650 * configure: Regenerate.
5652 2016-01-21 Yao Qi <yao.qi@linaro.org>
5654 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
5655 is_thumb and set it according to CPSR saved on the stack.
5656 (get_next_pcs_syscall_next_pc): Pass is_thumb to
5657 arm_sigreturn_next_pc.
5659 2016-01-18 Yao Qi <yao.qi@linaro.org>
5661 * linux-low.c (linux_set_pc_64bit): New function.
5662 (linux_get_pc_64bit): New function.
5663 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
5665 * linux-sparc-low.c (debug_threads): Remove declaration.
5666 (sparc_get_pc): Remove.
5667 (the_low_target): Use linux_get_pc_64bit instead of
5669 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
5670 (the_low_target): Use linux_get_pc_64bit and
5673 2016-01-18 Yao Qi <yao.qi@linaro.org>
5675 * linux-arm-low.c (debug_threads): Remove declaration.
5676 (arm_get_pc, arm_set_pc): Remove.
5677 (the_low_target): Use linux_get_pc_32bit and
5679 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
5680 (the_low_target): Use linux_get_pc_32bit and
5682 * linux-cris-low.c (debug_threads): Remove declaration.
5683 (cris_get_pc, cris_set_pc,): Remove.
5684 (the_low_target): Use linux_get_pc_32bit and
5686 * linux-crisv32-low.c (debug_threads): Remove declaration.
5687 (cris_get_pc, cris_set_pc): Remove.
5688 (the_low_target): Use linux_get_pc_32bit and
5690 * linux-low.c: Include inttypes.h.
5691 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
5692 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
5693 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
5694 (the_low_target): Use linux_get_pc_32bit and
5696 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
5697 (the_low_target): Use linux_get_pc_32bit and
5699 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
5700 (the_low_target): Use linux_get_pc_32bit and
5702 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
5703 (the_low_target): Use linux_get_pc_32bit and
5705 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
5706 (the_low_target): Use linux_get_pc_32bit and
5709 2016-01-18 Gary Benson <gbenson@redhat.com>
5711 * configure.ac (AC_FUNC_FORK): New check.
5712 * config.in: Regenerate.
5713 * configure: Likewise.
5715 2016-01-14 Yao Qi <yao.qi@linaro.org>
5717 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
5718 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
5719 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
5720 arm_get_next_pcs_ctor.
5722 2016-01-12 Josh Stone <jistone@redhat.com>
5723 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5725 * inferiors.h: Include "gdb_vecs.h".
5726 (struct process_info): Add syscalls_to_catch.
5727 * inferiors.c (remove_process): Free syscalls_to_catch.
5728 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
5729 syscall_return stops.
5730 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
5731 * server.c (handle_general_set): Handle QCatchSyscalls.
5732 (handle_query): Report support for QCatchSyscalls.
5733 * target.h (struct target_ops): Add supports_catch_syscall.
5734 (target_supports_catch_syscall): New macro.
5735 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
5736 (struct lwp_info): Add syscall_state.
5737 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
5738 Maintain syscall_state and syscalls_to_catch across exec.
5739 (get_syscall_trapinfo): New function, proxy to the_low_target.
5740 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
5741 (linux_low_filter_event): Toggle syscall_state entry/return for
5742 syscall traps, and set it ignored for all others.
5743 (gdb_catching_syscalls_p): New function.
5744 (gdb_catch_this_syscall_p): New function.
5745 (linux_wait_1): Handle SYSCALL_SIGTRAP.
5746 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
5747 (linux_supports_catch_syscall): New function.
5748 (linux_target_ops): Install it.
5749 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
5750 (the_low_target): Install it.
5752 2016-01-12 Mike Frysinger <vapier@gentoo.org>
5754 * acinclude.m4: Include new ../warning.m4 file.
5755 * configure: Regenerated.
5756 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
5758 2016-01-12 Mike Frysinger <vapier@gentoo.org>
5760 * ax.c (is_goto_target): Mark static.
5761 * linux-low.c (register_addr): Likewise.
5762 (linux_fetch_registers, linux_store_registers): Likewise.
5763 * mem-break.c (any_persistent_commands): Fix old prototype.
5764 (add_commands_to_breakpoint): Mark static.
5765 * regcache.c (find_register_by_name): Delete unused func.
5766 * remote-utils.c (hex_or_minus_one): Mark static.
5767 * server.c (monitor_show_help): Mark static.
5768 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
5769 handle_v_requests): Likewise.
5771 2016-01-12 Pedro Alves <palves@redhat.com>
5773 Remove use of the registered trademark symbol throughout.
5775 2016-01-08 Yao Qi <yao.qi@linaro.org>
5777 * remote-utils.c (getpkt): If c is '\003', call target hook
5780 2016-01-06 Yao Qi <yao.qi@linaro.org>
5782 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
5783 linux-aarch32-low.c.
5784 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
5785 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
5786 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
5787 (thumb2_breakpoint): Declare.
5788 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
5789 linux-aarch32-low.h.
5790 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
5791 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
5792 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
5794 2016-01-01 Joel Brobecker <brobecker@adacore.com>
5796 * gdbreplay.c (gdbreplay_version): Change copyright year in
5798 * server.c (gdbserver_version): Likewise.
5800 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
5802 * server.c (crc32_table): Delete.
5803 (crc32): Use libiberty's xcrc32 function.
5805 2015-12-22 Joel Brobecker <brobecker@adacore.com>
5807 * lynx-low.c (lynx_delete_thread_callback): New function.
5808 (lynx_mourn): Properly delete our process and all of its
5809 threads. Remove call to clear_inferiors.
5811 2015-12-22 Joel Brobecker <brobecker@adacore.com>
5813 * target.c (thread_search_callback): Add check that
5814 the thread_stopped target callback is not NULL before
5817 2015-12-21 Yao Qi <yao.qi@linaro.org>
5819 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
5822 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
5824 * server.c (handle_query): Call target_supports_software_single_step.
5826 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
5828 * linux-low.c (single_step): New function.
5829 (linux_resume_one_lwp_throw): Call single_step.
5830 (start_step_over): Likewise.
5832 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
5834 * Makefile.in (SFILES): Append arch/arm-linux.c,
5835 arch/arm-get-next-pcs.c.
5836 (arm-linux.o): New rule.
5837 (arm-get-next-pcs.o): New rule.
5838 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
5840 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
5841 to linux-aarch32-low.c.
5842 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
5843 (arm_breakpoint_len, thumb_breakpoint): Likewise.
5844 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
5845 (thumb2_breakpoint_len): Likewise.
5846 (arm_is_thumb_mode): Make non-static.
5847 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
5848 from linux-aarch32-low.c.
5849 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
5850 (arm_breakpoint_len, thumb_breakpoint): Likewise.
5851 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
5852 (thumb2_breakpoint_len): Likewise.
5853 (arm_is_thumb_mode): New declaration.
5854 * linux-arm-low.c: Include arch/arm-linux.h
5855 aarch/arm-get-next-pcs.h, sys/syscall.h.
5856 (get_next_pcs_ops): New struct.
5857 (get_next_pcs_addr_bits_remove): New function.
5858 (get_next_pcs_is_thumb): New function.
5859 (get_next_pcs_read_memory_unsigned_integer): Likewise.
5860 (arm_sigreturn_next_pc): Likewise.
5861 (get_next_pcs_syscall_next_pc): Likewise.
5862 (arm_gdbserver_get_next_pcs): Likewise.
5863 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
5865 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
5866 * server.h: Include gdb_vecs.h.
5868 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
5870 * Makefile.in (SFILES): Append common/common-regcache.c.
5871 (OBS): Append common-regcache.o.
5872 (common-regcache.o): New rule.
5873 * regcache.c (init_register_cache): Initialize cache to
5875 (regcache_raw_read_unsigned): New function.
5876 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
5877 register_status enum.
5879 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
5881 * linux-aarch64-low.c (the_low_targets): Rename
5882 breakpoint_reinsert_addr to get_next_pcs.
5883 * linux-arm-low.c (the_low_targets): Likewise.
5884 * linux-bfin-low.c (the_low_targets): Likewise.
5885 * linux-cris-low.c (the_low_targets): Likewise.
5886 * linux-crisv32-low.c (the_low_targets): Likewise.
5887 * linux-low.c (can_software_single_step): Likewise.
5888 (install_software_single_step_breakpoints): New function.
5889 (start_step_over): Use install_software_single_step_breakpoints.
5890 * linux-low.h: New CORE_ADDR vector.
5891 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
5893 * linux-mips-low.c (the_low_targets): Likewise.
5894 * linux-nios2-low.c (the_low_targets): Likewise.
5895 * linux-sparc-low.c (the_low_targets): Likewise.
5897 2015-12-17 Pedro Alves <palves@redhat.com>
5899 * linux-low.c (linux_kill_one_lwp): Remove references to
5901 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
5903 (linux_init_signals): Delete.
5904 (initialize_low): Adjust.
5905 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
5907 2015-12-16 Pedro Alves <palves@redhat.com>
5909 * configure.ac (compiler warning flags): When testing a
5910 -Wno-foo option, check whether -Wfoo works instead.
5911 * configure: Regenerate.
5913 2015-12-11 Don Breazeal <donb@codesourcery.com>
5915 * server.c (process_serial_event): Don't exit from gdbserver
5916 in remote mode if there are still active inferiors.
5918 2015-12-11 Yao Qi <yao.qi@linaro.org>
5920 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
5921 arm_breakpoint_at if the process is 32-bit.
5923 2015-12-11 Yao Qi <yao.qi@linaro.org>
5925 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
5928 2015-12-07 Yao Qi <yao.qi@linaro.org>
5930 * configure.srv: Append arm.o to srv_tgtobj for
5931 aarch64*-*-linux* target.
5932 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
5933 from linux-arm-low.c.
5934 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
5935 (arm_breakpoint_len, thumb_breakpoint): Likewise.
5936 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
5937 (thumb2_breakpoint_len): Likewise.
5938 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
5939 (arm_breakpoint_kinds): Likewise.
5940 (arm_breakpoint_kind_from_pc): Likewise.
5941 (arm_sw_breakpoint_from_kind): Likewise.
5942 (arm_breakpoint_kind_from_current_state): Likewise.
5943 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
5944 (arm_sw_breakpoint_from_kind): Declare.
5945 (arm_breakpoint_kind_from_current_state): Declare.
5946 (arm_breakpoint_at): Declare.
5947 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
5948 arm_sw_breakpoint_from_kind if process is 32-bit.
5949 (aarch64_breakpoint_kind_from_pc): New function.
5950 (aarch64_breakpoint_kind_from_current_state): New function.
5951 (the_low_target): Initialize fields breakpoint_kind_from_pc
5952 and breakpoint_kind_from_current_state.
5953 * linux-arm-low.c (arm_breakpoint_kinds): Move to
5954 linux-aarch32-low.c.
5955 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
5956 (arm_breakpoint, arm_breakpoint_len): Likewise.
5957 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
5958 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
5959 (arm_is_thumb_mode): Likewise.
5960 (arm_breakpoint_at): Likewise.
5961 (arm_breakpoint_kind_from_pc): Likewise.
5962 (arm_sw_breakpoint_from_kind): Likewise.
5963 (arm_breakpoint_kind_from_current_state): Likewise.
5966 2015-08-04 Yao Qi <yao.qi@linaro.org>
5968 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
5969 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
5970 * server.c (extended_protocol): Remove "static".
5971 * server.h (extended_protocol): Declare it.
5973 2015-12-04 Josh Stone <jistone@redhat.com>
5975 * target.h (struct target_ops) <arch_setup>: Rename to ...
5976 (struct target_ops) <post_create_inferior>: ... this.
5977 (target_arch_setup): Rename to ...
5978 (target_post_create_inferior): ... this, calling post_create_inferior.
5979 * server.c (start_inferior): Update target_arch_setup calls to
5980 target_post_create_inferior.
5981 * linux-low.c (linux_low_ptrace_options): Forward declare.
5982 (linux_arch_setup): Update its comment for general use.
5983 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
5984 (struct linux_target_ops): Use linux_post_create_inferior.
5985 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
5986 to post_create_inferior.
5987 * nto-low.c (struct nto_target_ops): Likewise.
5988 * spu-low.c (struct spu_target_ops): Likewise.
5989 * win32-low.c (struct win32_target_ops): Likewise.
5991 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
5993 * linux-arm-low.c: Remove duplicate arch/arm.h include.
5995 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
5997 * linux-arm-low.c (arm_reinsert_addr): Remove function.
5998 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
5999 * linux-cris-low.c (cris_reinsert_addr> Remove function.
6000 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6001 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
6002 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6003 * linux-mips-low.c (mips_reinsert_addr): Remove function.
6004 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6005 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
6006 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6007 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
6008 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6010 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6012 * linux-low.c (linux_look_up_symbols): Don't call
6013 linux_supports_traceclone.
6014 * linux-low.h (thread_db_init): Remove use_events argument.
6015 * thread-db.c (thread_db_use_event): Remove global variable.
6016 (struct thread_db) <td_thr_event_enable_p>: Remove field.
6017 (struct thread_db) <td_create_bp>: Remove field.
6018 (thread_db_create_event): Remove function.
6019 (thread_db_enable_reporting): Likewise.
6020 (find_one_thread): Don't check for thread_db_use_events.
6021 (attach_thread): Likewise.
6022 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
6023 (try_thread_db_load_1): Don't check for thread_db_use_events.
6024 (thread_db_init): Remove use_events argument and thread events
6026 (remove_thread_event_breakpoints): Remove function.
6027 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
6029 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6031 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
6033 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6034 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
6035 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6036 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
6037 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
6039 * linux-crisv32-low.c (cris_supports_hardware_single_step):
6041 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6042 * linux-low.c (can_hardware_single_step): Use
6043 supports_hardware_single_step.
6044 (can_software_single_step): New function.
6045 (start_step_over): Call can_software_single_step.
6046 (linux_supports_hardware_single_step): New function.
6047 (struct target_ops) <supports_software_single_step>: Initialize.
6048 * linux-low.h (struct linux_target_ops)
6049 <supports_hardware_single_step>: Initialize.
6050 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
6051 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6052 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
6053 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
6054 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
6055 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6056 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
6057 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6058 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
6059 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
6061 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
6062 (struct linux_target_ops) <tile_supports_hardware_single_step>:
6064 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
6065 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6066 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
6068 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6069 * target.h (struct target_ops): <supports_software_single_step>:
6071 (target_supports_software_single_step): New macro.
6073 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6075 * linux-low.c (linux_wait_1): Fix pc advance condition.
6076 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
6077 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
6079 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6081 * linux-arm-low.c (arm_is_thumb_mode): New function.
6082 (arm_breakpoint_at): Use arm_is_thumb_mode.
6083 (arm_breakpoint_kind_from_current_state): New function.
6084 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
6086 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
6087 (linux_breakpoint_kind_from_current_state): New function.
6088 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
6089 * linux-low.h (struct linux_target_ops)
6090 <breakpoint_kind_from_current_state>: New field.
6091 * target.h (struct target_ops): Likewise.
6092 (target_breakpoint_kind_from_current_state): New macro.
6094 2015-11-30 Pedro Alves <palves@redhat.com>
6096 * linux-low.c (linux_resume): Wake up the event loop before
6099 2015-11-30 Pedro Alves <palves@redhat.com>
6101 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
6103 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
6105 * target.c (struct thread_search): New structure.
6106 (thread_search_callback): New function.
6107 (prev_general_thread): New global.
6108 (prepare_to_access_memory, done_accessing_memory): New functions.
6109 * target.h (prepare_to_access_memory, done_accessing_memory):
6110 Replace macros with function declarations.
6112 2015-11-30 Pedro Alves <palves@redhat.com>
6115 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
6116 report TARGET_WAITKIND_NO_RESUMED.
6117 * remote-utils.c (prepare_resume_reply): Handle
6118 TARGET_WAITKIND_NO_RESUMED.
6119 * server.c (report_no_resumed): New global.
6120 (handle_query) <qSupported>: Handle "no-resumed+". Report
6121 "no-resumed+" support.
6122 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
6123 return error if the client doesn't support no-resumed events.
6124 (push_stop_notification): New function.
6125 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
6126 events if the client supports them.
6128 2015-11-30 Pedro Alves <palves@redhat.com>
6130 * linux-low.c (thread_still_has_status_pending_p): Don't check
6132 (lwp_resumed): New function.
6133 (status_pending_p_callback): Return early if the LWP is not
6134 supposed to be resumed.
6136 2015-11-30 Pedro Alves <palves@redhat.com>
6138 * linux-low.c (handle_extended_wait): Assert that the LWP's
6139 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
6140 thread create events, leave the new child's status pending.
6141 (linux_low_filter_event): If GDB wants to hear about thread exit
6142 events, leave the LWP marked dead and don't delete it.
6143 (linux_wait_for_event_filtered): Don't check for thread exit.
6144 (filter_exit_event): New function.
6145 (linux_wait_1): Use it, when returning an exit event.
6146 (linux_resume_one_lwp_throw): Assert that the LWP's
6147 waitstatus is TARGET_WAITKIND_IGNORE.
6148 * remote-utils.c (prepare_resume_reply): Handle
6149 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
6150 * server.c (report_thread_events): New global.
6151 (handle_general_set): Handle QThreadEvents.
6152 (handle_query) <qSupported>: Handle and report QThreadEvents+;
6153 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
6154 TARGET_WAITKIND_THREAD_EXITED.
6155 * server.h (report_thread_events): Declare.
6157 2015-11-30 Pedro Alves <palves@redhat.com>
6159 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
6160 the thread's last_resume_kind was resume_stop.
6162 2015-11-30 Pedro Alves <palves@redhat.com>
6164 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
6167 2015-11-30 Pedro Alves <palves@redhat.com>
6169 * server.c (handle_v_requests): Handle vCtrlC.
6171 2015-11-30 Pedro Alves <palves@redhat.com>
6173 * gdbthread.h (find_any_thread_of_pid): Declare.
6174 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
6176 * server.c (handle_query): If current_thread is NULL, look for
6177 another thread of the selected process.
6179 2015-11-26 Daniel Colascione <dancol@dancol.org>
6180 Simon Marchi <simon.marchi@ericsson.com>
6182 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
6183 * server.c (handle_qxfer_threads_worker): Refactor to include thread
6185 * target.h (struct target_ops) <thread_name>: New field.
6186 (target_thread_name): New macro.
6188 2015-11-23 Joel Brobecker <brobecker@adacore.com>
6190 * regcache.h (regcache_invalidate_pid): Add declaration.
6191 * regcache.c (regcache_invalidate_pid): New function, extracted
6192 from regcache_invalidate.
6193 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
6194 Add trivial documentation comment.
6195 * lynx-low.c: Use regcache_invalidate_pid instead of
6196 regcache_invalidate.
6198 2015-11-23 Joel Brobecker <brobecker@adacore.com>
6200 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
6201 and Elf64_auxv_t if the target is Android.
6203 2015-11-22 Doug Evans <xdje42@gmail.com>
6205 * target.h: #include <sys/types.h>.
6207 2015-11-19 Pedro Alves <palves@redhat.com>
6209 * linux-low.c (linux_process_qsupported): Change prototype.
6211 * linux-low.h (struct linux_target_ops) <process_qsupported>:
6213 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
6214 and adjust to loop over all features.
6215 * server.c (handle_query) <qSupported>: Adjust to call
6216 target_process_qsupported once, passing it a vector of unprocessed
6218 * target.h (struct target_ops) <process_qsupported>: Change
6220 (target_process_qsupported): Adjust.
6222 2015-11-19 Pedro Alves <palves@redhat.com>
6224 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
6226 * configure: Regenerate.
6228 2015-11-19 Pedro Alves <palves@redhat.com>
6230 * configure: Regenerate.
6232 2015-11-19 Yao Qi <yao.qi@linaro.org>
6234 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
6237 2015-11-19 Yao Qi <yao.qi@linaro.org>
6239 * linux-aarch64-low.c (enum aarch64_operand_type): New.
6240 (struct aarch64_operand): Move enum out.
6242 2015-11-19 Yao Qi <yao.qi@linaro.org>
6244 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
6245 struct user_fpsimd_state *.
6246 (aarch64_store_fpregset): Likewise.
6248 2015-11-19 Yao Qi <yao.qi@linaro.org>
6250 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
6251 struct user_pt_regs *.
6252 (aarch64_store_gregset): Likewise.
6254 2015-11-18 Pedro Alves <palves@redhat.com>
6256 * Makefile.in (all_object_files): Add $IPA_OBJS.
6258 2015-11-17 Pedro Alves <palves@redhat.com>
6260 * win32-low.c (win32_resume): Use gdb_signal_from_host,
6261 GDB_SIGNAL_0 and gdb_signal_to_string.
6263 2015-11-17 Pedro Alves <palves@redhat.com>
6265 * win32-low.c (handle_output_debug_string): Remove parameter.
6266 (win32_kill): Remove our_status local and adjust call to
6267 handle_output_debug_string.
6268 (get_child_debug_event): Adjust call to
6269 handle_output_debug_string.
6271 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6273 * linux-mips-low.c (mips_fill_gregset): Add cast.
6274 (mips_store_gregset): Likewise.
6275 (mips_fill_fpregset): Likewise.
6276 (mips_store_fpregset): Likewise.
6278 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6280 * linux-mips-low.c (mips_add_watchpoint): Rename private to
6283 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6285 * linux-mips-low.c (mips_linux_new_thread): Change type of
6286 watch_type to enum target_hw_bp_type.
6288 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6290 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
6291 Change return type to arm_hwbp_type.
6293 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6295 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
6296 (arm_store_gregset): Likewise.
6297 * linux-arm-low.c (arm_get_hwcap): Likewise.
6298 (arm_read_description): Likewise.
6300 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6302 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
6304 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6306 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
6307 (ppc_fill_vsxregset): Likewise.
6308 (ppc_store_vsxregset): Likewise.
6309 (ppc_fill_vrregset): Likewise.
6310 (ppc_store_vrregset): Likewise.
6311 (ppc_fill_evrregset): Likewise.
6312 (ppc_store_evrregset): Likewise.
6314 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6316 * linux-ppc-low.c (ppc_usrregs_info): Remove
6317 forward-declaration.
6318 (ppc_arch_setup): Move lower in file.
6320 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
6322 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
6323 (ps_pdwrite): Likewise.
6325 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
6327 * linux-arm-low.c (arm_new_thread): Move pointer dereference
6328 to after assert checks.
6330 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
6332 * proc-service.c (ps_pdread): Add/adjust casts.
6333 (ps_pdwrite): Add/adjust casts.
6335 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
6337 * server.c (handle_search_memory_1): Cast return value of
6340 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
6342 * server.c (write_qxfer_response): Change type of data to
6345 2015-10-29 Pedro Alves <palves@redhat.com>
6347 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
6349 2015-10-29 Pedro Alves <palves@redhat.com>
6351 * tracepoint.c (clear_installed_tracepoints): Add casts.
6353 2015-10-29 Pedro Alves <palves@redhat.com>
6355 * server.c (handle_v_cont, process_serial_event): Add enum
6356 gdb_signal casts to signal parsing code.
6358 2015-10-29 Pedro Alves <palves@redhat.com>
6360 * linux-low.h (NULL_REGSET): Define.
6361 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
6362 * linux-arm-low.c (arm_regsets): Likewise.
6363 * linux-crisv32-low.c (cris_regsets): Likewise.
6364 * linux-m68k-low.c (m68k_regsets): Likewise.
6365 * linux-mips-low.c (mips_regsets): Likewise.
6366 * linux-nios2-low.c (nios2_regsets): Likewise.
6367 * linux-ppc-low.c (ppc_regsets): Likewise.
6368 * linux-s390-low.c (s390_regsets): Likewise.
6369 * linux-sh-low.c (sh_regsets): Likewise.
6370 * linux-sparc-low.c (sparc_regsets): Likewise.
6371 * linux-tic6x-low.c (tic6x_regsets): Likewise.
6372 * linux-tile-low.c (tile_regsets): Likewise.
6373 * linux-x86-low.c (x86_regsets): Likewise.
6374 * linux-xtensa-low.c (xtensa_regsets): Likewise.
6376 2015-10-29 Pedro Alves <palves@redhat.com>
6378 * linux-low.h (NULL_REGSET): Define.
6379 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
6380 * linux-arm-low.c (arm_regsets): Likewise.
6381 * linux-crisv32-low.c (cris_regsets): Likewise.
6382 * linux-m68k-low.c (m68k_regsets): Likewise.
6383 * linux-mips-low.c (mips_regsets): Likewise.
6384 * linux-nios2-low.c (nios2_regsets): Likewise.
6385 * linux-ppc-low.c (ppc_regsets): Likewise.
6386 * linux-s390-low.c (s390_regsets): Likewise.
6387 * linux-sh-low.c (sh_regsets): Likewise.
6388 * linux-sparc-low.c (sparc_regsets): Likewise.
6389 * linux-tic6x-low.c (tic6x_regsets): Likewise.
6390 * linux-tile-low.c (tile_regsets): Likewise.
6391 * linux-x86-low.c (x86_regsets): Likewise.
6392 * linux-xtensa-low.c (xtensa_regsets): Likewise.
6394 2015-10-26 Doug Evans <dje@google.com>
6396 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
6398 2015-10-26 Doug Evans <dje@google.com>
6400 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
6402 2015-10-26 Doug Evans <dje@google.com>
6404 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
6406 (attach_thread, find_new_threads_callback): Ditto.
6408 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
6410 * mem-break.h (set_breakpoint_data): Remove.
6412 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
6414 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
6415 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
6416 (initialize_low): Remove set_breakpoint_data call.
6417 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
6418 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
6419 (initialize_low): Remove set_breakpoint_data call.
6420 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
6421 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
6422 (initialize_low): Remove set_breakpoint_data call.
6424 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
6426 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
6427 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
6428 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
6429 * target.h (target_breakpoint_kind_from_pc): New macro.
6431 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
6433 * linux-low.c (default_breakpoint_kind_from_pc): New function.
6434 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
6435 the default breakpoint kind.
6437 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6439 * linux-arm-low.c (arm_supports_z_point_type): Add software
6442 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6444 * linux-arm-low.c: Refactor breakpoint definitions.
6445 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
6446 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
6448 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6450 * Makefile.in: Add arm.c/o.
6451 * configure.srv: Likewise.
6452 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
6453 (arm_breakpoint_kind_from_pc): New function.
6454 (arm_sw_breakpoint_from_kind): Return proper kind.
6455 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
6457 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6459 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
6461 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
6462 (struct raw_breakpoint) <size>: Remove.
6463 (struct raw_breakpoint) <kind>: Add.
6464 (bp_size): New function.
6465 (bp_opcode): Likewise.
6466 (find_raw_breakpoint_at): Adjust for kind.
6467 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
6468 (remove_memory_breakpoint): Adjust for kind call bp_size.
6469 (set_raw_breakpoint_at): Adjust for kind.
6470 (set_breakpoint): Likewise.
6471 (set_breakpoint_at): Call breakpoint_kind_from_pc.
6472 (delete_raw_breakpoint): Adjust for kind.
6473 (delete_breakpoint): Likewise.
6474 (find_gdb_breakpoint): Likewise.
6475 (set_gdb_breakpoint_1): Likewise.
6476 (set_gdb_breakpoint): Likewise.
6477 (delete_gdb_breakpoint_1): Likewise.
6478 (delete_gdb_breakpoint): Likewise.
6479 (uninsert_raw_breakpoint): Likewise.
6480 (reinsert_raw_breakpoint): Likewise.
6481 (set_breakpoint_data): Remove.
6482 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
6483 (check_mem_read): Adjust for kind call bp_size.
6484 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
6485 (clone_one_breakpoint): Adjust for kind.
6486 * mem-break.h (set_gdb_breakpoint): Likewise.
6487 (delete_gdb_breakpoint): Likewise.
6488 * server.c (process_serial_event): Likewise.
6490 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6492 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
6493 (struct linux_target_ops) <breakpoint>: Remove.
6494 (struct linux_target_ops) <breakpoint_len>: Remove.
6495 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6496 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6497 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
6498 (arm_sw_breakpoint_from_kind): New function.
6499 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
6500 (struct linux_target_ops) <breakpoint>: Remove.
6501 (struct linux_target_ops) <breakpoint_len>: Remove.
6502 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6503 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6504 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
6505 (struct linux_target_ops) <breakpoint>: Remove.
6506 (struct linux_target_ops) <breakpoint_len>: Remove.
6507 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6508 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6509 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
6510 (struct linux_target_ops) <breakpoint>: Remove.
6511 (struct linux_target_ops) <breakpoint_len>: Remove.
6512 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6513 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6514 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
6515 and sw_breakpoint_from_kind to increment the pc.
6516 (linux_breakpoint_kind_from_pc): New function.
6517 (linux_sw_breakpoint_from_kind): New function.
6518 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
6519 (initialize_low): Call breakpoint_kind_from_pc and
6520 sw_breakpoint_from_kind to replace breakpoint_data/len.
6521 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
6523 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
6524 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
6525 (struct linux_target_ops) <breakpoint>: Remove.
6526 (struct linux_target_ops) <breakpoint_len>: Remove.
6527 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6528 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6529 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
6530 (struct linux_target_ops) <breakpoint>: Remove.
6531 (struct linux_target_ops) <breakpoint_len>: Remove.
6532 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6533 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6534 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
6535 (struct linux_target_ops) <breakpoint>: Remove.
6536 (struct linux_target_ops) <breakpoint_len>: Remove.
6537 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6538 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6539 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
6540 (struct linux_target_ops) <breakpoint>: Remove.
6541 (struct linux_target_ops) <breakpoint_len>: Remove.
6542 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6543 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6544 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
6545 (struct linux_target_ops) <breakpoint>: Remove.
6546 (struct linux_target_ops) <breakpoint_len>: Remove.
6547 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6548 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6549 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
6550 (struct linux_target_ops) <breakpoint>: Remove.
6551 (struct linux_target_ops) <breakpoint_len>: Remove.
6552 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6553 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6554 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
6555 (struct linux_target_ops) <breakpoint>: Remove.
6556 (struct linux_target_ops) <breakpoint_len>: Remove.
6557 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6558 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6559 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
6560 (struct linux_target_ops) <breakpoint>: Remove.
6561 (struct linux_target_ops) <breakpoint_len>: Remove.
6562 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6563 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6564 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
6565 (struct linux_target_ops) <breakpoint>: Remove.
6566 (struct linux_target_ops) <breakpoint_len>: Remove.
6567 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6568 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6569 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
6570 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
6571 (struct linux_target_ops) <breakpoint>: Remove.
6572 (struct linux_target_ops) <breakpoint_len>: Remove.
6573 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6574 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6575 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
6576 (struct linux_target_ops) <breakpoint>: Remove.
6577 (struct linux_target_ops) <breakpoint_len>: Remove.
6578 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6579 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6581 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6583 * linux-cris-low.c (cris_get_pc): Remove void arg.
6585 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
6587 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
6590 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
6592 * inferiors.c (thread_pid_matches_callback): New function.
6593 (find_thread_process): New function.
6594 (remove_thread): Reset current_thread.
6595 (remove_process): Assert threads have been removed first.
6597 2015-10-15 Yao Qi <yao.qi@linaro.org>
6599 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
6601 (aarch64_remove_point): Likewise.
6602 * regcache.c (regcache_register_size): New function.
6604 2015-10-12 Yao Qi <yao.qi@linaro.org>
6606 * linux-aarch64-low.c: Update all callers as emit_load_store
6607 is renamed to aarch64_emit_load_store.
6609 2015-10-12 Yao Qi <yao.qi@linaro.org>
6611 * linux-aarch64-low.c: Update all callers of function renaming
6612 from emit_insn to aarch64_emit_insn.
6614 2015-10-12 Yao Qi <yao.qi@linaro.org>
6616 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
6617 arch/aarch64-insn.h.
6618 (struct aarch64_memory_operand): Likewise.
6620 (emit_insn): Move to arch/aarch64-insn.c.
6621 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
6622 (emit_load_store): Move to arch/aarch64-insn.c.
6623 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
6624 (can_encode_int32): Remove.
6626 2015-10-12 Yao Qi <yao.qi@linaro.org>
6628 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
6629 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
6630 (aarch64_relocate_instruction): Likewise.
6631 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
6632 (struct aarch64_insn_visitor): Likewise.
6634 2015-10-12 Yao Qi <yao.qi@linaro.org>
6636 * linux-aarch64-low.c (struct aarch64_insn_data): New.
6637 (struct aarch64_insn_visitor): New.
6638 (struct aarch64_insn_relocation_data): New.
6639 (aarch64_ftrace_insn_reloc_b): New function.
6640 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
6641 (aarch64_ftrace_insn_reloc_cb): Likewise.
6642 (aarch64_ftrace_insn_reloc_tb): Likewise.
6643 (aarch64_ftrace_insn_reloc_adr): Likewise.
6644 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
6645 (aarch64_ftrace_insn_reloc_others): Likewise.
6647 (aarch64_relocate_instruction): Use visitor.
6649 2015-10-12 Yao Qi <yao.qi@linaro.org>
6651 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
6652 int. Add argument buf.
6653 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
6654 aarch64_relocate_instruction.
6656 2015-10-12 Yao Qi <yao.qi@linaro.org>
6658 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
6659 argument insn. Remove local variable insn. Don't call
6661 (aarch64_install_fast_tracepoint_jump_pad): Call
6664 2015-09-30 Yao Qi <yao.qi@linaro.org>
6666 * linux-aarch64-low.c (emit_movk): Shorten a long line.
6667 (emit_load_store_pair): Likewise.
6669 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
6671 * dll.c (match_dll): Add cast(s).
6672 (unloaded_dll): Likewise.
6673 * linux-low.c (second_thread_of_pid_p): Likewise.
6674 (delete_lwp_callback): Likewise.
6675 (count_events_callback): Likewise.
6676 (select_event_lwp_callback): Likewise.
6677 (linux_set_resume_request): Likewise.
6678 * server.c (accumulate_file_name_length): Likewise.
6679 (emit_dll_description): Likewise.
6680 (handle_qxfer_threads_worker): Likewise.
6681 (visit_actioned_threads): Likewise.
6682 * thread-db.c (any_thread_of): Likewise.
6683 * tracepoint.c (same_process_p): Likewise.
6684 (match_blocktype): Likewise.
6685 (build_traceframe_info_xml): Likewise.
6687 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
6689 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
6691 (gdb_unparse_agent_expr): Likewise.
6692 * hostio.c (require_data): Likewise.
6693 (handle_pread): Likewise.
6694 * linux-low.c (disable_regset): Likewise.
6695 (fetch_register): Likewise.
6696 (store_register): Likewise.
6697 (get_dynamic): Likewise.
6698 (linux_qxfer_libraries_svr4): Likewise.
6699 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
6700 (set_fast_tracepoint_jump): Likewise.
6701 (uninsert_fast_tracepoint_jumps_at): Likewise.
6702 (reinsert_fast_tracepoint_jumps_at): Likewise.
6703 (validate_inserted_breakpoint): Likewise.
6704 (clone_agent_expr): Likewise.
6705 * regcache.c (init_register_cache): Likewise.
6706 * remote-utils.c (putpkt_binary_1): Likewise.
6707 (decode_M_packet): Likewise.
6708 (decode_X_packet): Likewise.
6709 (look_up_one_symbol): Likewise.
6710 (relocate_instruction): Likewise.
6711 (monitor_output): Likewise.
6712 * server.c (handle_search_memory): Likewise.
6713 (handle_qxfer_exec_file): Likewise.
6714 (handle_qxfer_libraries): Likewise.
6715 (handle_qxfer): Likewise.
6716 (handle_query): Likewise.
6717 (handle_v_cont): Likewise.
6718 (handle_v_run): Likewise.
6719 (captured_main): Likewise.
6720 * target.c (write_inferior_memory): Likewise.
6721 * thread-db.c (try_thread_db_load_from_dir): Likewise.
6722 * tracepoint.c (init_trace_buffer): Likewise.
6723 (add_tracepoint_action): Likewise.
6724 (add_traceframe): Likewise.
6725 (add_traceframe_block): Likewise.
6726 (cmd_qtdpsrc): Likewise.
6727 (cmd_qtdv): Likewise.
6728 (cmd_qtstatus): Likewise.
6729 (response_source): Likewise.
6730 (response_tsv): Likewise.
6731 (cmd_qtnotes): Likewise.
6732 (gdb_collect): Likewise.
6733 (initialize_tracepoint): Likewise.
6735 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
6737 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
6738 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
6739 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
6741 (enum aarch64_condition_codes): New enum.
6742 (w0): New static global.
6745 (struct aarch64_memory_operand) <type>: New
6746 MEMORY_OPERAND_POSTINDEX type.
6747 (postindex_memory_operand): New helper function.
6748 (emit_ret): New function.
6749 (emit_load_store_pair): New function, factored out of emit_stp
6750 with support for MEMORY_OPERAND_POSTINDEX.
6751 (emit_stp): Rewrite using emit_load_store_pair.
6752 (emit_ldp): New function.
6753 (emit_load_store): Likewise.
6754 (emit_ldr): Mention post-index instruction in comment.
6755 (emit_ldrh): New function.
6756 (emit_ldrb): New function.
6757 (emit_ldrsw): Mention post-index instruction in comment.
6758 (emit_str): Likewise.
6759 (emit_subs): New function.
6760 (emit_cmp): Likewise.
6761 (emit_and): Likewise.
6762 (emit_orr): Likewise.
6763 (emit_orn): Likewise.
6764 (emit_eor): Likewise.
6765 (emit_mvn): Likewise.
6766 (emit_lslv): Likewise.
6767 (emit_lsrv): Likewise.
6768 (emit_asrv): Likewise.
6769 (emit_mul): Likewise.
6770 (emit_sbfm): Likewise.
6771 (emit_sbfx): Likewise.
6772 (emit_ubfm): Likewise.
6773 (emit_ubfx): Likewise.
6774 (emit_csinc): Likewise.
6775 (emit_cset): Likewise.
6776 (emit_nop): Likewise.
6777 (emit_ops_insns): New helper function.
6778 (emit_pop): Likewise.
6779 (emit_push): Likewise.
6780 (aarch64_emit_prologue): New function.
6781 (aarch64_emit_epilogue): Likewise.
6782 (aarch64_emit_add): Likewise.
6783 (aarch64_emit_sub): Likewise.
6784 (aarch64_emit_mul): Likewise.
6785 (aarch64_emit_lsh): Likewise.
6786 (aarch64_emit_rsh_signed): Likewise.
6787 (aarch64_emit_rsh_unsigned): Likewise.
6788 (aarch64_emit_ext): Likewise.
6789 (aarch64_emit_log_not): Likewise.
6790 (aarch64_emit_bit_and): Likewise.
6791 (aarch64_emit_bit_or): Likewise.
6792 (aarch64_emit_bit_xor): Likewise.
6793 (aarch64_emit_bit_not): Likewise.
6794 (aarch64_emit_equal): Likewise.
6795 (aarch64_emit_less_signed): Likewise.
6796 (aarch64_emit_less_unsigned): Likewise.
6797 (aarch64_emit_ref): Likewise.
6798 (aarch64_emit_if_goto): Likewise.
6799 (aarch64_emit_goto): Likewise.
6800 (aarch64_write_goto_address): Likewise.
6801 (aarch64_emit_const): Likewise.
6802 (aarch64_emit_call): Likewise.
6803 (aarch64_emit_reg): Likewise.
6804 (aarch64_emit_pop): Likewise.
6805 (aarch64_emit_stack_flush): Likewise.
6806 (aarch64_emit_zero_ext): Likewise.
6807 (aarch64_emit_swap): Likewise.
6808 (aarch64_emit_stack_adjust): Likewise.
6809 (aarch64_emit_int_call_1): Likewise.
6810 (aarch64_emit_void_call_2): Likewise.
6811 (aarch64_emit_eq_goto): Likewise.
6812 (aarch64_emit_ne_goto): Likewise.
6813 (aarch64_emit_lt_goto): Likewise.
6814 (aarch64_emit_le_goto): Likewise.
6815 (aarch64_emit_gt_goto): Likewise.
6816 (aarch64_emit_ge_got): Likewise.
6817 (aarch64_emit_ops_impl): New static global variable.
6818 (aarch64_emit_ops): New target function, return
6819 &aarch64_emit_ops_impl.
6820 (struct linux_target_ops): Install it.
6822 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
6824 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
6825 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
6827 * linux-aarch64-ipa.c: New file.
6828 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
6830 (aarch64_get_thread_area): New target method.
6831 (extract_signed_bitfield): New helper function.
6832 (aarch64_decode_ldr_literal): New function.
6833 (enum aarch64_opcodes): New enum.
6834 (struct aarch64_register): New struct.
6835 (struct aarch64_operand): New struct.
6836 (x0): New static global.
6845 (aarch64_register): New helper function.
6846 (register_operand): Likewise.
6847 (immediate_operand): Likewise.
6848 (struct aarch64_memory_operand): New struct.
6849 (offset_memory_operand): New helper function.
6850 (preindex_memory_operand): Likewise.
6851 (enum aarch64_system_control_registers): New enum.
6852 (ENCODE): New macro.
6853 (emit_insn): New helper function.
6854 (emit_b): New function.
6855 (emit_bcond): Likewise.
6856 (emit_cb): Likewise.
6857 (emit_tb): Likewise.
6858 (emit_blr): Likewise.
6859 (emit_stp): Likewise.
6860 (emit_ldp_q_offset): Likewise.
6861 (emit_stp_q_offset): Likewise.
6862 (emit_load_store): Likewise.
6863 (emit_ldr): Likewise.
6864 (emit_ldrsw): Likewise.
6865 (emit_str): Likewise.
6866 (emit_ldaxr): Likewise.
6867 (emit_stxr): Likewise.
6868 (emit_stlr): Likewise.
6869 (emit_data_processing_reg): Likewise.
6870 (emit_data_processing): Likewise.
6871 (emit_add): Likewise.
6872 (emit_sub): Likewise.
6873 (emit_mov): Likewise.
6874 (emit_movk): Likewise.
6875 (emit_mov_addr): Likewise.
6876 (emit_mrs): Likewise.
6877 (emit_msr): Likewise.
6878 (emit_sevl): Likewise.
6879 (emit_wfe): Likewise.
6880 (append_insns): Likewise.
6881 (can_encode_int32_in): New helper function.
6882 (aarch64_relocate_instruction): New function.
6883 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
6884 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
6885 (struct linux_target_ops): Install aarch64_get_thread_area,
6886 aarch64_install_fast_tracepoint_jump_pad and
6887 aarch64_get_min_fast_tracepoint_insn_len.
6889 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
6891 * Makefile.in (aarch64-insn.o): New rule.
6892 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
6894 2015-09-21 Yao Qi <yao.qi@linaro.org>
6896 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
6898 2015-09-21 Yao Qi <yao.qi@linaro.org>
6900 * tracepoint.c (max_jump_pad_size): Remove.
6902 2015-09-18 Yao Qi <yao.qi@linaro.org>
6904 * linux-aarch64-low.c: Don't include sys/uio.h.
6905 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
6907 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
6909 * tracepoint.c (eval_result_type): Change prototype.
6910 (condition_true_at_tracepoint): Fix argument to compiled_cond.
6912 2015-09-15 Pedro Alves <palves@redhat.com>
6914 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
6915 Check whether to report exec events instead of checking whether
6916 multiprocess is enabled.
6918 2015-09-15 Pedro Alves <palves@redhat.com>
6921 * remote-utils.c (prepare_resume_reply): Merge
6922 TARGET_WAITKIND_VFORK_DONE switch case with the
6923 TARGET_WAITKIND_FORKED case.
6925 2015-09-15 Yao Qi <yao.qi@linaro.org>
6927 * server.c (handle_query): Check string comparison using
6928 "else if" instead of "if".
6930 2015-09-15 Yao Qi <yao.qi@linaro.org>
6932 * server.c (vCont_supported): New global variable.
6933 (handle_query): Set vCont_supported to 1 if "vContSupported+"
6934 matches. Append ";vContSupported+" to own_buf.
6935 (handle_v_requests): Append ";s;S" to own_buf if target supports
6936 hardware single step or vCont_supported is false.
6937 (capture_main): Set vCont_supported to zero.
6939 2015-09-15 Yao Qi <yao.qi@linaro.org>
6941 * linux-low.c (linux_supports_conditional_breakpoints): Rename
6943 (linux_supports_hardware_single_step): ... New function.
6944 (linux_target_ops): Update.
6945 * lynx-low.c (lynx_target_ops): Set field
6946 supports_hardware_single_step to target_can_do_hardware_single_step.
6947 * nto-low.c (nto_target_ops): Likewise.
6948 * spu-low.c (spu_target_ops): Likewise.
6949 * win32-low.c (win32_target_ops): Likewise.
6950 * target.c (target_can_do_hardware_single_step): New function.
6951 * target.h (struct target_ops) <supports_conditional_breakpoints>:
6952 Remove. <supports_hardware_single_step>: New field.
6953 (target_supports_conditional_breakpoints): Remove.
6954 (target_supports_hardware_single_step): New macro.
6955 (target_can_do_hardware_single_step): Declare.
6956 * server.c (handle_query): Use target_supports_hardware_single_step
6957 instead of target_supports_conditional_breakpoints.
6959 2015-09-15 Yao Qi <yao.qi@linaro.org>
6961 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
6963 (struct linux_target_ops the_low_target): Install
6964 aarch64_linux_siginfo_fixup.
6966 2015-09-11 Don Breazeal <donb@codesourcery.com>
6967 Luis Machado <lgustavo@codesourcery.com>
6969 * linux-low.c (linux_mourn): Static declaration.
6970 (linux_arch_setup): Move in front of
6971 handle_extended_wait.
6972 (linux_arch_setup_thread): New function.
6973 (handle_extended_wait): Handle exec events. Call
6974 linux_arch_setup_thread. Make event_lwp argument a
6975 pointer-to-a-pointer.
6976 (check_zombie_leaders): Do not check stopped threads.
6977 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
6978 (linux_low_filter_event): Add lwp and thread for exec'ing
6979 non-leader thread if leader thread has been deleted.
6980 Refactor code into linux_arch_setup_thread and call it.
6981 Pass child lwp pointer by reference to handle_extended_wait.
6982 (linux_wait_for_event_filtered): Update comment.
6983 (linux_wait_1): Prevent clobbering exec event status.
6984 (linux_supports_exec_events): New function.
6985 (linux_target_ops) <supports_exec_events>: Initialize new member.
6986 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
6988 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
6989 * server.c (report_exec_events): New global variable.
6990 (handle_query): Handle qSupported query for exec-events feature.
6991 (captured_main): Initialize report_exec_events.
6992 * server.h (report_exec_events): Declare new global variable.
6993 * target.h (struct target_ops) <supports_exec_events>: New
6995 (target_supports_exec_events): New macro.
6996 * win32-low.c (win32_target_ops) <supports_exec_events>:
6997 Initialize new member.
6999 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
7001 * linux-low.c (linux_low_enable_btrace): Remove.
7002 (linux_target_ops): Replace linux_low_enable_btrace with
7003 linux_enable_btrace.
7005 2015-09-03 Yao Qi <yao.qi@linaro.org>
7007 * linux-aarch64-low.c (aarch64_insert_point): Call
7008 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
7011 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
7013 * linux-low.c (check_stopped_by_breakpoint): Use
7014 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
7016 2015-08-27 Pedro Alves <palves@redhat.com>
7018 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
7020 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
7022 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
7023 the XNEW-family equivalent.
7024 (compile_bytecodes): Likewise.
7025 * dll.c (loaded_dll): Likewise.
7026 * event-loop.c (append_callback_event): Likewise.
7027 (create_file_handler): Likewise.
7028 (create_file_event): Likewise.
7029 * hostio.c (handle_open): Likewise.
7030 * inferiors.c (add_thread): Likewise.
7031 (add_process): Likewise.
7032 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
7033 * linux-arm-low.c (arm_new_process): Likewise.
7034 (arm_new_thread): Likewise.
7035 * linux-low.c (add_to_pid_list): Likewise.
7036 (linux_add_process): Likewise.
7037 (handle_extended_wait): Likewise.
7038 (add_lwp): Likewise.
7039 (enqueue_one_deferred_signal): Likewise.
7040 (enqueue_pending_signal): Likewise.
7041 (linux_resume_one_lwp_throw): Likewise.
7042 (linux_resume_one_thread): Likewise.
7043 (linux_read_memory): Likewise.
7044 (linux_write_memory): Likewise.
7045 * linux-mips-low.c (mips_linux_new_process): Likewise.
7046 (mips_linux_new_thread): Likewise.
7047 (mips_add_watchpoint): Likewise.
7048 * linux-x86-low.c (initialize_low_arch): Likewise.
7049 * lynx-low.c (lynx_add_process): Likewise.
7050 * mem-break.c (set_raw_breakpoint_at): Likewise.
7051 (set_breakpoint): Likewise.
7052 (add_condition_to_breakpoint): Likewise.
7053 (add_commands_to_breakpoint): Likewise.
7054 (clone_agent_expr): Likewise.
7055 (clone_one_breakpoint): Likewise.
7056 * regcache.c (new_register_cache): Likewise.
7057 * remote-utils.c (look_up_one_symbol): Likewise.
7058 * server.c (queue_stop_reply): Likewise.
7059 (start_inferior): Likewise.
7060 (queue_stop_reply_callback): Likewise.
7061 (handle_target_event): Likewise.
7062 * spu-low.c (fetch_ppc_memory): Likewise.
7063 (store_ppc_memory): Likewise.
7064 * target.c (set_target_ops): Likewise.
7065 * thread-db.c (thread_db_load_search): Likewise.
7066 (try_thread_db_load_1): Likewise.
7067 * tracepoint.c (add_tracepoint): Likewise.
7068 (add_tracepoint_action): Likewise.
7069 (create_trace_state_variable): Likewise.
7070 (cmd_qtdpsrc): Likewise.
7071 (cmd_qtro): Likewise.
7072 (add_while_stepping_state): Likewise.
7073 * win32-low.c (child_add_thread): Likewise.
7074 (get_image_name): Likewise.
7076 2015-08-25 Yao Qi <yao.qi@linaro.org>
7078 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
7080 2015-08-25 Yao Qi <yao.qi@linaro.org>
7082 * Makefile.in (aarch64-linux.o): New rule.
7083 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
7085 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
7086 (aarch64_init_debug_reg_state): Make it extern.
7087 (aarch64_linux_prepare_to_resume): Remove.
7089 2015-08-25 Yao Qi <yao.qi@linaro.org>
7091 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
7092 lwp_arch_private_info and ptid_of_lwp.
7094 2015-08-25 Yao Qi <yao.qi@linaro.org>
7096 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
7097 Find proc_info by find_process_pid. All callers updated.
7099 2015-08-25 Yao Qi <yao.qi@linaro.org>
7101 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
7103 (debug_reg_change_callback): Remove.
7104 (aarch64_notify_debug_reg_change): Remove.
7106 2015-08-25 Yao Qi <yao.qi@linaro.org>
7108 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
7109 Call current_lwp_ptid.
7111 2015-08-25 Yao Qi <yao.qi@linaro.org>
7113 * linux-aarch64-low.c (debug_reg_change_callback): Use
7116 2015-08-25 Yao Qi <yao.qi@linaro.org>
7118 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
7120 2015-08-25 Yao Qi <yao.qi@linaro.org>
7122 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
7124 2015-08-25 Yao Qi <yao.qi@linaro.org>
7126 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
7129 2015-08-25 Yao Qi <yao.qi@linaro.org>
7131 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
7133 (debug_reg_change_callback): Remove argument entry and add argument
7134 lwp. Remove local variable thread. Don't print thread id in the
7135 debugging output. Don't check whether pid of thread equals to pid.
7136 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
7137 iterate_over_lwps instead find_inferior.
7139 2015-08-24 Pedro Alves <palves@redhat.com>
7141 * inferiors.c (get_first_process): New function.
7142 * inferiors.h (get_first_process): New declaration.
7143 * remote-utils.c (read_ptid): Default to the first process in the
7144 list, instead of to the current thread's process.
7146 2015-08-24 Pedro Alves <palves@redhat.com>
7148 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
7149 * event-loop.c: Likewise.
7150 * remote-utils.c: Likewise.
7151 * tracepoint.c: Likewise.
7153 2015-08-24 Pedro Alves <palves@redhat.com>
7155 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
7158 2015-08-21 Pedro Alves <palves@redhat.com>
7160 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
7161 instead of literal 1.
7163 2015-08-21 Pedro Alves <palves@redhat.com>
7165 * tdesc.c (default_description): Explicitly zero-initialize.
7167 2015-08-21 Pedro Alves <palves@redhat.com>
7170 * inferiors.c (remove_thread): Discard any pending stop reply for
7172 * server.c (remove_all_on_match_pid): Rename to ...
7173 (remove_all_on_match_ptid): ... this. Work with a filter ptid
7175 (discard_queued_stop_replies): Change parameter to a ptid. Now
7177 (handle_v_kill, kill_inferior_callback, captured_main)
7178 (process_serial_event): Adjust.
7179 * server.h (discard_queued_stop_replies): Declare.
7181 2015-08-21 Pedro Alves <palves@redhat.com>
7183 * linux-low.c (wait_for_sigstop): Always switch to no thread
7184 selected if the previously current thread dies.
7185 * lynx-low.c (lynx_request_interrupt): Use the first thread's
7186 process instead of the current thread's.
7187 * remote-utils.c (input_interrupt): Don't check if there's no
7189 * server.c (gdb_read_memory, gdb_write_memory): If setting the
7190 current thread to the general thread fails, error out.
7191 (handle_qxfer_auxv, handle_qxfer_libraries)
7192 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
7193 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
7194 (handle_query): Check if there's a thread selected instead of
7195 checking whether there's any thread in the thread list.
7196 (handle_qxfer_threads, handle_qxfer_btrace)
7197 (handle_qxfer_btrace_conf): Don't error out early if there's no
7198 thread in the thread list.
7199 (handle_v_cont, myresume): Don't set the current thread to the
7201 (process_serial_event) <Hg handling>: Also set thread_id if the
7202 previous general thread is still alive.
7203 (process_serial_event) <g/G handling>: If setting the current
7204 thread to the general thread fails, error out.
7205 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
7206 thread's lwp instead of the current thread's.
7207 * target.c (set_desired_thread): If the desired thread was not
7208 found, leave the current thread pointing to NULL. Return an int
7209 (boolean) indicating success.
7210 * target.h (set_desired_thread): Change return type to int.
7212 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
7214 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
7215 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
7217 (ps_get_thread_area): New function.
7219 2015-08-19 Gary Benson <gbenson@redhat.com>
7221 * hostio.c (handle_pread): Do not attempt to read more data
7222 than hostio_reply_with_data can fit in a packet.
7224 2015-08-18 Joel Brobecker <brobecker@adacore.com>
7226 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
7228 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
7230 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
7232 2015-08-06 Pedro Alves <palves@redhat.com>
7234 * tracepoint.c (expr_eval_result): Now an int.
7236 2015-08-06 Pedro Alves <palves@redhat.com>
7238 * gdbthread.h (struct regcache): Forward declare.
7239 (struct thread_info) <regcache_data>: Now a struct regcache
7241 * inferiors.c (inferior_regcache_data)
7242 (set_inferior_regcache_data): Now work with struct regcache
7244 * inferiors.h (struct regcache): Forward declare.
7245 (inferior_regcache_data, set_inferior_regcache_data): Now work
7246 with struct regcache pointers.
7247 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
7248 (free_register_cache_thread): Remove struct regcache pointer
7251 2015-08-06 Pedro Alves <palves@redhat.com>
7253 * server.c (captured_main): On error, print the exception message
7254 to stderr, and if run_once is set, throw a quit.
7256 2015-08-06 Pedro Alves <palves@redhat.com>
7258 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
7261 2015-08-06 Pedro Alves <palves@redhat.com>
7263 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
7264 reading beyond the passed in buffer length.
7266 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
7268 * tracepoint.c (symbol_list) <required>: Remove.
7270 2015-08-06 Pedro Alves <palves@redhat.com>
7272 * linux-low.c (handle_extended_wait): Set the fork child's suspend
7273 count if stopping and suspending threads.
7274 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
7275 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
7276 (linux_detach): Complete an ongoing step-over.
7277 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
7279 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
7280 (linux_wait_1): If passing a signal to the inferior after
7281 finishing a step-over, unsuspend and re-resume all lwps. If we
7282 see a single-step event but the thread should be continuing, don't
7283 pass the trap to gdb.
7284 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
7285 internal_error instead of gdb_assert.
7286 (enqueue_pending_signal): New function.
7287 (check_ptrace_stopped_lwp_gone): Add debug output.
7288 (start_step_over): Use internal_error instead of gdb_assert.
7289 (complete_ongoing_step_over): New function.
7290 (linux_resume_one_thread): Don't resume a suspended thread.
7291 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
7294 2015-08-06 Pedro Alves <palves@redhat.com>
7296 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
7297 (linux_thread_alive): Use lwp_is_marked_dead.
7298 (extended_event_reported): Delete.
7299 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
7300 instead of extended_event_reported.
7301 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
7303 (lwp_is_marked_dead): New function.
7304 (lwp_running): Use lwp_is_marked_dead.
7305 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
7308 2015-08-06 Pedro Alves <palves@redhat.com>
7310 * linux-low.c (linux_wait_1): Move fork event output out of the
7311 !report_to_gdb check. Pass event_child->waitstatus to
7312 target_waitstatus_to_string instead of ourstatus.
7314 2015-08-04 Yao Qi <yao.qi@linaro.org>
7316 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
7317 if current_thread is 32 bit.
7319 2015-08-04 Yao Qi <yao.qi@linaro.org>
7321 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
7322 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
7323 * server.c (extended_protocol): Remove "static".
7324 * server.h (extended_protocol): Declare it.
7326 2015-08-04 Yao Qi <yao.qi@linaro.org>
7328 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
7329 both aarch64 and aarch32.
7330 (aarch64_set_pc): Likewise.
7332 2015-08-04 Yao Qi <yao.qi@linaro.org>
7334 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
7335 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
7336 arm-with-neon.xml to srv_xmlfiles.
7337 * linux-aarch64-low.c: Include linux-aarch32-low.h.
7338 (is_64bit_tdesc): New function.
7339 (aarch64_linux_read_description): New function.
7340 (aarch64_arch_setup): Call aarch64_linux_read_description.
7341 (regs_info): Rename to regs_info_aarch64.
7342 (aarch64_regs_info): Return right regs_info.
7343 (initialize_low_arch): Call initialize_low_arch_aarch32.
7345 2015-08-04 Yao Qi <yao.qi@linaro.org>
7347 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
7348 * linux-aarch32-low.c: New file.
7349 * linux-aarch32-low.h: New file.
7350 * linux-arm-low.c (arm_fill_gregset): Move it to
7351 linux-aarch32-low.c.
7352 (arm_store_gregset): Likewise.
7353 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
7354 (arm_store_vfpregset): Call arm_store_vfpregset_num.
7355 (arm_arch_setup): Check if PTRACE_GETREGSET works.
7356 (regs_info): Rename to regs_info_arm.
7357 (arm_regs_info): Return regs_info_aarch32 if
7358 have_ptrace_getregset is 1 and target description is
7359 arm_with_neon or arm_with_vfpv3.
7360 (initialize_low_arch): Don't call init_registers_arm_with_neon.
7361 Call initialize_low_arch_aarch32 instead.
7363 2015-08-04 Yao Qi <yao.qi@linaro.org>
7365 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
7366 * linux-low.c: ... here.
7367 * linux-low.h (have_ptrace_getregset): Declare it.
7369 2015-08-04 Pedro Alves <palves@redhat.com>
7371 * thread-db.c (struct thread_db): Use new typedefs.
7372 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
7374 (disable_thread_event_reporting): Cast result of dlsym to
7375 destination function pointer type.
7376 (thread_db_mourn): Use td_ta_delete_ftype.
7378 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
7380 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
7382 (CDX_BREAKPOINT): Define for R2.
7383 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
7384 (the_low_target): Add comments.
7386 2015-07-30 Yao Qi <yao.qi@linaro.org>
7388 * linux-arm-low.c (arm_hwcap): Remove it.
7389 (arm_read_description): New local variable arm_hwcap. Don't
7390 set arm_hwcap to zero.
7392 2015-07-30 Yao Qi <yao.qi@linaro.org>
7394 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
7395 Use regcache->tdesc instead.
7396 (arm_store_wmmxregset): Likewise.
7397 (arm_fill_vfpregset): Likewise.
7398 (arm_store_vfpregset): Likewise.
7400 2015-07-30 Yao Qi <yao.qi@linaro.org>
7402 * linux-arm-low.c: Include arch/arm.h.
7403 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
7404 (arm_store_gregset): Likewise.
7406 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
7408 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
7409 ptrace's 4th parameter.
7411 2015-07-27 Yao Qi <yao.qi@linaro.org>
7413 * configure.srv (case aarch64*-*-linux*): Don't set
7416 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
7418 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
7420 * linux-arm-low.c: Likewise.
7421 * linux-cris-low.c: Likewise.
7422 * linux-crisv32-low.c: Likewise.
7423 * linux-low.c: Likewise.
7424 * linux-m68k-low.c: Likewise.
7425 * linux-mips-low.c: Likewise.
7426 * linux-nios2-low.c: Likewise.
7427 * linux-s390-low.c: Likewise.
7428 * linux-sparc-low.c: Likewise.
7429 * linux-tic6x-low.c: Likewise.
7430 * linux-tile-low.c: Likewise.
7431 * linux-x86-low.c: Likewise.
7433 2015-07-24 Pedro Alves <palves@redhat.com>
7435 * config.in: Regenerate.
7436 * configure: Regenerate.
7438 2015-07-24 Pedro Alves <palves@redhat.com>
7440 * acinclude.m4: Include ../ptrace.m4.
7441 * configure.ac: Call GDB_AC_PTRACE.
7442 * config.in, configure: Regenerate.
7444 2015-07-24 Yao Qi <yao.qi@linaro.org>
7446 * linux-low.c (linux_create_inferior): Remove setting to
7447 proc->priv->new_inferior.
7448 (linux_attach): Likewise.
7449 (linux_low_filter_event): Likewise.
7450 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
7452 2015-07-24 Yao Qi <yao.qi@linaro.org>
7454 * linux-low.c (linux_arch_setup): New function.
7455 (linux_low_filter_event): If proc->tdesc is NULL and
7456 proc->attached is true, call the_low_target.arch_setup.
7457 Otherwise, keep status pending, and return.
7458 (linux_resume_one_lwp_throw): Don't call get_pc if
7459 thread->while_stepping isn't NULL. Don't call
7460 get_thread_regcache if proc->tdesc is NULL.
7461 (need_step_over_p): Return 0 if proc->tdesc is NULL.
7462 (linux_target_ops): Install arch_setup.
7463 * server.c (start_inferior): Call the_target->arch_setup.
7464 * target.h (struct target_ops) <arch_setup>: New field.
7465 (target_arch_setup): New marco.
7466 * lynx-low.c (lynx_target_ops): Update.
7467 * nto-low.c (nto_target_ops): Update.
7468 * spu-low.c (spu_target_ops): Update.
7469 * win32-low.c (win32_target_ops): Update.
7471 2015-07-24 Yao Qi <yao.qi@linaro.org>
7473 * linux-low.c (linux_add_process): Don't set
7474 proc->priv->new_inferior.
7475 (linux_create_inferior): Set proc->priv->new_inferior to 1.
7476 (linux_attach): Likewise.
7478 2015-07-24 Yao Qi <yao.qi@linaro.org>
7480 * server.c (start_inferior): Code refactor.
7482 2015-07-24 Yao Qi <yao.qi@linaro.org>
7484 * server.c (process_serial_event): Set general_thread.
7486 2015-07-21 Yao Qi <yao.qi@linaro.org>
7488 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
7489 aarch64_linux_get_debug_reg_capacity.
7491 2015-07-17 Yao Qi <yao.qi@linaro.org>
7493 * Makefile.in (aarch64-linux-hw-point.o): New rule.
7494 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
7495 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
7496 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
7497 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
7498 (AARCH64_HWP_ALIGNMENT): Likewise.
7499 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
7500 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
7501 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
7502 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
7503 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
7504 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
7505 (struct aarch64_debug_reg_state): Likewise.
7506 (struct arch_lwp_info): Likewise.
7507 (aarch64_align_watchpoint): Likewise.
7508 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
7509 (aarch64_watchpoint_length): Likewise.
7510 (aarch64_point_encode_ctrl_reg): Likewise
7511 (aarch64_point_is_aligned): Likewise.
7512 (aarch64_align_watchpoint): Likewise.
7513 (aarch64_linux_set_debug_regs):
7514 (aarch64_dr_state_insert_one_point): Likewise.
7515 (aarch64_dr_state_remove_one_point): Likewise.
7516 (aarch64_handle_breakpoint): Likewise.
7517 (aarch64_handle_aligned_watchpoint): Likewise.
7518 (aarch64_handle_unaligned_watchpoint): Likewise.
7519 (aarch64_handle_watchpoint): Likewise.
7521 2015-07-17 Yao Qi <yao.qi@linaro.org>
7523 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
7524 and don't aarch64_get_debug_reg_state. All callers update.
7525 (aarch64_handle_aligned_watchpoint): Likewise.
7526 (aarch64_handle_unaligned_watchpoint): Likewise.
7527 (aarch64_handle_watchpoint): Likewise.
7528 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
7529 (aarch64_remove_point): Likewise.
7531 2015-07-17 Yao Qi <yao.qi@linaro.org>
7533 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
7535 (aarch64_handle_unaligned_watchpoint): Likewise.
7537 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
7539 Revert the previous 3 commits:
7540 Move gdb_regex* to common/
7541 Move linux_find_memory_regions_full & co.
7542 gdbserver build-id attribute generator
7544 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
7545 Jan Kratochvil <jan.kratochvil@redhat.com>
7547 gdbserver build-id attribute generator.
7548 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
7549 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
7550 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
7552 (get_dynamic): Use find_pdhr to traverse program headers.
7553 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
7554 (compare_mapping_entry_range, struct find_memory_region_callback_data)
7555 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
7556 (get_hex_build_id): New.
7557 (linux_qxfer_libraries_svr4): Add optional build-id attribute
7558 to reply XML document.
7560 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
7561 Jan Kratochvil <jan.kratochvil@redhat.com>
7563 * target.c: Include target/target-utils.h and fcntl.h.
7564 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
7565 (target_fileio_read_stralloc): New functions.
7567 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
7569 * Makefile.in (OBS): Add gdb_regex.o.
7571 * config.in: Rebuilt.
7572 * configure: Rebuilt.
7574 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
7575 Jan Kratochvil <jan.kratochvil@redhat.com>
7577 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
7578 * Makefile.in (OBS): Add target-utils.o.
7579 (linux-maps.o, target-utils.o): New.
7580 * configure.srv (srv_linux_obj): Add linux-maps.o.
7582 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
7584 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
7586 (the_low_target): Install it.
7588 2015-07-14 Pedro Alves <palves@redhat.com>
7590 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
7591 Instead, ignore ECHILD, and throw an error for other errnos.
7593 2015-07-10 Pedro Alves <palves@redhat.com>
7595 * event-loop.c (struct callback_event) <data>: Change type to
7596 gdb_client_data instance instead of gdb_client_data pointer.
7597 (append_callback_event): Adjust.
7599 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
7601 * linux-aarch64-low.c: Add comments for each linux_target_ops
7602 method. Remove comments already covered in target_ops and
7603 linux_target_ops definitions.
7604 (the_low_target): Add comments for each unimplemented method.
7606 2015-07-09 Yao Qi <yao.qi@linaro.org>
7608 * linux-aarch64-low.c (aarch64_regmap): Remove.
7609 (aarch64_usrregs_info): Remove.
7610 (regs_info): Set field usrregs to NULL.
7612 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
7614 * linux-low.c: Include "rsp-low.h"
7615 (linux_low_encode_pt_config, linux_low_encode_raw): New.
7616 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
7617 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
7618 (handle_btrace_enable_pt): New.
7619 (handle_btrace_general_set): Support "pt".
7620 (handle_btrace_conf_general_set): Support "pt:size".
7622 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
7624 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
7627 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
7629 * linux-aarch64-low.c: Remove comment about endianness.
7630 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
7631 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
7634 2015-06-24 Gary Benson <gbenson@redhat.com>
7636 * linux-i386-ipa.c (stdint.h): Do not include.
7637 * lynx-i386-low.c (stdint.h): Likewise.
7638 * lynx-ppc-low.c (stdint.h): Likewise.
7639 * mem-break.c (stdint.h): Likewise.
7640 * thread-db.c (stdint.h): Likewise.
7641 * tracepoint.c (stdint.h): Likewise.
7642 * win32-low.c (stdint.h): Likewise.
7644 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
7646 * server.c (write_qxfer_response): Update call to
7647 remote_escape_output.
7649 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
7650 Jan Kratochvil <jan.kratochvil@redhat.com>
7652 Merge multiple hex conversions.
7653 * gdbreplay.c (tohex): Rename to 'fromhex'.
7654 (logchar): Use fromhex.
7656 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
7658 * server.c (handle_qxfer_libraries): Set `version' attribute for
7661 2015-06-10 Gary Benson <gbenson@redhat.com>
7663 * target.h (struct target_ops) <multifs_open>: New field.
7664 <multifs_unlink>: Likewise.
7665 <multifs_readlink>: Likewise.
7666 * linux-low.c (nat/linux-namespaces.h): New include.
7667 (linux_target_ops): Initialize the_target->multifs_open,
7668 the_target->multifs_unlink and the_target->multifs_readlink.
7669 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
7670 * hostio.c (hostio_fs_pid): New static variable.
7671 (hostio_handle_new_gdb_connection): New function.
7672 (handle_setfs): Likewise.
7673 (handle_open): Use the_target->multifs_open as appropriate.
7674 (handle_unlink): Use the_target->multifs_unlink as appropriate.
7675 (handle_readlink): Use the_target->multifs_readlink as
7677 (handle_vFile): Handle vFile:setfs packets.
7678 * server.c (handle_query): Call hostio_handle_new_gdb_connection
7679 after target_handle_new_gdb_connection.
7681 2015-06-10 Gary Benson <gbenson@redhat.com>
7683 * configure.ac (AC_CHECK_FUNCS): Add setns.
7684 * config.in: Regenerate.
7685 * configure: Likewise.
7686 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
7687 (linux-namespaces.o): New rule.
7688 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
7690 2015-06-09 Gary Benson <gbenson@redhat.com>
7692 * hostio.c (handle_open): Process mode argument with
7693 fileio_to_host_mode.
7695 2015-06-01 Yao Qi <yao.qi@linaro.org>
7697 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
7698 * linux-x86-low.c: Likewise.
7700 2015-05-28 Don Breazeal <donb@codesourcery.com>
7702 * linux-low.c (handle_extended_wait): Initialize
7703 thread_info.last_resume_kind for new fork children.
7705 2015-05-15 Pedro Alves <palves@redhat.com>
7707 * target.h (target_handle_new_gdb_connection): Rewrite using if
7708 wrapped in do/while.
7710 2015-05-14 Joel Brobecker <brobecker@adacore.com>
7712 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
7713 * configure, config.in: Regenerate.
7714 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
7717 2015-05-12 Don Breazeal <donb@codesourcery.com>
7719 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
7720 PTRACE_EVENT_VFORK_DONE.
7721 (linux_low_ptrace_options, extended_event_reported): Add vfork
7723 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
7724 and "vforkdone" for RSP 'T' Stop Reply Packet.
7725 * server.h (report_vfork_events): Declare
7728 2015-05-12 Don Breazeal <donb@codesourcery.com>
7730 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
7731 (the_low_target) <new_fork>: Initialize new member.
7732 * linux-arm-low.c (arm_new_fork): New function.
7733 (the_low_target) <new_fork>: Initialize new member.
7734 * linux-low.c (handle_extended_wait): Call new target function
7736 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
7737 * linux-mips-low.c (mips_add_watchpoint): New function
7738 extracted from mips_insert_point.
7739 (the_low_target) <new_fork>: Initialize new member.
7740 (mips_linux_new_fork): New function.
7741 (mips_insert_point): Call mips_add_watchpoint.
7742 * linux-x86-low.c (x86_linux_new_fork): New function.
7743 (the_low_target) <new_fork>: Initialize new member.
7745 2015-05-12 Don Breazeal <donb@codesourcery.com>
7747 * linux-low.c (handle_extended_wait): Implement return value,
7748 rename argument 'event_child' to 'event_lwp', handle
7749 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
7750 (linux_low_ptrace_options): New function.
7751 (linux_low_filter_event): Call linux_low_ptrace_options,
7752 use different argument fo linux_enable_event_reporting,
7753 use return value from handle_extended_wait.
7754 (extended_event_reported): New function.
7755 (linux_wait_1): Call extended_event_reported and set
7756 status to report fork events.
7757 (linux_write_memory): Add pid to debug message.
7758 (reset_lwp_ptrace_options_callback): New function.
7759 (linux_handle_new_gdb_connection): New function.
7760 (linux_target_ops): Initialize new structure member.
7761 * linux-low.h (struct lwp_info) <waitstatus>: New member.
7762 * lynx-low.c: Initialize new structure member.
7763 * remote-utils.c (prepare_resume_reply): Implement stop reason
7764 "fork" for "T" stop message.
7765 * server.c (handle_query): Call handle_new_gdb_connection.
7766 * server.h (report_fork_events): Declare global flag.
7767 * target.h (struct target_ops) <handle_new_gdb_connection>:
7769 (target_handle_new_gdb_connection): New macro.
7770 * win32-low.c: Initialize new structure member.
7772 2015-05-12 Don Breazeal <donb@codesourcery.com>
7774 * mem-break.c (APPEND_TO_LIST): Define macro.
7775 (clone_agent_expr): New function.
7776 (clone_one_breakpoint): New function.
7777 (clone_all_breakpoints): New function.
7778 * mem-break.h: Declare new functions.
7780 2015-05-12 Don Breazeal <donb@codesourcery.com>
7782 * linux-low.c (linux_supports_fork_events): New function.
7783 (linux_supports_vfork_events): New function.
7784 (linux_target_ops): Initialize new structure members.
7785 (initialize_low): Call linux_check_ptrace_features.
7786 * lynx-low.c (lynx_target_ops): Initialize new structure
7788 * server.c (report_fork_events, report_vfork_events):
7790 (handle_query): Add new features to qSupported packet and
7792 (captured_main): Initialize new global variables.
7793 * target.h (struct target_ops) <supports_fork_events>:
7795 <supports_vfork_events>: New member.
7796 (target_supports_fork_events): New macro.
7797 (target_supports_vfork_events): New macro.
7798 * win32-low.c (win32_target_ops): Initialize new structure
7801 2015-05-12 Gary Benson <gbenson@redhat.com>
7803 * server.c (handle_qxfer_exec_file): Use current process
7806 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
7808 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
7809 Remove HAVE_PTRACE_GETREGS conditionals.
7810 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
7811 instead of PTRACE_GETREGS and PTRACE_SETREGS.
7813 2015-05-08 Yao Qi <yao.qi@linaro.org>
7815 * linux-low.c (linux_supports_conditional_breakpoints): New
7817 (linux_target_ops): Install new target method.
7818 * lynx-low.c (lynx_target_ops): Install NULL hook for
7819 supports_conditional_breakpoints.
7820 * nto-low.c (nto_target_ops): Likewise.
7821 * spu-low.c (spu_target_ops): Likewise.
7822 * win32-low.c (win32_target_ops): Likewise.
7823 * server.c (handle_query): Check
7824 target_supports_conditional_breakpoints.
7825 * target.h (struct target_ops) <supports_conditional_breakpoints>:
7827 (target_supports_conditional_breakpoints): New macro.
7829 2015-05-06 Pedro Alves <palves@redhat.com>
7832 * server.c (start_inferior): If the process exits, mourn it.
7834 2015-04-21 Gary Benson <gbenson@redhat.com>
7836 * hostio.c (fileio_open_flags_to_host): Factored out to
7837 fileio_to_host_openflags in common/fileio.c. Single use
7840 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
7842 * linux-xtensa-low.c (xtensa_fill_gregset)
7843 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
7846 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
7848 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
7849 (regs_info): Replace usrregs pointer with NULL.
7851 2015-04-17 Gary Benson <gbenson@redhat.com>
7853 * target.h (struct target_ops) <pid_to_exec_file>: New field.
7854 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
7855 * server.c (handle_qxfer_exec_file): New function.
7856 (qxfer_packets): Add exec-file entry.
7857 (handle_query): Report qXfer:exec-file:read as supported packet.
7859 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
7861 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
7863 2015-04-09 Gary Benson <gbenson@redhat.com>
7865 * hostio-errno.c (errno_to_fileio_error): Remove function.
7866 Update caller to use remote_fileio_to_fio_error.
7868 2015-04-09 Yao Qi <yao.qi@linaro.org>
7870 * linux-low.c (linux_insert_point): Call
7871 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
7872 (linux_remove_point): Call remove_memory_breakpoint if type is
7874 * linux-x86-low.c (x86_insert_point): Don't call
7875 insert_memory_breakpoint.
7876 (x86_remove_point): Don't call remove_memory_breakpoint.
7878 2015-04-01 Pedro Alves <palves@redhat.com>
7879 Cleber Rosa <crosa@redhat.com>
7881 * server.c (gdbserver_usage): Reorganize and extend the usage
7884 2015-03-24 Pedro Alves <palves@redhat.com>
7886 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
7887 output. Also dump TRAP_TRACE.
7888 (linux_low_filter_event): In debug output, distinguish a
7889 resume_stop SIGSTOP from a delayed SIGSTOP.
7891 2015-03-24 Gary Benson <gbenson@redhat.com>
7893 * linux-x86-low.c (x86_linux_new_thread): Moved to
7895 (x86_linux_prepare_to_resume): Likewise.
7897 2015-03-24 Gary Benson <gbenson@redhat.com>
7899 * Makefile.in (x86-linux-dregs.o): New rule.
7900 * configure.srv: Add x86-linux-dregs.o to relevant targets.
7901 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
7902 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
7903 (x86_linux_dr_get): Likewise.
7904 (x86_linux_dr_set): Likewise.
7905 (update_debug_registers_callback): Likewise.
7906 (x86_linux_dr_set_addr): Likewise.
7907 (x86_linux_dr_get_addr): Likewise.
7908 (x86_linux_dr_set_control): Likewise.
7909 (x86_linux_dr_get_control): Likewise.
7910 (x86_linux_dr_get_status): Likewise.
7911 (x86_linux_update_debug_registers): Likewise.
7913 2015-03-24 Gary Benson <gbenson@redhat.com>
7915 * linux-x86-low.c (x86_linux_update_debug_registers):
7916 New function, factored out from...
7917 (x86_linux_prepare_to_resume): ...this.
7919 2015-03-24 Gary Benson <gbenson@redhat.com>
7921 * linux-x86-low.c (x86_linux_dr_get): Update comments.
7922 (x86_linux_dr_set): Likewise.
7923 (update_debug_registers_callback): Likewise.
7924 (x86_linux_dr_set_addr): Likewise.
7925 (x86_linux_dr_get_addr): Likewise.
7926 (x86_linux_dr_set_control): Likewise.
7927 (x86_linux_dr_get_control): Likewise.
7928 (x86_linux_dr_get_status): Likewise.
7929 (x86_linux_prepare_to_resume): Likewise.
7931 2015-03-24 Gary Benson <gbenson@redhat.com>
7933 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
7934 Use perror_with_name. Pass string through gettext.
7935 (x86_linux_dr_set): Likewise.
7937 2015-03-24 Gary Benson <gbenson@redhat.com>
7939 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
7940 (x86_linux_dr_set_addr): ...this.
7941 (x86_dr_low_get_addr): Rename to...
7942 (x86_linux_dr_get_addr): ...this.
7943 (x86_dr_low_set_control): Rename to...
7944 (x86_linux_dr_set_control): ...this.
7945 (x86_dr_low_get_control): Rename to...
7946 (x86_linux_dr_get_control): ...this.
7947 (x86_dr_low_get_status): Rename to...
7948 (x86_linux_dr_get_status): ...this.
7949 (x86_dr_low): Update with new function names.
7951 2015-03-24 Gary Benson <gbenson@redhat.com>
7953 * Makefile.in (x86-linux.o): New rule.
7954 * configure.srv: Add x86-linux.o to relevant targets.
7955 * linux-low.c (lwp_set_arch_private_info): New function.
7956 (lwp_arch_private_info): Likewise.
7957 * linux-x86-low.c: Include nat/x86-linux.h.
7958 (arch_lwp_info): Removed structure.
7959 (update_debug_registers_callback):
7960 Use lwp_set_debug_registers_changed.
7961 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
7962 and lwp_set_debug_registers_changed.
7963 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
7965 2015-03-24 Gary Benson <gbenson@redhat.com>
7967 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
7968 * linux-arm-low.c (arm_new_thread): Likewise.
7969 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
7970 * linux-mips-low.c (mips_linux_new_thread): Likewise.
7971 * linux-x86-low.c (x86_linux_new_thread): Likewise.
7972 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
7974 2015-03-24 Gary Benson <gbenson@redhat.com>
7976 * linux-low.c (ptid_of_lwp): New function.
7977 (lwp_is_stopped): Likewise.
7978 (lwp_stop_reason): Likewise.
7979 * linux-x86-low.c (update_debug_registers_callback):
7981 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
7984 2015-03-24 Gary Benson <gbenson@redhat.com>
7986 * linux-low.h (linux_stop_lwp): Remove declaration.
7988 2015-03-24 Gary Benson <gbenson@redhat.com>
7990 * linux-low.h: Include nat/linux-nat.h.
7991 * linux-low.c (iterate_over_lwps_args): New structure.
7992 (iterate_over_lwps_filter): New function.
7993 (iterate_over_lwps): Likewise.
7994 * linux-x86-low.c (update_debug_registers_callback):
7995 Update signature to what iterate_over_lwps expects.
7996 Remove PID check that iterate_over_lwps now performs.
7997 (x86_dr_low_set_addr): Use iterate_over_lwps.
7998 (x86_dr_low_set_control): Likewise.
8000 2015-03-24 Gary Benson <gbenson@redhat.com>
8002 * linux-x86-low.c (x86_debug_reg_state): New function.
8003 (x86_linux_prepare_to_resume): Use the above.
8005 2015-03-24 Gary Benson <gbenson@redhat.com>
8007 * linux-low.c (current_lwp_ptid): New function.
8008 * linux-x86-low.c: Include nat/linux-nat.h.
8009 (x86_dr_low_get_addr): Use current_lwp_ptid.
8010 (x86_dr_low_get_control): Likewise.
8011 (x86_dr_low_get_status): Likewise.
8013 2015-03-20 Pedro Alves <palves@redhat.com>
8015 * tracepoint.c (cmd_qtstatus): Make "str" const.
8017 2015-03-20 Pedro Alves <palves@redhat.com>
8019 * server.c (handle_general_set): Make "req_str" const.
8021 2015-03-19 Pedro Alves <palves@redhat.com>
8023 * linux-low.c (linux_resume_one_lwp): Rename to ...
8024 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
8025 instead call perror_with_name.
8026 (check_ptrace_stopped_lwp_gone): New function.
8027 (linux_resume_one_lwp): Reimplement as wrapper around
8028 linux_resume_one_lwp_throw that swallows errors if the LWP is
8031 2015-03-19 Pedro Alves <palves@redhat.com>
8033 * linux-low.c (count_events_callback, select_event_lwp_callback):
8034 No longer check whether the thread has resume_stop as last resume
8037 2015-03-19 Pedro Alves <palves@redhat.com>
8039 * linux-low.c (count_events_callback, select_event_lwp_callback):
8040 Use the lwp's status_pending_p field, not the thread's.
8042 2015-03-19 Pedro Alves <palves@redhat.com>
8044 * linux-low.c (select_event_lwp_callback): Update comments to
8045 no longer mention SIGTRAP.
8047 2015-03-18 Gary Benson <gbenson@redhat.com>
8049 * server.c (handle_query): Do not report vFile:fstat as supported.
8051 2015-03-11 Gary Benson <gbenson@redhat.com>
8053 * hostio.c (sys/types.h): New include.
8054 (sys/stat.h): Likewise.
8055 (common-remote-fileio.h): Likewise.
8056 (handle_fstat): New function.
8057 (handle_vFile): Handle vFile:fstat packets.
8059 2015-03-11 Gary Benson <gbenson@redhat.com>
8061 * configure.ac (AC_CHECK_MEMBERS): Add checks for
8062 struct stat.st_blocks and struct stat.st_blksize.
8063 * configure: Regenerate.
8064 * config.in: Likewise.
8065 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
8066 (OBS): Add common-remote-fileio.o.
8067 (common-remote-fileio.o): New rule.
8069 2015-03-09 Pedro Alves <palves@redhat.com>
8071 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
8072 'struct sockaddr' pointer in 'accept' call.
8074 2015-03-09 Pedro Alves <palves@redhat.com>
8077 2015-03-07 Pedro Alves <palves@redhat.com>
8078 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
8079 or <winsock2.h> here. Instead include "gdb_socket.h".
8080 (remote_open): Use union gdb_sockaddr_u.
8081 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
8082 or <winsock2.h> here. Instead include "gdb_socket.h".
8083 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
8084 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
8086 (init_named_socket, gdb_agent_helper_thread): Use union
8089 2015-03-07 Pedro Alves <palves@redhat.com>
8091 * configure.ac (build_warnings): Move
8092 -Wdeclaration-after-statement to the C-specific set.
8093 * configure: Regenerate.
8095 2015-03-07 Pedro Alves <palves@redhat.com>
8097 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
8098 or <winsock2.h> here. Instead include "gdb_socket.h".
8099 (remote_open): Use union gdb_sockaddr_u.
8100 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
8101 or <winsock2.h> here. Instead include "gdb_socket.h".
8102 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
8103 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
8105 (init_named_socket, gdb_agent_helper_thread): Use union
8108 2015-03-07 Pedro Alves <palves@redhat.com>
8110 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
8113 2015-03-06 Yao Qi <yao.qi@linaro.org>
8115 * linux-aarch64-low.c (aarch64_insert_point): Use
8116 show_debug_regs as a boolean.
8117 (aarch64_remove_point): Likewise.
8119 2015-03-05 Pedro Alves <palves@redhat.com>
8121 * lynx-low.c (lynx_target_ops): Install NULL hooks for
8122 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
8123 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
8124 * nto-low.c (nto_target_ops): Likewise.
8125 * spu-low.c (spu_target_ops): Likewise.
8126 * win32-low.c (win32_target_ops): Likewise.
8128 2015-03-04 Pedro Alves <palves@redhat.com>
8130 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
8131 Decide whether a breakpoint triggered based on the SIGTRAP's
8133 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
8134 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
8135 (linux_low_filter_event): Check for breakpoints before checking
8137 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
8139 (linux_stopped_by_sw_breakpoint)
8140 (linux_supports_stopped_by_sw_breakpoint)
8141 (linux_stopped_by_hw_breakpoint)
8142 (linux_supports_stopped_by_hw_breakpoint): New functions.
8143 (linux_target_ops): Install new target methods.
8145 2015-03-04 Pedro Alves <palves@redhat.com>
8147 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
8148 * server.c (swbreak_feature, hwbreak_feature): New globals.
8149 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
8150 (captured_main): Clear swbreak_feature and hwbreak_feature.
8151 * server.h (swbreak_feature, hwbreak_feature): Declare.
8152 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
8153 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
8154 supports_stopped_by_hw_breakpoint>: New fields.
8155 (target_supports_stopped_by_sw_breakpoint)
8156 (target_stopped_by_sw_breakpoint)
8157 (target_supports_stopped_by_hw_breakpoint)
8158 (target_stopped_by_hw_breakpoint): Declare.
8160 2015-03-04 Pedro Alves <palves@redhat.com>
8162 enum lwp_stop_reason -> enum target_stop_reason
8163 * linux-low.c (check_stopped_by_breakpoint): Adjust.
8164 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
8165 (linux_wait_1, stuck_in_jump_pad_callback)
8166 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
8167 (linux_stopped_by_watchpoint):
8168 * linux-low.h (enum lwp_stop_reason): Delete.
8169 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
8170 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
8172 2015-03-04 Yao Qi <yao.qi@linaro.org>
8174 * Makefile.in (SFILES): Add linux-aarch64-low.c.
8176 2015-03-03 Gary Benson <gbenson@redhat.com>
8178 * hostio.c (handle_vFile): Fix prefix lengths.
8180 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
8182 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
8185 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
8187 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
8188 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
8189 (clean): Add "rm -f" for above C files.
8190 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
8191 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
8192 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
8193 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
8194 * linux-s390-low.c (HWCAP_S390_VX): New macro.
8195 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
8196 (init_registers_s390x_vx_linux64)
8197 (init_registers_s390x_tevx_linux64)
8198 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
8199 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
8201 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
8202 (s390_store_vxrs_high): New functions.
8203 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
8205 (s390_arch_setup): Add logic for selecting one of the new target
8206 descriptions. Activate the new vector regsets if applicable.
8207 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
8208 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
8209 and init_registers_s390x_tevx_linux64.
8211 2015-03-01 Pedro Alves <palves@redhat.com>
8213 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
8216 2015-02-27 Pedro Alves <palves@redhat.com>
8218 * linux-x86-low.c (u_debugreg_offset): New function.
8219 (x86_linux_dr_get, x86_linux_dr_set): Use it.
8221 2015-02-27 Pedro Alves <palves@redhat.com>
8223 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
8224 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
8225 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
8226 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
8227 (ps_lsetfpregs, ps_getpid)
8228 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
8229 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
8230 (ps_lsetxregs, ps_plog): Declare.
8232 2015-02-27 Pedro Alves <palves@redhat.com>
8234 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
8235 IP_AGENT_EXPORT_FUNC.
8236 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
8237 IP_AGENT_EXPORT_FUNC.
8238 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
8239 (IP_AGENT_EXPORT): Delete.
8240 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
8241 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
8242 (gdb_trampoline_buffer_error, collecting, gdb_collect)
8243 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
8244 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
8245 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
8246 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
8247 (traceframe_read_count, traceframe_write_count)
8248 (traceframes_created, trace_state_variables, get_raw_reg)
8249 (get_trace_state_variable_value, set_trace_state_variable_value)
8250 (ust_loaded, helper_thread_id, cmd_buf): Use
8251 IPA_SYM_EXPORTED_NAME.
8252 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
8253 (tracepoints) Use IP_AGENT_EXPORT_VAR.
8254 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
8255 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
8256 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
8257 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
8258 EXTERN_C_PUSH/EXTERN_C_POP.
8259 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
8260 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
8261 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
8262 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
8263 (traceframe_write_count, traceframe_read_count)
8264 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
8265 (about_to_request_buffer_space, get_trace_state_variable_value)
8266 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
8267 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
8268 EXTERN_C_PUSH/EXTERN_C_POP.
8269 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
8270 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
8271 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
8272 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
8273 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
8274 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
8275 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
8276 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
8278 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
8279 (IP_AGENT_EXPORT_VAR_DECL): Define.
8281 (gdb_agent_get_raw_reg): Declare.
8283 2015-02-27 Tom Tromey <tromey@redhat.com>
8284 Pedro Alves <palves@redhat.com>
8286 Rename symbols whose names are reserved C++ keywords throughout.
8288 2015-02-27 Pedro Alves <palves@redhat.com>
8290 * Makefile.in (COMPILER): New, get it from autoconf.
8291 (CXX): Get from autoconf instead.
8292 (COMPILE.pre): Use COMPILER.
8293 (CC-LD): Rename to ...
8294 (CC_LD): ... this. Use COMPILER.
8295 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
8296 (CXX_FOR_TARGET): Default to g++ instead of gcc.
8297 * acinclude.m4: Include build-with-cxx.m4.
8298 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
8299 Disable -Werror by default if building in C++ mode.
8300 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
8301 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
8302 the C++ compiler. Save/restore CXXFLAGS too.
8303 * configure: Regenerate.
8305 2015-02-27 Pedro Alves <palves@redhat.com>
8307 * acinclude.m4: Include libiberty.m4.
8308 * configure.ac: Call libiberty_INIT.
8309 * config.in, configure: Regenerate.
8311 2015-02-26 Pedro Alves <palves@redhat.com>
8313 * linux-low.c (linux_wait_1): When incrementing the PC past a
8314 program breakpoint always use the_low_target.breakpoint_len as
8315 increment, rather than the maximum between that and
8316 the_low_target.decr_pc_after_break.
8318 2015-02-23 Pedro Alves <palves@redhat.com>
8320 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
8321 thread was doing a step-over; always adjust the PC if
8322 we stepped over a permanent breakpoint.
8323 (linux_wait_1): If we stepped over breakpoint that was on top of a
8324 permanent breakpoint, manually advance the PC past it.
8326 2015-02-23 Pedro Alves <palves@redhat.com>
8328 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
8330 (x86_fill_gregset, x86_store_gregset): Use it when handling
8333 2015-02-20 Pedro Alves <palves@redhat.com>
8335 * thread-db.c: Include "nat/linux-procfs.h".
8336 (thread_db_init): Skip listing new threads if the kernel supports
8337 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
8339 2015-02-20 Pedro Alves <palves@redhat.com>
8341 * linux-low.c (status_pending_p_callback): Use ptid_match.
8343 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
8345 PR breakpoints/16812
8346 * linux-low.c (wstatus_maybe_breakpoint): Remove.
8347 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
8348 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
8350 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
8352 PR breakpoints/15956
8353 * tracepoint.c (cmd_qtinit): Add check for current_thread.
8355 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
8357 * linux-low.c (linux_low_btrace_conf): Print size.
8358 * server.c (handle_btrace_conf_general_set): New.
8359 (hanle_general_set): Call handle_btrace_conf_general_set.
8360 (handle_query): Report Qbtrace-conf:bts:size as supported.
8362 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
8364 * linux-low.c (linux_low_enable_btrace): Update parameters.
8365 (linux_low_btrace_conf): New.
8366 (linux_target_ops)<to_btrace_conf>: Initialize.
8367 * server.c (current_btrace_conf): New.
8368 (handle_btrace_enable): Rename to ...
8369 (handle_btrace_enable_bts): ... this. Pass ¤t_btrace_conf
8370 to target_enable_btrace. Update comment. Update users.
8371 (handle_qxfer_btrace_conf): New.
8372 (qxfer_packets): Add btrace-conf entry.
8373 (handle_query): Report qXfer:btrace-conf:read as supported packet.
8374 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
8375 (target_ops)<read_btrace_conf>: New.
8376 (target_enable_btrace): Update parameters.
8377 (target_read_btrace_conf): New.
8379 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
8381 * server.c (handle_btrace_general_set): Remove call to
8382 target_supports_btrace.
8383 (supported_btrace_packets): New.
8384 (handle_query): Call supported_btrace_packets.
8385 * target.h: include btrace-common.h.
8386 (btrace_target_info): Removed.
8387 (supports_btrace, target_supports_btrace): Update parameters.
8389 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
8391 * Makefile.in (SFILES): Add common/btrace-common.c.
8392 (OBS): Add common/btrace-common.o.
8393 (btrace-common.o): Add build rules.
8394 * linux-low: Include btrace-common.h.
8395 (linux_low_read_btrace): Use struct btrace_data. Call
8396 btrace_data_init and btrace_data_fini.
8398 2015-02-06 Pedro Alves <palves@redhat.com>
8400 * thread-db.c (find_new_threads_callback): Add debug output.
8402 2015-02-04 Pedro Alves <palves@redhat.com>
8404 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
8405 (resume_stopped_resumed_lwps): New function.
8406 (linux_wait_for_event_filtered): Use it.
8408 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
8410 * Makefile.in (SFILES): Add linux-personality.c.
8411 (linux-personality.o): New rule.
8412 * configure.srv (srv_linux_obj): Add linux-personality.o to the
8413 list of objects to be built.
8414 * linux-low.c: Include nat/linux-personality.h.
8415 (linux_create_inferior): Remove code to disable address space
8416 randomization (moved to ../nat/linux-personality.c). Create
8417 cleanup to disable address space randomization.
8419 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
8421 * Makefile.in (posix-strerror.o): New rule.
8422 (mingw-strerror.o): Likewise.
8423 * configure: Regenerated.
8424 * configure.ac: Source file ../common/common.host. Initialize new
8425 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
8427 2015-01-14 Yao Qi <yao@codesourcery.com>
8429 * Makefile.in (SFILES): Add nat/ppc-linux.c.
8430 (ppc-linux.o): New rule.
8431 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
8432 * configure.ac: AC_CHECK_FUNCS(getauxval).
8433 * config.in: Re-generated.
8434 * configure: Re-generated.
8435 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
8436 ppc64_64bit_inferior_p
8438 2015-01-14 Yao Qi <yao@codesourcery.com>
8440 * linux-ppc-low.c: Include "nat/ppc-linux.h".
8441 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
8442 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
8443 (PT_ORIG_R3, PT_TRAP): Likewise.
8444 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
8445 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
8446 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
8448 2015-01-10 Joel Brobecker <brobecker@adacore.com>
8450 * i387-fp.c (i387_cache_to_xsave): In look over
8451 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
8452 zmmh_low_space field by use of zmmh_high_space.
8454 2015-01-09 Pedro Alves <palves@redhat.com>
8456 * linux-low.c (step_over_bkpt): Move higher up in the file.
8457 (handle_extended_wait): Don't store the stop_pc here.
8458 (get_stop_pc): Adjust comments and rename to ...
8459 (check_stopped_by_breakpoint): ... this. Record whether the LWP
8460 stopped for a software breakpoint or hardware breakpoint.
8461 (thread_still_has_status_pending_p): New function.
8462 (status_pending_p_callback): Use
8463 thread_still_has_status_pending_p. If the event is no longer
8464 interesting, resume the LWP.
8465 (handle_tracepoints): Add assert.
8466 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
8467 (wstatus_maybe_breakpoint): New function.
8468 (cancel_breakpoint): Delete function.
8469 (check_stopped_by_watchpoint): New function, factored out from
8470 linux_low_filter_event.
8471 (lp_status_maybe_breakpoint): Delete function.
8472 (linux_low_filter_event): Remove filter_ptid argument.
8473 Leave thread group exits pending here. Store the LWP's stop PC.
8474 Always leave events pending.
8475 (linux_wait_for_event_filtered): Pull all events out of the
8476 kernel, and leave them all pending.
8477 (count_events_callback, select_event_lwp_callback): Consider all
8479 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
8480 (select_event_lwp): Only give preference to the stepping LWP in
8481 all-stop mode. Adjust comments.
8482 (ignore_event): New function.
8483 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
8484 references to cancel_breakpoints. Adjust to renames. Also give
8485 equal priority to all LWPs that have had events in non-stop mode.
8486 If reporting a software breakpoint event, unadjust the LWP's PC.
8487 (linux_wait): If linux_wait_1 returned an ignored event, retry.
8488 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
8490 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
8491 (resume_status_pending_p): Use thread_still_has_status_pending_p.
8492 (linux_stopped_by_watchpoint): Adjust.
8493 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
8494 * linux-low.h (enum lwp_stop_reason): New.
8495 (struct lwp_info) <stop_pc>: Adjust comment.
8496 <stopped_by_watchpoint>: Delete field.
8497 <stop_reason>: New field.
8498 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
8499 * mem-break.c (software_breakpoint_inserted_here)
8500 (hardware_breakpoint_inserted_here): New function.
8501 * mem-break.h (software_breakpoint_inserted_here)
8502 (hardware_breakpoint_inserted_here): Declare.
8503 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
8504 (cancel_breakpoints): Delete.
8505 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
8506 (upload_fast_traceframes): Remove references to
8509 2015-01-09 Pedro Alves <palves@redhat.com>
8511 * thread-db.c (find_new_threads_callback): Ignore thread if the
8512 kernel thread ID is -1.
8514 2015-01-09 Pedro Alves <palves@redhat.com>
8516 * linux-low.c (linux_attach_fail_reason_string): Move to
8517 nat/linux-ptrace.c, and rename.
8518 (linux_attach_lwp): Update comment.
8519 (attach_proc_task_lwp_callback): New function.
8520 (linux_attach): Adjust to rename and use
8521 linux_proc_attach_tgid_threads.
8522 (linux_attach_fail_reason_string): Delete declaration.
8524 2015-01-01 Joel Brobecker <brobecker@adacore.com>
8526 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
8527 * server.c (gdbserver_version): Likewise.
8529 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
8531 * remote-utils.c: Include ctype.h.
8532 (input_interrupt): Explicitly handle the case when the char
8533 received is the NUL byte. Improve the printing of non-ASCII
8536 2014-12-16 Joel Brobecker <brobecker@adacore.com>
8538 * linux-low.c (linux_low_filter_event): Update call to
8539 linux_enable_event_reporting following the addition of
8540 a new parameter to that function.
8542 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
8545 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
8546 (AARCH64_FPCR_REGNO): Likewise.
8547 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
8548 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
8549 (aarch64_store_fpregset): Likewise.
8551 2014-12-15 Joel Brobecker <brobecker@adacore.com>
8553 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
8554 Remove FIXME comment about assumption about N.
8556 2014-12-13 Joel Brobecker <brobecker@adacore.com>
8558 * configure.ac: If large-file support is disabled in GDBserver,
8559 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
8560 * configure: Regenerate.
8562 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
8564 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
8565 warning upon ENODATA from ptrace.
8566 * linux-s390-low.c (s390_store_tdb): New.
8567 (s390_regsets): Add regset for NT_S390_TDB.
8569 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
8571 * linux-low.c (regsets_store_inferior_registers): Skip regsets
8572 without a fill_function.
8573 * linux-s390-low.c (s390_fill_last_break): Remove.
8574 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
8575 (s390_arch_setup): Use regset's size instead of fill_function for
8578 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
8580 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
8581 the regset's store function when ptrace returned an error.
8582 * regcache.c (get_thread_regcache): Invalidate register cache
8583 before fetching inferior's registers.
8585 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
8587 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
8588 while-loop as for-loop.
8589 (regsets_store_inferior_registers): Likewise.
8591 2014-11-28 Yao Qi <yao@codesourcery.com>
8593 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
8594 * config.in, configure: Re-generate.
8595 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
8598 2014-11-21 Yao Qi <yao@codesourcery.com>
8600 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
8601 (AC_CHECK_HEADERS): Remove malloc.h.
8602 * configure: Re-generated.
8603 * config.in: Re-generated.
8604 * server.h: Don't include alloca.h and malloc.h.
8605 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
8606 Don't include malloc.h.
8608 2014-11-17 Joel Brobecker <brobecker@adacore.com>
8610 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
8611 corresponding ERRNO check in same block.
8613 2014-11-12 Pedro Alves <palves@redhat.com>
8615 * server.c (cont_thread): Update comment.
8616 (start_inferior, attach_inferior): No longer clear cont_thread.
8617 (handle_v_cont): No longer set cont_thread.
8618 (captured_main): Clear cont_thread each time a GDB connects.
8620 2014-11-12 Pedro Alves <palves@redhat.com>
8622 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
8623 thread, and don't resume all threads if the Hc thread has exited.
8625 2014-11-12 Pedro Alves <palves@redhat.com>
8627 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
8628 the process group instead of to a specific LWP.
8630 2014-10-15 Pedro Alves <palves@redhat.com>
8633 * win32-arm-low.c (arm_set_thread_context): Remove current_event
8635 (arm_set_thread_context): Delete.
8636 (the_low_target): Adjust.
8637 * win32-i386-low.c (debug_registers_changed)
8638 (debug_registers_used): Delete.
8639 (update_debug_registers_callback): New function.
8640 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
8641 needing to update their debug registers.
8642 (win32_get_current_dr): New function.
8643 (x86_dr_low_get_addr, x86_dr_low_get_control)
8644 (x86_dr_low_get_status): Fetch the debug register from the thread
8646 (i386_initial_stuff): Adjust.
8647 (i386_get_thread_context): Remove current_event parameter. Don't
8648 clear debug_registers_changed nor copy DR values to
8650 (i386_set_thread_context): Delete.
8651 (i386_prepare_to_resume): New function.
8652 (i386_thread_added): Mark the thread as needing to update irs
8654 (the_low_target): Remove i386_set_thread_context and install
8655 i386_prepare_to_resume.
8656 * win32-low.c (win32_get_thread_context): Adjust.
8657 (win32_set_thread_context): Use SetThreadContext
8659 (win32_prepare_to_resume): New function.
8660 (win32_require_context): New function, factored out from ...
8661 (thread_rec): ... this.
8662 (continue_one_thread): Call win32_prepare_to_resume on each thread
8663 we're about to continue.
8664 (win32_resume): Call win32_prepare_to_resume on the event thread.
8665 * win32-low.h (struct win32_thread_info)
8666 <debug_registers_changed>: New field.
8667 (struct win32_target_ops): Change prototype of set_thread_context,
8668 delete set_thread_context and add prepare_to_resume.
8669 (win32_require_context): New declaration.
8671 2014-10-08 Gary Benson <gbenson@redhat.com>
8673 * server.h: Do not include common-exceptions.h.
8675 2014-10-08 Gary Benson <gbenson@redhat.com>
8677 * server.h: Do not include cleanups.h.
8679 2014-09-30 James Hogan <james.hogan@imgtec.com>
8681 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
8684 2014-09-23 Yao Qi <yao@codesourcery.com>
8686 * linux-low.c (lp_status_maybe_breakpoint): New function.
8687 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
8688 (count_events_callback): Likewise.
8689 (select_event_lwp_callback): Likewise.
8690 (cancel_breakpoints_callback): Likewise.
8692 2014-09-19 Don Breazeal <donb@codesourcery.com>
8694 * linux-low.c (handle_extended_wait): Call
8695 linux_ptrace_get_extended_event.
8696 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
8697 linux_is_extended_waitstatus.
8699 2014-09-16 Joel Brobecker <brobecker@adacore.com>
8701 * Makefile.in (CPPFLAGS): Define.
8702 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
8703 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
8705 2014-09-16 Gary Benson <gbenson@redhat.com>
8707 * inferiors.h (current_inferior): Renamed as...
8708 (current_thread): New variable. All uses updated.
8709 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
8710 (maybe_move_out_of_jump_pad): Likewise.
8711 (cancel_breakpoint): Likewise.
8712 (linux_low_filter_event): Likewise.
8713 (wait_for_sigstop): Likewise.
8714 (linux_resume_one_lwp): Likewise.
8715 (need_step_over_p): Likewise.
8716 (start_step_over): Likewise.
8717 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
8718 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
8719 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
8720 and save_inferior as saved_thread.
8721 * regcache.c (get_thread_regcache): Renamed saved_inferior as
8723 (regcache_invalidate_thread): Likewise.
8724 * remote-utils.c (prepare_resume_reply): Likewise.
8725 * thread-db.c (thread_db_get_tls_address): Likewise.
8726 (disable_thread_event_reporting): Likewise.
8727 (remove_thread_event_breakpoints): Likewise.
8728 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
8730 * target.h (set_desired_inferior): Renamed as...
8731 (set_desired_thread): New declaration. All uses updated.
8732 * server.c (myresume): Updated comment to reference thread instead
8734 (handle_serial_event): Likewise.
8735 (handle_target_event): Likewise.
8737 2014-09-12 Tom Tromey <tromey@redhat.com>
8738 Gary Benson <gbenson@redhat.com>
8740 * regcache.h: Include common-regcache.h.
8741 (regcache_read_pc): Don't declare.
8742 * regcache.c (get_thread_regcache_for_ptid): New function.
8744 2014-09-11 Tom Tromey <tromey@redhat.com>
8745 Gary Benson <gbenson@redhat.com>
8747 * symbol.c: New file.
8748 * Makefile.in (SFILES): Add symbol.c.
8749 (OBS): Add symbol.o.
8751 2014-09-11 Gary Benson <gbenson@redhat.com>
8753 * target.c (target_stop_ptid, target_continue_ptid): New
8756 2014-09-11 Tom Tromey <tromey@redhat.com>
8757 Gary Benson <gbenson@redhat.com>
8759 * target.h: Include target/target.h.
8760 * target.c (target_read_memory, target_read_uint32)
8761 (target_write_memory): New functions.
8763 2014-09-11 Gary Benson <gbenson@redhat.com>
8765 * server.h (debug_hw_points): Don't declare.
8766 * server.c (debug_hw_points): Don't define. Replace all uses
8767 with show_debug_regs.
8768 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
8769 all uses with show_debug_regs.
8771 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
8773 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
8774 endianness into account.
8775 (ppc_supply_ptrace_register): Likewise.
8777 2014-09-03 James Hogan <james.hogan@imgtec.com>
8779 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
8780 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
8782 2014-09-03 Gary Benson <gbenson@redhat.com>
8784 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
8785 ALL_DEBUG_ADDRESS_REGISTERS.
8787 2014-09-02 Gary Benson <gbenson@redhat.com>
8789 * i386-low.h: Renamed as...
8790 * x86-low.h: New file. All type, function and variable name
8791 prefixes changed from "i386_" to "x86_". All references updated.
8792 * i386-low.c: Renamed as...
8793 * x86-low.c: New file. All type, function and variable name
8794 prefixes changed from "i386_" to "x86_". All references updated.
8796 2014-09-02 Gary Benson <gbenson@redhat.com>
8798 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
8799 (x86_linux_new_thread): Likewise.
8801 2014-08-29 Gary Benson <gbenson@redhat.com>
8803 * server.h (setjmp.h): Do not include.
8804 (toplevel): Do not declare.
8805 (common-exceptions.h): Include.
8806 (cleanups.h): Likewise.
8807 * server.c (toplevel): Do not define.
8808 (exit_code): New static global.
8809 (detach_or_kill_for_exit_cleanup): New function.
8810 (main): New function. Original main renamed to...
8811 (captured_main): New function.
8812 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
8814 2014-08-29 Gary Benson <gbenson@redhat.com>
8816 * Makefile.in (SFILES): Add common/common-exceptions.c.
8817 (OBS): Add common-exceptions.o.
8818 (common-exceptions.o): New rule.
8819 * utils.c (prepare_to_throw_exception): New function.
8821 2014-08-29 Gary Benson <gbenson@redhat.com>
8823 * config.in: Regenerate.
8824 * configure: Likewise.
8826 2014-08-29 Gary Benson <gbenson@redhat.com>
8828 * Makefile.in (SFILES): Add common/cleanups.c.
8830 (cleanups.o): New rule.
8832 2014-08-29 Gary Benson <gbenson@redhat.com>
8834 * utils.c (internal_vwarning): New function.
8836 2014-08-28 Gary Benson <gbenson@redhat.com>
8838 * utils.h (fatal): Remove declaration.
8839 * utils.c (fatal): Remove function.
8841 2014-08-28 Gary Benson <gbenson@redhat.com>
8843 * tracepoint.c (gdb_agent_init): Replace fatal with
8845 (initialize_tracepoint): Likewise.
8847 2014-08-28 Gary Benson <gbenson@redhat.com>
8849 * remote-utils.c (remote_prepare): Replace fatal with error.
8851 2014-08-28 Gary Benson <gbenson@redhat.com>
8853 * linux-low.c (linux_async): Replace fatal with warning.
8855 (linux_start_non_stop): Return -1 if linux_async failed.
8857 2014-08-28 Gary Benson <gbenson@redhat.com>
8859 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
8861 (i386_dr_low_get_addr): Remove vague comment.
8862 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
8865 2014-08-28 Gary Benson <gbenson@redhat.com>
8867 * inferiors.c (get_thread_process): Replace check with gdb_assert.
8868 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
8870 (linux_resume_one_lwp): Likewise.
8871 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
8873 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
8874 with internal_error.
8875 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
8876 (init_register_cache): Replace fatal with gdb_assert_not_reached.
8877 (find_register_by_name): Replace fatal with internal_error.
8878 (find_regno): Likewise.
8879 * tdesc.c (init_target_desc): Replace check with gdb_assert.
8880 * thread-db.c (thread_db_create_event): Likewise.
8881 (thread_db_load_search): Likewise.
8882 (try_thread_db_load_1): Likewise.
8883 * tracepoint.c (get_jump_space_head): Replace fatal with
8885 (claim_trampoline_space): Likewise.
8886 (have_fast_tracepoint_trampoline_buffer): Likewise.
8887 (cmd_qtstart): Likewise.
8888 (stop_tracing): Likewise.
8889 (fast_tracepoint_collecting): Likewise.
8890 (target_malloc): Likewise.
8891 (download_tracepoint): Likewise.
8892 (download_trace_state_variables): Replace check with gdb_assert.
8893 (upload_fast_traceframes): Replace fatal with internal_error.
8895 2014-08-19 Tom Tromey <tromey@redhat.com>
8896 Gary Benson <gbenson@redhat.com>
8898 * Makefile.in (SFILES): Add common/common-debug.c.
8899 (OBS): Add common-debug.o.
8900 (common-debug.o): New rule.
8901 * debug.h (debug_printf): Don't declare.
8902 * debug.c (debug_printf): Renamed and rewritten as...
8903 (debug_vprintf): New function.
8905 2014-08-19 Gary Benson <gbenson@redhat.com>
8907 * utils.h: Do not include print-utils.h.
8909 2014-08-19 Tom Tromey <tromey@redhat.com>
8910 Gary Benson <gbenson@redhat.com>
8912 * server.h: Add static assertion.
8913 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
8915 2014-08-19 Tom Tromey <tromey@redhat.com>
8916 Gary Benson <gbenson@redhat.com>
8918 * Makefile.in (SFILES): Add common/errors.c.
8919 (OBS): Add errors.o.
8920 (IPA_OBS): Add errors-ipa.o.
8921 (errors.o): New rule.
8922 (errors-ipa.o): Likewise.
8923 * utils.h (perror_with_name, error, warning): Don't declare.
8924 * utils.c (warning): Renamed and rewritten as...
8925 (vwarning): New function.
8926 (error): Renamed and rewritten as...
8927 (verror): New function.
8928 (internal_error): Renamed and rewritten as...
8929 (internal_verror): New function.
8931 2014-08-07 Gary Benson <gbenson@redhat.com>
8933 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
8934 * configure: Regenerate.
8935 * config.in: Likewise.
8936 * server.h: Do not include errno.h.
8937 * event-loop.c: Likewise.
8938 * hostio-errno.c: Likewise.
8939 * linux-low.c: Likewise.
8940 * remote-utils.c: Likewise.
8941 * spu-low.c: Likewise.
8942 * utils.c: Likewise.
8943 * gdbreplay.c: Unconditionally include errno.h.
8945 2014-08-07 Gary Benson <gbenson@redhat.com>
8947 * server.h: Do not include string.h.
8948 * event-loop.c: Likewise.
8949 * linux-low.c: Likewise.
8950 * regcache.c: Likewise.
8951 * remote-utils.c: Likewise.
8952 * spu-low.c: Likewise.
8953 * utils.c: Likewise.
8955 2014-08-07 Gary Benson <gbenson@redhat.com>
8957 * server.h: Do not include gdb_assert.h.
8959 2014-08-07 Gary Benson <gbenson@redhat.com>
8961 * server.h: Do not include common-utils.h.
8963 2014-08-07 Gary Benson <gbenson@redhat.com>
8965 * server.h: Do not include ptid.h.
8966 * notif.h: Likewise.
8968 2014-08-07 Gary Benson <gbenson@redhat.com>
8970 * server.h: Do not include gdb_locale.h.
8972 2014-08-07 Gary Benson <gbenson@redhat.com>
8974 * server.h: Do not include gdb/signals.h.
8975 * win32-low.c: Likewise.
8977 2014-08-07 Gary Benson <gbenson@redhat.com>
8979 * server.h: Do not include pathmax.h.
8981 2014-08-07 Gary Benson <gbenson@redhat.com>
8983 * server.h: Do not include libiberty.h.
8984 * linux-bfin-low.c: Likewise.
8986 2014-08-07 Gary Benson <gbenson@redhat.com>
8988 * server.h: Do not include ansidecl.h.
8990 2014-08-07 Gary Benson <gbenson@redhat.com>
8992 * linux-x86-low.c: Do not include stddef.h.
8993 * lynx-ppc-low.c: Likewise.
8994 * tracepoint.c: Likewise.
8996 2014-08-07 Gary Benson <gbenson@redhat.com>
8998 * server.h: Do not include stdarg.h.
8999 * nto-low.c: Likewise.
9001 2014-08-07 Gary Benson <gbenson@redhat.com>
9003 * server.h: Do not include stdlib.h.
9004 * inferiors.c: Likewise.
9005 * linux-low.c: Likewise.
9006 * regcache.c: Likewise.
9007 * spu-low.c: Likewise.
9008 * tracepoint.c: Likewise.
9009 * utils.c: Likewise.
9011 2014-08-07 Gary Benson <gbenson@redhat.com>
9013 * server.h: Do not include stdio.h.
9014 * linux-low.c: Likewise.
9015 * remote-utils.c: Likewise.
9016 * spu-low.c: Likewise.
9017 * utils.c: Likewise.
9018 * wincecompat.c: Likewise.
9020 2014-08-06 Gary Benson <gbenson@redhat.com>
9022 * regcache.c (init_register_cache): Move conditionals inside if.
9024 2014-08-06 Gary Benson <gbenson@redhat.com>
9026 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
9028 2014-07-31 Gary Benson <gbenson@redhat.com>
9030 * ax.h: Do not include server.h.
9031 * gdbthread.h: Likewise.
9032 * lynx-low.h: Likewise.
9033 * notif.h: Likewise.
9035 2014-07-30 Gary Benson <gbenson@redhat.com>
9037 * server.h: Include common-defs.h.
9038 Do not include config.h or build-gnulib-gdbserver/config.h.
9040 2014-07-30 Gary Benson <gbenson@redhat.com>
9042 * hostio-errno.c: Move server.h to top of includes list.
9043 * inferiors.c: Likewise.
9044 * linux-x86-low.c: Likewise.
9045 * notif.c: Include server.h.
9047 2014-07-24 Tom Tromey <tromey@redhat.com>
9048 Gary Benson <gbenson@redhat.com>
9050 * server.h (CORE_ADDR): Now unsigned.
9052 2014-07-16 Pedro Alves <palves@redhat.com>
9054 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
9056 2014-07-15 Pedro Alves <palves@redhat.com>
9058 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
9061 2014-07-11 Pedro Alves <palves@redhat.com>
9063 * linux-low.c (kill_wait_lwp): New function, based on
9064 kill_one_lwp_callback, but use my_waitpid directly.
9065 (kill_one_lwp_callback, linux_kill): Use it.
9067 2014-06-23 Pedro Alves <palves@redhat.com>
9069 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
9070 before setting DR0..DR3.
9072 2014-06-20 Gary Benson <gbenson@redhat.com>
9074 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
9075 * configure: Regenerated.
9076 * config.in: Likewise.
9078 2014-06-20 Gary Benson <gbenson@redhat.com>
9080 * Makefile.in (SFILES): Update locations for files moved
9082 (object file files): Reordered.
9084 2014-06-20 Gary Benson <gbenson@redhat.com>
9086 * i386-low.h (i386_dr_low_can_set_addr): Removed.
9087 (i386_dr_low_set_addr): Likewise.
9088 (i386_dr_low_get_addr): Likewise.
9089 (i386_dr_low_can_set_control): Likewise.
9090 (i386_dr_low_set_control): Likewise.
9091 (i386_dr_low_get_control): Likewise.
9092 (i386_dr_low_get_status): Likewise.
9093 (i386_get_debug_register_length): Likewise.
9094 * linux-x86-low.c (i386_dr_low_set_addr):
9095 Changed signature. Made static.
9096 (i386_dr_low_get_addr): Likewise.
9097 (i386_dr_low_set_control): Likewise.
9098 (i386_dr_low_get_control): Likewise.
9099 (i386_dr_low_get_status): Likewise.
9100 (i386_dr_low): New global variable.
9101 * win32-i386-low.c (i386_dr_low_set_addr):
9102 Changed signature. Made static.
9103 (i386_dr_low_get_addr): Likewise.
9104 (i386_dr_low_set_control): Likewise.
9105 (i386_dr_low_get_control): Likewise.
9106 (i386_dr_low_get_status): Likewise.
9107 (i386_dr_low): New global variable.
9109 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
9111 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
9112 * Makefile.in (AR, AR_FLAGS): Define.
9113 * configure: Regenerate.
9115 2014-06-19 Gary Benson <gbenson@redhat.com>
9117 * Makefile.in (i386-dregs.o): New rule.
9118 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
9119 * i386-low.c (target.h): Remove include.
9120 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
9121 (DR_CONTROL_SHIFT): Likewise.
9122 (DR_CONTROL_SIZE): Likewise.
9123 (DR_RW_EXECUTE): Likewise.
9124 (DR_RW_WRITE): Likewise.
9125 (DR_RW_READ): Likewise.
9126 (DR_RW_IORW): Likewise.
9127 (DR_LEN_1): Likewise.
9128 (DR_LEN_2): Likewise.
9129 (DR_LEN_4): Likewise.
9130 (DR_LEN_8): Likewise.
9131 (DR_LOCAL_ENABLE_SHIFT): Likewise.
9132 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
9133 (DR_ENABLE_SIZE): Likewise.
9134 (DR_LOCAL_SLOWDOWN): Likewise.
9135 (DR_GLOBAL_SLOWDOWN): Likewise.
9136 (DR_CONTROL_RESERVED): Likewise.
9137 (I386_DR_CONTROL_MASK): Likewise.
9138 (I386_DR_VACANT): Likewise.
9139 (I386_DR_LOCAL_ENABLE): Likewise.
9140 (I386_DR_GLOBAL_ENABLE): Likewise.
9141 (I386_DR_DISABLE): Likewise.
9142 (I386_DR_SET_RW_LEN): Likewise.
9143 (I386_DR_GET_RW_LEN): Likewise.
9144 (I386_DR_WATCH_HIT): Likewise.
9145 (i386_wp_op_t): Likewise.
9146 (i386_show_dr): Likewise.
9147 (i386_length_and_rw_bits): Likewise.
9148 (i386_insert_aligned_watchpoint): Likewise.
9149 (i386_remove_aligned_watchpoint): Likewise.
9150 (i386_handle_nonaligned_watchpoint): Likewise.
9151 i386_update_inferior_debug_regs(): Likewise.
9152 (i386_dr_insert_watchpoint): Likewise.
9153 (i386_dr_remove_watchpoint): Likewise.
9154 (i386_dr_region_ok_for_watchpoint): Likewise.
9155 (i386_dr_stopped_data_address): Likewise.
9156 (i386_dr_stopped_by_watchpoint): Likewise.
9158 2014-06-19 Gary Benson <gbenson@redhat.com>
9160 * i386-low.c (i386_dr_show): Renamed to
9161 i386_show_dr and made static. All uses updated.
9162 (i386_dr_length_and_rw_bits): Renamed to
9163 i386_length_and_rw_bits and made static.
9165 (i386_dr_insert_aligned_watchpoint): Renamed to
9166 i386_insert_aligned_watchpoint and made static.
9168 (i386_dr_remove_aligned_watchpoint): Renamed to
9169 i386_remove_aligned_watchpoint and made static.
9171 (i386_dr_update_inferior_debug_regs): Renamed to
9172 i386_update_inferior_debug_regs and made static.
9175 2014-06-18 Gary Benson <gbenson@redhat.com>
9177 * i386-low.h (i386_dr_low_can_set_addr): New macro.
9178 (i386_dr_low_can_set_control): Likewise.
9179 (i386_get_debug_register_length): Likewise.
9180 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
9181 (i386_dr_low_can_set_control): Likewise.
9182 (i386_get_debug_register_length): Likewise.
9184 2014-06-17 Gary Benson <gbenson@redhat.com>
9186 * i386-low.h (i386-dregs.h): New include.
9187 (DR_FIRSTADDR): Now in i386-dregs.h.
9188 (DR_LASTADDR): Likewise.
9189 (DR_NADDR): Likewise.
9190 (DR_STATUS): Likewise.
9191 (DR_CONTROL): Likewise.
9192 (i386_debug_reg_state): Likewise.
9193 (i386_dr_insert_watchpoint): Likewise.
9194 (i386_dr_remove_watchpoint): Likewise.
9195 (i386_dr_region_ok_for_watchpoint): Likewise.
9196 (i386_dr_stopped_data_address): Likewise.
9197 (i386_dr_stopped_by_watchpoint): Likewise.
9198 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
9200 2014-06-18 Gary Benson <gbenson@redhat.com>
9202 * i386-low.h (i386_low_insert_watchpoint): Renamed to
9203 i386_dr_insert_watchpoint.
9204 (i386_low_remove_watchpoint): Renamed to
9205 i386_dr_remove_watchpoint.
9206 (i386_low_region_ok_for_watchpoint): Renamed to
9207 i386_dr_region_ok_for_watchpoint.
9208 (i386_low_stopped_data_address): Renamed to
9209 i386_dr_stopped_data_address.
9210 (i386_low_stopped_by_watchpoint): Renamed to
9211 i386_dr_stopped_by_watchpoint.
9212 * i386-low.c (i386_show_dr): Renamed to
9213 i386_dr_show and made nonstatic. All uses updated.
9214 (i386_length_and_rw_bits): Renamed to
9215 i386_dr_length_and_rw_bits and made nonstatic.
9217 (i386_insert_aligned_watchpoint): Renamed to
9218 i386_dr_insert_aligned_watchpoint and made nonstatic.
9220 (i386_remove_aligned_watchpoint): Renamed to
9221 i386_dr_remove_aligned_watchpoint and made nonstatic.
9223 (i386_update_inferior_debug_regs): Renamed to
9224 i386_dr_update_inferior_debug_regs and made nonstatic.
9226 (i386_low_insert_watchpoint): Renamed to
9227 i386_dr_insert_watchpoint. All uses updated.
9228 (i386_low_remove_watchpoint): Renamed to
9229 i386_dr_remove_watchpoint. All uses updated.
9230 (i386_low_region_ok_for_watchpoint): Renamed to
9231 i386_dr_region_ok_for_watchpoint. All uses updated.
9232 (i386_low_stopped_data_address): Renamed to
9233 i386_dr_stopped_data_address. All uses updated.
9234 (i386_low_stopped_by_watchpoint): Renamed to
9235 i386_dr_stopped_by_watchpoint. All uses updated.
9237 2014-06-18 Gary Benson <gbenson@redhat.com>
9239 * i386-low.c (i386_dr_low_can_set_addr): New macro.
9240 (i386_dr_low_can_set_control): Likewise.
9241 (i386_insert_aligned_watchpoint): New check.
9243 2014-06-18 Gary Benson <gbenson@redhat.com>
9245 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
9248 2014-06-18 Gary Benson <gbenson@redhat.com>
9250 * i386-low.c (i386_length_and_rw_bits): Use internal_error
9251 instead of fatal and error.
9252 (i386_handle_nonaligned_watchpoint): Likewise.
9254 2014-06-18 Gary Benson <gbenson@redhat.com>
9256 * i386-low.c (i386_get_debug_register_length): New macro.
9257 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
9258 (i386_show_dr): Use debug_printf instead of fprintf. Use
9259 phex to format values.
9261 2014-06-18 Gary Benson <gbenson@redhat.com>
9263 * i386-low.h: Comment changes.
9264 * i386-low.c: Likewise.
9266 2014-06-18 Gary Benson <gbenson@redhat.com>
9268 * i386-low.c: Whitespace changes.
9270 2014-06-12 Tom Tromey <tromey@redhat.com>
9272 * utils.c (freeargv): Remove.
9274 2014-06-12 Tom Tromey <tromey@redhat.com>
9276 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
9277 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
9278 (parse_debug_format_options): Likewise.
9279 (gdbserver_usage): Likewise.
9280 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
9281 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
9282 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
9284 ($(LIBGNU)): Depend on libiberty.
9285 (all-lib): Recurse into all subdirs.
9286 (install-only): Invoke "install" target in subdirs.
9287 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
9289 * configure: Rebuild.
9290 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
9291 for vasprintf, vsnprintf, or gettimeofday.
9292 * configure.srv: Don't add safe-ctype.o or lbasename.o to
9295 2014-06-05 Joel Brobecker <brobecker@adacore.com>
9297 * development.sh: Delete.
9298 * Makefile.in (config.status): Adjust dependency on development.sh.
9299 * configure.ac: Adjust development.sh source call.
9300 * configure: Regenerate.
9302 2014-06-02 Pedro Alves <palves@redhat.com>
9304 * ax.c (gdb_free_agent_expr): New function.
9305 * ax.h (gdb_free_agent_expr): New declaration.
9306 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
9308 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
9310 (clear_breakpoint_conditions_and_commands): New function.
9311 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
9312 (clear_breakpoint_conditions_and_commands): New declaration.
9314 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
9316 * linux-aarch64-low.c (asm/ptrace.h): Include.
9318 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
9320 Fix TLS access for -static -pthread.
9321 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
9322 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
9323 (thread_db_load_search, try_thread_db_load_1): Initialize it.
9325 2014-05-20 Pedro Alves <palves@redhat.com>
9327 * linux-aarch64-low.c (aarch64_insert_point)
9328 (aarch64_remove_point): No longer check whether the type is
9329 supported here. Adjust to new interface.
9330 (the_low_target): Install aarch64_supports_z_point_type as
9331 supports_z_point_type method.
9332 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
9333 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
9334 instead of a Z packet char. Adjust.
9335 (arm_supports_z_point_type): New function.
9336 (arm_insert_point, arm_remove_point): Adjust to new interface.
9337 (the_low_target): Install arm_supports_z_point_type.
9338 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
9339 (cris_insert_point, cris_remove_point): Adjust to new interface.
9340 Don't check whether the type is supported here.
9341 (the_low_target): Install cris_supports_z_point_type.
9342 * linux-low.c (linux_supports_z_point_type): New function.
9343 (linux_insert_point, linux_remove_point): Adjust to new interface.
9344 * linux-low.h (struct linux_target_ops) <insert_point,
9345 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
9346 raw_breakpoint pointer parameter.
9347 <supports_z_point_type>: New method.
9348 * linux-mips-low.c (mips_supports_z_point_type): New function.
9349 (mips_insert_point, mips_remove_point): Adjust to new interface.
9350 Use mips_supports_z_point_type.
9351 (the_low_target): Install mips_supports_z_point_type.
9352 * linux-ppc-low.c (the_low_target): Install NULL as
9353 supports_z_point_type method.
9354 * linux-s390-low.c (the_low_target): Install NULL as
9355 supports_z_point_type method.
9356 * linux-sparc-low.c (the_low_target): Install NULL as
9357 supports_z_point_type method.
9358 * linux-x86-low.c (x86_supports_z_point_type): New function.
9359 (x86_insert_point): Adjust to new insert_point interface. Use
9360 insert_memory_breakpoint. Adjust to new
9361 i386_low_insert_watchpoint interface.
9362 (x86_remove_point): Adjust to remove_point interface. Use
9363 remove_memory_breakpoint. Adjust to new
9364 i386_low_remove_watchpoint interface.
9365 (the_low_target): Install x86_supports_z_point_type.
9366 * lynx-low.c (lynx_target_ops): Install NULL as
9367 supports_z_point_type callback.
9368 * nto-low.c (nto_supports_z_point_type): New.
9369 (nto_insert_point, nto_remove_point): Adjust to new interface.
9370 (nto_target_ops): Install nto_supports_z_point_type.
9371 * mem-break.c: Adjust intro comment.
9372 (struct raw_breakpoint) <raw_type, size>: New fields.
9373 <inserted>: Update comment.
9374 <shlib_disabled>: Delete field.
9375 (enum bkpt_type) <gdb_breakpoint>: Delete value.
9376 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
9377 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
9378 (raw_bkpt_type_to_target_hw_bp_type): New function.
9379 (find_enabled_raw_code_breakpoint_at): New function.
9380 (find_raw_breakpoint_at): New type and size parameters. Use them.
9381 (insert_memory_breakpoint): New function, based off
9382 set_raw_breakpoint_at.
9383 (remove_memory_breakpoint): New function.
9384 (set_raw_breakpoint_at): Reimplement.
9385 (set_breakpoint): New, based on set_breakpoint_at.
9386 (set_breakpoint_at): Reimplement.
9387 (delete_raw_breakpoint): Go through the_target->remove_point
9388 instead of assuming memory breakpoints.
9389 (find_gdb_breakpoint_at): Delete.
9390 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
9391 (find_gdb_breakpoint): New function.
9392 (set_gdb_breakpoint_at): Delete.
9393 (z_type_supported): New function.
9394 (set_gdb_breakpoint_1): New function, loosely based off
9395 set_gdb_breakpoint_at.
9396 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
9397 (delete_gdb_breakpoint_at): Delete.
9398 (delete_gdb_breakpoint_1): New function, loosely based off
9399 delete_gdb_breakpoint_at.
9400 (delete_gdb_breakpoint): New function.
9401 (clear_gdb_breakpoint_conditions): Rename to ...
9402 (clear_breakpoint_conditions): ... this. Don't handle a NULL
9404 (add_condition_to_breakpoint): Make static.
9405 (add_breakpoint_condition): Take a struct breakpoint pointer
9406 instead of an address. Adjust.
9407 (gdb_condition_true_at_breakpoint): Rename to ...
9408 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
9410 (gdb_condition_true_at_breakpoint): Reimplement.
9411 (add_breakpoint_commands): Take a struct breakpoint pointer
9412 instead of an address. Adjust.
9413 (gdb_no_commands_at_breakpoint): Rename to ...
9414 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
9415 parameter. Return true if no breakpoint was found. Change debug
9417 (gdb_no_commands_at_breakpoint): Reimplement.
9418 (run_breakpoint_commands): Rename to ...
9419 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
9420 and change return type to boolean.
9421 (run_breakpoint_commands): New function.
9422 (gdb_breakpoint_here): Also check for Z1 breakpoints.
9423 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
9424 breakpoint. Go through the_target->remove_point instead of
9425 assuming memory breakpoint.
9426 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
9427 software and hardware breakpoints.
9428 (reinsert_raw_breakpoint): Go through the_target->insert_point
9429 instead of assuming memory breakpoint.
9430 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
9431 software and hardware breakpoints.
9432 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
9433 Check both software and hardware breakpoints.
9434 (validate_inserted_breakpoint): Assert the breakpoint is a
9435 software breakpoint. Set the inserted flag to -1 instead of
9436 setting shlib_disabled.
9437 (delete_disabled_breakpoints): Adjust.
9438 (validate_breakpoints): Only validate software breakpoints.
9439 Adjust to inserted flag change.
9440 (check_mem_read, check_mem_write): Skip breakpoint types other
9441 than software breakpoints. Adjust to inserted flag change.
9442 * mem-break.h (enum raw_bkpt_type): New enum.
9443 (raw_breakpoint, struct process_info): Forward declare.
9444 (Z_packet_to_target_hw_bp_type): Delete declaration.
9445 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
9446 (set_gdb_breakpoint, delete_gdb_breakpoint)
9447 (clear_breakpoint_conditions): New declarations.
9448 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
9449 (breakpoint_inserted_here): Update comment.
9450 (add_breakpoint_condition, add_breakpoint_commands): Replace
9451 address parameter with a breakpoint pointer parameter.
9452 (gdb_breakpoint_here): Update comment.
9453 (delete_gdb_breakpoint_at): Delete.
9454 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
9455 * server.c (process_point_options): Take a struct breakpoint
9456 pointer instead of an address. Adjust.
9457 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
9458 delete_gdb_breakpoint.
9459 * spu-low.c (spu_target_ops): Install NULL as
9460 supports_z_point_type method.
9461 * target.h: Include mem-break.h.
9462 (struct target_ops) <prepare_to_access_memory>: Update comment.
9463 <supports_z_point_type>: New field.
9464 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
9465 instead of a char. Also take a raw breakpoint pointer.
9466 * win32-arm-low.c (the_low_target): Install NULL as
9467 supports_z_point_type.
9468 * win32-i386-low.c (i386_supports_z_point_type): New function.
9469 (i386_insert_point, i386_remove_point): Adjust to new interface.
9470 (the_low_target): Install i386_supports_z_point_type.
9471 * win32-low.c (win32_supports_z_point_type): New function.
9472 (win32_insert_point, win32_remove_point): Adjust to new interface.
9473 (win32_target_ops): Install win32_supports_z_point_type.
9474 * win32-low.h (struct win32_target_ops):
9475 <supports_z_point_type>: New method.
9476 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
9477 instead of a char. Also take a raw breakpoint pointer.
9479 2014-05-20 Pedro Alves <palves@redhat.com>
9481 * mem-break.h: Include break-common.h.
9482 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
9483 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
9484 (Z_packet_to_target_hw_bp_type): New declaration.
9485 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
9486 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
9487 (Z_PACKET_ACCESS_WP): Delete macros.
9488 (Z_packet_to_hw_type): Delete function.
9489 * i386-low.h: Don't include break-common.h here.
9490 (Z_packet_to_hw_type): Delete declaration.
9491 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
9492 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
9493 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
9494 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
9495 * linux-aarch64-low.c: Don't include break-common.h here.
9496 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
9497 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
9498 (Z_packet_to_target_hw_bp_type): Delete function.
9499 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
9501 (mips_insert_point, mips_remove_point): Use
9502 Z_packet_to_target_hw_bp_type.
9504 2014-05-20 Pedro Alves <palves@redhat.com>
9506 * linux-aarch64-low.c: Include break-common.h.
9507 (enum target_point_type): Delete.
9508 (Z_packet_to_point_type): Rename to ...
9509 (Z_packet_to_target_hw_bp_type): ... this, and return a
9510 target_hw_bp_type instead.
9511 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
9512 instead of an enum target_point_type.
9513 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
9515 (aarch64_dr_state_insert_one_point)
9516 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
9517 (aarch64_handle_aligned_watchpoint)
9518 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
9519 Take an enum target_hw_bp_type instead of an enum
9521 (aarch64_supports_z_point_type): New function.
9522 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
9523 use Z_packet_to_target_hw_bp_type.
9525 2014-05-20 Joel Brobecker <brobecker@adacore.com>
9527 * configure.ac: Only use -Werror by default when DEVELOPMENT
9529 * configure: Regenerate.
9531 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
9533 Fix gdbserver qGetTLSAddr for x86_64 -m32.
9534 * linux-x86-low.c (X86_64_USER_REGS): New.
9535 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
9537 2014-04-28 Yao Qi <yao@codesourcery.com>
9539 * Makefile.in (i386-avx512.c): Fix the typo of generated file
9542 2014-04-25 Pedro Alves <palves@redhat.com>
9545 * linux-low.c (linux_attach_fail_reason_string): New function.
9546 (linux_attach_lwp): Delete.
9547 (linux_attach_lwp_1): Rename to ...
9548 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
9549 argument. Remove "initial" parameter. Return int instead of
9550 void. Don't error or warn here.
9551 (linux_attach): Adjust to call linux_attach_lwp. Call error on
9552 failure to attach to the tgid. Call warning when failing to
9554 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
9555 argument. Remove "initial" parameter. Return int instead of
9556 void. Don't error or warn here.
9557 (linux_attach_fail_reason_string): New declaration.
9558 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
9559 interface change. Use linux_attach_fail_reason_string.
9561 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
9562 Walfred Tedeschi <walfred.tedeschi@intel.com>
9564 * Makefile.in: Added rules to handle new files
9565 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
9566 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
9567 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
9568 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
9569 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
9570 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
9572 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
9573 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
9574 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
9575 i386/x32-avx512.xml.
9576 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
9577 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
9578 i386/x32-avx512-linux.xml.
9579 * i387-fp.c (num_avx512_k_registers): New constant for number
9581 (num_avx512_zmmh_low_registers): New constant for number of
9582 lower ZMM registers (0-15).
9583 (num_avx512_zmmh_high_registers): New constant for number of
9584 higher ZMM registers (16-31).
9585 (num_avx512_ymmh_registers): New contant for number of higher
9586 YMM registers (ymm16-31 added by avx521 on x86_64).
9587 (num_avx512_xmm_registers): New constant for number of higher
9588 XMM registers (xmm16-31 added by AVX512 on x86_64).
9589 (struct i387_xsave): Add space for AVX512 registers.
9590 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
9591 Add code to handle AVX512 registers.
9592 (i387_xsave_to_cache): Add code to handle AVX512 registers.
9593 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
9594 prototypei from generated file.
9595 (tdesc_amd64_avx512_linux): Likewise.
9596 (init_registers_x32_avx512_linux): Likewise.
9597 (tdesc_x32_avx512_linux): Likewise.
9598 (init_registers_i386_avx512_linux): Likewise.
9599 (tdesc_i386_avx512_linux): Likewise.
9600 (x86_64_regmap): Add AVX512 registers.
9601 (x86_linux_read_description): Add code to handle AVX512 XSTATE
9603 (initialize_low_arch): Add code to initialize AVX512 registers.
9605 2014-04-23 Pedro Alves <palves@redhat.com>
9607 * mem-break.c (find_gdb_breakpoint_at): Make static.
9608 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
9610 2014-04-23 Pedro Alves <palves@redhat.com>
9612 * i386-low.c: Don't include break-common.h here.
9613 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
9614 prototype to take target_hw_bp_type as argument instead of a Z
9616 * i386-low.h: Include break-common.h here.
9617 (Z_packet_to_hw_type): Declare.
9618 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
9620 * linux-x86-low.c (x86_insert_point): Convert the packet number to
9621 a target_hw_bp_type before calling i386_low_insert_watchpoint.
9622 (x86_remove_point): Convert the packet number to a
9623 target_hw_bp_type before calling i386_low_remove_watchpoint.
9624 * win32-i386-low.c (i386_insert_point): Convert the packet number
9625 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
9626 (i386_remove_point): Convert the packet number to a
9627 target_hw_bp_type before calling i386_low_remove_watchpoint.
9629 2014-04-23 Pedro Alves <palves@redhat.com>
9631 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
9633 2014-04-10 Pedro Alves <palves@redhat.com>
9635 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
9636 Check if the condition or command is NULL before checking if the
9637 breakpoint is known. On success, return true.
9638 * mem-break.h (add_breakpoint_condition): Document return.
9639 (add_breakpoint_commands): Add describing comment.
9640 * server.c (skip_to_semicolon): New function.
9641 (process_point_options): Use it.
9643 2014-04-09 Pedro Alves <palves@redhat.com>
9645 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
9648 2014-02-27 Pedro Alves <palves@redhat.com>
9651 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
9653 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
9655 (last_thread_of_process_p): Take a PID argument instead of a
9657 (linux_wait_for_lwp): Delete.
9658 (num_lwps, check_zombie_leaders, not_stopped_callback): New
9660 (linux_low_filter_event): New function, party factored out from
9661 linux_wait_for_event.
9662 (linux_wait_for_event): Rename to ...
9663 (linux_wait_for_event_filtered): ... this. Add new filter ptid
9664 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
9665 sigsuspend. Check for zombie leaders.
9666 (linux_wait_for_event): Reimplement as wrapper around
9667 linux_wait_for_event_filtered.
9668 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
9669 a normal or signal exit is seen, it's the whole process exiting.
9670 (wait_for_sigstop): No longer a for_each_inferior callback.
9671 Rewrite on top of linux_wait_for_event_filtered.
9672 (stop_all_lwps): Call wait_for_sigstop directly.
9673 * server.c (resume, handle_target_event): Handle
9674 TARGET_WAITKIND_NO_RESUMED.
9676 2014-02-26 Joel Brobecker <brobecker@adacore.com>
9678 * win32-low.c (psapi_get_dll_name,
9679 * win32_CreateToolhelp32Snapshot): Delete.
9680 (win32_CreateToolhelp32Snapshot, win32_Module32First)
9681 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
9683 (handle_load_dll): Add function description.
9684 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
9686 2014-02-26 Joel Brobecker <brobecker@adacore.com>
9688 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
9690 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
9691 base address when calling win32_add_one_solib.
9692 (handle_load_dll): Delete local variable load_addr.
9693 Remove 0x1000 offset applied to DLL base address when calling
9694 win32_add_one_solib.
9695 (handle_unload_dll): Add comment.
9697 2014-02-26 Joel Brobecker <brobecker@adacore.com>
9699 * win32-low.c (win32_add_all_dlls): Renames
9700 win32_ensure_ntdll_loaded. Rewrite function documentation.
9701 Adjust implementation to always load all DLLs.
9702 Add 0x1000 offset to DLL base address when calling
9703 win32_add_one_solib.
9704 (child_initialization_done): New static global.
9705 (do_initial_child_stuff): Set child_initialization_done to
9706 zero during child initialization, and 1 after. Replace call
9707 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
9709 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
9710 (handle_unload_dll): Add function documentation.
9711 (get_child_debug_event): Ignore load and unload DLL events
9712 during child initialization.
9714 2014-02-20 Doug Evans <dje@google.com>
9716 Remove global all_lwps.
9717 * inferiors.h (ptid_of): Move here from linux-low.h.
9718 (pid_of, lwpid_of): Ditto.
9719 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
9720 parameter is a struct thread_info * now.
9721 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
9722 directly. Pass &all_threads to find_inferior instead of &all_lwps.
9723 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
9725 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
9726 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
9727 * linux-arm-low.c (update_registers_callback): Update, "entry"
9728 parameter is a struct thread_info * now.
9729 Fetch lwpid from current_inferior directly.
9730 (arm_insert_point): Pass &all_threads to find_inferior instead of
9732 (arm_remove_point): Ditto.
9733 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
9734 (arm_prepare_to_resume): Fetch pid from thread.
9735 (arm_read_description): Fetch lwpid from current_inferior directly.
9736 * linux-low.c (all_lwps): Delete.
9737 (delete_lwp): Delete call to remove_inferior.
9738 (handle_extended_wait): Fetch lwpid from thread.
9739 (add_lwp): Don't set lwp->entry.id. Remove call to
9740 add_inferior_to_list.
9741 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
9742 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
9743 (kill_one_lwp_callback): Ditto.
9744 (linux_kill): Don't dereference NULL pointer.
9745 Fetch ptid,lwpid from thread.
9746 (get_detach_signal): Fetch ptid from thread.
9747 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
9748 Simplify call to regcache_invalidate_thread.
9749 (delete_lwp_callback): Update, "entry" parameter is a
9750 struct thread_info * now. Fetch pid from thread.
9751 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
9752 (status_pending_p_callback): Update, "entry" parameter is a
9753 struct thread_info * now. Fetch ptid from thread.
9754 (find_lwp_pid): Update, "entry" parameter is a
9755 struct thread_info * now.
9756 (linux_wait_for_lwp): Fetch pid from thread.
9757 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
9758 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
9759 (enqueue_one_deferred_signal): Fetch lwpid from thread.
9760 (dequeue_one_deferred_signal): Ditto.
9761 (cancel_breakpoint): Fetch ptid from current_inferior.
9762 (linux_wait_for_event): Pass &all_threads to find_inferior,
9763 not &all_lwps. Fetch ptid, lwpid from thread.
9764 (count_events_callback): Update, "entry" parameter is a
9765 struct thread_info * now.
9766 (select_singlestep_lwp_callback): Ditto.
9767 (select_event_lwp_callback): Ditto.
9768 (cancel_breakpoints_callback): Ditto.
9769 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
9771 (select_event_lwp): Ditto. Fetch ptid from event_thread.
9772 (unsuspend_one_lwp): Update, "entry" parameter is a
9773 struct thread_info * now.
9774 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
9776 (linux_stabilize_threads): Ditto. And for for_each_inferior.
9777 Fetch lwpid from thread, not lwp.
9778 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
9779 Pass &all_threads to find_inferior, not &all_lwps.
9780 (send_sigstop): Fetch lwpid from thread, not lwp.
9781 (send_sigstop_callback): Update, "entry" parameter is a
9782 struct thread_info * now.
9783 (suspend_and_send_sigstop_callback): Ditto.
9784 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
9785 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
9786 struct thread_info * now.
9787 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
9789 (lwp_running): Update, "entry" parameter is a
9790 struct thread_info * now.
9791 (stop_all_lwps): Fetch ptid from thread.
9792 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
9793 (linux_resume_one_lwp): Fetch lwpid from thread.
9794 (linux_set_resume_request): Update, "entry" parameter is a
9795 struct thread_info * now. Fetch pid, lwpid from thread.
9796 (resume_status_pending_p): Update, "entry" parameter is a
9797 struct thread_info * now.
9798 (need_step_over_p): Ditto. Fetch lwpid from thread.
9799 (start_step_over): Fetch lwpid from thread.
9800 (linux_resume_one_thread): Update, "entry" parameter is a
9801 struct thread_info * now. Fetch lwpid from thread.
9802 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
9803 (proceed_one_lwp): Update, "entry" parameter is a
9804 struct thread_info * now. Fetch lwpid from thread.
9805 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
9806 struct thread_info * now.
9807 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
9808 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
9809 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
9811 (regsets_store_inferior_registers): Ditto.
9812 (fetch_register, store_register): Ditto.
9813 (linux_read_memory, linux_write_memory): Ditto.
9814 (linux_request_interrupt): Ditto.
9815 (linux_read_auxv): Ditto.
9816 (linux_xfer_siginfo): Ditto.
9817 (linux_qxfer_spu): Ditto.
9818 (linux_qxfer_libraries_svr4): Ditto.
9819 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
9820 moved to inferiors.h.
9822 (get_thread_lwp): Update.
9823 (struct lwp_info): Delete member "entry". Simplify comment for
9826 * linux-mips-low.c (mips_read_description): Fetch lwpid from
9827 current_inferior directly.
9828 (update_watch_registers_callback): Update, "entry" parameter is a
9829 struct thread_info * now. Fetch pid from thread.
9830 (mips_linux_prepare_to_resume): Fetch ptid from thread.
9831 (mips_insert_point): Fetch lwpid from current_inferior.
9832 Pass &all_threads to find_inferior, not &all_lwps.
9833 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
9834 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
9836 (mips_stopped_data_address): Ditto.
9837 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
9839 * linux-tile-low.c (tile_arch_setup): Ditto.
9840 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
9841 (update_debug_registers_callback): Update, "entry" parameter is a
9842 struct thread_info * now. Fetch pid from thread.
9843 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
9844 Pass &all_threads to find_inferior, not &all_lwps.
9845 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
9846 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
9847 Pass &all_threads to find_inferior, not &all_lwps.
9848 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
9849 (i386_dr_low_get_status): Ditto.
9850 (x86_linux_prepare_to_resume): Fetch ptid from thread.
9851 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
9852 (x86_linux_read_description): Ditto.
9853 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
9855 2014-02-20 Doug Evans <dje@google.com>
9857 * inferiors.c (get_first_inferior): Fix buglet.
9859 2014-02-19 Doug Evans <dje@google.com>
9861 * gdbthread.h (add_thread): Change result type to struct thread_info *.
9862 * inferiors.c (add_thread): Change result type to struct thread_info *.
9863 All callers updated.
9864 (add_lwp): Call add_thread here instead of in callers.
9865 All callers updated.
9866 * linux-low.h (get_lwp_thread): Rewrite.
9867 (struct lwp_info): New member "thread".
9869 2014-02-19 Doug Evans <dje@google.com>
9871 * linux-low.c (add_lwp): Change result to struct lwp_info *.
9872 All callers updated.
9874 2014-02-19 Doug Evans <dje@google.com>
9876 * inferiors.c (add_thread): Fix whitespace.
9878 2014-02-19 Doug Evans <dje@google.com>
9880 * dll.c (clear_dlls): Replace accessing list implemention details
9882 * gdbthread.h (get_first_thread): Declare.
9883 * inferiors.c (for_each_inferior_with_data): New function.
9884 (get_first_thread): New function.
9885 (find_thread_ptid): Simplify.
9886 (get_first_inferior): New function.
9887 (clear_list): Delete.
9888 (one_inferior_p): New function.
9889 (clear_inferior_list): New function.
9890 (clear_inferiors): Update.
9891 * inferiors.h (for_each_inferior_with_data): Declare.
9892 (clear_inferior_list): Declare.
9893 (one_inferior_p): Declare.
9894 (get_first_inferior): Declare.
9895 * linux-low.c (linux_wait_for_event): Replace accessing list
9896 implemention details with API function.
9897 * server.c (target_running): Ditto.
9898 (accumulate_file_name_length): New function.
9899 (emit_dll_description): New function.
9900 (handle_qxfer_libraries): Replace accessing list implemention
9901 details with API function.
9902 (handle_qxfer_threads_worker): New function.
9903 (handle_qxfer_threads_proper): Replace accessing list implemention
9904 details with API function.
9905 (handle_query): Ditto.
9906 (visit_actioned_threads_callback_ftype): New typedef.
9907 (visit_actioned_threads_data): New struct.
9908 (visit_actioned_threads): Rewrite to be find_inferior callback.
9909 (resume): Call find_inferior.
9910 (handle_status): Replace accessing list implemention
9911 details with API function.
9912 (process_serial_event): Replace accessing list implemention details
9914 * target.c (set_desired_inferior): Replace accessing list implemention
9915 details with API function.
9916 * tracepoint.c (same_process_p): New function.
9917 (gdb_agent_about_to_close): Replace accessing list implemention
9918 details with API function.
9919 * win32-low.c (child_delete_thread): Replace accessing list
9920 implemention details with API function.
9921 (match_dll_by_basename): New function.
9922 (dll_is_loaded_by_basename): New function.
9923 (win32_ensure_ntdll_loaded): Replace accessing list implemention
9924 details call to dll_is_loaded_by_basename.
9926 2014-02-19 Doug Evans <dje@google.com>
9928 * dll.h (struct dll_info): Add comment.
9929 * gdbthread.h (struct thread_info): Add comment.
9930 (current_ptid): Simplify.
9931 * inferiors.c (add_process): Update.
9932 (remove_process): Update.
9933 * inferiors.h (struct process_info): Rename member "head" to "entry".
9934 * linux-low.c (delete_lwp): Update.
9936 (last_thread_of_process_p): Update.
9937 (kill_one_lwp_callback, linux_kill): Update.
9938 (status_pending_p_callback): Update.
9939 (wait_for_sigstop): Update. Simplify read of ptid.
9940 (start_step_over): Update.
9941 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
9942 (get_lwp_thread): Update.
9943 (struct lwp_info): Rename member "head" to "entry".
9944 * regcache.h (inferior_list_entry): Delete.
9945 * server.c (kill_inferior_callback): Update.
9946 (detach_or_kill_inferior_callback): Update.
9947 (print_started_pid): Update.
9948 (print_attached_pid): Update.
9949 (process_serial_event): Simplify read of ptid.
9950 * thread-db.c (thread_db_create_event): Update.
9951 (thread_db_get_tls_address): Update.
9952 * win32-low.c (current_inferior_ptid): Simplify.
9954 2014-02-19 Tom Tromey <tromey@redhat.com>
9956 * target.h (struct target_ops) <supports_btrace>: Add target_ops
9958 (target_supports_btrace): Update.
9960 2014-02-14 Yao Qi <yao@codesourcery.com>
9962 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
9963 (rsp-low-ipa.o): New target.
9965 2014-02-12 Tom Tromey <tromey@redhat.com>
9967 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
9968 convert_ascii_to_int.
9969 * regcache.c (registers_to_string): Likewise.
9970 * remote-utils.c (decode_M_packet): Likewise.
9971 * server.c (process_serial_event): Likewise.
9973 2014-02-12 Tom Tromey <tromey@redhat.com>
9975 * server.c (handle_query, handle_v_run): Use hex2bin, not
9977 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
9979 2014-02-12 Tom Tromey <tromey@redhat.com>
9981 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
9982 convert_int_to_ascii.
9983 * regcache.c (registers_to_string, collect_register_as_string):
9985 * remote-utils.c (look_up_one_symbol, relocate_instruction):
9987 * server.c (process_serial_event): Likewise.
9988 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
9989 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
9991 2014-02-12 Tom Tromey <tromey@redhat.com>
9993 * remote-utils.c (look_up_one_symbol, monitor_output): Use
9994 bin2hex, not hexify.
9995 * tracepoint.c (cmd_qtstatus): Likewise.
9997 2014-02-12 Tom Tromey <tromey@redhat.com>
9999 * remote-utils.c (monitor_output): Pass explicit length to
10002 2014-02-12 Tom Tromey <tromey@redhat.com>
10004 * tracepoint.c: Include rsp-low.h.
10005 * server.c: Include rsp-low.h.
10006 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
10007 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
10009 * remote-utils.c: Include rsp-low.h.
10010 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
10011 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
10012 (convert_int_to_ascii, convert_ascii_to_int): Move to
10014 * regcache.c: Include rsp-low.h.
10015 * ax.c: Include rsp-low.h.
10016 * Makefile.in (SFILES): Add common/rsp-low.c.
10017 (OBS): Add rsp-low.o.
10018 (rsp-low.o): New target.
10020 2014-02-12 Tom Tromey <tromey@redhat.com>
10022 * utils.h (pulongest, plongest, phex_nz): Don't declare.
10023 Include print-utils.h.
10024 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
10025 (plongest, thirty_two, phex_nz): Remove.
10026 * Makefile.in (SFILES): Add common/print-utils.c.
10027 (OBS): Add print-utils.o.
10028 (print-utils-ipa.o): New target.
10029 (print-utils.o): New target.
10030 (IPA_OBJS): Add print-utils-ipa.o.
10032 2014-02-06 Tom Tromey <tromey@redhat.com>
10034 * Makefile.in (SFILES): Fix indentation.
10036 2014-02-05 Doug Evans <dje@google.com>
10038 * linux-low.c (linux_wait_for_event): Improve comment.
10039 (linux_wait_1): Keep current_inferior in sync with event_child.
10041 2014-01-22 Doug Evans <dje@google.com>
10043 * gdbthread.h (gdb_id_to_thread): Delete, unused.
10045 2014-01-22 Doug Evans <dje@google.com>
10047 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
10048 * configure: Regenerate.
10049 * config.in: Regenerate.
10050 * Makefile.in (SFILES): Add debug.c.
10051 (OBS): Add debug.o.
10052 * debug.c: New file.
10053 * debug.h: New file.
10054 * linux-aarch64-low.c (*): Update all debugging printfs to use
10055 debug_printf instead of fprintf.
10056 * linux-arm-low.c (*): Ditto.
10057 * linux-cris-low.c (*): Ditto.
10058 * linux-crisv32-low.c (*): Ditto.
10059 * linux-m32r-low.c (*): Ditto.
10060 * linux-sparc-low.c (*): Ditto.
10061 * linux-x86.c (*): Ditto.
10062 * linux-low.c (*): Ditto.
10063 (linux_wait_1): Add calls to debug_enter, debug_exit.
10064 (linux_wait): Remove redundant debugging printf.
10065 (stop_all_lwps): Add calls to debug_enter, debug_exit.
10066 (linux_resume, unstop_all_lwps): Ditto.
10067 * mem-break.c (*): Update all debugging printfs to use
10068 debug_printf instead of fprintf.
10069 * remote-utils.c (*): Ditto.
10070 * thread-db.c (*): Ditto.
10071 * server.c #include <ctype.h>, "gdb_vecs.h".
10072 (debug_threads): Moved to debug.c.
10073 (*): Update all debugging printfs to use debug_printf instead of
10075 (start_inferior): Replace call to fflush with call to debug_flush.
10076 (monitor_show_help): Mention set debug-format.
10077 (parse_debug_format_options): New function.
10078 (handle_monitor_command): Handle "monitor set debug-format".
10079 (gdbserver_usage): Mention --debug-format.
10080 (main): Parse --debug-format.
10081 * server.h (debug_threads): Declaration moved to debug.h.
10082 #include "debug.h".
10083 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
10084 trace_debug_1 that uses debug_printf.
10085 (tracepoint_look_up_symbols): Update all debugging printfs to use
10086 debug_printf instead of fprintf.
10088 2014-01-20 Baruch Siach <baruch@tkos.co.il>
10090 * linux-xtensa-low.c: Include asm/ptrace.h instead of
10093 2014-01-17 Pedro Alves <palves@redhat.com>
10096 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
10097 defined after including gdb_proc_service.h.
10099 2014-01-16 Doug Evans <dje@google.com>
10101 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
10102 (match_dll): Use it.
10104 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
10106 * target.h (target_ops) <read_btrace>: Change parameters and
10107 return type to allow error reporting.
10108 * server.c (handle_qxfer_btrace): Support delta reads. Pass
10109 trace reading errors on.
10110 * linux-low.c (linux_low_read_btrace): Pass trace reading
10112 (linux_low_disable_btrace): New.
10114 2014-01-15 Doug Evans <dje@google.com>
10116 * inferiors.c (thread_id_to_gdb_id): Delete.
10117 * inferiors.h (thread_id_to_gdb_id): Delete.
10119 2014-01-13 Eli Zaretskii <eliz@gnu.org>
10121 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
10122 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
10125 2014-01-08 Pedro Alves <palves@redhat.com>
10127 * server.c (handle_status): Don't discard previous queued stop
10128 replies or thread's pending status here.
10129 (main) <disconnection>: Do it here instead.
10131 2014-01-08 Pedro Alves <palves@redhat.com>
10133 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
10134 * server.c (visit_actioned_threads, handle_pending_status): New
10136 (handle_v_cont): Factor out parts to ...
10137 (resume): ... this new function. If in all-stop, and a thread
10138 being resumed has a pending status, report it without actually
10140 (myresume): Adjust to use the new 'resume' function.
10141 (clear_pending_status_callback, set_pending_status_callback)
10142 (find_status_pending_thread_callback): New functions.
10143 (handle_status): Handle the case of multiple threads having
10144 interesting statuses to report. Report threads' real last signal
10145 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
10146 with an interesting thread to report the status for, instead of
10147 always reporting the status of the first thread.
10149 2014-01-01 Joel Brobecker <brobecker@adacore.com>
10151 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
10152 * gdbreplay.c (gdbreplay_version): Likewise.
10154 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
10156 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
10157 iov.iov_len with the real length in use.
10159 2013-12-13 Joel Brobecker <brobecker@adacore.com>
10161 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
10162 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
10163 for all targets that use win32-low.c.
10164 * win32-low.c (win32_ensure_ntdll_loaded): New function.
10165 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
10167 2013-12-13 Pedro Alves <palves@redhat.com>
10169 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
10170 if equal to TARGET_WAITKIND_LOADED.
10171 * win32-low.c (cached_status): New static global.
10172 (win32_wait): Add declaration.
10173 (do_initial_child_stuff): Flush all initial pending debug events
10174 up to the initial breakpoint.
10175 (win32_wait): If CACHED_STATUS was set, return that instead
10176 of doing a real wait. Remove the code resuming the execution
10177 of the inferior after receiving a TARGET_WAITKIND_LOADED event
10178 during the initial phase. Also remove the code changing
10179 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
10180 TARGET_WAITKIND_STOPPED.
10182 2013-12-11 Yao Qi <yao@codesourcery.com>
10184 * notif.c (handle_notif_ack): Return 0 if no notification
10187 2013-11-20 Doug Evans <dje@google.com>
10189 * linux-low.c (linux_set_resume_request): Fix comment.
10191 2013-11-20 Doug Evans <dje@google.com>
10193 * linux-low.c (resume_status_pending_p): Tweak comment.
10195 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
10197 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
10198 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
10199 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
10200 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
10201 (srv_amd64_regobj): Add amd64-mpx.o.
10202 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
10203 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
10204 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
10205 * i387-fp.c (num_pl_bnd_register) Added constant.
10206 (num_pl_bnd_cfg_registers) Added constant.
10207 (struct i387_xsave) Added reserved area and MPX fields.
10208 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
10209 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
10211 (tdesc_i386_mpx_linux): Add MPX amd64 target.
10212 (init_registers_amd64_mpx_linux): Declare new function.
10213 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
10214 (x86_64_regmap): Add MPX registers.
10215 (x86_linux_read_description): Add MPX case.
10216 (initialize_low_arch): Initialize MPX targets.
10218 2013-11-18 Tom Tromey <tromey@redhat.com>
10220 * configure: Rebuild.
10221 * configure.ac: Don't check for stdlib.h.
10222 * gdbreplay.c: Unconditionally include stdlib.h.
10224 2013-11-18 Tom Tromey <tromey@redhat.com>
10226 * config.in: Rebuild.
10227 * configure: Rebuild.
10228 * configure.ac: Don't use AC_HEADER_DIRENT.
10230 2013-11-18 Tom Tromey <tromey@redhat.com>
10232 * server.h: Don't check HAVE_STRING_H.
10233 * gdbreplay.c: Don't check HAVE_STRING_H.
10234 * configure: Rebuild.
10236 2013-11-18 Tom Tromey <tromey@redhat.com>
10238 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
10241 2013-11-08 Tom Tromey <tromey@redhat.com>
10243 * configure, config.in: Rebuild.
10244 * configure.ac: Remove unused configury.
10246 2013-11-08 Tom Tromey <tromey@redhat.com>
10248 * acinclude.m4: Include common.m4, codeset.m4.
10249 * configure, config.in: Rebuild.
10250 * configure.ac: Use GDB_AC_COMMON.
10252 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
10254 * linux-s390-low.c (HWCAP_S390_TE): New define.
10255 (s390_arch_setup): Consider the TE field in the HWCAP for
10256 determining 'have_regset_tdb'.
10258 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
10261 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
10264 2013-10-02 Pedro Alves <palves@redhat.com>
10266 * server.c (process_serial_event): Don't output "GDBserver
10267 exiting" if GDB is connected through stdio.
10268 * target.c (mywait): Likewise, be silent if GDB is connected
10271 2013-10-01 Joel Brobecker <brobecker@adacore.com>
10273 * lynx-low.c (lynx_add_threads_after_attach): New function.
10274 (lynx_attach): Remove call to add_thread. Add call to
10275 lynx_add_threads_after_attach instead.
10277 2013-09-28 Mike Frysinger <vapier@gentoo.org>
10279 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
10280 * config.in, configure: Regenerated.
10282 2013-09-18 Yao Qi <yao@codesourcery.com>
10285 * server.c (start_inferior): Clear 'resume_info'.
10287 2013-09-16 Jiong Wang <jiwang@tilera.com>
10289 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
10292 2013-09-16 Jiong Wang <jiwang@tilera.com>
10294 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
10295 linux-tile-low.o to srv_tgtobj.
10297 2013-09-16 Will Newton <will.newton@linaro.org>
10299 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
10302 2013-09-06 Pedro Alves <palves@redhat.com>
10304 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
10305 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
10306 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
10307 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
10308 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
10309 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
10311 2013-09-06 Pedro Alves <palves@redhat.com>
10313 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
10314 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
10316 2013-09-06 Pedro Alves <palves@redhat.com>
10318 * linux-amd64-ipa.c: Include tracepoint.h.
10319 * linux-i386-ipa.c: Include tracepoint.h.
10321 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
10323 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
10324 (ps_get_thread_area): New function.
10326 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
10328 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
10329 (initialize_low_arch): Call init_registers_crisv32 rather than
10330 init_register_crisv32.
10332 2013-09-05 Pedro Alves <palves@redhat.com>
10334 * server.h (handle_vFile, hostio_last_error_from_errno): Move
10336 * hostio.h: ... this new file.
10337 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
10338 win32-low.c: Include hostio.h.
10340 2013-09-05 Pedro Alves <palves@redhat.com>
10342 * server.h (gdb_client_data, handler_func, callback_handler_func)
10343 (delete_file_handler, add_file_handler, append_callback_event)
10344 (delete_callback_event, start_event_loop, initialize_event_loop):
10345 Move to event-loop.h and include it.
10346 * event-loop.h: New file.
10348 2013-09-05 Pedro Alves <palves@redhat.com>
10350 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
10351 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
10352 (loaded_dll, unloaded_dll): Move to ...
10353 * dll.h: ... this new file.
10354 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
10356 2013-09-05 Pedro Alves <palves@redhat.com>
10358 * server.h (current_process, get_thread_process, all_processes)
10359 (add_inferior_to_list, for_each_inferior, current_inferior)
10360 (remove_inferior, add_process, remove_process, find_process_pid)
10361 (have_started_inferiors_p, have_attached_inferiors_p)
10362 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
10363 (clear_inferiors, find_inferior, find_inferior_id)
10364 (inferior_target_data, set_inferior_target_data)
10365 (inferior_regcache_data, set_inferior_regcache_data): Move to
10366 inferiors.h, and include it.
10367 * inferiors.h: New file.
10369 2013-09-05 Pedro Alves <palves@redhat.com>
10371 * server.h (struct emit_ops, current_insn_ptr, emit_error):
10375 2013-09-05 Pedro Alves <palves@redhat.com>
10377 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
10379 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
10380 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
10381 (handle_tracepoint_general_set, handle_tracepoint_query)
10382 (tracepoint_finished_step, tracepoint_was_hit)
10383 (release_while_stepping_state_list, current_traceframe)
10384 (in_readonly_region, traceframe_read_mem)
10385 (fetch_traceframe_registers, traceframe_read_sdata)
10386 (traceframe_read_info, struct fast_tpoint_collect_status)
10387 (fast_tracepoint_collecting, force_unlock_trace_buffer)
10388 (handle_tracepoit_bkpts, initialize_low_tracepoint)
10389 (supply_fast_tracepoint_registers)
10390 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
10391 (ipa_tdesc, claim_trampoline_space)
10392 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
10393 (agent_mem_read, agent_get_trace_state_variable_value)
10394 (agent_set_trace_state_variable_value, agent_tsv_read)
10395 (agent_mem_read_string, get_raw_reg_func_addr)
10396 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
10397 * tracepoint.h: ... this new file.
10399 2013-09-05 Pedro Alves <palves@redhat.com>
10401 * server.h (perror_with_name, error, fatal, warning, paddress)
10402 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
10404 * utils.h: New file.
10406 2013-09-05 Pedro Alves <palves@redhat.com>
10408 * server.h (remote_debug, noack_mode, transport_is_reliable)
10409 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
10410 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
10411 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
10412 (write_enn, initialize_async_io, enable_async_io)
10413 (disable_async_io, check_remote_input_interrupt_request)
10414 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
10415 (dead_thread_notify, prepare_resume_reply)
10416 (decode_address_to_semicolon, decode_address, decode_m_packet)
10417 (decode_M_packet, decode_X_packet, decode_xfer_write)
10418 (decode_search_memory_packet, unhexify, hexify)
10419 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
10420 (look_up_one_symbol, relocate_instruction)
10421 (monitor_output): Move to remote-utils.h, and include it.
10422 * remote-utils.h: New file.
10424 2013-09-05 Pedro Alves <palves@redhat.com>
10426 * server.h (_): Delete.
10428 2013-09-02 Pedro Alves <palves@redhat.com>
10430 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
10431 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
10433 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
10435 2013-09-02 Pierre Muller <muller@sourceware.org>
10437 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
10438 or WriteProcessMemory complete successfully and handle
10439 ERROR_PARTIAL_COPY error.
10441 2013-09-02 Pedro Alves <palves@redhat.com>
10443 * server.c (gdb_read_memory): Return -1 on traceframe memory read
10444 error instead of EIO.
10446 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
10449 * linux-low.c: Include filestuff.h.
10450 (linux_create_inferior) <pid == 0>: Call close_most_fds.
10451 * lynx-low.c: Include filestuff.h.
10452 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
10453 * server.c: Include filestuff.h.
10454 (main): Call notice_open_fds.
10455 * spu-low.c: Include filestuff.h.
10456 (spu_create_inferior) <pid == 0>: Call close_most_fds.
10458 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
10460 * Makefile.in: Explain why ../target and ../nat are not
10461 listed as include file search paths.
10462 (linux-waitpid.o): New object file rule.
10463 * configure.srv (srv_native_linux_obj): New variable.
10464 Replace all occurrences of linux native object files with
10465 $srv_native_linux_obj.
10466 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
10467 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
10468 (linux_enable_event_reporting): Remove declaration.
10469 (my_waitpid): Moved to common/linux-waitpid.c.
10470 (linux_wait_for_event): Pass ptid when calling
10471 linux_enable_event_reporting.
10472 (linux_supports_tracefork_flag): Remove.
10473 (linux_enable_event_reporting): Likewise.
10474 (linux_tracefork_grandchild): Remove.
10475 (STACK_SIZE): Moved to common/linux-ptrace.c.
10476 (linux_tracefork_child): Remove.
10477 (linux_test_for_tracefork): Remove.
10478 (linux_look_up_symbols): Call linux_supports_traceclone.
10479 (initialize_low): Remove call to linux_test_for_tracefork.
10480 * linux-low.h (PTRACE_TYPE_ARG3): Move to
10481 common/linux-ptrace.h.
10482 (PTRACE_TYPE_ARG4): Likewise.
10483 Include linux-ptrace.h.
10485 2013-08-21 Pedro Alves <palves@redhat.com>
10487 * config.in: Renegerate.
10489 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
10491 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
10492 (SFILES): Remove $(srcdir)/common/target-common.c and
10493 add $(srcdir)/target/waitstatus.c.
10494 (OBS): Remove target-common.o and add waitstatus.o.
10495 (server_h): Remove $(srcdir)/../common/target-common.h and
10496 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
10497 and $(srcdir)/../target/waitstatus.h.
10498 (target-common.o): Remove.
10499 (waitstatus.o): New target object file.
10500 * target.h: Do not include target-common.h and
10501 include target/resume.h, target/wait.h and
10502 target/waitstatus.h.
10504 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
10506 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
10507 to PTRACE_TYPE_ARG3.
10508 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
10509 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
10511 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
10512 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
10514 2013-07-27 Jie Zhang <jie@codesourcery.com>
10515 Daniel Jacobowitz <dan@codesourcery.com>
10516 Yao Qi <yao@codesourcery.com>
10518 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
10519 (mips-linux-watch.o): New rule.
10520 (mips_linux_watch_h): New variable.
10521 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
10523 * linux-mips-low.c: Include mips-linux-watch.h.
10524 (struct arch_process_info, struct arch_lwp_info): New.
10525 (update_watch_registers_callback): New function.
10526 (mips_linux_new_process, mips_linux_new_thread) New functions.
10527 (mips_linux_prepare_to_resume, mips_insert_point): New
10529 (mips_remove_point, mips_stopped_by_watchpoint): New
10531 (rsp_bp_type_to_target_hw_bp_type): New function.
10532 (mips_stopped_data_address): New function.
10533 (the_low_target): Add watchpoint support functions.
10535 2013-07-27 Yao Qi <yao@codesourcery.com>
10537 * i386-low.c: Include break-common.h.
10538 (enum target_hw_bp_type): Remove.
10540 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
10542 * Makefile.in (SFILES): /common/target-common.c.
10543 (OBS): Add target-common.o.
10544 (server_h): Add $(srcdir)/../common/target-common.h.
10545 (target-common.o): New target.
10546 * server.c (queue_stop_reply_callback): Free
10547 status string after use.
10548 * target.c (target_waitstatus_to_string): Remove.
10549 * target.h: Include target-common.h.
10550 (resume_kind): Likewise.
10551 (target_waitkind): Likewise.
10552 (target_waitstatus): Likewise.
10553 (TARGET_WNOHANG): Likewise.
10555 2013-07-04 Yao Qi <yao@codesourcery.com>
10557 * Makefile.in (host_alias): Use @host_noncanonical@.
10558 (target_alias): Use @target_noncanonical@.
10559 * configure.ac: Use ACX_NONCANONICAL_TARGET and
10560 ACX_NONCANONICAL_HOST.
10561 * configure: Regenerated.
10564 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
10566 * configure.ac (version_host, version_target): Set and AC_SUBST them.
10567 * configure: Rebuild.
10568 * Makefile.in (version_host, version_target): Get from configure.
10569 (version.c): Use $(version_host) and $(version_target).
10571 2013-07-03 Pedro Alves <palves@redhat.com>
10573 * Makefile.in (config.status): Depend on development.sh.
10574 * acinclude.m4: Include libmcheck.m4.
10575 * configure: Regenerate.
10577 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
10579 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
10580 attribute inside the parentheses.
10581 (winapi_DebugSetProcessKillOnExit): Ditto.
10582 (winapi_DebugBreakProcess): Ditto.
10583 (winapi_GenerateConsoleCtrlEvent): Ditto.
10585 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
10587 * notif.h (notif_event): Add a dummy member to avoid compiler
10590 2013-07-01 Pedro Alves <palves@redhat.com>
10592 * hostio.c (HOSTIO_PATH_MAX): Define.
10593 (require_filename, handle_open, handle_unlink, handle_readlink):
10596 2013-07-01 Pedro Alves <palves@redhat.com>
10598 * server.h: Include "pathmax.h".
10599 * linux-low.c: Don't include sys/param.h.
10600 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
10602 * win32-low.c: Don't include sys/param.h.
10603 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
10605 2013-07-01 Pedro Alves <palves@redhat.com>
10607 * event-loop.c: Don't check HAVE_UNISTD_H before including
10609 * gdbreplay.c: Likewise.
10610 * remote-utils.c: Likewise.
10611 * server.c: Likewise.
10612 * configure.ac: Don't check for unistd.h.
10613 * configure: Regenerate.
10615 2013-06-28 Tom Tromey <tromey@redhat.com>
10617 * Makefile.in (version.c): Use version.in, not
10620 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
10622 * configure.ac (version_host, version_target): Set and AC_SUBST them.
10623 * configure: Rebuild.
10624 * Makefile.in (version_host, version_target): Get from configure.
10625 (version.c): Use $(version_host) and $(version_target).
10627 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
10629 Fix trace-status to output user name without trailing colon.
10630 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
10632 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
10634 Fix trace-status to output proper start-time and stop-time.
10635 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
10636 output start time and stop time in hex as gdb expects.
10638 2013-06-26 Pedro Alves <pedro@codesourcery.com>
10640 * tracepoint.c (build_traceframe_info_xml): Output trace state
10641 variables present in the trace buffer.
10643 2013-06-24 Tom Tromey <tromey@redhat.com>
10645 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
10647 (version.o): Remove.
10648 * gdbreplay.c: Include version.h.
10649 (version, host_name): Don't declare.
10650 * server.h: Include version.h.
10651 (version, host_name): Don't declare.
10653 2013-06-12 Pedro Alves <palves@redhat.com>
10655 * linux-x86-low.c (linux_is_elf64): Delete global.
10656 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
10657 with local linux_pid_exe_is_elf_64_file use.
10659 2013-06-11 Pedro Alves <palves@redhat.com>
10661 * linux-low.c (regset_disabled, disable_regset): New functions.
10662 (regsets_fetch_inferior_registers)
10663 (regsets_store_inferior_registers): Use them.
10664 (initialize_regsets_info); Don't allocate the disabled_regsets
10666 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
10669 2013-06-11 Pedro Alves <palves@redhat.com>
10671 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
10674 2013-06-11 Pedro Alves <palves@redhat.com>
10676 * linux-x86-low.c (initialize_low_arch): Call
10677 init_registers_x32_avx_linux.
10679 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
10681 Fix compatibility with Android Bionic.
10682 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
10685 2013-06-07 Pedro Alves <palves@redhat.com>
10688 * Makefile.in (OBS): Add tdesc.o.
10689 (IPA_OBJS): Add tdesc-ipa.o.
10690 (tdesc-ipa.o): New rule.
10691 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
10693 * linux-low.c (new_inferior): Delete.
10694 (disabled_regsets, num_regsets): Delete.
10695 (linux_add_process): Adjust to set the new per-process
10697 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
10698 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
10699 was a stop. When calling arch_setup, switch the current inferior
10700 to the thread that got an event.
10701 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
10702 (regsets_fetch_inferior_registers)
10703 (regsets_store_inferior_registers): New regsets_info parameter.
10705 (linux_register_in_regsets): New regs_info parameter. Adjust to
10707 (register_addr, fetch_register, store_register): New usrregs_info
10708 parameter. Adjust to use it.
10709 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
10710 parameter regs_info. Adjust to use it.
10711 (linux_fetch_registers): Get the current inferior's regs_info, and
10713 (linux_store_registers): Ditto.
10714 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
10715 (initialize_low): Don't initialize the target_regsets here. Call
10716 initialize_low_arch.
10717 * linux-low.h (target_regsets): Delete declaration.
10718 (struct regsets_info): New.
10719 (struct usrregs_info): New.
10720 (struct regs_info): New.
10721 (struct process_info_private) <new_inferior>: New field.
10722 (struct linux_target_ops): Delete the num_regs, regmap, and
10723 regset_bitmap fields. New field regs_info.
10724 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
10725 * i387-fp.c (num_xmm_registers): Delete.
10726 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
10727 calls to new interface.
10728 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
10729 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
10730 Infer the number of xmm registers from the regcache's target
10732 * i387-fp.h (num_xmm_registers): Delete.
10733 * inferiors.c (add_thread): Don't install the thread's regcache
10735 * proc-service.c (gregset_info): Fetch the current inferior's
10736 regs_info. Adjust to use it.
10737 * regcache.c: Include tdesc.h.
10738 (register_bytes, reg_defs, num_registers)
10739 (gdbserver_expedite_regs): Delete.
10740 (get_thread_regcache): If the thread doesn't have a regcache yet,
10741 create one, instead of aborting gdbserver.
10742 (regcache_invalidate_one): Rename to ...
10743 (regcache_invalidate_thread): ... this.
10744 (regcache_invalidate_one): New.
10745 (regcache_invalidate): Only invalidate registers of the current
10747 (init_register_cache): Add target_desc parameter, and use it.
10748 (new_register_cache): Ditto. Assert the target description has a
10749 non zero registers_size.
10750 (regcache_cpy): Add assertions. Adjust.
10751 (realloc_register_cache, set_register_cache): Delete.
10752 (registers_to_string, registers_from_string): Adjust.
10753 (find_register_by_name, find_regno, find_register_by_number)
10754 (register_cache_size): Add target_desc parameter, and use it.
10755 (free_register_cache_thread, free_register_cache_thread_one)
10756 (regcache_release, register_cache_size): New.
10757 (register_size): Add target_desc parameter, and use it.
10758 (register_data, supply_register, supply_register_zeroed)
10759 (supply_regblock, supply_register_by_name, collect_register)
10760 (collect_register_as_string, collect_register_by_name): Adjust.
10761 * regcache.h (struct target_desc): Forward declare.
10762 (struct regcache) <tdesc>: New field.
10763 (init_register_cache, new_register_cache): Add target_desc
10765 (regcache_invalidate_thread): Declare.
10766 (regcache_invalidate_one): Delete declaration.
10767 (regcache_release): Declare.
10768 (find_register_by_number, register_cache_size, register_size)
10769 (find_regno): Add target_desc parameter.
10770 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
10772 * remote-utils.c: Include tdesc.h.
10773 (outreg, prepare_resume_reply): Adjust.
10774 * server.c: Include tdesc.h.
10775 (gdbserver_xmltarget): Delete declaration.
10776 (get_features_xml, process_serial_event): Adjust.
10777 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
10779 (struct process_info) <tdesc>: New field.
10780 (ipa_tdesc): Declare.
10781 * tdesc.c: New file.
10782 * tdesc.h: New file.
10783 * tracepoint.c: Include tdesc.h.
10784 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
10785 (get_context_regcache): Adjust to pass ipa_tdesc down.
10786 (do_action_at_tracepoint): Adjust to get the register cache size
10787 from the context regcache's description.
10788 (traceframe_walk_blocks): Adjust to get the register cache size
10789 from the current trace frame's description.
10790 (traceframe_get_pc): Adjust to get current trace frame's
10791 description and pass it down.
10792 (gdb_collect): Adjust to get the register cache size from the
10794 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
10795 (gdbserver_xmltarget): Delete.
10796 (initialize_low_tracepoint): Set the ipa's target description.
10797 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
10798 (initialize_low_tracepoint): Set the ipa's target description.
10799 * linux-x86-low.c: Include tdesc.h.
10800 [__x86_64__] (is_64bit_tdesc): New.
10801 (ps_get_thread_area, x86_get_thread_area): Use it.
10802 (i386_cannot_store_register): Rename to ...
10803 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
10804 (i386_cannot_fetch_register): Rename to ...
10805 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
10806 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
10808 (target_regsets): Rename to ...
10809 (x86_regsets): ... this.
10810 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
10812 (x86_siginfo_fixup): Use is_64bit_tdesc.
10813 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
10814 (tdesc_x32_avx_linux, tdesc_x32_linux)
10815 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
10817 (x86_linux_update_xmltarget): Delete.
10818 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
10819 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
10820 (AMD64_LINUX_USER64_CS): New.
10821 (x86_linux_read_description): New, based on
10822 x86_linux_update_xmltarget.
10823 (same_process_callback): New.
10824 (x86_arch_setup_process_callback): New.
10825 (x86_linux_update_xmltarget): New.
10826 (x86_regsets_info): New.
10827 (amd64_linux_regs_info): New.
10828 (i386_linux_usrregs_info): New.
10829 (i386_linux_regs_info): New.
10830 (x86_linux_regs_info): New.
10831 (x86_arch_setup): Reimplement.
10832 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
10833 (x86_emit_ops): Ditto.
10834 (the_low_target): Adjust. Install x86_linux_regs_info,
10835 x86_cannot_fetch_register, and x86_cannot_store_register.
10836 (initialize_low_arch): New.
10837 * linux-ia64-low.c (tdesc_ia64): Declare.
10838 (ia64_fetch_register): Adjust.
10839 (ia64_usrregs_info, regs_info): New globals.
10840 (ia64_regs_info): New function.
10841 (the_low_target): Adjust.
10842 (initialize_low_arch): New function.
10843 * linux-sparc-low.c (tdesc_sparc64): Declare.
10844 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
10846 (sparc_arch_setup): New function.
10847 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
10848 (the_low_target): Adjust.
10849 (initialize_low_arch): New function.
10850 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
10851 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
10852 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
10853 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
10854 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
10855 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
10856 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
10857 (tdesc_powerpc_isa205_vsx64l): Declare.
10858 (ppc_cannot_store_register, ppc_collect_ptrace_register)
10859 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
10860 (ppc_set_pc, ppc_get_hwcap): Adjust.
10861 (ppc_usrregs_info): Forward declare.
10862 (!__powerpc64__) ppc_regmap_adjusted: New global.
10863 (ppc_arch_setup): Adjust to the current process'es target
10865 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
10866 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
10867 (ppc_store_evrregset): Adjust.
10868 (target_regsets): Rename to ...
10869 (ppc_regsets): ... this, and make static.
10870 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
10871 (ppc_regs_info): New function.
10872 (the_low_target): Adjust.
10873 (initialize_low_arch): New function.
10874 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
10875 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
10876 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
10877 (tdesc_s390x_linux64v2): Declare.
10878 (s390_collect_ptrace_register, s390_supply_ptrace_register)
10879 (s390_fill_gregset, s390_store_last_break): Adjust.
10880 (target_regsets): Rename to ...
10881 (s390_regsets): ... this, and make static.
10882 (s390_get_pc, s390_set_pc): Adjust.
10883 (s390_get_hwcap): New target_desc parameter, and use it.
10884 [__s390x__] (have_hwcap_s390_high_gprs): New global.
10885 (s390_arch_setup): Adjust to set the current process'es target
10886 description. Don't adjust the regmap.
10887 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
10888 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
10889 (regs_info_3264): New globals.
10890 (s390_regs_info): New function.
10891 (the_low_target): Adjust.
10892 (initialize_low_arch): New function.
10893 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
10894 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
10895 [__mips64] (init_registers_mips_linux)
10896 (init_registers_mips_dsp_linux): Delete defines.
10897 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
10898 (have_dsp): New global.
10899 (mips_read_description): New, based on mips_arch_setup.
10900 (mips_arch_setup): Reimplement.
10901 (get_usrregs_info): New function.
10902 (mips_cannot_fetch_register, mips_cannot_store_register)
10903 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
10904 (mips_fill_fpregset, mips_store_fpregset): Adjust.
10905 (target_regsets): Rename to ...
10906 (mips_regsets): ... this, and make static.
10907 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
10908 (dsp_regs_info, regs_info): New globals.
10909 (mips_regs_info): New function.
10910 (the_low_target): Adjust.
10911 (initialize_low_arch): New function.
10912 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
10913 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
10915 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
10916 (arm_read_description): New, with bits factored from
10918 (arm_arch_setup): Reimplement.
10919 (target_regsets): Rename to ...
10920 (arm_regsets): ... this, and make static.
10921 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
10922 (arm_regs_info): New function.
10923 (the_low_target): Adjust.
10924 (initialize_low_arch): New function.
10925 * linux-m68k-low.c (tdesc_m68k): Declare.
10926 (target_regsets): Rename to ...
10927 (m68k_regsets): ... this, and make static.
10928 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
10929 (m68k_regs_info): New function.
10930 (m68k_arch_setup): New function.
10931 (the_low_target): Adjust.
10932 (initialize_low_arch): New function.
10933 * linux-sh-low.c (tdesc_sharch): Declare.
10934 (target_regsets): Rename to ...
10935 (sh_regsets): ... this, and make static.
10936 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
10937 (sh_regs_info, sh_arch_setup): New functions.
10938 (the_low_target): Adjust.
10939 (initialize_low_arch): New function.
10940 * linux-bfin-low.c (tdesc_bfin): Declare.
10941 (bfin_arch_setup): New function.
10942 (bfin_usrregs_info, regs_info): New globals.
10943 (bfin_regs_info): New function.
10944 (the_low_target): Adjust.
10945 (initialize_low_arch): New function.
10946 * linux-cris-low.c (tdesc_cris): Declare.
10947 (cris_arch_setup): New function.
10948 (cris_usrregs_info, regs_info): New globals.
10949 (cris_regs_info): New function.
10950 (the_low_target): Adjust.
10951 (initialize_low_arch): New function.
10952 * linux-cris-low.c (tdesc_crisv32): Declare.
10953 (cris_arch_setup): New function.
10954 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
10955 (cris_regs_info): New function.
10956 (the_low_target): Adjust.
10957 (initialize_low_arch): New function.
10958 * linux-m32r-low.c (tdesc_m32r): Declare.
10959 (m32r_arch_setup): New function.
10960 (m32r_usrregs_info, regs_info): New globals.
10961 (m32r_regs_info): Adjust.
10962 (initialize_low_arch): New function.
10963 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
10964 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
10965 (tic6x_usrregs_info): Forward declare.
10966 (tic6x_read_description): New function, based on ...
10967 (tic6x_arch_setup): ... this. Reimplement.
10968 (target_regsets): Rename to ...
10969 (tic6x_regsets): ... this, and make static.
10970 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
10971 (tic6x_regs_info): New function.
10972 (the_low_target): Adjust.
10973 (initialize_low_arch): New function.
10974 * linux-xtensa-low.c (tdesc_xtensa): Declare.
10975 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
10976 (target_regsets): Rename to ...
10977 (xtensa_regsets): ... this, and make static.
10978 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
10980 (xtensa_arch_setup, xtensa_regs_info): New functions.
10981 (the_low_target): Adjust.
10982 (initialize_low_arch): New function.
10983 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
10984 (nios2_arch_setup): Set the current process'es tdesc.
10985 (target_regsets): Rename to ...
10986 (nios2_regsets): ... this.
10987 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
10988 (nios2_regs_info): New function.
10989 (the_low_target): Adjust.
10990 (initialize_low_arch): New function.
10991 * linux-aarch64-low.c (tdesc_aarch64): Declare.
10992 (aarch64_arch_setup): Set the current process'es tdesc.
10993 (target_regsets): Rename to ...
10994 (aarch64_regsets): ... this.
10995 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
10996 (aarch64_regs_info): New function.
10997 (the_low_target): Adjust.
10998 (initialize_low_arch): New function.
10999 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
11001 (target_regsets): Rename to ...
11002 (tile_regsets): ... this.
11003 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
11004 (tile_regs_info): New function.
11005 (tile_arch_setup): Set the current process'es tdesc.
11006 (the_low_target): Adjust.
11007 (initialize_low_arch): New function.
11008 * spu-low.c (tdesc_spu): Declare.
11009 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
11010 * win32-arm-low.c (tdesc_arm): Declare.
11011 (arm_arch_setup): New function.
11012 (the_low_target): Install arm_arch_setup instead of
11013 init_registers_arm.
11014 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
11015 (init_windows_x86): Rename to ...
11016 (i386_arch_setup): ... this. Set `win32_tdesc'.
11017 (the_low_target): Adjust.
11018 * win32-low.c (win32_tdesc): New global.
11019 (child_add_thread): Don't create the thread cache here.
11020 (do_initial_child_stuff): Set the new process'es tdesc.
11021 * win32-low.h (struct target_desc): Forward declare.
11022 (win32_tdesc): Declare.
11023 * lynx-i386-low.c (tdesc_i386): Declare global.
11024 (lynx_i386_arch_setup): Set `lynx_tdesc'.
11025 * lynx-low.c (lynx_tdesc): New global.
11026 (lynx_add_process): Set the new process'es tdesc.
11027 * lynx-low.h (struct target_desc): Forward declare.
11028 (lynx_tdesc): Declare global.
11029 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
11030 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
11031 * nto-low.c (nto_tdesc): New global.
11032 (do_attach): Set the new process'es tdesc.
11033 * nto-low.h (struct target_desc): Forward declare.
11034 (nto_tdesc): Declare.
11035 * nto-x86-low.c (tdesc_i386): Declare.
11036 (nto_x86_arch_setup): Set `nto_tdesc'.
11038 2013-06-04 Gary Benson <gbenson@redhat.com>
11040 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
11041 to qSupported response when appropriate.
11042 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
11043 with nonzero-length annex.
11044 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
11045 arguments supplied in annex.
11047 2013-05-31 Doug Evans <dje@google.com>
11050 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
11051 64 bits in 64-cross-32 environment.
11053 2013-05-28 Pedro Alves <palves@redhat.com>
11055 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
11056 (aarch64-without-fpu.c): Delete rule.
11057 * configure.srv (aarch64*-*-linux*): Remove references to
11058 aarch64-without-fpu.o and aarch64-without-fpu.xml.
11059 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
11062 2013-05-24 Pedro Alves <palves@redhat.com>
11064 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
11065 instead of strchr/decode_address. Error if the range isn't split
11066 with a ','. Don't assume there's be a ':' in the action.
11068 2013-05-23 Yao Qi <yao@codesourcery.com>
11069 Pedro Alves <palves@redhat.com>
11071 * linux-low.c (lwp_in_step_range): New function.
11072 (linux_wait_1): If the thread was range stepping and stopped
11073 outside the stepping range, report the stop to GDB. Otherwise,
11074 continue stepping. Add range stepping debug output.
11075 (linux_set_resume_request): Copy the step range from the resume
11076 request to the lwp.
11077 (linux_supports_range_stepping): New.
11078 (linux_target_ops) <supports_range_stepping>: Set to
11079 linux_supports_range_stepping.
11080 * linux-low.h (struct linux_target_ops)
11081 <supports_range_stepping>: New field.
11082 (struct lwp_info) <step_range_start, step_range_end>: New fields.
11083 * linux-x86-low.c (x86_supports_range_stepping): New.
11084 (the_low_target) <supports_range_stepping>: Set to
11085 x86_supports_range_stepping.
11086 * server.c (handle_v_cont): Handle 'r' action.
11087 (handle_v_requests): Append ";r" if the target supports range
11089 * target.h (struct thread_resume) <step_range_start,
11090 step_range_end>: New fields.
11091 (struct target_ops) <supports_range_stepping>:
11093 (target_supports_range_stepping): New macro.
11095 2013-05-17 Joel Brobecker <brobecker@adacore.com>
11097 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
11098 confusion in comment.
11100 2013-05-17 Joel Brobecker <brobecker@adacore.com>
11102 * lynx-low.c (struct process_info_private): New type.
11103 (lynx_add_process): New function.
11104 (lynx_create_inferior, lynx_attach): Replace calls to
11105 add_process by calls to lynx_add_process.
11106 (lynx_resume): If PTID is null, then try using
11107 current_process()->private->last_wait_event_ptid.
11109 (lynx_clear_inferiors): Delete. The contents of that function
11110 has been inlined in lynx_mourn;
11111 (lynx_wait_1): Save the ptid in the process's private data.
11112 (lynx_mourn): Free the process' private data. Replace call
11113 to lynx_clear_inferiors by call to clear_inferiors.
11115 2013-05-17 Yao Qi <yao@codesourcery.com>
11117 * i386-low.c (i386_length_and_rw_bits): Move the comment to
11120 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
11122 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
11123 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
11124 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
11125 PT_TEXT_END_ADDR guards. Update comments.
11126 (linux_target_op) <read_offsets>: Conditionally define to
11127 linux_read_offsets if the target is UCLIBC and if it defines
11128 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
11130 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
11131 Andrew Jenner <andrew@codesourcery.com>
11133 * Makefile.in (SFILES): Add linux-nios2-low.c.
11134 (clean): Add action to delete nios2-linux.c.
11135 (nios2-linux.c): New rule.
11136 * configure.srv: Add nios2*-*-linux*.
11137 * linux-nios2-low.c: New.
11139 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
11141 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
11143 2013-04-25 Hui Zhu <hui@codesourcery.com>
11146 * ax.c (ax_printf): Add fflush.
11148 2013-04-22 Tom Tromey <tromey@redhat.com>
11150 * Makefile.in (SFILES): Add filestuff.c.
11151 (OBS): Add filestuff.o.
11152 (filestuff.o): New target.
11153 * config.in, configure: Rebuild.
11154 * configure.ac: Check for fdwalk, pipe2.
11156 2013-04-17 Pedro Alves <palves@redhat.com>
11158 * configure.ac (USE_THREAD_DB): Delete variable.
11159 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
11160 Don't AC_SUBST USE_THREAD_DB.
11161 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
11162 * config.in, configure: Regenerate.
11164 2013-04-16 Pedro Alves <palves@redhat.com>
11166 * linux-low.h (struct lwp_info) <thread_known>: Move under
11167 the USE_THREAD_DB #ifdef.
11169 2013-04-16 Pedro Alves <palves@redhat.com>
11171 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
11172 (linux-low.o): Delete rule.
11173 * linux-low.h: Always include "gdb_thread_db.h" instead of
11174 conditionally including thread_db.h.
11175 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
11178 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
11180 * Makefile.in (install-only): Fix make install regression.
11182 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
11184 Convert man pages to texinfo, new gdbinit.5 texinfo page.
11185 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
11187 * gdbserver.1: Remove.
11189 2013-03-22 Pedro Alves <palves@redhat.com>
11191 * linux-low.c (handle_extended_wait): Don't call
11192 linux_enable_event_reporting.
11194 2013-03-15 Tony Theodore <tonyt@logyst.com>
11197 * Makefile.in (SHELL): Use @SHELL@.
11199 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
11201 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
11204 2013-03-13 Joel Brobecker <brobecker@adacore.com>
11206 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
11207 Remove extraneous NULL element.
11209 2013-03-13 Yao Qi <yao@codesourcery.com>
11211 * tracepoint.c (traceframe_read_tsv): Look for the last matched
11212 'V' block in trace frame.
11214 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
11216 * target.h (struct target_ops): Add btrace ops.
11217 (target_supports_btrace): New macro.
11218 (target_enable_btrace): New macro.
11219 (target_disable_btrace): New macro.
11220 (target_read_btrace): New macro.
11221 * gdbthread.h (struct thread_info): Add btrace field.
11222 * server.c: Include btrace-common.h.
11223 (handle_btrace_general_set): New function.
11224 (handle_btrace_enable): New function.
11225 (handle_btrace_disable): New function.
11226 (handle_general_set): Call handle_btrace_general_set.
11227 (handle_qxfer_btrace): New function.
11228 (struct qxfer qxfer_packets[]): Add btrace entry.
11229 * inferiors.c (remove_thread): Disable btrace.
11230 * linux-low: Include linux-btrace.h.
11231 (linux_low_enable_btrace): New function.
11232 (linux_low_read_btrace): New function.
11233 (linux_target_ops): Add btrace ops.
11234 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
11235 Add srv_linux_btrace=yes.
11236 (x86_64-*-linux*): Add linux-btrace.o.
11237 Add srv_linux_btrace=yes.
11238 * configure.ac: Define HAVE_LINUX_BTRACE.
11239 * config.in: Regenerated.
11240 * configure: Regenerated.
11242 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
11244 * server.c (handle_qxfer): Preserve error message if -3 is
11246 (qxfer): Document the -3 return value.
11248 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
11250 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
11251 (linux_btrace_h): New variable.
11252 (linux-btrace.o): New rule.
11254 2013-03-08 Stan Shebs <stan@codesourcery.com>
11255 Hafiz Abid Qadeer <abidh@codesourcery.com>
11257 * tracepoint.c (trace_buffer_size): New global.
11258 (DEFAULT_TRACE_BUFFER_SIZE): New define.
11259 (init_trace_buffer): Change to one-argument function. Allocate
11260 trace buffer memory.
11261 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
11262 handle QTBuffer:size packet.
11263 (cmd_bigqtbuffer_size): New function.
11264 (initialize_tracepoint): Call init_trace_buffer with
11265 DEFAULT_TRACE_BUFFER_SIZE.
11266 * server.c (handle_query): Add QTBuffer:size in the
11269 2013-03-07 Yao Qi <yao@codesourcery.com>
11271 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
11272 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
11274 (cmd_qtsp): Adjust condition. Do post increment.
11275 Set cur_action and cur_step_action back to 0.
11277 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
11280 * linux-low.c (linux_write_memory): Return early success if LEN is
11283 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
11285 * configure.srv: Add x86_64-*-cygwin* as target.
11287 2013-02-28 Tom Tromey <tromey@redhat.com>
11289 * configure.ac: Invoke AC_SYS_LARGEFILE.
11290 * configure, config.in: Rebuild.
11292 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
11294 * win32-low.c: Throughout, fix format strings and casts of
11295 printf-like functions to avoid type related warnings on all
11297 (get_child_debug_event): Print dwDebugEventCode as hex since
11298 that's how it's usually documented.
11300 2013-02-28 Yao Qi <yao@codesourcery.com>
11302 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
11305 2013-02-27 Jiong Wang <jiwang@tilera.com>
11307 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
11308 (reg-tilegx32.c): New rule.
11309 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
11310 * linux-tile-low.c (tile_arch_setup): New function. Invoke
11311 different register info initializer according to elf class.
11312 (init_registers_tilgx32): New function. The tilegx32 register info
11314 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
11315 (tile_store_gregset): Likewise.
11317 2013-02-27 Yao Qi <yao@codesourcery.com>
11319 * server.c (process_point_options): Print debug message when
11320 debug_threads is true.
11322 2013-02-26 Yao Qi <yao@codesourcery.com>
11324 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
11326 2013-02-19 Pedro Alves <palves@redhat.com>
11327 Kai Tietz <ktietz@redhat.com>
11331 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
11332 instead of strtoul to extract address from packet.
11333 (process_serial_event) <'z'>: Likewise.
11335 2013-02-18 Yao Qi <yao@codesourcery.com>
11337 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
11339 2013-02-14 Pedro Alves <palves@redhat.com>
11343 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
11344 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
11346 2013-02-14 Pedro Alves <palves@redhat.com>
11348 * tracepoint.c (cmd_qtdpsrc): Use savestring.
11350 2013-02-14 Pedro Alves <palves@redhat.com>
11352 * tracepoint.c (save_string): Delete.
11353 (add_tracepoint_action): Use savestring instead of save_string.
11355 2013-02-12 Pedro Alves <palves@redhat.com>
11357 * linux-xtensa-low.c: Ditto.
11358 * xtensa-xtregs.c: Ditto.
11360 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
11362 * thread-db.c (thread_db_get_tls_address): NULL pointer check
11365 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
11367 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
11368 aarch64_num_wp_regs and aarch64_num_bp_regs to
11369 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
11371 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
11373 * linux-aarch64-low.c (ps_get_thread_area): Replace
11374 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
11376 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
11377 Marcus Shawcroft <marcus.shawcroft@arm.com>
11378 Nigel Stephens <nigel.stephens@arm.com>
11379 Yufeng Zhang <yufeng.zhang@arm.com>
11381 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
11382 (aarch64.c, aarch64-without-fpu.c): New targets.
11383 * configure.srv (aarch64*-*-linux*): New.
11384 * linux-aarch64-low.c: New file.
11386 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
11388 * linux-low.c (handle_extended_wait, linux_create_inferior)
11389 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
11390 (dequeue_one_deferred_signal, linux_resume_one_thread)
11391 (fetch_register, linux_write_memory, linux_enable_event_reporting)
11392 (linux_tracefork_grandchild, linux_test_for_tracefork)
11393 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
11394 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
11395 where the argument is 0.
11397 2013-01-25 Yao Qi <yao@codesourcery.com>
11399 * event-loop.c: Include "queue.h".
11400 (gdb_event_p): New typedef.
11401 (struct gdb_event) <next_event>: Remove.
11402 (event_queue): Change to QUEUE(gdb_event_p).
11403 (async_queue_event): Remove.
11404 (gdb_event_xfree): New.
11405 (initialize_event_loop): New.
11406 (process_event): Use API from QUEUE.
11407 (wait_for_event): Likewise.
11408 * server.c (main): Call initialize_event_loop.
11409 * server.h (initialize_event_loop): Declare.
11411 2013-01-18 Yao Qi <yao@codesourcery.com>
11413 * ax.h (struct eval_agent_expr_context): New.
11414 (gdb_eval_agent_expr): Update declaration.
11415 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
11416 TFRAME. Add new argument CTX.
11417 * server.h (struct eval_agent_expr_context): Declare.
11418 (agent_mem_read, agent_tsv_read): Update declaration.
11419 (agent_mem_read_string): Likewise.
11420 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
11421 (add_traceframe_block): Add new argument TPOINT.
11422 Increase TPOINT->traceframe_usage.
11423 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
11424 eval_tracepoint_agent_expr.
11425 (condition_true_at_tracepoint): Likewise.
11426 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
11427 (agent_mem_read_string, agent_tsv_read): Likewise.
11429 2013-01-16 Yao Qi <yao@codesourcery.com>
11431 * linux-low.c (linux_resume_one_lwp): Don't check
11432 'lwp->bp_reinsert != 0'.
11434 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11435 Pedro Alves <palves@redhat.com>
11437 * lynx-low.c (ptrace_request_to_str): Define a temporary
11438 macro and use it to simplify this function's implementation.
11440 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11442 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
11445 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11447 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
11449 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11451 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
11453 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11455 * lynx-low.c (lynx_resume): Use the resume_info parameter
11456 to determine the ptid for the lynx_ptrace call, unless
11457 it is equal to minus_one_ptid, in which case we use the
11458 ptid of the current_inferior.
11459 (lynx_wait_1): After having received a thread create/exit
11460 event, resume the inferior's execution using the signaling
11461 thread's ptid, rather than the old ptid.
11463 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11465 * lynx-low.c (lynx_resume): Delete variable ret.
11467 2013-01-01 Joel Brobecker <brobecker@adacore.com>
11469 * gdbreplay.c (gdbreplay_version): Update copyright year.
11470 * server.c (gdbserver_version): Likewise.
11472 2012-12-17 Joel Brobecker <brobecker@adacore.com>
11474 * lynx-low.c (lynx_wait_1): Add debug trace before adding
11477 2012-12-17 Joel Brobecker <brobecker@adacore.com>
11479 * lynx-low.c (ptrace_request_to_str): Add handling for
11480 PTRACE_GETTRACESIG.
11482 2012-12-17 Joel Brobecker <brobecker@adacore.com>
11484 * lynx-low.c (lynx_attach): Delete variable new_process.
11486 2012-12-17 Joel Brobecker <brobecker@adacore.com>
11488 * lynx-low.c (lynx_create_inferior): Delete variable
11491 2012-12-17 Joel Brobecker <brobecker@adacore.com>
11493 * lynx-low.c (ptrace_request_to_str): Do not handle
11494 PTRACE_GETTHREADLIST if this macro does not exist.
11496 2012-12-15 Yao Qi <yao@codesourcery.com>
11498 * Makefile.in (OBS): Add notif.o.
11499 * notif.c, notif.h: New.
11500 * server.c: Include "notif.h".
11501 (struct vstop_notif) <next>: Remove.
11503 (queue_stop_reply): Update.
11504 (push_event, send_next_stop_reply): Remove.
11505 (discard_queued_stop_replies): Update.
11506 (notif_stop): New variable.
11507 (handle_v_stopped): Remove.
11508 (handle_v_requests): Don't call handle_v_stopped. Call
11509 handle_ack_notif instead.
11510 (queue_stop_reply_callback): Call notif_event_enque instead
11511 of queue_stop_reply.
11512 (handle_status): Don't call send_next_stop_reply, call
11513 notif_write_event instead.
11514 (kill_inferior_callback): Likewise.
11515 (detach_or_kill_inferior_callback): Likewise.
11516 (main): Call initialize_notif.
11517 (process_serial_event): Call QUEUE_is_empty.
11518 (handle_target_event): Call notif_push instead of push event.
11519 * server.h (push_event): Remove declaration.
11521 2012-12-10 Tom Tromey <tromey@redhat.com>
11523 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
11524 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
11527 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
11528 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
11529 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
11530 (amd64-linux-ipa.o, ax.o): Rewrite.
11531 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
11532 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
11533 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
11534 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
11535 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
11536 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
11537 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
11538 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
11539 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
11540 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
11541 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
11542 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
11543 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
11544 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
11545 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
11546 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
11547 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
11548 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
11549 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
11550 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
11551 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
11552 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
11553 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
11554 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
11555 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
11556 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
11557 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
11558 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
11559 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
11560 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
11561 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
11562 (reg-tilegx.o): Remove.
11563 (all_object_files): New macro.
11564 Include .deps files.
11565 * aclocal.m4, configure: Rebuild.
11566 * acinclude.m4: Include depstand.m4, lead-dot.m4.
11567 * configure.ac: Invoke ZW_CREATE_DEPDIR,
11568 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
11570 2012-12-05 Tom Tromey <tromey@redhat.com>
11573 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
11575 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
11577 * configure.ac: Check for linux/perf_event.h.
11578 * config.in: Regenerated.
11579 * configure: Regenerated.
11581 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
11583 * hostio.c (handle_readlink): Decrease buffer size
11584 parameter passed to readlink by one byte.
11586 2012-11-26 Yao Qi <yao@codesourcery.com>
11588 * configure.ac (build_warnings): Append '-Wempty-body'.
11589 * configure: Regenerated.
11590 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
11593 2012-11-15 Pierre Muller <muller@sourceware.org>
11595 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
11596 * config.in: Regenerate.
11597 * configure: Regenerate.
11598 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
11599 Use "gdb_wait.h" header instead of <sys/wait.h> header.
11600 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
11601 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
11603 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
11604 instead of <sys/wait.h> header.
11605 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
11607 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
11609 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
11610 (various make rules): Remove -DGDBSERVER
11612 2012-11-09 Yao Qi <yao@codesourcery.com>
11614 * spu-low.c (current_ptid): Move it to ..
11615 * gdbthread.h: ... here. New.
11616 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
11617 * server.c (myresume, process_serial_event): Likewise.
11618 * thread-db.c (thread_db_find_new_threads): Likewise.
11619 * tracepoint.c (run_inferior_command): Likewise.
11621 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
11623 * server.c (handle_search_memory_1): Include access length in
11626 2012-09-05 Michael Brandt <michael.brandt@axis.com>
11628 * linux-crisv32-low.c: Fix compile errors.
11630 2012-09-04 Yao Qi <yao@codesourcery.com>
11632 * tracepoint.c (cmd_qtsv): Adjust debug message.
11633 Don't check CUR_TPOINT.
11635 2012-08-28 Yao Qi <yao@codesourcery.com>
11637 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
11638 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
11639 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
11640 Remove declarations of xmalloc, xreallloc, xstrdup and
11642 * Makefile.in (libiberty_h): New.
11643 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
11644 (linux-bfin-low.o): Append dependency 'libiberty.h'.
11646 2012-08-23 Yao Qi <yao@codesourcery.com>
11648 * server.h: Remove declaration of 'xsnprintf'.
11650 2012-08-22 Keith Seitz <keiths@redhat.com>
11652 * server.h: Include build-gnulib-gbserver/config.h.
11653 * gdbreplay.c: Likewise.
11655 2012-08-08 Doug Evans <dje@google.com>
11657 * Makefile.in (SFILES): Add gdb_vecs.c.
11658 (OBS): Add gdb_vecs.o.
11659 (gdb_vecs_h, host_defs_h): New variables.
11660 (thread-db.o): Add $(gdb_vecs_h) dependency.
11661 (gdb_vecs.o): New rule.
11662 * thread-db.c: #include "gdb_vecs.h".
11663 (thread_db_load_search): Use a vector to iterate over path elements.
11664 Handle text appearing after "$pdir".
11666 * configure.ac: Add check for strstr.
11667 * config.in: Regenerate.
11668 * configure: Regenerate.
11670 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
11672 * hostio.c (handle_pread): If pread fails, fall back to attempting
11674 (handle_pwrite): Likewise for pwrite.
11676 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
11678 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
11679 between unsupported TYPE and unimplementable ADDR/LEN combination.
11680 (arm_insert_point): Act on new return value.
11682 2012-07-31 Pedro Alves <palves@redhat.com>
11684 * server.c (process_point_options): Only skip tokens if we find
11685 one that is unrecognized. Don't treat 'X' specially while
11686 skipping unrecognized tokens.
11688 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
11690 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
11691 to 4-byte-align HW breakpoint addresses for Thumb.
11693 2012-07-27 Yao Qi <yao@codesourcery.com>
11697 * server.h: Declare gdb_agent_about_to_close.
11698 * target.c (kill_inferior): Include "agent.h".
11699 New. Send command 'kill'.
11700 * target.h (kill_inferior): Removed macro.
11701 * tracepoint.c (gdb_agent_about_to_close): New.
11702 (gdb_agent_helper_thread): Handle command 'close'.
11703 Wait endlessly until the inferior stops.
11704 Install gdb_agent_remove_socket to atexit hook.
11705 (agent_socket_name): New static variable.
11706 (gdb_agent_socket_init): Replace local variable 'name' with
11707 'agent_socket_name'.
11708 (gdb_agent_remove_socket): New.
11710 2012-07-27 Yao Qi <yao@codesourcery.com>
11712 * server.c (process_point_options): Stop at 'X' when parsing.
11714 2012-07-19 Michael Eager <eager@eagercon.com>
11716 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
11718 * linux-x86-low.c (x86_insert_point, x86_remove_point):
11719 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
11720 hardware breakpoint.
11722 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
11724 * gdbserver/linux-low.c (initialize_low): Call
11725 linux_ptrace_init_warnings.
11727 2012-07-02 Doug Evans <dje@google.com>
11729 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
11732 2012-07-02 Stan Shebs <stan@codesourcery.com>
11734 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
11735 (ax.o): Add it to build rule.
11737 (OBS): Add format.o.
11738 (IPA_OBS): Add format.o.
11739 * server.c (handle_query): Claim support for breakpoint commands.
11740 (process_point_options): Add command case.
11741 (process_serial_event): Leave running if there are printfs in
11743 * mem-break.h (any_persistent_commands): Declare.
11744 (add_breakpoint_commands): Declare.
11745 (gdb_no_commands_at_breakpoint): Declare.
11746 (run_breakpoint_commands): Declare.
11747 * mem-break.c (struct point_command_list): New struct.
11748 (struct breakpoint): New field command_list.
11749 (any_persistent_commands): New function.
11750 (add_commands_to_breakpoint): New function.
11751 (add_breakpoint_commands): New function.
11752 (gdb_no_commands_at_breakpoint): New function.
11753 (run_breakpoint_commands): New function.
11754 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
11756 * ax.c: Include format.h.
11757 (ax_printf): New function.
11758 (gdb_eval_agent_expr): Add printf opcode.
11760 2012-06-13 Yao Qi <yao@codesourcery.com>
11762 * server.c (start_inferior): Remove duplicated writes to fields
11763 'last_resume_kind' and 'last_status' of 'current_inferior'.
11765 2012-06-12 Yao Qi <yao@codesourcery.com>
11766 Pedro Alves <palves@redhat.com>
11768 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
11770 * server.c (handle_v_cont): Extend comment.
11772 2012-06-11 Yao Qi <yao@codesourcery.com>
11774 * linux-low.c (linux_attach): Add 'static'.
11776 2012-06-06 Yao Qi <yao@codesourcery.com>
11778 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
11780 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
11782 Fix gcc -flto compilation warning.
11783 * server.c (main): Make variable multi_mode and attach volatile.
11785 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
11787 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
11788 if the platform doesn't know about it.
11790 2012-05-30 Jeff Kenton <jkenton@tilera.com>
11792 * Makefile.in (SFILES): Add linux-tile-low.c.
11793 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
11794 * configure.srv: Handle tilegx-*-linux*.
11795 * linux-tile-low.c: New file.
11797 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
11799 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
11801 2012-05-24 Pedro Alves <palves@redhat.com>
11805 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
11807 2012-05-24 Pedro Alves <palves@redhat.com>
11811 Replace target_signal with gdb_signal throughout.
11813 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
11815 * linux-low.c (linux_store_registers): Avoid the copying sequence
11816 when no data has been retrieved by ptrace.
11818 2012-05-22 Will Deacon <will.deacon@arm.com>
11820 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
11821 Include asm/ptrace.h.
11822 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
11825 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
11827 * linux-low.c (linux_store_registers): Don't re-retrieve data
11828 with ptrace that has already been obtained from /proc. Always
11829 copy any data retrieved with ptrace to the buffer supplied.
11831 2012-05-11 Yao Qi <yao@codesourcery.com>
11832 Pedro Alves <palves@redhat.com>
11834 * linux-low.c (enum stopping_threads_kind): New.
11835 (stopping_threads): Change type to `enum stopping_threads_kind'.
11836 (handle_extended_wait): If stopping and suspending threads, leave
11837 the new_lwp suspended too.
11838 (linux_wait_for_event): Adjust.
11839 (stop_all_lwps): Set `stopping_threads' to
11840 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
11841 whether we're suspending threads or just stopping them. Assert no
11844 2012-04-29 Yao Qi <yao@codesourcery.com>
11846 * server.h: Move some code to ...
11847 * gdbthread.h: ... here. New.
11848 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
11849 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
11850 (nto-low.o, win32-low.o): Likewise.
11851 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
11852 * regcache.c, remote-utils.c, server.c: Likewise.
11853 * target.c, tracepoint.c, win32-low.c: Likewise.
11855 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
11857 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
11858 (PTRACE_ARG4_TYPE): Likewise.
11859 (PTRACE_XFER_TYPE): Likewise.
11860 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
11861 ptrace to PTRACE_ARG3_TYPE.
11862 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
11863 (PTRACE_ARG4_TYPE): Likewise.
11864 (PTRACE_XFER_TYPE): Likewise.
11865 (linux_detach_one_lwp): Cast fourth argument of
11866 ptrace to long then PTRACE_ARG4_TYPE.
11867 (regsets_fetch_inferior_registers): Cast third argument of
11868 ptrace to long then PTRACE_ARG3_TYPE.
11869 (regsets_store_inferior_registers): Likewise.
11871 2012-04-20 Pedro Alves <palves@redhat.com>
11873 * configure: Regenerate.
11875 2012-04-19 Pedro Alves <palves@redhat.com>
11877 * Makefile.in (GNULIB_BUILDDIR): New.
11878 (LIBGNU, INCGNU, GNULIB_H): Adjust.
11879 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
11880 (all, install-only, uninstall, clean-info, all-lib, clean): No
11881 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
11882 (maintainer-clean realclean distclean): Use subdir_do.
11884 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
11885 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
11886 * acinclude.m4: Include acx_configure_dir.m4.
11887 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
11888 calls. Call AC_PROG_RANLIB. Configure gnulib using
11891 (GNULIB_STDINT_H): Adjust.
11892 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
11893 * gdbreplay.c: Include build-gnulib/config.h.
11894 * server.h: Likewise.
11895 * aclocal.m4: Regenerate.
11896 * config.in: Regenerate.
11897 * configure: Regenerate.
11899 2012-04-19 Pedro Alves <palves@redhat.com>
11901 * Makefile.in (LIBGNU, INCGNU): Adjust.
11902 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
11903 (all, install-only, uninstall, clean-info, all-lib, clean)
11904 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
11905 * configure.ac: Adjust AC_OUTPUT output.
11906 * aclocal.m4: Regenerate.
11907 * configure: Regenerate.
11909 2012-04-19 Pedro Alves <palves@redhat.com>
11911 * Makefile.in (generated_files): New.
11912 (server_h): Remove the explicit dependency on config.h, and depend
11913 on $generated_files.
11915 2012-04-19 Pedro Alves <palves@redhat.com>
11917 * Makefile.in (INCGNU): Add -Ignulib.
11919 2012-04-19 Pedro Alves <palves@redhat.com>
11921 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
11922 (INCGNU): ... this, and spell out -I here.
11923 (GNULIB_LIB): Rename to ...
11924 (LIBGNU): ... this.
11925 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
11927 2012-04-19 Pedro Alves <palves@redhat.com>
11929 * config.in: Regenerate.
11931 2012-04-19 Pedro Alves <palves@redhat.com>
11933 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
11934 * server.h (memmem): Remove declaration.
11935 * config.in: Regenerate.
11936 * configure: Regenerate.
11938 2012-04-19 Yao Qi <yao@codesourcery.com>
11940 * Makefile.in (SFILES): Add common/vec.c.
11944 2012-04-19 Yao Qi <yao@codesourcery.com>
11946 * remote-utils.c (prepare_resume_reply): Replace with macro
11947 target_core_of_thread.
11948 * server.c (handle_qxfer_threads_proper): Likewise.
11949 * target.h (traget_core_of_thread): New macro.
11951 2012-04-18 Pedro Alves <palves@redhat.com>
11953 * aclocal.m4: Regenerate.
11954 * configure: Regenerate.
11956 2012-04-16 Yao Qi <yao@codesourcery.com>
11958 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
11959 duplicated on address.
11961 2012-04-16 Yao Qi <yao@codesourcery.com>
11963 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
11964 (struct tracepoint_action_ops) <send>: New field.
11965 (m_tracepoint_action_send, r_tracepoint_action_send): New.
11966 (agent_expr_send, x_tracepoint_action_send): New.
11967 (l_tracepoint_action_send): New.
11968 (cmd_qtdp): Download and install tracepoint
11969 according to `use_agent'.
11970 (run_inferior_command): Add one more parameter `len'.
11972 (tracepoint_send_agent): New.
11973 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
11975 2012-04-16 Yao Qi <yao@codesourcery.com>
11977 * tracepoint.c (download_tracepoints): Moved to ...
11978 (cmd_qtstart): ... here.
11980 2012-04-14 Yao Qi <yao@codesourcery.com>
11982 * tracepoint.c: Include inttypes.h.
11983 (struct collect_memory_action): Use sized types.
11984 (struct tracepoint): Likewise.
11985 (cmd_qtdp, stop_tracing): Update print specifiers.
11986 (cmd_qtp, response_tracepoint): Likewise.
11987 (collect_data_at_tracepoint): Likewise.
11988 (collect_data_at_step): Likewise.
11990 2012-04-14 Yao Qi <yao@codesourcery.com>
11992 Import gnulib module inttypes.
11993 * aclocal.m4, config.in, configure: Regenerated.
11995 2012-04-14 Yao Qi <yao@codesourcery.com>
11997 * Makefile.in (maintainer-clean, realclean, distclean): Remove
11998 Makefile and config.status at last.
12000 2012-04-13 Yao Qi <yao@codesourcery.com>
12002 * tracepoint.c: Include stdint.h unconditionally.
12004 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
12006 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
12007 on BFD_HAVE_SYS_PROCFS_TYPE.
12008 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
12009 * configure: Regenerate.
12010 * config.in: Likewise.
12012 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
12014 * Makefile.in (clean): Also remove x32.c x32-linux.c
12015 x32-avx.c x32-avx-linux.c.
12016 (x32.o): New target.
12018 (x32-linux.o): Likewise.
12019 (x32-linux.c): Likewise.
12020 (x32-avx.o): Likewise.
12021 (x32-avx.c): Likewise.
12022 (x32-avx-linux.o): Likewise.
12023 (x32-avx-linux.c): Likewise.
12025 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
12026 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
12027 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
12028 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
12029 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
12030 i386/x32-avx-linux.xml.
12032 * linux-x86-low.c (init_registers_x32_linux): New prototype.
12033 (init_registers_x32_avx_linux): Likwise.
12034 (x86_linux_update_xmltarget): Call init_registers_x32_linux
12035 or init_registers_x32_avx_linux if linux_is_elf64 is false.
12037 2012-04-13 Pedro Alves <palves@redhat.com>
12039 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
12040 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
12041 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
12042 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
12045 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
12047 * linux-x86-low.c (compat_x32_clock_t): New.
12048 (compat_x32_siginfo_t): Likewise.
12049 (compat_x32_siginfo_from_siginfo): Likewise.
12050 (siginfo_from_compat_x32_siginfo): Likewise.
12051 (linux_is_elf64): Likewise.
12052 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
12053 and siginfo_from_compat_x32_siginfo for x32.
12054 (x86_arch_setup): Set linux_is_elf64.
12056 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
12059 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
12061 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
12062 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
12063 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
12064 compatible with process.
12066 2012-04-12 Yao Qi <yao@codesourcery.com>
12068 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
12069 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
12070 (install-only, install-info, clean): Handle sub dir gnulib.
12071 (all-lib, am--refresh): New targets.
12072 (memmem.o): Remove target.
12073 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
12074 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
12075 (AC_REPLACE_FUNCS): Remove memmem.
12076 Invoke gl_INIT and AM_INIT_AUTOMAKE.
12077 (AC_OUTPUT): Generate Makefile in gnulib/.
12078 * aclocal.m4, config.in, configure: Regenerated.
12080 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
12082 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
12084 2012-04-05 Pedro Alves <palves@redhat.com>
12086 -Werror=strict-aliasing
12088 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
12091 2012-04-04 Pedro Alves <palves@redhat.com>
12093 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
12094 (sparc_store_gregset_from_stack, sparc_store_gregset)
12095 (sparc_breakpoint_at): Fix formatting.
12097 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
12099 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
12101 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
12102 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
12103 * config.in: Regenerate.
12104 * configure: Likewise.
12106 2012-03-29 Pedro Alves <palves@redhat.com>
12108 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
12109 Correct ptrace arguments.
12111 2012-03-28 Pedro Alves <palves@redhat.com>
12113 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
12114 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
12115 (IA64_FR1_REGNUM): New defines.
12116 (ia64_fetch_register): New.
12117 (the_low_target): Install it.
12118 * linux-low.h (struct linux_target_ops) <fetch_register>: New
12120 * linux-low.c (linux_fetch_registers): Try the
12121 the_low_target.fetch_register hook first.
12123 * linux-arm-low.c (the_low_target): Adjust.
12124 * linux-bfin-low.c (the_low_target): Adjust.
12125 * linux-cris-low.c (the_low_target): Adjust.
12126 * linux-crisv32-low.c (the_low_target): Adjust.
12127 * linux-m32r-low.c (the_low_target): Adjust.
12128 * linux-m68k-low.c (the_low_target): Adjust.
12129 * linux-mips-low.c (the_low_target): Adjust.
12130 * linux-ppc-low.c (the_low_target): Adjust.
12131 * linux-s390-low.c (the_low_target): Adjust.
12132 * linux-sh-low.c (the_low_target): Adjust.
12133 * linux-sparc-low.c (the_low_target): Adjust.
12134 * linux-tic6x-low.c (the_low_target): Adjust.
12135 * linux-x86-low.c (the_low_target): Adjust.
12136 * linux-xtensa-low.c (the_low_target): Adjust.
12138 2012-03-26 Pedro Alves <palves@redhat.com>
12140 * server.c (handle_qxfer_libraries): Don't bail early if
12141 the_target->qxfer_libraries_svr4 is not NULL.
12143 2012-03-26 Pedro Alves <palves@redhat.com>
12145 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
12147 2012-03-23 Pedro Alves <palves@redhat.com>
12149 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
12150 "library-list-svr4" element's start tag when the the DSO list is
12153 2012-03-23 Pedro Alves <palves@redhat.com>
12155 * linux-low.c (read_one_ptr): Read the inferior's pointer through
12156 a variable whose type size is the same as the inferior's pointer
12159 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
12161 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
12163 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
12164 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
12165 * linux-low.h: Include <signal.h>.
12166 (struct siginfo): Remove forward declaration.
12167 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
12170 2012-03-21 Mike Frysinger <vapier@gentoo.org>
12172 * .gitignore: Ignore more files.
12174 2012-03-19 Pedro Alves <palves@redhat.com>
12175 Jan Kratochvil <jan.kratochvil@redhat.com>
12177 * server.c (cont_thread, general_thread): Add describing comments.
12178 (start_inferior): Clear `cont_thread'.
12179 (handle_v_cont): Don't set `cont_thread' if resuming all threads
12182 2012-03-15 Yao Qi <yao@codesourcery.com>
12184 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
12186 (cmd_qtdp): ... here.
12188 2012-03-15 Yao Qi <yao@codesourcery.com>
12190 * tracepoint.c (struct tracepoint_action_ops): New.
12191 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
12192 (m_tracepoint_action_download): New.
12193 (r_tracepoint_action_download): New.
12194 (x_tracepoint_action_download): New.
12195 (l_tracepoint_action_download): New.
12196 (add_tracepoint_action): Install `action->ops' according type.
12197 (download_tracepoint_1): Move code `download' function pointer
12198 of various tracepoint_action_ops.
12200 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
12202 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
12203 linux_ptrace_attach_warnings.
12205 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
12207 * Makefile.in (linux-ptrace.o): New.
12208 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
12209 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
12210 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
12211 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
12212 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
12214 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
12216 2012-03-08 Yao Qi <yao@codesourcery.com>
12217 Pedro Alves <palves@redhat.com>
12219 Fix PR server/13392.
12220 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
12221 offset of JMP insn.
12222 * tracepoint.c (remove_tracepoint): New.
12223 (cmd_qtdp): Call remove_tracepoint when failed to install.
12225 2012-03-07 Pedro Alves <palves@redhat.com>
12227 * linux-low.c (get_detach_signal): New.
12228 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
12229 Pass on pending signals to PTRACE_DETACH. Check the result of the
12231 * server.c (program_signals, program_signals_p): New.
12232 (handle_general_set): Handle QProgramSignals.
12233 * server.h (program_signals, program_signals_p): Declare.
12235 2012-03-05 Pedro Alves <palves@redhat.com>
12236 Jan Kratochvil <jan.kratochvil@redhat.com>
12238 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
12241 2012-03-03 Yao Qi <yao@codesourcery.com>
12243 * tracepoint.c (tracepoint_look_up_symbols): Update call to
12244 agent_look_up_symbols.
12246 2012-03-03 Yao Qi <yao@codesourcery.com>
12248 * Makefile.in (linux-low.o): Keep dependence on agent.h.
12249 (linux-x86-low.o): Likewise.
12250 * server.h: Remove in_process_agent_loaded.
12251 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
12255 2012-03-03 Yao Qi <yao@codesourcery.com>
12257 * tracepoint.c (gdb_agent_capability): New global.
12258 (in_process_agent_loaded_ust): Renamed to
12259 `in_process_agent_supports_ust'.
12261 (in_process_agent_supports_ust): Call agent_capability_check.
12262 (clear_installed_tracepoints): Assert that agent supports
12265 2012-03-03 Yao Qi <yao@codesourcery.com>
12267 * linux-low.c (linux_supports_agent): New.
12268 (linux_target_ops): Initialize field `supports_agent' with
12269 linux_supports_agent.
12270 * target.h (struct target_ops) <supports_agent>: New.
12271 (target_supports_agent): New macro.
12272 * server.c (handle_general_set): Handle packet 'QAgent'.
12273 (handle_query): Send `QAgent+'.
12274 * Makefile.in (server.o): Depends on agent.h.
12276 2012-03-03 Yao Qi <yao@codesourcery.com>
12278 * Makefile.in (OBS): Add agent.o.
12279 Add new rule for agent.o.
12280 Track dependence of tracepoint.c on agent.h.
12281 * tracepoint.c (run_inferior_command_1):
12282 (run_inferior_command): Call agent_run_command.
12283 (gdb_ust_connect_sync_socket): Deleted. Move it to
12285 (resume_thread, stop_thread): Likewise.
12286 (gdb_ust_socket_init): Renamed to ...
12287 (gdb_agent_socket_init): ... New.
12288 (gdb_ust_thread): Renamed to ...
12289 (gdb_agent_helper_thread): ... New.
12290 (gdb_ust_init): Move some code to ...
12291 (gdb_agent_init): ... here. New.
12292 [HAVE_UST]: Call gdb_ust_init.
12293 (initialize_tracepoint_ftlib): Call gdb_agent_init.
12294 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
12295 * config.in, configure: Regenerated.
12297 2012-03-02 Pedro Alves <palves@redhat.com>
12299 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
12300 * linux-low.c (struct simple_pid_list): New.
12301 (stopped_pids): New a struct simple_pid_list pointer.
12302 (add_to_pid_list, pull_pid_from_list): New.
12303 (handle_extended_wait): Don't assume the first signal new children
12304 report is SIGSTOP. Adjust call to pull_pid_from_list.
12305 (linux_wait_for_lwp): Adjust.
12307 2012-03-02 Yao Qi <yao@codesourcery.com>
12309 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
12312 2012-03-02 Yao Qi <yao@codesourcery.com>
12314 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
12315 `stop_pc' and `tpoint'. Update caller.
12317 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
12319 * linux-low.h (linux_target_ops): Add regset_bitmap member.
12320 * linux-low.c (use_linux_regsets): New macro.
12321 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
12322 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
12323 (linux_register_in_regsets): New function.
12324 (usr_fetch_inferior_registers): Skip registers covered by
12326 (usr_store_inferior_registers): Likewise.
12327 (usr_fetch_inferior_registers): New macro.
12328 (usr_store_inferior_registers): Likewise.
12329 (linux_fetch_registers): Handle mixed regset/non-regset targets.
12330 (linux_store_registers): Likewise.
12331 * linux-mips-low.c (init_registers_mips_dsp_linux): New
12333 (init_registers_mips64_dsp_linux): Likewise.
12334 (init_registers_mips_linux): New macro.
12335 (init_registers_mips_dsp_linux): Likewise.
12336 (mips_dsp_num_regs): Likewise.
12337 (DSP_BASE, DSP_CONTROL): New fallback macros.
12338 (mips_base_regs): New macro.
12339 (mips_regmap): Use it. Fix the size.
12340 (mips_dsp_regmap): New variable.
12341 (mips_dsp_regset_bitmap): Likewise.
12342 (mips_arch_setup): New function.
12343 (mips_cannot_fetch_register): Use the_low_target.regmap rather
12345 (mips_cannot_store_register): Likewise.
12346 (the_low_target): Update .arch_setup, .num_regs and .regmap
12347 initializers. Add .regset_bitmap initializer.
12348 * linux-arm-low.c (the_low_target): Add .regset_bitmap
12350 * linux-bfin-low.c (the_low_target): Likewise.
12351 * linux-cris-low.c (the_low_target): Likewise.
12352 * linux-crisv32-low.c (the_low_target): Likewise.
12353 * linux-ia64-low.c (the_low_target): Likewise.
12354 * linux-m32r-low.c (the_low_target): Likewise.
12355 * linux-m68k-low.c (the_low_target): Likewise.
12356 * linux-ppc-low.c (the_low_target): Likewise.
12357 * linux-s390-low.c (the_low_target): Likewise.
12358 * linux-sh-low.c (the_low_target): Likewise.
12359 * linux-sparc-low.c (the_low_target): Likewise.
12360 * linux-tic6x-low.c (the_low_target): Likewise.
12361 * linux-x86-low.c (the_low_target): Likewise.
12362 * linux-xtensa-low.c (the_low_target): Likewise.
12363 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
12364 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
12365 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
12367 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
12368 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
12370 2012-02-29 Yao Qi <yao@codesourcery.com>
12371 Pedro Alves <palves@redhat.com>
12373 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
12374 `step_over_finished' is true.
12376 2012-02-27 Pedro Alves <palves@redhat.com>
12378 * linux-low.c (pid_is_stopped): Delete, moved to common/.
12379 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
12381 2012-02-27 Pedro Alves <palves@redhat.com>
12384 * linux-low.c (pid_is_stopped): New.
12385 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
12387 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
12389 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
12392 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
12394 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
12396 2012-02-24 Luis Machado <lgustavo@codesourcery>
12398 * server.c (handle_query): Advertise support for target-side
12399 breakpoint condition evaluation.
12400 (process_point_options): New function.
12401 (process_serial_event): When inserting a breakpoint, check for
12402 a target-side condition that should be evaluated.
12404 * mem-break.c: Include regcache.h and ax.h.
12405 (point_cond_list_t): New data structure.
12406 (breakpoint) <cond_list>: New field.
12407 (find_gdb_breakpoint_at): Make non-static.
12408 (delete_gdb_breakpoint_at): Clear any target-side
12410 (clear_gdb_breakpoint_conditions): New function.
12411 (add_condition_to_breakpoint): Likewise.
12412 (add_breakpoint_condition): Likewise.
12413 (gdb_condition_true_at_breakpoint): Likewise.
12414 (gdb_breakpoint_here): Return result directly instead
12415 of going through a local variable.
12417 * mem-break.h (find_gdb_breakpoint_at): New prototype.
12418 (clear_gdb_breakpoint_conditions): Likewise.
12419 (add_breakpoint_condition): Likewise.
12420 (gdb_condition_true_at_breakpoint): Likewise.
12422 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
12423 (need_step_over_p): Take target-side breakpoint condition into
12426 2012-02-24 Luis Machado <lgustavo@codesourcery>
12428 * server.h: Include tracepoint.h.
12429 (agent_mem_read, agent_get_trace_state_variable_value,
12430 agent_set_trace_state_variable_value,
12431 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
12432 get_set_tsv_func_addr): New prototypes.
12434 * ax.h: New include file.
12435 * ax.c: New source file.
12437 * tracepoint.c: Include ax.h.
12438 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
12439 agent_expr, eval_result_type): Move to ax.h.
12440 (parse_agent_expr): Rename to ...
12441 (gdb_parse_agent_expr): ... this, make it non-static and move
12443 (unparse_agent_expr) Rename to ...
12444 (gdb_unparse_agent_expr): ... this, make it non-static and move
12446 (eval_agent_expr): Rename to ...
12447 (eval_tracepoint_agent_expr): ... this.
12448 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
12449 forward declarations.
12450 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
12451 (agent_get_trace_state_variable_value): New function.
12452 (agent_set_trace_state_variable_value): New function.
12453 (cmd_qtdp): Call gdb_parse_agent_expr (...).
12454 (response_tracepoint): Call gdb_unparse_agent_expr (...).
12455 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
12456 (condition_true_at_tracepoint): Likewise.
12457 (parse_agent_expr): Rename to ...
12458 (gdb_parse_agent_expr): ... this and move to ax.c.
12459 (unparse_agent_expr): Rename to ...
12460 (gdb_unparse_agent_expr): ... this and move to ax.c.
12461 (gdb_agent_op_name): Move to ax.c.
12462 (eval_agent_expr): Rename to ...
12463 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
12465 (eval_tracepoint_agent_expr): New function.
12466 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
12468 (current_insn_ptr, emit_error, struct bytecode_address): Move to
12470 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
12471 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
12472 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
12473 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
12474 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
12475 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
12476 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
12477 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
12478 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
12479 (compile_bytecodes): Remove forward declaration.
12480 (is_goto_target): Move to ax.c.
12481 (compile_bytecodes): Move to ax.c and call
12482 agent_get_trace_state_variable_value (...) and
12483 agent_set_trace_state_variable_value (...).
12485 * Makefile.in: Update ax.c and IPA dependencies.
12487 2012-02-24 Pedro Alves <palves@redhat.com>
12489 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
12490 (cmd_bigqtbuffer_circular): ... this. Only handle
12491 'QTBuffer:circular:'.
12492 (handle_tracepoint_general_set): Adjust.
12494 2012-02-16 Yao Qi <yao@codesourcery.com>
12496 * inferiors.c: Move code to ...
12497 * dll.c: .... here. New.
12498 * server.h: Declare clear_dlls.
12499 * Makefile.in (SFILES): Add dll.c.
12503 2012-02-11 Yao Qi <yao@codesourcery.com>
12505 * server.c: (handle_monitor_command): Add a new parameter
12507 (handle_query): Update caller.
12509 2012-02-09 Joel Brobecker <brobecker@adacore.com>
12511 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
12512 * configure, config.in: Regenerate.
12513 * hostio.c: Provide an alternate implementation if HAVE_READLINK
12516 2012-02-02 Pedro Alves <palves@redhat.com>
12518 Try SIGKILL first, then PTRACE_KILL.
12519 * linux-low.c (linux_kill_one_lwp): New.
12520 (linux_kill_one_lwp): Rename to ...
12521 (kill_one_lwp_callback): ... this. Use the new
12522 linux_kill_one_lwp.
12524 2012-02-02 Pedro Alves <palves@redhat.com>
12526 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
12529 2012-01-27 Pedro Alves <palves@redhat.com>
12531 * linux-low.c (linux_child_pid_to_exec_file): Delete.
12532 (elf_64_file_p): Make static.
12533 (linux_pid_exe_is_elf_64_file): New.
12534 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
12535 Delete declarations.
12536 (linux_pid_exe_is_elf_64_file): Declare.
12537 * linux-x86-low.c (x86_arch_setup): Use
12538 linux_pid_exe_is_elf_64_file.
12540 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
12542 * linux-low.c (linux_wait_for_event_1): Rename to ...
12543 (linux_wait_for_event): ... here and merge it with former
12544 linux_wait_for_event - new variable wait_ptid, use it.
12545 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
12547 2012-01-23 Pedro Alves <palves@redhat.com>
12549 * server.c (main): Avoid yet another case of infinite loop while
12550 detaching/killing after a longjmp.
12552 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12555 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
12557 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
12559 * hostio.c (handle_readlink): New function.
12560 (handle_vFile): Call it to handle "vFile:readlink" packets.
12562 2012-01-20 Pedro Alves <palves@redhat.com>
12563 Ulrich Weigand <ulrich.weigand@linaro.org>
12565 * server.c (handle_v_requests): Only support vAttach and vRun to
12566 start multiple processes when in extended protocol mode.
12568 2012-01-17 Pedro Alves <palves@redhat.com>
12570 * tracepoint.c (initialize_tracepoint): Use mmap instead of
12571 memalign plus mprotect to allocate the scratch buffer.
12573 2012-01-13 Pedro Alves <palves@redhat.com>
12575 * server.c (attach_inferior): Clear `cont_thread'.
12577 2012-01-13 Pedro Alves <palves@redhat.com>
12579 * server.c (main): Avoid infinite loop while detaching/killing
12582 2012-01-09 Doug Evans <dje@google.com>
12584 * server.c (start_inferior): Set last_ptid in --wrapper case.
12586 2012-01-06 Yao Qi <yao@codesourcery.com>
12588 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
12590 [IN_PROCESS_AGENT] (debug_agent): New global variable.
12592 2012-01-04 Yao Qi <yao@codesourcery.com>
12594 * tracepoint.c (cmd_qtdp): Print debug message
12595 for static tracepoint.
12597 2012-01-04 Yao Qi <yao@codesourcery.com>
12599 * tracepoint.c (trace_vdebug): Differentiate debug message
12600 between gdbserver and IPA.
12602 2012-01-03 Yao Qi <yao@codesourcery.com>
12604 * tracepoint.c (tracepoint_was_hit): Don't collect for
12607 2012-01-02 Joel Brobecker <brobecker@adacore.com>
12609 * terminal.h: Reformat copyright header.
12611 2012-01-02 Joel Brobecker <brobecker@adacore.com>
12613 * server.c (gdbserver_version): Update copyright year.
12614 * gdbreplay.c (gdbreplay_version): Likewise.
12616 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
12618 * linux-low.c (linux_create_inferior): Put empty if clause for write.
12621 2011-12-18 Hui Zhu <teawater@gmail.com>
12622 * linux-low.c (linux_create_inferior): Save return value to ret.
12624 2011-12-18 Hui Zhu <teawater@gmail.com>
12626 * linux-low.c (linux_create_inferior): Save return value to ret.
12628 2011-12-16 Doug Evans <dje@google.com>
12630 * linux-low.c (linux_create_inferior): If stdio connection,
12631 redirect stdin from /dev/null, stdout to stderr.
12632 * remote-utils.c (remote_is_stdio): New static global.
12633 (remote_connection_is_stdio): New function.
12634 (remote_prepare): Handle stdio connection.
12635 (remote_open): Ditto.
12636 (remote_close): Don't close stdin for stdio connections.
12637 (read_prim,write_prim): New functions. Replace all calls to
12638 read/write to these.
12639 * server.c (main): Watch for "-" argument. Move call to
12640 remote_prepare before start_inferior.
12641 * server.h (STDIO_CONNECTION_NAME): New macro.
12642 (remote_connection_is_stdio): Declare.
12644 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
12645 in debugging output.
12647 2011-12-15 Yao Qi <yao@codesourcery.com>
12649 * tracepoint.c: Include sys/syscall.h.
12650 (gdb_ust_thread): Remove preprocessor conditional.
12652 2011-12-14 Pedro Alves <pedro@codesourcery.com>
12654 * linux-low.c (linux_detach_one_lwp): Call
12655 the_low_target.prepare_to_resume before detaching.
12657 2011-12-14 Yao Qi <yao@codesourcery.com>
12659 * tracepoint.c (gdb_ust_thread): Don't ignore return value
12662 2011-12-14 Yao Qi <yao@codesourcery.com>
12664 * i386-low.c (i386_low_stopped_data_address): Initialize local
12665 variable `control'.
12667 2011-12-13 Pedro Alves <pedro@codesourcery.com>
12671 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
12672 DR_CONTROL unless necessary. Extend comments.
12673 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
12674 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
12676 2011-12-13 Yao Qi <yao@codesourcery.com>
12678 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
12680 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
12682 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
12684 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
12685 Print new debug message for such case.
12687 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
12689 Fix overlapping memcpy.
12690 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
12691 the read_inferior_memory transfer.
12692 (delete_fast_tracepoint_jump): New variable buf. Use it for the
12693 write_inferior_memory transfer.
12694 (set_fast_tracepoint_jump): New variable buf. Use it for the
12695 read_inferior_memory and write_inferior_memory transfers.
12696 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
12697 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
12698 Use it for the write_inferior_memory transfer.
12699 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
12702 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
12704 * linux-low.c (fetch_register, store_register): Make code
12705 consistent, fix formatting.
12707 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
12709 * linux-low.c (usr_store_inferior_registers): Factor out code
12710 to handle individual registers into...
12711 (store_register): ... this new function.
12713 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
12715 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
12716 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
12717 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
12718 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
12719 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
12720 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
12721 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
12722 (srv_xmlfiles): Add new XML files.
12724 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
12726 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
12727 (init_registers_s390_linux32v1): Add prototype.
12728 (init_registers_s390_linux32v2): Likewise.
12729 (init_registers_s390_linux64v1): Likewise.
12730 (init_registers_s390_linux64v2): Likewise.
12731 (init_registers_s390x_linux64v1): Likewise.
12732 (init_registers_s390x_linux64v2): Likewise.
12733 (s390_num_regs): Increment to 52.
12734 (s390_regmap): Add orig_r2 register.
12735 (s390_num_regs_3264): Increment to 68.
12736 (s390_regmap_3264): Add orig_r2 register.
12737 (s390_collect_ptrace_register): Handle orig_r2 register.
12738 (s390_supply_ptrace_register): Likewise.
12739 (s390_fill_last_break): New function.
12740 (s390_store_last_break): Likewise.
12741 (s390_fill_system_call): New function.
12742 (s390_store_system_call): Likewise.
12743 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
12745 (s390_check_regset): New function.
12746 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
12747 NT_S390_SYSTEM_CALL regsets and use appropriate description.
12748 Update target_regsets for available register sets.
12750 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
12751 Jan Kratochvil <jan.kratochvil@redhat.com>
12753 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
12754 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
12756 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
12757 * linux-low.h (struct process_info_private): New member r_debug.
12758 * server.c (handle_qxfer_libraries): Call
12759 the_target->qxfer_libraries_svr4.
12760 (handle_qxfer_libraries_svr4): New function.
12761 (qxfer_packets): New entry "libraries-svr4".
12762 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
12763 * target.h (struct target_ops): New member qxfer_libraries_svr4.
12764 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
12765 PACKET_qXfer_libraries_svr4.
12767 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
12769 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
12770 PSW address/mask between 8-byte and 16-byte formats.
12771 (s390_supply_ptrace_register): Likewise.
12772 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
12773 basic addressing mode bit.
12775 2011-11-24 Stan Shebs <stan@codesourcery.com>
12777 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
12779 2011-11-17 Stan Shebs <stan@codesourcery.com>
12781 * tracepoint.c (struct tracepoint): New field traceframe_usage.
12782 (tracing_start_time): New global.
12783 (tracing_stop_time): New global.
12784 (tracing_user_name): New global.
12785 (tracing_notes): New global.
12786 (tracing_stop_note): New global.
12787 (cmd_qtstart): Set traceframe_usage, start_time.
12788 (stop_tracing): Set stop_time.
12789 (cmd_qtstatus): Report additional status.
12790 (cmd_qtp): New function.
12791 (handle_tracepoint_query): Call it.
12792 (cmd_qtnotes): New function.
12793 (handle_tracepoint_general_set): Call it.
12794 (get_timestamp): Rename from tsv_get_timestamp.
12796 2011-11-14 Stan Shebs <stan@codesourcery.com>
12797 Kwok Cheung Yeung <kcy@codesourcery.com>
12799 * linux-x86-low.c (small_jump_insn): New.
12800 (i386_install_fast_tracepoint_jump_pad): Add arguments for
12801 trampoline and error message, build a trampoline and issue a small
12802 jump instruction to it.
12803 (x86_install_fast_tracepoint_jump_pad): Add arguments for
12804 trampoline and error message.
12805 (x86_get_min_fast_tracepoint_insn_len): New.
12806 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
12807 * linux-low.h (struct linux_target_ops): Add arguments to
12808 install_fast_tracepoint_jump_pad operation, add new operation.
12809 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
12811 (linux_get_min_fast_tracepoint_insn_len): New function.
12812 (linux_target_op): Add new operation.
12813 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
12814 (gdb_trampoline_buffer_end): Ditto.
12815 (gdb_trampoline_buffer_error): Ditto.
12816 (struct ipa_sym_addresses): Add fields for new IPA variables.
12817 (symbol_list): Add entries for new IPA variables.
12818 (struct tracepoint): Add fields to hold the address range of the
12819 trampoline used by the tracepoint.
12820 (trampoline_buffer_head): New static variable.
12821 (trampoline_buffer_tail): Ditto.
12822 (claim_trampoline_space): New function.
12823 (have_fast_tracepoint_trampoline_buffer): New function.
12824 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
12826 (install_fast_tracepoint): Ditto, also add error buffer argument.
12827 (cmd_qtminftpilen): New function.
12828 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
12829 (fast_tracepoint_from_trampoline_address): New function.
12830 (fast_tracepoint_collecting): Handle trampoline as part of jump
12832 (set_trampoline_buffer_space): New function.
12833 (initialize_tracepoint): Initialize new IPA variables.
12834 * target.h (struct target_ops): Add arguments to
12835 install_fast_tracepoint_jump_pad operation, add new
12836 get_min_fast_tracepoint_insn_len operation.
12837 (target_get_min_fast_tracepoint_insn_len): New.
12838 (install_fast_tracepoint_jump_pad): Add arguments.
12839 * server.h (IPA_BUFSIZ): Define.
12840 * linux-i386-ipa.c: Include extra header files.
12841 (initialize_fast_tracepoint_trampoline_buffer): New function.
12842 (initialize_low_tracepoint): Call it.
12843 * server.h (set_trampoline_buffer_space): Declare.
12844 (claim_trampoline_space): Ditto.
12845 (have_fast_tracepoint_trampoline_buffer): Ditto.
12847 2011-11-14 Yao Qi <yao@codesourcery.com>
12849 * server.c (handle_query): Handle InstallInTrace for qSupported.
12850 * tracepoint.c (add_tracepoint): Sort list.
12851 (install_tracepoint, download_tracepoint): New.
12852 (cmd_qtdp): Call them to install and download tracepoints.
12853 (sort_tracepoints): Removed.
12854 (cmd_qtstart): Update.
12856 2011-11-14 Yao Qi <yao@codesourcery.com>
12858 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
12859 * mem-break.h: Declare.
12860 * tracepoint.c (cmd_qtstart): Move some code to ...
12861 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
12863 (download_tracepoints): Move some code to ...
12864 (download_tracepoint_1): ... here. New.
12866 2011-11-08 Yao Qi <yao@codesourcery.com>
12868 * remote-utils.c (relocate_instruction): A comment fix.
12870 2011-11-07 Joel Brobecker <brobecker@adacore.com>
12872 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
12873 (i386_dr_low_get_control, i386_dr_low_get_status): Use
12874 dr_status_mirror and dr_control_mirror from debug_reg_state.
12875 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
12876 (i386_initial_stuff): Remove use of deleted globals.
12877 (i386_get_thread_context, i386_set_thread_context,
12878 i386_thread_added): Use dr_status_mirror and dr_control_mirror
12879 from debug_reg_state.
12881 2011-11-05 Yao Qi <yao@codesourcery.com>
12883 * tracepoint.c (gdb_collect): Loop over tracepoints of same
12884 address as TPOINT's.
12886 2011-11-02 Stan Shebs <stan@codesourcery.com>
12888 * tracepoint.c (agent_mem_read_string): New function.
12889 (eval_agent_expr): Call it for tracenz.
12890 * server.c (handle_query): Report support for tracenz.
12892 2011-11-02 Yao Qi <yao@codesourcery.com>
12894 * tracepoint.c (cmd_qtstart): Remove unused local variables.
12896 2011-11-02 Yao Qi <yao@codesourcery.com>
12898 * target.h: Fix a typo in comment.
12900 2011-10-31 Pedro Alves <pedro@codesourcery.com>
12902 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
12903 clobber the breakpoints' shadows with fast tracepoint jumps.
12904 * mem-break.h (check_mem_write): Add `myaddr' parameter.
12905 * target.c (write_inferior_memory): Also pass MYADDR down to
12908 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
12910 * configure.ac: Check support for personality routine.
12911 * configure: Regenerate.
12912 * config.in: Likewise.
12913 * linux-low.c: Include <sys/personality.h>.
12914 Define ADDR_NO_RANDOMIZE if necessary.
12915 (linux_create_inferior): Disable address space randomization when
12916 forking inferior, if requested.
12917 (linux_supports_disable_randomization): New function.
12918 (linux_target_ops): Install it.
12919 * server.h (disable_randomization): Declare.
12920 * server.c (disable_randomization): New global variable.
12921 (handle_general_set): Handle QDisableRandomization.
12922 (handle_query): Likewise for qSupported.
12923 (main): Support --disable-randomization and --no-disable-randomization
12924 command line arguments.
12925 * target.h (struct target_ops): Add supports_disable_randomization.
12926 (target_supports_disable_randomization): New macro.
12928 2011-09-29 Mike Frysinger <vapier@gentoo.org>
12930 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
12932 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
12933 [!PT_GETDSBT] (target_loadmap): New definition.
12934 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
12935 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
12936 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
12937 and PT_GETDSBT to LINUX_LOADMAP.
12938 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
12939 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
12941 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
12943 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
12944 (arm_linux_hwbp_cap): New static variable.
12945 (arm_linux_get_hwbp_cap): Replace by ...
12946 (arm_linux_init_hwbp_cap): ... this new function.
12947 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
12948 (arm_linux_get_hw_watchpoint_count): Likewise.
12949 (arm_linux_get_hw_watchpoint_max_length): Likewise.
12950 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
12951 (arm_prepare_to_resume): Use perror_with_name instead of error.
12953 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
12955 * linux-arm-low.c: Include <signal.h>.
12956 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
12957 (struct arm_linux_hwbp_cap): New data type.
12958 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
12959 (struct arm_linux_hw_breakpoint): New data type.
12960 (MAX_BPTS, MAX_WPTS): Define.
12961 (struct arch_process_info, struct arch_lwp_info): New data types.
12962 (arm_linux_get_hwbp_cap): New function.
12963 (arm_linux_get_hw_breakpoint_count): Likewise.
12964 (arm_linux_get_hw_watchpoint_count): Likewise.
12965 (arm_linux_get_hw_watchpoint_max_length): Likewise.
12966 (arm_hwbp_control_initialize): Likewise.
12967 (arm_hwbp_control_is_enabled): Likewise.
12968 (arm_hwbp_control_is_initialized): Likewise.
12969 (arm_hwbp_control_disable): Likewise.
12970 (arm_linux_hw_breakpoint_equal): Likewise.
12971 (arm_linux_hw_point_initialize): Likewise.
12972 (struct update_registers_data): New data structure.
12973 (update_registers_callback: New function.
12974 (arm_insert_point): Likewise.
12975 (arm_remove_point): Likewise.
12976 (arm_stopped_by_watchpoint): Likewise.
12977 (arm_stopped_data_address): Likewise.
12978 (arm_new_process): Likewise.
12979 (arm_new_thread): Likewise.
12980 (arm_prepare_to_resume): Likewise.
12981 (the_low_target): Register arm_insert_point, arm_remove_point,
12982 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
12983 arm_new_thread, and arm_prepare_to_resume.
12985 2011-09-15 Stan Shebs <stan@codesourcery.com>
12987 * server.h (struct emit_ops): Add compare-goto fields.
12988 * tracepoint.c (gdb_agent_op_sizes): New table.
12989 (emit_eq_goto): New function.
12990 (emit_ne_goto): New function.
12991 (emit_lt_goto): New function.
12992 (emit_le_goto): New function.
12993 (emit_gt_goto): New function.
12994 (emit_ge_goto): New function.
12995 (is_goto_target): New function.
12996 (compile_bytecodes): Recognize special cases of compare-goto
12997 combinations and call specialized emitters for them.
12998 * linux-x86-low.c (amd64_emit_eq_goto): New function.
12999 (amd64_emit_ne_goto): New function.
13000 (amd64_emit_lt_goto): New function.
13001 (amd64_emit_le_goto): New function.
13002 (amd64_emit_gt_goto): New function.
13003 (amd64_emit_ge_goto): New function.
13004 (amd64_emit_ops): Add the new functions.
13005 (i386_emit_eq_goto): New function.
13006 (i386_emit_ne_goto): New function.
13007 (i386_emit_lt_goto): New function.
13008 (i386_emit_le_goto): New function.
13009 (i386_emit_gt_goto): New function.
13010 (i386_emit_ge_goto): New function.
13011 (i386_emit_ops): Add the new functions.
13013 2011-09-08 Stan Shebs <stan@codesourcery.com>
13015 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
13016 (i386_emit_epilogue): Restore %ebx.
13018 2011-08-31 Jie Zhang <jzhang918@gmail.com>
13020 * server.c (step_thread): Remove definition.
13021 (process_serial_event): Don't handle Hs.
13022 * server.h (step_thread): Remove declaration.
13023 * target.c (set_desired_inferior): Remove use of step_thread.
13025 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
13027 * linux-low.c: Include linux-procfs.h.
13028 (linux_attach_lwp_1): Update comments.
13029 (linux_attach): Scan for existing threads when attaching to a
13030 process that is the tgid.
13031 * Makefile.in: Update dependencies.
13033 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
13035 * configure.srv: Add linux-procfs.o dependencies.
13037 2011-08-14 Yao Qi <yao@codesourcery.com>
13039 * target.h (struct target_ops): Fix indent.
13040 * win32-low.c (win32_target_ops): Fix comment.
13042 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
13043 Yao Qi <yao@codesourcery.com>
13045 * Makefile.in (clean): Remove tic6x-*.c files.
13046 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
13047 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
13048 (tic6x-c64xp-linux.c): Likewise.
13049 * configure.srv: Add support for tic6x-*-uclinux.
13050 * linux-tic6x-low.c: New.
13051 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
13053 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
13054 Yao Qi <yao@codesourcery.com>
13056 * target.h (struct target_ops): Add read_loadmap.
13057 * linux-low.c (struct target_loadseg): New type.
13058 (struct target_loadmap): New type.
13059 (linux_read_loadmap): New function.
13060 (linux_target_ops): Add linux_read_loadmap.
13061 * server.c (handle_query): Support qXfer:fdpic:read packet.
13062 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
13065 2011-08-05 Eli Zaretskii <eliz@gnu.org>
13067 * win32-low.c: Include <stdint.h>.
13069 2011-07-22 Pedro Alves <pedro@codesourcery.com>
13071 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
13072 to the inferior here.
13073 (i386_remove_aligned_watchpoint): Ditto.
13074 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
13075 fit part of the watchpoint in the debug registers.
13076 (i386_update_inferior_debug_regs): New.
13077 (i386_low_insert_watchpoint): Work on a local mirror of the debug
13078 registers, and only update the inferior on success.
13079 (i386_low_remove_watchpoint): Ditto.
13081 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
13083 * linux-low.c (compare_ints, unique, list_threads, show_process,
13084 linux_core_of_thread): Delete.
13085 (linux_target_ops): Change linux_core_of_thread to
13086 linux_common_core_of_thread.
13087 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
13088 * utils.c (malloc_failure): Change type of argument.
13089 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
13090 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
13091 common/linux-osdata.c, common/ptid.c and common/buffer.c.
13092 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
13093 (IPA_OBJS): Add common-utils-ipa.o.
13094 (ptid_h, linux_osdata_h): New macros.
13095 (server_h): Add common/common-utils.h, common/xml-utils.h,
13096 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
13098 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
13099 ptid.o, buffer.o): New rules.
13100 (linux-low.o): Add common/linux-osdata.h as a dependency.
13101 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
13102 * configure.ac: Add AC_HEADER_DIRENT check.
13103 * config.in: Regenerate.
13104 * configure: Regenerate.
13105 * remote-utils.c (xml_escape_text): Delete.
13106 (buffer_grow, buffer_free, buffer_init, buffer_finish,
13107 buffer_xml_printf): Move to common/buffer.c.
13108 * server.c (main): Remove call to initialize_inferiors.
13109 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
13110 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
13111 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
13112 internal_error, gdb_assert, gdb_assert_fail): Delete.
13113 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
13114 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
13116 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
13117 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
13118 initialize_inferiors): Delete.
13120 2011-07-20 Pedro Alves <pedro@codesourcery.com>
13122 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
13125 2011-05-31 Pedro Alves <pedro@codesourcery.com>
13127 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
13129 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
13131 2011-05-26 Yao Qi <yao@codesourcery.com>
13133 * Makefile.in (thread-db.o): Track dependence to
13134 common/gdb_thread_db.h.
13135 * thread-db.c: include gdb_thread_db.h from right place.
13137 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
13139 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
13140 __FILE__ and __LINE__ to internal_error.
13142 2011-05-13 Doug Evans <dje@google.com>
13144 * thread-db.c (try_thread_db_load_from_sdir): New function.
13145 (try_thread_db_load_from_dir): New function.
13146 (thread_db_load_search): Handle $sdir, ignore $pdir.
13147 Remove trying of system directories if search of
13148 libthread-db-search-path fails, that is now done via $sdir.
13150 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
13152 * server.c (handle_query): Add EnableDisableTracepoints to the list
13153 of supported features.
13154 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
13156 (cmd_qtenable_disable): New.
13157 (cmd_qtstart): Install tracepoints even if disabled.
13158 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
13159 receiving a QTEnable or QTDisable packet.
13160 (gdb_collect): Skip data collection if fast tracepoint is disabled.
13161 (ust_marker_to_static_tracepoint): Do not ignore disabled static
13163 (gdb_probe): Skip data collection if static tracepoint is disabled.
13165 2011-05-10 Doug Evans <dje@google.com>
13167 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
13169 2011-05-04 Doug Evans <dje@google.com>
13171 * linux-low.c (linux_join): Skip process lookup.
13172 * spu-low.c (spu_join): Ditto.
13173 * server.c (join_inferiors_callback): Delete.
13174 (process_serial_event): For 'D' packet (detach) call join_inferior
13177 2011-05-04 Joseph Myers <joseph@codesourcery.com>
13179 * README: Don't mention xscale*-*-linux*.
13180 * configure.srv (xscale*-*-linux*): Don't handle target.
13182 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
13184 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
13186 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
13187 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
13188 (i386_emit_void_call_2): Likewise.
13190 2011-04-26 Yao Qi <yao@codesourcery.com>
13192 * linux-low.c: Move common macros to linux-ptrace.h.
13193 Include linux-ptrace.h.
13194 * Makefile.in (linux_ptrace_h): New.
13195 (linux-low.o): Depends on linux-ptrace.h.
13197 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
13199 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
13200 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
13201 (remote_prepare): New function with most of the TCP code from ...
13202 (remote_open): ... here. Detect PORT here unconditionally. Move also
13203 setting transport_is_reliable.
13204 * server.c (run_once): New variable.
13205 (gdbserver_usage): Document it.
13206 (main): Set run_once for `--once'. Call remote_prepare. Exit after
13207 the first run if RUN_ONCE.
13208 * server.h (run_once, remote_prepare): New declarations.
13210 2011-04-19 Tom Tromey <tromey@redhat.com>
13212 * win32-low.c (handle_load_dll): Remove duplicate "the".
13214 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
13216 Remove support for old Cygwin 1.5 versions.
13217 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
13218 function to avoid warning.
13219 (win32_add_one_solib): Use cygwin_conv_path function to avoid
13222 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
13224 * gdbserver/server.h (Macro _): Define it if not available.
13226 2011-03-14 Michael Snyder <msnyder@vmware.com>
13228 * hostio.c (handle_close): Remove unnecessary null test.
13230 2011-03-10 Joel Brobecker <brobecker@adacore.com>
13232 * Makefile.in (maintainer-clean realclean distclean): Remove
13233 "make ... subdir_do" command.
13235 2011-03-10 Michael Snyder <msnyder@vmware.com>
13237 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
13239 * server.c (handle_v_run): Free alloced buffer on early return.
13241 2011-03-09 Yao Qi <yao@codesourcery.com>
13244 2011-03-04 Yao Qi <yao@codesourcery.com>
13246 * Makefile.in: Remove GNU make feature --directory.
13248 2011-03-05 Yao Qi <yao@codesourcery.com>
13250 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
13251 (subdir_do): New make target. Copied from gdb/Makefile.
13252 (maintainer-clean, realclean, distclean, clean): Call corresponding
13253 make targets in common/Makefile.
13255 2011-02-11 Yao Qi <yao@codesourcery.com>
13257 * configure.ac: Call AC_PROG_RANLIB.
13258 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
13259 * configure: Regenerate.
13261 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
13263 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
13265 2011-03-06 Yao Qi <yao@codesourcery.com>
13267 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
13269 2011-03-05 Yao Qi <yao@codesourcery.com>
13271 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
13272 (subdir_do): New make target. Copied from gdb/Makefile.
13273 (maintainer-clean, realclean, distclean, clean): Call corresponding
13274 make targets in common/Makefile.
13276 2011-03-04 Yao Qi <yao@codesourcery.com>
13278 * Makefile.in: Remove GNU make feature --directory.
13280 2011-03-04 Michael Snyder <msnyder@vmware.com>
13282 * server.c (queue_stop_reply): Call xmalloc not malloc.
13284 2011-03-02 Michael Snyder <msnyder@vmware.com>
13286 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
13288 2011-02-28 Michael Snyder <msnyder@vmware.com>
13290 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
13291 (cmd_qtframe): Ditto.
13292 (cmd_qtbuffer): Ditto.
13293 (cmd_bigqtbuffer): Ditto.
13295 * utils.c (decimal2str): Initialize 'width' to nine, then
13296 don't mess with it.
13298 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
13300 * hostio.c (require_data): Free *data, not data.
13302 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13304 * hostio.c (require_data): Use free, not xfree.
13306 2011-02-27 Michael Snyder <msnyder@vmware.com>
13308 * server.c (handle_query): Discard unused value.
13310 * hostio.c (require_data): Free malloc memory before returning
13313 2011-02-26 Michael Snyder <msnyder@vmware.com>
13315 * linux-low.c (list_threads): Call closedir for dirent.
13317 2011-02-27 Michael Snyder <msnyder@vmware.com>
13319 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
13320 a case statement falls through.
13322 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
13324 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
13327 2011-02-26 Michael Snyder <msnyder@vmware.com>
13329 * utils.c (decimal2str): Eliminate dead code and dead param.
13330 (pulongest): Drop dead param from call to decimal2str.
13333 2011-02-24 Joel Brobecker <brobecker@adacore.com>
13335 Revert the following patch (not approved yet):
13336 2011-02-21 Hui Zhu <teawater@gmail.com>
13337 * tracepoint.c (tp_printf): New function.
13338 (eval_agent_expr): Handle gdb_agent_op_printf.
13340 2011-02-21 Hui Zhu <teawater@gmail.com>
13342 * tracepoint.c (tp_printf): New function.
13343 (eval_agent_expr): Handle gdb_agent_op_printf.
13345 2011-02-18 Tom Tromey <tromey@redhat.com>
13347 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
13348 (tracepoint.o): Likewise.
13349 * tracepoint.c (enum gdb_agent_op): Use ax.def.
13350 (gdb_agent_op_names): Likewise.
13352 2011-02-18 Tom Tromey <tromey@redhat.com>
13354 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
13355 gdb_agent_op_rot>: New constants.
13356 (gdb_agent_op_names): Add pick and roll.
13357 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
13360 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
13362 * aclocal.m4: Regenerated with aclocal-1.11.1.
13364 2011-02-14 Pedro Alves <pedro@codesourcery.com>
13366 * server.c (handle_qxfer_traceframe_info): New.
13367 (qxfer_packets): Register "traceframe-info".
13368 (handle_query): Report support for qXfer:traceframe-info:read+.
13369 * tracepoint.c (match_blocktype): New.
13370 (traceframe_find_block_type): Rename to ...
13371 (traceframe_walk_blocks): ... this. Add callback filter argument,
13373 (traceframe_find_block_type): New, reimplemented on top of
13374 traceframe_walk_blocks.
13375 (build_traceframe_info_xml): New.
13376 (traceframe_read_info): New.
13377 * server.h (traceframe_read_info): Declare.
13379 2011-02-11 Yao Qi <yao@codesourcery.com>
13381 * configure.ac: Call AC_PROG_RANLIB.
13382 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
13383 * configure: Regenerate.
13385 2011-02-07 Pedro Alves <pedro@codesourcery.com>
13387 * server.c (gdb_read_memory): Change return semantics to allow
13389 (handle_search_memory_1): Adjust.
13390 (process_serial_event) <'m' packet>: Handle partial transfers.
13391 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
13393 2011-01-28 Pedro Alves <pedro@codesourcery.com>
13395 * regcache.c (init_register_cache): Initialize
13396 regcache->register_status.
13397 (free_register_cache): Release regcache->register_status.
13398 (regcache_cpy): Copy register_status.
13399 (registers_to_string): Print 'x's for unavailable registers.
13400 (supply_register): Mark the register's status valid or
13401 unavailable, depending on whether a buffer was passed in or not.
13402 (supply_register_zeroed): New.
13403 (supply_regblock): Mark the registers' status valid or
13404 unavailable, depending on whether a buffer was passed in or not.
13405 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
13406 (struct regcache): New `register_status' field.
13407 (supply_register_zeroed): Declare.
13408 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
13409 supply_register_zeroed, rather than passing a NULL buffer to
13411 * tracepoint.c (fetch_traceframe_registers): Update comment.
13413 2011-01-28 Pedro Alves <pedro@codesourcery.com>
13415 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
13418 2011-01-25 Pedro Alves <pedro@codesourcery.com>
13420 * server.h (decode_xfer_write): Change prototype.
13421 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
13422 and don't extract the annex here.
13423 * server.c (decode_xfer_read): Remove `annex' parameter,
13424 and don't extract the annex here.
13425 (decode_xfer): New.
13426 (struct qxfer): New.
13427 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
13428 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
13429 (handle_qxfer_statictrace): New functions, abstracted out from
13430 handle_query, and made to use the struct qxfer interface.
13431 (handle_threads_qxfer_proper): Rename to ...
13432 (handle_qxfer_threads_proper): ... this.
13433 (handle_threads_qxfer): Rename to ...
13434 (handle_qxfer_threads): ... this. Adjust.
13435 (qxfer_packets): New array.
13436 (handle_qxfer): New function.
13437 (handle_query): Use handle_qxfer.
13439 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
13441 * gdbreplay.c: Shorten lines of >= 80 columns.
13442 * linux-low.c: Ditto.
13443 * linux-ppc-low.c: Ditto.
13444 * linux-s390-low.c: Ditto.
13445 * linux-sparc-low.c: Ditto.
13446 * linux-x86-low.c: Ditto.
13447 * linux-xtensa-low.c: Ditto.
13448 * mem-break.c: Ditto.
13449 * nto-low.c: Ditto.
13450 * regcache.h: Ditto.
13451 * remote-utils.c: Ditto.
13454 * thread-db.c: Ditto.
13455 * tracepoint.c: Ditto.
13457 * win32-low.h: Ditto.
13459 2011-01-05 Joel Brobecker <brobecker@adacore.com>
13461 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
13464 2011-01-01 Joel Brobecker <brobecker@adacore.com>
13466 * server.c (gdbserver_version): Update copyright year in version
13468 * gdbreplay.c (gdbreplay_version): Ditto.
13470 2010-12-29 Jie Zhang <jie.zhang@analog.com>
13472 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
13473 * linux-bfin-low.c: New file.
13474 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
13475 PT_DATA_ADDR for BFIN targets.
13476 * Makefile.in (SFILES): Add linux-bfin-low.c.
13477 (clean): Remove reg-bfin.c.
13478 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
13479 * README: Mention supported Blackfin targets.
13481 2010-12-23 Mike Frysinger <vapier@gentoo.org>
13483 * .gitignore: New file.
13485 2010-11-16 Mike Frysinger <vapier@gentoo.org>
13487 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
13489 2010-10-22 Jie Zhang <jie@codesourcery.com>
13491 * Makefile.in: Add FLAGS_TO_PASS variable.
13492 (install): Remove dependency of install-only and recursively
13493 invoke make for install-only.
13495 2010-10-04 Doug Evans <dje@google.com>
13497 * Makefile.in (uninstall): Use $(DESTDIR).
13499 2010-09-24 Pedro Alves <pedro@codesourcery.com>
13503 * linux-x86-low.c (compat_siginfo_from_siginfo)
13504 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
13505 si_code is < 0. Check for si_code == SI_TIMER before checking for
13508 2010-09-13 Joel Brobecker <brobecker@adacore.com>
13510 * lynx-i386-low.c: New file.
13511 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
13513 2010-09-13 Joel Brobecker <brobecker@adacore.com>
13515 * lynx-low.c (ptrace_request_to_str): Remove handling for
13516 request values that have been removed in LynxOS 5.x.
13518 2010-09-13 Joel Brobecker <brobecker@adacore.com>
13520 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
13523 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
13525 * configure.ac: Add --enable-inprocess-agent option.
13526 * configure: Rebuilt.
13528 2010-09-06 Yao Qi <yao@codesourcery.com>
13530 * linux-low.c (linux_kill): Remove unused variable.
13531 (linux_stabilize_threads): Likewise.
13532 * server.c (start_inferior): Likewise.
13533 (queue_stop_reply_callback): Likewise.
13534 * tracepoint.c (do_action_at_tracepoint): Likewise.
13536 2010-09-06 Yao Qi <yao@codesourcery.com>
13538 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
13541 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
13543 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
13545 2010-09-06 Pedro Alves <pedro@codesourcery.com>
13547 * Makefile.in (install-only): Replace $IPA_DEPFILES with
13550 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13552 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
13553 gdbserver/lynx-ppc-low.c: New files.
13554 * Makefile.in (lynx_low_h): New variable.
13555 (lynx-low.o, lynx-ppc-low.o): New rules.
13556 * configure.ac: On LynxOS, link with -lnetinet.
13557 * configure.srv: Add handling of powerpc-*-lynxos* targets.
13558 * configure: regenerate.
13560 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13562 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
13563 * configure.ac: Add check for vasprintf and vsnprintf.
13564 * configure, config.in: Regenerate.
13565 * server.h (vasprintf, vsnprintf): Add conditional declarations.
13567 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13569 * gdbreplay.c: Move include of alloca.h up, next to include of
13571 * server.h: Add include of malloc.h.
13572 * mem-break.c: Remove include of malloc.h.
13573 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
13575 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13577 * Makefile.in (memmem.o): Build with -Wno-error.
13579 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13581 * utils.c (xsnprintf): Make non-static.
13582 * server.h: Add xsnprintf declaration.
13583 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
13584 replace calls to snprintf by calls to xsnprintf throughout.
13586 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13588 * configure.ac: Add configure check for alloca.
13589 * configure, config.in: Regenerate.
13590 * server.h: Include alloca.h if it exists.
13591 * gdbreplay.c: Include alloca.h if it exists.
13593 2010-08-28 Pedro Alves <pedro@codesourcery.com>
13595 * linux-low.c (__SIGRTMIN): Define if not already defined.
13596 (linux_create_inferior): Check for __ANDROID__ rather than
13598 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
13599 are already deferred.
13600 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
13601 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
13602 stopped and already has a pending signal to report.
13603 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
13604 a pending signal to report or is moving out of a jump pad.
13605 (linux_init_signals): Check for __ANDROID__ rather than
13608 2010-08-28 Pedro Alves <pedro@codesourcery.com>
13610 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
13611 debug_threads check. Avoid a linear search when not doing debug
13614 2010-08-27 Pedro Alves <pedro@codesourcery.com>
13616 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
13617 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
13618 (struct file_handler) <fd>: Change type to gdb_fildes_t.
13619 (process_event): Change local fd's type to gdb_fildes_t.
13620 (create_file_handler): Adjust prototype.
13621 (delete_file_handler): Adjust prototype.
13622 (handle_file_event): Adjust prototype. Use pfildes.
13623 (create_file_event): Adjsut prototype.
13624 * remote-utils.c (remote_desc, listen_desc): Change type to
13626 * server.h: New gdb_fildes_t typedef.
13627 [USE_WIN32API]: Include winsock2.h.
13628 (delete_file_handler, add_file_handler): Adjust prototypes.
13629 (pfildes): Declare.
13630 * utils.c (pfildes): New.
13632 2010-08-27 Pedro Alves <pedro@codesourcery.com>
13634 * configure.ac (build_warnings): Add -Wno-char-subscripts.
13635 * configure: Regenerate.
13637 2010-08-27 Pedro Alves <pedro@codesourcery.com>
13639 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
13640 (linux_done_accessing_memory): ... this.
13641 (linux_target_ops): Adjust.
13642 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
13643 * nto-low.c (nto_target_ops): Adjust comment.
13644 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
13645 * spu-low.c (spu_target_ops): Adjust comment.
13646 * target.h (target_ops): Rename unprepare_to_access_memory field
13647 to done_accessing_memory.
13648 (unprepare_to_access_memory): Rename to ...
13649 (done_accessing_memory): ... this.
13651 2010-08-26 Pedro Alves <pedro@codesourcery.com>
13653 * linux-low.c (linux_prepare_to_access_memory): New.
13654 (linux_unprepare_to_access_memory): New.
13655 (linux_target_ops): Install them.
13656 * server.c (read_memory): Rename to ...
13657 (gdb_read_memory): ... this. Use
13658 prepare_to_access_memory/prepare_to_access_memory.
13659 (write_memory): Rename to ...
13660 (gdb_write_memory): ... this. Use
13661 prepare_to_access_memory/prepare_to_access_memory.
13662 (handle_search_memory_1): Adjust.
13663 (process_serial_event): Adjust.
13664 * target.h (struct target_ops): New fields
13665 prepare_to_access_memory and unprepare_to_access_memory.
13666 (prepare_to_access_memory, unprepare_to_access_memory): New.
13667 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
13668 prepare_to_access_memory/prepare_to_access_memory.
13669 * nto-low.c (nto_target_ops): Adjust.
13670 * spu-low.c (spu_target_ops): Adjust.
13671 * win32-low.c (win32_target_ops): Adjust.
13673 2010-08-26 Pedro Alves <pedro@codesourcery.com>
13675 * Makefile.in (WARN_CFLAGS): Get it from configure.
13676 (WERROR_CFLAGS): New.
13677 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
13678 * configure.ac: Introduce --enable-werror, which adds -Werror to
13679 the compiler command line. Enabled by default. Disable with
13680 --disable-werror. Add -Wdeclaration-after-statement
13681 Wpointer-arith and -Wformat-nonliteral to warning flags.
13682 * configure: Regenerate.
13684 2010-08-26 Pedro Alves <pedro@codesourcery.com>
13686 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
13688 2010-08-26 Pedro Alves <pedro@codesourcery.com>
13690 * gdbreplay.c (remote_error): New.
13692 (expect): Use gdbchar. Check for error reading from GDB.
13693 Clarify sync error output.
13694 (play): Check for errors writing to GDB.
13695 * linux-low.c (sigchld_handler): Really ignore `write' errors.
13696 * remote-utils.c (getpkt): Check for errors writing to the remote
13699 2010-08-25 Pedro Alves <pedro@codesourcery.com>
13701 * linux-low.c (linux_wait_1): Move non-debugging code out of
13702 `debug_threads' control.
13704 2010-08-25 Pedro Alves <pedro@codesourcery.com>
13706 * linux-low.c (linux_wait_1): Don't set last_status here.
13707 * server.c (push_event, queue_stop_reply_callback): Assert we're
13708 not pushing a TARGET_WAITKIND_IGNORE event.
13709 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
13710 (myresume, handle_target_event): Set the thread's last_resume_kind
13711 and last_status from the target returned status.
13713 2010-08-25 Pedro Alves <pedro@codesourcery.com>
13717 * linux-x86-low.c (update_debug_registers_callback): New.
13718 (i386_dr_low_set_addr): Use it.
13719 (i386_dr_low_get_addr): New.
13720 (i386_dr_low_set_control): Use update_debug_registers_callback.
13721 (i386_dr_low_get_control): New.
13722 (i386_dr_low_get_status): Adjust.
13723 * linux-low.c (linux_stop_lwp): New.
13724 * linux-low.h (linux_stop_lwp): Declare.
13726 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
13727 argument instead of a i386_debug_reg_state.
13728 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
13729 a i386_debug_reg_state.
13730 (i386_insert_aligned_watchpoint): Adjust.
13731 (i386_remove_aligned_watchpoint): Adjust.
13732 (i386_low_stopped_data_address): Read the debug registers from the
13733 inferior instead of from the mirrors.
13734 * i386-low.h (struct i386_debug_reg_state): Extend comment.
13735 (i386_dr_low_get_addr): Declare.
13736 (i386_dr_low_get_control): Declare.
13737 (i386_dr_low_get_status): Change prototype.
13739 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
13740 (i386_dr_low_get_addr): New.
13741 (i386_dr_low_get_control): New.
13742 (i386_dr_low_get_status): Adjust prototype. Return
13744 (i386_initial_stuff): Clear dr_status_mirror and
13746 (i386_get_thread_context): Adjust.
13747 (i386_set_thread_context): Adjust.
13748 (i386_thread_added): Adjust.
13750 2010-08-24 Pedro Alves <pedro@codesourcery.com>
13752 * linux-low.h (linux_thread_area): Delete declaration.
13754 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
13756 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
13757 after its termination.
13759 2010-08-09 Pedro Alves <pedro@codesourcery.com>
13761 * linux-low.c (gdb_wants_lwp_stopped): Delete.
13762 (gdb_wants_all_stopped): Delete.
13763 (linux_wait_1): Don't call them.
13764 * server.c (handle_v_cont): Tag all threads as want-stopped.
13765 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
13766 stopped as "client-wants-stopped".
13768 2010-07-31 Pedro Alves <pedro@codesourcery.com>
13770 * Makefile.in (signals_h): New.
13771 (server_h): Depend on it.
13772 (server.o): Don't depend on $(signals_def).
13773 (signals.o): Depend on $(signals_def).
13775 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
13777 * Makefile.in (signals_def): New.
13778 (server_h): Append include/gdb/signals.h and signals_def.
13779 (server.o): Append signals_def.
13781 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
13783 * server.c (handle_target_event): Use target_signal_to_host for
13784 resume_info.sig initialization.
13785 * target.h (struct thread_resume) <sig>: New comment.
13787 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
13789 * server.c (handle_query): strcpy() the returned string from paddress()
13790 instead of sprintf().
13791 * utils.c (paddress): Return phex_nz().
13793 2010-07-07 Joel Brobecker <brobecker@adacore.com>
13795 * server.c (handle_v_cont): Call mourn_inferior if process
13797 (myresume): Likewise.
13799 2010-07-01 Pedro Alves <pedro@codesourcery.com>
13801 Static tracepoints, and integration with UST.
13803 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
13804 * mem-break.c (uninsert_all_breakpoints)
13805 (reinsert_all_breakpoints): New.
13806 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
13807 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
13808 (gdb_agent_ust_loaded, helper_thread_id)
13809 (gdb_agent_helper_thread_id): New macros.
13810 (struct ipa_sym_addresses): Add addr_ust_loaded,
13811 addr_helper_thread_id, addr_cmd_buf.
13812 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
13813 (in_process_agent_loaded_ust): New.
13814 (write_e_ust_not_loaded): New.
13815 (maybe_write_ipa_ust_not_loaded): New.
13816 (struct collect_static_trace_data_action): New.
13817 (enum tracepoint_type) <static_tracepoint>: New.
13818 (struct tracepoint) <handle>: Mention static tracepoints.
13819 (struct static_tracepoint_ctx): New.
13820 (CMD_BUF_SIZE): New.
13821 (add_tracepoint_action): Handle static tracepoint actions.
13822 (unprobe_marker_at): New.
13823 (clear_installed_tracepoints): Handle static tracepoints.
13824 (cmd_qtdp): Handle static tracepoints.
13825 (probe_marker_at): New.
13826 (cmd_qtstart): Handle static tracepoints.
13827 (response_tracepoint): Handle static tracepoints.
13828 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
13829 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
13830 (get_context_regcache): Handle static tracepoints.
13831 (do_action_at_tracepoint): Handle static tracepoint actions.
13832 (traceframe_find_block_type): Handle static trace data blocks.
13833 (traceframe_read_sdata): New.
13834 (download_tracepoints): Download static tracepoint actions.
13835 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
13836 (GDB_PROBE_NAME): New.
13838 (GET_UST_SYM): New.
13841 (ust_marker_to_static_tracepoint): New.
13843 (collect_ust_data_at_tracepoint): New.
13844 (gdb_ust_probe): New.
13845 (UNIX_PATH_MAX, SOCK_DIR): New.
13846 (gdb_ust_connect_sync_socket): New.
13847 (resume_thread, stop_thread): New.
13848 (run_inferior_command): New.
13849 (init_named_socket): New.
13850 (gdb_ust_socket_init): New.
13851 (cstr_to_hexstr): New.
13853 (first_marker, next_marker): New.
13854 (response_ust_marker): New.
13855 (cmd_qtfstm, cmd_qtsstm): New.
13856 (unprobe_marker_at, probe_marker_at): New.
13857 (cmd_qtstmat, gdb_ust_thread): New.
13858 (gdb_ust_init): New.
13859 (initialize_tracepoint_ftlib): Call gdb_ust_init.
13860 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
13861 (ST_REGENTRY): New.
13862 (x86_64_st_collect_regmap): New.
13863 (X86_64_NUM_ST_COLLECT_GREGS): New.
13864 (AMD64_RIP_REGNUM): New.
13865 (supply_static_tracepoint_registers): New.
13866 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
13867 (ST_REGENTRY): New.
13868 (i386_st_collect_regmap): New.
13869 (i386_NUM_ST_COLLECT_GREGS): New.
13870 (supply_static_tracepoint_registers): New.
13871 * server.c (handle_query): Handle qXfer:statictrace:read.
13872 <qSupported>: Report support for StaticTracepoints, and
13873 qXfer:statictrace:read features.
13874 * server.h (traceframe_read_sdata)
13875 (supply_static_tracepoint_registers): Declare.
13876 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
13877 (unpack_varlen_hex): Include in IPA build.
13878 * Makefile.in (ustlibs, ustinc): New.
13879 (IPA_OBJS): Add remote-utils-ipa.o.
13880 ($(IPA_LIB)): Link -ldl and -lpthread.
13882 (IPAGENT_CFLAGS): Add UST_CFLAGS.
13883 * config.in, configure: Regenerate.
13885 2010-06-20 Ian Lance Taylor <iant@google.com>
13886 Pedro Alves <pedro@codesourcery.com>
13888 * linux-x86-low.c (always_true): Delete.
13889 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
13890 trying to fool the compiler with always_true.
13892 2010-06-20 Pedro Alves <pedro@codesourcery.com>
13894 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
13895 conditions in gdbserver.
13897 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
13899 * spu-low.c (spu_read_memory): Wrap around local store limit.
13900 (spu_write_memory): Likewise.
13902 2010-06-15 Pedro Alves <pedro@codesourcery.com>
13904 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
13905 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
13907 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
13909 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
13910 uses with LONGEST uses.
13912 2010-06-14 Stan Shebs <stan@codesourcery.com>
13913 Pedro Alves <pedro@codesourcery.com>
13917 * linux-x86-low.c: Include limits.h.
13919 (always_true): New.
13922 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
13923 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
13924 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
13925 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
13926 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
13927 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
13928 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
13929 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
13930 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
13931 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
13932 (amd64_emit_void_call_2): New.
13933 (amd64_emit_ops): New.
13934 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
13935 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
13936 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
13937 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
13938 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
13939 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
13940 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
13941 (i386_emit_call, i386_emit_reg, i386_emit_pop)
13942 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
13943 (i386_emit_stack_adjust, i386_emit_int_call_1)
13944 (i386_emit_void_call_2): New.
13945 (i386_emit_ops): New.
13946 (x86_emit_ops): New.
13947 (the_low_target): Install x86_emit_ops.
13948 * server.h (struct emit_ops): New.
13949 (get_raw_reg_func_addr): Declare.
13950 (current_insn_ptr, emit_error): Declare.
13951 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
13952 (set_trace_state_variable_value): New defines.
13953 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
13954 addr_get_trace_state_variable_value and
13955 addr_set_trace_state_variable_value.
13956 (symbol_list): New fields for get_raw_reg,
13957 get_trace_state_variable_value and set_trace_state_variable_value.
13958 (condfn): New typedef.
13959 (struct tracepoint): New field `compiled_cond'.
13960 (do_action_at_tracepoint): Clear compiled_cond.
13961 (get_trace_state_variable_value, set_trace_state_variable_value):
13963 (condition_true_at_tracepoint): If there's a compiled condition,
13965 (current_insn_ptr, emit_error): New globals.
13966 (struct bytecode_address): New.
13967 (get_raw_reg_func_addr): New.
13968 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
13969 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
13970 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
13971 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
13972 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
13973 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
13974 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
13975 (compile_tracepoint_condition, compile_bytecodes): New.
13976 * target.h (emit_ops): Forward declare.
13977 (struct target_ops): New field emit_ops.
13978 (target_emit_ops): New.
13979 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
13980 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
13981 * linux-low.c (linux_emit_ops): New.
13982 (linux_target_ops): Install it.
13983 * linux-low.h (struct linux_target_ops): New field emit_ops.
13985 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
13987 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
13988 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
13990 2010-06-01 Pedro Alves <pedro@codesourcery.com>
13991 Stan Shebs <stan@codesourcery.com>
13993 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
13994 (all): Depend on $(extra_libraries).
13995 (install-only): Install the IPA.
13996 (IPA_OBJS, IPA_LIB): New.
13997 (clean): Remove the IPA lib.
13998 (IPAGENT_CFLAGS): New.
13999 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
14000 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
14001 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
14002 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
14003 * configure.ac: Check for atomic builtins support in the compiler.
14004 (IPA_DEPFILES, extra_libraries): Define.
14005 * configure.srv (ipa_obj): Add description.
14006 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
14007 (i[34567]86-*-linux*): Set ipa_obj.
14008 (x86_64-*-linux*): Set ipa_obj.
14009 * linux-low.c (stabilizing_threads): New.
14010 (supports_fast_tracepoints): New.
14011 (linux_detach): Stabilize threads before detaching.
14012 (handle_tracepoints): Handle internal tracing breakpoints. Assert
14013 the lwp is either not stabilizing, or is moving out of a jump pad.
14014 (linux_fast_tracepoint_collecting): New.
14015 (maybe_move_out_of_jump_pad): New.
14016 (enqueue_one_deferred_signal): New.
14017 (dequeue_one_deferred_signal): New.
14018 (linux_wait_for_event_1): If moving out of a jump pad, defer
14019 pending signals to later.
14020 (linux_stabilize_threads): New.
14021 (linux_wait_1): Check if threads need moving out of jump pads, and
14023 (stuck_in_jump_pad_callback): New.
14024 (move_out_of_jump_pad_callback): New.
14025 (lwp_running): New.
14026 (linux_resume_one_lwp): Handle moving out of jump pads.
14027 (linux_set_resume_request): Dequeue deferred signals.
14028 (need_step_over_p): Also step over fast tracepoint jumps.
14029 (start_step_over): Also uninsert fast tracepoint jumps.
14030 (finish_step_over): Also reinsert fast tracepoint jumps.
14031 (linux_install_fast_tracepoint_jump): New.
14032 (linux_target_ops): Install linux_stabilize_threads and
14033 linux_install_fast_tracepoint_jump_pad.
14034 * linux-low.h (linux_target_ops) <get_thread_area,
14035 install_fast_tracepoint_jump_pad>: New fields.
14036 (struct lwp_info) <collecting_fast_tracepoint,
14037 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
14038 (linux_get_thread_area): Declare.
14039 * linux-x86-low.c (jump_insn): New.
14040 (x86_get_thread_area): New.
14041 (append_insns): New.
14042 (push_opcode): New.
14043 (amd64_install_fast_tracepoint_jump_pad): New.
14044 (i386_install_fast_tracepoint_jump_pad): New.
14045 (x86_install_fast_tracepoint_jump_pad): New.
14046 (the_low_target): Install x86_get_thread_area and
14047 x86_install_fast_tracepoint_jump_pad.
14048 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
14049 (struct fast_tracepoint_jump): New.
14050 (fast_tracepoint_jump_insn): New.
14051 (fast_tracepoint_jump_shadow): New.
14052 (find_fast_tracepoint_jump_at): New.
14053 (fast_tracepoint_jump_here): New.
14054 (delete_fast_tracepoint_jump): New.
14055 (set_fast_tracepoint_jump): New.
14056 (uninsert_fast_tracepoint_jumps_at): New.
14057 (reinsert_fast_tracepoint_jumps_at): New.
14058 (set_breakpoint_at): Use write_inferior_memory.
14059 (uninsert_raw_breakpoint): Use write_inferior_memory.
14060 (check_mem_read): Mask out fast tracepoint jumps.
14061 (check_mem_write): Mask out fast tracepoint jumps.
14062 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
14063 (set_fast_tracepoint_jump): Declare.
14064 (delete_fast_tracepoint_jump)
14065 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
14066 (reinsert_fast_tracepoint_jumps_at): Declare.
14067 * regcache.c: Don't compile many functions when building the
14068 in-process agent library.
14069 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
14070 the register buffer in the heap.
14071 (free_register_cache): If the register buffer isn't owned by the
14072 regcache, don't free it.
14073 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
14074 pre-existing register caches.
14075 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
14077 (convert_ascii_to_int): : Constify `from' parameter type.
14078 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
14079 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
14080 the needed buffer in-place.
14081 (relocate_instruction): New.
14082 * server.c (handle_query) <qSymbols>: If the target supports
14083 tracepoints, give it a chance of looking up symbols. Report
14084 support for fast tracepoints.
14085 (handle_status): Stabilize threads.
14086 (process_serial_event): Adjust.
14087 * server.h (struct fast_tracepoint_jump): Forward declare.
14088 (struct process_info) <fast_tracepoint_jumps>: New field.
14089 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
14090 (decode_X_packet, decode_M_packet): Adjust.
14091 (relocate_instruction): Declare.
14092 (in_process_agent_loaded): Declare.
14093 (tracepoint_look_up_symbols): Declare.
14094 (struct fast_tpoint_collect_status): Declare.
14095 (fast_tracepoint_collecting): Declare.
14096 (force_unlock_trace_buffer): Declare.
14097 (handle_tracepoint_bkpts): Declare.
14098 (initialize_low_tracepoint)
14099 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
14100 * target.h (struct target_ops) <stabilize_threads,
14101 install_fast_tracepoint_jump_pad>: New fields.
14102 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
14103 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
14104 [HAVE_STDINT_H]: Include stdint.h.
14105 (trace_debug_1): Rename to ...
14106 (trace_vdebug): ... this.
14107 (trace_debug): Rename to ...
14108 (trace_debug_1): ... this. Add `level' parameter.
14109 (trace_debug): New.
14110 (ATTR_USED, ATTR_NOINLINE): New.
14111 (IP_AGENT_EXPORT): New.
14112 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
14113 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
14114 (about_to_request_buffer_space, trace_buffer_is_full)
14115 (stopping_tracepoint, expr_eval_result, error_tracepoint)
14116 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
14117 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
14118 (traceframe_write_count, traceframes_created)
14119 (trace_state_variables)
14120 New renaming defines.
14121 (struct ipa_sym_addresses): New.
14122 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
14123 (symbol_list): New.
14124 (ipa_sym_addrs): New.
14125 (all_tracepoint_symbols_looked_up): New.
14126 (in_process_agent_loaded): New.
14127 (write_e_ipa_not_loaded): New.
14128 (maybe_write_ipa_not_loaded): New.
14129 (tracepoint_look_up_symbols): New.
14130 (debug_threads) [IN_PROCESS_AGENT]: New.
14131 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
14132 (UNKNOWN_SIDE_EFFECTS): New.
14133 (stop_tracing): New.
14134 (flush_trace_buffer): New.
14135 (stop_tracing_bkpt): New.
14136 (flush_trace_buffer_bkpt): New.
14137 (read_inferior_integer): New.
14138 (read_inferior_uinteger): New.
14139 (read_inferior_data_pointer): New.
14140 (write_inferior_data_pointer): New.
14141 (write_inferior_integer): New.
14142 (write_inferior_uinteger): New.
14143 (struct collect_static_trace_data_action): Delete.
14144 (enum tracepoint_type): New.
14145 (struct tracepoint) <type>: New field `type'.
14146 <actions_str, step_actions, step_actions_str>: Only include in
14148 <orig_size, obj_addr_on_target, adjusted_insn_addr>
14149 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
14150 (tracepoints): Use IP_AGENT_EXPORT.
14151 (last_tracepoint): Don't include in the IPA.
14152 (stopping_tracepoint): Use IP_AGENT_EXPORT.
14153 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
14154 (alloced_trace_state_variables): New.
14155 (trace_state_variables): Use IP_AGENT_EXPORT.
14156 (traceframe_t): Delete unused variable.
14157 (circular_trace_buffer): Don't include in the IPA.
14158 (trace_buffer_start): Delete.
14159 (struct trace_buffer_control): New.
14160 (trace_buffer_free): Delete.
14161 (struct ipa_trace_buffer_control): New.
14162 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
14163 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
14165 (trace_buffer_ctrl): New.
14166 (TRACE_BUFFER_CTRL_CURR): New.
14167 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
14168 Reimplement as macros.
14169 (trace_buffer_wrap): Delete.
14170 (traceframe_write_count, traceframe_read_count)
14171 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
14172 (struct tracepoint_hit_ctx) <type>: New field.
14173 (struct fast_tracepoint_ctx): New.
14174 (memory_barrier): New.
14176 (record_tracepoint_error): Update atomically in the IPA.
14177 (clear_inferior_trace_buffer): New.
14178 (about_to_request_buffer_space): New.
14179 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
14180 updating the same buffer.
14181 (add_tracepoint): Default the tracepoint's type to trap
14182 tracepoint, and orig_size to -1.
14183 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
14184 internal variables.
14185 (create_trace_state_variable): New parameter `gdb'. Handle it.
14186 (clear_installed_tracepoints): Clear fast tracepoint jumps.
14187 (cmd_qtdp): Handle fast tracepoints.
14188 (cmd_qtdv): Adjust.
14189 (max_jump_pad_size): New.
14190 (gdb_jump_pad_head): New.
14191 (get_jump_space_head): New.
14192 (claim_jump_space): New.
14193 (sort_tracepoints): New.
14194 (MAX_JUMP_SIZE): New.
14195 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
14197 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
14198 support. Upload fast traceframes, and delete internal IPA
14200 (stop_tracing_handler): New.
14201 (flush_trace_buffer_handler): New.
14202 (cmd_qtstop): Upload fast tracepoints.
14203 (response_tracepoint): Handle fast tracepoints.
14204 (tracepoint_finished_step): Upload fast traceframes. Set the
14205 tracepoint hit context's tracepoint type.
14206 (handle_tracepoint_bkpts): New.
14207 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
14208 type. Add comment about fast tracepoints.
14209 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
14210 non-existing action_str field.
14211 (get_context_regcache): Handle fast tracepoints.
14212 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
14214 (fast_tracepoint_from_jump_pad_address): New.
14215 (fast_tracepoint_from_ipa_tpoint_address): New.
14216 (collecting_t): New.
14217 (force_unlock_trace_buffer): New.
14218 (fast_tracepoint_collecting): New.
14220 (gdb_collect): New.
14221 (write_inferior_data_ptr): New.
14222 (target_tp_heap): New.
14223 (target_malloc): New.
14224 (download_agent_expr): New.
14226 (download_tracepoints): New.
14227 (download_trace_state_variables): New.
14228 (upload_fast_traceframes): New.
14229 (IPA_FIRST_TRACEFRAME): New.
14230 (IPA_NEXT_TRACEFRAME_1): New.
14231 (IPA_NEXT_TRACEFRAME): New.
14232 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
14233 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
14234 (gdb_jump_pad_buffer_end): New.
14235 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
14236 (initialize_tracepoint): Adjust.
14237 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
14238 buffer. Initialize the low module.
14239 * utils.c (PREFIX, TOOLNAME): New.
14240 (malloc_failure): Use PREFIX.
14241 (error): In the IPA, an error causes an exit.
14242 (fatal, warning): Use PREFIX.
14243 (internal_error): Use TOOLNAME.
14244 (NUMCELLS): Increase to 10.
14245 * configure, config.in: Regenerate.
14247 2010-06-01 Pedro Alves <pedro@codesourcery.com>
14249 * server.c (handle_query) <qSupported>: Do two passes over the
14250 qSupported string to avoid nesting strtok.
14252 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
14254 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
14256 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
14257 -Wl,--dynamic-list.
14258 * configure: Regenerate.
14259 * proc-service.list: New.
14261 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
14263 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
14266 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
14268 * gdbreplay.c (remote_open): Check error return from socket() call by
14269 its equality to -1 not by it being negative.
14270 * remote-utils.c (remote_open): Likewise.
14272 2010-05-23 Pedro Alves <pedro@codesourcery.com>
14274 * config.h: Regenerate.
14276 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
14278 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
14279 doesn't provide PTRACE_GET_THREAD_AREA.
14281 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
14283 * linux-m68k-low.c: Include <asm/ptrace.h>
14284 (ps_get_thread_area): Implement.
14286 2010-05-03 Doug Evans <dje@google.com>
14288 * event-loop.c (struct callback_event): New struct.
14289 (callback_list): New global.
14290 (append_callback_event, delete_callback_event): New functions.
14291 (process_callback): New function.
14292 (start_event_loop): Call it.
14293 * remote-utils.c (NOT_SCHEDULED): Define.
14294 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
14295 moved out of readchar.
14296 (readchar): Rewrite. Call reschedule before returning.
14297 (reset_readchar): New function.
14298 (remote_close): Call it.
14299 (process_remaining, reschedule): New functions.
14300 * server.h (callback_handler_func): New typedef.
14301 (append_callback_event, delete_callback_event): Declare.
14303 2010-05-03 Pedro Alves <pedro@codesourcery.com>
14305 * proc-service.c (ps_pglobal_lookup): Use
14306 thread_db_look_up_one_symbol.
14307 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
14308 parameter. Use it instead of all_symbols_looked_up.
14309 * server.h (struct process_info) <all_symbols_looked_up>: Delete
14311 (all_symbols_looked_up): Don't declare.
14312 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
14313 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
14315 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
14316 Set all_symbols_looked_up here.
14317 (thread_db_look_up_one_symbol): New.
14318 (thread_db_get_tls_address): Adjust.
14319 (thread_db_load_search, try_thread_db_load_1): Always allocate the
14320 thread_db object on the heap, and tentatively set it in the
14322 (thread_db_init): Don't set all_symbols_looked_up here.
14323 * linux-low.h (thread_db_look_up_one_symbol): Declare.
14325 2010-05-03 Pedro Alves <pedro@codesourcery.com>
14327 * linux-low.c (linux_kill, linux_detach): Adjust.
14328 (status_pending_p_callback): Remove redundant statement. Check
14329 for !TARGET_WAITIKIND_IGNORE, instead of
14330 TARGET_WAITKIND_STOPPED.
14331 (handle_tracepoints): Make sure LWP is locked. Adjust.
14332 (linux_wait_for_event_1): Adjust.
14333 (linux_cancel_breakpoints): New.
14334 (unsuspend_one_lwp): New.
14335 (unsuspend_all_lwps): New.
14336 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
14337 (send_sigstop_callback): Change return type to int, add new
14338 `except' parameter and handle it.
14339 (suspend_and_send_sigstop_callback): New.
14340 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
14341 pass them down. If SUSPEND, also increment the lwp's suspend
14343 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
14344 (need_step_over_p): Don't consider suspended LWPs.
14345 (start_step_over): Adjust.
14346 (proceed_one_lwp): Change return type to int, add new `except'
14347 parameter and handle it.
14348 (unsuspend_and_proceed_one_lwp): New.
14349 (proceed_all_lwps): Use find_inferior instead of
14351 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
14352 also decrement the suspend count of LWPs. Pass `except' down,
14353 instead of hacking its suspend count.
14354 (linux_pause_all): Add `freeze' parameter. Adjust.
14355 (linux_unpause_all): New.
14356 (linux_target_ops): Install linux_unpause_all.
14357 * server.c (handle_status): Adjust.
14358 * target.h (struct target_ops): New fields `unpause_all' and
14359 `cancel_breakpoints'. Add new parameter to `pause_all'.
14360 (pause_all): Add new `freeze' parameter.
14361 (unpause_all): New.
14362 (cancel_breakpoints): New.
14363 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
14364 cancel breakpoints.
14365 (cmd_qtstart): Pause threads.
14366 (stop_tracing): Pause threads, and cancel breakpoints.
14367 * win32-low.c (win32_target_ops): Adjust.
14369 2010-05-03 Pedro Alves <pedro@codesourcery.com>
14371 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
14372 the inferior right away from here...
14373 (linux_wait_1): ... to here, and adjust to check the thread's
14374 last_resume_kind instead of the lwp's step or stop_expected flags.
14376 2010-05-02 Pedro Alves <pedro@codesourcery.com>
14378 * README: Use consistent `GDB' and `GDBserver' spellings.
14380 2010-05-02 Pedro Alves <pedro@codesourcery.com>
14382 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
14383 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
14384 (linux_detach_one_lwp): Assume the lwp is stopped.
14385 (any_thread_of): Delete.
14386 (linux_detach): Stop all lwps here. Don't blindly delete all
14388 (delete_lwp_callback): New.
14389 (linux_mourn): Delete all lwps of the process that is gone.
14390 (linux_wait_1): Don't delete the last lwp of the process here.
14391 * mem-break.h (mark_breakpoints_out): Declare.
14392 * mem-break.c (mark_breakpoints_out): New.
14393 (free_all_breakpoints): Use it.
14394 * server.c (handle_target_event): If the process is gone, mark
14396 * thread-db.c (struct thread_db) <create_bp>: New field.
14397 (thread_db_enable_reporting): Fix prototype. Store a thread event
14398 breakpoint reference in the thread_db struct.
14399 (thread_db_load_search): Clear the thread_db object.
14400 (try_thread_db_load_1): Ditto.
14401 (switch_to_process): New.
14402 (disable_thread_event_reporting): Use it.
14403 (remove_thread_event_breakpoints): New.
14404 (thread_db_detach, thread_db_mourn): Use it.
14406 2010-05-01 Pedro Alves <pedro@codesourcery.com>
14408 * linux-low.c (linux_enable_event_reporting): New.
14409 (linux_wait_for_event_1, handle_extended_wait): Use it.
14411 2010-04-30 Pedro Alves <pedro@codesourcery.com>
14413 * linux-low.c (linux_kill_one_lwp, linux_kill)
14414 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
14415 (send_sigstop): Take an lwp_info as parameter instead. Queue a
14416 SIGSTOP even if the LWP is stopped.
14417 (send_sigstop_callback): New.
14418 (stop_all_lwps): Use send_sigstop_callback instead.
14419 (linux_resume_one_thread): Adjust.
14420 (proceed_one_lwp): Still proceed an LWP that the client has
14421 requested to stop, if we haven't reported it as stopped yet. Make
14422 sure that LWPs the client want stopped, have a pending SIGSTOP.
14424 2010-04-26 Doug Evans <dje@google.com>
14426 * server.c (handle_general_set): Make static.
14428 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
14429 Print received char after testing for error/eof instead of before.
14430 (input_interrupt): Tweak comment.
14432 2010-04-23 Doug Evans <dje@google.com>
14434 * server.c (start_inferior): Print inferior argv if --debug.
14436 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
14438 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
14439 * nto-x86-low.c: Include server.h
14441 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
14443 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
14444 be consistent with other sources of this directory.
14445 (init_registers_amd64): Correct name of source file of this function
14448 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
14450 * configure.srv (x86_64-*-mingw*): New configuration for Windows
14451 64-bit executables.
14453 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
14455 * win32-i386-low.c: Add 64-bit support.
14456 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
14457 (init_registers_amd64): Declare.
14458 (mappings): Add 64-bit version of array.
14459 (init_windows_x86): New function.
14460 (the_low_target): Change init_arch field to init_windows_x86.
14462 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
14464 * win32-low.c: Adapt to support also 64-bit architecture.
14465 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
14466 (get_image_name): Use SIZE_T type for local variable `done'.
14467 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
14468 (toolhelp_get_dll_name): Idem.
14469 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
14470 Use uintptr_t typecast to avoid warning.
14471 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
14472 (handle_exception): Use phex_nz to avoid warning.
14473 (win32_wait): Remove unused local variable `process'.
14475 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
14477 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
14480 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
14482 * configure.ac: Use `ws2_32' library for srv_mingw.
14483 * configure: Regenerate.
14484 * gdbreplay.c: Include winsock2.h instead of winsock.h.
14485 * remote-utils.c: Likewise.
14487 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
14489 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
14490 if __x86_64__ is defined.
14492 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
14494 * configure: Regenerate.
14496 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
14498 * server.c (handle_query): Handle 'qGetTIBAddr' query.
14499 * target.h (target_ops): New get_tib_address field.
14500 * win32-low.h (win32_thread_info): Add thread_local_base field.
14501 * win32-low.c (child_add_thread): Add tlb argument.
14502 Set thread_local_base field to TLB.
14503 (get_child_debug_event): Adapt to child_add_thread change.
14504 (win32_get_tib_address): New function.
14505 (win32_target_ops): Set get_tib_address field to
14506 win32_get_tib_address.
14507 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
14509 2010-04-12 Pedro Alves <pedro@codesourcery.com>
14511 * linux-low.c (linux_mourn): Also remove the process.
14512 * server.c (handle_target_event): Don't remove the process here.
14513 * nto-low.c (nto_mourn): New.
14514 (nto_target_ops): Install it.
14515 * spu-low.c (spu_mourn): New.
14516 (spu_target_ops): Install it.
14517 * win32-low.c (win32_mourn): New.
14518 (win32_target_ops): Install it.
14520 2010-04-12 Pedro Alves <pedro@codesourcery.com>
14522 * server.h (buffer_xml_printf): Remove redundant `;'.
14524 2010-04-12 Pedro Alves <pedro@codesourcery.com>
14526 * regcache.c (set_register_cache): Invalidate regcaches before
14527 changing the register cache layout.
14528 (regcache_invalidate_one): Allow a NULL regcache.
14529 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
14530 regcaches before changing the register cache layout or the target
14533 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
14535 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
14536 variable warning on Linux/x86-64.
14538 2010-04-11 Pedro Alves <pedro@codesourcery.com>
14540 GDBserver disconnected tracing support.
14542 * linux-low.c (linux_remove_process): Delete.
14543 (add_lwp): Don't set last_resume_kind here.
14544 (linux_kill): Use `mourn'.
14545 (linux_detach): Use `thread_db_detach', and `mourn'.
14546 (linux_mourn): New.
14547 (linux_attach_lwp_1): Adjust comment.
14548 (linux_attach): last_resume_kind moved the thread_info; adjust.
14549 (status_pending_p_callback): Adjust.
14550 (linux_wait_for_event_1): Adjust.
14551 (count_events_callback, select_singlestep_lwp_callback)
14552 (select_event_lwp_callback, cancel_breakpoints_callback)
14553 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
14554 (proceed_one_lwp): Adjust.
14555 (linux_async): Add debug output.
14556 (linux_thread_stopped): New.
14557 (linux_pause_all): New.
14558 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
14560 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
14561 (thread_db_free): Delete declaration.
14562 (thread_db_detach, thread_db_mourn): Declare.
14563 * thread-db.c (thread_db_init): Use thread_db_mourn.
14564 (thread_db_free): Delete, split in two.
14565 (disable_thread_event_reporting): New.
14566 (thread_db_detach): New.
14567 (thread_db_mourn): New.
14569 * server.h (struct thread_info) <last_resume_kind>: New field.
14570 <attached>: Add comment.
14571 <gdb_detached>: New field.
14572 (handler_func): Change return type to int.
14573 (handle_serial_event, handle_target_event): Ditto.
14574 (gdb_connected): Declare.
14576 (disconnected_tracing): Declare.
14577 (stop_tracing): Declare.
14579 * server.c (handle_query) <qSupported>: Report support for
14580 disconnected tracing.
14581 (queue_stop_reply_callback): Account for running threads.
14582 (gdb_wants_thread_stopped): New.
14583 (gdb_wants_all_threads_stopped): New.
14584 (gdb_reattached_process): New.
14585 (handle_status): Clear the `gdb_detached' flag of all processes.
14586 In all-stop, stop all threads.
14587 (main): Be sure to leave tfind mode. Handle disconnected tracing.
14588 (process_serial_event): If the remote connection breaks, or if an
14589 exit was forced with "monitor exit", force an event loop exit.
14590 Handle disconnected tracing on detach.
14591 (handle_serial_event): Adjust.
14592 (handle_target_event): If GDB isn't connected, forward events back
14593 to the inferior, unless the last process exited, in which case,
14594 exit gdbserver. Adjust interface.
14596 * remote-utils.c (remote_open): Don't block in accept. Instead
14597 register an event loop source on the listen socket file
14598 descriptor. Refactor bits into ...
14599 (listen_desc): ... this new global.
14600 (gdb_connected): ... this new function.
14601 (enable_async_notification): ... this new function.
14602 (handle_accept_event): ... this new function.
14603 (remote_close): Clear remote_desc.
14605 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
14607 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
14609 (mourn_inferior): Define.
14610 (target_process_qsupported): Avoid the dangling else problem.
14611 (thread_stopped): Define.
14612 (pause_all): Define.
14613 (target_waitstatus_to_string): Declare.
14614 * target.c (target_waitstatus_to_string): New.
14616 * tracepoint.c (tracing): Make extern.
14617 (disconnected_tracing): New.
14618 (stop_tracing): Make extern. Handle tracing stops due to GDB
14620 (cmd_qtdisconnected): New.
14621 (cmd_qtstatus): Report disconnected tracing status in trace reply.
14622 (handle_tracepoint_general_set): Handle QTDisconnected.
14624 * event-loop.c (event_handler_func): Change return type to int.
14625 (process_event): Bail out if the event handler wants the event
14627 (handle_file_event): Ditto.
14628 (start_event_loop): Bail out if the event handler wants the event
14631 * nto-low.c (nto_target_ops): Adjust.
14632 * spu-low.c (spu_wait): Don't remove the process here.
14633 (spu_target_ops): Adjust.
14634 * win32-low.c (win32_wait): Don't remove the process here.
14635 (win32_target_ops): Adjust.
14637 2010-04-11 Pedro Alves <pedro@codesourcery.com>
14639 * regcache.c (realloc_register_cache): Invalidate inferior's
14640 regcache before recreating it.
14642 2010-04-09 Pedro Alves <pedro@codesourcery.com>
14644 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
14646 2010-04-09 Stan Shebs <stan@codesourcery.com>
14647 Pedro Alves <pedro@codesourcery.com>
14649 * server.h (LONGEST): New.
14650 (struct thread_info) <while_stepping>: New field.
14651 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
14653 (initialize_tracepoint, handle_tracepoint_general_set)
14654 (handle_tracepoint_query, tracepoint_finished_step)
14655 (tracepoint_was_hit, release_while_stepping_state_list):
14656 (current_traceframe): Declare.
14657 * server.c (handle_general_set): Handle tracepoint packets.
14658 (read_memory): New.
14659 (write_memory): New.
14660 (handle_search_memory_1): Use read_memory.
14661 (handle_query): Report support for conditional tracepoints, trace
14662 state variables, and tracepoint sources. Handle tracepoint
14664 (main): Initialize the tracepoints module.
14665 (process_serial_event): Handle traceframe reads/writes.
14667 * linux-low.c (handle_tracepoints): New.
14668 (linux_wait_1): Call it.
14669 (linux_resume_one_lwp): Handle while-stepping.
14670 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
14671 (linux_target_ops): Install them.
14672 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
14674 * linux-x86-low.c (x86_supports_tracepoints): New.
14675 (the_low_target). Install it.
14677 * mem-break.h (delete_breakpoint): Declare.
14678 * mem-break.c (delete_breakpoint): Make external.
14680 * target.h (struct target_ops): Add `supports_tracepoints',
14681 `read_pc', and `write_pc' fields.
14682 (target_supports_tracepoints): Define.
14683 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
14686 * regcache.h (struct regcache) <registers_owned>: New field.
14687 (init_register_cache, regcache_cpy): Declare.
14688 (regcache_read_pc, regcache_write_pc): Declare.
14689 (register_cache_size): Declare.
14690 (supply_regblock): Declare.
14691 * regcache.c (init_register_cache): New.
14692 (new_register_cache): Use it.
14693 (regcache_cpy): New.
14694 (register_cache_size): New.
14695 (supply_regblock): New.
14696 (regcache_read_pc, regcache_write_pc): New.
14698 * tracepoint.c: New.
14700 * Makefile.in (OBS): Add tracepoint.o.
14701 (tracepoint.o): New rule.
14703 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
14705 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
14707 (i386-mmx.c): Likewise.
14708 (i386-mmx-linux.o): Likewise.
14709 (i386-mmx-linux.c): Likewise.
14711 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
14712 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
14713 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
14714 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
14716 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
14717 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
14718 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
14720 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
14722 * Makefile.in (clean): Updated.
14724 (i386-avx.c): Likewise.
14725 (i386-avx-linux.o): Likewise.
14726 (i386-avx-linux.c): Likewise.
14727 (amd64-avx.o): Likewise.
14728 (amd64-avx.c): Likewise.
14729 (amd64-avx-linux.o): Likewise.
14730 (amd64-avx-linux.c): Likewise.
14732 * configure.srv (srv_i386_regobj): Add i386-avx.o.
14733 (srv_i386_linux_regobj): Add i386-avx-linux.o.
14734 (srv_amd64_regobj): Add amd64-avx.o.
14735 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
14736 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
14737 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
14738 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
14739 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
14740 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
14741 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
14743 * i387-fp.c: Include "i386-xstate.h".
14745 (i387_cache_to_xsave): Likewise.
14746 (i387_xsave_to_cache): Likewise.
14747 (x86_xcr0): Likewise.
14749 * i387-fp.h (i387_cache_to_xsave): Likewise.
14750 (i387_xsave_to_cache): Likewise.
14751 (x86_xcr0): Likewise.
14753 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
14754 * linux-crisv32-low.c (target_regsets): Likewise.
14755 * linux-m68k-low.c (target_regsets): Likewise.
14756 * linux-mips-low.c (target_regsets): Likewise.
14757 * linux-ppc-low.c (target_regsets): Likewise.
14758 * linux-s390-low.c (target_regsets): Likewise.
14759 * linux-sh-low.c (target_regsets): Likewise.
14760 * linux-sparc-low.c (target_regsets): Likewise.
14761 * linux-xtensa-low.c (target_regsets): Likewise.
14763 * linux-low.c: Include <sys/uio.h>.
14764 (regsets_fetch_inferior_registers): Support nt_type.
14765 (regsets_store_inferior_registers): Likewise.
14766 (linux_process_qsupported): New.
14767 (linux_target_ops): Add linux_process_qsupported.
14769 * linux-low.h (regset_info): Add nt_type.
14770 (linux_target_ops): Add process_qsupported.
14772 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
14774 (init_registers_i386_avx_linux): New.
14775 (init_registers_amd64_avx_linux): Likewise.
14776 (xmltarget_i386_linux_no_xml): Likewise.
14777 (xmltarget_amd64_linux_no_xml): Likewise.
14778 (PTRACE_GETREGSET): Likewise.
14779 (PTRACE_SETREGSET): Likewise.
14780 (x86_fill_xstateregset): Likewise.
14781 (x86_store_xstateregset): Likewise.
14782 (use_xml): Likewise.
14783 (x86_linux_update_xmltarget): Likewise.
14784 (x86_linux_process_qsupported): Likewise.
14785 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
14786 (x86_arch_setup): Don't call init_registers_amd64_linux nor
14787 init_registers_i386_linux here. Call
14788 x86_linux_update_xmltarget.
14789 (the_low_target): Add x86_linux_process_qsupported.
14791 * server.c (handle_query): Call target_process_qsupported.
14793 * target.h (target_ops): Add process_qsupported.
14794 (target_process_qsupported): New.
14796 2010-04-03 Pedro Alves <pedro@codesourcery.com>
14798 * inferiors.c (add_thread): Set last_status kind to
14799 TARGET_WAITKIND_IGNORE.
14800 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
14801 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
14802 (linux_wait_1): Move `thread' local definition to block that uses
14803 it. Don't NULL initialize `event_child'.
14804 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
14805 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
14806 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
14808 2010-04-01 Pedro Alves <pedro@codesourcery.com>
14810 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
14811 an extended waitstatus, or by a watchpoint.
14812 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
14813 thread was stepping or has been stopped by a watchpoint.
14815 2010-04-01 Pedro Alves <pedro@codesourcery.com>
14817 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
14818 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
14819 of another, then delete the previous, and validate all
14821 (validate_inserted_breakpoint): New.
14822 (delete_disabled_breakpoints): New.
14823 (validate_breakpoints): New.
14824 (check_mem_read): Validate breakpoints before trusting their
14825 shadow. Delete disabled breakpoints.
14826 (check_mem_write): Validate breakpoints before trusting they
14827 should be inserted. Delete disabled breakpoints.
14828 * mem-break.h (validate_breakpoints):
14829 * server.c (handle_query): Validate breakpoints when we see a
14832 2010-04-01 Pedro Alves <pedro@codesourcery.com>
14834 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
14835 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
14836 if we could tell there's a GDB breakpoint at stop_pc.
14837 (need_step_over_p): Don't do a step over if we find a GDB
14838 breakpoint at the resume PC.
14840 * mem-break.c (struct raw_breakpoint): New.
14841 (enum bkpt_type): New type `gdb_breakpoint'.
14842 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
14843 fields. New field `raw'.
14844 (find_raw_breakpoint_at): New.
14845 (set_raw_breakpoint_at): Handle refcounting. Create a raw
14846 breakpoint instead.
14847 (set_breakpoint_at): Adjust.
14848 (delete_raw_breakpoint): New.
14849 (release_breakpoint): New.
14850 (delete_breakpoint): Rename to...
14851 (delete_breakpoint_1): ... this. Add proc parameter. Use
14852 release_breakpoint. Return ENOENT.
14853 (delete_breakpoint): Reimplement.
14854 (find_breakpoint_at): Delete.
14855 (find_gdb_breakpoint_at): New.
14856 (delete_breakpoint_at): Delete.
14857 (set_gdb_breakpoint_at): New.
14858 (delete_gdb_breakpoint_at): New.
14859 (gdb_breakpoint_here): New.
14860 (set_reinsert_breakpoint): Use release_breakpoint.
14861 (uninsert_breakpoint): Rename to ...
14862 (uninsert_raw_breakpoint): ... this.
14863 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
14864 (reinsert_raw_breakpoint): Change parameter type to
14866 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
14868 (check_breakpoints): Adjust. Use release_breakpoint.
14869 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
14870 (breakpoint_inserted_here): Ditto.
14871 (check_mem_read): Adjust to iterate over raw breakpoints instead.
14872 Don't trust the breakpoint's shadow if it is not inserted.
14873 (check_mem_write): Adjust to iterate over raw breakpoints instead.
14874 (delete_all_breakpoints): Adjust.
14875 (free_all_breakpoints): Mark all breakpoints as uninserted, and
14876 use delete_breakpoint_1.
14878 * mem-break.h (breakpoints_supported): Delete declaration.
14879 (set_gdb_breakpoint_at): Declare.
14880 (gdb_breakpoint_here): Declare.
14881 (delete_breakpoint_at): Delete.
14882 (delete_gdb_breakpoint_at): Declare.
14884 * server.h (struct raw_breakpoint): Forward declare.
14885 (struct process_info): New field `raw_breakpoints'.
14887 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
14890 2010-03-24 Pedro Alves <pedro@codesourcery.com>
14892 * linux-low.c (status_pending_p_callback): Fix comment.
14893 (linux_wait_for_event_1): Move most of the internal breakpoint
14894 handling from here...
14895 (linux_wait_1): ... to here.
14896 (count_events_callback): New.
14897 (select_singlestep_lwp_callback): New.
14898 (select_event_lwp_callback): New.
14899 (cancel_breakpoints_callback): New.
14900 (select_event_lwp): New.
14901 (linux_wait_1): Simplify internal breakpoint handling. Give equal
14902 priority to all LWPs that have had events that should be reported
14903 to the client. Cancel breakpoints when about to reporting the
14904 event to the client, not while stopping lwps. No longer cancel
14905 finished single-steps here.
14906 (cancel_finished_single_step): Delete.
14907 (cancel_finished_single_steps): Delete.
14909 2010-03-24 Pedro Alves <pedro@codesourcery.com>
14911 * mem-break.c (enum bkpt_type): New.
14912 (struct breakpoint): New field `type'.
14913 (set_breakpoint_at): Change return type to struct breakpoint
14914 pointer. Set type to `other_breakpoint' by default.
14915 (delete_breakpoint): Rewrite, supporting more than one breakpoint
14916 in the breakpoint list.
14917 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
14918 (reinsert_breakpoint): Rename to ...
14919 (reinsert_raw_breakpoint): ... this.
14920 (reinsert_breakpoints_at): Adjust.
14921 * mem-break.h (struct breakpoint): Declare.
14922 (set_breakpoint_at): Change return type to struct breakpoint
14925 2010-03-24 Pedro Alves <pedro@codesourcery.com>
14927 * server.c (handle_query): Assign, not compare.
14929 2010-03-24 Pedro Alves <pedro@codesourcery.com>
14931 Teach linux gdbserver to step-over-breakpoints.
14933 * linux-low.c (can_hardware_single_step): New.
14934 (supports_breakpoints): New.
14935 (handle_extended_wait): If stopping threads, read the stop pc of
14936 the new cloned LWP.
14938 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
14939 low target doesn't support retrieving the PC.
14940 (add_lwp): Set last_resume_kind to resume_continue.
14941 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
14942 (linux_attach): Don't clear stop_expected. Set the lwp's
14943 last_resume_kind to resume_stop.
14944 (linux_detach_one_lwp): Don't check for removed breakpoints.
14945 (check_removed_breakpoint): Delete.
14946 (status_pending_p): Rename to ...
14947 (status_pending_p_callback): ... this. Don't check for removed
14948 breakpoints. Don't consider threads that are stopped from GDB's
14950 (linux_wait_for_lwp): Always read the stop_pc here.
14951 (cancel_breakpoint): New.
14952 (step_over_bkpt): New global.
14953 (linux_wait_for_event_1): Implement stepping over breakpoints.
14954 (gdb_wants_lwp_stopped): New.
14955 (gdb_wants_all_stopped): New.
14956 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
14957 single-step traps here. Store the thread's last reported target
14959 (send_sigstop): Don't clear stop_expected. Always set it,
14961 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
14962 (cancel_finished_single_step): New.
14963 (cancel_finished_single_steps): New.
14964 (wait_for_sigstop): Don't cancel finished single-step traps here.
14965 (linux_resume_one_lwp): Don't check for removed breakpoints.
14966 Don't set `step' on non-hardware step archs.
14967 (linux_set_resume_request): Ignore resume_stop requests if already
14968 stopping or stopped. Set the lwp's last_resume_kind.
14969 (resume_status_pending_p): Don't check for removed breakpoints.
14970 (need_step_over_p): New.
14971 (start_step_over): New.
14972 (finish_step_over): New.
14973 (linux_resume_one_thread): Always queue a sigstop for resume_stop
14974 requests. Clear the thread's last reported target waitstatus.
14975 Don't use the `suspended' flag. Don't consider pending breakpoints.
14976 (linux_resume): Start a step-over if necessary.
14977 (proceed_one_lwp): New.
14978 (proceed_all_lwps): New.
14979 (unstop_all_lwps): New.
14980 * linux-low.h (struct lwp_info): Rewrite comment for the
14981 `suspended' flag. Add the `stop_pc' field. Delete the
14982 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
14983 Add `'last_resume_kind' and `need_step_over' fields.
14984 * inferiors.c (struct thread_info): Delete, moved elsewhere.
14985 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
14986 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
14987 (set_raw_breakpoint_at): New.
14988 (set_breakpoint_at): Rewrite to use it.
14989 (reinsert_breakpoint_handler): Delete.
14990 (set_reinsert_breakpoint): New.
14991 (reinsert_breakpoint_by_bp): Delete.
14992 (delete_reinsert_breakpoints): New.
14993 (uninsert_breakpoint): Rewrite.
14994 (uninsert_breakpoints_at): New.
14995 (reinsert_breakpoint): Rewrite.
14996 (reinsert_breakpoints_at): New.
14997 (check_breakpoints): Rewrite.
14998 (breakpoint_here): New.
14999 (breakpoint_inserted_here): New.
15000 (check_mem_read): Adjust.
15001 * mem-break.h (breakpoints_supported, breakpoint_here)
15002 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
15003 (reinsert_breakpoint_by_bp): Delete declaration.
15004 (delete_reinsert_breakpoints): Declare.
15005 (reinsert_breakpoint): Delete declaration.
15006 (reinsert_breakpoints_at): Declare.
15007 (uninsert_breakpoint): Delete declaration.
15008 (uninsert_breakpoints_at): Declare.
15009 (check_breakpoints): Adjust prototype.
15010 * server.h: Adjust include order.
15011 (struct thread_info): Declare here. Add a `last_status' field.
15013 2010-03-23 Michael Snyder <msnyder@vmware.com>
15015 * server.c (crc32): New function.
15016 (handle_query): Add handling for 'qCRC:' request.
15018 2010-03-23 Pedro Alves <pedro@codesourcery.com>
15020 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
15021 lwp had been stopped by a watchpoint.
15023 2010-03-16 Pedro Alves <pedro@codesourcery.com>
15025 * server.h (internal_error): Declare.
15026 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
15027 * utils.c (internal_error): New function.
15029 2010-03-15 Andreas Schwab <schwab@redhat.com>
15031 * configure.srv: Fix typo setting srv_regobj.
15033 2010-03-15 Pedro Alves <pedro@codesourcery.com>
15035 * linux-low.c (fetch_register): Avoid passing a non string literal
15037 (usr_store_inferior_registers): Ditto.
15039 2010-03-14 Pedro Alves <pedro@codesourcery.com>
15041 * linux-low.c (linux_write_memory): Bail out early if peeking
15044 2010-03-14 Pedro Alves <pedro@codesourcery.com>
15046 * linux-low.h (struct lwp_info): New fields
15047 `stopped_by_watchpoint' and `stopped_data_address'.
15048 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
15049 here, and cache them in the lwp object.
15050 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
15052 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
15054 (linux_stopped_by_watchpoint): Rewrite.
15055 (linux_stopped_data_address): Rewrite.
15057 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
15059 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
15060 switching the current inferior, not before.
15062 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
15064 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
15065 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
15066 i386-linux.c and amd64-linux.c.
15067 (reg-i386.o): Removed.
15068 (reg-i386.c): Likewise.
15069 (reg-i386-linux.o): Likewise.
15070 (reg-i386-linux.c): Likewise.
15071 (reg-x86-64.o): Likewise.
15072 (reg-x86-64.c): Likewise.
15073 (reg-x86-64-linux.o): Likewise.
15074 (reg-x86-64-linux.c): Likewise.
15076 (i386.c): Likewise.
15077 (i386-linux.o): Likewise.
15078 (i386-linux.c): Likewise.
15079 (amd64.o): Likewise.
15080 (amd64.c): Likewise.
15081 (amd64-linux.o): Likewise.
15082 (amd64-linux.c): Likewise.
15084 * configure.srv (srv_i386_regobj): New.
15085 (srv_i386_linux_regobj): Likewise.
15086 (srv_amd64_regobj): Likewise.
15087 (srv_amd64_linux_regobj): Likewise.
15088 (srv_i386_32bit_xmlfiles): Likewise.
15089 (srv_i386_64bit_xmlfiles): Likewise.
15090 (srv_i386_xmlfiles): Likewise.
15091 (srv_amd64_xmlfiles): Likewise.
15092 (srv_i386_linux_xmlfiles): Likewise.
15093 (srv_amd64_linux_xmlfiles): Likewise.
15094 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
15095 srv_xmlfiles to $srv_i386_xmlfiles.
15096 (i[34567]86-*-mingw32ce*): Likewise.
15097 (i[34567]86-*-mingw*): Likewise.
15098 (i[34567]86-*-nto*): Likewise.
15099 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
15100 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
15101 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
15102 (x86_64-*-linux*): Likewise.
15104 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
15105 (init_registers_amd64_linux): New.
15106 (x86_arch_setup): Replace init_registers_x86_64_linux with
15107 init_registers_amd64_linux.
15109 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
15111 * configure.ac: Check for libdl. If it is not available link against
15112 static libthread_db.
15113 * configure: Regenerate.
15115 2010-02-22 Pedro Alves <pedro@codesourcery.com>
15119 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
15120 handing a read watchpoint.
15121 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
15123 2010-02-12 Doug Evans <dje@google.com>
15125 * linux-low.c (linux_supports_tracefork_flag): Document.
15126 (linux_look_up_symbols): Add comment.
15128 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
15130 * regcache.c (supply_register): Clear regcache if buf is NULL.
15132 2010-02-02 Nicolas Roche <roche@sourceware.org>
15133 Joel Brobecker <brobecker@adacore.com>
15135 * inferiors.c (find_inferior): Add function documentation.
15136 (unloaded_dll): Handle the case where the unloaded dll has not
15137 been previously registered in the dll list.
15139 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
15141 * linux-arm-low.c (thumb_breakpoint_len): Delete.
15142 (thumb2_breakpoint): New.
15143 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
15145 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
15147 * linux-low.c (get_stop_pc): Check for SIGTRAP.
15148 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
15151 2010-01-21 Pedro Alves <pedro@codesourcery.com>
15153 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
15155 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
15157 * linux-s390-low.c (s390_collect_ptrace_register)
15158 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
15160 2010-01-21 Doug Evans <dje@google.com>
15162 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
15163 (PTRACE_ARG4_TYPE): New macro.
15164 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
15165 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
15166 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
15167 (usr_store_inferior_registers): Ditto.
15168 (linux_read_memory, linux_write_memory): Ditto.
15169 (linux_test_for_tracefork): Ditto.
15171 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
15172 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
15174 2010-01-21 Pedro Alves <pedro@codesourcery.com>
15176 * proc-service.c (ps_lgetregs): Don't refetch registers from the
15179 2010-01-21 Pedro Alves <pedro@codesourcery.com>
15181 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
15182 prototype to take a regcache. Adjust.
15184 2010-01-20 Pedro Alves <pedro@codesourcery.com>
15186 * regcache.h (struct thread_info): Forward declare.
15187 (struct regcache): New.
15188 (new_register_cache): Adjust prototype.
15189 (get_thread_regcache): Declare.
15190 (free_register_cache): Adjust prototype.
15191 (registers_to_string, registers_from_string): Ditto.
15192 (supply_register, supply_register_by_name, collect_register)
15193 (collect_register_as_string, collect_register_by_name): Ditto.
15194 * regcache.c (struct inferior_regcache_data): Delete.
15195 (get_regcache): Rename to ...
15196 (get_thread_regcache): ... this. Adjust. Switch inferior before
15197 fetching registers.
15198 (regcache_invalidate_one): Adjust.
15199 (regcache_invalidate): Fix prototype.
15200 (new_register_cache): Return the new register cache.
15201 (free_register_cache): Change prototype.
15202 (realloc_register_cache): Adjust.
15203 (registers_to_string): Change prototype to take a regcache. Adjust.
15204 (registers_from_string): Ditto.
15205 (register_data): Ditto.
15206 (supply_register): Ditto.
15207 (supply_register_by_name): Ditto.
15208 (collect_register): Ditto.
15209 (collect_register_as_string): Ditto.
15210 (collect_register_by_name): Ditto.
15211 * server.c (process_serial_event): Adjust.
15212 * linux-low.h (regset_fill_func, regset_store_func): Change
15214 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
15216 * linux-low.c (get_stop_pc): Adjust.
15217 (check_removed_breakpoint): Adjust.
15218 (linux_wait_for_event): Adjust.
15219 (linux_resume_one_lwp): Adjust.
15220 (fetch_register): Add regcache parameter. Adjust.
15221 (usr_store_inferior_registers): Ditto.
15222 (regsets_fetch_inferior_registers): Ditto.
15223 (regsets_store_inferior_registers): Ditto.
15224 (linux_fetch_registers, linux_store_registers): Ditto.
15225 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
15227 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
15229 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
15230 prototype to take a regcache.
15231 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
15232 * remote-utils.c (convert_ascii_to_int, outreg)
15233 (prepare_resume_reply): Change prototype to take a regcache.
15235 * target.h (struct target_ops) <fetch_registers, store_registers>:
15236 Change prototype to take a regcache.
15237 (fetch_inferior_registers, store_inferior_registers): Change
15238 prototype to take a regcache. Adjust.
15239 * proc-service.c (ps_lgetregs): Adjust.
15240 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
15241 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
15242 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
15243 take a regcache. Adjust.
15244 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
15245 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
15246 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
15247 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
15248 * linux-cris-low.c (cris_get_pc, cris_set_pc)
15249 (cris_cannot_fetch_register):
15250 (cris_breakpoint_at): Change prototype to take a regcache.
15252 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
15253 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
15254 to take a regcache. Adjust.
15255 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
15257 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
15258 take a regcache. Adjust.
15259 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
15260 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
15261 (m68k_set_pc): Change prototype to take a regcache. Adjust.
15262 * linux-mips-low.c (mips_get_pc):
15263 (mips_set_pc): Change prototype to take a regcache. Adjust.
15264 (mips_reinsert_addr): Adjust.
15265 (mips_collect_register): Change prototype to take a regcache.
15267 (mips_supply_register):
15268 (mips_collect_register_32bit, mips_supply_register_32bit)
15269 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
15270 (mips_store_fpregset): Ditto.
15271 * linux-ppc-low.c (ppc_supply_ptrace_register)
15272 (ppc_supply_ptrace_register): Ditto.
15273 (parse_spufs_run): Adjust.
15274 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
15275 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
15276 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
15277 take a regcache. Adjust.
15278 * linux-s390-low.c (s390_collect_ptrace_register)
15279 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
15280 (s390_set_pc): Change prototype to take a regcache. Adjust.
15281 (s390_arch_setup): Adjust.
15282 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
15283 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
15284 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
15285 (sparc_fill_gregset, sparc_store_gregset_from_stack)
15286 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
15288 (sparc_breakpoint_at): Adjust.
15289 * linux-xtensa-low.c (xtensa_fill_gregset):
15290 (xtensa_store_gregset):
15291 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
15292 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
15293 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
15294 prototype to take a regcache. Adjust.
15295 * win32-arm-low.c (arm_fetch_inferior_register)
15296 (arm_store_inferior_register): Change prototype to take a
15298 * win32-i386-low.c (i386_fetch_inferior_register)
15299 (i386_store_inferior_register): Change prototype to take a
15301 * win32-low.c (child_fetch_inferior_registers)
15302 (child_store_inferior_registers): Change prototype to take a
15304 (win32_wait): Adjust.
15305 (win32_fetch_inferior_registers): Change prototype to take a
15307 (win32_store_inferior_registers): Adjust.
15308 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
15309 store_inferior_register>: Change prototype to take a regcache.
15311 2010-01-20 Doug Evans <dje@google.com>
15313 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
15315 (linux_wait_for_event1, linux_init_signals): Ditto.
15316 (W_STOPCODE): Provide definition if missing.
15318 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
15320 * linux-low.c (linux_core_of_thread): New.
15321 (compare_ints, show_process, list_threads): New.
15322 (linux_qxfer_osdata): Report threads and cores.
15323 (linux_target_op): Register linux_core_of_thread.
15324 * remote-utils.c (prepare_resume_reply): Report the core.
15325 (buffer_xml_printf): Support %d specifier.
15326 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
15328 (handle_query): Handle qXfer:threads. Announce availability
15330 * target.h (struct target_ops): New field core_of_thread.
15332 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
15334 * Makefile.in (clean): Remove new generated files.
15335 (reg-s390.o, reg-s390.c): Remove rules.
15336 (reg-s390x.o, reg-s390x.c): Likewise.
15337 (s390-linux32.o, s390-linux32.c): Add rules.
15338 (s390-linux64.o, s390-linux64.c): Likewise.
15339 (s390x-linux64.o, s390x-linux64.c): Likewise.
15340 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
15341 * linux-s390-low.c: Include <elf.h>.
15342 (HWCAP_S390_HIGH_GPRS): Define if undefined.
15343 (init_registers_s390): Remove prototype.
15344 (init_registers_s390x): Likewise.
15345 (init_registers_s390_linux32): Add prototype.
15346 (init_registers_s390_linux64): Likewise.
15347 (init_registers_s390x_linux64): Likewise.
15348 (s390_num_regs_3264): New define.
15349 (s390_regmap_3264): New global variable.
15350 (s390_cannot_fetch_register): Remove obsolete check.
15351 (s390_cannot_store_register): Likewise.
15352 (s390_collect_ptrace_register): Handle upper/lower register halves.
15353 (s390_supply_ptrace_register): Likewise.
15354 (s390_fill_gregset): Update to register number changes.
15355 (s390_get_hwcap): New routine.
15356 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
15357 Install appropriate regmap and register set.
15359 2010-01-01 Joel Brobecker <brobecker@adacore.com>
15361 * server.c (gdbserver_version): Update copyright year to 2010.
15362 * gdbreplay.c (gdbreplay_version): Likewise.
15364 2009-12-28 Doug Evans <dje@google.com>
15366 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
15367 elf/external.h. Include <elf.h> instead but only if necessary.
15369 2009-12-28 Pedro Alves <pedro@codesourcery.com>
15371 * linux-low.c (linux_remove_process): Remove `detaching'
15372 parameter. Don't release/detach from thread_db here.
15373 (linux_kill): Release/detach from thread_db here, ...
15374 (linux_detach): ... and here, before actually detaching.
15375 (linux_wait_1): ... and here, when a process exits.
15376 * thread-db.c (any_thread_of): New.
15377 (thread_db_free): Switch the current inferior to a thread of the
15380 2009-12-21 Doug Evans <dje@google.com>
15382 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
15384 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
15385 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
15386 warning ifndef __NR_tkill. Move setting of errno there too.
15387 Delete unnecessary resetting of errno after syscall.
15388 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
15390 * configure.ac: Check for dladdr.
15391 * config.in: Regenerate.
15392 * configure: Regenerate.
15393 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
15394 (try_thread_db_load): Update.
15396 * linux-low.c (my_waitpid): Delete unnecessary prototype.
15398 2009-12-18 Doug Evans <dje@google.com>
15400 * event-loop.c: Include unistd.h if it exists.
15402 * linux-low.c (my_waitpid): Move definition away from being in
15403 between linux_tracefork_child/linux_test_for_tracefork.
15405 * gdb_proc_service.h (psaddr_t): Fix type.
15406 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
15407 signature to match glibc.
15409 2009-12-16 Doug Evans <dje@google.com>
15411 * linux-low.c (linux_read_memory): Fix argument to read.
15413 2009-11-26 Pedro Alves <pedro@codesourcery.com>
15415 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
15416 events, don't leave current_inferior pointing at null.
15418 2009-11-26 Pedro Alves <pedro@codesourcery.com>
15420 * win32-low.c (LOG): Delete.
15421 (OUTMSG): Output to stderr.
15422 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
15423 on compile time LOG macro.
15424 (win32_wait): Fix debug output.
15426 2009-11-26 Pedro Alves <pedro@codesourcery.com>
15428 * win32-low.c (win32_add_one_solib): If the dll name is
15429 "ntdll.dll", prepend the system directory to the dll path.
15431 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
15433 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
15435 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
15436 Vladimir Prus <vladimir@codesourcery.com>
15438 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
15439 * configure.ac: Check for __mcoldfire__ and set
15440 gdb_cv_m68k_is_coldfire.
15441 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
15442 reg-cf.o and reg-m68k.o.
15443 * configure: Regenerated.
15445 2009-11-16 Pedro Alves <pedro@codesourcery.com>
15447 * linux-low.c (linux_remove_process): Add `detaching' parameter.
15448 Pass it to thread_db_free.
15449 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
15450 proper `detaching' argument to linux_remove_process.
15451 * linux-low.h (thread_db_free): Add `detaching' parameter.
15452 * thread-db.c (thread_db_init): Pass false as `detaching' argument
15454 (thread_db_free): Add `detaching' parameter. Only
15455 call td_ta_clear_event if detaching from process.
15457 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
15459 * thread-db.c (thread_db_free): Fix typo.
15461 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
15464 * thread-db.c (thread_db_free): Call td_ta_clear_event.
15466 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
15468 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
15469 with an i686 compiler.
15470 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
15472 * configure: Rebuilt.
15474 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
15478 * server.c (handle_search_memory_1): Correct read_addr initialization
15479 in loop for searching subsequent chunks.
15481 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
15483 * configure.ac: New --with-libthread-db option.
15484 * thread-db.c: Allow direct dependence on libthread_db.
15485 (thread_db_free): Adjust.
15486 * config.in: Regenerate.
15487 * configure: Likewise.
15489 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
15492 * thread-db.c (attach_thread): New function.
15493 (maybe_attach_thread): Return success/failure.
15494 (find_new_threads_callback): Adjust.
15495 (thread_db_find_new_threads): Loop until no new threads.
15497 2009-10-13 Pedro Alves <pedro@codesourcery.com>
15499 * proc-service.c (ps_lgetregs): Formatting.
15501 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
15503 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
15504 * configure.ac: Adjust.
15505 * linux-low.h (struct process_info_private): Move members to struct
15507 (thread_db_free, thread_db_handle_monitor_command): New prototype.
15508 * linux-low.c (linux_remove_process): Adjust.
15509 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
15510 * server.c (handle_query): Move code ...
15511 (handle_monitor_command): ... here. New function.
15512 * target.h (struct target_ops): New member.
15513 * thread-db.c (struct thread_db): New.
15514 (libthread_db_search_path): New variable.
15515 (thread_db_create_event, thread_db_enable_reporting)
15516 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
15517 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
15518 (try_thread_db_load_1, dladdr_to_soname): New functions.
15519 (try_thread_db_load, thread_db_load_search): New functions.
15520 (thread_db_init): Search for libthread_db.
15521 (thread_db_free): New function.
15522 (thread_db_handle_monitor_command): Likewise.
15523 * config.in: Regenerate.
15524 * configure: Regenerate.
15526 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
15528 * spu-low.c (spu_kill): Wait for inferior to terminate.
15529 Call clear_inferiors.
15530 (spu_detach): Call clear_inferiors.
15532 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15534 * aclocal.m4: Regenerate.
15535 * config.in: Likewise.
15536 * configure: Likewise.
15538 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
15540 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
15541 (parse_spufs_run): New function.
15542 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
15543 (ppc_breakpoint_at): Handle SPU breakpoints.
15545 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
15547 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
15548 (SPUFS_MAGIC): Define.
15549 (spu_enumerate_spu_ids): New function.
15550 (linux_qxfer_spu): New function.
15551 (linux_target_ops): Install linux_qxfer_spu.
15553 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
15555 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
15556 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
15557 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
15558 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
15559 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
15560 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
15561 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
15562 (init_registers_powerpc_cell32l): Add prototype.
15563 (init_registers_powerpc_cell64l): Likewise.
15564 (ppc_arch_setup): Detect Cell/B.E. architecture.
15566 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15568 * Makefile.in (datarootdir): New variable.
15570 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
15572 * linux-low.c (linux_write_memory): Update debugging output.
15573 * Makefile.in (clean): Add new descriptions.
15574 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
15575 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
15576 * configure.srv: Add new files for arm*-*-linux*.
15577 * linux-arm-low.c: Add new declarations.
15578 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
15579 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
15580 (HWCAP_VFPv3D16): New.
15581 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
15582 instead of __IWMMXT__.
15583 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
15584 (arm_arch_setup): New.
15585 (target_regsets): Remove #ifdef. Add VFP regset.
15586 (the_low_target): Use arm_arch_setup.
15588 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
15590 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
15591 the main thread again.
15593 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
15595 Adding Neutrino gdbserver.
15596 * configure: Regenerated.
15597 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
15598 * configure.srv (i[34567]86-*-nto*): New target.
15599 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
15600 * remote-utils.c [__QNX__]: Include sys/iomgr.h
15601 (nto_comctrl) [__QNX__]: New function.
15602 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
15604 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
15606 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
15609 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
15610 Pedro Alves <pedro@codesourcery.com>
15612 * win32-i386-low.c (i386_get_thread_context): Handle systems that
15613 don't support CONTEXT_EXTENDED_REGISTERS.
15614 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
15615 (the_low_target): Install them.
15616 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
15617 failing with ERROR_PIPE_NOT_CONNECTED.
15619 2009-06-30 Doug Evans <dje@google.com>
15620 Pierre Muller <muller@ics.u-strasbg.fr>
15622 Add h/w watchpoint support to x86-linux, win32-i386.
15623 * Makefile.in (SFILES): Add i386-low.c
15624 (i386_low_h): Define.
15625 (i386-low.o): Add dependencies.
15626 (linux-x86-low.o): Add i386-low.h dependency.
15627 (win32-i386-low.o): Ditto.
15628 * i386-low.c: New file.
15629 * i386-low.h: New file.
15630 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
15631 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
15632 * linux-low.c (linux_add_process): Initialize arch_private.
15633 (linux_remove_process): Free arch_private.
15634 (add_lwp): Initialize arch_private.
15635 (delete_lwp): Free arch_private.
15636 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
15638 * linux-low.h (process_info_private): New member arch_private.
15639 (lwp_info): New member arch_private.
15640 (linux_target_ops): New members new_process, new_thread,
15642 (ptid_of): New macro.
15643 * linux-x86-low.c: Include stddef.h, i386-low.h.
15644 (arch_process_info): New struct.
15645 (arch_lwp_info): New struct.
15646 (x86_linux_dr_get, x86_linux_dr_set): New functions.
15647 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
15648 (i386_dr_low_get_status): New function.
15649 (x86_insert_point, x86_remove_point): New functions.
15650 (x86_stopped_by_watchpoint): New function.
15651 (x86_stopped_data_address): New function.
15652 (x86_linux_new_process, x86_linux_new_thread): New functions.
15653 (x86_linux_prepare_to_resume): New function.
15654 (the_low_target): Add entries for insert_point, remove_point,
15655 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
15657 * server.c (debug_hw_points): New global.
15658 (monitor_show_help): Document set debug-hw-points.
15659 (handle_query): Process "set debug-hw-points".
15660 * server.h (debug_hw_points): Declare.
15661 (paddress): Declare.
15662 * utils.c (NUMCELLS, CELLSIZE): New macros.
15663 (get_sell, xsnprintf, paddress): New functions.
15664 * win32-arm-low.c (the_low_target): Add entries for insert_point,
15665 remove_point, stopped_by_watchpoint, stopped_data_address.
15666 * win32-i386-low.c: Include i386-low.h.
15667 (debug_reg_state): Replaces dr.
15668 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
15669 (i386_dr_low_get_status): New function.
15670 (i386_insert_point, i386_remove_point): New functions.
15671 (i386_stopped_by_watchpoint): New function.
15672 (i386_stopped_data_address): New function.
15673 (i386_initial_stuff): Update.
15674 (get_thread_context,set_thread_context,i386_thread_added): Update.
15675 (the_low_target): Add entries for insert_point,
15676 remove_point, stopped_by_watchpoint, stopped_data_address.
15677 * win32-low.c (win32_insert_watchpoint): New function.
15678 (win32_remove_watchpoint): New function.
15679 (win32_stopped_by_watchpoint): New function.
15680 (win32_stopped_data_address): New function.
15681 (win32_target_ops): Add entries for insert_watchpoint,
15682 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
15683 * win32-low.h (win32_target_ops): New members insert_point,
15684 remove_point, stopped_by_watchpoint, stopped_data_address.
15686 2009-06-25 Pedro Alves <pedro@codesourcery.com>
15688 * server.c (process_serial_event): Re-return unsupported, not
15689 error, if the type isn't recognized. Re-allow supporting only
15690 insert or remove packets. Also call require_running for
15691 breakpoints. Add missing break statement to default case. Tidy.
15692 * target.h (struct target_ops): Rename insert_watchpoint to
15693 insert_point, and remove_watchpoint to remove_point.
15695 * linux-low.h (struct linux_target_ops): Likewise.
15696 * linux-low.c (linux_insert_watchpoint): Rename to ...
15697 (linux_insert_point): ... this. Adjust.
15698 (linux_remove_watchpoint): Rename to ...
15699 (linux_remove_point): ... this. Adjust.
15700 (linux_target_ops): Adjust.
15701 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
15702 (cris_insert_point): ... this.
15703 (cris_remove_watchpoint): Rename to ...
15704 (cris_remove_point): ... this.
15705 (the_low_target): Adjust.
15707 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
15709 * server.c (handle_v_kill): Pass signal_pid to
15710 kill_inferior if multi_process is zero.
15712 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
15714 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
15715 * target.h (target_ops): Comment for *_watchpoint to make it clear
15716 the functions can get types '0' and '1'.
15718 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
15720 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
15721 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
15722 * regcache.c (get_regcache): Likewise.
15723 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
15724 * win32-low.c (child_fetch_inferior_registers): Remove check for
15727 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
15728 Pedro Alves <pedro@codesourcery.com>
15730 * target.h (struct target_ops) <supports_multi_process>: New
15732 (target_supports_multi_process): New.
15733 * server.c (handle_query): Even if GDB reports support, only
15734 enable multi-process if the target also supports it. Report
15735 multi-process support only if the target backend supports it.
15736 * linux-low.c (linux_supports_multi_process): New function.
15737 (linux_target_ops): Install it as target_supports_multi_process
15740 2009-05-24 Doug Evans <dje@google.com>
15742 Global renaming of find_thread_pid to find_thread_ptid.
15743 * server.h (find_thread_ptid): Renamed from find_thread_pid.
15744 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
15745 All callers updated.
15747 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
15748 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
15751 * linux-low.c (get_stop_pc): Print pc if debug_threads.
15752 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
15753 (linux_resume_one_lwp): Ditto.
15755 2009-05-23 Doug Evans <dje@google.com>
15757 * linux-low.c (linux_resume_one_lwp): Change type of first arg
15758 from struct inferior_list_entry * to struct lwp_info *.
15759 All callers updated.
15761 2009-05-13 Doug Evans <dje@google.com>
15763 * linux-x86-low.c: Don't include assert.h.
15764 (x86_siginfo_fixup): Use fatal, not assert.
15765 (x86_arch_setup): Fix comment.
15767 2009-05-12 Doug Evans <dje@google.com>
15769 Biarch support for i386/amd64 gdbserver.
15770 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
15771 Add linux-x86-low.c.
15772 (linux-i386-low.o, linux-x86-64-low.o): Delete.
15773 (linux-x86-low.o): Add.
15774 * linux-x86-64-low.c: Delete.
15775 * linux-i386-low.c: Delete.
15776 * linux-x86-low.c: New file.
15777 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
15779 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
15781 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
15782 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
15783 (linux_child_pid_to_exec_file): New function.
15784 (elf_64_header_p, elf_64_file_p): New functions.
15785 (siginfo_fixup): New function.
15786 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
15787 give target a chance to convert layout.
15788 * linux-low.h (linux_target_ops): New member siginfo_fixup.
15789 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
15791 2009-05-07 Doug Evans <dje@google.com>
15793 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
15794 (regsets_store_inferior_registers): Ditto.
15796 2009-05-06 Pedro Alves <pedro@codesourcery.com>
15800 * linux-low.c (must_set_ptrace_flags): Delete.
15801 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
15803 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
15804 `lwp->must_set_ptrace_flags' instead.
15805 (linux_wait_for_event_1): Set ptrace options here.
15806 (linux_wait_1): ... not here.
15808 2009-04-30 Doug Evans <dje@google.com>
15810 * inferiors.c (started_inferior_callback): New function.
15811 (attached_inferior_callback): New function.
15812 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
15813 * server.c (print_started_pid, print_attached_pid): New functions.
15814 (detach_or_kill_for_exit): New function.
15815 (main): Call it instead of for_each_inferior (kill_inferior_callback).
15816 * server.h (have_started_inferiors_p): Declare.
15817 (have_attached_inferiors_p): Declare.
15819 * inferiors.c (remove_process): Fix memory leak, free process.
15820 * linux-low.c (linux_remove_process): New function.
15821 (linux_kill): Call it instead of remove_process.
15822 (linux_detach, linux_wait_1): Ditto.
15824 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
15826 * configure.srv: Add x86 Windows CE target.
15828 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
15830 * inferiors.c (get_thread_process): Make global.
15831 * server.h (get_thread_process): Add prototype.
15832 * thread-db.c (find_one_thread): Use get_thread_process
15833 instead of current_process.
15834 (thread_db_get_tls_address): Do not crash if called when
15835 thread layer is not yet initialized.
15837 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
15839 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
15840 * spu-low.c (current_tid): Rename to ...
15841 (current_ptid): ... this.
15842 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
15843 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
15844 ptid_get_lwp (current_ptid) instead of current_tid.
15845 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
15846 instead of current_tid. Use find_process_pid to verify pid
15847 argument is valid. Pass proper argument to remove_process.
15848 (spu_thread_alive): Compare current_ptid instead of current_tid.
15849 (spu_resume): Likewise.
15851 2009-04-02 Pedro Alves <pedro@codesourcery.com>
15853 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
15856 2009-04-01 Pedro Alves <pedro@codesourcery.com>
15858 Implement the multiprocess extensions, and add linux multiprocess
15861 * server.h (ULONGEST): Declare.
15862 (struct ptid, ptid_t): New.
15863 (minus_one_ptid, null_ptid): Declare.
15864 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
15865 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
15866 (struct inferior_list_entry): Change `id' type from unsigned from
15868 (struct sym_cache, struct breakpoint, struct
15869 process_info_private): Forward declare.
15870 (struct process_info): Declare.
15871 (current_process): Declare.
15872 (all_processes): Declare.
15873 (initialize_inferiors): Declare.
15874 (add_thread): Adjust to use ptid_t.
15875 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
15876 (add_process, remove_process, find_thread_pid): Declare.
15877 (find_inferior_id): Adjust to use ptid_t.
15878 (cont_thread, general_thread, step_thread): Change type to ptid_t.
15879 (multi_process): Declare.
15880 (push_event): Adjust to use ptid_t.
15881 (read_ptid, write_ptid): Declare.
15882 (prepare_resume_reply): Adjust to use ptid_t.
15883 (clear_symbol_cache): Declare.
15884 * inferiors.c (all_processes): New.
15885 (null_ptid, minus_one_ptid): New.
15886 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
15887 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
15888 (add_thread): Change unsigned long to ptid. Remove gdb_id
15890 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
15891 (gdb_id_to_thread): Rename to ...
15892 (find_thread_pid): ... this. Change unsigned long to ptid.
15893 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
15894 (loaded_dll, pull_pid_from_list): Adjust.
15895 (add_process, remove_process, find_process_pid)
15896 (get_thread_process, current_process, initialize_inferiors): New.
15897 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
15898 (struct target_waitstatus) <related_pid>: Ditto.
15899 (struct target_ops) <kill, detach>: Add `pid' argument. Change
15900 return type to int.
15901 (struct target_ops) <join>: Add `pid' argument.
15902 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
15903 (struct target_ops) <wait>: Add `ptid' field. Change return type
15905 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
15906 (mywait): Add `ptid' argument. Change return type to ptid_t.
15907 (target_pid_to_str): Declare.
15908 * target.c (set_desired_inferior): Adjust to use ptids.
15909 (mywait): Add new `ptid' argument. Adjust.
15910 (target_pid_to_str): New.
15911 * mem-break.h (free_all_breakpoints): Declare.
15912 * mem-break.c (breakpoints): Delelete.
15913 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
15914 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
15915 to use per-process breakpoint list.
15916 (free_all_breakpoints): New.
15917 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
15918 (symbol_cache, all_symbols_looked_up): Delete.
15920 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
15922 (prepare_resume_reply): Change ptid argument's type from unsigned
15923 long to ptid_t. Adjust. Implement W;process and X;process.
15924 (free_sym_cache, clear_symbol_cache): New.
15925 (look_up_one_symbol): Adjust to per-process symbol cache. *
15926 * server.c (cont_thread, general_thread, step_thread): Change type
15928 (attached): Delete.
15929 (multi_process): New.
15930 (last_ptid): Change type to ptid_t.
15931 (struct vstop_notif) <ptid>: Change type to ptid_t.
15932 (queue_stop_reply, push_event): Change `ptid' argument's type to
15934 (discard_queued_stop_replies): Add `pid' argument.
15935 (start_inferior): Adjust to use ptids. Adjust to mywait interface
15936 changes. Don't reference the `attached' global.
15937 (attach_inferior): Adjust to mywait interface changes.
15938 (handle_query): Adjust to use ptids. Parse GDB's qSupported
15939 features. Handle and report "multiprocess+". Handle
15941 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
15943 (handle_v_kill): New.
15944 (handle_v_stopped): Adjust to use target_pid_to_str.
15945 (handle_v_requests): Allow multiple attaches and runs when
15946 multiprocess extensions are in effect. Handle "vKill".
15947 (myresume): Adjust to use ptids.
15948 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
15949 (handle_status): Adjust to discard_queued_stop_replies interface
15951 (first_thread_of, kill_inferior_callback)
15952 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
15953 (main): Call initialize_inferiors. Adjust to use ptids, killing
15954 and detaching from all inferiors. Handle multiprocess packet
15956 * linux-low.h: Include gdb_proc_service.h.
15957 (struct process_info_private): New.
15958 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
15959 <lwpid_of>: Use ptid_get_lwp.
15960 (get_lwp_thread): Adjust.
15961 (struct lwp_info): Add `dead' member.
15962 (find_lwp_pid): Declare.
15963 * linux-low.c (thread_db_active): Delete.
15964 (new_inferior): Adjust comment.
15965 (inferior_pid): Delete.
15966 (linux_add_process): New.
15967 (handle_extended_wait): Adjust.
15968 (add_lwp): Change unsigned long to ptid.
15969 (linux_create_inferior): Add process to processes table. Adjust
15970 to use ptids. Don't set new_inferior here.
15971 (linux_attach_lwp): Rename to ...
15972 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
15973 it. Adjust to use ptids.
15974 (linux_attach_lwp): New.
15975 (linux_attach): Add process to processes table. Don't set
15977 (struct counter): New.
15978 (second_thread_of_pid_p, last_thread_of_process_p): New.
15979 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
15980 multiple processes.
15981 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
15982 processes. Remove process from process table.
15983 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
15984 to multiple processes.
15985 (any_thread_of): New.
15986 (linux_detach): Add `pid' argument, and handle it. Remove process
15987 from processes table.
15988 (linux_join): Add `pid' argument. Handle it.
15989 (linux_thread_alive): Change unsighed long argument to ptid_t.
15990 Consider dead lwps as not being alive.
15991 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
15992 threads we're not interested in.
15993 (same_lwp, find_lwp_pid): New.
15994 (linux_wait_for_lwp): Change `pid' argument's type from int to
15996 (linux_wait_for_event): Rename to ...
15997 (linux_wait_for_event_1): ... this. Change `pid' argument's type
15998 from int to ptid_t. Adjust.
15999 (linux_wait_for_event): New.
16000 (linux_wait_1): Add `ptid' argument. Change return type to
16001 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
16002 that exit from the process table.
16003 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
16005 (mark_lwp_dead): New.
16006 (wait_for_sigstop): Adjust to use ptids. If a process exits while
16007 stopping all threads, mark its main lwp as dead.
16008 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
16010 (fetch_register, usr_store_inferior_registers)
16011 (regsets_fetch_inferior_registers)
16012 (regsets_store_inferior_registers, linux_read_memory)
16013 (linux_write_memory): Inline `inferior_pid'.
16014 (linux_look_up_symbols): Adjust to use per-process
16015 `thread_db_active'.
16016 (linux_request_interrupt): Adjust to use ptids.
16017 (linux_read_auxv): Inline `inferior_pid'.
16018 (initialize_low): Don't reference thread_db_active.
16019 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
16020 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
16021 (ps_getpid): Return the pid of the current inferior.
16022 * thread-db.c (proc_handle, thread_agent): Delete.
16023 (thread_db_create_event, thread_db_enable_reporting): Adjust to
16025 (find_one_thread): Change argument type to ptid_t. Adjust to
16027 (maybe_attach_thread): Adjust to per-process data and ptids.
16028 (thread_db_find_new_threads): Ditto.
16029 (thread_db_init): Ditto.
16030 * spu-low.c (spu_create_inferior, spu_attach): Add process to
16031 processes table. Adjust to use ptids.
16032 (spu_kill, spu_detach): Adjust interface. Remove process from
16034 (spu_join, spu_thread_alive): Adjust interface.
16035 (spu_wait): Adjust interface. Remove process from processes
16036 table. Adjust to use ptids.
16037 * win32-low.c (current_inferior_tid): Delete.
16038 (current_inferior_ptid): New.
16039 (debug_event_ptid): New.
16040 (thread_rec): Take a ptid. Adjust.
16041 (child_add_thread): Add `pid' argument. Adjust to use ptids.
16042 (child_delete_thread): Ditto.
16043 (do_initial_child_stuff): Add `attached' argument. Add process to
16045 (child_fetch_inferior_registers, child_store_inferior_registers):
16047 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
16048 (win32_attach): Pass 1 to do_initial_child_stuff.
16049 (win32_kill): Adjust interface. Remove process from processes
16051 (win32_detach): Ditto.
16052 (win32_join): Adjust interface.
16053 (win32_thread_alive): Take a ptid.
16054 (win32_resume): Adjust to use ptids.
16055 (get_child_debug_event): Ditto.
16056 (win32_wait): Adjust interface. Remove exiting process from
16059 2009-04-01 Pedro Alves <pedro@codesourcery.com>
16061 Non-stop mode support.
16063 * server.h (non_stop): Declare.
16064 (gdb_client_data, handler_func): Declare.
16065 (delete_file_handler, add_file_handler, start_event_loop):
16067 (handle_serial_event, handle_target_event, push_event)
16068 (putpkt_notif): Declare.
16069 * target.h (enum resume_kind): New.
16070 (struct thread_resume): Replace `step' field by `kind' field.
16071 (TARGET_WNOHANG): Define.
16072 (struct target_ops) <wait>: Add `options' argument.
16073 <supports_non_stop, async, start_non_stop>: New fields.
16074 (target_supports_non_stop, target_async): New.
16075 (start_non_stop): Declare.
16076 (mywait): Add `options' argument.
16077 * target.c (mywait): Add `options' argument. Print child exit
16078 notifications here.
16079 (start_non_stop): New.
16080 * server.c (non_stop, own_buf, mem_buf): New globals.
16081 (struct vstop_notif): New.
16082 (notif_queue): New global.
16083 (queue_stop_reply, push_event, discard_queued_stop_replies)
16084 (send_next_stop_reply): New.
16085 (start_inferior): Adjust to use resume_kind. Adjust to mywait
16087 (attach_inferior): In non-stop mode, don't wait for the target
16089 (handle_general_set): Handle QNonStop.
16090 (handle_query): When handling qC, return the current general
16091 thread, instead of the first thread of the list.
16092 (handle_query): If the backend supports non-stop mode, include
16093 QNonStop+ in the qSupported query response.
16094 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
16096 (handle_v_attach, handle_v_run): Handle non-stop mode.
16097 (handle_v_stopped): New.
16098 (handle_v_requests): Report support for vCont;t. Handle vStopped.
16099 (myresume): Adjust to use resume_kind. Handle non-stop.
16100 (queue_stop_reply_callback): New.
16101 (handle_status): Handle non-stop mode.
16102 (main): Clear non_stop flag on reconnection. Use the event-loop.
16103 Refactor serial protocol handling from here ...
16104 (process_serial_event): ... to this new function. When GDB
16105 selects any thread, select one here. In non-stop mode, wait until
16106 GDB acks all pending events before exiting.
16107 (handle_serial_event, handle_target_event): New.
16108 * remote-utils.c (remote_open): Install remote_desc in the event
16110 (remote_close): Remove remote_desc from the event loop.
16111 (putpkt_binary): Rename to...
16112 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
16113 (putpkt_binary): New as wrapper around putpkt_binary_1.
16114 (putpkt_notif): New.
16115 (prepare_resume_reply): In non-stop mode, don't change the
16117 * event-loop.c: New.
16118 * Makefile.in (OBJ): Add event-loop.o.
16119 (event-loop.o): New rule.
16121 * linux-low.h (pid_of): Moved here.
16123 (get_lwp_thread): Use lwpid_of.
16124 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
16125 * linux-low.c (pid_of): Delete.
16126 (inferior_pid): Use lwpid_of.
16127 (linux_event_pipe): New.
16128 (target_is_async_p): New.
16130 (handle_extended_wait): Use lwpid_of.
16131 (add_lwp): Don't set lwpid field.
16132 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
16133 (linux_kill_one_lwp): If killing a running lwp, stop it first.
16134 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
16135 (linux_detach_one_lwp): If detaching from a running lwp, stop it
16136 first. Adjust to linux_wait_for_event interface changes. Use
16138 (linux_detach): Don't delete the main lwp here.
16139 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
16140 (status_pending_p): Don't consider explicitly suspended lwps.
16141 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
16142 pointer. Add OPTIONS argument. Change return type to int. Use
16143 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
16144 (linux_wait_for_event): Take an integer pid instead of a lwp_info
16145 pointer. Add status pointer argument. Return a pid instead of a
16146 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
16147 changes. In non-stop mode, don't switch to a random thread.
16148 (linux_wait): Rename to...
16149 (linux_wait_1): ... this. Add target_options argument, and handle
16150 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
16151 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
16152 clean exit and signal exit code. Don't stop all threads in
16153 non-stop mode. In all-stop mode, only stop all threads when
16154 reporting a stop to GDB. Handle explicit thread stop requests.
16155 (async_file_flush, async_file_mark): New.
16157 (send_sigstop): Use lwpid_of.
16158 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
16159 interface changes. In non-stop mode, don't switch to a random
16161 (linux_resume_one_lwp): Use lwpid_of.
16162 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
16163 (linux_resume_one_thread): ... this. Handle resume_stop. In
16164 non-stop mode, don't look for pending flag in all threads.
16165 (resume_status_pending_p): Don't consider explicitly suspended
16167 (my_waitpid): Reimplement. Emulate __WALL.
16168 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
16170 (sigchld_handler, linux_supports_non_stop, linux_async)
16171 (linux_start_non_stop): New.
16172 (linux_target_ops): Register linux_supports_non_stop, linux_async
16173 and linux_start_non_stop.
16174 (initialize_low): Install SIGCHLD handler.
16175 * thread-db.c (thread_db_create_event, find_one_thread)
16176 (thread_db_get_tls_address): Use lwpid_of.
16177 * win32-low.c (win32_detach): Adjust to use resume_kind.
16178 (win32_wait): Add `options' argument.
16179 * spu-low.c (spu_resume): Adjust to use resume_kind.
16180 (spu_wait): Add `options' argument.
16182 2009-04-01 Pedro Alves <pedro@codesourcery.com>
16184 Decouple target code from remote protocol.
16186 * target.h (enum target_waitkind): New.
16187 (struct target_waitstatus): New.
16188 (struct target_ops) <wait>: Return an unsigned long. Take a
16189 target_waitstatus pointer instead of a char pointer.
16190 (mywait): Likewise.
16191 * target.c (mywait): Change prototype to return an unsigned long.
16192 Take a target_waitstatus pointer instead of a char pointer. Adjust.
16193 * server.h (thread_from_wait, old_thread_from_wait): Delete
16195 (prepare_resume_reply): Change prototype to take a
16197 * server.c (thread_from_wait, old_thread_from_wait): Delete.
16198 (last_status, last_ptid): New.
16199 (start_inferior): Remove "statusptr" argument. Adjust. Return a
16200 pid instead of a signal.
16201 (attach_inferior): Remove "status" and "signal" parameters.
16203 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
16205 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
16206 (handle_v_requests, myresume): Remove "status" and "signal"
16207 parameters. Adjust.
16208 (handle_status): New.
16209 (main): Delete local `status'. Adjust.
16210 * remote-utils.c: Include target.h.
16211 (prepare_resume_reply): Change prototype to take a
16212 target_waitstatus. Adjust.
16214 * linux-low.c (linux_wait): Adjust to new target_ops->wait
16216 * spu-low.c (spu_wait): Adjust.
16217 * win32-low.c (enum target_waitkind, struct target_waitstatus):
16219 (win32_wait): Adjust.
16221 2009-04-01 Pedro Alves <pedro@codesourcery.com>
16223 * target.h (struct thread_resume): Delete leave_stopped member.
16224 (struct target_ops): Add a `n' argument to the `resume' callback.
16225 * server.c (start_inferior): Adjust.
16226 (handle_v_cont, myresume): Adjust.
16227 * linux-low.c (check_removed_breakpoint): Adjust to resume
16228 interface change, and to removed leave_stopped field.
16229 (resume_ptr): Delete.
16230 (struct thread_resume_array): New.
16231 (linux_set_resume_request): Add new `arg' parameter. Adjust to
16232 resume interface change.
16233 (linux_continue_one_thread, linux_queue_one_thread)
16234 (resume_status_pending_p): Check if the resume field is NULL
16235 instead of checking the leave_stopped member.
16236 (linux_resume): Adjust to the target resume interface change.
16237 * spu-low.c (spu_resume): Adjust to the target resume interface
16239 * win32-low.c (win32_detach, win32_resume): Ditto.
16241 2009-04-01 Pedro Alves <pedro@codesourcery.com>
16243 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
16245 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
16247 (linux_continue_one_thread): Only preserve the stepping flag if
16248 there's a pending breakpoint.
16250 2009-03-31 Pedro Alves <pedro@codesourcery.com>
16252 * server.c (main): After the inferior having exited, call
16253 remote_close before exiting gdbserver.
16255 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
16257 Fix size of FPSCR in Power 7 processors.
16258 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
16259 (PPC_FEATURE_HAS_DFP): New #define.
16260 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
16263 2009-03-23 Pedro Alves <pedro@codesourcery.com>
16265 * server.c (handle_query) Whitespace and formatting.
16267 2009-03-22 Pedro Alves <pedro@codesourcery.com>
16269 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
16270 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
16271 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
16272 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
16273 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
16274 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
16275 Makefile.in, configure.ac: Fix whitespace throughout.
16276 * configure: Regenerate.
16278 2009-03-22 Pedro Alves <pedro@codesourcery.com>
16280 * inferiors.c (find_inferior): Make it safe for the callback
16281 function to delete the currently iterated inferior.
16283 2009-03-22 Pedro Alves <pedro@codesourcery.com>
16285 * Makefile.in (linuw_low_h): Move higher.
16286 (thread-db.o): Depend on $(linux_low_h).
16288 2009-03-17 Pedro Alves <pedro@codesourcery.com>
16290 Rename "process" to "lwp" throughout.
16292 * linux-low.c (all_processes): Rename to...
16293 (all_lwps): ... this.
16294 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
16295 (add_process): Rename to ...
16296 (add_lwp): ... this. Adjust.
16297 (linux_create_inferior): Adjust.
16298 (linux_attach_lwp): Adjust.
16299 (linux_attach): Adjust.
16300 (linux_kill_one_process): Rename to ...
16301 (linux_kill_one_lwp): ... this. Adjust.
16302 (linux_kill): Adjust.
16303 (linux_detach_one_process): Rename to ...
16304 (linux_detach_one_lwp): ... this. Adjust.
16305 (linux_detach): Adjust.
16306 (check_removed_breakpoint): Adjust.
16307 (status_pending_p): Adjust.
16308 (linux_wait_for_process): Rename to ...
16309 (linux_wait_for_lwp): ... this. Adjust.
16310 (linux_wait_for_event): Adjust.
16311 (send_sigstop): Adjust.
16312 (wait_for_sigstop): Adjust.
16313 (stop_all_processes): Rename to ...
16314 (stop_all_lwps): ... this.
16315 (linux_resume_one_process): Rename to ...
16316 (linux_resume_one_lwp): ... this. Adjust.
16317 (linux_set_resume_request, linux_continue_one_thread)
16318 (linux_queue_one_thread, resume_status_pending_p)
16319 (usr_store_inferior_registers, regsets_store_inferior_registers)
16320 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
16322 * linux-low.h (get_process): Rename to ...
16323 (get_lwp): ... this. Adjust.
16324 (get_thread_process): Rename to ...
16325 (get_thread_lwp): ... this. Adjust.
16326 (get_process_thread): Rename to ...
16327 (get_lwp_thread): ... this. Adjust.
16328 (struct process_info): Rename to ...
16329 (struct lwp_info): ... this.
16330 (all_processes): Rename to ...
16331 (all_lwps): ... this.
16332 * proc-service.c (ps_lgetregs): Adjust.
16333 * thread-db.c (thread_db_create_event, find_one_thread)
16334 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
16336 2009-03-14 Pedro Alves <pedro@codesourcery.com>
16338 * server.c (handle_query): Handle "qAttached".
16340 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
16342 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
16343 GPLv3, update license URL.
16345 2009-03-01 Doug Evans <dje@google.com>
16347 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
16348 (server_h): Add gdb_signals.h.
16349 (signals.o): Update.
16350 * server.h (target_signal_from_host,target_signal_to_host_p)
16351 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
16353 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
16355 * remote-utils.c (getpkt): Also generate remote-debug
16356 information if noack_mode is set.
16358 2009-02-06 Pedro Alves <pedro@codesourcery.com>
16360 * server.c (handle_query): Report qXfer:siginfo:read and
16361 qXfer:siginfo:write as supported and handle them.
16362 * target.h (struct target_ops) <qxfer_siginfo>: New field.
16363 * linux-low.c (linux_xfer_siginfo): New.
16364 (linux_target_ops): Set it.
16366 2009-01-26 Pedro Alves <pedro@codesourcery.com>
16368 * server.c (gdbserver_usage): Mention --remote-debug.
16369 (main): Accept '--remote-debug' switch.
16371 2009-01-18 Doug Evans <dje@google.com>
16373 * regcache.c (new_register_cache): No need to check result of xcalloc.
16374 * server.c (handle_search_memory): Back out calls to xmalloc,
16375 result is checked and error is returned to user upon failure.
16376 (handle_query): Ditto. Add more checks for result of malloc.
16377 (handle_v_cont): Check result of malloc, report error back to
16379 (handle_v_run): Ditto. Call freeargv.
16380 * server.h (freeargv): Declare.
16381 * utils.c (freeargv): New fn.
16383 2009-01-15 Doug Evans <dje@google.com>
16385 * gdbreplay.c (perror_with_name): Make arg const char *.
16386 * server.h (target_signal_to_name): Make return type const char *.
16387 * thread-db.c (thread_db_err_str): Make return type const char *.
16388 * utils.c (perror_with_name): Make arg const char *.
16390 2009-01-14 Pedro Alves <pedro@codesourcery.com>
16392 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
16393 when handling a EXIT_PROCESS_DEBUG_EVENT.
16395 2009-01-06 Joel Brobecker <brobecker@adacore.com>
16397 * gdbreplay.c (gdbreplay_version): Update copyright year.
16398 * server.c (gdbserver_version): Likewise.
16400 2009-01-05 Doug Evans <dje@google.com>
16402 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
16403 (handle_extended_wait): Improve comment.
16405 2008-12-13 Doug Evans <dje@google.com>
16407 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
16408 * server.h (ATTR_MALLOC): New macro.
16409 (xmalloc,xcalloc,xstrdup): Declare.
16410 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
16411 * inferiors.c: Ditto.
16412 * linux-low.c: Ditto.
16413 * mem-break.c: Ditto.
16414 * regcache.c: Ditto.
16415 * remote-utils.c: Ditto.
16418 * win32-low.c: Ditto.
16420 2008-12-12 Doug Evans <dje@google.com>
16422 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
16423 in debugging printf.
16425 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
16427 2008-12-09 Doug Evans <dje@google.com>
16429 * linux-low.h (struct process_info): Delete member tid, unused.
16430 * thread-db.c (find_one_thread): Update.
16431 (maybe_attach_thread): Update.
16433 2008-12-02 Pedro Alves <pedro@codesourcery.com>
16435 * target.h (struct target_ops): Add qxfer_osdata member.
16436 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
16438 (linux_qxfer_osdata): New functions.
16439 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
16441 * server.c (handle_query): Handle "qXfer:osdata:read:".
16442 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
16443 (buffer_xml_printf): New functions.
16444 * server.h (struct buffer): New.
16445 (buffer_grow_str, buffer_grow_str0): New macros.
16446 (buffer_grow, buffer_free, buffer_init, buffer_finish)
16447 (buffer_xml_printf): Declare.
16449 2008-11-24 Doug Evans <dje@google.com>
16451 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
16453 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
16455 * server.c (handle_v_run): Always use the supplied argument list.
16457 2008-11-19 Bob Wilson <bob.wilson@acm.org>
16459 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
16460 (xtensa_regmap_table): Add entry for scompare1.
16462 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
16464 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
16465 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
16466 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
16467 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
16468 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
16469 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
16470 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
16471 XML target descriptions.
16472 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
16473 when inferior is running on an ISA 2.05 or later processor. Add
16474 special case to return offset for full 64-bit slot of FPSCR when
16477 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
16479 * Makefile.in (SFILES, clean): Added sparc64 files.
16480 (reg-sparc64.o, reg-sparc64.c): New.
16481 * configure.srv (sparc*-*-linux*): New configuration.
16482 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
16483 syscall arguments for SPARC.
16484 (regsets_store_inferior_registers): Likewise.
16485 * linux-sparc-low.c: New file.
16487 2008-10-21 Doug Evans <dje@google.com>
16489 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
16490 (READLINE_DIR,READLINE_DEP): Delete.
16491 (INTERNAL_CFLAGS): Update.
16492 (LINTFLAGS): Update.
16494 2008-10-10 Pedro Alves <pedro@codesourcery.com>
16496 * server.c (handle_v_run): If GDB didn't specify an argv, use the
16497 whole argv from the last run, not just argv[0].
16499 2008-09-08 Pedro Alves <pedro@codesourcery.com>
16501 * regcache.c (new_register_cache): Return NULL if the register
16502 cache size isn't known yet.
16503 (free_register_cache): Avoid dereferencing a NULL regcache.
16505 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
16507 * configure.srv: Merge MIPS and MIPS64.
16509 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
16511 * Makefile.in (uninstall): Apply $(EXEEXT) too.
16513 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
16515 * Makefile.in: Add required vsx dependencies.
16517 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
16518 Declare init_registers_powerpc_vsx32l.
16519 Declare init_registers_powerpc_vsx64l.
16520 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
16521 (ppc_arch_setup): Check for VSX in hwcap.
16522 (ppc_fill_vsxregset): New function.
16523 (ppc_store_vsxregset): New function.
16524 Add new VSX entry in regset_info target_regsets.
16526 * configure.srv: Add new VSX dependencies.
16528 2008-08-12 Pedro Alves <pedro@codesourcery.com>
16530 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
16531 (remote_open): Set or clear transport_is_reliable.
16532 (putpkt_binary): Don't expect acks in noack mode.
16533 (getpkt): Don't send ack/nac in noack mode.
16534 * server.c (handle_general_set): Handle QStartNoAckMode.
16535 (handle_query): If connected by tcp pass QStartNoAckMode+ in
16537 (main): Reset noack_mode on every connection.
16538 * server.h (noack_mode): Declare.
16540 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
16542 * Makefile.in (GDBREPLAY_OBS): New variable.
16543 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
16545 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
16546 Daniel Jacobowitz <dan@codesourcery.com>
16548 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
16549 (usr_store_inferior_registers): Likewise.
16550 (regsets_store_inferior_registers): Likewise.
16552 2008-07-31 Rolf Jansen <rj@surtec.com>
16553 Pedro Alves <pedro@codesourcery.com>
16555 * configure.ac: Check for memmem declaration.
16556 * server.c [HAVE_MALLOC_H]: Include malloc.h.
16557 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
16558 (disable_packet_qfThreadInfo): Unconditionally compile.
16559 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
16560 * configure, config.in: Regenerate.
16562 2008-07-28 Doug Kwan <dougkwan@google.com>
16564 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
16565 (linux_write_memory): Remove declaration of errno.
16567 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
16569 * linux-low.c (handle_extended_wait): Do not use "status"
16570 variable uninitialized.
16572 2008-07-07 Pedro Alves <pedro@codesourcery.com>
16574 * server.c (handle_v_attach): Inhibit reporting dll changes.
16576 2008-06-27 Pedro Alves <pedro@codesourcery.com>
16578 * remote-utils.c (prepare_resume_reply): If requested, don't
16579 output "thread:TID" in the T stop reply.
16581 * server.c (disable_packet_vCont, disable_packet_Tthread)
16582 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
16583 (handle_query): If requested, disable support for qC, qfThreadInfo
16585 (handle_v_requests): If requested, disable support for vCont.
16586 (gdbserver_show_disableable): New.
16587 (main): Handle --disable-packet and --disable-packet=LIST.
16589 * server.h (disable_packet_vCont, disable_packet_Tthread)
16590 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
16592 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
16594 * server.c (gdbserver_usage): Mention --version.
16596 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
16598 * Makefile.in (gdbreplay.o): New rule.
16600 2008-06-06 Joseph Myers <joseph@codesourcery.com>
16602 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
16603 message, not gdbserver.
16605 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
16606 Nathan Sidwell <nathan@codesourcery.com>
16607 Joseph Myers <joseph@codesourcery.com>
16609 * acinclude.m4: Include ../../config/acx.m4.
16610 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
16611 * configure, config.in: Regenerate.
16612 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
16613 * server.c (gdbserver_version): Print PKGVERSION.
16614 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
16615 (main): Adjust gdbserver_usage calls.
16616 * gdbreplay.c (version, host_name): Add declarations.
16617 (gdbreplay_version, gdbreplay_usage): New.
16618 (main): Accept --version and --help options.
16620 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
16622 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
16623 (arm_breakpoint_at): Handle Thumb.
16624 (the_low_target): Add comment.
16626 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
16628 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
16630 2008-05-09 Doug Evans <dje@google.com>
16632 * server.h (decode_search_memory_packet): Declare.
16633 * remote-utils.c (decode_search_memory_packet): New fn.
16634 * server.c (handle_search_memory_1): New fn.
16635 (handle_search_memory): New fn.
16636 (handle_query): Process qSearch:memory packets.
16638 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
16640 * regcache.c (registers_length): Remove.
16641 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
16642 full register packet.
16643 * regcache.h (registers_length): Remove prototype.
16644 * server.h (PBUFSIZ): Define to 16384.
16646 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
16648 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
16649 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
16650 powerpc-64l.o, and powerpc-altivec64l.o.
16651 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
16652 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
16653 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
16654 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
16655 rs6000/power-linux.xml, and rs6000/power64-linux.xml
16658 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
16659 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
16660 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
16661 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
16662 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
16663 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
16664 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
16665 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
16666 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
16667 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
16670 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
16671 (init_registers_powerpc_32l): ... this new prototype.
16672 (init_registers_powerpc_32): Remove, replace by ...
16673 (init_registers_powerpc_altivec32l): ... this new prototype.
16674 (init_registers_powerpc_e500): Remove, replace by ...
16675 (init_registers_powerpc_e500l): ... this new prototype.
16676 (init_registers_ppc64): Remove, replace by ...
16677 (init_registers_powerpc_64l): ... this new prototype.
16678 (init_registers_powerpc_64): Remove, replace by ...
16679 (init_registers_powerpc_altivec64l): ... this new prototype.
16680 (ppc_num_regs): Set to 73.
16681 (PT_ORIG_R3, PT_TRAP): Define if necessary.
16682 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
16683 (ppc_cannot_store_register): Handle orig_r3 and trap.
16684 (ppc_arch_setup): Update init_registers_... calls.
16685 (ppc_fill_gregset): Handle orig_r3 and trap.
16687 * inferiors.c (clear_inferiors): Reset current_inferior.
16689 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
16691 * acinclude.m4: Add override.m4.
16692 * configure: Regenerate.
16694 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
16696 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
16697 initial call to init_register_ppc64.
16699 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
16701 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
16702 single powerpc*-*-linux* case.
16703 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
16705 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
16707 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
16708 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
16710 * linux-ppc-low.c: Include <elf.h>.
16711 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
16712 (ppc_hwcap): New global variable.
16713 (ppc_regmap): Remove __SPE__ #ifdef sections.
16714 (ppc_regmap_e500): New global variable.
16715 (ppc_cannot_store_register): Update __SPE__ special case.
16716 (ppc_get_hwcap): New function.
16717 (ppc_arch_setup): Use it to determine whether inferior supports
16718 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
16719 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
16720 Do not access registers if target does not support AltiVec.
16721 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
16722 Do not access registers if target does not support SPE.
16723 (target_regsets): Unconditionally include AltiVec and SPE regsets.
16725 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
16727 * linux-low.c (disabled_regsets, num_regsets): New.
16728 (use_regsets_p): Delete.
16729 (linux_wait_for_process): Clear disabled_regsets.
16730 (regsets_fetch_inferior_registers): Check and set it.
16731 (regsets_store_inferior_registers): Likewise.
16732 (linux_fetch_registers, linux_store_registers): Do not use
16734 (initialize_low): Allocate disabled_regsets.
16736 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
16738 * Makefile.in (LIBOBJS): New.
16739 (OBS): Use LIBOBJS.
16740 (memmem.o): New rule.
16741 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
16742 * configure: Regenerated.
16744 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
16746 * server.c (handle_query): Never return "unsupported" for
16747 qXfer:features:read queries.
16749 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
16751 * server.c (get_features_xml): Fix inverted condition.
16752 (handle_query): Always support qXfer:feature:read.
16754 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
16756 * server.c (wrapper_argv): New.
16757 (start_inferior): Handle wrapper_argv. If set, expect an extra
16759 (gdbserver_usage): Document --wrapper.
16760 (main): Parse --wrapper.
16762 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
16764 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
16765 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
16766 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
16767 (ppc_set_pc): Likewise.
16768 (ppc_arch_setup): New function.
16769 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
16770 of collect_register.
16771 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
16773 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
16775 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
16776 instead of linux-ppc64-low.o.
16777 * linux-ppc64-low.c: Remove file.
16778 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
16779 (linux-ppc64-low.o): Remove rule.
16781 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
16782 (init_registers_powerpc_64): Likewise.
16783 (ppc_regmap): Conditionally define depending on __powerpc64__.
16784 (ppc_cannot_store_register): Do not special-case "fpscr" when
16785 compiled on __powerpc64__.
16786 (ppc_collect_ptrace_register): New function.
16787 (ppc_supply_ptrace_register): New function.
16788 (ppc_breakpoint): Change type to "unsigned int".
16789 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
16790 (the_low_target): Conditionally provide initializers for the
16791 arch_setup member depending on __powerpc64__. Install
16792 collect_ptrace_register and supply_ptrace_register members.
16794 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
16796 * regcache.h (gdbserver_xmltarget): Add extern declaration.
16797 * server.c (gdbserver_xmltarget): Define.
16798 (get_features_xml): Use it to replace "target.xml" and arch_string.
16800 * configure.srv: Remove srv_xmltarget. Add XML files that were
16801 mentioned there to srv_xmlfiles instead. Remove conditional tests
16802 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
16803 srv_xmlfiles and srv_regobj to include all possible choices.
16804 * configure.ac (srv_xmltarget): Remove.
16805 (srv_xmlfiles): Do not add "target.xml".
16806 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
16807 checks for supplementary target information.
16808 * configure: Regenerate.
16809 * Makefile.in (XML_TARGET): Remove.
16810 (target.xml): Remove rule.
16811 (clean): Do not clean up target.xml.
16812 (.PRECIOUS): Do not mention target.xml.
16814 * target.h (struct target_ops): Remove arch_string member.
16815 * linux-low.c (linux_arch_string): Remove.
16816 (linux_target_ops): Remove arch_string initializer.
16817 * linux-low.h (struct linux_target_ops): Remove arch_string member.
16818 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
16819 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
16820 * spu-low.c (spu_arch_string): Remove.
16821 (spu_target_ops): Remove arch_string initializer.
16822 * win32-low.c (win32_arch_string): Remove.
16823 (win32_target_ops): Remove arch_string initializer.
16824 * win32-low.h (struct win32_target_ops): Remove arch_string member.
16825 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
16826 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
16828 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
16830 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
16831 by collect_ptrace_register and supply_ptrace_register hooks.
16832 * linux-low.c (fetch_register): Use supply_ptrace_register callback
16833 instead of checking for the_low_target.left_pad_xfer.
16834 (usr_store_inferior_registers): Use collect_ptrace_register callback
16835 instead of checking for the_low_target.left_pad_xfer.
16837 * linux-s390-low.c (s390_collect_ptrace_register): New function.
16838 (s390_supply_ptrace_register): Likewise.
16839 (s390_fill_gregset): Call s390_collect_ptrace_register.
16840 (the_low_target): Update.
16842 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
16843 (ppc_supply_ptrace_register): Likewise.
16844 (the_low_target): Update.
16846 * linux-i386-low.c (the_low_target): Update.
16847 * linux-x86-64-low.c (the_low_target): Update.
16849 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
16851 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
16852 reg-s390.o and reg-s390x.o.
16854 * linux-low.c (new_inferior): New global variable.
16855 (linux_create_inferior, linux_attach): Set it.
16856 (linux_wait_for_process): Call the_low_target.arch_setup after the
16857 target has stopped for the first time.
16858 (initialize_low): Do not call the_low_target.arch_setup.
16860 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
16861 (s390_set_pc): Likewise.
16862 (s390_arch_setup): New function.
16863 (the_low_target): Use s390_arch_setup as arch_setup routine.
16865 * regcache.c (realloc_register_cache): New function.
16866 (set_register_cache): Call it for each existing regcache.
16868 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
16870 * server.h (init_registers): Remove prototype.
16872 * linux-low.h (struct linux_target_ops): Add arch_setup field.
16873 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
16874 instead of init_registers ().
16875 * linux-arm-low.c (init_registers_arm): Add prototype.
16876 (init_registers_arm_with_iwmmxt): Likewise.
16877 (the_low_target): Add initializer for arch_setup field.
16878 * linux-cris-low.c (init_registers_cris): Add prototype.
16879 (the_low_target): Add initializer for arch_setup field.
16880 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
16881 (the_low_target): Add initializer for arch_setup field.
16882 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
16883 (the_low_target): Add initializer for arch_setup field.
16884 * linux-ia64-low.c (init_registers_ia64): Add prototype.
16885 (the_low_target): Add initializer for arch_setup field.
16886 * linux-m32r-low.c (init_registers_m32r): Add prototype.
16887 (the_low_target): Add initializer for arch_setup field.
16888 * linux-m68k-low.c (init_registers_m68k): Add prototype.
16889 (the_low_target): Add initializer for arch_setup field.
16890 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
16891 (init_registers_mips64_linux): Likewise.
16892 (the_low_target): Add initializer for arch_setup field.
16893 * linux-ppc-low.c (init_registers_ppc): Add prototype.
16894 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
16895 (the_low_target): Add initializer for arch_setup field.
16896 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
16897 (init_registers_powerpc_64): Likewise.
16898 (the_low_target): Add initializer for arch_setup field.
16899 * linux-s390-low.c (init_registers_s390): Add prototype.
16900 (init_registers_s390x): Likewise.
16901 (the_low_target): Add initializer for arch_setup field.
16902 * linux-sh-low.c (init_registers_sh): Add prototype.
16903 (the_low_target): Add initializer for arch_setup field.
16904 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
16905 (the_low_target): Add initializer for arch_setup field.
16906 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
16907 (the_low_target): Add initializer for arch_setup field.
16909 * win32-low.h (struct win32_target_ops): Add arch_setup field.
16910 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
16911 instead of init_registers ().
16912 * win32-arm-low.c (init_registers_arm): Add prototype.
16913 (the_low_target): Add initializer for arch_setup field.
16914 * win32-i386-low.c (init_registers_i386): Add prototype.
16915 (the_low_target): Add initializer for arch_setup field.
16917 * spu-low.c (init_registers_spu): Add prototype.
16918 (initialize_low): Call initialie_registers_spu () instead of
16919 initialize_registers ().
16921 2008-02-19 Pedro Alves <pedro@codesourcery.com>
16923 * server.c (handle_v_requests): When handling the vRun and vAttach
16924 packets, if already debugging a process, don't kill it. Return an
16927 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
16929 * server.c (handle_query): Correct length check.
16931 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
16933 * win32-low.c (do_initial_child_stuff): Add process handle
16934 parameter. Set current_process_handle and current_process_id from the
16935 parameters. Clear globals.
16936 (win32_create_inferior): Don't set current_process_handle and
16937 current_process_id here. Instead pass them on the call to
16938 do_initial_child_stuff.
16939 (win32_attach): Likewise.
16940 (win32_clear_inferiors): New.
16941 (win32_kill): Don't close the current process handle or the
16942 current thread handle here. Instead call win32_clear_inferiors.
16943 (win32_detach): Don't open a new handle to the process. Call
16944 win32_clear_inferiors.
16945 (win32_join): Don't rely on current_process_handle; open a new
16946 handle using the process id.
16947 (win32_wait): Call win32_clear_inferiors when the inferior process
16950 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
16952 * server.c (monitor_show_help): Add "exit".
16954 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
16956 * Makefile.in (SFILES): Add linux-xtensa-low.c.
16957 (clean): Add reg-xtensa.c.
16958 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
16959 * configure.srv (xtensa*-*-linux*) New target.
16960 * linux-xtensa-low.c: New.
16961 * xtensa-xtregs.c: New.
16963 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
16965 * hostio.c: Don't include errno.h.
16966 (errno_to_fileio_errno): Move to hostio-errno.
16967 * hostio.c: (hostio_error): Remove the error parameter. Defer the
16968 error number outputting to the target->hostio_last_error callback.
16969 (hostio_packet_error): Use FILEIO_EINVAL directly.
16970 (handle_open, handle_pread, hostio_error, handle_unlink): Update
16971 calls to hostio_error.
16972 * hostio-errno.c: New.
16973 * server.h (hostio_last_error_from_errno): Declare.
16974 * target.h (target_ops): Add hostio_last_error member.
16975 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
16976 as hostio_last_error handler.
16977 * spu-low.c (spu_target_ops): Likewise.
16978 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
16979 (wince_hostio_last_error): New functions.
16980 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
16981 as hostio_last_error handler.
16982 (win32_target_ops) [!_WIN32_WCE]: Register
16983 hostio_last_error_from_errno as hostio_last_error handler.
16984 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
16985 (hostio-errno.o): New rule.
16986 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
16987 * configure.srv (srv_hostio_err_objs): New variable. Default to
16989 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
16990 * configure: Regenerate.
16992 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
16994 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
16995 (linux_kill, linux_detach): Clean up the process list.
16996 * remote-utils.c (remote_open): Improve port number parsing.
16997 (putpkt_binary, input_interrupt): Only send interrupts if the target
16999 * server.c (extended_protocol): Make static.
17000 (attached): Define earlier.
17001 (exit_requested, response_needed, program_argv): New variables.
17002 (target_running): New.
17003 (start_inferior): Clear attached here.
17004 (attach_inferior): Set attached here.
17005 (require_running): Define.
17006 (handle_query): Use require_running and target_running. Implement
17008 (handle_v_attach, handle_v_run): New.
17009 (handle_v_requests): Use require_running. Handle vAttach and vRun.
17010 (gdbserver_usage): Update.
17011 (main): Redo argument parsing. Handle --debug and --multi. Handle
17012 --attach along with other options or after the port. Save
17013 program_argv. Support no initial program. Resynchronize
17014 communication with GDB after an error. Handle "monitor exit".
17015 Use require_running and target_running. Always allow the extended
17016 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
17017 restart in extended mode.
17018 * README: Refer to the GDB manual. Update --attach usage.
17020 2007-12-20 Andreas Schwab <schwab@suse.de>
17022 * linux-low.c (STACK_SIZE): Define.
17023 (linux_tracefork_child): Use it. Use __clone2 on ia64.
17024 (linux_test_for_tracefork): Likewise.
17026 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
17028 * linux-low.c (linux_wait_for_event): Update messages. Do not
17029 reinsert auto-delete breakpoints.
17030 * mem-break.c (struct breakpoint): Change return type of handler to
17032 (set_breakpoint_at): Update handler type.
17033 (reinsert_breakpoint_handler): Return 1 instead of calling
17035 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
17037 (check_breakpoints): Delete auto-delete breakpoints and return 2.
17038 * mem-break.h (set_breakpoint_at): Update handler type.
17039 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
17040 * win32-low.c (auto_delete_breakpoint): New.
17041 (get_child_debug_event): Use it.
17043 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
17045 * configure.ac: Check for pread and pwrite.
17046 * hostio.c (handle_pread): Fall back to lseek and read.
17047 (handle_pwrite): Fall back to lseek and write.
17048 * config.in, configure: Regenerated.
17050 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
17052 * server.c (myresume): Add own_buf argument.
17053 (main): Update calls.
17055 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
17057 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
17058 * remote-utils.c (remote_open): Do not call disable_async_io.
17059 (block_async_io): Delete.
17060 (unblock_async_io): Make static.
17061 (initialize_async_io): New.
17062 * server.c (handle_v_cont): Handle async I/O here.
17063 (myresume): Likewise. Move other common resume tasks here...
17064 (main): ... from here. Call initialize_async_io. Disable async
17065 I/O before the main loop.
17066 * server.h (initialize_async_io): Declare.
17067 (block_async_io, unblock_async_io): Delete prototypes.
17068 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
17070 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
17072 * remote-utils.c (readchar): Allow binary data in received messages.
17074 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17076 * win32-low.c (attaching): New global.
17077 (win32_create_inferior): Clear the `attaching' global.
17078 (win32_attach): Set the `attaching' global.
17079 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
17080 attaching. Only set a breakpoint at the entry point if not
17083 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17085 * server.c (main): Don't report dll events on the initial
17086 connection on attaches.
17088 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17090 * server.c (main): Relax numerical bases supported for the pid of
17091 the --attach command line argument.
17093 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17095 * win32-low.c (win32_attach): Call OpenProcess before
17096 DebugActiveProcess, not after. Add last error output to error
17099 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17101 * win32-low.c (win32_get_thread_context)
17102 (win32_set_thread_context): New functions.
17103 (thread_rec): Use win32_get_thread_context.
17104 (continue_one_thread, win32_resume): Use win32_set_thread_context.
17105 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
17108 2007-12-03 Leo Zayas
17109 Pedro Alves <pedro_alves@portugalmail.pt>
17111 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
17113 (child_add_thread): Minor cleanup.
17114 (child_continue): Resume artificially suspended threads before
17115 calling ContinueDebugEvent.
17116 (suspend_one_thread): New.
17117 (fake_breakpoint_event): New.
17118 (get_child_debug_event): Change return type to int. Check here if
17119 gdb sent an interrupt request. If a soft interrupt was requested,
17120 fake a breakpoint event. Return 0 if there is no event to handle,
17122 (win32_wait): Don't check here if gdb sent an interrupt request.
17123 Ensure there is a valid event to handle.
17124 (win32_request_interrupt): Add soft interruption method as last
17127 2007-12-03 Leo Zayas
17128 Pedro Alves <pedro_alves@portugalmail.pt>
17130 * win32-low.h (win32_thread_info): Add descriptions to the
17131 structure members. Replace `suspend_count' counter by a
17133 * win32-low.c (thread_rec): Update condition of when to get the
17134 context from the inferior. Rely on ContextFlags being set if it
17135 has already been retrieved. Only suspend the inferior thread if
17136 we haven't already. Warn if that fails.
17137 (continue_one_thread): s/suspend_count/suspended/. Only call
17138 ResumeThread once. Warn if that fails.
17140 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
17142 * win32-low.c (win32_wait): Don't read from the inferior when it
17143 has already exited.
17145 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
17147 * Makefile.in (win32_low_h): New variable.
17148 (win32-low.o): Add dependency on $(win32_low_h).
17149 (win32-arm-low.o, win32-i386-low.o): New rules.
17151 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
17153 * hostio.c: Correct copyright year.
17155 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
17157 * Makefile.in (OBS): Add hostio.o.
17158 (hostio.o): New rule.
17159 * server.h (handle_vFile): Declare.
17160 * hostio.c: New file.
17161 * server.c (handle_v_requests): Take packet_len and new_packet_len
17162 for binary packets. Call handle_vFile.
17163 (main): Update call to handle_v_requests.
17165 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
17167 * linux-low.c: Include <sched.h>.
17169 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
17171 * linux-low.c (linux_tracefork_grandchild): New.
17172 (linux_tracefork_child): Use clone.
17173 (linux_test_for_tracefork): Use clone; allocate and free a stack.
17175 2007-10-31 Joel Brobecker <brobecker@adacore.com>
17177 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
17179 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
17181 * linux-low.c (handle_extended_wait): Handle unexpected signals.
17183 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
17185 * inferiors.c (change_inferior_id): Delete.
17186 (add_pid_to_list, pull_pid_from_list): New.
17187 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
17188 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
17189 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
17190 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
17191 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
17192 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
17193 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
17194 (using_threads): Always set to 1.
17195 (handle_extended_wait): New.
17196 (add_process): Do not set TID.
17197 (linux_create_inferior): Set must_set_ptrace_flags.
17198 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
17199 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
17200 (linux_thread_alive): Rename TID argument to LWPID.
17201 (linux_wait_for_process): Handle unknown processes. Do not use TID.
17202 (linux_wait_for_event): Do not use TID or check using_threads. Update
17203 call to dead_thread_notify. Call handle_extended_wait.
17204 (linux_create_inferior): Use PTRACE_SETOPTIONS.
17205 (send_sigstop): Delete sigstop_sent.
17206 (wait_for_sigstop): Avoid TID.
17207 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
17208 (linux_test_for_tracefork): New.
17209 (linux_lookup_signals): Use thread_db_active and
17210 linux_supports_tracefork_flag.
17211 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
17212 * linux-low.h (get_process_thread): Avoid TID.
17213 (struct process_ifo): Move thread_known and tid to the end. Remove
17215 (linux_attach_lwp, thread_db_init): Update prototypes.
17216 * server.h (change_inferior_id): Delete prototype.
17217 (add_pid_to_list, pull_pid_from_list): New prototypes.
17218 * thread-db.c (thread_db_use_events): New.
17219 (find_first_thread): Rename to...
17220 (find_one_thread): ...this. Update callers and messages. Do not
17221 call fatal. Check thread_db_use_events. Do not call
17222 change_inferior_id or new_thread_notify.
17223 (maybe_attach_thread): Update. Do not call new_thread_notify.
17224 (thread_db_init): Set thread_db_use_events. Check use_events.
17225 * utils.c (fatal, warning): Correct message prefix.
17227 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
17229 * Makefile.in (clean): Remove new files.
17230 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
17231 (powerpc-64.o, powerpc-64.c): New rules.
17232 * configure.srv: Use alternate register sets for powerpc64-*-linux*
17233 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
17235 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
17237 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
17238 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
17239 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
17240 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
17241 (target_regsets): Add AltiVec and SPE register sets.
17242 * configure.ac: Check for AltiVec and SPE.
17243 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
17244 (ppc_fill_vrregset, ppc_store_vrregset): New.
17245 (target_regsets): Add AltiVec register set.
17246 * configure: Regenerated.
17248 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
17250 * linux-low.c (O_LARGEFILE): Define.
17251 (linux_read_memory): Use /proc/PID/mem.
17252 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
17253 * configure, config.in: Regenerated.
17255 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
17257 * linux-low.c (linux_wait_for_event): Do not pass signals while
17260 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
17262 * win32-low.c (create_process): New.
17263 (win32_create_inferior): Use create_process instead of
17264 CreateProcess. If create_process failed retry appending an ".exe"
17265 suffix. Store the GetLastError result immediatelly after
17266 create_process calls and use it on the call to error.
17268 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
17270 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
17272 2007-08-23 Joel Brobecker <brobecker@adacore.com>
17274 * configure.ac: Switch license to GPLv3.
17276 2007-08-01 Michael Snyder <msnyder@access-company.com>
17278 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
17280 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
17282 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
17284 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
17285 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
17286 CloseToolhelp32Snapshot.
17287 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
17288 CloseToolhelp32Snapshot.
17290 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
17292 * server.c (main): Check for inferior exit before main loop.
17294 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
17296 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
17297 instead of on tmp_desc.
17299 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
17300 Daniel Jacobowitz <dan@codesourcery.com>
17302 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
17303 (add_thread): Minor cleanups.
17304 (clear_inferiors): Move lower in the file. Clear the DLL
17306 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
17307 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
17308 (xml_escape_text): New.
17309 * server.c (handle_query): Handle qXfer:libraries:read. Report it
17311 (handle_v_cont): Report errors.
17312 (gdbserver_version): Update.
17313 (main): Correct size of own_buf. Do not report initial DLL events.
17314 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
17315 (unloaded_dll, xml_escape_text): New.
17316 * win32-low.c (enum target_waitkind): Update comments.
17317 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
17318 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
17319 (win32_EnumProcessModules, win32_GetModuleInformation)
17320 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
17321 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
17322 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
17323 (win32_Module32First, win32_Module32Next, load_toolhelp)
17324 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
17325 (get_child_debug_event): Handle DLL events.
17326 (win32_wait): Likewise.
17328 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
17330 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
17331 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
17333 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
17335 * win32-low.c (handle_output_debug_string): Ignore event if not
17338 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
17340 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
17342 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
17344 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
17346 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
17348 * inferiors.c (change_inferior_id): Add comment.
17349 * linux-low.c (check_removed_breakpoint): Add an early
17350 prototype. Improve debug output.
17351 (linux_attach): Doc update.
17352 (linux_detach_one_process, linux_detach): Clean up before releasing
17354 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
17355 * linux-low.h (struct process_info): Doc improvement.
17356 * mem-break.c (delete_all_breakpoints): New.
17357 * mem-break.h (delete_all_breakpoints): New prototype.
17358 * thread-db.c (find_first_thread): New.
17359 (thread_db_create_event): Call it instead of
17360 thread_db_find_new_threads. Clean up unused variables.
17361 (maybe_attach_thread): Remove first thread handling.
17362 (thread_db_find_new_threads): Use find_first_thread.
17363 (thread_db_get_tls_address): Likewise.
17365 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
17367 * thread-db.c (thread_db_find_new_threads): Add prototype.
17368 (thread_db_create_event): Check for the main thread before adding
17370 (maybe_attach_thread): Only enable event reporting if TID == 0.
17371 (thread_db_get_tls_address): Check for new threads.
17373 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
17375 * linux-low.c (linux_create_inferior): Try execv before execvp.
17376 * spu-low.c (spu_create_inferior): Likewise.
17378 2007-06-13 Mike Frysinger <vapier@gentoo.org>
17380 * linux-low.c (linux_create_inferior): Change execv to execvp.
17381 * spu-low.c (spu_create_inferior): Likewies.
17383 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
17385 * Makefile.in (clean): Clean new files instead of deleted ones.
17386 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
17387 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
17389 * configure.srv: Specify XML files and new regformats for MIPS and
17391 * linux-mips-low.c (mips_num_regs): Set to only used registers.
17392 (mips_regmap): Do not fetch $0. Remove unused registers. Add
17393 an entry for the restart register.
17394 (mips_cannot_fetch_register, mips_cannot_store_register)
17395 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
17396 register names to match the XML descriptions.
17397 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
17398 restart register instead of $0.
17400 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
17401 Markus Deuling <deuling@de.ibm.com>
17403 * remote-utils.c (decode_xfer_write): New function.
17404 * server.h (decode_xfer_write): Add prototype.
17405 * server.c (handle_query): Add PACKET_LEN argument. Support
17406 qXfer:spu:read and qXfer:spu:write packets.
17407 (main): Pass packet_len to handle_query.
17408 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
17409 * target.h (target_ops): Add qxfer_spu.
17411 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
17413 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
17414 accessing non-seekable spufs files.
17416 2007-05-16 Markus Deuling <deuling@de.ibm.com>
17418 * server.c (handle_query): Add reply for qC packet.
17420 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17421 Leo Zayas <lerele@champenstudios@com>
17423 * server.h (check_remote_input_interrupt_request): New function.
17424 * remote_utils.c (INVALID_DESCRIPTOR): New define.
17425 (remote_desc): Initialize with INVALID_DESCRIPTOR.
17426 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
17427 (check_remote_input_interrupt_request): New function.
17428 * server.h (check_remote_input_interrupt_request): Declare.
17429 * win32-low.c (winapi_DebugBreakProcess,
17430 winapi_GenerateConsoleCtrlEvent): New typedefs.
17431 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
17433 (win32_wait): Check for remote interrupt request
17434 with check_remote_input_interrupt_request.
17435 (win32_request_interrupt): New function.
17436 (win32_target_op): Set request_interrupt to win32_request_interrupt.
17438 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17440 * win32-low.c (debug_registers_changed,
17441 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
17442 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
17443 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
17444 (thread_rec): Get context using the low target.
17445 (child_add_thread): Call thread_added on the low target,
17446 which does the same thing.
17448 (do_initial_child_stuff): Remove debug registers references.
17449 Set context using the low target. Resume threads after
17450 setting the contexts.
17451 (child_continue): Remove dead variable. Remove debug
17452 registers references.
17453 (child_fetch_inferior_registers): Go through the low target.
17454 (do_child_store_inferior_registers): Remove.
17455 (child_store_inferior_registers): Go through the low target.
17456 (win32_resume): Remove debug registers references.
17457 Set context using the low target.
17458 (handle_exception): Change return type to void. Don't record
17459 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
17460 first chance exception.
17461 (get_child_debug_event): Change return type to void. Remove
17462 goto loop. Always return after waiting for debug event.
17463 (win32_wait): Convert to switch statement. Handle spurious
17466 * win32-i386-low.c (debug_registers_changed,
17467 debug_registers_used): New.
17468 (initial_stuff): Rename to ...
17469 (i386_initial_stuff): ... this. Clear debug registers
17471 (store_debug_registers): Delete.
17472 (i386_get_thread_context): New.
17473 (load_debug_registers): Delete.
17474 (i386_set_thread_context): New.
17475 (i386_thread_added): New.
17476 (single_step): Rename to ...
17477 (i386_single_step): ... this.
17478 (do_fetch_inferior_registers): Rename to ...
17479 (i386_fetch_inferior_register): ... this.
17480 (i386_store_inferior_register): New.
17481 (the_low_target): Adapt to new interface.
17483 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
17484 (arm_get_thread_context): New.
17485 (arm_set_thread_context): New.
17487 (do_fetch_inferior_registers): Rename to ...
17488 (arm_fetch_inferior_register): ... this.
17489 (arm_store_inferior_register): New.
17490 (arm_wince_breakpoint): Reimplement as unsigned long.
17491 (arm_wince_breakpoint_len): Define.
17492 (the_low_target): Adapt to new interface.
17494 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
17495 load_debug_registers. Add get_thread_context, set_thread_context,
17496 thread_added and store_inferior_register. Rename
17497 fetch_inferior_registers to fetch_inferior_register.
17498 (regptr): Remove declaration.
17500 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17502 * linux-low.c (linux_detach): Change return type to int. Return 0.
17503 * spu-low.c (spu_detach): Likewise.
17505 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17507 * target.h (target_ops): Change return type of detach to int.
17509 (join_inferior): New.
17510 * server.c (main): Don't skip detach support on mingw32.
17511 If the inferior doesn't support detaching return error.
17512 Call join_inferior instead of using waitpid.
17513 * linux-low.c (linux_join): New.
17514 (linux_target_op): Add linux_join.
17515 * spu-low.c (spu_join): New.
17516 (spu_target_ops): Add spu_join.
17517 * win32-low.c (win32_detach): Adapt to new interface.
17518 Reopen current_process_handle before detaching. Issue a child
17519 resume before detaching.
17521 (win32_target_op): Add win32_join.
17523 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17525 * win32-low.c (win32-attach): Fix return value.
17526 * target.h (target_ops): Describe ATTACH return values.
17528 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17530 * win32-low.c (GETPROCADDRESS): Define.
17531 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
17532 (winapi_DebugSetProcessKillOnExit): Likewise.
17533 (win32_create_inferior): Force usage of ansi CreateProcessA.
17534 (win32_attach): Use GETPROCADDRESS.
17535 (win32_detach): Likewise.
17537 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17539 * win32-low.c (win32_wait): Don't use WSTOPSIG.
17541 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
17543 * win32-low.c: Commit leftover changes from 2007-03-29.
17545 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
17547 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
17548 fields short instead of int. Add explicit padding.
17549 (i387_cache_to_fsave): Remove unnecessary casts.
17550 (i387_fsave_to_cache): Doc fix.
17551 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
17553 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
17555 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
17556 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
17558 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
17560 * configure.srv (arm*-*-mingw32ce*): Move near the other
17563 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
17565 * configure.ac: Add errno checking.
17566 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
17567 sys/file.h and malloc.h.
17568 (AC_CHECK_DECLS): Add perror.
17569 (srv_mingwce): Handle.
17570 * configure.srv (i[34567]86-*-cygwin*): Add
17571 win32-i386-low.o to srv_tgtobj.
17572 (i[34567]86-*-mingw*): Likewise.
17573 (arm*-*-mingw32ce*): Add case.
17574 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
17575 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
17576 [__MINGW32CE__] (strerror): New function.
17577 [__MINGW32CE__] (errno): Define to GetLastError.
17578 [__MINGW32CE__] (COUNTOF): New macro.
17579 (remote_open): Remove extra close call.
17580 * mem-break.c (delete_breakpoint_at): New function.
17581 * mem-break.h (delete_breakpoint_at): Declare.
17582 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
17583 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
17584 [USE_WIN32API] (read, write): Add char* casts.
17585 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
17586 * server.h: Include wincecompat.h on Windows CE.
17587 [HAVE_ERRNO_H]: Check.
17588 (perror): Declare if not declared.
17589 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
17590 (perror_with_name): Remove errno declaration.
17591 * wincecompat.h: New.
17592 * wincecompat.c: New.
17593 * win32-low.h: New.
17594 * win32-arm-low.c: New.
17595 * win32-i386-low.c: New.
17596 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
17597 (OUTMSG2): Make it safe.
17599 (COUNTOF): New macro.
17600 (NUM_REGS): Get it from the low target.
17601 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
17602 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
17603 (thread_rec): Let low target handle debug registers.
17604 (child_add_thread): Likewise.
17605 (child_init_thread_list): Likewise.
17606 (continue_one_thread): Likewise.
17608 (do_child_fetch_inferior_registers): Move to ...
17609 * win32-i386-low.c: ... here, and rename to ...
17610 (do_fetch_inferior_registers): ... this.
17611 * win32-low.c (child_fetch_inferior_registers):
17612 Go through the low target.
17613 (do_child_store_inferior_registers): Use regptr.
17614 (strwinerror): New function.
17615 (win32_create_inferior): Handle Windows CE.
17616 Use strwinerror instead of strerror on Windows error
17617 codes. Add program to the error output.
17618 Don't close the main thread handle on Windows CE.
17619 (win32_attach): Use coredll.dll on Windows CE.
17620 (win32_kill): Close current process and current
17622 (win32_detach): Use coredll.dll on Windows CE.
17623 (win32_resume): Let low target handle debug registers, and
17625 (handle_exception): Add/Remove initial breakpoint. Avoid
17626 non-existant WSTOPSIG on Windows CE.
17627 (win32_read_inferior_memory): Cast to remove warning.
17628 (win32_arch_string): Go through the low target.
17629 (initialize_low): Call set_breakpoint_data with the low
17630 target's breakpoint.
17631 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
17632 FOP_REGNUM, mappings): Move to ...
17633 * win32-i386-low.c: ... here.
17634 * win32-low.c (win32_thread_info): Move to ...
17635 * win32-low.h: ... here.
17636 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
17637 win32-arm-low.c and wincecompat.c.
17638 (all:): Add $EXEEXT.
17639 (install-only:): Likewise.
17640 (gdbserver:): Likewise.
17641 (gdbreplay:): Likewise.
17642 * config.in: Regenerate.
17643 * configure: Regenerate.
17645 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
17647 * win32-low.c: Rename typedef thread_info to
17648 win32_thread_info throughout.
17650 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
17652 * win32-i386-low.c: Rename to ...
17653 * win32-low.c: ... this.
17654 * configure.srv: Replace win32-i386-low.o with win32-low.o.
17655 * Makefile.in: Likewise.
17657 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
17659 * remote-utils.c (monitor_output): Constify msg parameter.
17660 * server.h (monitor_output): Likewise.
17661 * win32-i386-low.c (handle_output_debug_string): New.
17662 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
17663 handle_output_debug_string.
17664 (get_child_debug_event): Likewise.
17666 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
17668 * server.c (main): Correct strtoul check.
17670 2007-03-27 Jon Ringle <jon@ringle.org>
17672 * linux-low.c: Check __ARCH_HAS_MMU__ also.
17674 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
17676 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
17678 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
17680 * terminal.h: Check HAVE_SGTTY_H.
17682 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
17684 * remote-utils.c (remote_open): Print out the assigned port number.
17686 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
17688 * remote-utils.c (monitor_output): New function.
17689 * server.c (debug_threads): Define here.
17690 (monitor_show_help): New function.
17691 (handle_query): Handle qRcmd.
17692 (main): Do not handle 'd' packet.
17693 * server.h (debug_threads, remote_debug, monitor_output): Declare.
17694 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
17697 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
17699 * Makefile.in (EXEEXT): New.
17700 (clean): Use $(EXEEXT).
17702 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
17704 * target.h (target_ops): Rename send_signal to request_interrupt,
17705 and remove enum target_signal parameter.
17706 * linux-low.c (linux_request_interrupt): Rename from
17707 linux_send_signal, and always send SIGINT.
17708 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
17709 and always send SIGINT.
17710 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
17712 (input_interrupt): Likewise.
17714 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
17716 * server.c (get_features_xml): Check if target implemented
17718 * win32-i386-low.c (win32_arch_string): New.
17719 (win32_target_ops): Add win32_arch_string as arch_string member.
17721 2007-02-22 Markus Deuling <deuling@de.ibm.com>
17723 * spu-low.c (spu_arch_string): New.
17724 (spu_target_ops): Add spu_arch_string.
17726 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
17728 * remote-utils.c: Remove HAVE_TERMINAL_H check.
17729 * configure.ac: Do not check for terminal.h.
17730 * configure, config.in: Regenerated.
17732 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
17734 * Makefile.in (OBS): Add $(XML_BUILTIN).
17735 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
17737 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
17738 (arm-with-iwmmxt.c): New.
17739 * config.in, configure: Regenerate.
17740 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
17741 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
17742 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
17743 (arm*-*-linux*): Add iWMMXt and regset support.
17744 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
17745 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
17746 (arm_store_wmmxregset, target_regsets): New.
17747 * server.c (get_features_xml): Take annex argument. Check builtin
17749 (handle_query): Handle multiple annexes.
17751 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
17753 * remote-utils.c [USE_WIN32API] (read, write): Define.
17754 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
17757 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
17759 * linux-i386-low.c (the_low_target): Set arch_string.
17760 * linux-x86-64-low.c (the_low_target): Likewise.
17761 * linux-low.c (linux_arch_string): New.
17762 (linux_target_ops): Add it.
17763 * linux-low.h (struct linux_target_ops): Add arch_string.
17764 * server.c (write_qxfer_response): Use const void * for DATA.
17765 (get_features_xml): New.
17766 (handle_query): Handle qXfer:features:read. Report it for qSupported.
17767 * target.h (struct target_ops): Add arch_string method.
17769 2007-01-03 Denis Pilat <denis.pilat@st.com>
17770 Daniel Jacobowitz <dan@codesourcery.com>
17772 * linux-low.c (linux_kill): Handle being called with no threads.
17773 * win32-i386-low.c (win32_kill): Likewise.
17774 (get_child_debug_event): Clear current_process_handle.
17776 2006-12-30 Denis PILAT <denis.pilat@st.com>
17777 Daniel Jacobowitz <dan@codesourcery.com>
17779 * remote-utils.c (remote_open): Check the type of specified
17780 serial port devices before opening them.
17781 * server.c (main): Kill the inferior if an error occurs during
17782 the first remote_open.
17784 2006-12-05 Markus Deuling <deuling@de.ibm.com>
17786 * README: Update supported targets.
17788 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
17790 * Makefile.in (clean): Remove reg-mips64.c.
17791 (reg-mips64.c, reg-mips64.o): New rules.
17792 * configure.srv: Handle mips64. Include regset support for mips.
17793 * linux-mips-low.c (union mips_register): New.
17794 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
17795 (mips_breakpoint, mips_breakpoint_at): Use int.
17796 (mips_collect_register, mips_supply_register)
17797 (mips_collect_register_32bit, mips_supply_register_32bit)
17798 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
17799 (mips_store_fpregset, target_regsets): New.
17800 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
17802 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
17804 * configure.srv: Add target "spu*-*-*".
17805 * Makefile.in (clean): Remove reg-spu.c.
17806 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
17807 * spu-low.c: New file.
17809 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
17811 * configure.ac: Correct td_thr_tls_get_addr test.
17812 * configure: Regenerated.
17814 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
17816 * linux-low.c (linux_wait_for_event): Reformat. Use the
17817 pass_signals array.
17818 * remote-utils.c (decode_address_to_semicolon): New.
17819 * server.c (pass_signals, handle_general_set): New.
17820 (handle_query): Mention QPassSignals for qSupported.
17821 (main): Call handle_general_set.
17822 * server.h (pass_signals, decode_address_to_semicolon): New.
17824 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
17826 * server.c (handle_query): Correct error handling for read_auxv.
17828 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
17830 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
17831 and srv_linux_thread_db to yes.
17832 * linux-s390-low.c (s390_fill_gregset): New function.
17833 (target_regsets): Define data structure.
17835 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
17837 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
17838 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
17839 * config.in, configure: Regenerated.
17840 * inferiors.c (gdb_id_to_thread): New function.
17841 (gdb_id_to_thread_id): Use it.
17842 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
17843 * linux-low.h (struct process_info): Add th member.
17844 (thread_db_get_tls_address): New prototype.
17845 * remote-utils.c (decode_address): Make non-static.
17846 * server.c (handle_query): Handle qGetTLSAddr.
17847 * server.h (gdb_id_to_thread, decode_address): New prototypes.
17848 * target.h (struct target_ops): Add get_tls_address.
17849 * thread-db.c (maybe_attach_thread): Save the thread handle.
17850 (thread_db_get_tls_address): New.
17852 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
17854 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
17855 (linux_resume_one_process): Take a siginfo_t *. Update all
17856 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
17857 (struct pending_signals): Add a siginfo_t.
17858 (linux_wait_for_process): Always set last_status.
17859 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
17860 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
17861 * linux-low.h (struct process_info): Add last_status.
17863 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
17865 * remote-utils.c (try_rle): New function.
17866 (putpkt_binary): Use it.
17868 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
17870 * Makefile.in (clean): Clean reg-x86-64-linux.c.
17871 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
17872 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
17873 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
17874 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
17877 2006-08-08 Richard Sandiford <richard@codesourcery.com>
17879 * server.c (terminal_fd): New variable.
17880 (old_foreground_pgrp): Likewise.
17881 (restore_old_foreground_pgrp): New function.
17882 (start_inferior): Record the terminal file descriptor in terminal_fd
17883 and its original foreground group in old_foreground_pgrp. Register
17884 restore_old_foreground_pgrp with atexit().
17886 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
17888 * server.c (handle_query): Correct qPart to qXfer.
17890 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
17892 * configure.ac: Check for more headers which are missing on
17893 Windows. Automatically supply -lwsock32 and USE_WIN32API.
17894 * configure.srv: Add Cygwin and mingw32.
17895 * remote-utils.c: Don't include headers unconditionally which
17896 are missing on mingw32. Include <winsock.h> for mingw32.
17897 (remote_open): Adjust for mingw32 support. Flush
17898 standard error after writing to it.
17899 (remote_close, putpkt_binary, input_interrupt, block_async_io)
17900 (unblock_async_io, enable_async_io, disable_async_io)
17901 (readchar, getpkt): Update for Winsock support.
17902 (prepare_resume_reply): Expect a protocol signal number.
17903 * server.c: Disable <sys/wait.h> on mingw32.
17904 (start_inferior): Adjust for mingw32 support. Flush
17905 standard error after writing to it.
17906 (attach_inferior): Likewise. Use protocol signal
17908 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
17910 * win32-i386-low.c: New file.
17911 * Makefile.in (XM_CLIBS): Set.
17912 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
17913 (win32-i386-low.o): New dependency rule.
17914 * linux-low.c (linux_wait): Use target signal numbers.
17915 * target.h (struct target_ops): Doc fix.
17916 * server.h (target_signal_to_name): New prototype.
17917 * gdbreplay.c: Don't include headers unconditionally which
17918 are missing on mingw32. Include <winsock.h> for mingw32.
17919 (remote_close, remote_open): Adjust for Winsock support.
17920 * configure, config.in: Regenerated.
17922 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
17924 * server.c (decode_xfer_read, write_qxfer_response): New.
17925 (handle_query): Take a packet length argument. Handle
17926 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
17927 the qSupported response.
17928 (main): Update call to handle_query.
17930 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
17932 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
17933 (putpkt_binary): Renamed from putpkt and adjusted for binary
17935 (putpkt): New wrapper for putpkt_binary.
17936 (readchar): Don't mask off the high bit.
17937 (decode_X_packet): New function.
17938 * server.c (main): Call putpkt_binary if a handler sets the packet
17939 length. Save the length of the incoming packet. Handle 'X'.
17940 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
17942 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
17944 * server.c (handle_query): Handle qSupported.
17946 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
17948 * remote-utils.c (all_symbols_looked_up): New variable.
17949 (look_up_one_symbol): Check it.
17950 * server.h (look_up_one_symbol): New declaration.
17951 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
17953 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
17955 * Makefile.in (linux-arm-low.o): Update dependencies.
17956 * linux-arm-low.c: Include "gdb_proc_service.h".
17957 (PTRACE_GET_THREAD_AREA): Define.
17958 (ps_get_thread_area): New function.
17960 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
17962 * configure.srv (m68k*-*-uclinux*): New target.
17963 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
17964 (linux_resume_one_process): Remove extraneous cast.
17965 (linux_read_offsets): New.
17966 (linux_target_op): Add linux_read_offsets on mmuless systems.
17967 * server.c (handle_query): Add qOffsets logic.
17968 * target.h (struct target_ops): Add read_offsets.
17970 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
17972 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
17973 (PTRACE_GET_THREAD_AREA): Define.
17974 (ps_get_thread_area): New function.
17975 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
17976 (linux-x86-64-low.o): Update.
17978 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
17980 * configure.ac: Remove checks for prfpregset_t.
17981 * gdb_proc_service.h: New file.
17982 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
17983 new "gdb_proc_service.h".
17984 * proc-service.c: Likewise.
17985 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
17986 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
17987 * Makefile.in (gdb_proc_service_h): Updated.
17988 * configure, config.in: Regenerated.
17990 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
17992 * remote-utils.c (prepare_resume_reply): Move declaration
17993 of gdb_id_from_wait to the top of the block.
17995 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
17997 * linux-low.c (regsets_store_inferior_registers): Read the regset
17998 from the target before filling it.
18000 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
18002 * server.c (attach_inferior): Return SIGTRAP for a successful
18005 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
18007 * Makefile.in (OBS): Add version.o.
18008 (STAGESTUFF): Delete.
18009 (version.o): Add dependencies.
18010 (version.c): Replace rule.
18011 (clean): Remove version.c.
18012 * server.c (gdbserver_version): New.
18013 (gdbserver_usage): Use printf.
18014 (main): Handle --version and --help.
18015 * server.h (version, host_name): Add declarations.
18017 2005-12-23 Eli Zaretskii <eliz@gnu.org>
18029 * linux-x86-64-low.c:
18031 * linux-s390-low.c:
18032 * linux-ppc64-low.c:
18034 * linux-mips-low.c:
18035 * linux-m68k-low.c:
18036 * linux-m32r-low.c:
18039 * linux-ia64-low.c:
18040 * linux-i386-low.c:
18041 * linux-crisv32-low.c:
18053 * gdbserver.1: Add (C) after Copyright. Update the FSF
18056 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
18058 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
18059 (arm_breakpoint_at): Recognize both breakpoints.
18060 (the_low_target): Use the correct breakpoint instruction.
18062 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
18064 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
18065 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
18066 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
18067 (the_low_target): Update.
18069 2005-10-25 Andreas Schwab <schwab@suse.de>
18071 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
18073 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
18074 (ia64_num_regs): Reduce to 462.
18076 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
18078 * acinclude.m4: Correct quoting.
18079 * aclocal.m4: Regenerated.
18081 Suggested by SZOKOVACS Robert <szo@ies.hu>:
18082 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
18083 (thread_db_init): Call thread_db_err_str.
18084 * configure.ac: Check for TD_VERSION.
18085 * config.in, configure: Regenerated.
18087 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
18089 * server.h (error, fatal, warning): Add ATTR_FORMAT.
18091 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
18093 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
18094 is not available. Define HAVE_PTRACE_GETREGS if it is.
18095 * config.in, configure: Regenerated.
18096 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
18097 * linux-i386-low.c, linux-m68k-low.c: Update to use
18098 HAVE_PTRACE_GETREGS.
18099 * linux-low.c (regsets_fetch_inferior_registers)
18100 (regsets_store_inferior_registers): Only return 0 if we processed
18102 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
18103 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
18105 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
18107 * inferiors.c (struct thread_info): Add gdb_id.
18108 (add_thread): Add gdb_id argument.
18109 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
18110 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
18111 calls to add_thread.
18112 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
18113 * server.c (handle_query): Use thread_to_gdb_id.
18114 (handle_v_cont, main): Use gdb_id_to_thread_id.
18115 * server.h (add_thread): Update prototype.
18116 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
18119 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
18121 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
18122 left-padded registers.
18123 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
18124 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
18126 2005-07-01 Steve Ellcey <sje@cup.hp.com>
18128 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
18129 * configure: Regenerate.
18130 * config.in: Regenerate.
18131 * server.h (NEED_DECLARATION_STRERROR):
18132 Replace with !HAVE_DECL_STRERROR.
18134 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
18136 * linux-low.c (linux_wait, linux_send_signal): Don't test
18137 an unsigned long variable for > 0 if it could be MAX_ULONG.
18138 * server.c (myresume): Likewise.
18139 * target.c (set_desired_inferior): Likewise.
18141 2005-06-13 Mark Kettenis <kettenis@gnu.org>
18143 * configure.ac: Simplify and improve check for socklen_t.
18144 * configure, config.in: Regenerate.
18146 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
18148 * acconfig.h: Remove.
18149 * configure.ac: Add a test for socklen_t. Use three-argument
18150 AC_DEFINE throughout.
18151 * config.in: Regenerated using autoheader 2.59.
18152 * configure: Regenerated.
18154 * gdbreplay.c (socklen_t): Provide a default.
18155 (remote_open): Use socklen_t.
18156 * remote-utils.c (socklen_t): Provide a default.
18157 (remote_open): Use socklen_t.
18158 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
18161 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
18163 * linux-low.c (linux_read_memory, linux_write_memory)
18164 (linux_read_auxv): Likewise.
18165 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
18166 (check_mem_write): Likewise.
18167 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
18169 * regcache.c (struct inferior_rgcache_data, registers_to_string)
18170 (registers_from_string, register_data): Likewise.
18171 * server.c (handle_query, main): Likewise.
18172 * server.h (convert_ascii_to_int, convert_int_to_ascii)
18173 (decode_M_packet): Likewise.
18174 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
18175 * target.h (struct target_ops): Update read_memory, write_memory,
18177 (read_inferior_memory, write_inferior_memory): Update.
18178 * linux-low.h (struct linux_target_ops): Change type of breakpoint
18179 to unsigned char *.
18180 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
18181 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
18182 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
18183 linux-s390-low.c, linux-sh-low.c: Update for changes in
18184 read_inferior_memory and the_low_target->breakpoint.
18186 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
18188 * Makefile.in (SFILES): Add linux-ppc64-low.c.
18189 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
18190 * configure.srv: Add powerpc64-*-linux*.
18191 * linux-ppc64-low.c: New file.
18193 2005-05-23 Orjan Friberg <orjanf@axis.com>
18195 * linux-cris-low.c: New file with support for CRIS.
18196 * linux-crisv32-low.c: Ditto for CRISv32.
18197 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
18198 (clean): Add reg-cris.c and reg-crisv32.c.
18199 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
18200 reg-crisv32.o, and reg-crisv32.c to make rules.
18201 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
18202 recognized targets.
18204 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
18206 * linux-low.c (fetch_register): Ensure buffer size is a multiple
18207 of sizeof (PTRACE_XFER_TYPE).
18208 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
18210 2005-05-12 Orjan Friberg <orjanf@axis.com>
18212 * target.h (struct target_ops): Add insert_watchpoint,
18213 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
18214 pointers for hardware watchpoint support.
18215 * linux-low.h (struct linux_target_ops): Ditto.
18216 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
18217 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
18218 to linux_target_ops.
18219 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
18221 * server.c (main): Recognize 'Z' and 'z' packets.
18223 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
18225 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
18226 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
18227 (the_low_target): Add new members.
18229 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
18231 * proc-service.c (ps_lgetregs): Search all_processes instead of
18234 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
18236 * server.c (start_inferior): Change return type to int.
18237 (attach_inferior): Change sigptr to int *.
18238 (handle_v_cont, handle_v_requests): Change signal to int *.
18239 (main): Change signal to int.
18241 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
18243 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
18244 * configure.srv: Add m32r*-*-linux*.
18245 * linux-m32r-low.c: New file.
18247 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
18249 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
18251 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
18253 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
18254 Take unsigned long arguments for PIDs.
18255 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
18256 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
18257 (wait_for_sigstop, linux_resume_one_process)
18258 (regsets_fetch_inferior_registers, linux_send_signal)
18259 (linux_read_auxv): Likewise. Update the types of variables holding
18260 PIDs. Update format string specifiers.
18261 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
18262 * remote-utils.c (prepare_resume_reply): Likewise.
18263 * server.c (cont_thread, general_thread, step_thread)
18264 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
18266 (handle_query): Update format specifiers.
18267 (handle_v_cont, main): Use strtoul for thread IDs.
18268 * server.h (struct inferior_list_entry): Use unsigned long for ID.
18269 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
18270 (general_thread, step_thread, thread_from_wait)
18271 (old_thread_from_wait): Update.
18272 * target.h (struct thread_resume): Use unsigned long for THREAD.
18273 (struct target_ops): Use unsigned long for arguments to attach and
18276 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
18278 * acinclude.m4: Include bfd/bfd.m4 directly.
18279 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
18280 <agriffis@toolchain.org>.
18281 * aclocal.m4, configure: Regenerated.
18283 2005-01-07 Andrew Cagney <cagney@gnu.org>
18285 * configure.ac: Rename configure.in, require autoconf 2.59.
18286 * configure: Re-generate.
18288 2004-12-08 Daniel Jacobowitz <dan@debian.org>
18290 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
18291 LIBS when finished.
18292 * aclocal.m4: Regenerated.
18293 * configure: Regenerated.
18295 2004-11-21 Andreas Schwab <schwab@suse.de>
18297 * linux-m68k-low.c (m68k_num_gregs): Define.
18298 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
18299 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
18300 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
18301 (m68k_breakpoint_at): New. Add to the_low_target.
18303 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
18304 srv_linux_thread_db to yes.
18306 2004-10-20 Joel Brobecker <brobecker@gnat.com>
18308 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
18309 (ARCH_SET_FS): Likewise.
18310 (ARCH_GET_FS): Likewise.
18311 (ARCH_GET_GS): Likewise.
18313 2004-10-16 Daniel Jacobowitz <dan@debian.org>
18315 * linux-i386-low.c (ps_get_thread_area): New.
18316 * linux-x86-64-low.c (ps_get_thread_area): New.
18317 * linux-low.c: Include <sys/syscall.h>.
18318 (linux_kill_one_process): Don't kill the first thread here.
18319 (linux_kill): Kill the first thread here.
18320 (kill_lwp): New function.
18321 (send_sigstop, linux_send_signal): Use it.
18322 * proc-service.c: Clean up #ifdefs.
18323 (fpregset_info): Delete.
18324 (ps_lgetregs): Update and enable implementation.
18325 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
18327 * remote-utils.c (struct sym_cache, symbol_cache): New.
18328 (input_interrupt): Print a clearer message.
18329 (async_io_enabled): New variable.
18330 (enable_async_io, disable_async_io): Use it. Update comments.
18331 (look_up_one_symbol): Use the symbol cache.
18332 * thread-db.c (thread_db_look_up_symbols): New function.
18333 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
18335 2004-10-16 Daniel Jacobowitz <dan@debian.org>
18337 * configure.in: Test for -rdynamic.
18338 * configure: Regenerated.
18339 * Makefile (INTERNAL_LDFLAGS): New.
18340 (gdbserver, gdbreplay): Use it.
18342 2004-09-02 Andrew Cagney <cagney@gnu.org>
18344 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
18346 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
18348 * linux-low.c (linux_wait): Clear all_processes list also.
18350 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
18352 * linux-low.c: Include <errno.h>. Remove extern declaration of
18355 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
18357 * gdbreplay.c, server.h, utils.c: Update copyright years.
18359 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
18361 * server.c (main): Print child status or termination signal from
18362 variable 'signal', not 'sig'.
18364 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
18366 * linux-low.c (linux_read_memory): Change return type to
18367 int. Check for and return error from ptrace().
18368 * target.c (read_inferior_memory): Change return type to int. Pass
18369 back return status from the_target->read_memory().
18370 * target.h (struct target_ops): Adapt *read_memory() prototype.
18372 (read_inferior_memory): Adapt prototype.
18373 * server.c (main): Return an error packet if
18374 read_inferior_memory() returns an error.
18376 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
18378 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
18379 Unify with other clean targets.
18381 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
18383 * server.c (handle_v_cont): Call set_desired_inferior.
18385 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
18387 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
18389 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
18391 * linux-low.c (linux_wait): Unblock async I/O.
18392 (linux_resume): Block and enable async I/O.
18393 * remote-utils.c (block_async_io, unblock_async_io): New functions.
18394 * server.h (block_async_io, unblock_async_io): Add prototypes.
18396 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
18398 * remote-utils.c (remote_open): Print a status notice after
18399 opening a TCP port.
18400 * server.c (attach_inferior): Print a status notice after
18403 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
18405 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
18407 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
18409 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
18411 * server.c, target.h: Update copyright years.
18413 2004-02-25 Roland McGrath <roland@redhat.com>
18415 * target.h (struct target_ops): New member `read_auxv'.
18416 * server.c (handle_query): Handle qPart:auxv:read: query using that.
18417 * linux-low.c (linux_read_auxv): New function.
18418 (linux_target_ops): Initialize `read_auxv' member to that.
18420 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
18422 Committed by Jim Blandy <jimb@redhat.com>.
18424 * linux-s390-low.c (s390_num_regs): Update.
18425 (s390_regmap): Remove control registers. Use __s390x__ predefine
18426 instead of GPR_SIZE to distiguish s390 and s390x targets.
18428 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
18430 * linux-low.c: Update copyright year.
18431 (check_removed_breakpoint): Clear pending_is_breakpoint.
18432 (linux_set_resume_request, linux_queue_one_thread)
18433 (resume_status_pending_p): New functions.
18434 (linux_continue_one_thread): Use process->resume.
18435 (linux_resume): Only resume threads if there are no pending events.
18436 * linux-low.h (struct process_info): Add resume request
18439 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
18441 * regcache.c (new_register_cache): Clear the allocated register
18442 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
18444 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
18446 * linux-low.c (linux_resume): Take a struct thread_resume *
18448 (linux_wait): Update call.
18449 (resume_ptr): New static variable.
18450 (linux_continue_one_thread): Renamed from
18451 linux_continue_one_process. Use resume_ptr.
18452 (linux_resume): Use linux_continue_one_thread.
18453 * server.c (handle_v_cont, handle_v_requests): New functions.
18454 (myresume): New function.
18455 (main): Handle 'v' case.
18456 * target.h (struct thread_resume): New type.
18457 (struct target_ops): Change argument of "resume" to struct
18459 (myresume): Delete macro.
18461 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
18463 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
18464 (uninstall): Support DESTDIR.
18466 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
18468 * configure.srv: Add xscale*linux copy of arm*linux entry.
18470 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
18472 * linux-arm-low.c (arm_reinsert_addr): New function.
18473 (the_low_target): Add arm_reinsert_addr.
18475 2003-07-08 Mark Kettenis <kettenis@gnu.org>
18477 * mem-break.c: Remove whitespace at end of file.
18479 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
18481 * configure.in: Check whether we need to prototype strerror.
18482 * server.h: Optionally prototype strerror.
18483 * gdbreplay.c (perror_with_name): Use strerror.
18484 * linux-low.c (linux_attach_lwp): Use strerror.
18485 * utils.c (perror_with_name): Use strerror.
18486 * config.in, configure: Regenerated.
18488 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
18490 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
18491 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
18493 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
18495 * Makefile.in (SFILES): Update.
18496 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
18497 low-sun3.c: Remove files.
18499 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
18501 * linux-low.c: Move comment to linux_thread_alive where it belonged.
18502 (linux_detach_one_process, linux_detach): New functions.
18503 (linux_target_ops): Add linux_detach.
18504 * server.c (main): Handle 'D' packet.
18505 * target.h (struct target_ops): Add "detach" member.
18506 (detach_inferior): Define.
18508 2003-06-13 Mark Kettenis <kettenis@gnu.org>
18510 From Kelley Cook <kelleycook@wideopenwest.com>:
18511 * configure.srv: Accept i[34567]86 variants.
18513 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
18515 * linux-low.c (linux_wait_for_event): Correct comment typos.
18516 (linux_resume_one_process): Call check_removed_breakpoint.
18517 (linux_send_signal): New function.
18518 (linux_target_ops): Add linux_send_signal.
18519 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
18521 * target.h (struct target_ops): Add send_signal.
18523 2003-05-29 Jim Blandy <jimb@redhat.com>
18525 * linux-low.c (usr_store_inferior_registers): Transfer buf in
18526 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
18527 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
18528 away part of the register's value.
18530 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
18532 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
18533 (linux_wait_for_event, linux_init_signals): Likewise.
18535 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
18537 * configure.in: Check for stdlib.h.
18538 * configure: Regenerated.
18539 * config.in: Regenerated.
18541 2003-01-04 Andreas Schwab <schwab@suse.de>
18543 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
18545 2003-01-02 Andrew Cagney <ac131313@redhat.com>
18547 * Makefile.in: Remove obsolete code.
18549 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
18551 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
18552 defined(PT_FPR0_HI).
18554 2002-11-17 Stuart Hughes <seh@zee2.com>
18556 * linux-arm-low.c (arm_num_regs): Increase.
18557 (arm_regmap): Include status register.
18559 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
18561 * linux-low.c (register_addr): Remove incorrect -1 check.
18563 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
18565 * linux-low.c (linux_create_inferior): Call setpgid. Return
18567 (unstopped_p, linux_signal_pid): Remove.
18568 (linux_target_ops): Remove linux_signal_pid.
18569 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
18570 global instead of target method.
18571 * target.h (struct target_ops): Remove signal_pid. Update comment
18572 for create_inferior.
18573 * server.c (signal_pid): New variable.
18574 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
18575 gdbserver. Set the child to be the foreground process group.
18576 (attach_inferior): Set signal_pid.
18578 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
18580 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
18582 2002-08-20 Jim Blandy <jimb@redhat.com>
18584 * Makefile.in (LDFLAGS): Allow the configure script to establish a
18587 2002-08-01 Andrew Cagney <cagney@redhat.com>
18589 * Makefile.in: Make chill references obsolete.
18591 2002-07-24 Kevin Buettner <kevinb@redhat.com>
18593 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
18594 * configure: Regenerate.
18595 * config.in: Regenerate.
18597 2002-07-09 David O'Brien <obrien@FreeBSD.org>
18599 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
18600 (perror_with_name, remote_close, remote_open, expect, play): Static.
18602 2002-07-04 Michal Ludvig <mludvig@suse.cz>
18604 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
18605 byte offsets instead of an array of indexes.
18606 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
18608 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
18610 * regcache.c: Add comment.
18612 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
18614 * thread-db.c: New file.
18615 * proc-service.c: New file.
18616 * acinclude.m4: New file.
18617 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
18618 proc-service.o, and thread-db.o.
18619 (linux-low.o): Add USE_THREAD_DB.
18620 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
18621 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
18622 * aclocal.m4: Regenerated.
18623 * config.in: Regenerated.
18624 * configure: Regenerated.
18625 * configure.in: Check for proc_service.h, sys/procfs.h,
18626 thread_db.h, and linux/elf.h headrs.
18627 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
18628 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
18629 Check for -lthread_db and thread support.
18630 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
18631 PowerPC, and SuperH.
18632 * i387-fp.c: Constify arguments.
18633 * i387-fp.h: Likewise.
18634 * inferiors.c: (struct thread_info): Renamed from
18635 `struct inferior_info'. Remove PID member. Use generic inferior
18636 list header. All uses updated.
18637 (inferiors, signal_pid): Removed.
18638 (all_threads): New variable.
18639 (get_thread): Define.
18640 (add_inferior_to_list): New function.
18641 (for_each_inferior): New function.
18642 (change_inferior_id): New function.
18643 (add_inferior): Removed.
18644 (remove_inferior): New function.
18645 (add_thread): New function.
18646 (free_one_thread): New function.
18647 (remove_thread): New function.
18648 (clear_inferiors): Use for_each_inferior and free_one_thread.
18649 (find_inferior): New function.
18650 (find_inferior_id): New function.
18651 (inferior_target_data): Update argument type.
18652 (set_inferior_target_data): Likewise.
18653 (inferior_regcache_data): Likewise.
18654 (set_inferior_regcache_data): Likewise.
18655 * linux-low.c (linux_bp_reinsert): Remove.
18656 (all_processes, stopping_threads, using_thrads)
18657 (struct pending_signals, debug_threads, pid_of): New.
18658 (inferior_pid): Replace with macro.
18659 (struct inferior_linux_data): Remove.
18660 (get_stop_pc, add_process): New functions.
18661 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
18662 Use add_process and add_thread.
18663 (linux_attach_lwp): New function, based on old linux_attach. Use
18664 add_process and add_thread. Set stop_expected for new threads.
18665 (linux_attach): New function.
18666 (linux_kill_one_process): New function.
18667 (linux_kill): Kill all LWPs.
18668 (linux_thread_alive): Use find_inferior_id.
18669 (check_removed_breakpoints, status_pending_p): New functions.
18670 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
18671 Update. Use WNOHANG. Wait for cloned processes also. Update process
18672 struct for the found process.
18673 (linux_wait_for_event): New function.
18674 (linux_wait): Use it. Support LWPs.
18675 (send_sigstop, wait_for_sigstop, stop_all_processes)
18676 (linux_resume_one_process, linux_continue_one_process): New functions.
18677 (linux_resume): Support LWPs.
18678 (REGISTER_RAW_SIZE): Remove.
18679 (fetch_register): Use register_size instead. Call supply_register.
18680 (usr_store_inferior_registers): Likewise. Call collect_register.
18681 Fix recursive case.
18682 (regsets_fetch_inferior_registers): Improve error message.
18683 (regsets_store_inferior_registers): Add debugging.
18684 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
18685 (unstopped_p, linux_signal_pid): New functions.
18686 (linux_target_ops): Add linux_signal_pid.
18687 (linux_init_signals): New function.
18688 (initialize_low): Call it. Initialize using_threads.
18689 * regcache.c (inferior_regcache_data): Add valid
18691 (get_regcache): Fetch registers lazily. Add fetch argument
18692 and update all callers.
18693 (regcache_invalidate_one, regcache_invalidate): New
18695 (new_register_cache): Renamed from create_register_cache.
18696 Return the new regcache.
18697 (free_register_cache): Change argument to a void *.
18698 (registers_to_string, registers_from_string): Call get_regcache
18699 with fetch flag set.
18700 (register_data): Make static. Pass fetch flag to get_regcache.
18701 (supply_register): Call get_regcache with fetch flag clear.
18702 (collect_register): Call get_regcache with fetch flag set.
18703 (collect_register_as_string): New function.
18704 * regcache.h: Update.
18705 * remote-utils.c (putpkt): Flush after debug output and use
18707 Handle input interrupts while waiting for an ACK.
18708 (input_interrupt): Use signal_pid method.
18709 (getpkt): Flush after debug output and use stderr.
18710 (outreg): Use collect_register_as_string.
18711 (new_thread_notify, dead_thread_notify): New functions.
18712 (prepare_resume_reply): Check using_threads. Set thread_from_wait
18713 and general_thread.
18714 (look_up_one_symbol): Flush after debug output.
18715 * server.c (step_thread, server_waiting): New variables.
18716 (start_inferior): Don't use signal_pid. Update call to mywait.
18717 (attach_inferior): Update call to mywait.
18718 (handle_query): Handle qfThreadInfo and qsThreadInfo.
18719 (main): Don't fetch/store registers explicitly. Use
18720 set_desired_inferior. Support proposed ``Hs'' packet. Update
18722 * server.h: Update.
18723 (struct inferior_list, struct_inferior_list_entry): New.
18724 * target.c (set_desired_inferior): New.
18725 (write_inferior_memory): Constify.
18726 (mywait): New function.
18727 * target.h: Update.
18728 (struct target_ops): New signal_pid method.
18729 (mywait): Removed macro, added prototype.
18731 * linux-low.h (regset_func): Removed.
18732 (regset_fill_func, regset_store_func): New.
18733 (enum regset_type): New.
18734 (struct regset_info): Add type field. Use new operation types.
18735 (struct linux_target_ops): stop_pc renamed to get_pc.
18736 Add decr_pc_after_break and breakpoint_at.
18737 (get_process, get_thread_proess, get_process_thread)
18738 (strut process_info, all_processes, linux_attach_lwp)
18739 (thread_db_init): New.
18741 * linux-arm-low.c (arm_get_pc, arm_set_pc,
18742 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
18743 (the_low_target): Add new members.
18744 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
18745 (i386_store_fpxregset): Constify.
18746 (target_regsets): Add new kind identifier.
18747 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
18748 (i386_set_pc): Add debugging.
18749 (i386_breakpoint_at): New function.
18750 (the_low_target): Add new members.
18751 * linux-mips-low.c (mips_get_pc, mips_set_pc)
18752 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
18753 (mips_breakpoint_at): New.
18754 (the_low_target): Add new members.
18755 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
18756 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
18757 (the_low_target): Add new members.
18758 * linux-sh-low.c (sh_get_pc, sh_set_pc)
18759 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
18760 (the_low_target): Add new members.
18761 * linux-x86-64-low.c (target_regsets): Add new kind
18764 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
18766 From Martin Pool <mbp@samba.org>:
18767 * server.c (gdbserver_usage): New function.
18770 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
18772 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
18773 stop_at -> stop_pc.
18775 2002-05-04 Andrew Cagney <ac131313@redhat.com>
18777 * Makefile.in: Remove obsolete code.
18779 2002-04-24 Michal Ludvig <mludvig@suse.cz>
18781 * linux-low.c (regsets_fetch_inferior_registers),
18782 (regsets_store_inferior_registers): Removed cast to int from
18784 * regcache.h: Added declaration of struct inferior_info.
18786 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
18788 * inferiors.c (struct inferior_info): Add regcache_data.
18789 (add_inferior): Call create_register_cache.
18790 (clear_inferiors): Call free_register_cache.
18791 (inferior_regcache_data, set_inferior_regcache_data): New functions.
18792 * regcache.c (struct inferior_regcache_data): New.
18793 (registers): Remove.
18794 (get_regcache): New function.
18795 (create_register_cache, free_register_cache): New functions.
18796 (set_register_cache): Don't initialize the register cache here.
18797 (registers_to_string, registers_from_string, register_data): Call
18799 * regcache.h: Add prototypes.
18800 * server.h: Likewise.
18802 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
18804 * mem-break.c: New file.
18805 * mem-break.h: New file.
18806 * Makefile.in: Add mem-break.o rule; update server.h
18808 * inferiors.c (struct inferior_info): Add target_data
18810 (clear_inferiors): Free target_data member if set.
18811 (inferior_target_data, set_inferior_target_data): New functions.
18812 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
18813 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
18814 * linux-low.c (linux_bp_reinsert): New variable.
18815 (struct inferior_linux_data): New.
18816 (linux_create_inferior): Use set_inferior_target_data.
18817 (linux_attach): Likewise. Call add_inferior.
18818 (linux_wait_for_one_inferior): New function.
18819 (linux_wait): Call it.
18820 (linux_write_memory): Add const.
18821 (initialize_low): Call set_breakpoint_data.
18822 * linux-low.h (struct linux_target_ops): Add breakpoint
18824 * server.c (attach_inferior): Remove extra add_inferior
18826 * server.h: Include mem-break.h. Update inferior.c
18828 * target.c (read_inferior_memory)
18829 (write_inferior_memory): New functions.
18830 * target.h (read_inferior_memory)
18831 (write_inferior_memory): Change macros to prototypes.
18832 (struct target_ops): Update comments. Add const to write_memory
18835 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
18837 * linux-low.c (usr_store_inferior_registers): Support
18838 registers which are allowed to fail to store.
18839 * linux-low.h (linux_target_ops): Likewise.
18840 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
18841 (ppc_cannot_store_register): FPSCR may not be storable.
18843 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
18845 * server.h: Include <string.h> if HAVE_STRING_H.
18846 * ChangeLog: Correct paths in last ChangeLog entry.
18848 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
18850 * linux-low.h: Remove obsolete prototypes.
18851 (struct linux_target_ops): New.
18852 (extern the_low_target): New.
18853 * linux-low.c (num_regs, regmap): Remove declarations.
18854 (register_addr): Use the_low_target explicitly.
18855 (fetch_register): Likewise.
18856 (usr_fetch_inferior_registers): Likewise.
18857 (usr_store_inferior_registers): Likewise.
18858 * linux-arm-low.c (num_regs): Remove.
18859 (arm_num_regs): Define.
18860 (arm_regmap): Renamed from regmap, made static.
18861 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
18863 (arm_cannot_store_register): Renamed from cannot_store_register,
18865 (the_low_target): New.
18866 * linux-i386-low.c (num_regs): Remove.
18867 (i386_num_regs): Define.
18868 (i386_regmap): Renamed from regmap, made static.
18869 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
18871 (i386_cannot_store_register): Renamed from cannot_store_register,
18873 (the_low_target): New.
18874 * linux-ia64-low.c (num_regs): Remove.
18875 (ia64_num_regs): Define.
18876 (ia64_regmap): Renamed from regmap, made static.
18877 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
18879 (ia64_cannot_store_register): Renamed from cannot_store_register,
18881 (the_low_target): New.
18882 * linux-m68k-low.c (num_regs): Remove.
18883 (m68k_num_regs): Define.
18884 (m68k_regmap): Renamed from regmap, made static.
18885 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
18887 (m68k_cannot_store_register): Renamed from cannot_store_register,
18889 (the_low_target): New.
18890 * linux-mips-low.c (num_regs): Remove.
18891 (mips_num_regs): Define.
18892 (mips_regmap): Renamed from regmap, made static.
18893 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
18895 (mips_cannot_store_register): Renamed from cannot_store_register,
18897 (the_low_target): New.
18898 * linux-ppc-low.c (num_regs): Remove.
18899 (ppc_num_regs): Define.
18900 (ppc_regmap): Renamed from regmap, made static.
18901 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
18903 (ppc_cannot_store_register): Renamed from cannot_store_register,
18905 (the_low_target): New.
18906 * linux-s390-low.c (num_regs): Remove.
18907 (s390_num_regs): Define.
18908 (s390_regmap): Renamed from regmap, made static.
18909 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
18911 (s390_cannot_store_register): Renamed from cannot_store_register,
18913 (the_low_target): New.
18914 * linux-sh-low.c (num_regs): Remove.
18915 (sh_num_regs): Define.
18916 (sh_regmap): Renamed from regmap, made static.
18917 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
18919 (sh_cannot_store_register): Renamed from cannot_store_register,
18921 (the_low_target): New.
18922 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
18923 (the_low_target): New.
18925 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
18927 * Makefile.in: Add stamp-h target.
18928 * configure.in: Create stamp-h.
18929 * configure: Regenerated.
18931 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
18933 * inferiors.c: New file.
18934 * target.c: New file.
18935 * target.h: New file.
18936 * Makefile.in: Add target.o and inferiors.o. Update
18938 * linux-low.c (inferior_pid): New static variable,
18939 moved from server.c.
18940 (linux_create_inferior): Renamed from create_inferior.
18941 Call add_inferior. Return 0 on success instead of a PID.
18942 (linux_attach): Renamed from myattach.
18943 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
18944 (linux_thread_alive): Renamed from mythread_alive.
18945 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
18947 (linux_resume): Renamed from myresume. Add missing ``return 0''.
18948 (regsets_store_inferior_registers): Correct error message.
18949 Add missing ``return 0''.
18950 (linux_fetch_registers): Renamed from fetch_inferior_registers.
18951 (linux_store_registers): Renamed from store_inferior_registers.
18952 (linux_read_memory): Renamed from read_inferior_memory.
18953 (linux_write_memory): Renamed from write_inferior_memory.
18954 (linux_target_ops): New structure.
18955 (initialize_low): Call set_target_ops ().
18956 * remote-utils.c (unhexify): New function.
18957 (hexify): New function.
18958 (input_interrupt): Send signals to ``signal_pid''.
18959 * server.c (inferior_pid): Remove.
18960 (start_inferior): Update create_inferior call.
18961 (attach_inferior): Call add_inferior.
18962 (handle_query): New function.
18963 (main): Call handle_query for `q' packets.
18964 * server.h: Include "target.h". Remove obsolete prototypes.
18965 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
18967 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
18969 * Makefile.in: Add WARN_CFLAGS. Update configury
18971 * configure.in: Check for <string.h>
18972 * configure: Regenerate.
18973 * config.in: Regenerate.
18974 * gdbreplay.c: Include needed system headers.
18975 (remote_open): Remove strchr prototype.
18976 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
18977 * regcache.c (supply_register): Change buf argument to const void *.
18978 (supply_register_by_name): Likewise.
18979 (collect_register): Change buf argument to void *.
18980 (collect_register_by_name): Likewise.
18981 * regcache.h: Add missing prototypes.
18982 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
18983 * server.c (handle_query): New function.
18984 (attached): New static variable, moved out of main.
18985 (main): Quiet longjmp clobber warnings.
18986 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
18987 * utils.c (error): Remove NORETURN.