1 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3 Turn process_stratum_target's supports_non_stop, async, and
4 start_non_stop ops into methods of process_target.
6 * target.h (struct process_stratum_target): Remove the target ops.
7 (class process_target): Add the target ops.
8 (target_supports_non_stop): Update the macro.
9 (target_async): Update the macro.
10 (start_non_stop): Remove declaration.
11 * target.cc (process_target::supports_non_stop): Define.
12 (process_target::async): Define.
13 (process_target::start_non_stop): Define.
14 (start_non_stop): Remove.
16 Update the derived classes and callers below.
18 * server.cc (handle_qxfer_siginfo): Update.
19 (handle_query): Update.
20 * linux-low.cc (linux_target_ops): Update.
21 (linux_supports_non_stop): Turn into ...
22 (linux_process_target::supports_non_stop): ... this.
23 (linux_async): Turn into ...
24 (linux_process_target::async): ... this.
25 (linux_start_non_stop): Turn into ...
26 (linux_process_target::start_non_stop): ... this.
27 * linux-low.h (class linux_process_target): Update.
28 * lynx-low.cc (lynx_target_ops): Update.
29 * nto-low.cc (nto_target_ops): Update.
30 (nto_supports_non_stop): Remove; rely on the default behavior
32 * win32-low.cc (win32_target_ops): Update.
34 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
36 Turn process_stratum_target's qxfer_siginfo op into a method of
39 * target.h (struct process_stratum_target): Remove the target op.
40 (class process_target): Add the target op. Also add
41 'supports_qxfer_siginfo'.
42 * target.cc (process_target::qxfer_siginfo): Define.
43 (process_target::supports_qxfer_siginfo): Define.
45 Update the derived classes and callers below.
47 * server.cc (handle_qxfer_siginfo): Update.
48 (handle_query): Update.
49 * linux-low.cc (linux_target_ops): Update.
50 (linux_process_target::supports_qxfer_siginfo): Define.
51 (linux_xfer_siginfo): Turn into ...
52 (linux_process_target::qxfer_siginfo): ... this.
53 * linux-low.h (class linux_process_target): Update.
54 * lynx-low.cc (lynx_target_ops): Update.
55 * nto-low.cc (nto_target_ops): Update.
56 * win32-low.cc (win32_target_ops): Update.
58 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
60 Turn process_stratum_target's qxfer_osdata op into a method of
63 * target.h (struct process_stratum_target): Remove the target op.
64 (class process_target): Add the target op. Also add
65 'supports_qxfer_osdata'.
66 * target.cc (process_target::qxfer_osdata): Define.
67 (process_target::supports_qxfer_osdata): Define.
69 Update the derived classes and callers below.
71 * server.cc (handle_qxfer_osdata): Update.
72 (handle_query): Update.
73 * linux-low.cc (linux_target_ops): Update.
74 (linux_process_target::supports_qxfer_osdata): Define.
75 (linux_qxfer_osdata): Turn into ...
76 (linux_process_target::qxfer_osdata): ... this.
77 * linux-low.h (class linux_process_target): Update.
78 * lynx-low.cc (lynx_target_ops): Update.
79 * nto-low.cc (nto_target_ops): Update.
80 * win32-low.cc (win32_target_ops): Update.
82 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
84 Turn process_stratum_target's hostio_last_error op into a
85 method of process_target.
87 * target.h (struct process_stratum_target): Remove the target op.
88 (class process_target): Add the target op.
89 * target.cc: Add "hostio.h" to includes.
90 (process_target::hostio_last_error): Define.
92 Update the derived classes and callers below.
94 * hostio.cc (hostio_error): Update.
95 * linux-low.cc: Remove "hostio.h" from includes.
96 (linux_target_ops): Update.
97 * lynx-low.cc (lynx_target_ops): Update.
98 * nto-low.cc (nto_target_ops): Update.
99 * win32-low.h (class win32_process_target): Update.
100 * win32-low.cc (win32_target_ops): Update.
101 (wince_hostio_last_error): Turn into ...
102 (win32_process_target::hostio_last_error): ... this.
104 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
106 Turn process_stratum_target's get_tls_address op into a method of
109 * target.h (struct process_stratum_target): Remove the target op.
110 (class process_target): Add the target op. Also add
111 'supports_get_tls_address'.
112 * target.cc (process_target::get_tls_address): Define.
113 (process_target::supports_get_tls_address): Define.
115 Update the derived classes and callers below.
117 * server.cc (handle_query): Update.
118 * linux-low.cc (linux_target_ops): Update.
119 (linux_process_target::supports_get_tls_address): Define.
120 (linux_process_target::get_tls_address): Define.
121 * linux-low.h (class linux_process_target): Update.
122 * lynx-low.cc (lynx_target_ops): Update.
123 * nto-low.cc (nto_target_ops): Update.
124 * win32-low.cc (win32_target_ops): Update.
126 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
128 Turn process_stratum_target's read_offsets op into a method of
131 * target.h (struct process_stratum_target): Remove the target op.
132 (class process_target): Add the target op. Also add
133 'supports_read_offsets'.
134 * target.cc (process_target::read_offsets): Define.
135 (process_target::supports_read_offsets): Define.
137 Update the derived classes and callers below.
139 * server.cc (handle_query): Update.
140 * linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
141 (linux_target_ops): Update.
142 (linux_process_target::supports_read_offsets): Define.
143 (linux_read_offsets): Turn into ...
144 (linux_process_target::read_offsets): ... this.
145 * linux-low.h (class linux_process_target): Update.
146 * lynx-low.cc (lynx_target_ops): Update.
147 * nto-low.cc (nto_target_ops): Update.
148 * win32-low.cc (win32_target_ops): Update.
150 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
152 Turn process_stratum_target's stopped_by_watchpoint and
153 stopped_data_address ops into methods of process_target.
155 * target.h (struct process_stratum_target): Remove the target ops.
156 (class process_target): Add the target ops.
157 * target.cc (process_target::stopped_by_watchpoint): Define.
158 (process_target::stopped_data_address): Define.
160 Update the derived classes and callers below.
162 * remote-utils.cc (prepare_resume_reply): Update.
163 * linux-low.cc (linux_target_ops): Update.
164 (linux_stopped_by_watchpoint): Turn into ...
165 (linux_process_target::stopped_by_watchpoint): ... this.
166 (linux_stopped_data_address): Turn into ...
167 (linux_process_target::stopped_data_address): ... this.
168 * linux-low.h (class linux_process_target): Update.
169 * lynx-low.cc (lynx_target_ops): Update.
170 * nto-low.cc (nto_target_ops): Update.
171 (nto_stopped_by_watchpoint): Turn into ...
172 (nto_process_target::stopped_by_watchpoint): ... this.
173 (nto_stopped_data_address): Turn into ...
174 (nto_process_target::stopped_data_address): ... this.
175 * nto-low.h (class nto_process_target): Update.
176 * win32-low.cc (win32_target_ops): Update.
177 (win32_stopped_by_watchpoint): Turn into ...
178 (win32_process_target::stopped_by_watchpoint): ... this.
179 (win32_stopped_data_address): Turn into ...
180 (win32_process_target::stopped_data_address): ... this.
181 * win32-low.h (class win32_process_target): Update.
183 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
185 Turn process_stratum_target's supports_hardware_single_step op into
186 a method of process_target.
188 * target.h (struct process_stratum_target): Remove the target op.
189 (class process_target): Add the target op.
190 (target_supports_hardware_single_step): Update the macro.
191 (target_can_do_hardware_single_step): Remove declaration.
192 * target.cc (process_target::supports_hardware_single_step): Define.
193 (target_can_do_hardware_single_step): Remove.
195 Update the derived classes and callers below.
197 * linux-low.h (class linux_process_target): Update.
198 * linux-low.cc (linux_target_ops): Update.
199 (linux_supports_hardware_single_step): Turn into ...
200 (linux_process_target::supports_hardware_single_step): ... this.
201 * lynx-low.h (class lynx_process_target): Update.
202 * lynx-low.cc (lynx_target_ops): Update.
203 (lynx_process_target::supports_hardware_single_step): Define.
204 * nto-low.h (class nto_process_target): Update.
205 * nto-low.cc (nto_target_ops): Update.
206 (nto_process_target::supports_hardware_single_step): Define.
207 * win32-low.h (class win32_process_target): Update.
208 * win32-low.cc (win32_target_ops): Update.
209 (win32_process_target::supports_hardware_single_step): Define.
211 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
213 Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
214 ops into methods of process_target.
216 * target.h (struct process_stratum_target): Remove the target ops.
217 (class process_target): Add the target ops.
218 (target_stopped_by_hw_breakpoint): Update the macro.
219 (target_supports_stopped_by_hw_breakpoint): Update the macro.
220 * target.cc (process_target::stopped_by_hw_breakpoint): Define.
221 (process_target::supports_stopped_by_hw_breakpoint): Define.
223 Update the derived classes and callers below.
225 * linux-low.cc (linux_target_ops): Update.
226 (linux_stopped_by_hw_breakpoint): Turn into ...
227 (linux_process_target::stopped_by_hw_breakpoint): ... this.
228 (linux_supports_stopped_by_hw_breakpoint): Turn into ...
229 (linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
230 * linux-low.h (class linux_process_target): Update.
231 * lynx-low.cc (lynx_target_ops): Update.
232 * nto-low.cc (nto_target_ops): Update.
233 * win32-low.cc (win32_target_ops): Update.
235 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
237 Turn process_stratum_target's {supports_}stopped_by_sw_breakpoint
238 ops into methods of process_target.
240 * target.h (struct process_stratum_target): Remove the target ops.
241 (class process_target): Add the target ops.
242 (target_stopped_by_sw_breakpoint): Update the macro.
243 (target_supports_stopped_by_sw_breakpoint): Update the macro.
244 * target.cc (process_target::stopped_by_sw_breakpoint): Define.
245 (process_target::supports_stopped_by_sw_breakpoint): Define.
247 Update the derived classes and callers below.
249 * linux-low.cc (linux_target_ops): Update.
250 (linux_stopped_by_sw_breakpoint): Turn into ...
251 (linux_process_target::stopped_by_sw_breakpoint): ... this.
252 (linux_supports_stopped_by_sw_breakpoint): Turn into ...
253 (linux_process_target::supports_stopped_by_sw_breakpoint): ... this.
254 * linux-low.h (class linux_process_target): Update.
255 * lynx-low.cc (lynx_target_ops): Update.
256 * nto-low.cc (nto_target_ops): Update.
257 * win32-low.cc (win32_target_ops): Update.
259 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
261 Turn process_stratum_target's insert_point and remove_point ops
262 into methods of process_target.
264 * target.h (struct process_stratum_target): Remove the target ops.
265 (class process_target): Add the target ops.
266 * target.cc (process_target::insert_point): Define.
267 (process_target::remove_point): Define.
269 Update the derived classes and callers below.
271 * mem-break.cc (set_raw_breakpoint_at): Update.
272 (delete_raw_breakpoint): Update.
273 (uninsert_raw_breakpoint): Update.
274 (reinsert_raw_breakpoint): Update.
275 * linux-low.cc (linux_target_ops): Update.
276 (linux_insert_point): Turn into ...
277 (linux_process_target::insert_point): ... this.
278 (linux_remove_point): Turn into ...
279 (linux_process_target::remove_point): ... this.
280 * linux-low.h (class linux_process_target): Update.
281 * lynx-low.cc (lynx_target_ops): Update.
282 * nto-low.cc (nto_target_ops): Update.
283 (nto_insert_point): Turn into ...
284 (nto_process_target::insert_point): ... this.
285 (nto_remove_point): Turn into ...
286 (nto_process_target::remove_point): ... this.
287 * nto-low.h (class nto_process_target): Update.
288 * win32-low.cc (win32_target_ops): Update.
289 (win32_insert_point): Turn into ...
290 (win32_process_target::insert_point): ... this.
291 (win32_remove_point): Turn into ...
292 (win32_process_target::remove_point): ... this.
293 * win32-low.h (class win32_process_target): Update.
295 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
297 Turn process_stratum_target's supports_z_point_type op into a
298 method of process_target.
300 * target.h (struct process_stratum_target): Remove the target op.
301 (class process_target): Add the target op.
302 * target.cc (process_target::supports_z_point_type): Define.
304 Update the derived classes and callers below.
306 * mem-break.cc (z_type_supported): Update.
307 * linux-low.cc (linux_target_ops): Update.
308 (linux_supports_z_point_type): Turn into ...
309 (linux_process_target::supports_z_point_type): ... this.
310 * linux-low.h (class linux_process_target): Update.
311 * lynx-low.cc (lynx_target_ops): Update.
312 * nto-low.cc (nto_target_ops): Update.
313 (nto_supports_z_point_type): Turn into ...
314 (nto_process_target::supports_z_point_type): ... this.
315 * nto-low.h (class nto_process_target): Update.
316 * win32-low.cc (win32_target_ops): Update.
317 (win32_supports_z_point_type): Turn into ...
318 (win32_process_target::supports_z_point_type): ... this.
319 * win32-low.h (class win32_process_target): Update.
321 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
323 Turn process_stratum_target's read_auxv op into a method of
326 * target.h (class process_stratum_target): Remove the target op.
327 (struct process_target): Add the target op. Also add
328 'supports_read_auxv'.
329 * target.cc (process_target::read_auxv): Define.
330 (process_target::supports_read_auxv): Define.
332 Update the derived classes and callers below.
334 * server.cc (handle_qxfer_auxv): Update.
335 (handle_query): Update.
336 * linux-low.cc (linux_target_ops): Update.
337 (linux_process_target::supports_read_auxv): Define.
338 (linux_read_auxv): Turn into ...
339 (linux_process_target::read_auxv): ... this.
340 * linux-low.h (class linux_process_target): Update.
341 * lynx-low.cc (lynx_target_ops): Update.
342 * nto-low.cc (nto_target_ops): Update.
343 (nto_process_target::supports_read_auxv): Define.
344 (nto_read_auxv): Turn into ...
345 (nto_process_target::read_auxv): ... this.
346 * nto-low.h (class nto_process_target): Update.
347 * win32-low.cc (win32_target_ops): Update.
349 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
351 Turn process_stratum_target's request_interrupt op into a method of
354 * target.h (struct process_stratum_target): Remove the target op.
355 (class process_target): Add the target op.
357 Update the derived classes and callers below.
359 * remote-utils.cc (putpkt_binary_1): Update.
360 (input_interrupt): Update.
362 * server.cc (handle_v_requests): Update.
363 * linux-low.cc (linux_target_ops): Update.
364 (linux_request_interrupt): Turn into ...
365 (linux_process_target::request_interrupt): ... this.
366 * linux-low.h (class linux_process_target): Update.
367 * lynx-low.cc (lynx_target_ops): Update.
368 (lynx_request_interrupt): Turn into ...
369 (lynx_process_target::request_interrupt): ... this.
370 * lynx-low.h (class lynx_process_target): Update.
371 * nto-low.cc (nto_target_ops): Update.
372 (nto_request_interrupt): Turn into ...
373 (nto_process_target::request_interrupt): ... this.
374 * nto-low.h (class nto_process_target): Update.
375 * win32-low.cc (win32_target_ops): Update.
376 (win32_request_interrupt): Turn into ...
377 (win32_process_target::request_interrupt): ... this.
378 * win32-low.h (class win32_process_target): Update.
380 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
382 Turn process_stratum_target's look_up_symbols op into a method of
385 * target.h (struct process_stratum_target): Remove the target op.
386 (class process_target): Add the target op.
387 * target.cc (process_target::look_up_symbols): Define.
389 Update the derived classes and callers below.
391 * server.cc (handle_query): Update.
392 * linux-low.cc (linux_target_ops): Update.
393 (linux_look_up_symbols): Turn into ...
394 (linux_process_target::look_up_symbols): ... this.
395 * linux-low.h (class linux_process_target): Update.
396 * lynx-low.cc (lynx_target_ops): Update.
397 * nto-low.cc (nto_target_ops): Update.
398 * win32-low.cc (win32_target_ops): Update.
400 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
402 Turn process_stratum_target's read_memory and write_memory
403 ops into methods of process_target.
405 * target.h (struct process_stratum_target): Remove the target ops.
406 (class process_target): Add the target ops.
408 Update the derived classes and callers below.
410 * linux-aarch32-low.cc (arm_breakpoint_at): Update.
411 * linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
412 * linux-arm-low.cc (arm_sigreturn_next_pc): Update.
413 (arm_get_syscall_trapinfo): Update.
414 * linux-cris-low.cc (cris_breakpoint_at): Update.
415 * linux-crisv32-low.cc (cris_breakpoint_at): Update.
416 * linux-m32r-low.cc (m32r_breakpoint_at): Update.
417 * linux-mips-low.cc (mips_breakpoint_at): Update.
418 * linux-nios2-low.cc (nios2_breakpoint_at): Update.
419 * linux-ppc-low.cc (ppc_breakpoint_at): Update.
420 * linux-sh-low.cc (sh_breakpoint_at): Update.
421 * linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
422 (sparc_store_gregset_from_stack): Update.
423 (sparc_breakpoint_at): Update.
424 * linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
425 * linux-tile-low.cc (tile_breakpoint_at): Update.
426 * linux-x86-low.cc (x86_breakpoint_at): Update.
427 * linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
428 * mem-brea.cc (insert_memory_breakpoint): Update.
429 (validate_inserted_breakpoint): Update.
430 * target.cc (read_inferior_memory): Update.
431 (target_write_memory): Update.
432 * linux-low.cc (linux_target_ops): Update.
433 (linux_read_memory): Make a wrapper around the read_memory target
435 (linux_process_target::read_memory): Rename from linux_read_memory.
436 (linux_write_memory): Turn into ...
437 (linux_process_target::write_memory): ... this.
438 * linux-low.h (class linux_process_target): Update.
439 * lynx-low.cc (lynx_target_ops): Update.
440 (lynx_read_memory): Turn into ...
441 (lynx_process_target::read_memory): ... this.
442 (lynx_write_memory): Turn into ...
443 (lynx_process_target::write_memory): ... this.
444 * lynx-low.h (class lynx_process_target): Update.
445 * nto-low.cc (nto_target_ops): Update.
446 (nto_read_memory): Turn into ...
447 (nto_process_target::read_memory): ... this.
448 (nto_write_memory): Turn into ...
449 (nto_process_target::write_memory): ... this.
450 * nto-low.h (class nto_process_target): Update.
451 * win32-low.cc (win32_target_ops): Update.
452 (win32_read_inferior_memory): Turn into ...
453 (win32_process_target::read_memory): ... this.
454 (win32_write_inferior_memory): Turn into ...
455 (win32_process_target::write_memory): ... this.
456 * win32-low.h (class win32_process_target): Update.
458 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
460 Turn process_stratum_target's prepare_to_access_memory and
461 done_accessing_memory ops into methods of process_target.
463 * target.h (struct process_stratum_target): Remove the target ops.
464 (class process_target): Add the target ops.
465 * target.cc (process_target::prepare_to_access_memory): Define.
466 (process_target::done_accessing_memory): Define.
467 (prepare_to_access_memory): Update.
468 (done_accessing_memory): Update.
470 Update the derived classes and callers below.
472 * linux-low.cc (linux_target_ops): Update.
473 (linux_prepare_to_access_memory): Turn into ...
474 (linux_process_target::prepare_to_access_memory): ... this.
475 (linux_done_accessing_memory): Turn into ...
476 (linux_process_target::done_accessing_memory): ... this.
477 * linux-low.h (class linux_process_target): Update.
478 * lynx-low.cc (lynx_target_ops): Update.
479 * nto-low.cc (nto_target_ops): Update.
480 * win32-low.cc (win32_target_ops): Update.
482 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
484 Turn process_stratum_target's fetch_registers and store_registers
485 ops into methods of process_target.
487 * target.h (struct process_stratum_target): Remove the target ops.
488 (class process_target): Add the target ops.
489 (fetch_inferior_registers): Update the macro.
490 (store_inferior_registers): Update the macro.
492 Update the derived classes and callers below.
494 * linux-low.cc (linux_target_ops): Update.
495 (linux_fetch_registers): Turn into ...
496 (linux_process_target::fetch_registers): ... this.
497 (linux_store_registers): Turn into ...
498 (linux_process_target::store_registers): ... this.
499 * linux-low.h (class linux_process_target): Update.
500 * lynx-low.cc (lynx_target_ops): Update.
501 (lynx_fetch_registers): Turn into ...
502 (lynx_process_target::fetch_registers): ... this.
503 (lynx_store_registers): Turn into ...
504 (lynx_process_target::store_registers): ... this.
505 * lynx-low.h (class lynx_process_target): Update.
506 * nto-low.cc (nto_target_ops): Update.
507 (nto_fetch_registers): Turn into ...
508 (nto_process_target::fetch_registers): ... this.
509 (nto_store_registers): Turn into ...
510 (nto_process_target::store_registers): ... this.
511 * nto-low.h (class nto_process_target): Update.
512 * win32-low.cc (win32_target_ops): Update.
513 (win32_fetch_inferior_registers): Turn into ...
514 (win32_process_target::fetch_registers): ... this.
515 (win32_store_inferior_registers): Turn into ...
516 (win32_process_target::store_registers): ... this.
517 * win32-low.h (class win32_process_target): Update.
519 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
521 Turn process_stratum_target's wait op into a method of
524 * target.h (struct process_stratum_target): Remove the target op.
525 (class process_target): Add the target op.
527 Update the derived classes and callers below.
529 * target.cc (target_wait): Update.
530 * linux-low.cc (linux_target_ops): Update.
531 (linux_wait): Turn into ...
532 (linux_process_target::wait): ... this.
533 * linux-low.h (class linux_process_target): Update.
534 * lynx-low.cc (lynx_target_ops): Update.
535 (lynx_wait): Turn into ...
536 (lynx_process_target::wait): ... this.
537 * lynx-low.h (class lynx_process_target): Update.
538 * nto-low.cc (nto_target_ops): Update.
539 (nto_wait): Turn into ...
540 (nto_process_target::wait): ... this.
541 * nto-low.h (class nto_process_target): Update.
542 * win32-low.cc (win32_target_ops): Update.
543 (win32_wait): Turn into ...
544 (win32_process_target::wait): ... this.
545 (do_initial_child_stuff): Update.
546 * win32-low.h (class win32_process_target): Update.
548 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
550 Turn process_stratum_target's resume op into a method of
553 * target.h (struct process_stratum_target): Remove the target op.
554 (class process_target): Add the target op.
556 Update the derived classes and callers below.
558 * server.cc (resume): Update.
559 * target.cc (target_stop_and_wait): Update.
560 (target_continue_no_signal): Update.
561 (target_continue): Update.
562 * linux-low.cc (linux_target_ops): Update.
563 (linux_resume): Turn into ...
564 (linux_process_target::resume): ... this.
565 * linux-low.h (class linux_process_target): Update.
566 * lynx-low.cc (lynx_target_ops): Update.
567 (lynx_resume): Turn into ...
568 (lynx_process_target::resume): ... this.
569 * lynx-low.h (class lynx_process_target): Update.
570 * nto-low.cc (nto_target_ops): Update.
571 (nto_resume): Turn into ...
572 (nto_process_target::resume): ... this.
573 * nto-low.h (class nto_process_target): Update.
574 * win32-low.cc (win32_target_ops): Update.
575 (win32_resume): Turn into ...
576 (win32_process_target::resume): ... this.
577 (win32_process_target::detach): Update.
578 (do_initial_child_stuff): Update.
579 * win32-low.h (class win32_process_target): Update.
581 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
583 Turn process_stratum_target's thread_alive op into a method of
586 * target.h (struct process_stratum_target): Remove the target op.
587 (class process_target): Add the target op.
588 (mythread_alive): Update the macro.
590 Update the derived classes and callers below.
592 * linux-low.cc (linux_target_ops): Update.
593 (linux_thread_alive): Turn into ...
594 (linux_process_target::thread_alive): ... this.
595 (wait_for_sigstop): Update.
596 * linux-low.h (class linux_process_target): Update.
597 * lynx-low.cc (lynx_target_ops): Update.
598 (lynx_thread_alive): Turn into ...
599 (lynx_process_target::thread_alive): ... this.
600 * lynx-low.h (class lynx_process_target): Update.
601 * nto-low.cc (nto_target_ops): Update.
602 (nto_thread_alive): Turn into ...
603 (nto_process_target::thread_alive): ... this.
604 * nto-low.h (class nto_process_target): Update.
605 * win32-low.cc (win32_target_ops): Update.
606 (win32_thread_alive): Turn into ...
607 (win32_process_target::thread_alive): ... this.
608 * win32-low.h (class win32_process_target): Update.
610 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
612 Turn process_stratum_target's join op into a method of
615 * target.h (struct process_stratum_target): Remove the target op.
616 (class process_target): Add the target op.
617 (join_inferior): Update the macro.
619 Update the derived classes and callers below.
621 * linux-low.cc (linux_target_ops): Update.
622 (linux_join): Turn into ...
623 (linux_process_target::join): ... this.
624 * linux-low.h (class linux_process_target): Update.
625 * lynx-low.cc (lynx_target_ops): Update.
626 (lynx_join): Turn into ...
627 (lynx_process_target::join): ... this.
628 * lynx-low.h (class lynx_process_target): Update.
629 * nto-low.cc (nto_target_ops): Update.
630 (nto_process_target::join): Define.
631 * nto-low.h (class nto_process_target): Update.
632 * win32-low.cc (win32_target_ops): Update.
633 (win32_join): Turn into ...
634 (win32_process_target::join): ... this.
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 mourn 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 * target.cc (target_mourn_inferior): Update.
648 * linux-low.cc (linux_target_ops): Update.
649 (linux_mourn): Turn into ...
650 (linux_process_target::mourn): ... this.
651 (handle_extended_wait): Update.
652 (linux_process_target::kill): Update.
653 (linux_process_target::detach): Update.
654 * linux-low.h (class linux_process_target): Update.
655 * lynx-low.cc (lynx_target_ops): Update.
656 (lynx_mourn): Turn into ...
657 (lynx_process_target::mourn): ... this.
658 * lynx-low.h (class lynx_process_target): Update.
659 * nto-low.cc (nto_target_ops): Update.
660 (nto_mourn): Turn into ...
661 (nto_process_target::mourn): ... this.
662 * nto-low.h (class nto_process_target): Update.
663 * win32-low.cc (win32_target_ops): Update.
664 (win32_mourn): Turn into ...
665 (win32_process_target::mourn): ... this.
666 * win32-low.h (class win32_process_target): Update.
668 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
670 Turn process_stratum_target's detach op into a method of
673 * target.h (struct process_stratum_target): Remove the target op.
674 (class process_target): Add the target op.
675 (detach_inferior): Update the macro.
677 Update the derived classes and callers below.
679 * linux-low.cc (linux_target_ops): Update.
680 (linux_detach): Turn into ...
681 (linux_process_target::detach): ... this.
682 * linux-low.h (class linux_process_target): Update.
683 * lynx-low.cc (lynx_target_ops): Update.
684 (lynx_detach): Turn into ...
685 (lynx_process_target::detach): ... this.
686 * lynx-low.h (class lynx_process_target): Update.
687 * nto-low.cc (nto_target_ops): Update.
688 (nto_detach): Turn into ...
689 (nto_process_target::detach): ... this.
690 * nto-low.h (class nto_process_target): Update.
691 * win32-low.cc (win32_target_ops): Update.
692 (win32_detach): Turn into ...
693 (win32_process_target::detach): ... this.
694 * win32-low.h (class win32_process_target): Update.
696 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
698 Turn process_stratum_target's kill op into a method of
701 * target.h (struct process_stratum_target): Remove the target op.
702 (class process_target): Add the target op.
704 Update the derived classes and callers below.
706 * target.cc (kill_inferior): Update.
707 * linux-low.cc (linux_target_ops): Update.
708 (linux_kill): Turn into ...
709 (linux_process_target::kill): ... this.
710 * linux-low.h (class linux_process_target): Update.
711 * lynx-low.cc (lynx_target_ops): Update.
712 (lynx_kill): Turn into ...
713 (lynx_process_target::kill): ... this.
714 * lynx-low.h (class lynx_process_target): Update.
715 * nto-low.cc (nto_target_ops): Update.
716 (nto_kill): Turn into ...
717 (nto_process_target::kill): ... this.
718 * nto-low.h (class nto_process_target): Update.
719 * win32-low.cc (win32_target_ops): Update.
720 (win32_kill): Turn into ...
721 (win32_process_target::kill): ... this.
722 * win32-low.h (class win32_process_target): Update.
724 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
726 Turn process_stratum_target's attach op into a method of
729 * target.h (struct process_stratum_target): Remove the target op.
730 (class process_target): Add the target op.
731 (myattach): Update the macro.
733 Update the derived classes and callers below.
735 * linux-low.cc (linux_target_ops): Update.
736 (linux_attach): Turn into ...
737 (linux_process_target::attach): ... this.
738 * linux-low.h (class linux_process_target): Update.
739 * lynx-low.cc (lynx_target_ops): Update.
740 (lynx_attach): Turn into ...
741 (lynx_process_target::attach): ... this.
742 * lynx-low.h (class lynx_process_target): Update.
743 * nto-low.cc (nto_target_ops): Update.
744 (nto_attach): Turn into ...
745 (nto_process_target::attach): ... this.
746 * nto-low.h (class nto_process_target): Update.
747 * win32-low.cc (win32_target_ops): Update.
748 (win32_attach): Turn into ...
749 (win32_process_target::attach): ... this.
750 * win32-low.h (class win32_process_target): Update.
752 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
754 Turn process_stratum_target's post_create_inferior op into a method
757 * target.h (struct process_stratum_target): Remove the target op.
758 (class process_target): Add the target op.
759 (target_post_create_inferior): Update the macro.
760 * target.cc (process_target::post_create_inferior): Define.
762 Update the derived classes and callers below.
764 * linux-low.cc (linux_target_ops): Update.
765 (linux_post_create_inferior): Turn into ...
766 (linux_process_target::post_create_inferior): ... this.
767 * linux-low.h (class linux_process_target): Update.
768 * lynx-low.cc (lynx_target_ops): Update.
769 * nto-low.cc (nto_target_ops): Update.
770 * win32-low.cc (win32_target_ops): Update.
772 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
774 Turn process_stratum_target's create_inferior op into a method of
777 * target.h (struct process_stratum_target): Remove the target op.
778 (class process_target): Add the target op.
779 (create_inferior): Rename the macro to ...
780 (target_create_inferior): ... this.
782 Update the derived classes and callers below.
784 * server.cc (handle_v_run): Update.
785 (captured_main): Update.
786 (process_serial_event): Update.
787 * linux-low.cc (linux_target_ops): Update.
788 (linux_create_inferior): Turn into ...
789 (linux_process_target::create_inferior): ... this.
790 * linux-low.h (class linux_process_target): Update.
791 * lynx-low.cc (lynx_target_ops): Update.
792 (lynx_create_inferior): Turn into ...
793 (lynx_process_target::create_inferior): ... this.
794 * lynx-low.h (class lynx_process_target): Update.
795 * nto-low.cc (nto_target_ops): Update.
796 (nto_create_inferior): Turn into ...
797 (nto_process_target::create_inferior): ... this.
798 * nto-low.h (class nto_process_target): Update.
799 * win32-low.cc (win32_target_ops): Update.
800 (win32_create_inferior): Turn into ...
801 (win32_process_target::create_inferior): ... this.
802 * win32-low.h (class win32_process_target): Update.
804 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
806 * target.h (class process_target): New class definition.
807 (struct process_stratum_target) <pt>: New field with type
809 * linux-low.h (class linux_process_target): Define as a derived
810 class of 'process_target'.
811 * linux-low.cc (linux_target_ops): Add a linux_process_target*
813 * lynx-low.h (class lynx_process_target): Define as a derived
814 class of 'process_target'.
815 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
817 * nto-low.h (class nto_process_target): Define as a derived
818 class of 'process_target'.
819 * nto-low.cc (nto_target_ops): Add an nto_process_target*
821 * win32-low.h (class win32_process_target): Define as a derived
822 class of 'process_target'.
823 * win32-low.cc (win32_target_ops): Add a win32_process_target*
826 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
828 * configure: Regenerate.
830 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
831 Andrew Burgess <andrew.burgess@embecosm.com>
833 * linux-riscv-low.cc: New file.
834 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
835 and nat/riscv-linux-tdesc.c.
836 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
837 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
840 2020-02-14 Tom Tromey <tom@tromey.com>
842 * acinclude.m4: Don't include acx_configure_dir.m4.
843 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
844 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
845 (all, install-only, uninstall, clean-info, clean)
846 (maintainer-clean): Don't recurse.
847 (subdir_do, all-lib): Remove.
848 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
850 (generated_files): Update.
851 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
852 * configure: Rebuild.
853 * configure.ac: Don't configure gnulib or libiberty.
856 2020-02-14 Eli Zaretskii <eliz@gnu.org>
858 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
859 preparing the command line for CreateProcess.
860 (win32_create_inferior): Reflect the program name in debugging
861 output that shows the process and its command line.
863 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
865 * Makefile.in: Rename source files from .c to .cc.
866 * %.c: Rename to %.cc.
867 * configure.ac: Rename server.c to server.cc.
868 * configure: Re-generate.
870 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
872 * Makefile.in: Rename gdbsupport source files from .c to .cc.
874 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
876 * win32-low.c (win32_create_inferior): Set signal_pid.
878 2020-02-12 Maciej W. Rozycki <macro@wdc.com>
879 Pedro Alves <palves@redhat.com>
881 Skip building gdbserver in a cross-configuration.
882 * configure.srv: Set $gdbserver_host depending on whether $target
883 is $host. Use $gdbserver_host instead of $host.
885 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
887 * configure: Re-generate.
889 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
891 * configure: Re-generate.
893 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
895 * acinclude.m4: Update warning.m4 path.
897 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
899 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
900 (handle_exception): Set siginfo_er.
901 (win32_xfer_siginfo): New function.
903 2020-02-07 Tom Tromey <tom@tromey.com>
904 Pedro Alves <palves@redhat.com>
906 * README: Update build documentation.
907 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
909 * configure.ac: Update paths.
910 * configure: Rebuild.
911 * acinclude.m4: Update paths.
912 * Makefile.in: Update include paths.
913 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
914 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
915 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
916 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
917 (%-generated.c): Update paths.
918 * Move entire directory from ../gdb/gdbserver.
920 2020-01-29 Maciej W. Rozycki <macro@wdc.com>
922 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
924 2020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
926 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
927 assignment instead of srv_linux_obj.
929 2020-01-28 Hannes Domani <ssbssa@yahoo.de>
931 * server.c (handle_qxfer_libraries): Write segment-address with
934 2020-01-24 Hannes Domani <ssbssa@yahoo.de>
936 * Makefile.in (install-strip): New target.
937 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
938 * aclocal.m4: Regenerate.
939 * configure: Regenerate.
940 * configure.ac: Add AM_PROG_INSTALL_STRIP.
942 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
944 * Makefile.in (SFILES): Adjust paths to point to real files.
945 (OBS): Move waitstatus.o to target/waitstatus.o.
946 (TAGS): Transform paths appropriately.
948 (nat/%.o): ... this pattern rule.
950 (target/%.o): ... this pattern rule.
951 * configure.srv: Adjust paths throughout to include nat/ prefix
952 with the revant files.
953 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
954 * configure: Regenerate.
956 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
958 * Makefile.in (TAGS): Remove config files from the recipe.
960 2020-01-14 Tom Tromey <tom@tromey.com>
962 * configure: Rebuild.
963 * configure.ac: Remove any checks that were added to common.m4.
964 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
967 2020-01-14 Tom Tromey <tom@tromey.com>
969 * server.h: Include config.h.
970 * gdbreplay.c: Include config.h.
971 * configure: Rebuild.
972 * configure.ac: Don't source common.host.
973 * acinclude.m4: Update path.
974 * Makefile.in (INCSUPPORT): New variable.
975 (INCLUDE_CFLAGS): Add INCSUPPORT.
976 (SFILES): Update paths.
977 (version-generated.c): Update path to create-version.sh.
978 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
980 2020-01-14 Tom Tromey <tom@tromey.com>
982 * configure.ac (LIBS): Use WIN32APILIBS.
983 (USE_WIN32API): Don't define.
984 * configure: Rebuild.
986 2020-01-14 Tom Tromey <tom@tromey.com>
988 * configure: Rebuild.
990 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
992 * Makefile.in (%-generated.c): Remove rule for files from
995 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
997 * configure: Re-generate.
999 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1001 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
1003 * tracepoint.c (stop_tracing, flush_trace_buffer,
1004 about_to_request_buffer_space, get_trace_state_variable_value,
1005 set_trace_state_variable_value, gdb_collect): Add declaration.
1007 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1009 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
1010 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
1011 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
1012 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
1013 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
1016 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1018 * inferiors.c: Include gdbsupport/common-inferior.h.
1020 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1022 * hostio-errno.c: Include hostio.h.
1024 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
1026 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
1029 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
1031 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
1032 * linux-arm-tdesc.h: Include arch/arm.h.
1034 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
1036 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
1038 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
1040 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
1041 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
1043 2020-01-10 Pedro Alves <palves@redhat.com>
1045 * fork-child.c (post_fork_inferior): Pass target down to
1047 * inferiors.c (switch_to_thread): Add process_stratum_target
1049 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
1050 * nto-low.c (nto_target_ops): Now a process_stratum_target.
1051 * linux-low.c (linux_target_ops): Now a process_stratum_target.
1052 * remote-utils.c (prepare_resume_reply): Pass the target to
1054 * target.c (the_target): Now a process_stratum_target.
1055 (done_accessing_memory): Pass the target to switch_to_thread.
1056 (set_target_ops): Ajust to use process_stratum_target.
1057 * target.h (struct target_ops): Rename to ...
1058 (struct process_stratum_target): ... this.
1059 (the_target, set_target_ops): Adjust.
1060 (prepare_to_access_memory): Adjust comment.
1061 * win32-low.c (child_xfer_memory): Adjust to use
1062 process_stratum_target.
1063 (win32_target_ops): Now a process_stratum_target.
1065 2020-01-06 Eli Zaretskii <eliz@gnu.org>
1066 Pedro Alves <palves@redhat.com>
1068 * win32-low.c (get_child_debug_event): Extract the fatal exception
1069 from the exit status and convert to the equivalent Posix signal
1071 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
1072 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
1074 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
1076 * Makefile.in: Use INSTALL_PROGRAM_ENV.
1078 2020-01-01 Joel Brobecker <brobecker@adacore.com>
1080 * server.c (gdbserver_version): Change copyright year to 2020.
1081 * gdbreplay.c (gdbreplay_version): Likewise.
1083 2019-12-19 Christian Biesinger <cbiesinger@google.com>
1085 * configure: Regenerate.
1086 * configure.ac: Quote variable arguments of test.
1088 2019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
1090 * Makefile.in: Fix build with GNU Make 3.81
1092 2019-12-16 Tom Tromey <tromey@adacore.com>
1094 * server.c (get_exec_file): Constify result.
1096 2019-12-10 Christian Biesinger <cbiesinger@google.com>
1098 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
1099 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
1100 * config.in: Regenerate.
1101 * configure: Regenerate.
1102 * configure.ac: Don't check for strerror.
1103 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
1104 Call safe_strerror instead of strerror.
1105 * server.h (strerror): Remove this now-unnecessary declaration.
1106 * tracepoint.c (init_named_socket): Call safe_strerror instead of
1108 (gdb_agent_helper_thread): Likewise.
1109 * utils.c (perror_with_name): Likewise.
1111 2019-11-26 Tom Tromey <tom@tromey.com>
1113 * configure, config.in: Rebuild.
1115 2019-11-26 Tom Tromey <tom@tromey.com>
1117 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
1118 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
1120 * configure, config.in: Rebuild.
1122 2019-11-26 Tom Tromey <tom@tromey.com>
1124 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
1125 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
1126 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
1127 * acinclude.m4: Include ax_pthread.m4.
1128 * config.in, configure: Rebuild.
1130 2019-11-26 Christian Biesinger <cbiesinger@google.com>
1132 * debug.c (debug_set_output): Call safe_strerror instead of
1134 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
1135 (linux_kill_one_lwp): Likewise.
1136 (linux_detach_one_lwp): Likewise.
1137 (linux_wait_for_event_filtered): Likewise.
1138 (store_register): Likewise.
1139 * lynx-low.c (lynx_attach): Likewise.
1140 * mem-break.c (insert_memory_breakpoint): Likewise.
1141 (remove_memory_breakpoint): Likewise.
1142 (delete_fast_tracepoint_jump): Likewise.
1143 (set_fast_tracepoint_jump): Likewise.
1144 (uninsert_fast_tracepoint_jumps_at): Likewise.
1145 (reinsert_fast_tracepoint_jumps_at): Likewise.
1146 * nto-low.c (nto_xfer_memory): Likewise.
1147 (nto_resume): Likewise.
1149 2019-11-20 Luis Machado <luis.machado@linaro.org>
1151 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
1152 instead of register count.
1153 * tdesc.c (tdesc_contains_feature): New function.
1154 * tdesc.h (tdesc_contains_feature): New prototype.
1156 2019-11-15 Christian Biesinger <cbiesinger@google.com>
1158 * Makefile.in: Add safe-strerror.c.
1159 * configure: Regenerate.
1160 * configure.ac: Don't source common.host.
1162 2019-11-15 Christian Biesinger <cbiesinger@google.com>
1164 * config.in: Regenerate.
1165 * configure: Regenerate.
1167 2019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
1169 * ax.c (ax_printf): Handle size_t_arg.
1171 2019-11-06 Christian Biesinger <cbiesinger@google.com>
1173 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
1174 * mi/mi-main.c (output_cores): Likewise.
1175 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
1176 (linux_xfer_osdata_modules): Likewise.
1177 * remote.c (register_remote_support_xml): Likewise.
1178 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
1179 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
1181 2019-11-01 Christian Biesinger <cbiesinger@google.com>
1183 * configure: Regenerate.
1184 * configure.ac: Remove check for strerror_r.
1186 2019-10-31 Christian Biesinger <cbiesinger@google.com>
1188 * config.in: Regenerate.
1189 * configure: Regenerate.
1190 * configure.ac: Also check for strerror_r.
1192 2019-10-31 Christian Biesinger <cbiesinger@google.com>
1194 * ax.h (debug_agent): Remove duplicate declaration.
1196 2019-10-26 Tom de Vries <tdevries@suse.de>
1198 * linux-aarch64-low.c: Fix typos in comments.
1199 * linux-arm-low.c: Same.
1200 * linux-low.c: Same.
1201 * linux-ppc-low.c: Same.
1202 * proc-service.c: Same.
1205 * tracepoint.c: Same.
1206 * win32-low.c: Same.
1208 2019-10-25 Tom Tromey <tromey@adacore.com>
1210 * utils.c (xstrdup): Remove.
1212 2019-10-23 Tom Tromey <tom@tromey.com>
1214 * configure, config.in: Rebuild.
1216 2019-10-23 Tom Tromey <tom@tromey.com>
1218 * configure: Rebuild.
1219 * acinclude.m4: Use m4_include, not sinclude.
1221 2019-10-17 Tom Tromey <tromey@adacore.com>
1223 * configure: Rebuild.
1224 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
1225 in AC_CONFIG_FILES invocation.
1226 * Makefile.in (stamp-h, Makefile): Use new-style config.status
1229 2019-10-16 Christian Biesinger <cbiesinger@google.com>
1231 * server.c: Include xml-builtin.h.
1232 (get_xml_features): Don't declare xml_builtins here.
1234 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
1236 * Makefile.in: Remove references to vec-ipa.o.
1238 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
1240 * Makefile.in: Remove references to vec.c.
1242 2019-10-02 Christian Biesinger <cbiesinger@google.com>
1244 * server.c (server_waiting): Change to bool.
1245 (extended_protocol): Likewise.
1246 (response_needed): Likewise.
1247 (exit_requested): Likewise.
1248 (run_once): Likewise.
1249 (report_no_resumed): Likewise.
1250 (non_stop): Likewise.
1251 (disable_packet_vCont): Likewise.
1252 (disable_packet_Tthread): Likewise.
1253 (disable_packet_qC): Likewise.
1254 (disable_packet_qfThreadInfo): Likewise.
1255 (handle_general_set): Update.
1256 (handle_detach): Update.
1257 (handle_monitor_command): Update.
1258 (handle_query): Update.
1259 (captured_main): Update.
1260 (process_serial_event): Update.
1261 * server.h (server_waiting): Change to bool.
1262 (disable_packet_vCont): Likewise.
1263 (disable_packet_Tthread): Likewise.
1264 (disable_packet_qC): Likewise.
1265 (disable_packet_qfThreadInfo): Likewise.
1266 (run_once): Likewise.
1267 (non_stop): Likewise.
1268 * target.c (target_stop_and_wait): Update.
1270 2019-10-02 Tom Tromey <tromey@adacore.com>
1272 * Makefile.in (SFILES): Add common-inferior.c.
1273 (OBS): Add common-inferior.o.
1274 * server.c (startup_with_shell): Don't define.
1276 2019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
1278 * linux-low.c (linux_low_read_btrace): Update for change to
1281 2019-09-20 Christian Biesinger <cbiesinger@google.com>
1283 * debug.c (debug_threads): Remove comment in favor of the header.
1284 * debug.h (using_threads): Add declaration.
1285 (debug_threads): Add comment.
1286 * linux-aarch64-low.c: Include debug.h and remove declaration of
1288 * nto-low.c: Likewise.
1289 * remote-utils.c: Likewise.
1290 * thread-db.c: Likewise.
1292 2019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
1294 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
1295 and powerpc-cell64l-ipa.o.
1296 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
1297 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
1298 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
1301 * spu-low.c: Remove file.
1303 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
1304 (parse_spufs_run): Remove.
1305 (ppc_get_pc): Remove Cell/B.E. support.
1306 (ppc_set_pc): Likewise.
1307 (ppc_breakpoint_at): Likewise.
1308 (ppc_arch_setup): Likewise.
1309 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
1310 tdesc_powerpc_cell32l.
1311 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
1312 or init_registers_powerpc_cell32l.
1313 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
1314 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
1315 or init_registers_powerpc_cell32l.
1316 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
1317 (init_registers_powerpc_cell32l): Remove prototype.
1318 (init_registers_powerpc_cell64l): Likewise.
1320 * target.h (struct target_ops): Remove qxfer_spu member.
1321 * server.c (handle_qxfer_spu): Remove.
1322 (qxfer_packets): Remove entry for "spu".
1323 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
1324 * linux-low.c (SPUFS_MAGIC): Remove.
1325 (spu_enumerate_spu_ids): Remove.
1326 (linux_qxfer_spu): Remove.
1327 (linux_target_ops): Remove qxfer_spu member.
1328 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
1329 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
1330 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
1332 2019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
1334 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
1335 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
1336 * config.in: Regenerate.
1337 * configure: Regenerate.
1339 2019-08-15 Tom Tromey <tromey@adacore.com>
1341 * target.c (target_write_memory): Use gdb::byte_vector.
1343 2019-08-15 Tom Tromey <tromey@adacore.com>
1345 * tracepoint.c (write_inferior_data_pointer)
1346 (write_inferior_integer, write_inferior_int8)
1347 (write_inferior_uinteger, m_tracepoint_action_download)
1348 (r_tracepoint_action_download, x_tracepoint_action_download)
1349 (l_tracepoint_action_download, clear_inferior_trace_buffer)
1350 (download_agent_expr, download_tracepoint_1)
1351 (download_trace_state_variables, upload_fast_traceframes): Update.
1352 * server.c (gdb_write_memory): Update.
1353 * remote-utils.c (relocate_instruction): Update.
1354 * proc-service.c (ps_pdwrite): Update.
1355 * mem-break.c (remove_memory_breakpoint)
1356 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
1357 (uninsert_fast_tracepoint_jumps_at)
1358 (reinsert_fast_tracepoint_jumps_at): Update.
1359 * linux-x86-low.c (append_insns)
1360 (i386_install_fast_tracepoint_jump_pad)
1361 (amd64_write_goto_address, i386_write_goto_address): Update.
1362 * linux-s390-low.c (append_insns, s390_write_goto_address):
1364 * linux-ppc-low.c (ppc_relocate_instruction)
1365 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
1366 (ppc_write_goto_address): Update.
1367 * linux-aarch64-low.c (append_insns): Update.
1368 * target.h (struct target_ops): Update.
1369 (write_inferior_memory): Don't declare.
1370 * target.c (target_write_memory): Rename from
1371 write_inferior_memory. Remove old target_write_memory.
1373 2019-08-15 Tom Tromey <tromey@adacore.com>
1375 * target.c (write_inferior_memory): Use std::vector.
1377 2019-08-06 Frank Ch. Eigler <fche@redhat.com>
1380 * configure.ac: Drop enable-libmcheck support.
1381 * configure, config.in: Rebuild.
1382 * acinclude.m4: Don't include it.
1384 2019-07-19 Alan Hayward <alan.hayward@arm.com>
1386 * configure.srv: Remove Arm xml files.
1388 2019-07-19 Alan Hayward <alan.hayward@arm.com>
1390 * configure.srv: Add new files. Remove xml generated files.
1391 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
1393 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
1394 * linux-aarch32-tdesc.c: New file.
1395 * linux-aarch32-tdesc.h: New file.
1396 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
1397 * linux-arm-low.c (init_registers_arm, tdesc_arm)
1398 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
1399 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
1400 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
1401 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
1402 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
1403 (arm_read_description): Call arm_linux_read_description.
1404 (initialize_low_arch): Don't init registers.
1405 * linux-arm-tdesc.c: New file.
1406 * linux-arm-tdesc.h: New file.
1408 2019-07-10 Alan Hayward <alan.hayward@arm.com>
1410 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
1411 Move counter inside for.
1412 (arm_read_description): Check ptrace earlier.
1413 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
1415 2019-07-09 Tom Tromey <tom@tromey.com>
1417 * configure: Rebuild.
1418 * configure.ac: Change common to gdbsupport.
1419 * acinclude.m4: Change common to gdbsupport.
1420 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
1421 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
1422 common to gdbsupport.
1423 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
1424 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
1425 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
1426 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
1427 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
1428 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
1429 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
1430 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
1431 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
1432 common to gdbsupport.
1434 2019-07-04 Alan Hayward <alan.hayward@arm.com>
1436 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
1438 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
1440 2019-07-04 Alan Hayward <alan.hayward@arm.com>
1442 * configure.srv: Remove legacy xml.
1443 * linux-aarch64-low.c (initialize_low_arch): Remove
1444 initialize_low_tdesc call.
1445 * linux-aarch64-tdesc-selftest.c: Remove file.
1446 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
1447 * linux-x86-low.c (initialize_low_arch): Remove
1448 initialize_low_tdesc call.
1449 * linux-x86-tdesc-selftest.c: Remove file.
1450 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
1452 2019-06-20 Tom de Vries <tdevries@suse.de>
1454 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
1455 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
1457 2019-06-19 Tom de Vries <tdevries@suse.de>
1459 * debug.h (debug_write): Change return type to ssize_t.
1460 * debug.c (debug_write): Same.
1462 2019-06-14 Tom Tromey <tom@tromey.com>
1464 * configure.ac: Use new path to gnulib.
1465 * configure: Rebuild.
1466 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
1469 2019-06-11 Tom Tromey <tom@tromey.com>
1471 * Makefile.in (SFILES): Add alloc.c.
1473 (IPA_OBJS): Add alloc-ipa.o.
1474 (alloc-ipa.o): New target.
1475 (%.o: ../%.c): New pattern rule.
1477 2019-06-10 Tom Tromey <tromey@adacore.com>
1479 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
1480 end warning with a newline.
1481 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
1483 * thread-db.c (attach_thread): Don't end warning with a newline.
1484 (thread_db_notice_clone): Likewise.
1485 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
1487 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
1488 end warning with a newline.
1490 2019-06-04 Pedro Alves <palves@redhat.com>
1492 * server.c (captured_main): Use make_unique_xstrdup.
1494 2019-06-02 Tom Tromey <tom@tromey.com>
1496 * gdbreplay.c (fromhex): Remove.
1497 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
1499 2019-05-29 Tom Tromey <tromey@adacore.com>
1501 * configure: Rebuild.
1503 2019-05-06 Kevin Buettner <kevinb@redhat.com>
1505 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
1506 sign extension code on 32-bit builds.
1508 2019-05-03 Eli Zaretskii <eliz@gnu.org>
1511 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
1513 2019-04-19 Tom Tromey <tom@tromey.com>
1515 * server.c (struct vstop_notif): Derive from notif_event.
1517 (queue_stop_reply): Update.
1518 (remove_all_on_match_ptid): Change type. Rewrite.
1519 (discard_queued_stop_replies): Rewrite.
1520 (in_queued_stop_replies_ptid): Change type.
1521 (in_queued_stop_replies): Rewrite.
1522 (notif_stop): Update.
1523 (queue_stop_reply_callback): Update.
1524 (captured_main): Don't call initialize_notif.
1525 (push_stop_notification): Update.
1526 * notif.c (notif_write_event, handle_notif_ack)
1527 (notif_event_enque, notif_push): Update.
1528 (notif_event_xfree, initialize_notif): Remove.
1529 * notif.h (struct notif_event): Include <list>, not
1531 (struct notif_server) <queue>: Now a std::list.
1532 (notif_event_p): Remove typedef.
1533 (initialize_notif): Don't declare.
1534 (struct notif_event): Add virtual destructor.
1536 2019-04-17 Alan Hayward <alan.hayward@arm.com>
1538 * ax.c (ax_vdebug): Call debug_printf.
1539 * debug.c (debug_write): New function.
1540 * debug.h (debug_write): New declaration.
1541 * linux-low.c (sigchld_handler): Call debug_write.
1543 2019-04-17 Alan Hayward <alan.hayward@arm.com>
1545 * debug.c (debug_set_output): New function.
1546 (debug_vprintf): Send output to debug_file.
1547 (debug_flush): Likewise.
1548 * debug.h (debug_set_output): New declaration.
1549 * server.c (handle_monitor_command): Add debug-file option.
1550 (captured_main): Likewise.
1552 2019-04-17 Alan Hayward <alan.hayward@arm.com>
1554 * debug.c (remote_debug): Add definition.
1555 * debug.h (remote_debug): Add declaration.
1556 * hostio.c (remote_debug): Remove declaration.
1557 * remote-utils.c (struct ui_file): Likewise.
1558 (remote_debug): Likewise.
1559 * remote-utils.h (remote_debug): Likewise,
1560 * server.c (remote_debug): Remove definition.
1562 2019-04-10 Kevin Buettner <kevinb@redhat.com>
1564 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
1565 when using a 64-bit gdbserver.
1567 2019-04-09 Tom Tromey <tromey@adacore.com>
1569 * linux-low.c (select_event_lwp): Use find_thread_in_random.
1571 2019-04-08 Tom Tromey <tom@tromey.com>
1573 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
1575 (linux_resume_one_lwp): Likewise.
1577 2019-04-08 Tom Tromey <tom@tromey.com>
1579 * gdbreplay.c: Update.
1580 * linux-low.c: Update.
1583 2019-04-08 Tom Tromey <tom@tromey.com>
1585 * server.c: Use C++ exception handling.
1586 * linux-low.c: Use C++ exception handling.
1587 * gdbreplay.c: Use C++ exception handling.
1589 2019-04-08 Tom Tromey <tom@tromey.com>
1591 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
1592 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
1593 (captured_main, main): Update.
1594 * gdbreplay.c (main): Update.
1596 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1598 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
1599 value in argument pointer, return 1 if the entry is found and 0
1600 otherwise. Move comment.
1601 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
1602 * linux-low.h (linux_get_auxv): Declare.
1603 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
1605 2019-04-05 Tom Tromey <tromey@adacore.com>
1607 * server.c (gdbserver_usage): Use upper-case for metasyntactic
1610 2019-03-28 Alan Hayward <alan.hayward@arm.com>
1612 * linux-low.c (AT_HWCAP2): Add define if not already included.
1614 2019-03-26 Alan Hayward <alan.hayward@arm.com>
1616 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
1617 (aarch64_arch_setup): Call linux_get_hwcap.
1618 * linux-arm-low.c (arm_get_hwcap): Remove function.
1619 (arm_read_description): Call linux_get_hwcap.
1620 * linux-low.c (linux_get_auxv): New function.
1621 (linux_get_hwcap): Likewise.
1622 (linux_get_hwcap2): Likewise.
1623 * linux-low.h (linux_get_hwcap): New declaration.
1624 (linux_get_hwcap2): Likewise.
1625 * linux-ppc-low.c (ppc_get_auxv): Remove function.
1626 (ppc_arch_setup): Call linux_get_hwcap.
1627 * linux-s390-low.c (s390_get_hwcap): Remove function.
1628 (s390_arch_setup): Call linux_get_hwcap.
1630 2019-03-22 Alan Hayward <alan.hayward@arm.com>
1631 Jiong Wang <jiong.wang@arm.com>
1633 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
1634 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
1636 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
1638 2019-03-22 Alan Hayward <alan.hayward@arm.com>
1639 Jiong Wang <jiong.wang@arm.com>
1641 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
1642 (aarch64_get_hwcap): New function.
1643 (aarch64_arch_setup): Read APIA hwcap.
1645 2019-03-22 Alan Hayward <alan.hayward@arm.com>
1646 Jiong Wang <jiong.wang@arm.com>
1648 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
1649 (initialize_low_tracepoint): Likewise.
1650 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
1651 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
1652 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
1653 (aarch64_linux_read_description): Likewise.
1654 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
1656 2019-03-12 John Baldwin <jhb@FreeBSD.org>
1658 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
1659 i386_create_target_description for 'segments' parameter.
1660 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
1661 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
1662 * win32-i386-low.c (i386_arch_setup): Likewise.
1664 2019-03-12 Tom Tromey <tromey@adacore.com>
1666 * linux-low.c (iterate_over_lwps): Update.
1668 2019-03-06 Tom Tromey <tom@tromey.com>
1670 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
1671 (captured_main): Use SCOPE_EXIT.
1673 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
1675 * configure.srv: Use '$enable_unittest' instead of '$development'
1676 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
1679 2019-02-27 Tom Tromey <tromey@adacore.com>
1681 * gdbreplay.c (logchar): Handle \r\n.
1683 2019-02-07 Alan Hayward <alan.hayward@arm.com>
1685 * linux-low.c (linux_attach): Add process before lwp.
1686 * server.c (attach_inferior): Check if already attached.
1688 2019-02-07 Tom Tromey <tom@tromey.com>
1690 * x86-tdesc.h: Rename include guard.
1691 * x86-low.h: Add include guard.
1692 * wincecompat.h: Rename include guard.
1693 * win32-low.h: Add include guard.
1694 * utils.h: Rename include guard.
1695 * tracepoint.h: Rename include guard.
1696 * tdesc.h: Rename include guard.
1697 * target.h: Rename include guard.
1698 * server.h: Rename include guard.
1699 * remote-utils.h: Rename include guard.
1700 * regcache.h: Rename include guard.
1701 * nto-low.h: Rename include guard.
1702 * notif.h: Add include guard.
1703 * mem-break.h: Rename include guard.
1704 * lynx-low.h: Add include guard.
1705 * linux-x86-tdesc.h: Add include guard.
1706 * linux-s390-tdesc.h: Add include guard.
1707 * linux-ppc-tdesc-init.h: Add include guard.
1708 * linux-low.h: Add include guard.
1709 * linux-aarch64-tdesc.h: Add include guard.
1710 * linux-aarch32-low.h: Add include guard.
1711 * inferiors.h: Rename include guard.
1712 * i387-fp.h: Rename include guard.
1713 * hostio.h: Rename include guard.
1714 * gdbthread.h: Rename include guard.
1715 * gdb_proc_service.h: Rename include guard.
1716 * event-loop.h: Rename include guard.
1717 * dll.h: Rename include guard.
1718 * debug.h: Rename include guard.
1719 * ax.h: Rename include guard.
1721 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
1724 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
1725 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
1727 2019-01-25 Tom Tromey <tom@tromey.com>
1729 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
1731 2019-01-25 Tom Tromey <tom@tromey.com>
1733 * win32-low.c: Fix common/ includes.
1734 * win32-i386-low.c: Fix common/ includes.
1735 * tracepoint.c: Fix common/ includes.
1736 * thread-db.c: Fix common/ includes.
1737 * target.h: Fix common/ includes.
1738 * symbol.c: Fix common/ includes.
1739 * spu-low.c: Fix common/ includes.
1740 * server.h: Fix common/ includes.
1741 * server.c: Fix common/ includes.
1742 * remote-utils.c: Fix common/ includes.
1743 * regcache.h: Fix common/ includes.
1744 * regcache.c: Fix common/ includes.
1745 * nto-x86-low.c: Fix common/ includes.
1746 * notif.h: Fix common/ includes.
1747 * mem-break.h: Fix common/ includes.
1748 * lynx-low.c: Fix common/ includes.
1749 * lynx-i386-low.c: Fix common/ includes.
1750 * linux-x86-tdesc-selftest.c: Fix common/ includes.
1751 * linux-x86-low.c: Fix common/ includes.
1752 * linux-low.c: Fix common/ includes.
1753 * inferiors.h: Fix common/ includes.
1754 * i387-fp.c: Fix common/ includes.
1755 * hostio.c: Fix common/ includes.
1756 * hostio-errno.c: Fix common/ includes.
1757 * gdbthread.h: Fix common/ includes.
1758 * gdbreplay.c: Fix common/ includes.
1759 * fork-child.c: Fix common/ includes.
1760 * event-loop.c: Fix common/ includes.
1762 (enum gdb_agent_op): Fix common/ includes.
1764 2019-01-21 Tom Tromey <tom@tromey.com>
1766 * tracepoint.c: Fix includes.
1767 * remote-utils.c: Fix includes.
1768 * linux-x86-low.c: Fix includes.
1770 2019-01-01 Joel Brobecker <brobecker@adacore.com>
1772 * gdbreplay.c (gdbreplay_version): Update copyright year in
1774 * server.c (gdbserver_version): Likewise.
1776 2018-12-05 Alan Hayward <alan.hayward@arm.com>
1778 * linux-low.c (add_lwp): Switch ordering.
1780 2018-11-29 Tom Tromey <tom@tromey.com>
1782 * win32-low.c (win32_join): Take pid, not process.
1783 * target.h (struct target_ops) <join>: Change argument type.
1784 (join_inferior): Change argument name.
1785 * spu-low.c (spu_join): Take pid, not process.
1786 * server.c (handle_detach): Preserve pid before destroying
1788 * lynx-low.c (lynx_join): Take pid, not process.
1789 * linux-low.c (linux_join): Take pid, not process.
1791 2018-11-23 Alan Hayward <alan.hayward@arm.com>
1793 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
1794 (aarch64_cannot_fetch_register): Likewise.
1795 (struct linux_target_ops): Update references.
1797 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1799 * linux-ppc-low.c: Include nat/linux-ptrace.h.
1801 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1803 * configure.srv (ipa_ppc_linux_regobj): Add
1804 powerpc-isa207-htm-vsx32l-ipa.o and
1805 powerpc-isa207-htm-vsx64l-ipa.o.
1806 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
1807 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
1808 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
1809 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
1810 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
1811 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
1812 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
1813 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
1814 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
1815 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
1816 (init_registers_powerpc_isa207_htm_vsx32l)
1817 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
1818 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
1819 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
1820 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
1821 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
1822 (ppc_store_tm_ctarregset): New functions.
1823 (ppc_regsets): Add entries for HTM regsets.
1824 (ppc_arch_setup): Set htm in features struct when needed. Set
1825 sizes for the HTM regsets.
1826 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
1827 (initialize_low_arch): Call
1828 init_registers_powerpc_isa207_htm_vsx32l and
1829 init_registers_powerpc_isa207_htm_vsx64l.
1830 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
1831 PPC_TDESC_ISA207_HTM_VSX.
1832 (initialize_low_tracepoint): Call
1833 init_registers_powerpc_isa207_htm_vsx32l and
1834 init_registers_powerpc_isa207_htm_vsx64l.
1836 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1838 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
1839 rs6000/power-linux-pmu.xml to srv_xmlfiles.
1840 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
1841 (ppc_store_pmuregset): New functions.
1842 (ppc_regsets): Add entries for ebb and pmu regsets.
1843 (ppc_arch_setup): Set isa207 in features struct if the ebb and
1844 pmu regsets are available. Set sizes for these regsets.
1846 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1848 * configure.srv (ipa_ppc_linux_regobj): Add
1849 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
1850 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
1851 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
1852 rs6000/powerpc-isa207-vsx32l.xml, and
1853 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
1854 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
1855 <PPC_TDESC_ISA207_VSX>: New enum value.
1856 (init_registers_powerpc_isa207_vsx32l): Declare.
1857 (init_registers_powerpc_isa207_vsx64l): Declare.
1858 * linux-ppc-low.c (ppc_fill_tarregset): New function.
1859 (ppc_store_tarregset): New function.
1860 (ppc_regsets): Add entry for the TAR regset.
1861 (ppc_arch_setup): Set isa207 in features struct when needed. Set
1862 size for the TAR regsets.
1863 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
1864 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
1865 and init_registers_powerpc_isa207_vsx64l.
1866 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
1867 (initialize_low_tracepoint): Call
1868 init_registers_powerpc_isa207_vsx32l and
1869 init_registers_powerpc_isa207_vsx64l.
1871 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
1872 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1874 * configure.srv (ipa_ppc_linux_regobj): Add
1875 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
1876 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
1877 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
1878 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
1879 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
1880 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
1881 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
1882 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
1883 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
1884 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
1885 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
1886 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
1887 (ppc_hwcap): Add comment.
1888 (ppc_hwcap2): New global.
1889 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
1890 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
1891 (ppc_regsets): Add entries for the DSCR and PPR regsets.
1892 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
1893 when needed. Set sizes for the the DSCR and PPR regsets.
1894 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
1895 (initialize_low_arch): Call
1896 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
1897 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
1898 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
1899 PPC_TDESC_ISA205_PPR_DSCR_VSX.
1900 (initialize_low_tracepoint): Call
1901 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
1902 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
1904 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1906 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
1908 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
1909 Simon Marchi <simark@simark.ca>
1911 * acinclude.m4: Include "../selftest.m4".
1912 * configure: Regenerate.
1913 * configure.ac: Use "GDB_AC_SELFTEST".
1914 * configure.srv: Use "$enable_unittests" instead of
1915 "$development" when checking whether unit tests have been
1917 * server.c (captured_main): Update message informing that
1918 selftests have been disabled.
1920 2018-10-04 Tom Tromey <tom@tromey.com>
1922 * configure: Rebuild.
1924 2018-10-04 Tom Tromey <tom@tromey.com>
1926 * server.c (handle_status): Rename inner "thread".
1927 (process_serial_event): Declare "res" in 'm' case.
1928 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
1929 (iterate_over_lwps): Rename inner "thread".
1930 (linux_qxfer_libraries_svr4): Rename inner "len".
1931 * gdbthread.h (find_thread_in_random): Rename inner "thread".
1933 2018-10-01 Gary Benson <gbenson@redhat.com>
1935 * gdb_proc_service.h: Moved common code to
1936 common/gdb_proc_service.h.
1938 2018-10-01 Gary Benson <gbenson@redhat.com>
1940 * gdb_proc_service.h: Synchronize comments and whitespace with
1941 GDB's version of this file.
1943 2018-09-25 Tom Tromey <tom@tromey.com>
1945 * configure: Rebuild.
1946 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
1948 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
1950 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
1951 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
1952 ($(IPA_LIB)): Sort IPA_OBJS.
1954 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
1956 * Makefile.in: Remove references to $(ADD_DEPS).
1958 2018-09-16 Tom Tromey <tom@tromey.com>
1960 * remote-utils.c (remote_open): Use GNU style for metasyntactic
1962 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
1965 2018-09-05 Tom Tromey <tom@tromey.com>
1967 * configure: Rebuild.
1969 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
1972 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
1974 2018-08-27 Tom Tromey <tom@tromey.com>
1977 * configure: Rebuild.
1979 2018-08-27 Tom Tromey <tom@tromey.com>
1981 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
1982 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
1983 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
1984 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
1985 (s390x_emit_stack_adjust): Add casts to unsigned char.
1987 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
1991 * server.h (struct client_state) <disable_randomization>:
1994 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
1996 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
1998 (mips_supply_ptrace_register): Likewise.
2000 2018-07-22 Tom Tromey <tom@tromey.com>
2002 * configure: Rebuild.
2004 2018-07-22 Tom Tromey <tom@tromey.com>
2006 * win32-low.c (win32_create_inferior): Remove unused variables.
2007 * gdbreplay.c (remote_open): Remove unused variable.
2008 * remote-utils.c (remote_prepare): Remove unused variable.
2009 * x86-tdesc.h (X86_TDESC_H): Define.
2010 (amd64_expedite_regs): Define conditionally.
2011 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
2012 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
2013 * remote-utils.c (readchar): Remove unused variable.
2015 2018-07-13 Pedro Alves <palves@redhat.com>
2017 * linux-low.c (linux_kill): Change parameter to process_info
2018 pointer instead of pid. Adjust.
2019 * lynx-low.c (lynx_kill): Likewise.
2020 * nto-low.c (nto_kill): Likewise.
2021 * spu-low.c (spu_kill): Likewise.
2022 * win32-low.c (win32_kill): Likewise.
2023 * server.c (handle_v_kill, kill_inferior_callback)
2024 (detach_or_kill_for_exit): Adjust.
2025 * target.c (kill_inferior): Change parameter to process_info
2026 pointer instead of pid. Adjust.
2027 * target.h (struct target_ops) <kill>: Change parameter to
2028 process_info pointer instead of pid. Adjust all implementations
2030 (kill_inferior): Likewise.
2032 2018-07-13 Pedro Alves <palves@redhat.com>
2034 * linux-low.c (linux_detach, linux_join): Change parameter to
2035 process_info pointer instead of pid. Adjust.
2036 * lynx-low.c (lynx_detach, lynx_join): Likewise.
2037 * nto-low.c (nto_detach): Likewise.
2038 * spu-low.c (spu_detach, spu_join): Likewise.
2039 * win32-low.c (win32_detach, win32_join): Likewise.
2040 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
2041 * target.h (struct target_ops) <detach, join>: Change parameter to
2042 process_info pointer instead of pid. Adjust all implementations
2044 (detach_inferior, join_inferior): Rename 'pid' parameter to
2047 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
2048 Jan Kratochvil <jan.kratochvil@redhat.com>
2049 Paul Fertser <fercerpav@gmail.com>
2050 Tsutomu Seki <sekiriki@gmail.com>
2052 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
2053 (OBS): Add 'common/netstuff.o'.
2054 (GDBREPLAY_OBS): Likewise.
2055 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
2056 (remote_open): Implement support for IPv6
2058 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
2060 (handle_accept_event): Accept connections from IPv6 sources.
2061 (remote_prepare): Handle IPv6-style hostnames; implement
2062 support for IPv6 connections.
2063 (remote_open): Implement support for printing connections from
2066 2018-07-11 Pedro Alves <palves@redhat.com>
2069 * mem-break.c (any_persistent_commands): Add process_info
2070 parameter and use it instead of relying on the current process.
2071 Change return type to bool.
2072 * mem-break.h (any_persistent_commands): Add process_info
2073 parameter and change return type to bool.
2074 * server.c (handle_detach): Remove require_running_or_return call.
2075 Look up the process_info for the process we're about to detach.
2076 If not found, return back error to GDB. Adjust
2077 any_persistent_commands call to pass down a process pointer.
2079 2018-07-11 Pedro Alves <palves@redhat.com>
2081 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
2082 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
2083 instead of collect_register_by_name.
2084 * regcache.c (regcache_raw_get_unsigned_by_name): New.
2085 * regcache.h (regcache_raw_get_unsigned_by_name): New.
2087 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
2088 Pedro Alves <palves@redhat.com>
2090 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
2092 2018-07-03 Tom Tromey <tom@tromey.com>
2094 * linux-low.c: Update.
2095 * lynx-low.c: Update.
2096 * mem-break.c: Update.
2097 * nto-low.c: Update.
2098 * remote-utils.c: Update.
2100 * spu-low.c: Update.
2102 * win32-low.c: Update.
2104 2018-07-03 Tom Tromey <tom@tromey.com>
2108 2018-07-03 Tom Tromey <tom@tromey.com>
2110 * linux-low.c: Update.
2112 2018-07-03 Tom Tromey <tom@tromey.com>
2116 2018-07-03 Tom Tromey <tom@tromey.com>
2118 * linux-low.c: Update.
2119 * linux-mips-low.c: Update.
2120 * lynx-low.c: Update.
2121 * nto-low.c: Update.
2122 * remote-utils.c: Update.
2124 * spu-low.c: Update.
2126 * thread-db.c: Update.
2128 2018-07-03 Tom Tromey <tom@tromey.com>
2130 * linux-low.c: Update.
2131 * linux-mips-low.c: Update.
2132 * lynx-low.c: Update.
2133 * mem-break.c: Update.
2134 * nto-low.c: Update.
2135 * remote-utils.c: Update.
2137 * spu-low.c: Update.
2139 * tracepoint.c: Update.
2141 2018-07-03 Tom Tromey <tom@tromey.com>
2143 * linux-low.c: Update.
2144 * linux-ppc-low.c: Update.
2145 * linux-x86-low.c: Update.
2146 * proc-service.c: Update.
2148 * spu-low.c: Update.
2149 * thread-db.c: Update.
2150 * win32-low.c: Update.
2152 2018-07-03 Tom Tromey <tom@tromey.com>
2154 * linux-low.c: Update.
2155 * lynx-low.c: Update.
2156 * nto-low.c: Update.
2157 * remote-utils.c: Update.
2158 * spu-low.c: Update.
2159 * thread-db.c: Update.
2160 * win32-low.c: Update.
2162 2018-06-29 Joel Brobecker <brobecker@adacore.com>
2164 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
2165 parameter in call to 'amd64_create_target_description'.
2167 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
2169 * x86-tdesc.h: Remove executable permission flag.
2171 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
2173 * configure.ac: Remove AC_PREREQ, add missing quoting.
2174 * configure: Re-generate.
2175 * config.in: Re-generate.
2176 * aclocal.m4: Re-generate.
2178 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
2180 * tracepoint.h (current_traceframe): Remove declaration.
2182 2018-06-18 Alan Hayward <alan.hayward@arm.com>
2184 * linux-aarch64-low.c (is_sve_tdesc): New function.
2185 (aarch64_sve_regs_copy_to_regcache): Likewise.
2186 (aarch64_sve_regs_copy_from_regcache): Likewise.
2187 (aarch64_regs_info): Add SVE checks.
2188 (initialize_low_arch): Initialize SVE.
2190 2018-06-18 Alan Hayward <alan.hayward@arm.com>
2192 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
2194 2018-06-11 Alan Hayward <alan.hayward@arm.com>
2196 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
2197 (initialize_low_tracepoint): Likewise
2198 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
2199 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
2201 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
2203 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
2205 2018-06-11 Alan Hayward <alan.hayward@arm.com>
2207 * server.h (PBUFSIZ): Increase size
2209 2018-06-11 Alan Hayward <alan.hayward@arm.com>
2211 * regcache.c (regcache::raw_compare): New function.
2212 * regcache.h (regcache::raw_compare): New declaration.
2214 2018-06-11 Alan Hayward <alan.hayward@arm.com>
2216 * regcache.c (new_register_cache): Use new.
2217 (free_register_cache): Use delete.
2218 (register_data): Use const.
2219 (supply_register): Move body inside regcache.
2220 (regcache::raw_supply): New override function.
2221 (collect_register): Move body inside regcache.
2222 (regcache::raw_collect): New override function.
2223 (regcache::get_register_status): New override function.
2224 * regcache.h (struct regcache): Inherit from reg_buffer_common.
2226 2018-06-09 Tom Tromey <tom@tromey.com>
2228 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
2230 (event_queue): Use std::queue.
2231 (gdb_event_xfree): Remove.
2232 (initialize_event_loop, process_event, wait_for_event): Update.
2234 2018-06-08 Stan Cox <scox@redhat.com>
2236 * win32-low.c (win32_create_inferior): last_ptid and last_status
2237 moved to client_state.
2239 2018-06-08 Pedro Alves <palves@redhat.com>
2241 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
2242 common/common-exceptions.o, common/common-utils.o,
2243 common/errors.o, common/print-utils.o and utils.o.
2244 * gdbreplay.c: Include "common-defs.h" instead of the two
2245 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
2246 string.h or alloca.h.
2247 (perror_with_name): Delete.
2248 (remote_open): Use xstrdup instead of strdup.
2249 (main): Rename to ...
2250 (captured_main): ... this.
2253 2018-06-08 Tom Tromey <tom@tromey.com>
2255 * linux-low.c (linux_low_read_btrace): Update.
2257 2018-06-04 Stan Cox <scox@redhat.com>
2259 * server.h (struct client_state): New.
2260 * server.c (cont_thread, general_thread, multi_process)
2261 (report_fork_events, report_vfork_events, report_exec_events)
2262 (report_thread_events, swbreak_feature, hwbreak_feature)
2263 (vCont_supported, disable_randomization, pass_signals)
2264 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
2265 Moved to client_state.
2266 * remote-utils.c (remote_debug, noack_mode)
2267 (transport_is_reliable): Moved to client_state.
2268 * tracepoint.c (current_traceframe): Moved to client_state.
2271 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
2272 linux-low.c, remote-utils.h, target.c: Use client_state.
2274 2018-05-31 Alan Hayward <alan.hayward@arm.com>
2276 * configure.srv: Add new c/h file.
2278 2018-05-31 Alan Hayward <alan.hayward@arm.com>
2280 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
2283 2018-05-25 Maciej W. Rozycki <macro@mips.com>
2285 * gdb.arch/mips-fpregset-core.exp: New test.
2286 * gdb.arch/mips-fpregset-core.c: New test source.
2288 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
2291 * hostio.c (require_int): Do not report overflow for integers
2292 between 0xfffffff and 0x7fffffff.
2294 2018-05-22 Maciej W. Rozycki <macro@mips.com>
2296 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
2297 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
2298 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
2300 (the_low_target): Wire them.
2302 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2304 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
2305 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
2306 mode. Call collect_register_by_name with vscr using
2307 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
2308 (ppc_store_vrregset): Add and set vscr_offset variable as in
2309 ppc_fill_vrregset. Call supply_register_by_name with vscr using
2312 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2314 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
2315 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
2316 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
2318 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2320 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
2321 (ppc_store_vsxregset): Likewise.
2322 (ppc_fill_vrregset): Likewise.
2323 (ppc_store_vrregset): Likewise.
2324 (ppc_fill_evrregset): Likewise.
2325 (ppc_store_evrregset): Likewise.
2326 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
2327 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
2330 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2332 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
2333 wordsize of the inferior. Call ppc_linux_target_wordsize.
2335 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2337 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
2338 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
2339 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
2340 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
2341 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
2342 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
2343 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
2344 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
2345 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
2346 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
2347 (tdesc_powerpc_e500l): Remove.
2348 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
2349 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
2350 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
2351 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
2353 (ppc_arch_setup): Remove target description matching code. Fill a
2354 ppc_linux_features struct and call ppc_linux_match_description
2357 2018-05-22 Maciej W. Rozycki <macro@mips.com>
2359 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
2360 width of the requested register exceeds the width of the
2362 (mips_cannot_store_register): Likewise.
2364 2018-05-21 Maciej W. Rozycki <macro@mips.com>
2366 * linux-mips-low.c (mips_fetch_register): New function. Update
2368 (mips_store_gregset): Supply 0 rather than $restart for $zero.
2369 (the_low_target): Wire `mips_fetch_register'.
2371 2018-05-10 Joel Brobecker <brobecker@adacore.com>
2373 * lynx-i386-low.c (LYNXOS_178): New macro.
2374 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
2375 the layout on LynxOS-178.
2376 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
2377 handle floating point registers that are not supported by
2380 2018-05-10 Tom Tromey <tom@tromey.com>
2382 * configure: Rebuild.
2384 2018-05-10 Joel Brobecker <brobecker@adacore.com>
2387 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
2388 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
2389 Use it to set the expedite_regs field in the given tdesc.
2390 * x86-tdesc.h: New file.
2391 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
2392 Adjust following the addition of the new expedite_regs parameter
2393 to init_target_desc.
2394 * linux-tic6x-low.c (tic6x_read_description): Likewise.
2395 * linux-x86-tdesc.c: #include "x86-tdesc.h".
2396 (i386_linux_read_description, amd64_linux_read_description):
2397 Adjust following the addition of the new expedite_regs parameter
2398 to init_target_desc.
2399 * lynx-i386-low.c: #include "x86-tdesc.h".
2400 (lynx_i386_arch_setup): Adjust following the addition of the new
2401 expedite_regs parameter to init_target_desc.
2402 * nto-x86-low.c: #include "x86-tdesc.h".
2403 (nto_x86_arch_setup): Adjust following the addition of the new
2404 expedite_regs parameter to init_target_desc.
2405 * win32-i386-low.c: #include "x86-tdesc.h".
2406 (i386_arch_setup): Adjust following the addition of the new
2407 expedite_regs parameter to init_target_desc.
2409 2018-05-10 Joel Brobecker <brobecker@adacore.com>
2412 * win32-low.c (win32_create_inferior): Add call to my_wait
2413 setting last_status global.
2415 2018-05-10 Joel Brobecker <brobecker@adacore.com>
2418 * win32-low.c (create_process): Only call gdb_tilde_expand if
2419 inferior_cwd is not NULL.
2421 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
2423 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
2424 registers to the cache if their values have changed.
2425 (i387_xsave_to_cache): Provide default values for x87 control
2426 registers when these features are available, but disabled.
2427 * regcache.c (supply_register_by_name_zeroed): New function.
2428 * regcache.h (supply_register_by_name_zeroed): Declare new
2431 2018-05-07 Tom Tromey <tom@tromey.com>
2433 * configure: Rebuild.
2435 2018-05-04 Tom Tromey <tom@tromey.com>
2437 * configure: Rebuild.
2439 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
2440 Pedro Alves <palves@redhat.com>
2442 * linux-aarch64-low.c (aarch64_stopped_data_address):
2445 2018-04-27 Tom Tromey <tom@tromey.com>
2447 * configure: Rebuild.
2449 2018-04-23 Tom Tromey <tom@tromey.com>
2451 * configure: Rebuild.
2453 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
2455 * Makefile.in (depcomp): Add "..".
2456 (all_deps_files): New and use it.
2458 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2460 * configure.srv (aarch64*-*-linux*): Don't include xml.
2461 (i[34567]86-*-cygwin*): Likewise.
2462 (i[34567]86-*-linux*): Likewise.
2463 (i[34567]86-*-lynxos*): Likewise.
2464 (i[34567]86-*-mingw32ce*): Likewise.
2465 (i[34567]86-*-mingw*): Likewise.
2466 (i[34567]86-*-nto*): Likewise.
2467 (tic6x-*-uclinux): Likewise.
2468 (x86_64-*-linux*): Likewise.
2469 (x86_64-*-mingw*): Likewise.
2470 (x86_64-*-cygwin*): Likewise.
2472 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2474 * tdesc.c: Remove xml parameter.
2476 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2478 * server.c (get_features_xml): Remove cast.
2479 * tdesc.c (void target_desc::accept): Fill in function.
2480 (tdesc_get_features_xml): Remove old xml creation.
2481 (print_xml_feature::visit_pre): Add xml vistor.
2482 * tdesc.h (struct target_desc): Make xmltarget mutable.
2483 (tdesc_get_features_xml): Remove declaration.
2485 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2487 * tdesc.c (tdesc_architecture_name): Add new function.
2488 (tdesc_osabi_name): Likewise.
2489 (tdesc_get_features_xml): Use new functions.
2491 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2493 * tdesc.c (tdesc_create_flags): Remove.
2494 (tdesc_add_flag): Likewise.
2495 (tdesc_named_type): Likewise.
2496 (tdesc_create_union): Likewise.
2497 (tdesc_create_struct): Likewise.
2498 (tdesc_create_vector): Likewise.
2499 (tdesc_add_bitfield): Likewise.
2500 (tdesc_add_field): Likewise.
2501 (tdesc_set_struct_size): Likewise.
2503 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2505 * tdesc.c (~target_desc): Remove implictly deleted items.
2506 (init_target_desc): Iterate all features.
2507 (tdesc_get_features_xml): Use vector.
2508 (tdesc_create_feature): Create feature.
2509 * tdesc.h (tdesc_feature) Remove
2510 (target_desc): Add features.
2512 2018-04-18 Alan Hayward <alan.hayward@arm.com>
2514 * Makefile.in: Add common/tdesc.c
2515 * tdesc.c (init_target_desc): init all reg_defs from register
2517 (tdesc_create_reg): Create tdesc_reg.
2518 * tdesc.h (tdesc_feature): Add register vector.
2520 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
2522 * tdesc.h (struct target_desc) <features>: Change type to
2523 std::vector<std::string>.
2524 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
2526 (tdesc_get_features_xml): Likewise.
2527 (tdesc_create_feature): Likewise.
2529 2018-03-26 Alan Hayward <alan.hayward@arm.com>
2531 * regcache.c (find_register_by_number): Return a ref.
2532 (find_regno): Use references.
2533 (register_size): Likewise.
2534 (register_data): Likewise.
2535 * tdesc.c (target_desc::~target_desc): Remove free calls.
2536 (target_desc::operator==): Use std::vector compare.
2537 (init_target_desc): Use reference.
2538 (tdesc_create_reg): Use reg constructors.
2539 * tdesc.h (struct target_desc): Replace pointer with object.
2541 2018-03-23 Alan Hayward <alan.hayward@arm.com>
2543 * regcache.c (find_register_by_number): Make static.
2544 (find_regno): Use find_register_by_number
2545 * regcache.h (struct reg): Remove declaration.
2547 2018-03-23 Alan Hayward <alan.hayward@arm.com>
2549 * tdesc.c (target_desc::~target_desc): Move to here.
2550 (target_desc::operator==): Likewise.
2551 * tdesc.h (target_desc::~target_desc): Move from here.
2552 (target_desc::operator==): Likewise.
2554 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
2556 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
2558 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
2560 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
2562 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
2563 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
2564 and init_registers_s390_gs_linux64.
2566 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
2568 * linux-s390-low.c (s390_fill_gs): Remove function.
2569 (s390_fill_gsbc): Remove function.
2570 (s390_regsets): Set fill functions for the guarded storage regsets
2573 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
2575 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
2576 the word size. Add comment.
2577 (s390_get_wordsize): New function.
2578 (s390_arch_setup): No longer select a temporary tdesc to fetch the
2579 pswm with it. Instead, use s390_get_wordsize to determine the
2580 word size first and derive the correct tdesc from that directly.
2582 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
2584 * Makefile.in: Include silent-rules.mk.
2585 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
2586 (COMPILE): Add ECHO_CXX.
2587 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
2588 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
2589 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
2590 (version-generated.c): Add ECHO_GEN.
2591 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
2592 (IPAGENT_COMPILE): Add ECHO_CXX.
2593 (%-generated.c): Add ECHO_REGDAT.
2595 2018-03-14 Tom Tromey <tom@tromey.com>
2598 * ax.c (ax_printf): Special case for NULL.
2600 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
2602 * linux-low.c (linux_qxfer_libraries_svr4): Use
2603 xml_escape_text_append.
2605 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
2607 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
2609 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
2611 * server.c (handle_general_set): Remove unnecessary xstrdup.
2613 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
2615 * server.c (parse_debug_format_options): Adjust to
2616 delim_string_to_char_ptr_vec changes.
2617 * thread-db.c (thread_db_load_search): Adjust to
2618 dirnames_to_char_ptr_vec changes.
2620 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
2622 * target.h (target_enable_btrace, target_disable_btrace)
2623 (target_read_btrace, target_read_btrace_conf): Turn macro into
2624 inline function. Throw error if target method is not defined.
2625 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
2626 check for btrace target method. Be prepared to handle exceptions
2627 from btrace target methods.
2629 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
2631 * server.c (captured_main): Change order of error message printed
2632 when the current working directory cannot be found.
2634 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
2636 * server.c: Include "filenames.h" and "pathstuff.h".
2637 (program_name): Delete variable.
2638 (program_path): New anonymous class.
2639 (get_exec_wrapper): Use "program_path" instead of
2641 (handle_v_run): Likewise.
2642 (captured_main): Likewise.
2643 (process_serial_event): Likewise.
2645 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
2647 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
2648 (OBJS): Add "pathstuff.o".
2649 * server.c (current_directory): New global variable.
2650 (captured_main): Initialize "current_directory".
2652 2018-02-26 Alan Hayward <alan.hayward@arm.com>
2654 * tdesc.c: Use common/tdesc.h.
2655 * tdesc.h: Likewise.
2657 2018-02-20 Alan Hayward <alan.hayward@arm.com>
2658 Simon Marchi <simon.marchi@ericsson.com>
2660 * Makefile.in: Switch order of make rules.
2662 2018-02-19 Alan Hayward <alan.hayward@arm.com>
2664 * Makefile.in: Add common directory in build.
2665 * configure.ac: Add common reference.
2666 * configure: Regenerate.
2668 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
2670 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
2671 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
2672 * spu-low.c (spu_target_ops): Likewise.
2673 * win32-low.c (win32_target_ops): Likewise.
2674 * server.c (supported_btrace_packets): Report packets unconditionally.
2675 * target.h (target_ops) <supports_btrace>: Remove.
2676 (target_supports_btrace): Remove.
2678 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
2680 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
2681 (handle_btrace_disable): Change return type to void. Use exceptions
2683 (handle_btrace_general_set): Catch exception and copy message to
2686 2018-02-08 Tom Tromey <tom@tromey.com>
2688 * linux-low.c (install_software_single_step_breakpoints): Use
2689 make_scoped_restore.
2690 * inferiors.c (make_cleanup_restore_current_thread): Remove.
2691 (do_restore_current_thread_cleanup): Remove.
2692 * gdbthread.h (make_cleanup_restore_current_thread): Don't
2695 2018-02-08 Tom Tromey <tom@tromey.com>
2697 * mem-break.c (set_raw_breakpoint_at): Use
2698 gdb::unique_xmalloc_ptr.
2700 2018-01-30 Pedro Alves <palves@redhat.com>
2703 * target.c (target_terminal::terminal_state): Rename to ...
2704 (target_terminal::m_terminal_state): ... this.
2706 2018-01-19 James Clarke <jrtc27@jrtc27.com>
2708 * linux-low.c (handle_extended_wait): Surround call to
2709 thread_db_notice_clone with #ifdef USE_THREAD_DB.
2711 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
2713 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
2714 linux_ptrace_attach_fail_reason_string now returning an
2716 (linux_attach): Likewise.
2717 * thread-db.c (attach_thread): Likewise.
2719 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
2722 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
2723 checking for fs_base/gs_base fields in struct user_regs_struct.
2724 * configure: Regenerate.
2726 2018-01-16 Yao Qi <yao.qi@linaro.org>
2729 * linux-low.c (fetch_register): Call supply_register instead of
2732 2018-01-08 Yao Qi <yao.qi@linaro.org>
2733 Simon Marchi <simon.marchi@ericsson.com>
2735 * Makefile.in (OBS): Remove selftest.o.
2736 * configure.ac: Set srv_selftest_objs if $development is true.
2737 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
2738 * configure: Re-generated.
2739 * server.c (captured_main): Wrap variable selftest_filter with
2742 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
2744 * server.c (parse_debug_format_options): Return std::string.
2745 (handle_monitor_command, captured_main): Adjust.
2747 2018-01-05 Pedro Alves <palves@redhat.com>
2750 * server.c (captured_main): Pass quiet=false to
2751 save_original_signals_state.
2753 2018-01-01 Joel Brobecker <brobecker@adacore.com>
2755 * gdbreplay.c (gdbreplay_version): Update copyright year in
2757 * server.c (gdbserver_version): Likewise.
2759 2017-12-08 Tom Tromey <tom@tromey.com>
2761 * ax.c (ax_printf): Update.
2763 2017-12-07 Yao Qi <yao.qi@linaro.org>
2765 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
2766 aarch64_linux_read_description.
2767 * linux-amd64-ipa.c (idx2mask): New array.
2768 (get_ipa_tdesc): Move idx2mask out.
2769 (initialize_low_tracepoint): Initialize target descriptions.
2770 * linux-i386-ipa.c (idx2mask): New array.
2771 (get_ipa_tdesc): Move idx2mask out.
2772 (initialize_low_tracepoint): Initialize target descriptions.
2774 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
2776 * tdesc.c (struct tdesc_type): Change return type.
2777 (tdesc_add_flag): Change parameter type.
2778 (tdesc_add_bitfield): Likewise.
2779 (tdesc_add_field): Likewise.
2780 (tdesc_set_struct_size): Likewise.
2782 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
2784 * regcache.c (registers_to_string): Remove unused variable.
2786 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2788 * inferiors.c (for_each_inferior_with_data): Remove.
2789 * inferiors.h (for_each_inferior_with_data): Remove.
2790 * server.c (handle_qxfer_threads_worker): Change parameter type.
2791 (handle_qxfer_threads_proper): Use for_each_thread.
2793 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2795 * inferiors.c (for_each_inferior): Remove.
2796 (clear_inferiors): Use for_each_thread.
2797 * inferiors.h (for_each_inferior): Remove.
2798 * linux-low.c (linux_wait_for_event_filtered): Use
2800 (linux_stabilize_threads): Likewise.
2801 * regcache.c (regcache_release): Likewise.
2802 * server.c (gdb_wants_all_threads_stopped): Likewise.
2803 (clear_pending_status_callback): Remove.
2804 (handle_status): Use for_each_thread.
2805 (captured_main): Likewise.
2806 * win32-low.c (child_init_thread_list): Likewise.
2807 (win32_clear_inferiors): Likewise.
2808 (fake_breakpoint_event): Likewise.
2810 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2812 * inferiors.h (find_inferior): Remove.
2813 * inferiors.c (find_inferior): Remove.
2815 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2817 * linux-low.c (resume_status_pending_p): Update comment.
2818 (need_step_over_p): Update comment.
2820 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2822 * linux-low.c (proceed_one_lwp): Return void, change parameter
2824 (unsuspend_and_proceed_one_lwp): Likewise.
2825 (proceed_all_lwps): Use for_each_thread.
2826 (unstop_all_lwps): Likewise.
2828 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2830 * linux-low.c (linux_resume_one_thread): Return void, take
2832 (linux_resume): Use for_each_thread.
2834 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2836 * linux-low.c (send_sigstop_callback): Return void, change
2837 parameter type. Rename to...
2838 (send_sigstop): ... this.
2839 (suspend_and_send_sigstop_callback): Return void, change parameter
2841 (suspend_and_send_sigstop): ... this.
2842 (stop_all_lwps): Use for_each_thread.
2844 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2846 * linux-low.c (lwp_running): Return bool, remove unused
2848 (linux_stabilize_threads): Use find_thread.
2850 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2852 * linux-low.c (select_singlestep_lwp_callback): Remove.
2853 (count_events_callback): Remove.
2854 (select_event_lwp_callback): Remove.
2855 (select_event_lwp): Use find_thread/for_each_thread.
2857 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2859 * linux-low.c (not_stopped_callback): Return bool, take filter
2861 (linux_wait_for_event_filtered): Use find_thread.
2862 (linux_wait_1): Likewise.
2864 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2866 * linux-low.c (same_lwp): Remove.
2867 (find_lwp_pid): Use find_thread.
2869 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2871 * linux-low.c (delete_lwp_callback): Remove.
2872 (linux_mourn): Use for_each_thread.
2874 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2876 * linux-low.c (linux_detach_lwp_callback): Return void, remove
2877 args parameter, don't check for pid.
2878 (linux_detach): Use for_each_thread.
2880 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2882 * linux-low.c (struct counter): Remove.
2883 (second_thread_of_pid_p): Remove.
2884 (last_thread_of_process_p): Use find_thread.
2886 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2888 * inferiors.c (find_inferior_in_random): Remove.
2889 * inferiors.h (find_inferior_in_random): Remove.
2890 * linux-low.c (status_pending_p_callback): Return bool, accept
2891 parameter ptid directly.
2892 (linux_wait_for_event_filtered): Use find_thread_in_random.
2893 (linux_wait_1): Likewise.
2895 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2897 * inferiors.c (find_inferior_id): Remove.
2898 (find_thread_ptid): Move implemention from find_inferior_id to
2900 * inferiors.h (find_inferior_id): Remove.
2901 * server.c (handle_status): Use find_thread_ptid.
2902 (process_serial_event): Likewise.
2903 * thread-db.c (find_one_thread): Likewise.
2904 (thread_db_thread_handle): Likewise.
2905 * win32-low.c (thread_rec): Likewise.
2906 (child_delete_thread): Likewise.
2907 (win32_thread_alive): Likewise.
2908 (get_child_debug_event): Likewise.
2910 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2912 * linux-mips-low.c (update_watch_registers_callback): Return
2913 void, remove pid_p parameter, don't check for pid.
2914 (mips_insert_point, mips_remove_point): Use for_each_thread.
2916 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2918 * lynx.low (lynx_delete_thread_callback): Remove.
2919 (lynx_mourn): Use for_each_thread.
2921 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2923 * regcache.c (regcache_invalidate_one): Remove.
2924 (regcache_invalidate_pid): use for_each_thread.
2926 2017-11-26 Tom Tromey <tom@tromey.com>
2928 * linux-low.c (linux_create_inferior): Update.
2930 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
2932 * spu-low.c (spu_create_inferior): Fix typo in argument name.
2934 2017-11-24 Alan Hayward <alan.hayward@arm.com>
2936 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
2937 * linux-aarch64-low.c (initialize_low_arch): Call init func.
2938 * linux-aarch64-tdesc-selftest.c: New file.
2939 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
2941 2017-11-24 Alan Hayward <alan.hayward@arm.com>
2943 * configure.srv: Add new file.
2944 * linux-aarch64-low.c (initialize_low_arch): Call init func.
2945 * linux-aarch64-tdesc-selftest.c: New file.
2946 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
2948 2017-11-24 Alan Hayward <alan.hayward@arm.com>
2950 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
2951 * linux-aarch64-low.c (initialize_low_arch): Remove init.
2952 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
2954 2017-11-24 Alan Hayward <alan.hayward@arm.com>
2956 * configure.srv: Add new files.
2957 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
2958 aarch64_linux_read_description.
2959 * linux-aarch64-low.c (aarch64_linux_read_description):
2960 Merge with aarch64_arch_setup.
2961 (aarch64_arch_setup): Call aarch64_linux_read_description.
2962 * linux-aarch64-tdesc.c: New file.
2963 * linux-aarch64-tdesc.h: New file.
2965 2017-11-24 Yao Qi <yao.qi@linaro.org>
2967 * configure.srv: Set $srv_regobj for tic6x-linux.
2968 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
2969 (tic6x_read_description): Move some code to tic6x_arch_setup.
2970 (tic6x_tdesc_test): New function.
2971 (initialize_low_arch): Call selftests::register_test.
2973 2017-11-22 Yao Qi <yao.qi@linaro.org>
2975 * remote-utils.c (prepare_resume_reply): Use memcpy.
2977 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
2979 * linux-low.c (kill_one_lwp_callback): Return void, take
2980 argument directly, don't filter on pid.
2981 (linux_kill): Use for_each_thread.
2983 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
2985 * linux-low.c (need_step_over_p): Return bool, remove dummy
2987 (linux_resume, proceed_all_lwps): Use find_thread.
2989 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
2991 * linux-low.c (resume_status_pending_p): Return bool, remove
2993 (linux_resume): Use find_thread.
2995 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
2997 * linux-low.c (struct thread_resume_array): Remove.
2998 (linux_set_resume_request): Return void, take arguments
3000 (linux_resume): Use for_each_thread.
3002 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3004 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
3005 return bool, remove data argument.
3006 (linux_stabilize_threads): Use find_thread.
3008 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3010 * linux-low.c (unsuspend_one_lwp): Remove.
3011 (unsuspend_all_lwps): Use for_each_thread, inline code from
3014 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3016 * gdbthread.h (find_thread): Add overload with ptid_t filter.
3017 * linux-low.c (struct iterate_over_lwps_args): Remove.
3018 (iterate_over_lwps_filter): Remove.
3019 (iterate_over_lwps): Use find_thread.
3021 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3023 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
3024 (linux_handle_new_gdb_connection): Use for_each_thread, inline
3025 code from reset_lwp_ptrace_options_callback.
3027 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3029 * linux-arm-low.c (struct update_registers_data): Remove.
3030 (update_registers_callback): Return void, take arguments
3031 directly, don't check thread's pid.
3032 (arm_insert_point, arm_remove_point): Use for_each_thread.
3034 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3036 * win32-low.c (continue_one_thread): Return void, take argument
3038 (child_continue): Use for_each_thread.
3040 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3042 * win32-i386-low.c (update_debug_registers_callback): Rename
3044 (update_debug_registers): ... this, return void, remove pid_p arg.
3045 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
3047 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
3049 * inferiors.h (struct process_info): Add constructor, initialize
3051 <syscalls_to_catch>: Change type to std::vector<int>.
3052 * inferiors.c (add_process): Allocate process_info with new.
3053 (remove_process): Free process_info with delete.
3054 * linux-low.c (handle_extended_wait): Adjust.
3055 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
3056 * server.c (handle_general_set): Adjust.
3058 2017-11-16 Pedro Alves <palves@redhat.com>
3060 * remote-utils.c (remote_close): Block SIGIO signals instead of
3061 uninstalling the SIGIO handler.
3063 2017-11-16 Alan Hayward <alan.hayward@arm.com>
3065 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
3067 2017-11-16 Yao Qi <yao.qi@linaro.org>
3069 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
3070 (tic6x_store_gregset): Likewise.
3071 (tic6x_usrregs_info): Move it up.
3073 2017-11-15 Alan Hayward <alan.hayward@arm.com>
3075 * Makefile.in: Update arch rules.
3076 * configure.srv: Explicitly mark arch/ files.
3078 2017-11-13 Andreas Schwab <schwab@suse.de>
3080 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
3082 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
3084 2017-11-06 Pedro Alves <palves@redhat.com>
3086 * config.in, configure: Regenerate.
3088 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3090 * target.c (struct thread_search): Remove.
3091 (thread_search_callback): Remove.
3092 (prepare_to_access_memory): Use for_each_thread instead of
3093 find_inferior. Inline code from thread_search_callback.
3095 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3097 * server.c (struct visit_actioned_threads_data): Remove.
3098 (visit_actioned_threads): Change prototype to take arguments
3100 (resume): Use find_thread instead of find_inferior.
3102 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3104 * server.c (queue_stop_reply_callback): Change prototype, return
3106 (find_status_pending_thread_callback): Remove.
3107 (handle_status): Replace find_inferior with find_thread and
3110 2017-10-25 Alan Hayward <alan.hayward@arm.com>
3112 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
3114 (aarch64_store_gregset): Likewise.
3115 (aarch64_fill_fpregset): Likewise.
3116 (aarch64_store_fpregset): Likewise.
3118 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
3120 * gdbthread.h (find_thread, for_each_thread): New functions.
3121 * inferiors.c (thread_of_pid): Remove.
3122 (find_any_thread_of_pid): Use find_thread.
3123 * linux-low.c (num_lwps): Use for_each_thread.
3125 2017-10-17 Yao Qi <yao.qi@linaro.org>
3127 * Makefile.in: Remove one rule.
3128 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
3130 2017-10-17 Yao Qi <yao.qi@linaro.org>
3132 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
3133 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
3135 2017-10-17 Yao Qi <yao.qi@linaro.org>
3137 * configure.srv: Rename arm.o with arch/arm.o.
3139 2017-10-17 Yao Qi <yao.qi@linaro.org>
3141 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
3142 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
3143 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
3144 (arch-i386.o, arch-amd64.o): Remove rules.
3145 (arch/%.o): New rule.
3146 Update POSTCOMPILE and COMPILE.pre.
3147 * configure.ac: Invoke AC_CONFIG_COMMANDS.
3148 * configure: Re-generated.
3149 * configure.srv: Replace arch-i386.o with arch/i386.o.
3150 Replace arch-amd64.o with arch/amd64.o.
3152 2017-10-16 Yao Qi <yao.qi@linaro.org>
3154 * configure: Regenerated.
3156 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3158 * inferiors.h: (struct inferior_list): Remove.
3159 (struct inferior_list_entry); Remove.
3160 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
3161 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
3162 get_first_inferior): Remove.
3163 (for_each_inferior, for_each_inferior_with_data, find_inferior,
3164 find_inferior_id, find_inferior_in_random): Change signature.
3165 * inferiors.c (all_threads): Change type to
3166 std::list<thread_info *>.
3167 (get_thread): Remove macro.
3168 (find_inferior, find_inferior_id): Change signature, implement
3170 (find_inferior_in_random): Change signature, implement using
3171 find_thread_in_random.
3172 (for_each_inferior, for_each_inferior_with_data): Change
3173 signature, implement using for_each_thread.
3174 (add_inferior_to_list, remove_inferior): Remove.
3175 (add_thread, get_first_thread, thread_of_pid,
3176 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
3177 (get_first_inferior, one_inferior_p, clear_inferior_list):
3179 (clear_inferiors, get_thread_process): Update.
3180 * gdbthread.h: Include <list>.
3181 (struct thread_info) <entry>: Remove field.
3183 (all_threads): Change type to std::list<thread_info *>.
3184 (get_first_inferior): Add doc.
3185 (find_thread, for_each_thread, find_thread_in_random): New
3187 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
3188 * linux-arm-low.c (update_registers_callback): Update.
3189 * linux-low.c (second_thread_of_pid_p): Update.
3190 (kill_one_lwp_callback, linux_detach_lwp_callback,
3191 delete_lwp_callback, status_pending_p_callback, same_lwp,
3192 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
3193 iterate_over_lwps, not_stopped_callback,
3194 resume_stopped_resumed_lwps, count_events_callback,
3195 select_singlestep_lwp_callback, select_event_lwp_callback,
3196 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
3197 suspend_and_send_sigstop_callback, wait_for_sigstop,
3198 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
3199 lwp_running, linux_set_resume_request, resume_status_pending_p,
3200 need_step_over_p, start_step_over, linux_resume_one_thread,
3201 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
3202 reset_lwp_ptrace_options_callback): Update.
3203 * linux-mips-low.c (update_watch_registers_callback): Update.
3204 * regcache.c (regcache_invalidate_one, regcache_invalidate):
3206 (free_register_cache_thread_one): Remove.
3207 (regcache_release): Update.
3208 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
3209 handle_qxfer_threads_worker): Update.
3210 (handle_query): Update, use list iterator.
3211 (visit_actioned_threads, handle_pending_status,
3212 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
3213 clear_pending_status_callback, set_pending_status_callback,
3214 find_status_pending_thread_callback, handle_status,
3215 process_serial_event): Update.
3216 * target.c (thread_search_callback): Update.
3217 * thread-db.c (thread_db_get_tls_address): Update.
3218 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
3220 * win32-i386-low.c (update_debug_registers_callback): Update.
3221 * win32-low.c (delete_thread_info, child_delete_thread,
3222 continue_one_thread, suspend_one_thread,
3223 get_child_debug_event): Adjust.
3225 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3227 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
3228 * inferiors.h: Include <list>.
3229 (struct process_info) <entry>: Remove field.
3231 (pid_of): Change macro to function.
3232 (ptid_of, lwpid_of): Remove macro.
3233 (all_processes): Change type to std::list<process_info *>.
3234 (ALL_PROCESSES): Remove macro.
3235 (for_each_process, find_process): New function.
3236 * inferiors.c (all_processes): Change type to
3237 std::list<process_info *>.
3238 (find_thread_process): Adjust.
3239 (add_process): Likewise.
3240 (remove_process): Likewise.
3241 (find_process_pid): Likewise.
3242 (get_first_process): Likewise.
3243 (started_inferior_callback): Remove.
3244 (have_started_inferiors_p): Adjust.
3245 (attached_inferior_callback): Remove.
3246 (have_attached_inferiors_p): Adjust.
3247 * linux-low.c (check_zombie_leaders): Likewise.
3248 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
3249 (x86_linux_update_xmltarget): Adjust.
3250 * server.c (handle_query): Likewise.
3251 (gdb_reattached_process): Remove.
3252 (handle_status): Adjust.
3253 (kill_inferior_callback): Likewise.
3254 (detach_or_kill_inferior): Remove.
3255 (print_started_pid): Likewise.
3256 (print_attached_pid): Likewise.
3257 (detach_or_kill_for_exit): Update.
3258 (process_serial_event): Likewise.
3259 * linux-arm-low.c (arm_new_fork): Likewise.
3261 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3263 * dll.h: Include <list>.
3264 (struct dll_info): Add constructor.
3265 <entry>: Remove field.
3266 (all_dlls): Change type to std::list<dll_info>.
3267 * dll.c: Include <algorithm>.
3268 (get_dll): Remove macro.
3269 (all_dlls): Change type to std::list<dll_info *>.
3270 (free_one_dll): Remove.
3271 (match_dll): Likewise.
3272 (loaded_dll): Adjust.
3273 (unloaded_dll): Adjust to all_dlls type change, use
3274 std::find_if. Inline code from match_dll.
3275 (clear_dlls): Adjust to all_dlls type change.
3276 * server.c (emit_dll_description): Remove.
3277 (handle_qxfer_libraries): Adjust to all_dlls type change,
3278 integrate emit_dll_description's functionality.
3280 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
3282 * linux-low.h (struct linux_target_ops) <delete_process>: New
3284 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
3285 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
3286 (struct linux_target_ops): Add delete_process callback.
3287 * linux-arm-low.c (arm_delete_process): New.
3288 (struct linux_target_ops): Add delete_process callback.
3289 * linux-bfin-low.c (struct linux_target_ops): Likewise.
3290 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
3291 * linux-m32r-low.c (struct linux_target_ops): Likewise.
3292 * linux-mips-low.c (mips_linux_delete_process): New.
3293 (struct linux_target_ops): Add delete_process callback.
3294 * linux-ppc-low.c (struct linux_target_ops): Likewise.
3295 * linux-s390-low.c (struct linux_target_ops): Likewise.
3296 * linux-sh-low.c (struct linux_target_ops): Likewise.
3297 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
3298 * linux-tile-low.c (struct linux_target_ops): Likewise.
3299 * linux-x86-low.c (x86_linux_delete_process): New.
3300 (struct linux_target_ops): Add delete_process callback.
3301 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
3303 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
3305 * linux-aarch64-low.c (the_low_target): Add thread delete
3307 * linux-arm-low.c (arm_delete_thread): New function.
3308 (the_low_target): Add thread delete callback.
3309 * linux-bfin-low.c (the_low_target): Likewise.
3310 * linux-crisv32-low.c (the_low_target): Likewise.
3311 * linux-low.c (delete_lwp): Invoke delete_thread callback if
3313 * linux-low.h (struct linux_target_ops) <delete_thread>: New
3315 * linux-m32r-low.c (the_low_target): Add thread delete callback.
3316 * linux-mips-low.c (mips_linux_delete_thread): New function.
3317 (the_low_target): Add thread delete callback.
3318 * linux-ppc-low.c (the_low_target): Likewise.
3319 * linux-s390-low.c (the_low_target): Likewise.
3320 * linux-sh-low.c (the_low_target): Likewise.
3321 * linux-tic6x-low.c (the_low_target): Likewise.
3322 * linux-tile-low.c (the_low_target): Likewise.
3323 * linux-x86-low.c (the_low_target): Likewise.
3324 * linux-xtensa-low.c (the_low_target): Likewise.
3326 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
3328 * win32-low.c: Include "common-inferior.h".
3330 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3332 * inferiors.c (set_inferior_cwd): New function.
3333 * server.c (handle_general_set): Handle QSetWorkingDir packet.
3334 (handle_query): Inform that QSetWorkingDir is supported.
3335 * win32-low.c (create_process): Pass the inferior's cwd to
3338 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3340 * inferiors.c (current_inferior_cwd): New global variable.
3341 (get_inferior_cwd): New function.
3342 * inferiors.h (struct process_info) <cwd>: New field.
3344 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3346 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
3347 (OBS): Add gdb_tilde_expand.o.
3349 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
3351 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
3352 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
3354 2017-09-29 Pedro Alves <palves@redhat.com>
3356 * ax.c (gdb_parse_agent_expr): Constify.
3357 * ax.h (gdb_parse_agent_expr): Constify.
3358 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
3360 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
3361 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
3362 * remote-utils.h (read_ptid): Constify.
3363 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
3364 (process_point_options, process_serial_event): Constify.
3365 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
3366 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
3367 (cmd_qtbuffer): Constify.
3369 2017-09-29 Pedro Alves <palves@redhat.com>
3371 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
3374 2017-09-29 Pedro Alves <palves@redhat.com>
3376 * linux-low.c (handle_extended_wait): Pass parent thread instead
3377 of process to thread_db_notice_clone.
3378 * linux-low.h (thread_db_notice_clone): Replace parent process
3379 parameter with parent thread parameter.
3380 * thread-db.c (find_one_thread): Add comment.
3381 (thread_db_notice_clone): Replace parent process parameter with
3382 parent thread parameter. Temporarily switch to the parent thread.
3384 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
3386 * gdbthread.h: Include "common-gdbthread.h".
3387 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
3388 "if" when validating the ptid.
3389 * remote-utils.c: Include "gdbthread.h".
3390 (prepare_resume_reply): Use "switch_to_thread".
3391 * target.c (done_accessing_memory): Likewise.
3393 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
3395 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
3396 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
3397 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
3398 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
3399 s390x-gs-linux64-ipa.o to ipa_obj.
3400 * linux-s390-low.c (HWCAP_S390_GS): New define.
3401 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
3403 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
3404 (s390_arch_setup): Check for guarded-storage support and choose
3406 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
3407 init_registers_s390x_gs_linux64.
3408 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
3410 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
3411 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
3413 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
3415 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
3417 2017-09-21 Kevin Buettner <kevinb@redhat.com>
3419 * linux-low.h (struct lwp_info): Add new field, thread_handle.
3420 (thread_db_thread_handle): Declare.
3421 * linux-low.c (linux_target_ops): Initialize thread_handle.
3422 * server.c (handle_qxfer_threads_worker): Add support for
3424 * target.h (struct target_ops): Add new function pointer,
3426 (target_thread_handle): Define.
3427 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
3429 (thread_db_thread_handle): New function.
3431 2017-09-21 Kevin Buettner <kevinb@redhat.com>
3433 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
3434 * linux-low.h (thread_db_notice_clone): Declare.
3435 * thread-db.c (thread_db_notice_clone): New function.
3437 2017-09-21 Pedro Alves <palves@redhat.com>
3439 * server.c (gdb_read_memory, handle_status, process_serial_event)
3440 (handle_serial_event, handle_target_event): Adjust to
3441 set_desired_thread prototype change.
3442 * target.c (set_desired_thread): Remove 'use_general' parameter
3444 * target.h (set_desired_thread): Remove 'use_general' parameter.
3446 2017-09-20 Tom Tromey <tom@tromey.com>
3448 * target.c (target_terminal::terminal_state): Define.
3449 (target_terminal::init): Rename from target_terminal_init.
3450 (target_terminal::inferior): Rename from
3451 target_terminal_inferior.
3452 (target_terminal::ours): Rename from target_terminal_ours.
3453 (target_terminal::ours_for_output, target_terminal::info): New.
3455 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3457 * server.c (accumulate_file_name_length): Remove.
3458 (emit_dll_description): Adjust to std::string change.
3459 (handle_qxfer_libraries): Use std::string to hold document.
3461 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3463 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
3464 return type of xml_escape_text.
3465 * server.c (emit_dll_description): Likewise.
3467 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3469 * server.c (captured_main): Accept argument for --selftest.
3470 Update run_tests call.
3471 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
3472 when registering selftests.
3474 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
3476 * regcache.c (get_thread_regcache): Update code to use "std::vector"
3477 instead of "VEC" for "target_desc.reg_defs".
3478 (regcache_cpy): Likewise.
3479 (registers_to_string): Likewise.
3480 (registers_from_string): Likewise.
3481 (find_regno): Likewise.
3482 (supply_regblock): Likewise.
3483 (regcache_raw_read_unsigned): Likewise.
3484 * tdesc.c (init_target_desc): Likewise.
3485 (tdesc_create_reg): Likewise.
3486 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
3487 (struct target_desc) <reg_defs>: Convert to "std::vector".
3488 (target_desc): Do not initialize "reg_defs".
3489 (~target_desc): Update code to use "std::vector" instead of "VEC"
3490 for "target_desc.reg_defs".
3491 (operator==): Likewise.
3493 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3495 * inferiors.h (thread_to_gdb_id): Remove.
3496 * inferiors.c (thread_to_gdb_id): Remove.
3497 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
3498 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
3499 lynx_store_registers, lynx_read_memory, lynx_write_memory):
3501 * nto-low.c (nto_fetch_registers, nto_store_registers,
3502 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
3504 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3506 * inferiors.h (gdb_id_to_thread_id): Remove.
3507 * inferiors.c (gdb_id_to_thread_id): Remove.
3508 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
3509 removal. Move pid declaration closer to where it's used.
3511 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3513 * server.c (handle_detach): New function.
3514 (process_serial_event): Move code out, call handle_detach.
3516 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3518 * server.c (require_running): Rename to ...
3519 (require_running_or_return): ... this ...
3520 (require_running_or_break): ... and this.
3521 (handle_query, process_serial_event): Adjust.
3523 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3525 * linux-low.c (linux_set_resume_request): Remove unused
3528 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3530 * server.c (first_thread_of): Remove.
3531 (process_serial_event): Replace usage of first_thread_of with
3532 find_any_thread_of_pid.
3533 * tracepoint.c (same_process_p): Remove.
3534 (gdb_agent_about_to_close): Replace usage of same_process_p with
3535 find_any_thread_of_pid.
3536 * linux-x86-low.c (same_process_callback): Remove.
3537 (x86_arch_setup_process_callback): Replace usage of
3538 same_process_callback with find_any_thread_of_pid.
3539 * thread-db.c (any_thread_of): Remove.
3540 (switch_to_process): Replace usage of any_thread_of with
3541 find_any_thread_of_pid.
3542 * inferiors.c (thread_pid_matches_callback): Remove.
3543 (find_thread_process): Adjust to use find_any_thread_of_pid.
3545 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
3547 * regcache.c (get_thread_regcache): Guard calls to "memset"
3550 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
3552 * linux-low.c (handle_extended_wait): Use
3553 "allocate_target_description" instead of "XNEW".
3554 * linux-x86-low.c (initialize_low_arch): Likewise.
3556 2017-09-05 Yao Qi <yao.qi@linaro.org>
3558 * configure.srv (srv_i386_regobj): Remove.
3559 (srv_amd64_regobj): Remove.
3560 (srv_regobj): Set it to "" for x86 non-linux targets.
3561 * linux-x86-tdesc.c (i386_linux_read_description):
3562 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
3563 (init_registers_i386): Remove the declaration.
3564 (tdesc_i386): Remove the declaration.
3565 (lynx_i386_arch_setup): Call i386_create_target_description.
3566 * nto-x86-low.c: Likewise.
3567 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
3568 [!__x86_64__]: include arch/i386.h.
3569 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
3571 2017-09-05 Yao Qi <yao.qi@linaro.org>
3573 * configure.srv (srv_amd64_linux_xmlfiles): Remove
3574 i386/amd64-XXX-linux from it.
3576 2017-09-05 Yao Qi <yao.qi@linaro.org>
3578 * configure.srv: Empty srv_amd64_linux_regobj if $development is
3580 (ipa_amd64_linux_regobj): Remove.
3581 (ipa_x32_linux_regobj): Remove.
3583 2017-09-05 Yao Qi <yao.qi@linaro.org>
3585 * Makefile.in (arch-amd64.o): New rule.
3586 * configure.srv: Append arch-amd64.o.
3587 * linux-amd64-ipa.c: Include common/x86-xstate.h.
3588 (get_ipa_tdesc): Call amd64_linux_read_description.
3589 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
3590 and init_registers_amd64_XXX.
3591 * linux-x86-low.c (x86_linux_read_description): Call
3592 amd64_linux_read_description.
3593 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
3594 (initialize_low_arch): Don't call init_registers_x32_XXX and
3595 init_registers_amd64_XXX.
3596 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
3597 and tdesc_amd64_XXX.
3598 [__x86_64__] (amd64_tdesc_test): New function.
3599 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
3600 and init_registers_amd64_XXX.
3601 * linux-x86-tdesc.c: Include arch/amd64.h.
3602 (xcr0_to_tdesc_idx): New function.
3603 (i386_linux_read_description): New function.
3604 (amd64_get_ipa_tdesc_idx): New function.
3605 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
3606 (amd64_get_ipa_tdesc): Declare.
3608 2017-09-05 Yao Qi <yao.qi@linaro.org>
3610 * configure.srv (srv_i386_linux_xmlfiles): Remove
3611 i386/i386-XXX-linux.xml from it.
3613 2017-09-05 Yao Qi <yao.qi@linaro.org>
3615 * configure.srv: Set srv_i386_linux_regobj empty if $development
3617 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
3618 initialize_low_tdesc.
3619 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
3620 with #if initialize_low_tdesc.
3621 * linux-x86-tdesc-selftest.c: New file.
3622 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
3624 2017-09-05 Yao Qi <yao.qi@linaro.org>
3626 * Makefile.in (arch-i386.o): New rule.
3627 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
3628 (x86_64-*-linux*): Likewise.
3629 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
3630 include arch/i386.h.
3631 (i386_linux_read_description): Remove code and call
3632 i386_create_target_description.
3633 * tdesc.c (allocate_target_description): New function.
3634 * tdesc.h (set_tdesc_architecture): Remove declaration.
3635 (set_tdesc_osabi): Likewise.
3637 2017-09-05 Yao Qi <yao.qi@linaro.org>
3639 * linux-x86-tdesc.c: Don't include <inttypes.h>.
3640 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
3641 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
3643 * server.c (get_features_xml): Call tdesc_get_features_xml.
3644 * tdesc.c (set_tdesc_architecture): New function.
3645 (set_tdesc_osabi): New function.
3646 (tdesc_get_features_xml): New function.
3647 (tdesc_create_feature): Add an argument.
3648 * tdesc.h (struct target_desc) <features>: New field.
3649 <arch, osabi>: New field.
3650 (~target_desc): xfree features, arch, and osabi.
3651 (target_desc::oerator==): Don't compare .xmltarget.
3652 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
3653 (set_tdesc_osabi): Likewise.
3654 (tdesc_get_features_xml): Likewise.
3656 2017-09-05 Yao Qi <yao.qi@linaro.org>
3658 * linux-x86-tdesc.c: Include selftest.h.
3659 (i386_tdesc_test): New function.
3660 (initialize_low_tdesc): Call selftests::register_test.
3661 * tdesc.h: Include regdef.h.
3662 (target_desc): Override operator == and !=.
3664 2017-09-05 Yao Qi <yao.qi@linaro.org>
3666 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
3667 (ipa_obj): Likewise.
3668 * linux-i386-ipa.c: Include common/x86-xstate.h
3669 (get_ipa_tdesc): Call i386_linux_read_description.
3670 (initialize_low_tracepoint): Don't call init_registers_XXX
3671 functions, call initialize_low_tdesc instead.
3672 * linux-x86-low.c (x86_linux_read_description): Call
3673 i386_linux_read_description.
3674 (initialize_low_arch): Don't call init_registers_i386_XXX
3675 functions, call initialize_low_tdesc.
3676 * linux-x86-tdesc.c: New file.
3677 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
3678 (i386_get_ipa_tdesc_idx): Declare.
3679 (i386_get_ipa_tdesc): Declare.
3680 (initialize_low_tdesc): Declare.
3682 2017-09-05 Yao Qi <yao.qi@linaro.org>
3684 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
3687 2017-09-05 Yao Qi <yao.qi@linaro.org>
3689 * Makefile.in (IPA_OBJS): Add vec-ipa.o
3690 * regcache.c (get_thread_regcache): Use VEC_length.
3691 (init_register_cache): Likewise.
3692 (regcache_cpy): Likewise.
3693 (registers_to_string): Iterate reg_defs via VEC_iterate.
3694 (find_regno): Likewise.
3695 (find_register_by_number): Use VEC_index.
3696 (register_size): Call find_register_by_number.
3697 (register_data): Call find_register_by_number.
3698 (supply_regblock): Use VEC_length.
3699 (regcache_raw_read_unsigned): Likewise.
3700 * tdesc.c (init_target_desc): Iterate reg_defs via
3702 (default_description): Update initializer.
3703 (copy_target_description): Don't update field num_registers.
3704 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
3705 <num_registers>: Remove.
3707 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
3709 * Makefile.in (.SECONDARY): Define target.
3711 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
3713 * linux-low.c (linux_wait_1): Adjust.
3714 * server.c (queue_stop_reply_callback): Adjust.
3716 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
3718 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
3719 QEnvironmentUnset and QEnvironmentReset packets.
3720 (handle_query): Inform remote that QEnvironmentHexEncoded,
3721 QEnvironmentUnset and QEnvironmentReset are supported.
3723 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
3725 * inferiors.h (inferior_target_data): Rename to ...
3726 (thread_target_data): ... this.
3727 (inferior_regcache_data): Rename to ...
3728 (thread_regcache_data): ... this.
3729 (set_inferior_regcache_data): Rename to ...
3730 (set_thread_regcache_data): ... this.
3731 * inferiors.c (inferior_target_data): Rename to ...
3732 (thread_target_data): ... this.
3733 (inferior_regcache_data): Rename to ...
3734 (thread_regcache_data): ... this.
3735 (set_inferior_regcache_data): Rename to ...
3736 (set_thread_regcache_data): ... this.
3737 (free_one_thread): Update.
3738 * linux-low.h (get_thread_lwp): Update.
3739 * regcache.c (get_thread_regcache): Update.
3740 (regcache_invalidate_thread): Update.
3741 (free_register_cache_thread): Update.
3742 * win32-i386-low.c (update_debug_registers_callback): Update.
3743 (win32_get_current_dr): Update.
3744 * win32-low.c (thread_rec): Update.
3745 (delete_thread_info): Update.
3746 (continue_one_thread): Update.
3747 (suspend_one_thread): Update.
3749 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
3751 * inferiors.c (set_inferior_target_data): Remove.
3752 * inferiors.h (set_inferior_target_data): Remove.
3754 2017-08-18 Yao Qi <yao.qi@linaro.org>
3756 * Makefile.in (OBS): Add selftest.o.
3757 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
3758 * configure, config.in: Re-generated.
3759 * server.c: Include common/sefltest.h.
3760 (captured_main): Handle option --selftest.
3762 2017-08-09 Yao Qi <yao.qi@linaro.org>
3764 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
3765 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
3766 i386-avx-mpx.o and i386-mmx.o.
3767 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
3768 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
3769 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
3770 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
3771 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
3772 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
3773 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
3774 i386/amd64-avx-mpx.xml.
3776 2017-08-09 Yao Qi <yao.qi@linaro.org>
3778 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
3779 and x32-avx-avx512.o.
3780 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
3781 i386/x32-avx-avx512.xml.
3783 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
3785 * tracepoint.h (enum class fast_tpoint_collect_result): New
3787 (fast_tracepoint_collecting): Change return type to
3788 fast_tpoint_collect_result.
3789 * tracepoint.c (fast_tracepoint_collecting): Likewise.
3790 * linux-low.h: Include tracepoint.h.
3791 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
3792 fast_tpoint_collect_result.
3793 * linux-low.c (handle_tracepoints): Adjust.
3794 (linux_fast_tracepoint_collecting): Change return type to
3795 fast_tpoint_collect_result.
3796 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
3797 linux_wait_1, stuck_in_jump_pad_callback,
3798 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
3799 proceed_one_lwp): Adjust to type change.
3801 2017-07-10 Yao Qi <yao.qi@linaro.org>
3803 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
3805 2017-06-29 Yao Qi <yao.qi@linaro.org>
3807 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
3809 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
3811 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
3813 * Makefile.in (IPA_OBJS): Sort and format one item per line.
3815 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
3817 * linux-low.c (linux_create_inferior): Adjust code to access the
3818 environment information via 'gdb_environ' class.
3819 * lynx-low.c (lynx_create_inferior): Likewise.
3820 * server.c (our_environ): Make it an instance of 'gdb_environ'.
3821 (get_environ): Return a pointer to 'our_environ'.
3822 (captured_main): Initialize 'our_environ'.
3823 * server.h (get_environ): Adjust prototype.
3824 * spu-low.c (spu_create_inferior): Adjust code to access the
3825 environment information via 'gdb_environ' class.
3827 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
3829 * linux-low.c (linux_read_memory, linux_write_memory): Remove
3830 usage of "register" keyword.
3832 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
3834 * configure: Re-generate.
3836 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
3838 * configure: Re-generate.
3840 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
3842 * Makefile.in (COMPILE.pre): Add "-x c++".
3844 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
3846 * fork-child.c: Conditionally include <signal.h>.
3848 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
3850 * server.c (handle_general_set): Handle new packet
3851 "QStartupWithShell".
3852 (handle_query): Add "QStartupWithShell" to the list of supported
3854 (gdbserver_usage): Add help text explaining the
3855 new "--startup-with-shell" and "--no-startup-with-shell" CLI
3857 (captured_main): Recognize and act upon the presence of the new
3860 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
3861 Pedro Alves <palves@redhat.com>
3863 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
3864 * configure: Regenerate.
3865 * configure.srv (srv_linux_obj): Add "fork-child.o" and
3867 (i[34567]86-*-lynxos*): Likewise.
3868 (spu*-*-*): Likewise.
3869 * fork-child.c: New file.
3870 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
3872 (linux_ptrace_fun): New function.
3873 (linux_create_inferior): Adjust function prototype to reflect
3874 change on "target.h". Adjust function code to use
3876 (linux_request_interrupt): Delete "signal_pid".
3877 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
3878 (lynx_ptrace_fun): New function.
3879 (lynx_create_inferior): Adjust function prototype to reflect
3880 change on "target.h". Adjust function code to use
3882 * nto-low.c (nto_create_inferior): Adjust function prototype and
3883 code to reflect change on "target.h". Update comments.
3884 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
3885 "common-terminal.h" and "environ.h".
3886 (terminal_fd): Moved to fork-child.c.
3887 (old_foreground_pgrp): Likewise.
3888 (restore_old_foreground_pgrp): Likewise.
3889 (last_status): Make it global.
3890 (last_ptid): Likewise.
3891 (our_environ): New variable.
3892 (startup_with_shell): Likewise.
3893 (program_name): Likewise.
3894 (program_argv): Rename to...
3895 (program_args): ...this.
3896 (wrapper_argv): New variable.
3897 (start_inferior): Delete function.
3898 (get_exec_wrapper): New function.
3899 (get_exec_file): Likewise.
3900 (get_environ): Likewise.
3901 (prefork_hook): Likewise.
3902 (post_fork_inferior): Likewise.
3903 (postfork_hook): Likewise.
3904 (postfork_child_hook): Likewise.
3905 (handle_v_run): Update code to deal with arguments coming from the
3906 remote host. Update calls from "start_inferior" to
3908 (captured_main): Likewise. Initialize environment variable. Call
3910 * server.h (post_fork_inferior): New prototype.
3911 (get_environ): Likewise.
3912 (last_status): Declare.
3913 (last_ptid): Likewise.
3914 (signal_pid): Likewise.
3915 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
3916 (spu_ptrace_fun): New function.
3917 (spu_create_inferior): Adjust function prototype to reflect change
3918 on "target.h". Adjust function code to use "fork_inferior".
3919 * target.c (target_terminal_init): New function.
3920 (target_terminal_inferior): Likewise.
3921 (target_terminal_ours): Likewise.
3922 * target.h: Include <vector>.
3923 (struct target_ops) <create_inferior>: Update prototype.
3924 (create_inferior): Update macro.
3925 * utils.c (gdb_flush_out_err): New function.
3926 * win32-low.c (win32_create_inferior): Adjust function prototype
3927 and code to reflect change on "target.h".
3929 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
3931 * inferiors.c (switch_to_thread): New function.
3933 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
3935 * Makefile.in (SFILE): Add "common/job-control.c".
3936 (OBS): Add "job-control.o".
3938 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
3940 * Makefile: Remove "@host_makefile_frag@".
3942 2017-05-05 Pedro Alves <palves@redhat.com>
3944 * configure: Regenerate.
3946 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
3948 * configure: Regenerate.
3950 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
3952 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
3953 software_single_step change of return type to
3954 std::vector<CORE_ADDR>.
3955 * linux-low.c (install_software_single_step_breakpoints):
3957 * linux-low.h (install_software_single_step_breakpoints):
3960 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
3962 * remote-utils.c: Include "gdb_termios.h" instead of
3964 * terminal.h: Delete file.
3966 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
3968 * server.c: Include <vector>.
3969 <program_argv, wrapper_argv>: Convert to std::vector.
3970 (start_inferior): Rewrite function to use C++.
3971 (handle_v_run): Likewise. Update code that calculates the argv
3972 based on the vRun packet; use C++.
3973 (captured_main): Likewise.
3975 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
3977 * server.c (handle_v_cont): Initialize thread_resume::thread
3980 2017-04-05 Pedro Alves <palves@redhat.com>
3982 * configure: Regenerate.
3984 2017-04-05 Pedro Alves <palves@redhat.com>
3986 * gdbreplay.c (sync_error): Constify.
3987 * linux-x86-low.c (push_opcode): Constify.
3989 2017-04-05 Pedro Alves <palves@redhat.com>
3991 * win32-low.c (get_child_debug_event)
3992 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
3993 Report TARGET_WAITKIND_SPURIOUS instead.
3995 2017-04-05 Pedro Alves <palves@redhat.com>
3997 * remote-utils.c (remote_prepare, remote_open): Constify.
3998 * remote-utils.h (remote_prepare, remote_open): Constify.
3999 * server.c (captured_main): Constify 'port' handling.
4001 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
4003 * Makefile.in (clean): Clear .deps.
4005 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
4007 * .gitignore: Remove generated files, replace with wildcard.
4008 * (clean): Replace removal of generated files with wildcard.
4009 (version.c): Replace with...
4010 (version-generated.c): ...this.
4011 (xml-builtin.c): Replace with...
4012 (xml-builtin-generated.c): ...this.
4013 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
4014 (%.c: *regformats*): Replace with...
4015 (%-generated.c: *regformats*): ...this.
4017 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
4019 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
4020 (xtensa_fill_gregset): Call collect_register_by_name for
4022 (xtensa_store_gregset): Call supply_register_by_name for
4025 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
4027 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
4028 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
4029 (xtensa_store_gregset): Call supply_register for all registers in
4030 a0_regnum..a0_regnum + C0_NREGS range.
4032 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4034 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
4035 (ax-ipa.o: ax.c): Remove.
4036 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
4037 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
4038 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
4039 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
4040 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
4042 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4044 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
4045 (print-utils-ipa.o: ../common/print-utils.c): Remove.
4046 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
4047 (errors-ipa.o: ../common/errors.c): Remove.
4048 (format-ipa.o: ../common/format.c): Remove.
4049 (common-utils-ipa.o: ../common/common-utils.c): Remove.
4051 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4053 * Makefile.in (%-ipa.o: %.c): New rule.
4054 (tracepoint-ipa.o: tracepoint.c): Remove.
4055 (utils-ipa.o: utils.c): Remove.
4056 (remote-utils-ipa.o: remote-utils.c): Remove.
4057 (regcache-ipa.o: regcache.c): Remove.
4058 (i386-linux-ipa.o: i386-linux.c): Remove.
4059 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
4060 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
4061 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
4062 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
4063 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
4064 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
4065 (amd64-linux-ipa.o: amd64-linux.c): Remove.
4066 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
4067 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
4068 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
4069 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
4070 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
4071 (aarch64-ipa.o: aarch64.c): Remove.
4072 (s390-linux32-ipa.o: s390-linux32.c): Remove.
4073 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
4074 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
4075 (s390-linux64-ipa.o: s390-linux64.c): Remove.
4076 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
4077 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
4078 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
4079 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
4080 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
4081 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
4082 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
4083 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
4084 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
4085 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
4086 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
4087 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
4088 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
4089 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
4090 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
4091 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
4092 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
4093 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
4094 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
4095 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
4096 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
4097 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
4098 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
4099 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
4100 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
4101 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
4102 (tdesc-ipa.o: tdesc.c): Remove.
4103 (x32-linux-ipa.o: x32-linux.c): Remove.
4104 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
4105 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
4107 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4109 * Makefile.in (%.o: ../arch/%.c): New rule.
4110 (arm.o: ../arch/arm.c): Remove.
4111 (arm-linux.o: ../arch/arm-linux.c): Remove.
4112 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
4113 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
4115 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4117 * Makefile.in (%.o: ../nat/%.c): New rule.
4118 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
4119 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
4120 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
4121 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
4122 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
4123 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
4124 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
4125 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
4126 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
4127 (linux-personality.o: ../nat/linux-personality.c): Remove.
4128 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
4129 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
4130 (x86-linux.o: ../nat/x86-linux.c): Remove.
4131 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
4132 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
4134 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4136 * Makefile.in (%.o: ../common/%.c): New rule.
4137 (signals.o: ../common/signals.c): Remove.
4138 (print-utils.o: ../common/print-utils.c): Remove.
4139 (rsp-low.o: ../common/rsp-low.c): Remove.
4140 (common-utils.o: ../common/common-utils.c): Remove.
4141 (posix-strerror.o: ../common/posix-strerror.c): Remove.
4142 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
4143 (vec.o: ../common/vec.c): Remove.
4144 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
4145 (xml-utils.o: ../common/xml-utils.c): Remove.
4146 (ptid.o: ../common/ptid.c): Remove.
4147 (buffer.o: ../common/buffer.c): Remove.
4148 (format.o: ../common/format.c): Remove.
4149 (filestuff.o: ../common/filestuff.c): Remove.
4150 (agent.o: ../common/agent.c): Remove.
4151 (errors.o: ../common/errors.c): Remove.
4152 (environ.o: ../common/environ.c): Remove.
4153 (common-debug.o: ../common/common-debug.c): Remove.
4154 (cleanups.o: ../common/cleanups.c): Remove.
4155 (common-exceptions.o: ../common/common-exceptions.c): Remove.
4156 (fileio.o: ../common/fileio.c): Remove.
4157 (common-regcache.o: ../common/common-regcache.c): Remove.
4158 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
4159 (new-op.o: ../common/new-op.c): Remove.
4160 (btrace-common.o: ../common/btrace-common.c): Remove.
4162 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4164 * Makefile.in (%.o: ../target/%.c): New rule.
4165 (waitstatus.o: ../target/waitstatus.c): Remove.
4167 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
4170 (%.c: ../regformats/%.dat,
4171 (%.c: ../regformats/arm/%.dat,
4172 (%.c: ../regformats/i386/%.dat,
4173 (%.c: ../regformats/rs6000/%.dat): New rules.
4174 (aarch64.c): Remove.
4175 (reg-arm.c): Remove.
4176 (arm-with-iwmmxt.c): Remove.
4177 (arm-with-vfpv2.c): Remove.
4178 (arm-with-vfpv3.c): Remove.
4179 (arm-with-neon.c): Remove.
4180 (reg-bfin.c): Remove.
4181 (reg-cris.c): Remove.
4182 (reg-crisv32.c): Remove.
4184 (i386-linux.c): Remove.
4185 (i386-avx.c): Remove.
4186 (i386-avx-linux.c): Remove.
4187 (i386-avx-avx512.c): Remove.
4188 (i386-avx-avx512-linux.c): Remove.
4189 (i386-mpx.c): Remove.
4190 (i386-mpx-linux.c): Remove.
4191 (i386-avx-mpx-avx512-pku.c): Remove.
4192 (i386-avx-mpx-avx512-pku-linux.c): Remove.
4193 (i386-avx-mpx.c): Remove.
4194 (i386-avx-mpx-linux.c): Remove.
4195 (i386-mmx.c): Remove.
4196 (i386-mmx-linux.c): Remove.
4197 (reg-ia64.c): Remove.
4198 (reg-m32r.c): Remove.
4199 (reg-m68k.c): Remove.
4201 (mips-linux.c): Remove.
4202 (mips-dsp-linux.c): Remove.
4203 (mips64-linux.c): Remove.
4204 (mips64-dsp-linux.c): Remove.
4205 (nios2-linux.c): Remove.
4206 (powerpc-32.c): Remove.
4207 (powerpc-32l.c): Remove.
4208 (powerpc-altivec32l.c): Remove.
4209 (powerpc-cell32l.c): Remove.
4210 (powerpc-vsx32l.c): Remove.
4211 (powerpc-isa205-32l.c): Remove.
4212 (powerpc-isa205-altivec32l.c): Remove.
4213 (powerpc-isa205-vsx32l.c): Remove.
4214 (powerpc-e500l.c): Remove.
4215 (powerpc-64l.c): Remove.
4216 (powerpc-altivec64l.c): Remove.
4217 (powerpc-cell64l.c): Remove.
4218 (powerpc-vsx64l.c): Remove.
4219 (powerpc-isa205-64l.c): Remove.
4220 (powerpc-isa205-altivec64l.c): Remove.
4221 (powerpc-isa205-vsx64l.c): Remove.
4222 (s390-linux32.c): Remove.
4223 (s390-linux32v1.c): Remove.
4224 (s390-linux32v2.c): Remove.
4225 (s390-linux64.c): Remove.
4226 (s390-linux64v1.c): Remove.
4227 (s390-linux64v2.c): Remove.
4228 (s390-te-linux64.c): Remove.
4229 (s390-vx-linux64.c): Remove.
4230 (s390-tevx-linux64.c): Remove.
4231 (s390x-linux64.c): Remove.
4232 (s390x-linux64v1.c): Remove.
4233 (s390x-linux64v2.c): Remove.
4234 (s390x-te-linux64.c): Remove.
4235 (s390x-vx-linux64.c): Remove.
4236 (s390x-tevx-linux64.c): Remove.
4237 (tic6x-c64xp-linux.c): Remove.
4238 (tic6x-c64x-linux.c): Remove.
4239 (tic6x-c62x-linux.c): Remove.
4241 (reg-sparc64.c): Remove.
4242 (reg-spu.c): Remove.
4244 (amd64-linux.c): Remove.
4245 (amd64-avx.c): Remove.
4246 (amd64-avx-linux.c): Remove.
4247 (amd64-avx-avx512.c): Remove.
4248 (amd64-avx-avx512-linux.c): Remove.
4249 (amd64-mpx.c): Remove.
4250 (amd64-mpx-linux.c): Remove.
4251 (amd64-avx-mpx-avx512-pku.c): Remove.
4252 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
4253 (amd64-avx-mpx.c): Remove.
4254 (amd64-avx-mpx-linux.c): Remove.
4256 (x32-linux.c): Remove.
4257 (x32-avx.c): Remove.
4258 (x32-avx-linux.c): Remove.
4259 (x32-avx-avx512.c): Remove.
4260 (x32-avx-avx512-linux.c): Remove.
4261 (reg-xtensa.c): Remove.
4262 (reg-tilegx.c): Remove.
4263 (reg-tilegx32.c): Remove.
4265 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
4267 * Makefile.in (SFILES): Add "common/environ.c".
4268 (OBJS): Add "common/environ.h".
4270 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
4272 * configure.ac: Check if the fs_base and gs_base members of
4273 `struct user_regs_struct' exist.
4274 * config.in: Regenerated.
4275 * configure: Likewise.
4277 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
4279 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
4281 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
4282 (get_next_pcs_syscall_next_pc): Likewise.
4284 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
4286 * win32-i386-low.c: Fix incorrect reference to a couple source files.
4287 * nto-x86-low.c: Likewise.
4289 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
4291 * Makefile.in: Include disable-implicit-rules.mk.
4293 2016-11-23 Pedro Alves <palves@redhat.com>
4295 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
4296 (debug_vprintf): Use std::chrono::steady_clock instead of
4297 gettimeofday. Use '.' instead of ':'.
4298 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
4299 (get_timestamp): Use std::chrono::steady_clock instead of
4302 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
4304 * Makefile.in: Fix whitespace formatting.
4306 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
4308 * Makefile.in (SFILES, OBS): Flatten list and order
4311 2016-11-23 Pedro Alves <palves@redhat.com>
4313 * event-loop.c (handle_file_event): Use warning.
4314 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
4315 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
4318 2016-11-23 Pedro Alves <palves@redhat.com>
4320 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
4322 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
4323 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
4324 debug_printf and debug_flush for debug output.
4325 * server.c (handle_general_set): Likewise.
4326 * thread-db.c (try_thread_db_load): Use debug_printf for debug
4329 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
4331 * Makefile.in (.c.o): Replace rule with ...
4332 (%.o: %.c): ... this one.
4334 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
4336 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
4337 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
4339 * configure.ac: Remove checks for the make program.
4340 * configure: Re-generate.
4342 2016-10-28 Pedro Alves <palves@redhat.com>
4344 * Makefile.in (CXX_DIALECT): Get from configure.
4345 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
4346 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
4347 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
4348 * config.in: Regenerate.
4349 * configure: Regenerate.
4351 2016-10-27 Yao Qi <yao.qi@linaro.org>
4353 * linux-low.c (linux_supports_range_stepping): Return true if
4354 can_software_single_step return true.
4356 2016-10-27 Yao Qi <yao.qi@linaro.org>
4358 * inferiors.c (find_inferior_in_random): New function.
4359 * inferiors.h (find_inferior_in_random): Declare.
4360 * linux-low.c (linux_wait_for_event_filtered): Call
4361 find_inferior_in_random instead of find_inferior.
4363 2016-10-27 Yao Qi <yao.qi@linaro.org>
4365 * linux-low.c (linux_wait_1): If single-step breakpoints are
4366 inserted, remove them.
4368 2016-10-26 Pedro Alves <palves@redhat.com>
4370 * linux-low.c (handle_extended_wait): Link parent/child fork
4372 (linux_wait_1): Unlink them.
4373 (linux_set_resume_request): Ignore resume requests for
4374 already-resumed and unhandled fork child threads.
4375 * linux-low.h (struct lwp_info) <fork_relative>: New field.
4376 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
4378 (handle_v_requests) <vCont>: Don't call require_running.
4379 * server.h (in_queued_stop_replies): New declaration.
4381 2016-10-24 Yao Qi <yao.qi@linaro.org>
4384 * linux-aarch64-low.c (append_insns): Cast the return value to
4387 2016-10-10 Yao Qi <yao.qi@linaro.org>
4389 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
4391 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
4393 * target.c (target_supports_multi_process): New function, moved
4395 * target.h (target_supports_multi_process): ... here. Remove
4398 2016-10-05 Tom Tromey <tom@tromey.com>
4401 * tracepoint.c (handle_tracepoint_bkpts): Check
4402 ipa_error_tracepoint, not ipa_stopping_tracepoint.
4404 2016-10-05 Yao Qi <yao.qi@linaro.org>
4406 * configure.srv: Update the path of arm-*.xml files.
4408 2016-10-05 Terry Guo <terry.guo@arm.com>
4409 Yao Qi <yao.qi@linaro.org>
4411 * Makefile.in: Adjust the path of rules.
4412 * configure.srv: Update the path of xml files.
4413 * regformats/arm-with-iwmmxt.dat: Regenerated.
4414 * regformats/arm-with-neon.dat: Likewise.
4415 * regformats/arm-with-vfpv2.dat: Likewise.
4416 * regformats/arm-with-vfpv3.dat Likewise.
4418 2016-09-30 Yao Qi <yao.qi@linaro.org>
4421 * target.c (target_stop_and_wait): Don't call
4422 target_continue_no_signal, use resume_stop instead.
4424 2016-09-26 Yao Qi <yao.qi@linaro.org>
4426 * linux-low.c (linux_wait_1): Call debug_exit.
4428 2016-09-23 Pedro Alves <palves@redhat.com>
4430 * Makefile.in (SFILES): Add common/new-op.c.
4431 (OBS): Add common/new-op.o.
4432 (new-op.o): New rule.
4434 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
4436 * .gitinore: Ignore more files.
4438 2016-09-21 Yao Qi <yao.qi@linaro.org>
4440 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
4443 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
4445 * server.c (start_inferior): Call target_mourn_inferior instead of
4446 mourn_inferior; pass ptid_t argument to it.
4448 (handle_target_event): Likewise.
4449 * target.c (target_mourn_inferior): New function.
4450 * target.h (mourn_inferior): Delete macro.
4452 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
4454 * linux-low.c (lwp_is_stepping): New function.
4456 2016-09-06 Carl Love <cel@us.ibm.com>
4458 * server.c (start_inferior): Fixed comment, requested comment change
4459 didn't get updated correctly. Removed reference to ptrace () call as
4460 it is only true on Linux systems.
4462 2016-09-06 Carl Love <cel@us.ibm.com>
4464 * server.c (start_inferior): Do not call
4465 function target_post_create_inferior () if the
4466 inferior process has already exited.
4468 2016-09-05 Pedro Alves <palves@redhat.com>
4470 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
4471 (COMPILE.pre, CC_LD): Use CXX directly.
4472 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
4473 * acinclude.m4: Don't include build-with-cxx.m4.
4474 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
4475 * configure: Regenerate.
4477 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
4480 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
4481 call writing data to own_buf.
4483 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
4485 * target.c (mywait): Call target_wait instead of
4487 (target_wait): New function.
4489 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
4491 * server.c (start_inferior): New variable 'ptid'. Replace calls
4492 to the_target->resume by target_continue{,_no_signal}, depending
4494 * target.c (target_stop_and_wait): Call target_continue_no_signal
4495 instead of the_target->resume.
4496 (target_continue): New function.
4498 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
4500 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
4502 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
4505 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
4507 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
4508 * linux-arm-low.c (ps_get_thread_area): Likewise.
4509 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
4510 * linux-m68k-low.c (ps_get_thread_area): Likewise.
4511 * linux-mips-low.c (ps_get_thread_area): Likewise.
4512 * linux-nios2-low.c (ps_get_thread_area): Likewise.
4513 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
4514 * linux-x86-low.c (ps_get_thread_area): Likewise.
4515 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
4517 2016-08-19 Pedro Alves <palves@redhat.com>
4519 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
4521 2016-08-19 Pedro Alves <palves@redhat.com>
4523 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
4524 comment. Use memcpy instead of casting through unsigned long.
4526 2016-08-19 Pedro Alves <palves@redhat.com>
4528 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
4529 allocating around 0x80000000.
4531 2016-08-19 Pedro Alves <palves@redhat.com>
4534 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
4535 (x32-avx512-linux-ipa.o): New rules.
4536 * configure.ac (x86_64-*-linux*): New x32 check.
4537 * configure.srv (ipa_x32_linux_regobj): New.
4538 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
4539 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
4541 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
4543 * configure: Regenerate.
4545 2016-08-09 Pedro Alves <palves@redhat.com>
4548 * Makefile.in (OBS): Add signals-state-save-restore.o.
4549 (signals-state-save-restore.o): New rule.
4550 * config.in: Regenerate.
4551 * configure: Regenerate.
4552 * linux-low.c: Include "signals-state-save-restore.h".
4553 (linux_create_inferior): Call
4554 restore_original_signals_state.
4555 * server.c: Include "dispositions-save-restore.h".
4556 (captured_main): Call save_original_signals_state.
4558 2016-08-05 Pedro Alves <palves@redhat.com>
4560 * configure: Regenerate.
4562 2016-08-04 Yao Qi <yao.qi@linaro.org>
4564 * linux-low.c (regsets_fetch_inferior_registers): Check
4565 errno is ESRCH or not.
4567 2016-08-02 Yao Qi <yao.qi@linaro.org>
4569 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
4570 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
4571 (thread_db_load_search): Update.
4572 (try_thread_db_load_1): Don't look for td_ta_event_addr,
4573 td_ta_set_event and td_ta_event_getmsg.
4575 2016-07-26 Pedro Alves <palves@redhat.com>
4578 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
4579 of unsigned long for 64-bit registers and use uint32_t instead of
4580 unsigned int for 32-bit registers.
4582 2016-07-26 Pedro Alves <palves@redhat.com>
4584 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
4587 2016-07-21 Tom Tromey <tom@tromey.com>
4589 * configure: Rebuild.
4591 2016-07-21 Yao Qi <yao.qi@linaro.org>
4593 * mem-break.c (find_gdb_breakpoint): Cast bp to
4594 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
4596 2016-07-21 Yao Qi <yao.qi@linaro.org>
4598 * server.c (handle_v_requests): Support s and S actions
4599 if target_supports_software_single_step return true.
4601 2016-07-21 Yao Qi <yao.qi@linaro.org>
4603 * linux-low.c (resume_stopped_resumed_lwps): If resume request
4604 is resume_step, call maybe_hw_step.
4605 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
4607 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
4609 (proceed_one_lwp): If resume request is resume_step, install
4610 reinsert breakpoints and call maybe_hw_step.
4612 2016-07-21 Yao Qi <yao.qi@linaro.org>
4614 * linux-low.c (proceed_one_lwp): Declare.
4615 (linux_resume_one_thread): Remove local variable 'step'.
4616 Lift code enqueue signal. Call proceed_one_lwp instead of
4617 linux_resume_one_lwp.
4619 2016-07-21 Yao Qi <yao.qi@linaro.org>
4621 * linux-low.c (linux_resume_one_thread): Call
4622 enqueue_pending_signal.
4624 2016-07-21 Yao Qi <yao.qi@linaro.org>
4626 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
4627 * inferiors.c (do_restore_current_thread_cleanup): New function.
4628 (make_cleanup_restore_current_thread): Likewise.
4629 * linux-low.c (install_software_single_step_breakpoints): Call
4630 make_cleanup_restore_current_thread. Switch current_thread to
4633 2016-07-21 Yao Qi <yao.qi@linaro.org>
4635 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
4636 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
4637 (clone_one_breakpoint): Likewise.
4638 (delete_reinsert_breakpoints): Change parameter to thread.
4640 (has_reinsert_breakpoints): Likewise.
4641 (uninsert_reinsert_breakpoints): Likewise.
4642 (reinsert_reinsert_breakpoints): Likewise.
4643 * mem-break.h (set_reinsert_breakpoint): Update declaration.
4644 (delete_reinsert_breakpoints): Likewise.
4645 (reinsert_reinsert_breakpoints): Likewise.
4646 (uninsert_reinsert_breakpoints): Likewise.
4647 (has_reinsert_breakpoints): Likewise.
4649 2016-07-21 Yao Qi <yao.qi@linaro.org>
4651 * inferiors.c (get_thread_process): Make parameter const.
4652 * inferiors.h (get_thread_process): Update declaration.
4653 * mem-break.c (clone_all_breakpoints): Remove all parameters.
4654 Add new parameters child_thread and parent_thread. Callers
4656 * mem-break.h (clone_all_breakpoints): Update declaration.
4658 2016-07-21 Yao Qi <yao.qi@linaro.org>
4660 * mem-break.c (struct breakpoint) <cond_list>: Remove.
4661 <command_list, handler>: Remove.
4662 (struct gdb_breakpoint): New.
4663 (struct other_breakpoint): New.
4664 (struct reinsert_breakpoint): New.
4665 (is_gdb_breakpoint): New function.
4666 (any_persistent_commands): Update command_list if
4667 is_gdb_breakpoint returns true.
4668 (set_breakpoint): Create breakpoints according to their types.
4669 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
4670 (set_gdb_breakpoint_1): Likewise.
4671 (set_gdb_breakpoint): Likewise.
4672 (clear_breakpoint_conditions): Change parameter type to
4673 'struct gdb_breakpoint *'.
4674 (clear_breakpoint_commands): Likewise.
4675 (clear_breakpoint_conditions_and_commands): Likewise.
4676 (add_condition_to_breakpoint): Likewise.
4677 (add_breakpoint_condition): Likewise.
4678 (add_commands_to_breakpoint): Likewise.
4679 (check_breakpoints): Check other_breakpoint.
4680 (clone_one_breakpoint): Clone breakpopint according to its type.
4681 * mem-break.h (struct gdb_breakpoint): Declare.
4682 (set_gdb_breakpoint): Update declaration.
4683 (clear_breakpoint_conditions_and_commands): Likewise.
4684 (add_breakpoint_condition): Likewise.
4685 (add_breakpoint_commands): Likewise.
4686 * server.c (process_point_options): Change parameter type to
4687 'struct gdb_breakpoint *'.
4689 2016-07-21 Yao Qi <yao.qi@linaro.org>
4691 * mem-break.c (set_breakpoint_at): Rename it to ...
4692 (set_breakpoint_type_at): ... it.
4693 (set_breakpoint_at): Call set_breakpoint_type_at.
4694 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
4695 * mem-break.h (set_breakpoint_at): Update comments.
4697 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
4699 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
4701 (nios2_store_gregset): Likewise.
4703 2016-07-01 Pedro Alves <palves@redhat.com>
4704 Antoine Tremblay <antoine.tremblay@ericsson.com>
4706 * linux-low.c: Change interface to take the target lwp_info
4707 pointer directly and return void. Handle detaching from a zombie
4709 (linux_detach_lwp_callback): New function.
4710 (linux_detach): Detach from the leader thread after detaching from
4713 2016-06-28 Yao Qi <yao.qi@linaro.org>
4715 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
4716 for variable new_offset.
4717 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
4718 (aarch64_ftrace_insn_reloc_cb): Likewise.
4719 (aarch64_ftrace_insn_reloc_tb): Likewise.
4720 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
4721 PRIx64 instead of PRIx32.
4723 2016-06-28 Yao Qi <yao.qi@linaro.org>
4725 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
4726 (the_low_target): Install arm_get_syscall_trapinfo.
4728 2016-06-28 Yao Qi <yao.qi@linaro.org>
4730 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
4732 (the_low_target): Install aarch64_get_syscall_trapinfo.
4734 2016-06-28 Yao Qi <yao.qi@linaro.org>
4736 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
4738 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
4739 Remove parameter sysno.
4740 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
4743 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
4745 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
4746 (s390_emit_ne_goto): Likewise.
4747 (s390_emit_lt_goto): Likewise.
4748 (s390_emit_le_goto): Likewise.
4749 (s390_emit_gt_goto): Likewise.
4750 (s390_emit_ge_goto): Likewise.
4751 (s390x_emit_eq_goto): Likewise.
4752 (s390x_emit_ne_goto): Likewise.
4753 (s390x_emit_lt_goto): Likewise.
4754 (s390x_emit_le_goto): Likewise.
4755 (s390x_emit_gt_goto): Likewise.
4756 (s390x_emit_ge_goto): Likewise.
4757 (s390_emit_ops_impl): Mark variable static.
4758 (s390x_emit_ops): Likewise.
4760 2016-06-17 Yao Qi <yao.qi@linaro.org>
4762 * linux-low.c (handle_extended_wait): Call
4763 uninsert_reinsert_breakpoints for the parent process. Remove
4764 reinsert breakpoints from the child process. Reinsert them to
4765 the parent process when vfork is done.
4766 * mem-break.c (uninsert_reinsert_breakpoints): New function.
4767 (reinsert_reinsert_breakpoints): New function.
4768 * mem-break.h (uninsert_reinsert_breakpoints): Declare
4769 (reinsert_reinsert_breakpoints): Declare.
4771 2016-06-17 Yao Qi <yao.qi@linaro.org>
4773 * linux-low.c (handle_extended_wait): If the parent is doing
4774 step-over, remove the reinsert breakpoints from the forked child.
4776 2016-06-17 Yao Qi <yao.qi@linaro.org>
4778 * linux-low.c (unsuspend_all_lwps): Declare.
4779 (linux_low_filter_event): If thread exited, call finish_step_over.
4780 If step-over is finished, unsuspend other threads.
4782 2016-06-17 Yao Qi <yao.qi@linaro.org>
4784 * linux-low.c (linux_resume_one_lwp_throw): Assert
4785 has_reinsert_breakpoints returns false.
4786 * mem-break.c (delete_disabled_breakpoints): Assert
4787 bp type isn't reinsert_breakpoint.
4789 2016-06-17 Yao Qi <yao.qi@linaro.org>
4791 * linux-low.c (maybe_hw_step): New function.
4792 (linux_resume_one_lwp_throw): Call maybe_hw_step.
4793 (finish_step_over): Switch current_thread to lwp temporarily,
4794 and assert has_reinsert_breakpoints returns true.
4795 (proceed_one_lwp): Call maybe_hw_step.
4796 * mem-break.c (has_reinsert_breakpoints): New function.
4797 * mem-break.h (has_reinsert_breakpoints): Declare.
4799 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
4801 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
4803 2016-05-17 Yao Qi <yao.qi@linaro.org>
4805 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
4806 instead of find_inferior.
4808 2016-05-05 Yao Qi <yao.qi@linaro.org>
4810 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
4811 Initialize res to zero.
4813 2016-05-05 Yao Qi <yao.qi@linaro.org>
4815 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
4818 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
4820 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
4821 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
4822 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
4824 2016-04-28 Par Olsson <par.olsson@windriver.com>
4825 Simon Marchi <simon.marchi@ericsson.com>
4827 * tracepoint.c (write_inferior_int8): New function.
4828 (cmd_qtenable_disable): Write enable flag using
4829 write_inferior_int8.
4831 2016-04-25 Yao Qi <yao.qi@linaro.org>
4833 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
4834 (need_step_over_p): Return zero if the LWP has pending signals
4835 can be delivered on software single step target.
4837 2016-04-25 Yao Qi <yao.qi@linaro.org>
4839 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
4840 return instead of error.
4842 2016-04-22 Yao Qi <yao.qi@linaro.org>
4844 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
4847 2016-04-22 Yao Qi <yao.qi@linaro.org>
4849 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
4850 signal when stepping over breakpoint with software single
4853 2016-04-21 Pedro Alves <palves@redhat.com>
4855 * linux-s390-low.c (s390_collect_ptrace_register)
4856 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
4858 (s390_check_regset): Use void * instead of gdb_byte *.
4860 2016-04-20 Pedro Alves <palves@redhat.com>
4862 * configure: Renegerate.
4864 2016-04-20 Yao Qi <yao.qi@linaro.org>
4866 * linux-aarch32-low.c: Include "arch/arm-linux.h".
4867 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
4869 (arm_store_gregset): Likewise.
4871 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
4873 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
4874 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
4875 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
4876 (amd64-avx-mpx-linux.c): New rules.
4877 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
4878 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
4879 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
4880 (srv_amd64_regobj): Add amd64-avx-mpx.o.
4881 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
4882 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
4883 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
4884 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
4885 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
4886 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
4887 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
4888 * linux-x86-low.c (x86_linux_read_description): Add case for
4889 X86_XSTATE_AVX_MPX_MASK.
4890 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
4891 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
4892 init_registers_i386_avx_mpx_linux.
4893 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
4894 (initialize_low_tracepoint): Call
4895 init_registers_i386_avx_mpx_linux.
4896 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
4897 (initialize_low_tracepoint): Call
4898 init_registers_amd64_avx_mpx_linux.
4899 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
4900 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
4901 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
4904 2016-04-18 Pedro Alves <palves@redhat.com>
4906 * configure: Regenerate.
4908 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
4910 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
4911 (aarch64_emit_sub): Likewise.
4913 2016-04-12 Pedro Alves <palves@redhat.com>
4915 * utils.c (prepare_to_throw_exception): Delete.
4917 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
4919 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
4921 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
4923 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
4925 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
4927 * linux-aarch64-ipa.c: Add <elf.h> include.
4928 * linux-ppc-ipa.c: Add <elf.h> include.
4929 * linux-s390-ipa.c: Add <elf.h> include.
4931 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
4933 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
4934 (get_raw_reg_ptr): Likewise.
4935 (get_trace_state_variable_value_ptr): Likewise.
4936 (set_trace_state_variable_value_ptr): Likewise.
4937 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
4940 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
4941 Marcin Kościelnicki <koriakin@0x04.net>
4944 * linux-ppc-low.c (emit_insns): New function.
4945 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
4946 (ppc_emit_prologue): New function.
4947 (ppc_emit_epilogue): New function.
4948 (ppc_emit_add): New function.
4949 (ppc_emit_sub): New function.
4950 (ppc_emit_mul): New function.
4951 (ppc_emit_lsh): New function.
4952 (ppc_emit_rsh_signed): New function.
4953 (ppc_emit_rsh_unsigned): New function.
4954 (ppc_emit_ext): New function.
4955 (ppc_emit_zero_ext): New function.
4956 (ppc_emit_log_not): New function.
4957 (ppc_emit_bit_and): New function.
4958 (ppc_emit_bit_or): New function.
4959 (ppc_emit_bit_xor): New function.
4960 (ppc_emit_bit_not): New function.
4961 (ppc_emit_equal): New function.
4962 (ppc_emit_less_signed): New function.
4963 (ppc_emit_less_unsigned): New function.
4964 (ppc_emit_ref): New function.
4965 (ppc_emit_const): New function.
4966 (ppc_emit_reg): New function.
4967 (ppc_emit_pop): New function.
4968 (ppc_emit_stack_flush): New function.
4969 (ppc_emit_swap): New function.
4970 (ppc_emit_stack_adjust): New function.
4971 (ppc_emit_call): New function.
4972 (ppc_emit_int_call_1): New function.
4973 (ppc_emit_void_call_2): New function.
4974 (ppc_emit_if_goto): New function.
4975 (ppc_emit_goto): New function.
4976 (ppc_emit_eq_goto): New function.
4977 (ppc_emit_ne_goto): New function.
4978 (ppc_emit_lt_goto): New function.
4979 (ppc_emit_le_goto): New function.
4980 (ppc_emit_gt_goto): New function.
4981 (ppc_emit_ge_goto): New function.
4982 (ppc_write_goto_address): New function.
4983 (ppc_emit_ops_impl): New static variable.
4984 (ppc64v1_emit_prologue): New function.
4985 (ppc64v2_emit_prologue): New function.
4986 (ppc64_emit_epilogue): New function.
4987 (ppc64_emit_add): New function.
4988 (ppc64_emit_sub): New function.
4989 (ppc64_emit_mul): New function.
4990 (ppc64_emit_lsh): New function.
4991 (ppc64_emit_rsh_signed): New function.
4992 (ppc64_emit_rsh_unsigned): New function.
4993 (ppc64_emit_ext): New function.
4994 (ppc64_emit_zero_ext): New function.
4995 (ppc64_emit_log_not): New function.
4996 (ppc64_emit_bit_and): New function.
4997 (ppc64_emit_bit_or): New function.
4998 (ppc64_emit_bit_xor): New function.
4999 (ppc64_emit_bit_not): New function.
5000 (ppc64_emit_equal): New function.
5001 (ppc64_emit_less_signed): New function.
5002 (ppc64_emit_less_unsigned): New function.
5003 (ppc64_emit_ref): New function.
5004 (ppc64_emit_const): New function.
5005 (ppc64v1_emit_reg): New function.
5006 (ppc64v2_emit_reg): New function.
5007 (ppc64_emit_pop): New function.
5008 (ppc64_emit_stack_flush): New function.
5009 (ppc64_emit_swap): New function.
5010 (ppc64v1_emit_call): New function.
5011 (ppc64v2_emit_call): New function.
5012 (ppc64v1_emit_int_call_1): New function.
5013 (ppc64v2_emit_int_call_1): New function.
5014 (ppc64v1_emit_void_call_2): New function.
5015 (ppc64v2_emit_void_call_2): New function.
5016 (ppc64_emit_if_goto): New function.
5017 (ppc64_emit_eq_goto): New function.
5018 (ppc64_emit_ne_goto): New function.
5019 (ppc64_emit_lt_goto): New function.
5020 (ppc64_emit_le_goto): New function.
5021 (ppc64_emit_gt_goto): New function.
5022 (ppc64_emit_ge_goto): New function.
5023 (ppc64v1_emit_ops_impl): New static variable.
5024 (ppc64v2_emit_ops_impl): New static variable.
5025 (ppc_emit_ops): New function.
5026 (linux_low_target): Wire in ppc_emit_ops.
5028 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
5029 Marcin Kościelnicki <koriakin@0x04.net>
5032 * Makefile.in: Add powerpc-*-ipa.o
5033 * configure.srv: Add ipa_obj for powerpc*-linux.
5034 * linux-ppc-ipa.c: New file.
5035 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
5037 (PPC_FIELD): New macro.
5038 (PPC_SEXT): New macro.
5039 (PPC_OP6): New macro.
5040 (PPC_BO): New macro.
5041 (PPC_LI): New macro.
5042 (PPC_BD): New macro.
5043 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
5044 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
5045 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
5046 (ppc_get_thread_area): New function.
5047 (is_elfv2_inferior): New function.
5048 (gen_ds_form): New function.
5049 (GEN_STD): New macro.
5050 (GEN_STDU): New macro.
5051 (GEN_LD): New macro.
5052 (GEN_LDU): New macro.
5053 (gen_d_form): New function.
5054 (GEN_ADDI): New macro.
5055 (GEN_ADDIS): New macro.
5056 (GEN_LI): New macro.
5057 (GEN_LIS): New macro.
5058 (GEN_ORI): New macro.
5059 (GEN_ORIS): New macro.
5060 (GEN_LWZ): New macro.
5061 (GEN_STW): New macro.
5062 (GEN_STWU): New macro.
5063 (gen_xfx_form): New function.
5064 (GEN_MFSPR): New macro.
5065 (GEN_MTSPR): New macro.
5066 (GEN_MFCR): New macro.
5067 (GEN_MTCR): New macro.
5068 (GEN_SYNC): New macro.
5069 (GEN_LWSYNC): New macro.
5070 (gen_x_form): New function.
5071 (GEN_OR): New macro.
5072 (GEN_MR): New macro.
5073 (GEN_LWARX): New macro.
5074 (GEN_STWCX): New macro.
5075 (GEN_CMPW): New macro.
5076 (gen_md_form): New function.
5077 (GEN_RLDICL): New macro.
5078 (GEN_RLDICR): New macro.
5079 (gen_i_form): New function.
5081 (GEN_BL): New macro.
5082 (gen_b_form): New function.
5083 (GEN_BNE): New macro.
5084 (GEN_LOAD): New macro.
5085 (GEN_STORE): New macro.
5086 (gen_limm): New function.
5087 (gen_atomic_xchg): New function.
5088 (gen_call): New function.
5089 (ppc_relocate_instruction): New function.
5090 (ppc_install_fast_tracepoint_jump_pad): New function.
5091 (ppc_get_min_fast_tracepoint_insn_len): New function.
5092 (ppc_get_ipa_tdesc_idx): New function.
5093 (the_low_target): Wire in the new functions.
5094 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
5096 * linux-ppc-tdesc.h: New file.
5098 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
5100 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
5101 (alloc_jump_pad_buffer): New function.
5102 * linux-amd64-ipa.c: Add <sys/mman.h> include.
5103 (alloc_jump_pad_buffer): New function.
5104 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
5105 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
5106 (alloc_jump_pad_buffer): New function.
5107 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
5108 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
5109 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
5110 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
5112 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
5114 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
5115 * linux-amd64-ipa.c: Likewise.
5116 * linux-i386-ipa.c: Likewise.
5117 * linux-s390-ipa.c: Likewise.
5118 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
5119 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
5120 set_trace_state_variable_value_ptr.
5121 (struct ipa_sym_addresses): Likewise.
5122 (symbol_list): Likewise.
5123 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
5124 accessing gdb_collect directly.
5125 (gdb_collect_ptr_type): New typedef.
5126 (get_raw_reg_ptr_type): New typedef.
5127 (get_trace_state_variable_value_ptr_type): New typedef.
5128 (set_trace_state_variable_value_ptr_type): New typedef.
5129 (gdb_collect_ptr): New global.
5130 (get_raw_reg_ptr): New global.
5131 (get_trace_state_variable_value_ptr): New global.
5132 (set_trace_state_variable_value_ptr): New global.
5133 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
5134 accessing get_raw_reg directly.
5135 (get_get_tsv_func_addr): Likewise for
5136 get_trace_state_variable_value_ptr.
5137 (get_set_tsv_func_addr): Likewise for
5138 set_trace_state_variable_value_ptr.
5139 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
5141 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
5143 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
5145 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
5147 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
5149 (relocate_instruction): Remove own_buf.
5150 * server.c (own_buf): Make global.
5151 (handle_v_requests): Make global.
5152 * server.h (own_buf): New declaration.
5153 (handle_v_requests): New prototype.
5155 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
5158 * linux-s390-low.c (add_insns): New function.
5159 (s390_emit_prologue): New function.
5160 (s390_emit_epilogue): New function.
5161 (s390_emit_add): New function.
5162 (s390_emit_sub): New function.
5163 (s390_emit_mul): New function.
5164 (s390_emit_lsh): New function.
5165 (s390_emit_rsh_signed): New function.
5166 (s390_emit_rsh_unsigned): New function.
5167 (s390_emit_ext): New function.
5168 (s390_emit_log_not): New function.
5169 (s390_emit_bit_and): New function.
5170 (s390_emit_bit_or): New function.
5171 (s390_emit_bit_xor): New function.
5172 (s390_emit_bit_not): New function.
5173 (s390_emit_equal): New function.
5174 (s390_emit_less_signed): New function.
5175 (s390_emit_less_unsigned): New function.
5176 (s390_emit_ref): New function.
5177 (s390_emit_if_goto): New function.
5178 (s390_emit_goto): New function.
5179 (s390_write_goto_address): New function.
5180 (s390_emit_litpool): New function.
5181 (s390_emit_const): New function.
5182 (s390_emit_call): New function.
5183 (s390_emit_reg): New function.
5184 (s390_emit_pop): New function.
5185 (s390_emit_stack_flush): New function.
5186 (s390_emit_zero_ext): New function.
5187 (s390_emit_swap): New function.
5188 (s390_emit_stack_adjust): New function.
5189 (s390_emit_set_r2): New function.
5190 (s390_emit_int_call_1): New function.
5191 (s390_emit_void_call_2): New function.
5192 (s390_emit_eq_goto): New function.
5193 (s390_emit_ne_goto): New function.
5194 (s390_emit_lt_goto): New function.
5195 (s390_emit_le_goto): New function.
5196 (s390_emit_gt_goto): New function.
5197 (s390_emit_ge_goto): New function.
5198 (s390x_emit_prologue): New function.
5199 (s390x_emit_epilogue): New function.
5200 (s390x_emit_add): New function.
5201 (s390x_emit_sub): New function.
5202 (s390x_emit_mul): New function.
5203 (s390x_emit_lsh): New function.
5204 (s390x_emit_rsh_signed): New function.
5205 (s390x_emit_rsh_unsigned): New function.
5206 (s390x_emit_ext): New function.
5207 (s390x_emit_log_not): New function.
5208 (s390x_emit_bit_and): New function.
5209 (s390x_emit_bit_or): New function.
5210 (s390x_emit_bit_xor): New function.
5211 (s390x_emit_bit_not): New function.
5212 (s390x_emit_equal): New function.
5213 (s390x_emit_less_signed): New function.
5214 (s390x_emit_less_unsigned): New function.
5215 (s390x_emit_ref): New function.
5216 (s390x_emit_if_goto): New function.
5217 (s390x_emit_const): New function.
5218 (s390x_emit_call): New function.
5219 (s390x_emit_reg): New function.
5220 (s390x_emit_pop): New function.
5221 (s390x_emit_stack_flush): New function.
5222 (s390x_emit_zero_ext): New function.
5223 (s390x_emit_swap): New function.
5224 (s390x_emit_stack_adjust): New function.
5225 (s390x_emit_int_call_1): New function.
5226 (s390x_emit_void_call_2): New function.
5227 (s390x_emit_eq_goto): New function.
5228 (s390x_emit_ne_goto): New function.
5229 (s390x_emit_lt_goto): New function.
5230 (s390x_emit_le_goto): New function.
5231 (s390x_emit_gt_goto): New function.
5232 (s390x_emit_ge_goto): New function.
5233 (s390_emit_ops): New function.
5234 (struct linux_target_ops): Fill in emit_ops hook.
5236 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
5239 * Makefile.in: Add s390 IPA files.
5240 * configure.srv: Build IPA for s390.
5241 * linux-s390-ipa.c: New file.
5242 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
5243 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
5244 (tdesc_s390_linux32): Likewise.
5245 (init_registers_s390_linux32v1): Likewise.
5246 (tdesc_s390_linux32v1): Likewise.
5247 (init_registers_s390_linux32v2): Likewise.
5248 (tdesc_s390_linux32v2): Likewise.
5249 (init_registers_s390_linux64): Likewise.
5250 (tdesc_s390_linux64): Likewise.
5251 (init_registers_s390_linux64v1): Likewise.
5252 (tdesc_s390_linux64v1): Likewise.
5253 (init_registers_s390_linux64v2): Likewise.
5254 (tdesc_s390_linux64v2): Likewise.
5255 (init_registers_s390_te_linux64): Likewise.
5256 (tdesc_s390_te_linux64): Likewise.
5257 (init_registers_s390_vx_linux64): Likewise.
5258 (tdesc_s390_vx_linux64): Likewise.
5259 (init_registers_s390_tevx_linux64): Likewise.
5260 (tdesc_s390_tevx_linux64): Likewise.
5261 (init_registers_s390x_linux64): Likewise.
5262 (tdesc_s390x_linux64): Likewise.
5263 (init_registers_s390x_linux64v1): Likewise.
5264 (tdesc_s390x_linux64v1): Likewise.
5265 (init_registers_s390x_linux64v2): Likewise.
5266 (tdesc_s390x_linux64v2): Likewise.
5267 (init_registers_s390x_te_linux64): Likewise.
5268 (tdesc_s390x_te_linux64): Likewise.
5269 (init_registers_s390x_vx_linux64): Likewise.
5270 (tdesc_s390x_vx_linux64): Likewise.
5271 (init_registers_s390x_tevx_linux64): Likewise.
5272 (tdesc_s390x_tevx_linux64): Likewise.
5273 (have_hwcap_s390_vx): New static variable.
5274 (s390_arch_setup): Fill have_hwcap_s390_vx.
5275 (s390_get_thread_area): New function.
5276 (s390_ft_entry_gpr_esa): New const.
5277 (s390_ft_entry_gpr_zarch): New const.
5278 (s390_ft_entry_misc): New const.
5279 (s390_ft_entry_fr): New const.
5280 (s390_ft_entry_vr): New const.
5281 (s390_ft_main_31): New const.
5282 (s390_ft_main_64): New const.
5283 (s390_ft_exit_fr): New const.
5284 (s390_ft_exit_vr): New const.
5285 (s390_ft_exit_misc): New const.
5286 (s390_ft_exit_gpr_esa): New const.
5287 (s390_ft_exit_gpr_zarch): New const.
5288 (append_insns): New function.
5289 (s390_relocate_instruction): New function.
5290 (s390_install_fast_tracepoint_jump_pad): New function.
5291 (s390_get_min_fast_tracepoint_insn_len): New function.
5292 (s390_get_ipa_tdesc_idx): New function.
5293 (struct linux_target_ops): Wire in the above functions.
5294 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
5295 * linux-s390-tdesc.h: New file.
5297 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
5299 * linux-s390-low.c (s390_supports_tracepoints): New function.
5300 (struct linux_target_ops): Fill supports_tracepoints hook.
5302 2016-03-18 Yao Qi <yao.qi@linaro.org>
5304 * linux-low.c (lwp_signal_can_be_delivered): New function.
5305 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
5307 2016-03-18 Yao Qi <yao.qi@linaro.org>
5309 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
5310 0 if signal is enqueued. Remove 'signal' from one debugging
5311 message. Move one debugging message to some lines below.
5312 Remove code setting 'signal' to 0.
5314 2016-03-18 Yao Qi <yao.qi@linaro.org>
5316 * linux-low.c (linux_low_filter_event): Remove redundant
5317 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
5319 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
5321 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
5322 (struct linux_target_ops): Wire in the above.
5324 2016-03-03 Yao Qi <yao.qi@linaro.org>
5326 * linux-low.c: Update comments to start_step_over.
5328 2016-03-03 Yao Qi <yao.qi@linaro.org>
5331 * linux-low.c (handle_extended_wait): Set child suspended
5332 if event_lwp->bp_reinsert isn't zero.
5334 2016-03-02 Yao Qi <yao.qi@linaro.org>
5336 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
5337 enqueue_pending_signal.
5339 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
5341 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
5344 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
5346 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
5347 (s390_regmap_3264) [!__s390x__]: New global.
5348 (s390_collect_ptrace_register): Skip map entries containing -1.
5349 (s390_supply_ptrace_register): Ditto.
5350 (s390_fill_gprs_high): New function.
5351 (s390_store_gprs_high): New function.
5352 (s390_regsets): Add NT_S390_HIGH_GPRS.
5353 (s390_get_hwcap): Enable on 31-bit.
5354 (have_hwcap_s390_high_gprs): Enable on 31-bit.
5355 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
5356 Detect NT_S390_HIGH_GPRS.
5357 (s390_usrregs_info_3264): Enable on 31-bit.
5358 (s390_regs_info): Enable regs_info_3264 on 31-bit.
5359 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
5361 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
5364 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
5365 * configure.srv: Ditto.
5366 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
5367 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
5368 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
5369 (init_registers_amd64_linux): Remove prototype.
5370 (tdesc_amd64_linux): Remove declaration.
5371 (get_ipa_tdesc): New function.
5372 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
5373 initialize remaining tdescs.
5374 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
5375 (init_registers_i386_linux): Remove prototype.
5376 (tdesc_i386_linux): Remove declaration.
5377 (get_ipa_tdesc): New function.
5378 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
5379 initialize remaining tdescs.
5380 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
5381 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
5382 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
5383 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
5384 (x86_get_ipa_tdesc_idx): New function.
5385 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
5386 * linux-x86-tdesc.h: New file.
5387 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
5388 (target_get_ipa_tdesc_idx): New macro.
5389 * tracepoint.c (ipa_tdesc_idx): New macro.
5390 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
5391 (symbol_list): Add ipa_tdesc_idx.
5392 (cmd_qtstart): Write ipa_tdesc_idx in the target.
5393 (ipa_tdesc): Remove.
5394 (ipa_tdesc_idx): New variable.
5395 (get_context_regcache): Use get_ipa_tdesc.
5396 (gdb_collect): Ditto.
5398 * tracepoint.h (get_ipa_tdesc): New prototype.
5399 (ipa_tdesc): Remove.
5401 2016-02-24 Pedro Alves <palves@redhat.com>
5403 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
5404 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
5405 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
5406 Factor out common code between the USE_SIGTRAP_SIGINFO and
5407 !USE_SIGTRAP_SIGINFO blocks.
5408 (linux_low_filter_event): Call save_stop_reason instead of
5409 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
5411 (linux_wait_1): Update comments.
5413 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
5415 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
5416 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
5417 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
5418 ppc_insert_point, ppc_remove_point.
5420 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
5422 * linux-s390-low.c (s390_supports_z_point_type): New function.
5423 (struct linux_target_ops): Wire s390_supports_z_point_type in.
5425 2016-02-16 Yao Qi <yao.qi@linaro.org>
5427 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
5428 PC. Get pc from regcache_read_pc.
5430 2016-02-12 Yao Qi <yao.qi@linaro.org>
5432 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
5433 or linux_get_pc_32bit.
5434 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
5436 2016-02-12 Yao Qi <yao.qi@linaro.org>
5438 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
5439 arm_linux_get_next_pcs_fixup.
5441 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
5443 * tracepoint.c (x_tracepoint_action_download): Change
5444 write_inferior_data_ptr to write_inferior_data_pointer.
5445 (cmd_qtstart): Likewise.
5446 (write_inferior_data_ptr): Remove.
5447 (download_agent_expr): Change write_inferior_data_ptr to
5448 write_inferior_data_pointer.
5449 (download_tracepoint_1): Likewise.
5450 (download_tracepoint): Likewise.
5451 (download_trace_state_variables): Likewise.
5453 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
5454 Marcin Kościelnicki <koriakin@0x04.net>
5456 * tracepoint.c (struct tracepoint_action_ops): Remove.
5457 (struct tracepoint_action): Remove ops.
5458 (m_tracepoint_action_download, r_tracepoint_action_download)
5459 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
5460 size and offset accordingly.
5461 (m_tracepoint_action_ops, r_tracepoint_action_ops)
5462 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
5463 (tracepoint_action_send, tracepoint_action_download): New functions.
5464 Helpers for trace action handlers.
5465 (add_tracepoint_action): Remove setup actions ops.
5466 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
5468 2016-02-10 Yao Qi <yao.qi@linaro.org>
5470 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
5472 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
5474 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
5476 * configure: Regenerate.
5478 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
5480 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
5481 void * to gdb_byte *.
5482 * linux-low.c (siginfo_fixup): Likewise.
5483 (linux_xfer_siginfo): Likewise.
5484 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
5486 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
5488 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
5490 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
5492 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
5494 * linux-x86-low.c [__x86_64__]: Include
5495 "nat/amd64-linux-siginfo.h".
5496 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
5497 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
5498 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
5499 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
5500 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
5501 (cpt_si_fd, si_timerid, si_overrun): Move from
5502 nat/amd64-linux-siginfo.c.
5503 * Makefile.in (amd64-linux-siginfo.o:): New rule.
5505 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
5507 * server.c (skip_to_semicolon): Remove.
5508 (process_point_options): Use strchrnul instead of
5511 2016-01-26 Yao Qi <yao.qi@linaro.org>
5513 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
5514 * linux-low.c (install_software_single_step_breakpoints): Don't
5515 call regcache_read_pc.
5516 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
5519 2016-01-26 Yao Qi <yao.qi@linaro.org>
5521 * linux-low.c (install_software_single_step_breakpoints): Call
5522 regcache_read_pc instead of get_pc.
5524 2016-01-26 Yao Qi <yao.qi@linaro.org>
5526 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
5527 (unblock_async_io): Rename to ...
5528 (block_unblock_async_io): ... it. New function.
5529 (enable_async_io): Don't install SIGIO handler. Unblock it
5531 (disable_async_io): Don't ignore SIGIO. Block it instead.
5532 (initialize_async_io): Install SIGIO handler. Don't call
5535 2016-01-26 Yao Qi <yao.qi@linaro.org>
5537 * remote-utils.c (getpkt): If the buffer isn't empty, and the
5538 first character is '\003', call *the_target->request_interrupt.
5540 2016-01-25 Yao Qi <yao.qi@linaro.org>
5542 * remote-utils.c (new_thread_notify): Remove.
5543 (dead_thread_notify): Likewise.
5544 * remote-utils.h (new_thread_notify): Remove declaration.
5545 (dead_thread_notify): Likewise.
5547 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
5549 * gdb.trace/pending.exp: Fix expected message on continue.
5551 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
5553 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
5554 it works properly on big-endian machines where sizeof (CORE_ADDR)
5557 2016-01-21 Pedro Alves <palves@redhat.com>
5559 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
5560 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
5561 * configure: Regenerate.
5563 2016-01-21 Yao Qi <yao.qi@linaro.org>
5565 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
5566 is_thumb and set it according to CPSR saved on the stack.
5567 (get_next_pcs_syscall_next_pc): Pass is_thumb to
5568 arm_sigreturn_next_pc.
5570 2016-01-18 Yao Qi <yao.qi@linaro.org>
5572 * linux-low.c (linux_set_pc_64bit): New function.
5573 (linux_get_pc_64bit): New function.
5574 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
5576 * linux-sparc-low.c (debug_threads): Remove declaration.
5577 (sparc_get_pc): Remove.
5578 (the_low_target): Use linux_get_pc_64bit instead of
5580 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
5581 (the_low_target): Use linux_get_pc_64bit and
5584 2016-01-18 Yao Qi <yao.qi@linaro.org>
5586 * linux-arm-low.c (debug_threads): Remove declaration.
5587 (arm_get_pc, arm_set_pc): Remove.
5588 (the_low_target): Use linux_get_pc_32bit and
5590 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
5591 (the_low_target): Use linux_get_pc_32bit and
5593 * linux-cris-low.c (debug_threads): Remove declaration.
5594 (cris_get_pc, cris_set_pc,): Remove.
5595 (the_low_target): Use linux_get_pc_32bit and
5597 * linux-crisv32-low.c (debug_threads): Remove declaration.
5598 (cris_get_pc, cris_set_pc): Remove.
5599 (the_low_target): Use linux_get_pc_32bit and
5601 * linux-low.c: Include inttypes.h.
5602 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
5603 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
5604 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
5605 (the_low_target): Use linux_get_pc_32bit and
5607 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
5608 (the_low_target): Use linux_get_pc_32bit and
5610 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
5611 (the_low_target): Use linux_get_pc_32bit and
5613 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
5614 (the_low_target): Use linux_get_pc_32bit and
5616 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
5617 (the_low_target): Use linux_get_pc_32bit and
5620 2016-01-18 Gary Benson <gbenson@redhat.com>
5622 * configure.ac (AC_FUNC_FORK): New check.
5623 * config.in: Regenerate.
5624 * configure: Likewise.
5626 2016-01-14 Yao Qi <yao.qi@linaro.org>
5628 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
5629 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
5630 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
5631 arm_get_next_pcs_ctor.
5633 2016-01-12 Josh Stone <jistone@redhat.com>
5634 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5636 * inferiors.h: Include "gdb_vecs.h".
5637 (struct process_info): Add syscalls_to_catch.
5638 * inferiors.c (remove_process): Free syscalls_to_catch.
5639 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
5640 syscall_return stops.
5641 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
5642 * server.c (handle_general_set): Handle QCatchSyscalls.
5643 (handle_query): Report support for QCatchSyscalls.
5644 * target.h (struct target_ops): Add supports_catch_syscall.
5645 (target_supports_catch_syscall): New macro.
5646 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
5647 (struct lwp_info): Add syscall_state.
5648 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
5649 Maintain syscall_state and syscalls_to_catch across exec.
5650 (get_syscall_trapinfo): New function, proxy to the_low_target.
5651 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
5652 (linux_low_filter_event): Toggle syscall_state entry/return for
5653 syscall traps, and set it ignored for all others.
5654 (gdb_catching_syscalls_p): New function.
5655 (gdb_catch_this_syscall_p): New function.
5656 (linux_wait_1): Handle SYSCALL_SIGTRAP.
5657 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
5658 (linux_supports_catch_syscall): New function.
5659 (linux_target_ops): Install it.
5660 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
5661 (the_low_target): Install it.
5663 2016-01-12 Mike Frysinger <vapier@gentoo.org>
5665 * acinclude.m4: Include new ../warning.m4 file.
5666 * configure: Regenerated.
5667 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
5669 2016-01-12 Mike Frysinger <vapier@gentoo.org>
5671 * ax.c (is_goto_target): Mark static.
5672 * linux-low.c (register_addr): Likewise.
5673 (linux_fetch_registers, linux_store_registers): Likewise.
5674 * mem-break.c (any_persistent_commands): Fix old prototype.
5675 (add_commands_to_breakpoint): Mark static.
5676 * regcache.c (find_register_by_name): Delete unused func.
5677 * remote-utils.c (hex_or_minus_one): Mark static.
5678 * server.c (monitor_show_help): Mark static.
5679 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
5680 handle_v_requests): Likewise.
5682 2016-01-12 Pedro Alves <palves@redhat.com>
5684 Remove use of the registered trademark symbol throughout.
5686 2016-01-08 Yao Qi <yao.qi@linaro.org>
5688 * remote-utils.c (getpkt): If c is '\003', call target hook
5691 2016-01-06 Yao Qi <yao.qi@linaro.org>
5693 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
5694 linux-aarch32-low.c.
5695 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
5696 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
5697 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
5698 (thumb2_breakpoint): Declare.
5699 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
5700 linux-aarch32-low.h.
5701 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
5702 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
5703 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
5705 2016-01-01 Joel Brobecker <brobecker@adacore.com>
5707 * gdbreplay.c (gdbreplay_version): Change copyright year in
5709 * server.c (gdbserver_version): Likewise.
5711 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
5713 * server.c (crc32_table): Delete.
5714 (crc32): Use libiberty's xcrc32 function.
5716 2015-12-22 Joel Brobecker <brobecker@adacore.com>
5718 * lynx-low.c (lynx_delete_thread_callback): New function.
5719 (lynx_mourn): Properly delete our process and all of its
5720 threads. Remove call to clear_inferiors.
5722 2015-12-22 Joel Brobecker <brobecker@adacore.com>
5724 * target.c (thread_search_callback): Add check that
5725 the thread_stopped target callback is not NULL before
5728 2015-12-21 Yao Qi <yao.qi@linaro.org>
5730 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
5733 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
5735 * server.c (handle_query): Call target_supports_software_single_step.
5737 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
5739 * linux-low.c (single_step): New function.
5740 (linux_resume_one_lwp_throw): Call single_step.
5741 (start_step_over): Likewise.
5743 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
5745 * Makefile.in (SFILES): Append arch/arm-linux.c,
5746 arch/arm-get-next-pcs.c.
5747 (arm-linux.o): New rule.
5748 (arm-get-next-pcs.o): New rule.
5749 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
5751 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
5752 to linux-aarch32-low.c.
5753 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
5754 (arm_breakpoint_len, thumb_breakpoint): Likewise.
5755 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
5756 (thumb2_breakpoint_len): Likewise.
5757 (arm_is_thumb_mode): Make non-static.
5758 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
5759 from linux-aarch32-low.c.
5760 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
5761 (arm_breakpoint_len, thumb_breakpoint): Likewise.
5762 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
5763 (thumb2_breakpoint_len): Likewise.
5764 (arm_is_thumb_mode): New declaration.
5765 * linux-arm-low.c: Include arch/arm-linux.h
5766 aarch/arm-get-next-pcs.h, sys/syscall.h.
5767 (get_next_pcs_ops): New struct.
5768 (get_next_pcs_addr_bits_remove): New function.
5769 (get_next_pcs_is_thumb): New function.
5770 (get_next_pcs_read_memory_unsigned_integer): Likewise.
5771 (arm_sigreturn_next_pc): Likewise.
5772 (get_next_pcs_syscall_next_pc): Likewise.
5773 (arm_gdbserver_get_next_pcs): Likewise.
5774 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
5776 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
5777 * server.h: Include gdb_vecs.h.
5779 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
5781 * Makefile.in (SFILES): Append common/common-regcache.c.
5782 (OBS): Append common-regcache.o.
5783 (common-regcache.o): New rule.
5784 * regcache.c (init_register_cache): Initialize cache to
5786 (regcache_raw_read_unsigned): New function.
5787 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
5788 register_status enum.
5790 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
5792 * linux-aarch64-low.c (the_low_targets): Rename
5793 breakpoint_reinsert_addr to get_next_pcs.
5794 * linux-arm-low.c (the_low_targets): Likewise.
5795 * linux-bfin-low.c (the_low_targets): Likewise.
5796 * linux-cris-low.c (the_low_targets): Likewise.
5797 * linux-crisv32-low.c (the_low_targets): Likewise.
5798 * linux-low.c (can_software_single_step): Likewise.
5799 (install_software_single_step_breakpoints): New function.
5800 (start_step_over): Use install_software_single_step_breakpoints.
5801 * linux-low.h: New CORE_ADDR vector.
5802 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
5804 * linux-mips-low.c (the_low_targets): Likewise.
5805 * linux-nios2-low.c (the_low_targets): Likewise.
5806 * linux-sparc-low.c (the_low_targets): Likewise.
5808 2015-12-17 Pedro Alves <palves@redhat.com>
5810 * linux-low.c (linux_kill_one_lwp): Remove references to
5812 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
5814 (linux_init_signals): Delete.
5815 (initialize_low): Adjust.
5816 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
5818 2015-12-16 Pedro Alves <palves@redhat.com>
5820 * configure.ac (compiler warning flags): When testing a
5821 -Wno-foo option, check whether -Wfoo works instead.
5822 * configure: Regenerate.
5824 2015-12-11 Don Breazeal <donb@codesourcery.com>
5826 * server.c (process_serial_event): Don't exit from gdbserver
5827 in remote mode if there are still active inferiors.
5829 2015-12-11 Yao Qi <yao.qi@linaro.org>
5831 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
5832 arm_breakpoint_at if the process is 32-bit.
5834 2015-12-11 Yao Qi <yao.qi@linaro.org>
5836 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
5839 2015-12-07 Yao Qi <yao.qi@linaro.org>
5841 * configure.srv: Append arm.o to srv_tgtobj for
5842 aarch64*-*-linux* target.
5843 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
5844 from linux-arm-low.c.
5845 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
5846 (arm_breakpoint_len, thumb_breakpoint): Likewise.
5847 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
5848 (thumb2_breakpoint_len): Likewise.
5849 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
5850 (arm_breakpoint_kinds): Likewise.
5851 (arm_breakpoint_kind_from_pc): Likewise.
5852 (arm_sw_breakpoint_from_kind): Likewise.
5853 (arm_breakpoint_kind_from_current_state): Likewise.
5854 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
5855 (arm_sw_breakpoint_from_kind): Declare.
5856 (arm_breakpoint_kind_from_current_state): Declare.
5857 (arm_breakpoint_at): Declare.
5858 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
5859 arm_sw_breakpoint_from_kind if process is 32-bit.
5860 (aarch64_breakpoint_kind_from_pc): New function.
5861 (aarch64_breakpoint_kind_from_current_state): New function.
5862 (the_low_target): Initialize fields breakpoint_kind_from_pc
5863 and breakpoint_kind_from_current_state.
5864 * linux-arm-low.c (arm_breakpoint_kinds): Move to
5865 linux-aarch32-low.c.
5866 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
5867 (arm_breakpoint, arm_breakpoint_len): Likewise.
5868 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
5869 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
5870 (arm_is_thumb_mode): Likewise.
5871 (arm_breakpoint_at): Likewise.
5872 (arm_breakpoint_kind_from_pc): Likewise.
5873 (arm_sw_breakpoint_from_kind): Likewise.
5874 (arm_breakpoint_kind_from_current_state): Likewise.
5877 2015-08-04 Yao Qi <yao.qi@linaro.org>
5879 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
5880 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
5881 * server.c (extended_protocol): Remove "static".
5882 * server.h (extended_protocol): Declare it.
5884 2015-12-04 Josh Stone <jistone@redhat.com>
5886 * target.h (struct target_ops) <arch_setup>: Rename to ...
5887 (struct target_ops) <post_create_inferior>: ... this.
5888 (target_arch_setup): Rename to ...
5889 (target_post_create_inferior): ... this, calling post_create_inferior.
5890 * server.c (start_inferior): Update target_arch_setup calls to
5891 target_post_create_inferior.
5892 * linux-low.c (linux_low_ptrace_options): Forward declare.
5893 (linux_arch_setup): Update its comment for general use.
5894 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
5895 (struct linux_target_ops): Use linux_post_create_inferior.
5896 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
5897 to post_create_inferior.
5898 * nto-low.c (struct nto_target_ops): Likewise.
5899 * spu-low.c (struct spu_target_ops): Likewise.
5900 * win32-low.c (struct win32_target_ops): Likewise.
5902 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
5904 * linux-arm-low.c: Remove duplicate arch/arm.h include.
5906 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
5908 * linux-arm-low.c (arm_reinsert_addr): Remove function.
5909 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
5910 * linux-cris-low.c (cris_reinsert_addr> Remove function.
5911 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
5912 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
5913 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
5914 * linux-mips-low.c (mips_reinsert_addr): Remove function.
5915 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
5916 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
5917 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
5918 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
5919 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
5921 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
5923 * linux-low.c (linux_look_up_symbols): Don't call
5924 linux_supports_traceclone.
5925 * linux-low.h (thread_db_init): Remove use_events argument.
5926 * thread-db.c (thread_db_use_event): Remove global variable.
5927 (struct thread_db) <td_thr_event_enable_p>: Remove field.
5928 (struct thread_db) <td_create_bp>: Remove field.
5929 (thread_db_create_event): Remove function.
5930 (thread_db_enable_reporting): Likewise.
5931 (find_one_thread): Don't check for thread_db_use_events.
5932 (attach_thread): Likewise.
5933 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
5934 (try_thread_db_load_1): Don't check for thread_db_use_events.
5935 (thread_db_init): Remove use_events argument and thread events
5937 (remove_thread_event_breakpoints): Remove function.
5938 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
5940 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
5942 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
5944 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
5945 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
5946 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
5947 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
5948 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
5950 * linux-crisv32-low.c (cris_supports_hardware_single_step):
5952 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
5953 * linux-low.c (can_hardware_single_step): Use
5954 supports_hardware_single_step.
5955 (can_software_single_step): New function.
5956 (start_step_over): Call can_software_single_step.
5957 (linux_supports_hardware_single_step): New function.
5958 (struct target_ops) <supports_software_single_step>: Initialize.
5959 * linux-low.h (struct linux_target_ops)
5960 <supports_hardware_single_step>: Initialize.
5961 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
5962 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
5963 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
5964 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
5965 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
5966 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
5967 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
5968 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
5969 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
5970 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
5972 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
5973 (struct linux_target_ops) <tile_supports_hardware_single_step>:
5975 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
5976 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
5977 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
5979 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
5980 * target.h (struct target_ops): <supports_software_single_step>:
5982 (target_supports_software_single_step): New macro.
5984 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
5986 * linux-low.c (linux_wait_1): Fix pc advance condition.
5987 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
5988 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
5990 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
5992 * linux-arm-low.c (arm_is_thumb_mode): New function.
5993 (arm_breakpoint_at): Use arm_is_thumb_mode.
5994 (arm_breakpoint_kind_from_current_state): New function.
5995 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
5997 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
5998 (linux_breakpoint_kind_from_current_state): New function.
5999 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
6000 * linux-low.h (struct linux_target_ops)
6001 <breakpoint_kind_from_current_state>: New field.
6002 * target.h (struct target_ops): Likewise.
6003 (target_breakpoint_kind_from_current_state): New macro.
6005 2015-11-30 Pedro Alves <palves@redhat.com>
6007 * linux-low.c (linux_resume): Wake up the event loop before
6010 2015-11-30 Pedro Alves <palves@redhat.com>
6012 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
6014 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
6016 * target.c (struct thread_search): New structure.
6017 (thread_search_callback): New function.
6018 (prev_general_thread): New global.
6019 (prepare_to_access_memory, done_accessing_memory): New functions.
6020 * target.h (prepare_to_access_memory, done_accessing_memory):
6021 Replace macros with function declarations.
6023 2015-11-30 Pedro Alves <palves@redhat.com>
6026 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
6027 report TARGET_WAITKIND_NO_RESUMED.
6028 * remote-utils.c (prepare_resume_reply): Handle
6029 TARGET_WAITKIND_NO_RESUMED.
6030 * server.c (report_no_resumed): New global.
6031 (handle_query) <qSupported>: Handle "no-resumed+". Report
6032 "no-resumed+" support.
6033 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
6034 return error if the client doesn't support no-resumed events.
6035 (push_stop_notification): New function.
6036 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
6037 events if the client supports them.
6039 2015-11-30 Pedro Alves <palves@redhat.com>
6041 * linux-low.c (thread_still_has_status_pending_p): Don't check
6043 (lwp_resumed): New function.
6044 (status_pending_p_callback): Return early if the LWP is not
6045 supposed to be resumed.
6047 2015-11-30 Pedro Alves <palves@redhat.com>
6049 * linux-low.c (handle_extended_wait): Assert that the LWP's
6050 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
6051 thread create events, leave the new child's status pending.
6052 (linux_low_filter_event): If GDB wants to hear about thread exit
6053 events, leave the LWP marked dead and don't delete it.
6054 (linux_wait_for_event_filtered): Don't check for thread exit.
6055 (filter_exit_event): New function.
6056 (linux_wait_1): Use it, when returning an exit event.
6057 (linux_resume_one_lwp_throw): Assert that the LWP's
6058 waitstatus is TARGET_WAITKIND_IGNORE.
6059 * remote-utils.c (prepare_resume_reply): Handle
6060 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
6061 * server.c (report_thread_events): New global.
6062 (handle_general_set): Handle QThreadEvents.
6063 (handle_query) <qSupported>: Handle and report QThreadEvents+;
6064 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
6065 TARGET_WAITKIND_THREAD_EXITED.
6066 * server.h (report_thread_events): Declare.
6068 2015-11-30 Pedro Alves <palves@redhat.com>
6070 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
6071 the thread's last_resume_kind was resume_stop.
6073 2015-11-30 Pedro Alves <palves@redhat.com>
6075 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
6078 2015-11-30 Pedro Alves <palves@redhat.com>
6080 * server.c (handle_v_requests): Handle vCtrlC.
6082 2015-11-30 Pedro Alves <palves@redhat.com>
6084 * gdbthread.h (find_any_thread_of_pid): Declare.
6085 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
6087 * server.c (handle_query): If current_thread is NULL, look for
6088 another thread of the selected process.
6090 2015-11-26 Daniel Colascione <dancol@dancol.org>
6091 Simon Marchi <simon.marchi@ericsson.com>
6093 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
6094 * server.c (handle_qxfer_threads_worker): Refactor to include thread
6096 * target.h (struct target_ops) <thread_name>: New field.
6097 (target_thread_name): New macro.
6099 2015-11-23 Joel Brobecker <brobecker@adacore.com>
6101 * regcache.h (regcache_invalidate_pid): Add declaration.
6102 * regcache.c (regcache_invalidate_pid): New function, extracted
6103 from regcache_invalidate.
6104 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
6105 Add trivial documentation comment.
6106 * lynx-low.c: Use regcache_invalidate_pid instead of
6107 regcache_invalidate.
6109 2015-11-23 Joel Brobecker <brobecker@adacore.com>
6111 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
6112 and Elf64_auxv_t if the target is Android.
6114 2015-11-22 Doug Evans <xdje42@gmail.com>
6116 * target.h: #include <sys/types.h>.
6118 2015-11-19 Pedro Alves <palves@redhat.com>
6120 * linux-low.c (linux_process_qsupported): Change prototype.
6122 * linux-low.h (struct linux_target_ops) <process_qsupported>:
6124 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
6125 and adjust to loop over all features.
6126 * server.c (handle_query) <qSupported>: Adjust to call
6127 target_process_qsupported once, passing it a vector of unprocessed
6129 * target.h (struct target_ops) <process_qsupported>: Change
6131 (target_process_qsupported): Adjust.
6133 2015-11-19 Pedro Alves <palves@redhat.com>
6135 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
6137 * configure: Regenerate.
6139 2015-11-19 Pedro Alves <palves@redhat.com>
6141 * configure: Regenerate.
6143 2015-11-19 Yao Qi <yao.qi@linaro.org>
6145 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
6148 2015-11-19 Yao Qi <yao.qi@linaro.org>
6150 * linux-aarch64-low.c (enum aarch64_operand_type): New.
6151 (struct aarch64_operand): Move enum out.
6153 2015-11-19 Yao Qi <yao.qi@linaro.org>
6155 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
6156 struct user_fpsimd_state *.
6157 (aarch64_store_fpregset): Likewise.
6159 2015-11-19 Yao Qi <yao.qi@linaro.org>
6161 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
6162 struct user_pt_regs *.
6163 (aarch64_store_gregset): Likewise.
6165 2015-11-18 Pedro Alves <palves@redhat.com>
6167 * Makefile.in (all_object_files): Add $IPA_OBJS.
6169 2015-11-17 Pedro Alves <palves@redhat.com>
6171 * win32-low.c (win32_resume): Use gdb_signal_from_host,
6172 GDB_SIGNAL_0 and gdb_signal_to_string.
6174 2015-11-17 Pedro Alves <palves@redhat.com>
6176 * win32-low.c (handle_output_debug_string): Remove parameter.
6177 (win32_kill): Remove our_status local and adjust call to
6178 handle_output_debug_string.
6179 (get_child_debug_event): Adjust call to
6180 handle_output_debug_string.
6182 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6184 * linux-mips-low.c (mips_fill_gregset): Add cast.
6185 (mips_store_gregset): Likewise.
6186 (mips_fill_fpregset): Likewise.
6187 (mips_store_fpregset): Likewise.
6189 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6191 * linux-mips-low.c (mips_add_watchpoint): Rename private to
6194 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6196 * linux-mips-low.c (mips_linux_new_thread): Change type of
6197 watch_type to enum target_hw_bp_type.
6199 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6201 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
6202 Change return type to arm_hwbp_type.
6204 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6206 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
6207 (arm_store_gregset): Likewise.
6208 * linux-arm-low.c (arm_get_hwcap): Likewise.
6209 (arm_read_description): Likewise.
6211 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6213 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
6215 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6217 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
6218 (ppc_fill_vsxregset): Likewise.
6219 (ppc_store_vsxregset): Likewise.
6220 (ppc_fill_vrregset): Likewise.
6221 (ppc_store_vrregset): Likewise.
6222 (ppc_fill_evrregset): Likewise.
6223 (ppc_store_evrregset): Likewise.
6225 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
6227 * linux-ppc-low.c (ppc_usrregs_info): Remove
6228 forward-declaration.
6229 (ppc_arch_setup): Move lower in file.
6231 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
6233 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
6234 (ps_pdwrite): Likewise.
6236 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
6238 * linux-arm-low.c (arm_new_thread): Move pointer dereference
6239 to after assert checks.
6241 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
6243 * proc-service.c (ps_pdread): Add/adjust casts.
6244 (ps_pdwrite): Add/adjust casts.
6246 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
6248 * server.c (handle_search_memory_1): Cast return value of
6251 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
6253 * server.c (write_qxfer_response): Change type of data to
6256 2015-10-29 Pedro Alves <palves@redhat.com>
6258 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
6260 2015-10-29 Pedro Alves <palves@redhat.com>
6262 * tracepoint.c (clear_installed_tracepoints): Add casts.
6264 2015-10-29 Pedro Alves <palves@redhat.com>
6266 * server.c (handle_v_cont, process_serial_event): Add enum
6267 gdb_signal casts to signal parsing code.
6269 2015-10-29 Pedro Alves <palves@redhat.com>
6271 * linux-low.h (NULL_REGSET): Define.
6272 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
6273 * linux-arm-low.c (arm_regsets): Likewise.
6274 * linux-crisv32-low.c (cris_regsets): Likewise.
6275 * linux-m68k-low.c (m68k_regsets): Likewise.
6276 * linux-mips-low.c (mips_regsets): Likewise.
6277 * linux-nios2-low.c (nios2_regsets): Likewise.
6278 * linux-ppc-low.c (ppc_regsets): Likewise.
6279 * linux-s390-low.c (s390_regsets): Likewise.
6280 * linux-sh-low.c (sh_regsets): Likewise.
6281 * linux-sparc-low.c (sparc_regsets): Likewise.
6282 * linux-tic6x-low.c (tic6x_regsets): Likewise.
6283 * linux-tile-low.c (tile_regsets): Likewise.
6284 * linux-x86-low.c (x86_regsets): Likewise.
6285 * linux-xtensa-low.c (xtensa_regsets): Likewise.
6287 2015-10-29 Pedro Alves <palves@redhat.com>
6289 * linux-low.h (NULL_REGSET): Define.
6290 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
6291 * linux-arm-low.c (arm_regsets): Likewise.
6292 * linux-crisv32-low.c (cris_regsets): Likewise.
6293 * linux-m68k-low.c (m68k_regsets): Likewise.
6294 * linux-mips-low.c (mips_regsets): Likewise.
6295 * linux-nios2-low.c (nios2_regsets): Likewise.
6296 * linux-ppc-low.c (ppc_regsets): Likewise.
6297 * linux-s390-low.c (s390_regsets): Likewise.
6298 * linux-sh-low.c (sh_regsets): Likewise.
6299 * linux-sparc-low.c (sparc_regsets): Likewise.
6300 * linux-tic6x-low.c (tic6x_regsets): Likewise.
6301 * linux-tile-low.c (tile_regsets): Likewise.
6302 * linux-x86-low.c (x86_regsets): Likewise.
6303 * linux-xtensa-low.c (xtensa_regsets): Likewise.
6305 2015-10-26 Doug Evans <dje@google.com>
6307 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
6309 2015-10-26 Doug Evans <dje@google.com>
6311 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
6313 2015-10-26 Doug Evans <dje@google.com>
6315 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
6317 (attach_thread, find_new_threads_callback): Ditto.
6319 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
6321 * mem-break.h (set_breakpoint_data): Remove.
6323 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
6325 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
6326 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
6327 (initialize_low): Remove set_breakpoint_data call.
6328 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
6329 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
6330 (initialize_low): Remove set_breakpoint_data call.
6331 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
6332 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
6333 (initialize_low): Remove set_breakpoint_data call.
6335 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
6337 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
6338 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
6339 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
6340 * target.h (target_breakpoint_kind_from_pc): New macro.
6342 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
6344 * linux-low.c (default_breakpoint_kind_from_pc): New function.
6345 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
6346 the default breakpoint kind.
6348 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6350 * linux-arm-low.c (arm_supports_z_point_type): Add software
6353 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6355 * linux-arm-low.c: Refactor breakpoint definitions.
6356 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
6357 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
6359 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6361 * Makefile.in: Add arm.c/o.
6362 * configure.srv: Likewise.
6363 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
6364 (arm_breakpoint_kind_from_pc): New function.
6365 (arm_sw_breakpoint_from_kind): Return proper kind.
6366 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
6368 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6370 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
6372 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
6373 (struct raw_breakpoint) <size>: Remove.
6374 (struct raw_breakpoint) <kind>: Add.
6375 (bp_size): New function.
6376 (bp_opcode): Likewise.
6377 (find_raw_breakpoint_at): Adjust for kind.
6378 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
6379 (remove_memory_breakpoint): Adjust for kind call bp_size.
6380 (set_raw_breakpoint_at): Adjust for kind.
6381 (set_breakpoint): Likewise.
6382 (set_breakpoint_at): Call breakpoint_kind_from_pc.
6383 (delete_raw_breakpoint): Adjust for kind.
6384 (delete_breakpoint): Likewise.
6385 (find_gdb_breakpoint): Likewise.
6386 (set_gdb_breakpoint_1): Likewise.
6387 (set_gdb_breakpoint): Likewise.
6388 (delete_gdb_breakpoint_1): Likewise.
6389 (delete_gdb_breakpoint): Likewise.
6390 (uninsert_raw_breakpoint): Likewise.
6391 (reinsert_raw_breakpoint): Likewise.
6392 (set_breakpoint_data): Remove.
6393 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
6394 (check_mem_read): Adjust for kind call bp_size.
6395 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
6396 (clone_one_breakpoint): Adjust for kind.
6397 * mem-break.h (set_gdb_breakpoint): Likewise.
6398 (delete_gdb_breakpoint): Likewise.
6399 * server.c (process_serial_event): Likewise.
6401 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6403 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
6404 (struct linux_target_ops) <breakpoint>: Remove.
6405 (struct linux_target_ops) <breakpoint_len>: Remove.
6406 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6407 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6408 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
6409 (arm_sw_breakpoint_from_kind): New function.
6410 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
6411 (struct linux_target_ops) <breakpoint>: Remove.
6412 (struct linux_target_ops) <breakpoint_len>: Remove.
6413 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6414 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6415 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
6416 (struct linux_target_ops) <breakpoint>: Remove.
6417 (struct linux_target_ops) <breakpoint_len>: Remove.
6418 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6419 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6420 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
6421 (struct linux_target_ops) <breakpoint>: Remove.
6422 (struct linux_target_ops) <breakpoint_len>: Remove.
6423 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6424 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6425 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
6426 and sw_breakpoint_from_kind to increment the pc.
6427 (linux_breakpoint_kind_from_pc): New function.
6428 (linux_sw_breakpoint_from_kind): New function.
6429 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
6430 (initialize_low): Call breakpoint_kind_from_pc and
6431 sw_breakpoint_from_kind to replace breakpoint_data/len.
6432 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
6434 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
6435 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
6436 (struct linux_target_ops) <breakpoint>: Remove.
6437 (struct linux_target_ops) <breakpoint_len>: Remove.
6438 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6439 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6440 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
6441 (struct linux_target_ops) <breakpoint>: Remove.
6442 (struct linux_target_ops) <breakpoint_len>: Remove.
6443 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6444 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6445 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
6446 (struct linux_target_ops) <breakpoint>: Remove.
6447 (struct linux_target_ops) <breakpoint_len>: Remove.
6448 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6449 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6450 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
6451 (struct linux_target_ops) <breakpoint>: Remove.
6452 (struct linux_target_ops) <breakpoint_len>: Remove.
6453 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6454 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6455 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
6456 (struct linux_target_ops) <breakpoint>: Remove.
6457 (struct linux_target_ops) <breakpoint_len>: Remove.
6458 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6459 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6460 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
6461 (struct linux_target_ops) <breakpoint>: Remove.
6462 (struct linux_target_ops) <breakpoint_len>: Remove.
6463 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6464 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6465 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
6466 (struct linux_target_ops) <breakpoint>: Remove.
6467 (struct linux_target_ops) <breakpoint_len>: Remove.
6468 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6469 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6470 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
6471 (struct linux_target_ops) <breakpoint>: Remove.
6472 (struct linux_target_ops) <breakpoint_len>: Remove.
6473 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6474 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6475 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
6476 (struct linux_target_ops) <breakpoint>: Remove.
6477 (struct linux_target_ops) <breakpoint_len>: Remove.
6478 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6479 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6480 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
6481 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
6482 (struct linux_target_ops) <breakpoint>: Remove.
6483 (struct linux_target_ops) <breakpoint_len>: Remove.
6484 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6485 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6486 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
6487 (struct linux_target_ops) <breakpoint>: Remove.
6488 (struct linux_target_ops) <breakpoint_len>: Remove.
6489 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
6490 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
6492 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
6494 * linux-cris-low.c (cris_get_pc): Remove void arg.
6496 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
6498 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
6501 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
6503 * inferiors.c (thread_pid_matches_callback): New function.
6504 (find_thread_process): New function.
6505 (remove_thread): Reset current_thread.
6506 (remove_process): Assert threads have been removed first.
6508 2015-10-15 Yao Qi <yao.qi@linaro.org>
6510 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
6512 (aarch64_remove_point): Likewise.
6513 * regcache.c (regcache_register_size): New function.
6515 2015-10-12 Yao Qi <yao.qi@linaro.org>
6517 * linux-aarch64-low.c: Update all callers as emit_load_store
6518 is renamed to aarch64_emit_load_store.
6520 2015-10-12 Yao Qi <yao.qi@linaro.org>
6522 * linux-aarch64-low.c: Update all callers of function renaming
6523 from emit_insn to aarch64_emit_insn.
6525 2015-10-12 Yao Qi <yao.qi@linaro.org>
6527 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
6528 arch/aarch64-insn.h.
6529 (struct aarch64_memory_operand): Likewise.
6531 (emit_insn): Move to arch/aarch64-insn.c.
6532 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
6533 (emit_load_store): Move to arch/aarch64-insn.c.
6534 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
6535 (can_encode_int32): Remove.
6537 2015-10-12 Yao Qi <yao.qi@linaro.org>
6539 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
6540 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
6541 (aarch64_relocate_instruction): Likewise.
6542 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
6543 (struct aarch64_insn_visitor): Likewise.
6545 2015-10-12 Yao Qi <yao.qi@linaro.org>
6547 * linux-aarch64-low.c (struct aarch64_insn_data): New.
6548 (struct aarch64_insn_visitor): New.
6549 (struct aarch64_insn_relocation_data): New.
6550 (aarch64_ftrace_insn_reloc_b): New function.
6551 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
6552 (aarch64_ftrace_insn_reloc_cb): Likewise.
6553 (aarch64_ftrace_insn_reloc_tb): Likewise.
6554 (aarch64_ftrace_insn_reloc_adr): Likewise.
6555 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
6556 (aarch64_ftrace_insn_reloc_others): Likewise.
6558 (aarch64_relocate_instruction): Use visitor.
6560 2015-10-12 Yao Qi <yao.qi@linaro.org>
6562 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
6563 int. Add argument buf.
6564 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
6565 aarch64_relocate_instruction.
6567 2015-10-12 Yao Qi <yao.qi@linaro.org>
6569 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
6570 argument insn. Remove local variable insn. Don't call
6572 (aarch64_install_fast_tracepoint_jump_pad): Call
6575 2015-09-30 Yao Qi <yao.qi@linaro.org>
6577 * linux-aarch64-low.c (emit_movk): Shorten a long line.
6578 (emit_load_store_pair): Likewise.
6580 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
6582 * dll.c (match_dll): Add cast(s).
6583 (unloaded_dll): Likewise.
6584 * linux-low.c (second_thread_of_pid_p): Likewise.
6585 (delete_lwp_callback): Likewise.
6586 (count_events_callback): Likewise.
6587 (select_event_lwp_callback): Likewise.
6588 (linux_set_resume_request): Likewise.
6589 * server.c (accumulate_file_name_length): Likewise.
6590 (emit_dll_description): Likewise.
6591 (handle_qxfer_threads_worker): Likewise.
6592 (visit_actioned_threads): Likewise.
6593 * thread-db.c (any_thread_of): Likewise.
6594 * tracepoint.c (same_process_p): Likewise.
6595 (match_blocktype): Likewise.
6596 (build_traceframe_info_xml): Likewise.
6598 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
6600 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
6602 (gdb_unparse_agent_expr): Likewise.
6603 * hostio.c (require_data): Likewise.
6604 (handle_pread): Likewise.
6605 * linux-low.c (disable_regset): Likewise.
6606 (fetch_register): Likewise.
6607 (store_register): Likewise.
6608 (get_dynamic): Likewise.
6609 (linux_qxfer_libraries_svr4): Likewise.
6610 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
6611 (set_fast_tracepoint_jump): Likewise.
6612 (uninsert_fast_tracepoint_jumps_at): Likewise.
6613 (reinsert_fast_tracepoint_jumps_at): Likewise.
6614 (validate_inserted_breakpoint): Likewise.
6615 (clone_agent_expr): Likewise.
6616 * regcache.c (init_register_cache): Likewise.
6617 * remote-utils.c (putpkt_binary_1): Likewise.
6618 (decode_M_packet): Likewise.
6619 (decode_X_packet): Likewise.
6620 (look_up_one_symbol): Likewise.
6621 (relocate_instruction): Likewise.
6622 (monitor_output): Likewise.
6623 * server.c (handle_search_memory): Likewise.
6624 (handle_qxfer_exec_file): Likewise.
6625 (handle_qxfer_libraries): Likewise.
6626 (handle_qxfer): Likewise.
6627 (handle_query): Likewise.
6628 (handle_v_cont): Likewise.
6629 (handle_v_run): Likewise.
6630 (captured_main): Likewise.
6631 * target.c (write_inferior_memory): Likewise.
6632 * thread-db.c (try_thread_db_load_from_dir): Likewise.
6633 * tracepoint.c (init_trace_buffer): Likewise.
6634 (add_tracepoint_action): Likewise.
6635 (add_traceframe): Likewise.
6636 (add_traceframe_block): Likewise.
6637 (cmd_qtdpsrc): Likewise.
6638 (cmd_qtdv): Likewise.
6639 (cmd_qtstatus): Likewise.
6640 (response_source): Likewise.
6641 (response_tsv): Likewise.
6642 (cmd_qtnotes): Likewise.
6643 (gdb_collect): Likewise.
6644 (initialize_tracepoint): Likewise.
6646 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
6648 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
6649 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
6650 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
6652 (enum aarch64_condition_codes): New enum.
6653 (w0): New static global.
6656 (struct aarch64_memory_operand) <type>: New
6657 MEMORY_OPERAND_POSTINDEX type.
6658 (postindex_memory_operand): New helper function.
6659 (emit_ret): New function.
6660 (emit_load_store_pair): New function, factored out of emit_stp
6661 with support for MEMORY_OPERAND_POSTINDEX.
6662 (emit_stp): Rewrite using emit_load_store_pair.
6663 (emit_ldp): New function.
6664 (emit_load_store): Likewise.
6665 (emit_ldr): Mention post-index instruction in comment.
6666 (emit_ldrh): New function.
6667 (emit_ldrb): New function.
6668 (emit_ldrsw): Mention post-index instruction in comment.
6669 (emit_str): Likewise.
6670 (emit_subs): New function.
6671 (emit_cmp): Likewise.
6672 (emit_and): Likewise.
6673 (emit_orr): Likewise.
6674 (emit_orn): Likewise.
6675 (emit_eor): Likewise.
6676 (emit_mvn): Likewise.
6677 (emit_lslv): Likewise.
6678 (emit_lsrv): Likewise.
6679 (emit_asrv): Likewise.
6680 (emit_mul): Likewise.
6681 (emit_sbfm): Likewise.
6682 (emit_sbfx): Likewise.
6683 (emit_ubfm): Likewise.
6684 (emit_ubfx): Likewise.
6685 (emit_csinc): Likewise.
6686 (emit_cset): Likewise.
6687 (emit_nop): Likewise.
6688 (emit_ops_insns): New helper function.
6689 (emit_pop): Likewise.
6690 (emit_push): Likewise.
6691 (aarch64_emit_prologue): New function.
6692 (aarch64_emit_epilogue): Likewise.
6693 (aarch64_emit_add): Likewise.
6694 (aarch64_emit_sub): Likewise.
6695 (aarch64_emit_mul): Likewise.
6696 (aarch64_emit_lsh): Likewise.
6697 (aarch64_emit_rsh_signed): Likewise.
6698 (aarch64_emit_rsh_unsigned): Likewise.
6699 (aarch64_emit_ext): Likewise.
6700 (aarch64_emit_log_not): Likewise.
6701 (aarch64_emit_bit_and): Likewise.
6702 (aarch64_emit_bit_or): Likewise.
6703 (aarch64_emit_bit_xor): Likewise.
6704 (aarch64_emit_bit_not): Likewise.
6705 (aarch64_emit_equal): Likewise.
6706 (aarch64_emit_less_signed): Likewise.
6707 (aarch64_emit_less_unsigned): Likewise.
6708 (aarch64_emit_ref): Likewise.
6709 (aarch64_emit_if_goto): Likewise.
6710 (aarch64_emit_goto): Likewise.
6711 (aarch64_write_goto_address): Likewise.
6712 (aarch64_emit_const): Likewise.
6713 (aarch64_emit_call): Likewise.
6714 (aarch64_emit_reg): Likewise.
6715 (aarch64_emit_pop): Likewise.
6716 (aarch64_emit_stack_flush): Likewise.
6717 (aarch64_emit_zero_ext): Likewise.
6718 (aarch64_emit_swap): Likewise.
6719 (aarch64_emit_stack_adjust): Likewise.
6720 (aarch64_emit_int_call_1): Likewise.
6721 (aarch64_emit_void_call_2): Likewise.
6722 (aarch64_emit_eq_goto): Likewise.
6723 (aarch64_emit_ne_goto): Likewise.
6724 (aarch64_emit_lt_goto): Likewise.
6725 (aarch64_emit_le_goto): Likewise.
6726 (aarch64_emit_gt_goto): Likewise.
6727 (aarch64_emit_ge_got): Likewise.
6728 (aarch64_emit_ops_impl): New static global variable.
6729 (aarch64_emit_ops): New target function, return
6730 &aarch64_emit_ops_impl.
6731 (struct linux_target_ops): Install it.
6733 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
6735 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
6736 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
6738 * linux-aarch64-ipa.c: New file.
6739 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
6741 (aarch64_get_thread_area): New target method.
6742 (extract_signed_bitfield): New helper function.
6743 (aarch64_decode_ldr_literal): New function.
6744 (enum aarch64_opcodes): New enum.
6745 (struct aarch64_register): New struct.
6746 (struct aarch64_operand): New struct.
6747 (x0): New static global.
6756 (aarch64_register): New helper function.
6757 (register_operand): Likewise.
6758 (immediate_operand): Likewise.
6759 (struct aarch64_memory_operand): New struct.
6760 (offset_memory_operand): New helper function.
6761 (preindex_memory_operand): Likewise.
6762 (enum aarch64_system_control_registers): New enum.
6763 (ENCODE): New macro.
6764 (emit_insn): New helper function.
6765 (emit_b): New function.
6766 (emit_bcond): Likewise.
6767 (emit_cb): Likewise.
6768 (emit_tb): Likewise.
6769 (emit_blr): Likewise.
6770 (emit_stp): Likewise.
6771 (emit_ldp_q_offset): Likewise.
6772 (emit_stp_q_offset): Likewise.
6773 (emit_load_store): Likewise.
6774 (emit_ldr): Likewise.
6775 (emit_ldrsw): Likewise.
6776 (emit_str): Likewise.
6777 (emit_ldaxr): Likewise.
6778 (emit_stxr): Likewise.
6779 (emit_stlr): Likewise.
6780 (emit_data_processing_reg): Likewise.
6781 (emit_data_processing): Likewise.
6782 (emit_add): Likewise.
6783 (emit_sub): Likewise.
6784 (emit_mov): Likewise.
6785 (emit_movk): Likewise.
6786 (emit_mov_addr): Likewise.
6787 (emit_mrs): Likewise.
6788 (emit_msr): Likewise.
6789 (emit_sevl): Likewise.
6790 (emit_wfe): Likewise.
6791 (append_insns): Likewise.
6792 (can_encode_int32_in): New helper function.
6793 (aarch64_relocate_instruction): New function.
6794 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
6795 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
6796 (struct linux_target_ops): Install aarch64_get_thread_area,
6797 aarch64_install_fast_tracepoint_jump_pad and
6798 aarch64_get_min_fast_tracepoint_insn_len.
6800 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
6802 * Makefile.in (aarch64-insn.o): New rule.
6803 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
6805 2015-09-21 Yao Qi <yao.qi@linaro.org>
6807 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
6809 2015-09-21 Yao Qi <yao.qi@linaro.org>
6811 * tracepoint.c (max_jump_pad_size): Remove.
6813 2015-09-18 Yao Qi <yao.qi@linaro.org>
6815 * linux-aarch64-low.c: Don't include sys/uio.h.
6816 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
6818 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
6820 * tracepoint.c (eval_result_type): Change prototype.
6821 (condition_true_at_tracepoint): Fix argument to compiled_cond.
6823 2015-09-15 Pedro Alves <palves@redhat.com>
6825 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
6826 Check whether to report exec events instead of checking whether
6827 multiprocess is enabled.
6829 2015-09-15 Pedro Alves <palves@redhat.com>
6832 * remote-utils.c (prepare_resume_reply): Merge
6833 TARGET_WAITKIND_VFORK_DONE switch case with the
6834 TARGET_WAITKIND_FORKED case.
6836 2015-09-15 Yao Qi <yao.qi@linaro.org>
6838 * server.c (handle_query): Check string comparison using
6839 "else if" instead of "if".
6841 2015-09-15 Yao Qi <yao.qi@linaro.org>
6843 * server.c (vCont_supported): New global variable.
6844 (handle_query): Set vCont_supported to 1 if "vContSupported+"
6845 matches. Append ";vContSupported+" to own_buf.
6846 (handle_v_requests): Append ";s;S" to own_buf if target supports
6847 hardware single step or vCont_supported is false.
6848 (capture_main): Set vCont_supported to zero.
6850 2015-09-15 Yao Qi <yao.qi@linaro.org>
6852 * linux-low.c (linux_supports_conditional_breakpoints): Rename
6854 (linux_supports_hardware_single_step): ... New function.
6855 (linux_target_ops): Update.
6856 * lynx-low.c (lynx_target_ops): Set field
6857 supports_hardware_single_step to target_can_do_hardware_single_step.
6858 * nto-low.c (nto_target_ops): Likewise.
6859 * spu-low.c (spu_target_ops): Likewise.
6860 * win32-low.c (win32_target_ops): Likewise.
6861 * target.c (target_can_do_hardware_single_step): New function.
6862 * target.h (struct target_ops) <supports_conditional_breakpoints>:
6863 Remove. <supports_hardware_single_step>: New field.
6864 (target_supports_conditional_breakpoints): Remove.
6865 (target_supports_hardware_single_step): New macro.
6866 (target_can_do_hardware_single_step): Declare.
6867 * server.c (handle_query): Use target_supports_hardware_single_step
6868 instead of target_supports_conditional_breakpoints.
6870 2015-09-15 Yao Qi <yao.qi@linaro.org>
6872 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
6874 (struct linux_target_ops the_low_target): Install
6875 aarch64_linux_siginfo_fixup.
6877 2015-09-11 Don Breazeal <donb@codesourcery.com>
6878 Luis Machado <lgustavo@codesourcery.com>
6880 * linux-low.c (linux_mourn): Static declaration.
6881 (linux_arch_setup): Move in front of
6882 handle_extended_wait.
6883 (linux_arch_setup_thread): New function.
6884 (handle_extended_wait): Handle exec events. Call
6885 linux_arch_setup_thread. Make event_lwp argument a
6886 pointer-to-a-pointer.
6887 (check_zombie_leaders): Do not check stopped threads.
6888 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
6889 (linux_low_filter_event): Add lwp and thread for exec'ing
6890 non-leader thread if leader thread has been deleted.
6891 Refactor code into linux_arch_setup_thread and call it.
6892 Pass child lwp pointer by reference to handle_extended_wait.
6893 (linux_wait_for_event_filtered): Update comment.
6894 (linux_wait_1): Prevent clobbering exec event status.
6895 (linux_supports_exec_events): New function.
6896 (linux_target_ops) <supports_exec_events>: Initialize new member.
6897 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
6899 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
6900 * server.c (report_exec_events): New global variable.
6901 (handle_query): Handle qSupported query for exec-events feature.
6902 (captured_main): Initialize report_exec_events.
6903 * server.h (report_exec_events): Declare new global variable.
6904 * target.h (struct target_ops) <supports_exec_events>: New
6906 (target_supports_exec_events): New macro.
6907 * win32-low.c (win32_target_ops) <supports_exec_events>:
6908 Initialize new member.
6910 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
6912 * linux-low.c (linux_low_enable_btrace): Remove.
6913 (linux_target_ops): Replace linux_low_enable_btrace with
6914 linux_enable_btrace.
6916 2015-09-03 Yao Qi <yao.qi@linaro.org>
6918 * linux-aarch64-low.c (aarch64_insert_point): Call
6919 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
6922 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
6924 * linux-low.c (check_stopped_by_breakpoint): Use
6925 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
6927 2015-08-27 Pedro Alves <palves@redhat.com>
6929 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
6931 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
6933 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
6934 the XNEW-family equivalent.
6935 (compile_bytecodes): Likewise.
6936 * dll.c (loaded_dll): Likewise.
6937 * event-loop.c (append_callback_event): Likewise.
6938 (create_file_handler): Likewise.
6939 (create_file_event): Likewise.
6940 * hostio.c (handle_open): Likewise.
6941 * inferiors.c (add_thread): Likewise.
6942 (add_process): Likewise.
6943 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
6944 * linux-arm-low.c (arm_new_process): Likewise.
6945 (arm_new_thread): Likewise.
6946 * linux-low.c (add_to_pid_list): Likewise.
6947 (linux_add_process): Likewise.
6948 (handle_extended_wait): Likewise.
6949 (add_lwp): Likewise.
6950 (enqueue_one_deferred_signal): Likewise.
6951 (enqueue_pending_signal): Likewise.
6952 (linux_resume_one_lwp_throw): Likewise.
6953 (linux_resume_one_thread): Likewise.
6954 (linux_read_memory): Likewise.
6955 (linux_write_memory): Likewise.
6956 * linux-mips-low.c (mips_linux_new_process): Likewise.
6957 (mips_linux_new_thread): Likewise.
6958 (mips_add_watchpoint): Likewise.
6959 * linux-x86-low.c (initialize_low_arch): Likewise.
6960 * lynx-low.c (lynx_add_process): Likewise.
6961 * mem-break.c (set_raw_breakpoint_at): Likewise.
6962 (set_breakpoint): Likewise.
6963 (add_condition_to_breakpoint): Likewise.
6964 (add_commands_to_breakpoint): Likewise.
6965 (clone_agent_expr): Likewise.
6966 (clone_one_breakpoint): Likewise.
6967 * regcache.c (new_register_cache): Likewise.
6968 * remote-utils.c (look_up_one_symbol): Likewise.
6969 * server.c (queue_stop_reply): Likewise.
6970 (start_inferior): Likewise.
6971 (queue_stop_reply_callback): Likewise.
6972 (handle_target_event): Likewise.
6973 * spu-low.c (fetch_ppc_memory): Likewise.
6974 (store_ppc_memory): Likewise.
6975 * target.c (set_target_ops): Likewise.
6976 * thread-db.c (thread_db_load_search): Likewise.
6977 (try_thread_db_load_1): Likewise.
6978 * tracepoint.c (add_tracepoint): Likewise.
6979 (add_tracepoint_action): Likewise.
6980 (create_trace_state_variable): Likewise.
6981 (cmd_qtdpsrc): Likewise.
6982 (cmd_qtro): Likewise.
6983 (add_while_stepping_state): Likewise.
6984 * win32-low.c (child_add_thread): Likewise.
6985 (get_image_name): Likewise.
6987 2015-08-25 Yao Qi <yao.qi@linaro.org>
6989 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
6991 2015-08-25 Yao Qi <yao.qi@linaro.org>
6993 * Makefile.in (aarch64-linux.o): New rule.
6994 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
6996 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
6997 (aarch64_init_debug_reg_state): Make it extern.
6998 (aarch64_linux_prepare_to_resume): Remove.
7000 2015-08-25 Yao Qi <yao.qi@linaro.org>
7002 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
7003 lwp_arch_private_info and ptid_of_lwp.
7005 2015-08-25 Yao Qi <yao.qi@linaro.org>
7007 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
7008 Find proc_info by find_process_pid. All callers updated.
7010 2015-08-25 Yao Qi <yao.qi@linaro.org>
7012 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
7014 (debug_reg_change_callback): Remove.
7015 (aarch64_notify_debug_reg_change): Remove.
7017 2015-08-25 Yao Qi <yao.qi@linaro.org>
7019 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
7020 Call current_lwp_ptid.
7022 2015-08-25 Yao Qi <yao.qi@linaro.org>
7024 * linux-aarch64-low.c (debug_reg_change_callback): Use
7027 2015-08-25 Yao Qi <yao.qi@linaro.org>
7029 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
7031 2015-08-25 Yao Qi <yao.qi@linaro.org>
7033 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
7035 2015-08-25 Yao Qi <yao.qi@linaro.org>
7037 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
7040 2015-08-25 Yao Qi <yao.qi@linaro.org>
7042 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
7044 (debug_reg_change_callback): Remove argument entry and add argument
7045 lwp. Remove local variable thread. Don't print thread id in the
7046 debugging output. Don't check whether pid of thread equals to pid.
7047 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
7048 iterate_over_lwps instead find_inferior.
7050 2015-08-24 Pedro Alves <palves@redhat.com>
7052 * inferiors.c (get_first_process): New function.
7053 * inferiors.h (get_first_process): New declaration.
7054 * remote-utils.c (read_ptid): Default to the first process in the
7055 list, instead of to the current thread's process.
7057 2015-08-24 Pedro Alves <palves@redhat.com>
7059 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
7060 * event-loop.c: Likewise.
7061 * remote-utils.c: Likewise.
7062 * tracepoint.c: Likewise.
7064 2015-08-24 Pedro Alves <palves@redhat.com>
7066 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
7069 2015-08-21 Pedro Alves <palves@redhat.com>
7071 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
7072 instead of literal 1.
7074 2015-08-21 Pedro Alves <palves@redhat.com>
7076 * tdesc.c (default_description): Explicitly zero-initialize.
7078 2015-08-21 Pedro Alves <palves@redhat.com>
7081 * inferiors.c (remove_thread): Discard any pending stop reply for
7083 * server.c (remove_all_on_match_pid): Rename to ...
7084 (remove_all_on_match_ptid): ... this. Work with a filter ptid
7086 (discard_queued_stop_replies): Change parameter to a ptid. Now
7088 (handle_v_kill, kill_inferior_callback, captured_main)
7089 (process_serial_event): Adjust.
7090 * server.h (discard_queued_stop_replies): Declare.
7092 2015-08-21 Pedro Alves <palves@redhat.com>
7094 * linux-low.c (wait_for_sigstop): Always switch to no thread
7095 selected if the previously current thread dies.
7096 * lynx-low.c (lynx_request_interrupt): Use the first thread's
7097 process instead of the current thread's.
7098 * remote-utils.c (input_interrupt): Don't check if there's no
7100 * server.c (gdb_read_memory, gdb_write_memory): If setting the
7101 current thread to the general thread fails, error out.
7102 (handle_qxfer_auxv, handle_qxfer_libraries)
7103 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
7104 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
7105 (handle_query): Check if there's a thread selected instead of
7106 checking whether there's any thread in the thread list.
7107 (handle_qxfer_threads, handle_qxfer_btrace)
7108 (handle_qxfer_btrace_conf): Don't error out early if there's no
7109 thread in the thread list.
7110 (handle_v_cont, myresume): Don't set the current thread to the
7112 (process_serial_event) <Hg handling>: Also set thread_id if the
7113 previous general thread is still alive.
7114 (process_serial_event) <g/G handling>: If setting the current
7115 thread to the general thread fails, error out.
7116 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
7117 thread's lwp instead of the current thread's.
7118 * target.c (set_desired_thread): If the desired thread was not
7119 found, leave the current thread pointing to NULL. Return an int
7120 (boolean) indicating success.
7121 * target.h (set_desired_thread): Change return type to int.
7123 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
7125 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
7126 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
7128 (ps_get_thread_area): New function.
7130 2015-08-19 Gary Benson <gbenson@redhat.com>
7132 * hostio.c (handle_pread): Do not attempt to read more data
7133 than hostio_reply_with_data can fit in a packet.
7135 2015-08-18 Joel Brobecker <brobecker@adacore.com>
7137 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
7139 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
7141 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
7143 2015-08-06 Pedro Alves <palves@redhat.com>
7145 * tracepoint.c (expr_eval_result): Now an int.
7147 2015-08-06 Pedro Alves <palves@redhat.com>
7149 * gdbthread.h (struct regcache): Forward declare.
7150 (struct thread_info) <regcache_data>: Now a struct regcache
7152 * inferiors.c (inferior_regcache_data)
7153 (set_inferior_regcache_data): Now work with struct regcache
7155 * inferiors.h (struct regcache): Forward declare.
7156 (inferior_regcache_data, set_inferior_regcache_data): Now work
7157 with struct regcache pointers.
7158 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
7159 (free_register_cache_thread): Remove struct regcache pointer
7162 2015-08-06 Pedro Alves <palves@redhat.com>
7164 * server.c (captured_main): On error, print the exception message
7165 to stderr, and if run_once is set, throw a quit.
7167 2015-08-06 Pedro Alves <palves@redhat.com>
7169 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
7172 2015-08-06 Pedro Alves <palves@redhat.com>
7174 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
7175 reading beyond the passed in buffer length.
7177 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
7179 * tracepoint.c (symbol_list) <required>: Remove.
7181 2015-08-06 Pedro Alves <palves@redhat.com>
7183 * linux-low.c (handle_extended_wait): Set the fork child's suspend
7184 count if stopping and suspending threads.
7185 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
7186 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
7187 (linux_detach): Complete an ongoing step-over.
7188 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
7190 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
7191 (linux_wait_1): If passing a signal to the inferior after
7192 finishing a step-over, unsuspend and re-resume all lwps. If we
7193 see a single-step event but the thread should be continuing, don't
7194 pass the trap to gdb.
7195 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
7196 internal_error instead of gdb_assert.
7197 (enqueue_pending_signal): New function.
7198 (check_ptrace_stopped_lwp_gone): Add debug output.
7199 (start_step_over): Use internal_error instead of gdb_assert.
7200 (complete_ongoing_step_over): New function.
7201 (linux_resume_one_thread): Don't resume a suspended thread.
7202 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
7205 2015-08-06 Pedro Alves <palves@redhat.com>
7207 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
7208 (linux_thread_alive): Use lwp_is_marked_dead.
7209 (extended_event_reported): Delete.
7210 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
7211 instead of extended_event_reported.
7212 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
7214 (lwp_is_marked_dead): New function.
7215 (lwp_running): Use lwp_is_marked_dead.
7216 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
7219 2015-08-06 Pedro Alves <palves@redhat.com>
7221 * linux-low.c (linux_wait_1): Move fork event output out of the
7222 !report_to_gdb check. Pass event_child->waitstatus to
7223 target_waitstatus_to_string instead of ourstatus.
7225 2015-08-04 Yao Qi <yao.qi@linaro.org>
7227 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
7228 if current_thread is 32 bit.
7230 2015-08-04 Yao Qi <yao.qi@linaro.org>
7232 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
7233 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
7234 * server.c (extended_protocol): Remove "static".
7235 * server.h (extended_protocol): Declare it.
7237 2015-08-04 Yao Qi <yao.qi@linaro.org>
7239 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
7240 both aarch64 and aarch32.
7241 (aarch64_set_pc): Likewise.
7243 2015-08-04 Yao Qi <yao.qi@linaro.org>
7245 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
7246 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
7247 arm-with-neon.xml to srv_xmlfiles.
7248 * linux-aarch64-low.c: Include linux-aarch32-low.h.
7249 (is_64bit_tdesc): New function.
7250 (aarch64_linux_read_description): New function.
7251 (aarch64_arch_setup): Call aarch64_linux_read_description.
7252 (regs_info): Rename to regs_info_aarch64.
7253 (aarch64_regs_info): Return right regs_info.
7254 (initialize_low_arch): Call initialize_low_arch_aarch32.
7256 2015-08-04 Yao Qi <yao.qi@linaro.org>
7258 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
7259 * linux-aarch32-low.c: New file.
7260 * linux-aarch32-low.h: New file.
7261 * linux-arm-low.c (arm_fill_gregset): Move it to
7262 linux-aarch32-low.c.
7263 (arm_store_gregset): Likewise.
7264 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
7265 (arm_store_vfpregset): Call arm_store_vfpregset_num.
7266 (arm_arch_setup): Check if PTRACE_GETREGSET works.
7267 (regs_info): Rename to regs_info_arm.
7268 (arm_regs_info): Return regs_info_aarch32 if
7269 have_ptrace_getregset is 1 and target description is
7270 arm_with_neon or arm_with_vfpv3.
7271 (initialize_low_arch): Don't call init_registers_arm_with_neon.
7272 Call initialize_low_arch_aarch32 instead.
7274 2015-08-04 Yao Qi <yao.qi@linaro.org>
7276 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
7277 * linux-low.c: ... here.
7278 * linux-low.h (have_ptrace_getregset): Declare it.
7280 2015-08-04 Pedro Alves <palves@redhat.com>
7282 * thread-db.c (struct thread_db): Use new typedefs.
7283 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
7285 (disable_thread_event_reporting): Cast result of dlsym to
7286 destination function pointer type.
7287 (thread_db_mourn): Use td_ta_delete_ftype.
7289 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
7291 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
7293 (CDX_BREAKPOINT): Define for R2.
7294 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
7295 (the_low_target): Add comments.
7297 2015-07-30 Yao Qi <yao.qi@linaro.org>
7299 * linux-arm-low.c (arm_hwcap): Remove it.
7300 (arm_read_description): New local variable arm_hwcap. Don't
7301 set arm_hwcap to zero.
7303 2015-07-30 Yao Qi <yao.qi@linaro.org>
7305 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
7306 Use regcache->tdesc instead.
7307 (arm_store_wmmxregset): Likewise.
7308 (arm_fill_vfpregset): Likewise.
7309 (arm_store_vfpregset): Likewise.
7311 2015-07-30 Yao Qi <yao.qi@linaro.org>
7313 * linux-arm-low.c: Include arch/arm.h.
7314 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
7315 (arm_store_gregset): Likewise.
7317 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
7319 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
7320 ptrace's 4th parameter.
7322 2015-07-27 Yao Qi <yao.qi@linaro.org>
7324 * configure.srv (case aarch64*-*-linux*): Don't set
7327 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
7329 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
7331 * linux-arm-low.c: Likewise.
7332 * linux-cris-low.c: Likewise.
7333 * linux-crisv32-low.c: Likewise.
7334 * linux-low.c: Likewise.
7335 * linux-m68k-low.c: Likewise.
7336 * linux-mips-low.c: Likewise.
7337 * linux-nios2-low.c: Likewise.
7338 * linux-s390-low.c: Likewise.
7339 * linux-sparc-low.c: Likewise.
7340 * linux-tic6x-low.c: Likewise.
7341 * linux-tile-low.c: Likewise.
7342 * linux-x86-low.c: Likewise.
7344 2015-07-24 Pedro Alves <palves@redhat.com>
7346 * config.in: Regenerate.
7347 * configure: Regenerate.
7349 2015-07-24 Pedro Alves <palves@redhat.com>
7351 * acinclude.m4: Include ../ptrace.m4.
7352 * configure.ac: Call GDB_AC_PTRACE.
7353 * config.in, configure: Regenerate.
7355 2015-07-24 Yao Qi <yao.qi@linaro.org>
7357 * linux-low.c (linux_create_inferior): Remove setting to
7358 proc->priv->new_inferior.
7359 (linux_attach): Likewise.
7360 (linux_low_filter_event): Likewise.
7361 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
7363 2015-07-24 Yao Qi <yao.qi@linaro.org>
7365 * linux-low.c (linux_arch_setup): New function.
7366 (linux_low_filter_event): If proc->tdesc is NULL and
7367 proc->attached is true, call the_low_target.arch_setup.
7368 Otherwise, keep status pending, and return.
7369 (linux_resume_one_lwp_throw): Don't call get_pc if
7370 thread->while_stepping isn't NULL. Don't call
7371 get_thread_regcache if proc->tdesc is NULL.
7372 (need_step_over_p): Return 0 if proc->tdesc is NULL.
7373 (linux_target_ops): Install arch_setup.
7374 * server.c (start_inferior): Call the_target->arch_setup.
7375 * target.h (struct target_ops) <arch_setup>: New field.
7376 (target_arch_setup): New marco.
7377 * lynx-low.c (lynx_target_ops): Update.
7378 * nto-low.c (nto_target_ops): Update.
7379 * spu-low.c (spu_target_ops): Update.
7380 * win32-low.c (win32_target_ops): Update.
7382 2015-07-24 Yao Qi <yao.qi@linaro.org>
7384 * linux-low.c (linux_add_process): Don't set
7385 proc->priv->new_inferior.
7386 (linux_create_inferior): Set proc->priv->new_inferior to 1.
7387 (linux_attach): Likewise.
7389 2015-07-24 Yao Qi <yao.qi@linaro.org>
7391 * server.c (start_inferior): Code refactor.
7393 2015-07-24 Yao Qi <yao.qi@linaro.org>
7395 * server.c (process_serial_event): Set general_thread.
7397 2015-07-21 Yao Qi <yao.qi@linaro.org>
7399 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
7400 aarch64_linux_get_debug_reg_capacity.
7402 2015-07-17 Yao Qi <yao.qi@linaro.org>
7404 * Makefile.in (aarch64-linux-hw-point.o): New rule.
7405 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
7406 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
7407 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
7408 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
7409 (AARCH64_HWP_ALIGNMENT): Likewise.
7410 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
7411 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
7412 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
7413 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
7414 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
7415 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
7416 (struct aarch64_debug_reg_state): Likewise.
7417 (struct arch_lwp_info): Likewise.
7418 (aarch64_align_watchpoint): Likewise.
7419 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
7420 (aarch64_watchpoint_length): Likewise.
7421 (aarch64_point_encode_ctrl_reg): Likewise
7422 (aarch64_point_is_aligned): Likewise.
7423 (aarch64_align_watchpoint): Likewise.
7424 (aarch64_linux_set_debug_regs):
7425 (aarch64_dr_state_insert_one_point): Likewise.
7426 (aarch64_dr_state_remove_one_point): Likewise.
7427 (aarch64_handle_breakpoint): Likewise.
7428 (aarch64_handle_aligned_watchpoint): Likewise.
7429 (aarch64_handle_unaligned_watchpoint): Likewise.
7430 (aarch64_handle_watchpoint): Likewise.
7432 2015-07-17 Yao Qi <yao.qi@linaro.org>
7434 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
7435 and don't aarch64_get_debug_reg_state. All callers update.
7436 (aarch64_handle_aligned_watchpoint): Likewise.
7437 (aarch64_handle_unaligned_watchpoint): Likewise.
7438 (aarch64_handle_watchpoint): Likewise.
7439 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
7440 (aarch64_remove_point): Likewise.
7442 2015-07-17 Yao Qi <yao.qi@linaro.org>
7444 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
7446 (aarch64_handle_unaligned_watchpoint): Likewise.
7448 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
7450 Revert the previous 3 commits:
7451 Move gdb_regex* to common/
7452 Move linux_find_memory_regions_full & co.
7453 gdbserver build-id attribute generator
7455 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
7456 Jan Kratochvil <jan.kratochvil@redhat.com>
7458 gdbserver build-id attribute generator.
7459 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
7460 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
7461 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
7463 (get_dynamic): Use find_pdhr to traverse program headers.
7464 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
7465 (compare_mapping_entry_range, struct find_memory_region_callback_data)
7466 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
7467 (get_hex_build_id): New.
7468 (linux_qxfer_libraries_svr4): Add optional build-id attribute
7469 to reply XML document.
7471 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
7472 Jan Kratochvil <jan.kratochvil@redhat.com>
7474 * target.c: Include target/target-utils.h and fcntl.h.
7475 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
7476 (target_fileio_read_stralloc): New functions.
7478 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
7480 * Makefile.in (OBS): Add gdb_regex.o.
7482 * config.in: Rebuilt.
7483 * configure: Rebuilt.
7485 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
7486 Jan Kratochvil <jan.kratochvil@redhat.com>
7488 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
7489 * Makefile.in (OBS): Add target-utils.o.
7490 (linux-maps.o, target-utils.o): New.
7491 * configure.srv (srv_linux_obj): Add linux-maps.o.
7493 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
7495 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
7497 (the_low_target): Install it.
7499 2015-07-14 Pedro Alves <palves@redhat.com>
7501 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
7502 Instead, ignore ECHILD, and throw an error for other errnos.
7504 2015-07-10 Pedro Alves <palves@redhat.com>
7506 * event-loop.c (struct callback_event) <data>: Change type to
7507 gdb_client_data instance instead of gdb_client_data pointer.
7508 (append_callback_event): Adjust.
7510 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
7512 * linux-aarch64-low.c: Add comments for each linux_target_ops
7513 method. Remove comments already covered in target_ops and
7514 linux_target_ops definitions.
7515 (the_low_target): Add comments for each unimplemented method.
7517 2015-07-09 Yao Qi <yao.qi@linaro.org>
7519 * linux-aarch64-low.c (aarch64_regmap): Remove.
7520 (aarch64_usrregs_info): Remove.
7521 (regs_info): Set field usrregs to NULL.
7523 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
7525 * linux-low.c: Include "rsp-low.h"
7526 (linux_low_encode_pt_config, linux_low_encode_raw): New.
7527 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
7528 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
7529 (handle_btrace_enable_pt): New.
7530 (handle_btrace_general_set): Support "pt".
7531 (handle_btrace_conf_general_set): Support "pt:size".
7533 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
7535 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
7538 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
7540 * linux-aarch64-low.c: Remove comment about endianness.
7541 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
7542 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
7545 2015-06-24 Gary Benson <gbenson@redhat.com>
7547 * linux-i386-ipa.c (stdint.h): Do not include.
7548 * lynx-i386-low.c (stdint.h): Likewise.
7549 * lynx-ppc-low.c (stdint.h): Likewise.
7550 * mem-break.c (stdint.h): Likewise.
7551 * thread-db.c (stdint.h): Likewise.
7552 * tracepoint.c (stdint.h): Likewise.
7553 * win32-low.c (stdint.h): Likewise.
7555 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
7557 * server.c (write_qxfer_response): Update call to
7558 remote_escape_output.
7560 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
7561 Jan Kratochvil <jan.kratochvil@redhat.com>
7563 Merge multiple hex conversions.
7564 * gdbreplay.c (tohex): Rename to 'fromhex'.
7565 (logchar): Use fromhex.
7567 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
7569 * server.c (handle_qxfer_libraries): Set `version' attribute for
7572 2015-06-10 Gary Benson <gbenson@redhat.com>
7574 * target.h (struct target_ops) <multifs_open>: New field.
7575 <multifs_unlink>: Likewise.
7576 <multifs_readlink>: Likewise.
7577 * linux-low.c (nat/linux-namespaces.h): New include.
7578 (linux_target_ops): Initialize the_target->multifs_open,
7579 the_target->multifs_unlink and the_target->multifs_readlink.
7580 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
7581 * hostio.c (hostio_fs_pid): New static variable.
7582 (hostio_handle_new_gdb_connection): New function.
7583 (handle_setfs): Likewise.
7584 (handle_open): Use the_target->multifs_open as appropriate.
7585 (handle_unlink): Use the_target->multifs_unlink as appropriate.
7586 (handle_readlink): Use the_target->multifs_readlink as
7588 (handle_vFile): Handle vFile:setfs packets.
7589 * server.c (handle_query): Call hostio_handle_new_gdb_connection
7590 after target_handle_new_gdb_connection.
7592 2015-06-10 Gary Benson <gbenson@redhat.com>
7594 * configure.ac (AC_CHECK_FUNCS): Add setns.
7595 * config.in: Regenerate.
7596 * configure: Likewise.
7597 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
7598 (linux-namespaces.o): New rule.
7599 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
7601 2015-06-09 Gary Benson <gbenson@redhat.com>
7603 * hostio.c (handle_open): Process mode argument with
7604 fileio_to_host_mode.
7606 2015-06-01 Yao Qi <yao.qi@linaro.org>
7608 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
7609 * linux-x86-low.c: Likewise.
7611 2015-05-28 Don Breazeal <donb@codesourcery.com>
7613 * linux-low.c (handle_extended_wait): Initialize
7614 thread_info.last_resume_kind for new fork children.
7616 2015-05-15 Pedro Alves <palves@redhat.com>
7618 * target.h (target_handle_new_gdb_connection): Rewrite using if
7619 wrapped in do/while.
7621 2015-05-14 Joel Brobecker <brobecker@adacore.com>
7623 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
7624 * configure, config.in: Regenerate.
7625 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
7628 2015-05-12 Don Breazeal <donb@codesourcery.com>
7630 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
7631 PTRACE_EVENT_VFORK_DONE.
7632 (linux_low_ptrace_options, extended_event_reported): Add vfork
7634 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
7635 and "vforkdone" for RSP 'T' Stop Reply Packet.
7636 * server.h (report_vfork_events): Declare
7639 2015-05-12 Don Breazeal <donb@codesourcery.com>
7641 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
7642 (the_low_target) <new_fork>: Initialize new member.
7643 * linux-arm-low.c (arm_new_fork): New function.
7644 (the_low_target) <new_fork>: Initialize new member.
7645 * linux-low.c (handle_extended_wait): Call new target function
7647 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
7648 * linux-mips-low.c (mips_add_watchpoint): New function
7649 extracted from mips_insert_point.
7650 (the_low_target) <new_fork>: Initialize new member.
7651 (mips_linux_new_fork): New function.
7652 (mips_insert_point): Call mips_add_watchpoint.
7653 * linux-x86-low.c (x86_linux_new_fork): New function.
7654 (the_low_target) <new_fork>: Initialize new member.
7656 2015-05-12 Don Breazeal <donb@codesourcery.com>
7658 * linux-low.c (handle_extended_wait): Implement return value,
7659 rename argument 'event_child' to 'event_lwp', handle
7660 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
7661 (linux_low_ptrace_options): New function.
7662 (linux_low_filter_event): Call linux_low_ptrace_options,
7663 use different argument fo linux_enable_event_reporting,
7664 use return value from handle_extended_wait.
7665 (extended_event_reported): New function.
7666 (linux_wait_1): Call extended_event_reported and set
7667 status to report fork events.
7668 (linux_write_memory): Add pid to debug message.
7669 (reset_lwp_ptrace_options_callback): New function.
7670 (linux_handle_new_gdb_connection): New function.
7671 (linux_target_ops): Initialize new structure member.
7672 * linux-low.h (struct lwp_info) <waitstatus>: New member.
7673 * lynx-low.c: Initialize new structure member.
7674 * remote-utils.c (prepare_resume_reply): Implement stop reason
7675 "fork" for "T" stop message.
7676 * server.c (handle_query): Call handle_new_gdb_connection.
7677 * server.h (report_fork_events): Declare global flag.
7678 * target.h (struct target_ops) <handle_new_gdb_connection>:
7680 (target_handle_new_gdb_connection): New macro.
7681 * win32-low.c: Initialize new structure member.
7683 2015-05-12 Don Breazeal <donb@codesourcery.com>
7685 * mem-break.c (APPEND_TO_LIST): Define macro.
7686 (clone_agent_expr): New function.
7687 (clone_one_breakpoint): New function.
7688 (clone_all_breakpoints): New function.
7689 * mem-break.h: Declare new functions.
7691 2015-05-12 Don Breazeal <donb@codesourcery.com>
7693 * linux-low.c (linux_supports_fork_events): New function.
7694 (linux_supports_vfork_events): New function.
7695 (linux_target_ops): Initialize new structure members.
7696 (initialize_low): Call linux_check_ptrace_features.
7697 * lynx-low.c (lynx_target_ops): Initialize new structure
7699 * server.c (report_fork_events, report_vfork_events):
7701 (handle_query): Add new features to qSupported packet and
7703 (captured_main): Initialize new global variables.
7704 * target.h (struct target_ops) <supports_fork_events>:
7706 <supports_vfork_events>: New member.
7707 (target_supports_fork_events): New macro.
7708 (target_supports_vfork_events): New macro.
7709 * win32-low.c (win32_target_ops): Initialize new structure
7712 2015-05-12 Gary Benson <gbenson@redhat.com>
7714 * server.c (handle_qxfer_exec_file): Use current process
7717 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
7719 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
7720 Remove HAVE_PTRACE_GETREGS conditionals.
7721 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
7722 instead of PTRACE_GETREGS and PTRACE_SETREGS.
7724 2015-05-08 Yao Qi <yao.qi@linaro.org>
7726 * linux-low.c (linux_supports_conditional_breakpoints): New
7728 (linux_target_ops): Install new target method.
7729 * lynx-low.c (lynx_target_ops): Install NULL hook for
7730 supports_conditional_breakpoints.
7731 * nto-low.c (nto_target_ops): Likewise.
7732 * spu-low.c (spu_target_ops): Likewise.
7733 * win32-low.c (win32_target_ops): Likewise.
7734 * server.c (handle_query): Check
7735 target_supports_conditional_breakpoints.
7736 * target.h (struct target_ops) <supports_conditional_breakpoints>:
7738 (target_supports_conditional_breakpoints): New macro.
7740 2015-05-06 Pedro Alves <palves@redhat.com>
7743 * server.c (start_inferior): If the process exits, mourn it.
7745 2015-04-21 Gary Benson <gbenson@redhat.com>
7747 * hostio.c (fileio_open_flags_to_host): Factored out to
7748 fileio_to_host_openflags in common/fileio.c. Single use
7751 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
7753 * linux-xtensa-low.c (xtensa_fill_gregset)
7754 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
7757 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
7759 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
7760 (regs_info): Replace usrregs pointer with NULL.
7762 2015-04-17 Gary Benson <gbenson@redhat.com>
7764 * target.h (struct target_ops) <pid_to_exec_file>: New field.
7765 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
7766 * server.c (handle_qxfer_exec_file): New function.
7767 (qxfer_packets): Add exec-file entry.
7768 (handle_query): Report qXfer:exec-file:read as supported packet.
7770 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
7772 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
7774 2015-04-09 Gary Benson <gbenson@redhat.com>
7776 * hostio-errno.c (errno_to_fileio_error): Remove function.
7777 Update caller to use remote_fileio_to_fio_error.
7779 2015-04-09 Yao Qi <yao.qi@linaro.org>
7781 * linux-low.c (linux_insert_point): Call
7782 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
7783 (linux_remove_point): Call remove_memory_breakpoint if type is
7785 * linux-x86-low.c (x86_insert_point): Don't call
7786 insert_memory_breakpoint.
7787 (x86_remove_point): Don't call remove_memory_breakpoint.
7789 2015-04-01 Pedro Alves <palves@redhat.com>
7790 Cleber Rosa <crosa@redhat.com>
7792 * server.c (gdbserver_usage): Reorganize and extend the usage
7795 2015-03-24 Pedro Alves <palves@redhat.com>
7797 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
7798 output. Also dump TRAP_TRACE.
7799 (linux_low_filter_event): In debug output, distinguish a
7800 resume_stop SIGSTOP from a delayed SIGSTOP.
7802 2015-03-24 Gary Benson <gbenson@redhat.com>
7804 * linux-x86-low.c (x86_linux_new_thread): Moved to
7806 (x86_linux_prepare_to_resume): Likewise.
7808 2015-03-24 Gary Benson <gbenson@redhat.com>
7810 * Makefile.in (x86-linux-dregs.o): New rule.
7811 * configure.srv: Add x86-linux-dregs.o to relevant targets.
7812 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
7813 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
7814 (x86_linux_dr_get): Likewise.
7815 (x86_linux_dr_set): Likewise.
7816 (update_debug_registers_callback): Likewise.
7817 (x86_linux_dr_set_addr): Likewise.
7818 (x86_linux_dr_get_addr): Likewise.
7819 (x86_linux_dr_set_control): Likewise.
7820 (x86_linux_dr_get_control): Likewise.
7821 (x86_linux_dr_get_status): Likewise.
7822 (x86_linux_update_debug_registers): Likewise.
7824 2015-03-24 Gary Benson <gbenson@redhat.com>
7826 * linux-x86-low.c (x86_linux_update_debug_registers):
7827 New function, factored out from...
7828 (x86_linux_prepare_to_resume): ...this.
7830 2015-03-24 Gary Benson <gbenson@redhat.com>
7832 * linux-x86-low.c (x86_linux_dr_get): Update comments.
7833 (x86_linux_dr_set): Likewise.
7834 (update_debug_registers_callback): Likewise.
7835 (x86_linux_dr_set_addr): Likewise.
7836 (x86_linux_dr_get_addr): Likewise.
7837 (x86_linux_dr_set_control): Likewise.
7838 (x86_linux_dr_get_control): Likewise.
7839 (x86_linux_dr_get_status): Likewise.
7840 (x86_linux_prepare_to_resume): Likewise.
7842 2015-03-24 Gary Benson <gbenson@redhat.com>
7844 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
7845 Use perror_with_name. Pass string through gettext.
7846 (x86_linux_dr_set): Likewise.
7848 2015-03-24 Gary Benson <gbenson@redhat.com>
7850 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
7851 (x86_linux_dr_set_addr): ...this.
7852 (x86_dr_low_get_addr): Rename to...
7853 (x86_linux_dr_get_addr): ...this.
7854 (x86_dr_low_set_control): Rename to...
7855 (x86_linux_dr_set_control): ...this.
7856 (x86_dr_low_get_control): Rename to...
7857 (x86_linux_dr_get_control): ...this.
7858 (x86_dr_low_get_status): Rename to...
7859 (x86_linux_dr_get_status): ...this.
7860 (x86_dr_low): Update with new function names.
7862 2015-03-24 Gary Benson <gbenson@redhat.com>
7864 * Makefile.in (x86-linux.o): New rule.
7865 * configure.srv: Add x86-linux.o to relevant targets.
7866 * linux-low.c (lwp_set_arch_private_info): New function.
7867 (lwp_arch_private_info): Likewise.
7868 * linux-x86-low.c: Include nat/x86-linux.h.
7869 (arch_lwp_info): Removed structure.
7870 (update_debug_registers_callback):
7871 Use lwp_set_debug_registers_changed.
7872 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
7873 and lwp_set_debug_registers_changed.
7874 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
7876 2015-03-24 Gary Benson <gbenson@redhat.com>
7878 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
7879 * linux-arm-low.c (arm_new_thread): Likewise.
7880 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
7881 * linux-mips-low.c (mips_linux_new_thread): Likewise.
7882 * linux-x86-low.c (x86_linux_new_thread): Likewise.
7883 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
7885 2015-03-24 Gary Benson <gbenson@redhat.com>
7887 * linux-low.c (ptid_of_lwp): New function.
7888 (lwp_is_stopped): Likewise.
7889 (lwp_stop_reason): Likewise.
7890 * linux-x86-low.c (update_debug_registers_callback):
7892 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
7895 2015-03-24 Gary Benson <gbenson@redhat.com>
7897 * linux-low.h (linux_stop_lwp): Remove declaration.
7899 2015-03-24 Gary Benson <gbenson@redhat.com>
7901 * linux-low.h: Include nat/linux-nat.h.
7902 * linux-low.c (iterate_over_lwps_args): New structure.
7903 (iterate_over_lwps_filter): New function.
7904 (iterate_over_lwps): Likewise.
7905 * linux-x86-low.c (update_debug_registers_callback):
7906 Update signature to what iterate_over_lwps expects.
7907 Remove PID check that iterate_over_lwps now performs.
7908 (x86_dr_low_set_addr): Use iterate_over_lwps.
7909 (x86_dr_low_set_control): Likewise.
7911 2015-03-24 Gary Benson <gbenson@redhat.com>
7913 * linux-x86-low.c (x86_debug_reg_state): New function.
7914 (x86_linux_prepare_to_resume): Use the above.
7916 2015-03-24 Gary Benson <gbenson@redhat.com>
7918 * linux-low.c (current_lwp_ptid): New function.
7919 * linux-x86-low.c: Include nat/linux-nat.h.
7920 (x86_dr_low_get_addr): Use current_lwp_ptid.
7921 (x86_dr_low_get_control): Likewise.
7922 (x86_dr_low_get_status): Likewise.
7924 2015-03-20 Pedro Alves <palves@redhat.com>
7926 * tracepoint.c (cmd_qtstatus): Make "str" const.
7928 2015-03-20 Pedro Alves <palves@redhat.com>
7930 * server.c (handle_general_set): Make "req_str" const.
7932 2015-03-19 Pedro Alves <palves@redhat.com>
7934 * linux-low.c (linux_resume_one_lwp): Rename to ...
7935 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
7936 instead call perror_with_name.
7937 (check_ptrace_stopped_lwp_gone): New function.
7938 (linux_resume_one_lwp): Reimplement as wrapper around
7939 linux_resume_one_lwp_throw that swallows errors if the LWP is
7942 2015-03-19 Pedro Alves <palves@redhat.com>
7944 * linux-low.c (count_events_callback, select_event_lwp_callback):
7945 No longer check whether the thread has resume_stop as last resume
7948 2015-03-19 Pedro Alves <palves@redhat.com>
7950 * linux-low.c (count_events_callback, select_event_lwp_callback):
7951 Use the lwp's status_pending_p field, not the thread's.
7953 2015-03-19 Pedro Alves <palves@redhat.com>
7955 * linux-low.c (select_event_lwp_callback): Update comments to
7956 no longer mention SIGTRAP.
7958 2015-03-18 Gary Benson <gbenson@redhat.com>
7960 * server.c (handle_query): Do not report vFile:fstat as supported.
7962 2015-03-11 Gary Benson <gbenson@redhat.com>
7964 * hostio.c (sys/types.h): New include.
7965 (sys/stat.h): Likewise.
7966 (common-remote-fileio.h): Likewise.
7967 (handle_fstat): New function.
7968 (handle_vFile): Handle vFile:fstat packets.
7970 2015-03-11 Gary Benson <gbenson@redhat.com>
7972 * configure.ac (AC_CHECK_MEMBERS): Add checks for
7973 struct stat.st_blocks and struct stat.st_blksize.
7974 * configure: Regenerate.
7975 * config.in: Likewise.
7976 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
7977 (OBS): Add common-remote-fileio.o.
7978 (common-remote-fileio.o): New rule.
7980 2015-03-09 Pedro Alves <palves@redhat.com>
7982 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
7983 'struct sockaddr' pointer in 'accept' call.
7985 2015-03-09 Pedro Alves <palves@redhat.com>
7988 2015-03-07 Pedro Alves <palves@redhat.com>
7989 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
7990 or <winsock2.h> here. Instead include "gdb_socket.h".
7991 (remote_open): Use union gdb_sockaddr_u.
7992 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
7993 or <winsock2.h> here. Instead include "gdb_socket.h".
7994 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
7995 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
7997 (init_named_socket, gdb_agent_helper_thread): Use union
8000 2015-03-07 Pedro Alves <palves@redhat.com>
8002 * configure.ac (build_warnings): Move
8003 -Wdeclaration-after-statement to the C-specific set.
8004 * configure: Regenerate.
8006 2015-03-07 Pedro Alves <palves@redhat.com>
8008 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
8009 or <winsock2.h> here. Instead include "gdb_socket.h".
8010 (remote_open): Use union gdb_sockaddr_u.
8011 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
8012 or <winsock2.h> here. Instead include "gdb_socket.h".
8013 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
8014 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
8016 (init_named_socket, gdb_agent_helper_thread): Use union
8019 2015-03-07 Pedro Alves <palves@redhat.com>
8021 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
8024 2015-03-06 Yao Qi <yao.qi@linaro.org>
8026 * linux-aarch64-low.c (aarch64_insert_point): Use
8027 show_debug_regs as a boolean.
8028 (aarch64_remove_point): Likewise.
8030 2015-03-05 Pedro Alves <palves@redhat.com>
8032 * lynx-low.c (lynx_target_ops): Install NULL hooks for
8033 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
8034 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
8035 * nto-low.c (nto_target_ops): Likewise.
8036 * spu-low.c (spu_target_ops): Likewise.
8037 * win32-low.c (win32_target_ops): Likewise.
8039 2015-03-04 Pedro Alves <palves@redhat.com>
8041 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
8042 Decide whether a breakpoint triggered based on the SIGTRAP's
8044 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
8045 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
8046 (linux_low_filter_event): Check for breakpoints before checking
8048 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
8050 (linux_stopped_by_sw_breakpoint)
8051 (linux_supports_stopped_by_sw_breakpoint)
8052 (linux_stopped_by_hw_breakpoint)
8053 (linux_supports_stopped_by_hw_breakpoint): New functions.
8054 (linux_target_ops): Install new target methods.
8056 2015-03-04 Pedro Alves <palves@redhat.com>
8058 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
8059 * server.c (swbreak_feature, hwbreak_feature): New globals.
8060 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
8061 (captured_main): Clear swbreak_feature and hwbreak_feature.
8062 * server.h (swbreak_feature, hwbreak_feature): Declare.
8063 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
8064 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
8065 supports_stopped_by_hw_breakpoint>: New fields.
8066 (target_supports_stopped_by_sw_breakpoint)
8067 (target_stopped_by_sw_breakpoint)
8068 (target_supports_stopped_by_hw_breakpoint)
8069 (target_stopped_by_hw_breakpoint): Declare.
8071 2015-03-04 Pedro Alves <palves@redhat.com>
8073 enum lwp_stop_reason -> enum target_stop_reason
8074 * linux-low.c (check_stopped_by_breakpoint): Adjust.
8075 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
8076 (linux_wait_1, stuck_in_jump_pad_callback)
8077 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
8078 (linux_stopped_by_watchpoint):
8079 * linux-low.h (enum lwp_stop_reason): Delete.
8080 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
8081 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
8083 2015-03-04 Yao Qi <yao.qi@linaro.org>
8085 * Makefile.in (SFILES): Add linux-aarch64-low.c.
8087 2015-03-03 Gary Benson <gbenson@redhat.com>
8089 * hostio.c (handle_vFile): Fix prefix lengths.
8091 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
8093 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
8096 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
8098 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
8099 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
8100 (clean): Add "rm -f" for above C files.
8101 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
8102 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
8103 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
8104 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
8105 * linux-s390-low.c (HWCAP_S390_VX): New macro.
8106 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
8107 (init_registers_s390x_vx_linux64)
8108 (init_registers_s390x_tevx_linux64)
8109 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
8110 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
8112 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
8113 (s390_store_vxrs_high): New functions.
8114 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
8116 (s390_arch_setup): Add logic for selecting one of the new target
8117 descriptions. Activate the new vector regsets if applicable.
8118 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
8119 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
8120 and init_registers_s390x_tevx_linux64.
8122 2015-03-01 Pedro Alves <palves@redhat.com>
8124 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
8127 2015-02-27 Pedro Alves <palves@redhat.com>
8129 * linux-x86-low.c (u_debugreg_offset): New function.
8130 (x86_linux_dr_get, x86_linux_dr_set): Use it.
8132 2015-02-27 Pedro Alves <palves@redhat.com>
8134 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
8135 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
8136 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
8137 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
8138 (ps_lsetfpregs, ps_getpid)
8139 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
8140 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
8141 (ps_lsetxregs, ps_plog): Declare.
8143 2015-02-27 Pedro Alves <palves@redhat.com>
8145 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
8146 IP_AGENT_EXPORT_FUNC.
8147 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
8148 IP_AGENT_EXPORT_FUNC.
8149 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
8150 (IP_AGENT_EXPORT): Delete.
8151 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
8152 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
8153 (gdb_trampoline_buffer_error, collecting, gdb_collect)
8154 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
8155 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
8156 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
8157 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
8158 (traceframe_read_count, traceframe_write_count)
8159 (traceframes_created, trace_state_variables, get_raw_reg)
8160 (get_trace_state_variable_value, set_trace_state_variable_value)
8161 (ust_loaded, helper_thread_id, cmd_buf): Use
8162 IPA_SYM_EXPORTED_NAME.
8163 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
8164 (tracepoints) Use IP_AGENT_EXPORT_VAR.
8165 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
8166 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
8167 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
8168 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
8169 EXTERN_C_PUSH/EXTERN_C_POP.
8170 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
8171 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
8172 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
8173 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
8174 (traceframe_write_count, traceframe_read_count)
8175 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
8176 (about_to_request_buffer_space, get_trace_state_variable_value)
8177 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
8178 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
8179 EXTERN_C_PUSH/EXTERN_C_POP.
8180 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
8181 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
8182 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
8183 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
8184 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
8185 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
8186 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
8187 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
8189 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
8190 (IP_AGENT_EXPORT_VAR_DECL): Define.
8192 (gdb_agent_get_raw_reg): Declare.
8194 2015-02-27 Tom Tromey <tromey@redhat.com>
8195 Pedro Alves <palves@redhat.com>
8197 Rename symbols whose names are reserved C++ keywords throughout.
8199 2015-02-27 Pedro Alves <palves@redhat.com>
8201 * Makefile.in (COMPILER): New, get it from autoconf.
8202 (CXX): Get from autoconf instead.
8203 (COMPILE.pre): Use COMPILER.
8204 (CC-LD): Rename to ...
8205 (CC_LD): ... this. Use COMPILER.
8206 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
8207 (CXX_FOR_TARGET): Default to g++ instead of gcc.
8208 * acinclude.m4: Include build-with-cxx.m4.
8209 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
8210 Disable -Werror by default if building in C++ mode.
8211 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
8212 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
8213 the C++ compiler. Save/restore CXXFLAGS too.
8214 * configure: Regenerate.
8216 2015-02-27 Pedro Alves <palves@redhat.com>
8218 * acinclude.m4: Include libiberty.m4.
8219 * configure.ac: Call libiberty_INIT.
8220 * config.in, configure: Regenerate.
8222 2015-02-26 Pedro Alves <palves@redhat.com>
8224 * linux-low.c (linux_wait_1): When incrementing the PC past a
8225 program breakpoint always use the_low_target.breakpoint_len as
8226 increment, rather than the maximum between that and
8227 the_low_target.decr_pc_after_break.
8229 2015-02-23 Pedro Alves <palves@redhat.com>
8231 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
8232 thread was doing a step-over; always adjust the PC if
8233 we stepped over a permanent breakpoint.
8234 (linux_wait_1): If we stepped over breakpoint that was on top of a
8235 permanent breakpoint, manually advance the PC past it.
8237 2015-02-23 Pedro Alves <palves@redhat.com>
8239 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
8241 (x86_fill_gregset, x86_store_gregset): Use it when handling
8244 2015-02-20 Pedro Alves <palves@redhat.com>
8246 * thread-db.c: Include "nat/linux-procfs.h".
8247 (thread_db_init): Skip listing new threads if the kernel supports
8248 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
8250 2015-02-20 Pedro Alves <palves@redhat.com>
8252 * linux-low.c (status_pending_p_callback): Use ptid_match.
8254 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
8256 PR breakpoints/16812
8257 * linux-low.c (wstatus_maybe_breakpoint): Remove.
8258 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
8259 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
8261 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
8263 PR breakpoints/15956
8264 * tracepoint.c (cmd_qtinit): Add check for current_thread.
8266 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
8268 * linux-low.c (linux_low_btrace_conf): Print size.
8269 * server.c (handle_btrace_conf_general_set): New.
8270 (hanle_general_set): Call handle_btrace_conf_general_set.
8271 (handle_query): Report Qbtrace-conf:bts:size as supported.
8273 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
8275 * linux-low.c (linux_low_enable_btrace): Update parameters.
8276 (linux_low_btrace_conf): New.
8277 (linux_target_ops)<to_btrace_conf>: Initialize.
8278 * server.c (current_btrace_conf): New.
8279 (handle_btrace_enable): Rename to ...
8280 (handle_btrace_enable_bts): ... this. Pass ¤t_btrace_conf
8281 to target_enable_btrace. Update comment. Update users.
8282 (handle_qxfer_btrace_conf): New.
8283 (qxfer_packets): Add btrace-conf entry.
8284 (handle_query): Report qXfer:btrace-conf:read as supported packet.
8285 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
8286 (target_ops)<read_btrace_conf>: New.
8287 (target_enable_btrace): Update parameters.
8288 (target_read_btrace_conf): New.
8290 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
8292 * server.c (handle_btrace_general_set): Remove call to
8293 target_supports_btrace.
8294 (supported_btrace_packets): New.
8295 (handle_query): Call supported_btrace_packets.
8296 * target.h: include btrace-common.h.
8297 (btrace_target_info): Removed.
8298 (supports_btrace, target_supports_btrace): Update parameters.
8300 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
8302 * Makefile.in (SFILES): Add common/btrace-common.c.
8303 (OBS): Add common/btrace-common.o.
8304 (btrace-common.o): Add build rules.
8305 * linux-low: Include btrace-common.h.
8306 (linux_low_read_btrace): Use struct btrace_data. Call
8307 btrace_data_init and btrace_data_fini.
8309 2015-02-06 Pedro Alves <palves@redhat.com>
8311 * thread-db.c (find_new_threads_callback): Add debug output.
8313 2015-02-04 Pedro Alves <palves@redhat.com>
8315 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
8316 (resume_stopped_resumed_lwps): New function.
8317 (linux_wait_for_event_filtered): Use it.
8319 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
8321 * Makefile.in (SFILES): Add linux-personality.c.
8322 (linux-personality.o): New rule.
8323 * configure.srv (srv_linux_obj): Add linux-personality.o to the
8324 list of objects to be built.
8325 * linux-low.c: Include nat/linux-personality.h.
8326 (linux_create_inferior): Remove code to disable address space
8327 randomization (moved to ../nat/linux-personality.c). Create
8328 cleanup to disable address space randomization.
8330 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
8332 * Makefile.in (posix-strerror.o): New rule.
8333 (mingw-strerror.o): Likewise.
8334 * configure: Regenerated.
8335 * configure.ac: Source file ../common/common.host. Initialize new
8336 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
8338 2015-01-14 Yao Qi <yao@codesourcery.com>
8340 * Makefile.in (SFILES): Add nat/ppc-linux.c.
8341 (ppc-linux.o): New rule.
8342 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
8343 * configure.ac: AC_CHECK_FUNCS(getauxval).
8344 * config.in: Re-generated.
8345 * configure: Re-generated.
8346 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
8347 ppc64_64bit_inferior_p
8349 2015-01-14 Yao Qi <yao@codesourcery.com>
8351 * linux-ppc-low.c: Include "nat/ppc-linux.h".
8352 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
8353 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
8354 (PT_ORIG_R3, PT_TRAP): Likewise.
8355 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
8356 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
8357 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
8359 2015-01-10 Joel Brobecker <brobecker@adacore.com>
8361 * i387-fp.c (i387_cache_to_xsave): In look over
8362 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
8363 zmmh_low_space field by use of zmmh_high_space.
8365 2015-01-09 Pedro Alves <palves@redhat.com>
8367 * linux-low.c (step_over_bkpt): Move higher up in the file.
8368 (handle_extended_wait): Don't store the stop_pc here.
8369 (get_stop_pc): Adjust comments and rename to ...
8370 (check_stopped_by_breakpoint): ... this. Record whether the LWP
8371 stopped for a software breakpoint or hardware breakpoint.
8372 (thread_still_has_status_pending_p): New function.
8373 (status_pending_p_callback): Use
8374 thread_still_has_status_pending_p. If the event is no longer
8375 interesting, resume the LWP.
8376 (handle_tracepoints): Add assert.
8377 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
8378 (wstatus_maybe_breakpoint): New function.
8379 (cancel_breakpoint): Delete function.
8380 (check_stopped_by_watchpoint): New function, factored out from
8381 linux_low_filter_event.
8382 (lp_status_maybe_breakpoint): Delete function.
8383 (linux_low_filter_event): Remove filter_ptid argument.
8384 Leave thread group exits pending here. Store the LWP's stop PC.
8385 Always leave events pending.
8386 (linux_wait_for_event_filtered): Pull all events out of the
8387 kernel, and leave them all pending.
8388 (count_events_callback, select_event_lwp_callback): Consider all
8390 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
8391 (select_event_lwp): Only give preference to the stepping LWP in
8392 all-stop mode. Adjust comments.
8393 (ignore_event): New function.
8394 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
8395 references to cancel_breakpoints. Adjust to renames. Also give
8396 equal priority to all LWPs that have had events in non-stop mode.
8397 If reporting a software breakpoint event, unadjust the LWP's PC.
8398 (linux_wait): If linux_wait_1 returned an ignored event, retry.
8399 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
8401 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
8402 (resume_status_pending_p): Use thread_still_has_status_pending_p.
8403 (linux_stopped_by_watchpoint): Adjust.
8404 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
8405 * linux-low.h (enum lwp_stop_reason): New.
8406 (struct lwp_info) <stop_pc>: Adjust comment.
8407 <stopped_by_watchpoint>: Delete field.
8408 <stop_reason>: New field.
8409 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
8410 * mem-break.c (software_breakpoint_inserted_here)
8411 (hardware_breakpoint_inserted_here): New function.
8412 * mem-break.h (software_breakpoint_inserted_here)
8413 (hardware_breakpoint_inserted_here): Declare.
8414 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
8415 (cancel_breakpoints): Delete.
8416 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
8417 (upload_fast_traceframes): Remove references to
8420 2015-01-09 Pedro Alves <palves@redhat.com>
8422 * thread-db.c (find_new_threads_callback): Ignore thread if the
8423 kernel thread ID is -1.
8425 2015-01-09 Pedro Alves <palves@redhat.com>
8427 * linux-low.c (linux_attach_fail_reason_string): Move to
8428 nat/linux-ptrace.c, and rename.
8429 (linux_attach_lwp): Update comment.
8430 (attach_proc_task_lwp_callback): New function.
8431 (linux_attach): Adjust to rename and use
8432 linux_proc_attach_tgid_threads.
8433 (linux_attach_fail_reason_string): Delete declaration.
8435 2015-01-01 Joel Brobecker <brobecker@adacore.com>
8437 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
8438 * server.c (gdbserver_version): Likewise.
8440 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
8442 * remote-utils.c: Include ctype.h.
8443 (input_interrupt): Explicitly handle the case when the char
8444 received is the NUL byte. Improve the printing of non-ASCII
8447 2014-12-16 Joel Brobecker <brobecker@adacore.com>
8449 * linux-low.c (linux_low_filter_event): Update call to
8450 linux_enable_event_reporting following the addition of
8451 a new parameter to that function.
8453 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
8456 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
8457 (AARCH64_FPCR_REGNO): Likewise.
8458 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
8459 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
8460 (aarch64_store_fpregset): Likewise.
8462 2014-12-15 Joel Brobecker <brobecker@adacore.com>
8464 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
8465 Remove FIXME comment about assumption about N.
8467 2014-12-13 Joel Brobecker <brobecker@adacore.com>
8469 * configure.ac: If large-file support is disabled in GDBserver,
8470 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
8471 * configure: Regenerate.
8473 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
8475 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
8476 warning upon ENODATA from ptrace.
8477 * linux-s390-low.c (s390_store_tdb): New.
8478 (s390_regsets): Add regset for NT_S390_TDB.
8480 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
8482 * linux-low.c (regsets_store_inferior_registers): Skip regsets
8483 without a fill_function.
8484 * linux-s390-low.c (s390_fill_last_break): Remove.
8485 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
8486 (s390_arch_setup): Use regset's size instead of fill_function for
8489 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
8491 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
8492 the regset's store function when ptrace returned an error.
8493 * regcache.c (get_thread_regcache): Invalidate register cache
8494 before fetching inferior's registers.
8496 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
8498 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
8499 while-loop as for-loop.
8500 (regsets_store_inferior_registers): Likewise.
8502 2014-11-28 Yao Qi <yao@codesourcery.com>
8504 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
8505 * config.in, configure: Re-generate.
8506 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
8509 2014-11-21 Yao Qi <yao@codesourcery.com>
8511 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
8512 (AC_CHECK_HEADERS): Remove malloc.h.
8513 * configure: Re-generated.
8514 * config.in: Re-generated.
8515 * server.h: Don't include alloca.h and malloc.h.
8516 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
8517 Don't include malloc.h.
8519 2014-11-17 Joel Brobecker <brobecker@adacore.com>
8521 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
8522 corresponding ERRNO check in same block.
8524 2014-11-12 Pedro Alves <palves@redhat.com>
8526 * server.c (cont_thread): Update comment.
8527 (start_inferior, attach_inferior): No longer clear cont_thread.
8528 (handle_v_cont): No longer set cont_thread.
8529 (captured_main): Clear cont_thread each time a GDB connects.
8531 2014-11-12 Pedro Alves <palves@redhat.com>
8533 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
8534 thread, and don't resume all threads if the Hc thread has exited.
8536 2014-11-12 Pedro Alves <palves@redhat.com>
8538 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
8539 the process group instead of to a specific LWP.
8541 2014-10-15 Pedro Alves <palves@redhat.com>
8544 * win32-arm-low.c (arm_set_thread_context): Remove current_event
8546 (arm_set_thread_context): Delete.
8547 (the_low_target): Adjust.
8548 * win32-i386-low.c (debug_registers_changed)
8549 (debug_registers_used): Delete.
8550 (update_debug_registers_callback): New function.
8551 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
8552 needing to update their debug registers.
8553 (win32_get_current_dr): New function.
8554 (x86_dr_low_get_addr, x86_dr_low_get_control)
8555 (x86_dr_low_get_status): Fetch the debug register from the thread
8557 (i386_initial_stuff): Adjust.
8558 (i386_get_thread_context): Remove current_event parameter. Don't
8559 clear debug_registers_changed nor copy DR values to
8561 (i386_set_thread_context): Delete.
8562 (i386_prepare_to_resume): New function.
8563 (i386_thread_added): Mark the thread as needing to update irs
8565 (the_low_target): Remove i386_set_thread_context and install
8566 i386_prepare_to_resume.
8567 * win32-low.c (win32_get_thread_context): Adjust.
8568 (win32_set_thread_context): Use SetThreadContext
8570 (win32_prepare_to_resume): New function.
8571 (win32_require_context): New function, factored out from ...
8572 (thread_rec): ... this.
8573 (continue_one_thread): Call win32_prepare_to_resume on each thread
8574 we're about to continue.
8575 (win32_resume): Call win32_prepare_to_resume on the event thread.
8576 * win32-low.h (struct win32_thread_info)
8577 <debug_registers_changed>: New field.
8578 (struct win32_target_ops): Change prototype of set_thread_context,
8579 delete set_thread_context and add prepare_to_resume.
8580 (win32_require_context): New declaration.
8582 2014-10-08 Gary Benson <gbenson@redhat.com>
8584 * server.h: Do not include common-exceptions.h.
8586 2014-10-08 Gary Benson <gbenson@redhat.com>
8588 * server.h: Do not include cleanups.h.
8590 2014-09-30 James Hogan <james.hogan@imgtec.com>
8592 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
8595 2014-09-23 Yao Qi <yao@codesourcery.com>
8597 * linux-low.c (lp_status_maybe_breakpoint): New function.
8598 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
8599 (count_events_callback): Likewise.
8600 (select_event_lwp_callback): Likewise.
8601 (cancel_breakpoints_callback): Likewise.
8603 2014-09-19 Don Breazeal <donb@codesourcery.com>
8605 * linux-low.c (handle_extended_wait): Call
8606 linux_ptrace_get_extended_event.
8607 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
8608 linux_is_extended_waitstatus.
8610 2014-09-16 Joel Brobecker <brobecker@adacore.com>
8612 * Makefile.in (CPPFLAGS): Define.
8613 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
8614 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
8616 2014-09-16 Gary Benson <gbenson@redhat.com>
8618 * inferiors.h (current_inferior): Renamed as...
8619 (current_thread): New variable. All uses updated.
8620 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
8621 (maybe_move_out_of_jump_pad): Likewise.
8622 (cancel_breakpoint): Likewise.
8623 (linux_low_filter_event): Likewise.
8624 (wait_for_sigstop): Likewise.
8625 (linux_resume_one_lwp): Likewise.
8626 (need_step_over_p): Likewise.
8627 (start_step_over): Likewise.
8628 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
8629 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
8630 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
8631 and save_inferior as saved_thread.
8632 * regcache.c (get_thread_regcache): Renamed saved_inferior as
8634 (regcache_invalidate_thread): Likewise.
8635 * remote-utils.c (prepare_resume_reply): Likewise.
8636 * thread-db.c (thread_db_get_tls_address): Likewise.
8637 (disable_thread_event_reporting): Likewise.
8638 (remove_thread_event_breakpoints): Likewise.
8639 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
8641 * target.h (set_desired_inferior): Renamed as...
8642 (set_desired_thread): New declaration. All uses updated.
8643 * server.c (myresume): Updated comment to reference thread instead
8645 (handle_serial_event): Likewise.
8646 (handle_target_event): Likewise.
8648 2014-09-12 Tom Tromey <tromey@redhat.com>
8649 Gary Benson <gbenson@redhat.com>
8651 * regcache.h: Include common-regcache.h.
8652 (regcache_read_pc): Don't declare.
8653 * regcache.c (get_thread_regcache_for_ptid): New function.
8655 2014-09-11 Tom Tromey <tromey@redhat.com>
8656 Gary Benson <gbenson@redhat.com>
8658 * symbol.c: New file.
8659 * Makefile.in (SFILES): Add symbol.c.
8660 (OBS): Add symbol.o.
8662 2014-09-11 Gary Benson <gbenson@redhat.com>
8664 * target.c (target_stop_ptid, target_continue_ptid): New
8667 2014-09-11 Tom Tromey <tromey@redhat.com>
8668 Gary Benson <gbenson@redhat.com>
8670 * target.h: Include target/target.h.
8671 * target.c (target_read_memory, target_read_uint32)
8672 (target_write_memory): New functions.
8674 2014-09-11 Gary Benson <gbenson@redhat.com>
8676 * server.h (debug_hw_points): Don't declare.
8677 * server.c (debug_hw_points): Don't define. Replace all uses
8678 with show_debug_regs.
8679 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
8680 all uses with show_debug_regs.
8682 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
8684 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
8685 endianness into account.
8686 (ppc_supply_ptrace_register): Likewise.
8688 2014-09-03 James Hogan <james.hogan@imgtec.com>
8690 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
8691 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
8693 2014-09-03 Gary Benson <gbenson@redhat.com>
8695 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
8696 ALL_DEBUG_ADDRESS_REGISTERS.
8698 2014-09-02 Gary Benson <gbenson@redhat.com>
8700 * i386-low.h: Renamed as...
8701 * x86-low.h: New file. All type, function and variable name
8702 prefixes changed from "i386_" to "x86_". All references updated.
8703 * i386-low.c: Renamed as...
8704 * x86-low.c: New file. All type, function and variable name
8705 prefixes changed from "i386_" to "x86_". All references updated.
8707 2014-09-02 Gary Benson <gbenson@redhat.com>
8709 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
8710 (x86_linux_new_thread): Likewise.
8712 2014-08-29 Gary Benson <gbenson@redhat.com>
8714 * server.h (setjmp.h): Do not include.
8715 (toplevel): Do not declare.
8716 (common-exceptions.h): Include.
8717 (cleanups.h): Likewise.
8718 * server.c (toplevel): Do not define.
8719 (exit_code): New static global.
8720 (detach_or_kill_for_exit_cleanup): New function.
8721 (main): New function. Original main renamed to...
8722 (captured_main): New function.
8723 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
8725 2014-08-29 Gary Benson <gbenson@redhat.com>
8727 * Makefile.in (SFILES): Add common/common-exceptions.c.
8728 (OBS): Add common-exceptions.o.
8729 (common-exceptions.o): New rule.
8730 * utils.c (prepare_to_throw_exception): New function.
8732 2014-08-29 Gary Benson <gbenson@redhat.com>
8734 * config.in: Regenerate.
8735 * configure: Likewise.
8737 2014-08-29 Gary Benson <gbenson@redhat.com>
8739 * Makefile.in (SFILES): Add common/cleanups.c.
8741 (cleanups.o): New rule.
8743 2014-08-29 Gary Benson <gbenson@redhat.com>
8745 * utils.c (internal_vwarning): New function.
8747 2014-08-28 Gary Benson <gbenson@redhat.com>
8749 * utils.h (fatal): Remove declaration.
8750 * utils.c (fatal): Remove function.
8752 2014-08-28 Gary Benson <gbenson@redhat.com>
8754 * tracepoint.c (gdb_agent_init): Replace fatal with
8756 (initialize_tracepoint): Likewise.
8758 2014-08-28 Gary Benson <gbenson@redhat.com>
8760 * remote-utils.c (remote_prepare): Replace fatal with error.
8762 2014-08-28 Gary Benson <gbenson@redhat.com>
8764 * linux-low.c (linux_async): Replace fatal with warning.
8766 (linux_start_non_stop): Return -1 if linux_async failed.
8768 2014-08-28 Gary Benson <gbenson@redhat.com>
8770 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
8772 (i386_dr_low_get_addr): Remove vague comment.
8773 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
8776 2014-08-28 Gary Benson <gbenson@redhat.com>
8778 * inferiors.c (get_thread_process): Replace check with gdb_assert.
8779 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
8781 (linux_resume_one_lwp): Likewise.
8782 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
8784 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
8785 with internal_error.
8786 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
8787 (init_register_cache): Replace fatal with gdb_assert_not_reached.
8788 (find_register_by_name): Replace fatal with internal_error.
8789 (find_regno): Likewise.
8790 * tdesc.c (init_target_desc): Replace check with gdb_assert.
8791 * thread-db.c (thread_db_create_event): Likewise.
8792 (thread_db_load_search): Likewise.
8793 (try_thread_db_load_1): Likewise.
8794 * tracepoint.c (get_jump_space_head): Replace fatal with
8796 (claim_trampoline_space): Likewise.
8797 (have_fast_tracepoint_trampoline_buffer): Likewise.
8798 (cmd_qtstart): Likewise.
8799 (stop_tracing): Likewise.
8800 (fast_tracepoint_collecting): Likewise.
8801 (target_malloc): Likewise.
8802 (download_tracepoint): Likewise.
8803 (download_trace_state_variables): Replace check with gdb_assert.
8804 (upload_fast_traceframes): Replace fatal with internal_error.
8806 2014-08-19 Tom Tromey <tromey@redhat.com>
8807 Gary Benson <gbenson@redhat.com>
8809 * Makefile.in (SFILES): Add common/common-debug.c.
8810 (OBS): Add common-debug.o.
8811 (common-debug.o): New rule.
8812 * debug.h (debug_printf): Don't declare.
8813 * debug.c (debug_printf): Renamed and rewritten as...
8814 (debug_vprintf): New function.
8816 2014-08-19 Gary Benson <gbenson@redhat.com>
8818 * utils.h: Do not include print-utils.h.
8820 2014-08-19 Tom Tromey <tromey@redhat.com>
8821 Gary Benson <gbenson@redhat.com>
8823 * server.h: Add static assertion.
8824 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
8826 2014-08-19 Tom Tromey <tromey@redhat.com>
8827 Gary Benson <gbenson@redhat.com>
8829 * Makefile.in (SFILES): Add common/errors.c.
8830 (OBS): Add errors.o.
8831 (IPA_OBS): Add errors-ipa.o.
8832 (errors.o): New rule.
8833 (errors-ipa.o): Likewise.
8834 * utils.h (perror_with_name, error, warning): Don't declare.
8835 * utils.c (warning): Renamed and rewritten as...
8836 (vwarning): New function.
8837 (error): Renamed and rewritten as...
8838 (verror): New function.
8839 (internal_error): Renamed and rewritten as...
8840 (internal_verror): New function.
8842 2014-08-07 Gary Benson <gbenson@redhat.com>
8844 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
8845 * configure: Regenerate.
8846 * config.in: Likewise.
8847 * server.h: Do not include errno.h.
8848 * event-loop.c: Likewise.
8849 * hostio-errno.c: Likewise.
8850 * linux-low.c: Likewise.
8851 * remote-utils.c: Likewise.
8852 * spu-low.c: Likewise.
8853 * utils.c: Likewise.
8854 * gdbreplay.c: Unconditionally include errno.h.
8856 2014-08-07 Gary Benson <gbenson@redhat.com>
8858 * server.h: Do not include string.h.
8859 * event-loop.c: Likewise.
8860 * linux-low.c: Likewise.
8861 * regcache.c: Likewise.
8862 * remote-utils.c: Likewise.
8863 * spu-low.c: Likewise.
8864 * utils.c: Likewise.
8866 2014-08-07 Gary Benson <gbenson@redhat.com>
8868 * server.h: Do not include gdb_assert.h.
8870 2014-08-07 Gary Benson <gbenson@redhat.com>
8872 * server.h: Do not include common-utils.h.
8874 2014-08-07 Gary Benson <gbenson@redhat.com>
8876 * server.h: Do not include ptid.h.
8877 * notif.h: Likewise.
8879 2014-08-07 Gary Benson <gbenson@redhat.com>
8881 * server.h: Do not include gdb_locale.h.
8883 2014-08-07 Gary Benson <gbenson@redhat.com>
8885 * server.h: Do not include gdb/signals.h.
8886 * win32-low.c: Likewise.
8888 2014-08-07 Gary Benson <gbenson@redhat.com>
8890 * server.h: Do not include pathmax.h.
8892 2014-08-07 Gary Benson <gbenson@redhat.com>
8894 * server.h: Do not include libiberty.h.
8895 * linux-bfin-low.c: Likewise.
8897 2014-08-07 Gary Benson <gbenson@redhat.com>
8899 * server.h: Do not include ansidecl.h.
8901 2014-08-07 Gary Benson <gbenson@redhat.com>
8903 * linux-x86-low.c: Do not include stddef.h.
8904 * lynx-ppc-low.c: Likewise.
8905 * tracepoint.c: Likewise.
8907 2014-08-07 Gary Benson <gbenson@redhat.com>
8909 * server.h: Do not include stdarg.h.
8910 * nto-low.c: Likewise.
8912 2014-08-07 Gary Benson <gbenson@redhat.com>
8914 * server.h: Do not include stdlib.h.
8915 * inferiors.c: Likewise.
8916 * linux-low.c: Likewise.
8917 * regcache.c: Likewise.
8918 * spu-low.c: Likewise.
8919 * tracepoint.c: Likewise.
8920 * utils.c: Likewise.
8922 2014-08-07 Gary Benson <gbenson@redhat.com>
8924 * server.h: Do not include stdio.h.
8925 * linux-low.c: Likewise.
8926 * remote-utils.c: Likewise.
8927 * spu-low.c: Likewise.
8928 * utils.c: Likewise.
8929 * wincecompat.c: Likewise.
8931 2014-08-06 Gary Benson <gbenson@redhat.com>
8933 * regcache.c (init_register_cache): Move conditionals inside if.
8935 2014-08-06 Gary Benson <gbenson@redhat.com>
8937 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
8939 2014-07-31 Gary Benson <gbenson@redhat.com>
8941 * ax.h: Do not include server.h.
8942 * gdbthread.h: Likewise.
8943 * lynx-low.h: Likewise.
8944 * notif.h: Likewise.
8946 2014-07-30 Gary Benson <gbenson@redhat.com>
8948 * server.h: Include common-defs.h.
8949 Do not include config.h or build-gnulib-gdbserver/config.h.
8951 2014-07-30 Gary Benson <gbenson@redhat.com>
8953 * hostio-errno.c: Move server.h to top of includes list.
8954 * inferiors.c: Likewise.
8955 * linux-x86-low.c: Likewise.
8956 * notif.c: Include server.h.
8958 2014-07-24 Tom Tromey <tromey@redhat.com>
8959 Gary Benson <gbenson@redhat.com>
8961 * server.h (CORE_ADDR): Now unsigned.
8963 2014-07-16 Pedro Alves <palves@redhat.com>
8965 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
8967 2014-07-15 Pedro Alves <palves@redhat.com>
8969 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
8972 2014-07-11 Pedro Alves <palves@redhat.com>
8974 * linux-low.c (kill_wait_lwp): New function, based on
8975 kill_one_lwp_callback, but use my_waitpid directly.
8976 (kill_one_lwp_callback, linux_kill): Use it.
8978 2014-06-23 Pedro Alves <palves@redhat.com>
8980 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
8981 before setting DR0..DR3.
8983 2014-06-20 Gary Benson <gbenson@redhat.com>
8985 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
8986 * configure: Regenerated.
8987 * config.in: Likewise.
8989 2014-06-20 Gary Benson <gbenson@redhat.com>
8991 * Makefile.in (SFILES): Update locations for files moved
8993 (object file files): Reordered.
8995 2014-06-20 Gary Benson <gbenson@redhat.com>
8997 * i386-low.h (i386_dr_low_can_set_addr): Removed.
8998 (i386_dr_low_set_addr): Likewise.
8999 (i386_dr_low_get_addr): Likewise.
9000 (i386_dr_low_can_set_control): Likewise.
9001 (i386_dr_low_set_control): Likewise.
9002 (i386_dr_low_get_control): Likewise.
9003 (i386_dr_low_get_status): Likewise.
9004 (i386_get_debug_register_length): Likewise.
9005 * linux-x86-low.c (i386_dr_low_set_addr):
9006 Changed signature. Made static.
9007 (i386_dr_low_get_addr): Likewise.
9008 (i386_dr_low_set_control): Likewise.
9009 (i386_dr_low_get_control): Likewise.
9010 (i386_dr_low_get_status): Likewise.
9011 (i386_dr_low): New global variable.
9012 * win32-i386-low.c (i386_dr_low_set_addr):
9013 Changed signature. Made static.
9014 (i386_dr_low_get_addr): Likewise.
9015 (i386_dr_low_set_control): Likewise.
9016 (i386_dr_low_get_control): Likewise.
9017 (i386_dr_low_get_status): Likewise.
9018 (i386_dr_low): New global variable.
9020 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
9022 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
9023 * Makefile.in (AR, AR_FLAGS): Define.
9024 * configure: Regenerate.
9026 2014-06-19 Gary Benson <gbenson@redhat.com>
9028 * Makefile.in (i386-dregs.o): New rule.
9029 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
9030 * i386-low.c (target.h): Remove include.
9031 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
9032 (DR_CONTROL_SHIFT): Likewise.
9033 (DR_CONTROL_SIZE): Likewise.
9034 (DR_RW_EXECUTE): Likewise.
9035 (DR_RW_WRITE): Likewise.
9036 (DR_RW_READ): Likewise.
9037 (DR_RW_IORW): Likewise.
9038 (DR_LEN_1): Likewise.
9039 (DR_LEN_2): Likewise.
9040 (DR_LEN_4): Likewise.
9041 (DR_LEN_8): Likewise.
9042 (DR_LOCAL_ENABLE_SHIFT): Likewise.
9043 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
9044 (DR_ENABLE_SIZE): Likewise.
9045 (DR_LOCAL_SLOWDOWN): Likewise.
9046 (DR_GLOBAL_SLOWDOWN): Likewise.
9047 (DR_CONTROL_RESERVED): Likewise.
9048 (I386_DR_CONTROL_MASK): Likewise.
9049 (I386_DR_VACANT): Likewise.
9050 (I386_DR_LOCAL_ENABLE): Likewise.
9051 (I386_DR_GLOBAL_ENABLE): Likewise.
9052 (I386_DR_DISABLE): Likewise.
9053 (I386_DR_SET_RW_LEN): Likewise.
9054 (I386_DR_GET_RW_LEN): Likewise.
9055 (I386_DR_WATCH_HIT): Likewise.
9056 (i386_wp_op_t): Likewise.
9057 (i386_show_dr): Likewise.
9058 (i386_length_and_rw_bits): Likewise.
9059 (i386_insert_aligned_watchpoint): Likewise.
9060 (i386_remove_aligned_watchpoint): Likewise.
9061 (i386_handle_nonaligned_watchpoint): Likewise.
9062 i386_update_inferior_debug_regs(): Likewise.
9063 (i386_dr_insert_watchpoint): Likewise.
9064 (i386_dr_remove_watchpoint): Likewise.
9065 (i386_dr_region_ok_for_watchpoint): Likewise.
9066 (i386_dr_stopped_data_address): Likewise.
9067 (i386_dr_stopped_by_watchpoint): Likewise.
9069 2014-06-19 Gary Benson <gbenson@redhat.com>
9071 * i386-low.c (i386_dr_show): Renamed to
9072 i386_show_dr and made static. All uses updated.
9073 (i386_dr_length_and_rw_bits): Renamed to
9074 i386_length_and_rw_bits and made static.
9076 (i386_dr_insert_aligned_watchpoint): Renamed to
9077 i386_insert_aligned_watchpoint and made static.
9079 (i386_dr_remove_aligned_watchpoint): Renamed to
9080 i386_remove_aligned_watchpoint and made static.
9082 (i386_dr_update_inferior_debug_regs): Renamed to
9083 i386_update_inferior_debug_regs and made static.
9086 2014-06-18 Gary Benson <gbenson@redhat.com>
9088 * i386-low.h (i386_dr_low_can_set_addr): New macro.
9089 (i386_dr_low_can_set_control): Likewise.
9090 (i386_get_debug_register_length): Likewise.
9091 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
9092 (i386_dr_low_can_set_control): Likewise.
9093 (i386_get_debug_register_length): Likewise.
9095 2014-06-17 Gary Benson <gbenson@redhat.com>
9097 * i386-low.h (i386-dregs.h): New include.
9098 (DR_FIRSTADDR): Now in i386-dregs.h.
9099 (DR_LASTADDR): Likewise.
9100 (DR_NADDR): Likewise.
9101 (DR_STATUS): Likewise.
9102 (DR_CONTROL): Likewise.
9103 (i386_debug_reg_state): Likewise.
9104 (i386_dr_insert_watchpoint): Likewise.
9105 (i386_dr_remove_watchpoint): Likewise.
9106 (i386_dr_region_ok_for_watchpoint): Likewise.
9107 (i386_dr_stopped_data_address): Likewise.
9108 (i386_dr_stopped_by_watchpoint): Likewise.
9109 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
9111 2014-06-18 Gary Benson <gbenson@redhat.com>
9113 * i386-low.h (i386_low_insert_watchpoint): Renamed to
9114 i386_dr_insert_watchpoint.
9115 (i386_low_remove_watchpoint): Renamed to
9116 i386_dr_remove_watchpoint.
9117 (i386_low_region_ok_for_watchpoint): Renamed to
9118 i386_dr_region_ok_for_watchpoint.
9119 (i386_low_stopped_data_address): Renamed to
9120 i386_dr_stopped_data_address.
9121 (i386_low_stopped_by_watchpoint): Renamed to
9122 i386_dr_stopped_by_watchpoint.
9123 * i386-low.c (i386_show_dr): Renamed to
9124 i386_dr_show and made nonstatic. All uses updated.
9125 (i386_length_and_rw_bits): Renamed to
9126 i386_dr_length_and_rw_bits and made nonstatic.
9128 (i386_insert_aligned_watchpoint): Renamed to
9129 i386_dr_insert_aligned_watchpoint and made nonstatic.
9131 (i386_remove_aligned_watchpoint): Renamed to
9132 i386_dr_remove_aligned_watchpoint and made nonstatic.
9134 (i386_update_inferior_debug_regs): Renamed to
9135 i386_dr_update_inferior_debug_regs and made nonstatic.
9137 (i386_low_insert_watchpoint): Renamed to
9138 i386_dr_insert_watchpoint. All uses updated.
9139 (i386_low_remove_watchpoint): Renamed to
9140 i386_dr_remove_watchpoint. All uses updated.
9141 (i386_low_region_ok_for_watchpoint): Renamed to
9142 i386_dr_region_ok_for_watchpoint. All uses updated.
9143 (i386_low_stopped_data_address): Renamed to
9144 i386_dr_stopped_data_address. All uses updated.
9145 (i386_low_stopped_by_watchpoint): Renamed to
9146 i386_dr_stopped_by_watchpoint. All uses updated.
9148 2014-06-18 Gary Benson <gbenson@redhat.com>
9150 * i386-low.c (i386_dr_low_can_set_addr): New macro.
9151 (i386_dr_low_can_set_control): Likewise.
9152 (i386_insert_aligned_watchpoint): New check.
9154 2014-06-18 Gary Benson <gbenson@redhat.com>
9156 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
9159 2014-06-18 Gary Benson <gbenson@redhat.com>
9161 * i386-low.c (i386_length_and_rw_bits): Use internal_error
9162 instead of fatal and error.
9163 (i386_handle_nonaligned_watchpoint): Likewise.
9165 2014-06-18 Gary Benson <gbenson@redhat.com>
9167 * i386-low.c (i386_get_debug_register_length): New macro.
9168 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
9169 (i386_show_dr): Use debug_printf instead of fprintf. Use
9170 phex to format values.
9172 2014-06-18 Gary Benson <gbenson@redhat.com>
9174 * i386-low.h: Comment changes.
9175 * i386-low.c: Likewise.
9177 2014-06-18 Gary Benson <gbenson@redhat.com>
9179 * i386-low.c: Whitespace changes.
9181 2014-06-12 Tom Tromey <tromey@redhat.com>
9183 * utils.c (freeargv): Remove.
9185 2014-06-12 Tom Tromey <tromey@redhat.com>
9187 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
9188 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
9189 (parse_debug_format_options): Likewise.
9190 (gdbserver_usage): Likewise.
9191 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
9192 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
9193 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
9195 ($(LIBGNU)): Depend on libiberty.
9196 (all-lib): Recurse into all subdirs.
9197 (install-only): Invoke "install" target in subdirs.
9198 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
9200 * configure: Rebuild.
9201 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
9202 for vasprintf, vsnprintf, or gettimeofday.
9203 * configure.srv: Don't add safe-ctype.o or lbasename.o to
9206 2014-06-05 Joel Brobecker <brobecker@adacore.com>
9208 * development.sh: Delete.
9209 * Makefile.in (config.status): Adjust dependency on development.sh.
9210 * configure.ac: Adjust development.sh source call.
9211 * configure: Regenerate.
9213 2014-06-02 Pedro Alves <palves@redhat.com>
9215 * ax.c (gdb_free_agent_expr): New function.
9216 * ax.h (gdb_free_agent_expr): New declaration.
9217 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
9219 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
9221 (clear_breakpoint_conditions_and_commands): New function.
9222 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
9223 (clear_breakpoint_conditions_and_commands): New declaration.
9225 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
9227 * linux-aarch64-low.c (asm/ptrace.h): Include.
9229 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
9231 Fix TLS access for -static -pthread.
9232 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
9233 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
9234 (thread_db_load_search, try_thread_db_load_1): Initialize it.
9236 2014-05-20 Pedro Alves <palves@redhat.com>
9238 * linux-aarch64-low.c (aarch64_insert_point)
9239 (aarch64_remove_point): No longer check whether the type is
9240 supported here. Adjust to new interface.
9241 (the_low_target): Install aarch64_supports_z_point_type as
9242 supports_z_point_type method.
9243 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
9244 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
9245 instead of a Z packet char. Adjust.
9246 (arm_supports_z_point_type): New function.
9247 (arm_insert_point, arm_remove_point): Adjust to new interface.
9248 (the_low_target): Install arm_supports_z_point_type.
9249 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
9250 (cris_insert_point, cris_remove_point): Adjust to new interface.
9251 Don't check whether the type is supported here.
9252 (the_low_target): Install cris_supports_z_point_type.
9253 * linux-low.c (linux_supports_z_point_type): New function.
9254 (linux_insert_point, linux_remove_point): Adjust to new interface.
9255 * linux-low.h (struct linux_target_ops) <insert_point,
9256 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
9257 raw_breakpoint pointer parameter.
9258 <supports_z_point_type>: New method.
9259 * linux-mips-low.c (mips_supports_z_point_type): New function.
9260 (mips_insert_point, mips_remove_point): Adjust to new interface.
9261 Use mips_supports_z_point_type.
9262 (the_low_target): Install mips_supports_z_point_type.
9263 * linux-ppc-low.c (the_low_target): Install NULL as
9264 supports_z_point_type method.
9265 * linux-s390-low.c (the_low_target): Install NULL as
9266 supports_z_point_type method.
9267 * linux-sparc-low.c (the_low_target): Install NULL as
9268 supports_z_point_type method.
9269 * linux-x86-low.c (x86_supports_z_point_type): New function.
9270 (x86_insert_point): Adjust to new insert_point interface. Use
9271 insert_memory_breakpoint. Adjust to new
9272 i386_low_insert_watchpoint interface.
9273 (x86_remove_point): Adjust to remove_point interface. Use
9274 remove_memory_breakpoint. Adjust to new
9275 i386_low_remove_watchpoint interface.
9276 (the_low_target): Install x86_supports_z_point_type.
9277 * lynx-low.c (lynx_target_ops): Install NULL as
9278 supports_z_point_type callback.
9279 * nto-low.c (nto_supports_z_point_type): New.
9280 (nto_insert_point, nto_remove_point): Adjust to new interface.
9281 (nto_target_ops): Install nto_supports_z_point_type.
9282 * mem-break.c: Adjust intro comment.
9283 (struct raw_breakpoint) <raw_type, size>: New fields.
9284 <inserted>: Update comment.
9285 <shlib_disabled>: Delete field.
9286 (enum bkpt_type) <gdb_breakpoint>: Delete value.
9287 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
9288 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
9289 (raw_bkpt_type_to_target_hw_bp_type): New function.
9290 (find_enabled_raw_code_breakpoint_at): New function.
9291 (find_raw_breakpoint_at): New type and size parameters. Use them.
9292 (insert_memory_breakpoint): New function, based off
9293 set_raw_breakpoint_at.
9294 (remove_memory_breakpoint): New function.
9295 (set_raw_breakpoint_at): Reimplement.
9296 (set_breakpoint): New, based on set_breakpoint_at.
9297 (set_breakpoint_at): Reimplement.
9298 (delete_raw_breakpoint): Go through the_target->remove_point
9299 instead of assuming memory breakpoints.
9300 (find_gdb_breakpoint_at): Delete.
9301 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
9302 (find_gdb_breakpoint): New function.
9303 (set_gdb_breakpoint_at): Delete.
9304 (z_type_supported): New function.
9305 (set_gdb_breakpoint_1): New function, loosely based off
9306 set_gdb_breakpoint_at.
9307 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
9308 (delete_gdb_breakpoint_at): Delete.
9309 (delete_gdb_breakpoint_1): New function, loosely based off
9310 delete_gdb_breakpoint_at.
9311 (delete_gdb_breakpoint): New function.
9312 (clear_gdb_breakpoint_conditions): Rename to ...
9313 (clear_breakpoint_conditions): ... this. Don't handle a NULL
9315 (add_condition_to_breakpoint): Make static.
9316 (add_breakpoint_condition): Take a struct breakpoint pointer
9317 instead of an address. Adjust.
9318 (gdb_condition_true_at_breakpoint): Rename to ...
9319 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
9321 (gdb_condition_true_at_breakpoint): Reimplement.
9322 (add_breakpoint_commands): Take a struct breakpoint pointer
9323 instead of an address. Adjust.
9324 (gdb_no_commands_at_breakpoint): Rename to ...
9325 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
9326 parameter. Return true if no breakpoint was found. Change debug
9328 (gdb_no_commands_at_breakpoint): Reimplement.
9329 (run_breakpoint_commands): Rename to ...
9330 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
9331 and change return type to boolean.
9332 (run_breakpoint_commands): New function.
9333 (gdb_breakpoint_here): Also check for Z1 breakpoints.
9334 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
9335 breakpoint. Go through the_target->remove_point instead of
9336 assuming memory breakpoint.
9337 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
9338 software and hardware breakpoints.
9339 (reinsert_raw_breakpoint): Go through the_target->insert_point
9340 instead of assuming memory breakpoint.
9341 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
9342 software and hardware breakpoints.
9343 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
9344 Check both software and hardware breakpoints.
9345 (validate_inserted_breakpoint): Assert the breakpoint is a
9346 software breakpoint. Set the inserted flag to -1 instead of
9347 setting shlib_disabled.
9348 (delete_disabled_breakpoints): Adjust.
9349 (validate_breakpoints): Only validate software breakpoints.
9350 Adjust to inserted flag change.
9351 (check_mem_read, check_mem_write): Skip breakpoint types other
9352 than software breakpoints. Adjust to inserted flag change.
9353 * mem-break.h (enum raw_bkpt_type): New enum.
9354 (raw_breakpoint, struct process_info): Forward declare.
9355 (Z_packet_to_target_hw_bp_type): Delete declaration.
9356 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
9357 (set_gdb_breakpoint, delete_gdb_breakpoint)
9358 (clear_breakpoint_conditions): New declarations.
9359 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
9360 (breakpoint_inserted_here): Update comment.
9361 (add_breakpoint_condition, add_breakpoint_commands): Replace
9362 address parameter with a breakpoint pointer parameter.
9363 (gdb_breakpoint_here): Update comment.
9364 (delete_gdb_breakpoint_at): Delete.
9365 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
9366 * server.c (process_point_options): Take a struct breakpoint
9367 pointer instead of an address. Adjust.
9368 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
9369 delete_gdb_breakpoint.
9370 * spu-low.c (spu_target_ops): Install NULL as
9371 supports_z_point_type method.
9372 * target.h: Include mem-break.h.
9373 (struct target_ops) <prepare_to_access_memory>: Update comment.
9374 <supports_z_point_type>: New field.
9375 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
9376 instead of a char. Also take a raw breakpoint pointer.
9377 * win32-arm-low.c (the_low_target): Install NULL as
9378 supports_z_point_type.
9379 * win32-i386-low.c (i386_supports_z_point_type): New function.
9380 (i386_insert_point, i386_remove_point): Adjust to new interface.
9381 (the_low_target): Install i386_supports_z_point_type.
9382 * win32-low.c (win32_supports_z_point_type): New function.
9383 (win32_insert_point, win32_remove_point): Adjust to new interface.
9384 (win32_target_ops): Install win32_supports_z_point_type.
9385 * win32-low.h (struct win32_target_ops):
9386 <supports_z_point_type>: New method.
9387 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
9388 instead of a char. Also take a raw breakpoint pointer.
9390 2014-05-20 Pedro Alves <palves@redhat.com>
9392 * mem-break.h: Include break-common.h.
9393 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
9394 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
9395 (Z_packet_to_target_hw_bp_type): New declaration.
9396 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
9397 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
9398 (Z_PACKET_ACCESS_WP): Delete macros.
9399 (Z_packet_to_hw_type): Delete function.
9400 * i386-low.h: Don't include break-common.h here.
9401 (Z_packet_to_hw_type): Delete declaration.
9402 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
9403 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
9404 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
9405 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
9406 * linux-aarch64-low.c: Don't include break-common.h here.
9407 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
9408 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
9409 (Z_packet_to_target_hw_bp_type): Delete function.
9410 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
9412 (mips_insert_point, mips_remove_point): Use
9413 Z_packet_to_target_hw_bp_type.
9415 2014-05-20 Pedro Alves <palves@redhat.com>
9417 * linux-aarch64-low.c: Include break-common.h.
9418 (enum target_point_type): Delete.
9419 (Z_packet_to_point_type): Rename to ...
9420 (Z_packet_to_target_hw_bp_type): ... this, and return a
9421 target_hw_bp_type instead.
9422 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
9423 instead of an enum target_point_type.
9424 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
9426 (aarch64_dr_state_insert_one_point)
9427 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
9428 (aarch64_handle_aligned_watchpoint)
9429 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
9430 Take an enum target_hw_bp_type instead of an enum
9432 (aarch64_supports_z_point_type): New function.
9433 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
9434 use Z_packet_to_target_hw_bp_type.
9436 2014-05-20 Joel Brobecker <brobecker@adacore.com>
9438 * configure.ac: Only use -Werror by default when DEVELOPMENT
9440 * configure: Regenerate.
9442 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
9444 Fix gdbserver qGetTLSAddr for x86_64 -m32.
9445 * linux-x86-low.c (X86_64_USER_REGS): New.
9446 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
9448 2014-04-28 Yao Qi <yao@codesourcery.com>
9450 * Makefile.in (i386-avx512.c): Fix the typo of generated file
9453 2014-04-25 Pedro Alves <palves@redhat.com>
9456 * linux-low.c (linux_attach_fail_reason_string): New function.
9457 (linux_attach_lwp): Delete.
9458 (linux_attach_lwp_1): Rename to ...
9459 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
9460 argument. Remove "initial" parameter. Return int instead of
9461 void. Don't error or warn here.
9462 (linux_attach): Adjust to call linux_attach_lwp. Call error on
9463 failure to attach to the tgid. Call warning when failing to
9465 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
9466 argument. Remove "initial" parameter. Return int instead of
9467 void. Don't error or warn here.
9468 (linux_attach_fail_reason_string): New declaration.
9469 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
9470 interface change. Use linux_attach_fail_reason_string.
9472 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
9473 Walfred Tedeschi <walfred.tedeschi@intel.com>
9475 * Makefile.in: Added rules to handle new files
9476 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
9477 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
9478 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
9479 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
9480 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
9481 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
9483 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
9484 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
9485 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
9486 i386/x32-avx512.xml.
9487 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
9488 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
9489 i386/x32-avx512-linux.xml.
9490 * i387-fp.c (num_avx512_k_registers): New constant for number
9492 (num_avx512_zmmh_low_registers): New constant for number of
9493 lower ZMM registers (0-15).
9494 (num_avx512_zmmh_high_registers): New constant for number of
9495 higher ZMM registers (16-31).
9496 (num_avx512_ymmh_registers): New contant for number of higher
9497 YMM registers (ymm16-31 added by avx521 on x86_64).
9498 (num_avx512_xmm_registers): New constant for number of higher
9499 XMM registers (xmm16-31 added by AVX512 on x86_64).
9500 (struct i387_xsave): Add space for AVX512 registers.
9501 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
9502 Add code to handle AVX512 registers.
9503 (i387_xsave_to_cache): Add code to handle AVX512 registers.
9504 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
9505 prototypei from generated file.
9506 (tdesc_amd64_avx512_linux): Likewise.
9507 (init_registers_x32_avx512_linux): Likewise.
9508 (tdesc_x32_avx512_linux): Likewise.
9509 (init_registers_i386_avx512_linux): Likewise.
9510 (tdesc_i386_avx512_linux): Likewise.
9511 (x86_64_regmap): Add AVX512 registers.
9512 (x86_linux_read_description): Add code to handle AVX512 XSTATE
9514 (initialize_low_arch): Add code to initialize AVX512 registers.
9516 2014-04-23 Pedro Alves <palves@redhat.com>
9518 * mem-break.c (find_gdb_breakpoint_at): Make static.
9519 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
9521 2014-04-23 Pedro Alves <palves@redhat.com>
9523 * i386-low.c: Don't include break-common.h here.
9524 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
9525 prototype to take target_hw_bp_type as argument instead of a Z
9527 * i386-low.h: Include break-common.h here.
9528 (Z_packet_to_hw_type): Declare.
9529 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
9531 * linux-x86-low.c (x86_insert_point): Convert the packet number to
9532 a target_hw_bp_type before calling i386_low_insert_watchpoint.
9533 (x86_remove_point): Convert the packet number to a
9534 target_hw_bp_type before calling i386_low_remove_watchpoint.
9535 * win32-i386-low.c (i386_insert_point): Convert the packet number
9536 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
9537 (i386_remove_point): Convert the packet number to a
9538 target_hw_bp_type before calling i386_low_remove_watchpoint.
9540 2014-04-23 Pedro Alves <palves@redhat.com>
9542 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
9544 2014-04-10 Pedro Alves <palves@redhat.com>
9546 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
9547 Check if the condition or command is NULL before checking if the
9548 breakpoint is known. On success, return true.
9549 * mem-break.h (add_breakpoint_condition): Document return.
9550 (add_breakpoint_commands): Add describing comment.
9551 * server.c (skip_to_semicolon): New function.
9552 (process_point_options): Use it.
9554 2014-04-09 Pedro Alves <palves@redhat.com>
9556 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
9559 2014-02-27 Pedro Alves <palves@redhat.com>
9562 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
9564 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
9566 (last_thread_of_process_p): Take a PID argument instead of a
9568 (linux_wait_for_lwp): Delete.
9569 (num_lwps, check_zombie_leaders, not_stopped_callback): New
9571 (linux_low_filter_event): New function, party factored out from
9572 linux_wait_for_event.
9573 (linux_wait_for_event): Rename to ...
9574 (linux_wait_for_event_filtered): ... this. Add new filter ptid
9575 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
9576 sigsuspend. Check for zombie leaders.
9577 (linux_wait_for_event): Reimplement as wrapper around
9578 linux_wait_for_event_filtered.
9579 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
9580 a normal or signal exit is seen, it's the whole process exiting.
9581 (wait_for_sigstop): No longer a for_each_inferior callback.
9582 Rewrite on top of linux_wait_for_event_filtered.
9583 (stop_all_lwps): Call wait_for_sigstop directly.
9584 * server.c (resume, handle_target_event): Handle
9585 TARGET_WAITKIND_NO_RESUMED.
9587 2014-02-26 Joel Brobecker <brobecker@adacore.com>
9589 * win32-low.c (psapi_get_dll_name,
9590 * win32_CreateToolhelp32Snapshot): Delete.
9591 (win32_CreateToolhelp32Snapshot, win32_Module32First)
9592 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
9594 (handle_load_dll): Add function description.
9595 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
9597 2014-02-26 Joel Brobecker <brobecker@adacore.com>
9599 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
9601 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
9602 base address when calling win32_add_one_solib.
9603 (handle_load_dll): Delete local variable load_addr.
9604 Remove 0x1000 offset applied to DLL base address when calling
9605 win32_add_one_solib.
9606 (handle_unload_dll): Add comment.
9608 2014-02-26 Joel Brobecker <brobecker@adacore.com>
9610 * win32-low.c (win32_add_all_dlls): Renames
9611 win32_ensure_ntdll_loaded. Rewrite function documentation.
9612 Adjust implementation to always load all DLLs.
9613 Add 0x1000 offset to DLL base address when calling
9614 win32_add_one_solib.
9615 (child_initialization_done): New static global.
9616 (do_initial_child_stuff): Set child_initialization_done to
9617 zero during child initialization, and 1 after. Replace call
9618 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
9620 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
9621 (handle_unload_dll): Add function documentation.
9622 (get_child_debug_event): Ignore load and unload DLL events
9623 during child initialization.
9625 2014-02-20 Doug Evans <dje@google.com>
9627 Remove global all_lwps.
9628 * inferiors.h (ptid_of): Move here from linux-low.h.
9629 (pid_of, lwpid_of): Ditto.
9630 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
9631 parameter is a struct thread_info * now.
9632 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
9633 directly. Pass &all_threads to find_inferior instead of &all_lwps.
9634 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
9636 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
9637 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
9638 * linux-arm-low.c (update_registers_callback): Update, "entry"
9639 parameter is a struct thread_info * now.
9640 Fetch lwpid from current_inferior directly.
9641 (arm_insert_point): Pass &all_threads to find_inferior instead of
9643 (arm_remove_point): Ditto.
9644 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
9645 (arm_prepare_to_resume): Fetch pid from thread.
9646 (arm_read_description): Fetch lwpid from current_inferior directly.
9647 * linux-low.c (all_lwps): Delete.
9648 (delete_lwp): Delete call to remove_inferior.
9649 (handle_extended_wait): Fetch lwpid from thread.
9650 (add_lwp): Don't set lwp->entry.id. Remove call to
9651 add_inferior_to_list.
9652 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
9653 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
9654 (kill_one_lwp_callback): Ditto.
9655 (linux_kill): Don't dereference NULL pointer.
9656 Fetch ptid,lwpid from thread.
9657 (get_detach_signal): Fetch ptid from thread.
9658 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
9659 Simplify call to regcache_invalidate_thread.
9660 (delete_lwp_callback): Update, "entry" parameter is a
9661 struct thread_info * now. Fetch pid from thread.
9662 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
9663 (status_pending_p_callback): Update, "entry" parameter is a
9664 struct thread_info * now. Fetch ptid from thread.
9665 (find_lwp_pid): Update, "entry" parameter is a
9666 struct thread_info * now.
9667 (linux_wait_for_lwp): Fetch pid from thread.
9668 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
9669 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
9670 (enqueue_one_deferred_signal): Fetch lwpid from thread.
9671 (dequeue_one_deferred_signal): Ditto.
9672 (cancel_breakpoint): Fetch ptid from current_inferior.
9673 (linux_wait_for_event): Pass &all_threads to find_inferior,
9674 not &all_lwps. Fetch ptid, lwpid from thread.
9675 (count_events_callback): Update, "entry" parameter is a
9676 struct thread_info * now.
9677 (select_singlestep_lwp_callback): Ditto.
9678 (select_event_lwp_callback): Ditto.
9679 (cancel_breakpoints_callback): Ditto.
9680 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
9682 (select_event_lwp): Ditto. Fetch ptid from event_thread.
9683 (unsuspend_one_lwp): Update, "entry" parameter is a
9684 struct thread_info * now.
9685 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
9687 (linux_stabilize_threads): Ditto. And for for_each_inferior.
9688 Fetch lwpid from thread, not lwp.
9689 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
9690 Pass &all_threads to find_inferior, not &all_lwps.
9691 (send_sigstop): Fetch lwpid from thread, not lwp.
9692 (send_sigstop_callback): Update, "entry" parameter is a
9693 struct thread_info * now.
9694 (suspend_and_send_sigstop_callback): Ditto.
9695 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
9696 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
9697 struct thread_info * now.
9698 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
9700 (lwp_running): Update, "entry" parameter is a
9701 struct thread_info * now.
9702 (stop_all_lwps): Fetch ptid from thread.
9703 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
9704 (linux_resume_one_lwp): Fetch lwpid from thread.
9705 (linux_set_resume_request): Update, "entry" parameter is a
9706 struct thread_info * now. Fetch pid, lwpid from thread.
9707 (resume_status_pending_p): Update, "entry" parameter is a
9708 struct thread_info * now.
9709 (need_step_over_p): Ditto. Fetch lwpid from thread.
9710 (start_step_over): Fetch lwpid from thread.
9711 (linux_resume_one_thread): Update, "entry" parameter is a
9712 struct thread_info * now. Fetch lwpid from thread.
9713 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
9714 (proceed_one_lwp): Update, "entry" parameter is a
9715 struct thread_info * now. Fetch lwpid from thread.
9716 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
9717 struct thread_info * now.
9718 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
9719 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
9720 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
9722 (regsets_store_inferior_registers): Ditto.
9723 (fetch_register, store_register): Ditto.
9724 (linux_read_memory, linux_write_memory): Ditto.
9725 (linux_request_interrupt): Ditto.
9726 (linux_read_auxv): Ditto.
9727 (linux_xfer_siginfo): Ditto.
9728 (linux_qxfer_spu): Ditto.
9729 (linux_qxfer_libraries_svr4): Ditto.
9730 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
9731 moved to inferiors.h.
9733 (get_thread_lwp): Update.
9734 (struct lwp_info): Delete member "entry". Simplify comment for
9737 * linux-mips-low.c (mips_read_description): Fetch lwpid from
9738 current_inferior directly.
9739 (update_watch_registers_callback): Update, "entry" parameter is a
9740 struct thread_info * now. Fetch pid from thread.
9741 (mips_linux_prepare_to_resume): Fetch ptid from thread.
9742 (mips_insert_point): Fetch lwpid from current_inferior.
9743 Pass &all_threads to find_inferior, not &all_lwps.
9744 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
9745 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
9747 (mips_stopped_data_address): Ditto.
9748 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
9750 * linux-tile-low.c (tile_arch_setup): Ditto.
9751 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
9752 (update_debug_registers_callback): Update, "entry" parameter is a
9753 struct thread_info * now. Fetch pid from thread.
9754 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
9755 Pass &all_threads to find_inferior, not &all_lwps.
9756 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
9757 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
9758 Pass &all_threads to find_inferior, not &all_lwps.
9759 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
9760 (i386_dr_low_get_status): Ditto.
9761 (x86_linux_prepare_to_resume): Fetch ptid from thread.
9762 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
9763 (x86_linux_read_description): Ditto.
9764 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
9766 2014-02-20 Doug Evans <dje@google.com>
9768 * inferiors.c (get_first_inferior): Fix buglet.
9770 2014-02-19 Doug Evans <dje@google.com>
9772 * gdbthread.h (add_thread): Change result type to struct thread_info *.
9773 * inferiors.c (add_thread): Change result type to struct thread_info *.
9774 All callers updated.
9775 (add_lwp): Call add_thread here instead of in callers.
9776 All callers updated.
9777 * linux-low.h (get_lwp_thread): Rewrite.
9778 (struct lwp_info): New member "thread".
9780 2014-02-19 Doug Evans <dje@google.com>
9782 * linux-low.c (add_lwp): Change result to struct lwp_info *.
9783 All callers updated.
9785 2014-02-19 Doug Evans <dje@google.com>
9787 * inferiors.c (add_thread): Fix whitespace.
9789 2014-02-19 Doug Evans <dje@google.com>
9791 * dll.c (clear_dlls): Replace accessing list implemention details
9793 * gdbthread.h (get_first_thread): Declare.
9794 * inferiors.c (for_each_inferior_with_data): New function.
9795 (get_first_thread): New function.
9796 (find_thread_ptid): Simplify.
9797 (get_first_inferior): New function.
9798 (clear_list): Delete.
9799 (one_inferior_p): New function.
9800 (clear_inferior_list): New function.
9801 (clear_inferiors): Update.
9802 * inferiors.h (for_each_inferior_with_data): Declare.
9803 (clear_inferior_list): Declare.
9804 (one_inferior_p): Declare.
9805 (get_first_inferior): Declare.
9806 * linux-low.c (linux_wait_for_event): Replace accessing list
9807 implemention details with API function.
9808 * server.c (target_running): Ditto.
9809 (accumulate_file_name_length): New function.
9810 (emit_dll_description): New function.
9811 (handle_qxfer_libraries): Replace accessing list implemention
9812 details with API function.
9813 (handle_qxfer_threads_worker): New function.
9814 (handle_qxfer_threads_proper): Replace accessing list implemention
9815 details with API function.
9816 (handle_query): Ditto.
9817 (visit_actioned_threads_callback_ftype): New typedef.
9818 (visit_actioned_threads_data): New struct.
9819 (visit_actioned_threads): Rewrite to be find_inferior callback.
9820 (resume): Call find_inferior.
9821 (handle_status): Replace accessing list implemention
9822 details with API function.
9823 (process_serial_event): Replace accessing list implemention details
9825 * target.c (set_desired_inferior): Replace accessing list implemention
9826 details with API function.
9827 * tracepoint.c (same_process_p): New function.
9828 (gdb_agent_about_to_close): Replace accessing list implemention
9829 details with API function.
9830 * win32-low.c (child_delete_thread): Replace accessing list
9831 implemention details with API function.
9832 (match_dll_by_basename): New function.
9833 (dll_is_loaded_by_basename): New function.
9834 (win32_ensure_ntdll_loaded): Replace accessing list implemention
9835 details call to dll_is_loaded_by_basename.
9837 2014-02-19 Doug Evans <dje@google.com>
9839 * dll.h (struct dll_info): Add comment.
9840 * gdbthread.h (struct thread_info): Add comment.
9841 (current_ptid): Simplify.
9842 * inferiors.c (add_process): Update.
9843 (remove_process): Update.
9844 * inferiors.h (struct process_info): Rename member "head" to "entry".
9845 * linux-low.c (delete_lwp): Update.
9847 (last_thread_of_process_p): Update.
9848 (kill_one_lwp_callback, linux_kill): Update.
9849 (status_pending_p_callback): Update.
9850 (wait_for_sigstop): Update. Simplify read of ptid.
9851 (start_step_over): Update.
9852 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
9853 (get_lwp_thread): Update.
9854 (struct lwp_info): Rename member "head" to "entry".
9855 * regcache.h (inferior_list_entry): Delete.
9856 * server.c (kill_inferior_callback): Update.
9857 (detach_or_kill_inferior_callback): Update.
9858 (print_started_pid): Update.
9859 (print_attached_pid): Update.
9860 (process_serial_event): Simplify read of ptid.
9861 * thread-db.c (thread_db_create_event): Update.
9862 (thread_db_get_tls_address): Update.
9863 * win32-low.c (current_inferior_ptid): Simplify.
9865 2014-02-19 Tom Tromey <tromey@redhat.com>
9867 * target.h (struct target_ops) <supports_btrace>: Add target_ops
9869 (target_supports_btrace): Update.
9871 2014-02-14 Yao Qi <yao@codesourcery.com>
9873 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
9874 (rsp-low-ipa.o): New target.
9876 2014-02-12 Tom Tromey <tromey@redhat.com>
9878 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
9879 convert_ascii_to_int.
9880 * regcache.c (registers_to_string): Likewise.
9881 * remote-utils.c (decode_M_packet): Likewise.
9882 * server.c (process_serial_event): Likewise.
9884 2014-02-12 Tom Tromey <tromey@redhat.com>
9886 * server.c (handle_query, handle_v_run): Use hex2bin, not
9888 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
9890 2014-02-12 Tom Tromey <tromey@redhat.com>
9892 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
9893 convert_int_to_ascii.
9894 * regcache.c (registers_to_string, collect_register_as_string):
9896 * remote-utils.c (look_up_one_symbol, relocate_instruction):
9898 * server.c (process_serial_event): Likewise.
9899 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
9900 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
9902 2014-02-12 Tom Tromey <tromey@redhat.com>
9904 * remote-utils.c (look_up_one_symbol, monitor_output): Use
9905 bin2hex, not hexify.
9906 * tracepoint.c (cmd_qtstatus): Likewise.
9908 2014-02-12 Tom Tromey <tromey@redhat.com>
9910 * remote-utils.c (monitor_output): Pass explicit length to
9913 2014-02-12 Tom Tromey <tromey@redhat.com>
9915 * tracepoint.c: Include rsp-low.h.
9916 * server.c: Include rsp-low.h.
9917 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
9918 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
9920 * remote-utils.c: Include rsp-low.h.
9921 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
9922 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
9923 (convert_int_to_ascii, convert_ascii_to_int): Move to
9925 * regcache.c: Include rsp-low.h.
9926 * ax.c: Include rsp-low.h.
9927 * Makefile.in (SFILES): Add common/rsp-low.c.
9928 (OBS): Add rsp-low.o.
9929 (rsp-low.o): New target.
9931 2014-02-12 Tom Tromey <tromey@redhat.com>
9933 * utils.h (pulongest, plongest, phex_nz): Don't declare.
9934 Include print-utils.h.
9935 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
9936 (plongest, thirty_two, phex_nz): Remove.
9937 * Makefile.in (SFILES): Add common/print-utils.c.
9938 (OBS): Add print-utils.o.
9939 (print-utils-ipa.o): New target.
9940 (print-utils.o): New target.
9941 (IPA_OBJS): Add print-utils-ipa.o.
9943 2014-02-06 Tom Tromey <tromey@redhat.com>
9945 * Makefile.in (SFILES): Fix indentation.
9947 2014-02-05 Doug Evans <dje@google.com>
9949 * linux-low.c (linux_wait_for_event): Improve comment.
9950 (linux_wait_1): Keep current_inferior in sync with event_child.
9952 2014-01-22 Doug Evans <dje@google.com>
9954 * gdbthread.h (gdb_id_to_thread): Delete, unused.
9956 2014-01-22 Doug Evans <dje@google.com>
9958 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
9959 * configure: Regenerate.
9960 * config.in: Regenerate.
9961 * Makefile.in (SFILES): Add debug.c.
9963 * debug.c: New file.
9964 * debug.h: New file.
9965 * linux-aarch64-low.c (*): Update all debugging printfs to use
9966 debug_printf instead of fprintf.
9967 * linux-arm-low.c (*): Ditto.
9968 * linux-cris-low.c (*): Ditto.
9969 * linux-crisv32-low.c (*): Ditto.
9970 * linux-m32r-low.c (*): Ditto.
9971 * linux-sparc-low.c (*): Ditto.
9972 * linux-x86.c (*): Ditto.
9973 * linux-low.c (*): Ditto.
9974 (linux_wait_1): Add calls to debug_enter, debug_exit.
9975 (linux_wait): Remove redundant debugging printf.
9976 (stop_all_lwps): Add calls to debug_enter, debug_exit.
9977 (linux_resume, unstop_all_lwps): Ditto.
9978 * mem-break.c (*): Update all debugging printfs to use
9979 debug_printf instead of fprintf.
9980 * remote-utils.c (*): Ditto.
9981 * thread-db.c (*): Ditto.
9982 * server.c #include <ctype.h>, "gdb_vecs.h".
9983 (debug_threads): Moved to debug.c.
9984 (*): Update all debugging printfs to use debug_printf instead of
9986 (start_inferior): Replace call to fflush with call to debug_flush.
9987 (monitor_show_help): Mention set debug-format.
9988 (parse_debug_format_options): New function.
9989 (handle_monitor_command): Handle "monitor set debug-format".
9990 (gdbserver_usage): Mention --debug-format.
9991 (main): Parse --debug-format.
9992 * server.h (debug_threads): Declaration moved to debug.h.
9994 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
9995 trace_debug_1 that uses debug_printf.
9996 (tracepoint_look_up_symbols): Update all debugging printfs to use
9997 debug_printf instead of fprintf.
9999 2014-01-20 Baruch Siach <baruch@tkos.co.il>
10001 * linux-xtensa-low.c: Include asm/ptrace.h instead of
10004 2014-01-17 Pedro Alves <palves@redhat.com>
10007 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
10008 defined after including gdb_proc_service.h.
10010 2014-01-16 Doug Evans <dje@google.com>
10012 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
10013 (match_dll): Use it.
10015 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
10017 * target.h (target_ops) <read_btrace>: Change parameters and
10018 return type to allow error reporting.
10019 * server.c (handle_qxfer_btrace): Support delta reads. Pass
10020 trace reading errors on.
10021 * linux-low.c (linux_low_read_btrace): Pass trace reading
10023 (linux_low_disable_btrace): New.
10025 2014-01-15 Doug Evans <dje@google.com>
10027 * inferiors.c (thread_id_to_gdb_id): Delete.
10028 * inferiors.h (thread_id_to_gdb_id): Delete.
10030 2014-01-13 Eli Zaretskii <eliz@gnu.org>
10032 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
10033 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
10036 2014-01-08 Pedro Alves <palves@redhat.com>
10038 * server.c (handle_status): Don't discard previous queued stop
10039 replies or thread's pending status here.
10040 (main) <disconnection>: Do it here instead.
10042 2014-01-08 Pedro Alves <palves@redhat.com>
10044 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
10045 * server.c (visit_actioned_threads, handle_pending_status): New
10047 (handle_v_cont): Factor out parts to ...
10048 (resume): ... this new function. If in all-stop, and a thread
10049 being resumed has a pending status, report it without actually
10051 (myresume): Adjust to use the new 'resume' function.
10052 (clear_pending_status_callback, set_pending_status_callback)
10053 (find_status_pending_thread_callback): New functions.
10054 (handle_status): Handle the case of multiple threads having
10055 interesting statuses to report. Report threads' real last signal
10056 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
10057 with an interesting thread to report the status for, instead of
10058 always reporting the status of the first thread.
10060 2014-01-01 Joel Brobecker <brobecker@adacore.com>
10062 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
10063 * gdbreplay.c (gdbreplay_version): Likewise.
10065 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
10067 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
10068 iov.iov_len with the real length in use.
10070 2013-12-13 Joel Brobecker <brobecker@adacore.com>
10072 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
10073 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
10074 for all targets that use win32-low.c.
10075 * win32-low.c (win32_ensure_ntdll_loaded): New function.
10076 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
10078 2013-12-13 Pedro Alves <palves@redhat.com>
10080 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
10081 if equal to TARGET_WAITKIND_LOADED.
10082 * win32-low.c (cached_status): New static global.
10083 (win32_wait): Add declaration.
10084 (do_initial_child_stuff): Flush all initial pending debug events
10085 up to the initial breakpoint.
10086 (win32_wait): If CACHED_STATUS was set, return that instead
10087 of doing a real wait. Remove the code resuming the execution
10088 of the inferior after receiving a TARGET_WAITKIND_LOADED event
10089 during the initial phase. Also remove the code changing
10090 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
10091 TARGET_WAITKIND_STOPPED.
10093 2013-12-11 Yao Qi <yao@codesourcery.com>
10095 * notif.c (handle_notif_ack): Return 0 if no notification
10098 2013-11-20 Doug Evans <dje@google.com>
10100 * linux-low.c (linux_set_resume_request): Fix comment.
10102 2013-11-20 Doug Evans <dje@google.com>
10104 * linux-low.c (resume_status_pending_p): Tweak comment.
10106 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
10108 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
10109 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
10110 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
10111 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
10112 (srv_amd64_regobj): Add amd64-mpx.o.
10113 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
10114 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
10115 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
10116 * i387-fp.c (num_pl_bnd_register) Added constant.
10117 (num_pl_bnd_cfg_registers) Added constant.
10118 (struct i387_xsave) Added reserved area and MPX fields.
10119 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
10120 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
10122 (tdesc_i386_mpx_linux): Add MPX amd64 target.
10123 (init_registers_amd64_mpx_linux): Declare new function.
10124 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
10125 (x86_64_regmap): Add MPX registers.
10126 (x86_linux_read_description): Add MPX case.
10127 (initialize_low_arch): Initialize MPX targets.
10129 2013-11-18 Tom Tromey <tromey@redhat.com>
10131 * configure: Rebuild.
10132 * configure.ac: Don't check for stdlib.h.
10133 * gdbreplay.c: Unconditionally include stdlib.h.
10135 2013-11-18 Tom Tromey <tromey@redhat.com>
10137 * config.in: Rebuild.
10138 * configure: Rebuild.
10139 * configure.ac: Don't use AC_HEADER_DIRENT.
10141 2013-11-18 Tom Tromey <tromey@redhat.com>
10143 * server.h: Don't check HAVE_STRING_H.
10144 * gdbreplay.c: Don't check HAVE_STRING_H.
10145 * configure: Rebuild.
10147 2013-11-18 Tom Tromey <tromey@redhat.com>
10149 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
10152 2013-11-08 Tom Tromey <tromey@redhat.com>
10154 * configure, config.in: Rebuild.
10155 * configure.ac: Remove unused configury.
10157 2013-11-08 Tom Tromey <tromey@redhat.com>
10159 * acinclude.m4: Include common.m4, codeset.m4.
10160 * configure, config.in: Rebuild.
10161 * configure.ac: Use GDB_AC_COMMON.
10163 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
10165 * linux-s390-low.c (HWCAP_S390_TE): New define.
10166 (s390_arch_setup): Consider the TE field in the HWCAP for
10167 determining 'have_regset_tdb'.
10169 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
10172 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
10175 2013-10-02 Pedro Alves <palves@redhat.com>
10177 * server.c (process_serial_event): Don't output "GDBserver
10178 exiting" if GDB is connected through stdio.
10179 * target.c (mywait): Likewise, be silent if GDB is connected
10182 2013-10-01 Joel Brobecker <brobecker@adacore.com>
10184 * lynx-low.c (lynx_add_threads_after_attach): New function.
10185 (lynx_attach): Remove call to add_thread. Add call to
10186 lynx_add_threads_after_attach instead.
10188 2013-09-28 Mike Frysinger <vapier@gentoo.org>
10190 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
10191 * config.in, configure: Regenerated.
10193 2013-09-18 Yao Qi <yao@codesourcery.com>
10196 * server.c (start_inferior): Clear 'resume_info'.
10198 2013-09-16 Jiong Wang <jiwang@tilera.com>
10200 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
10203 2013-09-16 Jiong Wang <jiwang@tilera.com>
10205 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
10206 linux-tile-low.o to srv_tgtobj.
10208 2013-09-16 Will Newton <will.newton@linaro.org>
10210 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
10213 2013-09-06 Pedro Alves <palves@redhat.com>
10215 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
10216 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
10217 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
10218 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
10219 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
10220 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
10222 2013-09-06 Pedro Alves <palves@redhat.com>
10224 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
10225 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
10227 2013-09-06 Pedro Alves <palves@redhat.com>
10229 * linux-amd64-ipa.c: Include tracepoint.h.
10230 * linux-i386-ipa.c: Include tracepoint.h.
10232 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
10234 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
10235 (ps_get_thread_area): New function.
10237 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
10239 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
10240 (initialize_low_arch): Call init_registers_crisv32 rather than
10241 init_register_crisv32.
10243 2013-09-05 Pedro Alves <palves@redhat.com>
10245 * server.h (handle_vFile, hostio_last_error_from_errno): Move
10247 * hostio.h: ... this new file.
10248 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
10249 win32-low.c: Include hostio.h.
10251 2013-09-05 Pedro Alves <palves@redhat.com>
10253 * server.h (gdb_client_data, handler_func, callback_handler_func)
10254 (delete_file_handler, add_file_handler, append_callback_event)
10255 (delete_callback_event, start_event_loop, initialize_event_loop):
10256 Move to event-loop.h and include it.
10257 * event-loop.h: New file.
10259 2013-09-05 Pedro Alves <palves@redhat.com>
10261 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
10262 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
10263 (loaded_dll, unloaded_dll): Move to ...
10264 * dll.h: ... this new file.
10265 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
10267 2013-09-05 Pedro Alves <palves@redhat.com>
10269 * server.h (current_process, get_thread_process, all_processes)
10270 (add_inferior_to_list, for_each_inferior, current_inferior)
10271 (remove_inferior, add_process, remove_process, find_process_pid)
10272 (have_started_inferiors_p, have_attached_inferiors_p)
10273 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
10274 (clear_inferiors, find_inferior, find_inferior_id)
10275 (inferior_target_data, set_inferior_target_data)
10276 (inferior_regcache_data, set_inferior_regcache_data): Move to
10277 inferiors.h, and include it.
10278 * inferiors.h: New file.
10280 2013-09-05 Pedro Alves <palves@redhat.com>
10282 * server.h (struct emit_ops, current_insn_ptr, emit_error):
10286 2013-09-05 Pedro Alves <palves@redhat.com>
10288 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
10290 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
10291 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
10292 (handle_tracepoint_general_set, handle_tracepoint_query)
10293 (tracepoint_finished_step, tracepoint_was_hit)
10294 (release_while_stepping_state_list, current_traceframe)
10295 (in_readonly_region, traceframe_read_mem)
10296 (fetch_traceframe_registers, traceframe_read_sdata)
10297 (traceframe_read_info, struct fast_tpoint_collect_status)
10298 (fast_tracepoint_collecting, force_unlock_trace_buffer)
10299 (handle_tracepoit_bkpts, initialize_low_tracepoint)
10300 (supply_fast_tracepoint_registers)
10301 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
10302 (ipa_tdesc, claim_trampoline_space)
10303 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
10304 (agent_mem_read, agent_get_trace_state_variable_value)
10305 (agent_set_trace_state_variable_value, agent_tsv_read)
10306 (agent_mem_read_string, get_raw_reg_func_addr)
10307 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
10308 * tracepoint.h: ... this new file.
10310 2013-09-05 Pedro Alves <palves@redhat.com>
10312 * server.h (perror_with_name, error, fatal, warning, paddress)
10313 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
10315 * utils.h: New file.
10317 2013-09-05 Pedro Alves <palves@redhat.com>
10319 * server.h (remote_debug, noack_mode, transport_is_reliable)
10320 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
10321 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
10322 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
10323 (write_enn, initialize_async_io, enable_async_io)
10324 (disable_async_io, check_remote_input_interrupt_request)
10325 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
10326 (dead_thread_notify, prepare_resume_reply)
10327 (decode_address_to_semicolon, decode_address, decode_m_packet)
10328 (decode_M_packet, decode_X_packet, decode_xfer_write)
10329 (decode_search_memory_packet, unhexify, hexify)
10330 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
10331 (look_up_one_symbol, relocate_instruction)
10332 (monitor_output): Move to remote-utils.h, and include it.
10333 * remote-utils.h: New file.
10335 2013-09-05 Pedro Alves <palves@redhat.com>
10337 * server.h (_): Delete.
10339 2013-09-02 Pedro Alves <palves@redhat.com>
10341 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
10342 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
10344 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
10346 2013-09-02 Pierre Muller <muller@sourceware.org>
10348 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
10349 or WriteProcessMemory complete successfully and handle
10350 ERROR_PARTIAL_COPY error.
10352 2013-09-02 Pedro Alves <palves@redhat.com>
10354 * server.c (gdb_read_memory): Return -1 on traceframe memory read
10355 error instead of EIO.
10357 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
10360 * linux-low.c: Include filestuff.h.
10361 (linux_create_inferior) <pid == 0>: Call close_most_fds.
10362 * lynx-low.c: Include filestuff.h.
10363 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
10364 * server.c: Include filestuff.h.
10365 (main): Call notice_open_fds.
10366 * spu-low.c: Include filestuff.h.
10367 (spu_create_inferior) <pid == 0>: Call close_most_fds.
10369 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
10371 * Makefile.in: Explain why ../target and ../nat are not
10372 listed as include file search paths.
10373 (linux-waitpid.o): New object file rule.
10374 * configure.srv (srv_native_linux_obj): New variable.
10375 Replace all occurrences of linux native object files with
10376 $srv_native_linux_obj.
10377 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
10378 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
10379 (linux_enable_event_reporting): Remove declaration.
10380 (my_waitpid): Moved to common/linux-waitpid.c.
10381 (linux_wait_for_event): Pass ptid when calling
10382 linux_enable_event_reporting.
10383 (linux_supports_tracefork_flag): Remove.
10384 (linux_enable_event_reporting): Likewise.
10385 (linux_tracefork_grandchild): Remove.
10386 (STACK_SIZE): Moved to common/linux-ptrace.c.
10387 (linux_tracefork_child): Remove.
10388 (linux_test_for_tracefork): Remove.
10389 (linux_look_up_symbols): Call linux_supports_traceclone.
10390 (initialize_low): Remove call to linux_test_for_tracefork.
10391 * linux-low.h (PTRACE_TYPE_ARG3): Move to
10392 common/linux-ptrace.h.
10393 (PTRACE_TYPE_ARG4): Likewise.
10394 Include linux-ptrace.h.
10396 2013-08-21 Pedro Alves <palves@redhat.com>
10398 * config.in: Renegerate.
10400 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
10402 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
10403 (SFILES): Remove $(srcdir)/common/target-common.c and
10404 add $(srcdir)/target/waitstatus.c.
10405 (OBS): Remove target-common.o and add waitstatus.o.
10406 (server_h): Remove $(srcdir)/../common/target-common.h and
10407 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
10408 and $(srcdir)/../target/waitstatus.h.
10409 (target-common.o): Remove.
10410 (waitstatus.o): New target object file.
10411 * target.h: Do not include target-common.h and
10412 include target/resume.h, target/wait.h and
10413 target/waitstatus.h.
10415 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
10417 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
10418 to PTRACE_TYPE_ARG3.
10419 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
10420 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
10422 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
10423 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
10425 2013-07-27 Jie Zhang <jie@codesourcery.com>
10426 Daniel Jacobowitz <dan@codesourcery.com>
10427 Yao Qi <yao@codesourcery.com>
10429 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
10430 (mips-linux-watch.o): New rule.
10431 (mips_linux_watch_h): New variable.
10432 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
10434 * linux-mips-low.c: Include mips-linux-watch.h.
10435 (struct arch_process_info, struct arch_lwp_info): New.
10436 (update_watch_registers_callback): New function.
10437 (mips_linux_new_process, mips_linux_new_thread) New functions.
10438 (mips_linux_prepare_to_resume, mips_insert_point): New
10440 (mips_remove_point, mips_stopped_by_watchpoint): New
10442 (rsp_bp_type_to_target_hw_bp_type): New function.
10443 (mips_stopped_data_address): New function.
10444 (the_low_target): Add watchpoint support functions.
10446 2013-07-27 Yao Qi <yao@codesourcery.com>
10448 * i386-low.c: Include break-common.h.
10449 (enum target_hw_bp_type): Remove.
10451 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
10453 * Makefile.in (SFILES): /common/target-common.c.
10454 (OBS): Add target-common.o.
10455 (server_h): Add $(srcdir)/../common/target-common.h.
10456 (target-common.o): New target.
10457 * server.c (queue_stop_reply_callback): Free
10458 status string after use.
10459 * target.c (target_waitstatus_to_string): Remove.
10460 * target.h: Include target-common.h.
10461 (resume_kind): Likewise.
10462 (target_waitkind): Likewise.
10463 (target_waitstatus): Likewise.
10464 (TARGET_WNOHANG): Likewise.
10466 2013-07-04 Yao Qi <yao@codesourcery.com>
10468 * Makefile.in (host_alias): Use @host_noncanonical@.
10469 (target_alias): Use @target_noncanonical@.
10470 * configure.ac: Use ACX_NONCANONICAL_TARGET and
10471 ACX_NONCANONICAL_HOST.
10472 * configure: Regenerated.
10475 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
10477 * configure.ac (version_host, version_target): Set and AC_SUBST them.
10478 * configure: Rebuild.
10479 * Makefile.in (version_host, version_target): Get from configure.
10480 (version.c): Use $(version_host) and $(version_target).
10482 2013-07-03 Pedro Alves <palves@redhat.com>
10484 * Makefile.in (config.status): Depend on development.sh.
10485 * acinclude.m4: Include libmcheck.m4.
10486 * configure: Regenerate.
10488 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
10490 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
10491 attribute inside the parentheses.
10492 (winapi_DebugSetProcessKillOnExit): Ditto.
10493 (winapi_DebugBreakProcess): Ditto.
10494 (winapi_GenerateConsoleCtrlEvent): Ditto.
10496 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
10498 * notif.h (notif_event): Add a dummy member to avoid compiler
10501 2013-07-01 Pedro Alves <palves@redhat.com>
10503 * hostio.c (HOSTIO_PATH_MAX): Define.
10504 (require_filename, handle_open, handle_unlink, handle_readlink):
10507 2013-07-01 Pedro Alves <palves@redhat.com>
10509 * server.h: Include "pathmax.h".
10510 * linux-low.c: Don't include sys/param.h.
10511 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
10513 * win32-low.c: Don't include sys/param.h.
10514 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
10516 2013-07-01 Pedro Alves <palves@redhat.com>
10518 * event-loop.c: Don't check HAVE_UNISTD_H before including
10520 * gdbreplay.c: Likewise.
10521 * remote-utils.c: Likewise.
10522 * server.c: Likewise.
10523 * configure.ac: Don't check for unistd.h.
10524 * configure: Regenerate.
10526 2013-06-28 Tom Tromey <tromey@redhat.com>
10528 * Makefile.in (version.c): Use version.in, not
10531 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
10533 * configure.ac (version_host, version_target): Set and AC_SUBST them.
10534 * configure: Rebuild.
10535 * Makefile.in (version_host, version_target): Get from configure.
10536 (version.c): Use $(version_host) and $(version_target).
10538 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
10540 Fix trace-status to output user name without trailing colon.
10541 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
10543 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
10545 Fix trace-status to output proper start-time and stop-time.
10546 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
10547 output start time and stop time in hex as gdb expects.
10549 2013-06-26 Pedro Alves <pedro@codesourcery.com>
10551 * tracepoint.c (build_traceframe_info_xml): Output trace state
10552 variables present in the trace buffer.
10554 2013-06-24 Tom Tromey <tromey@redhat.com>
10556 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
10558 (version.o): Remove.
10559 * gdbreplay.c: Include version.h.
10560 (version, host_name): Don't declare.
10561 * server.h: Include version.h.
10562 (version, host_name): Don't declare.
10564 2013-06-12 Pedro Alves <palves@redhat.com>
10566 * linux-x86-low.c (linux_is_elf64): Delete global.
10567 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
10568 with local linux_pid_exe_is_elf_64_file use.
10570 2013-06-11 Pedro Alves <palves@redhat.com>
10572 * linux-low.c (regset_disabled, disable_regset): New functions.
10573 (regsets_fetch_inferior_registers)
10574 (regsets_store_inferior_registers): Use them.
10575 (initialize_regsets_info); Don't allocate the disabled_regsets
10577 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
10580 2013-06-11 Pedro Alves <palves@redhat.com>
10582 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
10585 2013-06-11 Pedro Alves <palves@redhat.com>
10587 * linux-x86-low.c (initialize_low_arch): Call
10588 init_registers_x32_avx_linux.
10590 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
10592 Fix compatibility with Android Bionic.
10593 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
10596 2013-06-07 Pedro Alves <palves@redhat.com>
10599 * Makefile.in (OBS): Add tdesc.o.
10600 (IPA_OBJS): Add tdesc-ipa.o.
10601 (tdesc-ipa.o): New rule.
10602 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
10604 * linux-low.c (new_inferior): Delete.
10605 (disabled_regsets, num_regsets): Delete.
10606 (linux_add_process): Adjust to set the new per-process
10608 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
10609 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
10610 was a stop. When calling arch_setup, switch the current inferior
10611 to the thread that got an event.
10612 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
10613 (regsets_fetch_inferior_registers)
10614 (regsets_store_inferior_registers): New regsets_info parameter.
10616 (linux_register_in_regsets): New regs_info parameter. Adjust to
10618 (register_addr, fetch_register, store_register): New usrregs_info
10619 parameter. Adjust to use it.
10620 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
10621 parameter regs_info. Adjust to use it.
10622 (linux_fetch_registers): Get the current inferior's regs_info, and
10624 (linux_store_registers): Ditto.
10625 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
10626 (initialize_low): Don't initialize the target_regsets here. Call
10627 initialize_low_arch.
10628 * linux-low.h (target_regsets): Delete declaration.
10629 (struct regsets_info): New.
10630 (struct usrregs_info): New.
10631 (struct regs_info): New.
10632 (struct process_info_private) <new_inferior>: New field.
10633 (struct linux_target_ops): Delete the num_regs, regmap, and
10634 regset_bitmap fields. New field regs_info.
10635 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
10636 * i387-fp.c (num_xmm_registers): Delete.
10637 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
10638 calls to new interface.
10639 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
10640 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
10641 Infer the number of xmm registers from the regcache's target
10643 * i387-fp.h (num_xmm_registers): Delete.
10644 * inferiors.c (add_thread): Don't install the thread's regcache
10646 * proc-service.c (gregset_info): Fetch the current inferior's
10647 regs_info. Adjust to use it.
10648 * regcache.c: Include tdesc.h.
10649 (register_bytes, reg_defs, num_registers)
10650 (gdbserver_expedite_regs): Delete.
10651 (get_thread_regcache): If the thread doesn't have a regcache yet,
10652 create one, instead of aborting gdbserver.
10653 (regcache_invalidate_one): Rename to ...
10654 (regcache_invalidate_thread): ... this.
10655 (regcache_invalidate_one): New.
10656 (regcache_invalidate): Only invalidate registers of the current
10658 (init_register_cache): Add target_desc parameter, and use it.
10659 (new_register_cache): Ditto. Assert the target description has a
10660 non zero registers_size.
10661 (regcache_cpy): Add assertions. Adjust.
10662 (realloc_register_cache, set_register_cache): Delete.
10663 (registers_to_string, registers_from_string): Adjust.
10664 (find_register_by_name, find_regno, find_register_by_number)
10665 (register_cache_size): Add target_desc parameter, and use it.
10666 (free_register_cache_thread, free_register_cache_thread_one)
10667 (regcache_release, register_cache_size): New.
10668 (register_size): Add target_desc parameter, and use it.
10669 (register_data, supply_register, supply_register_zeroed)
10670 (supply_regblock, supply_register_by_name, collect_register)
10671 (collect_register_as_string, collect_register_by_name): Adjust.
10672 * regcache.h (struct target_desc): Forward declare.
10673 (struct regcache) <tdesc>: New field.
10674 (init_register_cache, new_register_cache): Add target_desc
10676 (regcache_invalidate_thread): Declare.
10677 (regcache_invalidate_one): Delete declaration.
10678 (regcache_release): Declare.
10679 (find_register_by_number, register_cache_size, register_size)
10680 (find_regno): Add target_desc parameter.
10681 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
10683 * remote-utils.c: Include tdesc.h.
10684 (outreg, prepare_resume_reply): Adjust.
10685 * server.c: Include tdesc.h.
10686 (gdbserver_xmltarget): Delete declaration.
10687 (get_features_xml, process_serial_event): Adjust.
10688 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
10690 (struct process_info) <tdesc>: New field.
10691 (ipa_tdesc): Declare.
10692 * tdesc.c: New file.
10693 * tdesc.h: New file.
10694 * tracepoint.c: Include tdesc.h.
10695 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
10696 (get_context_regcache): Adjust to pass ipa_tdesc down.
10697 (do_action_at_tracepoint): Adjust to get the register cache size
10698 from the context regcache's description.
10699 (traceframe_walk_blocks): Adjust to get the register cache size
10700 from the current trace frame's description.
10701 (traceframe_get_pc): Adjust to get current trace frame's
10702 description and pass it down.
10703 (gdb_collect): Adjust to get the register cache size from the
10705 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
10706 (gdbserver_xmltarget): Delete.
10707 (initialize_low_tracepoint): Set the ipa's target description.
10708 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
10709 (initialize_low_tracepoint): Set the ipa's target description.
10710 * linux-x86-low.c: Include tdesc.h.
10711 [__x86_64__] (is_64bit_tdesc): New.
10712 (ps_get_thread_area, x86_get_thread_area): Use it.
10713 (i386_cannot_store_register): Rename to ...
10714 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
10715 (i386_cannot_fetch_register): Rename to ...
10716 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
10717 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
10719 (target_regsets): Rename to ...
10720 (x86_regsets): ... this.
10721 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
10723 (x86_siginfo_fixup): Use is_64bit_tdesc.
10724 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
10725 (tdesc_x32_avx_linux, tdesc_x32_linux)
10726 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
10728 (x86_linux_update_xmltarget): Delete.
10729 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
10730 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
10731 (AMD64_LINUX_USER64_CS): New.
10732 (x86_linux_read_description): New, based on
10733 x86_linux_update_xmltarget.
10734 (same_process_callback): New.
10735 (x86_arch_setup_process_callback): New.
10736 (x86_linux_update_xmltarget): New.
10737 (x86_regsets_info): New.
10738 (amd64_linux_regs_info): New.
10739 (i386_linux_usrregs_info): New.
10740 (i386_linux_regs_info): New.
10741 (x86_linux_regs_info): New.
10742 (x86_arch_setup): Reimplement.
10743 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
10744 (x86_emit_ops): Ditto.
10745 (the_low_target): Adjust. Install x86_linux_regs_info,
10746 x86_cannot_fetch_register, and x86_cannot_store_register.
10747 (initialize_low_arch): New.
10748 * linux-ia64-low.c (tdesc_ia64): Declare.
10749 (ia64_fetch_register): Adjust.
10750 (ia64_usrregs_info, regs_info): New globals.
10751 (ia64_regs_info): New function.
10752 (the_low_target): Adjust.
10753 (initialize_low_arch): New function.
10754 * linux-sparc-low.c (tdesc_sparc64): Declare.
10755 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
10757 (sparc_arch_setup): New function.
10758 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
10759 (the_low_target): Adjust.
10760 (initialize_low_arch): New function.
10761 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
10762 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
10763 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
10764 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
10765 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
10766 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
10767 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
10768 (tdesc_powerpc_isa205_vsx64l): Declare.
10769 (ppc_cannot_store_register, ppc_collect_ptrace_register)
10770 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
10771 (ppc_set_pc, ppc_get_hwcap): Adjust.
10772 (ppc_usrregs_info): Forward declare.
10773 (!__powerpc64__) ppc_regmap_adjusted: New global.
10774 (ppc_arch_setup): Adjust to the current process'es target
10776 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
10777 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
10778 (ppc_store_evrregset): Adjust.
10779 (target_regsets): Rename to ...
10780 (ppc_regsets): ... this, and make static.
10781 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
10782 (ppc_regs_info): New function.
10783 (the_low_target): Adjust.
10784 (initialize_low_arch): New function.
10785 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
10786 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
10787 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
10788 (tdesc_s390x_linux64v2): Declare.
10789 (s390_collect_ptrace_register, s390_supply_ptrace_register)
10790 (s390_fill_gregset, s390_store_last_break): Adjust.
10791 (target_regsets): Rename to ...
10792 (s390_regsets): ... this, and make static.
10793 (s390_get_pc, s390_set_pc): Adjust.
10794 (s390_get_hwcap): New target_desc parameter, and use it.
10795 [__s390x__] (have_hwcap_s390_high_gprs): New global.
10796 (s390_arch_setup): Adjust to set the current process'es target
10797 description. Don't adjust the regmap.
10798 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
10799 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
10800 (regs_info_3264): New globals.
10801 (s390_regs_info): New function.
10802 (the_low_target): Adjust.
10803 (initialize_low_arch): New function.
10804 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
10805 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
10806 [__mips64] (init_registers_mips_linux)
10807 (init_registers_mips_dsp_linux): Delete defines.
10808 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
10809 (have_dsp): New global.
10810 (mips_read_description): New, based on mips_arch_setup.
10811 (mips_arch_setup): Reimplement.
10812 (get_usrregs_info): New function.
10813 (mips_cannot_fetch_register, mips_cannot_store_register)
10814 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
10815 (mips_fill_fpregset, mips_store_fpregset): Adjust.
10816 (target_regsets): Rename to ...
10817 (mips_regsets): ... this, and make static.
10818 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
10819 (dsp_regs_info, regs_info): New globals.
10820 (mips_regs_info): New function.
10821 (the_low_target): Adjust.
10822 (initialize_low_arch): New function.
10823 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
10824 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
10826 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
10827 (arm_read_description): New, with bits factored from
10829 (arm_arch_setup): Reimplement.
10830 (target_regsets): Rename to ...
10831 (arm_regsets): ... this, and make static.
10832 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
10833 (arm_regs_info): New function.
10834 (the_low_target): Adjust.
10835 (initialize_low_arch): New function.
10836 * linux-m68k-low.c (tdesc_m68k): Declare.
10837 (target_regsets): Rename to ...
10838 (m68k_regsets): ... this, and make static.
10839 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
10840 (m68k_regs_info): New function.
10841 (m68k_arch_setup): New function.
10842 (the_low_target): Adjust.
10843 (initialize_low_arch): New function.
10844 * linux-sh-low.c (tdesc_sharch): Declare.
10845 (target_regsets): Rename to ...
10846 (sh_regsets): ... this, and make static.
10847 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
10848 (sh_regs_info, sh_arch_setup): New functions.
10849 (the_low_target): Adjust.
10850 (initialize_low_arch): New function.
10851 * linux-bfin-low.c (tdesc_bfin): Declare.
10852 (bfin_arch_setup): New function.
10853 (bfin_usrregs_info, regs_info): New globals.
10854 (bfin_regs_info): New function.
10855 (the_low_target): Adjust.
10856 (initialize_low_arch): New function.
10857 * linux-cris-low.c (tdesc_cris): Declare.
10858 (cris_arch_setup): New function.
10859 (cris_usrregs_info, regs_info): New globals.
10860 (cris_regs_info): New function.
10861 (the_low_target): Adjust.
10862 (initialize_low_arch): New function.
10863 * linux-cris-low.c (tdesc_crisv32): Declare.
10864 (cris_arch_setup): New function.
10865 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
10866 (cris_regs_info): New function.
10867 (the_low_target): Adjust.
10868 (initialize_low_arch): New function.
10869 * linux-m32r-low.c (tdesc_m32r): Declare.
10870 (m32r_arch_setup): New function.
10871 (m32r_usrregs_info, regs_info): New globals.
10872 (m32r_regs_info): Adjust.
10873 (initialize_low_arch): New function.
10874 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
10875 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
10876 (tic6x_usrregs_info): Forward declare.
10877 (tic6x_read_description): New function, based on ...
10878 (tic6x_arch_setup): ... this. Reimplement.
10879 (target_regsets): Rename to ...
10880 (tic6x_regsets): ... this, and make static.
10881 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
10882 (tic6x_regs_info): New function.
10883 (the_low_target): Adjust.
10884 (initialize_low_arch): New function.
10885 * linux-xtensa-low.c (tdesc_xtensa): Declare.
10886 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
10887 (target_regsets): Rename to ...
10888 (xtensa_regsets): ... this, and make static.
10889 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
10891 (xtensa_arch_setup, xtensa_regs_info): New functions.
10892 (the_low_target): Adjust.
10893 (initialize_low_arch): New function.
10894 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
10895 (nios2_arch_setup): Set the current process'es tdesc.
10896 (target_regsets): Rename to ...
10897 (nios2_regsets): ... this.
10898 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
10899 (nios2_regs_info): New function.
10900 (the_low_target): Adjust.
10901 (initialize_low_arch): New function.
10902 * linux-aarch64-low.c (tdesc_aarch64): Declare.
10903 (aarch64_arch_setup): Set the current process'es tdesc.
10904 (target_regsets): Rename to ...
10905 (aarch64_regsets): ... this.
10906 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
10907 (aarch64_regs_info): New function.
10908 (the_low_target): Adjust.
10909 (initialize_low_arch): New function.
10910 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
10912 (target_regsets): Rename to ...
10913 (tile_regsets): ... this.
10914 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
10915 (tile_regs_info): New function.
10916 (tile_arch_setup): Set the current process'es tdesc.
10917 (the_low_target): Adjust.
10918 (initialize_low_arch): New function.
10919 * spu-low.c (tdesc_spu): Declare.
10920 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
10921 * win32-arm-low.c (tdesc_arm): Declare.
10922 (arm_arch_setup): New function.
10923 (the_low_target): Install arm_arch_setup instead of
10924 init_registers_arm.
10925 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
10926 (init_windows_x86): Rename to ...
10927 (i386_arch_setup): ... this. Set `win32_tdesc'.
10928 (the_low_target): Adjust.
10929 * win32-low.c (win32_tdesc): New global.
10930 (child_add_thread): Don't create the thread cache here.
10931 (do_initial_child_stuff): Set the new process'es tdesc.
10932 * win32-low.h (struct target_desc): Forward declare.
10933 (win32_tdesc): Declare.
10934 * lynx-i386-low.c (tdesc_i386): Declare global.
10935 (lynx_i386_arch_setup): Set `lynx_tdesc'.
10936 * lynx-low.c (lynx_tdesc): New global.
10937 (lynx_add_process): Set the new process'es tdesc.
10938 * lynx-low.h (struct target_desc): Forward declare.
10939 (lynx_tdesc): Declare global.
10940 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
10941 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
10942 * nto-low.c (nto_tdesc): New global.
10943 (do_attach): Set the new process'es tdesc.
10944 * nto-low.h (struct target_desc): Forward declare.
10945 (nto_tdesc): Declare.
10946 * nto-x86-low.c (tdesc_i386): Declare.
10947 (nto_x86_arch_setup): Set `nto_tdesc'.
10949 2013-06-04 Gary Benson <gbenson@redhat.com>
10951 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
10952 to qSupported response when appropriate.
10953 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
10954 with nonzero-length annex.
10955 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
10956 arguments supplied in annex.
10958 2013-05-31 Doug Evans <dje@google.com>
10961 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
10962 64 bits in 64-cross-32 environment.
10964 2013-05-28 Pedro Alves <palves@redhat.com>
10966 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
10967 (aarch64-without-fpu.c): Delete rule.
10968 * configure.srv (aarch64*-*-linux*): Remove references to
10969 aarch64-without-fpu.o and aarch64-without-fpu.xml.
10970 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
10973 2013-05-24 Pedro Alves <palves@redhat.com>
10975 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
10976 instead of strchr/decode_address. Error if the range isn't split
10977 with a ','. Don't assume there's be a ':' in the action.
10979 2013-05-23 Yao Qi <yao@codesourcery.com>
10980 Pedro Alves <palves@redhat.com>
10982 * linux-low.c (lwp_in_step_range): New function.
10983 (linux_wait_1): If the thread was range stepping and stopped
10984 outside the stepping range, report the stop to GDB. Otherwise,
10985 continue stepping. Add range stepping debug output.
10986 (linux_set_resume_request): Copy the step range from the resume
10987 request to the lwp.
10988 (linux_supports_range_stepping): New.
10989 (linux_target_ops) <supports_range_stepping>: Set to
10990 linux_supports_range_stepping.
10991 * linux-low.h (struct linux_target_ops)
10992 <supports_range_stepping>: New field.
10993 (struct lwp_info) <step_range_start, step_range_end>: New fields.
10994 * linux-x86-low.c (x86_supports_range_stepping): New.
10995 (the_low_target) <supports_range_stepping>: Set to
10996 x86_supports_range_stepping.
10997 * server.c (handle_v_cont): Handle 'r' action.
10998 (handle_v_requests): Append ";r" if the target supports range
11000 * target.h (struct thread_resume) <step_range_start,
11001 step_range_end>: New fields.
11002 (struct target_ops) <supports_range_stepping>:
11004 (target_supports_range_stepping): New macro.
11006 2013-05-17 Joel Brobecker <brobecker@adacore.com>
11008 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
11009 confusion in comment.
11011 2013-05-17 Joel Brobecker <brobecker@adacore.com>
11013 * lynx-low.c (struct process_info_private): New type.
11014 (lynx_add_process): New function.
11015 (lynx_create_inferior, lynx_attach): Replace calls to
11016 add_process by calls to lynx_add_process.
11017 (lynx_resume): If PTID is null, then try using
11018 current_process()->private->last_wait_event_ptid.
11020 (lynx_clear_inferiors): Delete. The contents of that function
11021 has been inlined in lynx_mourn;
11022 (lynx_wait_1): Save the ptid in the process's private data.
11023 (lynx_mourn): Free the process' private data. Replace call
11024 to lynx_clear_inferiors by call to clear_inferiors.
11026 2013-05-17 Yao Qi <yao@codesourcery.com>
11028 * i386-low.c (i386_length_and_rw_bits): Move the comment to
11031 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
11033 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
11034 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
11035 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
11036 PT_TEXT_END_ADDR guards. Update comments.
11037 (linux_target_op) <read_offsets>: Conditionally define to
11038 linux_read_offsets if the target is UCLIBC and if it defines
11039 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
11041 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
11042 Andrew Jenner <andrew@codesourcery.com>
11044 * Makefile.in (SFILES): Add linux-nios2-low.c.
11045 (clean): Add action to delete nios2-linux.c.
11046 (nios2-linux.c): New rule.
11047 * configure.srv: Add nios2*-*-linux*.
11048 * linux-nios2-low.c: New.
11050 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
11052 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
11054 2013-04-25 Hui Zhu <hui@codesourcery.com>
11057 * ax.c (ax_printf): Add fflush.
11059 2013-04-22 Tom Tromey <tromey@redhat.com>
11061 * Makefile.in (SFILES): Add filestuff.c.
11062 (OBS): Add filestuff.o.
11063 (filestuff.o): New target.
11064 * config.in, configure: Rebuild.
11065 * configure.ac: Check for fdwalk, pipe2.
11067 2013-04-17 Pedro Alves <palves@redhat.com>
11069 * configure.ac (USE_THREAD_DB): Delete variable.
11070 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
11071 Don't AC_SUBST USE_THREAD_DB.
11072 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
11073 * config.in, configure: Regenerate.
11075 2013-04-16 Pedro Alves <palves@redhat.com>
11077 * linux-low.h (struct lwp_info) <thread_known>: Move under
11078 the USE_THREAD_DB #ifdef.
11080 2013-04-16 Pedro Alves <palves@redhat.com>
11082 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
11083 (linux-low.o): Delete rule.
11084 * linux-low.h: Always include "gdb_thread_db.h" instead of
11085 conditionally including thread_db.h.
11086 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
11089 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
11091 * Makefile.in (install-only): Fix make install regression.
11093 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
11095 Convert man pages to texinfo, new gdbinit.5 texinfo page.
11096 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
11098 * gdbserver.1: Remove.
11100 2013-03-22 Pedro Alves <palves@redhat.com>
11102 * linux-low.c (handle_extended_wait): Don't call
11103 linux_enable_event_reporting.
11105 2013-03-15 Tony Theodore <tonyt@logyst.com>
11108 * Makefile.in (SHELL): Use @SHELL@.
11110 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
11112 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
11115 2013-03-13 Joel Brobecker <brobecker@adacore.com>
11117 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
11118 Remove extraneous NULL element.
11120 2013-03-13 Yao Qi <yao@codesourcery.com>
11122 * tracepoint.c (traceframe_read_tsv): Look for the last matched
11123 'V' block in trace frame.
11125 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
11127 * target.h (struct target_ops): Add btrace ops.
11128 (target_supports_btrace): New macro.
11129 (target_enable_btrace): New macro.
11130 (target_disable_btrace): New macro.
11131 (target_read_btrace): New macro.
11132 * gdbthread.h (struct thread_info): Add btrace field.
11133 * server.c: Include btrace-common.h.
11134 (handle_btrace_general_set): New function.
11135 (handle_btrace_enable): New function.
11136 (handle_btrace_disable): New function.
11137 (handle_general_set): Call handle_btrace_general_set.
11138 (handle_qxfer_btrace): New function.
11139 (struct qxfer qxfer_packets[]): Add btrace entry.
11140 * inferiors.c (remove_thread): Disable btrace.
11141 * linux-low: Include linux-btrace.h.
11142 (linux_low_enable_btrace): New function.
11143 (linux_low_read_btrace): New function.
11144 (linux_target_ops): Add btrace ops.
11145 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
11146 Add srv_linux_btrace=yes.
11147 (x86_64-*-linux*): Add linux-btrace.o.
11148 Add srv_linux_btrace=yes.
11149 * configure.ac: Define HAVE_LINUX_BTRACE.
11150 * config.in: Regenerated.
11151 * configure: Regenerated.
11153 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
11155 * server.c (handle_qxfer): Preserve error message if -3 is
11157 (qxfer): Document the -3 return value.
11159 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
11161 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
11162 (linux_btrace_h): New variable.
11163 (linux-btrace.o): New rule.
11165 2013-03-08 Stan Shebs <stan@codesourcery.com>
11166 Hafiz Abid Qadeer <abidh@codesourcery.com>
11168 * tracepoint.c (trace_buffer_size): New global.
11169 (DEFAULT_TRACE_BUFFER_SIZE): New define.
11170 (init_trace_buffer): Change to one-argument function. Allocate
11171 trace buffer memory.
11172 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
11173 handle QTBuffer:size packet.
11174 (cmd_bigqtbuffer_size): New function.
11175 (initialize_tracepoint): Call init_trace_buffer with
11176 DEFAULT_TRACE_BUFFER_SIZE.
11177 * server.c (handle_query): Add QTBuffer:size in the
11180 2013-03-07 Yao Qi <yao@codesourcery.com>
11182 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
11183 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
11185 (cmd_qtsp): Adjust condition. Do post increment.
11186 Set cur_action and cur_step_action back to 0.
11188 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
11191 * linux-low.c (linux_write_memory): Return early success if LEN is
11194 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
11196 * configure.srv: Add x86_64-*-cygwin* as target.
11198 2013-02-28 Tom Tromey <tromey@redhat.com>
11200 * configure.ac: Invoke AC_SYS_LARGEFILE.
11201 * configure, config.in: Rebuild.
11203 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
11205 * win32-low.c: Throughout, fix format strings and casts of
11206 printf-like functions to avoid type related warnings on all
11208 (get_child_debug_event): Print dwDebugEventCode as hex since
11209 that's how it's usually documented.
11211 2013-02-28 Yao Qi <yao@codesourcery.com>
11213 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
11216 2013-02-27 Jiong Wang <jiwang@tilera.com>
11218 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
11219 (reg-tilegx32.c): New rule.
11220 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
11221 * linux-tile-low.c (tile_arch_setup): New function. Invoke
11222 different register info initializer according to elf class.
11223 (init_registers_tilgx32): New function. The tilegx32 register info
11225 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
11226 (tile_store_gregset): Likewise.
11228 2013-02-27 Yao Qi <yao@codesourcery.com>
11230 * server.c (process_point_options): Print debug message when
11231 debug_threads is true.
11233 2013-02-26 Yao Qi <yao@codesourcery.com>
11235 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
11237 2013-02-19 Pedro Alves <palves@redhat.com>
11238 Kai Tietz <ktietz@redhat.com>
11242 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
11243 instead of strtoul to extract address from packet.
11244 (process_serial_event) <'z'>: Likewise.
11246 2013-02-18 Yao Qi <yao@codesourcery.com>
11248 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
11250 2013-02-14 Pedro Alves <palves@redhat.com>
11254 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
11255 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
11257 2013-02-14 Pedro Alves <palves@redhat.com>
11259 * tracepoint.c (cmd_qtdpsrc): Use savestring.
11261 2013-02-14 Pedro Alves <palves@redhat.com>
11263 * tracepoint.c (save_string): Delete.
11264 (add_tracepoint_action): Use savestring instead of save_string.
11266 2013-02-12 Pedro Alves <palves@redhat.com>
11268 * linux-xtensa-low.c: Ditto.
11269 * xtensa-xtregs.c: Ditto.
11271 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
11273 * thread-db.c (thread_db_get_tls_address): NULL pointer check
11276 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
11278 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
11279 aarch64_num_wp_regs and aarch64_num_bp_regs to
11280 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
11282 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
11284 * linux-aarch64-low.c (ps_get_thread_area): Replace
11285 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
11287 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
11288 Marcus Shawcroft <marcus.shawcroft@arm.com>
11289 Nigel Stephens <nigel.stephens@arm.com>
11290 Yufeng Zhang <yufeng.zhang@arm.com>
11292 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
11293 (aarch64.c, aarch64-without-fpu.c): New targets.
11294 * configure.srv (aarch64*-*-linux*): New.
11295 * linux-aarch64-low.c: New file.
11297 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
11299 * linux-low.c (handle_extended_wait, linux_create_inferior)
11300 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
11301 (dequeue_one_deferred_signal, linux_resume_one_thread)
11302 (fetch_register, linux_write_memory, linux_enable_event_reporting)
11303 (linux_tracefork_grandchild, linux_test_for_tracefork)
11304 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
11305 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
11306 where the argument is 0.
11308 2013-01-25 Yao Qi <yao@codesourcery.com>
11310 * event-loop.c: Include "queue.h".
11311 (gdb_event_p): New typedef.
11312 (struct gdb_event) <next_event>: Remove.
11313 (event_queue): Change to QUEUE(gdb_event_p).
11314 (async_queue_event): Remove.
11315 (gdb_event_xfree): New.
11316 (initialize_event_loop): New.
11317 (process_event): Use API from QUEUE.
11318 (wait_for_event): Likewise.
11319 * server.c (main): Call initialize_event_loop.
11320 * server.h (initialize_event_loop): Declare.
11322 2013-01-18 Yao Qi <yao@codesourcery.com>
11324 * ax.h (struct eval_agent_expr_context): New.
11325 (gdb_eval_agent_expr): Update declaration.
11326 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
11327 TFRAME. Add new argument CTX.
11328 * server.h (struct eval_agent_expr_context): Declare.
11329 (agent_mem_read, agent_tsv_read): Update declaration.
11330 (agent_mem_read_string): Likewise.
11331 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
11332 (add_traceframe_block): Add new argument TPOINT.
11333 Increase TPOINT->traceframe_usage.
11334 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
11335 eval_tracepoint_agent_expr.
11336 (condition_true_at_tracepoint): Likewise.
11337 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
11338 (agent_mem_read_string, agent_tsv_read): Likewise.
11340 2013-01-16 Yao Qi <yao@codesourcery.com>
11342 * linux-low.c (linux_resume_one_lwp): Don't check
11343 'lwp->bp_reinsert != 0'.
11345 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11346 Pedro Alves <palves@redhat.com>
11348 * lynx-low.c (ptrace_request_to_str): Define a temporary
11349 macro and use it to simplify this function's implementation.
11351 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11353 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
11356 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11358 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
11360 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11362 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
11364 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11366 * lynx-low.c (lynx_resume): Use the resume_info parameter
11367 to determine the ptid for the lynx_ptrace call, unless
11368 it is equal to minus_one_ptid, in which case we use the
11369 ptid of the current_inferior.
11370 (lynx_wait_1): After having received a thread create/exit
11371 event, resume the inferior's execution using the signaling
11372 thread's ptid, rather than the old ptid.
11374 2013-01-07 Joel Brobecker <brobecker@adacore.com>
11376 * lynx-low.c (lynx_resume): Delete variable ret.
11378 2013-01-01 Joel Brobecker <brobecker@adacore.com>
11380 * gdbreplay.c (gdbreplay_version): Update copyright year.
11381 * server.c (gdbserver_version): Likewise.
11383 2012-12-17 Joel Brobecker <brobecker@adacore.com>
11385 * lynx-low.c (lynx_wait_1): Add debug trace before adding
11388 2012-12-17 Joel Brobecker <brobecker@adacore.com>
11390 * lynx-low.c (ptrace_request_to_str): Add handling for
11391 PTRACE_GETTRACESIG.
11393 2012-12-17 Joel Brobecker <brobecker@adacore.com>
11395 * lynx-low.c (lynx_attach): Delete variable new_process.
11397 2012-12-17 Joel Brobecker <brobecker@adacore.com>
11399 * lynx-low.c (lynx_create_inferior): Delete variable
11402 2012-12-17 Joel Brobecker <brobecker@adacore.com>
11404 * lynx-low.c (ptrace_request_to_str): Do not handle
11405 PTRACE_GETTHREADLIST if this macro does not exist.
11407 2012-12-15 Yao Qi <yao@codesourcery.com>
11409 * Makefile.in (OBS): Add notif.o.
11410 * notif.c, notif.h: New.
11411 * server.c: Include "notif.h".
11412 (struct vstop_notif) <next>: Remove.
11414 (queue_stop_reply): Update.
11415 (push_event, send_next_stop_reply): Remove.
11416 (discard_queued_stop_replies): Update.
11417 (notif_stop): New variable.
11418 (handle_v_stopped): Remove.
11419 (handle_v_requests): Don't call handle_v_stopped. Call
11420 handle_ack_notif instead.
11421 (queue_stop_reply_callback): Call notif_event_enque instead
11422 of queue_stop_reply.
11423 (handle_status): Don't call send_next_stop_reply, call
11424 notif_write_event instead.
11425 (kill_inferior_callback): Likewise.
11426 (detach_or_kill_inferior_callback): Likewise.
11427 (main): Call initialize_notif.
11428 (process_serial_event): Call QUEUE_is_empty.
11429 (handle_target_event): Call notif_push instead of push event.
11430 * server.h (push_event): Remove declaration.
11432 2012-12-10 Tom Tromey <tromey@redhat.com>
11434 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
11435 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
11438 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
11439 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
11440 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
11441 (amd64-linux-ipa.o, ax.o): Rewrite.
11442 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
11443 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
11444 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
11445 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
11446 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
11447 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
11448 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
11449 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
11450 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
11451 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
11452 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
11453 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
11454 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
11455 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
11456 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
11457 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
11458 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
11459 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
11460 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
11461 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
11462 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
11463 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
11464 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
11465 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
11466 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
11467 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
11468 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
11469 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
11470 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
11471 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
11472 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
11473 (reg-tilegx.o): Remove.
11474 (all_object_files): New macro.
11475 Include .deps files.
11476 * aclocal.m4, configure: Rebuild.
11477 * acinclude.m4: Include depstand.m4, lead-dot.m4.
11478 * configure.ac: Invoke ZW_CREATE_DEPDIR,
11479 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
11481 2012-12-05 Tom Tromey <tromey@redhat.com>
11484 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
11486 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
11488 * configure.ac: Check for linux/perf_event.h.
11489 * config.in: Regenerated.
11490 * configure: Regenerated.
11492 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
11494 * hostio.c (handle_readlink): Decrease buffer size
11495 parameter passed to readlink by one byte.
11497 2012-11-26 Yao Qi <yao@codesourcery.com>
11499 * configure.ac (build_warnings): Append '-Wempty-body'.
11500 * configure: Regenerated.
11501 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
11504 2012-11-15 Pierre Muller <muller@sourceware.org>
11506 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
11507 * config.in: Regenerate.
11508 * configure: Regenerate.
11509 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
11510 Use "gdb_wait.h" header instead of <sys/wait.h> header.
11511 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
11512 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
11514 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
11515 instead of <sys/wait.h> header.
11516 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
11518 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
11520 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
11521 (various make rules): Remove -DGDBSERVER
11523 2012-11-09 Yao Qi <yao@codesourcery.com>
11525 * spu-low.c (current_ptid): Move it to ..
11526 * gdbthread.h: ... here. New.
11527 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
11528 * server.c (myresume, process_serial_event): Likewise.
11529 * thread-db.c (thread_db_find_new_threads): Likewise.
11530 * tracepoint.c (run_inferior_command): Likewise.
11532 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
11534 * server.c (handle_search_memory_1): Include access length in
11537 2012-09-05 Michael Brandt <michael.brandt@axis.com>
11539 * linux-crisv32-low.c: Fix compile errors.
11541 2012-09-04 Yao Qi <yao@codesourcery.com>
11543 * tracepoint.c (cmd_qtsv): Adjust debug message.
11544 Don't check CUR_TPOINT.
11546 2012-08-28 Yao Qi <yao@codesourcery.com>
11548 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
11549 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
11550 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
11551 Remove declarations of xmalloc, xreallloc, xstrdup and
11553 * Makefile.in (libiberty_h): New.
11554 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
11555 (linux-bfin-low.o): Append dependency 'libiberty.h'.
11557 2012-08-23 Yao Qi <yao@codesourcery.com>
11559 * server.h: Remove declaration of 'xsnprintf'.
11561 2012-08-22 Keith Seitz <keiths@redhat.com>
11563 * server.h: Include build-gnulib-gbserver/config.h.
11564 * gdbreplay.c: Likewise.
11566 2012-08-08 Doug Evans <dje@google.com>
11568 * Makefile.in (SFILES): Add gdb_vecs.c.
11569 (OBS): Add gdb_vecs.o.
11570 (gdb_vecs_h, host_defs_h): New variables.
11571 (thread-db.o): Add $(gdb_vecs_h) dependency.
11572 (gdb_vecs.o): New rule.
11573 * thread-db.c: #include "gdb_vecs.h".
11574 (thread_db_load_search): Use a vector to iterate over path elements.
11575 Handle text appearing after "$pdir".
11577 * configure.ac: Add check for strstr.
11578 * config.in: Regenerate.
11579 * configure: Regenerate.
11581 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
11583 * hostio.c (handle_pread): If pread fails, fall back to attempting
11585 (handle_pwrite): Likewise for pwrite.
11587 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
11589 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
11590 between unsupported TYPE and unimplementable ADDR/LEN combination.
11591 (arm_insert_point): Act on new return value.
11593 2012-07-31 Pedro Alves <palves@redhat.com>
11595 * server.c (process_point_options): Only skip tokens if we find
11596 one that is unrecognized. Don't treat 'X' specially while
11597 skipping unrecognized tokens.
11599 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
11601 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
11602 to 4-byte-align HW breakpoint addresses for Thumb.
11604 2012-07-27 Yao Qi <yao@codesourcery.com>
11608 * server.h: Declare gdb_agent_about_to_close.
11609 * target.c (kill_inferior): Include "agent.h".
11610 New. Send command 'kill'.
11611 * target.h (kill_inferior): Removed macro.
11612 * tracepoint.c (gdb_agent_about_to_close): New.
11613 (gdb_agent_helper_thread): Handle command 'close'.
11614 Wait endlessly until the inferior stops.
11615 Install gdb_agent_remove_socket to atexit hook.
11616 (agent_socket_name): New static variable.
11617 (gdb_agent_socket_init): Replace local variable 'name' with
11618 'agent_socket_name'.
11619 (gdb_agent_remove_socket): New.
11621 2012-07-27 Yao Qi <yao@codesourcery.com>
11623 * server.c (process_point_options): Stop at 'X' when parsing.
11625 2012-07-19 Michael Eager <eager@eagercon.com>
11627 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
11629 * linux-x86-low.c (x86_insert_point, x86_remove_point):
11630 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
11631 hardware breakpoint.
11633 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
11635 * gdbserver/linux-low.c (initialize_low): Call
11636 linux_ptrace_init_warnings.
11638 2012-07-02 Doug Evans <dje@google.com>
11640 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
11643 2012-07-02 Stan Shebs <stan@codesourcery.com>
11645 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
11646 (ax.o): Add it to build rule.
11648 (OBS): Add format.o.
11649 (IPA_OBS): Add format.o.
11650 * server.c (handle_query): Claim support for breakpoint commands.
11651 (process_point_options): Add command case.
11652 (process_serial_event): Leave running if there are printfs in
11654 * mem-break.h (any_persistent_commands): Declare.
11655 (add_breakpoint_commands): Declare.
11656 (gdb_no_commands_at_breakpoint): Declare.
11657 (run_breakpoint_commands): Declare.
11658 * mem-break.c (struct point_command_list): New struct.
11659 (struct breakpoint): New field command_list.
11660 (any_persistent_commands): New function.
11661 (add_commands_to_breakpoint): New function.
11662 (add_breakpoint_commands): New function.
11663 (gdb_no_commands_at_breakpoint): New function.
11664 (run_breakpoint_commands): New function.
11665 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
11667 * ax.c: Include format.h.
11668 (ax_printf): New function.
11669 (gdb_eval_agent_expr): Add printf opcode.
11671 2012-06-13 Yao Qi <yao@codesourcery.com>
11673 * server.c (start_inferior): Remove duplicated writes to fields
11674 'last_resume_kind' and 'last_status' of 'current_inferior'.
11676 2012-06-12 Yao Qi <yao@codesourcery.com>
11677 Pedro Alves <palves@redhat.com>
11679 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
11681 * server.c (handle_v_cont): Extend comment.
11683 2012-06-11 Yao Qi <yao@codesourcery.com>
11685 * linux-low.c (linux_attach): Add 'static'.
11687 2012-06-06 Yao Qi <yao@codesourcery.com>
11689 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
11691 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
11693 Fix gcc -flto compilation warning.
11694 * server.c (main): Make variable multi_mode and attach volatile.
11696 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
11698 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
11699 if the platform doesn't know about it.
11701 2012-05-30 Jeff Kenton <jkenton@tilera.com>
11703 * Makefile.in (SFILES): Add linux-tile-low.c.
11704 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
11705 * configure.srv: Handle tilegx-*-linux*.
11706 * linux-tile-low.c: New file.
11708 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
11710 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
11712 2012-05-24 Pedro Alves <palves@redhat.com>
11716 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
11718 2012-05-24 Pedro Alves <palves@redhat.com>
11722 Replace target_signal with gdb_signal throughout.
11724 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
11726 * linux-low.c (linux_store_registers): Avoid the copying sequence
11727 when no data has been retrieved by ptrace.
11729 2012-05-22 Will Deacon <will.deacon@arm.com>
11731 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
11732 Include asm/ptrace.h.
11733 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
11736 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
11738 * linux-low.c (linux_store_registers): Don't re-retrieve data
11739 with ptrace that has already been obtained from /proc. Always
11740 copy any data retrieved with ptrace to the buffer supplied.
11742 2012-05-11 Yao Qi <yao@codesourcery.com>
11743 Pedro Alves <palves@redhat.com>
11745 * linux-low.c (enum stopping_threads_kind): New.
11746 (stopping_threads): Change type to `enum stopping_threads_kind'.
11747 (handle_extended_wait): If stopping and suspending threads, leave
11748 the new_lwp suspended too.
11749 (linux_wait_for_event): Adjust.
11750 (stop_all_lwps): Set `stopping_threads' to
11751 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
11752 whether we're suspending threads or just stopping them. Assert no
11755 2012-04-29 Yao Qi <yao@codesourcery.com>
11757 * server.h: Move some code to ...
11758 * gdbthread.h: ... here. New.
11759 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
11760 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
11761 (nto-low.o, win32-low.o): Likewise.
11762 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
11763 * regcache.c, remote-utils.c, server.c: Likewise.
11764 * target.c, tracepoint.c, win32-low.c: Likewise.
11766 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
11768 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
11769 (PTRACE_ARG4_TYPE): Likewise.
11770 (PTRACE_XFER_TYPE): Likewise.
11771 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
11772 ptrace to PTRACE_ARG3_TYPE.
11773 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
11774 (PTRACE_ARG4_TYPE): Likewise.
11775 (PTRACE_XFER_TYPE): Likewise.
11776 (linux_detach_one_lwp): Cast fourth argument of
11777 ptrace to long then PTRACE_ARG4_TYPE.
11778 (regsets_fetch_inferior_registers): Cast third argument of
11779 ptrace to long then PTRACE_ARG3_TYPE.
11780 (regsets_store_inferior_registers): Likewise.
11782 2012-04-20 Pedro Alves <palves@redhat.com>
11784 * configure: Regenerate.
11786 2012-04-19 Pedro Alves <palves@redhat.com>
11788 * Makefile.in (GNULIB_BUILDDIR): New.
11789 (LIBGNU, INCGNU, GNULIB_H): Adjust.
11790 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
11791 (all, install-only, uninstall, clean-info, all-lib, clean): No
11792 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
11793 (maintainer-clean realclean distclean): Use subdir_do.
11795 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
11796 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
11797 * acinclude.m4: Include acx_configure_dir.m4.
11798 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
11799 calls. Call AC_PROG_RANLIB. Configure gnulib using
11802 (GNULIB_STDINT_H): Adjust.
11803 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
11804 * gdbreplay.c: Include build-gnulib/config.h.
11805 * server.h: Likewise.
11806 * aclocal.m4: Regenerate.
11807 * config.in: Regenerate.
11808 * configure: Regenerate.
11810 2012-04-19 Pedro Alves <palves@redhat.com>
11812 * Makefile.in (LIBGNU, INCGNU): Adjust.
11813 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
11814 (all, install-only, uninstall, clean-info, all-lib, clean)
11815 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
11816 * configure.ac: Adjust AC_OUTPUT output.
11817 * aclocal.m4: Regenerate.
11818 * configure: Regenerate.
11820 2012-04-19 Pedro Alves <palves@redhat.com>
11822 * Makefile.in (generated_files): New.
11823 (server_h): Remove the explicit dependency on config.h, and depend
11824 on $generated_files.
11826 2012-04-19 Pedro Alves <palves@redhat.com>
11828 * Makefile.in (INCGNU): Add -Ignulib.
11830 2012-04-19 Pedro Alves <palves@redhat.com>
11832 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
11833 (INCGNU): ... this, and spell out -I here.
11834 (GNULIB_LIB): Rename to ...
11835 (LIBGNU): ... this.
11836 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
11838 2012-04-19 Pedro Alves <palves@redhat.com>
11840 * config.in: Regenerate.
11842 2012-04-19 Pedro Alves <palves@redhat.com>
11844 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
11845 * server.h (memmem): Remove declaration.
11846 * config.in: Regenerate.
11847 * configure: Regenerate.
11849 2012-04-19 Yao Qi <yao@codesourcery.com>
11851 * Makefile.in (SFILES): Add common/vec.c.
11855 2012-04-19 Yao Qi <yao@codesourcery.com>
11857 * remote-utils.c (prepare_resume_reply): Replace with macro
11858 target_core_of_thread.
11859 * server.c (handle_qxfer_threads_proper): Likewise.
11860 * target.h (traget_core_of_thread): New macro.
11862 2012-04-18 Pedro Alves <palves@redhat.com>
11864 * aclocal.m4: Regenerate.
11865 * configure: Regenerate.
11867 2012-04-16 Yao Qi <yao@codesourcery.com>
11869 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
11870 duplicated on address.
11872 2012-04-16 Yao Qi <yao@codesourcery.com>
11874 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
11875 (struct tracepoint_action_ops) <send>: New field.
11876 (m_tracepoint_action_send, r_tracepoint_action_send): New.
11877 (agent_expr_send, x_tracepoint_action_send): New.
11878 (l_tracepoint_action_send): New.
11879 (cmd_qtdp): Download and install tracepoint
11880 according to `use_agent'.
11881 (run_inferior_command): Add one more parameter `len'.
11883 (tracepoint_send_agent): New.
11884 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
11886 2012-04-16 Yao Qi <yao@codesourcery.com>
11888 * tracepoint.c (download_tracepoints): Moved to ...
11889 (cmd_qtstart): ... here.
11891 2012-04-14 Yao Qi <yao@codesourcery.com>
11893 * tracepoint.c: Include inttypes.h.
11894 (struct collect_memory_action): Use sized types.
11895 (struct tracepoint): Likewise.
11896 (cmd_qtdp, stop_tracing): Update print specifiers.
11897 (cmd_qtp, response_tracepoint): Likewise.
11898 (collect_data_at_tracepoint): Likewise.
11899 (collect_data_at_step): Likewise.
11901 2012-04-14 Yao Qi <yao@codesourcery.com>
11903 Import gnulib module inttypes.
11904 * aclocal.m4, config.in, configure: Regenerated.
11906 2012-04-14 Yao Qi <yao@codesourcery.com>
11908 * Makefile.in (maintainer-clean, realclean, distclean): Remove
11909 Makefile and config.status at last.
11911 2012-04-13 Yao Qi <yao@codesourcery.com>
11913 * tracepoint.c: Include stdint.h unconditionally.
11915 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
11917 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
11918 on BFD_HAVE_SYS_PROCFS_TYPE.
11919 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
11920 * configure: Regenerate.
11921 * config.in: Likewise.
11923 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
11925 * Makefile.in (clean): Also remove x32.c x32-linux.c
11926 x32-avx.c x32-avx-linux.c.
11927 (x32.o): New target.
11929 (x32-linux.o): Likewise.
11930 (x32-linux.c): Likewise.
11931 (x32-avx.o): Likewise.
11932 (x32-avx.c): Likewise.
11933 (x32-avx-linux.o): Likewise.
11934 (x32-avx-linux.c): Likewise.
11936 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
11937 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
11938 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
11939 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
11940 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
11941 i386/x32-avx-linux.xml.
11943 * linux-x86-low.c (init_registers_x32_linux): New prototype.
11944 (init_registers_x32_avx_linux): Likwise.
11945 (x86_linux_update_xmltarget): Call init_registers_x32_linux
11946 or init_registers_x32_avx_linux if linux_is_elf64 is false.
11948 2012-04-13 Pedro Alves <palves@redhat.com>
11950 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
11951 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
11952 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
11953 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
11956 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
11958 * linux-x86-low.c (compat_x32_clock_t): New.
11959 (compat_x32_siginfo_t): Likewise.
11960 (compat_x32_siginfo_from_siginfo): Likewise.
11961 (siginfo_from_compat_x32_siginfo): Likewise.
11962 (linux_is_elf64): Likewise.
11963 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
11964 and siginfo_from_compat_x32_siginfo for x32.
11965 (x86_arch_setup): Set linux_is_elf64.
11967 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
11970 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
11972 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
11973 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
11974 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
11975 compatible with process.
11977 2012-04-12 Yao Qi <yao@codesourcery.com>
11979 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
11980 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
11981 (install-only, install-info, clean): Handle sub dir gnulib.
11982 (all-lib, am--refresh): New targets.
11983 (memmem.o): Remove target.
11984 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
11985 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
11986 (AC_REPLACE_FUNCS): Remove memmem.
11987 Invoke gl_INIT and AM_INIT_AUTOMAKE.
11988 (AC_OUTPUT): Generate Makefile in gnulib/.
11989 * aclocal.m4, config.in, configure: Regenerated.
11991 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
11993 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
11995 2012-04-05 Pedro Alves <palves@redhat.com>
11997 -Werror=strict-aliasing
11999 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
12002 2012-04-04 Pedro Alves <palves@redhat.com>
12004 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
12005 (sparc_store_gregset_from_stack, sparc_store_gregset)
12006 (sparc_breakpoint_at): Fix formatting.
12008 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
12010 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
12012 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
12013 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
12014 * config.in: Regenerate.
12015 * configure: Likewise.
12017 2012-03-29 Pedro Alves <palves@redhat.com>
12019 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
12020 Correct ptrace arguments.
12022 2012-03-28 Pedro Alves <palves@redhat.com>
12024 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
12025 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
12026 (IA64_FR1_REGNUM): New defines.
12027 (ia64_fetch_register): New.
12028 (the_low_target): Install it.
12029 * linux-low.h (struct linux_target_ops) <fetch_register>: New
12031 * linux-low.c (linux_fetch_registers): Try the
12032 the_low_target.fetch_register hook first.
12034 * linux-arm-low.c (the_low_target): Adjust.
12035 * linux-bfin-low.c (the_low_target): Adjust.
12036 * linux-cris-low.c (the_low_target): Adjust.
12037 * linux-crisv32-low.c (the_low_target): Adjust.
12038 * linux-m32r-low.c (the_low_target): Adjust.
12039 * linux-m68k-low.c (the_low_target): Adjust.
12040 * linux-mips-low.c (the_low_target): Adjust.
12041 * linux-ppc-low.c (the_low_target): Adjust.
12042 * linux-s390-low.c (the_low_target): Adjust.
12043 * linux-sh-low.c (the_low_target): Adjust.
12044 * linux-sparc-low.c (the_low_target): Adjust.
12045 * linux-tic6x-low.c (the_low_target): Adjust.
12046 * linux-x86-low.c (the_low_target): Adjust.
12047 * linux-xtensa-low.c (the_low_target): Adjust.
12049 2012-03-26 Pedro Alves <palves@redhat.com>
12051 * server.c (handle_qxfer_libraries): Don't bail early if
12052 the_target->qxfer_libraries_svr4 is not NULL.
12054 2012-03-26 Pedro Alves <palves@redhat.com>
12056 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
12058 2012-03-23 Pedro Alves <palves@redhat.com>
12060 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
12061 "library-list-svr4" element's start tag when the the DSO list is
12064 2012-03-23 Pedro Alves <palves@redhat.com>
12066 * linux-low.c (read_one_ptr): Read the inferior's pointer through
12067 a variable whose type size is the same as the inferior's pointer
12070 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
12072 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
12074 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
12075 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
12076 * linux-low.h: Include <signal.h>.
12077 (struct siginfo): Remove forward declaration.
12078 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
12081 2012-03-21 Mike Frysinger <vapier@gentoo.org>
12083 * .gitignore: Ignore more files.
12085 2012-03-19 Pedro Alves <palves@redhat.com>
12086 Jan Kratochvil <jan.kratochvil@redhat.com>
12088 * server.c (cont_thread, general_thread): Add describing comments.
12089 (start_inferior): Clear `cont_thread'.
12090 (handle_v_cont): Don't set `cont_thread' if resuming all threads
12093 2012-03-15 Yao Qi <yao@codesourcery.com>
12095 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
12097 (cmd_qtdp): ... here.
12099 2012-03-15 Yao Qi <yao@codesourcery.com>
12101 * tracepoint.c (struct tracepoint_action_ops): New.
12102 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
12103 (m_tracepoint_action_download): New.
12104 (r_tracepoint_action_download): New.
12105 (x_tracepoint_action_download): New.
12106 (l_tracepoint_action_download): New.
12107 (add_tracepoint_action): Install `action->ops' according type.
12108 (download_tracepoint_1): Move code `download' function pointer
12109 of various tracepoint_action_ops.
12111 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
12113 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
12114 linux_ptrace_attach_warnings.
12116 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
12118 * Makefile.in (linux-ptrace.o): New.
12119 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
12120 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
12121 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
12122 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
12123 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
12125 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
12127 2012-03-08 Yao Qi <yao@codesourcery.com>
12128 Pedro Alves <palves@redhat.com>
12130 Fix PR server/13392.
12131 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
12132 offset of JMP insn.
12133 * tracepoint.c (remove_tracepoint): New.
12134 (cmd_qtdp): Call remove_tracepoint when failed to install.
12136 2012-03-07 Pedro Alves <palves@redhat.com>
12138 * linux-low.c (get_detach_signal): New.
12139 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
12140 Pass on pending signals to PTRACE_DETACH. Check the result of the
12142 * server.c (program_signals, program_signals_p): New.
12143 (handle_general_set): Handle QProgramSignals.
12144 * server.h (program_signals, program_signals_p): Declare.
12146 2012-03-05 Pedro Alves <palves@redhat.com>
12147 Jan Kratochvil <jan.kratochvil@redhat.com>
12149 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
12152 2012-03-03 Yao Qi <yao@codesourcery.com>
12154 * tracepoint.c (tracepoint_look_up_symbols): Update call to
12155 agent_look_up_symbols.
12157 2012-03-03 Yao Qi <yao@codesourcery.com>
12159 * Makefile.in (linux-low.o): Keep dependence on agent.h.
12160 (linux-x86-low.o): Likewise.
12161 * server.h: Remove in_process_agent_loaded.
12162 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
12166 2012-03-03 Yao Qi <yao@codesourcery.com>
12168 * tracepoint.c (gdb_agent_capability): New global.
12169 (in_process_agent_loaded_ust): Renamed to
12170 `in_process_agent_supports_ust'.
12172 (in_process_agent_supports_ust): Call agent_capability_check.
12173 (clear_installed_tracepoints): Assert that agent supports
12176 2012-03-03 Yao Qi <yao@codesourcery.com>
12178 * linux-low.c (linux_supports_agent): New.
12179 (linux_target_ops): Initialize field `supports_agent' with
12180 linux_supports_agent.
12181 * target.h (struct target_ops) <supports_agent>: New.
12182 (target_supports_agent): New macro.
12183 * server.c (handle_general_set): Handle packet 'QAgent'.
12184 (handle_query): Send `QAgent+'.
12185 * Makefile.in (server.o): Depends on agent.h.
12187 2012-03-03 Yao Qi <yao@codesourcery.com>
12189 * Makefile.in (OBS): Add agent.o.
12190 Add new rule for agent.o.
12191 Track dependence of tracepoint.c on agent.h.
12192 * tracepoint.c (run_inferior_command_1):
12193 (run_inferior_command): Call agent_run_command.
12194 (gdb_ust_connect_sync_socket): Deleted. Move it to
12196 (resume_thread, stop_thread): Likewise.
12197 (gdb_ust_socket_init): Renamed to ...
12198 (gdb_agent_socket_init): ... New.
12199 (gdb_ust_thread): Renamed to ...
12200 (gdb_agent_helper_thread): ... New.
12201 (gdb_ust_init): Move some code to ...
12202 (gdb_agent_init): ... here. New.
12203 [HAVE_UST]: Call gdb_ust_init.
12204 (initialize_tracepoint_ftlib): Call gdb_agent_init.
12205 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
12206 * config.in, configure: Regenerated.
12208 2012-03-02 Pedro Alves <palves@redhat.com>
12210 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
12211 * linux-low.c (struct simple_pid_list): New.
12212 (stopped_pids): New a struct simple_pid_list pointer.
12213 (add_to_pid_list, pull_pid_from_list): New.
12214 (handle_extended_wait): Don't assume the first signal new children
12215 report is SIGSTOP. Adjust call to pull_pid_from_list.
12216 (linux_wait_for_lwp): Adjust.
12218 2012-03-02 Yao Qi <yao@codesourcery.com>
12220 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
12223 2012-03-02 Yao Qi <yao@codesourcery.com>
12225 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
12226 `stop_pc' and `tpoint'. Update caller.
12228 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
12230 * linux-low.h (linux_target_ops): Add regset_bitmap member.
12231 * linux-low.c (use_linux_regsets): New macro.
12232 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
12233 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
12234 (linux_register_in_regsets): New function.
12235 (usr_fetch_inferior_registers): Skip registers covered by
12237 (usr_store_inferior_registers): Likewise.
12238 (usr_fetch_inferior_registers): New macro.
12239 (usr_store_inferior_registers): Likewise.
12240 (linux_fetch_registers): Handle mixed regset/non-regset targets.
12241 (linux_store_registers): Likewise.
12242 * linux-mips-low.c (init_registers_mips_dsp_linux): New
12244 (init_registers_mips64_dsp_linux): Likewise.
12245 (init_registers_mips_linux): New macro.
12246 (init_registers_mips_dsp_linux): Likewise.
12247 (mips_dsp_num_regs): Likewise.
12248 (DSP_BASE, DSP_CONTROL): New fallback macros.
12249 (mips_base_regs): New macro.
12250 (mips_regmap): Use it. Fix the size.
12251 (mips_dsp_regmap): New variable.
12252 (mips_dsp_regset_bitmap): Likewise.
12253 (mips_arch_setup): New function.
12254 (mips_cannot_fetch_register): Use the_low_target.regmap rather
12256 (mips_cannot_store_register): Likewise.
12257 (the_low_target): Update .arch_setup, .num_regs and .regmap
12258 initializers. Add .regset_bitmap initializer.
12259 * linux-arm-low.c (the_low_target): Add .regset_bitmap
12261 * linux-bfin-low.c (the_low_target): Likewise.
12262 * linux-cris-low.c (the_low_target): Likewise.
12263 * linux-crisv32-low.c (the_low_target): Likewise.
12264 * linux-ia64-low.c (the_low_target): Likewise.
12265 * linux-m32r-low.c (the_low_target): Likewise.
12266 * linux-m68k-low.c (the_low_target): Likewise.
12267 * linux-ppc-low.c (the_low_target): Likewise.
12268 * linux-s390-low.c (the_low_target): Likewise.
12269 * linux-sh-low.c (the_low_target): Likewise.
12270 * linux-sparc-low.c (the_low_target): Likewise.
12271 * linux-tic6x-low.c (the_low_target): Likewise.
12272 * linux-x86-low.c (the_low_target): Likewise.
12273 * linux-xtensa-low.c (the_low_target): Likewise.
12274 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
12275 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
12276 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
12278 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
12279 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
12281 2012-02-29 Yao Qi <yao@codesourcery.com>
12282 Pedro Alves <palves@redhat.com>
12284 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
12285 `step_over_finished' is true.
12287 2012-02-27 Pedro Alves <palves@redhat.com>
12289 * linux-low.c (pid_is_stopped): Delete, moved to common/.
12290 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
12292 2012-02-27 Pedro Alves <palves@redhat.com>
12295 * linux-low.c (pid_is_stopped): New.
12296 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
12298 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
12300 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
12303 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
12305 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
12307 2012-02-24 Luis Machado <lgustavo@codesourcery>
12309 * server.c (handle_query): Advertise support for target-side
12310 breakpoint condition evaluation.
12311 (process_point_options): New function.
12312 (process_serial_event): When inserting a breakpoint, check for
12313 a target-side condition that should be evaluated.
12315 * mem-break.c: Include regcache.h and ax.h.
12316 (point_cond_list_t): New data structure.
12317 (breakpoint) <cond_list>: New field.
12318 (find_gdb_breakpoint_at): Make non-static.
12319 (delete_gdb_breakpoint_at): Clear any target-side
12321 (clear_gdb_breakpoint_conditions): New function.
12322 (add_condition_to_breakpoint): Likewise.
12323 (add_breakpoint_condition): Likewise.
12324 (gdb_condition_true_at_breakpoint): Likewise.
12325 (gdb_breakpoint_here): Return result directly instead
12326 of going through a local variable.
12328 * mem-break.h (find_gdb_breakpoint_at): New prototype.
12329 (clear_gdb_breakpoint_conditions): Likewise.
12330 (add_breakpoint_condition): Likewise.
12331 (gdb_condition_true_at_breakpoint): Likewise.
12333 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
12334 (need_step_over_p): Take target-side breakpoint condition into
12337 2012-02-24 Luis Machado <lgustavo@codesourcery>
12339 * server.h: Include tracepoint.h.
12340 (agent_mem_read, agent_get_trace_state_variable_value,
12341 agent_set_trace_state_variable_value,
12342 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
12343 get_set_tsv_func_addr): New prototypes.
12345 * ax.h: New include file.
12346 * ax.c: New source file.
12348 * tracepoint.c: Include ax.h.
12349 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
12350 agent_expr, eval_result_type): Move to ax.h.
12351 (parse_agent_expr): Rename to ...
12352 (gdb_parse_agent_expr): ... this, make it non-static and move
12354 (unparse_agent_expr) Rename to ...
12355 (gdb_unparse_agent_expr): ... this, make it non-static and move
12357 (eval_agent_expr): Rename to ...
12358 (eval_tracepoint_agent_expr): ... this.
12359 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
12360 forward declarations.
12361 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
12362 (agent_get_trace_state_variable_value): New function.
12363 (agent_set_trace_state_variable_value): New function.
12364 (cmd_qtdp): Call gdb_parse_agent_expr (...).
12365 (response_tracepoint): Call gdb_unparse_agent_expr (...).
12366 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
12367 (condition_true_at_tracepoint): Likewise.
12368 (parse_agent_expr): Rename to ...
12369 (gdb_parse_agent_expr): ... this and move to ax.c.
12370 (unparse_agent_expr): Rename to ...
12371 (gdb_unparse_agent_expr): ... this and move to ax.c.
12372 (gdb_agent_op_name): Move to ax.c.
12373 (eval_agent_expr): Rename to ...
12374 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
12376 (eval_tracepoint_agent_expr): New function.
12377 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
12379 (current_insn_ptr, emit_error, struct bytecode_address): Move to
12381 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
12382 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
12383 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
12384 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
12385 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
12386 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
12387 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
12388 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
12389 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
12390 (compile_bytecodes): Remove forward declaration.
12391 (is_goto_target): Move to ax.c.
12392 (compile_bytecodes): Move to ax.c and call
12393 agent_get_trace_state_variable_value (...) and
12394 agent_set_trace_state_variable_value (...).
12396 * Makefile.in: Update ax.c and IPA dependencies.
12398 2012-02-24 Pedro Alves <palves@redhat.com>
12400 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
12401 (cmd_bigqtbuffer_circular): ... this. Only handle
12402 'QTBuffer:circular:'.
12403 (handle_tracepoint_general_set): Adjust.
12405 2012-02-16 Yao Qi <yao@codesourcery.com>
12407 * inferiors.c: Move code to ...
12408 * dll.c: .... here. New.
12409 * server.h: Declare clear_dlls.
12410 * Makefile.in (SFILES): Add dll.c.
12414 2012-02-11 Yao Qi <yao@codesourcery.com>
12416 * server.c: (handle_monitor_command): Add a new parameter
12418 (handle_query): Update caller.
12420 2012-02-09 Joel Brobecker <brobecker@adacore.com>
12422 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
12423 * configure, config.in: Regenerate.
12424 * hostio.c: Provide an alternate implementation if HAVE_READLINK
12427 2012-02-02 Pedro Alves <palves@redhat.com>
12429 Try SIGKILL first, then PTRACE_KILL.
12430 * linux-low.c (linux_kill_one_lwp): New.
12431 (linux_kill_one_lwp): Rename to ...
12432 (kill_one_lwp_callback): ... this. Use the new
12433 linux_kill_one_lwp.
12435 2012-02-02 Pedro Alves <palves@redhat.com>
12437 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
12440 2012-01-27 Pedro Alves <palves@redhat.com>
12442 * linux-low.c (linux_child_pid_to_exec_file): Delete.
12443 (elf_64_file_p): Make static.
12444 (linux_pid_exe_is_elf_64_file): New.
12445 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
12446 Delete declarations.
12447 (linux_pid_exe_is_elf_64_file): Declare.
12448 * linux-x86-low.c (x86_arch_setup): Use
12449 linux_pid_exe_is_elf_64_file.
12451 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
12453 * linux-low.c (linux_wait_for_event_1): Rename to ...
12454 (linux_wait_for_event): ... here and merge it with former
12455 linux_wait_for_event - new variable wait_ptid, use it.
12456 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
12458 2012-01-23 Pedro Alves <palves@redhat.com>
12460 * server.c (main): Avoid yet another case of infinite loop while
12461 detaching/killing after a longjmp.
12463 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12466 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
12468 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
12470 * hostio.c (handle_readlink): New function.
12471 (handle_vFile): Call it to handle "vFile:readlink" packets.
12473 2012-01-20 Pedro Alves <palves@redhat.com>
12474 Ulrich Weigand <ulrich.weigand@linaro.org>
12476 * server.c (handle_v_requests): Only support vAttach and vRun to
12477 start multiple processes when in extended protocol mode.
12479 2012-01-17 Pedro Alves <palves@redhat.com>
12481 * tracepoint.c (initialize_tracepoint): Use mmap instead of
12482 memalign plus mprotect to allocate the scratch buffer.
12484 2012-01-13 Pedro Alves <palves@redhat.com>
12486 * server.c (attach_inferior): Clear `cont_thread'.
12488 2012-01-13 Pedro Alves <palves@redhat.com>
12490 * server.c (main): Avoid infinite loop while detaching/killing
12493 2012-01-09 Doug Evans <dje@google.com>
12495 * server.c (start_inferior): Set last_ptid in --wrapper case.
12497 2012-01-06 Yao Qi <yao@codesourcery.com>
12499 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
12501 [IN_PROCESS_AGENT] (debug_agent): New global variable.
12503 2012-01-04 Yao Qi <yao@codesourcery.com>
12505 * tracepoint.c (cmd_qtdp): Print debug message
12506 for static tracepoint.
12508 2012-01-04 Yao Qi <yao@codesourcery.com>
12510 * tracepoint.c (trace_vdebug): Differentiate debug message
12511 between gdbserver and IPA.
12513 2012-01-03 Yao Qi <yao@codesourcery.com>
12515 * tracepoint.c (tracepoint_was_hit): Don't collect for
12518 2012-01-02 Joel Brobecker <brobecker@adacore.com>
12520 * terminal.h: Reformat copyright header.
12522 2012-01-02 Joel Brobecker <brobecker@adacore.com>
12524 * server.c (gdbserver_version): Update copyright year.
12525 * gdbreplay.c (gdbreplay_version): Likewise.
12527 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
12529 * linux-low.c (linux_create_inferior): Put empty if clause for write.
12532 2011-12-18 Hui Zhu <teawater@gmail.com>
12533 * linux-low.c (linux_create_inferior): Save return value to ret.
12535 2011-12-18 Hui Zhu <teawater@gmail.com>
12537 * linux-low.c (linux_create_inferior): Save return value to ret.
12539 2011-12-16 Doug Evans <dje@google.com>
12541 * linux-low.c (linux_create_inferior): If stdio connection,
12542 redirect stdin from /dev/null, stdout to stderr.
12543 * remote-utils.c (remote_is_stdio): New static global.
12544 (remote_connection_is_stdio): New function.
12545 (remote_prepare): Handle stdio connection.
12546 (remote_open): Ditto.
12547 (remote_close): Don't close stdin for stdio connections.
12548 (read_prim,write_prim): New functions. Replace all calls to
12549 read/write to these.
12550 * server.c (main): Watch for "-" argument. Move call to
12551 remote_prepare before start_inferior.
12552 * server.h (STDIO_CONNECTION_NAME): New macro.
12553 (remote_connection_is_stdio): Declare.
12555 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
12556 in debugging output.
12558 2011-12-15 Yao Qi <yao@codesourcery.com>
12560 * tracepoint.c: Include sys/syscall.h.
12561 (gdb_ust_thread): Remove preprocessor conditional.
12563 2011-12-14 Pedro Alves <pedro@codesourcery.com>
12565 * linux-low.c (linux_detach_one_lwp): Call
12566 the_low_target.prepare_to_resume before detaching.
12568 2011-12-14 Yao Qi <yao@codesourcery.com>
12570 * tracepoint.c (gdb_ust_thread): Don't ignore return value
12573 2011-12-14 Yao Qi <yao@codesourcery.com>
12575 * i386-low.c (i386_low_stopped_data_address): Initialize local
12576 variable `control'.
12578 2011-12-13 Pedro Alves <pedro@codesourcery.com>
12582 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
12583 DR_CONTROL unless necessary. Extend comments.
12584 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
12585 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
12587 2011-12-13 Yao Qi <yao@codesourcery.com>
12589 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
12591 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
12593 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
12595 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
12596 Print new debug message for such case.
12598 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
12600 Fix overlapping memcpy.
12601 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
12602 the read_inferior_memory transfer.
12603 (delete_fast_tracepoint_jump): New variable buf. Use it for the
12604 write_inferior_memory transfer.
12605 (set_fast_tracepoint_jump): New variable buf. Use it for the
12606 read_inferior_memory and write_inferior_memory transfers.
12607 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
12608 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
12609 Use it for the write_inferior_memory transfer.
12610 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
12613 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
12615 * linux-low.c (fetch_register, store_register): Make code
12616 consistent, fix formatting.
12618 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
12620 * linux-low.c (usr_store_inferior_registers): Factor out code
12621 to handle individual registers into...
12622 (store_register): ... this new function.
12624 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
12626 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
12627 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
12628 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
12629 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
12630 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
12631 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
12632 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
12633 (srv_xmlfiles): Add new XML files.
12635 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
12637 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
12638 (init_registers_s390_linux32v1): Add prototype.
12639 (init_registers_s390_linux32v2): Likewise.
12640 (init_registers_s390_linux64v1): Likewise.
12641 (init_registers_s390_linux64v2): Likewise.
12642 (init_registers_s390x_linux64v1): Likewise.
12643 (init_registers_s390x_linux64v2): Likewise.
12644 (s390_num_regs): Increment to 52.
12645 (s390_regmap): Add orig_r2 register.
12646 (s390_num_regs_3264): Increment to 68.
12647 (s390_regmap_3264): Add orig_r2 register.
12648 (s390_collect_ptrace_register): Handle orig_r2 register.
12649 (s390_supply_ptrace_register): Likewise.
12650 (s390_fill_last_break): New function.
12651 (s390_store_last_break): Likewise.
12652 (s390_fill_system_call): New function.
12653 (s390_store_system_call): Likewise.
12654 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
12656 (s390_check_regset): New function.
12657 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
12658 NT_S390_SYSTEM_CALL regsets and use appropriate description.
12659 Update target_regsets for available register sets.
12661 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
12662 Jan Kratochvil <jan.kratochvil@redhat.com>
12664 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
12665 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
12667 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
12668 * linux-low.h (struct process_info_private): New member r_debug.
12669 * server.c (handle_qxfer_libraries): Call
12670 the_target->qxfer_libraries_svr4.
12671 (handle_qxfer_libraries_svr4): New function.
12672 (qxfer_packets): New entry "libraries-svr4".
12673 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
12674 * target.h (struct target_ops): New member qxfer_libraries_svr4.
12675 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
12676 PACKET_qXfer_libraries_svr4.
12678 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
12680 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
12681 PSW address/mask between 8-byte and 16-byte formats.
12682 (s390_supply_ptrace_register): Likewise.
12683 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
12684 basic addressing mode bit.
12686 2011-11-24 Stan Shebs <stan@codesourcery.com>
12688 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
12690 2011-11-17 Stan Shebs <stan@codesourcery.com>
12692 * tracepoint.c (struct tracepoint): New field traceframe_usage.
12693 (tracing_start_time): New global.
12694 (tracing_stop_time): New global.
12695 (tracing_user_name): New global.
12696 (tracing_notes): New global.
12697 (tracing_stop_note): New global.
12698 (cmd_qtstart): Set traceframe_usage, start_time.
12699 (stop_tracing): Set stop_time.
12700 (cmd_qtstatus): Report additional status.
12701 (cmd_qtp): New function.
12702 (handle_tracepoint_query): Call it.
12703 (cmd_qtnotes): New function.
12704 (handle_tracepoint_general_set): Call it.
12705 (get_timestamp): Rename from tsv_get_timestamp.
12707 2011-11-14 Stan Shebs <stan@codesourcery.com>
12708 Kwok Cheung Yeung <kcy@codesourcery.com>
12710 * linux-x86-low.c (small_jump_insn): New.
12711 (i386_install_fast_tracepoint_jump_pad): Add arguments for
12712 trampoline and error message, build a trampoline and issue a small
12713 jump instruction to it.
12714 (x86_install_fast_tracepoint_jump_pad): Add arguments for
12715 trampoline and error message.
12716 (x86_get_min_fast_tracepoint_insn_len): New.
12717 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
12718 * linux-low.h (struct linux_target_ops): Add arguments to
12719 install_fast_tracepoint_jump_pad operation, add new operation.
12720 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
12722 (linux_get_min_fast_tracepoint_insn_len): New function.
12723 (linux_target_op): Add new operation.
12724 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
12725 (gdb_trampoline_buffer_end): Ditto.
12726 (gdb_trampoline_buffer_error): Ditto.
12727 (struct ipa_sym_addresses): Add fields for new IPA variables.
12728 (symbol_list): Add entries for new IPA variables.
12729 (struct tracepoint): Add fields to hold the address range of the
12730 trampoline used by the tracepoint.
12731 (trampoline_buffer_head): New static variable.
12732 (trampoline_buffer_tail): Ditto.
12733 (claim_trampoline_space): New function.
12734 (have_fast_tracepoint_trampoline_buffer): New function.
12735 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
12737 (install_fast_tracepoint): Ditto, also add error buffer argument.
12738 (cmd_qtminftpilen): New function.
12739 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
12740 (fast_tracepoint_from_trampoline_address): New function.
12741 (fast_tracepoint_collecting): Handle trampoline as part of jump
12743 (set_trampoline_buffer_space): New function.
12744 (initialize_tracepoint): Initialize new IPA variables.
12745 * target.h (struct target_ops): Add arguments to
12746 install_fast_tracepoint_jump_pad operation, add new
12747 get_min_fast_tracepoint_insn_len operation.
12748 (target_get_min_fast_tracepoint_insn_len): New.
12749 (install_fast_tracepoint_jump_pad): Add arguments.
12750 * server.h (IPA_BUFSIZ): Define.
12751 * linux-i386-ipa.c: Include extra header files.
12752 (initialize_fast_tracepoint_trampoline_buffer): New function.
12753 (initialize_low_tracepoint): Call it.
12754 * server.h (set_trampoline_buffer_space): Declare.
12755 (claim_trampoline_space): Ditto.
12756 (have_fast_tracepoint_trampoline_buffer): Ditto.
12758 2011-11-14 Yao Qi <yao@codesourcery.com>
12760 * server.c (handle_query): Handle InstallInTrace for qSupported.
12761 * tracepoint.c (add_tracepoint): Sort list.
12762 (install_tracepoint, download_tracepoint): New.
12763 (cmd_qtdp): Call them to install and download tracepoints.
12764 (sort_tracepoints): Removed.
12765 (cmd_qtstart): Update.
12767 2011-11-14 Yao Qi <yao@codesourcery.com>
12769 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
12770 * mem-break.h: Declare.
12771 * tracepoint.c (cmd_qtstart): Move some code to ...
12772 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
12774 (download_tracepoints): Move some code to ...
12775 (download_tracepoint_1): ... here. New.
12777 2011-11-08 Yao Qi <yao@codesourcery.com>
12779 * remote-utils.c (relocate_instruction): A comment fix.
12781 2011-11-07 Joel Brobecker <brobecker@adacore.com>
12783 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
12784 (i386_dr_low_get_control, i386_dr_low_get_status): Use
12785 dr_status_mirror and dr_control_mirror from debug_reg_state.
12786 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
12787 (i386_initial_stuff): Remove use of deleted globals.
12788 (i386_get_thread_context, i386_set_thread_context,
12789 i386_thread_added): Use dr_status_mirror and dr_control_mirror
12790 from debug_reg_state.
12792 2011-11-05 Yao Qi <yao@codesourcery.com>
12794 * tracepoint.c (gdb_collect): Loop over tracepoints of same
12795 address as TPOINT's.
12797 2011-11-02 Stan Shebs <stan@codesourcery.com>
12799 * tracepoint.c (agent_mem_read_string): New function.
12800 (eval_agent_expr): Call it for tracenz.
12801 * server.c (handle_query): Report support for tracenz.
12803 2011-11-02 Yao Qi <yao@codesourcery.com>
12805 * tracepoint.c (cmd_qtstart): Remove unused local variables.
12807 2011-11-02 Yao Qi <yao@codesourcery.com>
12809 * target.h: Fix a typo in comment.
12811 2011-10-31 Pedro Alves <pedro@codesourcery.com>
12813 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
12814 clobber the breakpoints' shadows with fast tracepoint jumps.
12815 * mem-break.h (check_mem_write): Add `myaddr' parameter.
12816 * target.c (write_inferior_memory): Also pass MYADDR down to
12819 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
12821 * configure.ac: Check support for personality routine.
12822 * configure: Regenerate.
12823 * config.in: Likewise.
12824 * linux-low.c: Include <sys/personality.h>.
12825 Define ADDR_NO_RANDOMIZE if necessary.
12826 (linux_create_inferior): Disable address space randomization when
12827 forking inferior, if requested.
12828 (linux_supports_disable_randomization): New function.
12829 (linux_target_ops): Install it.
12830 * server.h (disable_randomization): Declare.
12831 * server.c (disable_randomization): New global variable.
12832 (handle_general_set): Handle QDisableRandomization.
12833 (handle_query): Likewise for qSupported.
12834 (main): Support --disable-randomization and --no-disable-randomization
12835 command line arguments.
12836 * target.h (struct target_ops): Add supports_disable_randomization.
12837 (target_supports_disable_randomization): New macro.
12839 2011-09-29 Mike Frysinger <vapier@gentoo.org>
12841 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
12843 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
12844 [!PT_GETDSBT] (target_loadmap): New definition.
12845 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
12846 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
12847 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
12848 and PT_GETDSBT to LINUX_LOADMAP.
12849 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
12850 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
12852 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
12854 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
12855 (arm_linux_hwbp_cap): New static variable.
12856 (arm_linux_get_hwbp_cap): Replace by ...
12857 (arm_linux_init_hwbp_cap): ... this new function.
12858 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
12859 (arm_linux_get_hw_watchpoint_count): Likewise.
12860 (arm_linux_get_hw_watchpoint_max_length): Likewise.
12861 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
12862 (arm_prepare_to_resume): Use perror_with_name instead of error.
12864 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
12866 * linux-arm-low.c: Include <signal.h>.
12867 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
12868 (struct arm_linux_hwbp_cap): New data type.
12869 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
12870 (struct arm_linux_hw_breakpoint): New data type.
12871 (MAX_BPTS, MAX_WPTS): Define.
12872 (struct arch_process_info, struct arch_lwp_info): New data types.
12873 (arm_linux_get_hwbp_cap): New function.
12874 (arm_linux_get_hw_breakpoint_count): Likewise.
12875 (arm_linux_get_hw_watchpoint_count): Likewise.
12876 (arm_linux_get_hw_watchpoint_max_length): Likewise.
12877 (arm_hwbp_control_initialize): Likewise.
12878 (arm_hwbp_control_is_enabled): Likewise.
12879 (arm_hwbp_control_is_initialized): Likewise.
12880 (arm_hwbp_control_disable): Likewise.
12881 (arm_linux_hw_breakpoint_equal): Likewise.
12882 (arm_linux_hw_point_initialize): Likewise.
12883 (struct update_registers_data): New data structure.
12884 (update_registers_callback: New function.
12885 (arm_insert_point): Likewise.
12886 (arm_remove_point): Likewise.
12887 (arm_stopped_by_watchpoint): Likewise.
12888 (arm_stopped_data_address): Likewise.
12889 (arm_new_process): Likewise.
12890 (arm_new_thread): Likewise.
12891 (arm_prepare_to_resume): Likewise.
12892 (the_low_target): Register arm_insert_point, arm_remove_point,
12893 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
12894 arm_new_thread, and arm_prepare_to_resume.
12896 2011-09-15 Stan Shebs <stan@codesourcery.com>
12898 * server.h (struct emit_ops): Add compare-goto fields.
12899 * tracepoint.c (gdb_agent_op_sizes): New table.
12900 (emit_eq_goto): New function.
12901 (emit_ne_goto): New function.
12902 (emit_lt_goto): New function.
12903 (emit_le_goto): New function.
12904 (emit_gt_goto): New function.
12905 (emit_ge_goto): New function.
12906 (is_goto_target): New function.
12907 (compile_bytecodes): Recognize special cases of compare-goto
12908 combinations and call specialized emitters for them.
12909 * linux-x86-low.c (amd64_emit_eq_goto): New function.
12910 (amd64_emit_ne_goto): New function.
12911 (amd64_emit_lt_goto): New function.
12912 (amd64_emit_le_goto): New function.
12913 (amd64_emit_gt_goto): New function.
12914 (amd64_emit_ge_goto): New function.
12915 (amd64_emit_ops): Add the new functions.
12916 (i386_emit_eq_goto): New function.
12917 (i386_emit_ne_goto): New function.
12918 (i386_emit_lt_goto): New function.
12919 (i386_emit_le_goto): New function.
12920 (i386_emit_gt_goto): New function.
12921 (i386_emit_ge_goto): New function.
12922 (i386_emit_ops): Add the new functions.
12924 2011-09-08 Stan Shebs <stan@codesourcery.com>
12926 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
12927 (i386_emit_epilogue): Restore %ebx.
12929 2011-08-31 Jie Zhang <jzhang918@gmail.com>
12931 * server.c (step_thread): Remove definition.
12932 (process_serial_event): Don't handle Hs.
12933 * server.h (step_thread): Remove declaration.
12934 * target.c (set_desired_inferior): Remove use of step_thread.
12936 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
12938 * linux-low.c: Include linux-procfs.h.
12939 (linux_attach_lwp_1): Update comments.
12940 (linux_attach): Scan for existing threads when attaching to a
12941 process that is the tgid.
12942 * Makefile.in: Update dependencies.
12944 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
12946 * configure.srv: Add linux-procfs.o dependencies.
12948 2011-08-14 Yao Qi <yao@codesourcery.com>
12950 * target.h (struct target_ops): Fix indent.
12951 * win32-low.c (win32_target_ops): Fix comment.
12953 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
12954 Yao Qi <yao@codesourcery.com>
12956 * Makefile.in (clean): Remove tic6x-*.c files.
12957 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
12958 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
12959 (tic6x-c64xp-linux.c): Likewise.
12960 * configure.srv: Add support for tic6x-*-uclinux.
12961 * linux-tic6x-low.c: New.
12962 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
12964 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
12965 Yao Qi <yao@codesourcery.com>
12967 * target.h (struct target_ops): Add read_loadmap.
12968 * linux-low.c (struct target_loadseg): New type.
12969 (struct target_loadmap): New type.
12970 (linux_read_loadmap): New function.
12971 (linux_target_ops): Add linux_read_loadmap.
12972 * server.c (handle_query): Support qXfer:fdpic:read packet.
12973 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
12976 2011-08-05 Eli Zaretskii <eliz@gnu.org>
12978 * win32-low.c: Include <stdint.h>.
12980 2011-07-22 Pedro Alves <pedro@codesourcery.com>
12982 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
12983 to the inferior here.
12984 (i386_remove_aligned_watchpoint): Ditto.
12985 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
12986 fit part of the watchpoint in the debug registers.
12987 (i386_update_inferior_debug_regs): New.
12988 (i386_low_insert_watchpoint): Work on a local mirror of the debug
12989 registers, and only update the inferior on success.
12990 (i386_low_remove_watchpoint): Ditto.
12992 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
12994 * linux-low.c (compare_ints, unique, list_threads, show_process,
12995 linux_core_of_thread): Delete.
12996 (linux_target_ops): Change linux_core_of_thread to
12997 linux_common_core_of_thread.
12998 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
12999 * utils.c (malloc_failure): Change type of argument.
13000 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
13001 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
13002 common/linux-osdata.c, common/ptid.c and common/buffer.c.
13003 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
13004 (IPA_OBJS): Add common-utils-ipa.o.
13005 (ptid_h, linux_osdata_h): New macros.
13006 (server_h): Add common/common-utils.h, common/xml-utils.h,
13007 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
13009 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
13010 ptid.o, buffer.o): New rules.
13011 (linux-low.o): Add common/linux-osdata.h as a dependency.
13012 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
13013 * configure.ac: Add AC_HEADER_DIRENT check.
13014 * config.in: Regenerate.
13015 * configure: Regenerate.
13016 * remote-utils.c (xml_escape_text): Delete.
13017 (buffer_grow, buffer_free, buffer_init, buffer_finish,
13018 buffer_xml_printf): Move to common/buffer.c.
13019 * server.c (main): Remove call to initialize_inferiors.
13020 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
13021 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
13022 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
13023 internal_error, gdb_assert, gdb_assert_fail): Delete.
13024 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
13025 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
13027 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
13028 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
13029 initialize_inferiors): Delete.
13031 2011-07-20 Pedro Alves <pedro@codesourcery.com>
13033 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
13036 2011-05-31 Pedro Alves <pedro@codesourcery.com>
13038 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
13040 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
13042 2011-05-26 Yao Qi <yao@codesourcery.com>
13044 * Makefile.in (thread-db.o): Track dependence to
13045 common/gdb_thread_db.h.
13046 * thread-db.c: include gdb_thread_db.h from right place.
13048 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
13050 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
13051 __FILE__ and __LINE__ to internal_error.
13053 2011-05-13 Doug Evans <dje@google.com>
13055 * thread-db.c (try_thread_db_load_from_sdir): New function.
13056 (try_thread_db_load_from_dir): New function.
13057 (thread_db_load_search): Handle $sdir, ignore $pdir.
13058 Remove trying of system directories if search of
13059 libthread-db-search-path fails, that is now done via $sdir.
13061 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
13063 * server.c (handle_query): Add EnableDisableTracepoints to the list
13064 of supported features.
13065 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
13067 (cmd_qtenable_disable): New.
13068 (cmd_qtstart): Install tracepoints even if disabled.
13069 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
13070 receiving a QTEnable or QTDisable packet.
13071 (gdb_collect): Skip data collection if fast tracepoint is disabled.
13072 (ust_marker_to_static_tracepoint): Do not ignore disabled static
13074 (gdb_probe): Skip data collection if static tracepoint is disabled.
13076 2011-05-10 Doug Evans <dje@google.com>
13078 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
13080 2011-05-04 Doug Evans <dje@google.com>
13082 * linux-low.c (linux_join): Skip process lookup.
13083 * spu-low.c (spu_join): Ditto.
13084 * server.c (join_inferiors_callback): Delete.
13085 (process_serial_event): For 'D' packet (detach) call join_inferior
13088 2011-05-04 Joseph Myers <joseph@codesourcery.com>
13090 * README: Don't mention xscale*-*-linux*.
13091 * configure.srv (xscale*-*-linux*): Don't handle target.
13093 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
13095 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
13097 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
13098 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
13099 (i386_emit_void_call_2): Likewise.
13101 2011-04-26 Yao Qi <yao@codesourcery.com>
13103 * linux-low.c: Move common macros to linux-ptrace.h.
13104 Include linux-ptrace.h.
13105 * Makefile.in (linux_ptrace_h): New.
13106 (linux-low.o): Depends on linux-ptrace.h.
13108 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
13110 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
13111 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
13112 (remote_prepare): New function with most of the TCP code from ...
13113 (remote_open): ... here. Detect PORT here unconditionally. Move also
13114 setting transport_is_reliable.
13115 * server.c (run_once): New variable.
13116 (gdbserver_usage): Document it.
13117 (main): Set run_once for `--once'. Call remote_prepare. Exit after
13118 the first run if RUN_ONCE.
13119 * server.h (run_once, remote_prepare): New declarations.
13121 2011-04-19 Tom Tromey <tromey@redhat.com>
13123 * win32-low.c (handle_load_dll): Remove duplicate "the".
13125 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
13127 Remove support for old Cygwin 1.5 versions.
13128 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
13129 function to avoid warning.
13130 (win32_add_one_solib): Use cygwin_conv_path function to avoid
13133 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
13135 * gdbserver/server.h (Macro _): Define it if not available.
13137 2011-03-14 Michael Snyder <msnyder@vmware.com>
13139 * hostio.c (handle_close): Remove unnecessary null test.
13141 2011-03-10 Joel Brobecker <brobecker@adacore.com>
13143 * Makefile.in (maintainer-clean realclean distclean): Remove
13144 "make ... subdir_do" command.
13146 2011-03-10 Michael Snyder <msnyder@vmware.com>
13148 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
13150 * server.c (handle_v_run): Free alloced buffer on early return.
13152 2011-03-09 Yao Qi <yao@codesourcery.com>
13155 2011-03-04 Yao Qi <yao@codesourcery.com>
13157 * Makefile.in: Remove GNU make feature --directory.
13159 2011-03-05 Yao Qi <yao@codesourcery.com>
13161 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
13162 (subdir_do): New make target. Copied from gdb/Makefile.
13163 (maintainer-clean, realclean, distclean, clean): Call corresponding
13164 make targets in common/Makefile.
13166 2011-02-11 Yao Qi <yao@codesourcery.com>
13168 * configure.ac: Call AC_PROG_RANLIB.
13169 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
13170 * configure: Regenerate.
13172 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
13174 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
13176 2011-03-06 Yao Qi <yao@codesourcery.com>
13178 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
13180 2011-03-05 Yao Qi <yao@codesourcery.com>
13182 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
13183 (subdir_do): New make target. Copied from gdb/Makefile.
13184 (maintainer-clean, realclean, distclean, clean): Call corresponding
13185 make targets in common/Makefile.
13187 2011-03-04 Yao Qi <yao@codesourcery.com>
13189 * Makefile.in: Remove GNU make feature --directory.
13191 2011-03-04 Michael Snyder <msnyder@vmware.com>
13193 * server.c (queue_stop_reply): Call xmalloc not malloc.
13195 2011-03-02 Michael Snyder <msnyder@vmware.com>
13197 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
13199 2011-02-28 Michael Snyder <msnyder@vmware.com>
13201 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
13202 (cmd_qtframe): Ditto.
13203 (cmd_qtbuffer): Ditto.
13204 (cmd_bigqtbuffer): Ditto.
13206 * utils.c (decimal2str): Initialize 'width' to nine, then
13207 don't mess with it.
13209 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
13211 * hostio.c (require_data): Free *data, not data.
13213 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13215 * hostio.c (require_data): Use free, not xfree.
13217 2011-02-27 Michael Snyder <msnyder@vmware.com>
13219 * server.c (handle_query): Discard unused value.
13221 * hostio.c (require_data): Free malloc memory before returning
13224 2011-02-26 Michael Snyder <msnyder@vmware.com>
13226 * linux-low.c (list_threads): Call closedir for dirent.
13228 2011-02-27 Michael Snyder <msnyder@vmware.com>
13230 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
13231 a case statement falls through.
13233 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
13235 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
13238 2011-02-26 Michael Snyder <msnyder@vmware.com>
13240 * utils.c (decimal2str): Eliminate dead code and dead param.
13241 (pulongest): Drop dead param from call to decimal2str.
13244 2011-02-24 Joel Brobecker <brobecker@adacore.com>
13246 Revert the following patch (not approved yet):
13247 2011-02-21 Hui Zhu <teawater@gmail.com>
13248 * tracepoint.c (tp_printf): New function.
13249 (eval_agent_expr): Handle gdb_agent_op_printf.
13251 2011-02-21 Hui Zhu <teawater@gmail.com>
13253 * tracepoint.c (tp_printf): New function.
13254 (eval_agent_expr): Handle gdb_agent_op_printf.
13256 2011-02-18 Tom Tromey <tromey@redhat.com>
13258 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
13259 (tracepoint.o): Likewise.
13260 * tracepoint.c (enum gdb_agent_op): Use ax.def.
13261 (gdb_agent_op_names): Likewise.
13263 2011-02-18 Tom Tromey <tromey@redhat.com>
13265 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
13266 gdb_agent_op_rot>: New constants.
13267 (gdb_agent_op_names): Add pick and roll.
13268 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
13271 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
13273 * aclocal.m4: Regenerated with aclocal-1.11.1.
13275 2011-02-14 Pedro Alves <pedro@codesourcery.com>
13277 * server.c (handle_qxfer_traceframe_info): New.
13278 (qxfer_packets): Register "traceframe-info".
13279 (handle_query): Report support for qXfer:traceframe-info:read+.
13280 * tracepoint.c (match_blocktype): New.
13281 (traceframe_find_block_type): Rename to ...
13282 (traceframe_walk_blocks): ... this. Add callback filter argument,
13284 (traceframe_find_block_type): New, reimplemented on top of
13285 traceframe_walk_blocks.
13286 (build_traceframe_info_xml): New.
13287 (traceframe_read_info): New.
13288 * server.h (traceframe_read_info): Declare.
13290 2011-02-11 Yao Qi <yao@codesourcery.com>
13292 * configure.ac: Call AC_PROG_RANLIB.
13293 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
13294 * configure: Regenerate.
13296 2011-02-07 Pedro Alves <pedro@codesourcery.com>
13298 * server.c (gdb_read_memory): Change return semantics to allow
13300 (handle_search_memory_1): Adjust.
13301 (process_serial_event) <'m' packet>: Handle partial transfers.
13302 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
13304 2011-01-28 Pedro Alves <pedro@codesourcery.com>
13306 * regcache.c (init_register_cache): Initialize
13307 regcache->register_status.
13308 (free_register_cache): Release regcache->register_status.
13309 (regcache_cpy): Copy register_status.
13310 (registers_to_string): Print 'x's for unavailable registers.
13311 (supply_register): Mark the register's status valid or
13312 unavailable, depending on whether a buffer was passed in or not.
13313 (supply_register_zeroed): New.
13314 (supply_regblock): Mark the registers' status valid or
13315 unavailable, depending on whether a buffer was passed in or not.
13316 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
13317 (struct regcache): New `register_status' field.
13318 (supply_register_zeroed): Declare.
13319 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
13320 supply_register_zeroed, rather than passing a NULL buffer to
13322 * tracepoint.c (fetch_traceframe_registers): Update comment.
13324 2011-01-28 Pedro Alves <pedro@codesourcery.com>
13326 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
13329 2011-01-25 Pedro Alves <pedro@codesourcery.com>
13331 * server.h (decode_xfer_write): Change prototype.
13332 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
13333 and don't extract the annex here.
13334 * server.c (decode_xfer_read): Remove `annex' parameter,
13335 and don't extract the annex here.
13336 (decode_xfer): New.
13337 (struct qxfer): New.
13338 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
13339 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
13340 (handle_qxfer_statictrace): New functions, abstracted out from
13341 handle_query, and made to use the struct qxfer interface.
13342 (handle_threads_qxfer_proper): Rename to ...
13343 (handle_qxfer_threads_proper): ... this.
13344 (handle_threads_qxfer): Rename to ...
13345 (handle_qxfer_threads): ... this. Adjust.
13346 (qxfer_packets): New array.
13347 (handle_qxfer): New function.
13348 (handle_query): Use handle_qxfer.
13350 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
13352 * gdbreplay.c: Shorten lines of >= 80 columns.
13353 * linux-low.c: Ditto.
13354 * linux-ppc-low.c: Ditto.
13355 * linux-s390-low.c: Ditto.
13356 * linux-sparc-low.c: Ditto.
13357 * linux-x86-low.c: Ditto.
13358 * linux-xtensa-low.c: Ditto.
13359 * mem-break.c: Ditto.
13360 * nto-low.c: Ditto.
13361 * regcache.h: Ditto.
13362 * remote-utils.c: Ditto.
13365 * thread-db.c: Ditto.
13366 * tracepoint.c: Ditto.
13368 * win32-low.h: Ditto.
13370 2011-01-05 Joel Brobecker <brobecker@adacore.com>
13372 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
13375 2011-01-01 Joel Brobecker <brobecker@adacore.com>
13377 * server.c (gdbserver_version): Update copyright year in version
13379 * gdbreplay.c (gdbreplay_version): Ditto.
13381 2010-12-29 Jie Zhang <jie.zhang@analog.com>
13383 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
13384 * linux-bfin-low.c: New file.
13385 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
13386 PT_DATA_ADDR for BFIN targets.
13387 * Makefile.in (SFILES): Add linux-bfin-low.c.
13388 (clean): Remove reg-bfin.c.
13389 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
13390 * README: Mention supported Blackfin targets.
13392 2010-12-23 Mike Frysinger <vapier@gentoo.org>
13394 * .gitignore: New file.
13396 2010-11-16 Mike Frysinger <vapier@gentoo.org>
13398 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
13400 2010-10-22 Jie Zhang <jie@codesourcery.com>
13402 * Makefile.in: Add FLAGS_TO_PASS variable.
13403 (install): Remove dependency of install-only and recursively
13404 invoke make for install-only.
13406 2010-10-04 Doug Evans <dje@google.com>
13408 * Makefile.in (uninstall): Use $(DESTDIR).
13410 2010-09-24 Pedro Alves <pedro@codesourcery.com>
13414 * linux-x86-low.c (compat_siginfo_from_siginfo)
13415 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
13416 si_code is < 0. Check for si_code == SI_TIMER before checking for
13419 2010-09-13 Joel Brobecker <brobecker@adacore.com>
13421 * lynx-i386-low.c: New file.
13422 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
13424 2010-09-13 Joel Brobecker <brobecker@adacore.com>
13426 * lynx-low.c (ptrace_request_to_str): Remove handling for
13427 request values that have been removed in LynxOS 5.x.
13429 2010-09-13 Joel Brobecker <brobecker@adacore.com>
13431 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
13434 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
13436 * configure.ac: Add --enable-inprocess-agent option.
13437 * configure: Rebuilt.
13439 2010-09-06 Yao Qi <yao@codesourcery.com>
13441 * linux-low.c (linux_kill): Remove unused variable.
13442 (linux_stabilize_threads): Likewise.
13443 * server.c (start_inferior): Likewise.
13444 (queue_stop_reply_callback): Likewise.
13445 * tracepoint.c (do_action_at_tracepoint): Likewise.
13447 2010-09-06 Yao Qi <yao@codesourcery.com>
13449 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
13452 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
13454 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
13456 2010-09-06 Pedro Alves <pedro@codesourcery.com>
13458 * Makefile.in (install-only): Replace $IPA_DEPFILES with
13461 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13463 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
13464 gdbserver/lynx-ppc-low.c: New files.
13465 * Makefile.in (lynx_low_h): New variable.
13466 (lynx-low.o, lynx-ppc-low.o): New rules.
13467 * configure.ac: On LynxOS, link with -lnetinet.
13468 * configure.srv: Add handling of powerpc-*-lynxos* targets.
13469 * configure: regenerate.
13471 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13473 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
13474 * configure.ac: Add check for vasprintf and vsnprintf.
13475 * configure, config.in: Regenerate.
13476 * server.h (vasprintf, vsnprintf): Add conditional declarations.
13478 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13480 * gdbreplay.c: Move include of alloca.h up, next to include of
13482 * server.h: Add include of malloc.h.
13483 * mem-break.c: Remove include of malloc.h.
13484 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
13486 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13488 * Makefile.in (memmem.o): Build with -Wno-error.
13490 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13492 * utils.c (xsnprintf): Make non-static.
13493 * server.h: Add xsnprintf declaration.
13494 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
13495 replace calls to snprintf by calls to xsnprintf throughout.
13497 2010-09-01 Joel Brobecker <brobecker@adacore.com>
13499 * configure.ac: Add configure check for alloca.
13500 * configure, config.in: Regenerate.
13501 * server.h: Include alloca.h if it exists.
13502 * gdbreplay.c: Include alloca.h if it exists.
13504 2010-08-28 Pedro Alves <pedro@codesourcery.com>
13506 * linux-low.c (__SIGRTMIN): Define if not already defined.
13507 (linux_create_inferior): Check for __ANDROID__ rather than
13509 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
13510 are already deferred.
13511 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
13512 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
13513 stopped and already has a pending signal to report.
13514 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
13515 a pending signal to report or is moving out of a jump pad.
13516 (linux_init_signals): Check for __ANDROID__ rather than
13519 2010-08-28 Pedro Alves <pedro@codesourcery.com>
13521 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
13522 debug_threads check. Avoid a linear search when not doing debug
13525 2010-08-27 Pedro Alves <pedro@codesourcery.com>
13527 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
13528 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
13529 (struct file_handler) <fd>: Change type to gdb_fildes_t.
13530 (process_event): Change local fd's type to gdb_fildes_t.
13531 (create_file_handler): Adjust prototype.
13532 (delete_file_handler): Adjust prototype.
13533 (handle_file_event): Adjust prototype. Use pfildes.
13534 (create_file_event): Adjsut prototype.
13535 * remote-utils.c (remote_desc, listen_desc): Change type to
13537 * server.h: New gdb_fildes_t typedef.
13538 [USE_WIN32API]: Include winsock2.h.
13539 (delete_file_handler, add_file_handler): Adjust prototypes.
13540 (pfildes): Declare.
13541 * utils.c (pfildes): New.
13543 2010-08-27 Pedro Alves <pedro@codesourcery.com>
13545 * configure.ac (build_warnings): Add -Wno-char-subscripts.
13546 * configure: Regenerate.
13548 2010-08-27 Pedro Alves <pedro@codesourcery.com>
13550 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
13551 (linux_done_accessing_memory): ... this.
13552 (linux_target_ops): Adjust.
13553 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
13554 * nto-low.c (nto_target_ops): Adjust comment.
13555 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
13556 * spu-low.c (spu_target_ops): Adjust comment.
13557 * target.h (target_ops): Rename unprepare_to_access_memory field
13558 to done_accessing_memory.
13559 (unprepare_to_access_memory): Rename to ...
13560 (done_accessing_memory): ... this.
13562 2010-08-26 Pedro Alves <pedro@codesourcery.com>
13564 * linux-low.c (linux_prepare_to_access_memory): New.
13565 (linux_unprepare_to_access_memory): New.
13566 (linux_target_ops): Install them.
13567 * server.c (read_memory): Rename to ...
13568 (gdb_read_memory): ... this. Use
13569 prepare_to_access_memory/prepare_to_access_memory.
13570 (write_memory): Rename to ...
13571 (gdb_write_memory): ... this. Use
13572 prepare_to_access_memory/prepare_to_access_memory.
13573 (handle_search_memory_1): Adjust.
13574 (process_serial_event): Adjust.
13575 * target.h (struct target_ops): New fields
13576 prepare_to_access_memory and unprepare_to_access_memory.
13577 (prepare_to_access_memory, unprepare_to_access_memory): New.
13578 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
13579 prepare_to_access_memory/prepare_to_access_memory.
13580 * nto-low.c (nto_target_ops): Adjust.
13581 * spu-low.c (spu_target_ops): Adjust.
13582 * win32-low.c (win32_target_ops): Adjust.
13584 2010-08-26 Pedro Alves <pedro@codesourcery.com>
13586 * Makefile.in (WARN_CFLAGS): Get it from configure.
13587 (WERROR_CFLAGS): New.
13588 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
13589 * configure.ac: Introduce --enable-werror, which adds -Werror to
13590 the compiler command line. Enabled by default. Disable with
13591 --disable-werror. Add -Wdeclaration-after-statement
13592 Wpointer-arith and -Wformat-nonliteral to warning flags.
13593 * configure: Regenerate.
13595 2010-08-26 Pedro Alves <pedro@codesourcery.com>
13597 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
13599 2010-08-26 Pedro Alves <pedro@codesourcery.com>
13601 * gdbreplay.c (remote_error): New.
13603 (expect): Use gdbchar. Check for error reading from GDB.
13604 Clarify sync error output.
13605 (play): Check for errors writing to GDB.
13606 * linux-low.c (sigchld_handler): Really ignore `write' errors.
13607 * remote-utils.c (getpkt): Check for errors writing to the remote
13610 2010-08-25 Pedro Alves <pedro@codesourcery.com>
13612 * linux-low.c (linux_wait_1): Move non-debugging code out of
13613 `debug_threads' control.
13615 2010-08-25 Pedro Alves <pedro@codesourcery.com>
13617 * linux-low.c (linux_wait_1): Don't set last_status here.
13618 * server.c (push_event, queue_stop_reply_callback): Assert we're
13619 not pushing a TARGET_WAITKIND_IGNORE event.
13620 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
13621 (myresume, handle_target_event): Set the thread's last_resume_kind
13622 and last_status from the target returned status.
13624 2010-08-25 Pedro Alves <pedro@codesourcery.com>
13628 * linux-x86-low.c (update_debug_registers_callback): New.
13629 (i386_dr_low_set_addr): Use it.
13630 (i386_dr_low_get_addr): New.
13631 (i386_dr_low_set_control): Use update_debug_registers_callback.
13632 (i386_dr_low_get_control): New.
13633 (i386_dr_low_get_status): Adjust.
13634 * linux-low.c (linux_stop_lwp): New.
13635 * linux-low.h (linux_stop_lwp): Declare.
13637 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
13638 argument instead of a i386_debug_reg_state.
13639 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
13640 a i386_debug_reg_state.
13641 (i386_insert_aligned_watchpoint): Adjust.
13642 (i386_remove_aligned_watchpoint): Adjust.
13643 (i386_low_stopped_data_address): Read the debug registers from the
13644 inferior instead of from the mirrors.
13645 * i386-low.h (struct i386_debug_reg_state): Extend comment.
13646 (i386_dr_low_get_addr): Declare.
13647 (i386_dr_low_get_control): Declare.
13648 (i386_dr_low_get_status): Change prototype.
13650 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
13651 (i386_dr_low_get_addr): New.
13652 (i386_dr_low_get_control): New.
13653 (i386_dr_low_get_status): Adjust prototype. Return
13655 (i386_initial_stuff): Clear dr_status_mirror and
13657 (i386_get_thread_context): Adjust.
13658 (i386_set_thread_context): Adjust.
13659 (i386_thread_added): Adjust.
13661 2010-08-24 Pedro Alves <pedro@codesourcery.com>
13663 * linux-low.h (linux_thread_area): Delete declaration.
13665 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
13667 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
13668 after its termination.
13670 2010-08-09 Pedro Alves <pedro@codesourcery.com>
13672 * linux-low.c (gdb_wants_lwp_stopped): Delete.
13673 (gdb_wants_all_stopped): Delete.
13674 (linux_wait_1): Don't call them.
13675 * server.c (handle_v_cont): Tag all threads as want-stopped.
13676 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
13677 stopped as "client-wants-stopped".
13679 2010-07-31 Pedro Alves <pedro@codesourcery.com>
13681 * Makefile.in (signals_h): New.
13682 (server_h): Depend on it.
13683 (server.o): Don't depend on $(signals_def).
13684 (signals.o): Depend on $(signals_def).
13686 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
13688 * Makefile.in (signals_def): New.
13689 (server_h): Append include/gdb/signals.h and signals_def.
13690 (server.o): Append signals_def.
13692 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
13694 * server.c (handle_target_event): Use target_signal_to_host for
13695 resume_info.sig initialization.
13696 * target.h (struct thread_resume) <sig>: New comment.
13698 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
13700 * server.c (handle_query): strcpy() the returned string from paddress()
13701 instead of sprintf().
13702 * utils.c (paddress): Return phex_nz().
13704 2010-07-07 Joel Brobecker <brobecker@adacore.com>
13706 * server.c (handle_v_cont): Call mourn_inferior if process
13708 (myresume): Likewise.
13710 2010-07-01 Pedro Alves <pedro@codesourcery.com>
13712 Static tracepoints, and integration with UST.
13714 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
13715 * mem-break.c (uninsert_all_breakpoints)
13716 (reinsert_all_breakpoints): New.
13717 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
13718 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
13719 (gdb_agent_ust_loaded, helper_thread_id)
13720 (gdb_agent_helper_thread_id): New macros.
13721 (struct ipa_sym_addresses): Add addr_ust_loaded,
13722 addr_helper_thread_id, addr_cmd_buf.
13723 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
13724 (in_process_agent_loaded_ust): New.
13725 (write_e_ust_not_loaded): New.
13726 (maybe_write_ipa_ust_not_loaded): New.
13727 (struct collect_static_trace_data_action): New.
13728 (enum tracepoint_type) <static_tracepoint>: New.
13729 (struct tracepoint) <handle>: Mention static tracepoints.
13730 (struct static_tracepoint_ctx): New.
13731 (CMD_BUF_SIZE): New.
13732 (add_tracepoint_action): Handle static tracepoint actions.
13733 (unprobe_marker_at): New.
13734 (clear_installed_tracepoints): Handle static tracepoints.
13735 (cmd_qtdp): Handle static tracepoints.
13736 (probe_marker_at): New.
13737 (cmd_qtstart): Handle static tracepoints.
13738 (response_tracepoint): Handle static tracepoints.
13739 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
13740 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
13741 (get_context_regcache): Handle static tracepoints.
13742 (do_action_at_tracepoint): Handle static tracepoint actions.
13743 (traceframe_find_block_type): Handle static trace data blocks.
13744 (traceframe_read_sdata): New.
13745 (download_tracepoints): Download static tracepoint actions.
13746 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
13747 (GDB_PROBE_NAME): New.
13749 (GET_UST_SYM): New.
13752 (ust_marker_to_static_tracepoint): New.
13754 (collect_ust_data_at_tracepoint): New.
13755 (gdb_ust_probe): New.
13756 (UNIX_PATH_MAX, SOCK_DIR): New.
13757 (gdb_ust_connect_sync_socket): New.
13758 (resume_thread, stop_thread): New.
13759 (run_inferior_command): New.
13760 (init_named_socket): New.
13761 (gdb_ust_socket_init): New.
13762 (cstr_to_hexstr): New.
13764 (first_marker, next_marker): New.
13765 (response_ust_marker): New.
13766 (cmd_qtfstm, cmd_qtsstm): New.
13767 (unprobe_marker_at, probe_marker_at): New.
13768 (cmd_qtstmat, gdb_ust_thread): New.
13769 (gdb_ust_init): New.
13770 (initialize_tracepoint_ftlib): Call gdb_ust_init.
13771 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
13772 (ST_REGENTRY): New.
13773 (x86_64_st_collect_regmap): New.
13774 (X86_64_NUM_ST_COLLECT_GREGS): New.
13775 (AMD64_RIP_REGNUM): New.
13776 (supply_static_tracepoint_registers): New.
13777 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
13778 (ST_REGENTRY): New.
13779 (i386_st_collect_regmap): New.
13780 (i386_NUM_ST_COLLECT_GREGS): New.
13781 (supply_static_tracepoint_registers): New.
13782 * server.c (handle_query): Handle qXfer:statictrace:read.
13783 <qSupported>: Report support for StaticTracepoints, and
13784 qXfer:statictrace:read features.
13785 * server.h (traceframe_read_sdata)
13786 (supply_static_tracepoint_registers): Declare.
13787 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
13788 (unpack_varlen_hex): Include in IPA build.
13789 * Makefile.in (ustlibs, ustinc): New.
13790 (IPA_OBJS): Add remote-utils-ipa.o.
13791 ($(IPA_LIB)): Link -ldl and -lpthread.
13793 (IPAGENT_CFLAGS): Add UST_CFLAGS.
13794 * config.in, configure: Regenerate.
13796 2010-06-20 Ian Lance Taylor <iant@google.com>
13797 Pedro Alves <pedro@codesourcery.com>
13799 * linux-x86-low.c (always_true): Delete.
13800 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
13801 trying to fool the compiler with always_true.
13803 2010-06-20 Pedro Alves <pedro@codesourcery.com>
13805 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
13806 conditions in gdbserver.
13808 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
13810 * spu-low.c (spu_read_memory): Wrap around local store limit.
13811 (spu_write_memory): Likewise.
13813 2010-06-15 Pedro Alves <pedro@codesourcery.com>
13815 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
13816 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
13818 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
13820 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
13821 uses with LONGEST uses.
13823 2010-06-14 Stan Shebs <stan@codesourcery.com>
13824 Pedro Alves <pedro@codesourcery.com>
13828 * linux-x86-low.c: Include limits.h.
13830 (always_true): New.
13833 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
13834 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
13835 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
13836 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
13837 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
13838 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
13839 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
13840 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
13841 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
13842 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
13843 (amd64_emit_void_call_2): New.
13844 (amd64_emit_ops): New.
13845 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
13846 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
13847 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
13848 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
13849 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
13850 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
13851 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
13852 (i386_emit_call, i386_emit_reg, i386_emit_pop)
13853 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
13854 (i386_emit_stack_adjust, i386_emit_int_call_1)
13855 (i386_emit_void_call_2): New.
13856 (i386_emit_ops): New.
13857 (x86_emit_ops): New.
13858 (the_low_target): Install x86_emit_ops.
13859 * server.h (struct emit_ops): New.
13860 (get_raw_reg_func_addr): Declare.
13861 (current_insn_ptr, emit_error): Declare.
13862 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
13863 (set_trace_state_variable_value): New defines.
13864 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
13865 addr_get_trace_state_variable_value and
13866 addr_set_trace_state_variable_value.
13867 (symbol_list): New fields for get_raw_reg,
13868 get_trace_state_variable_value and set_trace_state_variable_value.
13869 (condfn): New typedef.
13870 (struct tracepoint): New field `compiled_cond'.
13871 (do_action_at_tracepoint): Clear compiled_cond.
13872 (get_trace_state_variable_value, set_trace_state_variable_value):
13874 (condition_true_at_tracepoint): If there's a compiled condition,
13876 (current_insn_ptr, emit_error): New globals.
13877 (struct bytecode_address): New.
13878 (get_raw_reg_func_addr): New.
13879 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
13880 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
13881 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
13882 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
13883 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
13884 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
13885 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
13886 (compile_tracepoint_condition, compile_bytecodes): New.
13887 * target.h (emit_ops): Forward declare.
13888 (struct target_ops): New field emit_ops.
13889 (target_emit_ops): New.
13890 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
13891 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
13892 * linux-low.c (linux_emit_ops): New.
13893 (linux_target_ops): Install it.
13894 * linux-low.h (struct linux_target_ops): New field emit_ops.
13896 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
13898 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
13899 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
13901 2010-06-01 Pedro Alves <pedro@codesourcery.com>
13902 Stan Shebs <stan@codesourcery.com>
13904 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
13905 (all): Depend on $(extra_libraries).
13906 (install-only): Install the IPA.
13907 (IPA_OBJS, IPA_LIB): New.
13908 (clean): Remove the IPA lib.
13909 (IPAGENT_CFLAGS): New.
13910 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
13911 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
13912 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
13913 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
13914 * configure.ac: Check for atomic builtins support in the compiler.
13915 (IPA_DEPFILES, extra_libraries): Define.
13916 * configure.srv (ipa_obj): Add description.
13917 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
13918 (i[34567]86-*-linux*): Set ipa_obj.
13919 (x86_64-*-linux*): Set ipa_obj.
13920 * linux-low.c (stabilizing_threads): New.
13921 (supports_fast_tracepoints): New.
13922 (linux_detach): Stabilize threads before detaching.
13923 (handle_tracepoints): Handle internal tracing breakpoints. Assert
13924 the lwp is either not stabilizing, or is moving out of a jump pad.
13925 (linux_fast_tracepoint_collecting): New.
13926 (maybe_move_out_of_jump_pad): New.
13927 (enqueue_one_deferred_signal): New.
13928 (dequeue_one_deferred_signal): New.
13929 (linux_wait_for_event_1): If moving out of a jump pad, defer
13930 pending signals to later.
13931 (linux_stabilize_threads): New.
13932 (linux_wait_1): Check if threads need moving out of jump pads, and
13934 (stuck_in_jump_pad_callback): New.
13935 (move_out_of_jump_pad_callback): New.
13936 (lwp_running): New.
13937 (linux_resume_one_lwp): Handle moving out of jump pads.
13938 (linux_set_resume_request): Dequeue deferred signals.
13939 (need_step_over_p): Also step over fast tracepoint jumps.
13940 (start_step_over): Also uninsert fast tracepoint jumps.
13941 (finish_step_over): Also reinsert fast tracepoint jumps.
13942 (linux_install_fast_tracepoint_jump): New.
13943 (linux_target_ops): Install linux_stabilize_threads and
13944 linux_install_fast_tracepoint_jump_pad.
13945 * linux-low.h (linux_target_ops) <get_thread_area,
13946 install_fast_tracepoint_jump_pad>: New fields.
13947 (struct lwp_info) <collecting_fast_tracepoint,
13948 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
13949 (linux_get_thread_area): Declare.
13950 * linux-x86-low.c (jump_insn): New.
13951 (x86_get_thread_area): New.
13952 (append_insns): New.
13953 (push_opcode): New.
13954 (amd64_install_fast_tracepoint_jump_pad): New.
13955 (i386_install_fast_tracepoint_jump_pad): New.
13956 (x86_install_fast_tracepoint_jump_pad): New.
13957 (the_low_target): Install x86_get_thread_area and
13958 x86_install_fast_tracepoint_jump_pad.
13959 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
13960 (struct fast_tracepoint_jump): New.
13961 (fast_tracepoint_jump_insn): New.
13962 (fast_tracepoint_jump_shadow): New.
13963 (find_fast_tracepoint_jump_at): New.
13964 (fast_tracepoint_jump_here): New.
13965 (delete_fast_tracepoint_jump): New.
13966 (set_fast_tracepoint_jump): New.
13967 (uninsert_fast_tracepoint_jumps_at): New.
13968 (reinsert_fast_tracepoint_jumps_at): New.
13969 (set_breakpoint_at): Use write_inferior_memory.
13970 (uninsert_raw_breakpoint): Use write_inferior_memory.
13971 (check_mem_read): Mask out fast tracepoint jumps.
13972 (check_mem_write): Mask out fast tracepoint jumps.
13973 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
13974 (set_fast_tracepoint_jump): Declare.
13975 (delete_fast_tracepoint_jump)
13976 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
13977 (reinsert_fast_tracepoint_jumps_at): Declare.
13978 * regcache.c: Don't compile many functions when building the
13979 in-process agent library.
13980 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
13981 the register buffer in the heap.
13982 (free_register_cache): If the register buffer isn't owned by the
13983 regcache, don't free it.
13984 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
13985 pre-existing register caches.
13986 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
13988 (convert_ascii_to_int): : Constify `from' parameter type.
13989 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
13990 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
13991 the needed buffer in-place.
13992 (relocate_instruction): New.
13993 * server.c (handle_query) <qSymbols>: If the target supports
13994 tracepoints, give it a chance of looking up symbols. Report
13995 support for fast tracepoints.
13996 (handle_status): Stabilize threads.
13997 (process_serial_event): Adjust.
13998 * server.h (struct fast_tracepoint_jump): Forward declare.
13999 (struct process_info) <fast_tracepoint_jumps>: New field.
14000 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
14001 (decode_X_packet, decode_M_packet): Adjust.
14002 (relocate_instruction): Declare.
14003 (in_process_agent_loaded): Declare.
14004 (tracepoint_look_up_symbols): Declare.
14005 (struct fast_tpoint_collect_status): Declare.
14006 (fast_tracepoint_collecting): Declare.
14007 (force_unlock_trace_buffer): Declare.
14008 (handle_tracepoint_bkpts): Declare.
14009 (initialize_low_tracepoint)
14010 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
14011 * target.h (struct target_ops) <stabilize_threads,
14012 install_fast_tracepoint_jump_pad>: New fields.
14013 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
14014 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
14015 [HAVE_STDINT_H]: Include stdint.h.
14016 (trace_debug_1): Rename to ...
14017 (trace_vdebug): ... this.
14018 (trace_debug): Rename to ...
14019 (trace_debug_1): ... this. Add `level' parameter.
14020 (trace_debug): New.
14021 (ATTR_USED, ATTR_NOINLINE): New.
14022 (IP_AGENT_EXPORT): New.
14023 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
14024 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
14025 (about_to_request_buffer_space, trace_buffer_is_full)
14026 (stopping_tracepoint, expr_eval_result, error_tracepoint)
14027 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
14028 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
14029 (traceframe_write_count, traceframes_created)
14030 (trace_state_variables)
14031 New renaming defines.
14032 (struct ipa_sym_addresses): New.
14033 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
14034 (symbol_list): New.
14035 (ipa_sym_addrs): New.
14036 (all_tracepoint_symbols_looked_up): New.
14037 (in_process_agent_loaded): New.
14038 (write_e_ipa_not_loaded): New.
14039 (maybe_write_ipa_not_loaded): New.
14040 (tracepoint_look_up_symbols): New.
14041 (debug_threads) [IN_PROCESS_AGENT]: New.
14042 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
14043 (UNKNOWN_SIDE_EFFECTS): New.
14044 (stop_tracing): New.
14045 (flush_trace_buffer): New.
14046 (stop_tracing_bkpt): New.
14047 (flush_trace_buffer_bkpt): New.
14048 (read_inferior_integer): New.
14049 (read_inferior_uinteger): New.
14050 (read_inferior_data_pointer): New.
14051 (write_inferior_data_pointer): New.
14052 (write_inferior_integer): New.
14053 (write_inferior_uinteger): New.
14054 (struct collect_static_trace_data_action): Delete.
14055 (enum tracepoint_type): New.
14056 (struct tracepoint) <type>: New field `type'.
14057 <actions_str, step_actions, step_actions_str>: Only include in
14059 <orig_size, obj_addr_on_target, adjusted_insn_addr>
14060 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
14061 (tracepoints): Use IP_AGENT_EXPORT.
14062 (last_tracepoint): Don't include in the IPA.
14063 (stopping_tracepoint): Use IP_AGENT_EXPORT.
14064 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
14065 (alloced_trace_state_variables): New.
14066 (trace_state_variables): Use IP_AGENT_EXPORT.
14067 (traceframe_t): Delete unused variable.
14068 (circular_trace_buffer): Don't include in the IPA.
14069 (trace_buffer_start): Delete.
14070 (struct trace_buffer_control): New.
14071 (trace_buffer_free): Delete.
14072 (struct ipa_trace_buffer_control): New.
14073 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
14074 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
14076 (trace_buffer_ctrl): New.
14077 (TRACE_BUFFER_CTRL_CURR): New.
14078 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
14079 Reimplement as macros.
14080 (trace_buffer_wrap): Delete.
14081 (traceframe_write_count, traceframe_read_count)
14082 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
14083 (struct tracepoint_hit_ctx) <type>: New field.
14084 (struct fast_tracepoint_ctx): New.
14085 (memory_barrier): New.
14087 (record_tracepoint_error): Update atomically in the IPA.
14088 (clear_inferior_trace_buffer): New.
14089 (about_to_request_buffer_space): New.
14090 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
14091 updating the same buffer.
14092 (add_tracepoint): Default the tracepoint's type to trap
14093 tracepoint, and orig_size to -1.
14094 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
14095 internal variables.
14096 (create_trace_state_variable): New parameter `gdb'. Handle it.
14097 (clear_installed_tracepoints): Clear fast tracepoint jumps.
14098 (cmd_qtdp): Handle fast tracepoints.
14099 (cmd_qtdv): Adjust.
14100 (max_jump_pad_size): New.
14101 (gdb_jump_pad_head): New.
14102 (get_jump_space_head): New.
14103 (claim_jump_space): New.
14104 (sort_tracepoints): New.
14105 (MAX_JUMP_SIZE): New.
14106 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
14108 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
14109 support. Upload fast traceframes, and delete internal IPA
14111 (stop_tracing_handler): New.
14112 (flush_trace_buffer_handler): New.
14113 (cmd_qtstop): Upload fast tracepoints.
14114 (response_tracepoint): Handle fast tracepoints.
14115 (tracepoint_finished_step): Upload fast traceframes. Set the
14116 tracepoint hit context's tracepoint type.
14117 (handle_tracepoint_bkpts): New.
14118 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
14119 type. Add comment about fast tracepoints.
14120 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
14121 non-existing action_str field.
14122 (get_context_regcache): Handle fast tracepoints.
14123 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
14125 (fast_tracepoint_from_jump_pad_address): New.
14126 (fast_tracepoint_from_ipa_tpoint_address): New.
14127 (collecting_t): New.
14128 (force_unlock_trace_buffer): New.
14129 (fast_tracepoint_collecting): New.
14131 (gdb_collect): New.
14132 (write_inferior_data_ptr): New.
14133 (target_tp_heap): New.
14134 (target_malloc): New.
14135 (download_agent_expr): New.
14137 (download_tracepoints): New.
14138 (download_trace_state_variables): New.
14139 (upload_fast_traceframes): New.
14140 (IPA_FIRST_TRACEFRAME): New.
14141 (IPA_NEXT_TRACEFRAME_1): New.
14142 (IPA_NEXT_TRACEFRAME): New.
14143 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
14144 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
14145 (gdb_jump_pad_buffer_end): New.
14146 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
14147 (initialize_tracepoint): Adjust.
14148 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
14149 buffer. Initialize the low module.
14150 * utils.c (PREFIX, TOOLNAME): New.
14151 (malloc_failure): Use PREFIX.
14152 (error): In the IPA, an error causes an exit.
14153 (fatal, warning): Use PREFIX.
14154 (internal_error): Use TOOLNAME.
14155 (NUMCELLS): Increase to 10.
14156 * configure, config.in: Regenerate.
14158 2010-06-01 Pedro Alves <pedro@codesourcery.com>
14160 * server.c (handle_query) <qSupported>: Do two passes over the
14161 qSupported string to avoid nesting strtok.
14163 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
14165 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
14167 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
14168 -Wl,--dynamic-list.
14169 * configure: Regenerate.
14170 * proc-service.list: New.
14172 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
14174 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
14177 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
14179 * gdbreplay.c (remote_open): Check error return from socket() call by
14180 its equality to -1 not by it being negative.
14181 * remote-utils.c (remote_open): Likewise.
14183 2010-05-23 Pedro Alves <pedro@codesourcery.com>
14185 * config.h: Regenerate.
14187 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
14189 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
14190 doesn't provide PTRACE_GET_THREAD_AREA.
14192 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
14194 * linux-m68k-low.c: Include <asm/ptrace.h>
14195 (ps_get_thread_area): Implement.
14197 2010-05-03 Doug Evans <dje@google.com>
14199 * event-loop.c (struct callback_event): New struct.
14200 (callback_list): New global.
14201 (append_callback_event, delete_callback_event): New functions.
14202 (process_callback): New function.
14203 (start_event_loop): Call it.
14204 * remote-utils.c (NOT_SCHEDULED): Define.
14205 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
14206 moved out of readchar.
14207 (readchar): Rewrite. Call reschedule before returning.
14208 (reset_readchar): New function.
14209 (remote_close): Call it.
14210 (process_remaining, reschedule): New functions.
14211 * server.h (callback_handler_func): New typedef.
14212 (append_callback_event, delete_callback_event): Declare.
14214 2010-05-03 Pedro Alves <pedro@codesourcery.com>
14216 * proc-service.c (ps_pglobal_lookup): Use
14217 thread_db_look_up_one_symbol.
14218 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
14219 parameter. Use it instead of all_symbols_looked_up.
14220 * server.h (struct process_info) <all_symbols_looked_up>: Delete
14222 (all_symbols_looked_up): Don't declare.
14223 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
14224 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
14226 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
14227 Set all_symbols_looked_up here.
14228 (thread_db_look_up_one_symbol): New.
14229 (thread_db_get_tls_address): Adjust.
14230 (thread_db_load_search, try_thread_db_load_1): Always allocate the
14231 thread_db object on the heap, and tentatively set it in the
14233 (thread_db_init): Don't set all_symbols_looked_up here.
14234 * linux-low.h (thread_db_look_up_one_symbol): Declare.
14236 2010-05-03 Pedro Alves <pedro@codesourcery.com>
14238 * linux-low.c (linux_kill, linux_detach): Adjust.
14239 (status_pending_p_callback): Remove redundant statement. Check
14240 for !TARGET_WAITIKIND_IGNORE, instead of
14241 TARGET_WAITKIND_STOPPED.
14242 (handle_tracepoints): Make sure LWP is locked. Adjust.
14243 (linux_wait_for_event_1): Adjust.
14244 (linux_cancel_breakpoints): New.
14245 (unsuspend_one_lwp): New.
14246 (unsuspend_all_lwps): New.
14247 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
14248 (send_sigstop_callback): Change return type to int, add new
14249 `except' parameter and handle it.
14250 (suspend_and_send_sigstop_callback): New.
14251 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
14252 pass them down. If SUSPEND, also increment the lwp's suspend
14254 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
14255 (need_step_over_p): Don't consider suspended LWPs.
14256 (start_step_over): Adjust.
14257 (proceed_one_lwp): Change return type to int, add new `except'
14258 parameter and handle it.
14259 (unsuspend_and_proceed_one_lwp): New.
14260 (proceed_all_lwps): Use find_inferior instead of
14262 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
14263 also decrement the suspend count of LWPs. Pass `except' down,
14264 instead of hacking its suspend count.
14265 (linux_pause_all): Add `freeze' parameter. Adjust.
14266 (linux_unpause_all): New.
14267 (linux_target_ops): Install linux_unpause_all.
14268 * server.c (handle_status): Adjust.
14269 * target.h (struct target_ops): New fields `unpause_all' and
14270 `cancel_breakpoints'. Add new parameter to `pause_all'.
14271 (pause_all): Add new `freeze' parameter.
14272 (unpause_all): New.
14273 (cancel_breakpoints): New.
14274 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
14275 cancel breakpoints.
14276 (cmd_qtstart): Pause threads.
14277 (stop_tracing): Pause threads, and cancel breakpoints.
14278 * win32-low.c (win32_target_ops): Adjust.
14280 2010-05-03 Pedro Alves <pedro@codesourcery.com>
14282 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
14283 the inferior right away from here...
14284 (linux_wait_1): ... to here, and adjust to check the thread's
14285 last_resume_kind instead of the lwp's step or stop_expected flags.
14287 2010-05-02 Pedro Alves <pedro@codesourcery.com>
14289 * README: Use consistent `GDB' and `GDBserver' spellings.
14291 2010-05-02 Pedro Alves <pedro@codesourcery.com>
14293 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
14294 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
14295 (linux_detach_one_lwp): Assume the lwp is stopped.
14296 (any_thread_of): Delete.
14297 (linux_detach): Stop all lwps here. Don't blindly delete all
14299 (delete_lwp_callback): New.
14300 (linux_mourn): Delete all lwps of the process that is gone.
14301 (linux_wait_1): Don't delete the last lwp of the process here.
14302 * mem-break.h (mark_breakpoints_out): Declare.
14303 * mem-break.c (mark_breakpoints_out): New.
14304 (free_all_breakpoints): Use it.
14305 * server.c (handle_target_event): If the process is gone, mark
14307 * thread-db.c (struct thread_db) <create_bp>: New field.
14308 (thread_db_enable_reporting): Fix prototype. Store a thread event
14309 breakpoint reference in the thread_db struct.
14310 (thread_db_load_search): Clear the thread_db object.
14311 (try_thread_db_load_1): Ditto.
14312 (switch_to_process): New.
14313 (disable_thread_event_reporting): Use it.
14314 (remove_thread_event_breakpoints): New.
14315 (thread_db_detach, thread_db_mourn): Use it.
14317 2010-05-01 Pedro Alves <pedro@codesourcery.com>
14319 * linux-low.c (linux_enable_event_reporting): New.
14320 (linux_wait_for_event_1, handle_extended_wait): Use it.
14322 2010-04-30 Pedro Alves <pedro@codesourcery.com>
14324 * linux-low.c (linux_kill_one_lwp, linux_kill)
14325 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
14326 (send_sigstop): Take an lwp_info as parameter instead. Queue a
14327 SIGSTOP even if the LWP is stopped.
14328 (send_sigstop_callback): New.
14329 (stop_all_lwps): Use send_sigstop_callback instead.
14330 (linux_resume_one_thread): Adjust.
14331 (proceed_one_lwp): Still proceed an LWP that the client has
14332 requested to stop, if we haven't reported it as stopped yet. Make
14333 sure that LWPs the client want stopped, have a pending SIGSTOP.
14335 2010-04-26 Doug Evans <dje@google.com>
14337 * server.c (handle_general_set): Make static.
14339 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
14340 Print received char after testing for error/eof instead of before.
14341 (input_interrupt): Tweak comment.
14343 2010-04-23 Doug Evans <dje@google.com>
14345 * server.c (start_inferior): Print inferior argv if --debug.
14347 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
14349 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
14350 * nto-x86-low.c: Include server.h
14352 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
14354 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
14355 be consistent with other sources of this directory.
14356 (init_registers_amd64): Correct name of source file of this function
14359 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
14361 * configure.srv (x86_64-*-mingw*): New configuration for Windows
14362 64-bit executables.
14364 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
14366 * win32-i386-low.c: Add 64-bit support.
14367 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
14368 (init_registers_amd64): Declare.
14369 (mappings): Add 64-bit version of array.
14370 (init_windows_x86): New function.
14371 (the_low_target): Change init_arch field to init_windows_x86.
14373 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
14375 * win32-low.c: Adapt to support also 64-bit architecture.
14376 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
14377 (get_image_name): Use SIZE_T type for local variable `done'.
14378 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
14379 (toolhelp_get_dll_name): Idem.
14380 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
14381 Use uintptr_t typecast to avoid warning.
14382 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
14383 (handle_exception): Use phex_nz to avoid warning.
14384 (win32_wait): Remove unused local variable `process'.
14386 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
14388 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
14391 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
14393 * configure.ac: Use `ws2_32' library for srv_mingw.
14394 * configure: Regenerate.
14395 * gdbreplay.c: Include winsock2.h instead of winsock.h.
14396 * remote-utils.c: Likewise.
14398 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
14400 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
14401 if __x86_64__ is defined.
14403 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
14405 * configure: Regenerate.
14407 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
14409 * server.c (handle_query): Handle 'qGetTIBAddr' query.
14410 * target.h (target_ops): New get_tib_address field.
14411 * win32-low.h (win32_thread_info): Add thread_local_base field.
14412 * win32-low.c (child_add_thread): Add tlb argument.
14413 Set thread_local_base field to TLB.
14414 (get_child_debug_event): Adapt to child_add_thread change.
14415 (win32_get_tib_address): New function.
14416 (win32_target_ops): Set get_tib_address field to
14417 win32_get_tib_address.
14418 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
14420 2010-04-12 Pedro Alves <pedro@codesourcery.com>
14422 * linux-low.c (linux_mourn): Also remove the process.
14423 * server.c (handle_target_event): Don't remove the process here.
14424 * nto-low.c (nto_mourn): New.
14425 (nto_target_ops): Install it.
14426 * spu-low.c (spu_mourn): New.
14427 (spu_target_ops): Install it.
14428 * win32-low.c (win32_mourn): New.
14429 (win32_target_ops): Install it.
14431 2010-04-12 Pedro Alves <pedro@codesourcery.com>
14433 * server.h (buffer_xml_printf): Remove redundant `;'.
14435 2010-04-12 Pedro Alves <pedro@codesourcery.com>
14437 * regcache.c (set_register_cache): Invalidate regcaches before
14438 changing the register cache layout.
14439 (regcache_invalidate_one): Allow a NULL regcache.
14440 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
14441 regcaches before changing the register cache layout or the target
14444 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
14446 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
14447 variable warning on Linux/x86-64.
14449 2010-04-11 Pedro Alves <pedro@codesourcery.com>
14451 GDBserver disconnected tracing support.
14453 * linux-low.c (linux_remove_process): Delete.
14454 (add_lwp): Don't set last_resume_kind here.
14455 (linux_kill): Use `mourn'.
14456 (linux_detach): Use `thread_db_detach', and `mourn'.
14457 (linux_mourn): New.
14458 (linux_attach_lwp_1): Adjust comment.
14459 (linux_attach): last_resume_kind moved the thread_info; adjust.
14460 (status_pending_p_callback): Adjust.
14461 (linux_wait_for_event_1): Adjust.
14462 (count_events_callback, select_singlestep_lwp_callback)
14463 (select_event_lwp_callback, cancel_breakpoints_callback)
14464 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
14465 (proceed_one_lwp): Adjust.
14466 (linux_async): Add debug output.
14467 (linux_thread_stopped): New.
14468 (linux_pause_all): New.
14469 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
14471 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
14472 (thread_db_free): Delete declaration.
14473 (thread_db_detach, thread_db_mourn): Declare.
14474 * thread-db.c (thread_db_init): Use thread_db_mourn.
14475 (thread_db_free): Delete, split in two.
14476 (disable_thread_event_reporting): New.
14477 (thread_db_detach): New.
14478 (thread_db_mourn): New.
14480 * server.h (struct thread_info) <last_resume_kind>: New field.
14481 <attached>: Add comment.
14482 <gdb_detached>: New field.
14483 (handler_func): Change return type to int.
14484 (handle_serial_event, handle_target_event): Ditto.
14485 (gdb_connected): Declare.
14487 (disconnected_tracing): Declare.
14488 (stop_tracing): Declare.
14490 * server.c (handle_query) <qSupported>: Report support for
14491 disconnected tracing.
14492 (queue_stop_reply_callback): Account for running threads.
14493 (gdb_wants_thread_stopped): New.
14494 (gdb_wants_all_threads_stopped): New.
14495 (gdb_reattached_process): New.
14496 (handle_status): Clear the `gdb_detached' flag of all processes.
14497 In all-stop, stop all threads.
14498 (main): Be sure to leave tfind mode. Handle disconnected tracing.
14499 (process_serial_event): If the remote connection breaks, or if an
14500 exit was forced with "monitor exit", force an event loop exit.
14501 Handle disconnected tracing on detach.
14502 (handle_serial_event): Adjust.
14503 (handle_target_event): If GDB isn't connected, forward events back
14504 to the inferior, unless the last process exited, in which case,
14505 exit gdbserver. Adjust interface.
14507 * remote-utils.c (remote_open): Don't block in accept. Instead
14508 register an event loop source on the listen socket file
14509 descriptor. Refactor bits into ...
14510 (listen_desc): ... this new global.
14511 (gdb_connected): ... this new function.
14512 (enable_async_notification): ... this new function.
14513 (handle_accept_event): ... this new function.
14514 (remote_close): Clear remote_desc.
14516 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
14518 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
14520 (mourn_inferior): Define.
14521 (target_process_qsupported): Avoid the dangling else problem.
14522 (thread_stopped): Define.
14523 (pause_all): Define.
14524 (target_waitstatus_to_string): Declare.
14525 * target.c (target_waitstatus_to_string): New.
14527 * tracepoint.c (tracing): Make extern.
14528 (disconnected_tracing): New.
14529 (stop_tracing): Make extern. Handle tracing stops due to GDB
14531 (cmd_qtdisconnected): New.
14532 (cmd_qtstatus): Report disconnected tracing status in trace reply.
14533 (handle_tracepoint_general_set): Handle QTDisconnected.
14535 * event-loop.c (event_handler_func): Change return type to int.
14536 (process_event): Bail out if the event handler wants the event
14538 (handle_file_event): Ditto.
14539 (start_event_loop): Bail out if the event handler wants the event
14542 * nto-low.c (nto_target_ops): Adjust.
14543 * spu-low.c (spu_wait): Don't remove the process here.
14544 (spu_target_ops): Adjust.
14545 * win32-low.c (win32_wait): Don't remove the process here.
14546 (win32_target_ops): Adjust.
14548 2010-04-11 Pedro Alves <pedro@codesourcery.com>
14550 * regcache.c (realloc_register_cache): Invalidate inferior's
14551 regcache before recreating it.
14553 2010-04-09 Pedro Alves <pedro@codesourcery.com>
14555 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
14557 2010-04-09 Stan Shebs <stan@codesourcery.com>
14558 Pedro Alves <pedro@codesourcery.com>
14560 * server.h (LONGEST): New.
14561 (struct thread_info) <while_stepping>: New field.
14562 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
14564 (initialize_tracepoint, handle_tracepoint_general_set)
14565 (handle_tracepoint_query, tracepoint_finished_step)
14566 (tracepoint_was_hit, release_while_stepping_state_list):
14567 (current_traceframe): Declare.
14568 * server.c (handle_general_set): Handle tracepoint packets.
14569 (read_memory): New.
14570 (write_memory): New.
14571 (handle_search_memory_1): Use read_memory.
14572 (handle_query): Report support for conditional tracepoints, trace
14573 state variables, and tracepoint sources. Handle tracepoint
14575 (main): Initialize the tracepoints module.
14576 (process_serial_event): Handle traceframe reads/writes.
14578 * linux-low.c (handle_tracepoints): New.
14579 (linux_wait_1): Call it.
14580 (linux_resume_one_lwp): Handle while-stepping.
14581 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
14582 (linux_target_ops): Install them.
14583 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
14585 * linux-x86-low.c (x86_supports_tracepoints): New.
14586 (the_low_target). Install it.
14588 * mem-break.h (delete_breakpoint): Declare.
14589 * mem-break.c (delete_breakpoint): Make external.
14591 * target.h (struct target_ops): Add `supports_tracepoints',
14592 `read_pc', and `write_pc' fields.
14593 (target_supports_tracepoints): Define.
14594 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
14597 * regcache.h (struct regcache) <registers_owned>: New field.
14598 (init_register_cache, regcache_cpy): Declare.
14599 (regcache_read_pc, regcache_write_pc): Declare.
14600 (register_cache_size): Declare.
14601 (supply_regblock): Declare.
14602 * regcache.c (init_register_cache): New.
14603 (new_register_cache): Use it.
14604 (regcache_cpy): New.
14605 (register_cache_size): New.
14606 (supply_regblock): New.
14607 (regcache_read_pc, regcache_write_pc): New.
14609 * tracepoint.c: New.
14611 * Makefile.in (OBS): Add tracepoint.o.
14612 (tracepoint.o): New rule.
14614 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
14616 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
14618 (i386-mmx.c): Likewise.
14619 (i386-mmx-linux.o): Likewise.
14620 (i386-mmx-linux.c): Likewise.
14622 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
14623 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
14624 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
14625 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
14627 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
14628 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
14629 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
14631 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
14633 * Makefile.in (clean): Updated.
14635 (i386-avx.c): Likewise.
14636 (i386-avx-linux.o): Likewise.
14637 (i386-avx-linux.c): Likewise.
14638 (amd64-avx.o): Likewise.
14639 (amd64-avx.c): Likewise.
14640 (amd64-avx-linux.o): Likewise.
14641 (amd64-avx-linux.c): Likewise.
14643 * configure.srv (srv_i386_regobj): Add i386-avx.o.
14644 (srv_i386_linux_regobj): Add i386-avx-linux.o.
14645 (srv_amd64_regobj): Add amd64-avx.o.
14646 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
14647 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
14648 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
14649 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
14650 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
14651 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
14652 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
14654 * i387-fp.c: Include "i386-xstate.h".
14656 (i387_cache_to_xsave): Likewise.
14657 (i387_xsave_to_cache): Likewise.
14658 (x86_xcr0): Likewise.
14660 * i387-fp.h (i387_cache_to_xsave): Likewise.
14661 (i387_xsave_to_cache): Likewise.
14662 (x86_xcr0): Likewise.
14664 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
14665 * linux-crisv32-low.c (target_regsets): Likewise.
14666 * linux-m68k-low.c (target_regsets): Likewise.
14667 * linux-mips-low.c (target_regsets): Likewise.
14668 * linux-ppc-low.c (target_regsets): Likewise.
14669 * linux-s390-low.c (target_regsets): Likewise.
14670 * linux-sh-low.c (target_regsets): Likewise.
14671 * linux-sparc-low.c (target_regsets): Likewise.
14672 * linux-xtensa-low.c (target_regsets): Likewise.
14674 * linux-low.c: Include <sys/uio.h>.
14675 (regsets_fetch_inferior_registers): Support nt_type.
14676 (regsets_store_inferior_registers): Likewise.
14677 (linux_process_qsupported): New.
14678 (linux_target_ops): Add linux_process_qsupported.
14680 * linux-low.h (regset_info): Add nt_type.
14681 (linux_target_ops): Add process_qsupported.
14683 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
14685 (init_registers_i386_avx_linux): New.
14686 (init_registers_amd64_avx_linux): Likewise.
14687 (xmltarget_i386_linux_no_xml): Likewise.
14688 (xmltarget_amd64_linux_no_xml): Likewise.
14689 (PTRACE_GETREGSET): Likewise.
14690 (PTRACE_SETREGSET): Likewise.
14691 (x86_fill_xstateregset): Likewise.
14692 (x86_store_xstateregset): Likewise.
14693 (use_xml): Likewise.
14694 (x86_linux_update_xmltarget): Likewise.
14695 (x86_linux_process_qsupported): Likewise.
14696 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
14697 (x86_arch_setup): Don't call init_registers_amd64_linux nor
14698 init_registers_i386_linux here. Call
14699 x86_linux_update_xmltarget.
14700 (the_low_target): Add x86_linux_process_qsupported.
14702 * server.c (handle_query): Call target_process_qsupported.
14704 * target.h (target_ops): Add process_qsupported.
14705 (target_process_qsupported): New.
14707 2010-04-03 Pedro Alves <pedro@codesourcery.com>
14709 * inferiors.c (add_thread): Set last_status kind to
14710 TARGET_WAITKIND_IGNORE.
14711 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
14712 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
14713 (linux_wait_1): Move `thread' local definition to block that uses
14714 it. Don't NULL initialize `event_child'.
14715 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
14716 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
14717 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
14719 2010-04-01 Pedro Alves <pedro@codesourcery.com>
14721 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
14722 an extended waitstatus, or by a watchpoint.
14723 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
14724 thread was stepping or has been stopped by a watchpoint.
14726 2010-04-01 Pedro Alves <pedro@codesourcery.com>
14728 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
14729 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
14730 of another, then delete the previous, and validate all
14732 (validate_inserted_breakpoint): New.
14733 (delete_disabled_breakpoints): New.
14734 (validate_breakpoints): New.
14735 (check_mem_read): Validate breakpoints before trusting their
14736 shadow. Delete disabled breakpoints.
14737 (check_mem_write): Validate breakpoints before trusting they
14738 should be inserted. Delete disabled breakpoints.
14739 * mem-break.h (validate_breakpoints):
14740 * server.c (handle_query): Validate breakpoints when we see a
14743 2010-04-01 Pedro Alves <pedro@codesourcery.com>
14745 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
14746 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
14747 if we could tell there's a GDB breakpoint at stop_pc.
14748 (need_step_over_p): Don't do a step over if we find a GDB
14749 breakpoint at the resume PC.
14751 * mem-break.c (struct raw_breakpoint): New.
14752 (enum bkpt_type): New type `gdb_breakpoint'.
14753 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
14754 fields. New field `raw'.
14755 (find_raw_breakpoint_at): New.
14756 (set_raw_breakpoint_at): Handle refcounting. Create a raw
14757 breakpoint instead.
14758 (set_breakpoint_at): Adjust.
14759 (delete_raw_breakpoint): New.
14760 (release_breakpoint): New.
14761 (delete_breakpoint): Rename to...
14762 (delete_breakpoint_1): ... this. Add proc parameter. Use
14763 release_breakpoint. Return ENOENT.
14764 (delete_breakpoint): Reimplement.
14765 (find_breakpoint_at): Delete.
14766 (find_gdb_breakpoint_at): New.
14767 (delete_breakpoint_at): Delete.
14768 (set_gdb_breakpoint_at): New.
14769 (delete_gdb_breakpoint_at): New.
14770 (gdb_breakpoint_here): New.
14771 (set_reinsert_breakpoint): Use release_breakpoint.
14772 (uninsert_breakpoint): Rename to ...
14773 (uninsert_raw_breakpoint): ... this.
14774 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
14775 (reinsert_raw_breakpoint): Change parameter type to
14777 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
14779 (check_breakpoints): Adjust. Use release_breakpoint.
14780 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
14781 (breakpoint_inserted_here): Ditto.
14782 (check_mem_read): Adjust to iterate over raw breakpoints instead.
14783 Don't trust the breakpoint's shadow if it is not inserted.
14784 (check_mem_write): Adjust to iterate over raw breakpoints instead.
14785 (delete_all_breakpoints): Adjust.
14786 (free_all_breakpoints): Mark all breakpoints as uninserted, and
14787 use delete_breakpoint_1.
14789 * mem-break.h (breakpoints_supported): Delete declaration.
14790 (set_gdb_breakpoint_at): Declare.
14791 (gdb_breakpoint_here): Declare.
14792 (delete_breakpoint_at): Delete.
14793 (delete_gdb_breakpoint_at): Declare.
14795 * server.h (struct raw_breakpoint): Forward declare.
14796 (struct process_info): New field `raw_breakpoints'.
14798 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
14801 2010-03-24 Pedro Alves <pedro@codesourcery.com>
14803 * linux-low.c (status_pending_p_callback): Fix comment.
14804 (linux_wait_for_event_1): Move most of the internal breakpoint
14805 handling from here...
14806 (linux_wait_1): ... to here.
14807 (count_events_callback): New.
14808 (select_singlestep_lwp_callback): New.
14809 (select_event_lwp_callback): New.
14810 (cancel_breakpoints_callback): New.
14811 (select_event_lwp): New.
14812 (linux_wait_1): Simplify internal breakpoint handling. Give equal
14813 priority to all LWPs that have had events that should be reported
14814 to the client. Cancel breakpoints when about to reporting the
14815 event to the client, not while stopping lwps. No longer cancel
14816 finished single-steps here.
14817 (cancel_finished_single_step): Delete.
14818 (cancel_finished_single_steps): Delete.
14820 2010-03-24 Pedro Alves <pedro@codesourcery.com>
14822 * mem-break.c (enum bkpt_type): New.
14823 (struct breakpoint): New field `type'.
14824 (set_breakpoint_at): Change return type to struct breakpoint
14825 pointer. Set type to `other_breakpoint' by default.
14826 (delete_breakpoint): Rewrite, supporting more than one breakpoint
14827 in the breakpoint list.
14828 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
14829 (reinsert_breakpoint): Rename to ...
14830 (reinsert_raw_breakpoint): ... this.
14831 (reinsert_breakpoints_at): Adjust.
14832 * mem-break.h (struct breakpoint): Declare.
14833 (set_breakpoint_at): Change return type to struct breakpoint
14836 2010-03-24 Pedro Alves <pedro@codesourcery.com>
14838 * server.c (handle_query): Assign, not compare.
14840 2010-03-24 Pedro Alves <pedro@codesourcery.com>
14842 Teach linux gdbserver to step-over-breakpoints.
14844 * linux-low.c (can_hardware_single_step): New.
14845 (supports_breakpoints): New.
14846 (handle_extended_wait): If stopping threads, read the stop pc of
14847 the new cloned LWP.
14849 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
14850 low target doesn't support retrieving the PC.
14851 (add_lwp): Set last_resume_kind to resume_continue.
14852 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
14853 (linux_attach): Don't clear stop_expected. Set the lwp's
14854 last_resume_kind to resume_stop.
14855 (linux_detach_one_lwp): Don't check for removed breakpoints.
14856 (check_removed_breakpoint): Delete.
14857 (status_pending_p): Rename to ...
14858 (status_pending_p_callback): ... this. Don't check for removed
14859 breakpoints. Don't consider threads that are stopped from GDB's
14861 (linux_wait_for_lwp): Always read the stop_pc here.
14862 (cancel_breakpoint): New.
14863 (step_over_bkpt): New global.
14864 (linux_wait_for_event_1): Implement stepping over breakpoints.
14865 (gdb_wants_lwp_stopped): New.
14866 (gdb_wants_all_stopped): New.
14867 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
14868 single-step traps here. Store the thread's last reported target
14870 (send_sigstop): Don't clear stop_expected. Always set it,
14872 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
14873 (cancel_finished_single_step): New.
14874 (cancel_finished_single_steps): New.
14875 (wait_for_sigstop): Don't cancel finished single-step traps here.
14876 (linux_resume_one_lwp): Don't check for removed breakpoints.
14877 Don't set `step' on non-hardware step archs.
14878 (linux_set_resume_request): Ignore resume_stop requests if already
14879 stopping or stopped. Set the lwp's last_resume_kind.
14880 (resume_status_pending_p): Don't check for removed breakpoints.
14881 (need_step_over_p): New.
14882 (start_step_over): New.
14883 (finish_step_over): New.
14884 (linux_resume_one_thread): Always queue a sigstop for resume_stop
14885 requests. Clear the thread's last reported target waitstatus.
14886 Don't use the `suspended' flag. Don't consider pending breakpoints.
14887 (linux_resume): Start a step-over if necessary.
14888 (proceed_one_lwp): New.
14889 (proceed_all_lwps): New.
14890 (unstop_all_lwps): New.
14891 * linux-low.h (struct lwp_info): Rewrite comment for the
14892 `suspended' flag. Add the `stop_pc' field. Delete the
14893 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
14894 Add `'last_resume_kind' and `need_step_over' fields.
14895 * inferiors.c (struct thread_info): Delete, moved elsewhere.
14896 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
14897 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
14898 (set_raw_breakpoint_at): New.
14899 (set_breakpoint_at): Rewrite to use it.
14900 (reinsert_breakpoint_handler): Delete.
14901 (set_reinsert_breakpoint): New.
14902 (reinsert_breakpoint_by_bp): Delete.
14903 (delete_reinsert_breakpoints): New.
14904 (uninsert_breakpoint): Rewrite.
14905 (uninsert_breakpoints_at): New.
14906 (reinsert_breakpoint): Rewrite.
14907 (reinsert_breakpoints_at): New.
14908 (check_breakpoints): Rewrite.
14909 (breakpoint_here): New.
14910 (breakpoint_inserted_here): New.
14911 (check_mem_read): Adjust.
14912 * mem-break.h (breakpoints_supported, breakpoint_here)
14913 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
14914 (reinsert_breakpoint_by_bp): Delete declaration.
14915 (delete_reinsert_breakpoints): Declare.
14916 (reinsert_breakpoint): Delete declaration.
14917 (reinsert_breakpoints_at): Declare.
14918 (uninsert_breakpoint): Delete declaration.
14919 (uninsert_breakpoints_at): Declare.
14920 (check_breakpoints): Adjust prototype.
14921 * server.h: Adjust include order.
14922 (struct thread_info): Declare here. Add a `last_status' field.
14924 2010-03-23 Michael Snyder <msnyder@vmware.com>
14926 * server.c (crc32): New function.
14927 (handle_query): Add handling for 'qCRC:' request.
14929 2010-03-23 Pedro Alves <pedro@codesourcery.com>
14931 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
14932 lwp had been stopped by a watchpoint.
14934 2010-03-16 Pedro Alves <pedro@codesourcery.com>
14936 * server.h (internal_error): Declare.
14937 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
14938 * utils.c (internal_error): New function.
14940 2010-03-15 Andreas Schwab <schwab@redhat.com>
14942 * configure.srv: Fix typo setting srv_regobj.
14944 2010-03-15 Pedro Alves <pedro@codesourcery.com>
14946 * linux-low.c (fetch_register): Avoid passing a non string literal
14948 (usr_store_inferior_registers): Ditto.
14950 2010-03-14 Pedro Alves <pedro@codesourcery.com>
14952 * linux-low.c (linux_write_memory): Bail out early if peeking
14955 2010-03-14 Pedro Alves <pedro@codesourcery.com>
14957 * linux-low.h (struct lwp_info): New fields
14958 `stopped_by_watchpoint' and `stopped_data_address'.
14959 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
14960 here, and cache them in the lwp object.
14961 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
14963 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
14965 (linux_stopped_by_watchpoint): Rewrite.
14966 (linux_stopped_data_address): Rewrite.
14968 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
14970 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
14971 switching the current inferior, not before.
14973 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
14975 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
14976 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
14977 i386-linux.c and amd64-linux.c.
14978 (reg-i386.o): Removed.
14979 (reg-i386.c): Likewise.
14980 (reg-i386-linux.o): Likewise.
14981 (reg-i386-linux.c): Likewise.
14982 (reg-x86-64.o): Likewise.
14983 (reg-x86-64.c): Likewise.
14984 (reg-x86-64-linux.o): Likewise.
14985 (reg-x86-64-linux.c): Likewise.
14987 (i386.c): Likewise.
14988 (i386-linux.o): Likewise.
14989 (i386-linux.c): Likewise.
14990 (amd64.o): Likewise.
14991 (amd64.c): Likewise.
14992 (amd64-linux.o): Likewise.
14993 (amd64-linux.c): Likewise.
14995 * configure.srv (srv_i386_regobj): New.
14996 (srv_i386_linux_regobj): Likewise.
14997 (srv_amd64_regobj): Likewise.
14998 (srv_amd64_linux_regobj): Likewise.
14999 (srv_i386_32bit_xmlfiles): Likewise.
15000 (srv_i386_64bit_xmlfiles): Likewise.
15001 (srv_i386_xmlfiles): Likewise.
15002 (srv_amd64_xmlfiles): Likewise.
15003 (srv_i386_linux_xmlfiles): Likewise.
15004 (srv_amd64_linux_xmlfiles): Likewise.
15005 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
15006 srv_xmlfiles to $srv_i386_xmlfiles.
15007 (i[34567]86-*-mingw32ce*): Likewise.
15008 (i[34567]86-*-mingw*): Likewise.
15009 (i[34567]86-*-nto*): Likewise.
15010 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
15011 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
15012 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
15013 (x86_64-*-linux*): Likewise.
15015 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
15016 (init_registers_amd64_linux): New.
15017 (x86_arch_setup): Replace init_registers_x86_64_linux with
15018 init_registers_amd64_linux.
15020 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
15022 * configure.ac: Check for libdl. If it is not available link against
15023 static libthread_db.
15024 * configure: Regenerate.
15026 2010-02-22 Pedro Alves <pedro@codesourcery.com>
15030 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
15031 handing a read watchpoint.
15032 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
15034 2010-02-12 Doug Evans <dje@google.com>
15036 * linux-low.c (linux_supports_tracefork_flag): Document.
15037 (linux_look_up_symbols): Add comment.
15039 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
15041 * regcache.c (supply_register): Clear regcache if buf is NULL.
15043 2010-02-02 Nicolas Roche <roche@sourceware.org>
15044 Joel Brobecker <brobecker@adacore.com>
15046 * inferiors.c (find_inferior): Add function documentation.
15047 (unloaded_dll): Handle the case where the unloaded dll has not
15048 been previously registered in the dll list.
15050 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
15052 * linux-arm-low.c (thumb_breakpoint_len): Delete.
15053 (thumb2_breakpoint): New.
15054 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
15056 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
15058 * linux-low.c (get_stop_pc): Check for SIGTRAP.
15059 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
15062 2010-01-21 Pedro Alves <pedro@codesourcery.com>
15064 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
15066 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
15068 * linux-s390-low.c (s390_collect_ptrace_register)
15069 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
15071 2010-01-21 Doug Evans <dje@google.com>
15073 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
15074 (PTRACE_ARG4_TYPE): New macro.
15075 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
15076 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
15077 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
15078 (usr_store_inferior_registers): Ditto.
15079 (linux_read_memory, linux_write_memory): Ditto.
15080 (linux_test_for_tracefork): Ditto.
15082 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
15083 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
15085 2010-01-21 Pedro Alves <pedro@codesourcery.com>
15087 * proc-service.c (ps_lgetregs): Don't refetch registers from the
15090 2010-01-21 Pedro Alves <pedro@codesourcery.com>
15092 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
15093 prototype to take a regcache. Adjust.
15095 2010-01-20 Pedro Alves <pedro@codesourcery.com>
15097 * regcache.h (struct thread_info): Forward declare.
15098 (struct regcache): New.
15099 (new_register_cache): Adjust prototype.
15100 (get_thread_regcache): Declare.
15101 (free_register_cache): Adjust prototype.
15102 (registers_to_string, registers_from_string): Ditto.
15103 (supply_register, supply_register_by_name, collect_register)
15104 (collect_register_as_string, collect_register_by_name): Ditto.
15105 * regcache.c (struct inferior_regcache_data): Delete.
15106 (get_regcache): Rename to ...
15107 (get_thread_regcache): ... this. Adjust. Switch inferior before
15108 fetching registers.
15109 (regcache_invalidate_one): Adjust.
15110 (regcache_invalidate): Fix prototype.
15111 (new_register_cache): Return the new register cache.
15112 (free_register_cache): Change prototype.
15113 (realloc_register_cache): Adjust.
15114 (registers_to_string): Change prototype to take a regcache. Adjust.
15115 (registers_from_string): Ditto.
15116 (register_data): Ditto.
15117 (supply_register): Ditto.
15118 (supply_register_by_name): Ditto.
15119 (collect_register): Ditto.
15120 (collect_register_as_string): Ditto.
15121 (collect_register_by_name): Ditto.
15122 * server.c (process_serial_event): Adjust.
15123 * linux-low.h (regset_fill_func, regset_store_func): Change
15125 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
15127 * linux-low.c (get_stop_pc): Adjust.
15128 (check_removed_breakpoint): Adjust.
15129 (linux_wait_for_event): Adjust.
15130 (linux_resume_one_lwp): Adjust.
15131 (fetch_register): Add regcache parameter. Adjust.
15132 (usr_store_inferior_registers): Ditto.
15133 (regsets_fetch_inferior_registers): Ditto.
15134 (regsets_store_inferior_registers): Ditto.
15135 (linux_fetch_registers, linux_store_registers): Ditto.
15136 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
15138 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
15140 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
15141 prototype to take a regcache.
15142 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
15143 * remote-utils.c (convert_ascii_to_int, outreg)
15144 (prepare_resume_reply): Change prototype to take a regcache.
15146 * target.h (struct target_ops) <fetch_registers, store_registers>:
15147 Change prototype to take a regcache.
15148 (fetch_inferior_registers, store_inferior_registers): Change
15149 prototype to take a regcache. Adjust.
15150 * proc-service.c (ps_lgetregs): Adjust.
15151 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
15152 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
15153 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
15154 take a regcache. Adjust.
15155 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
15156 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
15157 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
15158 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
15159 * linux-cris-low.c (cris_get_pc, cris_set_pc)
15160 (cris_cannot_fetch_register):
15161 (cris_breakpoint_at): Change prototype to take a regcache.
15163 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
15164 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
15165 to take a regcache. Adjust.
15166 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
15168 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
15169 take a regcache. Adjust.
15170 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
15171 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
15172 (m68k_set_pc): Change prototype to take a regcache. Adjust.
15173 * linux-mips-low.c (mips_get_pc):
15174 (mips_set_pc): Change prototype to take a regcache. Adjust.
15175 (mips_reinsert_addr): Adjust.
15176 (mips_collect_register): Change prototype to take a regcache.
15178 (mips_supply_register):
15179 (mips_collect_register_32bit, mips_supply_register_32bit)
15180 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
15181 (mips_store_fpregset): Ditto.
15182 * linux-ppc-low.c (ppc_supply_ptrace_register)
15183 (ppc_supply_ptrace_register): Ditto.
15184 (parse_spufs_run): Adjust.
15185 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
15186 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
15187 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
15188 take a regcache. Adjust.
15189 * linux-s390-low.c (s390_collect_ptrace_register)
15190 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
15191 (s390_set_pc): Change prototype to take a regcache. Adjust.
15192 (s390_arch_setup): Adjust.
15193 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
15194 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
15195 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
15196 (sparc_fill_gregset, sparc_store_gregset_from_stack)
15197 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
15199 (sparc_breakpoint_at): Adjust.
15200 * linux-xtensa-low.c (xtensa_fill_gregset):
15201 (xtensa_store_gregset):
15202 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
15203 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
15204 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
15205 prototype to take a regcache. Adjust.
15206 * win32-arm-low.c (arm_fetch_inferior_register)
15207 (arm_store_inferior_register): Change prototype to take a
15209 * win32-i386-low.c (i386_fetch_inferior_register)
15210 (i386_store_inferior_register): Change prototype to take a
15212 * win32-low.c (child_fetch_inferior_registers)
15213 (child_store_inferior_registers): Change prototype to take a
15215 (win32_wait): Adjust.
15216 (win32_fetch_inferior_registers): Change prototype to take a
15218 (win32_store_inferior_registers): Adjust.
15219 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
15220 store_inferior_register>: Change prototype to take a regcache.
15222 2010-01-20 Doug Evans <dje@google.com>
15224 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
15226 (linux_wait_for_event1, linux_init_signals): Ditto.
15227 (W_STOPCODE): Provide definition if missing.
15229 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
15231 * linux-low.c (linux_core_of_thread): New.
15232 (compare_ints, show_process, list_threads): New.
15233 (linux_qxfer_osdata): Report threads and cores.
15234 (linux_target_op): Register linux_core_of_thread.
15235 * remote-utils.c (prepare_resume_reply): Report the core.
15236 (buffer_xml_printf): Support %d specifier.
15237 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
15239 (handle_query): Handle qXfer:threads. Announce availability
15241 * target.h (struct target_ops): New field core_of_thread.
15243 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
15245 * Makefile.in (clean): Remove new generated files.
15246 (reg-s390.o, reg-s390.c): Remove rules.
15247 (reg-s390x.o, reg-s390x.c): Likewise.
15248 (s390-linux32.o, s390-linux32.c): Add rules.
15249 (s390-linux64.o, s390-linux64.c): Likewise.
15250 (s390x-linux64.o, s390x-linux64.c): Likewise.
15251 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
15252 * linux-s390-low.c: Include <elf.h>.
15253 (HWCAP_S390_HIGH_GPRS): Define if undefined.
15254 (init_registers_s390): Remove prototype.
15255 (init_registers_s390x): Likewise.
15256 (init_registers_s390_linux32): Add prototype.
15257 (init_registers_s390_linux64): Likewise.
15258 (init_registers_s390x_linux64): Likewise.
15259 (s390_num_regs_3264): New define.
15260 (s390_regmap_3264): New global variable.
15261 (s390_cannot_fetch_register): Remove obsolete check.
15262 (s390_cannot_store_register): Likewise.
15263 (s390_collect_ptrace_register): Handle upper/lower register halves.
15264 (s390_supply_ptrace_register): Likewise.
15265 (s390_fill_gregset): Update to register number changes.
15266 (s390_get_hwcap): New routine.
15267 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
15268 Install appropriate regmap and register set.
15270 2010-01-01 Joel Brobecker <brobecker@adacore.com>
15272 * server.c (gdbserver_version): Update copyright year to 2010.
15273 * gdbreplay.c (gdbreplay_version): Likewise.
15275 2009-12-28 Doug Evans <dje@google.com>
15277 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
15278 elf/external.h. Include <elf.h> instead but only if necessary.
15280 2009-12-28 Pedro Alves <pedro@codesourcery.com>
15282 * linux-low.c (linux_remove_process): Remove `detaching'
15283 parameter. Don't release/detach from thread_db here.
15284 (linux_kill): Release/detach from thread_db here, ...
15285 (linux_detach): ... and here, before actually detaching.
15286 (linux_wait_1): ... and here, when a process exits.
15287 * thread-db.c (any_thread_of): New.
15288 (thread_db_free): Switch the current inferior to a thread of the
15291 2009-12-21 Doug Evans <dje@google.com>
15293 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
15295 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
15296 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
15297 warning ifndef __NR_tkill. Move setting of errno there too.
15298 Delete unnecessary resetting of errno after syscall.
15299 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
15301 * configure.ac: Check for dladdr.
15302 * config.in: Regenerate.
15303 * configure: Regenerate.
15304 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
15305 (try_thread_db_load): Update.
15307 * linux-low.c (my_waitpid): Delete unnecessary prototype.
15309 2009-12-18 Doug Evans <dje@google.com>
15311 * event-loop.c: Include unistd.h if it exists.
15313 * linux-low.c (my_waitpid): Move definition away from being in
15314 between linux_tracefork_child/linux_test_for_tracefork.
15316 * gdb_proc_service.h (psaddr_t): Fix type.
15317 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
15318 signature to match glibc.
15320 2009-12-16 Doug Evans <dje@google.com>
15322 * linux-low.c (linux_read_memory): Fix argument to read.
15324 2009-11-26 Pedro Alves <pedro@codesourcery.com>
15326 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
15327 events, don't leave current_inferior pointing at null.
15329 2009-11-26 Pedro Alves <pedro@codesourcery.com>
15331 * win32-low.c (LOG): Delete.
15332 (OUTMSG): Output to stderr.
15333 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
15334 on compile time LOG macro.
15335 (win32_wait): Fix debug output.
15337 2009-11-26 Pedro Alves <pedro@codesourcery.com>
15339 * win32-low.c (win32_add_one_solib): If the dll name is
15340 "ntdll.dll", prepend the system directory to the dll path.
15342 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
15344 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
15346 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
15347 Vladimir Prus <vladimir@codesourcery.com>
15349 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
15350 * configure.ac: Check for __mcoldfire__ and set
15351 gdb_cv_m68k_is_coldfire.
15352 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
15353 reg-cf.o and reg-m68k.o.
15354 * configure: Regenerated.
15356 2009-11-16 Pedro Alves <pedro@codesourcery.com>
15358 * linux-low.c (linux_remove_process): Add `detaching' parameter.
15359 Pass it to thread_db_free.
15360 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
15361 proper `detaching' argument to linux_remove_process.
15362 * linux-low.h (thread_db_free): Add `detaching' parameter.
15363 * thread-db.c (thread_db_init): Pass false as `detaching' argument
15365 (thread_db_free): Add `detaching' parameter. Only
15366 call td_ta_clear_event if detaching from process.
15368 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
15370 * thread-db.c (thread_db_free): Fix typo.
15372 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
15375 * thread-db.c (thread_db_free): Call td_ta_clear_event.
15377 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
15379 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
15380 with an i686 compiler.
15381 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
15383 * configure: Rebuilt.
15385 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
15389 * server.c (handle_search_memory_1): Correct read_addr initialization
15390 in loop for searching subsequent chunks.
15392 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
15394 * configure.ac: New --with-libthread-db option.
15395 * thread-db.c: Allow direct dependence on libthread_db.
15396 (thread_db_free): Adjust.
15397 * config.in: Regenerate.
15398 * configure: Likewise.
15400 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
15403 * thread-db.c (attach_thread): New function.
15404 (maybe_attach_thread): Return success/failure.
15405 (find_new_threads_callback): Adjust.
15406 (thread_db_find_new_threads): Loop until no new threads.
15408 2009-10-13 Pedro Alves <pedro@codesourcery.com>
15410 * proc-service.c (ps_lgetregs): Formatting.
15412 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
15414 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
15415 * configure.ac: Adjust.
15416 * linux-low.h (struct process_info_private): Move members to struct
15418 (thread_db_free, thread_db_handle_monitor_command): New prototype.
15419 * linux-low.c (linux_remove_process): Adjust.
15420 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
15421 * server.c (handle_query): Move code ...
15422 (handle_monitor_command): ... here. New function.
15423 * target.h (struct target_ops): New member.
15424 * thread-db.c (struct thread_db): New.
15425 (libthread_db_search_path): New variable.
15426 (thread_db_create_event, thread_db_enable_reporting)
15427 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
15428 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
15429 (try_thread_db_load_1, dladdr_to_soname): New functions.
15430 (try_thread_db_load, thread_db_load_search): New functions.
15431 (thread_db_init): Search for libthread_db.
15432 (thread_db_free): New function.
15433 (thread_db_handle_monitor_command): Likewise.
15434 * config.in: Regenerate.
15435 * configure: Regenerate.
15437 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
15439 * spu-low.c (spu_kill): Wait for inferior to terminate.
15440 Call clear_inferiors.
15441 (spu_detach): Call clear_inferiors.
15443 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15445 * aclocal.m4: Regenerate.
15446 * config.in: Likewise.
15447 * configure: Likewise.
15449 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
15451 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
15452 (parse_spufs_run): New function.
15453 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
15454 (ppc_breakpoint_at): Handle SPU breakpoints.
15456 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
15458 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
15459 (SPUFS_MAGIC): Define.
15460 (spu_enumerate_spu_ids): New function.
15461 (linux_qxfer_spu): New function.
15462 (linux_target_ops): Install linux_qxfer_spu.
15464 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
15466 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
15467 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
15468 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
15469 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
15470 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
15471 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
15472 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
15473 (init_registers_powerpc_cell32l): Add prototype.
15474 (init_registers_powerpc_cell64l): Likewise.
15475 (ppc_arch_setup): Detect Cell/B.E. architecture.
15477 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15479 * Makefile.in (datarootdir): New variable.
15481 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
15483 * linux-low.c (linux_write_memory): Update debugging output.
15484 * Makefile.in (clean): Add new descriptions.
15485 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
15486 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
15487 * configure.srv: Add new files for arm*-*-linux*.
15488 * linux-arm-low.c: Add new declarations.
15489 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
15490 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
15491 (HWCAP_VFPv3D16): New.
15492 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
15493 instead of __IWMMXT__.
15494 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
15495 (arm_arch_setup): New.
15496 (target_regsets): Remove #ifdef. Add VFP regset.
15497 (the_low_target): Use arm_arch_setup.
15499 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
15501 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
15502 the main thread again.
15504 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
15506 Adding Neutrino gdbserver.
15507 * configure: Regenerated.
15508 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
15509 * configure.srv (i[34567]86-*-nto*): New target.
15510 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
15511 * remote-utils.c [__QNX__]: Include sys/iomgr.h
15512 (nto_comctrl) [__QNX__]: New function.
15513 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
15515 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
15517 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
15520 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
15521 Pedro Alves <pedro@codesourcery.com>
15523 * win32-i386-low.c (i386_get_thread_context): Handle systems that
15524 don't support CONTEXT_EXTENDED_REGISTERS.
15525 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
15526 (the_low_target): Install them.
15527 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
15528 failing with ERROR_PIPE_NOT_CONNECTED.
15530 2009-06-30 Doug Evans <dje@google.com>
15531 Pierre Muller <muller@ics.u-strasbg.fr>
15533 Add h/w watchpoint support to x86-linux, win32-i386.
15534 * Makefile.in (SFILES): Add i386-low.c
15535 (i386_low_h): Define.
15536 (i386-low.o): Add dependencies.
15537 (linux-x86-low.o): Add i386-low.h dependency.
15538 (win32-i386-low.o): Ditto.
15539 * i386-low.c: New file.
15540 * i386-low.h: New file.
15541 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
15542 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
15543 * linux-low.c (linux_add_process): Initialize arch_private.
15544 (linux_remove_process): Free arch_private.
15545 (add_lwp): Initialize arch_private.
15546 (delete_lwp): Free arch_private.
15547 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
15549 * linux-low.h (process_info_private): New member arch_private.
15550 (lwp_info): New member arch_private.
15551 (linux_target_ops): New members new_process, new_thread,
15553 (ptid_of): New macro.
15554 * linux-x86-low.c: Include stddef.h, i386-low.h.
15555 (arch_process_info): New struct.
15556 (arch_lwp_info): New struct.
15557 (x86_linux_dr_get, x86_linux_dr_set): New functions.
15558 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
15559 (i386_dr_low_get_status): New function.
15560 (x86_insert_point, x86_remove_point): New functions.
15561 (x86_stopped_by_watchpoint): New function.
15562 (x86_stopped_data_address): New function.
15563 (x86_linux_new_process, x86_linux_new_thread): New functions.
15564 (x86_linux_prepare_to_resume): New function.
15565 (the_low_target): Add entries for insert_point, remove_point,
15566 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
15568 * server.c (debug_hw_points): New global.
15569 (monitor_show_help): Document set debug-hw-points.
15570 (handle_query): Process "set debug-hw-points".
15571 * server.h (debug_hw_points): Declare.
15572 (paddress): Declare.
15573 * utils.c (NUMCELLS, CELLSIZE): New macros.
15574 (get_sell, xsnprintf, paddress): New functions.
15575 * win32-arm-low.c (the_low_target): Add entries for insert_point,
15576 remove_point, stopped_by_watchpoint, stopped_data_address.
15577 * win32-i386-low.c: Include i386-low.h.
15578 (debug_reg_state): Replaces dr.
15579 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
15580 (i386_dr_low_get_status): New function.
15581 (i386_insert_point, i386_remove_point): New functions.
15582 (i386_stopped_by_watchpoint): New function.
15583 (i386_stopped_data_address): New function.
15584 (i386_initial_stuff): Update.
15585 (get_thread_context,set_thread_context,i386_thread_added): Update.
15586 (the_low_target): Add entries for insert_point,
15587 remove_point, stopped_by_watchpoint, stopped_data_address.
15588 * win32-low.c (win32_insert_watchpoint): New function.
15589 (win32_remove_watchpoint): New function.
15590 (win32_stopped_by_watchpoint): New function.
15591 (win32_stopped_data_address): New function.
15592 (win32_target_ops): Add entries for insert_watchpoint,
15593 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
15594 * win32-low.h (win32_target_ops): New members insert_point,
15595 remove_point, stopped_by_watchpoint, stopped_data_address.
15597 2009-06-25 Pedro Alves <pedro@codesourcery.com>
15599 * server.c (process_serial_event): Re-return unsupported, not
15600 error, if the type isn't recognized. Re-allow supporting only
15601 insert or remove packets. Also call require_running for
15602 breakpoints. Add missing break statement to default case. Tidy.
15603 * target.h (struct target_ops): Rename insert_watchpoint to
15604 insert_point, and remove_watchpoint to remove_point.
15606 * linux-low.h (struct linux_target_ops): Likewise.
15607 * linux-low.c (linux_insert_watchpoint): Rename to ...
15608 (linux_insert_point): ... this. Adjust.
15609 (linux_remove_watchpoint): Rename to ...
15610 (linux_remove_point): ... this. Adjust.
15611 (linux_target_ops): Adjust.
15612 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
15613 (cris_insert_point): ... this.
15614 (cris_remove_watchpoint): Rename to ...
15615 (cris_remove_point): ... this.
15616 (the_low_target): Adjust.
15618 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
15620 * server.c (handle_v_kill): Pass signal_pid to
15621 kill_inferior if multi_process is zero.
15623 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
15625 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
15626 * target.h (target_ops): Comment for *_watchpoint to make it clear
15627 the functions can get types '0' and '1'.
15629 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
15631 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
15632 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
15633 * regcache.c (get_regcache): Likewise.
15634 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
15635 * win32-low.c (child_fetch_inferior_registers): Remove check for
15638 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
15639 Pedro Alves <pedro@codesourcery.com>
15641 * target.h (struct target_ops) <supports_multi_process>: New
15643 (target_supports_multi_process): New.
15644 * server.c (handle_query): Even if GDB reports support, only
15645 enable multi-process if the target also supports it. Report
15646 multi-process support only if the target backend supports it.
15647 * linux-low.c (linux_supports_multi_process): New function.
15648 (linux_target_ops): Install it as target_supports_multi_process
15651 2009-05-24 Doug Evans <dje@google.com>
15653 Global renaming of find_thread_pid to find_thread_ptid.
15654 * server.h (find_thread_ptid): Renamed from find_thread_pid.
15655 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
15656 All callers updated.
15658 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
15659 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
15662 * linux-low.c (get_stop_pc): Print pc if debug_threads.
15663 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
15664 (linux_resume_one_lwp): Ditto.
15666 2009-05-23 Doug Evans <dje@google.com>
15668 * linux-low.c (linux_resume_one_lwp): Change type of first arg
15669 from struct inferior_list_entry * to struct lwp_info *.
15670 All callers updated.
15672 2009-05-13 Doug Evans <dje@google.com>
15674 * linux-x86-low.c: Don't include assert.h.
15675 (x86_siginfo_fixup): Use fatal, not assert.
15676 (x86_arch_setup): Fix comment.
15678 2009-05-12 Doug Evans <dje@google.com>
15680 Biarch support for i386/amd64 gdbserver.
15681 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
15682 Add linux-x86-low.c.
15683 (linux-i386-low.o, linux-x86-64-low.o): Delete.
15684 (linux-x86-low.o): Add.
15685 * linux-x86-64-low.c: Delete.
15686 * linux-i386-low.c: Delete.
15687 * linux-x86-low.c: New file.
15688 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
15690 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
15692 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
15693 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
15694 (linux_child_pid_to_exec_file): New function.
15695 (elf_64_header_p, elf_64_file_p): New functions.
15696 (siginfo_fixup): New function.
15697 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
15698 give target a chance to convert layout.
15699 * linux-low.h (linux_target_ops): New member siginfo_fixup.
15700 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
15702 2009-05-07 Doug Evans <dje@google.com>
15704 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
15705 (regsets_store_inferior_registers): Ditto.
15707 2009-05-06 Pedro Alves <pedro@codesourcery.com>
15711 * linux-low.c (must_set_ptrace_flags): Delete.
15712 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
15714 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
15715 `lwp->must_set_ptrace_flags' instead.
15716 (linux_wait_for_event_1): Set ptrace options here.
15717 (linux_wait_1): ... not here.
15719 2009-04-30 Doug Evans <dje@google.com>
15721 * inferiors.c (started_inferior_callback): New function.
15722 (attached_inferior_callback): New function.
15723 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
15724 * server.c (print_started_pid, print_attached_pid): New functions.
15725 (detach_or_kill_for_exit): New function.
15726 (main): Call it instead of for_each_inferior (kill_inferior_callback).
15727 * server.h (have_started_inferiors_p): Declare.
15728 (have_attached_inferiors_p): Declare.
15730 * inferiors.c (remove_process): Fix memory leak, free process.
15731 * linux-low.c (linux_remove_process): New function.
15732 (linux_kill): Call it instead of remove_process.
15733 (linux_detach, linux_wait_1): Ditto.
15735 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
15737 * configure.srv: Add x86 Windows CE target.
15739 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
15741 * inferiors.c (get_thread_process): Make global.
15742 * server.h (get_thread_process): Add prototype.
15743 * thread-db.c (find_one_thread): Use get_thread_process
15744 instead of current_process.
15745 (thread_db_get_tls_address): Do not crash if called when
15746 thread layer is not yet initialized.
15748 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
15750 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
15751 * spu-low.c (current_tid): Rename to ...
15752 (current_ptid): ... this.
15753 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
15754 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
15755 ptid_get_lwp (current_ptid) instead of current_tid.
15756 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
15757 instead of current_tid. Use find_process_pid to verify pid
15758 argument is valid. Pass proper argument to remove_process.
15759 (spu_thread_alive): Compare current_ptid instead of current_tid.
15760 (spu_resume): Likewise.
15762 2009-04-02 Pedro Alves <pedro@codesourcery.com>
15764 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
15767 2009-04-01 Pedro Alves <pedro@codesourcery.com>
15769 Implement the multiprocess extensions, and add linux multiprocess
15772 * server.h (ULONGEST): Declare.
15773 (struct ptid, ptid_t): New.
15774 (minus_one_ptid, null_ptid): Declare.
15775 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
15776 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
15777 (struct inferior_list_entry): Change `id' type from unsigned from
15779 (struct sym_cache, struct breakpoint, struct
15780 process_info_private): Forward declare.
15781 (struct process_info): Declare.
15782 (current_process): Declare.
15783 (all_processes): Declare.
15784 (initialize_inferiors): Declare.
15785 (add_thread): Adjust to use ptid_t.
15786 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
15787 (add_process, remove_process, find_thread_pid): Declare.
15788 (find_inferior_id): Adjust to use ptid_t.
15789 (cont_thread, general_thread, step_thread): Change type to ptid_t.
15790 (multi_process): Declare.
15791 (push_event): Adjust to use ptid_t.
15792 (read_ptid, write_ptid): Declare.
15793 (prepare_resume_reply): Adjust to use ptid_t.
15794 (clear_symbol_cache): Declare.
15795 * inferiors.c (all_processes): New.
15796 (null_ptid, minus_one_ptid): New.
15797 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
15798 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
15799 (add_thread): Change unsigned long to ptid. Remove gdb_id
15801 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
15802 (gdb_id_to_thread): Rename to ...
15803 (find_thread_pid): ... this. Change unsigned long to ptid.
15804 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
15805 (loaded_dll, pull_pid_from_list): Adjust.
15806 (add_process, remove_process, find_process_pid)
15807 (get_thread_process, current_process, initialize_inferiors): New.
15808 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
15809 (struct target_waitstatus) <related_pid>: Ditto.
15810 (struct target_ops) <kill, detach>: Add `pid' argument. Change
15811 return type to int.
15812 (struct target_ops) <join>: Add `pid' argument.
15813 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
15814 (struct target_ops) <wait>: Add `ptid' field. Change return type
15816 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
15817 (mywait): Add `ptid' argument. Change return type to ptid_t.
15818 (target_pid_to_str): Declare.
15819 * target.c (set_desired_inferior): Adjust to use ptids.
15820 (mywait): Add new `ptid' argument. Adjust.
15821 (target_pid_to_str): New.
15822 * mem-break.h (free_all_breakpoints): Declare.
15823 * mem-break.c (breakpoints): Delelete.
15824 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
15825 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
15826 to use per-process breakpoint list.
15827 (free_all_breakpoints): New.
15828 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
15829 (symbol_cache, all_symbols_looked_up): Delete.
15831 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
15833 (prepare_resume_reply): Change ptid argument's type from unsigned
15834 long to ptid_t. Adjust. Implement W;process and X;process.
15835 (free_sym_cache, clear_symbol_cache): New.
15836 (look_up_one_symbol): Adjust to per-process symbol cache. *
15837 * server.c (cont_thread, general_thread, step_thread): Change type
15839 (attached): Delete.
15840 (multi_process): New.
15841 (last_ptid): Change type to ptid_t.
15842 (struct vstop_notif) <ptid>: Change type to ptid_t.
15843 (queue_stop_reply, push_event): Change `ptid' argument's type to
15845 (discard_queued_stop_replies): Add `pid' argument.
15846 (start_inferior): Adjust to use ptids. Adjust to mywait interface
15847 changes. Don't reference the `attached' global.
15848 (attach_inferior): Adjust to mywait interface changes.
15849 (handle_query): Adjust to use ptids. Parse GDB's qSupported
15850 features. Handle and report "multiprocess+". Handle
15852 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
15854 (handle_v_kill): New.
15855 (handle_v_stopped): Adjust to use target_pid_to_str.
15856 (handle_v_requests): Allow multiple attaches and runs when
15857 multiprocess extensions are in effect. Handle "vKill".
15858 (myresume): Adjust to use ptids.
15859 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
15860 (handle_status): Adjust to discard_queued_stop_replies interface
15862 (first_thread_of, kill_inferior_callback)
15863 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
15864 (main): Call initialize_inferiors. Adjust to use ptids, killing
15865 and detaching from all inferiors. Handle multiprocess packet
15867 * linux-low.h: Include gdb_proc_service.h.
15868 (struct process_info_private): New.
15869 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
15870 <lwpid_of>: Use ptid_get_lwp.
15871 (get_lwp_thread): Adjust.
15872 (struct lwp_info): Add `dead' member.
15873 (find_lwp_pid): Declare.
15874 * linux-low.c (thread_db_active): Delete.
15875 (new_inferior): Adjust comment.
15876 (inferior_pid): Delete.
15877 (linux_add_process): New.
15878 (handle_extended_wait): Adjust.
15879 (add_lwp): Change unsigned long to ptid.
15880 (linux_create_inferior): Add process to processes table. Adjust
15881 to use ptids. Don't set new_inferior here.
15882 (linux_attach_lwp): Rename to ...
15883 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
15884 it. Adjust to use ptids.
15885 (linux_attach_lwp): New.
15886 (linux_attach): Add process to processes table. Don't set
15888 (struct counter): New.
15889 (second_thread_of_pid_p, last_thread_of_process_p): New.
15890 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
15891 multiple processes.
15892 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
15893 processes. Remove process from process table.
15894 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
15895 to multiple processes.
15896 (any_thread_of): New.
15897 (linux_detach): Add `pid' argument, and handle it. Remove process
15898 from processes table.
15899 (linux_join): Add `pid' argument. Handle it.
15900 (linux_thread_alive): Change unsighed long argument to ptid_t.
15901 Consider dead lwps as not being alive.
15902 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
15903 threads we're not interested in.
15904 (same_lwp, find_lwp_pid): New.
15905 (linux_wait_for_lwp): Change `pid' argument's type from int to
15907 (linux_wait_for_event): Rename to ...
15908 (linux_wait_for_event_1): ... this. Change `pid' argument's type
15909 from int to ptid_t. Adjust.
15910 (linux_wait_for_event): New.
15911 (linux_wait_1): Add `ptid' argument. Change return type to
15912 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
15913 that exit from the process table.
15914 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
15916 (mark_lwp_dead): New.
15917 (wait_for_sigstop): Adjust to use ptids. If a process exits while
15918 stopping all threads, mark its main lwp as dead.
15919 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
15921 (fetch_register, usr_store_inferior_registers)
15922 (regsets_fetch_inferior_registers)
15923 (regsets_store_inferior_registers, linux_read_memory)
15924 (linux_write_memory): Inline `inferior_pid'.
15925 (linux_look_up_symbols): Adjust to use per-process
15926 `thread_db_active'.
15927 (linux_request_interrupt): Adjust to use ptids.
15928 (linux_read_auxv): Inline `inferior_pid'.
15929 (initialize_low): Don't reference thread_db_active.
15930 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
15931 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
15932 (ps_getpid): Return the pid of the current inferior.
15933 * thread-db.c (proc_handle, thread_agent): Delete.
15934 (thread_db_create_event, thread_db_enable_reporting): Adjust to
15936 (find_one_thread): Change argument type to ptid_t. Adjust to
15938 (maybe_attach_thread): Adjust to per-process data and ptids.
15939 (thread_db_find_new_threads): Ditto.
15940 (thread_db_init): Ditto.
15941 * spu-low.c (spu_create_inferior, spu_attach): Add process to
15942 processes table. Adjust to use ptids.
15943 (spu_kill, spu_detach): Adjust interface. Remove process from
15945 (spu_join, spu_thread_alive): Adjust interface.
15946 (spu_wait): Adjust interface. Remove process from processes
15947 table. Adjust to use ptids.
15948 * win32-low.c (current_inferior_tid): Delete.
15949 (current_inferior_ptid): New.
15950 (debug_event_ptid): New.
15951 (thread_rec): Take a ptid. Adjust.
15952 (child_add_thread): Add `pid' argument. Adjust to use ptids.
15953 (child_delete_thread): Ditto.
15954 (do_initial_child_stuff): Add `attached' argument. Add process to
15956 (child_fetch_inferior_registers, child_store_inferior_registers):
15958 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
15959 (win32_attach): Pass 1 to do_initial_child_stuff.
15960 (win32_kill): Adjust interface. Remove process from processes
15962 (win32_detach): Ditto.
15963 (win32_join): Adjust interface.
15964 (win32_thread_alive): Take a ptid.
15965 (win32_resume): Adjust to use ptids.
15966 (get_child_debug_event): Ditto.
15967 (win32_wait): Adjust interface. Remove exiting process from
15970 2009-04-01 Pedro Alves <pedro@codesourcery.com>
15972 Non-stop mode support.
15974 * server.h (non_stop): Declare.
15975 (gdb_client_data, handler_func): Declare.
15976 (delete_file_handler, add_file_handler, start_event_loop):
15978 (handle_serial_event, handle_target_event, push_event)
15979 (putpkt_notif): Declare.
15980 * target.h (enum resume_kind): New.
15981 (struct thread_resume): Replace `step' field by `kind' field.
15982 (TARGET_WNOHANG): Define.
15983 (struct target_ops) <wait>: Add `options' argument.
15984 <supports_non_stop, async, start_non_stop>: New fields.
15985 (target_supports_non_stop, target_async): New.
15986 (start_non_stop): Declare.
15987 (mywait): Add `options' argument.
15988 * target.c (mywait): Add `options' argument. Print child exit
15989 notifications here.
15990 (start_non_stop): New.
15991 * server.c (non_stop, own_buf, mem_buf): New globals.
15992 (struct vstop_notif): New.
15993 (notif_queue): New global.
15994 (queue_stop_reply, push_event, discard_queued_stop_replies)
15995 (send_next_stop_reply): New.
15996 (start_inferior): Adjust to use resume_kind. Adjust to mywait
15998 (attach_inferior): In non-stop mode, don't wait for the target
16000 (handle_general_set): Handle QNonStop.
16001 (handle_query): When handling qC, return the current general
16002 thread, instead of the first thread of the list.
16003 (handle_query): If the backend supports non-stop mode, include
16004 QNonStop+ in the qSupported query response.
16005 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
16007 (handle_v_attach, handle_v_run): Handle non-stop mode.
16008 (handle_v_stopped): New.
16009 (handle_v_requests): Report support for vCont;t. Handle vStopped.
16010 (myresume): Adjust to use resume_kind. Handle non-stop.
16011 (queue_stop_reply_callback): New.
16012 (handle_status): Handle non-stop mode.
16013 (main): Clear non_stop flag on reconnection. Use the event-loop.
16014 Refactor serial protocol handling from here ...
16015 (process_serial_event): ... to this new function. When GDB
16016 selects any thread, select one here. In non-stop mode, wait until
16017 GDB acks all pending events before exiting.
16018 (handle_serial_event, handle_target_event): New.
16019 * remote-utils.c (remote_open): Install remote_desc in the event
16021 (remote_close): Remove remote_desc from the event loop.
16022 (putpkt_binary): Rename to...
16023 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
16024 (putpkt_binary): New as wrapper around putpkt_binary_1.
16025 (putpkt_notif): New.
16026 (prepare_resume_reply): In non-stop mode, don't change the
16028 * event-loop.c: New.
16029 * Makefile.in (OBJ): Add event-loop.o.
16030 (event-loop.o): New rule.
16032 * linux-low.h (pid_of): Moved here.
16034 (get_lwp_thread): Use lwpid_of.
16035 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
16036 * linux-low.c (pid_of): Delete.
16037 (inferior_pid): Use lwpid_of.
16038 (linux_event_pipe): New.
16039 (target_is_async_p): New.
16041 (handle_extended_wait): Use lwpid_of.
16042 (add_lwp): Don't set lwpid field.
16043 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
16044 (linux_kill_one_lwp): If killing a running lwp, stop it first.
16045 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
16046 (linux_detach_one_lwp): If detaching from a running lwp, stop it
16047 first. Adjust to linux_wait_for_event interface changes. Use
16049 (linux_detach): Don't delete the main lwp here.
16050 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
16051 (status_pending_p): Don't consider explicitly suspended lwps.
16052 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
16053 pointer. Add OPTIONS argument. Change return type to int. Use
16054 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
16055 (linux_wait_for_event): Take an integer pid instead of a lwp_info
16056 pointer. Add status pointer argument. Return a pid instead of a
16057 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
16058 changes. In non-stop mode, don't switch to a random thread.
16059 (linux_wait): Rename to...
16060 (linux_wait_1): ... this. Add target_options argument, and handle
16061 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
16062 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
16063 clean exit and signal exit code. Don't stop all threads in
16064 non-stop mode. In all-stop mode, only stop all threads when
16065 reporting a stop to GDB. Handle explicit thread stop requests.
16066 (async_file_flush, async_file_mark): New.
16068 (send_sigstop): Use lwpid_of.
16069 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
16070 interface changes. In non-stop mode, don't switch to a random
16072 (linux_resume_one_lwp): Use lwpid_of.
16073 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
16074 (linux_resume_one_thread): ... this. Handle resume_stop. In
16075 non-stop mode, don't look for pending flag in all threads.
16076 (resume_status_pending_p): Don't consider explicitly suspended
16078 (my_waitpid): Reimplement. Emulate __WALL.
16079 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
16081 (sigchld_handler, linux_supports_non_stop, linux_async)
16082 (linux_start_non_stop): New.
16083 (linux_target_ops): Register linux_supports_non_stop, linux_async
16084 and linux_start_non_stop.
16085 (initialize_low): Install SIGCHLD handler.
16086 * thread-db.c (thread_db_create_event, find_one_thread)
16087 (thread_db_get_tls_address): Use lwpid_of.
16088 * win32-low.c (win32_detach): Adjust to use resume_kind.
16089 (win32_wait): Add `options' argument.
16090 * spu-low.c (spu_resume): Adjust to use resume_kind.
16091 (spu_wait): Add `options' argument.
16093 2009-04-01 Pedro Alves <pedro@codesourcery.com>
16095 Decouple target code from remote protocol.
16097 * target.h (enum target_waitkind): New.
16098 (struct target_waitstatus): New.
16099 (struct target_ops) <wait>: Return an unsigned long. Take a
16100 target_waitstatus pointer instead of a char pointer.
16101 (mywait): Likewise.
16102 * target.c (mywait): Change prototype to return an unsigned long.
16103 Take a target_waitstatus pointer instead of a char pointer. Adjust.
16104 * server.h (thread_from_wait, old_thread_from_wait): Delete
16106 (prepare_resume_reply): Change prototype to take a
16108 * server.c (thread_from_wait, old_thread_from_wait): Delete.
16109 (last_status, last_ptid): New.
16110 (start_inferior): Remove "statusptr" argument. Adjust. Return a
16111 pid instead of a signal.
16112 (attach_inferior): Remove "status" and "signal" parameters.
16114 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
16116 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
16117 (handle_v_requests, myresume): Remove "status" and "signal"
16118 parameters. Adjust.
16119 (handle_status): New.
16120 (main): Delete local `status'. Adjust.
16121 * remote-utils.c: Include target.h.
16122 (prepare_resume_reply): Change prototype to take a
16123 target_waitstatus. Adjust.
16125 * linux-low.c (linux_wait): Adjust to new target_ops->wait
16127 * spu-low.c (spu_wait): Adjust.
16128 * win32-low.c (enum target_waitkind, struct target_waitstatus):
16130 (win32_wait): Adjust.
16132 2009-04-01 Pedro Alves <pedro@codesourcery.com>
16134 * target.h (struct thread_resume): Delete leave_stopped member.
16135 (struct target_ops): Add a `n' argument to the `resume' callback.
16136 * server.c (start_inferior): Adjust.
16137 (handle_v_cont, myresume): Adjust.
16138 * linux-low.c (check_removed_breakpoint): Adjust to resume
16139 interface change, and to removed leave_stopped field.
16140 (resume_ptr): Delete.
16141 (struct thread_resume_array): New.
16142 (linux_set_resume_request): Add new `arg' parameter. Adjust to
16143 resume interface change.
16144 (linux_continue_one_thread, linux_queue_one_thread)
16145 (resume_status_pending_p): Check if the resume field is NULL
16146 instead of checking the leave_stopped member.
16147 (linux_resume): Adjust to the target resume interface change.
16148 * spu-low.c (spu_resume): Adjust to the target resume interface
16150 * win32-low.c (win32_detach, win32_resume): Ditto.
16152 2009-04-01 Pedro Alves <pedro@codesourcery.com>
16154 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
16156 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
16158 (linux_continue_one_thread): Only preserve the stepping flag if
16159 there's a pending breakpoint.
16161 2009-03-31 Pedro Alves <pedro@codesourcery.com>
16163 * server.c (main): After the inferior having exited, call
16164 remote_close before exiting gdbserver.
16166 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
16168 Fix size of FPSCR in Power 7 processors.
16169 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
16170 (PPC_FEATURE_HAS_DFP): New #define.
16171 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
16174 2009-03-23 Pedro Alves <pedro@codesourcery.com>
16176 * server.c (handle_query) Whitespace and formatting.
16178 2009-03-22 Pedro Alves <pedro@codesourcery.com>
16180 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
16181 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
16182 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
16183 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
16184 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
16185 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
16186 Makefile.in, configure.ac: Fix whitespace throughout.
16187 * configure: Regenerate.
16189 2009-03-22 Pedro Alves <pedro@codesourcery.com>
16191 * inferiors.c (find_inferior): Make it safe for the callback
16192 function to delete the currently iterated inferior.
16194 2009-03-22 Pedro Alves <pedro@codesourcery.com>
16196 * Makefile.in (linuw_low_h): Move higher.
16197 (thread-db.o): Depend on $(linux_low_h).
16199 2009-03-17 Pedro Alves <pedro@codesourcery.com>
16201 Rename "process" to "lwp" throughout.
16203 * linux-low.c (all_processes): Rename to...
16204 (all_lwps): ... this.
16205 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
16206 (add_process): Rename to ...
16207 (add_lwp): ... this. Adjust.
16208 (linux_create_inferior): Adjust.
16209 (linux_attach_lwp): Adjust.
16210 (linux_attach): Adjust.
16211 (linux_kill_one_process): Rename to ...
16212 (linux_kill_one_lwp): ... this. Adjust.
16213 (linux_kill): Adjust.
16214 (linux_detach_one_process): Rename to ...
16215 (linux_detach_one_lwp): ... this. Adjust.
16216 (linux_detach): Adjust.
16217 (check_removed_breakpoint): Adjust.
16218 (status_pending_p): Adjust.
16219 (linux_wait_for_process): Rename to ...
16220 (linux_wait_for_lwp): ... this. Adjust.
16221 (linux_wait_for_event): Adjust.
16222 (send_sigstop): Adjust.
16223 (wait_for_sigstop): Adjust.
16224 (stop_all_processes): Rename to ...
16225 (stop_all_lwps): ... this.
16226 (linux_resume_one_process): Rename to ...
16227 (linux_resume_one_lwp): ... this. Adjust.
16228 (linux_set_resume_request, linux_continue_one_thread)
16229 (linux_queue_one_thread, resume_status_pending_p)
16230 (usr_store_inferior_registers, regsets_store_inferior_registers)
16231 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
16233 * linux-low.h (get_process): Rename to ...
16234 (get_lwp): ... this. Adjust.
16235 (get_thread_process): Rename to ...
16236 (get_thread_lwp): ... this. Adjust.
16237 (get_process_thread): Rename to ...
16238 (get_lwp_thread): ... this. Adjust.
16239 (struct process_info): Rename to ...
16240 (struct lwp_info): ... this.
16241 (all_processes): Rename to ...
16242 (all_lwps): ... this.
16243 * proc-service.c (ps_lgetregs): Adjust.
16244 * thread-db.c (thread_db_create_event, find_one_thread)
16245 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
16247 2009-03-14 Pedro Alves <pedro@codesourcery.com>
16249 * server.c (handle_query): Handle "qAttached".
16251 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
16253 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
16254 GPLv3, update license URL.
16256 2009-03-01 Doug Evans <dje@google.com>
16258 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
16259 (server_h): Add gdb_signals.h.
16260 (signals.o): Update.
16261 * server.h (target_signal_from_host,target_signal_to_host_p)
16262 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
16264 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
16266 * remote-utils.c (getpkt): Also generate remote-debug
16267 information if noack_mode is set.
16269 2009-02-06 Pedro Alves <pedro@codesourcery.com>
16271 * server.c (handle_query): Report qXfer:siginfo:read and
16272 qXfer:siginfo:write as supported and handle them.
16273 * target.h (struct target_ops) <qxfer_siginfo>: New field.
16274 * linux-low.c (linux_xfer_siginfo): New.
16275 (linux_target_ops): Set it.
16277 2009-01-26 Pedro Alves <pedro@codesourcery.com>
16279 * server.c (gdbserver_usage): Mention --remote-debug.
16280 (main): Accept '--remote-debug' switch.
16282 2009-01-18 Doug Evans <dje@google.com>
16284 * regcache.c (new_register_cache): No need to check result of xcalloc.
16285 * server.c (handle_search_memory): Back out calls to xmalloc,
16286 result is checked and error is returned to user upon failure.
16287 (handle_query): Ditto. Add more checks for result of malloc.
16288 (handle_v_cont): Check result of malloc, report error back to
16290 (handle_v_run): Ditto. Call freeargv.
16291 * server.h (freeargv): Declare.
16292 * utils.c (freeargv): New fn.
16294 2009-01-15 Doug Evans <dje@google.com>
16296 * gdbreplay.c (perror_with_name): Make arg const char *.
16297 * server.h (target_signal_to_name): Make return type const char *.
16298 * thread-db.c (thread_db_err_str): Make return type const char *.
16299 * utils.c (perror_with_name): Make arg const char *.
16301 2009-01-14 Pedro Alves <pedro@codesourcery.com>
16303 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
16304 when handling a EXIT_PROCESS_DEBUG_EVENT.
16306 2009-01-06 Joel Brobecker <brobecker@adacore.com>
16308 * gdbreplay.c (gdbreplay_version): Update copyright year.
16309 * server.c (gdbserver_version): Likewise.
16311 2009-01-05 Doug Evans <dje@google.com>
16313 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
16314 (handle_extended_wait): Improve comment.
16316 2008-12-13 Doug Evans <dje@google.com>
16318 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
16319 * server.h (ATTR_MALLOC): New macro.
16320 (xmalloc,xcalloc,xstrdup): Declare.
16321 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
16322 * inferiors.c: Ditto.
16323 * linux-low.c: Ditto.
16324 * mem-break.c: Ditto.
16325 * regcache.c: Ditto.
16326 * remote-utils.c: Ditto.
16329 * win32-low.c: Ditto.
16331 2008-12-12 Doug Evans <dje@google.com>
16333 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
16334 in debugging printf.
16336 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
16338 2008-12-09 Doug Evans <dje@google.com>
16340 * linux-low.h (struct process_info): Delete member tid, unused.
16341 * thread-db.c (find_one_thread): Update.
16342 (maybe_attach_thread): Update.
16344 2008-12-02 Pedro Alves <pedro@codesourcery.com>
16346 * target.h (struct target_ops): Add qxfer_osdata member.
16347 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
16349 (linux_qxfer_osdata): New functions.
16350 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
16352 * server.c (handle_query): Handle "qXfer:osdata:read:".
16353 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
16354 (buffer_xml_printf): New functions.
16355 * server.h (struct buffer): New.
16356 (buffer_grow_str, buffer_grow_str0): New macros.
16357 (buffer_grow, buffer_free, buffer_init, buffer_finish)
16358 (buffer_xml_printf): Declare.
16360 2008-11-24 Doug Evans <dje@google.com>
16362 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
16364 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
16366 * server.c (handle_v_run): Always use the supplied argument list.
16368 2008-11-19 Bob Wilson <bob.wilson@acm.org>
16370 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
16371 (xtensa_regmap_table): Add entry for scompare1.
16373 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
16375 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
16376 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
16377 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
16378 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
16379 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
16380 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
16381 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
16382 XML target descriptions.
16383 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
16384 when inferior is running on an ISA 2.05 or later processor. Add
16385 special case to return offset for full 64-bit slot of FPSCR when
16388 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
16390 * Makefile.in (SFILES, clean): Added sparc64 files.
16391 (reg-sparc64.o, reg-sparc64.c): New.
16392 * configure.srv (sparc*-*-linux*): New configuration.
16393 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
16394 syscall arguments for SPARC.
16395 (regsets_store_inferior_registers): Likewise.
16396 * linux-sparc-low.c: New file.
16398 2008-10-21 Doug Evans <dje@google.com>
16400 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
16401 (READLINE_DIR,READLINE_DEP): Delete.
16402 (INTERNAL_CFLAGS): Update.
16403 (LINTFLAGS): Update.
16405 2008-10-10 Pedro Alves <pedro@codesourcery.com>
16407 * server.c (handle_v_run): If GDB didn't specify an argv, use the
16408 whole argv from the last run, not just argv[0].
16410 2008-09-08 Pedro Alves <pedro@codesourcery.com>
16412 * regcache.c (new_register_cache): Return NULL if the register
16413 cache size isn't known yet.
16414 (free_register_cache): Avoid dereferencing a NULL regcache.
16416 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
16418 * configure.srv: Merge MIPS and MIPS64.
16420 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
16422 * Makefile.in (uninstall): Apply $(EXEEXT) too.
16424 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
16426 * Makefile.in: Add required vsx dependencies.
16428 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
16429 Declare init_registers_powerpc_vsx32l.
16430 Declare init_registers_powerpc_vsx64l.
16431 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
16432 (ppc_arch_setup): Check for VSX in hwcap.
16433 (ppc_fill_vsxregset): New function.
16434 (ppc_store_vsxregset): New function.
16435 Add new VSX entry in regset_info target_regsets.
16437 * configure.srv: Add new VSX dependencies.
16439 2008-08-12 Pedro Alves <pedro@codesourcery.com>
16441 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
16442 (remote_open): Set or clear transport_is_reliable.
16443 (putpkt_binary): Don't expect acks in noack mode.
16444 (getpkt): Don't send ack/nac in noack mode.
16445 * server.c (handle_general_set): Handle QStartNoAckMode.
16446 (handle_query): If connected by tcp pass QStartNoAckMode+ in
16448 (main): Reset noack_mode on every connection.
16449 * server.h (noack_mode): Declare.
16451 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
16453 * Makefile.in (GDBREPLAY_OBS): New variable.
16454 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
16456 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
16457 Daniel Jacobowitz <dan@codesourcery.com>
16459 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
16460 (usr_store_inferior_registers): Likewise.
16461 (regsets_store_inferior_registers): Likewise.
16463 2008-07-31 Rolf Jansen <rj@surtec.com>
16464 Pedro Alves <pedro@codesourcery.com>
16466 * configure.ac: Check for memmem declaration.
16467 * server.c [HAVE_MALLOC_H]: Include malloc.h.
16468 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
16469 (disable_packet_qfThreadInfo): Unconditionally compile.
16470 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
16471 * configure, config.in: Regenerate.
16473 2008-07-28 Doug Kwan <dougkwan@google.com>
16475 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
16476 (linux_write_memory): Remove declaration of errno.
16478 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
16480 * linux-low.c (handle_extended_wait): Do not use "status"
16481 variable uninitialized.
16483 2008-07-07 Pedro Alves <pedro@codesourcery.com>
16485 * server.c (handle_v_attach): Inhibit reporting dll changes.
16487 2008-06-27 Pedro Alves <pedro@codesourcery.com>
16489 * remote-utils.c (prepare_resume_reply): If requested, don't
16490 output "thread:TID" in the T stop reply.
16492 * server.c (disable_packet_vCont, disable_packet_Tthread)
16493 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
16494 (handle_query): If requested, disable support for qC, qfThreadInfo
16496 (handle_v_requests): If requested, disable support for vCont.
16497 (gdbserver_show_disableable): New.
16498 (main): Handle --disable-packet and --disable-packet=LIST.
16500 * server.h (disable_packet_vCont, disable_packet_Tthread)
16501 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
16503 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
16505 * server.c (gdbserver_usage): Mention --version.
16507 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
16509 * Makefile.in (gdbreplay.o): New rule.
16511 2008-06-06 Joseph Myers <joseph@codesourcery.com>
16513 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
16514 message, not gdbserver.
16516 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
16517 Nathan Sidwell <nathan@codesourcery.com>
16518 Joseph Myers <joseph@codesourcery.com>
16520 * acinclude.m4: Include ../../config/acx.m4.
16521 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
16522 * configure, config.in: Regenerate.
16523 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
16524 * server.c (gdbserver_version): Print PKGVERSION.
16525 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
16526 (main): Adjust gdbserver_usage calls.
16527 * gdbreplay.c (version, host_name): Add declarations.
16528 (gdbreplay_version, gdbreplay_usage): New.
16529 (main): Accept --version and --help options.
16531 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
16533 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
16534 (arm_breakpoint_at): Handle Thumb.
16535 (the_low_target): Add comment.
16537 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
16539 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
16541 2008-05-09 Doug Evans <dje@google.com>
16543 * server.h (decode_search_memory_packet): Declare.
16544 * remote-utils.c (decode_search_memory_packet): New fn.
16545 * server.c (handle_search_memory_1): New fn.
16546 (handle_search_memory): New fn.
16547 (handle_query): Process qSearch:memory packets.
16549 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
16551 * regcache.c (registers_length): Remove.
16552 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
16553 full register packet.
16554 * regcache.h (registers_length): Remove prototype.
16555 * server.h (PBUFSIZ): Define to 16384.
16557 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
16559 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
16560 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
16561 powerpc-64l.o, and powerpc-altivec64l.o.
16562 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
16563 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
16564 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
16565 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
16566 rs6000/power-linux.xml, and rs6000/power64-linux.xml
16569 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
16570 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
16571 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
16572 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
16573 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
16574 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
16575 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
16576 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
16577 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
16578 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
16581 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
16582 (init_registers_powerpc_32l): ... this new prototype.
16583 (init_registers_powerpc_32): Remove, replace by ...
16584 (init_registers_powerpc_altivec32l): ... this new prototype.
16585 (init_registers_powerpc_e500): Remove, replace by ...
16586 (init_registers_powerpc_e500l): ... this new prototype.
16587 (init_registers_ppc64): Remove, replace by ...
16588 (init_registers_powerpc_64l): ... this new prototype.
16589 (init_registers_powerpc_64): Remove, replace by ...
16590 (init_registers_powerpc_altivec64l): ... this new prototype.
16591 (ppc_num_regs): Set to 73.
16592 (PT_ORIG_R3, PT_TRAP): Define if necessary.
16593 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
16594 (ppc_cannot_store_register): Handle orig_r3 and trap.
16595 (ppc_arch_setup): Update init_registers_... calls.
16596 (ppc_fill_gregset): Handle orig_r3 and trap.
16598 * inferiors.c (clear_inferiors): Reset current_inferior.
16600 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
16602 * acinclude.m4: Add override.m4.
16603 * configure: Regenerate.
16605 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
16607 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
16608 initial call to init_register_ppc64.
16610 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
16612 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
16613 single powerpc*-*-linux* case.
16614 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
16616 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
16618 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
16619 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
16621 * linux-ppc-low.c: Include <elf.h>.
16622 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
16623 (ppc_hwcap): New global variable.
16624 (ppc_regmap): Remove __SPE__ #ifdef sections.
16625 (ppc_regmap_e500): New global variable.
16626 (ppc_cannot_store_register): Update __SPE__ special case.
16627 (ppc_get_hwcap): New function.
16628 (ppc_arch_setup): Use it to determine whether inferior supports
16629 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
16630 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
16631 Do not access registers if target does not support AltiVec.
16632 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
16633 Do not access registers if target does not support SPE.
16634 (target_regsets): Unconditionally include AltiVec and SPE regsets.
16636 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
16638 * linux-low.c (disabled_regsets, num_regsets): New.
16639 (use_regsets_p): Delete.
16640 (linux_wait_for_process): Clear disabled_regsets.
16641 (regsets_fetch_inferior_registers): Check and set it.
16642 (regsets_store_inferior_registers): Likewise.
16643 (linux_fetch_registers, linux_store_registers): Do not use
16645 (initialize_low): Allocate disabled_regsets.
16647 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
16649 * Makefile.in (LIBOBJS): New.
16650 (OBS): Use LIBOBJS.
16651 (memmem.o): New rule.
16652 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
16653 * configure: Regenerated.
16655 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
16657 * server.c (handle_query): Never return "unsupported" for
16658 qXfer:features:read queries.
16660 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
16662 * server.c (get_features_xml): Fix inverted condition.
16663 (handle_query): Always support qXfer:feature:read.
16665 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
16667 * server.c (wrapper_argv): New.
16668 (start_inferior): Handle wrapper_argv. If set, expect an extra
16670 (gdbserver_usage): Document --wrapper.
16671 (main): Parse --wrapper.
16673 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
16675 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
16676 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
16677 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
16678 (ppc_set_pc): Likewise.
16679 (ppc_arch_setup): New function.
16680 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
16681 of collect_register.
16682 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
16684 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
16686 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
16687 instead of linux-ppc64-low.o.
16688 * linux-ppc64-low.c: Remove file.
16689 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
16690 (linux-ppc64-low.o): Remove rule.
16692 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
16693 (init_registers_powerpc_64): Likewise.
16694 (ppc_regmap): Conditionally define depending on __powerpc64__.
16695 (ppc_cannot_store_register): Do not special-case "fpscr" when
16696 compiled on __powerpc64__.
16697 (ppc_collect_ptrace_register): New function.
16698 (ppc_supply_ptrace_register): New function.
16699 (ppc_breakpoint): Change type to "unsigned int".
16700 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
16701 (the_low_target): Conditionally provide initializers for the
16702 arch_setup member depending on __powerpc64__. Install
16703 collect_ptrace_register and supply_ptrace_register members.
16705 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
16707 * regcache.h (gdbserver_xmltarget): Add extern declaration.
16708 * server.c (gdbserver_xmltarget): Define.
16709 (get_features_xml): Use it to replace "target.xml" and arch_string.
16711 * configure.srv: Remove srv_xmltarget. Add XML files that were
16712 mentioned there to srv_xmlfiles instead. Remove conditional tests
16713 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
16714 srv_xmlfiles and srv_regobj to include all possible choices.
16715 * configure.ac (srv_xmltarget): Remove.
16716 (srv_xmlfiles): Do not add "target.xml".
16717 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
16718 checks for supplementary target information.
16719 * configure: Regenerate.
16720 * Makefile.in (XML_TARGET): Remove.
16721 (target.xml): Remove rule.
16722 (clean): Do not clean up target.xml.
16723 (.PRECIOUS): Do not mention target.xml.
16725 * target.h (struct target_ops): Remove arch_string member.
16726 * linux-low.c (linux_arch_string): Remove.
16727 (linux_target_ops): Remove arch_string initializer.
16728 * linux-low.h (struct linux_target_ops): Remove arch_string member.
16729 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
16730 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
16731 * spu-low.c (spu_arch_string): Remove.
16732 (spu_target_ops): Remove arch_string initializer.
16733 * win32-low.c (win32_arch_string): Remove.
16734 (win32_target_ops): Remove arch_string initializer.
16735 * win32-low.h (struct win32_target_ops): Remove arch_string member.
16736 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
16737 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
16739 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
16741 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
16742 by collect_ptrace_register and supply_ptrace_register hooks.
16743 * linux-low.c (fetch_register): Use supply_ptrace_register callback
16744 instead of checking for the_low_target.left_pad_xfer.
16745 (usr_store_inferior_registers): Use collect_ptrace_register callback
16746 instead of checking for the_low_target.left_pad_xfer.
16748 * linux-s390-low.c (s390_collect_ptrace_register): New function.
16749 (s390_supply_ptrace_register): Likewise.
16750 (s390_fill_gregset): Call s390_collect_ptrace_register.
16751 (the_low_target): Update.
16753 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
16754 (ppc_supply_ptrace_register): Likewise.
16755 (the_low_target): Update.
16757 * linux-i386-low.c (the_low_target): Update.
16758 * linux-x86-64-low.c (the_low_target): Update.
16760 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
16762 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
16763 reg-s390.o and reg-s390x.o.
16765 * linux-low.c (new_inferior): New global variable.
16766 (linux_create_inferior, linux_attach): Set it.
16767 (linux_wait_for_process): Call the_low_target.arch_setup after the
16768 target has stopped for the first time.
16769 (initialize_low): Do not call the_low_target.arch_setup.
16771 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
16772 (s390_set_pc): Likewise.
16773 (s390_arch_setup): New function.
16774 (the_low_target): Use s390_arch_setup as arch_setup routine.
16776 * regcache.c (realloc_register_cache): New function.
16777 (set_register_cache): Call it for each existing regcache.
16779 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
16781 * server.h (init_registers): Remove prototype.
16783 * linux-low.h (struct linux_target_ops): Add arch_setup field.
16784 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
16785 instead of init_registers ().
16786 * linux-arm-low.c (init_registers_arm): Add prototype.
16787 (init_registers_arm_with_iwmmxt): Likewise.
16788 (the_low_target): Add initializer for arch_setup field.
16789 * linux-cris-low.c (init_registers_cris): Add prototype.
16790 (the_low_target): Add initializer for arch_setup field.
16791 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
16792 (the_low_target): Add initializer for arch_setup field.
16793 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
16794 (the_low_target): Add initializer for arch_setup field.
16795 * linux-ia64-low.c (init_registers_ia64): Add prototype.
16796 (the_low_target): Add initializer for arch_setup field.
16797 * linux-m32r-low.c (init_registers_m32r): Add prototype.
16798 (the_low_target): Add initializer for arch_setup field.
16799 * linux-m68k-low.c (init_registers_m68k): Add prototype.
16800 (the_low_target): Add initializer for arch_setup field.
16801 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
16802 (init_registers_mips64_linux): Likewise.
16803 (the_low_target): Add initializer for arch_setup field.
16804 * linux-ppc-low.c (init_registers_ppc): Add prototype.
16805 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
16806 (the_low_target): Add initializer for arch_setup field.
16807 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
16808 (init_registers_powerpc_64): Likewise.
16809 (the_low_target): Add initializer for arch_setup field.
16810 * linux-s390-low.c (init_registers_s390): Add prototype.
16811 (init_registers_s390x): Likewise.
16812 (the_low_target): Add initializer for arch_setup field.
16813 * linux-sh-low.c (init_registers_sh): Add prototype.
16814 (the_low_target): Add initializer for arch_setup field.
16815 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
16816 (the_low_target): Add initializer for arch_setup field.
16817 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
16818 (the_low_target): Add initializer for arch_setup field.
16820 * win32-low.h (struct win32_target_ops): Add arch_setup field.
16821 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
16822 instead of init_registers ().
16823 * win32-arm-low.c (init_registers_arm): Add prototype.
16824 (the_low_target): Add initializer for arch_setup field.
16825 * win32-i386-low.c (init_registers_i386): Add prototype.
16826 (the_low_target): Add initializer for arch_setup field.
16828 * spu-low.c (init_registers_spu): Add prototype.
16829 (initialize_low): Call initialie_registers_spu () instead of
16830 initialize_registers ().
16832 2008-02-19 Pedro Alves <pedro@codesourcery.com>
16834 * server.c (handle_v_requests): When handling the vRun and vAttach
16835 packets, if already debugging a process, don't kill it. Return an
16838 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
16840 * server.c (handle_query): Correct length check.
16842 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
16844 * win32-low.c (do_initial_child_stuff): Add process handle
16845 parameter. Set current_process_handle and current_process_id from the
16846 parameters. Clear globals.
16847 (win32_create_inferior): Don't set current_process_handle and
16848 current_process_id here. Instead pass them on the call to
16849 do_initial_child_stuff.
16850 (win32_attach): Likewise.
16851 (win32_clear_inferiors): New.
16852 (win32_kill): Don't close the current process handle or the
16853 current thread handle here. Instead call win32_clear_inferiors.
16854 (win32_detach): Don't open a new handle to the process. Call
16855 win32_clear_inferiors.
16856 (win32_join): Don't rely on current_process_handle; open a new
16857 handle using the process id.
16858 (win32_wait): Call win32_clear_inferiors when the inferior process
16861 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
16863 * server.c (monitor_show_help): Add "exit".
16865 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
16867 * Makefile.in (SFILES): Add linux-xtensa-low.c.
16868 (clean): Add reg-xtensa.c.
16869 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
16870 * configure.srv (xtensa*-*-linux*) New target.
16871 * linux-xtensa-low.c: New.
16872 * xtensa-xtregs.c: New.
16874 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
16876 * hostio.c: Don't include errno.h.
16877 (errno_to_fileio_errno): Move to hostio-errno.
16878 * hostio.c: (hostio_error): Remove the error parameter. Defer the
16879 error number outputting to the target->hostio_last_error callback.
16880 (hostio_packet_error): Use FILEIO_EINVAL directly.
16881 (handle_open, handle_pread, hostio_error, handle_unlink): Update
16882 calls to hostio_error.
16883 * hostio-errno.c: New.
16884 * server.h (hostio_last_error_from_errno): Declare.
16885 * target.h (target_ops): Add hostio_last_error member.
16886 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
16887 as hostio_last_error handler.
16888 * spu-low.c (spu_target_ops): Likewise.
16889 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
16890 (wince_hostio_last_error): New functions.
16891 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
16892 as hostio_last_error handler.
16893 (win32_target_ops) [!_WIN32_WCE]: Register
16894 hostio_last_error_from_errno as hostio_last_error handler.
16895 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
16896 (hostio-errno.o): New rule.
16897 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
16898 * configure.srv (srv_hostio_err_objs): New variable. Default to
16900 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
16901 * configure: Regenerate.
16903 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
16905 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
16906 (linux_kill, linux_detach): Clean up the process list.
16907 * remote-utils.c (remote_open): Improve port number parsing.
16908 (putpkt_binary, input_interrupt): Only send interrupts if the target
16910 * server.c (extended_protocol): Make static.
16911 (attached): Define earlier.
16912 (exit_requested, response_needed, program_argv): New variables.
16913 (target_running): New.
16914 (start_inferior): Clear attached here.
16915 (attach_inferior): Set attached here.
16916 (require_running): Define.
16917 (handle_query): Use require_running and target_running. Implement
16919 (handle_v_attach, handle_v_run): New.
16920 (handle_v_requests): Use require_running. Handle vAttach and vRun.
16921 (gdbserver_usage): Update.
16922 (main): Redo argument parsing. Handle --debug and --multi. Handle
16923 --attach along with other options or after the port. Save
16924 program_argv. Support no initial program. Resynchronize
16925 communication with GDB after an error. Handle "monitor exit".
16926 Use require_running and target_running. Always allow the extended
16927 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
16928 restart in extended mode.
16929 * README: Refer to the GDB manual. Update --attach usage.
16931 2007-12-20 Andreas Schwab <schwab@suse.de>
16933 * linux-low.c (STACK_SIZE): Define.
16934 (linux_tracefork_child): Use it. Use __clone2 on ia64.
16935 (linux_test_for_tracefork): Likewise.
16937 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
16939 * linux-low.c (linux_wait_for_event): Update messages. Do not
16940 reinsert auto-delete breakpoints.
16941 * mem-break.c (struct breakpoint): Change return type of handler to
16943 (set_breakpoint_at): Update handler type.
16944 (reinsert_breakpoint_handler): Return 1 instead of calling
16946 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
16948 (check_breakpoints): Delete auto-delete breakpoints and return 2.
16949 * mem-break.h (set_breakpoint_at): Update handler type.
16950 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
16951 * win32-low.c (auto_delete_breakpoint): New.
16952 (get_child_debug_event): Use it.
16954 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
16956 * configure.ac: Check for pread and pwrite.
16957 * hostio.c (handle_pread): Fall back to lseek and read.
16958 (handle_pwrite): Fall back to lseek and write.
16959 * config.in, configure: Regenerated.
16961 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
16963 * server.c (myresume): Add own_buf argument.
16964 (main): Update calls.
16966 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
16968 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
16969 * remote-utils.c (remote_open): Do not call disable_async_io.
16970 (block_async_io): Delete.
16971 (unblock_async_io): Make static.
16972 (initialize_async_io): New.
16973 * server.c (handle_v_cont): Handle async I/O here.
16974 (myresume): Likewise. Move other common resume tasks here...
16975 (main): ... from here. Call initialize_async_io. Disable async
16976 I/O before the main loop.
16977 * server.h (initialize_async_io): Declare.
16978 (block_async_io, unblock_async_io): Delete prototypes.
16979 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
16981 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
16983 * remote-utils.c (readchar): Allow binary data in received messages.
16985 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
16987 * win32-low.c (attaching): New global.
16988 (win32_create_inferior): Clear the `attaching' global.
16989 (win32_attach): Set the `attaching' global.
16990 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
16991 attaching. Only set a breakpoint at the entry point if not
16994 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
16996 * server.c (main): Don't report dll events on the initial
16997 connection on attaches.
16999 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17001 * server.c (main): Relax numerical bases supported for the pid of
17002 the --attach command line argument.
17004 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17006 * win32-low.c (win32_attach): Call OpenProcess before
17007 DebugActiveProcess, not after. Add last error output to error
17010 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17012 * win32-low.c (win32_get_thread_context)
17013 (win32_set_thread_context): New functions.
17014 (thread_rec): Use win32_get_thread_context.
17015 (continue_one_thread, win32_resume): Use win32_set_thread_context.
17016 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
17019 2007-12-03 Leo Zayas
17020 Pedro Alves <pedro_alves@portugalmail.pt>
17022 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
17024 (child_add_thread): Minor cleanup.
17025 (child_continue): Resume artificially suspended threads before
17026 calling ContinueDebugEvent.
17027 (suspend_one_thread): New.
17028 (fake_breakpoint_event): New.
17029 (get_child_debug_event): Change return type to int. Check here if
17030 gdb sent an interrupt request. If a soft interrupt was requested,
17031 fake a breakpoint event. Return 0 if there is no event to handle,
17033 (win32_wait): Don't check here if gdb sent an interrupt request.
17034 Ensure there is a valid event to handle.
17035 (win32_request_interrupt): Add soft interruption method as last
17038 2007-12-03 Leo Zayas
17039 Pedro Alves <pedro_alves@portugalmail.pt>
17041 * win32-low.h (win32_thread_info): Add descriptions to the
17042 structure members. Replace `suspend_count' counter by a
17044 * win32-low.c (thread_rec): Update condition of when to get the
17045 context from the inferior. Rely on ContextFlags being set if it
17046 has already been retrieved. Only suspend the inferior thread if
17047 we haven't already. Warn if that fails.
17048 (continue_one_thread): s/suspend_count/suspended/. Only call
17049 ResumeThread once. Warn if that fails.
17051 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
17053 * win32-low.c (win32_wait): Don't read from the inferior when it
17054 has already exited.
17056 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
17058 * Makefile.in (win32_low_h): New variable.
17059 (win32-low.o): Add dependency on $(win32_low_h).
17060 (win32-arm-low.o, win32-i386-low.o): New rules.
17062 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
17064 * hostio.c: Correct copyright year.
17066 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
17068 * Makefile.in (OBS): Add hostio.o.
17069 (hostio.o): New rule.
17070 * server.h (handle_vFile): Declare.
17071 * hostio.c: New file.
17072 * server.c (handle_v_requests): Take packet_len and new_packet_len
17073 for binary packets. Call handle_vFile.
17074 (main): Update call to handle_v_requests.
17076 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
17078 * linux-low.c: Include <sched.h>.
17080 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
17082 * linux-low.c (linux_tracefork_grandchild): New.
17083 (linux_tracefork_child): Use clone.
17084 (linux_test_for_tracefork): Use clone; allocate and free a stack.
17086 2007-10-31 Joel Brobecker <brobecker@adacore.com>
17088 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
17090 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
17092 * linux-low.c (handle_extended_wait): Handle unexpected signals.
17094 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
17096 * inferiors.c (change_inferior_id): Delete.
17097 (add_pid_to_list, pull_pid_from_list): New.
17098 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
17099 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
17100 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
17101 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
17102 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
17103 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
17104 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
17105 (using_threads): Always set to 1.
17106 (handle_extended_wait): New.
17107 (add_process): Do not set TID.
17108 (linux_create_inferior): Set must_set_ptrace_flags.
17109 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
17110 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
17111 (linux_thread_alive): Rename TID argument to LWPID.
17112 (linux_wait_for_process): Handle unknown processes. Do not use TID.
17113 (linux_wait_for_event): Do not use TID or check using_threads. Update
17114 call to dead_thread_notify. Call handle_extended_wait.
17115 (linux_create_inferior): Use PTRACE_SETOPTIONS.
17116 (send_sigstop): Delete sigstop_sent.
17117 (wait_for_sigstop): Avoid TID.
17118 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
17119 (linux_test_for_tracefork): New.
17120 (linux_lookup_signals): Use thread_db_active and
17121 linux_supports_tracefork_flag.
17122 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
17123 * linux-low.h (get_process_thread): Avoid TID.
17124 (struct process_ifo): Move thread_known and tid to the end. Remove
17126 (linux_attach_lwp, thread_db_init): Update prototypes.
17127 * server.h (change_inferior_id): Delete prototype.
17128 (add_pid_to_list, pull_pid_from_list): New prototypes.
17129 * thread-db.c (thread_db_use_events): New.
17130 (find_first_thread): Rename to...
17131 (find_one_thread): ...this. Update callers and messages. Do not
17132 call fatal. Check thread_db_use_events. Do not call
17133 change_inferior_id or new_thread_notify.
17134 (maybe_attach_thread): Update. Do not call new_thread_notify.
17135 (thread_db_init): Set thread_db_use_events. Check use_events.
17136 * utils.c (fatal, warning): Correct message prefix.
17138 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
17140 * Makefile.in (clean): Remove new files.
17141 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
17142 (powerpc-64.o, powerpc-64.c): New rules.
17143 * configure.srv: Use alternate register sets for powerpc64-*-linux*
17144 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
17146 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
17148 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
17149 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
17150 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
17151 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
17152 (target_regsets): Add AltiVec and SPE register sets.
17153 * configure.ac: Check for AltiVec and SPE.
17154 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
17155 (ppc_fill_vrregset, ppc_store_vrregset): New.
17156 (target_regsets): Add AltiVec register set.
17157 * configure: Regenerated.
17159 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
17161 * linux-low.c (O_LARGEFILE): Define.
17162 (linux_read_memory): Use /proc/PID/mem.
17163 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
17164 * configure, config.in: Regenerated.
17166 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
17168 * linux-low.c (linux_wait_for_event): Do not pass signals while
17171 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
17173 * win32-low.c (create_process): New.
17174 (win32_create_inferior): Use create_process instead of
17175 CreateProcess. If create_process failed retry appending an ".exe"
17176 suffix. Store the GetLastError result immediatelly after
17177 create_process calls and use it on the call to error.
17179 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
17181 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
17183 2007-08-23 Joel Brobecker <brobecker@adacore.com>
17185 * configure.ac: Switch license to GPLv3.
17187 2007-08-01 Michael Snyder <msnyder@access-company.com>
17189 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
17191 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
17193 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
17195 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
17196 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
17197 CloseToolhelp32Snapshot.
17198 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
17199 CloseToolhelp32Snapshot.
17201 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
17203 * server.c (main): Check for inferior exit before main loop.
17205 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
17207 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
17208 instead of on tmp_desc.
17210 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
17211 Daniel Jacobowitz <dan@codesourcery.com>
17213 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
17214 (add_thread): Minor cleanups.
17215 (clear_inferiors): Move lower in the file. Clear the DLL
17217 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
17218 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
17219 (xml_escape_text): New.
17220 * server.c (handle_query): Handle qXfer:libraries:read. Report it
17222 (handle_v_cont): Report errors.
17223 (gdbserver_version): Update.
17224 (main): Correct size of own_buf. Do not report initial DLL events.
17225 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
17226 (unloaded_dll, xml_escape_text): New.
17227 * win32-low.c (enum target_waitkind): Update comments.
17228 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
17229 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
17230 (win32_EnumProcessModules, win32_GetModuleInformation)
17231 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
17232 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
17233 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
17234 (win32_Module32First, win32_Module32Next, load_toolhelp)
17235 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
17236 (get_child_debug_event): Handle DLL events.
17237 (win32_wait): Likewise.
17239 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
17241 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
17242 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
17244 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
17246 * win32-low.c (handle_output_debug_string): Ignore event if not
17249 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
17251 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
17253 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
17255 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
17257 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
17259 * inferiors.c (change_inferior_id): Add comment.
17260 * linux-low.c (check_removed_breakpoint): Add an early
17261 prototype. Improve debug output.
17262 (linux_attach): Doc update.
17263 (linux_detach_one_process, linux_detach): Clean up before releasing
17265 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
17266 * linux-low.h (struct process_info): Doc improvement.
17267 * mem-break.c (delete_all_breakpoints): New.
17268 * mem-break.h (delete_all_breakpoints): New prototype.
17269 * thread-db.c (find_first_thread): New.
17270 (thread_db_create_event): Call it instead of
17271 thread_db_find_new_threads. Clean up unused variables.
17272 (maybe_attach_thread): Remove first thread handling.
17273 (thread_db_find_new_threads): Use find_first_thread.
17274 (thread_db_get_tls_address): Likewise.
17276 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
17278 * thread-db.c (thread_db_find_new_threads): Add prototype.
17279 (thread_db_create_event): Check for the main thread before adding
17281 (maybe_attach_thread): Only enable event reporting if TID == 0.
17282 (thread_db_get_tls_address): Check for new threads.
17284 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
17286 * linux-low.c (linux_create_inferior): Try execv before execvp.
17287 * spu-low.c (spu_create_inferior): Likewise.
17289 2007-06-13 Mike Frysinger <vapier@gentoo.org>
17291 * linux-low.c (linux_create_inferior): Change execv to execvp.
17292 * spu-low.c (spu_create_inferior): Likewies.
17294 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
17296 * Makefile.in (clean): Clean new files instead of deleted ones.
17297 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
17298 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
17300 * configure.srv: Specify XML files and new regformats for MIPS and
17302 * linux-mips-low.c (mips_num_regs): Set to only used registers.
17303 (mips_regmap): Do not fetch $0. Remove unused registers. Add
17304 an entry for the restart register.
17305 (mips_cannot_fetch_register, mips_cannot_store_register)
17306 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
17307 register names to match the XML descriptions.
17308 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
17309 restart register instead of $0.
17311 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
17312 Markus Deuling <deuling@de.ibm.com>
17314 * remote-utils.c (decode_xfer_write): New function.
17315 * server.h (decode_xfer_write): Add prototype.
17316 * server.c (handle_query): Add PACKET_LEN argument. Support
17317 qXfer:spu:read and qXfer:spu:write packets.
17318 (main): Pass packet_len to handle_query.
17319 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
17320 * target.h (target_ops): Add qxfer_spu.
17322 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
17324 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
17325 accessing non-seekable spufs files.
17327 2007-05-16 Markus Deuling <deuling@de.ibm.com>
17329 * server.c (handle_query): Add reply for qC packet.
17331 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17332 Leo Zayas <lerele@champenstudios@com>
17334 * server.h (check_remote_input_interrupt_request): New function.
17335 * remote_utils.c (INVALID_DESCRIPTOR): New define.
17336 (remote_desc): Initialize with INVALID_DESCRIPTOR.
17337 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
17338 (check_remote_input_interrupt_request): New function.
17339 * server.h (check_remote_input_interrupt_request): Declare.
17340 * win32-low.c (winapi_DebugBreakProcess,
17341 winapi_GenerateConsoleCtrlEvent): New typedefs.
17342 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
17344 (win32_wait): Check for remote interrupt request
17345 with check_remote_input_interrupt_request.
17346 (win32_request_interrupt): New function.
17347 (win32_target_op): Set request_interrupt to win32_request_interrupt.
17349 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17351 * win32-low.c (debug_registers_changed,
17352 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
17353 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
17354 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
17355 (thread_rec): Get context using the low target.
17356 (child_add_thread): Call thread_added on the low target,
17357 which does the same thing.
17359 (do_initial_child_stuff): Remove debug registers references.
17360 Set context using the low target. Resume threads after
17361 setting the contexts.
17362 (child_continue): Remove dead variable. Remove debug
17363 registers references.
17364 (child_fetch_inferior_registers): Go through the low target.
17365 (do_child_store_inferior_registers): Remove.
17366 (child_store_inferior_registers): Go through the low target.
17367 (win32_resume): Remove debug registers references.
17368 Set context using the low target.
17369 (handle_exception): Change return type to void. Don't record
17370 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
17371 first chance exception.
17372 (get_child_debug_event): Change return type to void. Remove
17373 goto loop. Always return after waiting for debug event.
17374 (win32_wait): Convert to switch statement. Handle spurious
17377 * win32-i386-low.c (debug_registers_changed,
17378 debug_registers_used): New.
17379 (initial_stuff): Rename to ...
17380 (i386_initial_stuff): ... this. Clear debug registers
17382 (store_debug_registers): Delete.
17383 (i386_get_thread_context): New.
17384 (load_debug_registers): Delete.
17385 (i386_set_thread_context): New.
17386 (i386_thread_added): New.
17387 (single_step): Rename to ...
17388 (i386_single_step): ... this.
17389 (do_fetch_inferior_registers): Rename to ...
17390 (i386_fetch_inferior_register): ... this.
17391 (i386_store_inferior_register): New.
17392 (the_low_target): Adapt to new interface.
17394 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
17395 (arm_get_thread_context): New.
17396 (arm_set_thread_context): New.
17398 (do_fetch_inferior_registers): Rename to ...
17399 (arm_fetch_inferior_register): ... this.
17400 (arm_store_inferior_register): New.
17401 (arm_wince_breakpoint): Reimplement as unsigned long.
17402 (arm_wince_breakpoint_len): Define.
17403 (the_low_target): Adapt to new interface.
17405 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
17406 load_debug_registers. Add get_thread_context, set_thread_context,
17407 thread_added and store_inferior_register. Rename
17408 fetch_inferior_registers to fetch_inferior_register.
17409 (regptr): Remove declaration.
17411 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17413 * linux-low.c (linux_detach): Change return type to int. Return 0.
17414 * spu-low.c (spu_detach): Likewise.
17416 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17418 * target.h (target_ops): Change return type of detach to int.
17420 (join_inferior): New.
17421 * server.c (main): Don't skip detach support on mingw32.
17422 If the inferior doesn't support detaching return error.
17423 Call join_inferior instead of using waitpid.
17424 * linux-low.c (linux_join): New.
17425 (linux_target_op): Add linux_join.
17426 * spu-low.c (spu_join): New.
17427 (spu_target_ops): Add spu_join.
17428 * win32-low.c (win32_detach): Adapt to new interface.
17429 Reopen current_process_handle before detaching. Issue a child
17430 resume before detaching.
17432 (win32_target_op): Add win32_join.
17434 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17436 * win32-low.c (win32-attach): Fix return value.
17437 * target.h (target_ops): Describe ATTACH return values.
17439 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17441 * win32-low.c (GETPROCADDRESS): Define.
17442 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
17443 (winapi_DebugSetProcessKillOnExit): Likewise.
17444 (win32_create_inferior): Force usage of ansi CreateProcessA.
17445 (win32_attach): Use GETPROCADDRESS.
17446 (win32_detach): Likewise.
17448 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
17450 * win32-low.c (win32_wait): Don't use WSTOPSIG.
17452 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
17454 * win32-low.c: Commit leftover changes from 2007-03-29.
17456 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
17458 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
17459 fields short instead of int. Add explicit padding.
17460 (i387_cache_to_fsave): Remove unnecessary casts.
17461 (i387_fsave_to_cache): Doc fix.
17462 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
17464 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
17466 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
17467 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
17469 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
17471 * configure.srv (arm*-*-mingw32ce*): Move near the other
17474 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
17476 * configure.ac: Add errno checking.
17477 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
17478 sys/file.h and malloc.h.
17479 (AC_CHECK_DECLS): Add perror.
17480 (srv_mingwce): Handle.
17481 * configure.srv (i[34567]86-*-cygwin*): Add
17482 win32-i386-low.o to srv_tgtobj.
17483 (i[34567]86-*-mingw*): Likewise.
17484 (arm*-*-mingw32ce*): Add case.
17485 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
17486 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
17487 [__MINGW32CE__] (strerror): New function.
17488 [__MINGW32CE__] (errno): Define to GetLastError.
17489 [__MINGW32CE__] (COUNTOF): New macro.
17490 (remote_open): Remove extra close call.
17491 * mem-break.c (delete_breakpoint_at): New function.
17492 * mem-break.h (delete_breakpoint_at): Declare.
17493 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
17494 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
17495 [USE_WIN32API] (read, write): Add char* casts.
17496 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
17497 * server.h: Include wincecompat.h on Windows CE.
17498 [HAVE_ERRNO_H]: Check.
17499 (perror): Declare if not declared.
17500 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
17501 (perror_with_name): Remove errno declaration.
17502 * wincecompat.h: New.
17503 * wincecompat.c: New.
17504 * win32-low.h: New.
17505 * win32-arm-low.c: New.
17506 * win32-i386-low.c: New.
17507 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
17508 (OUTMSG2): Make it safe.
17510 (COUNTOF): New macro.
17511 (NUM_REGS): Get it from the low target.
17512 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
17513 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
17514 (thread_rec): Let low target handle debug registers.
17515 (child_add_thread): Likewise.
17516 (child_init_thread_list): Likewise.
17517 (continue_one_thread): Likewise.
17519 (do_child_fetch_inferior_registers): Move to ...
17520 * win32-i386-low.c: ... here, and rename to ...
17521 (do_fetch_inferior_registers): ... this.
17522 * win32-low.c (child_fetch_inferior_registers):
17523 Go through the low target.
17524 (do_child_store_inferior_registers): Use regptr.
17525 (strwinerror): New function.
17526 (win32_create_inferior): Handle Windows CE.
17527 Use strwinerror instead of strerror on Windows error
17528 codes. Add program to the error output.
17529 Don't close the main thread handle on Windows CE.
17530 (win32_attach): Use coredll.dll on Windows CE.
17531 (win32_kill): Close current process and current
17533 (win32_detach): Use coredll.dll on Windows CE.
17534 (win32_resume): Let low target handle debug registers, and
17536 (handle_exception): Add/Remove initial breakpoint. Avoid
17537 non-existant WSTOPSIG on Windows CE.
17538 (win32_read_inferior_memory): Cast to remove warning.
17539 (win32_arch_string): Go through the low target.
17540 (initialize_low): Call set_breakpoint_data with the low
17541 target's breakpoint.
17542 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
17543 FOP_REGNUM, mappings): Move to ...
17544 * win32-i386-low.c: ... here.
17545 * win32-low.c (win32_thread_info): Move to ...
17546 * win32-low.h: ... here.
17547 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
17548 win32-arm-low.c and wincecompat.c.
17549 (all:): Add $EXEEXT.
17550 (install-only:): Likewise.
17551 (gdbserver:): Likewise.
17552 (gdbreplay:): Likewise.
17553 * config.in: Regenerate.
17554 * configure: Regenerate.
17556 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
17558 * win32-low.c: Rename typedef thread_info to
17559 win32_thread_info throughout.
17561 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
17563 * win32-i386-low.c: Rename to ...
17564 * win32-low.c: ... this.
17565 * configure.srv: Replace win32-i386-low.o with win32-low.o.
17566 * Makefile.in: Likewise.
17568 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
17570 * remote-utils.c (monitor_output): Constify msg parameter.
17571 * server.h (monitor_output): Likewise.
17572 * win32-i386-low.c (handle_output_debug_string): New.
17573 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
17574 handle_output_debug_string.
17575 (get_child_debug_event): Likewise.
17577 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
17579 * server.c (main): Correct strtoul check.
17581 2007-03-27 Jon Ringle <jon@ringle.org>
17583 * linux-low.c: Check __ARCH_HAS_MMU__ also.
17585 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
17587 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
17589 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
17591 * terminal.h: Check HAVE_SGTTY_H.
17593 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
17595 * remote-utils.c (remote_open): Print out the assigned port number.
17597 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
17599 * remote-utils.c (monitor_output): New function.
17600 * server.c (debug_threads): Define here.
17601 (monitor_show_help): New function.
17602 (handle_query): Handle qRcmd.
17603 (main): Do not handle 'd' packet.
17604 * server.h (debug_threads, remote_debug, monitor_output): Declare.
17605 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
17608 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
17610 * Makefile.in (EXEEXT): New.
17611 (clean): Use $(EXEEXT).
17613 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
17615 * target.h (target_ops): Rename send_signal to request_interrupt,
17616 and remove enum target_signal parameter.
17617 * linux-low.c (linux_request_interrupt): Rename from
17618 linux_send_signal, and always send SIGINT.
17619 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
17620 and always send SIGINT.
17621 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
17623 (input_interrupt): Likewise.
17625 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
17627 * server.c (get_features_xml): Check if target implemented
17629 * win32-i386-low.c (win32_arch_string): New.
17630 (win32_target_ops): Add win32_arch_string as arch_string member.
17632 2007-02-22 Markus Deuling <deuling@de.ibm.com>
17634 * spu-low.c (spu_arch_string): New.
17635 (spu_target_ops): Add spu_arch_string.
17637 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
17639 * remote-utils.c: Remove HAVE_TERMINAL_H check.
17640 * configure.ac: Do not check for terminal.h.
17641 * configure, config.in: Regenerated.
17643 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
17645 * Makefile.in (OBS): Add $(XML_BUILTIN).
17646 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
17648 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
17649 (arm-with-iwmmxt.c): New.
17650 * config.in, configure: Regenerate.
17651 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
17652 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
17653 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
17654 (arm*-*-linux*): Add iWMMXt and regset support.
17655 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
17656 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
17657 (arm_store_wmmxregset, target_regsets): New.
17658 * server.c (get_features_xml): Take annex argument. Check builtin
17660 (handle_query): Handle multiple annexes.
17662 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
17664 * remote-utils.c [USE_WIN32API] (read, write): Define.
17665 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
17668 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
17670 * linux-i386-low.c (the_low_target): Set arch_string.
17671 * linux-x86-64-low.c (the_low_target): Likewise.
17672 * linux-low.c (linux_arch_string): New.
17673 (linux_target_ops): Add it.
17674 * linux-low.h (struct linux_target_ops): Add arch_string.
17675 * server.c (write_qxfer_response): Use const void * for DATA.
17676 (get_features_xml): New.
17677 (handle_query): Handle qXfer:features:read. Report it for qSupported.
17678 * target.h (struct target_ops): Add arch_string method.
17680 2007-01-03 Denis Pilat <denis.pilat@st.com>
17681 Daniel Jacobowitz <dan@codesourcery.com>
17683 * linux-low.c (linux_kill): Handle being called with no threads.
17684 * win32-i386-low.c (win32_kill): Likewise.
17685 (get_child_debug_event): Clear current_process_handle.
17687 2006-12-30 Denis PILAT <denis.pilat@st.com>
17688 Daniel Jacobowitz <dan@codesourcery.com>
17690 * remote-utils.c (remote_open): Check the type of specified
17691 serial port devices before opening them.
17692 * server.c (main): Kill the inferior if an error occurs during
17693 the first remote_open.
17695 2006-12-05 Markus Deuling <deuling@de.ibm.com>
17697 * README: Update supported targets.
17699 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
17701 * Makefile.in (clean): Remove reg-mips64.c.
17702 (reg-mips64.c, reg-mips64.o): New rules.
17703 * configure.srv: Handle mips64. Include regset support for mips.
17704 * linux-mips-low.c (union mips_register): New.
17705 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
17706 (mips_breakpoint, mips_breakpoint_at): Use int.
17707 (mips_collect_register, mips_supply_register)
17708 (mips_collect_register_32bit, mips_supply_register_32bit)
17709 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
17710 (mips_store_fpregset, target_regsets): New.
17711 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
17713 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
17715 * configure.srv: Add target "spu*-*-*".
17716 * Makefile.in (clean): Remove reg-spu.c.
17717 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
17718 * spu-low.c: New file.
17720 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
17722 * configure.ac: Correct td_thr_tls_get_addr test.
17723 * configure: Regenerated.
17725 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
17727 * linux-low.c (linux_wait_for_event): Reformat. Use the
17728 pass_signals array.
17729 * remote-utils.c (decode_address_to_semicolon): New.
17730 * server.c (pass_signals, handle_general_set): New.
17731 (handle_query): Mention QPassSignals for qSupported.
17732 (main): Call handle_general_set.
17733 * server.h (pass_signals, decode_address_to_semicolon): New.
17735 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
17737 * server.c (handle_query): Correct error handling for read_auxv.
17739 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
17741 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
17742 and srv_linux_thread_db to yes.
17743 * linux-s390-low.c (s390_fill_gregset): New function.
17744 (target_regsets): Define data structure.
17746 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
17748 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
17749 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
17750 * config.in, configure: Regenerated.
17751 * inferiors.c (gdb_id_to_thread): New function.
17752 (gdb_id_to_thread_id): Use it.
17753 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
17754 * linux-low.h (struct process_info): Add th member.
17755 (thread_db_get_tls_address): New prototype.
17756 * remote-utils.c (decode_address): Make non-static.
17757 * server.c (handle_query): Handle qGetTLSAddr.
17758 * server.h (gdb_id_to_thread, decode_address): New prototypes.
17759 * target.h (struct target_ops): Add get_tls_address.
17760 * thread-db.c (maybe_attach_thread): Save the thread handle.
17761 (thread_db_get_tls_address): New.
17763 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
17765 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
17766 (linux_resume_one_process): Take a siginfo_t *. Update all
17767 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
17768 (struct pending_signals): Add a siginfo_t.
17769 (linux_wait_for_process): Always set last_status.
17770 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
17771 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
17772 * linux-low.h (struct process_info): Add last_status.
17774 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
17776 * remote-utils.c (try_rle): New function.
17777 (putpkt_binary): Use it.
17779 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
17781 * Makefile.in (clean): Clean reg-x86-64-linux.c.
17782 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
17783 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
17784 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
17785 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
17788 2006-08-08 Richard Sandiford <richard@codesourcery.com>
17790 * server.c (terminal_fd): New variable.
17791 (old_foreground_pgrp): Likewise.
17792 (restore_old_foreground_pgrp): New function.
17793 (start_inferior): Record the terminal file descriptor in terminal_fd
17794 and its original foreground group in old_foreground_pgrp. Register
17795 restore_old_foreground_pgrp with atexit().
17797 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
17799 * server.c (handle_query): Correct qPart to qXfer.
17801 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
17803 * configure.ac: Check for more headers which are missing on
17804 Windows. Automatically supply -lwsock32 and USE_WIN32API.
17805 * configure.srv: Add Cygwin and mingw32.
17806 * remote-utils.c: Don't include headers unconditionally which
17807 are missing on mingw32. Include <winsock.h> for mingw32.
17808 (remote_open): Adjust for mingw32 support. Flush
17809 standard error after writing to it.
17810 (remote_close, putpkt_binary, input_interrupt, block_async_io)
17811 (unblock_async_io, enable_async_io, disable_async_io)
17812 (readchar, getpkt): Update for Winsock support.
17813 (prepare_resume_reply): Expect a protocol signal number.
17814 * server.c: Disable <sys/wait.h> on mingw32.
17815 (start_inferior): Adjust for mingw32 support. Flush
17816 standard error after writing to it.
17817 (attach_inferior): Likewise. Use protocol signal
17819 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
17821 * win32-i386-low.c: New file.
17822 * Makefile.in (XM_CLIBS): Set.
17823 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
17824 (win32-i386-low.o): New dependency rule.
17825 * linux-low.c (linux_wait): Use target signal numbers.
17826 * target.h (struct target_ops): Doc fix.
17827 * server.h (target_signal_to_name): New prototype.
17828 * gdbreplay.c: Don't include headers unconditionally which
17829 are missing on mingw32. Include <winsock.h> for mingw32.
17830 (remote_close, remote_open): Adjust for Winsock support.
17831 * configure, config.in: Regenerated.
17833 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
17835 * server.c (decode_xfer_read, write_qxfer_response): New.
17836 (handle_query): Take a packet length argument. Handle
17837 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
17838 the qSupported response.
17839 (main): Update call to handle_query.
17841 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
17843 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
17844 (putpkt_binary): Renamed from putpkt and adjusted for binary
17846 (putpkt): New wrapper for putpkt_binary.
17847 (readchar): Don't mask off the high bit.
17848 (decode_X_packet): New function.
17849 * server.c (main): Call putpkt_binary if a handler sets the packet
17850 length. Save the length of the incoming packet. Handle 'X'.
17851 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
17853 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
17855 * server.c (handle_query): Handle qSupported.
17857 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
17859 * remote-utils.c (all_symbols_looked_up): New variable.
17860 (look_up_one_symbol): Check it.
17861 * server.h (look_up_one_symbol): New declaration.
17862 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
17864 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
17866 * Makefile.in (linux-arm-low.o): Update dependencies.
17867 * linux-arm-low.c: Include "gdb_proc_service.h".
17868 (PTRACE_GET_THREAD_AREA): Define.
17869 (ps_get_thread_area): New function.
17871 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
17873 * configure.srv (m68k*-*-uclinux*): New target.
17874 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
17875 (linux_resume_one_process): Remove extraneous cast.
17876 (linux_read_offsets): New.
17877 (linux_target_op): Add linux_read_offsets on mmuless systems.
17878 * server.c (handle_query): Add qOffsets logic.
17879 * target.h (struct target_ops): Add read_offsets.
17881 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
17883 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
17884 (PTRACE_GET_THREAD_AREA): Define.
17885 (ps_get_thread_area): New function.
17886 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
17887 (linux-x86-64-low.o): Update.
17889 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
17891 * configure.ac: Remove checks for prfpregset_t.
17892 * gdb_proc_service.h: New file.
17893 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
17894 new "gdb_proc_service.h".
17895 * proc-service.c: Likewise.
17896 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
17897 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
17898 * Makefile.in (gdb_proc_service_h): Updated.
17899 * configure, config.in: Regenerated.
17901 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
17903 * remote-utils.c (prepare_resume_reply): Move declaration
17904 of gdb_id_from_wait to the top of the block.
17906 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
17908 * linux-low.c (regsets_store_inferior_registers): Read the regset
17909 from the target before filling it.
17911 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
17913 * server.c (attach_inferior): Return SIGTRAP for a successful
17916 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
17918 * Makefile.in (OBS): Add version.o.
17919 (STAGESTUFF): Delete.
17920 (version.o): Add dependencies.
17921 (version.c): Replace rule.
17922 (clean): Remove version.c.
17923 * server.c (gdbserver_version): New.
17924 (gdbserver_usage): Use printf.
17925 (main): Handle --version and --help.
17926 * server.h (version, host_name): Add declarations.
17928 2005-12-23 Eli Zaretskii <eliz@gnu.org>
17940 * linux-x86-64-low.c:
17942 * linux-s390-low.c:
17943 * linux-ppc64-low.c:
17945 * linux-mips-low.c:
17946 * linux-m68k-low.c:
17947 * linux-m32r-low.c:
17950 * linux-ia64-low.c:
17951 * linux-i386-low.c:
17952 * linux-crisv32-low.c:
17964 * gdbserver.1: Add (C) after Copyright. Update the FSF
17967 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
17969 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
17970 (arm_breakpoint_at): Recognize both breakpoints.
17971 (the_low_target): Use the correct breakpoint instruction.
17973 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
17975 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
17976 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
17977 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
17978 (the_low_target): Update.
17980 2005-10-25 Andreas Schwab <schwab@suse.de>
17982 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
17984 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
17985 (ia64_num_regs): Reduce to 462.
17987 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
17989 * acinclude.m4: Correct quoting.
17990 * aclocal.m4: Regenerated.
17992 Suggested by SZOKOVACS Robert <szo@ies.hu>:
17993 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
17994 (thread_db_init): Call thread_db_err_str.
17995 * configure.ac: Check for TD_VERSION.
17996 * config.in, configure: Regenerated.
17998 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
18000 * server.h (error, fatal, warning): Add ATTR_FORMAT.
18002 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
18004 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
18005 is not available. Define HAVE_PTRACE_GETREGS if it is.
18006 * config.in, configure: Regenerated.
18007 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
18008 * linux-i386-low.c, linux-m68k-low.c: Update to use
18009 HAVE_PTRACE_GETREGS.
18010 * linux-low.c (regsets_fetch_inferior_registers)
18011 (regsets_store_inferior_registers): Only return 0 if we processed
18013 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
18014 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
18016 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
18018 * inferiors.c (struct thread_info): Add gdb_id.
18019 (add_thread): Add gdb_id argument.
18020 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
18021 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
18022 calls to add_thread.
18023 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
18024 * server.c (handle_query): Use thread_to_gdb_id.
18025 (handle_v_cont, main): Use gdb_id_to_thread_id.
18026 * server.h (add_thread): Update prototype.
18027 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
18030 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
18032 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
18033 left-padded registers.
18034 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
18035 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
18037 2005-07-01 Steve Ellcey <sje@cup.hp.com>
18039 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
18040 * configure: Regenerate.
18041 * config.in: Regenerate.
18042 * server.h (NEED_DECLARATION_STRERROR):
18043 Replace with !HAVE_DECL_STRERROR.
18045 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
18047 * linux-low.c (linux_wait, linux_send_signal): Don't test
18048 an unsigned long variable for > 0 if it could be MAX_ULONG.
18049 * server.c (myresume): Likewise.
18050 * target.c (set_desired_inferior): Likewise.
18052 2005-06-13 Mark Kettenis <kettenis@gnu.org>
18054 * configure.ac: Simplify and improve check for socklen_t.
18055 * configure, config.in: Regenerate.
18057 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
18059 * acconfig.h: Remove.
18060 * configure.ac: Add a test for socklen_t. Use three-argument
18061 AC_DEFINE throughout.
18062 * config.in: Regenerated using autoheader 2.59.
18063 * configure: Regenerated.
18065 * gdbreplay.c (socklen_t): Provide a default.
18066 (remote_open): Use socklen_t.
18067 * remote-utils.c (socklen_t): Provide a default.
18068 (remote_open): Use socklen_t.
18069 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
18072 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
18074 * linux-low.c (linux_read_memory, linux_write_memory)
18075 (linux_read_auxv): Likewise.
18076 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
18077 (check_mem_write): Likewise.
18078 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
18080 * regcache.c (struct inferior_rgcache_data, registers_to_string)
18081 (registers_from_string, register_data): Likewise.
18082 * server.c (handle_query, main): Likewise.
18083 * server.h (convert_ascii_to_int, convert_int_to_ascii)
18084 (decode_M_packet): Likewise.
18085 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
18086 * target.h (struct target_ops): Update read_memory, write_memory,
18088 (read_inferior_memory, write_inferior_memory): Update.
18089 * linux-low.h (struct linux_target_ops): Change type of breakpoint
18090 to unsigned char *.
18091 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
18092 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
18093 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
18094 linux-s390-low.c, linux-sh-low.c: Update for changes in
18095 read_inferior_memory and the_low_target->breakpoint.
18097 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
18099 * Makefile.in (SFILES): Add linux-ppc64-low.c.
18100 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
18101 * configure.srv: Add powerpc64-*-linux*.
18102 * linux-ppc64-low.c: New file.
18104 2005-05-23 Orjan Friberg <orjanf@axis.com>
18106 * linux-cris-low.c: New file with support for CRIS.
18107 * linux-crisv32-low.c: Ditto for CRISv32.
18108 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
18109 (clean): Add reg-cris.c and reg-crisv32.c.
18110 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
18111 reg-crisv32.o, and reg-crisv32.c to make rules.
18112 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
18113 recognized targets.
18115 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
18117 * linux-low.c (fetch_register): Ensure buffer size is a multiple
18118 of sizeof (PTRACE_XFER_TYPE).
18119 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
18121 2005-05-12 Orjan Friberg <orjanf@axis.com>
18123 * target.h (struct target_ops): Add insert_watchpoint,
18124 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
18125 pointers for hardware watchpoint support.
18126 * linux-low.h (struct linux_target_ops): Ditto.
18127 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
18128 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
18129 to linux_target_ops.
18130 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
18132 * server.c (main): Recognize 'Z' and 'z' packets.
18134 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
18136 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
18137 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
18138 (the_low_target): Add new members.
18140 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
18142 * proc-service.c (ps_lgetregs): Search all_processes instead of
18145 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
18147 * server.c (start_inferior): Change return type to int.
18148 (attach_inferior): Change sigptr to int *.
18149 (handle_v_cont, handle_v_requests): Change signal to int *.
18150 (main): Change signal to int.
18152 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
18154 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
18155 * configure.srv: Add m32r*-*-linux*.
18156 * linux-m32r-low.c: New file.
18158 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
18160 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
18162 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
18164 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
18165 Take unsigned long arguments for PIDs.
18166 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
18167 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
18168 (wait_for_sigstop, linux_resume_one_process)
18169 (regsets_fetch_inferior_registers, linux_send_signal)
18170 (linux_read_auxv): Likewise. Update the types of variables holding
18171 PIDs. Update format string specifiers.
18172 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
18173 * remote-utils.c (prepare_resume_reply): Likewise.
18174 * server.c (cont_thread, general_thread, step_thread)
18175 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
18177 (handle_query): Update format specifiers.
18178 (handle_v_cont, main): Use strtoul for thread IDs.
18179 * server.h (struct inferior_list_entry): Use unsigned long for ID.
18180 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
18181 (general_thread, step_thread, thread_from_wait)
18182 (old_thread_from_wait): Update.
18183 * target.h (struct thread_resume): Use unsigned long for THREAD.
18184 (struct target_ops): Use unsigned long for arguments to attach and
18187 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
18189 * acinclude.m4: Include bfd/bfd.m4 directly.
18190 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
18191 <agriffis@toolchain.org>.
18192 * aclocal.m4, configure: Regenerated.
18194 2005-01-07 Andrew Cagney <cagney@gnu.org>
18196 * configure.ac: Rename configure.in, require autoconf 2.59.
18197 * configure: Re-generate.
18199 2004-12-08 Daniel Jacobowitz <dan@debian.org>
18201 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
18202 LIBS when finished.
18203 * aclocal.m4: Regenerated.
18204 * configure: Regenerated.
18206 2004-11-21 Andreas Schwab <schwab@suse.de>
18208 * linux-m68k-low.c (m68k_num_gregs): Define.
18209 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
18210 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
18211 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
18212 (m68k_breakpoint_at): New. Add to the_low_target.
18214 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
18215 srv_linux_thread_db to yes.
18217 2004-10-20 Joel Brobecker <brobecker@gnat.com>
18219 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
18220 (ARCH_SET_FS): Likewise.
18221 (ARCH_GET_FS): Likewise.
18222 (ARCH_GET_GS): Likewise.
18224 2004-10-16 Daniel Jacobowitz <dan@debian.org>
18226 * linux-i386-low.c (ps_get_thread_area): New.
18227 * linux-x86-64-low.c (ps_get_thread_area): New.
18228 * linux-low.c: Include <sys/syscall.h>.
18229 (linux_kill_one_process): Don't kill the first thread here.
18230 (linux_kill): Kill the first thread here.
18231 (kill_lwp): New function.
18232 (send_sigstop, linux_send_signal): Use it.
18233 * proc-service.c: Clean up #ifdefs.
18234 (fpregset_info): Delete.
18235 (ps_lgetregs): Update and enable implementation.
18236 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
18238 * remote-utils.c (struct sym_cache, symbol_cache): New.
18239 (input_interrupt): Print a clearer message.
18240 (async_io_enabled): New variable.
18241 (enable_async_io, disable_async_io): Use it. Update comments.
18242 (look_up_one_symbol): Use the symbol cache.
18243 * thread-db.c (thread_db_look_up_symbols): New function.
18244 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
18246 2004-10-16 Daniel Jacobowitz <dan@debian.org>
18248 * configure.in: Test for -rdynamic.
18249 * configure: Regenerated.
18250 * Makefile (INTERNAL_LDFLAGS): New.
18251 (gdbserver, gdbreplay): Use it.
18253 2004-09-02 Andrew Cagney <cagney@gnu.org>
18255 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
18257 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
18259 * linux-low.c (linux_wait): Clear all_processes list also.
18261 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
18263 * linux-low.c: Include <errno.h>. Remove extern declaration of
18266 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
18268 * gdbreplay.c, server.h, utils.c: Update copyright years.
18270 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
18272 * server.c (main): Print child status or termination signal from
18273 variable 'signal', not 'sig'.
18275 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
18277 * linux-low.c (linux_read_memory): Change return type to
18278 int. Check for and return error from ptrace().
18279 * target.c (read_inferior_memory): Change return type to int. Pass
18280 back return status from the_target->read_memory().
18281 * target.h (struct target_ops): Adapt *read_memory() prototype.
18283 (read_inferior_memory): Adapt prototype.
18284 * server.c (main): Return an error packet if
18285 read_inferior_memory() returns an error.
18287 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
18289 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
18290 Unify with other clean targets.
18292 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
18294 * server.c (handle_v_cont): Call set_desired_inferior.
18296 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
18298 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
18300 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
18302 * linux-low.c (linux_wait): Unblock async I/O.
18303 (linux_resume): Block and enable async I/O.
18304 * remote-utils.c (block_async_io, unblock_async_io): New functions.
18305 * server.h (block_async_io, unblock_async_io): Add prototypes.
18307 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
18309 * remote-utils.c (remote_open): Print a status notice after
18310 opening a TCP port.
18311 * server.c (attach_inferior): Print a status notice after
18314 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
18316 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
18318 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
18320 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
18322 * server.c, target.h: Update copyright years.
18324 2004-02-25 Roland McGrath <roland@redhat.com>
18326 * target.h (struct target_ops): New member `read_auxv'.
18327 * server.c (handle_query): Handle qPart:auxv:read: query using that.
18328 * linux-low.c (linux_read_auxv): New function.
18329 (linux_target_ops): Initialize `read_auxv' member to that.
18331 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
18333 Committed by Jim Blandy <jimb@redhat.com>.
18335 * linux-s390-low.c (s390_num_regs): Update.
18336 (s390_regmap): Remove control registers. Use __s390x__ predefine
18337 instead of GPR_SIZE to distiguish s390 and s390x targets.
18339 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
18341 * linux-low.c: Update copyright year.
18342 (check_removed_breakpoint): Clear pending_is_breakpoint.
18343 (linux_set_resume_request, linux_queue_one_thread)
18344 (resume_status_pending_p): New functions.
18345 (linux_continue_one_thread): Use process->resume.
18346 (linux_resume): Only resume threads if there are no pending events.
18347 * linux-low.h (struct process_info): Add resume request
18350 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
18352 * regcache.c (new_register_cache): Clear the allocated register
18353 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
18355 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
18357 * linux-low.c (linux_resume): Take a struct thread_resume *
18359 (linux_wait): Update call.
18360 (resume_ptr): New static variable.
18361 (linux_continue_one_thread): Renamed from
18362 linux_continue_one_process. Use resume_ptr.
18363 (linux_resume): Use linux_continue_one_thread.
18364 * server.c (handle_v_cont, handle_v_requests): New functions.
18365 (myresume): New function.
18366 (main): Handle 'v' case.
18367 * target.h (struct thread_resume): New type.
18368 (struct target_ops): Change argument of "resume" to struct
18370 (myresume): Delete macro.
18372 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
18374 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
18375 (uninstall): Support DESTDIR.
18377 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
18379 * configure.srv: Add xscale*linux copy of arm*linux entry.
18381 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
18383 * linux-arm-low.c (arm_reinsert_addr): New function.
18384 (the_low_target): Add arm_reinsert_addr.
18386 2003-07-08 Mark Kettenis <kettenis@gnu.org>
18388 * mem-break.c: Remove whitespace at end of file.
18390 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
18392 * configure.in: Check whether we need to prototype strerror.
18393 * server.h: Optionally prototype strerror.
18394 * gdbreplay.c (perror_with_name): Use strerror.
18395 * linux-low.c (linux_attach_lwp): Use strerror.
18396 * utils.c (perror_with_name): Use strerror.
18397 * config.in, configure: Regenerated.
18399 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
18401 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
18402 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
18404 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
18406 * Makefile.in (SFILES): Update.
18407 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
18408 low-sun3.c: Remove files.
18410 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
18412 * linux-low.c: Move comment to linux_thread_alive where it belonged.
18413 (linux_detach_one_process, linux_detach): New functions.
18414 (linux_target_ops): Add linux_detach.
18415 * server.c (main): Handle 'D' packet.
18416 * target.h (struct target_ops): Add "detach" member.
18417 (detach_inferior): Define.
18419 2003-06-13 Mark Kettenis <kettenis@gnu.org>
18421 From Kelley Cook <kelleycook@wideopenwest.com>:
18422 * configure.srv: Accept i[34567]86 variants.
18424 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
18426 * linux-low.c (linux_wait_for_event): Correct comment typos.
18427 (linux_resume_one_process): Call check_removed_breakpoint.
18428 (linux_send_signal): New function.
18429 (linux_target_ops): Add linux_send_signal.
18430 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
18432 * target.h (struct target_ops): Add send_signal.
18434 2003-05-29 Jim Blandy <jimb@redhat.com>
18436 * linux-low.c (usr_store_inferior_registers): Transfer buf in
18437 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
18438 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
18439 away part of the register's value.
18441 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
18443 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
18444 (linux_wait_for_event, linux_init_signals): Likewise.
18446 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
18448 * configure.in: Check for stdlib.h.
18449 * configure: Regenerated.
18450 * config.in: Regenerated.
18452 2003-01-04 Andreas Schwab <schwab@suse.de>
18454 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
18456 2003-01-02 Andrew Cagney <ac131313@redhat.com>
18458 * Makefile.in: Remove obsolete code.
18460 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
18462 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
18463 defined(PT_FPR0_HI).
18465 2002-11-17 Stuart Hughes <seh@zee2.com>
18467 * linux-arm-low.c (arm_num_regs): Increase.
18468 (arm_regmap): Include status register.
18470 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
18472 * linux-low.c (register_addr): Remove incorrect -1 check.
18474 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
18476 * linux-low.c (linux_create_inferior): Call setpgid. Return
18478 (unstopped_p, linux_signal_pid): Remove.
18479 (linux_target_ops): Remove linux_signal_pid.
18480 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
18481 global instead of target method.
18482 * target.h (struct target_ops): Remove signal_pid. Update comment
18483 for create_inferior.
18484 * server.c (signal_pid): New variable.
18485 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
18486 gdbserver. Set the child to be the foreground process group.
18487 (attach_inferior): Set signal_pid.
18489 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
18491 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
18493 2002-08-20 Jim Blandy <jimb@redhat.com>
18495 * Makefile.in (LDFLAGS): Allow the configure script to establish a
18498 2002-08-01 Andrew Cagney <cagney@redhat.com>
18500 * Makefile.in: Make chill references obsolete.
18502 2002-07-24 Kevin Buettner <kevinb@redhat.com>
18504 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
18505 * configure: Regenerate.
18506 * config.in: Regenerate.
18508 2002-07-09 David O'Brien <obrien@FreeBSD.org>
18510 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
18511 (perror_with_name, remote_close, remote_open, expect, play): Static.
18513 2002-07-04 Michal Ludvig <mludvig@suse.cz>
18515 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
18516 byte offsets instead of an array of indexes.
18517 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
18519 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
18521 * regcache.c: Add comment.
18523 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
18525 * thread-db.c: New file.
18526 * proc-service.c: New file.
18527 * acinclude.m4: New file.
18528 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
18529 proc-service.o, and thread-db.o.
18530 (linux-low.o): Add USE_THREAD_DB.
18531 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
18532 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
18533 * aclocal.m4: Regenerated.
18534 * config.in: Regenerated.
18535 * configure: Regenerated.
18536 * configure.in: Check for proc_service.h, sys/procfs.h,
18537 thread_db.h, and linux/elf.h headrs.
18538 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
18539 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
18540 Check for -lthread_db and thread support.
18541 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
18542 PowerPC, and SuperH.
18543 * i387-fp.c: Constify arguments.
18544 * i387-fp.h: Likewise.
18545 * inferiors.c: (struct thread_info): Renamed from
18546 `struct inferior_info'. Remove PID member. Use generic inferior
18547 list header. All uses updated.
18548 (inferiors, signal_pid): Removed.
18549 (all_threads): New variable.
18550 (get_thread): Define.
18551 (add_inferior_to_list): New function.
18552 (for_each_inferior): New function.
18553 (change_inferior_id): New function.
18554 (add_inferior): Removed.
18555 (remove_inferior): New function.
18556 (add_thread): New function.
18557 (free_one_thread): New function.
18558 (remove_thread): New function.
18559 (clear_inferiors): Use for_each_inferior and free_one_thread.
18560 (find_inferior): New function.
18561 (find_inferior_id): New function.
18562 (inferior_target_data): Update argument type.
18563 (set_inferior_target_data): Likewise.
18564 (inferior_regcache_data): Likewise.
18565 (set_inferior_regcache_data): Likewise.
18566 * linux-low.c (linux_bp_reinsert): Remove.
18567 (all_processes, stopping_threads, using_thrads)
18568 (struct pending_signals, debug_threads, pid_of): New.
18569 (inferior_pid): Replace with macro.
18570 (struct inferior_linux_data): Remove.
18571 (get_stop_pc, add_process): New functions.
18572 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
18573 Use add_process and add_thread.
18574 (linux_attach_lwp): New function, based on old linux_attach. Use
18575 add_process and add_thread. Set stop_expected for new threads.
18576 (linux_attach): New function.
18577 (linux_kill_one_process): New function.
18578 (linux_kill): Kill all LWPs.
18579 (linux_thread_alive): Use find_inferior_id.
18580 (check_removed_breakpoints, status_pending_p): New functions.
18581 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
18582 Update. Use WNOHANG. Wait for cloned processes also. Update process
18583 struct for the found process.
18584 (linux_wait_for_event): New function.
18585 (linux_wait): Use it. Support LWPs.
18586 (send_sigstop, wait_for_sigstop, stop_all_processes)
18587 (linux_resume_one_process, linux_continue_one_process): New functions.
18588 (linux_resume): Support LWPs.
18589 (REGISTER_RAW_SIZE): Remove.
18590 (fetch_register): Use register_size instead. Call supply_register.
18591 (usr_store_inferior_registers): Likewise. Call collect_register.
18592 Fix recursive case.
18593 (regsets_fetch_inferior_registers): Improve error message.
18594 (regsets_store_inferior_registers): Add debugging.
18595 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
18596 (unstopped_p, linux_signal_pid): New functions.
18597 (linux_target_ops): Add linux_signal_pid.
18598 (linux_init_signals): New function.
18599 (initialize_low): Call it. Initialize using_threads.
18600 * regcache.c (inferior_regcache_data): Add valid
18602 (get_regcache): Fetch registers lazily. Add fetch argument
18603 and update all callers.
18604 (regcache_invalidate_one, regcache_invalidate): New
18606 (new_register_cache): Renamed from create_register_cache.
18607 Return the new regcache.
18608 (free_register_cache): Change argument to a void *.
18609 (registers_to_string, registers_from_string): Call get_regcache
18610 with fetch flag set.
18611 (register_data): Make static. Pass fetch flag to get_regcache.
18612 (supply_register): Call get_regcache with fetch flag clear.
18613 (collect_register): Call get_regcache with fetch flag set.
18614 (collect_register_as_string): New function.
18615 * regcache.h: Update.
18616 * remote-utils.c (putpkt): Flush after debug output and use
18618 Handle input interrupts while waiting for an ACK.
18619 (input_interrupt): Use signal_pid method.
18620 (getpkt): Flush after debug output and use stderr.
18621 (outreg): Use collect_register_as_string.
18622 (new_thread_notify, dead_thread_notify): New functions.
18623 (prepare_resume_reply): Check using_threads. Set thread_from_wait
18624 and general_thread.
18625 (look_up_one_symbol): Flush after debug output.
18626 * server.c (step_thread, server_waiting): New variables.
18627 (start_inferior): Don't use signal_pid. Update call to mywait.
18628 (attach_inferior): Update call to mywait.
18629 (handle_query): Handle qfThreadInfo and qsThreadInfo.
18630 (main): Don't fetch/store registers explicitly. Use
18631 set_desired_inferior. Support proposed ``Hs'' packet. Update
18633 * server.h: Update.
18634 (struct inferior_list, struct_inferior_list_entry): New.
18635 * target.c (set_desired_inferior): New.
18636 (write_inferior_memory): Constify.
18637 (mywait): New function.
18638 * target.h: Update.
18639 (struct target_ops): New signal_pid method.
18640 (mywait): Removed macro, added prototype.
18642 * linux-low.h (regset_func): Removed.
18643 (regset_fill_func, regset_store_func): New.
18644 (enum regset_type): New.
18645 (struct regset_info): Add type field. Use new operation types.
18646 (struct linux_target_ops): stop_pc renamed to get_pc.
18647 Add decr_pc_after_break and breakpoint_at.
18648 (get_process, get_thread_proess, get_process_thread)
18649 (strut process_info, all_processes, linux_attach_lwp)
18650 (thread_db_init): New.
18652 * linux-arm-low.c (arm_get_pc, arm_set_pc,
18653 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
18654 (the_low_target): Add new members.
18655 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
18656 (i386_store_fpxregset): Constify.
18657 (target_regsets): Add new kind identifier.
18658 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
18659 (i386_set_pc): Add debugging.
18660 (i386_breakpoint_at): New function.
18661 (the_low_target): Add new members.
18662 * linux-mips-low.c (mips_get_pc, mips_set_pc)
18663 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
18664 (mips_breakpoint_at): New.
18665 (the_low_target): Add new members.
18666 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
18667 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
18668 (the_low_target): Add new members.
18669 * linux-sh-low.c (sh_get_pc, sh_set_pc)
18670 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
18671 (the_low_target): Add new members.
18672 * linux-x86-64-low.c (target_regsets): Add new kind
18675 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
18677 From Martin Pool <mbp@samba.org>:
18678 * server.c (gdbserver_usage): New function.
18681 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
18683 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
18684 stop_at -> stop_pc.
18686 2002-05-04 Andrew Cagney <ac131313@redhat.com>
18688 * Makefile.in: Remove obsolete code.
18690 2002-04-24 Michal Ludvig <mludvig@suse.cz>
18692 * linux-low.c (regsets_fetch_inferior_registers),
18693 (regsets_store_inferior_registers): Removed cast to int from
18695 * regcache.h: Added declaration of struct inferior_info.
18697 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
18699 * inferiors.c (struct inferior_info): Add regcache_data.
18700 (add_inferior): Call create_register_cache.
18701 (clear_inferiors): Call free_register_cache.
18702 (inferior_regcache_data, set_inferior_regcache_data): New functions.
18703 * regcache.c (struct inferior_regcache_data): New.
18704 (registers): Remove.
18705 (get_regcache): New function.
18706 (create_register_cache, free_register_cache): New functions.
18707 (set_register_cache): Don't initialize the register cache here.
18708 (registers_to_string, registers_from_string, register_data): Call
18710 * regcache.h: Add prototypes.
18711 * server.h: Likewise.
18713 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
18715 * mem-break.c: New file.
18716 * mem-break.h: New file.
18717 * Makefile.in: Add mem-break.o rule; update server.h
18719 * inferiors.c (struct inferior_info): Add target_data
18721 (clear_inferiors): Free target_data member if set.
18722 (inferior_target_data, set_inferior_target_data): New functions.
18723 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
18724 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
18725 * linux-low.c (linux_bp_reinsert): New variable.
18726 (struct inferior_linux_data): New.
18727 (linux_create_inferior): Use set_inferior_target_data.
18728 (linux_attach): Likewise. Call add_inferior.
18729 (linux_wait_for_one_inferior): New function.
18730 (linux_wait): Call it.
18731 (linux_write_memory): Add const.
18732 (initialize_low): Call set_breakpoint_data.
18733 * linux-low.h (struct linux_target_ops): Add breakpoint
18735 * server.c (attach_inferior): Remove extra add_inferior
18737 * server.h: Include mem-break.h. Update inferior.c
18739 * target.c (read_inferior_memory)
18740 (write_inferior_memory): New functions.
18741 * target.h (read_inferior_memory)
18742 (write_inferior_memory): Change macros to prototypes.
18743 (struct target_ops): Update comments. Add const to write_memory
18746 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
18748 * linux-low.c (usr_store_inferior_registers): Support
18749 registers which are allowed to fail to store.
18750 * linux-low.h (linux_target_ops): Likewise.
18751 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
18752 (ppc_cannot_store_register): FPSCR may not be storable.
18754 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
18756 * server.h: Include <string.h> if HAVE_STRING_H.
18757 * ChangeLog: Correct paths in last ChangeLog entry.
18759 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
18761 * linux-low.h: Remove obsolete prototypes.
18762 (struct linux_target_ops): New.
18763 (extern the_low_target): New.
18764 * linux-low.c (num_regs, regmap): Remove declarations.
18765 (register_addr): Use the_low_target explicitly.
18766 (fetch_register): Likewise.
18767 (usr_fetch_inferior_registers): Likewise.
18768 (usr_store_inferior_registers): Likewise.
18769 * linux-arm-low.c (num_regs): Remove.
18770 (arm_num_regs): Define.
18771 (arm_regmap): Renamed from regmap, made static.
18772 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
18774 (arm_cannot_store_register): Renamed from cannot_store_register,
18776 (the_low_target): New.
18777 * linux-i386-low.c (num_regs): Remove.
18778 (i386_num_regs): Define.
18779 (i386_regmap): Renamed from regmap, made static.
18780 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
18782 (i386_cannot_store_register): Renamed from cannot_store_register,
18784 (the_low_target): New.
18785 * linux-ia64-low.c (num_regs): Remove.
18786 (ia64_num_regs): Define.
18787 (ia64_regmap): Renamed from regmap, made static.
18788 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
18790 (ia64_cannot_store_register): Renamed from cannot_store_register,
18792 (the_low_target): New.
18793 * linux-m68k-low.c (num_regs): Remove.
18794 (m68k_num_regs): Define.
18795 (m68k_regmap): Renamed from regmap, made static.
18796 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
18798 (m68k_cannot_store_register): Renamed from cannot_store_register,
18800 (the_low_target): New.
18801 * linux-mips-low.c (num_regs): Remove.
18802 (mips_num_regs): Define.
18803 (mips_regmap): Renamed from regmap, made static.
18804 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
18806 (mips_cannot_store_register): Renamed from cannot_store_register,
18808 (the_low_target): New.
18809 * linux-ppc-low.c (num_regs): Remove.
18810 (ppc_num_regs): Define.
18811 (ppc_regmap): Renamed from regmap, made static.
18812 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
18814 (ppc_cannot_store_register): Renamed from cannot_store_register,
18816 (the_low_target): New.
18817 * linux-s390-low.c (num_regs): Remove.
18818 (s390_num_regs): Define.
18819 (s390_regmap): Renamed from regmap, made static.
18820 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
18822 (s390_cannot_store_register): Renamed from cannot_store_register,
18824 (the_low_target): New.
18825 * linux-sh-low.c (num_regs): Remove.
18826 (sh_num_regs): Define.
18827 (sh_regmap): Renamed from regmap, made static.
18828 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
18830 (sh_cannot_store_register): Renamed from cannot_store_register,
18832 (the_low_target): New.
18833 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
18834 (the_low_target): New.
18836 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
18838 * Makefile.in: Add stamp-h target.
18839 * configure.in: Create stamp-h.
18840 * configure: Regenerated.
18842 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
18844 * inferiors.c: New file.
18845 * target.c: New file.
18846 * target.h: New file.
18847 * Makefile.in: Add target.o and inferiors.o. Update
18849 * linux-low.c (inferior_pid): New static variable,
18850 moved from server.c.
18851 (linux_create_inferior): Renamed from create_inferior.
18852 Call add_inferior. Return 0 on success instead of a PID.
18853 (linux_attach): Renamed from myattach.
18854 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
18855 (linux_thread_alive): Renamed from mythread_alive.
18856 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
18858 (linux_resume): Renamed from myresume. Add missing ``return 0''.
18859 (regsets_store_inferior_registers): Correct error message.
18860 Add missing ``return 0''.
18861 (linux_fetch_registers): Renamed from fetch_inferior_registers.
18862 (linux_store_registers): Renamed from store_inferior_registers.
18863 (linux_read_memory): Renamed from read_inferior_memory.
18864 (linux_write_memory): Renamed from write_inferior_memory.
18865 (linux_target_ops): New structure.
18866 (initialize_low): Call set_target_ops ().
18867 * remote-utils.c (unhexify): New function.
18868 (hexify): New function.
18869 (input_interrupt): Send signals to ``signal_pid''.
18870 * server.c (inferior_pid): Remove.
18871 (start_inferior): Update create_inferior call.
18872 (attach_inferior): Call add_inferior.
18873 (handle_query): New function.
18874 (main): Call handle_query for `q' packets.
18875 * server.h: Include "target.h". Remove obsolete prototypes.
18876 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
18878 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
18880 * Makefile.in: Add WARN_CFLAGS. Update configury
18882 * configure.in: Check for <string.h>
18883 * configure: Regenerate.
18884 * config.in: Regenerate.
18885 * gdbreplay.c: Include needed system headers.
18886 (remote_open): Remove strchr prototype.
18887 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
18888 * regcache.c (supply_register): Change buf argument to const void *.
18889 (supply_register_by_name): Likewise.
18890 (collect_register): Change buf argument to void *.
18891 (collect_register_by_name): Likewise.
18892 * regcache.h: Add missing prototypes.
18893 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
18894 * server.c (handle_query): New function.
18895 (attached): New static variable, moved out of main.
18896 (main): Quiet longjmp clobber warnings.
18897 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
18898 * utils.c (error): Remove NORETURN.