1 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3 Turn the 'get_pc' and 'set_pc' linux target ops into methods
4 of linux_process_target.
6 * linux-low.h (struct linux_target_ops): Remove the ops.
7 (class linux_process_target) <low_supports_breakpoints>
10 * linux-low.cc (supports_breakpoints): Turn into...
11 (linux_process_target::low_supports_breakpoints): ...this.
12 (linux_process_target::low_get_pc): Define.
13 (linux_process_target::low_set_pc): Define.
15 Update the callers below.
17 (linux_process_target::get_pc)
18 (linux_process_target::save_stop_reason)
19 (linux_process_target::maybe_move_out_of_jump_pad)
20 (linux_process_target::wait_1)
21 (linux_process_target::resume_one_lwp_throw)
22 (linux_process_target::resume)
23 (linux_process_target::proceed_all_lwps)
24 (linux_process_target::read_pc)
25 (linux_process_target::write_pc)
27 * linux-x86-low.cc (class linux_process_target)
28 <low_supports_breakpoints>
30 <low_set_pc>: Declare.
31 (x86_target::low_supports_breakpoints): Define.
32 (x86_get_pc): Turn into...
33 (x86_target::low_get_pc): ...this.
34 (x86_set_pc): Turn into...
35 (x86_target::low_set_pc): ...this.
36 (the_low_target): Remove the op fields.
37 * linux-arm-low.cc (class arm_target)
38 <low_supports_breakpoints>
40 <low_set_pc>: Declare.
41 (arm_target::low_supports_breakpoints)
42 (arm_target::low_get_pc)
43 (arm_target::low_set_pc): Define.
44 (the_low_target): Remove the op fields.
45 * linux-bfin-low.cc (class bfin_target)
46 <low_supports_breakpoints>
48 <low_set_pc>: Declare.
49 (bfin_target::low_supports_breakpoints)
50 (bfin_target::low_get_pc)
51 (bfin_target::low_set_pc): Define.
52 (the_low_target): Remove the op fields.
53 * linux-cris-low.cc (class cris_target)
54 <low_supports_breakpoints>
56 <low_set_pc>: Declare.
57 (cris_target::low_supports_breakpoints)
58 (cris_target::low_get_pc)
59 (cris_target::low_set_pc): Define.
60 (the_low_target): Remove the op fields.
61 * linux-crisv32-low.cc (class crisv32_target)
62 <low_supports_breakpoints>
64 <low_set_pc>: Declare.
65 (crisv32_target::low_supports_breakpoints)
66 (crisv32_target::low_get_pc)
67 (crisv32_target::low_set_pc): Define.
68 (the_low_target): Remove the op fields.
69 * linux-m32r-low.cc (class m32r_target)
70 <low_supports_breakpoints>
72 <low_set_pc>: Declare.
73 (m32r_target::low_supports_breakpoints)
74 (m32r_target::low_get_pc)
75 (m32r_target::low_set_pc): Define.
76 (the_low_target): Remove the op fields.
77 * linux-m68k-low.cc (class m68k_target)
78 <low_supports_breakpoints>
80 <low_set_pc>: Declare.
81 (m68k_target::low_supports_breakpoints)
82 (m68k_target::low_get_pc)
83 (m68k_target::low_set_pc): Define.
84 (the_low_target): Remove the op fields.
85 * linux-nios2-low.cc (class nios2_target)
86 <low_supports_breakpoints>
88 <low_set_pc>: Declare.
89 (nios2_target::low_supports_breakpoints)
90 (nios2_target::low_get_pc)
91 (nios2_target::low_set_pc): Define.
92 (the_low_target): Remove the op fields.
93 * linux-sh-low.cc (class sh_target)
94 <low_supports_breakpoints>
96 <low_set_pc>: Declare.
97 (sh_target::low_supports_breakpoints)
98 (sh_target::low_get_pc)
99 (sh_target::low_set_pc): Define.
100 (the_low_target): Remove the op fields.
101 * linux-xtensa-low.cc (class xtensa_target)
102 <low_supports_breakpoints>
104 <low_set_pc>: Declare.
105 (xtensa_target::low_supports_breakpoints)
106 (xtensa_target::low_get_pc)
107 (xtensa_target::low_set_pc): Define.
108 (the_low_target): Remove the op fields.
109 * linux-sparc-low.cc (class sparc_target)
110 <low_supports_breakpoints>
111 <low_get_pc>: Declare.
112 (sparc_target::low_supports_breakpoints)
113 (sparc_target::low_get_pc): Define.
114 (the_low_target): Remove the op fields.
115 * linux-tile-low.cc (class tile_target)
116 <low_supports_breakpoints>
118 <low_set_pc>: Declare.
119 (tile_target::low_supports_breakpoints)
120 (tile_target::low_get_pc)
121 (tile_target::low_set_pc): Define.
122 (the_low_target): Remove the op fields.
123 * linux-aarch64-low.cc (class aarch64_target)
124 <low_supports_breakpoints>
126 <low_set_pc>: Declare.
127 (aarch64_target::low_supports_breakpoints): Define.
128 (aarch64_get_pc): Turn into...
129 (aarch64_target::low_get_pc): ...this.
130 (aarch64_set_pc): Turn into...
131 (aarch64_target::low_set_pc): ...this.
132 (the_low_target): Remove the op fields.
133 * linux-mips-low.cc (class mips_target)
134 <low_supports_breakpoints>
136 <low_set_pc>: Declare.
137 (mips_target::low_supports_breakpoints): Define.
138 (mips_get_pc): Turn into...
139 (mips_target::low_get_pc): ...this.
140 (mips_set_pc): Turn into...
141 (mips_target::low_set_pc): ...this.
142 (the_low_target): Remove the op fields.
143 * linux-ppc-low.cc (class ppc_target)
144 <low_supports_breakpoints>
146 <low_set_pc>: Declare.
147 (ppc_target::low_supports_breakpoints): Define.
148 (ppc_get_pc): Turn into...
149 (ppc_target::low_get_pc): ...this.
150 (ppc_set_pc): Turn into...
151 (ppc_target::low_set_pc): ...this.
152 (the_low_target): Remove the op fields.
153 * linux-riscv-low.cc (class riscv_target)
154 <low_supports_breakpoints>
156 <low_set_pc>: Declare.
157 (riscv_target::low_supports_breakpoints): Define.
158 (riscv_get_pc): Turn into...
159 (riscv_target::low_get_pc): ...this.
160 (riscv_set_pc): Turn into...
161 (riscv_target::low_set_pc): ...this.
162 (the_low_target): Remove the op fields.
163 * linux-s390-low.cc (class s390_target)
164 <low_supports_breakpoints>
166 <low_set_pc>: Declare.
167 (s390_target::low_supports_breakpoints): Define.
168 (s390_get_pc): Turn into...
169 (s390_target::low_get_pc): ...this.
170 (s390_set_pc): Turn into...
171 (s390_target::low_set_pc): ...this.
172 (the_low_target): Remove the op fields.
173 * linux-tic6x-low.cc (class tic6x_target)
174 <low_supports_breakpoints>
176 <low_set_pc>: Declare.
177 (tic6x_target::low_supports_breakpoints): Define.
178 (tic6x_get_pc): Turn into...
179 (tic6x_target::low_get_pc): ...this.
180 (tic6x_set_pc): Turn into...
181 (tic6x_target::low_set_pc): ...this.
182 (the_low_target): Remove the op fields.
184 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
186 Turn some more static methods in linux-low into private methods
187 of linux_process_target.
189 * linux-low.cc (get_pc): Turn into...
190 (linux_process_target::get_pc): ...this.
191 (save_stop_reason): Turn into...
192 (linux_process_target::save_stop_reason): ...this.
193 (thread_still_has_status_pending_p): Turn into...
194 (linux_process_target::thread_still_has_status_pending): ...this.
195 (status_pending_p_callback): Turn into...
196 (linux_process_target::status_pending_p_callback): ...this.
197 (resume_stopped_resumed_lwps): Turn into...
198 (linux_process_target::resume_stopped_resumed_lwps): ...this.
199 (install_software_single_step_breakpoints): Turn into...
200 (linux_process_target::install_software_single_step_breakpoints):
202 (single_step): Turn into...
203 (linux_process_target::single_step): ...this.
204 (linux_resume_one_lwp_throw): Turn into...
205 (linux_process_target::resume_one_lwp_throw): ...this.
206 (linux_resume_one_lwp): Turn into...
207 (linux_process_target::resume_one_lwp): ...this.
208 (resume_status_pending_p): Turn into...
209 (linux_process_target::resume_status_pending): ...this.
210 (need_step_over_p): Turn into...
211 (linux_process_target::thread_needs_step_over): ...this.
212 (linux_resume_one_thread): Turn into...
213 (linux_process_target::resume_one_thread): ...this.
214 (proceed_one_lwp): Turn into...
215 (linux_process_target::proceed_one_lwp): ...this.
216 (unsuspend_and_proceed_one_lwp): Turn into...
217 (linux_process_target::unsuspend_and_proceed_one_lwp): ...this.
219 Update the calls/references to the above functions below.
221 (linux_process_target::handle_extended_wait)
222 (linux_process_target::filter_event)
223 (linux_process_target::wait_for_event_filtered)
224 (linux_process_target::wait_1)
225 (linux_process_target::move_out_of_jump_pad)
226 (linux_process_target::start_step_over)
227 (linux_process_target::resume)
228 (linux_process_target::proceed_all_lwps)
229 (regsets_store_inferior_registers)
230 (linux_process_target::store_register)
232 * linux-low.h (class linux_process_target)
235 <thread_still_has_status_pending>
236 <status_pending_p_callback>
237 <resume_stopped_resumed_lwps>
238 <install_software_single_step_breakpoints>
240 <resume_one_lwp_throw>
242 <resume_status_pending>
243 <thread_needs_step_over>
246 <unsuspend_and_proceed_one_lwp>: Declare.
248 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
250 Turn the 'fetch_register' linux target op into a method of
251 linux_process_target.
253 * linux-low.h (struct linux_target_ops) <fetch_register>: Remove.
254 (class linux_process_target) <low_fetch_register>: Declare.
255 * linux-x86-low.cc (the_low_target)
256 * linux-aarch64-low.cc (the_low_target)
257 * linux-arm-low.cc (the_low_target)
258 * linux-bfin-low.cc (the_low_target)
259 * linux-cris-low.cc (the_low_target)
260 * linux-crisv32-low.cc (the_low_target)
261 * linux-m32r-low.cc (the_low_target)
262 * linux-m68k-low.cc (the_low_target)
263 * linux-nios2-low.cc (the_low_target)
264 * linux-ppc-low.cc (the_low_target)
265 * linux-s390-low.cc (the_low_target)
266 * linux-sh-low.cc (the_low_target)
267 * linux-sparc-low.cc (the_low_target)
268 * linux-tic6x-low.cc (the_low_target)
269 * linux-tile-low.cc (the_low_target)
270 * linux-xtensa-low.cc (the_low_target): Remove the op field.
271 * linux-ia64-low.cc (class ia64_target) <low_fetch_register>:
273 (ia64_fetch_register): Turn into...
274 (ia64_target::low_fetch_register): ...this.
275 (the_low_target): Remove the op field.
276 * linux-mips-low.cc (class mips_target) <low_fetch_register>:
278 (mips_fetch_register): Turn into...
279 (mips_target::low_fetch_register): ...this.
280 (the_low_target): Remove the op field.
281 * linux-riscv-low.cc (class riscv_target) <low_fetch_register>:
283 (riscv_fetch_register): Turn into...
284 (riscv_target::low_fetch_register): ...this.
285 (the_low_target): Remove the op field.
287 Update the callers below.
289 * linux-low.cc (linux_process_target::fetch_registers)
290 (linux_process_target::low_fetch_register)
292 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
294 Turn the 'cannot_fetch_register' and 'cannot_store_register'
295 linux target ops into methods of linux_process_target.
297 * linux-low.h (struct linux_target_ops): Remove the low target ops.
298 (class linux_process_target) <fetch_register>
300 <usr_fetch_inferior_registers>
301 <usr_store_inferior_registers>
302 <low_cannot_fetch_register>
303 <low_cannot_fetch_register> Declare.
304 * linux-low.cc (fetch_register): Turn into...
305 (linux_process_target::fetch_register): ...this.
306 (store_register): Turn into ...
307 (linux_process_target::store_register): ...this.
308 (usr_fetch_inferior_registers): Turn into...
309 (linux_process_target::usr_fetch_inferior_registers): ...this.
310 (usr_store_inferior_registers): Turn into...
311 (linux_process_target::usr_store_inferior_registers): ...this.
312 * linux-x86-low.cc (class x86_target)
313 <low_cannot_fetch_register>
314 <low_cannot_store_register>: Declare.
315 (x86_cannot_store_register): Turn into...
316 (x86_target::low_cannot_store_register): ...this.
317 (x86_cannot_fetch_register): Turn into...
318 (x86_target::low_cannot_fetch_register): ...this.
319 (the_low_target): Remove the target op fields.
320 * linux-aarch64-low.cc (class aarch64_target)
321 <low_cannot_fetch_register>
322 <low_cannot_store_register>: Declare.
323 (aarch64_target::low_cannot_fetch_register)
324 (aarch64_target::low_cannot_store_register): Define.
325 (the_low_target): Remove the op fields.
326 * linux-arm-low.cc (class arm_target)
327 <low_cannot_fetch_register>
328 <low_cannot_store_register>: Declare.
329 (arm_cannot_fetch_register): Turn into...
330 (arm_target::low_cannot_fetch_register): ...this.
331 (arm_cannot_store_register): Turn into...
332 (arm_target::low_cannot_store_register): ...this.
333 (the_low_target): Remove the op fields.
334 * linux-bfin-low.cc (class bfin_target)
335 <low_cannot_fetch_register>
336 <low_cannot_store_register>: Declare.
337 (bfin_cannot_fetch_register): Turn into...
338 (bfin_target::low_cannot_fetch_register): ...this.
339 (bfin_cannot_store_register): Turn into...
340 (bfin_target::low_cannot_store_register): ...this.
341 (the_low_target): Remove the op fields.
342 * linux-cris-low.cc (class cris_target)
343 <low_cannot_fetch_register>
344 <low_cannot_store_register>: Declare.
345 (cris_cannot_fetch_register): Turn into...
346 (cris_target::low_cannot_fetch_register): ...this.
347 (cris_cannot_store_register): Turn into...
348 (cris_target::low_cannot_store_register): ...this.
349 (the_low_target): Remove the op fields.
350 * linux-crisv32-low.cc (class crisv32_target)
351 <low_cannot_fetch_register>
352 <low_cannot_store_register>: Declare.
353 (crisv32_target::low_cannot_fetch_register)
354 (crisv32_target::low_cannot_store_register): Define.
355 (the_low_target): Remove the op fields.
356 * linux-ia64-low.cc (class ia64_target)
357 <low_cannot_fetch_register>
358 <low_cannot_store_register>: Declare.
359 (ia64_cannot_fetch_register): Turn into...
360 (ia64_target::low_cannot_fetch_register): ...this.
361 (ia64_cannot_store_register): Turn into...
362 (ia64_target::low_cannot_store_register): ...this.
363 (the_low_target): Remove the op fields.
364 * linux-m32r-low.cc (class m32r_target)
365 <low_cannot_fetch_register>
366 <low_cannot_store_register>: Declare.
367 (m32r_cannot_fetch_register): Turn into...
368 (m32r_target::low_cannot_fetch_register): ...this.
369 (m32r_cannot_store_register): Turn into...
370 (m32r_target::low_cannot_store_register): ...this.
371 (the_low_target): Remove the op fields.
372 * linux-m68k-low.cc (class m68k_target)
373 <low_cannot_fetch_register>
374 <low_cannot_store_register>: Declare.
375 (m68k_cannot_fetch_register): Turn into...
376 (m68k_target::low_cannot_fetch_register): ...this.
377 (m68k_cannot_store_register): Turn into...
378 (m68k_target::low_cannot_store_register): ...this.
379 (the_low_target): Remove the op fields.
380 * linux-mips-low.cc (class mips_target)
381 <low_cannot_fetch_register>
382 <low_cannot_store_register>: Declare.
383 (mips_cannot_fetch_register): Turn into...
384 (mips_target::low_cannot_fetch_register): ...this.
385 (mips_cannot_store_register): Turn into...
386 (mips_target::low_cannot_store_register): ...this.
387 (get_usrregs_info): Inline at the call sites in
388 low_cannot_fetch_register and low_cannot_store_register,
390 (the_low_target): Remove the op fields.
391 * linux-nios2-low.cc (class nios2_target)
392 <low_cannot_fetch_register>
393 <low_cannot_store_register>: Declare.
394 (nios2_cannot_fetch_register): Turn into...
395 (nios2_target::low_cannot_fetch_register): ...this.
396 (nios2_cannot_store_register): Turn into...
397 (nios2_target::low_cannot_store_register): ...this.
398 (the_low_target): Remove the op fields.
399 * linux-ppc-low.cc (class ppc_target)
400 <low_cannot_fetch_register>
401 <low_cannot_store_register>: Declare.
402 (ppc_cannot_fetch_register): Turn into...
403 (ppc_target::low_cannot_fetch_register): ...this.
404 (ppc_cannot_store_register): Turn into...
405 (ppc_target::low_cannot_store_register): ...this.
406 (the_low_target): Remove the op fields.
407 * linux-riscv-low.cc (class riscv_target)
408 <low_cannot_fetch_register>
409 <low_cannot_store_register>: Declare.
410 (riscv_target::low_cannot_fetch_register)
411 (riscv_target::low_cannot_store_register): Define.
412 (the_low_target): Remove the op fields.
413 * linux-s390-low.cc (class s390_target)
414 <low_cannot_fetch_register>
415 <low_cannot_store_register>: Declare.
416 (s390_cannot_fetch_register): Turn into...
417 (s390_target::low_cannot_fetch_register): ...this.
418 (s390_cannot_store_register): Turn into...
419 (s390_target::low_cannot_store_register): ...this.
420 (the_low_target): Remove the op fields.
421 * linux-sh-low.cc (class sh_target)
422 <low_cannot_fetch_register>
423 <low_cannot_store_register>: Declare.
424 (sh_cannot_fetch_register): Turn into...
425 (sh_target::low_cannot_fetch_register): ...this.
426 (sh_cannot_store_register): Turn into...
427 (sh_target::low_cannot_store_register): ...this.
428 (the_low_target): Remove the op fields.
429 * linux-sparc-low.cc (class sparc_target)
430 <low_cannot_fetch_register>
431 <low_cannot_store_register>: Declare.
432 (sparc_cannot_fetch_register): Turn into...
433 (sparc_target::low_cannot_fetch_register): ...this.
434 (sparc_cannot_store_register): Turn into...
435 (sparc_target::low_cannot_store_register): ...this.
436 (the_low_target): Remove the op fields.
437 * linux-tic6x-low.cc (class tic6x_target)
438 <low_cannot_fetch_register>
439 <low_cannot_store_register>: Declare.
440 (tic6x_cannot_fetch_register): Turn into...
441 (tic6x_target::low_cannot_fetch_register): ...this.
442 (tic6x_cannot_store_register): Turn into...
443 (tic6x_target::low_cannot_store_register): ...this.
444 (the_low_target): Remove the op fields.
445 * linux-tile-low.cc (class tile_target)
446 <low_cannot_fetch_register>
447 <low_cannot_store_register>: Declare.
448 (tile_cannot_fetch_register): Turn into...
449 (tile_target::low_cannot_fetch_register): ...this.
450 (tile_cannot_store_register): Turn into...
451 (tile_target::low_cannot_store_register): ...this.
452 (the_low_target): Remove the op fields.
453 * linux-xtensa-low.cc (class xtensa_target)
454 <low_cannot_fetch_register>
455 <low_cannot_store_register>: Declare.
456 (xtensa_target::low_cannot_fetch_register)
457 (xtensa_target::low_cannot_store_register): Define.
458 (the_low_target): Remove the op fields.
460 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
462 Turn the 'regs_info' linux target op into a method of
463 linux_process_target.
465 * linux-low.h (struct linux_target_ops) <regs_info>: Remove.
466 (class linux_process_target) <get_regs_info>: Define.
468 Update the callers below.
470 * linux-low.cc (linux_process_target::fetch_registers)
471 (linux_process_target::store_registers)
472 * proc-service.cc (gregset_info)
474 * linux-x86-low.cc (class x86_target) <get_regs_info>: Declare.
475 (x86_linux_regs_info): Turn into ...
476 (x86_target::get_regs_info): ...this.
477 (the_low_target): Remove the op field.
478 * linux-aarch64-low.cc (class aarch64_target) <get_regs_info>:
480 (aarch64_regs_info): Turn into ...
481 (aarch64_target::get_regs_info): ...this.
482 (the_low_target): Remove the op field.
483 * linux-arm-low.cc (class arm_target) <get_regs_info>: Declare.
484 (arm_regs_info): Turn into ...
485 (arm_target::get_regs_info): ...this.
486 (the_low_target): Remove the op field.
487 * linux-bfin-low.cc (class bfin_target) <get_regs_info>: Declare.
488 (bfin_regs_info): Turn into ...
489 (bfin_target::get_regs_info): ...this.
490 (the_low_target): Remove the op field.
491 * linux-cris-low.cc (class cris_target) <get_regs_info>: Declare.
492 (cris_regs_info): Turn into ...
493 (cris_target::get_regs_info): ...this.
494 (the_low_target): Remove the op field.
495 * linux-crisv32-low.cc (class crisv32_target) <get_regs_info>:
497 (crisv32_regs_info): Turn into ...
498 (crisv32_target::get_regs_info): ...this.
499 (the_low_target): Remove the op field.
500 * linux-ia64-low.cc (class ia64_target) <get_regs_info>: Declare.
501 (ia64_regs_info): Turn into ...
502 (ia64_target::get_regs_info): ...this.
503 (the_low_target): Remove the op field.
504 * linux-m32r-low.cc (class m32r_target) <get_regs_info>: Declare.
505 (m32r_regs_info): Turn into ...
506 (m32r_target::get_regs_info): ...this.
507 (the_low_target): Remove the op field.
508 * linux-m68k-low.cc (class m68k_target) <get_regs_info>: Declare.
509 (m68k_regs_info): Turn into ...
510 (m68k_target::get_regs_info): ...this.
511 (the_low_target): Remove the op field.
512 * linux-mips-low.cc (class mips_target) <get_regs_info>: Declare.
513 (mips_regs_info): Turn into ...
514 (mips_target::get_regs_info): ...this.
515 (the_low_target): Remove the op field.
516 (get_usrregs_info): Update the call to the op.
517 * linux-nios2-low.cc (class nios2_target) <get_regs_info>: Declare.
518 (nios2_regs_info): Turn into ...
519 (nios2_target::get_regs_info): ...this.
520 (the_low_target): Remove the op field.
521 * linux-ppc-low.cc (class ppc_target) <get_regs_info>: Declare.
522 (ppc_regs_info): Turn into ...
523 (ppc_target::get_regs_info): ...this.
524 (the_low_target): Remove the op field.
525 * linux-riscv-low.cc (class riscv_target) <get_regs_info>: Declare.
526 (riscv_regs_info): Turn into ...
527 (riscv_target::get_regs_info): ...this.
528 (the_low_target): Remove the op field.
529 * linux-s390-low.cc (class s390_target) <get_regs_info>: Declare.
530 (s390_regs_info): Turn into ...
531 (s390_target::get_regs_info): ...this.
532 (the_low_target): Remove the op field.
533 (s390_collect_ptrace_register)
534 (s390_supply_ptrace_register)
535 (s390_fill_gregset): Update the call to the op.
536 * linux-sh-low.cc (class sh_target) <get_regs_info>: Declare.
537 (sh_regs_info): Turn into ...
538 (sh_target::get_regs_info): ...this.
539 (the_low_target): Remove the op field.
540 * linux-sparc-low.cc (class sparc_target) <get_regs_info>: Declare.
541 (sparc_regs_info): Turn into ...
542 (sparc_target::get_regs_info): ...this.
543 (the_low_target): Remove the op field.
544 * linux-tic6x-low.cc (class tic6x_target) <get_regs_info>: Declare.
545 (tic6x_regs_info): Turn into ...
546 (tic6x_target::get_regs_info): ...this.
547 (the_low_target): Remove the op field.
548 * linux-tile-low.cc (class tile_target) <get_regs_info>: Declare.
549 (tile_regs_info): Turn into ...
550 (tile_target::get_regs_info): ...this.
551 (the_low_target): Remove the op field.
552 * linux-xtensa-low.cc (class xtensa_target) <get_regs_info>:
554 (xtensa_regs_info): Turn into ...
555 (xtensa_target::get_regs_info): ...this.
556 (the_low_target): Remove the op field.
558 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
560 Turn the 'arch_setup' linux target op into a method of
561 linux_process_target.
563 * linux-low.h (struct linux_target_ops) <arch_setup>: Delete.
564 (class linux_process_target) <arch_setup_thread>
565 <low_arch_setup>: New declarations.
566 * linux-low.cc (linux_arch_setup): Delete.
567 (linux_arch_setup_thread): Turn into...
568 (linux_process_target::arch_setup_thread): ... this.
570 Update the callers below.
572 (linux_process_target::handle_extended_wait)
573 (linux_process_target::post_create_inferior)
574 (linux_process_target::filter_event)
576 * linux-x86-low.cc (class x86_target) <low_arch_setup>: New
578 (x86_linux_update_xmltarget): Turn into...
579 (x86_target::update_xmltarget): ...this.
580 (x86_linux_process_qsupported): Update the call to
581 x86_linux_update_xmltarget.
582 (x86_arch_setup): Turn into ...
583 (x86_target::low_arch_setup): ...this.
584 (the_low_target): Remove the op field.
585 * linux-aarch64-low.cc (class aarch64_target) <low_arch_setup>: New
587 (aarch64_arch_setup): Turn into ...
588 (aarch64_target::low_arch_setup): ...this.
589 (the_low_target): Remove the op field.
590 * linux-arm-low.cc (class arm_target) <low_arch_setup>: New
592 (arm_arch_setup): Turn into ...
593 (arm_target::low_arch_setup): ...this.
594 (the_low_target): Remove the op field.
595 * linux-bfin-low.cc (class bfin_target) <low_arch_setup>: New
597 (bfin_arch_setup): Turn into ...
598 (bfin_target::low_arch_setup): ...this.
599 (the_low_target): Remove the op field.
600 * linux-cris-low.cc (class cris_target) <low_arch_setup>: New
602 (cris_arch_setup): Turn into ...
603 (cris_target::low_arch_setup): ...this.
604 (the_low_target): Remove the op field.
605 * linux-crisv32-low.cc (class crisv32_target) <low_arch_setup>: New
607 (crisv32_arch_setup): Turn into ...
608 (crisv32_target::low_arch_setup): ...this.
609 (the_low_target): Remove the op field.
610 * linux-ia64-low.cc (class ia64_target) <low_arch_setup>: New
612 (ia64_arch_setup): Turn into ...
613 (ia64_target::low_arch_setup): ...this.
614 (the_low_target): Remove the op field.
615 * linux-m32r-low.cc (class m32r_target) <low_arch_setup>: New
617 (m32r_arch_setup): Turn into ...
618 (m32r_target::low_arch_setup): ...this.
619 (the_low_target): Remove the op field.
620 * linux-m68k-low.cc (class m68k_target) <low_arch_setup>: New
622 (m68k_arch_setup): Turn into ...
623 (m68k_target::low_arch_setup): ...this.
624 (the_low_target): Remove the op field.
625 * linux-mips-low.cc (class mips_target) <low_arch_setup>: New
627 (mips_arch_setup): Turn into ...
628 (mips_target::low_arch_setup): ...this.
629 (the_low_target): Remove the op field.
630 * linux-nios2-low.cc (class nios2_target) <low_arch_setup>: New
632 (nios2_arch_setup): Turn into ...
633 (nios2_target::low_arch_setup): ...this.
634 (the_low_target): Remove the op field.
635 * linux-ppc-low.cc (class ppc_target) <low_arch_setup>: New
637 (ppc_arch_setup): Turn into ...
638 (ppc_target::low_arch_setup): ...this.
639 (the_low_target): Remove the op field.
640 * linux-riscv-low.cc (class riscv_target) <low_arch_setup>: New
642 (riscv_arch_setup): Turn into ...
643 (riscv_target::low_arch_setup): ...this.
644 (the_low_target): Remove the op field.
645 * linux-s390-low.cc (class s390_target) <low_arch_setup>: New
647 (s390_arch_setup): Turn into ...
648 (s390_target::low_arch_setup): ...this.
649 (the_low_target): Remove the op field.
650 * linux-sh-low.cc (class sh_target) <low_arch_setup>: New
652 (sh_arch_setup): Turn into ...
653 (sh_target::low_arch_setup): ...this.
654 (the_low_target): Remove the op field.
655 * linux-sparc-low.cc (class sparc_target) <low_arch_setup>: New
657 (sparc_arch_setup): Turn into ...
658 (sparc_target::low_arch_setup): ...this.
659 (the_low_target): Remove the op field.
660 * linux-tic6x-low.cc (class tic6x_target) <low_arch_setup>: New
662 (tic6x_arch_setup): Turn into ...
663 (tic6x_target::low_arch_setup): ...this.
664 (the_low_target): Remove the op field.
665 * linux-tile-low.cc (class tile_target) <low_arch_setup>: New
667 (tile_arch_setup): Turn into ...
668 (tile_target::low_arch_setup): ...this.
669 (the_low_target): Remove the op field.
670 * linux-xtensa-low.cc (class xtensa_target) <low_arch_setup>: New
672 (xtensa_arch_setup): Turn into ...
673 (xtensa_target::low_arch_setup): ...this.
674 (the_low_target): Remove the op field.
676 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
678 * linux-low.h (the_linux_target): New extern declaration.
679 * linux-low.cc (initialize_low): Use 'the_linux_target' to set
681 (the_linux_target): Remove.
682 * linux-x86-low.cc (class x86_target): New class.
683 (the_x86_target): New static object.
684 (the_linux_target): Define as pointer to the_x86_target.
685 * linux-aarch64-low.cc (class aarch64_target): New class.
686 (the_aarch64_target): New static object.
687 (the_linux_target): Define as pointer to the_aarch64_target.
688 * linux-arm-low.cc (class arm_target): New class.
689 (the_arm_target): New static object.
690 (the_linux_target): Define as pointer to the_arm_target.
691 * linux-bfin-low.cc (class bfin_target): New class.
692 (the_bfin_target): New static object.
693 (the_linux_target): Define as pointer to the_bfin_target.
694 * linux-cris-low.cc (class cris_target): New class.
695 (the_cris_target): New static object.
696 (the_linux_target): Define as pointer to the_cris_target.
697 * linux-crisv32-low.cc (class crisv32_target): New class.
698 (the_crisv32_target): New static object.
699 (the_linux_target): Define as pointer to the_crisv32_target.
700 * linux-ia64-low.cc (class ia64_target): New class.
701 (the_ia64_target): New static object.
702 (the_linux_target): Define as pointer to the_ia64_target.
703 * linux-m32r-low.cc (class m32r_target): New class.
704 (the_m32r_target): New static object.
705 (the_linux_target): Define as pointer to the_m32r_target.
706 * linux-m68k-low.cc (class m68k_target): New class.
707 (the_m68k_target): New static object.
708 (the_linux_target): Define as pointer to the_m68k_target.
709 * linux-mips-low.cc (class mips_target): New class.
710 (the_mips_target): New static object.
711 (the_linux_target): Define as pointer to the_mips_target.
712 * linux-nios2-low.cc (class nios2_target): New class.
713 (the_nios2_target): New static object.
714 (the_linux_target): Define as pointer to the_nios2_target.
715 * linux-ppc-low.cc (class ppc_target): New class.
716 (the_ppc_target): New static object.
717 (the_linux_target): Define as pointer to the_ppc_target.
718 * linux-riscv-low.cc (class riscv_target): New class.
719 (the_riscv_target): New static object.
720 (the_linux_target): Define as pointer to the_riscv_target.
721 * linux-s390-low.cc (class s390_target): New class.
722 (the_s390_target): New static object.
723 (the_linux_target): Define as pointer to the_s390_target.
724 * linux-sh-low.cc (class sh_target): New class.
725 (the_sh_target): New static object.
726 (the_linux_target): Define as pointer to the_sh_target.
727 * linux-sparc-low.cc (class sparc_target): New class.
728 (the_sparc_target): New static object.
729 (the_linux_target): Define as pointer to the_sparc_target.
730 * linux-tic6x-low.cc (class tic6x_target): New class.
731 (the_tic6x_target): New static object.
732 (the_linux_target): Define as pointer to the_tic6x_target.
733 * linux-tile-low.cc (class tile_target): New class.
734 (the_tile_target): New static object.
735 (the_linux_target): Define as pointer to the_tile_target.
736 * linux-xtensa-low.cc (class xtensa_target): New class.
737 (the_xtensa_target): New static object.
738 (the_linux_target): Define as pointer to the_xtensa_target.
740 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
742 Turn some static functions in linux-low.cc into private methods of
743 linux_process_target.
745 * linux-low.cc (handle_extended_wait): Turn into ...
746 (linux_process_target::handle_extended_wait): ...this. Call
747 'mourn' on 'this' object instead of 'the_target'.
748 (maybe_move_out_of_jump_pad): Turn into...
749 (linux_process_target::maybe_move_out_of_jump_pad): ...this.
750 (linux_low_filter_event): Turn into...
751 (linux_process_target::filter_event): ...this.
752 (linux_wait_for_event_filtered): Turn into...
753 (linux_process_target::wait_for_event_filtered): ...this.
754 (linux_wait_for_event): Turn into...
755 (linux_process_target::wait_for_event): ...this.
756 (linux_wait_1): Turn into...
757 (linux_process_target::wait_1): ...this.
758 (wait_for_sigstop): Turn into...
759 (linux_process_target::wait_for_sigstop): ...this.
760 (move_out_of_jump_pad_callback): Turn into...
761 (linux_process_target::move_out_of_jump_pad): ...this.
762 (stop_all_lwps): Turn into...
763 (linux_process_target::stop_all_lwps): ...this.
764 (start_step_over): Turn into...
765 (linux_process_target::start_step_over): ...this.
766 (complete_ongoing_step_over): Turn into...
767 (linux_process_target::complete_ongoing_step_over): ...this.
768 (proceed_all_lwps): Turn into...
769 (linux_process_target::proceed_all_lwps): ...this.
770 (unstop_all_lwps): Turn into...
771 (linux_process_target::unstop_all_lwps): ...this.
773 * linux-low.h (class linux_process_target)
774 <handle_extended_wait>
775 <maybe_move_out_of_jump_pad>
777 <wait_for_event_filtered>
781 <move_out_of_jump_pad>
784 <complete_ongoing_step_over>
786 <unstop_all_lwps>: Declare.
788 Update the callers below.
790 * linux-low.cc (linux_process_target::attach): Update.
791 (linux_process_target::stabilize_threads): Ditto.
792 (linux_process_target::wait): Ditto.
794 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
796 * linux-low.h (struct linux_target_ops): Update the comment for
797 'cannot_store_register' to return 0 or 1.
798 * linux-ppc-low.cc (ppc_cannot_store_register): Return 1 instead
801 2020-03-20 Simon Marchi <simon.marchi@efficios.com>
803 * config.in: Re-generate.
804 * configure: Re-generate.
806 2020-03-17 Kamil Rytarowski <n54@gmx.com>
808 * regcache.cc (find_register_by_number): Update.
809 * tdesc.cc (init_target_desc): Likewise.
810 * tdesc.h (target_desc::reg_defs): Likewise.
812 2020-03-12 Tom Tromey <tom@tromey.com>
814 * configure: Rebuild.
815 * configure.ac (GDBSERVER_DEPFILES): Remove srv_selftest_objs.
816 (WIN32APILIBS): New subst.
817 * Makefile.in (SFILES, OBS, TAGS, GDBREPLAY_OBS): Remove
819 (gdbsupport/%.o): Remove target.
820 (GDBSUPPORT_BUILDDIR, GDBSUPPORT): New variables.
821 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Add GDBSUPPORT.
822 (WIN32APILIBS): New variable.
823 (gdbserver$(EXEEXT)): Add WIN32APILIBS.
824 (gdbreplay$(EXEEXT)): Likewise.
826 2020-03-12 Tom Tromey <tom@tromey.com>
828 * config.in, configure: Rebuild.
829 * configure.ac: Call ZW_GNU_GETTEXT_SISTER_DIR.
830 * acinclude.m4: Include gettext-sister.m4.
831 * Makefile.in (top_builddir, INTL, INTL_DEPS, INTL_CFLAGS): New
833 (INCLUDE_CFLAGS): Add INTL_CFLAGS.
834 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Use INTL_DEPS, INTL.
836 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
838 * acinclude.m4: Update path to selftest.m4.
840 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
842 * configure.ac: Don't source bfd/development.sh, move
843 GDB_AC_COMMON higher.
844 * configure: Re-generate.
846 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
848 * configure: Re-generate.
850 2020-03-11 Simon Marchi <simon.marchi@efficios.com>
852 * configure: Re-generate.
854 2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
856 * .dir-locals.el: New file.
858 2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
860 * .gitattributes: New file.
862 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
864 * remote-utils.cc (prepare_resume_reply): Add ability to convert T
865 reply into an S reply.
866 * server.cc (disable_packet_T): New global.
867 (captured_main): Set new global when appropriate.
868 * server.h (disable_packet_T): Declare.
870 2020-02-21 Tom Tromey <tom@tromey.com>
872 * Makefile.in (mostlyclean): New target.
874 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
876 * target.h (struct process_stratum_target): Remove.
877 (class process_target): Rename to ...
878 (class process_stratum_target): ... this.
879 * linux-low.h (class linux_process_target): Derive from
880 'process_stratum_target'.
881 * linux-low.cc (linux_target_ops): Remove.
882 (initialize_low): Set the_target to the singleton instance of
883 linux_process_target.
884 * lynx-low.h (class lynx_process_target): Derive from
885 'process_stratum_target'.
886 * lynx-low.cc (lynx_target_ops): Remove.
887 (initialize_low): Set the_target to the singleton instance of
889 * nto-low.h (class nto_process_target): Derive from
890 'process_stratum_target'.
891 * nto-low.cc (nto_target_ops): Remove.
892 (initialize_low): Set the_target to the singleton instance of
894 * win32-low.h (class win32_process_target): Derive from
895 'process_stratum_target'.
896 * win32-low.cc (win32_target_ops): Remove.
897 (initialize_low): Set the_target to the singleton instance of
898 win32_process_target.
900 Replace 'the_target->pt' with 'the_target' in the uses below.
902 * hostio.cc (hostio_error)
907 * linux-aarch32-low.cc (arm_breakpoint_at)
908 * linux-aarch64-low.cc (aarch64_breakpoint_at)
909 * linux-arm-low.cc (arm_sigreturn_next_pc)
911 (arm_get_syscall_trapinfo)
912 * linux-cris-low.cc (cris_breakpoint_at)
913 * linux-crisv32-low.cc (cris_breakpoint_at)
914 * linux-low.cc (handle_extended_wait)
917 (linux_process_target::breakpoint_kind_from_pc)
919 * linux-m32r-low.cc (m32r_breakpoint_at)
920 * linux-mips-low.cc (mips_breakpoint_at)
921 * linux-nios2-low.cc (nios2_breakpoint_at)
922 * linux-ppc-low.cc (ppc_breakpoint_at)
923 * linux-s390-low.cc (s390_get_hwcap)
924 * linux-sh-low.cc (sh_breakpoint_at)
925 * linux-sparc-low.cc (sparc_fill_gregset_to_stack)
926 (sparc_store_gregset_from_stack)
927 (sparc_breakpoint_at)
928 * linux-tic6x-low.cc (tic6x_breakpoint_at)
929 * linux-tile-low.cc (tile_breakpoint_at)
930 * linux-x86-low.cc (x86_breakpoint_at)
931 * linux-xtensa-low.cc (xtensa_breakpoint_at)
932 * mem-break.cc (bp_size)
934 (insert_memory_breakpoint)
935 (set_raw_breakpoint_at)
936 (delete_raw_breakpoint)
938 (uninsert_raw_breakpoint)
939 (reinsert_raw_breakpoint)
940 (validate_inserted_breakpoint)
941 * regcache.cc (regcache_read_pc)
943 * remote-utils.cc (putpkt_binary_1)
946 (prepare_resume_reply)
947 * server.cc (handle_general_set)
950 (handle_qxfer_exec_file)
951 (handle_qxfer_libraries_svr4)
952 (handle_qxfer_osdata)
953 (handle_qxfer_siginfo)
958 (queue_stop_reply_callback)
960 * target.cc (prepare_to_access_memory)
961 (done_accessing_memory)
962 (read_inferior_memory)
963 (target_write_memory)
964 (target_stop_and_wait)
966 (target_mourn_inferior)
967 (target_continue_no_signal)
969 (target_supports_multi_process)
972 (target_create_inferior)
973 (target_post_create_inferior)
975 (target_supports_fork_events)
976 (target_supports_vfork_events)
977 (target_supports_exec_events)
978 (target_handle_new_gdb_connection)
981 (fetch_inferior_registers)
982 (store_inferior_registers)
984 (target_supports_non_stop)
986 (target_process_qsupported)
987 (target_supports_catch_syscall)
988 (target_get_ipa_tdesc_idx)
989 (target_supports_tracepoints)
990 (target_supports_fast_tracepoints)
991 (target_get_min_fast_tracepoint_insn_len)
992 (target_thread_stopped)
995 (target_stabilize_threads)
996 (target_install_fast_tracepoint_jump_pad)
998 (target_supports_disable_randomization)
999 (target_supports_agent)
1000 (target_enable_btrace)
1001 (target_disable_btrace)
1002 (target_read_btrace)
1003 (target_read_btrace_conf)
1004 (target_supports_range_stepping)
1005 (target_supports_stopped_by_sw_breakpoint)
1006 (target_stopped_by_sw_breakpoint)
1007 (target_supports_stopped_by_hw_breakpoint)
1008 (target_supports_hardware_single_step)
1009 (target_stopped_by_hw_breakpoint)
1010 (target_breakpoint_kind_from_pc)
1011 (target_breakpoint_kind_from_current_state)
1012 (target_supports_software_single_step)
1013 (target_core_of_thread)
1014 (target_thread_name)
1015 (target_thread_handle)
1016 * win32-low.cc (do_initial_child_stuff)
1018 Rename target op default definitions listed below.
1020 * target.cc (process_target::post_create_inferior): Rename as ...
1021 (process_stratum_target::post_create_inferior): ... this.
1022 (process_target::prepare_to_access_memory): Rename as ...
1023 (process_stratum_target::prepare_to_access_memory): ... this.
1024 (process_target::done_accessing_memory): Rename as ...
1025 (process_stratum_target::done_accessing_memory): ... this.
1026 (process_target::look_up_symbols): Rename as ...
1027 (process_stratum_target::look_up_symbols): ... this.
1028 (process_target::supports_read_auxv): Rename as ...
1029 (process_stratum_target::supports_read_auxv): ... this.
1030 (process_target::read_auxv): Rename as ...
1031 (process_stratum_target::read_auxv): ... this.
1032 (process_target::supports_z_point_type): Rename as ...
1033 (process_stratum_target::supports_z_point_type): ... this.
1034 (process_target::insert_point): Rename as ...
1035 (process_stratum_target::insert_point): ... this.
1036 (process_target::remove_point): Rename as ...
1037 (process_stratum_target::remove_point): ... this.
1038 (process_target::stopped_by_sw_breakpoint): Rename as ...
1039 (process_stratum_target::stopped_by_sw_breakpoint): ... this.
1040 (process_target::supports_stopped_by_sw_breakpoint): Rename as ...
1041 (process_stratum_target::supports_stopped_by_sw_breakpoint): ... this.
1042 (process_target::stopped_by_hw_breakpoint): Rename as ...
1043 (process_stratum_target::stopped_by_hw_breakpoint): ... this.
1044 (process_target::supports_stopped_by_hw_breakpoint): Rename as ...
1045 (process_stratum_target::supports_stopped_by_hw_breakpoint): ... this.
1046 (process_target::supports_hardware_single_step): Rename as ...
1047 (process_stratum_target::supports_hardware_single_step): ... this.
1048 (process_target::stopped_by_watchpoint): Rename as ...
1049 (process_stratum_target::stopped_by_watchpoint): ... this.
1050 (process_target::stopped_data_address): Rename as ...
1051 (process_stratum_target::stopped_data_address): ... this.
1052 (process_target::supports_read_offsets): Rename as ...
1053 (process_stratum_target::supports_read_offsets): ... this.
1054 (process_target::read_offsets): Rename as ...
1055 (process_stratum_target::read_offsets): ... this.
1056 (process_target::supports_get_tls_address): Rename as ...
1057 (process_stratum_target::supports_get_tls_address): ... this.
1058 (process_target::get_tls_address): Rename as ...
1059 (process_stratum_target::get_tls_address): ... this.
1060 (process_target::hostio_last_error): Rename as ...
1061 (process_stratum_target::hostio_last_error): ... this.
1062 (process_target::supports_qxfer_osdata): Rename as ...
1063 (process_stratum_target::supports_qxfer_osdata): ... this.
1064 (process_target::qxfer_osdata): Rename as ...
1065 (process_stratum_target::qxfer_osdata): ... this.
1066 (process_target::supports_qxfer_siginfo): Rename as ...
1067 (process_stratum_target::supports_qxfer_siginfo): ... this.
1068 (process_target::qxfer_siginfo): Rename as ...
1069 (process_stratum_target::qxfer_siginfo): ... this.
1070 (process_target::supports_non_stop): Rename as ...
1071 (process_stratum_target::supports_non_stop): ... this.
1072 (process_target::async): Rename as ...
1073 (process_stratum_target::async): ... this.
1074 (process_target::start_non_stop): Rename as ...
1075 (process_stratum_target::start_non_stop): ... this.
1076 (process_target::supports_multi_process): Rename as ...
1077 (process_stratum_target::supports_multi_process): ... this.
1078 (process_target::supports_fork_events): Rename as ...
1079 (process_stratum_target::supports_fork_events): ... this.
1080 (process_target::supports_vfork_events): Rename as ...
1081 (process_stratum_target::supports_vfork_events): ... this.
1082 (process_target::supports_exec_events): Rename as ...
1083 (process_stratum_target::supports_exec_events): ... this.
1084 (process_target::handle_new_gdb_connection): Rename as ...
1085 (process_stratum_target::handle_new_gdb_connection): ... this.
1086 (process_target::handle_monitor_command): Rename as ...
1087 (process_stratum_target::handle_monitor_command): ... this.
1088 (process_target::core_of_thread): Rename as ...
1089 (process_stratum_target::core_of_thread): ... this.
1090 (process_target::supports_read_loadmap): Rename as ...
1091 (process_stratum_target::supports_read_loadmap): ... this.
1092 (process_target::read_loadmap): Rename as ...
1093 (process_stratum_target::read_loadmap): ... this.
1094 (process_target::process_qsupported): Rename as ...
1095 (process_stratum_target::process_qsupported): ... this.
1096 (process_target::supports_tracepoints): Rename as ...
1097 (process_stratum_target::supports_tracepoints): ... this.
1098 (process_target::read_pc): Rename as ...
1099 (process_stratum_target::read_pc): ... this.
1100 (process_target::write_pc): Rename as ...
1101 (process_stratum_target::write_pc): ... this.
1102 (process_target::supports_thread_stopped): Rename as ...
1103 (process_stratum_target::supports_thread_stopped): ... this.
1104 (process_target::thread_stopped): Rename as ...
1105 (process_stratum_target::thread_stopped): ... this.
1106 (process_target::supports_get_tib_address): Rename as ...
1107 (process_stratum_target::supports_get_tib_address): ... this.
1108 (process_target::get_tib_address): Rename as ...
1109 (process_stratum_target::get_tib_address): ... this.
1110 (process_target::pause_all): Rename as ...
1111 (process_stratum_target::pause_all): ... this.
1112 (process_target::unpause_all): Rename as ...
1113 (process_stratum_target::unpause_all): ... this.
1114 (process_target::stabilize_threads): Rename as ...
1115 (process_stratum_target::stabilize_threads): ... this.
1116 (process_target::supports_fast_tracepoints): Rename as ...
1117 (process_stratum_target::supports_fast_tracepoints): ... this.
1118 (process_target::get_min_fast_tracepoint_insn_len): Rename as ...
1119 (process_stratum_target::get_min_fast_tracepoint_insn_len): ... this.
1120 (process_target::emit_ops): Rename as ...
1121 (process_stratum_target::emit_ops): ... this.
1122 (process_target::supports_disable_randomization): Rename as ...
1123 (process_stratum_target::supports_disable_randomization): ... this.
1124 (process_target::supports_qxfer_libraries_svr4): Rename as ...
1125 (process_stratum_target::supports_qxfer_libraries_svr4): ... this.
1126 (process_target::qxfer_libraries_svr4): Rename as ...
1127 (process_stratum_target::qxfer_libraries_svr4): ... this.
1128 (process_target::supports_agent): Rename as ...
1129 (process_stratum_target::supports_agent): ... this.
1130 (process_target::enable_btrace): Rename as ...
1131 (process_stratum_target::enable_btrace): ... this.
1132 (process_target::disable_btrace): Rename as ...
1133 (process_stratum_target::disable_btrace): ... this.
1134 (process_target::read_btrace): Rename as ...
1135 (process_stratum_target::read_btrace): ... this.
1136 (process_target::read_btrace_conf): Rename as ...
1137 (process_stratum_target::read_btrace_conf): ... this.
1138 (process_target::supports_range_stepping): Rename as ...
1139 (process_stratum_target::supports_range_stepping): ... this.
1140 (process_target::supports_pid_to_exec_file): Rename as ...
1141 (process_stratum_target::supports_pid_to_exec_file): ... this.
1142 (process_target::pid_to_exec_file): Rename as ...
1143 (process_stratum_target::pid_to_exec_file): ... this.
1144 (process_target::supports_multifs): Rename as ...
1145 (process_stratum_target::supports_multifs): ... this.
1146 (process_target::multifs_open): Rename as ...
1147 (process_stratum_target::multifs_open): ... this.
1148 (process_target::multifs_unlink): Rename as ...
1149 (process_stratum_target::multifs_unlink): ... this.
1150 (process_target::multifs_readlink): Rename as ...
1151 (process_stratum_target::multifs_readlink): ... this.
1152 (process_target::breakpoint_kind_from_pc): Rename as ...
1153 (process_stratum_target::breakpoint_kind_from_pc): ... this.
1154 (process_target::breakpoint_kind_from_current_state): Rename as ...
1155 (process_stratum_target::breakpoint_kind_from_current_state): ... this.
1156 (process_target::thread_name): Rename as ...
1157 (process_stratum_target::thread_name): ... this.
1158 (process_target::thread_handle): Rename as ...
1159 (process_stratum_target::thread_handle): ... this.
1160 (process_target::supports_software_single_step): Rename as ...
1161 (process_stratum_target::supports_software_single_step): ... this.
1162 (process_target::supports_catch_syscall): Rename as ...
1163 (process_stratum_target::supports_catch_syscall): ... this.
1164 (process_target::get_ipa_tdesc_idx): Rename as ...
1165 (process_stratum_target::get_ipa_tdesc_idx): ... this.
1167 2020-02-20 Pedro Alves <palves@redhat.com>
1169 * target.cc (set_target_ops): Simply copy the given target pointer
1170 instead of creating a copy of the pointed object.
1172 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1174 Turn process_stratum_target's get_ipa_tdesc_idx op into a method
1177 * target.h (struct process_stratum_target): Remove the target op.
1178 (class process_target): Add the target op.
1179 (target_get_ipa_tdesc_idx): Update the macro.
1180 * target.cc (process_target::get_ipa_tdesc_idx): Define.
1182 Update the derived classes and callers below.
1184 * linux-low.cc (linux_target_ops): Update.
1185 (linux_get_ipa_tdesc_idx): Turn into ...
1186 (linux_process_target::get_ipa_tdesc_idx): ... this.
1187 * linux-low.h (class linux_process_target): Update.
1188 * lynx-low.cc (lynx_target_ops): Update.
1189 * nto-low.cc (nto_target_ops): Update.
1190 * win32-low.cc (win32_target_ops): Update.
1192 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1194 Turn process_stratum_target's supports_catch_syscall op into a
1195 method of process_target.
1197 * target.h (struct process_stratum_target): Remove the target op.
1198 (class process_target): Add the target op.
1199 (target_supports_catch_syscall): Update the macro.
1200 * target.cc (process_target::supports_catch_syscall): Define.
1202 Update the derived classes and callers below.
1204 * linux-low.cc (linux_target_ops): Update.
1205 (linux_supports_catch_syscall): Turn into ...
1206 (linux_process_target::supports_catch_syscall): ... this.
1207 * linux-low.h (class linux_process_target): Update.
1208 * lynx-low.cc (lynx_target_ops): Update.
1209 * nto-low.cc (nto_target_ops): Update.
1210 * win32-low.cc (win32_target_ops): Update.
1212 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1214 Turn process_stratum_target's supports_software_single_step op
1215 into a method of process_target.
1217 * target.h (struct process_stratum_target): Remove the target op.
1218 (class process_target): Add the target op.
1219 (target_supports_software_single_step): Update the macro.
1220 * target.cc (process_target::supports_software_single_step): Define.
1222 Update the derived classes and callers below.
1224 * linux-low.cc (linux_target_ops): Update.
1225 (linux_supports_software_single_step): Turn into ...
1226 (linux_process_target::supports_software_single_step): ... this.
1227 * linux-low.h (class linux_process_target): Update.
1228 * lynx-low.cc (lynx_target_ops): Update.
1229 * nto-low.cc (nto_target_ops): Update.
1230 * win32-low.cc (win32_target_ops): Update.
1232 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1234 Turn process_stratum_target's thread_name and thread_handle ops
1235 into methods of process_target.
1237 * target.h (struct process_stratum_target): Remove the target ops.
1238 (class process_target): Add the target ops.
1239 (target_thread_name): Update the macro.
1240 (target_thread_handle): Update the macro.
1241 * target.cc (process_target::thread_name): Define.
1242 (process_target::thread_handle): Define.
1244 Update the derived classes and callers below.
1246 * linux-low.cc (linux_target_ops): Update.
1247 (linux_process_target::thread_name): Define.
1248 (linux_process_target::thread_handle): Define.
1249 * linux-low.h (class linux_process_target): Update.
1250 * lynx-low.cc (lynx_target_ops): Update.
1251 * nto-low.cc (nto_target_ops): Update.
1252 * win32-low.cc (win32_target_ops): Update.
1254 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1256 Turn process_stratum_target's breakpoint_kind_from_pc,
1257 sw_breakpoint_from_kind, and breakpoint_kind_from_current_state
1258 ops into methods of process_target.
1260 * target.h (struct process_stratum_target): Remove the target op.
1261 (class process_target): Add the target op.
1262 (target_breakpoint_kind_from_pc): Update the macro.
1263 (target_breakpoint_kind_from_current_state): Update the macro.
1264 (default_breakpoint_kind_from_pc): Remove declaration.
1265 * target.cc (default_breakpoint_kind_from_pc): Turn into ...
1266 (process_target::breakpoint_kind_from_pc): ... this.
1267 (process_target::breakpoint_kind_from_current_state): Define.
1269 Update the derived classes and callers below.
1271 * mem-break.cc (bp_size): Update.
1272 (bp_opcode): Update.
1273 * linux-low.cc (linux_target_ops): Update.
1274 (linux_wait_1): Update.
1275 (linux_breakpoint_kind_from_pc): Turn into ...
1276 (linux_process_target::breakpoint_kind_from_pc): ... this.
1277 (linux_sw_breakpoint_from_kind): Turn into ...
1278 (linux_process_target::sw_breakpoint_from_kind): ... this.
1279 (linux_breakpoint_kind_from_current_state): Turn into ...
1280 (linux_process_target::breakpoint_kind_from_current_state): ... this.
1281 * linux-low.h (class linux_process_target): Update.
1282 * lynx-low.cc (lynx_target_ops): Update.
1283 (lynx_process_target::sw_breakpoint_from_kind): Define.
1284 * lynx-low.h (class lynx_process_target): Update.
1285 * nto-low.cc (nto_target_ops): Update.
1286 (nto_sw_breakpoint_from_kind): Turn into ...
1287 (nto_process_target::sw_breakpoint_from_kind): ... this.
1288 * nto-low.h (class nto_process_target): Update.
1289 * win32-low.cc (win32_target_ops): Update.
1290 (win32_sw_breakpoint_from_kind): Turn into ...
1291 (win32_process_target::sw_breakpoint_from_kind): ... this.
1292 * win32-low.h (class win32_process_target): Update.
1294 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1296 Turn process_stratum_target's multifs_open, multifs_readlink,
1297 multifs_unlink ops into methods of process_target.
1299 * target.h (struct process_stratum_target): Remove the target ops.
1300 (class process_target): Add the target ops. Also add
1302 * target.cc: Include "fcntl.h", "unistd.h", "sys/types.h", and
1304 (process_target::supports_multifs): Define.
1305 (process_target::multifs_open): Define.
1306 (process_target::multifs_readlink): Define.
1307 (process_target::multifs_unlink): Define.
1309 Update the derived classes and callers below.
1311 * hostio.cc (handle_setfs): Update.
1312 (handle_open): Update.
1313 (handle_unlink): Update.
1314 (handle_readlink): Update.
1315 * linux-low.cc (linux_target_ops): Update.
1316 (linux_process_target::supports_multifs): Define.
1317 (linux_process_target::multifs_open): Define.
1318 (linux_process_target::multifs_readlink): Define.
1319 (linux_process_target::multifs_unlink): Define.
1320 * linux-low.h (class linux_process_target): Update.
1321 * lynx-low.cc (lynx_target_ops): Update.
1322 * nto-low.cc (nto_target_ops): Update.
1323 * win32-low.cc (win32_target_ops): Update.
1325 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1327 Turn process_stratum_target's pid_to_exec_file op into a method
1330 * target.h (struct process_stratum_target): Remove the target op.
1331 (class process_target): Add the target op. Also add
1332 'supports_pid_to_exec_file'.
1333 * target.cc (process_target::pid_to_exec_file): Define.
1334 (process_target::supports_pid_to_exec_file): Define.
1336 Update the derived classes and callers below.
1338 * server.cc (handle_qxfer_exec_file): Update.
1339 (handle_query): Update.
1340 * linux-low.cc (linux_target_ops): Update.
1341 (linux_process_target::supports_pid_to_exec_file): Define.
1342 (linux_process_target::pid_to_exec_file): Define.
1343 * linux-low.h (class linux_process_target): Update.
1344 * lynx-low.cc (lynx_target_ops): Update.
1345 * nto-low.cc (nto_target_ops): Update.
1346 * win32-low.cc (win32_target_ops): Update.
1348 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1350 Turn process_stratum_target's supports_range_stepping op into a
1351 method of process_target.
1353 * target.h (struct process_stratum_target): Remove the target op.
1354 (class process_target): Add the target op.
1355 (target_supports_range_stepping): Update the macro.
1356 * target.cc (process_target::supports_range_stepping): Define.
1358 Update the derived classes and callers below.
1360 * linux-low.cc (linux_target_ops): Update.
1361 (linux_supports_range_stepping): Turn into ...
1362 (linux_process_target::supports_range_stepping): ... this.
1363 * linux-low.h (class linux_process_target): Update.
1364 * lynx-low.cc (lynx_target_ops): Update.
1365 * nto-low.cc (nto_target_ops): Update.
1366 * win32-low.cc (win32_target_ops): Update.
1368 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1370 Turn process_stratum_target's btrace-related ops (enable_btrace,
1371 disable_btrace, read_btrace, read_btrace_conf) into methods of
1374 * target.h (struct process_stratum_target): Remove the target ops.
1375 (class process_target): Add the target ops.
1376 (target_enable_btrace): Update.
1377 (target_disable_btrace): Update.
1378 (target_read_btrace): Update.
1379 (target_read_btrace_conf): Update.
1380 * target.cc (process_target::enable_btrace): Define.
1381 (process_target::disable_btrace): Define.
1382 (process_target::read_btrace): Define.
1383 (process_target::read_btrace_conf): Define.
1385 Update the derived classes and callers below.
1387 * linux-low.cc (linux_target_ops): Update.
1388 (linux_process_target:enable_btrace): Define as a wrapper around
1389 linux_enable_btrace.
1390 (linux_low_disable_btrace): Turn into ...
1391 (linux_process_target::disable_btrace): ... this.
1392 (linux_low_read_btrace): Turn into ...
1393 (linux_process_target::read_btrace): ... this.
1394 (linux_low_btrace_conf): Turn into ...
1395 (linux_process_target::read_btrace_conf): ... this.
1396 * linux-low.h (class linux_process_target): Update.
1397 * lynx-low.cc (lynx_target_ops): Update.
1398 * nto-low.cc (nto_target_ops): Update.
1399 * win32-low.cc (win32_target_ops): Update.
1401 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1403 Turn process_stratum_target's supports_agent op into a method of
1406 * target.h (struct process_stratum_target): Remove the target op.
1407 (class process_target): Add the target op.
1408 (target_supports_agent): Update the macro.
1409 * target.cc (process_target::supports_agent): Define.
1411 Update the derived classes and callers below.
1413 * linux-low.cc (linux_target_ops): Update.
1414 (linux_supports_agent): Turn into ...
1415 (linux_process_target::supports_agent): ... this.
1416 * linux-low.h (class linux_process_target): Update.
1417 * lynx-low.cc (lynx_target_ops): Update.
1418 * nto-low.cc (nto_target_ops): Update.
1419 * win32-low.cc (win32_target_ops): Update.
1421 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1423 Turn process_stratum_target's qxfer_libraries_svr4 op into a
1424 method of process_target.
1426 * target.h (struct process_stratum_target): Remove the target op.
1427 (class process_target): Add the target op. Also add
1428 'supports_qxfer_libraries_svr4'.
1429 * target.cc (process_target::qxfer_libraries_svr4): Define.
1430 (process_target::supports_qxfer_libraries_svr4): Define.
1432 Update the derived classes and callers below.
1434 * server.cc (handle_qxfer_libraries_svr4): Update.
1435 (handle_query): Update.
1436 * linux-low.cc (linux_target_ops): Update.
1437 (linux_process_target::supports_qxfer_libraries_svr4): Define.
1438 (linux_qxfer_libraries_svr4): Turn into ...
1439 (linux_process_target::qxfer_libraries_svr4): ... this.
1440 * linux-low.h (class linux_process_target): Update.
1441 * lynx-low.cc (lynx_target_ops): Update.
1442 * nto-low.cc (nto_target_ops): Update.
1443 * win32-low.cc (win32_target_ops): Update.
1445 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1447 Turn process_stratum_target's supports_disable_randomization op
1448 into a method of process_target.
1450 * target.h (struct process_stratum_target): Remove the target op.
1451 (class process_target): Add the target op.
1452 (target_supports_disable_randomization): Update the macro.
1453 * target.cc (process_target::supports_disable_randomization): Define.
1455 Update the derived classes and callers below.
1457 * linux-low.cc (linux_target_ops): Update.
1458 (linux_supports_disable_randomization): Turn into ...
1459 (linux_process_target::supports_disable_randomization): ... this.
1460 * linux-low.h (class linux_process_target): Update.
1461 * lynx-low.cc (lynx_target_ops): Update.
1462 * nto-low.cc (nto_target_ops): Update.
1463 * win32-low.cc (win32_target_ops): Update.
1465 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1467 Turn process_stratum_target's emit_ops op into a method of
1470 * target.h (struct process_stratum_target): Remove the target op.
1471 (class process_target): Add the target op.
1472 (target_emit_ops): Update the macro.
1473 * target.cc (process_target::emit_ops): Define.
1475 Update the derived classes and callers below.
1477 * linux-low.cc (linux_target_ops): Update.
1478 (linux_emit_ops): Turn into ...
1479 (linux_process_target::emit_ops): ... this.
1480 * linux-low.h (class linux_process_target): Update.
1481 * lynx-low.cc (lynx_target_ops): Update.
1482 * nto-low.cc (nto_target_ops): Update.
1483 * win32-low.cc (win32_target_ops): Update.
1485 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1487 Turn process_stratum_target's install_fast_tracepoint_jump_pad
1488 and get_min_fast_tracepoint_insn_len ops into methods of
1491 * target.h (struct process_stratum_target): Remove the target ops.
1492 (class process_target): Add the target ops. Also add
1493 'supports_fast_tracepoints'.
1494 (target_supports_fast_tracepoints): Update the macro.
1495 (target_get_min_fast_tracepoint_insn_len): Update the macro.
1496 (install_fast_tracepoint_jump_pad): Update and rename the macro
1498 (target_install_fast_tracepoint_jump_pad): ... this.
1499 * target.cc (process_target::supports_fast_tracepoints): Define.
1500 (process_target::install_fast_tracepoint_jump_pad): Define.
1501 (process_target::get_min_fast_tracepoint_insn_len): Define.
1503 Update the derived classes and callers below.
1505 * tracepoint.cc (install_fast_tracepoint): Update.
1506 * linux-low.cc (linux_target_ops): Update.
1507 (linux_process_target::supports_fast_tracepoints): Define.
1508 (linux_install_fast_tracepoint_jump_pad): Turn into ...
1509 (linux_process_target::install_fast_tracepoint_jump_pad): ... this.
1510 (linux_get_min_fast_tracepoint_insn_len): Turn into ...
1511 (linux_process_target::get_min_fast_tracepoint_insn_len): ... this.
1512 * linux-low.h (class linux_process_target): Update.
1513 * lynx-low.cc (lynx_target_ops): Update.
1514 * nto-low.cc (nto_target_ops): Update.
1515 * win32-low.cc (win32_target_ops): Update.
1517 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1519 Turn process_stratum_target's stabilize_threads op into a
1520 method of process_target.
1522 * target.h (struct process_stratum_target): Remove the target op.
1523 (class process_target): Add the target op.
1524 (target_stabilize_threads): Update the macro.
1525 * target.cc (process_target::stabilize_threads): Define.
1527 Update the derived classes and callers below.
1529 * server.cc (handle_status): Update.
1530 * tracepoint.cc (cmd_qtdp): Update.
1531 (cmd_qtstart): Update.
1532 * linux-low.cc (linux_target_ops): Update.
1533 (linux_stabilize_threads): Turn into ...
1534 (linux_process_target::stabilize_threads): ... this.
1535 (linux_wait_1): Update.
1536 * linux-low.h (class linux_process_target): Update.
1537 * lynx-low.cc (lynx_target_ops): Update.
1538 * nto-low.cc (nto_target_ops): Update.
1539 * win32-low.cc (win32_target_ops): Update.
1541 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1543 Turn process_stratum_target's pause_all and unpause_all ops
1544 into methods of process_target.
1546 * target.h (struct process_stratum_target): Remove the target ops.
1547 (class process_target): Add the target ops.
1548 (pause_all): Update the macro and rename to...
1549 (target_pause_all): ... this.
1550 (unpause_all): Update the macro and rename to...
1551 (target_unpause_all): ... this.
1552 * target.cc (process_target::pause_all): Define.
1553 (process_target::unpause_all): Define.
1555 Update the derived classes and callers below.
1557 * server.cc (handle_status): Update.
1558 * tracepoint.cc (clear_installed_tracepoints): Update.
1560 (cmd_qtstart): Update.
1561 (stop_tracing): Update.
1562 (cmd_qtstatus): Update.
1563 (upload_fast_traceframes): Update.
1564 (run_inferior_command): Update.
1565 * linux-low.cc (linux_target_ops): Update.
1566 (linux_pause_all): Turn into ...
1567 (linux_process_target::pause_all): ... this.
1568 (linux_unpause_all): Turn into ...
1569 (linux_process_target::unpause_all): ... this.
1570 (linux_process_target::prepare_to_access_memory): Update.
1571 (linux_process_target::done_accessing_memory): Update.
1572 * linux-low.h (class linux_process_target): Update.
1573 * lynx-low.cc (lynx_target_ops): Update.
1574 * nto-low.cc (nto_target_ops): Update.
1575 * win32-low.cc (win32_target_ops): Update.
1577 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1579 Turn process_stratum_target's get_tib_address op into a method of
1582 * target.h (struct process_stratum_target): Remove the target op.
1583 (class process_target): Add the target op. Also add
1584 'supports_get_tib_address'.
1585 * target.cc (process_target::get_tib_address): Define.
1586 (process_target::supports_get_tib_address): Define.
1588 Update the derived classes and callers below.
1590 * server.cc (handle_query): Update.
1591 * linux-low.cc (win32_target_ops): Update.
1592 * lynx-low.cc (lynx_target_ops): Update.
1593 * nto-low.cc (nto_target_ops): Update.
1594 * win32-low.cc (win32_target_ops): Update.
1595 (win32_process_target::supports_get_tib_address): Define.
1596 (win32_get_tib_address): Turn into ...
1597 (win32_process_target::get_tib_address): ... this.
1598 * win32-low.h (class win32_process_target): Update.
1600 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1602 Turn process_stratum_target's thread_stopped op into a method of
1605 * target.h (struct process_stratum_target): Remove the target op.
1606 (class process_target): Add the target op. Also add
1607 'supports_thread_stopped'.
1608 (target_thread_stopped): Update the macro.
1609 * target.cc (process_target::thread_stopped): Define.
1610 (process_target::supports_thread_stopped): Define.
1611 (prepare_to_access_memory): Update.
1613 Update the derived classes and callers below.
1615 * server.cc (queue_stop_reply_callback): Update.
1616 * linux-low.cc (linux_target_ops): Update.
1617 (linux_process_target::supports_thread_stopped): Define.
1618 (linux_thread_stopped): Turn into ...
1619 (linux_process_target::thread_stopped): ... this.
1620 * linux-low.h (class linux_process_target): Update.
1621 * lynx-low.cc (lynx_target_ops): Update.
1622 * nto-low.cc (nto_target_ops): Update.
1623 * win32-low.cc (win32_target_ops): Update.
1625 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1627 Turn process_stratum_target's read_pc and write_pc ops into
1628 methods of process_target.
1630 * target.h (struct process_stratum_target): Remove the target ops.
1631 (class process_target): Add the target ops.
1632 * target.cc (process_target::read_pc): Define.
1633 (process_target::write_pc): Define.
1635 Update the derived classes and callers below.
1637 * regcache.cc (regcache_read_pc): Update.
1638 (regcache_write_pc): Update.
1639 * linux-low.cc (linux_target_ops): Update.
1640 (linux_read_pc): Turn into ...
1641 (linux_process_target::read_pc): ... this.
1642 (linux_write_pc): Turn into ...
1643 (linux_process_target::write_pc): ... this.
1644 * linux-low.h (class linux_process_target): Update.
1645 * lynx-low.cc (lynx_target_ops): Update.
1646 * nto-low.cc (nto_target_ops): Update.
1647 * win32-low.cc (win32_target_ops): Update.
1649 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1651 Turn process_stratum_target's supports_tracepoints op into a
1652 method of process_target.
1654 * target.h (struct process_stratum_target): Remove the target op.
1655 (class process_target): Add the target op.
1656 (target_supports_tracepoints): Update the macro.
1657 * target.cc (process_target::supports_tracepoints): Define.
1659 Update the derived classes and callers below.
1661 * linux-low.cc (linux_target_ops): Update.
1662 (linux_supports_tracepoints): Turn into ...
1663 (linux_process_target::supports_tracepoints): ... this.
1664 * linux-low.h (class linux_process_target): Update.
1665 * lynx-low.cc (lynx_target_ops): Update.
1666 * nto-low.cc (nto_target_ops): Update.
1667 * win32-low.cc (win32_target_ops): Update.
1669 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1671 Turn process_stratum_target's process_qsupported op into a method
1674 * target.h (struct process_stratum_target): Remove the target op.
1675 (class process_target): Add the target op.
1676 (target_process_qsupported): Update the macro.
1677 * target.cc (process_target::process_qsupported): Define.
1679 Update the derived classes and callers below.
1681 * linux-low.cc (linux_target_ops): Update.
1682 (linux_process_qsupported): Turn into ...
1683 (linux_process_target::process_qsupported): ... this.
1684 * linux-low.h (class linux_process_target): Update.
1685 * lynx-low.cc (lynx_target_ops): Update.
1686 * nto-low.cc (nto_target_ops): Update.
1687 * win32-low.cc (win32_target_ops): Update.
1689 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1691 Turn process_stratum_target's read_loadmap op into a method of
1694 * target.h (struct process_stratum_target): Remove the target op.
1695 (class process_target): Add the target op. Also add
1696 'supports_read_loadmap'.
1697 * target.cc (process_target::read_loadmap): Define.
1698 (process_target::supports_read_loadmap): Define.
1700 Update the derived classes and callers below.
1702 * server.cc (handle_qxfer_fdpic): Update.
1703 (handle_query): Update.
1704 * linux-low.cc (linux_target_ops): Update.
1705 (linux_process_target::supports_read_loadmap): Define.
1706 (linux_read_loadmap): Turn into ...
1707 (linux_process_target::read_loadmap): ... this.
1708 * linux-low.h (class linux_process_target): Update.
1709 * lynx-low.cc (lynx_target_ops): Update.
1710 * nto-low.cc (nto_target_ops): Update.
1711 * win32-low.cc (win32_target_ops): Update.
1713 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1715 Turn process_stratum_target's core_of_thread op into a method of
1718 * target.h (struct process_stratum_target): Remove the target op.
1719 (class process_target): Add the target op.
1720 (target_core_of_thread): Update the macro.
1721 * target.cc (process_target::core_of_thread): Define.
1723 Update the derived classes and callers below.
1725 * linux-low.cc (linux_target_ops): Update.
1726 (linux_process_target::core_of_thread): Define.
1727 * linux-low.h (class linux_process_target): Update.
1728 * lynx-low.cc (lynx_target_ops): Update.
1729 * nto-low.cc (nto_target_ops): Update.
1730 * win32-low.cc (win32_target_ops): Update.
1732 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1734 Turn process_stratum_target's handle_monitor_command op into a
1735 method of process_target.
1737 * target.h (struct process_stratum_target): Remove the target op.
1738 (class process_target): Add the target op.
1739 (target_handle_monitor_command): Update the macro.
1740 * target.cc (process_target::handle_monitor_command): Define.
1742 Update the derived classes and callers below.
1744 * server.cc (handle_query): Update.
1745 * linux-low.cc (linux_target_ops): Update.
1746 (linux_process_target::handle_monitor_command): Define.
1747 * linux-low.h (class linux_process_target): Update.
1748 * lynx-low.cc (lynx_target_ops): Update.
1749 * nto-low.cc (nto_target_ops): Update.
1750 * win32-low.cc (win32_target_ops): Update.
1752 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1754 Turn process_stratum_target's handle_new_gdb_connection op into a
1755 method of process_target.
1757 * target.h (struct process_stratum_target): Remove the target op.
1758 (class process_target): Add the target op.
1759 (target_handle_new_gdb_connection): Update the macro.
1760 * target.cc (process_target::handle_new_gdb_connection): Define.
1762 Update the derived classes and callers below.
1764 * linux-low.cc (linux_target_ops): Update.
1765 (linux_handle_new_gdb_connection): Turn into ...
1766 (linux_process_target::handle_new_gdb_connection): ... this.
1767 * linux-low.h (class linux_process_target): Update.
1768 * lynx-low.cc (lynx_target_ops): Update.
1769 * nto-low.cc (nto_target_ops): Update.
1770 * win32-low.cc (win32_target_ops): Update.
1772 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1774 Turn process_stratum_target's supports_fork_events,
1775 supports_vfork_events, and supports_exec_events ops into methods
1778 * target.h (struct process_stratum_target): Remove the target ops.
1779 (class process_target): Add the target ops.
1780 (target_supports_fork_events): Update the macro.
1781 (target_supports_vfork_events): Update the macro.
1782 (target_supports_exec_events): Update the macro.
1783 * target.cc (process_target::supports_fork_events): Define.
1784 (process_target::supports_vfork_events): Define.
1785 (process_target::supports_exec_events): Define.
1787 Update the derived classes and callers below.
1789 * linux-low.cc (linux_target_ops): Update.
1790 (linux_supports_fork_events): Turn into ...
1791 (linux_process_target::supports_fork_events): ... this.
1792 (linux_supports_vfork_events): Turn into ...
1793 (linux_process_target::supports_vfork_events): ... this.
1794 (linux_supports_exec_events): Turn into ...
1795 (linux_process_target::supports_exec_events): ... this.
1796 * linux-low.h (class linux_process_target): Update.
1797 * lynx-low.cc (lynx_target_ops): Update.
1798 * nto-low.cc (nto_target_ops): Update.
1799 * win32-low.cc (win32_target_ops): Update.
1801 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1803 Turn process_stratum_target's supports_multi_process op into a
1804 method of process_target.
1806 * target.h (struct process_stratum_target): Remove the target op.
1807 (class process_target): Add the target op.
1808 * target.cc (process_target::supports_multi_process): Define.
1809 (target_supports_multi_process): Update.
1811 Update the derived classes and callers below.
1813 * linux-low.cc (linux_target_ops): Update.
1814 (linux_supports_multi_process): Turn into ...
1815 (linux_process_target::supports_multi_process): ... this.
1816 * linux-low.h (class linux_process_target): Update.
1817 * lynx-low.cc (lynx_target_ops): Update.
1818 * nto-low.cc (nto_target_ops): Update.
1819 * win32-low.cc (win32_target_ops): Update.
1821 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1823 Turn process_stratum_target's supports_non_stop, async, and
1824 start_non_stop ops into methods of process_target.
1826 * target.h (struct process_stratum_target): Remove the target ops.
1827 (class process_target): Add the target ops.
1828 (target_supports_non_stop): Update the macro.
1829 (target_async): Update the macro.
1830 (start_non_stop): Remove declaration.
1831 * target.cc (process_target::supports_non_stop): Define.
1832 (process_target::async): Define.
1833 (process_target::start_non_stop): Define.
1834 (start_non_stop): Remove.
1836 Update the derived classes and callers below.
1838 * server.cc (handle_qxfer_siginfo): Update.
1839 (handle_query): Update.
1840 * linux-low.cc (linux_target_ops): Update.
1841 (linux_supports_non_stop): Turn into ...
1842 (linux_process_target::supports_non_stop): ... this.
1843 (linux_async): Turn into ...
1844 (linux_process_target::async): ... this.
1845 (linux_start_non_stop): Turn into ...
1846 (linux_process_target::start_non_stop): ... this.
1847 * linux-low.h (class linux_process_target): Update.
1848 * lynx-low.cc (lynx_target_ops): Update.
1849 * nto-low.cc (nto_target_ops): Update.
1850 (nto_supports_non_stop): Remove; rely on the default behavior
1852 * win32-low.cc (win32_target_ops): Update.
1854 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1856 Turn process_stratum_target's qxfer_siginfo op into a method of
1859 * target.h (struct process_stratum_target): Remove the target op.
1860 (class process_target): Add the target op. Also add
1861 'supports_qxfer_siginfo'.
1862 * target.cc (process_target::qxfer_siginfo): Define.
1863 (process_target::supports_qxfer_siginfo): Define.
1865 Update the derived classes and callers below.
1867 * server.cc (handle_qxfer_siginfo): Update.
1868 (handle_query): Update.
1869 * linux-low.cc (linux_target_ops): Update.
1870 (linux_process_target::supports_qxfer_siginfo): Define.
1871 (linux_xfer_siginfo): Turn into ...
1872 (linux_process_target::qxfer_siginfo): ... this.
1873 * linux-low.h (class linux_process_target): Update.
1874 * lynx-low.cc (lynx_target_ops): Update.
1875 * nto-low.cc (nto_target_ops): Update.
1876 * win32-low.cc (win32_target_ops): Update.
1878 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1880 Turn process_stratum_target's qxfer_osdata op into a method of
1883 * target.h (struct process_stratum_target): Remove the target op.
1884 (class process_target): Add the target op. Also add
1885 'supports_qxfer_osdata'.
1886 * target.cc (process_target::qxfer_osdata): Define.
1887 (process_target::supports_qxfer_osdata): Define.
1889 Update the derived classes and callers below.
1891 * server.cc (handle_qxfer_osdata): Update.
1892 (handle_query): Update.
1893 * linux-low.cc (linux_target_ops): Update.
1894 (linux_process_target::supports_qxfer_osdata): Define.
1895 (linux_qxfer_osdata): Turn into ...
1896 (linux_process_target::qxfer_osdata): ... this.
1897 * linux-low.h (class linux_process_target): Update.
1898 * lynx-low.cc (lynx_target_ops): Update.
1899 * nto-low.cc (nto_target_ops): Update.
1900 * win32-low.cc (win32_target_ops): Update.
1902 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1904 Turn process_stratum_target's hostio_last_error op into a
1905 method of process_target.
1907 * target.h (struct process_stratum_target): Remove the target op.
1908 (class process_target): Add the target op.
1909 * target.cc: Add "hostio.h" to includes.
1910 (process_target::hostio_last_error): Define.
1912 Update the derived classes and callers below.
1914 * hostio.cc (hostio_error): Update.
1915 * linux-low.cc: Remove "hostio.h" from includes.
1916 (linux_target_ops): Update.
1917 * lynx-low.cc (lynx_target_ops): Update.
1918 * nto-low.cc (nto_target_ops): Update.
1919 * win32-low.h (class win32_process_target): Update.
1920 * win32-low.cc (win32_target_ops): Update.
1921 (wince_hostio_last_error): Turn into ...
1922 (win32_process_target::hostio_last_error): ... this.
1924 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1926 Turn process_stratum_target's get_tls_address op into a method of
1929 * target.h (struct process_stratum_target): Remove the target op.
1930 (class process_target): Add the target op. Also add
1931 'supports_get_tls_address'.
1932 * target.cc (process_target::get_tls_address): Define.
1933 (process_target::supports_get_tls_address): Define.
1935 Update the derived classes and callers below.
1937 * server.cc (handle_query): Update.
1938 * linux-low.cc (linux_target_ops): Update.
1939 (linux_process_target::supports_get_tls_address): Define.
1940 (linux_process_target::get_tls_address): Define.
1941 * linux-low.h (class linux_process_target): Update.
1942 * lynx-low.cc (lynx_target_ops): Update.
1943 * nto-low.cc (nto_target_ops): Update.
1944 * win32-low.cc (win32_target_ops): Update.
1946 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1948 Turn process_stratum_target's read_offsets op into a method of
1951 * target.h (struct process_stratum_target): Remove the target op.
1952 (class process_target): Add the target op. Also add
1953 'supports_read_offsets'.
1954 * target.cc (process_target::read_offsets): Define.
1955 (process_target::supports_read_offsets): Define.
1957 Update the derived classes and callers below.
1959 * server.cc (handle_query): Update.
1960 * linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
1961 (linux_target_ops): Update.
1962 (linux_process_target::supports_read_offsets): Define.
1963 (linux_read_offsets): Turn into ...
1964 (linux_process_target::read_offsets): ... this.
1965 * linux-low.h (class linux_process_target): Update.
1966 * lynx-low.cc (lynx_target_ops): Update.
1967 * nto-low.cc (nto_target_ops): Update.
1968 * win32-low.cc (win32_target_ops): Update.
1970 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1972 Turn process_stratum_target's stopped_by_watchpoint and
1973 stopped_data_address ops into methods of process_target.
1975 * target.h (struct process_stratum_target): Remove the target ops.
1976 (class process_target): Add the target ops.
1977 * target.cc (process_target::stopped_by_watchpoint): Define.
1978 (process_target::stopped_data_address): Define.
1980 Update the derived classes and callers below.
1982 * remote-utils.cc (prepare_resume_reply): Update.
1983 * linux-low.cc (linux_target_ops): Update.
1984 (linux_stopped_by_watchpoint): Turn into ...
1985 (linux_process_target::stopped_by_watchpoint): ... this.
1986 (linux_stopped_data_address): Turn into ...
1987 (linux_process_target::stopped_data_address): ... this.
1988 * linux-low.h (class linux_process_target): Update.
1989 * lynx-low.cc (lynx_target_ops): Update.
1990 * nto-low.cc (nto_target_ops): Update.
1991 (nto_stopped_by_watchpoint): Turn into ...
1992 (nto_process_target::stopped_by_watchpoint): ... this.
1993 (nto_stopped_data_address): Turn into ...
1994 (nto_process_target::stopped_data_address): ... this.
1995 * nto-low.h (class nto_process_target): Update.
1996 * win32-low.cc (win32_target_ops): Update.
1997 (win32_stopped_by_watchpoint): Turn into ...
1998 (win32_process_target::stopped_by_watchpoint): ... this.
1999 (win32_stopped_data_address): Turn into ...
2000 (win32_process_target::stopped_data_address): ... this.
2001 * win32-low.h (class win32_process_target): Update.
2003 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2005 Turn process_stratum_target's supports_hardware_single_step op into
2006 a method of process_target.
2008 * target.h (struct process_stratum_target): Remove the target op.
2009 (class process_target): Add the target op.
2010 (target_supports_hardware_single_step): Update the macro.
2011 (target_can_do_hardware_single_step): Remove declaration.
2012 * target.cc (process_target::supports_hardware_single_step): Define.
2013 (target_can_do_hardware_single_step): Remove.
2015 Update the derived classes and callers below.
2017 * linux-low.h (class linux_process_target): Update.
2018 * linux-low.cc (linux_target_ops): Update.
2019 (linux_supports_hardware_single_step): Turn into ...
2020 (linux_process_target::supports_hardware_single_step): ... this.
2021 * lynx-low.h (class lynx_process_target): Update.
2022 * lynx-low.cc (lynx_target_ops): Update.
2023 (lynx_process_target::supports_hardware_single_step): Define.
2024 * nto-low.h (class nto_process_target): Update.
2025 * nto-low.cc (nto_target_ops): Update.
2026 (nto_process_target::supports_hardware_single_step): Define.
2027 * win32-low.h (class win32_process_target): Update.
2028 * win32-low.cc (win32_target_ops): Update.
2029 (win32_process_target::supports_hardware_single_step): Define.
2031 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2033 Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
2034 ops into methods of process_target.
2036 * target.h (struct process_stratum_target): Remove the target ops.
2037 (class process_target): Add the target ops.
2038 (target_stopped_by_hw_breakpoint): Update the macro.
2039 (target_supports_stopped_by_hw_breakpoint): Update the macro.
2040 * target.cc (process_target::stopped_by_hw_breakpoint): Define.
2041 (process_target::supports_stopped_by_hw_breakpoint): Define.
2043 Update the derived classes and callers below.
2045 * linux-low.cc (linux_target_ops): Update.
2046 (linux_stopped_by_hw_breakpoint): Turn into ...
2047 (linux_process_target::stopped_by_hw_breakpoint): ... this.
2048 (linux_supports_stopped_by_hw_breakpoint): Turn into ...
2049 (linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
2050 * linux-low.h (class linux_process_target): Update.
2051 * lynx-low.cc (lynx_target_ops): Update.
2052 * nto-low.cc (nto_target_ops): Update.
2053 * win32-low.cc (win32_target_ops): Update.
2055 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2057 Turn process_stratum_target's {supports_}stopped_by_sw_breakpoint
2058 ops into methods of process_target.
2060 * target.h (struct process_stratum_target): Remove the target ops.
2061 (class process_target): Add the target ops.
2062 (target_stopped_by_sw_breakpoint): Update the macro.
2063 (target_supports_stopped_by_sw_breakpoint): Update the macro.
2064 * target.cc (process_target::stopped_by_sw_breakpoint): Define.
2065 (process_target::supports_stopped_by_sw_breakpoint): Define.
2067 Update the derived classes and callers below.
2069 * linux-low.cc (linux_target_ops): Update.
2070 (linux_stopped_by_sw_breakpoint): Turn into ...
2071 (linux_process_target::stopped_by_sw_breakpoint): ... this.
2072 (linux_supports_stopped_by_sw_breakpoint): Turn into ...
2073 (linux_process_target::supports_stopped_by_sw_breakpoint): ... this.
2074 * linux-low.h (class linux_process_target): Update.
2075 * lynx-low.cc (lynx_target_ops): Update.
2076 * nto-low.cc (nto_target_ops): Update.
2077 * win32-low.cc (win32_target_ops): Update.
2079 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2081 Turn process_stratum_target's insert_point and remove_point ops
2082 into methods of process_target.
2084 * target.h (struct process_stratum_target): Remove the target ops.
2085 (class process_target): Add the target ops.
2086 * target.cc (process_target::insert_point): Define.
2087 (process_target::remove_point): Define.
2089 Update the derived classes and callers below.
2091 * mem-break.cc (set_raw_breakpoint_at): Update.
2092 (delete_raw_breakpoint): Update.
2093 (uninsert_raw_breakpoint): Update.
2094 (reinsert_raw_breakpoint): Update.
2095 * linux-low.cc (linux_target_ops): Update.
2096 (linux_insert_point): Turn into ...
2097 (linux_process_target::insert_point): ... this.
2098 (linux_remove_point): Turn into ...
2099 (linux_process_target::remove_point): ... this.
2100 * linux-low.h (class linux_process_target): Update.
2101 * lynx-low.cc (lynx_target_ops): Update.
2102 * nto-low.cc (nto_target_ops): Update.
2103 (nto_insert_point): Turn into ...
2104 (nto_process_target::insert_point): ... this.
2105 (nto_remove_point): Turn into ...
2106 (nto_process_target::remove_point): ... this.
2107 * nto-low.h (class nto_process_target): Update.
2108 * win32-low.cc (win32_target_ops): Update.
2109 (win32_insert_point): Turn into ...
2110 (win32_process_target::insert_point): ... this.
2111 (win32_remove_point): Turn into ...
2112 (win32_process_target::remove_point): ... this.
2113 * win32-low.h (class win32_process_target): Update.
2115 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2117 Turn process_stratum_target's supports_z_point_type op into a
2118 method of process_target.
2120 * target.h (struct process_stratum_target): Remove the target op.
2121 (class process_target): Add the target op.
2122 * target.cc (process_target::supports_z_point_type): Define.
2124 Update the derived classes and callers below.
2126 * mem-break.cc (z_type_supported): Update.
2127 * linux-low.cc (linux_target_ops): Update.
2128 (linux_supports_z_point_type): Turn into ...
2129 (linux_process_target::supports_z_point_type): ... this.
2130 * linux-low.h (class linux_process_target): Update.
2131 * lynx-low.cc (lynx_target_ops): Update.
2132 * nto-low.cc (nto_target_ops): Update.
2133 (nto_supports_z_point_type): Turn into ...
2134 (nto_process_target::supports_z_point_type): ... this.
2135 * nto-low.h (class nto_process_target): Update.
2136 * win32-low.cc (win32_target_ops): Update.
2137 (win32_supports_z_point_type): Turn into ...
2138 (win32_process_target::supports_z_point_type): ... this.
2139 * win32-low.h (class win32_process_target): Update.
2141 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2143 Turn process_stratum_target's read_auxv op into a method of
2146 * target.h (class process_stratum_target): Remove the target op.
2147 (struct process_target): Add the target op. Also add
2148 'supports_read_auxv'.
2149 * target.cc (process_target::read_auxv): Define.
2150 (process_target::supports_read_auxv): Define.
2152 Update the derived classes and callers below.
2154 * server.cc (handle_qxfer_auxv): Update.
2155 (handle_query): Update.
2156 * linux-low.cc (linux_target_ops): Update.
2157 (linux_process_target::supports_read_auxv): Define.
2158 (linux_read_auxv): Turn into ...
2159 (linux_process_target::read_auxv): ... this.
2160 * linux-low.h (class linux_process_target): Update.
2161 * lynx-low.cc (lynx_target_ops): Update.
2162 * nto-low.cc (nto_target_ops): Update.
2163 (nto_process_target::supports_read_auxv): Define.
2164 (nto_read_auxv): Turn into ...
2165 (nto_process_target::read_auxv): ... this.
2166 * nto-low.h (class nto_process_target): Update.
2167 * win32-low.cc (win32_target_ops): Update.
2169 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2171 Turn process_stratum_target's request_interrupt op into a method of
2174 * target.h (struct process_stratum_target): Remove the target op.
2175 (class process_target): Add the target op.
2177 Update the derived classes and callers below.
2179 * remote-utils.cc (putpkt_binary_1): Update.
2180 (input_interrupt): Update.
2182 * server.cc (handle_v_requests): Update.
2183 * linux-low.cc (linux_target_ops): Update.
2184 (linux_request_interrupt): Turn into ...
2185 (linux_process_target::request_interrupt): ... this.
2186 * linux-low.h (class linux_process_target): Update.
2187 * lynx-low.cc (lynx_target_ops): Update.
2188 (lynx_request_interrupt): Turn into ...
2189 (lynx_process_target::request_interrupt): ... this.
2190 * lynx-low.h (class lynx_process_target): Update.
2191 * nto-low.cc (nto_target_ops): Update.
2192 (nto_request_interrupt): Turn into ...
2193 (nto_process_target::request_interrupt): ... this.
2194 * nto-low.h (class nto_process_target): Update.
2195 * win32-low.cc (win32_target_ops): Update.
2196 (win32_request_interrupt): Turn into ...
2197 (win32_process_target::request_interrupt): ... this.
2198 * win32-low.h (class win32_process_target): Update.
2200 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2202 Turn process_stratum_target's look_up_symbols op into a method of
2205 * target.h (struct process_stratum_target): Remove the target op.
2206 (class process_target): Add the target op.
2207 * target.cc (process_target::look_up_symbols): Define.
2209 Update the derived classes and callers below.
2211 * server.cc (handle_query): Update.
2212 * linux-low.cc (linux_target_ops): Update.
2213 (linux_look_up_symbols): Turn into ...
2214 (linux_process_target::look_up_symbols): ... this.
2215 * linux-low.h (class linux_process_target): Update.
2216 * lynx-low.cc (lynx_target_ops): Update.
2217 * nto-low.cc (nto_target_ops): Update.
2218 * win32-low.cc (win32_target_ops): Update.
2220 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2222 Turn process_stratum_target's read_memory and write_memory
2223 ops into methods of process_target.
2225 * target.h (struct process_stratum_target): Remove the target ops.
2226 (class process_target): Add the target ops.
2228 Update the derived classes and callers below.
2230 * linux-aarch32-low.cc (arm_breakpoint_at): Update.
2231 * linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
2232 * linux-arm-low.cc (arm_sigreturn_next_pc): Update.
2233 (arm_get_syscall_trapinfo): Update.
2234 * linux-cris-low.cc (cris_breakpoint_at): Update.
2235 * linux-crisv32-low.cc (cris_breakpoint_at): Update.
2236 * linux-m32r-low.cc (m32r_breakpoint_at): Update.
2237 * linux-mips-low.cc (mips_breakpoint_at): Update.
2238 * linux-nios2-low.cc (nios2_breakpoint_at): Update.
2239 * linux-ppc-low.cc (ppc_breakpoint_at): Update.
2240 * linux-sh-low.cc (sh_breakpoint_at): Update.
2241 * linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
2242 (sparc_store_gregset_from_stack): Update.
2243 (sparc_breakpoint_at): Update.
2244 * linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
2245 * linux-tile-low.cc (tile_breakpoint_at): Update.
2246 * linux-x86-low.cc (x86_breakpoint_at): Update.
2247 * linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
2248 * mem-brea.cc (insert_memory_breakpoint): Update.
2249 (validate_inserted_breakpoint): Update.
2250 * target.cc (read_inferior_memory): Update.
2251 (target_write_memory): Update.
2252 * linux-low.cc (linux_target_ops): Update.
2253 (linux_read_memory): Make a wrapper around the read_memory target
2255 (linux_process_target::read_memory): Rename from linux_read_memory.
2256 (linux_write_memory): Turn into ...
2257 (linux_process_target::write_memory): ... this.
2258 * linux-low.h (class linux_process_target): Update.
2259 * lynx-low.cc (lynx_target_ops): Update.
2260 (lynx_read_memory): Turn into ...
2261 (lynx_process_target::read_memory): ... this.
2262 (lynx_write_memory): Turn into ...
2263 (lynx_process_target::write_memory): ... this.
2264 * lynx-low.h (class lynx_process_target): Update.
2265 * nto-low.cc (nto_target_ops): Update.
2266 (nto_read_memory): Turn into ...
2267 (nto_process_target::read_memory): ... this.
2268 (nto_write_memory): Turn into ...
2269 (nto_process_target::write_memory): ... this.
2270 * nto-low.h (class nto_process_target): Update.
2271 * win32-low.cc (win32_target_ops): Update.
2272 (win32_read_inferior_memory): Turn into ...
2273 (win32_process_target::read_memory): ... this.
2274 (win32_write_inferior_memory): Turn into ...
2275 (win32_process_target::write_memory): ... this.
2276 * win32-low.h (class win32_process_target): Update.
2278 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2280 Turn process_stratum_target's prepare_to_access_memory and
2281 done_accessing_memory ops into methods of process_target.
2283 * target.h (struct process_stratum_target): Remove the target ops.
2284 (class process_target): Add the target ops.
2285 * target.cc (process_target::prepare_to_access_memory): Define.
2286 (process_target::done_accessing_memory): Define.
2287 (prepare_to_access_memory): Update.
2288 (done_accessing_memory): Update.
2290 Update the derived classes and callers below.
2292 * linux-low.cc (linux_target_ops): Update.
2293 (linux_prepare_to_access_memory): Turn into ...
2294 (linux_process_target::prepare_to_access_memory): ... this.
2295 (linux_done_accessing_memory): Turn into ...
2296 (linux_process_target::done_accessing_memory): ... this.
2297 * linux-low.h (class linux_process_target): Update.
2298 * lynx-low.cc (lynx_target_ops): Update.
2299 * nto-low.cc (nto_target_ops): Update.
2300 * win32-low.cc (win32_target_ops): Update.
2302 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2304 Turn process_stratum_target's fetch_registers and store_registers
2305 ops into methods of process_target.
2307 * target.h (struct process_stratum_target): Remove the target ops.
2308 (class process_target): Add the target ops.
2309 (fetch_inferior_registers): Update the macro.
2310 (store_inferior_registers): Update the macro.
2312 Update the derived classes and callers below.
2314 * linux-low.cc (linux_target_ops): Update.
2315 (linux_fetch_registers): Turn into ...
2316 (linux_process_target::fetch_registers): ... this.
2317 (linux_store_registers): Turn into ...
2318 (linux_process_target::store_registers): ... this.
2319 * linux-low.h (class linux_process_target): Update.
2320 * lynx-low.cc (lynx_target_ops): Update.
2321 (lynx_fetch_registers): Turn into ...
2322 (lynx_process_target::fetch_registers): ... this.
2323 (lynx_store_registers): Turn into ...
2324 (lynx_process_target::store_registers): ... this.
2325 * lynx-low.h (class lynx_process_target): Update.
2326 * nto-low.cc (nto_target_ops): Update.
2327 (nto_fetch_registers): Turn into ...
2328 (nto_process_target::fetch_registers): ... this.
2329 (nto_store_registers): Turn into ...
2330 (nto_process_target::store_registers): ... this.
2331 * nto-low.h (class nto_process_target): Update.
2332 * win32-low.cc (win32_target_ops): Update.
2333 (win32_fetch_inferior_registers): Turn into ...
2334 (win32_process_target::fetch_registers): ... this.
2335 (win32_store_inferior_registers): Turn into ...
2336 (win32_process_target::store_registers): ... this.
2337 * win32-low.h (class win32_process_target): Update.
2339 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2341 Turn process_stratum_target's wait op into a method of
2344 * target.h (struct process_stratum_target): Remove the target op.
2345 (class process_target): Add the target op.
2347 Update the derived classes and callers below.
2349 * target.cc (target_wait): Update.
2350 * linux-low.cc (linux_target_ops): Update.
2351 (linux_wait): Turn into ...
2352 (linux_process_target::wait): ... this.
2353 * linux-low.h (class linux_process_target): Update.
2354 * lynx-low.cc (lynx_target_ops): Update.
2355 (lynx_wait): Turn into ...
2356 (lynx_process_target::wait): ... this.
2357 * lynx-low.h (class lynx_process_target): Update.
2358 * nto-low.cc (nto_target_ops): Update.
2359 (nto_wait): Turn into ...
2360 (nto_process_target::wait): ... this.
2361 * nto-low.h (class nto_process_target): Update.
2362 * win32-low.cc (win32_target_ops): Update.
2363 (win32_wait): Turn into ...
2364 (win32_process_target::wait): ... this.
2365 (do_initial_child_stuff): Update.
2366 * win32-low.h (class win32_process_target): Update.
2368 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2370 Turn process_stratum_target's resume op into a method of
2373 * target.h (struct process_stratum_target): Remove the target op.
2374 (class process_target): Add the target op.
2376 Update the derived classes and callers below.
2378 * server.cc (resume): Update.
2379 * target.cc (target_stop_and_wait): Update.
2380 (target_continue_no_signal): Update.
2381 (target_continue): Update.
2382 * linux-low.cc (linux_target_ops): Update.
2383 (linux_resume): Turn into ...
2384 (linux_process_target::resume): ... this.
2385 * linux-low.h (class linux_process_target): Update.
2386 * lynx-low.cc (lynx_target_ops): Update.
2387 (lynx_resume): Turn into ...
2388 (lynx_process_target::resume): ... this.
2389 * lynx-low.h (class lynx_process_target): Update.
2390 * nto-low.cc (nto_target_ops): Update.
2391 (nto_resume): Turn into ...
2392 (nto_process_target::resume): ... this.
2393 * nto-low.h (class nto_process_target): Update.
2394 * win32-low.cc (win32_target_ops): Update.
2395 (win32_resume): Turn into ...
2396 (win32_process_target::resume): ... this.
2397 (win32_process_target::detach): Update.
2398 (do_initial_child_stuff): Update.
2399 * win32-low.h (class win32_process_target): Update.
2401 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2403 Turn process_stratum_target's thread_alive op into a method of
2406 * target.h (struct process_stratum_target): Remove the target op.
2407 (class process_target): Add the target op.
2408 (mythread_alive): Update the macro.
2410 Update the derived classes and callers below.
2412 * linux-low.cc (linux_target_ops): Update.
2413 (linux_thread_alive): Turn into ...
2414 (linux_process_target::thread_alive): ... this.
2415 (wait_for_sigstop): Update.
2416 * linux-low.h (class linux_process_target): Update.
2417 * lynx-low.cc (lynx_target_ops): Update.
2418 (lynx_thread_alive): Turn into ...
2419 (lynx_process_target::thread_alive): ... this.
2420 * lynx-low.h (class lynx_process_target): Update.
2421 * nto-low.cc (nto_target_ops): Update.
2422 (nto_thread_alive): Turn into ...
2423 (nto_process_target::thread_alive): ... this.
2424 * nto-low.h (class nto_process_target): Update.
2425 * win32-low.cc (win32_target_ops): Update.
2426 (win32_thread_alive): Turn into ...
2427 (win32_process_target::thread_alive): ... this.
2428 * win32-low.h (class win32_process_target): Update.
2430 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2432 Turn process_stratum_target's join op into a method of
2435 * target.h (struct process_stratum_target): Remove the target op.
2436 (class process_target): Add the target op.
2437 (join_inferior): Update the macro.
2439 Update the derived classes and callers below.
2441 * linux-low.cc (linux_target_ops): Update.
2442 (linux_join): Turn into ...
2443 (linux_process_target::join): ... this.
2444 * linux-low.h (class linux_process_target): Update.
2445 * lynx-low.cc (lynx_target_ops): Update.
2446 (lynx_join): Turn into ...
2447 (lynx_process_target::join): ... this.
2448 * lynx-low.h (class lynx_process_target): Update.
2449 * nto-low.cc (nto_target_ops): Update.
2450 (nto_process_target::join): Define.
2451 * nto-low.h (class nto_process_target): Update.
2452 * win32-low.cc (win32_target_ops): Update.
2453 (win32_join): Turn into ...
2454 (win32_process_target::join): ... this.
2455 * win32-low.h (class win32_process_target): Update.
2457 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2459 Turn process_stratum_target's mourn op into a method of
2462 * target.h (struct process_stratum_target): Remove the target op.
2463 (class process_target): Add the target op.
2465 Update the derived classes and callers below.
2467 * target.cc (target_mourn_inferior): Update.
2468 * linux-low.cc (linux_target_ops): Update.
2469 (linux_mourn): Turn into ...
2470 (linux_process_target::mourn): ... this.
2471 (handle_extended_wait): Update.
2472 (linux_process_target::kill): Update.
2473 (linux_process_target::detach): Update.
2474 * linux-low.h (class linux_process_target): Update.
2475 * lynx-low.cc (lynx_target_ops): Update.
2476 (lynx_mourn): Turn into ...
2477 (lynx_process_target::mourn): ... this.
2478 * lynx-low.h (class lynx_process_target): Update.
2479 * nto-low.cc (nto_target_ops): Update.
2480 (nto_mourn): Turn into ...
2481 (nto_process_target::mourn): ... this.
2482 * nto-low.h (class nto_process_target): Update.
2483 * win32-low.cc (win32_target_ops): Update.
2484 (win32_mourn): Turn into ...
2485 (win32_process_target::mourn): ... this.
2486 * win32-low.h (class win32_process_target): Update.
2488 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2490 Turn process_stratum_target's detach op into a method of
2493 * target.h (struct process_stratum_target): Remove the target op.
2494 (class process_target): Add the target op.
2495 (detach_inferior): Update the macro.
2497 Update the derived classes and callers below.
2499 * linux-low.cc (linux_target_ops): Update.
2500 (linux_detach): Turn into ...
2501 (linux_process_target::detach): ... this.
2502 * linux-low.h (class linux_process_target): Update.
2503 * lynx-low.cc (lynx_target_ops): Update.
2504 (lynx_detach): Turn into ...
2505 (lynx_process_target::detach): ... this.
2506 * lynx-low.h (class lynx_process_target): Update.
2507 * nto-low.cc (nto_target_ops): Update.
2508 (nto_detach): Turn into ...
2509 (nto_process_target::detach): ... this.
2510 * nto-low.h (class nto_process_target): Update.
2511 * win32-low.cc (win32_target_ops): Update.
2512 (win32_detach): Turn into ...
2513 (win32_process_target::detach): ... this.
2514 * win32-low.h (class win32_process_target): Update.
2516 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2518 Turn process_stratum_target's kill op into a method of
2521 * target.h (struct process_stratum_target): Remove the target op.
2522 (class process_target): Add the target op.
2524 Update the derived classes and callers below.
2526 * target.cc (kill_inferior): Update.
2527 * linux-low.cc (linux_target_ops): Update.
2528 (linux_kill): Turn into ...
2529 (linux_process_target::kill): ... this.
2530 * linux-low.h (class linux_process_target): Update.
2531 * lynx-low.cc (lynx_target_ops): Update.
2532 (lynx_kill): Turn into ...
2533 (lynx_process_target::kill): ... this.
2534 * lynx-low.h (class lynx_process_target): Update.
2535 * nto-low.cc (nto_target_ops): Update.
2536 (nto_kill): Turn into ...
2537 (nto_process_target::kill): ... this.
2538 * nto-low.h (class nto_process_target): Update.
2539 * win32-low.cc (win32_target_ops): Update.
2540 (win32_kill): Turn into ...
2541 (win32_process_target::kill): ... this.
2542 * win32-low.h (class win32_process_target): Update.
2544 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2546 Turn process_stratum_target's attach op into a method of
2549 * target.h (struct process_stratum_target): Remove the target op.
2550 (class process_target): Add the target op.
2551 (myattach): Update the macro.
2553 Update the derived classes and callers below.
2555 * linux-low.cc (linux_target_ops): Update.
2556 (linux_attach): Turn into ...
2557 (linux_process_target::attach): ... this.
2558 * linux-low.h (class linux_process_target): Update.
2559 * lynx-low.cc (lynx_target_ops): Update.
2560 (lynx_attach): Turn into ...
2561 (lynx_process_target::attach): ... this.
2562 * lynx-low.h (class lynx_process_target): Update.
2563 * nto-low.cc (nto_target_ops): Update.
2564 (nto_attach): Turn into ...
2565 (nto_process_target::attach): ... this.
2566 * nto-low.h (class nto_process_target): Update.
2567 * win32-low.cc (win32_target_ops): Update.
2568 (win32_attach): Turn into ...
2569 (win32_process_target::attach): ... this.
2570 * win32-low.h (class win32_process_target): Update.
2572 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2574 Turn process_stratum_target's post_create_inferior op into a method
2577 * target.h (struct process_stratum_target): Remove the target op.
2578 (class process_target): Add the target op.
2579 (target_post_create_inferior): Update the macro.
2580 * target.cc (process_target::post_create_inferior): Define.
2582 Update the derived classes and callers below.
2584 * linux-low.cc (linux_target_ops): Update.
2585 (linux_post_create_inferior): Turn into ...
2586 (linux_process_target::post_create_inferior): ... this.
2587 * linux-low.h (class linux_process_target): Update.
2588 * lynx-low.cc (lynx_target_ops): Update.
2589 * nto-low.cc (nto_target_ops): Update.
2590 * win32-low.cc (win32_target_ops): Update.
2592 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2594 Turn process_stratum_target's create_inferior op into a method of
2597 * target.h (struct process_stratum_target): Remove the target op.
2598 (class process_target): Add the target op.
2599 (create_inferior): Rename the macro to ...
2600 (target_create_inferior): ... this.
2602 Update the derived classes and callers below.
2604 * server.cc (handle_v_run): Update.
2605 (captured_main): Update.
2606 (process_serial_event): Update.
2607 * linux-low.cc (linux_target_ops): Update.
2608 (linux_create_inferior): Turn into ...
2609 (linux_process_target::create_inferior): ... this.
2610 * linux-low.h (class linux_process_target): Update.
2611 * lynx-low.cc (lynx_target_ops): Update.
2612 (lynx_create_inferior): Turn into ...
2613 (lynx_process_target::create_inferior): ... this.
2614 * lynx-low.h (class lynx_process_target): Update.
2615 * nto-low.cc (nto_target_ops): Update.
2616 (nto_create_inferior): Turn into ...
2617 (nto_process_target::create_inferior): ... this.
2618 * nto-low.h (class nto_process_target): Update.
2619 * win32-low.cc (win32_target_ops): Update.
2620 (win32_create_inferior): Turn into ...
2621 (win32_process_target::create_inferior): ... this.
2622 * win32-low.h (class win32_process_target): Update.
2624 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2626 * target.h (class process_target): New class definition.
2627 (struct process_stratum_target) <pt>: New field with type
2629 * linux-low.h (class linux_process_target): Define as a derived
2630 class of 'process_target'.
2631 * linux-low.cc (linux_target_ops): Add a linux_process_target*
2633 * lynx-low.h (class lynx_process_target): Define as a derived
2634 class of 'process_target'.
2635 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
2637 * nto-low.h (class nto_process_target): Define as a derived
2638 class of 'process_target'.
2639 * nto-low.cc (nto_target_ops): Add an nto_process_target*
2641 * win32-low.h (class win32_process_target): Define as a derived
2642 class of 'process_target'.
2643 * win32-low.cc (win32_target_ops): Add a win32_process_target*
2646 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
2648 * configure: Regenerate.
2650 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
2651 Andrew Burgess <andrew.burgess@embecosm.com>
2653 * linux-riscv-low.cc: New file.
2654 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
2655 and nat/riscv-linux-tdesc.c.
2656 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
2657 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
2660 2020-02-14 Tom Tromey <tom@tromey.com>
2662 * acinclude.m4: Don't include acx_configure_dir.m4.
2663 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
2664 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
2665 (all, install-only, uninstall, clean-info, clean)
2666 (maintainer-clean): Don't recurse.
2667 (subdir_do, all-lib): Remove.
2668 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
2670 (generated_files): Update.
2671 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
2672 * configure: Rebuild.
2673 * configure.ac: Don't configure gnulib or libiberty.
2676 2020-02-14 Eli Zaretskii <eliz@gnu.org>
2678 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
2679 preparing the command line for CreateProcess.
2680 (win32_create_inferior): Reflect the program name in debugging
2681 output that shows the process and its command line.
2683 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
2685 * Makefile.in: Rename source files from .c to .cc.
2686 * %.c: Rename to %.cc.
2687 * configure.ac: Rename server.c to server.cc.
2688 * configure: Re-generate.
2690 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
2692 * Makefile.in: Rename gdbsupport source files from .c to .cc.
2694 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
2696 * win32-low.c (win32_create_inferior): Set signal_pid.
2698 2020-02-12 Maciej W. Rozycki <macro@wdc.com>
2699 Pedro Alves <palves@redhat.com>
2701 Skip building gdbserver in a cross-configuration.
2702 * configure.srv: Set $gdbserver_host depending on whether $target
2703 is $host. Use $gdbserver_host instead of $host.
2705 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
2707 * configure: Re-generate.
2709 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
2711 * configure: Re-generate.
2713 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
2715 * acinclude.m4: Update warning.m4 path.
2717 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
2719 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
2720 (handle_exception): Set siginfo_er.
2721 (win32_xfer_siginfo): New function.
2723 2020-02-07 Tom Tromey <tom@tromey.com>
2724 Pedro Alves <palves@redhat.com>
2726 * README: Update build documentation.
2727 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
2729 * configure.ac: Update paths.
2730 * configure: Rebuild.
2731 * acinclude.m4: Update paths.
2732 * Makefile.in: Update include paths.
2733 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
2734 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
2735 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
2736 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
2737 (%-generated.c): Update paths.
2738 * Move entire directory from ../gdb/gdbserver.
2740 2020-01-29 Maciej W. Rozycki <macro@wdc.com>
2742 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
2744 2020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2746 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
2747 assignment instead of srv_linux_obj.
2749 2020-01-28 Hannes Domani <ssbssa@yahoo.de>
2751 * server.c (handle_qxfer_libraries): Write segment-address with
2754 2020-01-24 Hannes Domani <ssbssa@yahoo.de>
2756 * Makefile.in (install-strip): New target.
2757 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
2758 * aclocal.m4: Regenerate.
2759 * configure: Regenerate.
2760 * configure.ac: Add AM_PROG_INSTALL_STRIP.
2762 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
2764 * Makefile.in (SFILES): Adjust paths to point to real files.
2765 (OBS): Move waitstatus.o to target/waitstatus.o.
2766 (TAGS): Transform paths appropriately.
2768 (nat/%.o): ... this pattern rule.
2770 (target/%.o): ... this pattern rule.
2771 * configure.srv: Adjust paths throughout to include nat/ prefix
2772 with the revant files.
2773 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
2774 * configure: Regenerate.
2776 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
2778 * Makefile.in (TAGS): Remove config files from the recipe.
2780 2020-01-14 Tom Tromey <tom@tromey.com>
2782 * configure: Rebuild.
2783 * configure.ac: Remove any checks that were added to common.m4.
2784 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
2787 2020-01-14 Tom Tromey <tom@tromey.com>
2789 * server.h: Include config.h.
2790 * gdbreplay.c: Include config.h.
2791 * configure: Rebuild.
2792 * configure.ac: Don't source common.host.
2793 * acinclude.m4: Update path.
2794 * Makefile.in (INCSUPPORT): New variable.
2795 (INCLUDE_CFLAGS): Add INCSUPPORT.
2796 (SFILES): Update paths.
2797 (version-generated.c): Update path to create-version.sh.
2798 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
2800 2020-01-14 Tom Tromey <tom@tromey.com>
2802 * configure.ac (LIBS): Use WIN32APILIBS.
2803 (USE_WIN32API): Don't define.
2804 * configure: Rebuild.
2806 2020-01-14 Tom Tromey <tom@tromey.com>
2808 * configure: Rebuild.
2810 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
2812 * Makefile.in (%-generated.c): Remove rule for files from
2815 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
2817 * configure: Re-generate.
2819 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
2821 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
2823 * tracepoint.c (stop_tracing, flush_trace_buffer,
2824 about_to_request_buffer_space, get_trace_state_variable_value,
2825 set_trace_state_variable_value, gdb_collect): Add declaration.
2827 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
2829 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
2830 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
2831 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
2832 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
2833 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
2836 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
2838 * inferiors.c: Include gdbsupport/common-inferior.h.
2840 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
2842 * hostio-errno.c: Include hostio.h.
2844 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
2846 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
2849 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
2851 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
2852 * linux-arm-tdesc.h: Include arch/arm.h.
2854 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
2856 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
2858 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
2860 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
2861 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
2863 2020-01-10 Pedro Alves <palves@redhat.com>
2865 * fork-child.c (post_fork_inferior): Pass target down to
2867 * inferiors.c (switch_to_thread): Add process_stratum_target
2869 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
2870 * nto-low.c (nto_target_ops): Now a process_stratum_target.
2871 * linux-low.c (linux_target_ops): Now a process_stratum_target.
2872 * remote-utils.c (prepare_resume_reply): Pass the target to
2874 * target.c (the_target): Now a process_stratum_target.
2875 (done_accessing_memory): Pass the target to switch_to_thread.
2876 (set_target_ops): Ajust to use process_stratum_target.
2877 * target.h (struct target_ops): Rename to ...
2878 (struct process_stratum_target): ... this.
2879 (the_target, set_target_ops): Adjust.
2880 (prepare_to_access_memory): Adjust comment.
2881 * win32-low.c (child_xfer_memory): Adjust to use
2882 process_stratum_target.
2883 (win32_target_ops): Now a process_stratum_target.
2885 2020-01-06 Eli Zaretskii <eliz@gnu.org>
2886 Pedro Alves <palves@redhat.com>
2888 * win32-low.c (get_child_debug_event): Extract the fatal exception
2889 from the exit status and convert to the equivalent Posix signal
2891 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
2892 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
2894 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
2896 * Makefile.in: Use INSTALL_PROGRAM_ENV.
2898 2020-01-01 Joel Brobecker <brobecker@adacore.com>
2900 * server.c (gdbserver_version): Change copyright year to 2020.
2901 * gdbreplay.c (gdbreplay_version): Likewise.
2903 2019-12-19 Christian Biesinger <cbiesinger@google.com>
2905 * configure: Regenerate.
2906 * configure.ac: Quote variable arguments of test.
2908 2019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
2910 * Makefile.in: Fix build with GNU Make 3.81
2912 2019-12-16 Tom Tromey <tromey@adacore.com>
2914 * server.c (get_exec_file): Constify result.
2916 2019-12-10 Christian Biesinger <cbiesinger@google.com>
2918 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
2919 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
2920 * config.in: Regenerate.
2921 * configure: Regenerate.
2922 * configure.ac: Don't check for strerror.
2923 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
2924 Call safe_strerror instead of strerror.
2925 * server.h (strerror): Remove this now-unnecessary declaration.
2926 * tracepoint.c (init_named_socket): Call safe_strerror instead of
2928 (gdb_agent_helper_thread): Likewise.
2929 * utils.c (perror_with_name): Likewise.
2931 2019-11-26 Tom Tromey <tom@tromey.com>
2933 * configure, config.in: Rebuild.
2935 2019-11-26 Tom Tromey <tom@tromey.com>
2937 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
2938 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
2940 * configure, config.in: Rebuild.
2942 2019-11-26 Tom Tromey <tom@tromey.com>
2944 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
2945 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
2946 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
2947 * acinclude.m4: Include ax_pthread.m4.
2948 * config.in, configure: Rebuild.
2950 2019-11-26 Christian Biesinger <cbiesinger@google.com>
2952 * debug.c (debug_set_output): Call safe_strerror instead of
2954 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
2955 (linux_kill_one_lwp): Likewise.
2956 (linux_detach_one_lwp): Likewise.
2957 (linux_wait_for_event_filtered): Likewise.
2958 (store_register): Likewise.
2959 * lynx-low.c (lynx_attach): Likewise.
2960 * mem-break.c (insert_memory_breakpoint): Likewise.
2961 (remove_memory_breakpoint): Likewise.
2962 (delete_fast_tracepoint_jump): Likewise.
2963 (set_fast_tracepoint_jump): Likewise.
2964 (uninsert_fast_tracepoint_jumps_at): Likewise.
2965 (reinsert_fast_tracepoint_jumps_at): Likewise.
2966 * nto-low.c (nto_xfer_memory): Likewise.
2967 (nto_resume): Likewise.
2969 2019-11-20 Luis Machado <luis.machado@linaro.org>
2971 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
2972 instead of register count.
2973 * tdesc.c (tdesc_contains_feature): New function.
2974 * tdesc.h (tdesc_contains_feature): New prototype.
2976 2019-11-15 Christian Biesinger <cbiesinger@google.com>
2978 * Makefile.in: Add safe-strerror.c.
2979 * configure: Regenerate.
2980 * configure.ac: Don't source common.host.
2982 2019-11-15 Christian Biesinger <cbiesinger@google.com>
2984 * config.in: Regenerate.
2985 * configure: Regenerate.
2987 2019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
2989 * ax.c (ax_printf): Handle size_t_arg.
2991 2019-11-06 Christian Biesinger <cbiesinger@google.com>
2993 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
2994 * mi/mi-main.c (output_cores): Likewise.
2995 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
2996 (linux_xfer_osdata_modules): Likewise.
2997 * remote.c (register_remote_support_xml): Likewise.
2998 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
2999 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
3001 2019-11-01 Christian Biesinger <cbiesinger@google.com>
3003 * configure: Regenerate.
3004 * configure.ac: Remove check for strerror_r.
3006 2019-10-31 Christian Biesinger <cbiesinger@google.com>
3008 * config.in: Regenerate.
3009 * configure: Regenerate.
3010 * configure.ac: Also check for strerror_r.
3012 2019-10-31 Christian Biesinger <cbiesinger@google.com>
3014 * ax.h (debug_agent): Remove duplicate declaration.
3016 2019-10-26 Tom de Vries <tdevries@suse.de>
3018 * linux-aarch64-low.c: Fix typos in comments.
3019 * linux-arm-low.c: Same.
3020 * linux-low.c: Same.
3021 * linux-ppc-low.c: Same.
3022 * proc-service.c: Same.
3025 * tracepoint.c: Same.
3026 * win32-low.c: Same.
3028 2019-10-25 Tom Tromey <tromey@adacore.com>
3030 * utils.c (xstrdup): Remove.
3032 2019-10-23 Tom Tromey <tom@tromey.com>
3034 * configure, config.in: Rebuild.
3036 2019-10-23 Tom Tromey <tom@tromey.com>
3038 * configure: Rebuild.
3039 * acinclude.m4: Use m4_include, not sinclude.
3041 2019-10-17 Tom Tromey <tromey@adacore.com>
3043 * configure: Rebuild.
3044 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
3045 in AC_CONFIG_FILES invocation.
3046 * Makefile.in (stamp-h, Makefile): Use new-style config.status
3049 2019-10-16 Christian Biesinger <cbiesinger@google.com>
3051 * server.c: Include xml-builtin.h.
3052 (get_xml_features): Don't declare xml_builtins here.
3054 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
3056 * Makefile.in: Remove references to vec-ipa.o.
3058 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
3060 * Makefile.in: Remove references to vec.c.
3062 2019-10-02 Christian Biesinger <cbiesinger@google.com>
3064 * server.c (server_waiting): Change to bool.
3065 (extended_protocol): Likewise.
3066 (response_needed): Likewise.
3067 (exit_requested): Likewise.
3068 (run_once): Likewise.
3069 (report_no_resumed): Likewise.
3070 (non_stop): Likewise.
3071 (disable_packet_vCont): Likewise.
3072 (disable_packet_Tthread): Likewise.
3073 (disable_packet_qC): Likewise.
3074 (disable_packet_qfThreadInfo): Likewise.
3075 (handle_general_set): Update.
3076 (handle_detach): Update.
3077 (handle_monitor_command): Update.
3078 (handle_query): Update.
3079 (captured_main): Update.
3080 (process_serial_event): Update.
3081 * server.h (server_waiting): Change to bool.
3082 (disable_packet_vCont): Likewise.
3083 (disable_packet_Tthread): Likewise.
3084 (disable_packet_qC): Likewise.
3085 (disable_packet_qfThreadInfo): Likewise.
3086 (run_once): Likewise.
3087 (non_stop): Likewise.
3088 * target.c (target_stop_and_wait): Update.
3090 2019-10-02 Tom Tromey <tromey@adacore.com>
3092 * Makefile.in (SFILES): Add common-inferior.c.
3093 (OBS): Add common-inferior.o.
3094 * server.c (startup_with_shell): Don't define.
3096 2019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
3098 * linux-low.c (linux_low_read_btrace): Update for change to
3101 2019-09-20 Christian Biesinger <cbiesinger@google.com>
3103 * debug.c (debug_threads): Remove comment in favor of the header.
3104 * debug.h (using_threads): Add declaration.
3105 (debug_threads): Add comment.
3106 * linux-aarch64-low.c: Include debug.h and remove declaration of
3108 * nto-low.c: Likewise.
3109 * remote-utils.c: Likewise.
3110 * thread-db.c: Likewise.
3112 2019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
3114 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
3115 and powerpc-cell64l-ipa.o.
3116 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
3117 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
3118 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
3121 * spu-low.c: Remove file.
3123 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
3124 (parse_spufs_run): Remove.
3125 (ppc_get_pc): Remove Cell/B.E. support.
3126 (ppc_set_pc): Likewise.
3127 (ppc_breakpoint_at): Likewise.
3128 (ppc_arch_setup): Likewise.
3129 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
3130 tdesc_powerpc_cell32l.
3131 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
3132 or init_registers_powerpc_cell32l.
3133 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
3134 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
3135 or init_registers_powerpc_cell32l.
3136 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
3137 (init_registers_powerpc_cell32l): Remove prototype.
3138 (init_registers_powerpc_cell64l): Likewise.
3140 * target.h (struct target_ops): Remove qxfer_spu member.
3141 * server.c (handle_qxfer_spu): Remove.
3142 (qxfer_packets): Remove entry for "spu".
3143 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
3144 * linux-low.c (SPUFS_MAGIC): Remove.
3145 (spu_enumerate_spu_ids): Remove.
3146 (linux_qxfer_spu): Remove.
3147 (linux_target_ops): Remove qxfer_spu member.
3148 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
3149 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
3150 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
3152 2019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
3154 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
3155 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
3156 * config.in: Regenerate.
3157 * configure: Regenerate.
3159 2019-08-15 Tom Tromey <tromey@adacore.com>
3161 * target.c (target_write_memory): Use gdb::byte_vector.
3163 2019-08-15 Tom Tromey <tromey@adacore.com>
3165 * tracepoint.c (write_inferior_data_pointer)
3166 (write_inferior_integer, write_inferior_int8)
3167 (write_inferior_uinteger, m_tracepoint_action_download)
3168 (r_tracepoint_action_download, x_tracepoint_action_download)
3169 (l_tracepoint_action_download, clear_inferior_trace_buffer)
3170 (download_agent_expr, download_tracepoint_1)
3171 (download_trace_state_variables, upload_fast_traceframes): Update.
3172 * server.c (gdb_write_memory): Update.
3173 * remote-utils.c (relocate_instruction): Update.
3174 * proc-service.c (ps_pdwrite): Update.
3175 * mem-break.c (remove_memory_breakpoint)
3176 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
3177 (uninsert_fast_tracepoint_jumps_at)
3178 (reinsert_fast_tracepoint_jumps_at): Update.
3179 * linux-x86-low.c (append_insns)
3180 (i386_install_fast_tracepoint_jump_pad)
3181 (amd64_write_goto_address, i386_write_goto_address): Update.
3182 * linux-s390-low.c (append_insns, s390_write_goto_address):
3184 * linux-ppc-low.c (ppc_relocate_instruction)
3185 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
3186 (ppc_write_goto_address): Update.
3187 * linux-aarch64-low.c (append_insns): Update.
3188 * target.h (struct target_ops): Update.
3189 (write_inferior_memory): Don't declare.
3190 * target.c (target_write_memory): Rename from
3191 write_inferior_memory. Remove old target_write_memory.
3193 2019-08-15 Tom Tromey <tromey@adacore.com>
3195 * target.c (write_inferior_memory): Use std::vector.
3197 2019-08-06 Frank Ch. Eigler <fche@redhat.com>
3200 * configure.ac: Drop enable-libmcheck support.
3201 * configure, config.in: Rebuild.
3202 * acinclude.m4: Don't include it.
3204 2019-07-19 Alan Hayward <alan.hayward@arm.com>
3206 * configure.srv: Remove Arm xml files.
3208 2019-07-19 Alan Hayward <alan.hayward@arm.com>
3210 * configure.srv: Add new files. Remove xml generated files.
3211 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
3213 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
3214 * linux-aarch32-tdesc.c: New file.
3215 * linux-aarch32-tdesc.h: New file.
3216 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
3217 * linux-arm-low.c (init_registers_arm, tdesc_arm)
3218 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
3219 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
3220 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
3221 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
3222 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
3223 (arm_read_description): Call arm_linux_read_description.
3224 (initialize_low_arch): Don't init registers.
3225 * linux-arm-tdesc.c: New file.
3226 * linux-arm-tdesc.h: New file.
3228 2019-07-10 Alan Hayward <alan.hayward@arm.com>
3230 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
3231 Move counter inside for.
3232 (arm_read_description): Check ptrace earlier.
3233 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
3235 2019-07-09 Tom Tromey <tom@tromey.com>
3237 * configure: Rebuild.
3238 * configure.ac: Change common to gdbsupport.
3239 * acinclude.m4: Change common to gdbsupport.
3240 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
3241 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
3242 common to gdbsupport.
3243 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
3244 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
3245 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
3246 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
3247 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
3248 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
3249 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
3250 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
3251 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
3252 common to gdbsupport.
3254 2019-07-04 Alan Hayward <alan.hayward@arm.com>
3256 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
3258 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
3260 2019-07-04 Alan Hayward <alan.hayward@arm.com>
3262 * configure.srv: Remove legacy xml.
3263 * linux-aarch64-low.c (initialize_low_arch): Remove
3264 initialize_low_tdesc call.
3265 * linux-aarch64-tdesc-selftest.c: Remove file.
3266 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
3267 * linux-x86-low.c (initialize_low_arch): Remove
3268 initialize_low_tdesc call.
3269 * linux-x86-tdesc-selftest.c: Remove file.
3270 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
3272 2019-06-20 Tom de Vries <tdevries@suse.de>
3274 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
3275 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
3277 2019-06-19 Tom de Vries <tdevries@suse.de>
3279 * debug.h (debug_write): Change return type to ssize_t.
3280 * debug.c (debug_write): Same.
3282 2019-06-14 Tom Tromey <tom@tromey.com>
3284 * configure.ac: Use new path to gnulib.
3285 * configure: Rebuild.
3286 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
3289 2019-06-11 Tom Tromey <tom@tromey.com>
3291 * Makefile.in (SFILES): Add alloc.c.
3293 (IPA_OBJS): Add alloc-ipa.o.
3294 (alloc-ipa.o): New target.
3295 (%.o: ../%.c): New pattern rule.
3297 2019-06-10 Tom Tromey <tromey@adacore.com>
3299 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
3300 end warning with a newline.
3301 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
3303 * thread-db.c (attach_thread): Don't end warning with a newline.
3304 (thread_db_notice_clone): Likewise.
3305 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
3307 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
3308 end warning with a newline.
3310 2019-06-04 Pedro Alves <palves@redhat.com>
3312 * server.c (captured_main): Use make_unique_xstrdup.
3314 2019-06-02 Tom Tromey <tom@tromey.com>
3316 * gdbreplay.c (fromhex): Remove.
3317 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
3319 2019-05-29 Tom Tromey <tromey@adacore.com>
3321 * configure: Rebuild.
3323 2019-05-06 Kevin Buettner <kevinb@redhat.com>
3325 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
3326 sign extension code on 32-bit builds.
3328 2019-05-03 Eli Zaretskii <eliz@gnu.org>
3331 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
3333 2019-04-19 Tom Tromey <tom@tromey.com>
3335 * server.c (struct vstop_notif): Derive from notif_event.
3337 (queue_stop_reply): Update.
3338 (remove_all_on_match_ptid): Change type. Rewrite.
3339 (discard_queued_stop_replies): Rewrite.
3340 (in_queued_stop_replies_ptid): Change type.
3341 (in_queued_stop_replies): Rewrite.
3342 (notif_stop): Update.
3343 (queue_stop_reply_callback): Update.
3344 (captured_main): Don't call initialize_notif.
3345 (push_stop_notification): Update.
3346 * notif.c (notif_write_event, handle_notif_ack)
3347 (notif_event_enque, notif_push): Update.
3348 (notif_event_xfree, initialize_notif): Remove.
3349 * notif.h (struct notif_event): Include <list>, not
3351 (struct notif_server) <queue>: Now a std::list.
3352 (notif_event_p): Remove typedef.
3353 (initialize_notif): Don't declare.
3354 (struct notif_event): Add virtual destructor.
3356 2019-04-17 Alan Hayward <alan.hayward@arm.com>
3358 * ax.c (ax_vdebug): Call debug_printf.
3359 * debug.c (debug_write): New function.
3360 * debug.h (debug_write): New declaration.
3361 * linux-low.c (sigchld_handler): Call debug_write.
3363 2019-04-17 Alan Hayward <alan.hayward@arm.com>
3365 * debug.c (debug_set_output): New function.
3366 (debug_vprintf): Send output to debug_file.
3367 (debug_flush): Likewise.
3368 * debug.h (debug_set_output): New declaration.
3369 * server.c (handle_monitor_command): Add debug-file option.
3370 (captured_main): Likewise.
3372 2019-04-17 Alan Hayward <alan.hayward@arm.com>
3374 * debug.c (remote_debug): Add definition.
3375 * debug.h (remote_debug): Add declaration.
3376 * hostio.c (remote_debug): Remove declaration.
3377 * remote-utils.c (struct ui_file): Likewise.
3378 (remote_debug): Likewise.
3379 * remote-utils.h (remote_debug): Likewise,
3380 * server.c (remote_debug): Remove definition.
3382 2019-04-10 Kevin Buettner <kevinb@redhat.com>
3384 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
3385 when using a 64-bit gdbserver.
3387 2019-04-09 Tom Tromey <tromey@adacore.com>
3389 * linux-low.c (select_event_lwp): Use find_thread_in_random.
3391 2019-04-08 Tom Tromey <tom@tromey.com>
3393 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
3395 (linux_resume_one_lwp): Likewise.
3397 2019-04-08 Tom Tromey <tom@tromey.com>
3399 * gdbreplay.c: Update.
3400 * linux-low.c: Update.
3403 2019-04-08 Tom Tromey <tom@tromey.com>
3405 * server.c: Use C++ exception handling.
3406 * linux-low.c: Use C++ exception handling.
3407 * gdbreplay.c: Use C++ exception handling.
3409 2019-04-08 Tom Tromey <tom@tromey.com>
3411 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
3412 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
3413 (captured_main, main): Update.
3414 * gdbreplay.c (main): Update.
3416 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3418 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
3419 value in argument pointer, return 1 if the entry is found and 0
3420 otherwise. Move comment.
3421 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
3422 * linux-low.h (linux_get_auxv): Declare.
3423 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
3425 2019-04-05 Tom Tromey <tromey@adacore.com>
3427 * server.c (gdbserver_usage): Use upper-case for metasyntactic
3430 2019-03-28 Alan Hayward <alan.hayward@arm.com>
3432 * linux-low.c (AT_HWCAP2): Add define if not already included.
3434 2019-03-26 Alan Hayward <alan.hayward@arm.com>
3436 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
3437 (aarch64_arch_setup): Call linux_get_hwcap.
3438 * linux-arm-low.c (arm_get_hwcap): Remove function.
3439 (arm_read_description): Call linux_get_hwcap.
3440 * linux-low.c (linux_get_auxv): New function.
3441 (linux_get_hwcap): Likewise.
3442 (linux_get_hwcap2): Likewise.
3443 * linux-low.h (linux_get_hwcap): New declaration.
3444 (linux_get_hwcap2): Likewise.
3445 * linux-ppc-low.c (ppc_get_auxv): Remove function.
3446 (ppc_arch_setup): Call linux_get_hwcap.
3447 * linux-s390-low.c (s390_get_hwcap): Remove function.
3448 (s390_arch_setup): Call linux_get_hwcap.
3450 2019-03-22 Alan Hayward <alan.hayward@arm.com>
3451 Jiong Wang <jiong.wang@arm.com>
3453 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
3454 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
3456 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
3458 2019-03-22 Alan Hayward <alan.hayward@arm.com>
3459 Jiong Wang <jiong.wang@arm.com>
3461 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
3462 (aarch64_get_hwcap): New function.
3463 (aarch64_arch_setup): Read APIA hwcap.
3465 2019-03-22 Alan Hayward <alan.hayward@arm.com>
3466 Jiong Wang <jiong.wang@arm.com>
3468 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
3469 (initialize_low_tracepoint): Likewise.
3470 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
3471 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
3472 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
3473 (aarch64_linux_read_description): Likewise.
3474 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
3476 2019-03-12 John Baldwin <jhb@FreeBSD.org>
3478 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
3479 i386_create_target_description for 'segments' parameter.
3480 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
3481 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
3482 * win32-i386-low.c (i386_arch_setup): Likewise.
3484 2019-03-12 Tom Tromey <tromey@adacore.com>
3486 * linux-low.c (iterate_over_lwps): Update.
3488 2019-03-06 Tom Tromey <tom@tromey.com>
3490 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
3491 (captured_main): Use SCOPE_EXIT.
3493 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
3495 * configure.srv: Use '$enable_unittest' instead of '$development'
3496 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
3499 2019-02-27 Tom Tromey <tromey@adacore.com>
3501 * gdbreplay.c (logchar): Handle \r\n.
3503 2019-02-07 Alan Hayward <alan.hayward@arm.com>
3505 * linux-low.c (linux_attach): Add process before lwp.
3506 * server.c (attach_inferior): Check if already attached.
3508 2019-02-07 Tom Tromey <tom@tromey.com>
3510 * x86-tdesc.h: Rename include guard.
3511 * x86-low.h: Add include guard.
3512 * wincecompat.h: Rename include guard.
3513 * win32-low.h: Add include guard.
3514 * utils.h: Rename include guard.
3515 * tracepoint.h: Rename include guard.
3516 * tdesc.h: Rename include guard.
3517 * target.h: Rename include guard.
3518 * server.h: Rename include guard.
3519 * remote-utils.h: Rename include guard.
3520 * regcache.h: Rename include guard.
3521 * nto-low.h: Rename include guard.
3522 * notif.h: Add include guard.
3523 * mem-break.h: Rename include guard.
3524 * lynx-low.h: Add include guard.
3525 * linux-x86-tdesc.h: Add include guard.
3526 * linux-s390-tdesc.h: Add include guard.
3527 * linux-ppc-tdesc-init.h: Add include guard.
3528 * linux-low.h: Add include guard.
3529 * linux-aarch64-tdesc.h: Add include guard.
3530 * linux-aarch32-low.h: Add include guard.
3531 * inferiors.h: Rename include guard.
3532 * i387-fp.h: Rename include guard.
3533 * hostio.h: Rename include guard.
3534 * gdbthread.h: Rename include guard.
3535 * gdb_proc_service.h: Rename include guard.
3536 * event-loop.h: Rename include guard.
3537 * dll.h: Rename include guard.
3538 * debug.h: Rename include guard.
3539 * ax.h: Rename include guard.
3541 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
3544 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
3545 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
3547 2019-01-25 Tom Tromey <tom@tromey.com>
3549 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
3551 2019-01-25 Tom Tromey <tom@tromey.com>
3553 * win32-low.c: Fix common/ includes.
3554 * win32-i386-low.c: Fix common/ includes.
3555 * tracepoint.c: Fix common/ includes.
3556 * thread-db.c: Fix common/ includes.
3557 * target.h: Fix common/ includes.
3558 * symbol.c: Fix common/ includes.
3559 * spu-low.c: Fix common/ includes.
3560 * server.h: Fix common/ includes.
3561 * server.c: Fix common/ includes.
3562 * remote-utils.c: Fix common/ includes.
3563 * regcache.h: Fix common/ includes.
3564 * regcache.c: Fix common/ includes.
3565 * nto-x86-low.c: Fix common/ includes.
3566 * notif.h: Fix common/ includes.
3567 * mem-break.h: Fix common/ includes.
3568 * lynx-low.c: Fix common/ includes.
3569 * lynx-i386-low.c: Fix common/ includes.
3570 * linux-x86-tdesc-selftest.c: Fix common/ includes.
3571 * linux-x86-low.c: Fix common/ includes.
3572 * linux-low.c: Fix common/ includes.
3573 * inferiors.h: Fix common/ includes.
3574 * i387-fp.c: Fix common/ includes.
3575 * hostio.c: Fix common/ includes.
3576 * hostio-errno.c: Fix common/ includes.
3577 * gdbthread.h: Fix common/ includes.
3578 * gdbreplay.c: Fix common/ includes.
3579 * fork-child.c: Fix common/ includes.
3580 * event-loop.c: Fix common/ includes.
3582 (enum gdb_agent_op): Fix common/ includes.
3584 2019-01-21 Tom Tromey <tom@tromey.com>
3586 * tracepoint.c: Fix includes.
3587 * remote-utils.c: Fix includes.
3588 * linux-x86-low.c: Fix includes.
3590 2019-01-01 Joel Brobecker <brobecker@adacore.com>
3592 * gdbreplay.c (gdbreplay_version): Update copyright year in
3594 * server.c (gdbserver_version): Likewise.
3596 2018-12-05 Alan Hayward <alan.hayward@arm.com>
3598 * linux-low.c (add_lwp): Switch ordering.
3600 2018-11-29 Tom Tromey <tom@tromey.com>
3602 * win32-low.c (win32_join): Take pid, not process.
3603 * target.h (struct target_ops) <join>: Change argument type.
3604 (join_inferior): Change argument name.
3605 * spu-low.c (spu_join): Take pid, not process.
3606 * server.c (handle_detach): Preserve pid before destroying
3608 * lynx-low.c (lynx_join): Take pid, not process.
3609 * linux-low.c (linux_join): Take pid, not process.
3611 2018-11-23 Alan Hayward <alan.hayward@arm.com>
3613 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
3614 (aarch64_cannot_fetch_register): Likewise.
3615 (struct linux_target_ops): Update references.
3617 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3619 * linux-ppc-low.c: Include nat/linux-ptrace.h.
3621 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3623 * configure.srv (ipa_ppc_linux_regobj): Add
3624 powerpc-isa207-htm-vsx32l-ipa.o and
3625 powerpc-isa207-htm-vsx64l-ipa.o.
3626 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
3627 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
3628 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
3629 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
3630 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
3631 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
3632 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
3633 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
3634 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
3635 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
3636 (init_registers_powerpc_isa207_htm_vsx32l)
3637 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
3638 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
3639 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
3640 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
3641 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
3642 (ppc_store_tm_ctarregset): New functions.
3643 (ppc_regsets): Add entries for HTM regsets.
3644 (ppc_arch_setup): Set htm in features struct when needed. Set
3645 sizes for the HTM regsets.
3646 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
3647 (initialize_low_arch): Call
3648 init_registers_powerpc_isa207_htm_vsx32l and
3649 init_registers_powerpc_isa207_htm_vsx64l.
3650 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
3651 PPC_TDESC_ISA207_HTM_VSX.
3652 (initialize_low_tracepoint): Call
3653 init_registers_powerpc_isa207_htm_vsx32l and
3654 init_registers_powerpc_isa207_htm_vsx64l.
3656 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3658 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
3659 rs6000/power-linux-pmu.xml to srv_xmlfiles.
3660 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
3661 (ppc_store_pmuregset): New functions.
3662 (ppc_regsets): Add entries for ebb and pmu regsets.
3663 (ppc_arch_setup): Set isa207 in features struct if the ebb and
3664 pmu regsets are available. Set sizes for these regsets.
3666 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3668 * configure.srv (ipa_ppc_linux_regobj): Add
3669 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
3670 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
3671 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
3672 rs6000/powerpc-isa207-vsx32l.xml, and
3673 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
3674 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
3675 <PPC_TDESC_ISA207_VSX>: New enum value.
3676 (init_registers_powerpc_isa207_vsx32l): Declare.
3677 (init_registers_powerpc_isa207_vsx64l): Declare.
3678 * linux-ppc-low.c (ppc_fill_tarregset): New function.
3679 (ppc_store_tarregset): New function.
3680 (ppc_regsets): Add entry for the TAR regset.
3681 (ppc_arch_setup): Set isa207 in features struct when needed. Set
3682 size for the TAR regsets.
3683 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
3684 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
3685 and init_registers_powerpc_isa207_vsx64l.
3686 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
3687 (initialize_low_tracepoint): Call
3688 init_registers_powerpc_isa207_vsx32l and
3689 init_registers_powerpc_isa207_vsx64l.
3691 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
3692 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3694 * configure.srv (ipa_ppc_linux_regobj): Add
3695 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
3696 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
3697 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
3698 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
3699 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
3700 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
3701 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
3702 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
3703 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
3704 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
3705 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
3706 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
3707 (ppc_hwcap): Add comment.
3708 (ppc_hwcap2): New global.
3709 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
3710 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
3711 (ppc_regsets): Add entries for the DSCR and PPR regsets.
3712 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
3713 when needed. Set sizes for the the DSCR and PPR regsets.
3714 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
3715 (initialize_low_arch): Call
3716 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
3717 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
3718 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
3719 PPC_TDESC_ISA205_PPR_DSCR_VSX.
3720 (initialize_low_tracepoint): Call
3721 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
3722 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
3724 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3726 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
3728 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
3729 Simon Marchi <simark@simark.ca>
3731 * acinclude.m4: Include "../selftest.m4".
3732 * configure: Regenerate.
3733 * configure.ac: Use "GDB_AC_SELFTEST".
3734 * configure.srv: Use "$enable_unittests" instead of
3735 "$development" when checking whether unit tests have been
3737 * server.c (captured_main): Update message informing that
3738 selftests have been disabled.
3740 2018-10-04 Tom Tromey <tom@tromey.com>
3742 * configure: Rebuild.
3744 2018-10-04 Tom Tromey <tom@tromey.com>
3746 * server.c (handle_status): Rename inner "thread".
3747 (process_serial_event): Declare "res" in 'm' case.
3748 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
3749 (iterate_over_lwps): Rename inner "thread".
3750 (linux_qxfer_libraries_svr4): Rename inner "len".
3751 * gdbthread.h (find_thread_in_random): Rename inner "thread".
3753 2018-10-01 Gary Benson <gbenson@redhat.com>
3755 * gdb_proc_service.h: Moved common code to
3756 common/gdb_proc_service.h.
3758 2018-10-01 Gary Benson <gbenson@redhat.com>
3760 * gdb_proc_service.h: Synchronize comments and whitespace with
3761 GDB's version of this file.
3763 2018-09-25 Tom Tromey <tom@tromey.com>
3765 * configure: Rebuild.
3766 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
3768 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
3770 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
3771 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
3772 ($(IPA_LIB)): Sort IPA_OBJS.
3774 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
3776 * Makefile.in: Remove references to $(ADD_DEPS).
3778 2018-09-16 Tom Tromey <tom@tromey.com>
3780 * remote-utils.c (remote_open): Use GNU style for metasyntactic
3782 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
3785 2018-09-05 Tom Tromey <tom@tromey.com>
3787 * configure: Rebuild.
3789 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
3792 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
3794 2018-08-27 Tom Tromey <tom@tromey.com>
3797 * configure: Rebuild.
3799 2018-08-27 Tom Tromey <tom@tromey.com>
3801 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
3802 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
3803 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
3804 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
3805 (s390x_emit_stack_adjust): Add casts to unsigned char.
3807 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
3811 * server.h (struct client_state) <disable_randomization>:
3814 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
3816 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
3818 (mips_supply_ptrace_register): Likewise.
3820 2018-07-22 Tom Tromey <tom@tromey.com>
3822 * configure: Rebuild.
3824 2018-07-22 Tom Tromey <tom@tromey.com>
3826 * win32-low.c (win32_create_inferior): Remove unused variables.
3827 * gdbreplay.c (remote_open): Remove unused variable.
3828 * remote-utils.c (remote_prepare): Remove unused variable.
3829 * x86-tdesc.h (X86_TDESC_H): Define.
3830 (amd64_expedite_regs): Define conditionally.
3831 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
3832 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
3833 * remote-utils.c (readchar): Remove unused variable.
3835 2018-07-13 Pedro Alves <palves@redhat.com>
3837 * linux-low.c (linux_kill): Change parameter to process_info
3838 pointer instead of pid. Adjust.
3839 * lynx-low.c (lynx_kill): Likewise.
3840 * nto-low.c (nto_kill): Likewise.
3841 * spu-low.c (spu_kill): Likewise.
3842 * win32-low.c (win32_kill): Likewise.
3843 * server.c (handle_v_kill, kill_inferior_callback)
3844 (detach_or_kill_for_exit): Adjust.
3845 * target.c (kill_inferior): Change parameter to process_info
3846 pointer instead of pid. Adjust.
3847 * target.h (struct target_ops) <kill>: Change parameter to
3848 process_info pointer instead of pid. Adjust all implementations
3850 (kill_inferior): Likewise.
3852 2018-07-13 Pedro Alves <palves@redhat.com>
3854 * linux-low.c (linux_detach, linux_join): Change parameter to
3855 process_info pointer instead of pid. Adjust.
3856 * lynx-low.c (lynx_detach, lynx_join): Likewise.
3857 * nto-low.c (nto_detach): Likewise.
3858 * spu-low.c (spu_detach, spu_join): Likewise.
3859 * win32-low.c (win32_detach, win32_join): Likewise.
3860 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
3861 * target.h (struct target_ops) <detach, join>: Change parameter to
3862 process_info pointer instead of pid. Adjust all implementations
3864 (detach_inferior, join_inferior): Rename 'pid' parameter to
3867 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
3868 Jan Kratochvil <jan.kratochvil@redhat.com>
3869 Paul Fertser <fercerpav@gmail.com>
3870 Tsutomu Seki <sekiriki@gmail.com>
3872 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
3873 (OBS): Add 'common/netstuff.o'.
3874 (GDBREPLAY_OBS): Likewise.
3875 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
3876 (remote_open): Implement support for IPv6
3878 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
3880 (handle_accept_event): Accept connections from IPv6 sources.
3881 (remote_prepare): Handle IPv6-style hostnames; implement
3882 support for IPv6 connections.
3883 (remote_open): Implement support for printing connections from
3886 2018-07-11 Pedro Alves <palves@redhat.com>
3889 * mem-break.c (any_persistent_commands): Add process_info
3890 parameter and use it instead of relying on the current process.
3891 Change return type to bool.
3892 * mem-break.h (any_persistent_commands): Add process_info
3893 parameter and change return type to bool.
3894 * server.c (handle_detach): Remove require_running_or_return call.
3895 Look up the process_info for the process we're about to detach.
3896 If not found, return back error to GDB. Adjust
3897 any_persistent_commands call to pass down a process pointer.
3899 2018-07-11 Pedro Alves <palves@redhat.com>
3901 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
3902 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
3903 instead of collect_register_by_name.
3904 * regcache.c (regcache_raw_get_unsigned_by_name): New.
3905 * regcache.h (regcache_raw_get_unsigned_by_name): New.
3907 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
3908 Pedro Alves <palves@redhat.com>
3910 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
3912 2018-07-03 Tom Tromey <tom@tromey.com>
3914 * linux-low.c: Update.
3915 * lynx-low.c: Update.
3916 * mem-break.c: Update.
3917 * nto-low.c: Update.
3918 * remote-utils.c: Update.
3920 * spu-low.c: Update.
3922 * win32-low.c: Update.
3924 2018-07-03 Tom Tromey <tom@tromey.com>
3928 2018-07-03 Tom Tromey <tom@tromey.com>
3930 * linux-low.c: Update.
3932 2018-07-03 Tom Tromey <tom@tromey.com>
3936 2018-07-03 Tom Tromey <tom@tromey.com>
3938 * linux-low.c: Update.
3939 * linux-mips-low.c: Update.
3940 * lynx-low.c: Update.
3941 * nto-low.c: Update.
3942 * remote-utils.c: Update.
3944 * spu-low.c: Update.
3946 * thread-db.c: Update.
3948 2018-07-03 Tom Tromey <tom@tromey.com>
3950 * linux-low.c: Update.
3951 * linux-mips-low.c: Update.
3952 * lynx-low.c: Update.
3953 * mem-break.c: Update.
3954 * nto-low.c: Update.
3955 * remote-utils.c: Update.
3957 * spu-low.c: Update.
3959 * tracepoint.c: Update.
3961 2018-07-03 Tom Tromey <tom@tromey.com>
3963 * linux-low.c: Update.
3964 * linux-ppc-low.c: Update.
3965 * linux-x86-low.c: Update.
3966 * proc-service.c: Update.
3968 * spu-low.c: Update.
3969 * thread-db.c: Update.
3970 * win32-low.c: Update.
3972 2018-07-03 Tom Tromey <tom@tromey.com>
3974 * linux-low.c: Update.
3975 * lynx-low.c: Update.
3976 * nto-low.c: Update.
3977 * remote-utils.c: Update.
3978 * spu-low.c: Update.
3979 * thread-db.c: Update.
3980 * win32-low.c: Update.
3982 2018-06-29 Joel Brobecker <brobecker@adacore.com>
3984 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
3985 parameter in call to 'amd64_create_target_description'.
3987 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
3989 * x86-tdesc.h: Remove executable permission flag.
3991 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
3993 * configure.ac: Remove AC_PREREQ, add missing quoting.
3994 * configure: Re-generate.
3995 * config.in: Re-generate.
3996 * aclocal.m4: Re-generate.
3998 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
4000 * tracepoint.h (current_traceframe): Remove declaration.
4002 2018-06-18 Alan Hayward <alan.hayward@arm.com>
4004 * linux-aarch64-low.c (is_sve_tdesc): New function.
4005 (aarch64_sve_regs_copy_to_regcache): Likewise.
4006 (aarch64_sve_regs_copy_from_regcache): Likewise.
4007 (aarch64_regs_info): Add SVE checks.
4008 (initialize_low_arch): Initialize SVE.
4010 2018-06-18 Alan Hayward <alan.hayward@arm.com>
4012 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
4014 2018-06-11 Alan Hayward <alan.hayward@arm.com>
4016 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
4017 (initialize_low_tracepoint): Likewise
4018 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
4019 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
4021 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
4023 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
4025 2018-06-11 Alan Hayward <alan.hayward@arm.com>
4027 * server.h (PBUFSIZ): Increase size
4029 2018-06-11 Alan Hayward <alan.hayward@arm.com>
4031 * regcache.c (regcache::raw_compare): New function.
4032 * regcache.h (regcache::raw_compare): New declaration.
4034 2018-06-11 Alan Hayward <alan.hayward@arm.com>
4036 * regcache.c (new_register_cache): Use new.
4037 (free_register_cache): Use delete.
4038 (register_data): Use const.
4039 (supply_register): Move body inside regcache.
4040 (regcache::raw_supply): New override function.
4041 (collect_register): Move body inside regcache.
4042 (regcache::raw_collect): New override function.
4043 (regcache::get_register_status): New override function.
4044 * regcache.h (struct regcache): Inherit from reg_buffer_common.
4046 2018-06-09 Tom Tromey <tom@tromey.com>
4048 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
4050 (event_queue): Use std::queue.
4051 (gdb_event_xfree): Remove.
4052 (initialize_event_loop, process_event, wait_for_event): Update.
4054 2018-06-08 Stan Cox <scox@redhat.com>
4056 * win32-low.c (win32_create_inferior): last_ptid and last_status
4057 moved to client_state.
4059 2018-06-08 Pedro Alves <palves@redhat.com>
4061 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
4062 common/common-exceptions.o, common/common-utils.o,
4063 common/errors.o, common/print-utils.o and utils.o.
4064 * gdbreplay.c: Include "common-defs.h" instead of the two
4065 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
4066 string.h or alloca.h.
4067 (perror_with_name): Delete.
4068 (remote_open): Use xstrdup instead of strdup.
4069 (main): Rename to ...
4070 (captured_main): ... this.
4073 2018-06-08 Tom Tromey <tom@tromey.com>
4075 * linux-low.c (linux_low_read_btrace): Update.
4077 2018-06-04 Stan Cox <scox@redhat.com>
4079 * server.h (struct client_state): New.
4080 * server.c (cont_thread, general_thread, multi_process)
4081 (report_fork_events, report_vfork_events, report_exec_events)
4082 (report_thread_events, swbreak_feature, hwbreak_feature)
4083 (vCont_supported, disable_randomization, pass_signals)
4084 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
4085 Moved to client_state.
4086 * remote-utils.c (remote_debug, noack_mode)
4087 (transport_is_reliable): Moved to client_state.
4088 * tracepoint.c (current_traceframe): Moved to client_state.
4091 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
4092 linux-low.c, remote-utils.h, target.c: Use client_state.
4094 2018-05-31 Alan Hayward <alan.hayward@arm.com>
4096 * configure.srv: Add new c/h file.
4098 2018-05-31 Alan Hayward <alan.hayward@arm.com>
4100 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
4103 2018-05-25 Maciej W. Rozycki <macro@mips.com>
4105 * gdb.arch/mips-fpregset-core.exp: New test.
4106 * gdb.arch/mips-fpregset-core.c: New test source.
4108 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
4111 * hostio.c (require_int): Do not report overflow for integers
4112 between 0xfffffff and 0x7fffffff.
4114 2018-05-22 Maciej W. Rozycki <macro@mips.com>
4116 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
4117 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
4118 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
4120 (the_low_target): Wire them.
4122 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4124 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
4125 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
4126 mode. Call collect_register_by_name with vscr using
4127 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
4128 (ppc_store_vrregset): Add and set vscr_offset variable as in
4129 ppc_fill_vrregset. Call supply_register_by_name with vscr using
4132 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4134 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
4135 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
4136 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
4138 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4140 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
4141 (ppc_store_vsxregset): Likewise.
4142 (ppc_fill_vrregset): Likewise.
4143 (ppc_store_vrregset): Likewise.
4144 (ppc_fill_evrregset): Likewise.
4145 (ppc_store_evrregset): Likewise.
4146 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
4147 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
4150 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4152 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
4153 wordsize of the inferior. Call ppc_linux_target_wordsize.
4155 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4157 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
4158 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
4159 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
4160 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
4161 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
4162 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
4163 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
4164 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
4165 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
4166 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
4167 (tdesc_powerpc_e500l): Remove.
4168 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
4169 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
4170 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
4171 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
4173 (ppc_arch_setup): Remove target description matching code. Fill a
4174 ppc_linux_features struct and call ppc_linux_match_description
4177 2018-05-22 Maciej W. Rozycki <macro@mips.com>
4179 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
4180 width of the requested register exceeds the width of the
4182 (mips_cannot_store_register): Likewise.
4184 2018-05-21 Maciej W. Rozycki <macro@mips.com>
4186 * linux-mips-low.c (mips_fetch_register): New function. Update
4188 (mips_store_gregset): Supply 0 rather than $restart for $zero.
4189 (the_low_target): Wire `mips_fetch_register'.
4191 2018-05-10 Joel Brobecker <brobecker@adacore.com>
4193 * lynx-i386-low.c (LYNXOS_178): New macro.
4194 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
4195 the layout on LynxOS-178.
4196 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
4197 handle floating point registers that are not supported by
4200 2018-05-10 Tom Tromey <tom@tromey.com>
4202 * configure: Rebuild.
4204 2018-05-10 Joel Brobecker <brobecker@adacore.com>
4207 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
4208 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
4209 Use it to set the expedite_regs field in the given tdesc.
4210 * x86-tdesc.h: New file.
4211 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
4212 Adjust following the addition of the new expedite_regs parameter
4213 to init_target_desc.
4214 * linux-tic6x-low.c (tic6x_read_description): Likewise.
4215 * linux-x86-tdesc.c: #include "x86-tdesc.h".
4216 (i386_linux_read_description, amd64_linux_read_description):
4217 Adjust following the addition of the new expedite_regs parameter
4218 to init_target_desc.
4219 * lynx-i386-low.c: #include "x86-tdesc.h".
4220 (lynx_i386_arch_setup): Adjust following the addition of the new
4221 expedite_regs parameter to init_target_desc.
4222 * nto-x86-low.c: #include "x86-tdesc.h".
4223 (nto_x86_arch_setup): Adjust following the addition of the new
4224 expedite_regs parameter to init_target_desc.
4225 * win32-i386-low.c: #include "x86-tdesc.h".
4226 (i386_arch_setup): Adjust following the addition of the new
4227 expedite_regs parameter to init_target_desc.
4229 2018-05-10 Joel Brobecker <brobecker@adacore.com>
4232 * win32-low.c (win32_create_inferior): Add call to my_wait
4233 setting last_status global.
4235 2018-05-10 Joel Brobecker <brobecker@adacore.com>
4238 * win32-low.c (create_process): Only call gdb_tilde_expand if
4239 inferior_cwd is not NULL.
4241 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
4243 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
4244 registers to the cache if their values have changed.
4245 (i387_xsave_to_cache): Provide default values for x87 control
4246 registers when these features are available, but disabled.
4247 * regcache.c (supply_register_by_name_zeroed): New function.
4248 * regcache.h (supply_register_by_name_zeroed): Declare new
4251 2018-05-07 Tom Tromey <tom@tromey.com>
4253 * configure: Rebuild.
4255 2018-05-04 Tom Tromey <tom@tromey.com>
4257 * configure: Rebuild.
4259 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
4260 Pedro Alves <palves@redhat.com>
4262 * linux-aarch64-low.c (aarch64_stopped_data_address):
4265 2018-04-27 Tom Tromey <tom@tromey.com>
4267 * configure: Rebuild.
4269 2018-04-23 Tom Tromey <tom@tromey.com>
4271 * configure: Rebuild.
4273 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
4275 * Makefile.in (depcomp): Add "..".
4276 (all_deps_files): New and use it.
4278 2018-04-18 Alan Hayward <alan.hayward@arm.com>
4280 * configure.srv (aarch64*-*-linux*): Don't include xml.
4281 (i[34567]86-*-cygwin*): Likewise.
4282 (i[34567]86-*-linux*): Likewise.
4283 (i[34567]86-*-lynxos*): Likewise.
4284 (i[34567]86-*-mingw32ce*): Likewise.
4285 (i[34567]86-*-mingw*): Likewise.
4286 (i[34567]86-*-nto*): Likewise.
4287 (tic6x-*-uclinux): Likewise.
4288 (x86_64-*-linux*): Likewise.
4289 (x86_64-*-mingw*): Likewise.
4290 (x86_64-*-cygwin*): Likewise.
4292 2018-04-18 Alan Hayward <alan.hayward@arm.com>
4294 * tdesc.c: Remove xml parameter.
4296 2018-04-18 Alan Hayward <alan.hayward@arm.com>
4298 * server.c (get_features_xml): Remove cast.
4299 * tdesc.c (void target_desc::accept): Fill in function.
4300 (tdesc_get_features_xml): Remove old xml creation.
4301 (print_xml_feature::visit_pre): Add xml vistor.
4302 * tdesc.h (struct target_desc): Make xmltarget mutable.
4303 (tdesc_get_features_xml): Remove declaration.
4305 2018-04-18 Alan Hayward <alan.hayward@arm.com>
4307 * tdesc.c (tdesc_architecture_name): Add new function.
4308 (tdesc_osabi_name): Likewise.
4309 (tdesc_get_features_xml): Use new functions.
4311 2018-04-18 Alan Hayward <alan.hayward@arm.com>
4313 * tdesc.c (tdesc_create_flags): Remove.
4314 (tdesc_add_flag): Likewise.
4315 (tdesc_named_type): Likewise.
4316 (tdesc_create_union): Likewise.
4317 (tdesc_create_struct): Likewise.
4318 (tdesc_create_vector): Likewise.
4319 (tdesc_add_bitfield): Likewise.
4320 (tdesc_add_field): Likewise.
4321 (tdesc_set_struct_size): Likewise.
4323 2018-04-18 Alan Hayward <alan.hayward@arm.com>
4325 * tdesc.c (~target_desc): Remove implictly deleted items.
4326 (init_target_desc): Iterate all features.
4327 (tdesc_get_features_xml): Use vector.
4328 (tdesc_create_feature): Create feature.
4329 * tdesc.h (tdesc_feature) Remove
4330 (target_desc): Add features.
4332 2018-04-18 Alan Hayward <alan.hayward@arm.com>
4334 * Makefile.in: Add common/tdesc.c
4335 * tdesc.c (init_target_desc): init all reg_defs from register
4337 (tdesc_create_reg): Create tdesc_reg.
4338 * tdesc.h (tdesc_feature): Add register vector.
4340 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
4342 * tdesc.h (struct target_desc) <features>: Change type to
4343 std::vector<std::string>.
4344 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
4346 (tdesc_get_features_xml): Likewise.
4347 (tdesc_create_feature): Likewise.
4349 2018-03-26 Alan Hayward <alan.hayward@arm.com>
4351 * regcache.c (find_register_by_number): Return a ref.
4352 (find_regno): Use references.
4353 (register_size): Likewise.
4354 (register_data): Likewise.
4355 * tdesc.c (target_desc::~target_desc): Remove free calls.
4356 (target_desc::operator==): Use std::vector compare.
4357 (init_target_desc): Use reference.
4358 (tdesc_create_reg): Use reg constructors.
4359 * tdesc.h (struct target_desc): Replace pointer with object.
4361 2018-03-23 Alan Hayward <alan.hayward@arm.com>
4363 * regcache.c (find_register_by_number): Make static.
4364 (find_regno): Use find_register_by_number
4365 * regcache.h (struct reg): Remove declaration.
4367 2018-03-23 Alan Hayward <alan.hayward@arm.com>
4369 * tdesc.c (target_desc::~target_desc): Move to here.
4370 (target_desc::operator==): Likewise.
4371 * tdesc.h (target_desc::~target_desc): Move from here.
4372 (target_desc::operator==): Likewise.
4374 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
4376 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
4378 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
4380 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
4382 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
4383 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
4384 and init_registers_s390_gs_linux64.
4386 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
4388 * linux-s390-low.c (s390_fill_gs): Remove function.
4389 (s390_fill_gsbc): Remove function.
4390 (s390_regsets): Set fill functions for the guarded storage regsets
4393 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
4395 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
4396 the word size. Add comment.
4397 (s390_get_wordsize): New function.
4398 (s390_arch_setup): No longer select a temporary tdesc to fetch the
4399 pswm with it. Instead, use s390_get_wordsize to determine the
4400 word size first and derive the correct tdesc from that directly.
4402 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
4404 * Makefile.in: Include silent-rules.mk.
4405 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
4406 (COMPILE): Add ECHO_CXX.
4407 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
4408 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
4409 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
4410 (version-generated.c): Add ECHO_GEN.
4411 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
4412 (IPAGENT_COMPILE): Add ECHO_CXX.
4413 (%-generated.c): Add ECHO_REGDAT.
4415 2018-03-14 Tom Tromey <tom@tromey.com>
4418 * ax.c (ax_printf): Special case for NULL.
4420 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
4422 * linux-low.c (linux_qxfer_libraries_svr4): Use
4423 xml_escape_text_append.
4425 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
4427 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
4429 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
4431 * server.c (handle_general_set): Remove unnecessary xstrdup.
4433 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
4435 * server.c (parse_debug_format_options): Adjust to
4436 delim_string_to_char_ptr_vec changes.
4437 * thread-db.c (thread_db_load_search): Adjust to
4438 dirnames_to_char_ptr_vec changes.
4440 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
4442 * target.h (target_enable_btrace, target_disable_btrace)
4443 (target_read_btrace, target_read_btrace_conf): Turn macro into
4444 inline function. Throw error if target method is not defined.
4445 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
4446 check for btrace target method. Be prepared to handle exceptions
4447 from btrace target methods.
4449 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
4451 * server.c (captured_main): Change order of error message printed
4452 when the current working directory cannot be found.
4454 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
4456 * server.c: Include "filenames.h" and "pathstuff.h".
4457 (program_name): Delete variable.
4458 (program_path): New anonymous class.
4459 (get_exec_wrapper): Use "program_path" instead of
4461 (handle_v_run): Likewise.
4462 (captured_main): Likewise.
4463 (process_serial_event): Likewise.
4465 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
4467 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
4468 (OBJS): Add "pathstuff.o".
4469 * server.c (current_directory): New global variable.
4470 (captured_main): Initialize "current_directory".
4472 2018-02-26 Alan Hayward <alan.hayward@arm.com>
4474 * tdesc.c: Use common/tdesc.h.
4475 * tdesc.h: Likewise.
4477 2018-02-20 Alan Hayward <alan.hayward@arm.com>
4478 Simon Marchi <simon.marchi@ericsson.com>
4480 * Makefile.in: Switch order of make rules.
4482 2018-02-19 Alan Hayward <alan.hayward@arm.com>
4484 * Makefile.in: Add common directory in build.
4485 * configure.ac: Add common reference.
4486 * configure: Regenerate.
4488 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
4490 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
4491 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
4492 * spu-low.c (spu_target_ops): Likewise.
4493 * win32-low.c (win32_target_ops): Likewise.
4494 * server.c (supported_btrace_packets): Report packets unconditionally.
4495 * target.h (target_ops) <supports_btrace>: Remove.
4496 (target_supports_btrace): Remove.
4498 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
4500 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
4501 (handle_btrace_disable): Change return type to void. Use exceptions
4503 (handle_btrace_general_set): Catch exception and copy message to
4506 2018-02-08 Tom Tromey <tom@tromey.com>
4508 * linux-low.c (install_software_single_step_breakpoints): Use
4509 make_scoped_restore.
4510 * inferiors.c (make_cleanup_restore_current_thread): Remove.
4511 (do_restore_current_thread_cleanup): Remove.
4512 * gdbthread.h (make_cleanup_restore_current_thread): Don't
4515 2018-02-08 Tom Tromey <tom@tromey.com>
4517 * mem-break.c (set_raw_breakpoint_at): Use
4518 gdb::unique_xmalloc_ptr.
4520 2018-01-30 Pedro Alves <palves@redhat.com>
4523 * target.c (target_terminal::terminal_state): Rename to ...
4524 (target_terminal::m_terminal_state): ... this.
4526 2018-01-19 James Clarke <jrtc27@jrtc27.com>
4528 * linux-low.c (handle_extended_wait): Surround call to
4529 thread_db_notice_clone with #ifdef USE_THREAD_DB.
4531 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
4533 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
4534 linux_ptrace_attach_fail_reason_string now returning an
4536 (linux_attach): Likewise.
4537 * thread-db.c (attach_thread): Likewise.
4539 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
4542 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
4543 checking for fs_base/gs_base fields in struct user_regs_struct.
4544 * configure: Regenerate.
4546 2018-01-16 Yao Qi <yao.qi@linaro.org>
4549 * linux-low.c (fetch_register): Call supply_register instead of
4552 2018-01-08 Yao Qi <yao.qi@linaro.org>
4553 Simon Marchi <simon.marchi@ericsson.com>
4555 * Makefile.in (OBS): Remove selftest.o.
4556 * configure.ac: Set srv_selftest_objs if $development is true.
4557 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
4558 * configure: Re-generated.
4559 * server.c (captured_main): Wrap variable selftest_filter with
4562 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
4564 * server.c (parse_debug_format_options): Return std::string.
4565 (handle_monitor_command, captured_main): Adjust.
4567 2018-01-05 Pedro Alves <palves@redhat.com>
4570 * server.c (captured_main): Pass quiet=false to
4571 save_original_signals_state.
4573 2018-01-01 Joel Brobecker <brobecker@adacore.com>
4575 * gdbreplay.c (gdbreplay_version): Update copyright year in
4577 * server.c (gdbserver_version): Likewise.
4579 2017-12-08 Tom Tromey <tom@tromey.com>
4581 * ax.c (ax_printf): Update.
4583 2017-12-07 Yao Qi <yao.qi@linaro.org>
4585 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
4586 aarch64_linux_read_description.
4587 * linux-amd64-ipa.c (idx2mask): New array.
4588 (get_ipa_tdesc): Move idx2mask out.
4589 (initialize_low_tracepoint): Initialize target descriptions.
4590 * linux-i386-ipa.c (idx2mask): New array.
4591 (get_ipa_tdesc): Move idx2mask out.
4592 (initialize_low_tracepoint): Initialize target descriptions.
4594 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
4596 * tdesc.c (struct tdesc_type): Change return type.
4597 (tdesc_add_flag): Change parameter type.
4598 (tdesc_add_bitfield): Likewise.
4599 (tdesc_add_field): Likewise.
4600 (tdesc_set_struct_size): Likewise.
4602 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
4604 * regcache.c (registers_to_string): Remove unused variable.
4606 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4608 * inferiors.c (for_each_inferior_with_data): Remove.
4609 * inferiors.h (for_each_inferior_with_data): Remove.
4610 * server.c (handle_qxfer_threads_worker): Change parameter type.
4611 (handle_qxfer_threads_proper): Use for_each_thread.
4613 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4615 * inferiors.c (for_each_inferior): Remove.
4616 (clear_inferiors): Use for_each_thread.
4617 * inferiors.h (for_each_inferior): Remove.
4618 * linux-low.c (linux_wait_for_event_filtered): Use
4620 (linux_stabilize_threads): Likewise.
4621 * regcache.c (regcache_release): Likewise.
4622 * server.c (gdb_wants_all_threads_stopped): Likewise.
4623 (clear_pending_status_callback): Remove.
4624 (handle_status): Use for_each_thread.
4625 (captured_main): Likewise.
4626 * win32-low.c (child_init_thread_list): Likewise.
4627 (win32_clear_inferiors): Likewise.
4628 (fake_breakpoint_event): Likewise.
4630 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4632 * inferiors.h (find_inferior): Remove.
4633 * inferiors.c (find_inferior): Remove.
4635 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4637 * linux-low.c (resume_status_pending_p): Update comment.
4638 (need_step_over_p): Update comment.
4640 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4642 * linux-low.c (proceed_one_lwp): Return void, change parameter
4644 (unsuspend_and_proceed_one_lwp): Likewise.
4645 (proceed_all_lwps): Use for_each_thread.
4646 (unstop_all_lwps): Likewise.
4648 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4650 * linux-low.c (linux_resume_one_thread): Return void, take
4652 (linux_resume): Use for_each_thread.
4654 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4656 * linux-low.c (send_sigstop_callback): Return void, change
4657 parameter type. Rename to...
4658 (send_sigstop): ... this.
4659 (suspend_and_send_sigstop_callback): Return void, change parameter
4661 (suspend_and_send_sigstop): ... this.
4662 (stop_all_lwps): Use for_each_thread.
4664 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4666 * linux-low.c (lwp_running): Return bool, remove unused
4668 (linux_stabilize_threads): Use find_thread.
4670 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4672 * linux-low.c (select_singlestep_lwp_callback): Remove.
4673 (count_events_callback): Remove.
4674 (select_event_lwp_callback): Remove.
4675 (select_event_lwp): Use find_thread/for_each_thread.
4677 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4679 * linux-low.c (not_stopped_callback): Return bool, take filter
4681 (linux_wait_for_event_filtered): Use find_thread.
4682 (linux_wait_1): Likewise.
4684 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4686 * linux-low.c (same_lwp): Remove.
4687 (find_lwp_pid): Use find_thread.
4689 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4691 * linux-low.c (delete_lwp_callback): Remove.
4692 (linux_mourn): Use for_each_thread.
4694 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4696 * linux-low.c (linux_detach_lwp_callback): Return void, remove
4697 args parameter, don't check for pid.
4698 (linux_detach): Use for_each_thread.
4700 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4702 * linux-low.c (struct counter): Remove.
4703 (second_thread_of_pid_p): Remove.
4704 (last_thread_of_process_p): Use find_thread.
4706 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4708 * inferiors.c (find_inferior_in_random): Remove.
4709 * inferiors.h (find_inferior_in_random): Remove.
4710 * linux-low.c (status_pending_p_callback): Return bool, accept
4711 parameter ptid directly.
4712 (linux_wait_for_event_filtered): Use find_thread_in_random.
4713 (linux_wait_1): Likewise.
4715 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4717 * inferiors.c (find_inferior_id): Remove.
4718 (find_thread_ptid): Move implemention from find_inferior_id to
4720 * inferiors.h (find_inferior_id): Remove.
4721 * server.c (handle_status): Use find_thread_ptid.
4722 (process_serial_event): Likewise.
4723 * thread-db.c (find_one_thread): Likewise.
4724 (thread_db_thread_handle): Likewise.
4725 * win32-low.c (thread_rec): Likewise.
4726 (child_delete_thread): Likewise.
4727 (win32_thread_alive): Likewise.
4728 (get_child_debug_event): Likewise.
4730 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4732 * linux-mips-low.c (update_watch_registers_callback): Return
4733 void, remove pid_p parameter, don't check for pid.
4734 (mips_insert_point, mips_remove_point): Use for_each_thread.
4736 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4738 * lynx.low (lynx_delete_thread_callback): Remove.
4739 (lynx_mourn): Use for_each_thread.
4741 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4743 * regcache.c (regcache_invalidate_one): Remove.
4744 (regcache_invalidate_pid): use for_each_thread.
4746 2017-11-26 Tom Tromey <tom@tromey.com>
4748 * linux-low.c (linux_create_inferior): Update.
4750 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
4752 * spu-low.c (spu_create_inferior): Fix typo in argument name.
4754 2017-11-24 Alan Hayward <alan.hayward@arm.com>
4756 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
4757 * linux-aarch64-low.c (initialize_low_arch): Call init func.
4758 * linux-aarch64-tdesc-selftest.c: New file.
4759 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
4761 2017-11-24 Alan Hayward <alan.hayward@arm.com>
4763 * configure.srv: Add new file.
4764 * linux-aarch64-low.c (initialize_low_arch): Call init func.
4765 * linux-aarch64-tdesc-selftest.c: New file.
4766 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
4768 2017-11-24 Alan Hayward <alan.hayward@arm.com>
4770 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
4771 * linux-aarch64-low.c (initialize_low_arch): Remove init.
4772 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
4774 2017-11-24 Alan Hayward <alan.hayward@arm.com>
4776 * configure.srv: Add new files.
4777 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
4778 aarch64_linux_read_description.
4779 * linux-aarch64-low.c (aarch64_linux_read_description):
4780 Merge with aarch64_arch_setup.
4781 (aarch64_arch_setup): Call aarch64_linux_read_description.
4782 * linux-aarch64-tdesc.c: New file.
4783 * linux-aarch64-tdesc.h: New file.
4785 2017-11-24 Yao Qi <yao.qi@linaro.org>
4787 * configure.srv: Set $srv_regobj for tic6x-linux.
4788 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
4789 (tic6x_read_description): Move some code to tic6x_arch_setup.
4790 (tic6x_tdesc_test): New function.
4791 (initialize_low_arch): Call selftests::register_test.
4793 2017-11-22 Yao Qi <yao.qi@linaro.org>
4795 * remote-utils.c (prepare_resume_reply): Use memcpy.
4797 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4799 * linux-low.c (kill_one_lwp_callback): Return void, take
4800 argument directly, don't filter on pid.
4801 (linux_kill): Use for_each_thread.
4803 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4805 * linux-low.c (need_step_over_p): Return bool, remove dummy
4807 (linux_resume, proceed_all_lwps): Use find_thread.
4809 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4811 * linux-low.c (resume_status_pending_p): Return bool, remove
4813 (linux_resume): Use find_thread.
4815 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4817 * linux-low.c (struct thread_resume_array): Remove.
4818 (linux_set_resume_request): Return void, take arguments
4820 (linux_resume): Use for_each_thread.
4822 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4824 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
4825 return bool, remove data argument.
4826 (linux_stabilize_threads): Use find_thread.
4828 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4830 * linux-low.c (unsuspend_one_lwp): Remove.
4831 (unsuspend_all_lwps): Use for_each_thread, inline code from
4834 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4836 * gdbthread.h (find_thread): Add overload with ptid_t filter.
4837 * linux-low.c (struct iterate_over_lwps_args): Remove.
4838 (iterate_over_lwps_filter): Remove.
4839 (iterate_over_lwps): Use find_thread.
4841 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4843 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
4844 (linux_handle_new_gdb_connection): Use for_each_thread, inline
4845 code from reset_lwp_ptrace_options_callback.
4847 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4849 * linux-arm-low.c (struct update_registers_data): Remove.
4850 (update_registers_callback): Return void, take arguments
4851 directly, don't check thread's pid.
4852 (arm_insert_point, arm_remove_point): Use for_each_thread.
4854 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4856 * win32-low.c (continue_one_thread): Return void, take argument
4858 (child_continue): Use for_each_thread.
4860 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4862 * win32-i386-low.c (update_debug_registers_callback): Rename
4864 (update_debug_registers): ... this, return void, remove pid_p arg.
4865 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
4867 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
4869 * inferiors.h (struct process_info): Add constructor, initialize
4871 <syscalls_to_catch>: Change type to std::vector<int>.
4872 * inferiors.c (add_process): Allocate process_info with new.
4873 (remove_process): Free process_info with delete.
4874 * linux-low.c (handle_extended_wait): Adjust.
4875 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
4876 * server.c (handle_general_set): Adjust.
4878 2017-11-16 Pedro Alves <palves@redhat.com>
4880 * remote-utils.c (remote_close): Block SIGIO signals instead of
4881 uninstalling the SIGIO handler.
4883 2017-11-16 Alan Hayward <alan.hayward@arm.com>
4885 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
4887 2017-11-16 Yao Qi <yao.qi@linaro.org>
4889 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
4890 (tic6x_store_gregset): Likewise.
4891 (tic6x_usrregs_info): Move it up.
4893 2017-11-15 Alan Hayward <alan.hayward@arm.com>
4895 * Makefile.in: Update arch rules.
4896 * configure.srv: Explicitly mark arch/ files.
4898 2017-11-13 Andreas Schwab <schwab@suse.de>
4900 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
4902 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4904 2017-11-06 Pedro Alves <palves@redhat.com>
4906 * config.in, configure: Regenerate.
4908 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4910 * target.c (struct thread_search): Remove.
4911 (thread_search_callback): Remove.
4912 (prepare_to_access_memory): Use for_each_thread instead of
4913 find_inferior. Inline code from thread_search_callback.
4915 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4917 * server.c (struct visit_actioned_threads_data): Remove.
4918 (visit_actioned_threads): Change prototype to take arguments
4920 (resume): Use find_thread instead of find_inferior.
4922 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4924 * server.c (queue_stop_reply_callback): Change prototype, return
4926 (find_status_pending_thread_callback): Remove.
4927 (handle_status): Replace find_inferior with find_thread and
4930 2017-10-25 Alan Hayward <alan.hayward@arm.com>
4932 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
4934 (aarch64_store_gregset): Likewise.
4935 (aarch64_fill_fpregset): Likewise.
4936 (aarch64_store_fpregset): Likewise.
4938 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
4940 * gdbthread.h (find_thread, for_each_thread): New functions.
4941 * inferiors.c (thread_of_pid): Remove.
4942 (find_any_thread_of_pid): Use find_thread.
4943 * linux-low.c (num_lwps): Use for_each_thread.
4945 2017-10-17 Yao Qi <yao.qi@linaro.org>
4947 * Makefile.in: Remove one rule.
4948 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
4950 2017-10-17 Yao Qi <yao.qi@linaro.org>
4952 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
4953 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
4955 2017-10-17 Yao Qi <yao.qi@linaro.org>
4957 * configure.srv: Rename arm.o with arch/arm.o.
4959 2017-10-17 Yao Qi <yao.qi@linaro.org>
4961 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
4962 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
4963 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
4964 (arch-i386.o, arch-amd64.o): Remove rules.
4965 (arch/%.o): New rule.
4966 Update POSTCOMPILE and COMPILE.pre.
4967 * configure.ac: Invoke AC_CONFIG_COMMANDS.
4968 * configure: Re-generated.
4969 * configure.srv: Replace arch-i386.o with arch/i386.o.
4970 Replace arch-amd64.o with arch/amd64.o.
4972 2017-10-16 Yao Qi <yao.qi@linaro.org>
4974 * configure: Regenerated.
4976 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4978 * inferiors.h: (struct inferior_list): Remove.
4979 (struct inferior_list_entry); Remove.
4980 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
4981 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
4982 get_first_inferior): Remove.
4983 (for_each_inferior, for_each_inferior_with_data, find_inferior,
4984 find_inferior_id, find_inferior_in_random): Change signature.
4985 * inferiors.c (all_threads): Change type to
4986 std::list<thread_info *>.
4987 (get_thread): Remove macro.
4988 (find_inferior, find_inferior_id): Change signature, implement
4990 (find_inferior_in_random): Change signature, implement using
4991 find_thread_in_random.
4992 (for_each_inferior, for_each_inferior_with_data): Change
4993 signature, implement using for_each_thread.
4994 (add_inferior_to_list, remove_inferior): Remove.
4995 (add_thread, get_first_thread, thread_of_pid,
4996 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
4997 (get_first_inferior, one_inferior_p, clear_inferior_list):
4999 (clear_inferiors, get_thread_process): Update.
5000 * gdbthread.h: Include <list>.
5001 (struct thread_info) <entry>: Remove field.
5003 (all_threads): Change type to std::list<thread_info *>.
5004 (get_first_inferior): Add doc.
5005 (find_thread, for_each_thread, find_thread_in_random): New
5007 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
5008 * linux-arm-low.c (update_registers_callback): Update.
5009 * linux-low.c (second_thread_of_pid_p): Update.
5010 (kill_one_lwp_callback, linux_detach_lwp_callback,
5011 delete_lwp_callback, status_pending_p_callback, same_lwp,
5012 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
5013 iterate_over_lwps, not_stopped_callback,
5014 resume_stopped_resumed_lwps, count_events_callback,
5015 select_singlestep_lwp_callback, select_event_lwp_callback,
5016 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
5017 suspend_and_send_sigstop_callback, wait_for_sigstop,
5018 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
5019 lwp_running, linux_set_resume_request, resume_status_pending_p,
5020 need_step_over_p, start_step_over, linux_resume_one_thread,
5021 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
5022 reset_lwp_ptrace_options_callback): Update.
5023 * linux-mips-low.c (update_watch_registers_callback): Update.
5024 * regcache.c (regcache_invalidate_one, regcache_invalidate):
5026 (free_register_cache_thread_one): Remove.
5027 (regcache_release): Update.
5028 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
5029 handle_qxfer_threads_worker): Update.
5030 (handle_query): Update, use list iterator.
5031 (visit_actioned_threads, handle_pending_status,
5032 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
5033 clear_pending_status_callback, set_pending_status_callback,
5034 find_status_pending_thread_callback, handle_status,
5035 process_serial_event): Update.
5036 * target.c (thread_search_callback): Update.
5037 * thread-db.c (thread_db_get_tls_address): Update.
5038 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
5040 * win32-i386-low.c (update_debug_registers_callback): Update.
5041 * win32-low.c (delete_thread_info, child_delete_thread,
5042 continue_one_thread, suspend_one_thread,
5043 get_child_debug_event): Adjust.
5045 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
5047 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
5048 * inferiors.h: Include <list>.
5049 (struct process_info) <entry>: Remove field.
5051 (pid_of): Change macro to function.
5052 (ptid_of, lwpid_of): Remove macro.
5053 (all_processes): Change type to std::list<process_info *>.
5054 (ALL_PROCESSES): Remove macro.
5055 (for_each_process, find_process): New function.
5056 * inferiors.c (all_processes): Change type to
5057 std::list<process_info *>.
5058 (find_thread_process): Adjust.
5059 (add_process): Likewise.
5060 (remove_process): Likewise.
5061 (find_process_pid): Likewise.
5062 (get_first_process): Likewise.
5063 (started_inferior_callback): Remove.
5064 (have_started_inferiors_p): Adjust.
5065 (attached_inferior_callback): Remove.
5066 (have_attached_inferiors_p): Adjust.
5067 * linux-low.c (check_zombie_leaders): Likewise.
5068 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
5069 (x86_linux_update_xmltarget): Adjust.
5070 * server.c (handle_query): Likewise.
5071 (gdb_reattached_process): Remove.
5072 (handle_status): Adjust.
5073 (kill_inferior_callback): Likewise.
5074 (detach_or_kill_inferior): Remove.
5075 (print_started_pid): Likewise.
5076 (print_attached_pid): Likewise.
5077 (detach_or_kill_for_exit): Update.
5078 (process_serial_event): Likewise.
5079 * linux-arm-low.c (arm_new_fork): Likewise.
5081 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
5083 * dll.h: Include <list>.
5084 (struct dll_info): Add constructor.
5085 <entry>: Remove field.
5086 (all_dlls): Change type to std::list<dll_info>.
5087 * dll.c: Include <algorithm>.
5088 (get_dll): Remove macro.
5089 (all_dlls): Change type to std::list<dll_info *>.
5090 (free_one_dll): Remove.
5091 (match_dll): Likewise.
5092 (loaded_dll): Adjust.
5093 (unloaded_dll): Adjust to all_dlls type change, use
5094 std::find_if. Inline code from match_dll.
5095 (clear_dlls): Adjust to all_dlls type change.
5096 * server.c (emit_dll_description): Remove.
5097 (handle_qxfer_libraries): Adjust to all_dlls type change,
5098 integrate emit_dll_description's functionality.
5100 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
5102 * linux-low.h (struct linux_target_ops) <delete_process>: New
5104 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
5105 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
5106 (struct linux_target_ops): Add delete_process callback.
5107 * linux-arm-low.c (arm_delete_process): New.
5108 (struct linux_target_ops): Add delete_process callback.
5109 * linux-bfin-low.c (struct linux_target_ops): Likewise.
5110 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
5111 * linux-m32r-low.c (struct linux_target_ops): Likewise.
5112 * linux-mips-low.c (mips_linux_delete_process): New.
5113 (struct linux_target_ops): Add delete_process callback.
5114 * linux-ppc-low.c (struct linux_target_ops): Likewise.
5115 * linux-s390-low.c (struct linux_target_ops): Likewise.
5116 * linux-sh-low.c (struct linux_target_ops): Likewise.
5117 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
5118 * linux-tile-low.c (struct linux_target_ops): Likewise.
5119 * linux-x86-low.c (x86_linux_delete_process): New.
5120 (struct linux_target_ops): Add delete_process callback.
5121 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
5123 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
5125 * linux-aarch64-low.c (the_low_target): Add thread delete
5127 * linux-arm-low.c (arm_delete_thread): New function.
5128 (the_low_target): Add thread delete callback.
5129 * linux-bfin-low.c (the_low_target): Likewise.
5130 * linux-crisv32-low.c (the_low_target): Likewise.
5131 * linux-low.c (delete_lwp): Invoke delete_thread callback if
5133 * linux-low.h (struct linux_target_ops) <delete_thread>: New
5135 * linux-m32r-low.c (the_low_target): Add thread delete callback.
5136 * linux-mips-low.c (mips_linux_delete_thread): New function.
5137 (the_low_target): Add thread delete callback.
5138 * linux-ppc-low.c (the_low_target): Likewise.
5139 * linux-s390-low.c (the_low_target): Likewise.
5140 * linux-sh-low.c (the_low_target): Likewise.
5141 * linux-tic6x-low.c (the_low_target): Likewise.
5142 * linux-tile-low.c (the_low_target): Likewise.
5143 * linux-x86-low.c (the_low_target): Likewise.
5144 * linux-xtensa-low.c (the_low_target): Likewise.
5146 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
5148 * win32-low.c: Include "common-inferior.h".
5150 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
5152 * inferiors.c (set_inferior_cwd): New function.
5153 * server.c (handle_general_set): Handle QSetWorkingDir packet.
5154 (handle_query): Inform that QSetWorkingDir is supported.
5155 * win32-low.c (create_process): Pass the inferior's cwd to
5158 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
5160 * inferiors.c (current_inferior_cwd): New global variable.
5161 (get_inferior_cwd): New function.
5162 * inferiors.h (struct process_info) <cwd>: New field.
5164 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
5166 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
5167 (OBS): Add gdb_tilde_expand.o.
5169 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
5171 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
5172 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
5174 2017-09-29 Pedro Alves <palves@redhat.com>
5176 * ax.c (gdb_parse_agent_expr): Constify.
5177 * ax.h (gdb_parse_agent_expr): Constify.
5178 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
5180 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
5181 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
5182 * remote-utils.h (read_ptid): Constify.
5183 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
5184 (process_point_options, process_serial_event): Constify.
5185 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
5186 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
5187 (cmd_qtbuffer): Constify.
5189 2017-09-29 Pedro Alves <palves@redhat.com>
5191 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
5194 2017-09-29 Pedro Alves <palves@redhat.com>
5196 * linux-low.c (handle_extended_wait): Pass parent thread instead
5197 of process to thread_db_notice_clone.
5198 * linux-low.h (thread_db_notice_clone): Replace parent process
5199 parameter with parent thread parameter.
5200 * thread-db.c (find_one_thread): Add comment.
5201 (thread_db_notice_clone): Replace parent process parameter with
5202 parent thread parameter. Temporarily switch to the parent thread.
5204 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
5206 * gdbthread.h: Include "common-gdbthread.h".
5207 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
5208 "if" when validating the ptid.
5209 * remote-utils.c: Include "gdbthread.h".
5210 (prepare_resume_reply): Use "switch_to_thread".
5211 * target.c (done_accessing_memory): Likewise.
5213 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
5215 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
5216 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
5217 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
5218 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
5219 s390x-gs-linux64-ipa.o to ipa_obj.
5220 * linux-s390-low.c (HWCAP_S390_GS): New define.
5221 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
5223 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
5224 (s390_arch_setup): Check for guarded-storage support and choose
5226 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
5227 init_registers_s390x_gs_linux64.
5228 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
5230 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
5231 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
5233 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
5235 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
5237 2017-09-21 Kevin Buettner <kevinb@redhat.com>
5239 * linux-low.h (struct lwp_info): Add new field, thread_handle.
5240 (thread_db_thread_handle): Declare.
5241 * linux-low.c (linux_target_ops): Initialize thread_handle.
5242 * server.c (handle_qxfer_threads_worker): Add support for
5244 * target.h (struct target_ops): Add new function pointer,
5246 (target_thread_handle): Define.
5247 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
5249 (thread_db_thread_handle): New function.
5251 2017-09-21 Kevin Buettner <kevinb@redhat.com>
5253 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
5254 * linux-low.h (thread_db_notice_clone): Declare.
5255 * thread-db.c (thread_db_notice_clone): New function.
5257 2017-09-21 Pedro Alves <palves@redhat.com>
5259 * server.c (gdb_read_memory, handle_status, process_serial_event)
5260 (handle_serial_event, handle_target_event): Adjust to
5261 set_desired_thread prototype change.
5262 * target.c (set_desired_thread): Remove 'use_general' parameter
5264 * target.h (set_desired_thread): Remove 'use_general' parameter.
5266 2017-09-20 Tom Tromey <tom@tromey.com>
5268 * target.c (target_terminal::terminal_state): Define.
5269 (target_terminal::init): Rename from target_terminal_init.
5270 (target_terminal::inferior): Rename from
5271 target_terminal_inferior.
5272 (target_terminal::ours): Rename from target_terminal_ours.
5273 (target_terminal::ours_for_output, target_terminal::info): New.
5275 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
5277 * server.c (accumulate_file_name_length): Remove.
5278 (emit_dll_description): Adjust to std::string change.
5279 (handle_qxfer_libraries): Use std::string to hold document.
5281 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
5283 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
5284 return type of xml_escape_text.
5285 * server.c (emit_dll_description): Likewise.
5287 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
5289 * server.c (captured_main): Accept argument for --selftest.
5290 Update run_tests call.
5291 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
5292 when registering selftests.
5294 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
5296 * regcache.c (get_thread_regcache): Update code to use "std::vector"
5297 instead of "VEC" for "target_desc.reg_defs".
5298 (regcache_cpy): Likewise.
5299 (registers_to_string): Likewise.
5300 (registers_from_string): Likewise.
5301 (find_regno): Likewise.
5302 (supply_regblock): Likewise.
5303 (regcache_raw_read_unsigned): Likewise.
5304 * tdesc.c (init_target_desc): Likewise.
5305 (tdesc_create_reg): Likewise.
5306 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
5307 (struct target_desc) <reg_defs>: Convert to "std::vector".
5308 (target_desc): Do not initialize "reg_defs".
5309 (~target_desc): Update code to use "std::vector" instead of "VEC"
5310 for "target_desc.reg_defs".
5311 (operator==): Likewise.
5313 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
5315 * inferiors.h (thread_to_gdb_id): Remove.
5316 * inferiors.c (thread_to_gdb_id): Remove.
5317 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
5318 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
5319 lynx_store_registers, lynx_read_memory, lynx_write_memory):
5321 * nto-low.c (nto_fetch_registers, nto_store_registers,
5322 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
5324 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
5326 * inferiors.h (gdb_id_to_thread_id): Remove.
5327 * inferiors.c (gdb_id_to_thread_id): Remove.
5328 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
5329 removal. Move pid declaration closer to where it's used.
5331 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
5333 * server.c (handle_detach): New function.
5334 (process_serial_event): Move code out, call handle_detach.
5336 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
5338 * server.c (require_running): Rename to ...
5339 (require_running_or_return): ... this ...
5340 (require_running_or_break): ... and this.
5341 (handle_query, process_serial_event): Adjust.
5343 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
5345 * linux-low.c (linux_set_resume_request): Remove unused
5348 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
5350 * server.c (first_thread_of): Remove.
5351 (process_serial_event): Replace usage of first_thread_of with
5352 find_any_thread_of_pid.
5353 * tracepoint.c (same_process_p): Remove.
5354 (gdb_agent_about_to_close): Replace usage of same_process_p with
5355 find_any_thread_of_pid.
5356 * linux-x86-low.c (same_process_callback): Remove.
5357 (x86_arch_setup_process_callback): Replace usage of
5358 same_process_callback with find_any_thread_of_pid.
5359 * thread-db.c (any_thread_of): Remove.
5360 (switch_to_process): Replace usage of any_thread_of with
5361 find_any_thread_of_pid.
5362 * inferiors.c (thread_pid_matches_callback): Remove.
5363 (find_thread_process): Adjust to use find_any_thread_of_pid.
5365 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
5367 * regcache.c (get_thread_regcache): Guard calls to "memset"
5370 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
5372 * linux-low.c (handle_extended_wait): Use
5373 "allocate_target_description" instead of "XNEW".
5374 * linux-x86-low.c (initialize_low_arch): Likewise.
5376 2017-09-05 Yao Qi <yao.qi@linaro.org>
5378 * configure.srv (srv_i386_regobj): Remove.
5379 (srv_amd64_regobj): Remove.
5380 (srv_regobj): Set it to "" for x86 non-linux targets.
5381 * linux-x86-tdesc.c (i386_linux_read_description):
5382 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
5383 (init_registers_i386): Remove the declaration.
5384 (tdesc_i386): Remove the declaration.
5385 (lynx_i386_arch_setup): Call i386_create_target_description.
5386 * nto-x86-low.c: Likewise.
5387 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
5388 [!__x86_64__]: include arch/i386.h.
5389 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
5391 2017-09-05 Yao Qi <yao.qi@linaro.org>
5393 * configure.srv (srv_amd64_linux_xmlfiles): Remove
5394 i386/amd64-XXX-linux from it.
5396 2017-09-05 Yao Qi <yao.qi@linaro.org>
5398 * configure.srv: Empty srv_amd64_linux_regobj if $development is
5400 (ipa_amd64_linux_regobj): Remove.
5401 (ipa_x32_linux_regobj): Remove.
5403 2017-09-05 Yao Qi <yao.qi@linaro.org>
5405 * Makefile.in (arch-amd64.o): New rule.
5406 * configure.srv: Append arch-amd64.o.
5407 * linux-amd64-ipa.c: Include common/x86-xstate.h.
5408 (get_ipa_tdesc): Call amd64_linux_read_description.
5409 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
5410 and init_registers_amd64_XXX.
5411 * linux-x86-low.c (x86_linux_read_description): Call
5412 amd64_linux_read_description.
5413 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
5414 (initialize_low_arch): Don't call init_registers_x32_XXX and
5415 init_registers_amd64_XXX.
5416 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
5417 and tdesc_amd64_XXX.
5418 [__x86_64__] (amd64_tdesc_test): New function.
5419 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
5420 and init_registers_amd64_XXX.
5421 * linux-x86-tdesc.c: Include arch/amd64.h.
5422 (xcr0_to_tdesc_idx): New function.
5423 (i386_linux_read_description): New function.
5424 (amd64_get_ipa_tdesc_idx): New function.
5425 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
5426 (amd64_get_ipa_tdesc): Declare.
5428 2017-09-05 Yao Qi <yao.qi@linaro.org>
5430 * configure.srv (srv_i386_linux_xmlfiles): Remove
5431 i386/i386-XXX-linux.xml from it.
5433 2017-09-05 Yao Qi <yao.qi@linaro.org>
5435 * configure.srv: Set srv_i386_linux_regobj empty if $development
5437 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
5438 initialize_low_tdesc.
5439 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
5440 with #if initialize_low_tdesc.
5441 * linux-x86-tdesc-selftest.c: New file.
5442 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
5444 2017-09-05 Yao Qi <yao.qi@linaro.org>
5446 * Makefile.in (arch-i386.o): New rule.
5447 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
5448 (x86_64-*-linux*): Likewise.
5449 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
5450 include arch/i386.h.
5451 (i386_linux_read_description): Remove code and call
5452 i386_create_target_description.
5453 * tdesc.c (allocate_target_description): New function.
5454 * tdesc.h (set_tdesc_architecture): Remove declaration.
5455 (set_tdesc_osabi): Likewise.
5457 2017-09-05 Yao Qi <yao.qi@linaro.org>
5459 * linux-x86-tdesc.c: Don't include <inttypes.h>.
5460 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
5461 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
5463 * server.c (get_features_xml): Call tdesc_get_features_xml.
5464 * tdesc.c (set_tdesc_architecture): New function.
5465 (set_tdesc_osabi): New function.
5466 (tdesc_get_features_xml): New function.
5467 (tdesc_create_feature): Add an argument.
5468 * tdesc.h (struct target_desc) <features>: New field.
5469 <arch, osabi>: New field.
5470 (~target_desc): xfree features, arch, and osabi.
5471 (target_desc::oerator==): Don't compare .xmltarget.
5472 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
5473 (set_tdesc_osabi): Likewise.
5474 (tdesc_get_features_xml): Likewise.
5476 2017-09-05 Yao Qi <yao.qi@linaro.org>
5478 * linux-x86-tdesc.c: Include selftest.h.
5479 (i386_tdesc_test): New function.
5480 (initialize_low_tdesc): Call selftests::register_test.
5481 * tdesc.h: Include regdef.h.
5482 (target_desc): Override operator == and !=.
5484 2017-09-05 Yao Qi <yao.qi@linaro.org>
5486 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
5487 (ipa_obj): Likewise.
5488 * linux-i386-ipa.c: Include common/x86-xstate.h
5489 (get_ipa_tdesc): Call i386_linux_read_description.
5490 (initialize_low_tracepoint): Don't call init_registers_XXX
5491 functions, call initialize_low_tdesc instead.
5492 * linux-x86-low.c (x86_linux_read_description): Call
5493 i386_linux_read_description.
5494 (initialize_low_arch): Don't call init_registers_i386_XXX
5495 functions, call initialize_low_tdesc.
5496 * linux-x86-tdesc.c: New file.
5497 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
5498 (i386_get_ipa_tdesc_idx): Declare.
5499 (i386_get_ipa_tdesc): Declare.
5500 (initialize_low_tdesc): Declare.
5502 2017-09-05 Yao Qi <yao.qi@linaro.org>
5504 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
5507 2017-09-05 Yao Qi <yao.qi@linaro.org>
5509 * Makefile.in (IPA_OBJS): Add vec-ipa.o
5510 * regcache.c (get_thread_regcache): Use VEC_length.
5511 (init_register_cache): Likewise.
5512 (regcache_cpy): Likewise.
5513 (registers_to_string): Iterate reg_defs via VEC_iterate.
5514 (find_regno): Likewise.
5515 (find_register_by_number): Use VEC_index.
5516 (register_size): Call find_register_by_number.
5517 (register_data): Call find_register_by_number.
5518 (supply_regblock): Use VEC_length.
5519 (regcache_raw_read_unsigned): Likewise.
5520 * tdesc.c (init_target_desc): Iterate reg_defs via
5522 (default_description): Update initializer.
5523 (copy_target_description): Don't update field num_registers.
5524 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
5525 <num_registers>: Remove.
5527 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
5529 * Makefile.in (.SECONDARY): Define target.
5531 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
5533 * linux-low.c (linux_wait_1): Adjust.
5534 * server.c (queue_stop_reply_callback): Adjust.
5536 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
5538 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
5539 QEnvironmentUnset and QEnvironmentReset packets.
5540 (handle_query): Inform remote that QEnvironmentHexEncoded,
5541 QEnvironmentUnset and QEnvironmentReset are supported.
5543 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
5545 * inferiors.h (inferior_target_data): Rename to ...
5546 (thread_target_data): ... this.
5547 (inferior_regcache_data): Rename to ...
5548 (thread_regcache_data): ... this.
5549 (set_inferior_regcache_data): Rename to ...
5550 (set_thread_regcache_data): ... this.
5551 * inferiors.c (inferior_target_data): Rename to ...
5552 (thread_target_data): ... this.
5553 (inferior_regcache_data): Rename to ...
5554 (thread_regcache_data): ... this.
5555 (set_inferior_regcache_data): Rename to ...
5556 (set_thread_regcache_data): ... this.
5557 (free_one_thread): Update.
5558 * linux-low.h (get_thread_lwp): Update.
5559 * regcache.c (get_thread_regcache): Update.
5560 (regcache_invalidate_thread): Update.
5561 (free_register_cache_thread): Update.
5562 * win32-i386-low.c (update_debug_registers_callback): Update.
5563 (win32_get_current_dr): Update.
5564 * win32-low.c (thread_rec): Update.
5565 (delete_thread_info): Update.
5566 (continue_one_thread): Update.
5567 (suspend_one_thread): Update.
5569 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
5571 * inferiors.c (set_inferior_target_data): Remove.
5572 * inferiors.h (set_inferior_target_data): Remove.
5574 2017-08-18 Yao Qi <yao.qi@linaro.org>
5576 * Makefile.in (OBS): Add selftest.o.
5577 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
5578 * configure, config.in: Re-generated.
5579 * server.c: Include common/sefltest.h.
5580 (captured_main): Handle option --selftest.
5582 2017-08-09 Yao Qi <yao.qi@linaro.org>
5584 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
5585 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
5586 i386-avx-mpx.o and i386-mmx.o.
5587 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
5588 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
5589 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
5590 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
5591 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
5592 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
5593 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
5594 i386/amd64-avx-mpx.xml.
5596 2017-08-09 Yao Qi <yao.qi@linaro.org>
5598 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
5599 and x32-avx-avx512.o.
5600 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
5601 i386/x32-avx-avx512.xml.
5603 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
5605 * tracepoint.h (enum class fast_tpoint_collect_result): New
5607 (fast_tracepoint_collecting): Change return type to
5608 fast_tpoint_collect_result.
5609 * tracepoint.c (fast_tracepoint_collecting): Likewise.
5610 * linux-low.h: Include tracepoint.h.
5611 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
5612 fast_tpoint_collect_result.
5613 * linux-low.c (handle_tracepoints): Adjust.
5614 (linux_fast_tracepoint_collecting): Change return type to
5615 fast_tpoint_collect_result.
5616 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
5617 linux_wait_1, stuck_in_jump_pad_callback,
5618 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
5619 proceed_one_lwp): Adjust to type change.
5621 2017-07-10 Yao Qi <yao.qi@linaro.org>
5623 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
5625 2017-06-29 Yao Qi <yao.qi@linaro.org>
5627 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
5629 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
5631 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
5633 * Makefile.in (IPA_OBJS): Sort and format one item per line.
5635 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
5637 * linux-low.c (linux_create_inferior): Adjust code to access the
5638 environment information via 'gdb_environ' class.
5639 * lynx-low.c (lynx_create_inferior): Likewise.
5640 * server.c (our_environ): Make it an instance of 'gdb_environ'.
5641 (get_environ): Return a pointer to 'our_environ'.
5642 (captured_main): Initialize 'our_environ'.
5643 * server.h (get_environ): Adjust prototype.
5644 * spu-low.c (spu_create_inferior): Adjust code to access the
5645 environment information via 'gdb_environ' class.
5647 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5649 * linux-low.c (linux_read_memory, linux_write_memory): Remove
5650 usage of "register" keyword.
5652 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5654 * configure: Re-generate.
5656 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5658 * configure: Re-generate.
5660 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5662 * Makefile.in (COMPILE.pre): Add "-x c++".
5664 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
5666 * fork-child.c: Conditionally include <signal.h>.
5668 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5670 * server.c (handle_general_set): Handle new packet
5671 "QStartupWithShell".
5672 (handle_query): Add "QStartupWithShell" to the list of supported
5674 (gdbserver_usage): Add help text explaining the
5675 new "--startup-with-shell" and "--no-startup-with-shell" CLI
5677 (captured_main): Recognize and act upon the presence of the new
5680 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5681 Pedro Alves <palves@redhat.com>
5683 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
5684 * configure: Regenerate.
5685 * configure.srv (srv_linux_obj): Add "fork-child.o" and
5687 (i[34567]86-*-lynxos*): Likewise.
5688 (spu*-*-*): Likewise.
5689 * fork-child.c: New file.
5690 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
5692 (linux_ptrace_fun): New function.
5693 (linux_create_inferior): Adjust function prototype to reflect
5694 change on "target.h". Adjust function code to use
5696 (linux_request_interrupt): Delete "signal_pid".
5697 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
5698 (lynx_ptrace_fun): New function.
5699 (lynx_create_inferior): Adjust function prototype to reflect
5700 change on "target.h". Adjust function code to use
5702 * nto-low.c (nto_create_inferior): Adjust function prototype and
5703 code to reflect change on "target.h". Update comments.
5704 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
5705 "common-terminal.h" and "environ.h".
5706 (terminal_fd): Moved to fork-child.c.
5707 (old_foreground_pgrp): Likewise.
5708 (restore_old_foreground_pgrp): Likewise.
5709 (last_status): Make it global.
5710 (last_ptid): Likewise.
5711 (our_environ): New variable.
5712 (startup_with_shell): Likewise.
5713 (program_name): Likewise.
5714 (program_argv): Rename to...
5715 (program_args): ...this.
5716 (wrapper_argv): New variable.
5717 (start_inferior): Delete function.
5718 (get_exec_wrapper): New function.
5719 (get_exec_file): Likewise.
5720 (get_environ): Likewise.
5721 (prefork_hook): Likewise.
5722 (post_fork_inferior): Likewise.
5723 (postfork_hook): Likewise.
5724 (postfork_child_hook): Likewise.
5725 (handle_v_run): Update code to deal with arguments coming from the
5726 remote host. Update calls from "start_inferior" to
5728 (captured_main): Likewise. Initialize environment variable. Call
5730 * server.h (post_fork_inferior): New prototype.
5731 (get_environ): Likewise.
5732 (last_status): Declare.
5733 (last_ptid): Likewise.
5734 (signal_pid): Likewise.
5735 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
5736 (spu_ptrace_fun): New function.
5737 (spu_create_inferior): Adjust function prototype to reflect change
5738 on "target.h". Adjust function code to use "fork_inferior".
5739 * target.c (target_terminal_init): New function.
5740 (target_terminal_inferior): Likewise.
5741 (target_terminal_ours): Likewise.
5742 * target.h: Include <vector>.
5743 (struct target_ops) <create_inferior>: Update prototype.
5744 (create_inferior): Update macro.
5745 * utils.c (gdb_flush_out_err): New function.
5746 * win32-low.c (win32_create_inferior): Adjust function prototype
5747 and code to reflect change on "target.h".
5749 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5751 * inferiors.c (switch_to_thread): New function.
5753 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5755 * Makefile.in (SFILE): Add "common/job-control.c".
5756 (OBS): Add "job-control.o".
5758 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
5760 * Makefile: Remove "@host_makefile_frag@".
5762 2017-05-05 Pedro Alves <palves@redhat.com>
5764 * configure: Regenerate.
5766 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
5768 * configure: Regenerate.
5770 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
5772 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
5773 software_single_step change of return type to
5774 std::vector<CORE_ADDR>.
5775 * linux-low.c (install_software_single_step_breakpoints):
5777 * linux-low.h (install_software_single_step_breakpoints):
5780 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
5782 * remote-utils.c: Include "gdb_termios.h" instead of
5784 * terminal.h: Delete file.
5786 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
5788 * server.c: Include <vector>.
5789 <program_argv, wrapper_argv>: Convert to std::vector.
5790 (start_inferior): Rewrite function to use C++.
5791 (handle_v_run): Likewise. Update code that calculates the argv
5792 based on the vRun packet; use C++.
5793 (captured_main): Likewise.
5795 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
5797 * server.c (handle_v_cont): Initialize thread_resume::thread
5800 2017-04-05 Pedro Alves <palves@redhat.com>
5802 * configure: Regenerate.
5804 2017-04-05 Pedro Alves <palves@redhat.com>
5806 * gdbreplay.c (sync_error): Constify.
5807 * linux-x86-low.c (push_opcode): Constify.
5809 2017-04-05 Pedro Alves <palves@redhat.com>
5811 * win32-low.c (get_child_debug_event)
5812 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
5813 Report TARGET_WAITKIND_SPURIOUS instead.
5815 2017-04-05 Pedro Alves <palves@redhat.com>
5817 * remote-utils.c (remote_prepare, remote_open): Constify.
5818 * remote-utils.h (remote_prepare, remote_open): Constify.
5819 * server.c (captured_main): Constify 'port' handling.
5821 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
5823 * Makefile.in (clean): Clear .deps.
5825 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
5827 * .gitignore: Remove generated files, replace with wildcard.
5828 * (clean): Replace removal of generated files with wildcard.
5829 (version.c): Replace with...
5830 (version-generated.c): ...this.
5831 (xml-builtin.c): Replace with...
5832 (xml-builtin-generated.c): ...this.
5833 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
5834 (%.c: *regformats*): Replace with...
5835 (%-generated.c: *regformats*): ...this.
5837 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
5839 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
5840 (xtensa_fill_gregset): Call collect_register_by_name for
5842 (xtensa_store_gregset): Call supply_register_by_name for
5845 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
5847 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
5848 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
5849 (xtensa_store_gregset): Call supply_register for all registers in
5850 a0_regnum..a0_regnum + C0_NREGS range.
5852 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5854 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
5855 (ax-ipa.o: ax.c): Remove.
5856 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
5857 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
5858 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
5859 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
5860 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
5862 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5864 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
5865 (print-utils-ipa.o: ../common/print-utils.c): Remove.
5866 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
5867 (errors-ipa.o: ../common/errors.c): Remove.
5868 (format-ipa.o: ../common/format.c): Remove.
5869 (common-utils-ipa.o: ../common/common-utils.c): Remove.
5871 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5873 * Makefile.in (%-ipa.o: %.c): New rule.
5874 (tracepoint-ipa.o: tracepoint.c): Remove.
5875 (utils-ipa.o: utils.c): Remove.
5876 (remote-utils-ipa.o: remote-utils.c): Remove.
5877 (regcache-ipa.o: regcache.c): Remove.
5878 (i386-linux-ipa.o: i386-linux.c): Remove.
5879 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
5880 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
5881 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
5882 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
5883 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
5884 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
5885 (amd64-linux-ipa.o: amd64-linux.c): Remove.
5886 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
5887 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
5888 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
5889 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
5890 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
5891 (aarch64-ipa.o: aarch64.c): Remove.
5892 (s390-linux32-ipa.o: s390-linux32.c): Remove.
5893 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
5894 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
5895 (s390-linux64-ipa.o: s390-linux64.c): Remove.
5896 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
5897 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
5898 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
5899 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
5900 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
5901 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
5902 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
5903 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
5904 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
5905 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
5906 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
5907 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
5908 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
5909 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
5910 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
5911 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
5912 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
5913 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
5914 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
5915 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
5916 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
5917 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
5918 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
5919 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
5920 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
5921 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
5922 (tdesc-ipa.o: tdesc.c): Remove.
5923 (x32-linux-ipa.o: x32-linux.c): Remove.
5924 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
5925 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
5927 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5929 * Makefile.in (%.o: ../arch/%.c): New rule.
5930 (arm.o: ../arch/arm.c): Remove.
5931 (arm-linux.o: ../arch/arm-linux.c): Remove.
5932 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
5933 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
5935 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5937 * Makefile.in (%.o: ../nat/%.c): New rule.
5938 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
5939 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
5940 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
5941 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
5942 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
5943 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
5944 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
5945 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
5946 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
5947 (linux-personality.o: ../nat/linux-personality.c): Remove.
5948 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
5949 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
5950 (x86-linux.o: ../nat/x86-linux.c): Remove.
5951 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
5952 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
5954 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5956 * Makefile.in (%.o: ../common/%.c): New rule.
5957 (signals.o: ../common/signals.c): Remove.
5958 (print-utils.o: ../common/print-utils.c): Remove.
5959 (rsp-low.o: ../common/rsp-low.c): Remove.
5960 (common-utils.o: ../common/common-utils.c): Remove.
5961 (posix-strerror.o: ../common/posix-strerror.c): Remove.
5962 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
5963 (vec.o: ../common/vec.c): Remove.
5964 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
5965 (xml-utils.o: ../common/xml-utils.c): Remove.
5966 (ptid.o: ../common/ptid.c): Remove.
5967 (buffer.o: ../common/buffer.c): Remove.
5968 (format.o: ../common/format.c): Remove.
5969 (filestuff.o: ../common/filestuff.c): Remove.
5970 (agent.o: ../common/agent.c): Remove.
5971 (errors.o: ../common/errors.c): Remove.
5972 (environ.o: ../common/environ.c): Remove.
5973 (common-debug.o: ../common/common-debug.c): Remove.
5974 (cleanups.o: ../common/cleanups.c): Remove.
5975 (common-exceptions.o: ../common/common-exceptions.c): Remove.
5976 (fileio.o: ../common/fileio.c): Remove.
5977 (common-regcache.o: ../common/common-regcache.c): Remove.
5978 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
5979 (new-op.o: ../common/new-op.c): Remove.
5980 (btrace-common.o: ../common/btrace-common.c): Remove.
5982 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5984 * Makefile.in (%.o: ../target/%.c): New rule.
5985 (waitstatus.o: ../target/waitstatus.c): Remove.
5987 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5990 (%.c: ../regformats/%.dat,
5991 (%.c: ../regformats/arm/%.dat,
5992 (%.c: ../regformats/i386/%.dat,
5993 (%.c: ../regformats/rs6000/%.dat): New rules.
5994 (aarch64.c): Remove.
5995 (reg-arm.c): Remove.
5996 (arm-with-iwmmxt.c): Remove.
5997 (arm-with-vfpv2.c): Remove.
5998 (arm-with-vfpv3.c): Remove.
5999 (arm-with-neon.c): Remove.
6000 (reg-bfin.c): Remove.
6001 (reg-cris.c): Remove.
6002 (reg-crisv32.c): Remove.
6004 (i386-linux.c): Remove.
6005 (i386-avx.c): Remove.
6006 (i386-avx-linux.c): Remove.
6007 (i386-avx-avx512.c): Remove.
6008 (i386-avx-avx512-linux.c): Remove.
6009 (i386-mpx.c): Remove.
6010 (i386-mpx-linux.c): Remove.
6011 (i386-avx-mpx-avx512-pku.c): Remove.
6012 (i386-avx-mpx-avx512-pku-linux.c): Remove.
6013 (i386-avx-mpx.c): Remove.
6014 (i386-avx-mpx-linux.c): Remove.
6015 (i386-mmx.c): Remove.
6016 (i386-mmx-linux.c): Remove.
6017 (reg-ia64.c): Remove.
6018 (reg-m32r.c): Remove.
6019 (reg-m68k.c): Remove.
6021 (mips-linux.c): Remove.
6022 (mips-dsp-linux.c): Remove.
6023 (mips64-linux.c): Remove.
6024 (mips64-dsp-linux.c): Remove.
6025 (nios2-linux.c): Remove.
6026 (powerpc-32.c): Remove.
6027 (powerpc-32l.c): Remove.
6028 (powerpc-altivec32l.c): Remove.
6029 (powerpc-cell32l.c): Remove.
6030 (powerpc-vsx32l.c): Remove.
6031 (powerpc-isa205-32l.c): Remove.
6032 (powerpc-isa205-altivec32l.c): Remove.
6033 (powerpc-isa205-vsx32l.c): Remove.
6034 (powerpc-e500l.c): Remove.
6035 (powerpc-64l.c): Remove.
6036 (powerpc-altivec64l.c): Remove.
6037 (powerpc-cell64l.c): Remove.
6038 (powerpc-vsx64l.c): Remove.
6039 (powerpc-isa205-64l.c): Remove.
6040 (powerpc-isa205-altivec64l.c): Remove.
6041 (powerpc-isa205-vsx64l.c): Remove.
6042 (s390-linux32.c): Remove.
6043 (s390-linux32v1.c): Remove.
6044 (s390-linux32v2.c): Remove.
6045 (s390-linux64.c): Remove.
6046 (s390-linux64v1.c): Remove.
6047 (s390-linux64v2.c): Remove.
6048 (s390-te-linux64.c): Remove.
6049 (s390-vx-linux64.c): Remove.
6050 (s390-tevx-linux64.c): Remove.
6051 (s390x-linux64.c): Remove.
6052 (s390x-linux64v1.c): Remove.
6053 (s390x-linux64v2.c): Remove.
6054 (s390x-te-linux64.c): Remove.
6055 (s390x-vx-linux64.c): Remove.
6056 (s390x-tevx-linux64.c): Remove.
6057 (tic6x-c64xp-linux.c): Remove.
6058 (tic6x-c64x-linux.c): Remove.
6059 (tic6x-c62x-linux.c): Remove.
6061 (reg-sparc64.c): Remove.
6062 (reg-spu.c): Remove.
6064 (amd64-linux.c): Remove.
6065 (amd64-avx.c): Remove.
6066 (amd64-avx-linux.c): Remove.
6067 (amd64-avx-avx512.c): Remove.
6068 (amd64-avx-avx512-linux.c): Remove.
6069 (amd64-mpx.c): Remove.
6070 (amd64-mpx-linux.c): Remove.
6071 (amd64-avx-mpx-avx512-pku.c): Remove.
6072 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
6073 (amd64-avx-mpx.c): Remove.
6074 (amd64-avx-mpx-linux.c): Remove.
6076 (x32-linux.c): Remove.
6077 (x32-avx.c): Remove.
6078 (x32-avx-linux.c): Remove.
6079 (x32-avx-avx512.c): Remove.
6080 (x32-avx-avx512-linux.c): Remove.
6081 (reg-xtensa.c): Remove.
6082 (reg-tilegx.c): Remove.
6083 (reg-tilegx32.c): Remove.
6085 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
6087 * Makefile.in (SFILES): Add "common/environ.c".
6088 (OBJS): Add "common/environ.h".
6090 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
6092 * configure.ac: Check if the fs_base and gs_base members of
6093 `struct user_regs_struct' exist.
6094 * config.in: Regenerated.
6095 * configure: Likewise.
6097 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
6099 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
6101 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
6102 (get_next_pcs_syscall_next_pc): Likewise.
6104 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
6106 * win32-i386-low.c: Fix incorrect reference to a couple source files.
6107 * nto-x86-low.c: Likewise.
6109 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
6111 * Makefile.in: Include disable-implicit-rules.mk.
6113 2016-11-23 Pedro Alves <palves@redhat.com>
6115 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
6116 (debug_vprintf): Use std::chrono::steady_clock instead of
6117 gettimeofday. Use '.' instead of ':'.
6118 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
6119 (get_timestamp): Use std::chrono::steady_clock instead of
6122 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
6124 * Makefile.in: Fix whitespace formatting.
6126 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
6128 * Makefile.in (SFILES, OBS): Flatten list and order
6131 2016-11-23 Pedro Alves <palves@redhat.com>
6133 * event-loop.c (handle_file_event): Use warning.
6134 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
6135 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
6138 2016-11-23 Pedro Alves <palves@redhat.com>
6140 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
6142 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
6143 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
6144 debug_printf and debug_flush for debug output.
6145 * server.c (handle_general_set): Likewise.
6146 * thread-db.c (try_thread_db_load): Use debug_printf for debug
6149 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
6151 * Makefile.in (.c.o): Replace rule with ...
6152 (%.o: %.c): ... this one.
6154 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
6156 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
6157 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
6159 * configure.ac: Remove checks for the make program.
6160 * configure: Re-generate.
6162 2016-10-28 Pedro Alves <palves@redhat.com>
6164 * Makefile.in (CXX_DIALECT): Get from configure.
6165 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
6166 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
6167 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
6168 * config.in: Regenerate.
6169 * configure: Regenerate.
6171 2016-10-27 Yao Qi <yao.qi@linaro.org>
6173 * linux-low.c (linux_supports_range_stepping): Return true if
6174 can_software_single_step return true.
6176 2016-10-27 Yao Qi <yao.qi@linaro.org>
6178 * inferiors.c (find_inferior_in_random): New function.
6179 * inferiors.h (find_inferior_in_random): Declare.
6180 * linux-low.c (linux_wait_for_event_filtered): Call
6181 find_inferior_in_random instead of find_inferior.
6183 2016-10-27 Yao Qi <yao.qi@linaro.org>
6185 * linux-low.c (linux_wait_1): If single-step breakpoints are
6186 inserted, remove them.
6188 2016-10-26 Pedro Alves <palves@redhat.com>
6190 * linux-low.c (handle_extended_wait): Link parent/child fork
6192 (linux_wait_1): Unlink them.
6193 (linux_set_resume_request): Ignore resume requests for
6194 already-resumed and unhandled fork child threads.
6195 * linux-low.h (struct lwp_info) <fork_relative>: New field.
6196 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
6198 (handle_v_requests) <vCont>: Don't call require_running.
6199 * server.h (in_queued_stop_replies): New declaration.
6201 2016-10-24 Yao Qi <yao.qi@linaro.org>
6204 * linux-aarch64-low.c (append_insns): Cast the return value to
6207 2016-10-10 Yao Qi <yao.qi@linaro.org>
6209 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
6211 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
6213 * target.c (target_supports_multi_process): New function, moved
6215 * target.h (target_supports_multi_process): ... here. Remove
6218 2016-10-05 Tom Tromey <tom@tromey.com>
6221 * tracepoint.c (handle_tracepoint_bkpts): Check
6222 ipa_error_tracepoint, not ipa_stopping_tracepoint.
6224 2016-10-05 Yao Qi <yao.qi@linaro.org>
6226 * configure.srv: Update the path of arm-*.xml files.
6228 2016-10-05 Terry Guo <terry.guo@arm.com>
6229 Yao Qi <yao.qi@linaro.org>
6231 * Makefile.in: Adjust the path of rules.
6232 * configure.srv: Update the path of xml files.
6233 * regformats/arm-with-iwmmxt.dat: Regenerated.
6234 * regformats/arm-with-neon.dat: Likewise.
6235 * regformats/arm-with-vfpv2.dat: Likewise.
6236 * regformats/arm-with-vfpv3.dat Likewise.
6238 2016-09-30 Yao Qi <yao.qi@linaro.org>
6241 * target.c (target_stop_and_wait): Don't call
6242 target_continue_no_signal, use resume_stop instead.
6244 2016-09-26 Yao Qi <yao.qi@linaro.org>
6246 * linux-low.c (linux_wait_1): Call debug_exit.
6248 2016-09-23 Pedro Alves <palves@redhat.com>
6250 * Makefile.in (SFILES): Add common/new-op.c.
6251 (OBS): Add common/new-op.o.
6252 (new-op.o): New rule.
6254 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
6256 * .gitinore: Ignore more files.
6258 2016-09-21 Yao Qi <yao.qi@linaro.org>
6260 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
6263 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
6265 * server.c (start_inferior): Call target_mourn_inferior instead of
6266 mourn_inferior; pass ptid_t argument to it.
6268 (handle_target_event): Likewise.
6269 * target.c (target_mourn_inferior): New function.
6270 * target.h (mourn_inferior): Delete macro.
6272 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
6274 * linux-low.c (lwp_is_stepping): New function.
6276 2016-09-06 Carl Love <cel@us.ibm.com>
6278 * server.c (start_inferior): Fixed comment, requested comment change
6279 didn't get updated correctly. Removed reference to ptrace () call as
6280 it is only true on Linux systems.
6282 2016-09-06 Carl Love <cel@us.ibm.com>
6284 * server.c (start_inferior): Do not call
6285 function target_post_create_inferior () if the
6286 inferior process has already exited.
6288 2016-09-05 Pedro Alves <palves@redhat.com>
6290 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
6291 (COMPILE.pre, CC_LD): Use CXX directly.
6292 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
6293 * acinclude.m4: Don't include build-with-cxx.m4.
6294 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
6295 * configure: Regenerate.
6297 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
6300 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
6301 call writing data to own_buf.
6303 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
6305 * target.c (mywait): Call target_wait instead of
6307 (target_wait): New function.
6309 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
6311 * server.c (start_inferior): New variable 'ptid'. Replace calls
6312 to the_target->resume by target_continue{,_no_signal}, depending
6314 * target.c (target_stop_and_wait): Call target_continue_no_signal
6315 instead of the_target->resume.
6316 (target_continue): New function.
6318 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
6320 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
6322 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
6325 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
6327 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
6328 * linux-arm-low.c (ps_get_thread_area): Likewise.
6329 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
6330 * linux-m68k-low.c (ps_get_thread_area): Likewise.
6331 * linux-mips-low.c (ps_get_thread_area): Likewise.
6332 * linux-nios2-low.c (ps_get_thread_area): Likewise.
6333 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
6334 * linux-x86-low.c (ps_get_thread_area): Likewise.
6335 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
6337 2016-08-19 Pedro Alves <palves@redhat.com>
6339 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
6341 2016-08-19 Pedro Alves <palves@redhat.com>
6343 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
6344 comment. Use memcpy instead of casting through unsigned long.
6346 2016-08-19 Pedro Alves <palves@redhat.com>
6348 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
6349 allocating around 0x80000000.
6351 2016-08-19 Pedro Alves <palves@redhat.com>
6354 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
6355 (x32-avx512-linux-ipa.o): New rules.
6356 * configure.ac (x86_64-*-linux*): New x32 check.
6357 * configure.srv (ipa_x32_linux_regobj): New.
6358 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
6359 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
6361 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
6363 * configure: Regenerate.
6365 2016-08-09 Pedro Alves <palves@redhat.com>
6368 * Makefile.in (OBS): Add signals-state-save-restore.o.
6369 (signals-state-save-restore.o): New rule.
6370 * config.in: Regenerate.
6371 * configure: Regenerate.
6372 * linux-low.c: Include "signals-state-save-restore.h".
6373 (linux_create_inferior): Call
6374 restore_original_signals_state.
6375 * server.c: Include "dispositions-save-restore.h".
6376 (captured_main): Call save_original_signals_state.
6378 2016-08-05 Pedro Alves <palves@redhat.com>
6380 * configure: Regenerate.
6382 2016-08-04 Yao Qi <yao.qi@linaro.org>
6384 * linux-low.c (regsets_fetch_inferior_registers): Check
6385 errno is ESRCH or not.
6387 2016-08-02 Yao Qi <yao.qi@linaro.org>
6389 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
6390 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
6391 (thread_db_load_search): Update.
6392 (try_thread_db_load_1): Don't look for td_ta_event_addr,
6393 td_ta_set_event and td_ta_event_getmsg.
6395 2016-07-26 Pedro Alves <palves@redhat.com>
6398 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
6399 of unsigned long for 64-bit registers and use uint32_t instead of
6400 unsigned int for 32-bit registers.
6402 2016-07-26 Pedro Alves <palves@redhat.com>
6404 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
6407 2016-07-21 Tom Tromey <tom@tromey.com>
6409 * configure: Rebuild.
6411 2016-07-21 Yao Qi <yao.qi@linaro.org>
6413 * mem-break.c (find_gdb_breakpoint): Cast bp to
6414 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
6416 2016-07-21 Yao Qi <yao.qi@linaro.org>
6418 * server.c (handle_v_requests): Support s and S actions
6419 if target_supports_software_single_step return true.
6421 2016-07-21 Yao Qi <yao.qi@linaro.org>
6423 * linux-low.c (resume_stopped_resumed_lwps): If resume request
6424 is resume_step, call maybe_hw_step.
6425 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
6427 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
6429 (proceed_one_lwp): If resume request is resume_step, install
6430 reinsert breakpoints and call maybe_hw_step.
6432 2016-07-21 Yao Qi <yao.qi@linaro.org>
6434 * linux-low.c (proceed_one_lwp): Declare.
6435 (linux_resume_one_thread): Remove local variable 'step'.
6436 Lift code enqueue signal. Call proceed_one_lwp instead of
6437 linux_resume_one_lwp.
6439 2016-07-21 Yao Qi <yao.qi@linaro.org>
6441 * linux-low.c (linux_resume_one_thread): Call
6442 enqueue_pending_signal.
6444 2016-07-21 Yao Qi <yao.qi@linaro.org>
6446 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
6447 * inferiors.c (do_restore_current_thread_cleanup): New function.
6448 (make_cleanup_restore_current_thread): Likewise.
6449 * linux-low.c (install_software_single_step_breakpoints): Call
6450 make_cleanup_restore_current_thread. Switch current_thread to
6453 2016-07-21 Yao Qi <yao.qi@linaro.org>
6455 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
6456 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
6457 (clone_one_breakpoint): Likewise.
6458 (delete_reinsert_breakpoints): Change parameter to thread.
6460 (has_reinsert_breakpoints): Likewise.
6461 (uninsert_reinsert_breakpoints): Likewise.
6462 (reinsert_reinsert_breakpoints): Likewise.
6463 * mem-break.h (set_reinsert_breakpoint): Update declaration.
6464 (delete_reinsert_breakpoints): Likewise.
6465 (reinsert_reinsert_breakpoints): Likewise.
6466 (uninsert_reinsert_breakpoints): Likewise.
6467 (has_reinsert_breakpoints): Likewise.
6469 2016-07-21 Yao Qi <yao.qi@linaro.org>
6471 * inferiors.c (get_thread_process): Make parameter const.
6472 * inferiors.h (get_thread_process): Update declaration.
6473 * mem-break.c (clone_all_breakpoints): Remove all parameters.
6474 Add new parameters child_thread and parent_thread. Callers
6476 * mem-break.h (clone_all_breakpoints): Update declaration.
6478 2016-07-21 Yao Qi <yao.qi@linaro.org>
6480 * mem-break.c (struct breakpoint) <cond_list>: Remove.
6481 <command_list, handler>: Remove.
6482 (struct gdb_breakpoint): New.
6483 (struct other_breakpoint): New.
6484 (struct reinsert_breakpoint): New.
6485 (is_gdb_breakpoint): New function.
6486 (any_persistent_commands): Update command_list if
6487 is_gdb_breakpoint returns true.
6488 (set_breakpoint): Create breakpoints according to their types.
6489 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
6490 (set_gdb_breakpoint_1): Likewise.
6491 (set_gdb_breakpoint): Likewise.
6492 (clear_breakpoint_conditions): Change parameter type to
6493 'struct gdb_breakpoint *'.
6494 (clear_breakpoint_commands): Likewise.
6495 (clear_breakpoint_conditions_and_commands): Likewise.
6496 (add_condition_to_breakpoint): Likewise.
6497 (add_breakpoint_condition): Likewise.
6498 (add_commands_to_breakpoint): Likewise.
6499 (check_breakpoints): Check other_breakpoint.
6500 (clone_one_breakpoint): Clone breakpopint according to its type.
6501 * mem-break.h (struct gdb_breakpoint): Declare.
6502 (set_gdb_breakpoint): Update declaration.
6503 (clear_breakpoint_conditions_and_commands): Likewise.
6504 (add_breakpoint_condition): Likewise.
6505 (add_breakpoint_commands): Likewise.
6506 * server.c (process_point_options): Change parameter type to
6507 'struct gdb_breakpoint *'.
6509 2016-07-21 Yao Qi <yao.qi@linaro.org>
6511 * mem-break.c (set_breakpoint_at): Rename it to ...
6512 (set_breakpoint_type_at): ... it.
6513 (set_breakpoint_at): Call set_breakpoint_type_at.
6514 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
6515 * mem-break.h (set_breakpoint_at): Update comments.
6517 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
6519 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
6521 (nios2_store_gregset): Likewise.
6523 2016-07-01 Pedro Alves <palves@redhat.com>
6524 Antoine Tremblay <antoine.tremblay@ericsson.com>
6526 * linux-low.c: Change interface to take the target lwp_info
6527 pointer directly and return void. Handle detaching from a zombie
6529 (linux_detach_lwp_callback): New function.
6530 (linux_detach): Detach from the leader thread after detaching from
6533 2016-06-28 Yao Qi <yao.qi@linaro.org>
6535 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
6536 for variable new_offset.
6537 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
6538 (aarch64_ftrace_insn_reloc_cb): Likewise.
6539 (aarch64_ftrace_insn_reloc_tb): Likewise.
6540 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
6541 PRIx64 instead of PRIx32.
6543 2016-06-28 Yao Qi <yao.qi@linaro.org>
6545 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
6546 (the_low_target): Install arm_get_syscall_trapinfo.
6548 2016-06-28 Yao Qi <yao.qi@linaro.org>
6550 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
6552 (the_low_target): Install aarch64_get_syscall_trapinfo.
6554 2016-06-28 Yao Qi <yao.qi@linaro.org>
6556 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
6558 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
6559 Remove parameter sysno.
6560 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
6563 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
6565 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
6566 (s390_emit_ne_goto): Likewise.
6567 (s390_emit_lt_goto): Likewise.
6568 (s390_emit_le_goto): Likewise.
6569 (s390_emit_gt_goto): Likewise.
6570 (s390_emit_ge_goto): Likewise.
6571 (s390x_emit_eq_goto): Likewise.
6572 (s390x_emit_ne_goto): Likewise.
6573 (s390x_emit_lt_goto): Likewise.
6574 (s390x_emit_le_goto): Likewise.
6575 (s390x_emit_gt_goto): Likewise.
6576 (s390x_emit_ge_goto): Likewise.
6577 (s390_emit_ops_impl): Mark variable static.
6578 (s390x_emit_ops): Likewise.
6580 2016-06-17 Yao Qi <yao.qi@linaro.org>
6582 * linux-low.c (handle_extended_wait): Call
6583 uninsert_reinsert_breakpoints for the parent process. Remove
6584 reinsert breakpoints from the child process. Reinsert them to
6585 the parent process when vfork is done.
6586 * mem-break.c (uninsert_reinsert_breakpoints): New function.
6587 (reinsert_reinsert_breakpoints): New function.
6588 * mem-break.h (uninsert_reinsert_breakpoints): Declare
6589 (reinsert_reinsert_breakpoints): Declare.
6591 2016-06-17 Yao Qi <yao.qi@linaro.org>
6593 * linux-low.c (handle_extended_wait): If the parent is doing
6594 step-over, remove the reinsert breakpoints from the forked child.
6596 2016-06-17 Yao Qi <yao.qi@linaro.org>
6598 * linux-low.c (unsuspend_all_lwps): Declare.
6599 (linux_low_filter_event): If thread exited, call finish_step_over.
6600 If step-over is finished, unsuspend other threads.
6602 2016-06-17 Yao Qi <yao.qi@linaro.org>
6604 * linux-low.c (linux_resume_one_lwp_throw): Assert
6605 has_reinsert_breakpoints returns false.
6606 * mem-break.c (delete_disabled_breakpoints): Assert
6607 bp type isn't reinsert_breakpoint.
6609 2016-06-17 Yao Qi <yao.qi@linaro.org>
6611 * linux-low.c (maybe_hw_step): New function.
6612 (linux_resume_one_lwp_throw): Call maybe_hw_step.
6613 (finish_step_over): Switch current_thread to lwp temporarily,
6614 and assert has_reinsert_breakpoints returns true.
6615 (proceed_one_lwp): Call maybe_hw_step.
6616 * mem-break.c (has_reinsert_breakpoints): New function.
6617 * mem-break.h (has_reinsert_breakpoints): Declare.
6619 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
6621 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
6623 2016-05-17 Yao Qi <yao.qi@linaro.org>
6625 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
6626 instead of find_inferior.
6628 2016-05-05 Yao Qi <yao.qi@linaro.org>
6630 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
6631 Initialize res to zero.
6633 2016-05-05 Yao Qi <yao.qi@linaro.org>
6635 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
6638 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
6640 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
6641 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
6642 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
6644 2016-04-28 Par Olsson <par.olsson@windriver.com>
6645 Simon Marchi <simon.marchi@ericsson.com>
6647 * tracepoint.c (write_inferior_int8): New function.
6648 (cmd_qtenable_disable): Write enable flag using
6649 write_inferior_int8.
6651 2016-04-25 Yao Qi <yao.qi@linaro.org>
6653 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
6654 (need_step_over_p): Return zero if the LWP has pending signals
6655 can be delivered on software single step target.
6657 2016-04-25 Yao Qi <yao.qi@linaro.org>
6659 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
6660 return instead of error.
6662 2016-04-22 Yao Qi <yao.qi@linaro.org>
6664 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
6667 2016-04-22 Yao Qi <yao.qi@linaro.org>
6669 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
6670 signal when stepping over breakpoint with software single
6673 2016-04-21 Pedro Alves <palves@redhat.com>
6675 * linux-s390-low.c (s390_collect_ptrace_register)
6676 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
6678 (s390_check_regset): Use void * instead of gdb_byte *.
6680 2016-04-20 Pedro Alves <palves@redhat.com>
6682 * configure: Renegerate.
6684 2016-04-20 Yao Qi <yao.qi@linaro.org>
6686 * linux-aarch32-low.c: Include "arch/arm-linux.h".
6687 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
6689 (arm_store_gregset): Likewise.
6691 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
6693 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
6694 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
6695 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
6696 (amd64-avx-mpx-linux.c): New rules.
6697 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
6698 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
6699 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
6700 (srv_amd64_regobj): Add amd64-avx-mpx.o.
6701 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
6702 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
6703 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
6704 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
6705 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
6706 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
6707 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
6708 * linux-x86-low.c (x86_linux_read_description): Add case for
6709 X86_XSTATE_AVX_MPX_MASK.
6710 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
6711 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
6712 init_registers_i386_avx_mpx_linux.
6713 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
6714 (initialize_low_tracepoint): Call
6715 init_registers_i386_avx_mpx_linux.
6716 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
6717 (initialize_low_tracepoint): Call
6718 init_registers_amd64_avx_mpx_linux.
6719 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
6720 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
6721 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
6724 2016-04-18 Pedro Alves <palves@redhat.com>
6726 * configure: Regenerate.
6728 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
6730 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
6731 (aarch64_emit_sub): Likewise.
6733 2016-04-12 Pedro Alves <palves@redhat.com>
6735 * utils.c (prepare_to_throw_exception): Delete.
6737 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
6739 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
6741 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
6743 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
6745 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
6747 * linux-aarch64-ipa.c: Add <elf.h> include.
6748 * linux-ppc-ipa.c: Add <elf.h> include.
6749 * linux-s390-ipa.c: Add <elf.h> include.
6751 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
6753 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
6754 (get_raw_reg_ptr): Likewise.
6755 (get_trace_state_variable_value_ptr): Likewise.
6756 (set_trace_state_variable_value_ptr): Likewise.
6757 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
6760 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
6761 Marcin Kościelnicki <koriakin@0x04.net>
6764 * linux-ppc-low.c (emit_insns): New function.
6765 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
6766 (ppc_emit_prologue): New function.
6767 (ppc_emit_epilogue): New function.
6768 (ppc_emit_add): New function.
6769 (ppc_emit_sub): New function.
6770 (ppc_emit_mul): New function.
6771 (ppc_emit_lsh): New function.
6772 (ppc_emit_rsh_signed): New function.
6773 (ppc_emit_rsh_unsigned): New function.
6774 (ppc_emit_ext): New function.
6775 (ppc_emit_zero_ext): New function.
6776 (ppc_emit_log_not): New function.
6777 (ppc_emit_bit_and): New function.
6778 (ppc_emit_bit_or): New function.
6779 (ppc_emit_bit_xor): New function.
6780 (ppc_emit_bit_not): New function.
6781 (ppc_emit_equal): New function.
6782 (ppc_emit_less_signed): New function.
6783 (ppc_emit_less_unsigned): New function.
6784 (ppc_emit_ref): New function.
6785 (ppc_emit_const): New function.
6786 (ppc_emit_reg): New function.
6787 (ppc_emit_pop): New function.
6788 (ppc_emit_stack_flush): New function.
6789 (ppc_emit_swap): New function.
6790 (ppc_emit_stack_adjust): New function.
6791 (ppc_emit_call): New function.
6792 (ppc_emit_int_call_1): New function.
6793 (ppc_emit_void_call_2): New function.
6794 (ppc_emit_if_goto): New function.
6795 (ppc_emit_goto): New function.
6796 (ppc_emit_eq_goto): New function.
6797 (ppc_emit_ne_goto): New function.
6798 (ppc_emit_lt_goto): New function.
6799 (ppc_emit_le_goto): New function.
6800 (ppc_emit_gt_goto): New function.
6801 (ppc_emit_ge_goto): New function.
6802 (ppc_write_goto_address): New function.
6803 (ppc_emit_ops_impl): New static variable.
6804 (ppc64v1_emit_prologue): New function.
6805 (ppc64v2_emit_prologue): New function.
6806 (ppc64_emit_epilogue): New function.
6807 (ppc64_emit_add): New function.
6808 (ppc64_emit_sub): New function.
6809 (ppc64_emit_mul): New function.
6810 (ppc64_emit_lsh): New function.
6811 (ppc64_emit_rsh_signed): New function.
6812 (ppc64_emit_rsh_unsigned): New function.
6813 (ppc64_emit_ext): New function.
6814 (ppc64_emit_zero_ext): New function.
6815 (ppc64_emit_log_not): New function.
6816 (ppc64_emit_bit_and): New function.
6817 (ppc64_emit_bit_or): New function.
6818 (ppc64_emit_bit_xor): New function.
6819 (ppc64_emit_bit_not): New function.
6820 (ppc64_emit_equal): New function.
6821 (ppc64_emit_less_signed): New function.
6822 (ppc64_emit_less_unsigned): New function.
6823 (ppc64_emit_ref): New function.
6824 (ppc64_emit_const): New function.
6825 (ppc64v1_emit_reg): New function.
6826 (ppc64v2_emit_reg): New function.
6827 (ppc64_emit_pop): New function.
6828 (ppc64_emit_stack_flush): New function.
6829 (ppc64_emit_swap): New function.
6830 (ppc64v1_emit_call): New function.
6831 (ppc64v2_emit_call): New function.
6832 (ppc64v1_emit_int_call_1): New function.
6833 (ppc64v2_emit_int_call_1): New function.
6834 (ppc64v1_emit_void_call_2): New function.
6835 (ppc64v2_emit_void_call_2): New function.
6836 (ppc64_emit_if_goto): New function.
6837 (ppc64_emit_eq_goto): New function.
6838 (ppc64_emit_ne_goto): New function.
6839 (ppc64_emit_lt_goto): New function.
6840 (ppc64_emit_le_goto): New function.
6841 (ppc64_emit_gt_goto): New function.
6842 (ppc64_emit_ge_goto): New function.
6843 (ppc64v1_emit_ops_impl): New static variable.
6844 (ppc64v2_emit_ops_impl): New static variable.
6845 (ppc_emit_ops): New function.
6846 (linux_low_target): Wire in ppc_emit_ops.
6848 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
6849 Marcin Kościelnicki <koriakin@0x04.net>
6852 * Makefile.in: Add powerpc-*-ipa.o
6853 * configure.srv: Add ipa_obj for powerpc*-linux.
6854 * linux-ppc-ipa.c: New file.
6855 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
6857 (PPC_FIELD): New macro.
6858 (PPC_SEXT): New macro.
6859 (PPC_OP6): New macro.
6860 (PPC_BO): New macro.
6861 (PPC_LI): New macro.
6862 (PPC_BD): New macro.
6863 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
6864 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
6865 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
6866 (ppc_get_thread_area): New function.
6867 (is_elfv2_inferior): New function.
6868 (gen_ds_form): New function.
6869 (GEN_STD): New macro.
6870 (GEN_STDU): New macro.
6871 (GEN_LD): New macro.
6872 (GEN_LDU): New macro.
6873 (gen_d_form): New function.
6874 (GEN_ADDI): New macro.
6875 (GEN_ADDIS): New macro.
6876 (GEN_LI): New macro.
6877 (GEN_LIS): New macro.
6878 (GEN_ORI): New macro.
6879 (GEN_ORIS): New macro.
6880 (GEN_LWZ): New macro.
6881 (GEN_STW): New macro.
6882 (GEN_STWU): New macro.
6883 (gen_xfx_form): New function.
6884 (GEN_MFSPR): New macro.
6885 (GEN_MTSPR): New macro.
6886 (GEN_MFCR): New macro.
6887 (GEN_MTCR): New macro.
6888 (GEN_SYNC): New macro.
6889 (GEN_LWSYNC): New macro.
6890 (gen_x_form): New function.
6891 (GEN_OR): New macro.
6892 (GEN_MR): New macro.
6893 (GEN_LWARX): New macro.
6894 (GEN_STWCX): New macro.
6895 (GEN_CMPW): New macro.
6896 (gen_md_form): New function.
6897 (GEN_RLDICL): New macro.
6898 (GEN_RLDICR): New macro.
6899 (gen_i_form): New function.
6901 (GEN_BL): New macro.
6902 (gen_b_form): New function.
6903 (GEN_BNE): New macro.
6904 (GEN_LOAD): New macro.
6905 (GEN_STORE): New macro.
6906 (gen_limm): New function.
6907 (gen_atomic_xchg): New function.
6908 (gen_call): New function.
6909 (ppc_relocate_instruction): New function.
6910 (ppc_install_fast_tracepoint_jump_pad): New function.
6911 (ppc_get_min_fast_tracepoint_insn_len): New function.
6912 (ppc_get_ipa_tdesc_idx): New function.
6913 (the_low_target): Wire in the new functions.
6914 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
6916 * linux-ppc-tdesc.h: New file.
6918 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
6920 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
6921 (alloc_jump_pad_buffer): New function.
6922 * linux-amd64-ipa.c: Add <sys/mman.h> include.
6923 (alloc_jump_pad_buffer): New function.
6924 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
6925 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
6926 (alloc_jump_pad_buffer): New function.
6927 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
6928 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
6929 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
6930 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
6932 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
6934 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
6935 * linux-amd64-ipa.c: Likewise.
6936 * linux-i386-ipa.c: Likewise.
6937 * linux-s390-ipa.c: Likewise.
6938 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
6939 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
6940 set_trace_state_variable_value_ptr.
6941 (struct ipa_sym_addresses): Likewise.
6942 (symbol_list): Likewise.
6943 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
6944 accessing gdb_collect directly.
6945 (gdb_collect_ptr_type): New typedef.
6946 (get_raw_reg_ptr_type): New typedef.
6947 (get_trace_state_variable_value_ptr_type): New typedef.
6948 (set_trace_state_variable_value_ptr_type): New typedef.
6949 (gdb_collect_ptr): New global.
6950 (get_raw_reg_ptr): New global.
6951 (get_trace_state_variable_value_ptr): New global.
6952 (set_trace_state_variable_value_ptr): New global.
6953 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
6954 accessing get_raw_reg directly.
6955 (get_get_tsv_func_addr): Likewise for
6956 get_trace_state_variable_value_ptr.
6957 (get_set_tsv_func_addr): Likewise for
6958 set_trace_state_variable_value_ptr.
6959 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
6961 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
6963 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
6965 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
6967 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
6969 (relocate_instruction): Remove own_buf.
6970 * server.c (own_buf): Make global.
6971 (handle_v_requests): Make global.
6972 * server.h (own_buf): New declaration.
6973 (handle_v_requests): New prototype.
6975 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
6978 * linux-s390-low.c (add_insns): New function.
6979 (s390_emit_prologue): New function.
6980 (s390_emit_epilogue): New function.
6981 (s390_emit_add): New function.
6982 (s390_emit_sub): New function.
6983 (s390_emit_mul): New function.
6984 (s390_emit_lsh): New function.
6985 (s390_emit_rsh_signed): New function.
6986 (s390_emit_rsh_unsigned): New function.
6987 (s390_emit_ext): New function.
6988 (s390_emit_log_not): New function.
6989 (s390_emit_bit_and): New function.
6990 (s390_emit_bit_or): New function.
6991 (s390_emit_bit_xor): New function.
6992 (s390_emit_bit_not): New function.
6993 (s390_emit_equal): New function.
6994 (s390_emit_less_signed): New function.
6995 (s390_emit_less_unsigned): New function.
6996 (s390_emit_ref): New function.
6997 (s390_emit_if_goto): New function.
6998 (s390_emit_goto): New function.
6999 (s390_write_goto_address): New function.
7000 (s390_emit_litpool): New function.
7001 (s390_emit_const): New function.
7002 (s390_emit_call): New function.
7003 (s390_emit_reg): New function.
7004 (s390_emit_pop): New function.
7005 (s390_emit_stack_flush): New function.
7006 (s390_emit_zero_ext): New function.
7007 (s390_emit_swap): New function.
7008 (s390_emit_stack_adjust): New function.
7009 (s390_emit_set_r2): New function.
7010 (s390_emit_int_call_1): New function.
7011 (s390_emit_void_call_2): New function.
7012 (s390_emit_eq_goto): New function.
7013 (s390_emit_ne_goto): New function.
7014 (s390_emit_lt_goto): New function.
7015 (s390_emit_le_goto): New function.
7016 (s390_emit_gt_goto): New function.
7017 (s390_emit_ge_goto): New function.
7018 (s390x_emit_prologue): New function.
7019 (s390x_emit_epilogue): New function.
7020 (s390x_emit_add): New function.
7021 (s390x_emit_sub): New function.
7022 (s390x_emit_mul): New function.
7023 (s390x_emit_lsh): New function.
7024 (s390x_emit_rsh_signed): New function.
7025 (s390x_emit_rsh_unsigned): New function.
7026 (s390x_emit_ext): New function.
7027 (s390x_emit_log_not): New function.
7028 (s390x_emit_bit_and): New function.
7029 (s390x_emit_bit_or): New function.
7030 (s390x_emit_bit_xor): New function.
7031 (s390x_emit_bit_not): New function.
7032 (s390x_emit_equal): New function.
7033 (s390x_emit_less_signed): New function.
7034 (s390x_emit_less_unsigned): New function.
7035 (s390x_emit_ref): New function.
7036 (s390x_emit_if_goto): New function.
7037 (s390x_emit_const): New function.
7038 (s390x_emit_call): New function.
7039 (s390x_emit_reg): New function.
7040 (s390x_emit_pop): New function.
7041 (s390x_emit_stack_flush): New function.
7042 (s390x_emit_zero_ext): New function.
7043 (s390x_emit_swap): New function.
7044 (s390x_emit_stack_adjust): New function.
7045 (s390x_emit_int_call_1): New function.
7046 (s390x_emit_void_call_2): New function.
7047 (s390x_emit_eq_goto): New function.
7048 (s390x_emit_ne_goto): New function.
7049 (s390x_emit_lt_goto): New function.
7050 (s390x_emit_le_goto): New function.
7051 (s390x_emit_gt_goto): New function.
7052 (s390x_emit_ge_goto): New function.
7053 (s390_emit_ops): New function.
7054 (struct linux_target_ops): Fill in emit_ops hook.
7056 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
7059 * Makefile.in: Add s390 IPA files.
7060 * configure.srv: Build IPA for s390.
7061 * linux-s390-ipa.c: New file.
7062 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
7063 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
7064 (tdesc_s390_linux32): Likewise.
7065 (init_registers_s390_linux32v1): Likewise.
7066 (tdesc_s390_linux32v1): Likewise.
7067 (init_registers_s390_linux32v2): Likewise.
7068 (tdesc_s390_linux32v2): Likewise.
7069 (init_registers_s390_linux64): Likewise.
7070 (tdesc_s390_linux64): Likewise.
7071 (init_registers_s390_linux64v1): Likewise.
7072 (tdesc_s390_linux64v1): Likewise.
7073 (init_registers_s390_linux64v2): Likewise.
7074 (tdesc_s390_linux64v2): Likewise.
7075 (init_registers_s390_te_linux64): Likewise.
7076 (tdesc_s390_te_linux64): Likewise.
7077 (init_registers_s390_vx_linux64): Likewise.
7078 (tdesc_s390_vx_linux64): Likewise.
7079 (init_registers_s390_tevx_linux64): Likewise.
7080 (tdesc_s390_tevx_linux64): Likewise.
7081 (init_registers_s390x_linux64): Likewise.
7082 (tdesc_s390x_linux64): Likewise.
7083 (init_registers_s390x_linux64v1): Likewise.
7084 (tdesc_s390x_linux64v1): Likewise.
7085 (init_registers_s390x_linux64v2): Likewise.
7086 (tdesc_s390x_linux64v2): Likewise.
7087 (init_registers_s390x_te_linux64): Likewise.
7088 (tdesc_s390x_te_linux64): Likewise.
7089 (init_registers_s390x_vx_linux64): Likewise.
7090 (tdesc_s390x_vx_linux64): Likewise.
7091 (init_registers_s390x_tevx_linux64): Likewise.
7092 (tdesc_s390x_tevx_linux64): Likewise.
7093 (have_hwcap_s390_vx): New static variable.
7094 (s390_arch_setup): Fill have_hwcap_s390_vx.
7095 (s390_get_thread_area): New function.
7096 (s390_ft_entry_gpr_esa): New const.
7097 (s390_ft_entry_gpr_zarch): New const.
7098 (s390_ft_entry_misc): New const.
7099 (s390_ft_entry_fr): New const.
7100 (s390_ft_entry_vr): New const.
7101 (s390_ft_main_31): New const.
7102 (s390_ft_main_64): New const.
7103 (s390_ft_exit_fr): New const.
7104 (s390_ft_exit_vr): New const.
7105 (s390_ft_exit_misc): New const.
7106 (s390_ft_exit_gpr_esa): New const.
7107 (s390_ft_exit_gpr_zarch): New const.
7108 (append_insns): New function.
7109 (s390_relocate_instruction): New function.
7110 (s390_install_fast_tracepoint_jump_pad): New function.
7111 (s390_get_min_fast_tracepoint_insn_len): New function.
7112 (s390_get_ipa_tdesc_idx): New function.
7113 (struct linux_target_ops): Wire in the above functions.
7114 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
7115 * linux-s390-tdesc.h: New file.
7117 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
7119 * linux-s390-low.c (s390_supports_tracepoints): New function.
7120 (struct linux_target_ops): Fill supports_tracepoints hook.
7122 2016-03-18 Yao Qi <yao.qi@linaro.org>
7124 * linux-low.c (lwp_signal_can_be_delivered): New function.
7125 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
7127 2016-03-18 Yao Qi <yao.qi@linaro.org>
7129 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
7130 0 if signal is enqueued. Remove 'signal' from one debugging
7131 message. Move one debugging message to some lines below.
7132 Remove code setting 'signal' to 0.
7134 2016-03-18 Yao Qi <yao.qi@linaro.org>
7136 * linux-low.c (linux_low_filter_event): Remove redundant
7137 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
7139 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
7141 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
7142 (struct linux_target_ops): Wire in the above.
7144 2016-03-03 Yao Qi <yao.qi@linaro.org>
7146 * linux-low.c: Update comments to start_step_over.
7148 2016-03-03 Yao Qi <yao.qi@linaro.org>
7151 * linux-low.c (handle_extended_wait): Set child suspended
7152 if event_lwp->bp_reinsert isn't zero.
7154 2016-03-02 Yao Qi <yao.qi@linaro.org>
7156 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
7157 enqueue_pending_signal.
7159 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
7161 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
7164 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
7166 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
7167 (s390_regmap_3264) [!__s390x__]: New global.
7168 (s390_collect_ptrace_register): Skip map entries containing -1.
7169 (s390_supply_ptrace_register): Ditto.
7170 (s390_fill_gprs_high): New function.
7171 (s390_store_gprs_high): New function.
7172 (s390_regsets): Add NT_S390_HIGH_GPRS.
7173 (s390_get_hwcap): Enable on 31-bit.
7174 (have_hwcap_s390_high_gprs): Enable on 31-bit.
7175 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
7176 Detect NT_S390_HIGH_GPRS.
7177 (s390_usrregs_info_3264): Enable on 31-bit.
7178 (s390_regs_info): Enable regs_info_3264 on 31-bit.
7179 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
7181 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
7184 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
7185 * configure.srv: Ditto.
7186 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
7187 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
7188 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
7189 (init_registers_amd64_linux): Remove prototype.
7190 (tdesc_amd64_linux): Remove declaration.
7191 (get_ipa_tdesc): New function.
7192 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
7193 initialize remaining tdescs.
7194 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
7195 (init_registers_i386_linux): Remove prototype.
7196 (tdesc_i386_linux): Remove declaration.
7197 (get_ipa_tdesc): New function.
7198 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
7199 initialize remaining tdescs.
7200 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
7201 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
7202 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
7203 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
7204 (x86_get_ipa_tdesc_idx): New function.
7205 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
7206 * linux-x86-tdesc.h: New file.
7207 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
7208 (target_get_ipa_tdesc_idx): New macro.
7209 * tracepoint.c (ipa_tdesc_idx): New macro.
7210 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
7211 (symbol_list): Add ipa_tdesc_idx.
7212 (cmd_qtstart): Write ipa_tdesc_idx in the target.
7213 (ipa_tdesc): Remove.
7214 (ipa_tdesc_idx): New variable.
7215 (get_context_regcache): Use get_ipa_tdesc.
7216 (gdb_collect): Ditto.
7218 * tracepoint.h (get_ipa_tdesc): New prototype.
7219 (ipa_tdesc): Remove.
7221 2016-02-24 Pedro Alves <palves@redhat.com>
7223 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
7224 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
7225 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
7226 Factor out common code between the USE_SIGTRAP_SIGINFO and
7227 !USE_SIGTRAP_SIGINFO blocks.
7228 (linux_low_filter_event): Call save_stop_reason instead of
7229 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
7231 (linux_wait_1): Update comments.
7233 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
7235 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
7236 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
7237 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
7238 ppc_insert_point, ppc_remove_point.
7240 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
7242 * linux-s390-low.c (s390_supports_z_point_type): New function.
7243 (struct linux_target_ops): Wire s390_supports_z_point_type in.
7245 2016-02-16 Yao Qi <yao.qi@linaro.org>
7247 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
7248 PC. Get pc from regcache_read_pc.
7250 2016-02-12 Yao Qi <yao.qi@linaro.org>
7252 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
7253 or linux_get_pc_32bit.
7254 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
7256 2016-02-12 Yao Qi <yao.qi@linaro.org>
7258 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
7259 arm_linux_get_next_pcs_fixup.
7261 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
7263 * tracepoint.c (x_tracepoint_action_download): Change
7264 write_inferior_data_ptr to write_inferior_data_pointer.
7265 (cmd_qtstart): Likewise.
7266 (write_inferior_data_ptr): Remove.
7267 (download_agent_expr): Change write_inferior_data_ptr to
7268 write_inferior_data_pointer.
7269 (download_tracepoint_1): Likewise.
7270 (download_tracepoint): Likewise.
7271 (download_trace_state_variables): Likewise.
7273 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
7274 Marcin Kościelnicki <koriakin@0x04.net>
7276 * tracepoint.c (struct tracepoint_action_ops): Remove.
7277 (struct tracepoint_action): Remove ops.
7278 (m_tracepoint_action_download, r_tracepoint_action_download)
7279 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
7280 size and offset accordingly.
7281 (m_tracepoint_action_ops, r_tracepoint_action_ops)
7282 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
7283 (tracepoint_action_send, tracepoint_action_download): New functions.
7284 Helpers for trace action handlers.
7285 (add_tracepoint_action): Remove setup actions ops.
7286 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
7288 2016-02-10 Yao Qi <yao.qi@linaro.org>
7290 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
7292 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
7294 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
7296 * configure: Regenerate.
7298 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
7300 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
7301 void * to gdb_byte *.
7302 * linux-low.c (siginfo_fixup): Likewise.
7303 (linux_xfer_siginfo): Likewise.
7304 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
7306 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
7308 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
7310 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
7312 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
7314 * linux-x86-low.c [__x86_64__]: Include
7315 "nat/amd64-linux-siginfo.h".
7316 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
7317 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
7318 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
7319 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
7320 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
7321 (cpt_si_fd, si_timerid, si_overrun): Move from
7322 nat/amd64-linux-siginfo.c.
7323 * Makefile.in (amd64-linux-siginfo.o:): New rule.
7325 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
7327 * server.c (skip_to_semicolon): Remove.
7328 (process_point_options): Use strchrnul instead of
7331 2016-01-26 Yao Qi <yao.qi@linaro.org>
7333 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
7334 * linux-low.c (install_software_single_step_breakpoints): Don't
7335 call regcache_read_pc.
7336 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
7339 2016-01-26 Yao Qi <yao.qi@linaro.org>
7341 * linux-low.c (install_software_single_step_breakpoints): Call
7342 regcache_read_pc instead of get_pc.
7344 2016-01-26 Yao Qi <yao.qi@linaro.org>
7346 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
7347 (unblock_async_io): Rename to ...
7348 (block_unblock_async_io): ... it. New function.
7349 (enable_async_io): Don't install SIGIO handler. Unblock it
7351 (disable_async_io): Don't ignore SIGIO. Block it instead.
7352 (initialize_async_io): Install SIGIO handler. Don't call
7355 2016-01-26 Yao Qi <yao.qi@linaro.org>
7357 * remote-utils.c (getpkt): If the buffer isn't empty, and the
7358 first character is '\003', call *the_target->request_interrupt.
7360 2016-01-25 Yao Qi <yao.qi@linaro.org>
7362 * remote-utils.c (new_thread_notify): Remove.
7363 (dead_thread_notify): Likewise.
7364 * remote-utils.h (new_thread_notify): Remove declaration.
7365 (dead_thread_notify): Likewise.
7367 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
7369 * gdb.trace/pending.exp: Fix expected message on continue.
7371 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
7373 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
7374 it works properly on big-endian machines where sizeof (CORE_ADDR)
7377 2016-01-21 Pedro Alves <palves@redhat.com>
7379 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
7380 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
7381 * configure: Regenerate.
7383 2016-01-21 Yao Qi <yao.qi@linaro.org>
7385 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
7386 is_thumb and set it according to CPSR saved on the stack.
7387 (get_next_pcs_syscall_next_pc): Pass is_thumb to
7388 arm_sigreturn_next_pc.
7390 2016-01-18 Yao Qi <yao.qi@linaro.org>
7392 * linux-low.c (linux_set_pc_64bit): New function.
7393 (linux_get_pc_64bit): New function.
7394 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
7396 * linux-sparc-low.c (debug_threads): Remove declaration.
7397 (sparc_get_pc): Remove.
7398 (the_low_target): Use linux_get_pc_64bit instead of
7400 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
7401 (the_low_target): Use linux_get_pc_64bit and
7404 2016-01-18 Yao Qi <yao.qi@linaro.org>
7406 * linux-arm-low.c (debug_threads): Remove declaration.
7407 (arm_get_pc, arm_set_pc): Remove.
7408 (the_low_target): Use linux_get_pc_32bit and
7410 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
7411 (the_low_target): Use linux_get_pc_32bit and
7413 * linux-cris-low.c (debug_threads): Remove declaration.
7414 (cris_get_pc, cris_set_pc,): Remove.
7415 (the_low_target): Use linux_get_pc_32bit and
7417 * linux-crisv32-low.c (debug_threads): Remove declaration.
7418 (cris_get_pc, cris_set_pc): Remove.
7419 (the_low_target): Use linux_get_pc_32bit and
7421 * linux-low.c: Include inttypes.h.
7422 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
7423 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
7424 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
7425 (the_low_target): Use linux_get_pc_32bit and
7427 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
7428 (the_low_target): Use linux_get_pc_32bit and
7430 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
7431 (the_low_target): Use linux_get_pc_32bit and
7433 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
7434 (the_low_target): Use linux_get_pc_32bit and
7436 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
7437 (the_low_target): Use linux_get_pc_32bit and
7440 2016-01-18 Gary Benson <gbenson@redhat.com>
7442 * configure.ac (AC_FUNC_FORK): New check.
7443 * config.in: Regenerate.
7444 * configure: Likewise.
7446 2016-01-14 Yao Qi <yao.qi@linaro.org>
7448 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
7449 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
7450 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
7451 arm_get_next_pcs_ctor.
7453 2016-01-12 Josh Stone <jistone@redhat.com>
7454 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7456 * inferiors.h: Include "gdb_vecs.h".
7457 (struct process_info): Add syscalls_to_catch.
7458 * inferiors.c (remove_process): Free syscalls_to_catch.
7459 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
7460 syscall_return stops.
7461 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
7462 * server.c (handle_general_set): Handle QCatchSyscalls.
7463 (handle_query): Report support for QCatchSyscalls.
7464 * target.h (struct target_ops): Add supports_catch_syscall.
7465 (target_supports_catch_syscall): New macro.
7466 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
7467 (struct lwp_info): Add syscall_state.
7468 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
7469 Maintain syscall_state and syscalls_to_catch across exec.
7470 (get_syscall_trapinfo): New function, proxy to the_low_target.
7471 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
7472 (linux_low_filter_event): Toggle syscall_state entry/return for
7473 syscall traps, and set it ignored for all others.
7474 (gdb_catching_syscalls_p): New function.
7475 (gdb_catch_this_syscall_p): New function.
7476 (linux_wait_1): Handle SYSCALL_SIGTRAP.
7477 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
7478 (linux_supports_catch_syscall): New function.
7479 (linux_target_ops): Install it.
7480 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
7481 (the_low_target): Install it.
7483 2016-01-12 Mike Frysinger <vapier@gentoo.org>
7485 * acinclude.m4: Include new ../warning.m4 file.
7486 * configure: Regenerated.
7487 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
7489 2016-01-12 Mike Frysinger <vapier@gentoo.org>
7491 * ax.c (is_goto_target): Mark static.
7492 * linux-low.c (register_addr): Likewise.
7493 (linux_fetch_registers, linux_store_registers): Likewise.
7494 * mem-break.c (any_persistent_commands): Fix old prototype.
7495 (add_commands_to_breakpoint): Mark static.
7496 * regcache.c (find_register_by_name): Delete unused func.
7497 * remote-utils.c (hex_or_minus_one): Mark static.
7498 * server.c (monitor_show_help): Mark static.
7499 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
7500 handle_v_requests): Likewise.
7502 2016-01-12 Pedro Alves <palves@redhat.com>
7504 Remove use of the registered trademark symbol throughout.
7506 2016-01-08 Yao Qi <yao.qi@linaro.org>
7508 * remote-utils.c (getpkt): If c is '\003', call target hook
7511 2016-01-06 Yao Qi <yao.qi@linaro.org>
7513 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
7514 linux-aarch32-low.c.
7515 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
7516 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
7517 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
7518 (thumb2_breakpoint): Declare.
7519 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
7520 linux-aarch32-low.h.
7521 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
7522 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
7523 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
7525 2016-01-01 Joel Brobecker <brobecker@adacore.com>
7527 * gdbreplay.c (gdbreplay_version): Change copyright year in
7529 * server.c (gdbserver_version): Likewise.
7531 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
7533 * server.c (crc32_table): Delete.
7534 (crc32): Use libiberty's xcrc32 function.
7536 2015-12-22 Joel Brobecker <brobecker@adacore.com>
7538 * lynx-low.c (lynx_delete_thread_callback): New function.
7539 (lynx_mourn): Properly delete our process and all of its
7540 threads. Remove call to clear_inferiors.
7542 2015-12-22 Joel Brobecker <brobecker@adacore.com>
7544 * target.c (thread_search_callback): Add check that
7545 the thread_stopped target callback is not NULL before
7548 2015-12-21 Yao Qi <yao.qi@linaro.org>
7550 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
7553 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
7555 * server.c (handle_query): Call target_supports_software_single_step.
7557 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
7559 * linux-low.c (single_step): New function.
7560 (linux_resume_one_lwp_throw): Call single_step.
7561 (start_step_over): Likewise.
7563 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
7565 * Makefile.in (SFILES): Append arch/arm-linux.c,
7566 arch/arm-get-next-pcs.c.
7567 (arm-linux.o): New rule.
7568 (arm-get-next-pcs.o): New rule.
7569 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
7571 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
7572 to linux-aarch32-low.c.
7573 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
7574 (arm_breakpoint_len, thumb_breakpoint): Likewise.
7575 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
7576 (thumb2_breakpoint_len): Likewise.
7577 (arm_is_thumb_mode): Make non-static.
7578 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
7579 from linux-aarch32-low.c.
7580 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
7581 (arm_breakpoint_len, thumb_breakpoint): Likewise.
7582 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
7583 (thumb2_breakpoint_len): Likewise.
7584 (arm_is_thumb_mode): New declaration.
7585 * linux-arm-low.c: Include arch/arm-linux.h
7586 aarch/arm-get-next-pcs.h, sys/syscall.h.
7587 (get_next_pcs_ops): New struct.
7588 (get_next_pcs_addr_bits_remove): New function.
7589 (get_next_pcs_is_thumb): New function.
7590 (get_next_pcs_read_memory_unsigned_integer): Likewise.
7591 (arm_sigreturn_next_pc): Likewise.
7592 (get_next_pcs_syscall_next_pc): Likewise.
7593 (arm_gdbserver_get_next_pcs): Likewise.
7594 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
7596 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
7597 * server.h: Include gdb_vecs.h.
7599 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
7601 * Makefile.in (SFILES): Append common/common-regcache.c.
7602 (OBS): Append common-regcache.o.
7603 (common-regcache.o): New rule.
7604 * regcache.c (init_register_cache): Initialize cache to
7606 (regcache_raw_read_unsigned): New function.
7607 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
7608 register_status enum.
7610 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
7612 * linux-aarch64-low.c (the_low_targets): Rename
7613 breakpoint_reinsert_addr to get_next_pcs.
7614 * linux-arm-low.c (the_low_targets): Likewise.
7615 * linux-bfin-low.c (the_low_targets): Likewise.
7616 * linux-cris-low.c (the_low_targets): Likewise.
7617 * linux-crisv32-low.c (the_low_targets): Likewise.
7618 * linux-low.c (can_software_single_step): Likewise.
7619 (install_software_single_step_breakpoints): New function.
7620 (start_step_over): Use install_software_single_step_breakpoints.
7621 * linux-low.h: New CORE_ADDR vector.
7622 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
7624 * linux-mips-low.c (the_low_targets): Likewise.
7625 * linux-nios2-low.c (the_low_targets): Likewise.
7626 * linux-sparc-low.c (the_low_targets): Likewise.
7628 2015-12-17 Pedro Alves <palves@redhat.com>
7630 * linux-low.c (linux_kill_one_lwp): Remove references to
7632 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
7634 (linux_init_signals): Delete.
7635 (initialize_low): Adjust.
7636 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
7638 2015-12-16 Pedro Alves <palves@redhat.com>
7640 * configure.ac (compiler warning flags): When testing a
7641 -Wno-foo option, check whether -Wfoo works instead.
7642 * configure: Regenerate.
7644 2015-12-11 Don Breazeal <donb@codesourcery.com>
7646 * server.c (process_serial_event): Don't exit from gdbserver
7647 in remote mode if there are still active inferiors.
7649 2015-12-11 Yao Qi <yao.qi@linaro.org>
7651 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
7652 arm_breakpoint_at if the process is 32-bit.
7654 2015-12-11 Yao Qi <yao.qi@linaro.org>
7656 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
7659 2015-12-07 Yao Qi <yao.qi@linaro.org>
7661 * configure.srv: Append arm.o to srv_tgtobj for
7662 aarch64*-*-linux* target.
7663 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
7664 from linux-arm-low.c.
7665 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
7666 (arm_breakpoint_len, thumb_breakpoint): Likewise.
7667 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
7668 (thumb2_breakpoint_len): Likewise.
7669 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
7670 (arm_breakpoint_kinds): Likewise.
7671 (arm_breakpoint_kind_from_pc): Likewise.
7672 (arm_sw_breakpoint_from_kind): Likewise.
7673 (arm_breakpoint_kind_from_current_state): Likewise.
7674 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
7675 (arm_sw_breakpoint_from_kind): Declare.
7676 (arm_breakpoint_kind_from_current_state): Declare.
7677 (arm_breakpoint_at): Declare.
7678 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
7679 arm_sw_breakpoint_from_kind if process is 32-bit.
7680 (aarch64_breakpoint_kind_from_pc): New function.
7681 (aarch64_breakpoint_kind_from_current_state): New function.
7682 (the_low_target): Initialize fields breakpoint_kind_from_pc
7683 and breakpoint_kind_from_current_state.
7684 * linux-arm-low.c (arm_breakpoint_kinds): Move to
7685 linux-aarch32-low.c.
7686 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
7687 (arm_breakpoint, arm_breakpoint_len): Likewise.
7688 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
7689 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
7690 (arm_is_thumb_mode): Likewise.
7691 (arm_breakpoint_at): Likewise.
7692 (arm_breakpoint_kind_from_pc): Likewise.
7693 (arm_sw_breakpoint_from_kind): Likewise.
7694 (arm_breakpoint_kind_from_current_state): Likewise.
7697 2015-08-04 Yao Qi <yao.qi@linaro.org>
7699 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
7700 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
7701 * server.c (extended_protocol): Remove "static".
7702 * server.h (extended_protocol): Declare it.
7704 2015-12-04 Josh Stone <jistone@redhat.com>
7706 * target.h (struct target_ops) <arch_setup>: Rename to ...
7707 (struct target_ops) <post_create_inferior>: ... this.
7708 (target_arch_setup): Rename to ...
7709 (target_post_create_inferior): ... this, calling post_create_inferior.
7710 * server.c (start_inferior): Update target_arch_setup calls to
7711 target_post_create_inferior.
7712 * linux-low.c (linux_low_ptrace_options): Forward declare.
7713 (linux_arch_setup): Update its comment for general use.
7714 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
7715 (struct linux_target_ops): Use linux_post_create_inferior.
7716 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
7717 to post_create_inferior.
7718 * nto-low.c (struct nto_target_ops): Likewise.
7719 * spu-low.c (struct spu_target_ops): Likewise.
7720 * win32-low.c (struct win32_target_ops): Likewise.
7722 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
7724 * linux-arm-low.c: Remove duplicate arch/arm.h include.
7726 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
7728 * linux-arm-low.c (arm_reinsert_addr): Remove function.
7729 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
7730 * linux-cris-low.c (cris_reinsert_addr> Remove function.
7731 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
7732 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
7733 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
7734 * linux-mips-low.c (mips_reinsert_addr): Remove function.
7735 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
7736 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
7737 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
7738 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
7739 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
7741 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
7743 * linux-low.c (linux_look_up_symbols): Don't call
7744 linux_supports_traceclone.
7745 * linux-low.h (thread_db_init): Remove use_events argument.
7746 * thread-db.c (thread_db_use_event): Remove global variable.
7747 (struct thread_db) <td_thr_event_enable_p>: Remove field.
7748 (struct thread_db) <td_create_bp>: Remove field.
7749 (thread_db_create_event): Remove function.
7750 (thread_db_enable_reporting): Likewise.
7751 (find_one_thread): Don't check for thread_db_use_events.
7752 (attach_thread): Likewise.
7753 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
7754 (try_thread_db_load_1): Don't check for thread_db_use_events.
7755 (thread_db_init): Remove use_events argument and thread events
7757 (remove_thread_event_breakpoints): Remove function.
7758 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
7760 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
7762 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
7764 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7765 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
7766 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7767 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
7768 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
7770 * linux-crisv32-low.c (cris_supports_hardware_single_step):
7772 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7773 * linux-low.c (can_hardware_single_step): Use
7774 supports_hardware_single_step.
7775 (can_software_single_step): New function.
7776 (start_step_over): Call can_software_single_step.
7777 (linux_supports_hardware_single_step): New function.
7778 (struct target_ops) <supports_software_single_step>: Initialize.
7779 * linux-low.h (struct linux_target_ops)
7780 <supports_hardware_single_step>: Initialize.
7781 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
7782 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7783 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
7784 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
7785 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
7786 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7787 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
7788 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7789 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
7790 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
7792 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
7793 (struct linux_target_ops) <tile_supports_hardware_single_step>:
7795 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
7796 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7797 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
7799 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7800 * target.h (struct target_ops): <supports_software_single_step>:
7802 (target_supports_software_single_step): New macro.
7804 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
7806 * linux-low.c (linux_wait_1): Fix pc advance condition.
7807 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
7808 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
7810 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
7812 * linux-arm-low.c (arm_is_thumb_mode): New function.
7813 (arm_breakpoint_at): Use arm_is_thumb_mode.
7814 (arm_breakpoint_kind_from_current_state): New function.
7815 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
7817 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
7818 (linux_breakpoint_kind_from_current_state): New function.
7819 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
7820 * linux-low.h (struct linux_target_ops)
7821 <breakpoint_kind_from_current_state>: New field.
7822 * target.h (struct target_ops): Likewise.
7823 (target_breakpoint_kind_from_current_state): New macro.
7825 2015-11-30 Pedro Alves <palves@redhat.com>
7827 * linux-low.c (linux_resume): Wake up the event loop before
7830 2015-11-30 Pedro Alves <palves@redhat.com>
7832 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
7834 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
7836 * target.c (struct thread_search): New structure.
7837 (thread_search_callback): New function.
7838 (prev_general_thread): New global.
7839 (prepare_to_access_memory, done_accessing_memory): New functions.
7840 * target.h (prepare_to_access_memory, done_accessing_memory):
7841 Replace macros with function declarations.
7843 2015-11-30 Pedro Alves <palves@redhat.com>
7846 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
7847 report TARGET_WAITKIND_NO_RESUMED.
7848 * remote-utils.c (prepare_resume_reply): Handle
7849 TARGET_WAITKIND_NO_RESUMED.
7850 * server.c (report_no_resumed): New global.
7851 (handle_query) <qSupported>: Handle "no-resumed+". Report
7852 "no-resumed+" support.
7853 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
7854 return error if the client doesn't support no-resumed events.
7855 (push_stop_notification): New function.
7856 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
7857 events if the client supports them.
7859 2015-11-30 Pedro Alves <palves@redhat.com>
7861 * linux-low.c (thread_still_has_status_pending_p): Don't check
7863 (lwp_resumed): New function.
7864 (status_pending_p_callback): Return early if the LWP is not
7865 supposed to be resumed.
7867 2015-11-30 Pedro Alves <palves@redhat.com>
7869 * linux-low.c (handle_extended_wait): Assert that the LWP's
7870 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
7871 thread create events, leave the new child's status pending.
7872 (linux_low_filter_event): If GDB wants to hear about thread exit
7873 events, leave the LWP marked dead and don't delete it.
7874 (linux_wait_for_event_filtered): Don't check for thread exit.
7875 (filter_exit_event): New function.
7876 (linux_wait_1): Use it, when returning an exit event.
7877 (linux_resume_one_lwp_throw): Assert that the LWP's
7878 waitstatus is TARGET_WAITKIND_IGNORE.
7879 * remote-utils.c (prepare_resume_reply): Handle
7880 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
7881 * server.c (report_thread_events): New global.
7882 (handle_general_set): Handle QThreadEvents.
7883 (handle_query) <qSupported>: Handle and report QThreadEvents+;
7884 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
7885 TARGET_WAITKIND_THREAD_EXITED.
7886 * server.h (report_thread_events): Declare.
7888 2015-11-30 Pedro Alves <palves@redhat.com>
7890 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
7891 the thread's last_resume_kind was resume_stop.
7893 2015-11-30 Pedro Alves <palves@redhat.com>
7895 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
7898 2015-11-30 Pedro Alves <palves@redhat.com>
7900 * server.c (handle_v_requests): Handle vCtrlC.
7902 2015-11-30 Pedro Alves <palves@redhat.com>
7904 * gdbthread.h (find_any_thread_of_pid): Declare.
7905 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
7907 * server.c (handle_query): If current_thread is NULL, look for
7908 another thread of the selected process.
7910 2015-11-26 Daniel Colascione <dancol@dancol.org>
7911 Simon Marchi <simon.marchi@ericsson.com>
7913 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
7914 * server.c (handle_qxfer_threads_worker): Refactor to include thread
7916 * target.h (struct target_ops) <thread_name>: New field.
7917 (target_thread_name): New macro.
7919 2015-11-23 Joel Brobecker <brobecker@adacore.com>
7921 * regcache.h (regcache_invalidate_pid): Add declaration.
7922 * regcache.c (regcache_invalidate_pid): New function, extracted
7923 from regcache_invalidate.
7924 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
7925 Add trivial documentation comment.
7926 * lynx-low.c: Use regcache_invalidate_pid instead of
7927 regcache_invalidate.
7929 2015-11-23 Joel Brobecker <brobecker@adacore.com>
7931 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
7932 and Elf64_auxv_t if the target is Android.
7934 2015-11-22 Doug Evans <xdje42@gmail.com>
7936 * target.h: #include <sys/types.h>.
7938 2015-11-19 Pedro Alves <palves@redhat.com>
7940 * linux-low.c (linux_process_qsupported): Change prototype.
7942 * linux-low.h (struct linux_target_ops) <process_qsupported>:
7944 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
7945 and adjust to loop over all features.
7946 * server.c (handle_query) <qSupported>: Adjust to call
7947 target_process_qsupported once, passing it a vector of unprocessed
7949 * target.h (struct target_ops) <process_qsupported>: Change
7951 (target_process_qsupported): Adjust.
7953 2015-11-19 Pedro Alves <palves@redhat.com>
7955 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
7957 * configure: Regenerate.
7959 2015-11-19 Pedro Alves <palves@redhat.com>
7961 * configure: Regenerate.
7963 2015-11-19 Yao Qi <yao.qi@linaro.org>
7965 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
7968 2015-11-19 Yao Qi <yao.qi@linaro.org>
7970 * linux-aarch64-low.c (enum aarch64_operand_type): New.
7971 (struct aarch64_operand): Move enum out.
7973 2015-11-19 Yao Qi <yao.qi@linaro.org>
7975 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
7976 struct user_fpsimd_state *.
7977 (aarch64_store_fpregset): Likewise.
7979 2015-11-19 Yao Qi <yao.qi@linaro.org>
7981 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
7982 struct user_pt_regs *.
7983 (aarch64_store_gregset): Likewise.
7985 2015-11-18 Pedro Alves <palves@redhat.com>
7987 * Makefile.in (all_object_files): Add $IPA_OBJS.
7989 2015-11-17 Pedro Alves <palves@redhat.com>
7991 * win32-low.c (win32_resume): Use gdb_signal_from_host,
7992 GDB_SIGNAL_0 and gdb_signal_to_string.
7994 2015-11-17 Pedro Alves <palves@redhat.com>
7996 * win32-low.c (handle_output_debug_string): Remove parameter.
7997 (win32_kill): Remove our_status local and adjust call to
7998 handle_output_debug_string.
7999 (get_child_debug_event): Adjust call to
8000 handle_output_debug_string.
8002 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
8004 * linux-mips-low.c (mips_fill_gregset): Add cast.
8005 (mips_store_gregset): Likewise.
8006 (mips_fill_fpregset): Likewise.
8007 (mips_store_fpregset): Likewise.
8009 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
8011 * linux-mips-low.c (mips_add_watchpoint): Rename private to
8014 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
8016 * linux-mips-low.c (mips_linux_new_thread): Change type of
8017 watch_type to enum target_hw_bp_type.
8019 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
8021 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
8022 Change return type to arm_hwbp_type.
8024 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
8026 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
8027 (arm_store_gregset): Likewise.
8028 * linux-arm-low.c (arm_get_hwcap): Likewise.
8029 (arm_read_description): Likewise.
8031 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
8033 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
8035 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
8037 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
8038 (ppc_fill_vsxregset): Likewise.
8039 (ppc_store_vsxregset): Likewise.
8040 (ppc_fill_vrregset): Likewise.
8041 (ppc_store_vrregset): Likewise.
8042 (ppc_fill_evrregset): Likewise.
8043 (ppc_store_evrregset): Likewise.
8045 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
8047 * linux-ppc-low.c (ppc_usrregs_info): Remove
8048 forward-declaration.
8049 (ppc_arch_setup): Move lower in file.
8051 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
8053 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
8054 (ps_pdwrite): Likewise.
8056 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
8058 * linux-arm-low.c (arm_new_thread): Move pointer dereference
8059 to after assert checks.
8061 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
8063 * proc-service.c (ps_pdread): Add/adjust casts.
8064 (ps_pdwrite): Add/adjust casts.
8066 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
8068 * server.c (handle_search_memory_1): Cast return value of
8071 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
8073 * server.c (write_qxfer_response): Change type of data to
8076 2015-10-29 Pedro Alves <palves@redhat.com>
8078 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
8080 2015-10-29 Pedro Alves <palves@redhat.com>
8082 * tracepoint.c (clear_installed_tracepoints): Add casts.
8084 2015-10-29 Pedro Alves <palves@redhat.com>
8086 * server.c (handle_v_cont, process_serial_event): Add enum
8087 gdb_signal casts to signal parsing code.
8089 2015-10-29 Pedro Alves <palves@redhat.com>
8091 * linux-low.h (NULL_REGSET): Define.
8092 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
8093 * linux-arm-low.c (arm_regsets): Likewise.
8094 * linux-crisv32-low.c (cris_regsets): Likewise.
8095 * linux-m68k-low.c (m68k_regsets): Likewise.
8096 * linux-mips-low.c (mips_regsets): Likewise.
8097 * linux-nios2-low.c (nios2_regsets): Likewise.
8098 * linux-ppc-low.c (ppc_regsets): Likewise.
8099 * linux-s390-low.c (s390_regsets): Likewise.
8100 * linux-sh-low.c (sh_regsets): Likewise.
8101 * linux-sparc-low.c (sparc_regsets): Likewise.
8102 * linux-tic6x-low.c (tic6x_regsets): Likewise.
8103 * linux-tile-low.c (tile_regsets): Likewise.
8104 * linux-x86-low.c (x86_regsets): Likewise.
8105 * linux-xtensa-low.c (xtensa_regsets): Likewise.
8107 2015-10-29 Pedro Alves <palves@redhat.com>
8109 * linux-low.h (NULL_REGSET): Define.
8110 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
8111 * linux-arm-low.c (arm_regsets): Likewise.
8112 * linux-crisv32-low.c (cris_regsets): Likewise.
8113 * linux-m68k-low.c (m68k_regsets): Likewise.
8114 * linux-mips-low.c (mips_regsets): Likewise.
8115 * linux-nios2-low.c (nios2_regsets): Likewise.
8116 * linux-ppc-low.c (ppc_regsets): Likewise.
8117 * linux-s390-low.c (s390_regsets): Likewise.
8118 * linux-sh-low.c (sh_regsets): Likewise.
8119 * linux-sparc-low.c (sparc_regsets): Likewise.
8120 * linux-tic6x-low.c (tic6x_regsets): Likewise.
8121 * linux-tile-low.c (tile_regsets): Likewise.
8122 * linux-x86-low.c (x86_regsets): Likewise.
8123 * linux-xtensa-low.c (xtensa_regsets): Likewise.
8125 2015-10-26 Doug Evans <dje@google.com>
8127 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
8129 2015-10-26 Doug Evans <dje@google.com>
8131 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
8133 2015-10-26 Doug Evans <dje@google.com>
8135 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
8137 (attach_thread, find_new_threads_callback): Ditto.
8139 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
8141 * mem-break.h (set_breakpoint_data): Remove.
8143 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
8145 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
8146 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
8147 (initialize_low): Remove set_breakpoint_data call.
8148 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
8149 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
8150 (initialize_low): Remove set_breakpoint_data call.
8151 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
8152 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
8153 (initialize_low): Remove set_breakpoint_data call.
8155 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
8157 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
8158 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
8159 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
8160 * target.h (target_breakpoint_kind_from_pc): New macro.
8162 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
8164 * linux-low.c (default_breakpoint_kind_from_pc): New function.
8165 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
8166 the default breakpoint kind.
8168 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
8170 * linux-arm-low.c (arm_supports_z_point_type): Add software
8173 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
8175 * linux-arm-low.c: Refactor breakpoint definitions.
8176 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
8177 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
8179 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
8181 * Makefile.in: Add arm.c/o.
8182 * configure.srv: Likewise.
8183 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
8184 (arm_breakpoint_kind_from_pc): New function.
8185 (arm_sw_breakpoint_from_kind): Return proper kind.
8186 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
8188 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
8190 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
8192 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
8193 (struct raw_breakpoint) <size>: Remove.
8194 (struct raw_breakpoint) <kind>: Add.
8195 (bp_size): New function.
8196 (bp_opcode): Likewise.
8197 (find_raw_breakpoint_at): Adjust for kind.
8198 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
8199 (remove_memory_breakpoint): Adjust for kind call bp_size.
8200 (set_raw_breakpoint_at): Adjust for kind.
8201 (set_breakpoint): Likewise.
8202 (set_breakpoint_at): Call breakpoint_kind_from_pc.
8203 (delete_raw_breakpoint): Adjust for kind.
8204 (delete_breakpoint): Likewise.
8205 (find_gdb_breakpoint): Likewise.
8206 (set_gdb_breakpoint_1): Likewise.
8207 (set_gdb_breakpoint): Likewise.
8208 (delete_gdb_breakpoint_1): Likewise.
8209 (delete_gdb_breakpoint): Likewise.
8210 (uninsert_raw_breakpoint): Likewise.
8211 (reinsert_raw_breakpoint): Likewise.
8212 (set_breakpoint_data): Remove.
8213 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
8214 (check_mem_read): Adjust for kind call bp_size.
8215 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
8216 (clone_one_breakpoint): Adjust for kind.
8217 * mem-break.h (set_gdb_breakpoint): Likewise.
8218 (delete_gdb_breakpoint): Likewise.
8219 * server.c (process_serial_event): Likewise.
8221 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
8223 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
8224 (struct linux_target_ops) <breakpoint>: Remove.
8225 (struct linux_target_ops) <breakpoint_len>: Remove.
8226 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8227 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8228 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
8229 (arm_sw_breakpoint_from_kind): New function.
8230 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
8231 (struct linux_target_ops) <breakpoint>: Remove.
8232 (struct linux_target_ops) <breakpoint_len>: Remove.
8233 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8234 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8235 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
8236 (struct linux_target_ops) <breakpoint>: Remove.
8237 (struct linux_target_ops) <breakpoint_len>: Remove.
8238 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8239 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8240 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
8241 (struct linux_target_ops) <breakpoint>: Remove.
8242 (struct linux_target_ops) <breakpoint_len>: Remove.
8243 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8244 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8245 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
8246 and sw_breakpoint_from_kind to increment the pc.
8247 (linux_breakpoint_kind_from_pc): New function.
8248 (linux_sw_breakpoint_from_kind): New function.
8249 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
8250 (initialize_low): Call breakpoint_kind_from_pc and
8251 sw_breakpoint_from_kind to replace breakpoint_data/len.
8252 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
8254 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
8255 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
8256 (struct linux_target_ops) <breakpoint>: Remove.
8257 (struct linux_target_ops) <breakpoint_len>: Remove.
8258 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8259 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8260 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
8261 (struct linux_target_ops) <breakpoint>: Remove.
8262 (struct linux_target_ops) <breakpoint_len>: Remove.
8263 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8264 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8265 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
8266 (struct linux_target_ops) <breakpoint>: Remove.
8267 (struct linux_target_ops) <breakpoint_len>: Remove.
8268 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8269 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8270 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
8271 (struct linux_target_ops) <breakpoint>: Remove.
8272 (struct linux_target_ops) <breakpoint_len>: Remove.
8273 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8274 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8275 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
8276 (struct linux_target_ops) <breakpoint>: Remove.
8277 (struct linux_target_ops) <breakpoint_len>: Remove.
8278 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8279 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8280 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
8281 (struct linux_target_ops) <breakpoint>: Remove.
8282 (struct linux_target_ops) <breakpoint_len>: Remove.
8283 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8284 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8285 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
8286 (struct linux_target_ops) <breakpoint>: Remove.
8287 (struct linux_target_ops) <breakpoint_len>: Remove.
8288 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8289 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8290 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
8291 (struct linux_target_ops) <breakpoint>: Remove.
8292 (struct linux_target_ops) <breakpoint_len>: Remove.
8293 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8294 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8295 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
8296 (struct linux_target_ops) <breakpoint>: Remove.
8297 (struct linux_target_ops) <breakpoint_len>: Remove.
8298 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8299 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8300 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
8301 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
8302 (struct linux_target_ops) <breakpoint>: Remove.
8303 (struct linux_target_ops) <breakpoint_len>: Remove.
8304 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8305 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8306 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
8307 (struct linux_target_ops) <breakpoint>: Remove.
8308 (struct linux_target_ops) <breakpoint_len>: Remove.
8309 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
8310 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
8312 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
8314 * linux-cris-low.c (cris_get_pc): Remove void arg.
8316 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
8318 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
8321 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
8323 * inferiors.c (thread_pid_matches_callback): New function.
8324 (find_thread_process): New function.
8325 (remove_thread): Reset current_thread.
8326 (remove_process): Assert threads have been removed first.
8328 2015-10-15 Yao Qi <yao.qi@linaro.org>
8330 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
8332 (aarch64_remove_point): Likewise.
8333 * regcache.c (regcache_register_size): New function.
8335 2015-10-12 Yao Qi <yao.qi@linaro.org>
8337 * linux-aarch64-low.c: Update all callers as emit_load_store
8338 is renamed to aarch64_emit_load_store.
8340 2015-10-12 Yao Qi <yao.qi@linaro.org>
8342 * linux-aarch64-low.c: Update all callers of function renaming
8343 from emit_insn to aarch64_emit_insn.
8345 2015-10-12 Yao Qi <yao.qi@linaro.org>
8347 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
8348 arch/aarch64-insn.h.
8349 (struct aarch64_memory_operand): Likewise.
8351 (emit_insn): Move to arch/aarch64-insn.c.
8352 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
8353 (emit_load_store): Move to arch/aarch64-insn.c.
8354 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
8355 (can_encode_int32): Remove.
8357 2015-10-12 Yao Qi <yao.qi@linaro.org>
8359 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
8360 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
8361 (aarch64_relocate_instruction): Likewise.
8362 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
8363 (struct aarch64_insn_visitor): Likewise.
8365 2015-10-12 Yao Qi <yao.qi@linaro.org>
8367 * linux-aarch64-low.c (struct aarch64_insn_data): New.
8368 (struct aarch64_insn_visitor): New.
8369 (struct aarch64_insn_relocation_data): New.
8370 (aarch64_ftrace_insn_reloc_b): New function.
8371 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
8372 (aarch64_ftrace_insn_reloc_cb): Likewise.
8373 (aarch64_ftrace_insn_reloc_tb): Likewise.
8374 (aarch64_ftrace_insn_reloc_adr): Likewise.
8375 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
8376 (aarch64_ftrace_insn_reloc_others): Likewise.
8378 (aarch64_relocate_instruction): Use visitor.
8380 2015-10-12 Yao Qi <yao.qi@linaro.org>
8382 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
8383 int. Add argument buf.
8384 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
8385 aarch64_relocate_instruction.
8387 2015-10-12 Yao Qi <yao.qi@linaro.org>
8389 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
8390 argument insn. Remove local variable insn. Don't call
8392 (aarch64_install_fast_tracepoint_jump_pad): Call
8395 2015-09-30 Yao Qi <yao.qi@linaro.org>
8397 * linux-aarch64-low.c (emit_movk): Shorten a long line.
8398 (emit_load_store_pair): Likewise.
8400 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
8402 * dll.c (match_dll): Add cast(s).
8403 (unloaded_dll): Likewise.
8404 * linux-low.c (second_thread_of_pid_p): Likewise.
8405 (delete_lwp_callback): Likewise.
8406 (count_events_callback): Likewise.
8407 (select_event_lwp_callback): Likewise.
8408 (linux_set_resume_request): Likewise.
8409 * server.c (accumulate_file_name_length): Likewise.
8410 (emit_dll_description): Likewise.
8411 (handle_qxfer_threads_worker): Likewise.
8412 (visit_actioned_threads): Likewise.
8413 * thread-db.c (any_thread_of): Likewise.
8414 * tracepoint.c (same_process_p): Likewise.
8415 (match_blocktype): Likewise.
8416 (build_traceframe_info_xml): Likewise.
8418 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
8420 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
8422 (gdb_unparse_agent_expr): Likewise.
8423 * hostio.c (require_data): Likewise.
8424 (handle_pread): Likewise.
8425 * linux-low.c (disable_regset): Likewise.
8426 (fetch_register): Likewise.
8427 (store_register): Likewise.
8428 (get_dynamic): Likewise.
8429 (linux_qxfer_libraries_svr4): Likewise.
8430 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
8431 (set_fast_tracepoint_jump): Likewise.
8432 (uninsert_fast_tracepoint_jumps_at): Likewise.
8433 (reinsert_fast_tracepoint_jumps_at): Likewise.
8434 (validate_inserted_breakpoint): Likewise.
8435 (clone_agent_expr): Likewise.
8436 * regcache.c (init_register_cache): Likewise.
8437 * remote-utils.c (putpkt_binary_1): Likewise.
8438 (decode_M_packet): Likewise.
8439 (decode_X_packet): Likewise.
8440 (look_up_one_symbol): Likewise.
8441 (relocate_instruction): Likewise.
8442 (monitor_output): Likewise.
8443 * server.c (handle_search_memory): Likewise.
8444 (handle_qxfer_exec_file): Likewise.
8445 (handle_qxfer_libraries): Likewise.
8446 (handle_qxfer): Likewise.
8447 (handle_query): Likewise.
8448 (handle_v_cont): Likewise.
8449 (handle_v_run): Likewise.
8450 (captured_main): Likewise.
8451 * target.c (write_inferior_memory): Likewise.
8452 * thread-db.c (try_thread_db_load_from_dir): Likewise.
8453 * tracepoint.c (init_trace_buffer): Likewise.
8454 (add_tracepoint_action): Likewise.
8455 (add_traceframe): Likewise.
8456 (add_traceframe_block): Likewise.
8457 (cmd_qtdpsrc): Likewise.
8458 (cmd_qtdv): Likewise.
8459 (cmd_qtstatus): Likewise.
8460 (response_source): Likewise.
8461 (response_tsv): Likewise.
8462 (cmd_qtnotes): Likewise.
8463 (gdb_collect): Likewise.
8464 (initialize_tracepoint): Likewise.
8466 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
8468 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
8469 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
8470 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
8472 (enum aarch64_condition_codes): New enum.
8473 (w0): New static global.
8476 (struct aarch64_memory_operand) <type>: New
8477 MEMORY_OPERAND_POSTINDEX type.
8478 (postindex_memory_operand): New helper function.
8479 (emit_ret): New function.
8480 (emit_load_store_pair): New function, factored out of emit_stp
8481 with support for MEMORY_OPERAND_POSTINDEX.
8482 (emit_stp): Rewrite using emit_load_store_pair.
8483 (emit_ldp): New function.
8484 (emit_load_store): Likewise.
8485 (emit_ldr): Mention post-index instruction in comment.
8486 (emit_ldrh): New function.
8487 (emit_ldrb): New function.
8488 (emit_ldrsw): Mention post-index instruction in comment.
8489 (emit_str): Likewise.
8490 (emit_subs): New function.
8491 (emit_cmp): Likewise.
8492 (emit_and): Likewise.
8493 (emit_orr): Likewise.
8494 (emit_orn): Likewise.
8495 (emit_eor): Likewise.
8496 (emit_mvn): Likewise.
8497 (emit_lslv): Likewise.
8498 (emit_lsrv): Likewise.
8499 (emit_asrv): Likewise.
8500 (emit_mul): Likewise.
8501 (emit_sbfm): Likewise.
8502 (emit_sbfx): Likewise.
8503 (emit_ubfm): Likewise.
8504 (emit_ubfx): Likewise.
8505 (emit_csinc): Likewise.
8506 (emit_cset): Likewise.
8507 (emit_nop): Likewise.
8508 (emit_ops_insns): New helper function.
8509 (emit_pop): Likewise.
8510 (emit_push): Likewise.
8511 (aarch64_emit_prologue): New function.
8512 (aarch64_emit_epilogue): Likewise.
8513 (aarch64_emit_add): Likewise.
8514 (aarch64_emit_sub): Likewise.
8515 (aarch64_emit_mul): Likewise.
8516 (aarch64_emit_lsh): Likewise.
8517 (aarch64_emit_rsh_signed): Likewise.
8518 (aarch64_emit_rsh_unsigned): Likewise.
8519 (aarch64_emit_ext): Likewise.
8520 (aarch64_emit_log_not): Likewise.
8521 (aarch64_emit_bit_and): Likewise.
8522 (aarch64_emit_bit_or): Likewise.
8523 (aarch64_emit_bit_xor): Likewise.
8524 (aarch64_emit_bit_not): Likewise.
8525 (aarch64_emit_equal): Likewise.
8526 (aarch64_emit_less_signed): Likewise.
8527 (aarch64_emit_less_unsigned): Likewise.
8528 (aarch64_emit_ref): Likewise.
8529 (aarch64_emit_if_goto): Likewise.
8530 (aarch64_emit_goto): Likewise.
8531 (aarch64_write_goto_address): Likewise.
8532 (aarch64_emit_const): Likewise.
8533 (aarch64_emit_call): Likewise.
8534 (aarch64_emit_reg): Likewise.
8535 (aarch64_emit_pop): Likewise.
8536 (aarch64_emit_stack_flush): Likewise.
8537 (aarch64_emit_zero_ext): Likewise.
8538 (aarch64_emit_swap): Likewise.
8539 (aarch64_emit_stack_adjust): Likewise.
8540 (aarch64_emit_int_call_1): Likewise.
8541 (aarch64_emit_void_call_2): Likewise.
8542 (aarch64_emit_eq_goto): Likewise.
8543 (aarch64_emit_ne_goto): Likewise.
8544 (aarch64_emit_lt_goto): Likewise.
8545 (aarch64_emit_le_goto): Likewise.
8546 (aarch64_emit_gt_goto): Likewise.
8547 (aarch64_emit_ge_got): Likewise.
8548 (aarch64_emit_ops_impl): New static global variable.
8549 (aarch64_emit_ops): New target function, return
8550 &aarch64_emit_ops_impl.
8551 (struct linux_target_ops): Install it.
8553 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
8555 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
8556 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
8558 * linux-aarch64-ipa.c: New file.
8559 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
8561 (aarch64_get_thread_area): New target method.
8562 (extract_signed_bitfield): New helper function.
8563 (aarch64_decode_ldr_literal): New function.
8564 (enum aarch64_opcodes): New enum.
8565 (struct aarch64_register): New struct.
8566 (struct aarch64_operand): New struct.
8567 (x0): New static global.
8576 (aarch64_register): New helper function.
8577 (register_operand): Likewise.
8578 (immediate_operand): Likewise.
8579 (struct aarch64_memory_operand): New struct.
8580 (offset_memory_operand): New helper function.
8581 (preindex_memory_operand): Likewise.
8582 (enum aarch64_system_control_registers): New enum.
8583 (ENCODE): New macro.
8584 (emit_insn): New helper function.
8585 (emit_b): New function.
8586 (emit_bcond): Likewise.
8587 (emit_cb): Likewise.
8588 (emit_tb): Likewise.
8589 (emit_blr): Likewise.
8590 (emit_stp): Likewise.
8591 (emit_ldp_q_offset): Likewise.
8592 (emit_stp_q_offset): Likewise.
8593 (emit_load_store): Likewise.
8594 (emit_ldr): Likewise.
8595 (emit_ldrsw): Likewise.
8596 (emit_str): Likewise.
8597 (emit_ldaxr): Likewise.
8598 (emit_stxr): Likewise.
8599 (emit_stlr): Likewise.
8600 (emit_data_processing_reg): Likewise.
8601 (emit_data_processing): Likewise.
8602 (emit_add): Likewise.
8603 (emit_sub): Likewise.
8604 (emit_mov): Likewise.
8605 (emit_movk): Likewise.
8606 (emit_mov_addr): Likewise.
8607 (emit_mrs): Likewise.
8608 (emit_msr): Likewise.
8609 (emit_sevl): Likewise.
8610 (emit_wfe): Likewise.
8611 (append_insns): Likewise.
8612 (can_encode_int32_in): New helper function.
8613 (aarch64_relocate_instruction): New function.
8614 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
8615 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
8616 (struct linux_target_ops): Install aarch64_get_thread_area,
8617 aarch64_install_fast_tracepoint_jump_pad and
8618 aarch64_get_min_fast_tracepoint_insn_len.
8620 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
8622 * Makefile.in (aarch64-insn.o): New rule.
8623 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
8625 2015-09-21 Yao Qi <yao.qi@linaro.org>
8627 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
8629 2015-09-21 Yao Qi <yao.qi@linaro.org>
8631 * tracepoint.c (max_jump_pad_size): Remove.
8633 2015-09-18 Yao Qi <yao.qi@linaro.org>
8635 * linux-aarch64-low.c: Don't include sys/uio.h.
8636 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
8638 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
8640 * tracepoint.c (eval_result_type): Change prototype.
8641 (condition_true_at_tracepoint): Fix argument to compiled_cond.
8643 2015-09-15 Pedro Alves <palves@redhat.com>
8645 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
8646 Check whether to report exec events instead of checking whether
8647 multiprocess is enabled.
8649 2015-09-15 Pedro Alves <palves@redhat.com>
8652 * remote-utils.c (prepare_resume_reply): Merge
8653 TARGET_WAITKIND_VFORK_DONE switch case with the
8654 TARGET_WAITKIND_FORKED case.
8656 2015-09-15 Yao Qi <yao.qi@linaro.org>
8658 * server.c (handle_query): Check string comparison using
8659 "else if" instead of "if".
8661 2015-09-15 Yao Qi <yao.qi@linaro.org>
8663 * server.c (vCont_supported): New global variable.
8664 (handle_query): Set vCont_supported to 1 if "vContSupported+"
8665 matches. Append ";vContSupported+" to own_buf.
8666 (handle_v_requests): Append ";s;S" to own_buf if target supports
8667 hardware single step or vCont_supported is false.
8668 (capture_main): Set vCont_supported to zero.
8670 2015-09-15 Yao Qi <yao.qi@linaro.org>
8672 * linux-low.c (linux_supports_conditional_breakpoints): Rename
8674 (linux_supports_hardware_single_step): ... New function.
8675 (linux_target_ops): Update.
8676 * lynx-low.c (lynx_target_ops): Set field
8677 supports_hardware_single_step to target_can_do_hardware_single_step.
8678 * nto-low.c (nto_target_ops): Likewise.
8679 * spu-low.c (spu_target_ops): Likewise.
8680 * win32-low.c (win32_target_ops): Likewise.
8681 * target.c (target_can_do_hardware_single_step): New function.
8682 * target.h (struct target_ops) <supports_conditional_breakpoints>:
8683 Remove. <supports_hardware_single_step>: New field.
8684 (target_supports_conditional_breakpoints): Remove.
8685 (target_supports_hardware_single_step): New macro.
8686 (target_can_do_hardware_single_step): Declare.
8687 * server.c (handle_query): Use target_supports_hardware_single_step
8688 instead of target_supports_conditional_breakpoints.
8690 2015-09-15 Yao Qi <yao.qi@linaro.org>
8692 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
8694 (struct linux_target_ops the_low_target): Install
8695 aarch64_linux_siginfo_fixup.
8697 2015-09-11 Don Breazeal <donb@codesourcery.com>
8698 Luis Machado <lgustavo@codesourcery.com>
8700 * linux-low.c (linux_mourn): Static declaration.
8701 (linux_arch_setup): Move in front of
8702 handle_extended_wait.
8703 (linux_arch_setup_thread): New function.
8704 (handle_extended_wait): Handle exec events. Call
8705 linux_arch_setup_thread. Make event_lwp argument a
8706 pointer-to-a-pointer.
8707 (check_zombie_leaders): Do not check stopped threads.
8708 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
8709 (linux_low_filter_event): Add lwp and thread for exec'ing
8710 non-leader thread if leader thread has been deleted.
8711 Refactor code into linux_arch_setup_thread and call it.
8712 Pass child lwp pointer by reference to handle_extended_wait.
8713 (linux_wait_for_event_filtered): Update comment.
8714 (linux_wait_1): Prevent clobbering exec event status.
8715 (linux_supports_exec_events): New function.
8716 (linux_target_ops) <supports_exec_events>: Initialize new member.
8717 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
8719 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
8720 * server.c (report_exec_events): New global variable.
8721 (handle_query): Handle qSupported query for exec-events feature.
8722 (captured_main): Initialize report_exec_events.
8723 * server.h (report_exec_events): Declare new global variable.
8724 * target.h (struct target_ops) <supports_exec_events>: New
8726 (target_supports_exec_events): New macro.
8727 * win32-low.c (win32_target_ops) <supports_exec_events>:
8728 Initialize new member.
8730 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
8732 * linux-low.c (linux_low_enable_btrace): Remove.
8733 (linux_target_ops): Replace linux_low_enable_btrace with
8734 linux_enable_btrace.
8736 2015-09-03 Yao Qi <yao.qi@linaro.org>
8738 * linux-aarch64-low.c (aarch64_insert_point): Call
8739 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
8742 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
8744 * linux-low.c (check_stopped_by_breakpoint): Use
8745 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
8747 2015-08-27 Pedro Alves <palves@redhat.com>
8749 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
8751 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
8753 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
8754 the XNEW-family equivalent.
8755 (compile_bytecodes): Likewise.
8756 * dll.c (loaded_dll): Likewise.
8757 * event-loop.c (append_callback_event): Likewise.
8758 (create_file_handler): Likewise.
8759 (create_file_event): Likewise.
8760 * hostio.c (handle_open): Likewise.
8761 * inferiors.c (add_thread): Likewise.
8762 (add_process): Likewise.
8763 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
8764 * linux-arm-low.c (arm_new_process): Likewise.
8765 (arm_new_thread): Likewise.
8766 * linux-low.c (add_to_pid_list): Likewise.
8767 (linux_add_process): Likewise.
8768 (handle_extended_wait): Likewise.
8769 (add_lwp): Likewise.
8770 (enqueue_one_deferred_signal): Likewise.
8771 (enqueue_pending_signal): Likewise.
8772 (linux_resume_one_lwp_throw): Likewise.
8773 (linux_resume_one_thread): Likewise.
8774 (linux_read_memory): Likewise.
8775 (linux_write_memory): Likewise.
8776 * linux-mips-low.c (mips_linux_new_process): Likewise.
8777 (mips_linux_new_thread): Likewise.
8778 (mips_add_watchpoint): Likewise.
8779 * linux-x86-low.c (initialize_low_arch): Likewise.
8780 * lynx-low.c (lynx_add_process): Likewise.
8781 * mem-break.c (set_raw_breakpoint_at): Likewise.
8782 (set_breakpoint): Likewise.
8783 (add_condition_to_breakpoint): Likewise.
8784 (add_commands_to_breakpoint): Likewise.
8785 (clone_agent_expr): Likewise.
8786 (clone_one_breakpoint): Likewise.
8787 * regcache.c (new_register_cache): Likewise.
8788 * remote-utils.c (look_up_one_symbol): Likewise.
8789 * server.c (queue_stop_reply): Likewise.
8790 (start_inferior): Likewise.
8791 (queue_stop_reply_callback): Likewise.
8792 (handle_target_event): Likewise.
8793 * spu-low.c (fetch_ppc_memory): Likewise.
8794 (store_ppc_memory): Likewise.
8795 * target.c (set_target_ops): Likewise.
8796 * thread-db.c (thread_db_load_search): Likewise.
8797 (try_thread_db_load_1): Likewise.
8798 * tracepoint.c (add_tracepoint): Likewise.
8799 (add_tracepoint_action): Likewise.
8800 (create_trace_state_variable): Likewise.
8801 (cmd_qtdpsrc): Likewise.
8802 (cmd_qtro): Likewise.
8803 (add_while_stepping_state): Likewise.
8804 * win32-low.c (child_add_thread): Likewise.
8805 (get_image_name): Likewise.
8807 2015-08-25 Yao Qi <yao.qi@linaro.org>
8809 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
8811 2015-08-25 Yao Qi <yao.qi@linaro.org>
8813 * Makefile.in (aarch64-linux.o): New rule.
8814 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
8816 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
8817 (aarch64_init_debug_reg_state): Make it extern.
8818 (aarch64_linux_prepare_to_resume): Remove.
8820 2015-08-25 Yao Qi <yao.qi@linaro.org>
8822 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
8823 lwp_arch_private_info and ptid_of_lwp.
8825 2015-08-25 Yao Qi <yao.qi@linaro.org>
8827 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
8828 Find proc_info by find_process_pid. All callers updated.
8830 2015-08-25 Yao Qi <yao.qi@linaro.org>
8832 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
8834 (debug_reg_change_callback): Remove.
8835 (aarch64_notify_debug_reg_change): Remove.
8837 2015-08-25 Yao Qi <yao.qi@linaro.org>
8839 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
8840 Call current_lwp_ptid.
8842 2015-08-25 Yao Qi <yao.qi@linaro.org>
8844 * linux-aarch64-low.c (debug_reg_change_callback): Use
8847 2015-08-25 Yao Qi <yao.qi@linaro.org>
8849 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
8851 2015-08-25 Yao Qi <yao.qi@linaro.org>
8853 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
8855 2015-08-25 Yao Qi <yao.qi@linaro.org>
8857 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
8860 2015-08-25 Yao Qi <yao.qi@linaro.org>
8862 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
8864 (debug_reg_change_callback): Remove argument entry and add argument
8865 lwp. Remove local variable thread. Don't print thread id in the
8866 debugging output. Don't check whether pid of thread equals to pid.
8867 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
8868 iterate_over_lwps instead find_inferior.
8870 2015-08-24 Pedro Alves <palves@redhat.com>
8872 * inferiors.c (get_first_process): New function.
8873 * inferiors.h (get_first_process): New declaration.
8874 * remote-utils.c (read_ptid): Default to the first process in the
8875 list, instead of to the current thread's process.
8877 2015-08-24 Pedro Alves <palves@redhat.com>
8879 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
8880 * event-loop.c: Likewise.
8881 * remote-utils.c: Likewise.
8882 * tracepoint.c: Likewise.
8884 2015-08-24 Pedro Alves <palves@redhat.com>
8886 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
8889 2015-08-21 Pedro Alves <palves@redhat.com>
8891 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
8892 instead of literal 1.
8894 2015-08-21 Pedro Alves <palves@redhat.com>
8896 * tdesc.c (default_description): Explicitly zero-initialize.
8898 2015-08-21 Pedro Alves <palves@redhat.com>
8901 * inferiors.c (remove_thread): Discard any pending stop reply for
8903 * server.c (remove_all_on_match_pid): Rename to ...
8904 (remove_all_on_match_ptid): ... this. Work with a filter ptid
8906 (discard_queued_stop_replies): Change parameter to a ptid. Now
8908 (handle_v_kill, kill_inferior_callback, captured_main)
8909 (process_serial_event): Adjust.
8910 * server.h (discard_queued_stop_replies): Declare.
8912 2015-08-21 Pedro Alves <palves@redhat.com>
8914 * linux-low.c (wait_for_sigstop): Always switch to no thread
8915 selected if the previously current thread dies.
8916 * lynx-low.c (lynx_request_interrupt): Use the first thread's
8917 process instead of the current thread's.
8918 * remote-utils.c (input_interrupt): Don't check if there's no
8920 * server.c (gdb_read_memory, gdb_write_memory): If setting the
8921 current thread to the general thread fails, error out.
8922 (handle_qxfer_auxv, handle_qxfer_libraries)
8923 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
8924 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
8925 (handle_query): Check if there's a thread selected instead of
8926 checking whether there's any thread in the thread list.
8927 (handle_qxfer_threads, handle_qxfer_btrace)
8928 (handle_qxfer_btrace_conf): Don't error out early if there's no
8929 thread in the thread list.
8930 (handle_v_cont, myresume): Don't set the current thread to the
8932 (process_serial_event) <Hg handling>: Also set thread_id if the
8933 previous general thread is still alive.
8934 (process_serial_event) <g/G handling>: If setting the current
8935 thread to the general thread fails, error out.
8936 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
8937 thread's lwp instead of the current thread's.
8938 * target.c (set_desired_thread): If the desired thread was not
8939 found, leave the current thread pointing to NULL. Return an int
8940 (boolean) indicating success.
8941 * target.h (set_desired_thread): Change return type to int.
8943 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
8945 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
8946 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
8948 (ps_get_thread_area): New function.
8950 2015-08-19 Gary Benson <gbenson@redhat.com>
8952 * hostio.c (handle_pread): Do not attempt to read more data
8953 than hostio_reply_with_data can fit in a packet.
8955 2015-08-18 Joel Brobecker <brobecker@adacore.com>
8957 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
8959 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
8961 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
8963 2015-08-06 Pedro Alves <palves@redhat.com>
8965 * tracepoint.c (expr_eval_result): Now an int.
8967 2015-08-06 Pedro Alves <palves@redhat.com>
8969 * gdbthread.h (struct regcache): Forward declare.
8970 (struct thread_info) <regcache_data>: Now a struct regcache
8972 * inferiors.c (inferior_regcache_data)
8973 (set_inferior_regcache_data): Now work with struct regcache
8975 * inferiors.h (struct regcache): Forward declare.
8976 (inferior_regcache_data, set_inferior_regcache_data): Now work
8977 with struct regcache pointers.
8978 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
8979 (free_register_cache_thread): Remove struct regcache pointer
8982 2015-08-06 Pedro Alves <palves@redhat.com>
8984 * server.c (captured_main): On error, print the exception message
8985 to stderr, and if run_once is set, throw a quit.
8987 2015-08-06 Pedro Alves <palves@redhat.com>
8989 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
8992 2015-08-06 Pedro Alves <palves@redhat.com>
8994 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
8995 reading beyond the passed in buffer length.
8997 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
8999 * tracepoint.c (symbol_list) <required>: Remove.
9001 2015-08-06 Pedro Alves <palves@redhat.com>
9003 * linux-low.c (handle_extended_wait): Set the fork child's suspend
9004 count if stopping and suspending threads.
9005 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
9006 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
9007 (linux_detach): Complete an ongoing step-over.
9008 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
9010 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
9011 (linux_wait_1): If passing a signal to the inferior after
9012 finishing a step-over, unsuspend and re-resume all lwps. If we
9013 see a single-step event but the thread should be continuing, don't
9014 pass the trap to gdb.
9015 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
9016 internal_error instead of gdb_assert.
9017 (enqueue_pending_signal): New function.
9018 (check_ptrace_stopped_lwp_gone): Add debug output.
9019 (start_step_over): Use internal_error instead of gdb_assert.
9020 (complete_ongoing_step_over): New function.
9021 (linux_resume_one_thread): Don't resume a suspended thread.
9022 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
9025 2015-08-06 Pedro Alves <palves@redhat.com>
9027 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
9028 (linux_thread_alive): Use lwp_is_marked_dead.
9029 (extended_event_reported): Delete.
9030 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
9031 instead of extended_event_reported.
9032 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
9034 (lwp_is_marked_dead): New function.
9035 (lwp_running): Use lwp_is_marked_dead.
9036 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
9039 2015-08-06 Pedro Alves <palves@redhat.com>
9041 * linux-low.c (linux_wait_1): Move fork event output out of the
9042 !report_to_gdb check. Pass event_child->waitstatus to
9043 target_waitstatus_to_string instead of ourstatus.
9045 2015-08-04 Yao Qi <yao.qi@linaro.org>
9047 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
9048 if current_thread is 32 bit.
9050 2015-08-04 Yao Qi <yao.qi@linaro.org>
9052 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
9053 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
9054 * server.c (extended_protocol): Remove "static".
9055 * server.h (extended_protocol): Declare it.
9057 2015-08-04 Yao Qi <yao.qi@linaro.org>
9059 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
9060 both aarch64 and aarch32.
9061 (aarch64_set_pc): Likewise.
9063 2015-08-04 Yao Qi <yao.qi@linaro.org>
9065 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
9066 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
9067 arm-with-neon.xml to srv_xmlfiles.
9068 * linux-aarch64-low.c: Include linux-aarch32-low.h.
9069 (is_64bit_tdesc): New function.
9070 (aarch64_linux_read_description): New function.
9071 (aarch64_arch_setup): Call aarch64_linux_read_description.
9072 (regs_info): Rename to regs_info_aarch64.
9073 (aarch64_regs_info): Return right regs_info.
9074 (initialize_low_arch): Call initialize_low_arch_aarch32.
9076 2015-08-04 Yao Qi <yao.qi@linaro.org>
9078 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
9079 * linux-aarch32-low.c: New file.
9080 * linux-aarch32-low.h: New file.
9081 * linux-arm-low.c (arm_fill_gregset): Move it to
9082 linux-aarch32-low.c.
9083 (arm_store_gregset): Likewise.
9084 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
9085 (arm_store_vfpregset): Call arm_store_vfpregset_num.
9086 (arm_arch_setup): Check if PTRACE_GETREGSET works.
9087 (regs_info): Rename to regs_info_arm.
9088 (arm_regs_info): Return regs_info_aarch32 if
9089 have_ptrace_getregset is 1 and target description is
9090 arm_with_neon or arm_with_vfpv3.
9091 (initialize_low_arch): Don't call init_registers_arm_with_neon.
9092 Call initialize_low_arch_aarch32 instead.
9094 2015-08-04 Yao Qi <yao.qi@linaro.org>
9096 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
9097 * linux-low.c: ... here.
9098 * linux-low.h (have_ptrace_getregset): Declare it.
9100 2015-08-04 Pedro Alves <palves@redhat.com>
9102 * thread-db.c (struct thread_db): Use new typedefs.
9103 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
9105 (disable_thread_event_reporting): Cast result of dlsym to
9106 destination function pointer type.
9107 (thread_db_mourn): Use td_ta_delete_ftype.
9109 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
9111 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
9113 (CDX_BREAKPOINT): Define for R2.
9114 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
9115 (the_low_target): Add comments.
9117 2015-07-30 Yao Qi <yao.qi@linaro.org>
9119 * linux-arm-low.c (arm_hwcap): Remove it.
9120 (arm_read_description): New local variable arm_hwcap. Don't
9121 set arm_hwcap to zero.
9123 2015-07-30 Yao Qi <yao.qi@linaro.org>
9125 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
9126 Use regcache->tdesc instead.
9127 (arm_store_wmmxregset): Likewise.
9128 (arm_fill_vfpregset): Likewise.
9129 (arm_store_vfpregset): Likewise.
9131 2015-07-30 Yao Qi <yao.qi@linaro.org>
9133 * linux-arm-low.c: Include arch/arm.h.
9134 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
9135 (arm_store_gregset): Likewise.
9137 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
9139 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
9140 ptrace's 4th parameter.
9142 2015-07-27 Yao Qi <yao.qi@linaro.org>
9144 * configure.srv (case aarch64*-*-linux*): Don't set
9147 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
9149 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
9151 * linux-arm-low.c: Likewise.
9152 * linux-cris-low.c: Likewise.
9153 * linux-crisv32-low.c: Likewise.
9154 * linux-low.c: Likewise.
9155 * linux-m68k-low.c: Likewise.
9156 * linux-mips-low.c: Likewise.
9157 * linux-nios2-low.c: Likewise.
9158 * linux-s390-low.c: Likewise.
9159 * linux-sparc-low.c: Likewise.
9160 * linux-tic6x-low.c: Likewise.
9161 * linux-tile-low.c: Likewise.
9162 * linux-x86-low.c: Likewise.
9164 2015-07-24 Pedro Alves <palves@redhat.com>
9166 * config.in: Regenerate.
9167 * configure: Regenerate.
9169 2015-07-24 Pedro Alves <palves@redhat.com>
9171 * acinclude.m4: Include ../ptrace.m4.
9172 * configure.ac: Call GDB_AC_PTRACE.
9173 * config.in, configure: Regenerate.
9175 2015-07-24 Yao Qi <yao.qi@linaro.org>
9177 * linux-low.c (linux_create_inferior): Remove setting to
9178 proc->priv->new_inferior.
9179 (linux_attach): Likewise.
9180 (linux_low_filter_event): Likewise.
9181 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
9183 2015-07-24 Yao Qi <yao.qi@linaro.org>
9185 * linux-low.c (linux_arch_setup): New function.
9186 (linux_low_filter_event): If proc->tdesc is NULL and
9187 proc->attached is true, call the_low_target.arch_setup.
9188 Otherwise, keep status pending, and return.
9189 (linux_resume_one_lwp_throw): Don't call get_pc if
9190 thread->while_stepping isn't NULL. Don't call
9191 get_thread_regcache if proc->tdesc is NULL.
9192 (need_step_over_p): Return 0 if proc->tdesc is NULL.
9193 (linux_target_ops): Install arch_setup.
9194 * server.c (start_inferior): Call the_target->arch_setup.
9195 * target.h (struct target_ops) <arch_setup>: New field.
9196 (target_arch_setup): New marco.
9197 * lynx-low.c (lynx_target_ops): Update.
9198 * nto-low.c (nto_target_ops): Update.
9199 * spu-low.c (spu_target_ops): Update.
9200 * win32-low.c (win32_target_ops): Update.
9202 2015-07-24 Yao Qi <yao.qi@linaro.org>
9204 * linux-low.c (linux_add_process): Don't set
9205 proc->priv->new_inferior.
9206 (linux_create_inferior): Set proc->priv->new_inferior to 1.
9207 (linux_attach): Likewise.
9209 2015-07-24 Yao Qi <yao.qi@linaro.org>
9211 * server.c (start_inferior): Code refactor.
9213 2015-07-24 Yao Qi <yao.qi@linaro.org>
9215 * server.c (process_serial_event): Set general_thread.
9217 2015-07-21 Yao Qi <yao.qi@linaro.org>
9219 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
9220 aarch64_linux_get_debug_reg_capacity.
9222 2015-07-17 Yao Qi <yao.qi@linaro.org>
9224 * Makefile.in (aarch64-linux-hw-point.o): New rule.
9225 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
9226 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
9227 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
9228 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
9229 (AARCH64_HWP_ALIGNMENT): Likewise.
9230 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
9231 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
9232 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
9233 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
9234 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
9235 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
9236 (struct aarch64_debug_reg_state): Likewise.
9237 (struct arch_lwp_info): Likewise.
9238 (aarch64_align_watchpoint): Likewise.
9239 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
9240 (aarch64_watchpoint_length): Likewise.
9241 (aarch64_point_encode_ctrl_reg): Likewise
9242 (aarch64_point_is_aligned): Likewise.
9243 (aarch64_align_watchpoint): Likewise.
9244 (aarch64_linux_set_debug_regs):
9245 (aarch64_dr_state_insert_one_point): Likewise.
9246 (aarch64_dr_state_remove_one_point): Likewise.
9247 (aarch64_handle_breakpoint): Likewise.
9248 (aarch64_handle_aligned_watchpoint): Likewise.
9249 (aarch64_handle_unaligned_watchpoint): Likewise.
9250 (aarch64_handle_watchpoint): Likewise.
9252 2015-07-17 Yao Qi <yao.qi@linaro.org>
9254 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
9255 and don't aarch64_get_debug_reg_state. All callers update.
9256 (aarch64_handle_aligned_watchpoint): Likewise.
9257 (aarch64_handle_unaligned_watchpoint): Likewise.
9258 (aarch64_handle_watchpoint): Likewise.
9259 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
9260 (aarch64_remove_point): Likewise.
9262 2015-07-17 Yao Qi <yao.qi@linaro.org>
9264 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
9266 (aarch64_handle_unaligned_watchpoint): Likewise.
9268 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
9270 Revert the previous 3 commits:
9271 Move gdb_regex* to common/
9272 Move linux_find_memory_regions_full & co.
9273 gdbserver build-id attribute generator
9275 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
9276 Jan Kratochvil <jan.kratochvil@redhat.com>
9278 gdbserver build-id attribute generator.
9279 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
9280 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
9281 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
9283 (get_dynamic): Use find_pdhr to traverse program headers.
9284 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
9285 (compare_mapping_entry_range, struct find_memory_region_callback_data)
9286 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
9287 (get_hex_build_id): New.
9288 (linux_qxfer_libraries_svr4): Add optional build-id attribute
9289 to reply XML document.
9291 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
9292 Jan Kratochvil <jan.kratochvil@redhat.com>
9294 * target.c: Include target/target-utils.h and fcntl.h.
9295 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
9296 (target_fileio_read_stralloc): New functions.
9298 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
9300 * Makefile.in (OBS): Add gdb_regex.o.
9302 * config.in: Rebuilt.
9303 * configure: Rebuilt.
9305 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
9306 Jan Kratochvil <jan.kratochvil@redhat.com>
9308 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
9309 * Makefile.in (OBS): Add target-utils.o.
9310 (linux-maps.o, target-utils.o): New.
9311 * configure.srv (srv_linux_obj): Add linux-maps.o.
9313 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
9315 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
9317 (the_low_target): Install it.
9319 2015-07-14 Pedro Alves <palves@redhat.com>
9321 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
9322 Instead, ignore ECHILD, and throw an error for other errnos.
9324 2015-07-10 Pedro Alves <palves@redhat.com>
9326 * event-loop.c (struct callback_event) <data>: Change type to
9327 gdb_client_data instance instead of gdb_client_data pointer.
9328 (append_callback_event): Adjust.
9330 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
9332 * linux-aarch64-low.c: Add comments for each linux_target_ops
9333 method. Remove comments already covered in target_ops and
9334 linux_target_ops definitions.
9335 (the_low_target): Add comments for each unimplemented method.
9337 2015-07-09 Yao Qi <yao.qi@linaro.org>
9339 * linux-aarch64-low.c (aarch64_regmap): Remove.
9340 (aarch64_usrregs_info): Remove.
9341 (regs_info): Set field usrregs to NULL.
9343 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
9345 * linux-low.c: Include "rsp-low.h"
9346 (linux_low_encode_pt_config, linux_low_encode_raw): New.
9347 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
9348 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
9349 (handle_btrace_enable_pt): New.
9350 (handle_btrace_general_set): Support "pt".
9351 (handle_btrace_conf_general_set): Support "pt:size".
9353 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
9355 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
9358 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
9360 * linux-aarch64-low.c: Remove comment about endianness.
9361 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
9362 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
9365 2015-06-24 Gary Benson <gbenson@redhat.com>
9367 * linux-i386-ipa.c (stdint.h): Do not include.
9368 * lynx-i386-low.c (stdint.h): Likewise.
9369 * lynx-ppc-low.c (stdint.h): Likewise.
9370 * mem-break.c (stdint.h): Likewise.
9371 * thread-db.c (stdint.h): Likewise.
9372 * tracepoint.c (stdint.h): Likewise.
9373 * win32-low.c (stdint.h): Likewise.
9375 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
9377 * server.c (write_qxfer_response): Update call to
9378 remote_escape_output.
9380 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
9381 Jan Kratochvil <jan.kratochvil@redhat.com>
9383 Merge multiple hex conversions.
9384 * gdbreplay.c (tohex): Rename to 'fromhex'.
9385 (logchar): Use fromhex.
9387 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
9389 * server.c (handle_qxfer_libraries): Set `version' attribute for
9392 2015-06-10 Gary Benson <gbenson@redhat.com>
9394 * target.h (struct target_ops) <multifs_open>: New field.
9395 <multifs_unlink>: Likewise.
9396 <multifs_readlink>: Likewise.
9397 * linux-low.c (nat/linux-namespaces.h): New include.
9398 (linux_target_ops): Initialize the_target->multifs_open,
9399 the_target->multifs_unlink and the_target->multifs_readlink.
9400 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
9401 * hostio.c (hostio_fs_pid): New static variable.
9402 (hostio_handle_new_gdb_connection): New function.
9403 (handle_setfs): Likewise.
9404 (handle_open): Use the_target->multifs_open as appropriate.
9405 (handle_unlink): Use the_target->multifs_unlink as appropriate.
9406 (handle_readlink): Use the_target->multifs_readlink as
9408 (handle_vFile): Handle vFile:setfs packets.
9409 * server.c (handle_query): Call hostio_handle_new_gdb_connection
9410 after target_handle_new_gdb_connection.
9412 2015-06-10 Gary Benson <gbenson@redhat.com>
9414 * configure.ac (AC_CHECK_FUNCS): Add setns.
9415 * config.in: Regenerate.
9416 * configure: Likewise.
9417 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
9418 (linux-namespaces.o): New rule.
9419 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
9421 2015-06-09 Gary Benson <gbenson@redhat.com>
9423 * hostio.c (handle_open): Process mode argument with
9424 fileio_to_host_mode.
9426 2015-06-01 Yao Qi <yao.qi@linaro.org>
9428 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
9429 * linux-x86-low.c: Likewise.
9431 2015-05-28 Don Breazeal <donb@codesourcery.com>
9433 * linux-low.c (handle_extended_wait): Initialize
9434 thread_info.last_resume_kind for new fork children.
9436 2015-05-15 Pedro Alves <palves@redhat.com>
9438 * target.h (target_handle_new_gdb_connection): Rewrite using if
9439 wrapped in do/while.
9441 2015-05-14 Joel Brobecker <brobecker@adacore.com>
9443 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
9444 * configure, config.in: Regenerate.
9445 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
9448 2015-05-12 Don Breazeal <donb@codesourcery.com>
9450 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
9451 PTRACE_EVENT_VFORK_DONE.
9452 (linux_low_ptrace_options, extended_event_reported): Add vfork
9454 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
9455 and "vforkdone" for RSP 'T' Stop Reply Packet.
9456 * server.h (report_vfork_events): Declare
9459 2015-05-12 Don Breazeal <donb@codesourcery.com>
9461 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
9462 (the_low_target) <new_fork>: Initialize new member.
9463 * linux-arm-low.c (arm_new_fork): New function.
9464 (the_low_target) <new_fork>: Initialize new member.
9465 * linux-low.c (handle_extended_wait): Call new target function
9467 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
9468 * linux-mips-low.c (mips_add_watchpoint): New function
9469 extracted from mips_insert_point.
9470 (the_low_target) <new_fork>: Initialize new member.
9471 (mips_linux_new_fork): New function.
9472 (mips_insert_point): Call mips_add_watchpoint.
9473 * linux-x86-low.c (x86_linux_new_fork): New function.
9474 (the_low_target) <new_fork>: Initialize new member.
9476 2015-05-12 Don Breazeal <donb@codesourcery.com>
9478 * linux-low.c (handle_extended_wait): Implement return value,
9479 rename argument 'event_child' to 'event_lwp', handle
9480 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
9481 (linux_low_ptrace_options): New function.
9482 (linux_low_filter_event): Call linux_low_ptrace_options,
9483 use different argument fo linux_enable_event_reporting,
9484 use return value from handle_extended_wait.
9485 (extended_event_reported): New function.
9486 (linux_wait_1): Call extended_event_reported and set
9487 status to report fork events.
9488 (linux_write_memory): Add pid to debug message.
9489 (reset_lwp_ptrace_options_callback): New function.
9490 (linux_handle_new_gdb_connection): New function.
9491 (linux_target_ops): Initialize new structure member.
9492 * linux-low.h (struct lwp_info) <waitstatus>: New member.
9493 * lynx-low.c: Initialize new structure member.
9494 * remote-utils.c (prepare_resume_reply): Implement stop reason
9495 "fork" for "T" stop message.
9496 * server.c (handle_query): Call handle_new_gdb_connection.
9497 * server.h (report_fork_events): Declare global flag.
9498 * target.h (struct target_ops) <handle_new_gdb_connection>:
9500 (target_handle_new_gdb_connection): New macro.
9501 * win32-low.c: Initialize new structure member.
9503 2015-05-12 Don Breazeal <donb@codesourcery.com>
9505 * mem-break.c (APPEND_TO_LIST): Define macro.
9506 (clone_agent_expr): New function.
9507 (clone_one_breakpoint): New function.
9508 (clone_all_breakpoints): New function.
9509 * mem-break.h: Declare new functions.
9511 2015-05-12 Don Breazeal <donb@codesourcery.com>
9513 * linux-low.c (linux_supports_fork_events): New function.
9514 (linux_supports_vfork_events): New function.
9515 (linux_target_ops): Initialize new structure members.
9516 (initialize_low): Call linux_check_ptrace_features.
9517 * lynx-low.c (lynx_target_ops): Initialize new structure
9519 * server.c (report_fork_events, report_vfork_events):
9521 (handle_query): Add new features to qSupported packet and
9523 (captured_main): Initialize new global variables.
9524 * target.h (struct target_ops) <supports_fork_events>:
9526 <supports_vfork_events>: New member.
9527 (target_supports_fork_events): New macro.
9528 (target_supports_vfork_events): New macro.
9529 * win32-low.c (win32_target_ops): Initialize new structure
9532 2015-05-12 Gary Benson <gbenson@redhat.com>
9534 * server.c (handle_qxfer_exec_file): Use current process
9537 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
9539 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
9540 Remove HAVE_PTRACE_GETREGS conditionals.
9541 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
9542 instead of PTRACE_GETREGS and PTRACE_SETREGS.
9544 2015-05-08 Yao Qi <yao.qi@linaro.org>
9546 * linux-low.c (linux_supports_conditional_breakpoints): New
9548 (linux_target_ops): Install new target method.
9549 * lynx-low.c (lynx_target_ops): Install NULL hook for
9550 supports_conditional_breakpoints.
9551 * nto-low.c (nto_target_ops): Likewise.
9552 * spu-low.c (spu_target_ops): Likewise.
9553 * win32-low.c (win32_target_ops): Likewise.
9554 * server.c (handle_query): Check
9555 target_supports_conditional_breakpoints.
9556 * target.h (struct target_ops) <supports_conditional_breakpoints>:
9558 (target_supports_conditional_breakpoints): New macro.
9560 2015-05-06 Pedro Alves <palves@redhat.com>
9563 * server.c (start_inferior): If the process exits, mourn it.
9565 2015-04-21 Gary Benson <gbenson@redhat.com>
9567 * hostio.c (fileio_open_flags_to_host): Factored out to
9568 fileio_to_host_openflags in common/fileio.c. Single use
9571 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
9573 * linux-xtensa-low.c (xtensa_fill_gregset)
9574 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
9577 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
9579 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
9580 (regs_info): Replace usrregs pointer with NULL.
9582 2015-04-17 Gary Benson <gbenson@redhat.com>
9584 * target.h (struct target_ops) <pid_to_exec_file>: New field.
9585 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
9586 * server.c (handle_qxfer_exec_file): New function.
9587 (qxfer_packets): Add exec-file entry.
9588 (handle_query): Report qXfer:exec-file:read as supported packet.
9590 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
9592 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
9594 2015-04-09 Gary Benson <gbenson@redhat.com>
9596 * hostio-errno.c (errno_to_fileio_error): Remove function.
9597 Update caller to use remote_fileio_to_fio_error.
9599 2015-04-09 Yao Qi <yao.qi@linaro.org>
9601 * linux-low.c (linux_insert_point): Call
9602 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
9603 (linux_remove_point): Call remove_memory_breakpoint if type is
9605 * linux-x86-low.c (x86_insert_point): Don't call
9606 insert_memory_breakpoint.
9607 (x86_remove_point): Don't call remove_memory_breakpoint.
9609 2015-04-01 Pedro Alves <palves@redhat.com>
9610 Cleber Rosa <crosa@redhat.com>
9612 * server.c (gdbserver_usage): Reorganize and extend the usage
9615 2015-03-24 Pedro Alves <palves@redhat.com>
9617 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
9618 output. Also dump TRAP_TRACE.
9619 (linux_low_filter_event): In debug output, distinguish a
9620 resume_stop SIGSTOP from a delayed SIGSTOP.
9622 2015-03-24 Gary Benson <gbenson@redhat.com>
9624 * linux-x86-low.c (x86_linux_new_thread): Moved to
9626 (x86_linux_prepare_to_resume): Likewise.
9628 2015-03-24 Gary Benson <gbenson@redhat.com>
9630 * Makefile.in (x86-linux-dregs.o): New rule.
9631 * configure.srv: Add x86-linux-dregs.o to relevant targets.
9632 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
9633 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
9634 (x86_linux_dr_get): Likewise.
9635 (x86_linux_dr_set): Likewise.
9636 (update_debug_registers_callback): Likewise.
9637 (x86_linux_dr_set_addr): Likewise.
9638 (x86_linux_dr_get_addr): Likewise.
9639 (x86_linux_dr_set_control): Likewise.
9640 (x86_linux_dr_get_control): Likewise.
9641 (x86_linux_dr_get_status): Likewise.
9642 (x86_linux_update_debug_registers): Likewise.
9644 2015-03-24 Gary Benson <gbenson@redhat.com>
9646 * linux-x86-low.c (x86_linux_update_debug_registers):
9647 New function, factored out from...
9648 (x86_linux_prepare_to_resume): ...this.
9650 2015-03-24 Gary Benson <gbenson@redhat.com>
9652 * linux-x86-low.c (x86_linux_dr_get): Update comments.
9653 (x86_linux_dr_set): Likewise.
9654 (update_debug_registers_callback): Likewise.
9655 (x86_linux_dr_set_addr): Likewise.
9656 (x86_linux_dr_get_addr): Likewise.
9657 (x86_linux_dr_set_control): Likewise.
9658 (x86_linux_dr_get_control): Likewise.
9659 (x86_linux_dr_get_status): Likewise.
9660 (x86_linux_prepare_to_resume): Likewise.
9662 2015-03-24 Gary Benson <gbenson@redhat.com>
9664 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
9665 Use perror_with_name. Pass string through gettext.
9666 (x86_linux_dr_set): Likewise.
9668 2015-03-24 Gary Benson <gbenson@redhat.com>
9670 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
9671 (x86_linux_dr_set_addr): ...this.
9672 (x86_dr_low_get_addr): Rename to...
9673 (x86_linux_dr_get_addr): ...this.
9674 (x86_dr_low_set_control): Rename to...
9675 (x86_linux_dr_set_control): ...this.
9676 (x86_dr_low_get_control): Rename to...
9677 (x86_linux_dr_get_control): ...this.
9678 (x86_dr_low_get_status): Rename to...
9679 (x86_linux_dr_get_status): ...this.
9680 (x86_dr_low): Update with new function names.
9682 2015-03-24 Gary Benson <gbenson@redhat.com>
9684 * Makefile.in (x86-linux.o): New rule.
9685 * configure.srv: Add x86-linux.o to relevant targets.
9686 * linux-low.c (lwp_set_arch_private_info): New function.
9687 (lwp_arch_private_info): Likewise.
9688 * linux-x86-low.c: Include nat/x86-linux.h.
9689 (arch_lwp_info): Removed structure.
9690 (update_debug_registers_callback):
9691 Use lwp_set_debug_registers_changed.
9692 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
9693 and lwp_set_debug_registers_changed.
9694 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
9696 2015-03-24 Gary Benson <gbenson@redhat.com>
9698 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
9699 * linux-arm-low.c (arm_new_thread): Likewise.
9700 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
9701 * linux-mips-low.c (mips_linux_new_thread): Likewise.
9702 * linux-x86-low.c (x86_linux_new_thread): Likewise.
9703 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
9705 2015-03-24 Gary Benson <gbenson@redhat.com>
9707 * linux-low.c (ptid_of_lwp): New function.
9708 (lwp_is_stopped): Likewise.
9709 (lwp_stop_reason): Likewise.
9710 * linux-x86-low.c (update_debug_registers_callback):
9712 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
9715 2015-03-24 Gary Benson <gbenson@redhat.com>
9717 * linux-low.h (linux_stop_lwp): Remove declaration.
9719 2015-03-24 Gary Benson <gbenson@redhat.com>
9721 * linux-low.h: Include nat/linux-nat.h.
9722 * linux-low.c (iterate_over_lwps_args): New structure.
9723 (iterate_over_lwps_filter): New function.
9724 (iterate_over_lwps): Likewise.
9725 * linux-x86-low.c (update_debug_registers_callback):
9726 Update signature to what iterate_over_lwps expects.
9727 Remove PID check that iterate_over_lwps now performs.
9728 (x86_dr_low_set_addr): Use iterate_over_lwps.
9729 (x86_dr_low_set_control): Likewise.
9731 2015-03-24 Gary Benson <gbenson@redhat.com>
9733 * linux-x86-low.c (x86_debug_reg_state): New function.
9734 (x86_linux_prepare_to_resume): Use the above.
9736 2015-03-24 Gary Benson <gbenson@redhat.com>
9738 * linux-low.c (current_lwp_ptid): New function.
9739 * linux-x86-low.c: Include nat/linux-nat.h.
9740 (x86_dr_low_get_addr): Use current_lwp_ptid.
9741 (x86_dr_low_get_control): Likewise.
9742 (x86_dr_low_get_status): Likewise.
9744 2015-03-20 Pedro Alves <palves@redhat.com>
9746 * tracepoint.c (cmd_qtstatus): Make "str" const.
9748 2015-03-20 Pedro Alves <palves@redhat.com>
9750 * server.c (handle_general_set): Make "req_str" const.
9752 2015-03-19 Pedro Alves <palves@redhat.com>
9754 * linux-low.c (linux_resume_one_lwp): Rename to ...
9755 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
9756 instead call perror_with_name.
9757 (check_ptrace_stopped_lwp_gone): New function.
9758 (linux_resume_one_lwp): Reimplement as wrapper around
9759 linux_resume_one_lwp_throw that swallows errors if the LWP is
9762 2015-03-19 Pedro Alves <palves@redhat.com>
9764 * linux-low.c (count_events_callback, select_event_lwp_callback):
9765 No longer check whether the thread has resume_stop as last resume
9768 2015-03-19 Pedro Alves <palves@redhat.com>
9770 * linux-low.c (count_events_callback, select_event_lwp_callback):
9771 Use the lwp's status_pending_p field, not the thread's.
9773 2015-03-19 Pedro Alves <palves@redhat.com>
9775 * linux-low.c (select_event_lwp_callback): Update comments to
9776 no longer mention SIGTRAP.
9778 2015-03-18 Gary Benson <gbenson@redhat.com>
9780 * server.c (handle_query): Do not report vFile:fstat as supported.
9782 2015-03-11 Gary Benson <gbenson@redhat.com>
9784 * hostio.c (sys/types.h): New include.
9785 (sys/stat.h): Likewise.
9786 (common-remote-fileio.h): Likewise.
9787 (handle_fstat): New function.
9788 (handle_vFile): Handle vFile:fstat packets.
9790 2015-03-11 Gary Benson <gbenson@redhat.com>
9792 * configure.ac (AC_CHECK_MEMBERS): Add checks for
9793 struct stat.st_blocks and struct stat.st_blksize.
9794 * configure: Regenerate.
9795 * config.in: Likewise.
9796 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
9797 (OBS): Add common-remote-fileio.o.
9798 (common-remote-fileio.o): New rule.
9800 2015-03-09 Pedro Alves <palves@redhat.com>
9802 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
9803 'struct sockaddr' pointer in 'accept' call.
9805 2015-03-09 Pedro Alves <palves@redhat.com>
9808 2015-03-07 Pedro Alves <palves@redhat.com>
9809 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
9810 or <winsock2.h> here. Instead include "gdb_socket.h".
9811 (remote_open): Use union gdb_sockaddr_u.
9812 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
9813 or <winsock2.h> here. Instead include "gdb_socket.h".
9814 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
9815 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
9817 (init_named_socket, gdb_agent_helper_thread): Use union
9820 2015-03-07 Pedro Alves <palves@redhat.com>
9822 * configure.ac (build_warnings): Move
9823 -Wdeclaration-after-statement to the C-specific set.
9824 * configure: Regenerate.
9826 2015-03-07 Pedro Alves <palves@redhat.com>
9828 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
9829 or <winsock2.h> here. Instead include "gdb_socket.h".
9830 (remote_open): Use union gdb_sockaddr_u.
9831 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
9832 or <winsock2.h> here. Instead include "gdb_socket.h".
9833 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
9834 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
9836 (init_named_socket, gdb_agent_helper_thread): Use union
9839 2015-03-07 Pedro Alves <palves@redhat.com>
9841 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
9844 2015-03-06 Yao Qi <yao.qi@linaro.org>
9846 * linux-aarch64-low.c (aarch64_insert_point): Use
9847 show_debug_regs as a boolean.
9848 (aarch64_remove_point): Likewise.
9850 2015-03-05 Pedro Alves <palves@redhat.com>
9852 * lynx-low.c (lynx_target_ops): Install NULL hooks for
9853 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
9854 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
9855 * nto-low.c (nto_target_ops): Likewise.
9856 * spu-low.c (spu_target_ops): Likewise.
9857 * win32-low.c (win32_target_ops): Likewise.
9859 2015-03-04 Pedro Alves <palves@redhat.com>
9861 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
9862 Decide whether a breakpoint triggered based on the SIGTRAP's
9864 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
9865 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
9866 (linux_low_filter_event): Check for breakpoints before checking
9868 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
9870 (linux_stopped_by_sw_breakpoint)
9871 (linux_supports_stopped_by_sw_breakpoint)
9872 (linux_stopped_by_hw_breakpoint)
9873 (linux_supports_stopped_by_hw_breakpoint): New functions.
9874 (linux_target_ops): Install new target methods.
9876 2015-03-04 Pedro Alves <palves@redhat.com>
9878 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
9879 * server.c (swbreak_feature, hwbreak_feature): New globals.
9880 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
9881 (captured_main): Clear swbreak_feature and hwbreak_feature.
9882 * server.h (swbreak_feature, hwbreak_feature): Declare.
9883 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
9884 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
9885 supports_stopped_by_hw_breakpoint>: New fields.
9886 (target_supports_stopped_by_sw_breakpoint)
9887 (target_stopped_by_sw_breakpoint)
9888 (target_supports_stopped_by_hw_breakpoint)
9889 (target_stopped_by_hw_breakpoint): Declare.
9891 2015-03-04 Pedro Alves <palves@redhat.com>
9893 enum lwp_stop_reason -> enum target_stop_reason
9894 * linux-low.c (check_stopped_by_breakpoint): Adjust.
9895 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
9896 (linux_wait_1, stuck_in_jump_pad_callback)
9897 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
9898 (linux_stopped_by_watchpoint):
9899 * linux-low.h (enum lwp_stop_reason): Delete.
9900 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
9901 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
9903 2015-03-04 Yao Qi <yao.qi@linaro.org>
9905 * Makefile.in (SFILES): Add linux-aarch64-low.c.
9907 2015-03-03 Gary Benson <gbenson@redhat.com>
9909 * hostio.c (handle_vFile): Fix prefix lengths.
9911 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
9913 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
9916 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
9918 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
9919 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
9920 (clean): Add "rm -f" for above C files.
9921 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
9922 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
9923 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
9924 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
9925 * linux-s390-low.c (HWCAP_S390_VX): New macro.
9926 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
9927 (init_registers_s390x_vx_linux64)
9928 (init_registers_s390x_tevx_linux64)
9929 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
9930 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
9932 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
9933 (s390_store_vxrs_high): New functions.
9934 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
9936 (s390_arch_setup): Add logic for selecting one of the new target
9937 descriptions. Activate the new vector regsets if applicable.
9938 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
9939 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
9940 and init_registers_s390x_tevx_linux64.
9942 2015-03-01 Pedro Alves <palves@redhat.com>
9944 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
9947 2015-02-27 Pedro Alves <palves@redhat.com>
9949 * linux-x86-low.c (u_debugreg_offset): New function.
9950 (x86_linux_dr_get, x86_linux_dr_set): Use it.
9952 2015-02-27 Pedro Alves <palves@redhat.com>
9954 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
9955 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
9956 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
9957 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
9958 (ps_lsetfpregs, ps_getpid)
9959 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
9960 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
9961 (ps_lsetxregs, ps_plog): Declare.
9963 2015-02-27 Pedro Alves <palves@redhat.com>
9965 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
9966 IP_AGENT_EXPORT_FUNC.
9967 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
9968 IP_AGENT_EXPORT_FUNC.
9969 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
9970 (IP_AGENT_EXPORT): Delete.
9971 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
9972 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
9973 (gdb_trampoline_buffer_error, collecting, gdb_collect)
9974 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
9975 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
9976 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
9977 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
9978 (traceframe_read_count, traceframe_write_count)
9979 (traceframes_created, trace_state_variables, get_raw_reg)
9980 (get_trace_state_variable_value, set_trace_state_variable_value)
9981 (ust_loaded, helper_thread_id, cmd_buf): Use
9982 IPA_SYM_EXPORTED_NAME.
9983 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
9984 (tracepoints) Use IP_AGENT_EXPORT_VAR.
9985 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
9986 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
9987 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
9988 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
9989 EXTERN_C_PUSH/EXTERN_C_POP.
9990 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
9991 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
9992 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
9993 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
9994 (traceframe_write_count, traceframe_read_count)
9995 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
9996 (about_to_request_buffer_space, get_trace_state_variable_value)
9997 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
9998 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
9999 EXTERN_C_PUSH/EXTERN_C_POP.
10000 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
10001 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
10002 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
10003 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
10004 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
10005 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
10006 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
10007 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
10009 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
10010 (IP_AGENT_EXPORT_VAR_DECL): Define.
10011 (tracing): Declare.
10012 (gdb_agent_get_raw_reg): Declare.
10014 2015-02-27 Tom Tromey <tromey@redhat.com>
10015 Pedro Alves <palves@redhat.com>
10017 Rename symbols whose names are reserved C++ keywords throughout.
10019 2015-02-27 Pedro Alves <palves@redhat.com>
10021 * Makefile.in (COMPILER): New, get it from autoconf.
10022 (CXX): Get from autoconf instead.
10023 (COMPILE.pre): Use COMPILER.
10024 (CC-LD): Rename to ...
10025 (CC_LD): ... this. Use COMPILER.
10026 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
10027 (CXX_FOR_TARGET): Default to g++ instead of gcc.
10028 * acinclude.m4: Include build-with-cxx.m4.
10029 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
10030 Disable -Werror by default if building in C++ mode.
10031 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
10032 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
10033 the C++ compiler. Save/restore CXXFLAGS too.
10034 * configure: Regenerate.
10036 2015-02-27 Pedro Alves <palves@redhat.com>
10038 * acinclude.m4: Include libiberty.m4.
10039 * configure.ac: Call libiberty_INIT.
10040 * config.in, configure: Regenerate.
10042 2015-02-26 Pedro Alves <palves@redhat.com>
10044 * linux-low.c (linux_wait_1): When incrementing the PC past a
10045 program breakpoint always use the_low_target.breakpoint_len as
10046 increment, rather than the maximum between that and
10047 the_low_target.decr_pc_after_break.
10049 2015-02-23 Pedro Alves <palves@redhat.com>
10051 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
10052 thread was doing a step-over; always adjust the PC if
10053 we stepped over a permanent breakpoint.
10054 (linux_wait_1): If we stepped over breakpoint that was on top of a
10055 permanent breakpoint, manually advance the PC past it.
10057 2015-02-23 Pedro Alves <palves@redhat.com>
10059 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
10061 (x86_fill_gregset, x86_store_gregset): Use it when handling
10064 2015-02-20 Pedro Alves <palves@redhat.com>
10066 * thread-db.c: Include "nat/linux-procfs.h".
10067 (thread_db_init): Skip listing new threads if the kernel supports
10068 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
10070 2015-02-20 Pedro Alves <palves@redhat.com>
10072 * linux-low.c (status_pending_p_callback): Use ptid_match.
10074 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
10076 PR breakpoints/16812
10077 * linux-low.c (wstatus_maybe_breakpoint): Remove.
10078 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
10079 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
10081 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
10083 PR breakpoints/15956
10084 * tracepoint.c (cmd_qtinit): Add check for current_thread.
10086 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
10088 * linux-low.c (linux_low_btrace_conf): Print size.
10089 * server.c (handle_btrace_conf_general_set): New.
10090 (hanle_general_set): Call handle_btrace_conf_general_set.
10091 (handle_query): Report Qbtrace-conf:bts:size as supported.
10093 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
10095 * linux-low.c (linux_low_enable_btrace): Update parameters.
10096 (linux_low_btrace_conf): New.
10097 (linux_target_ops)<to_btrace_conf>: Initialize.
10098 * server.c (current_btrace_conf): New.
10099 (handle_btrace_enable): Rename to ...
10100 (handle_btrace_enable_bts): ... this. Pass ¤t_btrace_conf
10101 to target_enable_btrace. Update comment. Update users.
10102 (handle_qxfer_btrace_conf): New.
10103 (qxfer_packets): Add btrace-conf entry.
10104 (handle_query): Report qXfer:btrace-conf:read as supported packet.
10105 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
10106 (target_ops)<read_btrace_conf>: New.
10107 (target_enable_btrace): Update parameters.
10108 (target_read_btrace_conf): New.
10110 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
10112 * server.c (handle_btrace_general_set): Remove call to
10113 target_supports_btrace.
10114 (supported_btrace_packets): New.
10115 (handle_query): Call supported_btrace_packets.
10116 * target.h: include btrace-common.h.
10117 (btrace_target_info): Removed.
10118 (supports_btrace, target_supports_btrace): Update parameters.
10120 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
10122 * Makefile.in (SFILES): Add common/btrace-common.c.
10123 (OBS): Add common/btrace-common.o.
10124 (btrace-common.o): Add build rules.
10125 * linux-low: Include btrace-common.h.
10126 (linux_low_read_btrace): Use struct btrace_data. Call
10127 btrace_data_init and btrace_data_fini.
10129 2015-02-06 Pedro Alves <palves@redhat.com>
10131 * thread-db.c (find_new_threads_callback): Add debug output.
10133 2015-02-04 Pedro Alves <palves@redhat.com>
10135 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
10136 (resume_stopped_resumed_lwps): New function.
10137 (linux_wait_for_event_filtered): Use it.
10139 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
10141 * Makefile.in (SFILES): Add linux-personality.c.
10142 (linux-personality.o): New rule.
10143 * configure.srv (srv_linux_obj): Add linux-personality.o to the
10144 list of objects to be built.
10145 * linux-low.c: Include nat/linux-personality.h.
10146 (linux_create_inferior): Remove code to disable address space
10147 randomization (moved to ../nat/linux-personality.c). Create
10148 cleanup to disable address space randomization.
10150 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
10152 * Makefile.in (posix-strerror.o): New rule.
10153 (mingw-strerror.o): Likewise.
10154 * configure: Regenerated.
10155 * configure.ac: Source file ../common/common.host. Initialize new
10156 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
10158 2015-01-14 Yao Qi <yao@codesourcery.com>
10160 * Makefile.in (SFILES): Add nat/ppc-linux.c.
10161 (ppc-linux.o): New rule.
10162 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
10163 * configure.ac: AC_CHECK_FUNCS(getauxval).
10164 * config.in: Re-generated.
10165 * configure: Re-generated.
10166 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
10167 ppc64_64bit_inferior_p
10169 2015-01-14 Yao Qi <yao@codesourcery.com>
10171 * linux-ppc-low.c: Include "nat/ppc-linux.h".
10172 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
10173 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
10174 (PT_ORIG_R3, PT_TRAP): Likewise.
10175 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
10176 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
10177 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
10179 2015-01-10 Joel Brobecker <brobecker@adacore.com>
10181 * i387-fp.c (i387_cache_to_xsave): In look over
10182 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
10183 zmmh_low_space field by use of zmmh_high_space.
10185 2015-01-09 Pedro Alves <palves@redhat.com>
10187 * linux-low.c (step_over_bkpt): Move higher up in the file.
10188 (handle_extended_wait): Don't store the stop_pc here.
10189 (get_stop_pc): Adjust comments and rename to ...
10190 (check_stopped_by_breakpoint): ... this. Record whether the LWP
10191 stopped for a software breakpoint or hardware breakpoint.
10192 (thread_still_has_status_pending_p): New function.
10193 (status_pending_p_callback): Use
10194 thread_still_has_status_pending_p. If the event is no longer
10195 interesting, resume the LWP.
10196 (handle_tracepoints): Add assert.
10197 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
10198 (wstatus_maybe_breakpoint): New function.
10199 (cancel_breakpoint): Delete function.
10200 (check_stopped_by_watchpoint): New function, factored out from
10201 linux_low_filter_event.
10202 (lp_status_maybe_breakpoint): Delete function.
10203 (linux_low_filter_event): Remove filter_ptid argument.
10204 Leave thread group exits pending here. Store the LWP's stop PC.
10205 Always leave events pending.
10206 (linux_wait_for_event_filtered): Pull all events out of the
10207 kernel, and leave them all pending.
10208 (count_events_callback, select_event_lwp_callback): Consider all
10210 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
10211 (select_event_lwp): Only give preference to the stepping LWP in
10212 all-stop mode. Adjust comments.
10213 (ignore_event): New function.
10214 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
10215 references to cancel_breakpoints. Adjust to renames. Also give
10216 equal priority to all LWPs that have had events in non-stop mode.
10217 If reporting a software breakpoint event, unadjust the LWP's PC.
10218 (linux_wait): If linux_wait_1 returned an ignored event, retry.
10219 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
10221 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
10222 (resume_status_pending_p): Use thread_still_has_status_pending_p.
10223 (linux_stopped_by_watchpoint): Adjust.
10224 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
10225 * linux-low.h (enum lwp_stop_reason): New.
10226 (struct lwp_info) <stop_pc>: Adjust comment.
10227 <stopped_by_watchpoint>: Delete field.
10228 <stop_reason>: New field.
10229 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
10230 * mem-break.c (software_breakpoint_inserted_here)
10231 (hardware_breakpoint_inserted_here): New function.
10232 * mem-break.h (software_breakpoint_inserted_here)
10233 (hardware_breakpoint_inserted_here): Declare.
10234 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
10235 (cancel_breakpoints): Delete.
10236 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
10237 (upload_fast_traceframes): Remove references to
10238 cancel_breakpoints.
10240 2015-01-09 Pedro Alves <palves@redhat.com>
10242 * thread-db.c (find_new_threads_callback): Ignore thread if the
10243 kernel thread ID is -1.
10245 2015-01-09 Pedro Alves <palves@redhat.com>
10247 * linux-low.c (linux_attach_fail_reason_string): Move to
10248 nat/linux-ptrace.c, and rename.
10249 (linux_attach_lwp): Update comment.
10250 (attach_proc_task_lwp_callback): New function.
10251 (linux_attach): Adjust to rename and use
10252 linux_proc_attach_tgid_threads.
10253 (linux_attach_fail_reason_string): Delete declaration.
10255 2015-01-01 Joel Brobecker <brobecker@adacore.com>
10257 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
10258 * server.c (gdbserver_version): Likewise.
10260 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
10262 * remote-utils.c: Include ctype.h.
10263 (input_interrupt): Explicitly handle the case when the char
10264 received is the NUL byte. Improve the printing of non-ASCII
10267 2014-12-16 Joel Brobecker <brobecker@adacore.com>
10269 * linux-low.c (linux_low_filter_event): Update call to
10270 linux_enable_event_reporting following the addition of
10271 a new parameter to that function.
10273 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
10276 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
10277 (AARCH64_FPCR_REGNO): Likewise.
10278 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
10279 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
10280 (aarch64_store_fpregset): Likewise.
10282 2014-12-15 Joel Brobecker <brobecker@adacore.com>
10284 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
10285 Remove FIXME comment about assumption about N.
10287 2014-12-13 Joel Brobecker <brobecker@adacore.com>
10289 * configure.ac: If large-file support is disabled in GDBserver,
10290 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
10291 * configure: Regenerate.
10293 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
10295 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
10296 warning upon ENODATA from ptrace.
10297 * linux-s390-low.c (s390_store_tdb): New.
10298 (s390_regsets): Add regset for NT_S390_TDB.
10300 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
10302 * linux-low.c (regsets_store_inferior_registers): Skip regsets
10303 without a fill_function.
10304 * linux-s390-low.c (s390_fill_last_break): Remove.
10305 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
10306 (s390_arch_setup): Use regset's size instead of fill_function for
10307 loop end condition.
10309 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
10311 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
10312 the regset's store function when ptrace returned an error.
10313 * regcache.c (get_thread_regcache): Invalidate register cache
10314 before fetching inferior's registers.
10316 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
10318 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
10319 while-loop as for-loop.
10320 (regsets_store_inferior_registers): Likewise.
10322 2014-11-28 Yao Qi <yao@codesourcery.com>
10324 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
10325 * config.in, configure: Re-generate.
10326 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
10329 2014-11-21 Yao Qi <yao@codesourcery.com>
10331 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
10332 (AC_CHECK_HEADERS): Remove malloc.h.
10333 * configure: Re-generated.
10334 * config.in: Re-generated.
10335 * server.h: Don't include alloca.h and malloc.h.
10336 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
10337 Don't include malloc.h.
10339 2014-11-17 Joel Brobecker <brobecker@adacore.com>
10341 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
10342 corresponding ERRNO check in same block.
10344 2014-11-12 Pedro Alves <palves@redhat.com>
10346 * server.c (cont_thread): Update comment.
10347 (start_inferior, attach_inferior): No longer clear cont_thread.
10348 (handle_v_cont): No longer set cont_thread.
10349 (captured_main): Clear cont_thread each time a GDB connects.
10351 2014-11-12 Pedro Alves <palves@redhat.com>
10353 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
10354 thread, and don't resume all threads if the Hc thread has exited.
10356 2014-11-12 Pedro Alves <palves@redhat.com>
10358 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
10359 the process group instead of to a specific LWP.
10361 2014-10-15 Pedro Alves <palves@redhat.com>
10364 * win32-arm-low.c (arm_set_thread_context): Remove current_event
10366 (arm_set_thread_context): Delete.
10367 (the_low_target): Adjust.
10368 * win32-i386-low.c (debug_registers_changed)
10369 (debug_registers_used): Delete.
10370 (update_debug_registers_callback): New function.
10371 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
10372 needing to update their debug registers.
10373 (win32_get_current_dr): New function.
10374 (x86_dr_low_get_addr, x86_dr_low_get_control)
10375 (x86_dr_low_get_status): Fetch the debug register from the thread
10377 (i386_initial_stuff): Adjust.
10378 (i386_get_thread_context): Remove current_event parameter. Don't
10379 clear debug_registers_changed nor copy DR values to
10381 (i386_set_thread_context): Delete.
10382 (i386_prepare_to_resume): New function.
10383 (i386_thread_added): Mark the thread as needing to update irs
10385 (the_low_target): Remove i386_set_thread_context and install
10386 i386_prepare_to_resume.
10387 * win32-low.c (win32_get_thread_context): Adjust.
10388 (win32_set_thread_context): Use SetThreadContext
10390 (win32_prepare_to_resume): New function.
10391 (win32_require_context): New function, factored out from ...
10392 (thread_rec): ... this.
10393 (continue_one_thread): Call win32_prepare_to_resume on each thread
10394 we're about to continue.
10395 (win32_resume): Call win32_prepare_to_resume on the event thread.
10396 * win32-low.h (struct win32_thread_info)
10397 <debug_registers_changed>: New field.
10398 (struct win32_target_ops): Change prototype of set_thread_context,
10399 delete set_thread_context and add prepare_to_resume.
10400 (win32_require_context): New declaration.
10402 2014-10-08 Gary Benson <gbenson@redhat.com>
10404 * server.h: Do not include common-exceptions.h.
10406 2014-10-08 Gary Benson <gbenson@redhat.com>
10408 * server.h: Do not include cleanups.h.
10410 2014-09-30 James Hogan <james.hogan@imgtec.com>
10412 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
10413 mips64-dsp-linux.c.
10415 2014-09-23 Yao Qi <yao@codesourcery.com>
10417 * linux-low.c (lp_status_maybe_breakpoint): New function.
10418 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
10419 (count_events_callback): Likewise.
10420 (select_event_lwp_callback): Likewise.
10421 (cancel_breakpoints_callback): Likewise.
10423 2014-09-19 Don Breazeal <donb@codesourcery.com>
10425 * linux-low.c (handle_extended_wait): Call
10426 linux_ptrace_get_extended_event.
10427 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
10428 linux_is_extended_waitstatus.
10430 2014-09-16 Joel Brobecker <brobecker@adacore.com>
10432 * Makefile.in (CPPFLAGS): Define.
10433 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
10434 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
10436 2014-09-16 Gary Benson <gbenson@redhat.com>
10438 * inferiors.h (current_inferior): Renamed as...
10439 (current_thread): New variable. All uses updated.
10440 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
10441 (maybe_move_out_of_jump_pad): Likewise.
10442 (cancel_breakpoint): Likewise.
10443 (linux_low_filter_event): Likewise.
10444 (wait_for_sigstop): Likewise.
10445 (linux_resume_one_lwp): Likewise.
10446 (need_step_over_p): Likewise.
10447 (start_step_over): Likewise.
10448 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
10449 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
10450 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
10451 and save_inferior as saved_thread.
10452 * regcache.c (get_thread_regcache): Renamed saved_inferior as
10454 (regcache_invalidate_thread): Likewise.
10455 * remote-utils.c (prepare_resume_reply): Likewise.
10456 * thread-db.c (thread_db_get_tls_address): Likewise.
10457 (disable_thread_event_reporting): Likewise.
10458 (remove_thread_event_breakpoints): Likewise.
10459 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
10461 * target.h (set_desired_inferior): Renamed as...
10462 (set_desired_thread): New declaration. All uses updated.
10463 * server.c (myresume): Updated comment to reference thread instead
10465 (handle_serial_event): Likewise.
10466 (handle_target_event): Likewise.
10468 2014-09-12 Tom Tromey <tromey@redhat.com>
10469 Gary Benson <gbenson@redhat.com>
10471 * regcache.h: Include common-regcache.h.
10472 (regcache_read_pc): Don't declare.
10473 * regcache.c (get_thread_regcache_for_ptid): New function.
10475 2014-09-11 Tom Tromey <tromey@redhat.com>
10476 Gary Benson <gbenson@redhat.com>
10478 * symbol.c: New file.
10479 * Makefile.in (SFILES): Add symbol.c.
10480 (OBS): Add symbol.o.
10482 2014-09-11 Gary Benson <gbenson@redhat.com>
10484 * target.c (target_stop_ptid, target_continue_ptid): New
10487 2014-09-11 Tom Tromey <tromey@redhat.com>
10488 Gary Benson <gbenson@redhat.com>
10490 * target.h: Include target/target.h.
10491 * target.c (target_read_memory, target_read_uint32)
10492 (target_write_memory): New functions.
10494 2014-09-11 Gary Benson <gbenson@redhat.com>
10496 * server.h (debug_hw_points): Don't declare.
10497 * server.c (debug_hw_points): Don't define. Replace all uses
10498 with show_debug_regs.
10499 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
10500 all uses with show_debug_regs.
10502 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
10504 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
10505 endianness into account.
10506 (ppc_supply_ptrace_register): Likewise.
10508 2014-09-03 James Hogan <james.hogan@imgtec.com>
10510 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
10511 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
10513 2014-09-03 Gary Benson <gbenson@redhat.com>
10515 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
10516 ALL_DEBUG_ADDRESS_REGISTERS.
10518 2014-09-02 Gary Benson <gbenson@redhat.com>
10520 * i386-low.h: Renamed as...
10521 * x86-low.h: New file. All type, function and variable name
10522 prefixes changed from "i386_" to "x86_". All references updated.
10523 * i386-low.c: Renamed as...
10524 * x86-low.c: New file. All type, function and variable name
10525 prefixes changed from "i386_" to "x86_". All references updated.
10527 2014-09-02 Gary Benson <gbenson@redhat.com>
10529 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
10530 (x86_linux_new_thread): Likewise.
10532 2014-08-29 Gary Benson <gbenson@redhat.com>
10534 * server.h (setjmp.h): Do not include.
10535 (toplevel): Do not declare.
10536 (common-exceptions.h): Include.
10537 (cleanups.h): Likewise.
10538 * server.c (toplevel): Do not define.
10539 (exit_code): New static global.
10540 (detach_or_kill_for_exit_cleanup): New function.
10541 (main): New function. Original main renamed to...
10542 (captured_main): New function.
10543 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
10545 2014-08-29 Gary Benson <gbenson@redhat.com>
10547 * Makefile.in (SFILES): Add common/common-exceptions.c.
10548 (OBS): Add common-exceptions.o.
10549 (common-exceptions.o): New rule.
10550 * utils.c (prepare_to_throw_exception): New function.
10552 2014-08-29 Gary Benson <gbenson@redhat.com>
10554 * config.in: Regenerate.
10555 * configure: Likewise.
10557 2014-08-29 Gary Benson <gbenson@redhat.com>
10559 * Makefile.in (SFILES): Add common/cleanups.c.
10561 (cleanups.o): New rule.
10563 2014-08-29 Gary Benson <gbenson@redhat.com>
10565 * utils.c (internal_vwarning): New function.
10567 2014-08-28 Gary Benson <gbenson@redhat.com>
10569 * utils.h (fatal): Remove declaration.
10570 * utils.c (fatal): Remove function.
10572 2014-08-28 Gary Benson <gbenson@redhat.com>
10574 * tracepoint.c (gdb_agent_init): Replace fatal with
10576 (initialize_tracepoint): Likewise.
10578 2014-08-28 Gary Benson <gbenson@redhat.com>
10580 * remote-utils.c (remote_prepare): Replace fatal with error.
10582 2014-08-28 Gary Benson <gbenson@redhat.com>
10584 * linux-low.c (linux_async): Replace fatal with warning.
10585 Tidy up and return.
10586 (linux_start_non_stop): Return -1 if linux_async failed.
10588 2014-08-28 Gary Benson <gbenson@redhat.com>
10590 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
10592 (i386_dr_low_get_addr): Remove vague comment.
10593 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
10596 2014-08-28 Gary Benson <gbenson@redhat.com>
10598 * inferiors.c (get_thread_process): Replace check with gdb_assert.
10599 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
10601 (linux_resume_one_lwp): Likewise.
10602 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
10604 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
10605 with internal_error.
10606 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
10607 (init_register_cache): Replace fatal with gdb_assert_not_reached.
10608 (find_register_by_name): Replace fatal with internal_error.
10609 (find_regno): Likewise.
10610 * tdesc.c (init_target_desc): Replace check with gdb_assert.
10611 * thread-db.c (thread_db_create_event): Likewise.
10612 (thread_db_load_search): Likewise.
10613 (try_thread_db_load_1): Likewise.
10614 * tracepoint.c (get_jump_space_head): Replace fatal with
10616 (claim_trampoline_space): Likewise.
10617 (have_fast_tracepoint_trampoline_buffer): Likewise.
10618 (cmd_qtstart): Likewise.
10619 (stop_tracing): Likewise.
10620 (fast_tracepoint_collecting): Likewise.
10621 (target_malloc): Likewise.
10622 (download_tracepoint): Likewise.
10623 (download_trace_state_variables): Replace check with gdb_assert.
10624 (upload_fast_traceframes): Replace fatal with internal_error.
10626 2014-08-19 Tom Tromey <tromey@redhat.com>
10627 Gary Benson <gbenson@redhat.com>
10629 * Makefile.in (SFILES): Add common/common-debug.c.
10630 (OBS): Add common-debug.o.
10631 (common-debug.o): New rule.
10632 * debug.h (debug_printf): Don't declare.
10633 * debug.c (debug_printf): Renamed and rewritten as...
10634 (debug_vprintf): New function.
10636 2014-08-19 Gary Benson <gbenson@redhat.com>
10638 * utils.h: Do not include print-utils.h.
10640 2014-08-19 Tom Tromey <tromey@redhat.com>
10641 Gary Benson <gbenson@redhat.com>
10643 * server.h: Add static assertion.
10644 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
10646 2014-08-19 Tom Tromey <tromey@redhat.com>
10647 Gary Benson <gbenson@redhat.com>
10649 * Makefile.in (SFILES): Add common/errors.c.
10650 (OBS): Add errors.o.
10651 (IPA_OBS): Add errors-ipa.o.
10652 (errors.o): New rule.
10653 (errors-ipa.o): Likewise.
10654 * utils.h (perror_with_name, error, warning): Don't declare.
10655 * utils.c (warning): Renamed and rewritten as...
10656 (vwarning): New function.
10657 (error): Renamed and rewritten as...
10658 (verror): New function.
10659 (internal_error): Renamed and rewritten as...
10660 (internal_verror): New function.
10662 2014-08-07 Gary Benson <gbenson@redhat.com>
10664 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
10665 * configure: Regenerate.
10666 * config.in: Likewise.
10667 * server.h: Do not include errno.h.
10668 * event-loop.c: Likewise.
10669 * hostio-errno.c: Likewise.
10670 * linux-low.c: Likewise.
10671 * remote-utils.c: Likewise.
10672 * spu-low.c: Likewise.
10673 * utils.c: Likewise.
10674 * gdbreplay.c: Unconditionally include errno.h.
10676 2014-08-07 Gary Benson <gbenson@redhat.com>
10678 * server.h: Do not include string.h.
10679 * event-loop.c: Likewise.
10680 * linux-low.c: Likewise.
10681 * regcache.c: Likewise.
10682 * remote-utils.c: Likewise.
10683 * spu-low.c: Likewise.
10684 * utils.c: Likewise.
10686 2014-08-07 Gary Benson <gbenson@redhat.com>
10688 * server.h: Do not include gdb_assert.h.
10690 2014-08-07 Gary Benson <gbenson@redhat.com>
10692 * server.h: Do not include common-utils.h.
10694 2014-08-07 Gary Benson <gbenson@redhat.com>
10696 * server.h: Do not include ptid.h.
10697 * notif.h: Likewise.
10699 2014-08-07 Gary Benson <gbenson@redhat.com>
10701 * server.h: Do not include gdb_locale.h.
10703 2014-08-07 Gary Benson <gbenson@redhat.com>
10705 * server.h: Do not include gdb/signals.h.
10706 * win32-low.c: Likewise.
10708 2014-08-07 Gary Benson <gbenson@redhat.com>
10710 * server.h: Do not include pathmax.h.
10712 2014-08-07 Gary Benson <gbenson@redhat.com>
10714 * server.h: Do not include libiberty.h.
10715 * linux-bfin-low.c: Likewise.
10717 2014-08-07 Gary Benson <gbenson@redhat.com>
10719 * server.h: Do not include ansidecl.h.
10721 2014-08-07 Gary Benson <gbenson@redhat.com>
10723 * linux-x86-low.c: Do not include stddef.h.
10724 * lynx-ppc-low.c: Likewise.
10725 * tracepoint.c: Likewise.
10727 2014-08-07 Gary Benson <gbenson@redhat.com>
10729 * server.h: Do not include stdarg.h.
10730 * nto-low.c: Likewise.
10732 2014-08-07 Gary Benson <gbenson@redhat.com>
10734 * server.h: Do not include stdlib.h.
10735 * inferiors.c: Likewise.
10736 * linux-low.c: Likewise.
10737 * regcache.c: Likewise.
10738 * spu-low.c: Likewise.
10739 * tracepoint.c: Likewise.
10740 * utils.c: Likewise.
10742 2014-08-07 Gary Benson <gbenson@redhat.com>
10744 * server.h: Do not include stdio.h.
10745 * linux-low.c: Likewise.
10746 * remote-utils.c: Likewise.
10747 * spu-low.c: Likewise.
10748 * utils.c: Likewise.
10749 * wincecompat.c: Likewise.
10751 2014-08-06 Gary Benson <gbenson@redhat.com>
10753 * regcache.c (init_register_cache): Move conditionals inside if.
10755 2014-08-06 Gary Benson <gbenson@redhat.com>
10757 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
10759 2014-07-31 Gary Benson <gbenson@redhat.com>
10761 * ax.h: Do not include server.h.
10762 * gdbthread.h: Likewise.
10763 * lynx-low.h: Likewise.
10764 * notif.h: Likewise.
10766 2014-07-30 Gary Benson <gbenson@redhat.com>
10768 * server.h: Include common-defs.h.
10769 Do not include config.h or build-gnulib-gdbserver/config.h.
10771 2014-07-30 Gary Benson <gbenson@redhat.com>
10773 * hostio-errno.c: Move server.h to top of includes list.
10774 * inferiors.c: Likewise.
10775 * linux-x86-low.c: Likewise.
10776 * notif.c: Include server.h.
10778 2014-07-24 Tom Tromey <tromey@redhat.com>
10779 Gary Benson <gbenson@redhat.com>
10781 * server.h (CORE_ADDR): Now unsigned.
10783 2014-07-16 Pedro Alves <palves@redhat.com>
10785 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
10787 2014-07-15 Pedro Alves <palves@redhat.com>
10789 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
10792 2014-07-11 Pedro Alves <palves@redhat.com>
10794 * linux-low.c (kill_wait_lwp): New function, based on
10795 kill_one_lwp_callback, but use my_waitpid directly.
10796 (kill_one_lwp_callback, linux_kill): Use it.
10798 2014-06-23 Pedro Alves <palves@redhat.com>
10800 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
10801 before setting DR0..DR3.
10803 2014-06-20 Gary Benson <gbenson@redhat.com>
10805 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
10806 * configure: Regenerated.
10807 * config.in: Likewise.
10809 2014-06-20 Gary Benson <gbenson@redhat.com>
10811 * Makefile.in (SFILES): Update locations for files moved
10812 from common to nat.
10813 (object file files): Reordered.
10815 2014-06-20 Gary Benson <gbenson@redhat.com>
10817 * i386-low.h (i386_dr_low_can_set_addr): Removed.
10818 (i386_dr_low_set_addr): Likewise.
10819 (i386_dr_low_get_addr): Likewise.
10820 (i386_dr_low_can_set_control): Likewise.
10821 (i386_dr_low_set_control): Likewise.
10822 (i386_dr_low_get_control): Likewise.
10823 (i386_dr_low_get_status): Likewise.
10824 (i386_get_debug_register_length): Likewise.
10825 * linux-x86-low.c (i386_dr_low_set_addr):
10826 Changed signature. Made static.
10827 (i386_dr_low_get_addr): Likewise.
10828 (i386_dr_low_set_control): Likewise.
10829 (i386_dr_low_get_control): Likewise.
10830 (i386_dr_low_get_status): Likewise.
10831 (i386_dr_low): New global variable.
10832 * win32-i386-low.c (i386_dr_low_set_addr):
10833 Changed signature. Made static.
10834 (i386_dr_low_get_addr): Likewise.
10835 (i386_dr_low_set_control): Likewise.
10836 (i386_dr_low_get_control): Likewise.
10837 (i386_dr_low_get_status): Likewise.
10838 (i386_dr_low): New global variable.
10840 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
10842 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
10843 * Makefile.in (AR, AR_FLAGS): Define.
10844 * configure: Regenerate.
10846 2014-06-19 Gary Benson <gbenson@redhat.com>
10848 * Makefile.in (i386-dregs.o): New rule.
10849 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
10850 * i386-low.c (target.h): Remove include.
10851 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
10852 (DR_CONTROL_SHIFT): Likewise.
10853 (DR_CONTROL_SIZE): Likewise.
10854 (DR_RW_EXECUTE): Likewise.
10855 (DR_RW_WRITE): Likewise.
10856 (DR_RW_READ): Likewise.
10857 (DR_RW_IORW): Likewise.
10858 (DR_LEN_1): Likewise.
10859 (DR_LEN_2): Likewise.
10860 (DR_LEN_4): Likewise.
10861 (DR_LEN_8): Likewise.
10862 (DR_LOCAL_ENABLE_SHIFT): Likewise.
10863 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
10864 (DR_ENABLE_SIZE): Likewise.
10865 (DR_LOCAL_SLOWDOWN): Likewise.
10866 (DR_GLOBAL_SLOWDOWN): Likewise.
10867 (DR_CONTROL_RESERVED): Likewise.
10868 (I386_DR_CONTROL_MASK): Likewise.
10869 (I386_DR_VACANT): Likewise.
10870 (I386_DR_LOCAL_ENABLE): Likewise.
10871 (I386_DR_GLOBAL_ENABLE): Likewise.
10872 (I386_DR_DISABLE): Likewise.
10873 (I386_DR_SET_RW_LEN): Likewise.
10874 (I386_DR_GET_RW_LEN): Likewise.
10875 (I386_DR_WATCH_HIT): Likewise.
10876 (i386_wp_op_t): Likewise.
10877 (i386_show_dr): Likewise.
10878 (i386_length_and_rw_bits): Likewise.
10879 (i386_insert_aligned_watchpoint): Likewise.
10880 (i386_remove_aligned_watchpoint): Likewise.
10881 (i386_handle_nonaligned_watchpoint): Likewise.
10882 i386_update_inferior_debug_regs(): Likewise.
10883 (i386_dr_insert_watchpoint): Likewise.
10884 (i386_dr_remove_watchpoint): Likewise.
10885 (i386_dr_region_ok_for_watchpoint): Likewise.
10886 (i386_dr_stopped_data_address): Likewise.
10887 (i386_dr_stopped_by_watchpoint): Likewise.
10889 2014-06-19 Gary Benson <gbenson@redhat.com>
10891 * i386-low.c (i386_dr_show): Renamed to
10892 i386_show_dr and made static. All uses updated.
10893 (i386_dr_length_and_rw_bits): Renamed to
10894 i386_length_and_rw_bits and made static.
10896 (i386_dr_insert_aligned_watchpoint): Renamed to
10897 i386_insert_aligned_watchpoint and made static.
10899 (i386_dr_remove_aligned_watchpoint): Renamed to
10900 i386_remove_aligned_watchpoint and made static.
10902 (i386_dr_update_inferior_debug_regs): Renamed to
10903 i386_update_inferior_debug_regs and made static.
10906 2014-06-18 Gary Benson <gbenson@redhat.com>
10908 * i386-low.h (i386_dr_low_can_set_addr): New macro.
10909 (i386_dr_low_can_set_control): Likewise.
10910 (i386_get_debug_register_length): Likewise.
10911 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
10912 (i386_dr_low_can_set_control): Likewise.
10913 (i386_get_debug_register_length): Likewise.
10915 2014-06-17 Gary Benson <gbenson@redhat.com>
10917 * i386-low.h (i386-dregs.h): New include.
10918 (DR_FIRSTADDR): Now in i386-dregs.h.
10919 (DR_LASTADDR): Likewise.
10920 (DR_NADDR): Likewise.
10921 (DR_STATUS): Likewise.
10922 (DR_CONTROL): Likewise.
10923 (i386_debug_reg_state): Likewise.
10924 (i386_dr_insert_watchpoint): Likewise.
10925 (i386_dr_remove_watchpoint): Likewise.
10926 (i386_dr_region_ok_for_watchpoint): Likewise.
10927 (i386_dr_stopped_data_address): Likewise.
10928 (i386_dr_stopped_by_watchpoint): Likewise.
10929 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
10931 2014-06-18 Gary Benson <gbenson@redhat.com>
10933 * i386-low.h (i386_low_insert_watchpoint): Renamed to
10934 i386_dr_insert_watchpoint.
10935 (i386_low_remove_watchpoint): Renamed to
10936 i386_dr_remove_watchpoint.
10937 (i386_low_region_ok_for_watchpoint): Renamed to
10938 i386_dr_region_ok_for_watchpoint.
10939 (i386_low_stopped_data_address): Renamed to
10940 i386_dr_stopped_data_address.
10941 (i386_low_stopped_by_watchpoint): Renamed to
10942 i386_dr_stopped_by_watchpoint.
10943 * i386-low.c (i386_show_dr): Renamed to
10944 i386_dr_show and made nonstatic. All uses updated.
10945 (i386_length_and_rw_bits): Renamed to
10946 i386_dr_length_and_rw_bits and made nonstatic.
10948 (i386_insert_aligned_watchpoint): Renamed to
10949 i386_dr_insert_aligned_watchpoint and made nonstatic.
10951 (i386_remove_aligned_watchpoint): Renamed to
10952 i386_dr_remove_aligned_watchpoint and made nonstatic.
10954 (i386_update_inferior_debug_regs): Renamed to
10955 i386_dr_update_inferior_debug_regs and made nonstatic.
10957 (i386_low_insert_watchpoint): Renamed to
10958 i386_dr_insert_watchpoint. All uses updated.
10959 (i386_low_remove_watchpoint): Renamed to
10960 i386_dr_remove_watchpoint. All uses updated.
10961 (i386_low_region_ok_for_watchpoint): Renamed to
10962 i386_dr_region_ok_for_watchpoint. All uses updated.
10963 (i386_low_stopped_data_address): Renamed to
10964 i386_dr_stopped_data_address. All uses updated.
10965 (i386_low_stopped_by_watchpoint): Renamed to
10966 i386_dr_stopped_by_watchpoint. All uses updated.
10968 2014-06-18 Gary Benson <gbenson@redhat.com>
10970 * i386-low.c (i386_dr_low_can_set_addr): New macro.
10971 (i386_dr_low_can_set_control): Likewise.
10972 (i386_insert_aligned_watchpoint): New check.
10974 2014-06-18 Gary Benson <gbenson@redhat.com>
10976 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
10979 2014-06-18 Gary Benson <gbenson@redhat.com>
10981 * i386-low.c (i386_length_and_rw_bits): Use internal_error
10982 instead of fatal and error.
10983 (i386_handle_nonaligned_watchpoint): Likewise.
10985 2014-06-18 Gary Benson <gbenson@redhat.com>
10987 * i386-low.c (i386_get_debug_register_length): New macro.
10988 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
10989 (i386_show_dr): Use debug_printf instead of fprintf. Use
10990 phex to format values.
10992 2014-06-18 Gary Benson <gbenson@redhat.com>
10994 * i386-low.h: Comment changes.
10995 * i386-low.c: Likewise.
10997 2014-06-18 Gary Benson <gbenson@redhat.com>
10999 * i386-low.c: Whitespace changes.
11001 2014-06-12 Tom Tromey <tromey@redhat.com>
11003 * utils.c (freeargv): Remove.
11005 2014-06-12 Tom Tromey <tromey@redhat.com>
11007 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
11008 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
11009 (parse_debug_format_options): Likewise.
11010 (gdbserver_usage): Likewise.
11011 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
11012 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
11013 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
11015 ($(LIBGNU)): Depend on libiberty.
11016 (all-lib): Recurse into all subdirs.
11017 (install-only): Invoke "install" target in subdirs.
11018 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
11020 * configure: Rebuild.
11021 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
11022 for vasprintf, vsnprintf, or gettimeofday.
11023 * configure.srv: Don't add safe-ctype.o or lbasename.o to
11026 2014-06-05 Joel Brobecker <brobecker@adacore.com>
11028 * development.sh: Delete.
11029 * Makefile.in (config.status): Adjust dependency on development.sh.
11030 * configure.ac: Adjust development.sh source call.
11031 * configure: Regenerate.
11033 2014-06-02 Pedro Alves <palves@redhat.com>
11035 * ax.c (gdb_free_agent_expr): New function.
11036 * ax.h (gdb_free_agent_expr): New declaration.
11037 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
11039 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
11041 (clear_breakpoint_conditions_and_commands): New function.
11042 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
11043 (clear_breakpoint_conditions_and_commands): New declaration.
11045 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
11047 * linux-aarch64-low.c (asm/ptrace.h): Include.
11049 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
11051 Fix TLS access for -static -pthread.
11052 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
11053 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
11054 (thread_db_load_search, try_thread_db_load_1): Initialize it.
11056 2014-05-20 Pedro Alves <palves@redhat.com>
11058 * linux-aarch64-low.c (aarch64_insert_point)
11059 (aarch64_remove_point): No longer check whether the type is
11060 supported here. Adjust to new interface.
11061 (the_low_target): Install aarch64_supports_z_point_type as
11062 supports_z_point_type method.
11063 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
11064 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
11065 instead of a Z packet char. Adjust.
11066 (arm_supports_z_point_type): New function.
11067 (arm_insert_point, arm_remove_point): Adjust to new interface.
11068 (the_low_target): Install arm_supports_z_point_type.
11069 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
11070 (cris_insert_point, cris_remove_point): Adjust to new interface.
11071 Don't check whether the type is supported here.
11072 (the_low_target): Install cris_supports_z_point_type.
11073 * linux-low.c (linux_supports_z_point_type): New function.
11074 (linux_insert_point, linux_remove_point): Adjust to new interface.
11075 * linux-low.h (struct linux_target_ops) <insert_point,
11076 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
11077 raw_breakpoint pointer parameter.
11078 <supports_z_point_type>: New method.
11079 * linux-mips-low.c (mips_supports_z_point_type): New function.
11080 (mips_insert_point, mips_remove_point): Adjust to new interface.
11081 Use mips_supports_z_point_type.
11082 (the_low_target): Install mips_supports_z_point_type.
11083 * linux-ppc-low.c (the_low_target): Install NULL as
11084 supports_z_point_type method.
11085 * linux-s390-low.c (the_low_target): Install NULL as
11086 supports_z_point_type method.
11087 * linux-sparc-low.c (the_low_target): Install NULL as
11088 supports_z_point_type method.
11089 * linux-x86-low.c (x86_supports_z_point_type): New function.
11090 (x86_insert_point): Adjust to new insert_point interface. Use
11091 insert_memory_breakpoint. Adjust to new
11092 i386_low_insert_watchpoint interface.
11093 (x86_remove_point): Adjust to remove_point interface. Use
11094 remove_memory_breakpoint. Adjust to new
11095 i386_low_remove_watchpoint interface.
11096 (the_low_target): Install x86_supports_z_point_type.
11097 * lynx-low.c (lynx_target_ops): Install NULL as
11098 supports_z_point_type callback.
11099 * nto-low.c (nto_supports_z_point_type): New.
11100 (nto_insert_point, nto_remove_point): Adjust to new interface.
11101 (nto_target_ops): Install nto_supports_z_point_type.
11102 * mem-break.c: Adjust intro comment.
11103 (struct raw_breakpoint) <raw_type, size>: New fields.
11104 <inserted>: Update comment.
11105 <shlib_disabled>: Delete field.
11106 (enum bkpt_type) <gdb_breakpoint>: Delete value.
11107 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
11108 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
11109 (raw_bkpt_type_to_target_hw_bp_type): New function.
11110 (find_enabled_raw_code_breakpoint_at): New function.
11111 (find_raw_breakpoint_at): New type and size parameters. Use them.
11112 (insert_memory_breakpoint): New function, based off
11113 set_raw_breakpoint_at.
11114 (remove_memory_breakpoint): New function.
11115 (set_raw_breakpoint_at): Reimplement.
11116 (set_breakpoint): New, based on set_breakpoint_at.
11117 (set_breakpoint_at): Reimplement.
11118 (delete_raw_breakpoint): Go through the_target->remove_point
11119 instead of assuming memory breakpoints.
11120 (find_gdb_breakpoint_at): Delete.
11121 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
11122 (find_gdb_breakpoint): New function.
11123 (set_gdb_breakpoint_at): Delete.
11124 (z_type_supported): New function.
11125 (set_gdb_breakpoint_1): New function, loosely based off
11126 set_gdb_breakpoint_at.
11127 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
11128 (delete_gdb_breakpoint_at): Delete.
11129 (delete_gdb_breakpoint_1): New function, loosely based off
11130 delete_gdb_breakpoint_at.
11131 (delete_gdb_breakpoint): New function.
11132 (clear_gdb_breakpoint_conditions): Rename to ...
11133 (clear_breakpoint_conditions): ... this. Don't handle a NULL
11135 (add_condition_to_breakpoint): Make static.
11136 (add_breakpoint_condition): Take a struct breakpoint pointer
11137 instead of an address. Adjust.
11138 (gdb_condition_true_at_breakpoint): Rename to ...
11139 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
11141 (gdb_condition_true_at_breakpoint): Reimplement.
11142 (add_breakpoint_commands): Take a struct breakpoint pointer
11143 instead of an address. Adjust.
11144 (gdb_no_commands_at_breakpoint): Rename to ...
11145 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
11146 parameter. Return true if no breakpoint was found. Change debug
11148 (gdb_no_commands_at_breakpoint): Reimplement.
11149 (run_breakpoint_commands): Rename to ...
11150 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
11151 and change return type to boolean.
11152 (run_breakpoint_commands): New function.
11153 (gdb_breakpoint_here): Also check for Z1 breakpoints.
11154 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
11155 breakpoint. Go through the_target->remove_point instead of
11156 assuming memory breakpoint.
11157 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
11158 software and hardware breakpoints.
11159 (reinsert_raw_breakpoint): Go through the_target->insert_point
11160 instead of assuming memory breakpoint.
11161 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
11162 software and hardware breakpoints.
11163 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
11164 Check both software and hardware breakpoints.
11165 (validate_inserted_breakpoint): Assert the breakpoint is a
11166 software breakpoint. Set the inserted flag to -1 instead of
11167 setting shlib_disabled.
11168 (delete_disabled_breakpoints): Adjust.
11169 (validate_breakpoints): Only validate software breakpoints.
11170 Adjust to inserted flag change.
11171 (check_mem_read, check_mem_write): Skip breakpoint types other
11172 than software breakpoints. Adjust to inserted flag change.
11173 * mem-break.h (enum raw_bkpt_type): New enum.
11174 (raw_breakpoint, struct process_info): Forward declare.
11175 (Z_packet_to_target_hw_bp_type): Delete declaration.
11176 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
11177 (set_gdb_breakpoint, delete_gdb_breakpoint)
11178 (clear_breakpoint_conditions): New declarations.
11179 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
11180 (breakpoint_inserted_here): Update comment.
11181 (add_breakpoint_condition, add_breakpoint_commands): Replace
11182 address parameter with a breakpoint pointer parameter.
11183 (gdb_breakpoint_here): Update comment.
11184 (delete_gdb_breakpoint_at): Delete.
11185 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
11186 * server.c (process_point_options): Take a struct breakpoint
11187 pointer instead of an address. Adjust.
11188 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
11189 delete_gdb_breakpoint.
11190 * spu-low.c (spu_target_ops): Install NULL as
11191 supports_z_point_type method.
11192 * target.h: Include mem-break.h.
11193 (struct target_ops) <prepare_to_access_memory>: Update comment.
11194 <supports_z_point_type>: New field.
11195 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
11196 instead of a char. Also take a raw breakpoint pointer.
11197 * win32-arm-low.c (the_low_target): Install NULL as
11198 supports_z_point_type.
11199 * win32-i386-low.c (i386_supports_z_point_type): New function.
11200 (i386_insert_point, i386_remove_point): Adjust to new interface.
11201 (the_low_target): Install i386_supports_z_point_type.
11202 * win32-low.c (win32_supports_z_point_type): New function.
11203 (win32_insert_point, win32_remove_point): Adjust to new interface.
11204 (win32_target_ops): Install win32_supports_z_point_type.
11205 * win32-low.h (struct win32_target_ops):
11206 <supports_z_point_type>: New method.
11207 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
11208 instead of a char. Also take a raw breakpoint pointer.
11210 2014-05-20 Pedro Alves <palves@redhat.com>
11212 * mem-break.h: Include break-common.h.
11213 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
11214 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
11215 (Z_packet_to_target_hw_bp_type): New declaration.
11216 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
11217 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
11218 (Z_PACKET_ACCESS_WP): Delete macros.
11219 (Z_packet_to_hw_type): Delete function.
11220 * i386-low.h: Don't include break-common.h here.
11221 (Z_packet_to_hw_type): Delete declaration.
11222 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
11223 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
11224 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
11225 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
11226 * linux-aarch64-low.c: Don't include break-common.h here.
11227 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
11228 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
11229 (Z_packet_to_target_hw_bp_type): Delete function.
11230 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
11232 (mips_insert_point, mips_remove_point): Use
11233 Z_packet_to_target_hw_bp_type.
11235 2014-05-20 Pedro Alves <palves@redhat.com>
11237 * linux-aarch64-low.c: Include break-common.h.
11238 (enum target_point_type): Delete.
11239 (Z_packet_to_point_type): Rename to ...
11240 (Z_packet_to_target_hw_bp_type): ... this, and return a
11241 target_hw_bp_type instead.
11242 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
11243 instead of an enum target_point_type.
11244 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
11246 (aarch64_dr_state_insert_one_point)
11247 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
11248 (aarch64_handle_aligned_watchpoint)
11249 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
11250 Take an enum target_hw_bp_type instead of an enum
11252 (aarch64_supports_z_point_type): New function.
11253 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
11254 use Z_packet_to_target_hw_bp_type.
11256 2014-05-20 Joel Brobecker <brobecker@adacore.com>
11258 * configure.ac: Only use -Werror by default when DEVELOPMENT
11260 * configure: Regenerate.
11262 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
11264 Fix gdbserver qGetTLSAddr for x86_64 -m32.
11265 * linux-x86-low.c (X86_64_USER_REGS): New.
11266 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
11268 2014-04-28 Yao Qi <yao@codesourcery.com>
11270 * Makefile.in (i386-avx512.c): Fix the typo of generated file
11273 2014-04-25 Pedro Alves <palves@redhat.com>
11276 * linux-low.c (linux_attach_fail_reason_string): New function.
11277 (linux_attach_lwp): Delete.
11278 (linux_attach_lwp_1): Rename to ...
11279 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
11280 argument. Remove "initial" parameter. Return int instead of
11281 void. Don't error or warn here.
11282 (linux_attach): Adjust to call linux_attach_lwp. Call error on
11283 failure to attach to the tgid. Call warning when failing to
11285 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
11286 argument. Remove "initial" parameter. Return int instead of
11287 void. Don't error or warn here.
11288 (linux_attach_fail_reason_string): New declaration.
11289 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
11290 interface change. Use linux_attach_fail_reason_string.
11292 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
11293 Walfred Tedeschi <walfred.tedeschi@intel.com>
11295 * Makefile.in: Added rules to handle new files
11296 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
11297 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
11298 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
11299 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
11300 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
11301 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
11302 x32-avx512-linux.o.
11303 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
11304 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
11305 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
11306 i386/x32-avx512.xml.
11307 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
11308 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
11309 i386/x32-avx512-linux.xml.
11310 * i387-fp.c (num_avx512_k_registers): New constant for number
11312 (num_avx512_zmmh_low_registers): New constant for number of
11313 lower ZMM registers (0-15).
11314 (num_avx512_zmmh_high_registers): New constant for number of
11315 higher ZMM registers (16-31).
11316 (num_avx512_ymmh_registers): New contant for number of higher
11317 YMM registers (ymm16-31 added by avx521 on x86_64).
11318 (num_avx512_xmm_registers): New constant for number of higher
11319 XMM registers (xmm16-31 added by AVX512 on x86_64).
11320 (struct i387_xsave): Add space for AVX512 registers.
11321 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
11322 Add code to handle AVX512 registers.
11323 (i387_xsave_to_cache): Add code to handle AVX512 registers.
11324 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
11325 prototypei from generated file.
11326 (tdesc_amd64_avx512_linux): Likewise.
11327 (init_registers_x32_avx512_linux): Likewise.
11328 (tdesc_x32_avx512_linux): Likewise.
11329 (init_registers_i386_avx512_linux): Likewise.
11330 (tdesc_i386_avx512_linux): Likewise.
11331 (x86_64_regmap): Add AVX512 registers.
11332 (x86_linux_read_description): Add code to handle AVX512 XSTATE
11334 (initialize_low_arch): Add code to initialize AVX512 registers.
11336 2014-04-23 Pedro Alves <palves@redhat.com>
11338 * mem-break.c (find_gdb_breakpoint_at): Make static.
11339 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
11341 2014-04-23 Pedro Alves <palves@redhat.com>
11343 * i386-low.c: Don't include break-common.h here.
11344 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
11345 prototype to take target_hw_bp_type as argument instead of a Z
11347 * i386-low.h: Include break-common.h here.
11348 (Z_packet_to_hw_type): Declare.
11349 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
11351 * linux-x86-low.c (x86_insert_point): Convert the packet number to
11352 a target_hw_bp_type before calling i386_low_insert_watchpoint.
11353 (x86_remove_point): Convert the packet number to a
11354 target_hw_bp_type before calling i386_low_remove_watchpoint.
11355 * win32-i386-low.c (i386_insert_point): Convert the packet number
11356 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
11357 (i386_remove_point): Convert the packet number to a
11358 target_hw_bp_type before calling i386_low_remove_watchpoint.
11360 2014-04-23 Pedro Alves <palves@redhat.com>
11362 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
11364 2014-04-10 Pedro Alves <palves@redhat.com>
11366 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
11367 Check if the condition or command is NULL before checking if the
11368 breakpoint is known. On success, return true.
11369 * mem-break.h (add_breakpoint_condition): Document return.
11370 (add_breakpoint_commands): Add describing comment.
11371 * server.c (skip_to_semicolon): New function.
11372 (process_point_options): Use it.
11374 2014-04-09 Pedro Alves <palves@redhat.com>
11376 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
11379 2014-02-27 Pedro Alves <palves@redhat.com>
11382 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
11384 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
11386 (last_thread_of_process_p): Take a PID argument instead of a
11388 (linux_wait_for_lwp): Delete.
11389 (num_lwps, check_zombie_leaders, not_stopped_callback): New
11391 (linux_low_filter_event): New function, party factored out from
11392 linux_wait_for_event.
11393 (linux_wait_for_event): Rename to ...
11394 (linux_wait_for_event_filtered): ... this. Add new filter ptid
11395 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
11396 sigsuspend. Check for zombie leaders.
11397 (linux_wait_for_event): Reimplement as wrapper around
11398 linux_wait_for_event_filtered.
11399 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
11400 a normal or signal exit is seen, it's the whole process exiting.
11401 (wait_for_sigstop): No longer a for_each_inferior callback.
11402 Rewrite on top of linux_wait_for_event_filtered.
11403 (stop_all_lwps): Call wait_for_sigstop directly.
11404 * server.c (resume, handle_target_event): Handle
11405 TARGET_WAITKIND_NO_RESUMED.
11407 2014-02-26 Joel Brobecker <brobecker@adacore.com>
11409 * win32-low.c (psapi_get_dll_name,
11410 * win32_CreateToolhelp32Snapshot): Delete.
11411 (win32_CreateToolhelp32Snapshot, win32_Module32First)
11412 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
11414 (handle_load_dll): Add function description.
11415 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
11417 2014-02-26 Joel Brobecker <brobecker@adacore.com>
11419 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
11421 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
11422 base address when calling win32_add_one_solib.
11423 (handle_load_dll): Delete local variable load_addr.
11424 Remove 0x1000 offset applied to DLL base address when calling
11425 win32_add_one_solib.
11426 (handle_unload_dll): Add comment.
11428 2014-02-26 Joel Brobecker <brobecker@adacore.com>
11430 * win32-low.c (win32_add_all_dlls): Renames
11431 win32_ensure_ntdll_loaded. Rewrite function documentation.
11432 Adjust implementation to always load all DLLs.
11433 Add 0x1000 offset to DLL base address when calling
11434 win32_add_one_solib.
11435 (child_initialization_done): New static global.
11436 (do_initial_child_stuff): Set child_initialization_done to
11437 zero during child initialization, and 1 after. Replace call
11438 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
11440 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
11441 (handle_unload_dll): Add function documentation.
11442 (get_child_debug_event): Ignore load and unload DLL events
11443 during child initialization.
11445 2014-02-20 Doug Evans <dje@google.com>
11447 Remove global all_lwps.
11448 * inferiors.h (ptid_of): Move here from linux-low.h.
11449 (pid_of, lwpid_of): Ditto.
11450 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
11451 parameter is a struct thread_info * now.
11452 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
11453 directly. Pass &all_threads to find_inferior instead of &all_lwps.
11454 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
11456 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
11457 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
11458 * linux-arm-low.c (update_registers_callback): Update, "entry"
11459 parameter is a struct thread_info * now.
11460 Fetch lwpid from current_inferior directly.
11461 (arm_insert_point): Pass &all_threads to find_inferior instead of
11463 (arm_remove_point): Ditto.
11464 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
11465 (arm_prepare_to_resume): Fetch pid from thread.
11466 (arm_read_description): Fetch lwpid from current_inferior directly.
11467 * linux-low.c (all_lwps): Delete.
11468 (delete_lwp): Delete call to remove_inferior.
11469 (handle_extended_wait): Fetch lwpid from thread.
11470 (add_lwp): Don't set lwp->entry.id. Remove call to
11471 add_inferior_to_list.
11472 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
11473 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
11474 (kill_one_lwp_callback): Ditto.
11475 (linux_kill): Don't dereference NULL pointer.
11476 Fetch ptid,lwpid from thread.
11477 (get_detach_signal): Fetch ptid from thread.
11478 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
11479 Simplify call to regcache_invalidate_thread.
11480 (delete_lwp_callback): Update, "entry" parameter is a
11481 struct thread_info * now. Fetch pid from thread.
11482 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
11483 (status_pending_p_callback): Update, "entry" parameter is a
11484 struct thread_info * now. Fetch ptid from thread.
11485 (find_lwp_pid): Update, "entry" parameter is a
11486 struct thread_info * now.
11487 (linux_wait_for_lwp): Fetch pid from thread.
11488 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
11489 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
11490 (enqueue_one_deferred_signal): Fetch lwpid from thread.
11491 (dequeue_one_deferred_signal): Ditto.
11492 (cancel_breakpoint): Fetch ptid from current_inferior.
11493 (linux_wait_for_event): Pass &all_threads to find_inferior,
11494 not &all_lwps. Fetch ptid, lwpid from thread.
11495 (count_events_callback): Update, "entry" parameter is a
11496 struct thread_info * now.
11497 (select_singlestep_lwp_callback): Ditto.
11498 (select_event_lwp_callback): Ditto.
11499 (cancel_breakpoints_callback): Ditto.
11500 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
11502 (select_event_lwp): Ditto. Fetch ptid from event_thread.
11503 (unsuspend_one_lwp): Update, "entry" parameter is a
11504 struct thread_info * now.
11505 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
11507 (linux_stabilize_threads): Ditto. And for for_each_inferior.
11508 Fetch lwpid from thread, not lwp.
11509 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
11510 Pass &all_threads to find_inferior, not &all_lwps.
11511 (send_sigstop): Fetch lwpid from thread, not lwp.
11512 (send_sigstop_callback): Update, "entry" parameter is a
11513 struct thread_info * now.
11514 (suspend_and_send_sigstop_callback): Ditto.
11515 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
11516 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
11517 struct thread_info * now.
11518 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
11520 (lwp_running): Update, "entry" parameter is a
11521 struct thread_info * now.
11522 (stop_all_lwps): Fetch ptid from thread.
11523 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
11524 (linux_resume_one_lwp): Fetch lwpid from thread.
11525 (linux_set_resume_request): Update, "entry" parameter is a
11526 struct thread_info * now. Fetch pid, lwpid from thread.
11527 (resume_status_pending_p): Update, "entry" parameter is a
11528 struct thread_info * now.
11529 (need_step_over_p): Ditto. Fetch lwpid from thread.
11530 (start_step_over): Fetch lwpid from thread.
11531 (linux_resume_one_thread): Update, "entry" parameter is a
11532 struct thread_info * now. Fetch lwpid from thread.
11533 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
11534 (proceed_one_lwp): Update, "entry" parameter is a
11535 struct thread_info * now. Fetch lwpid from thread.
11536 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
11537 struct thread_info * now.
11538 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
11539 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
11540 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
11542 (regsets_store_inferior_registers): Ditto.
11543 (fetch_register, store_register): Ditto.
11544 (linux_read_memory, linux_write_memory): Ditto.
11545 (linux_request_interrupt): Ditto.
11546 (linux_read_auxv): Ditto.
11547 (linux_xfer_siginfo): Ditto.
11548 (linux_qxfer_spu): Ditto.
11549 (linux_qxfer_libraries_svr4): Ditto.
11550 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
11551 moved to inferiors.h.
11553 (get_thread_lwp): Update.
11554 (struct lwp_info): Delete member "entry". Simplify comment for
11556 (all_lwps): Delete.
11557 * linux-mips-low.c (mips_read_description): Fetch lwpid from
11558 current_inferior directly.
11559 (update_watch_registers_callback): Update, "entry" parameter is a
11560 struct thread_info * now. Fetch pid from thread.
11561 (mips_linux_prepare_to_resume): Fetch ptid from thread.
11562 (mips_insert_point): Fetch lwpid from current_inferior.
11563 Pass &all_threads to find_inferior, not &all_lwps.
11564 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
11565 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
11567 (mips_stopped_data_address): Ditto.
11568 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
11570 * linux-tile-low.c (tile_arch_setup): Ditto.
11571 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
11572 (update_debug_registers_callback): Update, "entry" parameter is a
11573 struct thread_info * now. Fetch pid from thread.
11574 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
11575 Pass &all_threads to find_inferior, not &all_lwps.
11576 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
11577 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
11578 Pass &all_threads to find_inferior, not &all_lwps.
11579 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
11580 (i386_dr_low_get_status): Ditto.
11581 (x86_linux_prepare_to_resume): Fetch ptid from thread.
11582 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
11583 (x86_linux_read_description): Ditto.
11584 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
11586 2014-02-20 Doug Evans <dje@google.com>
11588 * inferiors.c (get_first_inferior): Fix buglet.
11590 2014-02-19 Doug Evans <dje@google.com>
11592 * gdbthread.h (add_thread): Change result type to struct thread_info *.
11593 * inferiors.c (add_thread): Change result type to struct thread_info *.
11594 All callers updated.
11595 (add_lwp): Call add_thread here instead of in callers.
11596 All callers updated.
11597 * linux-low.h (get_lwp_thread): Rewrite.
11598 (struct lwp_info): New member "thread".
11600 2014-02-19 Doug Evans <dje@google.com>
11602 * linux-low.c (add_lwp): Change result to struct lwp_info *.
11603 All callers updated.
11605 2014-02-19 Doug Evans <dje@google.com>
11607 * inferiors.c (add_thread): Fix whitespace.
11609 2014-02-19 Doug Evans <dje@google.com>
11611 * dll.c (clear_dlls): Replace accessing list implemention details
11613 * gdbthread.h (get_first_thread): Declare.
11614 * inferiors.c (for_each_inferior_with_data): New function.
11615 (get_first_thread): New function.
11616 (find_thread_ptid): Simplify.
11617 (get_first_inferior): New function.
11618 (clear_list): Delete.
11619 (one_inferior_p): New function.
11620 (clear_inferior_list): New function.
11621 (clear_inferiors): Update.
11622 * inferiors.h (for_each_inferior_with_data): Declare.
11623 (clear_inferior_list): Declare.
11624 (one_inferior_p): Declare.
11625 (get_first_inferior): Declare.
11626 * linux-low.c (linux_wait_for_event): Replace accessing list
11627 implemention details with API function.
11628 * server.c (target_running): Ditto.
11629 (accumulate_file_name_length): New function.
11630 (emit_dll_description): New function.
11631 (handle_qxfer_libraries): Replace accessing list implemention
11632 details with API function.
11633 (handle_qxfer_threads_worker): New function.
11634 (handle_qxfer_threads_proper): Replace accessing list implemention
11635 details with API function.
11636 (handle_query): Ditto.
11637 (visit_actioned_threads_callback_ftype): New typedef.
11638 (visit_actioned_threads_data): New struct.
11639 (visit_actioned_threads): Rewrite to be find_inferior callback.
11640 (resume): Call find_inferior.
11641 (handle_status): Replace accessing list implemention
11642 details with API function.
11643 (process_serial_event): Replace accessing list implemention details
11645 * target.c (set_desired_inferior): Replace accessing list implemention
11646 details with API function.
11647 * tracepoint.c (same_process_p): New function.
11648 (gdb_agent_about_to_close): Replace accessing list implemention
11649 details with API function.
11650 * win32-low.c (child_delete_thread): Replace accessing list
11651 implemention details with API function.
11652 (match_dll_by_basename): New function.
11653 (dll_is_loaded_by_basename): New function.
11654 (win32_ensure_ntdll_loaded): Replace accessing list implemention
11655 details call to dll_is_loaded_by_basename.
11657 2014-02-19 Doug Evans <dje@google.com>
11659 * dll.h (struct dll_info): Add comment.
11660 * gdbthread.h (struct thread_info): Add comment.
11661 (current_ptid): Simplify.
11662 * inferiors.c (add_process): Update.
11663 (remove_process): Update.
11664 * inferiors.h (struct process_info): Rename member "head" to "entry".
11665 * linux-low.c (delete_lwp): Update.
11667 (last_thread_of_process_p): Update.
11668 (kill_one_lwp_callback, linux_kill): Update.
11669 (status_pending_p_callback): Update.
11670 (wait_for_sigstop): Update. Simplify read of ptid.
11671 (start_step_over): Update.
11672 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
11673 (get_lwp_thread): Update.
11674 (struct lwp_info): Rename member "head" to "entry".
11675 * regcache.h (inferior_list_entry): Delete.
11676 * server.c (kill_inferior_callback): Update.
11677 (detach_or_kill_inferior_callback): Update.
11678 (print_started_pid): Update.
11679 (print_attached_pid): Update.
11680 (process_serial_event): Simplify read of ptid.
11681 * thread-db.c (thread_db_create_event): Update.
11682 (thread_db_get_tls_address): Update.
11683 * win32-low.c (current_inferior_ptid): Simplify.
11685 2014-02-19 Tom Tromey <tromey@redhat.com>
11687 * target.h (struct target_ops) <supports_btrace>: Add target_ops
11689 (target_supports_btrace): Update.
11691 2014-02-14 Yao Qi <yao@codesourcery.com>
11693 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
11694 (rsp-low-ipa.o): New target.
11696 2014-02-12 Tom Tromey <tromey@redhat.com>
11698 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
11699 convert_ascii_to_int.
11700 * regcache.c (registers_to_string): Likewise.
11701 * remote-utils.c (decode_M_packet): Likewise.
11702 * server.c (process_serial_event): Likewise.
11704 2014-02-12 Tom Tromey <tromey@redhat.com>
11706 * server.c (handle_query, handle_v_run): Use hex2bin, not
11708 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
11710 2014-02-12 Tom Tromey <tromey@redhat.com>
11712 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
11713 convert_int_to_ascii.
11714 * regcache.c (registers_to_string, collect_register_as_string):
11716 * remote-utils.c (look_up_one_symbol, relocate_instruction):
11718 * server.c (process_serial_event): Likewise.
11719 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
11720 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
11722 2014-02-12 Tom Tromey <tromey@redhat.com>
11724 * remote-utils.c (look_up_one_symbol, monitor_output): Use
11725 bin2hex, not hexify.
11726 * tracepoint.c (cmd_qtstatus): Likewise.
11728 2014-02-12 Tom Tromey <tromey@redhat.com>
11730 * remote-utils.c (monitor_output): Pass explicit length to
11733 2014-02-12 Tom Tromey <tromey@redhat.com>
11735 * tracepoint.c: Include rsp-low.h.
11736 * server.c: Include rsp-low.h.
11737 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
11738 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
11740 * remote-utils.c: Include rsp-low.h.
11741 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
11742 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
11743 (convert_int_to_ascii, convert_ascii_to_int): Move to
11745 * regcache.c: Include rsp-low.h.
11746 * ax.c: Include rsp-low.h.
11747 * Makefile.in (SFILES): Add common/rsp-low.c.
11748 (OBS): Add rsp-low.o.
11749 (rsp-low.o): New target.
11751 2014-02-12 Tom Tromey <tromey@redhat.com>
11753 * utils.h (pulongest, plongest, phex_nz): Don't declare.
11754 Include print-utils.h.
11755 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
11756 (plongest, thirty_two, phex_nz): Remove.
11757 * Makefile.in (SFILES): Add common/print-utils.c.
11758 (OBS): Add print-utils.o.
11759 (print-utils-ipa.o): New target.
11760 (print-utils.o): New target.
11761 (IPA_OBJS): Add print-utils-ipa.o.
11763 2014-02-06 Tom Tromey <tromey@redhat.com>
11765 * Makefile.in (SFILES): Fix indentation.
11767 2014-02-05 Doug Evans <dje@google.com>
11769 * linux-low.c (linux_wait_for_event): Improve comment.
11770 (linux_wait_1): Keep current_inferior in sync with event_child.
11772 2014-01-22 Doug Evans <dje@google.com>
11774 * gdbthread.h (gdb_id_to_thread): Delete, unused.
11776 2014-01-22 Doug Evans <dje@google.com>
11778 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
11779 * configure: Regenerate.
11780 * config.in: Regenerate.
11781 * Makefile.in (SFILES): Add debug.c.
11782 (OBS): Add debug.o.
11783 * debug.c: New file.
11784 * debug.h: New file.
11785 * linux-aarch64-low.c (*): Update all debugging printfs to use
11786 debug_printf instead of fprintf.
11787 * linux-arm-low.c (*): Ditto.
11788 * linux-cris-low.c (*): Ditto.
11789 * linux-crisv32-low.c (*): Ditto.
11790 * linux-m32r-low.c (*): Ditto.
11791 * linux-sparc-low.c (*): Ditto.
11792 * linux-x86.c (*): Ditto.
11793 * linux-low.c (*): Ditto.
11794 (linux_wait_1): Add calls to debug_enter, debug_exit.
11795 (linux_wait): Remove redundant debugging printf.
11796 (stop_all_lwps): Add calls to debug_enter, debug_exit.
11797 (linux_resume, unstop_all_lwps): Ditto.
11798 * mem-break.c (*): Update all debugging printfs to use
11799 debug_printf instead of fprintf.
11800 * remote-utils.c (*): Ditto.
11801 * thread-db.c (*): Ditto.
11802 * server.c #include <ctype.h>, "gdb_vecs.h".
11803 (debug_threads): Moved to debug.c.
11804 (*): Update all debugging printfs to use debug_printf instead of
11806 (start_inferior): Replace call to fflush with call to debug_flush.
11807 (monitor_show_help): Mention set debug-format.
11808 (parse_debug_format_options): New function.
11809 (handle_monitor_command): Handle "monitor set debug-format".
11810 (gdbserver_usage): Mention --debug-format.
11811 (main): Parse --debug-format.
11812 * server.h (debug_threads): Declaration moved to debug.h.
11813 #include "debug.h".
11814 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
11815 trace_debug_1 that uses debug_printf.
11816 (tracepoint_look_up_symbols): Update all debugging printfs to use
11817 debug_printf instead of fprintf.
11819 2014-01-20 Baruch Siach <baruch@tkos.co.il>
11821 * linux-xtensa-low.c: Include asm/ptrace.h instead of
11824 2014-01-17 Pedro Alves <palves@redhat.com>
11827 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
11828 defined after including gdb_proc_service.h.
11830 2014-01-16 Doug Evans <dje@google.com>
11832 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
11833 (match_dll): Use it.
11835 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
11837 * target.h (target_ops) <read_btrace>: Change parameters and
11838 return type to allow error reporting.
11839 * server.c (handle_qxfer_btrace): Support delta reads. Pass
11840 trace reading errors on.
11841 * linux-low.c (linux_low_read_btrace): Pass trace reading
11843 (linux_low_disable_btrace): New.
11845 2014-01-15 Doug Evans <dje@google.com>
11847 * inferiors.c (thread_id_to_gdb_id): Delete.
11848 * inferiors.h (thread_id_to_gdb_id): Delete.
11850 2014-01-13 Eli Zaretskii <eliz@gnu.org>
11852 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
11853 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
11856 2014-01-08 Pedro Alves <palves@redhat.com>
11858 * server.c (handle_status): Don't discard previous queued stop
11859 replies or thread's pending status here.
11860 (main) <disconnection>: Do it here instead.
11862 2014-01-08 Pedro Alves <palves@redhat.com>
11864 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
11865 * server.c (visit_actioned_threads, handle_pending_status): New
11867 (handle_v_cont): Factor out parts to ...
11868 (resume): ... this new function. If in all-stop, and a thread
11869 being resumed has a pending status, report it without actually
11871 (myresume): Adjust to use the new 'resume' function.
11872 (clear_pending_status_callback, set_pending_status_callback)
11873 (find_status_pending_thread_callback): New functions.
11874 (handle_status): Handle the case of multiple threads having
11875 interesting statuses to report. Report threads' real last signal
11876 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
11877 with an interesting thread to report the status for, instead of
11878 always reporting the status of the first thread.
11880 2014-01-01 Joel Brobecker <brobecker@adacore.com>
11882 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
11883 * gdbreplay.c (gdbreplay_version): Likewise.
11885 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
11887 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
11888 iov.iov_len with the real length in use.
11890 2013-12-13 Joel Brobecker <brobecker@adacore.com>
11892 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
11893 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
11894 for all targets that use win32-low.c.
11895 * win32-low.c (win32_ensure_ntdll_loaded): New function.
11896 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
11898 2013-12-13 Pedro Alves <palves@redhat.com>
11900 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
11901 if equal to TARGET_WAITKIND_LOADED.
11902 * win32-low.c (cached_status): New static global.
11903 (win32_wait): Add declaration.
11904 (do_initial_child_stuff): Flush all initial pending debug events
11905 up to the initial breakpoint.
11906 (win32_wait): If CACHED_STATUS was set, return that instead
11907 of doing a real wait. Remove the code resuming the execution
11908 of the inferior after receiving a TARGET_WAITKIND_LOADED event
11909 during the initial phase. Also remove the code changing
11910 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
11911 TARGET_WAITKIND_STOPPED.
11913 2013-12-11 Yao Qi <yao@codesourcery.com>
11915 * notif.c (handle_notif_ack): Return 0 if no notification
11918 2013-11-20 Doug Evans <dje@google.com>
11920 * linux-low.c (linux_set_resume_request): Fix comment.
11922 2013-11-20 Doug Evans <dje@google.com>
11924 * linux-low.c (resume_status_pending_p): Tweak comment.
11926 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
11928 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
11929 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
11930 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
11931 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
11932 (srv_amd64_regobj): Add amd64-mpx.o.
11933 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
11934 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
11935 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
11936 * i387-fp.c (num_pl_bnd_register) Added constant.
11937 (num_pl_bnd_cfg_registers) Added constant.
11938 (struct i387_xsave) Added reserved area and MPX fields.
11939 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
11940 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
11942 (tdesc_i386_mpx_linux): Add MPX amd64 target.
11943 (init_registers_amd64_mpx_linux): Declare new function.
11944 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
11945 (x86_64_regmap): Add MPX registers.
11946 (x86_linux_read_description): Add MPX case.
11947 (initialize_low_arch): Initialize MPX targets.
11949 2013-11-18 Tom Tromey <tromey@redhat.com>
11951 * configure: Rebuild.
11952 * configure.ac: Don't check for stdlib.h.
11953 * gdbreplay.c: Unconditionally include stdlib.h.
11955 2013-11-18 Tom Tromey <tromey@redhat.com>
11957 * config.in: Rebuild.
11958 * configure: Rebuild.
11959 * configure.ac: Don't use AC_HEADER_DIRENT.
11961 2013-11-18 Tom Tromey <tromey@redhat.com>
11963 * server.h: Don't check HAVE_STRING_H.
11964 * gdbreplay.c: Don't check HAVE_STRING_H.
11965 * configure: Rebuild.
11967 2013-11-18 Tom Tromey <tromey@redhat.com>
11969 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
11972 2013-11-08 Tom Tromey <tromey@redhat.com>
11974 * configure, config.in: Rebuild.
11975 * configure.ac: Remove unused configury.
11977 2013-11-08 Tom Tromey <tromey@redhat.com>
11979 * acinclude.m4: Include common.m4, codeset.m4.
11980 * configure, config.in: Rebuild.
11981 * configure.ac: Use GDB_AC_COMMON.
11983 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
11985 * linux-s390-low.c (HWCAP_S390_TE): New define.
11986 (s390_arch_setup): Consider the TE field in the HWCAP for
11987 determining 'have_regset_tdb'.
11989 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
11992 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
11995 2013-10-02 Pedro Alves <palves@redhat.com>
11997 * server.c (process_serial_event): Don't output "GDBserver
11998 exiting" if GDB is connected through stdio.
11999 * target.c (mywait): Likewise, be silent if GDB is connected
12002 2013-10-01 Joel Brobecker <brobecker@adacore.com>
12004 * lynx-low.c (lynx_add_threads_after_attach): New function.
12005 (lynx_attach): Remove call to add_thread. Add call to
12006 lynx_add_threads_after_attach instead.
12008 2013-09-28 Mike Frysinger <vapier@gentoo.org>
12010 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
12011 * config.in, configure: Regenerated.
12013 2013-09-18 Yao Qi <yao@codesourcery.com>
12016 * server.c (start_inferior): Clear 'resume_info'.
12018 2013-09-16 Jiong Wang <jiwang@tilera.com>
12020 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
12023 2013-09-16 Jiong Wang <jiwang@tilera.com>
12025 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
12026 linux-tile-low.o to srv_tgtobj.
12028 2013-09-16 Will Newton <will.newton@linaro.org>
12030 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
12033 2013-09-06 Pedro Alves <palves@redhat.com>
12035 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
12036 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
12037 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
12038 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
12039 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
12040 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
12042 2013-09-06 Pedro Alves <palves@redhat.com>
12044 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
12045 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
12047 2013-09-06 Pedro Alves <palves@redhat.com>
12049 * linux-amd64-ipa.c: Include tracepoint.h.
12050 * linux-i386-ipa.c: Include tracepoint.h.
12052 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
12054 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
12055 (ps_get_thread_area): New function.
12057 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
12059 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
12060 (initialize_low_arch): Call init_registers_crisv32 rather than
12061 init_register_crisv32.
12063 2013-09-05 Pedro Alves <palves@redhat.com>
12065 * server.h (handle_vFile, hostio_last_error_from_errno): Move
12067 * hostio.h: ... this new file.
12068 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
12069 win32-low.c: Include hostio.h.
12071 2013-09-05 Pedro Alves <palves@redhat.com>
12073 * server.h (gdb_client_data, handler_func, callback_handler_func)
12074 (delete_file_handler, add_file_handler, append_callback_event)
12075 (delete_callback_event, start_event_loop, initialize_event_loop):
12076 Move to event-loop.h and include it.
12077 * event-loop.h: New file.
12079 2013-09-05 Pedro Alves <palves@redhat.com>
12081 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
12082 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
12083 (loaded_dll, unloaded_dll): Move to ...
12084 * dll.h: ... this new file.
12085 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
12087 2013-09-05 Pedro Alves <palves@redhat.com>
12089 * server.h (current_process, get_thread_process, all_processes)
12090 (add_inferior_to_list, for_each_inferior, current_inferior)
12091 (remove_inferior, add_process, remove_process, find_process_pid)
12092 (have_started_inferiors_p, have_attached_inferiors_p)
12093 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
12094 (clear_inferiors, find_inferior, find_inferior_id)
12095 (inferior_target_data, set_inferior_target_data)
12096 (inferior_regcache_data, set_inferior_regcache_data): Move to
12097 inferiors.h, and include it.
12098 * inferiors.h: New file.
12100 2013-09-05 Pedro Alves <palves@redhat.com>
12102 * server.h (struct emit_ops, current_insn_ptr, emit_error):
12106 2013-09-05 Pedro Alves <palves@redhat.com>
12108 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
12110 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
12111 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
12112 (handle_tracepoint_general_set, handle_tracepoint_query)
12113 (tracepoint_finished_step, tracepoint_was_hit)
12114 (release_while_stepping_state_list, current_traceframe)
12115 (in_readonly_region, traceframe_read_mem)
12116 (fetch_traceframe_registers, traceframe_read_sdata)
12117 (traceframe_read_info, struct fast_tpoint_collect_status)
12118 (fast_tracepoint_collecting, force_unlock_trace_buffer)
12119 (handle_tracepoit_bkpts, initialize_low_tracepoint)
12120 (supply_fast_tracepoint_registers)
12121 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
12122 (ipa_tdesc, claim_trampoline_space)
12123 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
12124 (agent_mem_read, agent_get_trace_state_variable_value)
12125 (agent_set_trace_state_variable_value, agent_tsv_read)
12126 (agent_mem_read_string, get_raw_reg_func_addr)
12127 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
12128 * tracepoint.h: ... this new file.
12130 2013-09-05 Pedro Alves <palves@redhat.com>
12132 * server.h (perror_with_name, error, fatal, warning, paddress)
12133 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
12135 * utils.h: New file.
12137 2013-09-05 Pedro Alves <palves@redhat.com>
12139 * server.h (remote_debug, noack_mode, transport_is_reliable)
12140 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
12141 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
12142 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
12143 (write_enn, initialize_async_io, enable_async_io)
12144 (disable_async_io, check_remote_input_interrupt_request)
12145 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
12146 (dead_thread_notify, prepare_resume_reply)
12147 (decode_address_to_semicolon, decode_address, decode_m_packet)
12148 (decode_M_packet, decode_X_packet, decode_xfer_write)
12149 (decode_search_memory_packet, unhexify, hexify)
12150 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
12151 (look_up_one_symbol, relocate_instruction)
12152 (monitor_output): Move to remote-utils.h, and include it.
12153 * remote-utils.h: New file.
12155 2013-09-05 Pedro Alves <palves@redhat.com>
12157 * server.h (_): Delete.
12159 2013-09-02 Pedro Alves <palves@redhat.com>
12161 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
12162 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
12164 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
12166 2013-09-02 Pierre Muller <muller@sourceware.org>
12168 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
12169 or WriteProcessMemory complete successfully and handle
12170 ERROR_PARTIAL_COPY error.
12172 2013-09-02 Pedro Alves <palves@redhat.com>
12174 * server.c (gdb_read_memory): Return -1 on traceframe memory read
12175 error instead of EIO.
12177 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12180 * linux-low.c: Include filestuff.h.
12181 (linux_create_inferior) <pid == 0>: Call close_most_fds.
12182 * lynx-low.c: Include filestuff.h.
12183 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
12184 * server.c: Include filestuff.h.
12185 (main): Call notice_open_fds.
12186 * spu-low.c: Include filestuff.h.
12187 (spu_create_inferior) <pid == 0>: Call close_most_fds.
12189 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
12191 * Makefile.in: Explain why ../target and ../nat are not
12192 listed as include file search paths.
12193 (linux-waitpid.o): New object file rule.
12194 * configure.srv (srv_native_linux_obj): New variable.
12195 Replace all occurrences of linux native object files with
12196 $srv_native_linux_obj.
12197 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
12198 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
12199 (linux_enable_event_reporting): Remove declaration.
12200 (my_waitpid): Moved to common/linux-waitpid.c.
12201 (linux_wait_for_event): Pass ptid when calling
12202 linux_enable_event_reporting.
12203 (linux_supports_tracefork_flag): Remove.
12204 (linux_enable_event_reporting): Likewise.
12205 (linux_tracefork_grandchild): Remove.
12206 (STACK_SIZE): Moved to common/linux-ptrace.c.
12207 (linux_tracefork_child): Remove.
12208 (linux_test_for_tracefork): Remove.
12209 (linux_look_up_symbols): Call linux_supports_traceclone.
12210 (initialize_low): Remove call to linux_test_for_tracefork.
12211 * linux-low.h (PTRACE_TYPE_ARG3): Move to
12212 common/linux-ptrace.h.
12213 (PTRACE_TYPE_ARG4): Likewise.
12214 Include linux-ptrace.h.
12216 2013-08-21 Pedro Alves <palves@redhat.com>
12218 * config.in: Renegerate.
12220 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
12222 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
12223 (SFILES): Remove $(srcdir)/common/target-common.c and
12224 add $(srcdir)/target/waitstatus.c.
12225 (OBS): Remove target-common.o and add waitstatus.o.
12226 (server_h): Remove $(srcdir)/../common/target-common.h and
12227 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
12228 and $(srcdir)/../target/waitstatus.h.
12229 (target-common.o): Remove.
12230 (waitstatus.o): New target object file.
12231 * target.h: Do not include target-common.h and
12232 include target/resume.h, target/wait.h and
12233 target/waitstatus.h.
12235 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
12237 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
12238 to PTRACE_TYPE_ARG3.
12239 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
12240 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
12242 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
12243 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
12245 2013-07-27 Jie Zhang <jie@codesourcery.com>
12246 Daniel Jacobowitz <dan@codesourcery.com>
12247 Yao Qi <yao@codesourcery.com>
12249 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
12250 (mips-linux-watch.o): New rule.
12251 (mips_linux_watch_h): New variable.
12252 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
12254 * linux-mips-low.c: Include mips-linux-watch.h.
12255 (struct arch_process_info, struct arch_lwp_info): New.
12256 (update_watch_registers_callback): New function.
12257 (mips_linux_new_process, mips_linux_new_thread) New functions.
12258 (mips_linux_prepare_to_resume, mips_insert_point): New
12260 (mips_remove_point, mips_stopped_by_watchpoint): New
12262 (rsp_bp_type_to_target_hw_bp_type): New function.
12263 (mips_stopped_data_address): New function.
12264 (the_low_target): Add watchpoint support functions.
12266 2013-07-27 Yao Qi <yao@codesourcery.com>
12268 * i386-low.c: Include break-common.h.
12269 (enum target_hw_bp_type): Remove.
12271 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
12273 * Makefile.in (SFILES): /common/target-common.c.
12274 (OBS): Add target-common.o.
12275 (server_h): Add $(srcdir)/../common/target-common.h.
12276 (target-common.o): New target.
12277 * server.c (queue_stop_reply_callback): Free
12278 status string after use.
12279 * target.c (target_waitstatus_to_string): Remove.
12280 * target.h: Include target-common.h.
12281 (resume_kind): Likewise.
12282 (target_waitkind): Likewise.
12283 (target_waitstatus): Likewise.
12284 (TARGET_WNOHANG): Likewise.
12286 2013-07-04 Yao Qi <yao@codesourcery.com>
12288 * Makefile.in (host_alias): Use @host_noncanonical@.
12289 (target_alias): Use @target_noncanonical@.
12290 * configure.ac: Use ACX_NONCANONICAL_TARGET and
12291 ACX_NONCANONICAL_HOST.
12292 * configure: Regenerated.
12295 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
12297 * configure.ac (version_host, version_target): Set and AC_SUBST them.
12298 * configure: Rebuild.
12299 * Makefile.in (version_host, version_target): Get from configure.
12300 (version.c): Use $(version_host) and $(version_target).
12302 2013-07-03 Pedro Alves <palves@redhat.com>
12304 * Makefile.in (config.status): Depend on development.sh.
12305 * acinclude.m4: Include libmcheck.m4.
12306 * configure: Regenerate.
12308 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
12310 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
12311 attribute inside the parentheses.
12312 (winapi_DebugSetProcessKillOnExit): Ditto.
12313 (winapi_DebugBreakProcess): Ditto.
12314 (winapi_GenerateConsoleCtrlEvent): Ditto.
12316 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
12318 * notif.h (notif_event): Add a dummy member to avoid compiler
12321 2013-07-01 Pedro Alves <palves@redhat.com>
12323 * hostio.c (HOSTIO_PATH_MAX): Define.
12324 (require_filename, handle_open, handle_unlink, handle_readlink):
12327 2013-07-01 Pedro Alves <palves@redhat.com>
12329 * server.h: Include "pathmax.h".
12330 * linux-low.c: Don't include sys/param.h.
12331 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
12333 * win32-low.c: Don't include sys/param.h.
12334 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
12336 2013-07-01 Pedro Alves <palves@redhat.com>
12338 * event-loop.c: Don't check HAVE_UNISTD_H before including
12340 * gdbreplay.c: Likewise.
12341 * remote-utils.c: Likewise.
12342 * server.c: Likewise.
12343 * configure.ac: Don't check for unistd.h.
12344 * configure: Regenerate.
12346 2013-06-28 Tom Tromey <tromey@redhat.com>
12348 * Makefile.in (version.c): Use version.in, not
12351 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
12353 * configure.ac (version_host, version_target): Set and AC_SUBST them.
12354 * configure: Rebuild.
12355 * Makefile.in (version_host, version_target): Get from configure.
12356 (version.c): Use $(version_host) and $(version_target).
12358 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
12360 Fix trace-status to output user name without trailing colon.
12361 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
12363 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
12365 Fix trace-status to output proper start-time and stop-time.
12366 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
12367 output start time and stop time in hex as gdb expects.
12369 2013-06-26 Pedro Alves <pedro@codesourcery.com>
12371 * tracepoint.c (build_traceframe_info_xml): Output trace state
12372 variables present in the trace buffer.
12374 2013-06-24 Tom Tromey <tromey@redhat.com>
12376 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
12378 (version.o): Remove.
12379 * gdbreplay.c: Include version.h.
12380 (version, host_name): Don't declare.
12381 * server.h: Include version.h.
12382 (version, host_name): Don't declare.
12384 2013-06-12 Pedro Alves <palves@redhat.com>
12386 * linux-x86-low.c (linux_is_elf64): Delete global.
12387 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
12388 with local linux_pid_exe_is_elf_64_file use.
12390 2013-06-11 Pedro Alves <palves@redhat.com>
12392 * linux-low.c (regset_disabled, disable_regset): New functions.
12393 (regsets_fetch_inferior_registers)
12394 (regsets_store_inferior_registers): Use them.
12395 (initialize_regsets_info); Don't allocate the disabled_regsets
12397 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
12400 2013-06-11 Pedro Alves <palves@redhat.com>
12402 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
12405 2013-06-11 Pedro Alves <palves@redhat.com>
12407 * linux-x86-low.c (initialize_low_arch): Call
12408 init_registers_x32_avx_linux.
12410 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
12412 Fix compatibility with Android Bionic.
12413 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
12416 2013-06-07 Pedro Alves <palves@redhat.com>
12419 * Makefile.in (OBS): Add tdesc.o.
12420 (IPA_OBJS): Add tdesc-ipa.o.
12421 (tdesc-ipa.o): New rule.
12422 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
12424 * linux-low.c (new_inferior): Delete.
12425 (disabled_regsets, num_regsets): Delete.
12426 (linux_add_process): Adjust to set the new per-process
12428 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
12429 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
12430 was a stop. When calling arch_setup, switch the current inferior
12431 to the thread that got an event.
12432 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
12433 (regsets_fetch_inferior_registers)
12434 (regsets_store_inferior_registers): New regsets_info parameter.
12436 (linux_register_in_regsets): New regs_info parameter. Adjust to
12438 (register_addr, fetch_register, store_register): New usrregs_info
12439 parameter. Adjust to use it.
12440 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
12441 parameter regs_info. Adjust to use it.
12442 (linux_fetch_registers): Get the current inferior's regs_info, and
12444 (linux_store_registers): Ditto.
12445 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
12446 (initialize_low): Don't initialize the target_regsets here. Call
12447 initialize_low_arch.
12448 * linux-low.h (target_regsets): Delete declaration.
12449 (struct regsets_info): New.
12450 (struct usrregs_info): New.
12451 (struct regs_info): New.
12452 (struct process_info_private) <new_inferior>: New field.
12453 (struct linux_target_ops): Delete the num_regs, regmap, and
12454 regset_bitmap fields. New field regs_info.
12455 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
12456 * i387-fp.c (num_xmm_registers): Delete.
12457 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
12458 calls to new interface.
12459 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
12460 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
12461 Infer the number of xmm registers from the regcache's target
12463 * i387-fp.h (num_xmm_registers): Delete.
12464 * inferiors.c (add_thread): Don't install the thread's regcache
12466 * proc-service.c (gregset_info): Fetch the current inferior's
12467 regs_info. Adjust to use it.
12468 * regcache.c: Include tdesc.h.
12469 (register_bytes, reg_defs, num_registers)
12470 (gdbserver_expedite_regs): Delete.
12471 (get_thread_regcache): If the thread doesn't have a regcache yet,
12472 create one, instead of aborting gdbserver.
12473 (regcache_invalidate_one): Rename to ...
12474 (regcache_invalidate_thread): ... this.
12475 (regcache_invalidate_one): New.
12476 (regcache_invalidate): Only invalidate registers of the current
12478 (init_register_cache): Add target_desc parameter, and use it.
12479 (new_register_cache): Ditto. Assert the target description has a
12480 non zero registers_size.
12481 (regcache_cpy): Add assertions. Adjust.
12482 (realloc_register_cache, set_register_cache): Delete.
12483 (registers_to_string, registers_from_string): Adjust.
12484 (find_register_by_name, find_regno, find_register_by_number)
12485 (register_cache_size): Add target_desc parameter, and use it.
12486 (free_register_cache_thread, free_register_cache_thread_one)
12487 (regcache_release, register_cache_size): New.
12488 (register_size): Add target_desc parameter, and use it.
12489 (register_data, supply_register, supply_register_zeroed)
12490 (supply_regblock, supply_register_by_name, collect_register)
12491 (collect_register_as_string, collect_register_by_name): Adjust.
12492 * regcache.h (struct target_desc): Forward declare.
12493 (struct regcache) <tdesc>: New field.
12494 (init_register_cache, new_register_cache): Add target_desc
12496 (regcache_invalidate_thread): Declare.
12497 (regcache_invalidate_one): Delete declaration.
12498 (regcache_release): Declare.
12499 (find_register_by_number, register_cache_size, register_size)
12500 (find_regno): Add target_desc parameter.
12501 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
12503 * remote-utils.c: Include tdesc.h.
12504 (outreg, prepare_resume_reply): Adjust.
12505 * server.c: Include tdesc.h.
12506 (gdbserver_xmltarget): Delete declaration.
12507 (get_features_xml, process_serial_event): Adjust.
12508 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
12510 (struct process_info) <tdesc>: New field.
12511 (ipa_tdesc): Declare.
12512 * tdesc.c: New file.
12513 * tdesc.h: New file.
12514 * tracepoint.c: Include tdesc.h.
12515 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
12516 (get_context_regcache): Adjust to pass ipa_tdesc down.
12517 (do_action_at_tracepoint): Adjust to get the register cache size
12518 from the context regcache's description.
12519 (traceframe_walk_blocks): Adjust to get the register cache size
12520 from the current trace frame's description.
12521 (traceframe_get_pc): Adjust to get current trace frame's
12522 description and pass it down.
12523 (gdb_collect): Adjust to get the register cache size from the
12525 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
12526 (gdbserver_xmltarget): Delete.
12527 (initialize_low_tracepoint): Set the ipa's target description.
12528 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
12529 (initialize_low_tracepoint): Set the ipa's target description.
12530 * linux-x86-low.c: Include tdesc.h.
12531 [__x86_64__] (is_64bit_tdesc): New.
12532 (ps_get_thread_area, x86_get_thread_area): Use it.
12533 (i386_cannot_store_register): Rename to ...
12534 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
12535 (i386_cannot_fetch_register): Rename to ...
12536 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
12537 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
12539 (target_regsets): Rename to ...
12540 (x86_regsets): ... this.
12541 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
12543 (x86_siginfo_fixup): Use is_64bit_tdesc.
12544 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
12545 (tdesc_x32_avx_linux, tdesc_x32_linux)
12546 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
12548 (x86_linux_update_xmltarget): Delete.
12549 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
12550 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
12551 (AMD64_LINUX_USER64_CS): New.
12552 (x86_linux_read_description): New, based on
12553 x86_linux_update_xmltarget.
12554 (same_process_callback): New.
12555 (x86_arch_setup_process_callback): New.
12556 (x86_linux_update_xmltarget): New.
12557 (x86_regsets_info): New.
12558 (amd64_linux_regs_info): New.
12559 (i386_linux_usrregs_info): New.
12560 (i386_linux_regs_info): New.
12561 (x86_linux_regs_info): New.
12562 (x86_arch_setup): Reimplement.
12563 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
12564 (x86_emit_ops): Ditto.
12565 (the_low_target): Adjust. Install x86_linux_regs_info,
12566 x86_cannot_fetch_register, and x86_cannot_store_register.
12567 (initialize_low_arch): New.
12568 * linux-ia64-low.c (tdesc_ia64): Declare.
12569 (ia64_fetch_register): Adjust.
12570 (ia64_usrregs_info, regs_info): New globals.
12571 (ia64_regs_info): New function.
12572 (the_low_target): Adjust.
12573 (initialize_low_arch): New function.
12574 * linux-sparc-low.c (tdesc_sparc64): Declare.
12575 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
12577 (sparc_arch_setup): New function.
12578 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
12579 (the_low_target): Adjust.
12580 (initialize_low_arch): New function.
12581 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
12582 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
12583 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
12584 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
12585 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
12586 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
12587 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
12588 (tdesc_powerpc_isa205_vsx64l): Declare.
12589 (ppc_cannot_store_register, ppc_collect_ptrace_register)
12590 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
12591 (ppc_set_pc, ppc_get_hwcap): Adjust.
12592 (ppc_usrregs_info): Forward declare.
12593 (!__powerpc64__) ppc_regmap_adjusted: New global.
12594 (ppc_arch_setup): Adjust to the current process'es target
12596 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
12597 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
12598 (ppc_store_evrregset): Adjust.
12599 (target_regsets): Rename to ...
12600 (ppc_regsets): ... this, and make static.
12601 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
12602 (ppc_regs_info): New function.
12603 (the_low_target): Adjust.
12604 (initialize_low_arch): New function.
12605 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
12606 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
12607 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
12608 (tdesc_s390x_linux64v2): Declare.
12609 (s390_collect_ptrace_register, s390_supply_ptrace_register)
12610 (s390_fill_gregset, s390_store_last_break): Adjust.
12611 (target_regsets): Rename to ...
12612 (s390_regsets): ... this, and make static.
12613 (s390_get_pc, s390_set_pc): Adjust.
12614 (s390_get_hwcap): New target_desc parameter, and use it.
12615 [__s390x__] (have_hwcap_s390_high_gprs): New global.
12616 (s390_arch_setup): Adjust to set the current process'es target
12617 description. Don't adjust the regmap.
12618 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
12619 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
12620 (regs_info_3264): New globals.
12621 (s390_regs_info): New function.
12622 (the_low_target): Adjust.
12623 (initialize_low_arch): New function.
12624 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
12625 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
12626 [__mips64] (init_registers_mips_linux)
12627 (init_registers_mips_dsp_linux): Delete defines.
12628 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
12629 (have_dsp): New global.
12630 (mips_read_description): New, based on mips_arch_setup.
12631 (mips_arch_setup): Reimplement.
12632 (get_usrregs_info): New function.
12633 (mips_cannot_fetch_register, mips_cannot_store_register)
12634 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
12635 (mips_fill_fpregset, mips_store_fpregset): Adjust.
12636 (target_regsets): Rename to ...
12637 (mips_regsets): ... this, and make static.
12638 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
12639 (dsp_regs_info, regs_info): New globals.
12640 (mips_regs_info): New function.
12641 (the_low_target): Adjust.
12642 (initialize_low_arch): New function.
12643 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
12644 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
12646 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
12647 (arm_read_description): New, with bits factored from
12649 (arm_arch_setup): Reimplement.
12650 (target_regsets): Rename to ...
12651 (arm_regsets): ... this, and make static.
12652 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
12653 (arm_regs_info): New function.
12654 (the_low_target): Adjust.
12655 (initialize_low_arch): New function.
12656 * linux-m68k-low.c (tdesc_m68k): Declare.
12657 (target_regsets): Rename to ...
12658 (m68k_regsets): ... this, and make static.
12659 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
12660 (m68k_regs_info): New function.
12661 (m68k_arch_setup): New function.
12662 (the_low_target): Adjust.
12663 (initialize_low_arch): New function.
12664 * linux-sh-low.c (tdesc_sharch): Declare.
12665 (target_regsets): Rename to ...
12666 (sh_regsets): ... this, and make static.
12667 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
12668 (sh_regs_info, sh_arch_setup): New functions.
12669 (the_low_target): Adjust.
12670 (initialize_low_arch): New function.
12671 * linux-bfin-low.c (tdesc_bfin): Declare.
12672 (bfin_arch_setup): New function.
12673 (bfin_usrregs_info, regs_info): New globals.
12674 (bfin_regs_info): New function.
12675 (the_low_target): Adjust.
12676 (initialize_low_arch): New function.
12677 * linux-cris-low.c (tdesc_cris): Declare.
12678 (cris_arch_setup): New function.
12679 (cris_usrregs_info, regs_info): New globals.
12680 (cris_regs_info): New function.
12681 (the_low_target): Adjust.
12682 (initialize_low_arch): New function.
12683 * linux-cris-low.c (tdesc_crisv32): Declare.
12684 (cris_arch_setup): New function.
12685 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
12686 (cris_regs_info): New function.
12687 (the_low_target): Adjust.
12688 (initialize_low_arch): New function.
12689 * linux-m32r-low.c (tdesc_m32r): Declare.
12690 (m32r_arch_setup): New function.
12691 (m32r_usrregs_info, regs_info): New globals.
12692 (m32r_regs_info): Adjust.
12693 (initialize_low_arch): New function.
12694 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
12695 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
12696 (tic6x_usrregs_info): Forward declare.
12697 (tic6x_read_description): New function, based on ...
12698 (tic6x_arch_setup): ... this. Reimplement.
12699 (target_regsets): Rename to ...
12700 (tic6x_regsets): ... this, and make static.
12701 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
12702 (tic6x_regs_info): New function.
12703 (the_low_target): Adjust.
12704 (initialize_low_arch): New function.
12705 * linux-xtensa-low.c (tdesc_xtensa): Declare.
12706 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
12707 (target_regsets): Rename to ...
12708 (xtensa_regsets): ... this, and make static.
12709 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
12711 (xtensa_arch_setup, xtensa_regs_info): New functions.
12712 (the_low_target): Adjust.
12713 (initialize_low_arch): New function.
12714 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
12715 (nios2_arch_setup): Set the current process'es tdesc.
12716 (target_regsets): Rename to ...
12717 (nios2_regsets): ... this.
12718 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
12719 (nios2_regs_info): New function.
12720 (the_low_target): Adjust.
12721 (initialize_low_arch): New function.
12722 * linux-aarch64-low.c (tdesc_aarch64): Declare.
12723 (aarch64_arch_setup): Set the current process'es tdesc.
12724 (target_regsets): Rename to ...
12725 (aarch64_regsets): ... this.
12726 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
12727 (aarch64_regs_info): New function.
12728 (the_low_target): Adjust.
12729 (initialize_low_arch): New function.
12730 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
12732 (target_regsets): Rename to ...
12733 (tile_regsets): ... this.
12734 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
12735 (tile_regs_info): New function.
12736 (tile_arch_setup): Set the current process'es tdesc.
12737 (the_low_target): Adjust.
12738 (initialize_low_arch): New function.
12739 * spu-low.c (tdesc_spu): Declare.
12740 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
12741 * win32-arm-low.c (tdesc_arm): Declare.
12742 (arm_arch_setup): New function.
12743 (the_low_target): Install arm_arch_setup instead of
12744 init_registers_arm.
12745 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
12746 (init_windows_x86): Rename to ...
12747 (i386_arch_setup): ... this. Set `win32_tdesc'.
12748 (the_low_target): Adjust.
12749 * win32-low.c (win32_tdesc): New global.
12750 (child_add_thread): Don't create the thread cache here.
12751 (do_initial_child_stuff): Set the new process'es tdesc.
12752 * win32-low.h (struct target_desc): Forward declare.
12753 (win32_tdesc): Declare.
12754 * lynx-i386-low.c (tdesc_i386): Declare global.
12755 (lynx_i386_arch_setup): Set `lynx_tdesc'.
12756 * lynx-low.c (lynx_tdesc): New global.
12757 (lynx_add_process): Set the new process'es tdesc.
12758 * lynx-low.h (struct target_desc): Forward declare.
12759 (lynx_tdesc): Declare global.
12760 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
12761 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
12762 * nto-low.c (nto_tdesc): New global.
12763 (do_attach): Set the new process'es tdesc.
12764 * nto-low.h (struct target_desc): Forward declare.
12765 (nto_tdesc): Declare.
12766 * nto-x86-low.c (tdesc_i386): Declare.
12767 (nto_x86_arch_setup): Set `nto_tdesc'.
12769 2013-06-04 Gary Benson <gbenson@redhat.com>
12771 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
12772 to qSupported response when appropriate.
12773 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
12774 with nonzero-length annex.
12775 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
12776 arguments supplied in annex.
12778 2013-05-31 Doug Evans <dje@google.com>
12781 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
12782 64 bits in 64-cross-32 environment.
12784 2013-05-28 Pedro Alves <palves@redhat.com>
12786 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
12787 (aarch64-without-fpu.c): Delete rule.
12788 * configure.srv (aarch64*-*-linux*): Remove references to
12789 aarch64-without-fpu.o and aarch64-without-fpu.xml.
12790 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
12793 2013-05-24 Pedro Alves <palves@redhat.com>
12795 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
12796 instead of strchr/decode_address. Error if the range isn't split
12797 with a ','. Don't assume there's be a ':' in the action.
12799 2013-05-23 Yao Qi <yao@codesourcery.com>
12800 Pedro Alves <palves@redhat.com>
12802 * linux-low.c (lwp_in_step_range): New function.
12803 (linux_wait_1): If the thread was range stepping and stopped
12804 outside the stepping range, report the stop to GDB. Otherwise,
12805 continue stepping. Add range stepping debug output.
12806 (linux_set_resume_request): Copy the step range from the resume
12807 request to the lwp.
12808 (linux_supports_range_stepping): New.
12809 (linux_target_ops) <supports_range_stepping>: Set to
12810 linux_supports_range_stepping.
12811 * linux-low.h (struct linux_target_ops)
12812 <supports_range_stepping>: New field.
12813 (struct lwp_info) <step_range_start, step_range_end>: New fields.
12814 * linux-x86-low.c (x86_supports_range_stepping): New.
12815 (the_low_target) <supports_range_stepping>: Set to
12816 x86_supports_range_stepping.
12817 * server.c (handle_v_cont): Handle 'r' action.
12818 (handle_v_requests): Append ";r" if the target supports range
12820 * target.h (struct thread_resume) <step_range_start,
12821 step_range_end>: New fields.
12822 (struct target_ops) <supports_range_stepping>:
12824 (target_supports_range_stepping): New macro.
12826 2013-05-17 Joel Brobecker <brobecker@adacore.com>
12828 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
12829 confusion in comment.
12831 2013-05-17 Joel Brobecker <brobecker@adacore.com>
12833 * lynx-low.c (struct process_info_private): New type.
12834 (lynx_add_process): New function.
12835 (lynx_create_inferior, lynx_attach): Replace calls to
12836 add_process by calls to lynx_add_process.
12837 (lynx_resume): If PTID is null, then try using
12838 current_process()->private->last_wait_event_ptid.
12840 (lynx_clear_inferiors): Delete. The contents of that function
12841 has been inlined in lynx_mourn;
12842 (lynx_wait_1): Save the ptid in the process's private data.
12843 (lynx_mourn): Free the process' private data. Replace call
12844 to lynx_clear_inferiors by call to clear_inferiors.
12846 2013-05-17 Yao Qi <yao@codesourcery.com>
12848 * i386-low.c (i386_length_and_rw_bits): Move the comment to
12851 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
12853 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
12854 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
12855 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
12856 PT_TEXT_END_ADDR guards. Update comments.
12857 (linux_target_op) <read_offsets>: Conditionally define to
12858 linux_read_offsets if the target is UCLIBC and if it defines
12859 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
12861 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
12862 Andrew Jenner <andrew@codesourcery.com>
12864 * Makefile.in (SFILES): Add linux-nios2-low.c.
12865 (clean): Add action to delete nios2-linux.c.
12866 (nios2-linux.c): New rule.
12867 * configure.srv: Add nios2*-*-linux*.
12868 * linux-nios2-low.c: New.
12870 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
12872 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
12874 2013-04-25 Hui Zhu <hui@codesourcery.com>
12877 * ax.c (ax_printf): Add fflush.
12879 2013-04-22 Tom Tromey <tromey@redhat.com>
12881 * Makefile.in (SFILES): Add filestuff.c.
12882 (OBS): Add filestuff.o.
12883 (filestuff.o): New target.
12884 * config.in, configure: Rebuild.
12885 * configure.ac: Check for fdwalk, pipe2.
12887 2013-04-17 Pedro Alves <palves@redhat.com>
12889 * configure.ac (USE_THREAD_DB): Delete variable.
12890 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
12891 Don't AC_SUBST USE_THREAD_DB.
12892 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
12893 * config.in, configure: Regenerate.
12895 2013-04-16 Pedro Alves <palves@redhat.com>
12897 * linux-low.h (struct lwp_info) <thread_known>: Move under
12898 the USE_THREAD_DB #ifdef.
12900 2013-04-16 Pedro Alves <palves@redhat.com>
12902 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
12903 (linux-low.o): Delete rule.
12904 * linux-low.h: Always include "gdb_thread_db.h" instead of
12905 conditionally including thread_db.h.
12906 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
12909 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
12911 * Makefile.in (install-only): Fix make install regression.
12913 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
12915 Convert man pages to texinfo, new gdbinit.5 texinfo page.
12916 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
12918 * gdbserver.1: Remove.
12920 2013-03-22 Pedro Alves <palves@redhat.com>
12922 * linux-low.c (handle_extended_wait): Don't call
12923 linux_enable_event_reporting.
12925 2013-03-15 Tony Theodore <tonyt@logyst.com>
12928 * Makefile.in (SHELL): Use @SHELL@.
12930 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
12932 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
12935 2013-03-13 Joel Brobecker <brobecker@adacore.com>
12937 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
12938 Remove extraneous NULL element.
12940 2013-03-13 Yao Qi <yao@codesourcery.com>
12942 * tracepoint.c (traceframe_read_tsv): Look for the last matched
12943 'V' block in trace frame.
12945 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
12947 * target.h (struct target_ops): Add btrace ops.
12948 (target_supports_btrace): New macro.
12949 (target_enable_btrace): New macro.
12950 (target_disable_btrace): New macro.
12951 (target_read_btrace): New macro.
12952 * gdbthread.h (struct thread_info): Add btrace field.
12953 * server.c: Include btrace-common.h.
12954 (handle_btrace_general_set): New function.
12955 (handle_btrace_enable): New function.
12956 (handle_btrace_disable): New function.
12957 (handle_general_set): Call handle_btrace_general_set.
12958 (handle_qxfer_btrace): New function.
12959 (struct qxfer qxfer_packets[]): Add btrace entry.
12960 * inferiors.c (remove_thread): Disable btrace.
12961 * linux-low: Include linux-btrace.h.
12962 (linux_low_enable_btrace): New function.
12963 (linux_low_read_btrace): New function.
12964 (linux_target_ops): Add btrace ops.
12965 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
12966 Add srv_linux_btrace=yes.
12967 (x86_64-*-linux*): Add linux-btrace.o.
12968 Add srv_linux_btrace=yes.
12969 * configure.ac: Define HAVE_LINUX_BTRACE.
12970 * config.in: Regenerated.
12971 * configure: Regenerated.
12973 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
12975 * server.c (handle_qxfer): Preserve error message if -3 is
12977 (qxfer): Document the -3 return value.
12979 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
12981 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
12982 (linux_btrace_h): New variable.
12983 (linux-btrace.o): New rule.
12985 2013-03-08 Stan Shebs <stan@codesourcery.com>
12986 Hafiz Abid Qadeer <abidh@codesourcery.com>
12988 * tracepoint.c (trace_buffer_size): New global.
12989 (DEFAULT_TRACE_BUFFER_SIZE): New define.
12990 (init_trace_buffer): Change to one-argument function. Allocate
12991 trace buffer memory.
12992 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
12993 handle QTBuffer:size packet.
12994 (cmd_bigqtbuffer_size): New function.
12995 (initialize_tracepoint): Call init_trace_buffer with
12996 DEFAULT_TRACE_BUFFER_SIZE.
12997 * server.c (handle_query): Add QTBuffer:size in the
13000 2013-03-07 Yao Qi <yao@codesourcery.com>
13002 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
13003 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
13005 (cmd_qtsp): Adjust condition. Do post increment.
13006 Set cur_action and cur_step_action back to 0.
13008 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
13011 * linux-low.c (linux_write_memory): Return early success if LEN is
13014 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
13016 * configure.srv: Add x86_64-*-cygwin* as target.
13018 2013-02-28 Tom Tromey <tromey@redhat.com>
13020 * configure.ac: Invoke AC_SYS_LARGEFILE.
13021 * configure, config.in: Rebuild.
13023 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
13025 * win32-low.c: Throughout, fix format strings and casts of
13026 printf-like functions to avoid type related warnings on all
13028 (get_child_debug_event): Print dwDebugEventCode as hex since
13029 that's how it's usually documented.
13031 2013-02-28 Yao Qi <yao@codesourcery.com>
13033 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
13036 2013-02-27 Jiong Wang <jiwang@tilera.com>
13038 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
13039 (reg-tilegx32.c): New rule.
13040 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
13041 * linux-tile-low.c (tile_arch_setup): New function. Invoke
13042 different register info initializer according to elf class.
13043 (init_registers_tilgx32): New function. The tilegx32 register info
13045 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
13046 (tile_store_gregset): Likewise.
13048 2013-02-27 Yao Qi <yao@codesourcery.com>
13050 * server.c (process_point_options): Print debug message when
13051 debug_threads is true.
13053 2013-02-26 Yao Qi <yao@codesourcery.com>
13055 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
13057 2013-02-19 Pedro Alves <palves@redhat.com>
13058 Kai Tietz <ktietz@redhat.com>
13062 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
13063 instead of strtoul to extract address from packet.
13064 (process_serial_event) <'z'>: Likewise.
13066 2013-02-18 Yao Qi <yao@codesourcery.com>
13068 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
13070 2013-02-14 Pedro Alves <palves@redhat.com>
13074 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
13075 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
13077 2013-02-14 Pedro Alves <palves@redhat.com>
13079 * tracepoint.c (cmd_qtdpsrc): Use savestring.
13081 2013-02-14 Pedro Alves <palves@redhat.com>
13083 * tracepoint.c (save_string): Delete.
13084 (add_tracepoint_action): Use savestring instead of save_string.
13086 2013-02-12 Pedro Alves <palves@redhat.com>
13088 * linux-xtensa-low.c: Ditto.
13089 * xtensa-xtregs.c: Ditto.
13091 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
13093 * thread-db.c (thread_db_get_tls_address): NULL pointer check
13096 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
13098 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
13099 aarch64_num_wp_regs and aarch64_num_bp_regs to
13100 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
13102 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
13104 * linux-aarch64-low.c (ps_get_thread_area): Replace
13105 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
13107 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
13108 Marcus Shawcroft <marcus.shawcroft@arm.com>
13109 Nigel Stephens <nigel.stephens@arm.com>
13110 Yufeng Zhang <yufeng.zhang@arm.com>
13112 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
13113 (aarch64.c, aarch64-without-fpu.c): New targets.
13114 * configure.srv (aarch64*-*-linux*): New.
13115 * linux-aarch64-low.c: New file.
13117 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
13119 * linux-low.c (handle_extended_wait, linux_create_inferior)
13120 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
13121 (dequeue_one_deferred_signal, linux_resume_one_thread)
13122 (fetch_register, linux_write_memory, linux_enable_event_reporting)
13123 (linux_tracefork_grandchild, linux_test_for_tracefork)
13124 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
13125 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
13126 where the argument is 0.
13128 2013-01-25 Yao Qi <yao@codesourcery.com>
13130 * event-loop.c: Include "queue.h".
13131 (gdb_event_p): New typedef.
13132 (struct gdb_event) <next_event>: Remove.
13133 (event_queue): Change to QUEUE(gdb_event_p).
13134 (async_queue_event): Remove.
13135 (gdb_event_xfree): New.
13136 (initialize_event_loop): New.
13137 (process_event): Use API from QUEUE.
13138 (wait_for_event): Likewise.
13139 * server.c (main): Call initialize_event_loop.
13140 * server.h (initialize_event_loop): Declare.
13142 2013-01-18 Yao Qi <yao@codesourcery.com>
13144 * ax.h (struct eval_agent_expr_context): New.
13145 (gdb_eval_agent_expr): Update declaration.
13146 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
13147 TFRAME. Add new argument CTX.
13148 * server.h (struct eval_agent_expr_context): Declare.
13149 (agent_mem_read, agent_tsv_read): Update declaration.
13150 (agent_mem_read_string): Likewise.
13151 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
13152 (add_traceframe_block): Add new argument TPOINT.
13153 Increase TPOINT->traceframe_usage.
13154 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
13155 eval_tracepoint_agent_expr.
13156 (condition_true_at_tracepoint): Likewise.
13157 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
13158 (agent_mem_read_string, agent_tsv_read): Likewise.
13160 2013-01-16 Yao Qi <yao@codesourcery.com>
13162 * linux-low.c (linux_resume_one_lwp): Don't check
13163 'lwp->bp_reinsert != 0'.
13165 2013-01-07 Joel Brobecker <brobecker@adacore.com>
13166 Pedro Alves <palves@redhat.com>
13168 * lynx-low.c (ptrace_request_to_str): Define a temporary
13169 macro and use it to simplify this function's implementation.
13171 2013-01-07 Joel Brobecker <brobecker@adacore.com>
13173 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
13176 2013-01-07 Joel Brobecker <brobecker@adacore.com>
13178 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
13180 2013-01-07 Joel Brobecker <brobecker@adacore.com>
13182 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
13184 2013-01-07 Joel Brobecker <brobecker@adacore.com>
13186 * lynx-low.c (lynx_resume): Use the resume_info parameter
13187 to determine the ptid for the lynx_ptrace call, unless
13188 it is equal to minus_one_ptid, in which case we use the
13189 ptid of the current_inferior.
13190 (lynx_wait_1): After having received a thread create/exit
13191 event, resume the inferior's execution using the signaling
13192 thread's ptid, rather than the old ptid.
13194 2013-01-07 Joel Brobecker <brobecker@adacore.com>
13196 * lynx-low.c (lynx_resume): Delete variable ret.
13198 2013-01-01 Joel Brobecker <brobecker@adacore.com>
13200 * gdbreplay.c (gdbreplay_version): Update copyright year.
13201 * server.c (gdbserver_version): Likewise.
13203 2012-12-17 Joel Brobecker <brobecker@adacore.com>
13205 * lynx-low.c (lynx_wait_1): Add debug trace before adding
13208 2012-12-17 Joel Brobecker <brobecker@adacore.com>
13210 * lynx-low.c (ptrace_request_to_str): Add handling for
13211 PTRACE_GETTRACESIG.
13213 2012-12-17 Joel Brobecker <brobecker@adacore.com>
13215 * lynx-low.c (lynx_attach): Delete variable new_process.
13217 2012-12-17 Joel Brobecker <brobecker@adacore.com>
13219 * lynx-low.c (lynx_create_inferior): Delete variable
13222 2012-12-17 Joel Brobecker <brobecker@adacore.com>
13224 * lynx-low.c (ptrace_request_to_str): Do not handle
13225 PTRACE_GETTHREADLIST if this macro does not exist.
13227 2012-12-15 Yao Qi <yao@codesourcery.com>
13229 * Makefile.in (OBS): Add notif.o.
13230 * notif.c, notif.h: New.
13231 * server.c: Include "notif.h".
13232 (struct vstop_notif) <next>: Remove.
13234 (queue_stop_reply): Update.
13235 (push_event, send_next_stop_reply): Remove.
13236 (discard_queued_stop_replies): Update.
13237 (notif_stop): New variable.
13238 (handle_v_stopped): Remove.
13239 (handle_v_requests): Don't call handle_v_stopped. Call
13240 handle_ack_notif instead.
13241 (queue_stop_reply_callback): Call notif_event_enque instead
13242 of queue_stop_reply.
13243 (handle_status): Don't call send_next_stop_reply, call
13244 notif_write_event instead.
13245 (kill_inferior_callback): Likewise.
13246 (detach_or_kill_inferior_callback): Likewise.
13247 (main): Call initialize_notif.
13248 (process_serial_event): Call QUEUE_is_empty.
13249 (handle_target_event): Call notif_push instead of push event.
13250 * server.h (push_event): Remove declaration.
13252 2012-12-10 Tom Tromey <tromey@redhat.com>
13254 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
13255 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
13258 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
13259 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
13260 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
13261 (amd64-linux-ipa.o, ax.o): Rewrite.
13262 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
13263 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
13264 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
13265 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
13266 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
13267 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
13268 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
13269 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
13270 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
13271 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
13272 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
13273 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
13274 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
13275 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
13276 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
13277 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
13278 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
13279 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
13280 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
13281 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
13282 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
13283 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
13284 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
13285 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
13286 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
13287 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
13288 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
13289 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
13290 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
13291 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
13292 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
13293 (reg-tilegx.o): Remove.
13294 (all_object_files): New macro.
13295 Include .deps files.
13296 * aclocal.m4, configure: Rebuild.
13297 * acinclude.m4: Include depstand.m4, lead-dot.m4.
13298 * configure.ac: Invoke ZW_CREATE_DEPDIR,
13299 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
13301 2012-12-05 Tom Tromey <tromey@redhat.com>
13304 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
13306 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
13308 * configure.ac: Check for linux/perf_event.h.
13309 * config.in: Regenerated.
13310 * configure: Regenerated.
13312 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
13314 * hostio.c (handle_readlink): Decrease buffer size
13315 parameter passed to readlink by one byte.
13317 2012-11-26 Yao Qi <yao@codesourcery.com>
13319 * configure.ac (build_warnings): Append '-Wempty-body'.
13320 * configure: Regenerated.
13321 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
13324 2012-11-15 Pierre Muller <muller@sourceware.org>
13326 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
13327 * config.in: Regenerate.
13328 * configure: Regenerate.
13329 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
13330 Use "gdb_wait.h" header instead of <sys/wait.h> header.
13331 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
13332 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
13334 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
13335 instead of <sys/wait.h> header.
13336 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
13338 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
13340 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
13341 (various make rules): Remove -DGDBSERVER
13343 2012-11-09 Yao Qi <yao@codesourcery.com>
13345 * spu-low.c (current_ptid): Move it to ..
13346 * gdbthread.h: ... here. New.
13347 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
13348 * server.c (myresume, process_serial_event): Likewise.
13349 * thread-db.c (thread_db_find_new_threads): Likewise.
13350 * tracepoint.c (run_inferior_command): Likewise.
13352 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
13354 * server.c (handle_search_memory_1): Include access length in
13357 2012-09-05 Michael Brandt <michael.brandt@axis.com>
13359 * linux-crisv32-low.c: Fix compile errors.
13361 2012-09-04 Yao Qi <yao@codesourcery.com>
13363 * tracepoint.c (cmd_qtsv): Adjust debug message.
13364 Don't check CUR_TPOINT.
13366 2012-08-28 Yao Qi <yao@codesourcery.com>
13368 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
13369 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
13370 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
13371 Remove declarations of xmalloc, xreallloc, xstrdup and
13373 * Makefile.in (libiberty_h): New.
13374 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
13375 (linux-bfin-low.o): Append dependency 'libiberty.h'.
13377 2012-08-23 Yao Qi <yao@codesourcery.com>
13379 * server.h: Remove declaration of 'xsnprintf'.
13381 2012-08-22 Keith Seitz <keiths@redhat.com>
13383 * server.h: Include build-gnulib-gbserver/config.h.
13384 * gdbreplay.c: Likewise.
13386 2012-08-08 Doug Evans <dje@google.com>
13388 * Makefile.in (SFILES): Add gdb_vecs.c.
13389 (OBS): Add gdb_vecs.o.
13390 (gdb_vecs_h, host_defs_h): New variables.
13391 (thread-db.o): Add $(gdb_vecs_h) dependency.
13392 (gdb_vecs.o): New rule.
13393 * thread-db.c: #include "gdb_vecs.h".
13394 (thread_db_load_search): Use a vector to iterate over path elements.
13395 Handle text appearing after "$pdir".
13397 * configure.ac: Add check for strstr.
13398 * config.in: Regenerate.
13399 * configure: Regenerate.
13401 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
13403 * hostio.c (handle_pread): If pread fails, fall back to attempting
13405 (handle_pwrite): Likewise for pwrite.
13407 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
13409 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
13410 between unsupported TYPE and unimplementable ADDR/LEN combination.
13411 (arm_insert_point): Act on new return value.
13413 2012-07-31 Pedro Alves <palves@redhat.com>
13415 * server.c (process_point_options): Only skip tokens if we find
13416 one that is unrecognized. Don't treat 'X' specially while
13417 skipping unrecognized tokens.
13419 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
13421 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
13422 to 4-byte-align HW breakpoint addresses for Thumb.
13424 2012-07-27 Yao Qi <yao@codesourcery.com>
13428 * server.h: Declare gdb_agent_about_to_close.
13429 * target.c (kill_inferior): Include "agent.h".
13430 New. Send command 'kill'.
13431 * target.h (kill_inferior): Removed macro.
13432 * tracepoint.c (gdb_agent_about_to_close): New.
13433 (gdb_agent_helper_thread): Handle command 'close'.
13434 Wait endlessly until the inferior stops.
13435 Install gdb_agent_remove_socket to atexit hook.
13436 (agent_socket_name): New static variable.
13437 (gdb_agent_socket_init): Replace local variable 'name' with
13438 'agent_socket_name'.
13439 (gdb_agent_remove_socket): New.
13441 2012-07-27 Yao Qi <yao@codesourcery.com>
13443 * server.c (process_point_options): Stop at 'X' when parsing.
13445 2012-07-19 Michael Eager <eager@eagercon.com>
13447 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
13449 * linux-x86-low.c (x86_insert_point, x86_remove_point):
13450 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
13451 hardware breakpoint.
13453 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
13455 * gdbserver/linux-low.c (initialize_low): Call
13456 linux_ptrace_init_warnings.
13458 2012-07-02 Doug Evans <dje@google.com>
13460 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
13463 2012-07-02 Stan Shebs <stan@codesourcery.com>
13465 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
13466 (ax.o): Add it to build rule.
13468 (OBS): Add format.o.
13469 (IPA_OBS): Add format.o.
13470 * server.c (handle_query): Claim support for breakpoint commands.
13471 (process_point_options): Add command case.
13472 (process_serial_event): Leave running if there are printfs in
13474 * mem-break.h (any_persistent_commands): Declare.
13475 (add_breakpoint_commands): Declare.
13476 (gdb_no_commands_at_breakpoint): Declare.
13477 (run_breakpoint_commands): Declare.
13478 * mem-break.c (struct point_command_list): New struct.
13479 (struct breakpoint): New field command_list.
13480 (any_persistent_commands): New function.
13481 (add_commands_to_breakpoint): New function.
13482 (add_breakpoint_commands): New function.
13483 (gdb_no_commands_at_breakpoint): New function.
13484 (run_breakpoint_commands): New function.
13485 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
13487 * ax.c: Include format.h.
13488 (ax_printf): New function.
13489 (gdb_eval_agent_expr): Add printf opcode.
13491 2012-06-13 Yao Qi <yao@codesourcery.com>
13493 * server.c (start_inferior): Remove duplicated writes to fields
13494 'last_resume_kind' and 'last_status' of 'current_inferior'.
13496 2012-06-12 Yao Qi <yao@codesourcery.com>
13497 Pedro Alves <palves@redhat.com>
13499 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
13501 * server.c (handle_v_cont): Extend comment.
13503 2012-06-11 Yao Qi <yao@codesourcery.com>
13505 * linux-low.c (linux_attach): Add 'static'.
13507 2012-06-06 Yao Qi <yao@codesourcery.com>
13509 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
13511 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
13513 Fix gcc -flto compilation warning.
13514 * server.c (main): Make variable multi_mode and attach volatile.
13516 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
13518 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
13519 if the platform doesn't know about it.
13521 2012-05-30 Jeff Kenton <jkenton@tilera.com>
13523 * Makefile.in (SFILES): Add linux-tile-low.c.
13524 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
13525 * configure.srv: Handle tilegx-*-linux*.
13526 * linux-tile-low.c: New file.
13528 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13530 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
13532 2012-05-24 Pedro Alves <palves@redhat.com>
13536 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
13538 2012-05-24 Pedro Alves <palves@redhat.com>
13542 Replace target_signal with gdb_signal throughout.
13544 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
13546 * linux-low.c (linux_store_registers): Avoid the copying sequence
13547 when no data has been retrieved by ptrace.
13549 2012-05-22 Will Deacon <will.deacon@arm.com>
13551 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
13552 Include asm/ptrace.h.
13553 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
13556 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
13558 * linux-low.c (linux_store_registers): Don't re-retrieve data
13559 with ptrace that has already been obtained from /proc. Always
13560 copy any data retrieved with ptrace to the buffer supplied.
13562 2012-05-11 Yao Qi <yao@codesourcery.com>
13563 Pedro Alves <palves@redhat.com>
13565 * linux-low.c (enum stopping_threads_kind): New.
13566 (stopping_threads): Change type to `enum stopping_threads_kind'.
13567 (handle_extended_wait): If stopping and suspending threads, leave
13568 the new_lwp suspended too.
13569 (linux_wait_for_event): Adjust.
13570 (stop_all_lwps): Set `stopping_threads' to
13571 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
13572 whether we're suspending threads or just stopping them. Assert no
13575 2012-04-29 Yao Qi <yao@codesourcery.com>
13577 * server.h: Move some code to ...
13578 * gdbthread.h: ... here. New.
13579 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
13580 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
13581 (nto-low.o, win32-low.o): Likewise.
13582 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
13583 * regcache.c, remote-utils.c, server.c: Likewise.
13584 * target.c, tracepoint.c, win32-low.c: Likewise.
13586 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
13588 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
13589 (PTRACE_ARG4_TYPE): Likewise.
13590 (PTRACE_XFER_TYPE): Likewise.
13591 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
13592 ptrace to PTRACE_ARG3_TYPE.
13593 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
13594 (PTRACE_ARG4_TYPE): Likewise.
13595 (PTRACE_XFER_TYPE): Likewise.
13596 (linux_detach_one_lwp): Cast fourth argument of
13597 ptrace to long then PTRACE_ARG4_TYPE.
13598 (regsets_fetch_inferior_registers): Cast third argument of
13599 ptrace to long then PTRACE_ARG3_TYPE.
13600 (regsets_store_inferior_registers): Likewise.
13602 2012-04-20 Pedro Alves <palves@redhat.com>
13604 * configure: Regenerate.
13606 2012-04-19 Pedro Alves <palves@redhat.com>
13608 * Makefile.in (GNULIB_BUILDDIR): New.
13609 (LIBGNU, INCGNU, GNULIB_H): Adjust.
13610 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
13611 (all, install-only, uninstall, clean-info, all-lib, clean): No
13612 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
13613 (maintainer-clean realclean distclean): Use subdir_do.
13615 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
13616 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
13617 * acinclude.m4: Include acx_configure_dir.m4.
13618 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
13619 calls. Call AC_PROG_RANLIB. Configure gnulib using
13622 (GNULIB_STDINT_H): Adjust.
13623 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
13624 * gdbreplay.c: Include build-gnulib/config.h.
13625 * server.h: Likewise.
13626 * aclocal.m4: Regenerate.
13627 * config.in: Regenerate.
13628 * configure: Regenerate.
13630 2012-04-19 Pedro Alves <palves@redhat.com>
13632 * Makefile.in (LIBGNU, INCGNU): Adjust.
13633 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
13634 (all, install-only, uninstall, clean-info, all-lib, clean)
13635 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
13636 * configure.ac: Adjust AC_OUTPUT output.
13637 * aclocal.m4: Regenerate.
13638 * configure: Regenerate.
13640 2012-04-19 Pedro Alves <palves@redhat.com>
13642 * Makefile.in (generated_files): New.
13643 (server_h): Remove the explicit dependency on config.h, and depend
13644 on $generated_files.
13646 2012-04-19 Pedro Alves <palves@redhat.com>
13648 * Makefile.in (INCGNU): Add -Ignulib.
13650 2012-04-19 Pedro Alves <palves@redhat.com>
13652 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
13653 (INCGNU): ... this, and spell out -I here.
13654 (GNULIB_LIB): Rename to ...
13655 (LIBGNU): ... this.
13656 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
13658 2012-04-19 Pedro Alves <palves@redhat.com>
13660 * config.in: Regenerate.
13662 2012-04-19 Pedro Alves <palves@redhat.com>
13664 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
13665 * server.h (memmem): Remove declaration.
13666 * config.in: Regenerate.
13667 * configure: Regenerate.
13669 2012-04-19 Yao Qi <yao@codesourcery.com>
13671 * Makefile.in (SFILES): Add common/vec.c.
13675 2012-04-19 Yao Qi <yao@codesourcery.com>
13677 * remote-utils.c (prepare_resume_reply): Replace with macro
13678 target_core_of_thread.
13679 * server.c (handle_qxfer_threads_proper): Likewise.
13680 * target.h (traget_core_of_thread): New macro.
13682 2012-04-18 Pedro Alves <palves@redhat.com>
13684 * aclocal.m4: Regenerate.
13685 * configure: Regenerate.
13687 2012-04-16 Yao Qi <yao@codesourcery.com>
13689 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
13690 duplicated on address.
13692 2012-04-16 Yao Qi <yao@codesourcery.com>
13694 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
13695 (struct tracepoint_action_ops) <send>: New field.
13696 (m_tracepoint_action_send, r_tracepoint_action_send): New.
13697 (agent_expr_send, x_tracepoint_action_send): New.
13698 (l_tracepoint_action_send): New.
13699 (cmd_qtdp): Download and install tracepoint
13700 according to `use_agent'.
13701 (run_inferior_command): Add one more parameter `len'.
13703 (tracepoint_send_agent): New.
13704 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
13706 2012-04-16 Yao Qi <yao@codesourcery.com>
13708 * tracepoint.c (download_tracepoints): Moved to ...
13709 (cmd_qtstart): ... here.
13711 2012-04-14 Yao Qi <yao@codesourcery.com>
13713 * tracepoint.c: Include inttypes.h.
13714 (struct collect_memory_action): Use sized types.
13715 (struct tracepoint): Likewise.
13716 (cmd_qtdp, stop_tracing): Update print specifiers.
13717 (cmd_qtp, response_tracepoint): Likewise.
13718 (collect_data_at_tracepoint): Likewise.
13719 (collect_data_at_step): Likewise.
13721 2012-04-14 Yao Qi <yao@codesourcery.com>
13723 Import gnulib module inttypes.
13724 * aclocal.m4, config.in, configure: Regenerated.
13726 2012-04-14 Yao Qi <yao@codesourcery.com>
13728 * Makefile.in (maintainer-clean, realclean, distclean): Remove
13729 Makefile and config.status at last.
13731 2012-04-13 Yao Qi <yao@codesourcery.com>
13733 * tracepoint.c: Include stdint.h unconditionally.
13735 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
13737 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
13738 on BFD_HAVE_SYS_PROCFS_TYPE.
13739 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
13740 * configure: Regenerate.
13741 * config.in: Likewise.
13743 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
13745 * Makefile.in (clean): Also remove x32.c x32-linux.c
13746 x32-avx.c x32-avx-linux.c.
13747 (x32.o): New target.
13749 (x32-linux.o): Likewise.
13750 (x32-linux.c): Likewise.
13751 (x32-avx.o): Likewise.
13752 (x32-avx.c): Likewise.
13753 (x32-avx-linux.o): Likewise.
13754 (x32-avx-linux.c): Likewise.
13756 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
13757 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
13758 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
13759 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
13760 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
13761 i386/x32-avx-linux.xml.
13763 * linux-x86-low.c (init_registers_x32_linux): New prototype.
13764 (init_registers_x32_avx_linux): Likwise.
13765 (x86_linux_update_xmltarget): Call init_registers_x32_linux
13766 or init_registers_x32_avx_linux if linux_is_elf64 is false.
13768 2012-04-13 Pedro Alves <palves@redhat.com>
13770 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
13771 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
13772 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
13773 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
13776 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
13778 * linux-x86-low.c (compat_x32_clock_t): New.
13779 (compat_x32_siginfo_t): Likewise.
13780 (compat_x32_siginfo_from_siginfo): Likewise.
13781 (siginfo_from_compat_x32_siginfo): Likewise.
13782 (linux_is_elf64): Likewise.
13783 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
13784 and siginfo_from_compat_x32_siginfo for x32.
13785 (x86_arch_setup): Set linux_is_elf64.
13787 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
13790 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
13792 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
13793 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
13794 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
13795 compatible with process.
13797 2012-04-12 Yao Qi <yao@codesourcery.com>
13799 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
13800 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
13801 (install-only, install-info, clean): Handle sub dir gnulib.
13802 (all-lib, am--refresh): New targets.
13803 (memmem.o): Remove target.
13804 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
13805 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
13806 (AC_REPLACE_FUNCS): Remove memmem.
13807 Invoke gl_INIT and AM_INIT_AUTOMAKE.
13808 (AC_OUTPUT): Generate Makefile in gnulib/.
13809 * aclocal.m4, config.in, configure: Regenerated.
13811 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
13813 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
13815 2012-04-05 Pedro Alves <palves@redhat.com>
13817 -Werror=strict-aliasing
13819 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
13822 2012-04-04 Pedro Alves <palves@redhat.com>
13824 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
13825 (sparc_store_gregset_from_stack, sparc_store_gregset)
13826 (sparc_breakpoint_at): Fix formatting.
13828 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
13830 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
13832 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
13833 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
13834 * config.in: Regenerate.
13835 * configure: Likewise.
13837 2012-03-29 Pedro Alves <palves@redhat.com>
13839 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
13840 Correct ptrace arguments.
13842 2012-03-28 Pedro Alves <palves@redhat.com>
13844 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
13845 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
13846 (IA64_FR1_REGNUM): New defines.
13847 (ia64_fetch_register): New.
13848 (the_low_target): Install it.
13849 * linux-low.h (struct linux_target_ops) <fetch_register>: New
13851 * linux-low.c (linux_fetch_registers): Try the
13852 the_low_target.fetch_register hook first.
13854 * linux-arm-low.c (the_low_target): Adjust.
13855 * linux-bfin-low.c (the_low_target): Adjust.
13856 * linux-cris-low.c (the_low_target): Adjust.
13857 * linux-crisv32-low.c (the_low_target): Adjust.
13858 * linux-m32r-low.c (the_low_target): Adjust.
13859 * linux-m68k-low.c (the_low_target): Adjust.
13860 * linux-mips-low.c (the_low_target): Adjust.
13861 * linux-ppc-low.c (the_low_target): Adjust.
13862 * linux-s390-low.c (the_low_target): Adjust.
13863 * linux-sh-low.c (the_low_target): Adjust.
13864 * linux-sparc-low.c (the_low_target): Adjust.
13865 * linux-tic6x-low.c (the_low_target): Adjust.
13866 * linux-x86-low.c (the_low_target): Adjust.
13867 * linux-xtensa-low.c (the_low_target): Adjust.
13869 2012-03-26 Pedro Alves <palves@redhat.com>
13871 * server.c (handle_qxfer_libraries): Don't bail early if
13872 the_target->qxfer_libraries_svr4 is not NULL.
13874 2012-03-26 Pedro Alves <palves@redhat.com>
13876 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
13878 2012-03-23 Pedro Alves <palves@redhat.com>
13880 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
13881 "library-list-svr4" element's start tag when the the DSO list is
13884 2012-03-23 Pedro Alves <palves@redhat.com>
13886 * linux-low.c (read_one_ptr): Read the inferior's pointer through
13887 a variable whose type size is the same as the inferior's pointer
13890 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
13892 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
13894 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
13895 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
13896 * linux-low.h: Include <signal.h>.
13897 (struct siginfo): Remove forward declaration.
13898 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
13901 2012-03-21 Mike Frysinger <vapier@gentoo.org>
13903 * .gitignore: Ignore more files.
13905 2012-03-19 Pedro Alves <palves@redhat.com>
13906 Jan Kratochvil <jan.kratochvil@redhat.com>
13908 * server.c (cont_thread, general_thread): Add describing comments.
13909 (start_inferior): Clear `cont_thread'.
13910 (handle_v_cont): Don't set `cont_thread' if resuming all threads
13913 2012-03-15 Yao Qi <yao@codesourcery.com>
13915 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
13917 (cmd_qtdp): ... here.
13919 2012-03-15 Yao Qi <yao@codesourcery.com>
13921 * tracepoint.c (struct tracepoint_action_ops): New.
13922 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
13923 (m_tracepoint_action_download): New.
13924 (r_tracepoint_action_download): New.
13925 (x_tracepoint_action_download): New.
13926 (l_tracepoint_action_download): New.
13927 (add_tracepoint_action): Install `action->ops' according type.
13928 (download_tracepoint_1): Move code `download' function pointer
13929 of various tracepoint_action_ops.
13931 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
13933 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
13934 linux_ptrace_attach_warnings.
13936 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
13938 * Makefile.in (linux-ptrace.o): New.
13939 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
13940 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
13941 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
13942 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
13943 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
13945 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
13947 2012-03-08 Yao Qi <yao@codesourcery.com>
13948 Pedro Alves <palves@redhat.com>
13950 Fix PR server/13392.
13951 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
13952 offset of JMP insn.
13953 * tracepoint.c (remove_tracepoint): New.
13954 (cmd_qtdp): Call remove_tracepoint when failed to install.
13956 2012-03-07 Pedro Alves <palves@redhat.com>
13958 * linux-low.c (get_detach_signal): New.
13959 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
13960 Pass on pending signals to PTRACE_DETACH. Check the result of the
13962 * server.c (program_signals, program_signals_p): New.
13963 (handle_general_set): Handle QProgramSignals.
13964 * server.h (program_signals, program_signals_p): Declare.
13966 2012-03-05 Pedro Alves <palves@redhat.com>
13967 Jan Kratochvil <jan.kratochvil@redhat.com>
13969 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
13972 2012-03-03 Yao Qi <yao@codesourcery.com>
13974 * tracepoint.c (tracepoint_look_up_symbols): Update call to
13975 agent_look_up_symbols.
13977 2012-03-03 Yao Qi <yao@codesourcery.com>
13979 * Makefile.in (linux-low.o): Keep dependence on agent.h.
13980 (linux-x86-low.o): Likewise.
13981 * server.h: Remove in_process_agent_loaded.
13982 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
13986 2012-03-03 Yao Qi <yao@codesourcery.com>
13988 * tracepoint.c (gdb_agent_capability): New global.
13989 (in_process_agent_loaded_ust): Renamed to
13990 `in_process_agent_supports_ust'.
13992 (in_process_agent_supports_ust): Call agent_capability_check.
13993 (clear_installed_tracepoints): Assert that agent supports
13996 2012-03-03 Yao Qi <yao@codesourcery.com>
13998 * linux-low.c (linux_supports_agent): New.
13999 (linux_target_ops): Initialize field `supports_agent' with
14000 linux_supports_agent.
14001 * target.h (struct target_ops) <supports_agent>: New.
14002 (target_supports_agent): New macro.
14003 * server.c (handle_general_set): Handle packet 'QAgent'.
14004 (handle_query): Send `QAgent+'.
14005 * Makefile.in (server.o): Depends on agent.h.
14007 2012-03-03 Yao Qi <yao@codesourcery.com>
14009 * Makefile.in (OBS): Add agent.o.
14010 Add new rule for agent.o.
14011 Track dependence of tracepoint.c on agent.h.
14012 * tracepoint.c (run_inferior_command_1):
14013 (run_inferior_command): Call agent_run_command.
14014 (gdb_ust_connect_sync_socket): Deleted. Move it to
14016 (resume_thread, stop_thread): Likewise.
14017 (gdb_ust_socket_init): Renamed to ...
14018 (gdb_agent_socket_init): ... New.
14019 (gdb_ust_thread): Renamed to ...
14020 (gdb_agent_helper_thread): ... New.
14021 (gdb_ust_init): Move some code to ...
14022 (gdb_agent_init): ... here. New.
14023 [HAVE_UST]: Call gdb_ust_init.
14024 (initialize_tracepoint_ftlib): Call gdb_agent_init.
14025 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
14026 * config.in, configure: Regenerated.
14028 2012-03-02 Pedro Alves <palves@redhat.com>
14030 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
14031 * linux-low.c (struct simple_pid_list): New.
14032 (stopped_pids): New a struct simple_pid_list pointer.
14033 (add_to_pid_list, pull_pid_from_list): New.
14034 (handle_extended_wait): Don't assume the first signal new children
14035 report is SIGSTOP. Adjust call to pull_pid_from_list.
14036 (linux_wait_for_lwp): Adjust.
14038 2012-03-02 Yao Qi <yao@codesourcery.com>
14040 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
14043 2012-03-02 Yao Qi <yao@codesourcery.com>
14045 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
14046 `stop_pc' and `tpoint'. Update caller.
14048 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
14050 * linux-low.h (linux_target_ops): Add regset_bitmap member.
14051 * linux-low.c (use_linux_regsets): New macro.
14052 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
14053 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
14054 (linux_register_in_regsets): New function.
14055 (usr_fetch_inferior_registers): Skip registers covered by
14057 (usr_store_inferior_registers): Likewise.
14058 (usr_fetch_inferior_registers): New macro.
14059 (usr_store_inferior_registers): Likewise.
14060 (linux_fetch_registers): Handle mixed regset/non-regset targets.
14061 (linux_store_registers): Likewise.
14062 * linux-mips-low.c (init_registers_mips_dsp_linux): New
14064 (init_registers_mips64_dsp_linux): Likewise.
14065 (init_registers_mips_linux): New macro.
14066 (init_registers_mips_dsp_linux): Likewise.
14067 (mips_dsp_num_regs): Likewise.
14068 (DSP_BASE, DSP_CONTROL): New fallback macros.
14069 (mips_base_regs): New macro.
14070 (mips_regmap): Use it. Fix the size.
14071 (mips_dsp_regmap): New variable.
14072 (mips_dsp_regset_bitmap): Likewise.
14073 (mips_arch_setup): New function.
14074 (mips_cannot_fetch_register): Use the_low_target.regmap rather
14076 (mips_cannot_store_register): Likewise.
14077 (the_low_target): Update .arch_setup, .num_regs and .regmap
14078 initializers. Add .regset_bitmap initializer.
14079 * linux-arm-low.c (the_low_target): Add .regset_bitmap
14081 * linux-bfin-low.c (the_low_target): Likewise.
14082 * linux-cris-low.c (the_low_target): Likewise.
14083 * linux-crisv32-low.c (the_low_target): Likewise.
14084 * linux-ia64-low.c (the_low_target): Likewise.
14085 * linux-m32r-low.c (the_low_target): Likewise.
14086 * linux-m68k-low.c (the_low_target): Likewise.
14087 * linux-ppc-low.c (the_low_target): Likewise.
14088 * linux-s390-low.c (the_low_target): Likewise.
14089 * linux-sh-low.c (the_low_target): Likewise.
14090 * linux-sparc-low.c (the_low_target): Likewise.
14091 * linux-tic6x-low.c (the_low_target): Likewise.
14092 * linux-x86-low.c (the_low_target): Likewise.
14093 * linux-xtensa-low.c (the_low_target): Likewise.
14094 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
14095 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
14096 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
14098 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
14099 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
14101 2012-02-29 Yao Qi <yao@codesourcery.com>
14102 Pedro Alves <palves@redhat.com>
14104 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
14105 `step_over_finished' is true.
14107 2012-02-27 Pedro Alves <palves@redhat.com>
14109 * linux-low.c (pid_is_stopped): Delete, moved to common/.
14110 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
14112 2012-02-27 Pedro Alves <palves@redhat.com>
14115 * linux-low.c (pid_is_stopped): New.
14116 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
14118 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
14120 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
14123 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
14125 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
14127 2012-02-24 Luis Machado <lgustavo@codesourcery>
14129 * server.c (handle_query): Advertise support for target-side
14130 breakpoint condition evaluation.
14131 (process_point_options): New function.
14132 (process_serial_event): When inserting a breakpoint, check for
14133 a target-side condition that should be evaluated.
14135 * mem-break.c: Include regcache.h and ax.h.
14136 (point_cond_list_t): New data structure.
14137 (breakpoint) <cond_list>: New field.
14138 (find_gdb_breakpoint_at): Make non-static.
14139 (delete_gdb_breakpoint_at): Clear any target-side
14141 (clear_gdb_breakpoint_conditions): New function.
14142 (add_condition_to_breakpoint): Likewise.
14143 (add_breakpoint_condition): Likewise.
14144 (gdb_condition_true_at_breakpoint): Likewise.
14145 (gdb_breakpoint_here): Return result directly instead
14146 of going through a local variable.
14148 * mem-break.h (find_gdb_breakpoint_at): New prototype.
14149 (clear_gdb_breakpoint_conditions): Likewise.
14150 (add_breakpoint_condition): Likewise.
14151 (gdb_condition_true_at_breakpoint): Likewise.
14153 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
14154 (need_step_over_p): Take target-side breakpoint condition into
14157 2012-02-24 Luis Machado <lgustavo@codesourcery>
14159 * server.h: Include tracepoint.h.
14160 (agent_mem_read, agent_get_trace_state_variable_value,
14161 agent_set_trace_state_variable_value,
14162 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
14163 get_set_tsv_func_addr): New prototypes.
14165 * ax.h: New include file.
14166 * ax.c: New source file.
14168 * tracepoint.c: Include ax.h.
14169 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
14170 agent_expr, eval_result_type): Move to ax.h.
14171 (parse_agent_expr): Rename to ...
14172 (gdb_parse_agent_expr): ... this, make it non-static and move
14174 (unparse_agent_expr) Rename to ...
14175 (gdb_unparse_agent_expr): ... this, make it non-static and move
14177 (eval_agent_expr): Rename to ...
14178 (eval_tracepoint_agent_expr): ... this.
14179 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
14180 forward declarations.
14181 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
14182 (agent_get_trace_state_variable_value): New function.
14183 (agent_set_trace_state_variable_value): New function.
14184 (cmd_qtdp): Call gdb_parse_agent_expr (...).
14185 (response_tracepoint): Call gdb_unparse_agent_expr (...).
14186 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
14187 (condition_true_at_tracepoint): Likewise.
14188 (parse_agent_expr): Rename to ...
14189 (gdb_parse_agent_expr): ... this and move to ax.c.
14190 (unparse_agent_expr): Rename to ...
14191 (gdb_unparse_agent_expr): ... this and move to ax.c.
14192 (gdb_agent_op_name): Move to ax.c.
14193 (eval_agent_expr): Rename to ...
14194 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
14196 (eval_tracepoint_agent_expr): New function.
14197 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
14199 (current_insn_ptr, emit_error, struct bytecode_address): Move to
14201 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
14202 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
14203 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
14204 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
14205 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
14206 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
14207 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
14208 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
14209 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
14210 (compile_bytecodes): Remove forward declaration.
14211 (is_goto_target): Move to ax.c.
14212 (compile_bytecodes): Move to ax.c and call
14213 agent_get_trace_state_variable_value (...) and
14214 agent_set_trace_state_variable_value (...).
14216 * Makefile.in: Update ax.c and IPA dependencies.
14218 2012-02-24 Pedro Alves <palves@redhat.com>
14220 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
14221 (cmd_bigqtbuffer_circular): ... this. Only handle
14222 'QTBuffer:circular:'.
14223 (handle_tracepoint_general_set): Adjust.
14225 2012-02-16 Yao Qi <yao@codesourcery.com>
14227 * inferiors.c: Move code to ...
14228 * dll.c: .... here. New.
14229 * server.h: Declare clear_dlls.
14230 * Makefile.in (SFILES): Add dll.c.
14234 2012-02-11 Yao Qi <yao@codesourcery.com>
14236 * server.c: (handle_monitor_command): Add a new parameter
14238 (handle_query): Update caller.
14240 2012-02-09 Joel Brobecker <brobecker@adacore.com>
14242 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
14243 * configure, config.in: Regenerate.
14244 * hostio.c: Provide an alternate implementation if HAVE_READLINK
14247 2012-02-02 Pedro Alves <palves@redhat.com>
14249 Try SIGKILL first, then PTRACE_KILL.
14250 * linux-low.c (linux_kill_one_lwp): New.
14251 (linux_kill_one_lwp): Rename to ...
14252 (kill_one_lwp_callback): ... this. Use the new
14253 linux_kill_one_lwp.
14255 2012-02-02 Pedro Alves <palves@redhat.com>
14257 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
14260 2012-01-27 Pedro Alves <palves@redhat.com>
14262 * linux-low.c (linux_child_pid_to_exec_file): Delete.
14263 (elf_64_file_p): Make static.
14264 (linux_pid_exe_is_elf_64_file): New.
14265 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
14266 Delete declarations.
14267 (linux_pid_exe_is_elf_64_file): Declare.
14268 * linux-x86-low.c (x86_arch_setup): Use
14269 linux_pid_exe_is_elf_64_file.
14271 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
14273 * linux-low.c (linux_wait_for_event_1): Rename to ...
14274 (linux_wait_for_event): ... here and merge it with former
14275 linux_wait_for_event - new variable wait_ptid, use it.
14276 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
14278 2012-01-23 Pedro Alves <palves@redhat.com>
14280 * server.c (main): Avoid yet another case of infinite loop while
14281 detaching/killing after a longjmp.
14283 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
14286 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
14288 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
14290 * hostio.c (handle_readlink): New function.
14291 (handle_vFile): Call it to handle "vFile:readlink" packets.
14293 2012-01-20 Pedro Alves <palves@redhat.com>
14294 Ulrich Weigand <ulrich.weigand@linaro.org>
14296 * server.c (handle_v_requests): Only support vAttach and vRun to
14297 start multiple processes when in extended protocol mode.
14299 2012-01-17 Pedro Alves <palves@redhat.com>
14301 * tracepoint.c (initialize_tracepoint): Use mmap instead of
14302 memalign plus mprotect to allocate the scratch buffer.
14304 2012-01-13 Pedro Alves <palves@redhat.com>
14306 * server.c (attach_inferior): Clear `cont_thread'.
14308 2012-01-13 Pedro Alves <palves@redhat.com>
14310 * server.c (main): Avoid infinite loop while detaching/killing
14313 2012-01-09 Doug Evans <dje@google.com>
14315 * server.c (start_inferior): Set last_ptid in --wrapper case.
14317 2012-01-06 Yao Qi <yao@codesourcery.com>
14319 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
14321 [IN_PROCESS_AGENT] (debug_agent): New global variable.
14323 2012-01-04 Yao Qi <yao@codesourcery.com>
14325 * tracepoint.c (cmd_qtdp): Print debug message
14326 for static tracepoint.
14328 2012-01-04 Yao Qi <yao@codesourcery.com>
14330 * tracepoint.c (trace_vdebug): Differentiate debug message
14331 between gdbserver and IPA.
14333 2012-01-03 Yao Qi <yao@codesourcery.com>
14335 * tracepoint.c (tracepoint_was_hit): Don't collect for
14338 2012-01-02 Joel Brobecker <brobecker@adacore.com>
14340 * terminal.h: Reformat copyright header.
14342 2012-01-02 Joel Brobecker <brobecker@adacore.com>
14344 * server.c (gdbserver_version): Update copyright year.
14345 * gdbreplay.c (gdbreplay_version): Likewise.
14347 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
14349 * linux-low.c (linux_create_inferior): Put empty if clause for write.
14352 2011-12-18 Hui Zhu <teawater@gmail.com>
14353 * linux-low.c (linux_create_inferior): Save return value to ret.
14355 2011-12-18 Hui Zhu <teawater@gmail.com>
14357 * linux-low.c (linux_create_inferior): Save return value to ret.
14359 2011-12-16 Doug Evans <dje@google.com>
14361 * linux-low.c (linux_create_inferior): If stdio connection,
14362 redirect stdin from /dev/null, stdout to stderr.
14363 * remote-utils.c (remote_is_stdio): New static global.
14364 (remote_connection_is_stdio): New function.
14365 (remote_prepare): Handle stdio connection.
14366 (remote_open): Ditto.
14367 (remote_close): Don't close stdin for stdio connections.
14368 (read_prim,write_prim): New functions. Replace all calls to
14369 read/write to these.
14370 * server.c (main): Watch for "-" argument. Move call to
14371 remote_prepare before start_inferior.
14372 * server.h (STDIO_CONNECTION_NAME): New macro.
14373 (remote_connection_is_stdio): Declare.
14375 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
14376 in debugging output.
14378 2011-12-15 Yao Qi <yao@codesourcery.com>
14380 * tracepoint.c: Include sys/syscall.h.
14381 (gdb_ust_thread): Remove preprocessor conditional.
14383 2011-12-14 Pedro Alves <pedro@codesourcery.com>
14385 * linux-low.c (linux_detach_one_lwp): Call
14386 the_low_target.prepare_to_resume before detaching.
14388 2011-12-14 Yao Qi <yao@codesourcery.com>
14390 * tracepoint.c (gdb_ust_thread): Don't ignore return value
14393 2011-12-14 Yao Qi <yao@codesourcery.com>
14395 * i386-low.c (i386_low_stopped_data_address): Initialize local
14396 variable `control'.
14398 2011-12-13 Pedro Alves <pedro@codesourcery.com>
14402 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
14403 DR_CONTROL unless necessary. Extend comments.
14404 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
14405 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
14407 2011-12-13 Yao Qi <yao@codesourcery.com>
14409 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
14411 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
14413 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
14415 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
14416 Print new debug message for such case.
14418 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
14420 Fix overlapping memcpy.
14421 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
14422 the read_inferior_memory transfer.
14423 (delete_fast_tracepoint_jump): New variable buf. Use it for the
14424 write_inferior_memory transfer.
14425 (set_fast_tracepoint_jump): New variable buf. Use it for the
14426 read_inferior_memory and write_inferior_memory transfers.
14427 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
14428 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
14429 Use it for the write_inferior_memory transfer.
14430 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
14433 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
14435 * linux-low.c (fetch_register, store_register): Make code
14436 consistent, fix formatting.
14438 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
14440 * linux-low.c (usr_store_inferior_registers): Factor out code
14441 to handle individual registers into...
14442 (store_register): ... this new function.
14444 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
14446 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
14447 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
14448 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
14449 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
14450 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
14451 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
14452 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
14453 (srv_xmlfiles): Add new XML files.
14455 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
14457 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
14458 (init_registers_s390_linux32v1): Add prototype.
14459 (init_registers_s390_linux32v2): Likewise.
14460 (init_registers_s390_linux64v1): Likewise.
14461 (init_registers_s390_linux64v2): Likewise.
14462 (init_registers_s390x_linux64v1): Likewise.
14463 (init_registers_s390x_linux64v2): Likewise.
14464 (s390_num_regs): Increment to 52.
14465 (s390_regmap): Add orig_r2 register.
14466 (s390_num_regs_3264): Increment to 68.
14467 (s390_regmap_3264): Add orig_r2 register.
14468 (s390_collect_ptrace_register): Handle orig_r2 register.
14469 (s390_supply_ptrace_register): Likewise.
14470 (s390_fill_last_break): New function.
14471 (s390_store_last_break): Likewise.
14472 (s390_fill_system_call): New function.
14473 (s390_store_system_call): Likewise.
14474 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
14476 (s390_check_regset): New function.
14477 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
14478 NT_S390_SYSTEM_CALL regsets and use appropriate description.
14479 Update target_regsets for available register sets.
14481 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
14482 Jan Kratochvil <jan.kratochvil@redhat.com>
14484 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
14485 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
14487 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
14488 * linux-low.h (struct process_info_private): New member r_debug.
14489 * server.c (handle_qxfer_libraries): Call
14490 the_target->qxfer_libraries_svr4.
14491 (handle_qxfer_libraries_svr4): New function.
14492 (qxfer_packets): New entry "libraries-svr4".
14493 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
14494 * target.h (struct target_ops): New member qxfer_libraries_svr4.
14495 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
14496 PACKET_qXfer_libraries_svr4.
14498 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
14500 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
14501 PSW address/mask between 8-byte and 16-byte formats.
14502 (s390_supply_ptrace_register): Likewise.
14503 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
14504 basic addressing mode bit.
14506 2011-11-24 Stan Shebs <stan@codesourcery.com>
14508 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
14510 2011-11-17 Stan Shebs <stan@codesourcery.com>
14512 * tracepoint.c (struct tracepoint): New field traceframe_usage.
14513 (tracing_start_time): New global.
14514 (tracing_stop_time): New global.
14515 (tracing_user_name): New global.
14516 (tracing_notes): New global.
14517 (tracing_stop_note): New global.
14518 (cmd_qtstart): Set traceframe_usage, start_time.
14519 (stop_tracing): Set stop_time.
14520 (cmd_qtstatus): Report additional status.
14521 (cmd_qtp): New function.
14522 (handle_tracepoint_query): Call it.
14523 (cmd_qtnotes): New function.
14524 (handle_tracepoint_general_set): Call it.
14525 (get_timestamp): Rename from tsv_get_timestamp.
14527 2011-11-14 Stan Shebs <stan@codesourcery.com>
14528 Kwok Cheung Yeung <kcy@codesourcery.com>
14530 * linux-x86-low.c (small_jump_insn): New.
14531 (i386_install_fast_tracepoint_jump_pad): Add arguments for
14532 trampoline and error message, build a trampoline and issue a small
14533 jump instruction to it.
14534 (x86_install_fast_tracepoint_jump_pad): Add arguments for
14535 trampoline and error message.
14536 (x86_get_min_fast_tracepoint_insn_len): New.
14537 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
14538 * linux-low.h (struct linux_target_ops): Add arguments to
14539 install_fast_tracepoint_jump_pad operation, add new operation.
14540 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
14542 (linux_get_min_fast_tracepoint_insn_len): New function.
14543 (linux_target_op): Add new operation.
14544 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
14545 (gdb_trampoline_buffer_end): Ditto.
14546 (gdb_trampoline_buffer_error): Ditto.
14547 (struct ipa_sym_addresses): Add fields for new IPA variables.
14548 (symbol_list): Add entries for new IPA variables.
14549 (struct tracepoint): Add fields to hold the address range of the
14550 trampoline used by the tracepoint.
14551 (trampoline_buffer_head): New static variable.
14552 (trampoline_buffer_tail): Ditto.
14553 (claim_trampoline_space): New function.
14554 (have_fast_tracepoint_trampoline_buffer): New function.
14555 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
14557 (install_fast_tracepoint): Ditto, also add error buffer argument.
14558 (cmd_qtminftpilen): New function.
14559 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
14560 (fast_tracepoint_from_trampoline_address): New function.
14561 (fast_tracepoint_collecting): Handle trampoline as part of jump
14563 (set_trampoline_buffer_space): New function.
14564 (initialize_tracepoint): Initialize new IPA variables.
14565 * target.h (struct target_ops): Add arguments to
14566 install_fast_tracepoint_jump_pad operation, add new
14567 get_min_fast_tracepoint_insn_len operation.
14568 (target_get_min_fast_tracepoint_insn_len): New.
14569 (install_fast_tracepoint_jump_pad): Add arguments.
14570 * server.h (IPA_BUFSIZ): Define.
14571 * linux-i386-ipa.c: Include extra header files.
14572 (initialize_fast_tracepoint_trampoline_buffer): New function.
14573 (initialize_low_tracepoint): Call it.
14574 * server.h (set_trampoline_buffer_space): Declare.
14575 (claim_trampoline_space): Ditto.
14576 (have_fast_tracepoint_trampoline_buffer): Ditto.
14578 2011-11-14 Yao Qi <yao@codesourcery.com>
14580 * server.c (handle_query): Handle InstallInTrace for qSupported.
14581 * tracepoint.c (add_tracepoint): Sort list.
14582 (install_tracepoint, download_tracepoint): New.
14583 (cmd_qtdp): Call them to install and download tracepoints.
14584 (sort_tracepoints): Removed.
14585 (cmd_qtstart): Update.
14587 2011-11-14 Yao Qi <yao@codesourcery.com>
14589 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
14590 * mem-break.h: Declare.
14591 * tracepoint.c (cmd_qtstart): Move some code to ...
14592 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
14594 (download_tracepoints): Move some code to ...
14595 (download_tracepoint_1): ... here. New.
14597 2011-11-08 Yao Qi <yao@codesourcery.com>
14599 * remote-utils.c (relocate_instruction): A comment fix.
14601 2011-11-07 Joel Brobecker <brobecker@adacore.com>
14603 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
14604 (i386_dr_low_get_control, i386_dr_low_get_status): Use
14605 dr_status_mirror and dr_control_mirror from debug_reg_state.
14606 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
14607 (i386_initial_stuff): Remove use of deleted globals.
14608 (i386_get_thread_context, i386_set_thread_context,
14609 i386_thread_added): Use dr_status_mirror and dr_control_mirror
14610 from debug_reg_state.
14612 2011-11-05 Yao Qi <yao@codesourcery.com>
14614 * tracepoint.c (gdb_collect): Loop over tracepoints of same
14615 address as TPOINT's.
14617 2011-11-02 Stan Shebs <stan@codesourcery.com>
14619 * tracepoint.c (agent_mem_read_string): New function.
14620 (eval_agent_expr): Call it for tracenz.
14621 * server.c (handle_query): Report support for tracenz.
14623 2011-11-02 Yao Qi <yao@codesourcery.com>
14625 * tracepoint.c (cmd_qtstart): Remove unused local variables.
14627 2011-11-02 Yao Qi <yao@codesourcery.com>
14629 * target.h: Fix a typo in comment.
14631 2011-10-31 Pedro Alves <pedro@codesourcery.com>
14633 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
14634 clobber the breakpoints' shadows with fast tracepoint jumps.
14635 * mem-break.h (check_mem_write): Add `myaddr' parameter.
14636 * target.c (write_inferior_memory): Also pass MYADDR down to
14639 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
14641 * configure.ac: Check support for personality routine.
14642 * configure: Regenerate.
14643 * config.in: Likewise.
14644 * linux-low.c: Include <sys/personality.h>.
14645 Define ADDR_NO_RANDOMIZE if necessary.
14646 (linux_create_inferior): Disable address space randomization when
14647 forking inferior, if requested.
14648 (linux_supports_disable_randomization): New function.
14649 (linux_target_ops): Install it.
14650 * server.h (disable_randomization): Declare.
14651 * server.c (disable_randomization): New global variable.
14652 (handle_general_set): Handle QDisableRandomization.
14653 (handle_query): Likewise for qSupported.
14654 (main): Support --disable-randomization and --no-disable-randomization
14655 command line arguments.
14656 * target.h (struct target_ops): Add supports_disable_randomization.
14657 (target_supports_disable_randomization): New macro.
14659 2011-09-29 Mike Frysinger <vapier@gentoo.org>
14661 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
14663 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
14664 [!PT_GETDSBT] (target_loadmap): New definition.
14665 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
14666 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
14667 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
14668 and PT_GETDSBT to LINUX_LOADMAP.
14669 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
14670 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
14672 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
14674 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
14675 (arm_linux_hwbp_cap): New static variable.
14676 (arm_linux_get_hwbp_cap): Replace by ...
14677 (arm_linux_init_hwbp_cap): ... this new function.
14678 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
14679 (arm_linux_get_hw_watchpoint_count): Likewise.
14680 (arm_linux_get_hw_watchpoint_max_length): Likewise.
14681 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
14682 (arm_prepare_to_resume): Use perror_with_name instead of error.
14684 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
14686 * linux-arm-low.c: Include <signal.h>.
14687 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
14688 (struct arm_linux_hwbp_cap): New data type.
14689 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
14690 (struct arm_linux_hw_breakpoint): New data type.
14691 (MAX_BPTS, MAX_WPTS): Define.
14692 (struct arch_process_info, struct arch_lwp_info): New data types.
14693 (arm_linux_get_hwbp_cap): New function.
14694 (arm_linux_get_hw_breakpoint_count): Likewise.
14695 (arm_linux_get_hw_watchpoint_count): Likewise.
14696 (arm_linux_get_hw_watchpoint_max_length): Likewise.
14697 (arm_hwbp_control_initialize): Likewise.
14698 (arm_hwbp_control_is_enabled): Likewise.
14699 (arm_hwbp_control_is_initialized): Likewise.
14700 (arm_hwbp_control_disable): Likewise.
14701 (arm_linux_hw_breakpoint_equal): Likewise.
14702 (arm_linux_hw_point_initialize): Likewise.
14703 (struct update_registers_data): New data structure.
14704 (update_registers_callback: New function.
14705 (arm_insert_point): Likewise.
14706 (arm_remove_point): Likewise.
14707 (arm_stopped_by_watchpoint): Likewise.
14708 (arm_stopped_data_address): Likewise.
14709 (arm_new_process): Likewise.
14710 (arm_new_thread): Likewise.
14711 (arm_prepare_to_resume): Likewise.
14712 (the_low_target): Register arm_insert_point, arm_remove_point,
14713 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
14714 arm_new_thread, and arm_prepare_to_resume.
14716 2011-09-15 Stan Shebs <stan@codesourcery.com>
14718 * server.h (struct emit_ops): Add compare-goto fields.
14719 * tracepoint.c (gdb_agent_op_sizes): New table.
14720 (emit_eq_goto): New function.
14721 (emit_ne_goto): New function.
14722 (emit_lt_goto): New function.
14723 (emit_le_goto): New function.
14724 (emit_gt_goto): New function.
14725 (emit_ge_goto): New function.
14726 (is_goto_target): New function.
14727 (compile_bytecodes): Recognize special cases of compare-goto
14728 combinations and call specialized emitters for them.
14729 * linux-x86-low.c (amd64_emit_eq_goto): New function.
14730 (amd64_emit_ne_goto): New function.
14731 (amd64_emit_lt_goto): New function.
14732 (amd64_emit_le_goto): New function.
14733 (amd64_emit_gt_goto): New function.
14734 (amd64_emit_ge_goto): New function.
14735 (amd64_emit_ops): Add the new functions.
14736 (i386_emit_eq_goto): New function.
14737 (i386_emit_ne_goto): New function.
14738 (i386_emit_lt_goto): New function.
14739 (i386_emit_le_goto): New function.
14740 (i386_emit_gt_goto): New function.
14741 (i386_emit_ge_goto): New function.
14742 (i386_emit_ops): Add the new functions.
14744 2011-09-08 Stan Shebs <stan@codesourcery.com>
14746 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
14747 (i386_emit_epilogue): Restore %ebx.
14749 2011-08-31 Jie Zhang <jzhang918@gmail.com>
14751 * server.c (step_thread): Remove definition.
14752 (process_serial_event): Don't handle Hs.
14753 * server.h (step_thread): Remove declaration.
14754 * target.c (set_desired_inferior): Remove use of step_thread.
14756 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
14758 * linux-low.c: Include linux-procfs.h.
14759 (linux_attach_lwp_1): Update comments.
14760 (linux_attach): Scan for existing threads when attaching to a
14761 process that is the tgid.
14762 * Makefile.in: Update dependencies.
14764 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
14766 * configure.srv: Add linux-procfs.o dependencies.
14768 2011-08-14 Yao Qi <yao@codesourcery.com>
14770 * target.h (struct target_ops): Fix indent.
14771 * win32-low.c (win32_target_ops): Fix comment.
14773 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
14774 Yao Qi <yao@codesourcery.com>
14776 * Makefile.in (clean): Remove tic6x-*.c files.
14777 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
14778 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
14779 (tic6x-c64xp-linux.c): Likewise.
14780 * configure.srv: Add support for tic6x-*-uclinux.
14781 * linux-tic6x-low.c: New.
14782 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
14784 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
14785 Yao Qi <yao@codesourcery.com>
14787 * target.h (struct target_ops): Add read_loadmap.
14788 * linux-low.c (struct target_loadseg): New type.
14789 (struct target_loadmap): New type.
14790 (linux_read_loadmap): New function.
14791 (linux_target_ops): Add linux_read_loadmap.
14792 * server.c (handle_query): Support qXfer:fdpic:read packet.
14793 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
14796 2011-08-05 Eli Zaretskii <eliz@gnu.org>
14798 * win32-low.c: Include <stdint.h>.
14800 2011-07-22 Pedro Alves <pedro@codesourcery.com>
14802 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
14803 to the inferior here.
14804 (i386_remove_aligned_watchpoint): Ditto.
14805 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
14806 fit part of the watchpoint in the debug registers.
14807 (i386_update_inferior_debug_regs): New.
14808 (i386_low_insert_watchpoint): Work on a local mirror of the debug
14809 registers, and only update the inferior on success.
14810 (i386_low_remove_watchpoint): Ditto.
14812 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
14814 * linux-low.c (compare_ints, unique, list_threads, show_process,
14815 linux_core_of_thread): Delete.
14816 (linux_target_ops): Change linux_core_of_thread to
14817 linux_common_core_of_thread.
14818 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
14819 * utils.c (malloc_failure): Change type of argument.
14820 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
14821 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
14822 common/linux-osdata.c, common/ptid.c and common/buffer.c.
14823 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
14824 (IPA_OBJS): Add common-utils-ipa.o.
14825 (ptid_h, linux_osdata_h): New macros.
14826 (server_h): Add common/common-utils.h, common/xml-utils.h,
14827 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
14829 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
14830 ptid.o, buffer.o): New rules.
14831 (linux-low.o): Add common/linux-osdata.h as a dependency.
14832 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
14833 * configure.ac: Add AC_HEADER_DIRENT check.
14834 * config.in: Regenerate.
14835 * configure: Regenerate.
14836 * remote-utils.c (xml_escape_text): Delete.
14837 (buffer_grow, buffer_free, buffer_init, buffer_finish,
14838 buffer_xml_printf): Move to common/buffer.c.
14839 * server.c (main): Remove call to initialize_inferiors.
14840 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
14841 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
14842 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
14843 internal_error, gdb_assert, gdb_assert_fail): Delete.
14844 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
14845 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
14847 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
14848 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
14849 initialize_inferiors): Delete.
14851 2011-07-20 Pedro Alves <pedro@codesourcery.com>
14853 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
14856 2011-05-31 Pedro Alves <pedro@codesourcery.com>
14858 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
14860 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
14862 2011-05-26 Yao Qi <yao@codesourcery.com>
14864 * Makefile.in (thread-db.o): Track dependence to
14865 common/gdb_thread_db.h.
14866 * thread-db.c: include gdb_thread_db.h from right place.
14868 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
14870 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
14871 __FILE__ and __LINE__ to internal_error.
14873 2011-05-13 Doug Evans <dje@google.com>
14875 * thread-db.c (try_thread_db_load_from_sdir): New function.
14876 (try_thread_db_load_from_dir): New function.
14877 (thread_db_load_search): Handle $sdir, ignore $pdir.
14878 Remove trying of system directories if search of
14879 libthread-db-search-path fails, that is now done via $sdir.
14881 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
14883 * server.c (handle_query): Add EnableDisableTracepoints to the list
14884 of supported features.
14885 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
14887 (cmd_qtenable_disable): New.
14888 (cmd_qtstart): Install tracepoints even if disabled.
14889 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
14890 receiving a QTEnable or QTDisable packet.
14891 (gdb_collect): Skip data collection if fast tracepoint is disabled.
14892 (ust_marker_to_static_tracepoint): Do not ignore disabled static
14894 (gdb_probe): Skip data collection if static tracepoint is disabled.
14896 2011-05-10 Doug Evans <dje@google.com>
14898 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
14900 2011-05-04 Doug Evans <dje@google.com>
14902 * linux-low.c (linux_join): Skip process lookup.
14903 * spu-low.c (spu_join): Ditto.
14904 * server.c (join_inferiors_callback): Delete.
14905 (process_serial_event): For 'D' packet (detach) call join_inferior
14908 2011-05-04 Joseph Myers <joseph@codesourcery.com>
14910 * README: Don't mention xscale*-*-linux*.
14911 * configure.srv (xscale*-*-linux*): Don't handle target.
14913 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
14915 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
14917 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
14918 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
14919 (i386_emit_void_call_2): Likewise.
14921 2011-04-26 Yao Qi <yao@codesourcery.com>
14923 * linux-low.c: Move common macros to linux-ptrace.h.
14924 Include linux-ptrace.h.
14925 * Makefile.in (linux_ptrace_h): New.
14926 (linux-low.o): Depends on linux-ptrace.h.
14928 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
14930 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
14931 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
14932 (remote_prepare): New function with most of the TCP code from ...
14933 (remote_open): ... here. Detect PORT here unconditionally. Move also
14934 setting transport_is_reliable.
14935 * server.c (run_once): New variable.
14936 (gdbserver_usage): Document it.
14937 (main): Set run_once for `--once'. Call remote_prepare. Exit after
14938 the first run if RUN_ONCE.
14939 * server.h (run_once, remote_prepare): New declarations.
14941 2011-04-19 Tom Tromey <tromey@redhat.com>
14943 * win32-low.c (handle_load_dll): Remove duplicate "the".
14945 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
14947 Remove support for old Cygwin 1.5 versions.
14948 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
14949 function to avoid warning.
14950 (win32_add_one_solib): Use cygwin_conv_path function to avoid
14953 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
14955 * gdbserver/server.h (Macro _): Define it if not available.
14957 2011-03-14 Michael Snyder <msnyder@vmware.com>
14959 * hostio.c (handle_close): Remove unnecessary null test.
14961 2011-03-10 Joel Brobecker <brobecker@adacore.com>
14963 * Makefile.in (maintainer-clean realclean distclean): Remove
14964 "make ... subdir_do" command.
14966 2011-03-10 Michael Snyder <msnyder@vmware.com>
14968 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
14970 * server.c (handle_v_run): Free alloced buffer on early return.
14972 2011-03-09 Yao Qi <yao@codesourcery.com>
14975 2011-03-04 Yao Qi <yao@codesourcery.com>
14977 * Makefile.in: Remove GNU make feature --directory.
14979 2011-03-05 Yao Qi <yao@codesourcery.com>
14981 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
14982 (subdir_do): New make target. Copied from gdb/Makefile.
14983 (maintainer-clean, realclean, distclean, clean): Call corresponding
14984 make targets in common/Makefile.
14986 2011-02-11 Yao Qi <yao@codesourcery.com>
14988 * configure.ac: Call AC_PROG_RANLIB.
14989 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
14990 * configure: Regenerate.
14992 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14994 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
14996 2011-03-06 Yao Qi <yao@codesourcery.com>
14998 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
15000 2011-03-05 Yao Qi <yao@codesourcery.com>
15002 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
15003 (subdir_do): New make target. Copied from gdb/Makefile.
15004 (maintainer-clean, realclean, distclean, clean): Call corresponding
15005 make targets in common/Makefile.
15007 2011-03-04 Yao Qi <yao@codesourcery.com>
15009 * Makefile.in: Remove GNU make feature --directory.
15011 2011-03-04 Michael Snyder <msnyder@vmware.com>
15013 * server.c (queue_stop_reply): Call xmalloc not malloc.
15015 2011-03-02 Michael Snyder <msnyder@vmware.com>
15017 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
15019 2011-02-28 Michael Snyder <msnyder@vmware.com>
15021 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
15022 (cmd_qtframe): Ditto.
15023 (cmd_qtbuffer): Ditto.
15024 (cmd_bigqtbuffer): Ditto.
15026 * utils.c (decimal2str): Initialize 'width' to nine, then
15027 don't mess with it.
15029 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15031 * hostio.c (require_data): Free *data, not data.
15033 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
15035 * hostio.c (require_data): Use free, not xfree.
15037 2011-02-27 Michael Snyder <msnyder@vmware.com>
15039 * server.c (handle_query): Discard unused value.
15041 * hostio.c (require_data): Free malloc memory before returning
15044 2011-02-26 Michael Snyder <msnyder@vmware.com>
15046 * linux-low.c (list_threads): Call closedir for dirent.
15048 2011-02-27 Michael Snyder <msnyder@vmware.com>
15050 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
15051 a case statement falls through.
15053 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
15055 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
15058 2011-02-26 Michael Snyder <msnyder@vmware.com>
15060 * utils.c (decimal2str): Eliminate dead code and dead param.
15061 (pulongest): Drop dead param from call to decimal2str.
15064 2011-02-24 Joel Brobecker <brobecker@adacore.com>
15066 Revert the following patch (not approved yet):
15067 2011-02-21 Hui Zhu <teawater@gmail.com>
15068 * tracepoint.c (tp_printf): New function.
15069 (eval_agent_expr): Handle gdb_agent_op_printf.
15071 2011-02-21 Hui Zhu <teawater@gmail.com>
15073 * tracepoint.c (tp_printf): New function.
15074 (eval_agent_expr): Handle gdb_agent_op_printf.
15076 2011-02-18 Tom Tromey <tromey@redhat.com>
15078 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
15079 (tracepoint.o): Likewise.
15080 * tracepoint.c (enum gdb_agent_op): Use ax.def.
15081 (gdb_agent_op_names): Likewise.
15083 2011-02-18 Tom Tromey <tromey@redhat.com>
15085 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
15086 gdb_agent_op_rot>: New constants.
15087 (gdb_agent_op_names): Add pick and roll.
15088 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
15091 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
15093 * aclocal.m4: Regenerated with aclocal-1.11.1.
15095 2011-02-14 Pedro Alves <pedro@codesourcery.com>
15097 * server.c (handle_qxfer_traceframe_info): New.
15098 (qxfer_packets): Register "traceframe-info".
15099 (handle_query): Report support for qXfer:traceframe-info:read+.
15100 * tracepoint.c (match_blocktype): New.
15101 (traceframe_find_block_type): Rename to ...
15102 (traceframe_walk_blocks): ... this. Add callback filter argument,
15104 (traceframe_find_block_type): New, reimplemented on top of
15105 traceframe_walk_blocks.
15106 (build_traceframe_info_xml): New.
15107 (traceframe_read_info): New.
15108 * server.h (traceframe_read_info): Declare.
15110 2011-02-11 Yao Qi <yao@codesourcery.com>
15112 * configure.ac: Call AC_PROG_RANLIB.
15113 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
15114 * configure: Regenerate.
15116 2011-02-07 Pedro Alves <pedro@codesourcery.com>
15118 * server.c (gdb_read_memory): Change return semantics to allow
15120 (handle_search_memory_1): Adjust.
15121 (process_serial_event) <'m' packet>: Handle partial transfers.
15122 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
15124 2011-01-28 Pedro Alves <pedro@codesourcery.com>
15126 * regcache.c (init_register_cache): Initialize
15127 regcache->register_status.
15128 (free_register_cache): Release regcache->register_status.
15129 (regcache_cpy): Copy register_status.
15130 (registers_to_string): Print 'x's for unavailable registers.
15131 (supply_register): Mark the register's status valid or
15132 unavailable, depending on whether a buffer was passed in or not.
15133 (supply_register_zeroed): New.
15134 (supply_regblock): Mark the registers' status valid or
15135 unavailable, depending on whether a buffer was passed in or not.
15136 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
15137 (struct regcache): New `register_status' field.
15138 (supply_register_zeroed): Declare.
15139 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
15140 supply_register_zeroed, rather than passing a NULL buffer to
15142 * tracepoint.c (fetch_traceframe_registers): Update comment.
15144 2011-01-28 Pedro Alves <pedro@codesourcery.com>
15146 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
15149 2011-01-25 Pedro Alves <pedro@codesourcery.com>
15151 * server.h (decode_xfer_write): Change prototype.
15152 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
15153 and don't extract the annex here.
15154 * server.c (decode_xfer_read): Remove `annex' parameter,
15155 and don't extract the annex here.
15156 (decode_xfer): New.
15157 (struct qxfer): New.
15158 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
15159 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
15160 (handle_qxfer_statictrace): New functions, abstracted out from
15161 handle_query, and made to use the struct qxfer interface.
15162 (handle_threads_qxfer_proper): Rename to ...
15163 (handle_qxfer_threads_proper): ... this.
15164 (handle_threads_qxfer): Rename to ...
15165 (handle_qxfer_threads): ... this. Adjust.
15166 (qxfer_packets): New array.
15167 (handle_qxfer): New function.
15168 (handle_query): Use handle_qxfer.
15170 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
15172 * gdbreplay.c: Shorten lines of >= 80 columns.
15173 * linux-low.c: Ditto.
15174 * linux-ppc-low.c: Ditto.
15175 * linux-s390-low.c: Ditto.
15176 * linux-sparc-low.c: Ditto.
15177 * linux-x86-low.c: Ditto.
15178 * linux-xtensa-low.c: Ditto.
15179 * mem-break.c: Ditto.
15180 * nto-low.c: Ditto.
15181 * regcache.h: Ditto.
15182 * remote-utils.c: Ditto.
15185 * thread-db.c: Ditto.
15186 * tracepoint.c: Ditto.
15188 * win32-low.h: Ditto.
15190 2011-01-05 Joel Brobecker <brobecker@adacore.com>
15192 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
15195 2011-01-01 Joel Brobecker <brobecker@adacore.com>
15197 * server.c (gdbserver_version): Update copyright year in version
15199 * gdbreplay.c (gdbreplay_version): Ditto.
15201 2010-12-29 Jie Zhang <jie.zhang@analog.com>
15203 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
15204 * linux-bfin-low.c: New file.
15205 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
15206 PT_DATA_ADDR for BFIN targets.
15207 * Makefile.in (SFILES): Add linux-bfin-low.c.
15208 (clean): Remove reg-bfin.c.
15209 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
15210 * README: Mention supported Blackfin targets.
15212 2010-12-23 Mike Frysinger <vapier@gentoo.org>
15214 * .gitignore: New file.
15216 2010-11-16 Mike Frysinger <vapier@gentoo.org>
15218 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
15220 2010-10-22 Jie Zhang <jie@codesourcery.com>
15222 * Makefile.in: Add FLAGS_TO_PASS variable.
15223 (install): Remove dependency of install-only and recursively
15224 invoke make for install-only.
15226 2010-10-04 Doug Evans <dje@google.com>
15228 * Makefile.in (uninstall): Use $(DESTDIR).
15230 2010-09-24 Pedro Alves <pedro@codesourcery.com>
15234 * linux-x86-low.c (compat_siginfo_from_siginfo)
15235 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
15236 si_code is < 0. Check for si_code == SI_TIMER before checking for
15239 2010-09-13 Joel Brobecker <brobecker@adacore.com>
15241 * lynx-i386-low.c: New file.
15242 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
15244 2010-09-13 Joel Brobecker <brobecker@adacore.com>
15246 * lynx-low.c (ptrace_request_to_str): Remove handling for
15247 request values that have been removed in LynxOS 5.x.
15249 2010-09-13 Joel Brobecker <brobecker@adacore.com>
15251 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
15254 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
15256 * configure.ac: Add --enable-inprocess-agent option.
15257 * configure: Rebuilt.
15259 2010-09-06 Yao Qi <yao@codesourcery.com>
15261 * linux-low.c (linux_kill): Remove unused variable.
15262 (linux_stabilize_threads): Likewise.
15263 * server.c (start_inferior): Likewise.
15264 (queue_stop_reply_callback): Likewise.
15265 * tracepoint.c (do_action_at_tracepoint): Likewise.
15267 2010-09-06 Yao Qi <yao@codesourcery.com>
15269 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
15272 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
15274 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
15276 2010-09-06 Pedro Alves <pedro@codesourcery.com>
15278 * Makefile.in (install-only): Replace $IPA_DEPFILES with
15281 2010-09-01 Joel Brobecker <brobecker@adacore.com>
15283 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
15284 gdbserver/lynx-ppc-low.c: New files.
15285 * Makefile.in (lynx_low_h): New variable.
15286 (lynx-low.o, lynx-ppc-low.o): New rules.
15287 * configure.ac: On LynxOS, link with -lnetinet.
15288 * configure.srv: Add handling of powerpc-*-lynxos* targets.
15289 * configure: regenerate.
15291 2010-09-01 Joel Brobecker <brobecker@adacore.com>
15293 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
15294 * configure.ac: Add check for vasprintf and vsnprintf.
15295 * configure, config.in: Regenerate.
15296 * server.h (vasprintf, vsnprintf): Add conditional declarations.
15298 2010-09-01 Joel Brobecker <brobecker@adacore.com>
15300 * gdbreplay.c: Move include of alloca.h up, next to include of
15302 * server.h: Add include of malloc.h.
15303 * mem-break.c: Remove include of malloc.h.
15304 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
15306 2010-09-01 Joel Brobecker <brobecker@adacore.com>
15308 * Makefile.in (memmem.o): Build with -Wno-error.
15310 2010-09-01 Joel Brobecker <brobecker@adacore.com>
15312 * utils.c (xsnprintf): Make non-static.
15313 * server.h: Add xsnprintf declaration.
15314 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
15315 replace calls to snprintf by calls to xsnprintf throughout.
15317 2010-09-01 Joel Brobecker <brobecker@adacore.com>
15319 * configure.ac: Add configure check for alloca.
15320 * configure, config.in: Regenerate.
15321 * server.h: Include alloca.h if it exists.
15322 * gdbreplay.c: Include alloca.h if it exists.
15324 2010-08-28 Pedro Alves <pedro@codesourcery.com>
15326 * linux-low.c (__SIGRTMIN): Define if not already defined.
15327 (linux_create_inferior): Check for __ANDROID__ rather than
15329 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
15330 are already deferred.
15331 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
15332 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
15333 stopped and already has a pending signal to report.
15334 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
15335 a pending signal to report or is moving out of a jump pad.
15336 (linux_init_signals): Check for __ANDROID__ rather than
15339 2010-08-28 Pedro Alves <pedro@codesourcery.com>
15341 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
15342 debug_threads check. Avoid a linear search when not doing debug
15345 2010-08-27 Pedro Alves <pedro@codesourcery.com>
15347 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
15348 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
15349 (struct file_handler) <fd>: Change type to gdb_fildes_t.
15350 (process_event): Change local fd's type to gdb_fildes_t.
15351 (create_file_handler): Adjust prototype.
15352 (delete_file_handler): Adjust prototype.
15353 (handle_file_event): Adjust prototype. Use pfildes.
15354 (create_file_event): Adjsut prototype.
15355 * remote-utils.c (remote_desc, listen_desc): Change type to
15357 * server.h: New gdb_fildes_t typedef.
15358 [USE_WIN32API]: Include winsock2.h.
15359 (delete_file_handler, add_file_handler): Adjust prototypes.
15360 (pfildes): Declare.
15361 * utils.c (pfildes): New.
15363 2010-08-27 Pedro Alves <pedro@codesourcery.com>
15365 * configure.ac (build_warnings): Add -Wno-char-subscripts.
15366 * configure: Regenerate.
15368 2010-08-27 Pedro Alves <pedro@codesourcery.com>
15370 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
15371 (linux_done_accessing_memory): ... this.
15372 (linux_target_ops): Adjust.
15373 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
15374 * nto-low.c (nto_target_ops): Adjust comment.
15375 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
15376 * spu-low.c (spu_target_ops): Adjust comment.
15377 * target.h (target_ops): Rename unprepare_to_access_memory field
15378 to done_accessing_memory.
15379 (unprepare_to_access_memory): Rename to ...
15380 (done_accessing_memory): ... this.
15382 2010-08-26 Pedro Alves <pedro@codesourcery.com>
15384 * linux-low.c (linux_prepare_to_access_memory): New.
15385 (linux_unprepare_to_access_memory): New.
15386 (linux_target_ops): Install them.
15387 * server.c (read_memory): Rename to ...
15388 (gdb_read_memory): ... this. Use
15389 prepare_to_access_memory/prepare_to_access_memory.
15390 (write_memory): Rename to ...
15391 (gdb_write_memory): ... this. Use
15392 prepare_to_access_memory/prepare_to_access_memory.
15393 (handle_search_memory_1): Adjust.
15394 (process_serial_event): Adjust.
15395 * target.h (struct target_ops): New fields
15396 prepare_to_access_memory and unprepare_to_access_memory.
15397 (prepare_to_access_memory, unprepare_to_access_memory): New.
15398 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
15399 prepare_to_access_memory/prepare_to_access_memory.
15400 * nto-low.c (nto_target_ops): Adjust.
15401 * spu-low.c (spu_target_ops): Adjust.
15402 * win32-low.c (win32_target_ops): Adjust.
15404 2010-08-26 Pedro Alves <pedro@codesourcery.com>
15406 * Makefile.in (WARN_CFLAGS): Get it from configure.
15407 (WERROR_CFLAGS): New.
15408 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
15409 * configure.ac: Introduce --enable-werror, which adds -Werror to
15410 the compiler command line. Enabled by default. Disable with
15411 --disable-werror. Add -Wdeclaration-after-statement
15412 Wpointer-arith and -Wformat-nonliteral to warning flags.
15413 * configure: Regenerate.
15415 2010-08-26 Pedro Alves <pedro@codesourcery.com>
15417 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
15419 2010-08-26 Pedro Alves <pedro@codesourcery.com>
15421 * gdbreplay.c (remote_error): New.
15423 (expect): Use gdbchar. Check for error reading from GDB.
15424 Clarify sync error output.
15425 (play): Check for errors writing to GDB.
15426 * linux-low.c (sigchld_handler): Really ignore `write' errors.
15427 * remote-utils.c (getpkt): Check for errors writing to the remote
15430 2010-08-25 Pedro Alves <pedro@codesourcery.com>
15432 * linux-low.c (linux_wait_1): Move non-debugging code out of
15433 `debug_threads' control.
15435 2010-08-25 Pedro Alves <pedro@codesourcery.com>
15437 * linux-low.c (linux_wait_1): Don't set last_status here.
15438 * server.c (push_event, queue_stop_reply_callback): Assert we're
15439 not pushing a TARGET_WAITKIND_IGNORE event.
15440 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
15441 (myresume, handle_target_event): Set the thread's last_resume_kind
15442 and last_status from the target returned status.
15444 2010-08-25 Pedro Alves <pedro@codesourcery.com>
15448 * linux-x86-low.c (update_debug_registers_callback): New.
15449 (i386_dr_low_set_addr): Use it.
15450 (i386_dr_low_get_addr): New.
15451 (i386_dr_low_set_control): Use update_debug_registers_callback.
15452 (i386_dr_low_get_control): New.
15453 (i386_dr_low_get_status): Adjust.
15454 * linux-low.c (linux_stop_lwp): New.
15455 * linux-low.h (linux_stop_lwp): Declare.
15457 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
15458 argument instead of a i386_debug_reg_state.
15459 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
15460 a i386_debug_reg_state.
15461 (i386_insert_aligned_watchpoint): Adjust.
15462 (i386_remove_aligned_watchpoint): Adjust.
15463 (i386_low_stopped_data_address): Read the debug registers from the
15464 inferior instead of from the mirrors.
15465 * i386-low.h (struct i386_debug_reg_state): Extend comment.
15466 (i386_dr_low_get_addr): Declare.
15467 (i386_dr_low_get_control): Declare.
15468 (i386_dr_low_get_status): Change prototype.
15470 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
15471 (i386_dr_low_get_addr): New.
15472 (i386_dr_low_get_control): New.
15473 (i386_dr_low_get_status): Adjust prototype. Return
15475 (i386_initial_stuff): Clear dr_status_mirror and
15477 (i386_get_thread_context): Adjust.
15478 (i386_set_thread_context): Adjust.
15479 (i386_thread_added): Adjust.
15481 2010-08-24 Pedro Alves <pedro@codesourcery.com>
15483 * linux-low.h (linux_thread_area): Delete declaration.
15485 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
15487 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
15488 after its termination.
15490 2010-08-09 Pedro Alves <pedro@codesourcery.com>
15492 * linux-low.c (gdb_wants_lwp_stopped): Delete.
15493 (gdb_wants_all_stopped): Delete.
15494 (linux_wait_1): Don't call them.
15495 * server.c (handle_v_cont): Tag all threads as want-stopped.
15496 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
15497 stopped as "client-wants-stopped".
15499 2010-07-31 Pedro Alves <pedro@codesourcery.com>
15501 * Makefile.in (signals_h): New.
15502 (server_h): Depend on it.
15503 (server.o): Don't depend on $(signals_def).
15504 (signals.o): Depend on $(signals_def).
15506 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
15508 * Makefile.in (signals_def): New.
15509 (server_h): Append include/gdb/signals.h and signals_def.
15510 (server.o): Append signals_def.
15512 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
15514 * server.c (handle_target_event): Use target_signal_to_host for
15515 resume_info.sig initialization.
15516 * target.h (struct thread_resume) <sig>: New comment.
15518 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
15520 * server.c (handle_query): strcpy() the returned string from paddress()
15521 instead of sprintf().
15522 * utils.c (paddress): Return phex_nz().
15524 2010-07-07 Joel Brobecker <brobecker@adacore.com>
15526 * server.c (handle_v_cont): Call mourn_inferior if process
15528 (myresume): Likewise.
15530 2010-07-01 Pedro Alves <pedro@codesourcery.com>
15532 Static tracepoints, and integration with UST.
15534 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
15535 * mem-break.c (uninsert_all_breakpoints)
15536 (reinsert_all_breakpoints): New.
15537 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
15538 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
15539 (gdb_agent_ust_loaded, helper_thread_id)
15540 (gdb_agent_helper_thread_id): New macros.
15541 (struct ipa_sym_addresses): Add addr_ust_loaded,
15542 addr_helper_thread_id, addr_cmd_buf.
15543 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
15544 (in_process_agent_loaded_ust): New.
15545 (write_e_ust_not_loaded): New.
15546 (maybe_write_ipa_ust_not_loaded): New.
15547 (struct collect_static_trace_data_action): New.
15548 (enum tracepoint_type) <static_tracepoint>: New.
15549 (struct tracepoint) <handle>: Mention static tracepoints.
15550 (struct static_tracepoint_ctx): New.
15551 (CMD_BUF_SIZE): New.
15552 (add_tracepoint_action): Handle static tracepoint actions.
15553 (unprobe_marker_at): New.
15554 (clear_installed_tracepoints): Handle static tracepoints.
15555 (cmd_qtdp): Handle static tracepoints.
15556 (probe_marker_at): New.
15557 (cmd_qtstart): Handle static tracepoints.
15558 (response_tracepoint): Handle static tracepoints.
15559 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
15560 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
15561 (get_context_regcache): Handle static tracepoints.
15562 (do_action_at_tracepoint): Handle static tracepoint actions.
15563 (traceframe_find_block_type): Handle static trace data blocks.
15564 (traceframe_read_sdata): New.
15565 (download_tracepoints): Download static tracepoint actions.
15566 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
15567 (GDB_PROBE_NAME): New.
15569 (GET_UST_SYM): New.
15572 (ust_marker_to_static_tracepoint): New.
15574 (collect_ust_data_at_tracepoint): New.
15575 (gdb_ust_probe): New.
15576 (UNIX_PATH_MAX, SOCK_DIR): New.
15577 (gdb_ust_connect_sync_socket): New.
15578 (resume_thread, stop_thread): New.
15579 (run_inferior_command): New.
15580 (init_named_socket): New.
15581 (gdb_ust_socket_init): New.
15582 (cstr_to_hexstr): New.
15584 (first_marker, next_marker): New.
15585 (response_ust_marker): New.
15586 (cmd_qtfstm, cmd_qtsstm): New.
15587 (unprobe_marker_at, probe_marker_at): New.
15588 (cmd_qtstmat, gdb_ust_thread): New.
15589 (gdb_ust_init): New.
15590 (initialize_tracepoint_ftlib): Call gdb_ust_init.
15591 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
15592 (ST_REGENTRY): New.
15593 (x86_64_st_collect_regmap): New.
15594 (X86_64_NUM_ST_COLLECT_GREGS): New.
15595 (AMD64_RIP_REGNUM): New.
15596 (supply_static_tracepoint_registers): New.
15597 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
15598 (ST_REGENTRY): New.
15599 (i386_st_collect_regmap): New.
15600 (i386_NUM_ST_COLLECT_GREGS): New.
15601 (supply_static_tracepoint_registers): New.
15602 * server.c (handle_query): Handle qXfer:statictrace:read.
15603 <qSupported>: Report support for StaticTracepoints, and
15604 qXfer:statictrace:read features.
15605 * server.h (traceframe_read_sdata)
15606 (supply_static_tracepoint_registers): Declare.
15607 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
15608 (unpack_varlen_hex): Include in IPA build.
15609 * Makefile.in (ustlibs, ustinc): New.
15610 (IPA_OBJS): Add remote-utils-ipa.o.
15611 ($(IPA_LIB)): Link -ldl and -lpthread.
15613 (IPAGENT_CFLAGS): Add UST_CFLAGS.
15614 * config.in, configure: Regenerate.
15616 2010-06-20 Ian Lance Taylor <iant@google.com>
15617 Pedro Alves <pedro@codesourcery.com>
15619 * linux-x86-low.c (always_true): Delete.
15620 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
15621 trying to fool the compiler with always_true.
15623 2010-06-20 Pedro Alves <pedro@codesourcery.com>
15625 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
15626 conditions in gdbserver.
15628 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
15630 * spu-low.c (spu_read_memory): Wrap around local store limit.
15631 (spu_write_memory): Likewise.
15633 2010-06-15 Pedro Alves <pedro@codesourcery.com>
15635 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
15636 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
15638 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
15640 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
15641 uses with LONGEST uses.
15643 2010-06-14 Stan Shebs <stan@codesourcery.com>
15644 Pedro Alves <pedro@codesourcery.com>
15648 * linux-x86-low.c: Include limits.h.
15650 (always_true): New.
15653 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
15654 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
15655 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
15656 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
15657 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
15658 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
15659 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
15660 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
15661 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
15662 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
15663 (amd64_emit_void_call_2): New.
15664 (amd64_emit_ops): New.
15665 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
15666 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
15667 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
15668 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
15669 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
15670 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
15671 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
15672 (i386_emit_call, i386_emit_reg, i386_emit_pop)
15673 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
15674 (i386_emit_stack_adjust, i386_emit_int_call_1)
15675 (i386_emit_void_call_2): New.
15676 (i386_emit_ops): New.
15677 (x86_emit_ops): New.
15678 (the_low_target): Install x86_emit_ops.
15679 * server.h (struct emit_ops): New.
15680 (get_raw_reg_func_addr): Declare.
15681 (current_insn_ptr, emit_error): Declare.
15682 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
15683 (set_trace_state_variable_value): New defines.
15684 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
15685 addr_get_trace_state_variable_value and
15686 addr_set_trace_state_variable_value.
15687 (symbol_list): New fields for get_raw_reg,
15688 get_trace_state_variable_value and set_trace_state_variable_value.
15689 (condfn): New typedef.
15690 (struct tracepoint): New field `compiled_cond'.
15691 (do_action_at_tracepoint): Clear compiled_cond.
15692 (get_trace_state_variable_value, set_trace_state_variable_value):
15694 (condition_true_at_tracepoint): If there's a compiled condition,
15696 (current_insn_ptr, emit_error): New globals.
15697 (struct bytecode_address): New.
15698 (get_raw_reg_func_addr): New.
15699 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
15700 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
15701 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
15702 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
15703 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
15704 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
15705 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
15706 (compile_tracepoint_condition, compile_bytecodes): New.
15707 * target.h (emit_ops): Forward declare.
15708 (struct target_ops): New field emit_ops.
15709 (target_emit_ops): New.
15710 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
15711 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
15712 * linux-low.c (linux_emit_ops): New.
15713 (linux_target_ops): Install it.
15714 * linux-low.h (struct linux_target_ops): New field emit_ops.
15716 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
15718 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
15719 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
15721 2010-06-01 Pedro Alves <pedro@codesourcery.com>
15722 Stan Shebs <stan@codesourcery.com>
15724 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
15725 (all): Depend on $(extra_libraries).
15726 (install-only): Install the IPA.
15727 (IPA_OBJS, IPA_LIB): New.
15728 (clean): Remove the IPA lib.
15729 (IPAGENT_CFLAGS): New.
15730 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
15731 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
15732 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
15733 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
15734 * configure.ac: Check for atomic builtins support in the compiler.
15735 (IPA_DEPFILES, extra_libraries): Define.
15736 * configure.srv (ipa_obj): Add description.
15737 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
15738 (i[34567]86-*-linux*): Set ipa_obj.
15739 (x86_64-*-linux*): Set ipa_obj.
15740 * linux-low.c (stabilizing_threads): New.
15741 (supports_fast_tracepoints): New.
15742 (linux_detach): Stabilize threads before detaching.
15743 (handle_tracepoints): Handle internal tracing breakpoints. Assert
15744 the lwp is either not stabilizing, or is moving out of a jump pad.
15745 (linux_fast_tracepoint_collecting): New.
15746 (maybe_move_out_of_jump_pad): New.
15747 (enqueue_one_deferred_signal): New.
15748 (dequeue_one_deferred_signal): New.
15749 (linux_wait_for_event_1): If moving out of a jump pad, defer
15750 pending signals to later.
15751 (linux_stabilize_threads): New.
15752 (linux_wait_1): Check if threads need moving out of jump pads, and
15754 (stuck_in_jump_pad_callback): New.
15755 (move_out_of_jump_pad_callback): New.
15756 (lwp_running): New.
15757 (linux_resume_one_lwp): Handle moving out of jump pads.
15758 (linux_set_resume_request): Dequeue deferred signals.
15759 (need_step_over_p): Also step over fast tracepoint jumps.
15760 (start_step_over): Also uninsert fast tracepoint jumps.
15761 (finish_step_over): Also reinsert fast tracepoint jumps.
15762 (linux_install_fast_tracepoint_jump): New.
15763 (linux_target_ops): Install linux_stabilize_threads and
15764 linux_install_fast_tracepoint_jump_pad.
15765 * linux-low.h (linux_target_ops) <get_thread_area,
15766 install_fast_tracepoint_jump_pad>: New fields.
15767 (struct lwp_info) <collecting_fast_tracepoint,
15768 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
15769 (linux_get_thread_area): Declare.
15770 * linux-x86-low.c (jump_insn): New.
15771 (x86_get_thread_area): New.
15772 (append_insns): New.
15773 (push_opcode): New.
15774 (amd64_install_fast_tracepoint_jump_pad): New.
15775 (i386_install_fast_tracepoint_jump_pad): New.
15776 (x86_install_fast_tracepoint_jump_pad): New.
15777 (the_low_target): Install x86_get_thread_area and
15778 x86_install_fast_tracepoint_jump_pad.
15779 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
15780 (struct fast_tracepoint_jump): New.
15781 (fast_tracepoint_jump_insn): New.
15782 (fast_tracepoint_jump_shadow): New.
15783 (find_fast_tracepoint_jump_at): New.
15784 (fast_tracepoint_jump_here): New.
15785 (delete_fast_tracepoint_jump): New.
15786 (set_fast_tracepoint_jump): New.
15787 (uninsert_fast_tracepoint_jumps_at): New.
15788 (reinsert_fast_tracepoint_jumps_at): New.
15789 (set_breakpoint_at): Use write_inferior_memory.
15790 (uninsert_raw_breakpoint): Use write_inferior_memory.
15791 (check_mem_read): Mask out fast tracepoint jumps.
15792 (check_mem_write): Mask out fast tracepoint jumps.
15793 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
15794 (set_fast_tracepoint_jump): Declare.
15795 (delete_fast_tracepoint_jump)
15796 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
15797 (reinsert_fast_tracepoint_jumps_at): Declare.
15798 * regcache.c: Don't compile many functions when building the
15799 in-process agent library.
15800 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
15801 the register buffer in the heap.
15802 (free_register_cache): If the register buffer isn't owned by the
15803 regcache, don't free it.
15804 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
15805 pre-existing register caches.
15806 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
15808 (convert_ascii_to_int): : Constify `from' parameter type.
15809 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
15810 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
15811 the needed buffer in-place.
15812 (relocate_instruction): New.
15813 * server.c (handle_query) <qSymbols>: If the target supports
15814 tracepoints, give it a chance of looking up symbols. Report
15815 support for fast tracepoints.
15816 (handle_status): Stabilize threads.
15817 (process_serial_event): Adjust.
15818 * server.h (struct fast_tracepoint_jump): Forward declare.
15819 (struct process_info) <fast_tracepoint_jumps>: New field.
15820 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
15821 (decode_X_packet, decode_M_packet): Adjust.
15822 (relocate_instruction): Declare.
15823 (in_process_agent_loaded): Declare.
15824 (tracepoint_look_up_symbols): Declare.
15825 (struct fast_tpoint_collect_status): Declare.
15826 (fast_tracepoint_collecting): Declare.
15827 (force_unlock_trace_buffer): Declare.
15828 (handle_tracepoint_bkpts): Declare.
15829 (initialize_low_tracepoint)
15830 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
15831 * target.h (struct target_ops) <stabilize_threads,
15832 install_fast_tracepoint_jump_pad>: New fields.
15833 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
15834 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
15835 [HAVE_STDINT_H]: Include stdint.h.
15836 (trace_debug_1): Rename to ...
15837 (trace_vdebug): ... this.
15838 (trace_debug): Rename to ...
15839 (trace_debug_1): ... this. Add `level' parameter.
15840 (trace_debug): New.
15841 (ATTR_USED, ATTR_NOINLINE): New.
15842 (IP_AGENT_EXPORT): New.
15843 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
15844 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
15845 (about_to_request_buffer_space, trace_buffer_is_full)
15846 (stopping_tracepoint, expr_eval_result, error_tracepoint)
15847 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
15848 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
15849 (traceframe_write_count, traceframes_created)
15850 (trace_state_variables)
15851 New renaming defines.
15852 (struct ipa_sym_addresses): New.
15853 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
15854 (symbol_list): New.
15855 (ipa_sym_addrs): New.
15856 (all_tracepoint_symbols_looked_up): New.
15857 (in_process_agent_loaded): New.
15858 (write_e_ipa_not_loaded): New.
15859 (maybe_write_ipa_not_loaded): New.
15860 (tracepoint_look_up_symbols): New.
15861 (debug_threads) [IN_PROCESS_AGENT]: New.
15862 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
15863 (UNKNOWN_SIDE_EFFECTS): New.
15864 (stop_tracing): New.
15865 (flush_trace_buffer): New.
15866 (stop_tracing_bkpt): New.
15867 (flush_trace_buffer_bkpt): New.
15868 (read_inferior_integer): New.
15869 (read_inferior_uinteger): New.
15870 (read_inferior_data_pointer): New.
15871 (write_inferior_data_pointer): New.
15872 (write_inferior_integer): New.
15873 (write_inferior_uinteger): New.
15874 (struct collect_static_trace_data_action): Delete.
15875 (enum tracepoint_type): New.
15876 (struct tracepoint) <type>: New field `type'.
15877 <actions_str, step_actions, step_actions_str>: Only include in
15879 <orig_size, obj_addr_on_target, adjusted_insn_addr>
15880 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
15881 (tracepoints): Use IP_AGENT_EXPORT.
15882 (last_tracepoint): Don't include in the IPA.
15883 (stopping_tracepoint): Use IP_AGENT_EXPORT.
15884 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
15885 (alloced_trace_state_variables): New.
15886 (trace_state_variables): Use IP_AGENT_EXPORT.
15887 (traceframe_t): Delete unused variable.
15888 (circular_trace_buffer): Don't include in the IPA.
15889 (trace_buffer_start): Delete.
15890 (struct trace_buffer_control): New.
15891 (trace_buffer_free): Delete.
15892 (struct ipa_trace_buffer_control): New.
15893 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
15894 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
15896 (trace_buffer_ctrl): New.
15897 (TRACE_BUFFER_CTRL_CURR): New.
15898 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
15899 Reimplement as macros.
15900 (trace_buffer_wrap): Delete.
15901 (traceframe_write_count, traceframe_read_count)
15902 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
15903 (struct tracepoint_hit_ctx) <type>: New field.
15904 (struct fast_tracepoint_ctx): New.
15905 (memory_barrier): New.
15907 (record_tracepoint_error): Update atomically in the IPA.
15908 (clear_inferior_trace_buffer): New.
15909 (about_to_request_buffer_space): New.
15910 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
15911 updating the same buffer.
15912 (add_tracepoint): Default the tracepoint's type to trap
15913 tracepoint, and orig_size to -1.
15914 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
15915 internal variables.
15916 (create_trace_state_variable): New parameter `gdb'. Handle it.
15917 (clear_installed_tracepoints): Clear fast tracepoint jumps.
15918 (cmd_qtdp): Handle fast tracepoints.
15919 (cmd_qtdv): Adjust.
15920 (max_jump_pad_size): New.
15921 (gdb_jump_pad_head): New.
15922 (get_jump_space_head): New.
15923 (claim_jump_space): New.
15924 (sort_tracepoints): New.
15925 (MAX_JUMP_SIZE): New.
15926 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
15928 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
15929 support. Upload fast traceframes, and delete internal IPA
15931 (stop_tracing_handler): New.
15932 (flush_trace_buffer_handler): New.
15933 (cmd_qtstop): Upload fast tracepoints.
15934 (response_tracepoint): Handle fast tracepoints.
15935 (tracepoint_finished_step): Upload fast traceframes. Set the
15936 tracepoint hit context's tracepoint type.
15937 (handle_tracepoint_bkpts): New.
15938 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
15939 type. Add comment about fast tracepoints.
15940 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
15941 non-existing action_str field.
15942 (get_context_regcache): Handle fast tracepoints.
15943 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
15945 (fast_tracepoint_from_jump_pad_address): New.
15946 (fast_tracepoint_from_ipa_tpoint_address): New.
15947 (collecting_t): New.
15948 (force_unlock_trace_buffer): New.
15949 (fast_tracepoint_collecting): New.
15951 (gdb_collect): New.
15952 (write_inferior_data_ptr): New.
15953 (target_tp_heap): New.
15954 (target_malloc): New.
15955 (download_agent_expr): New.
15957 (download_tracepoints): New.
15958 (download_trace_state_variables): New.
15959 (upload_fast_traceframes): New.
15960 (IPA_FIRST_TRACEFRAME): New.
15961 (IPA_NEXT_TRACEFRAME_1): New.
15962 (IPA_NEXT_TRACEFRAME): New.
15963 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
15964 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
15965 (gdb_jump_pad_buffer_end): New.
15966 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
15967 (initialize_tracepoint): Adjust.
15968 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
15969 buffer. Initialize the low module.
15970 * utils.c (PREFIX, TOOLNAME): New.
15971 (malloc_failure): Use PREFIX.
15972 (error): In the IPA, an error causes an exit.
15973 (fatal, warning): Use PREFIX.
15974 (internal_error): Use TOOLNAME.
15975 (NUMCELLS): Increase to 10.
15976 * configure, config.in: Regenerate.
15978 2010-06-01 Pedro Alves <pedro@codesourcery.com>
15980 * server.c (handle_query) <qSupported>: Do two passes over the
15981 qSupported string to avoid nesting strtok.
15983 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
15985 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
15987 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
15988 -Wl,--dynamic-list.
15989 * configure: Regenerate.
15990 * proc-service.list: New.
15992 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
15994 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
15997 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
15999 * gdbreplay.c (remote_open): Check error return from socket() call by
16000 its equality to -1 not by it being negative.
16001 * remote-utils.c (remote_open): Likewise.
16003 2010-05-23 Pedro Alves <pedro@codesourcery.com>
16005 * config.h: Regenerate.
16007 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
16009 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
16010 doesn't provide PTRACE_GET_THREAD_AREA.
16012 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
16014 * linux-m68k-low.c: Include <asm/ptrace.h>
16015 (ps_get_thread_area): Implement.
16017 2010-05-03 Doug Evans <dje@google.com>
16019 * event-loop.c (struct callback_event): New struct.
16020 (callback_list): New global.
16021 (append_callback_event, delete_callback_event): New functions.
16022 (process_callback): New function.
16023 (start_event_loop): Call it.
16024 * remote-utils.c (NOT_SCHEDULED): Define.
16025 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
16026 moved out of readchar.
16027 (readchar): Rewrite. Call reschedule before returning.
16028 (reset_readchar): New function.
16029 (remote_close): Call it.
16030 (process_remaining, reschedule): New functions.
16031 * server.h (callback_handler_func): New typedef.
16032 (append_callback_event, delete_callback_event): Declare.
16034 2010-05-03 Pedro Alves <pedro@codesourcery.com>
16036 * proc-service.c (ps_pglobal_lookup): Use
16037 thread_db_look_up_one_symbol.
16038 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
16039 parameter. Use it instead of all_symbols_looked_up.
16040 * server.h (struct process_info) <all_symbols_looked_up>: Delete
16042 (all_symbols_looked_up): Don't declare.
16043 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
16044 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
16046 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
16047 Set all_symbols_looked_up here.
16048 (thread_db_look_up_one_symbol): New.
16049 (thread_db_get_tls_address): Adjust.
16050 (thread_db_load_search, try_thread_db_load_1): Always allocate the
16051 thread_db object on the heap, and tentatively set it in the
16053 (thread_db_init): Don't set all_symbols_looked_up here.
16054 * linux-low.h (thread_db_look_up_one_symbol): Declare.
16056 2010-05-03 Pedro Alves <pedro@codesourcery.com>
16058 * linux-low.c (linux_kill, linux_detach): Adjust.
16059 (status_pending_p_callback): Remove redundant statement. Check
16060 for !TARGET_WAITIKIND_IGNORE, instead of
16061 TARGET_WAITKIND_STOPPED.
16062 (handle_tracepoints): Make sure LWP is locked. Adjust.
16063 (linux_wait_for_event_1): Adjust.
16064 (linux_cancel_breakpoints): New.
16065 (unsuspend_one_lwp): New.
16066 (unsuspend_all_lwps): New.
16067 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
16068 (send_sigstop_callback): Change return type to int, add new
16069 `except' parameter and handle it.
16070 (suspend_and_send_sigstop_callback): New.
16071 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
16072 pass them down. If SUSPEND, also increment the lwp's suspend
16074 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
16075 (need_step_over_p): Don't consider suspended LWPs.
16076 (start_step_over): Adjust.
16077 (proceed_one_lwp): Change return type to int, add new `except'
16078 parameter and handle it.
16079 (unsuspend_and_proceed_one_lwp): New.
16080 (proceed_all_lwps): Use find_inferior instead of
16082 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
16083 also decrement the suspend count of LWPs. Pass `except' down,
16084 instead of hacking its suspend count.
16085 (linux_pause_all): Add `freeze' parameter. Adjust.
16086 (linux_unpause_all): New.
16087 (linux_target_ops): Install linux_unpause_all.
16088 * server.c (handle_status): Adjust.
16089 * target.h (struct target_ops): New fields `unpause_all' and
16090 `cancel_breakpoints'. Add new parameter to `pause_all'.
16091 (pause_all): Add new `freeze' parameter.
16092 (unpause_all): New.
16093 (cancel_breakpoints): New.
16094 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
16095 cancel breakpoints.
16096 (cmd_qtstart): Pause threads.
16097 (stop_tracing): Pause threads, and cancel breakpoints.
16098 * win32-low.c (win32_target_ops): Adjust.
16100 2010-05-03 Pedro Alves <pedro@codesourcery.com>
16102 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
16103 the inferior right away from here...
16104 (linux_wait_1): ... to here, and adjust to check the thread's
16105 last_resume_kind instead of the lwp's step or stop_expected flags.
16107 2010-05-02 Pedro Alves <pedro@codesourcery.com>
16109 * README: Use consistent `GDB' and `GDBserver' spellings.
16111 2010-05-02 Pedro Alves <pedro@codesourcery.com>
16113 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
16114 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
16115 (linux_detach_one_lwp): Assume the lwp is stopped.
16116 (any_thread_of): Delete.
16117 (linux_detach): Stop all lwps here. Don't blindly delete all
16119 (delete_lwp_callback): New.
16120 (linux_mourn): Delete all lwps of the process that is gone.
16121 (linux_wait_1): Don't delete the last lwp of the process here.
16122 * mem-break.h (mark_breakpoints_out): Declare.
16123 * mem-break.c (mark_breakpoints_out): New.
16124 (free_all_breakpoints): Use it.
16125 * server.c (handle_target_event): If the process is gone, mark
16127 * thread-db.c (struct thread_db) <create_bp>: New field.
16128 (thread_db_enable_reporting): Fix prototype. Store a thread event
16129 breakpoint reference in the thread_db struct.
16130 (thread_db_load_search): Clear the thread_db object.
16131 (try_thread_db_load_1): Ditto.
16132 (switch_to_process): New.
16133 (disable_thread_event_reporting): Use it.
16134 (remove_thread_event_breakpoints): New.
16135 (thread_db_detach, thread_db_mourn): Use it.
16137 2010-05-01 Pedro Alves <pedro@codesourcery.com>
16139 * linux-low.c (linux_enable_event_reporting): New.
16140 (linux_wait_for_event_1, handle_extended_wait): Use it.
16142 2010-04-30 Pedro Alves <pedro@codesourcery.com>
16144 * linux-low.c (linux_kill_one_lwp, linux_kill)
16145 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
16146 (send_sigstop): Take an lwp_info as parameter instead. Queue a
16147 SIGSTOP even if the LWP is stopped.
16148 (send_sigstop_callback): New.
16149 (stop_all_lwps): Use send_sigstop_callback instead.
16150 (linux_resume_one_thread): Adjust.
16151 (proceed_one_lwp): Still proceed an LWP that the client has
16152 requested to stop, if we haven't reported it as stopped yet. Make
16153 sure that LWPs the client want stopped, have a pending SIGSTOP.
16155 2010-04-26 Doug Evans <dje@google.com>
16157 * server.c (handle_general_set): Make static.
16159 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
16160 Print received char after testing for error/eof instead of before.
16161 (input_interrupt): Tweak comment.
16163 2010-04-23 Doug Evans <dje@google.com>
16165 * server.c (start_inferior): Print inferior argv if --debug.
16167 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
16169 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
16170 * nto-x86-low.c: Include server.h
16172 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
16174 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
16175 be consistent with other sources of this directory.
16176 (init_registers_amd64): Correct name of source file of this function
16179 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
16181 * configure.srv (x86_64-*-mingw*): New configuration for Windows
16182 64-bit executables.
16184 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
16186 * win32-i386-low.c: Add 64-bit support.
16187 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
16188 (init_registers_amd64): Declare.
16189 (mappings): Add 64-bit version of array.
16190 (init_windows_x86): New function.
16191 (the_low_target): Change init_arch field to init_windows_x86.
16193 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
16195 * win32-low.c: Adapt to support also 64-bit architecture.
16196 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
16197 (get_image_name): Use SIZE_T type for local variable `done'.
16198 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
16199 (toolhelp_get_dll_name): Idem.
16200 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
16201 Use uintptr_t typecast to avoid warning.
16202 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
16203 (handle_exception): Use phex_nz to avoid warning.
16204 (win32_wait): Remove unused local variable `process'.
16206 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
16208 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
16211 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
16213 * configure.ac: Use `ws2_32' library for srv_mingw.
16214 * configure: Regenerate.
16215 * gdbreplay.c: Include winsock2.h instead of winsock.h.
16216 * remote-utils.c: Likewise.
16218 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
16220 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
16221 if __x86_64__ is defined.
16223 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
16225 * configure: Regenerate.
16227 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
16229 * server.c (handle_query): Handle 'qGetTIBAddr' query.
16230 * target.h (target_ops): New get_tib_address field.
16231 * win32-low.h (win32_thread_info): Add thread_local_base field.
16232 * win32-low.c (child_add_thread): Add tlb argument.
16233 Set thread_local_base field to TLB.
16234 (get_child_debug_event): Adapt to child_add_thread change.
16235 (win32_get_tib_address): New function.
16236 (win32_target_ops): Set get_tib_address field to
16237 win32_get_tib_address.
16238 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
16240 2010-04-12 Pedro Alves <pedro@codesourcery.com>
16242 * linux-low.c (linux_mourn): Also remove the process.
16243 * server.c (handle_target_event): Don't remove the process here.
16244 * nto-low.c (nto_mourn): New.
16245 (nto_target_ops): Install it.
16246 * spu-low.c (spu_mourn): New.
16247 (spu_target_ops): Install it.
16248 * win32-low.c (win32_mourn): New.
16249 (win32_target_ops): Install it.
16251 2010-04-12 Pedro Alves <pedro@codesourcery.com>
16253 * server.h (buffer_xml_printf): Remove redundant `;'.
16255 2010-04-12 Pedro Alves <pedro@codesourcery.com>
16257 * regcache.c (set_register_cache): Invalidate regcaches before
16258 changing the register cache layout.
16259 (regcache_invalidate_one): Allow a NULL regcache.
16260 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
16261 regcaches before changing the register cache layout or the target
16264 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
16266 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
16267 variable warning on Linux/x86-64.
16269 2010-04-11 Pedro Alves <pedro@codesourcery.com>
16271 GDBserver disconnected tracing support.
16273 * linux-low.c (linux_remove_process): Delete.
16274 (add_lwp): Don't set last_resume_kind here.
16275 (linux_kill): Use `mourn'.
16276 (linux_detach): Use `thread_db_detach', and `mourn'.
16277 (linux_mourn): New.
16278 (linux_attach_lwp_1): Adjust comment.
16279 (linux_attach): last_resume_kind moved the thread_info; adjust.
16280 (status_pending_p_callback): Adjust.
16281 (linux_wait_for_event_1): Adjust.
16282 (count_events_callback, select_singlestep_lwp_callback)
16283 (select_event_lwp_callback, cancel_breakpoints_callback)
16284 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
16285 (proceed_one_lwp): Adjust.
16286 (linux_async): Add debug output.
16287 (linux_thread_stopped): New.
16288 (linux_pause_all): New.
16289 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
16291 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
16292 (thread_db_free): Delete declaration.
16293 (thread_db_detach, thread_db_mourn): Declare.
16294 * thread-db.c (thread_db_init): Use thread_db_mourn.
16295 (thread_db_free): Delete, split in two.
16296 (disable_thread_event_reporting): New.
16297 (thread_db_detach): New.
16298 (thread_db_mourn): New.
16300 * server.h (struct thread_info) <last_resume_kind>: New field.
16301 <attached>: Add comment.
16302 <gdb_detached>: New field.
16303 (handler_func): Change return type to int.
16304 (handle_serial_event, handle_target_event): Ditto.
16305 (gdb_connected): Declare.
16307 (disconnected_tracing): Declare.
16308 (stop_tracing): Declare.
16310 * server.c (handle_query) <qSupported>: Report support for
16311 disconnected tracing.
16312 (queue_stop_reply_callback): Account for running threads.
16313 (gdb_wants_thread_stopped): New.
16314 (gdb_wants_all_threads_stopped): New.
16315 (gdb_reattached_process): New.
16316 (handle_status): Clear the `gdb_detached' flag of all processes.
16317 In all-stop, stop all threads.
16318 (main): Be sure to leave tfind mode. Handle disconnected tracing.
16319 (process_serial_event): If the remote connection breaks, or if an
16320 exit was forced with "monitor exit", force an event loop exit.
16321 Handle disconnected tracing on detach.
16322 (handle_serial_event): Adjust.
16323 (handle_target_event): If GDB isn't connected, forward events back
16324 to the inferior, unless the last process exited, in which case,
16325 exit gdbserver. Adjust interface.
16327 * remote-utils.c (remote_open): Don't block in accept. Instead
16328 register an event loop source on the listen socket file
16329 descriptor. Refactor bits into ...
16330 (listen_desc): ... this new global.
16331 (gdb_connected): ... this new function.
16332 (enable_async_notification): ... this new function.
16333 (handle_accept_event): ... this new function.
16334 (remote_close): Clear remote_desc.
16336 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
16338 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
16340 (mourn_inferior): Define.
16341 (target_process_qsupported): Avoid the dangling else problem.
16342 (thread_stopped): Define.
16343 (pause_all): Define.
16344 (target_waitstatus_to_string): Declare.
16345 * target.c (target_waitstatus_to_string): New.
16347 * tracepoint.c (tracing): Make extern.
16348 (disconnected_tracing): New.
16349 (stop_tracing): Make extern. Handle tracing stops due to GDB
16351 (cmd_qtdisconnected): New.
16352 (cmd_qtstatus): Report disconnected tracing status in trace reply.
16353 (handle_tracepoint_general_set): Handle QTDisconnected.
16355 * event-loop.c (event_handler_func): Change return type to int.
16356 (process_event): Bail out if the event handler wants the event
16358 (handle_file_event): Ditto.
16359 (start_event_loop): Bail out if the event handler wants the event
16362 * nto-low.c (nto_target_ops): Adjust.
16363 * spu-low.c (spu_wait): Don't remove the process here.
16364 (spu_target_ops): Adjust.
16365 * win32-low.c (win32_wait): Don't remove the process here.
16366 (win32_target_ops): Adjust.
16368 2010-04-11 Pedro Alves <pedro@codesourcery.com>
16370 * regcache.c (realloc_register_cache): Invalidate inferior's
16371 regcache before recreating it.
16373 2010-04-09 Pedro Alves <pedro@codesourcery.com>
16375 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
16377 2010-04-09 Stan Shebs <stan@codesourcery.com>
16378 Pedro Alves <pedro@codesourcery.com>
16380 * server.h (LONGEST): New.
16381 (struct thread_info) <while_stepping>: New field.
16382 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
16384 (initialize_tracepoint, handle_tracepoint_general_set)
16385 (handle_tracepoint_query, tracepoint_finished_step)
16386 (tracepoint_was_hit, release_while_stepping_state_list):
16387 (current_traceframe): Declare.
16388 * server.c (handle_general_set): Handle tracepoint packets.
16389 (read_memory): New.
16390 (write_memory): New.
16391 (handle_search_memory_1): Use read_memory.
16392 (handle_query): Report support for conditional tracepoints, trace
16393 state variables, and tracepoint sources. Handle tracepoint
16395 (main): Initialize the tracepoints module.
16396 (process_serial_event): Handle traceframe reads/writes.
16398 * linux-low.c (handle_tracepoints): New.
16399 (linux_wait_1): Call it.
16400 (linux_resume_one_lwp): Handle while-stepping.
16401 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
16402 (linux_target_ops): Install them.
16403 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
16405 * linux-x86-low.c (x86_supports_tracepoints): New.
16406 (the_low_target). Install it.
16408 * mem-break.h (delete_breakpoint): Declare.
16409 * mem-break.c (delete_breakpoint): Make external.
16411 * target.h (struct target_ops): Add `supports_tracepoints',
16412 `read_pc', and `write_pc' fields.
16413 (target_supports_tracepoints): Define.
16414 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
16417 * regcache.h (struct regcache) <registers_owned>: New field.
16418 (init_register_cache, regcache_cpy): Declare.
16419 (regcache_read_pc, regcache_write_pc): Declare.
16420 (register_cache_size): Declare.
16421 (supply_regblock): Declare.
16422 * regcache.c (init_register_cache): New.
16423 (new_register_cache): Use it.
16424 (regcache_cpy): New.
16425 (register_cache_size): New.
16426 (supply_regblock): New.
16427 (regcache_read_pc, regcache_write_pc): New.
16429 * tracepoint.c: New.
16431 * Makefile.in (OBS): Add tracepoint.o.
16432 (tracepoint.o): New rule.
16434 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
16436 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
16438 (i386-mmx.c): Likewise.
16439 (i386-mmx-linux.o): Likewise.
16440 (i386-mmx-linux.c): Likewise.
16442 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
16443 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
16444 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
16445 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
16447 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
16448 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
16449 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
16451 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
16453 * Makefile.in (clean): Updated.
16455 (i386-avx.c): Likewise.
16456 (i386-avx-linux.o): Likewise.
16457 (i386-avx-linux.c): Likewise.
16458 (amd64-avx.o): Likewise.
16459 (amd64-avx.c): Likewise.
16460 (amd64-avx-linux.o): Likewise.
16461 (amd64-avx-linux.c): Likewise.
16463 * configure.srv (srv_i386_regobj): Add i386-avx.o.
16464 (srv_i386_linux_regobj): Add i386-avx-linux.o.
16465 (srv_amd64_regobj): Add amd64-avx.o.
16466 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
16467 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
16468 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
16469 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
16470 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
16471 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
16472 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
16474 * i387-fp.c: Include "i386-xstate.h".
16476 (i387_cache_to_xsave): Likewise.
16477 (i387_xsave_to_cache): Likewise.
16478 (x86_xcr0): Likewise.
16480 * i387-fp.h (i387_cache_to_xsave): Likewise.
16481 (i387_xsave_to_cache): Likewise.
16482 (x86_xcr0): Likewise.
16484 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
16485 * linux-crisv32-low.c (target_regsets): Likewise.
16486 * linux-m68k-low.c (target_regsets): Likewise.
16487 * linux-mips-low.c (target_regsets): Likewise.
16488 * linux-ppc-low.c (target_regsets): Likewise.
16489 * linux-s390-low.c (target_regsets): Likewise.
16490 * linux-sh-low.c (target_regsets): Likewise.
16491 * linux-sparc-low.c (target_regsets): Likewise.
16492 * linux-xtensa-low.c (target_regsets): Likewise.
16494 * linux-low.c: Include <sys/uio.h>.
16495 (regsets_fetch_inferior_registers): Support nt_type.
16496 (regsets_store_inferior_registers): Likewise.
16497 (linux_process_qsupported): New.
16498 (linux_target_ops): Add linux_process_qsupported.
16500 * linux-low.h (regset_info): Add nt_type.
16501 (linux_target_ops): Add process_qsupported.
16503 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
16505 (init_registers_i386_avx_linux): New.
16506 (init_registers_amd64_avx_linux): Likewise.
16507 (xmltarget_i386_linux_no_xml): Likewise.
16508 (xmltarget_amd64_linux_no_xml): Likewise.
16509 (PTRACE_GETREGSET): Likewise.
16510 (PTRACE_SETREGSET): Likewise.
16511 (x86_fill_xstateregset): Likewise.
16512 (x86_store_xstateregset): Likewise.
16513 (use_xml): Likewise.
16514 (x86_linux_update_xmltarget): Likewise.
16515 (x86_linux_process_qsupported): Likewise.
16516 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
16517 (x86_arch_setup): Don't call init_registers_amd64_linux nor
16518 init_registers_i386_linux here. Call
16519 x86_linux_update_xmltarget.
16520 (the_low_target): Add x86_linux_process_qsupported.
16522 * server.c (handle_query): Call target_process_qsupported.
16524 * target.h (target_ops): Add process_qsupported.
16525 (target_process_qsupported): New.
16527 2010-04-03 Pedro Alves <pedro@codesourcery.com>
16529 * inferiors.c (add_thread): Set last_status kind to
16530 TARGET_WAITKIND_IGNORE.
16531 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
16532 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
16533 (linux_wait_1): Move `thread' local definition to block that uses
16534 it. Don't NULL initialize `event_child'.
16535 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
16536 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
16537 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
16539 2010-04-01 Pedro Alves <pedro@codesourcery.com>
16541 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
16542 an extended waitstatus, or by a watchpoint.
16543 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
16544 thread was stepping or has been stopped by a watchpoint.
16546 2010-04-01 Pedro Alves <pedro@codesourcery.com>
16548 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
16549 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
16550 of another, then delete the previous, and validate all
16552 (validate_inserted_breakpoint): New.
16553 (delete_disabled_breakpoints): New.
16554 (validate_breakpoints): New.
16555 (check_mem_read): Validate breakpoints before trusting their
16556 shadow. Delete disabled breakpoints.
16557 (check_mem_write): Validate breakpoints before trusting they
16558 should be inserted. Delete disabled breakpoints.
16559 * mem-break.h (validate_breakpoints):
16560 * server.c (handle_query): Validate breakpoints when we see a
16563 2010-04-01 Pedro Alves <pedro@codesourcery.com>
16565 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
16566 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
16567 if we could tell there's a GDB breakpoint at stop_pc.
16568 (need_step_over_p): Don't do a step over if we find a GDB
16569 breakpoint at the resume PC.
16571 * mem-break.c (struct raw_breakpoint): New.
16572 (enum bkpt_type): New type `gdb_breakpoint'.
16573 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
16574 fields. New field `raw'.
16575 (find_raw_breakpoint_at): New.
16576 (set_raw_breakpoint_at): Handle refcounting. Create a raw
16577 breakpoint instead.
16578 (set_breakpoint_at): Adjust.
16579 (delete_raw_breakpoint): New.
16580 (release_breakpoint): New.
16581 (delete_breakpoint): Rename to...
16582 (delete_breakpoint_1): ... this. Add proc parameter. Use
16583 release_breakpoint. Return ENOENT.
16584 (delete_breakpoint): Reimplement.
16585 (find_breakpoint_at): Delete.
16586 (find_gdb_breakpoint_at): New.
16587 (delete_breakpoint_at): Delete.
16588 (set_gdb_breakpoint_at): New.
16589 (delete_gdb_breakpoint_at): New.
16590 (gdb_breakpoint_here): New.
16591 (set_reinsert_breakpoint): Use release_breakpoint.
16592 (uninsert_breakpoint): Rename to ...
16593 (uninsert_raw_breakpoint): ... this.
16594 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
16595 (reinsert_raw_breakpoint): Change parameter type to
16597 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
16599 (check_breakpoints): Adjust. Use release_breakpoint.
16600 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
16601 (breakpoint_inserted_here): Ditto.
16602 (check_mem_read): Adjust to iterate over raw breakpoints instead.
16603 Don't trust the breakpoint's shadow if it is not inserted.
16604 (check_mem_write): Adjust to iterate over raw breakpoints instead.
16605 (delete_all_breakpoints): Adjust.
16606 (free_all_breakpoints): Mark all breakpoints as uninserted, and
16607 use delete_breakpoint_1.
16609 * mem-break.h (breakpoints_supported): Delete declaration.
16610 (set_gdb_breakpoint_at): Declare.
16611 (gdb_breakpoint_here): Declare.
16612 (delete_breakpoint_at): Delete.
16613 (delete_gdb_breakpoint_at): Declare.
16615 * server.h (struct raw_breakpoint): Forward declare.
16616 (struct process_info): New field `raw_breakpoints'.
16618 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
16621 2010-03-24 Pedro Alves <pedro@codesourcery.com>
16623 * linux-low.c (status_pending_p_callback): Fix comment.
16624 (linux_wait_for_event_1): Move most of the internal breakpoint
16625 handling from here...
16626 (linux_wait_1): ... to here.
16627 (count_events_callback): New.
16628 (select_singlestep_lwp_callback): New.
16629 (select_event_lwp_callback): New.
16630 (cancel_breakpoints_callback): New.
16631 (select_event_lwp): New.
16632 (linux_wait_1): Simplify internal breakpoint handling. Give equal
16633 priority to all LWPs that have had events that should be reported
16634 to the client. Cancel breakpoints when about to reporting the
16635 event to the client, not while stopping lwps. No longer cancel
16636 finished single-steps here.
16637 (cancel_finished_single_step): Delete.
16638 (cancel_finished_single_steps): Delete.
16640 2010-03-24 Pedro Alves <pedro@codesourcery.com>
16642 * mem-break.c (enum bkpt_type): New.
16643 (struct breakpoint): New field `type'.
16644 (set_breakpoint_at): Change return type to struct breakpoint
16645 pointer. Set type to `other_breakpoint' by default.
16646 (delete_breakpoint): Rewrite, supporting more than one breakpoint
16647 in the breakpoint list.
16648 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
16649 (reinsert_breakpoint): Rename to ...
16650 (reinsert_raw_breakpoint): ... this.
16651 (reinsert_breakpoints_at): Adjust.
16652 * mem-break.h (struct breakpoint): Declare.
16653 (set_breakpoint_at): Change return type to struct breakpoint
16656 2010-03-24 Pedro Alves <pedro@codesourcery.com>
16658 * server.c (handle_query): Assign, not compare.
16660 2010-03-24 Pedro Alves <pedro@codesourcery.com>
16662 Teach linux gdbserver to step-over-breakpoints.
16664 * linux-low.c (can_hardware_single_step): New.
16665 (supports_breakpoints): New.
16666 (handle_extended_wait): If stopping threads, read the stop pc of
16667 the new cloned LWP.
16669 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
16670 low target doesn't support retrieving the PC.
16671 (add_lwp): Set last_resume_kind to resume_continue.
16672 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
16673 (linux_attach): Don't clear stop_expected. Set the lwp's
16674 last_resume_kind to resume_stop.
16675 (linux_detach_one_lwp): Don't check for removed breakpoints.
16676 (check_removed_breakpoint): Delete.
16677 (status_pending_p): Rename to ...
16678 (status_pending_p_callback): ... this. Don't check for removed
16679 breakpoints. Don't consider threads that are stopped from GDB's
16681 (linux_wait_for_lwp): Always read the stop_pc here.
16682 (cancel_breakpoint): New.
16683 (step_over_bkpt): New global.
16684 (linux_wait_for_event_1): Implement stepping over breakpoints.
16685 (gdb_wants_lwp_stopped): New.
16686 (gdb_wants_all_stopped): New.
16687 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
16688 single-step traps here. Store the thread's last reported target
16690 (send_sigstop): Don't clear stop_expected. Always set it,
16692 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
16693 (cancel_finished_single_step): New.
16694 (cancel_finished_single_steps): New.
16695 (wait_for_sigstop): Don't cancel finished single-step traps here.
16696 (linux_resume_one_lwp): Don't check for removed breakpoints.
16697 Don't set `step' on non-hardware step archs.
16698 (linux_set_resume_request): Ignore resume_stop requests if already
16699 stopping or stopped. Set the lwp's last_resume_kind.
16700 (resume_status_pending_p): Don't check for removed breakpoints.
16701 (need_step_over_p): New.
16702 (start_step_over): New.
16703 (finish_step_over): New.
16704 (linux_resume_one_thread): Always queue a sigstop for resume_stop
16705 requests. Clear the thread's last reported target waitstatus.
16706 Don't use the `suspended' flag. Don't consider pending breakpoints.
16707 (linux_resume): Start a step-over if necessary.
16708 (proceed_one_lwp): New.
16709 (proceed_all_lwps): New.
16710 (unstop_all_lwps): New.
16711 * linux-low.h (struct lwp_info): Rewrite comment for the
16712 `suspended' flag. Add the `stop_pc' field. Delete the
16713 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
16714 Add `'last_resume_kind' and `need_step_over' fields.
16715 * inferiors.c (struct thread_info): Delete, moved elsewhere.
16716 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
16717 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
16718 (set_raw_breakpoint_at): New.
16719 (set_breakpoint_at): Rewrite to use it.
16720 (reinsert_breakpoint_handler): Delete.
16721 (set_reinsert_breakpoint): New.
16722 (reinsert_breakpoint_by_bp): Delete.
16723 (delete_reinsert_breakpoints): New.
16724 (uninsert_breakpoint): Rewrite.
16725 (uninsert_breakpoints_at): New.
16726 (reinsert_breakpoint): Rewrite.
16727 (reinsert_breakpoints_at): New.
16728 (check_breakpoints): Rewrite.
16729 (breakpoint_here): New.
16730 (breakpoint_inserted_here): New.
16731 (check_mem_read): Adjust.
16732 * mem-break.h (breakpoints_supported, breakpoint_here)
16733 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
16734 (reinsert_breakpoint_by_bp): Delete declaration.
16735 (delete_reinsert_breakpoints): Declare.
16736 (reinsert_breakpoint): Delete declaration.
16737 (reinsert_breakpoints_at): Declare.
16738 (uninsert_breakpoint): Delete declaration.
16739 (uninsert_breakpoints_at): Declare.
16740 (check_breakpoints): Adjust prototype.
16741 * server.h: Adjust include order.
16742 (struct thread_info): Declare here. Add a `last_status' field.
16744 2010-03-23 Michael Snyder <msnyder@vmware.com>
16746 * server.c (crc32): New function.
16747 (handle_query): Add handling for 'qCRC:' request.
16749 2010-03-23 Pedro Alves <pedro@codesourcery.com>
16751 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
16752 lwp had been stopped by a watchpoint.
16754 2010-03-16 Pedro Alves <pedro@codesourcery.com>
16756 * server.h (internal_error): Declare.
16757 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
16758 * utils.c (internal_error): New function.
16760 2010-03-15 Andreas Schwab <schwab@redhat.com>
16762 * configure.srv: Fix typo setting srv_regobj.
16764 2010-03-15 Pedro Alves <pedro@codesourcery.com>
16766 * linux-low.c (fetch_register): Avoid passing a non string literal
16768 (usr_store_inferior_registers): Ditto.
16770 2010-03-14 Pedro Alves <pedro@codesourcery.com>
16772 * linux-low.c (linux_write_memory): Bail out early if peeking
16775 2010-03-14 Pedro Alves <pedro@codesourcery.com>
16777 * linux-low.h (struct lwp_info): New fields
16778 `stopped_by_watchpoint' and `stopped_data_address'.
16779 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
16780 here, and cache them in the lwp object.
16781 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
16783 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
16785 (linux_stopped_by_watchpoint): Rewrite.
16786 (linux_stopped_data_address): Rewrite.
16788 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
16790 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
16791 switching the current inferior, not before.
16793 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
16795 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
16796 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
16797 i386-linux.c and amd64-linux.c.
16798 (reg-i386.o): Removed.
16799 (reg-i386.c): Likewise.
16800 (reg-i386-linux.o): Likewise.
16801 (reg-i386-linux.c): Likewise.
16802 (reg-x86-64.o): Likewise.
16803 (reg-x86-64.c): Likewise.
16804 (reg-x86-64-linux.o): Likewise.
16805 (reg-x86-64-linux.c): Likewise.
16807 (i386.c): Likewise.
16808 (i386-linux.o): Likewise.
16809 (i386-linux.c): Likewise.
16810 (amd64.o): Likewise.
16811 (amd64.c): Likewise.
16812 (amd64-linux.o): Likewise.
16813 (amd64-linux.c): Likewise.
16815 * configure.srv (srv_i386_regobj): New.
16816 (srv_i386_linux_regobj): Likewise.
16817 (srv_amd64_regobj): Likewise.
16818 (srv_amd64_linux_regobj): Likewise.
16819 (srv_i386_32bit_xmlfiles): Likewise.
16820 (srv_i386_64bit_xmlfiles): Likewise.
16821 (srv_i386_xmlfiles): Likewise.
16822 (srv_amd64_xmlfiles): Likewise.
16823 (srv_i386_linux_xmlfiles): Likewise.
16824 (srv_amd64_linux_xmlfiles): Likewise.
16825 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
16826 srv_xmlfiles to $srv_i386_xmlfiles.
16827 (i[34567]86-*-mingw32ce*): Likewise.
16828 (i[34567]86-*-mingw*): Likewise.
16829 (i[34567]86-*-nto*): Likewise.
16830 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
16831 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
16832 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
16833 (x86_64-*-linux*): Likewise.
16835 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
16836 (init_registers_amd64_linux): New.
16837 (x86_arch_setup): Replace init_registers_x86_64_linux with
16838 init_registers_amd64_linux.
16840 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
16842 * configure.ac: Check for libdl. If it is not available link against
16843 static libthread_db.
16844 * configure: Regenerate.
16846 2010-02-22 Pedro Alves <pedro@codesourcery.com>
16850 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
16851 handing a read watchpoint.
16852 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
16854 2010-02-12 Doug Evans <dje@google.com>
16856 * linux-low.c (linux_supports_tracefork_flag): Document.
16857 (linux_look_up_symbols): Add comment.
16859 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
16861 * regcache.c (supply_register): Clear regcache if buf is NULL.
16863 2010-02-02 Nicolas Roche <roche@sourceware.org>
16864 Joel Brobecker <brobecker@adacore.com>
16866 * inferiors.c (find_inferior): Add function documentation.
16867 (unloaded_dll): Handle the case where the unloaded dll has not
16868 been previously registered in the dll list.
16870 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
16872 * linux-arm-low.c (thumb_breakpoint_len): Delete.
16873 (thumb2_breakpoint): New.
16874 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
16876 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
16878 * linux-low.c (get_stop_pc): Check for SIGTRAP.
16879 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
16882 2010-01-21 Pedro Alves <pedro@codesourcery.com>
16884 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
16886 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
16888 * linux-s390-low.c (s390_collect_ptrace_register)
16889 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
16891 2010-01-21 Doug Evans <dje@google.com>
16893 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
16894 (PTRACE_ARG4_TYPE): New macro.
16895 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
16896 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
16897 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
16898 (usr_store_inferior_registers): Ditto.
16899 (linux_read_memory, linux_write_memory): Ditto.
16900 (linux_test_for_tracefork): Ditto.
16902 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
16903 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
16905 2010-01-21 Pedro Alves <pedro@codesourcery.com>
16907 * proc-service.c (ps_lgetregs): Don't refetch registers from the
16910 2010-01-21 Pedro Alves <pedro@codesourcery.com>
16912 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
16913 prototype to take a regcache. Adjust.
16915 2010-01-20 Pedro Alves <pedro@codesourcery.com>
16917 * regcache.h (struct thread_info): Forward declare.
16918 (struct regcache): New.
16919 (new_register_cache): Adjust prototype.
16920 (get_thread_regcache): Declare.
16921 (free_register_cache): Adjust prototype.
16922 (registers_to_string, registers_from_string): Ditto.
16923 (supply_register, supply_register_by_name, collect_register)
16924 (collect_register_as_string, collect_register_by_name): Ditto.
16925 * regcache.c (struct inferior_regcache_data): Delete.
16926 (get_regcache): Rename to ...
16927 (get_thread_regcache): ... this. Adjust. Switch inferior before
16928 fetching registers.
16929 (regcache_invalidate_one): Adjust.
16930 (regcache_invalidate): Fix prototype.
16931 (new_register_cache): Return the new register cache.
16932 (free_register_cache): Change prototype.
16933 (realloc_register_cache): Adjust.
16934 (registers_to_string): Change prototype to take a regcache. Adjust.
16935 (registers_from_string): Ditto.
16936 (register_data): Ditto.
16937 (supply_register): Ditto.
16938 (supply_register_by_name): Ditto.
16939 (collect_register): Ditto.
16940 (collect_register_as_string): Ditto.
16941 (collect_register_by_name): Ditto.
16942 * server.c (process_serial_event): Adjust.
16943 * linux-low.h (regset_fill_func, regset_store_func): Change
16945 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
16947 * linux-low.c (get_stop_pc): Adjust.
16948 (check_removed_breakpoint): Adjust.
16949 (linux_wait_for_event): Adjust.
16950 (linux_resume_one_lwp): Adjust.
16951 (fetch_register): Add regcache parameter. Adjust.
16952 (usr_store_inferior_registers): Ditto.
16953 (regsets_fetch_inferior_registers): Ditto.
16954 (regsets_store_inferior_registers): Ditto.
16955 (linux_fetch_registers, linux_store_registers): Ditto.
16956 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
16958 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
16960 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
16961 prototype to take a regcache.
16962 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
16963 * remote-utils.c (convert_ascii_to_int, outreg)
16964 (prepare_resume_reply): Change prototype to take a regcache.
16966 * target.h (struct target_ops) <fetch_registers, store_registers>:
16967 Change prototype to take a regcache.
16968 (fetch_inferior_registers, store_inferior_registers): Change
16969 prototype to take a regcache. Adjust.
16970 * proc-service.c (ps_lgetregs): Adjust.
16971 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
16972 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
16973 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
16974 take a regcache. Adjust.
16975 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
16976 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
16977 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
16978 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
16979 * linux-cris-low.c (cris_get_pc, cris_set_pc)
16980 (cris_cannot_fetch_register):
16981 (cris_breakpoint_at): Change prototype to take a regcache.
16983 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
16984 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
16985 to take a regcache. Adjust.
16986 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
16988 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
16989 take a regcache. Adjust.
16990 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
16991 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
16992 (m68k_set_pc): Change prototype to take a regcache. Adjust.
16993 * linux-mips-low.c (mips_get_pc):
16994 (mips_set_pc): Change prototype to take a regcache. Adjust.
16995 (mips_reinsert_addr): Adjust.
16996 (mips_collect_register): Change prototype to take a regcache.
16998 (mips_supply_register):
16999 (mips_collect_register_32bit, mips_supply_register_32bit)
17000 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
17001 (mips_store_fpregset): Ditto.
17002 * linux-ppc-low.c (ppc_supply_ptrace_register)
17003 (ppc_supply_ptrace_register): Ditto.
17004 (parse_spufs_run): Adjust.
17005 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
17006 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
17007 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
17008 take a regcache. Adjust.
17009 * linux-s390-low.c (s390_collect_ptrace_register)
17010 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
17011 (s390_set_pc): Change prototype to take a regcache. Adjust.
17012 (s390_arch_setup): Adjust.
17013 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
17014 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
17015 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
17016 (sparc_fill_gregset, sparc_store_gregset_from_stack)
17017 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
17019 (sparc_breakpoint_at): Adjust.
17020 * linux-xtensa-low.c (xtensa_fill_gregset):
17021 (xtensa_store_gregset):
17022 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
17023 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
17024 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
17025 prototype to take a regcache. Adjust.
17026 * win32-arm-low.c (arm_fetch_inferior_register)
17027 (arm_store_inferior_register): Change prototype to take a
17029 * win32-i386-low.c (i386_fetch_inferior_register)
17030 (i386_store_inferior_register): Change prototype to take a
17032 * win32-low.c (child_fetch_inferior_registers)
17033 (child_store_inferior_registers): Change prototype to take a
17035 (win32_wait): Adjust.
17036 (win32_fetch_inferior_registers): Change prototype to take a
17038 (win32_store_inferior_registers): Adjust.
17039 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
17040 store_inferior_register>: Change prototype to take a regcache.
17042 2010-01-20 Doug Evans <dje@google.com>
17044 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
17046 (linux_wait_for_event1, linux_init_signals): Ditto.
17047 (W_STOPCODE): Provide definition if missing.
17049 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
17051 * linux-low.c (linux_core_of_thread): New.
17052 (compare_ints, show_process, list_threads): New.
17053 (linux_qxfer_osdata): Report threads and cores.
17054 (linux_target_op): Register linux_core_of_thread.
17055 * remote-utils.c (prepare_resume_reply): Report the core.
17056 (buffer_xml_printf): Support %d specifier.
17057 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
17059 (handle_query): Handle qXfer:threads. Announce availability
17061 * target.h (struct target_ops): New field core_of_thread.
17063 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
17065 * Makefile.in (clean): Remove new generated files.
17066 (reg-s390.o, reg-s390.c): Remove rules.
17067 (reg-s390x.o, reg-s390x.c): Likewise.
17068 (s390-linux32.o, s390-linux32.c): Add rules.
17069 (s390-linux64.o, s390-linux64.c): Likewise.
17070 (s390x-linux64.o, s390x-linux64.c): Likewise.
17071 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
17072 * linux-s390-low.c: Include <elf.h>.
17073 (HWCAP_S390_HIGH_GPRS): Define if undefined.
17074 (init_registers_s390): Remove prototype.
17075 (init_registers_s390x): Likewise.
17076 (init_registers_s390_linux32): Add prototype.
17077 (init_registers_s390_linux64): Likewise.
17078 (init_registers_s390x_linux64): Likewise.
17079 (s390_num_regs_3264): New define.
17080 (s390_regmap_3264): New global variable.
17081 (s390_cannot_fetch_register): Remove obsolete check.
17082 (s390_cannot_store_register): Likewise.
17083 (s390_collect_ptrace_register): Handle upper/lower register halves.
17084 (s390_supply_ptrace_register): Likewise.
17085 (s390_fill_gregset): Update to register number changes.
17086 (s390_get_hwcap): New routine.
17087 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
17088 Install appropriate regmap and register set.
17090 2010-01-01 Joel Brobecker <brobecker@adacore.com>
17092 * server.c (gdbserver_version): Update copyright year to 2010.
17093 * gdbreplay.c (gdbreplay_version): Likewise.
17095 2009-12-28 Doug Evans <dje@google.com>
17097 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
17098 elf/external.h. Include <elf.h> instead but only if necessary.
17100 2009-12-28 Pedro Alves <pedro@codesourcery.com>
17102 * linux-low.c (linux_remove_process): Remove `detaching'
17103 parameter. Don't release/detach from thread_db here.
17104 (linux_kill): Release/detach from thread_db here, ...
17105 (linux_detach): ... and here, before actually detaching.
17106 (linux_wait_1): ... and here, when a process exits.
17107 * thread-db.c (any_thread_of): New.
17108 (thread_db_free): Switch the current inferior to a thread of the
17111 2009-12-21 Doug Evans <dje@google.com>
17113 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
17115 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
17116 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
17117 warning ifndef __NR_tkill. Move setting of errno there too.
17118 Delete unnecessary resetting of errno after syscall.
17119 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
17121 * configure.ac: Check for dladdr.
17122 * config.in: Regenerate.
17123 * configure: Regenerate.
17124 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
17125 (try_thread_db_load): Update.
17127 * linux-low.c (my_waitpid): Delete unnecessary prototype.
17129 2009-12-18 Doug Evans <dje@google.com>
17131 * event-loop.c: Include unistd.h if it exists.
17133 * linux-low.c (my_waitpid): Move definition away from being in
17134 between linux_tracefork_child/linux_test_for_tracefork.
17136 * gdb_proc_service.h (psaddr_t): Fix type.
17137 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
17138 signature to match glibc.
17140 2009-12-16 Doug Evans <dje@google.com>
17142 * linux-low.c (linux_read_memory): Fix argument to read.
17144 2009-11-26 Pedro Alves <pedro@codesourcery.com>
17146 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
17147 events, don't leave current_inferior pointing at null.
17149 2009-11-26 Pedro Alves <pedro@codesourcery.com>
17151 * win32-low.c (LOG): Delete.
17152 (OUTMSG): Output to stderr.
17153 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
17154 on compile time LOG macro.
17155 (win32_wait): Fix debug output.
17157 2009-11-26 Pedro Alves <pedro@codesourcery.com>
17159 * win32-low.c (win32_add_one_solib): If the dll name is
17160 "ntdll.dll", prepend the system directory to the dll path.
17162 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
17164 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
17166 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
17167 Vladimir Prus <vladimir@codesourcery.com>
17169 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
17170 * configure.ac: Check for __mcoldfire__ and set
17171 gdb_cv_m68k_is_coldfire.
17172 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
17173 reg-cf.o and reg-m68k.o.
17174 * configure: Regenerated.
17176 2009-11-16 Pedro Alves <pedro@codesourcery.com>
17178 * linux-low.c (linux_remove_process): Add `detaching' parameter.
17179 Pass it to thread_db_free.
17180 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
17181 proper `detaching' argument to linux_remove_process.
17182 * linux-low.h (thread_db_free): Add `detaching' parameter.
17183 * thread-db.c (thread_db_init): Pass false as `detaching' argument
17185 (thread_db_free): Add `detaching' parameter. Only
17186 call td_ta_clear_event if detaching from process.
17188 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
17190 * thread-db.c (thread_db_free): Fix typo.
17192 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
17195 * thread-db.c (thread_db_free): Call td_ta_clear_event.
17197 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
17199 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
17200 with an i686 compiler.
17201 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
17203 * configure: Rebuilt.
17205 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
17209 * server.c (handle_search_memory_1): Correct read_addr initialization
17210 in loop for searching subsequent chunks.
17212 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
17214 * configure.ac: New --with-libthread-db option.
17215 * thread-db.c: Allow direct dependence on libthread_db.
17216 (thread_db_free): Adjust.
17217 * config.in: Regenerate.
17218 * configure: Likewise.
17220 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
17223 * thread-db.c (attach_thread): New function.
17224 (maybe_attach_thread): Return success/failure.
17225 (find_new_threads_callback): Adjust.
17226 (thread_db_find_new_threads): Loop until no new threads.
17228 2009-10-13 Pedro Alves <pedro@codesourcery.com>
17230 * proc-service.c (ps_lgetregs): Formatting.
17232 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
17234 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
17235 * configure.ac: Adjust.
17236 * linux-low.h (struct process_info_private): Move members to struct
17238 (thread_db_free, thread_db_handle_monitor_command): New prototype.
17239 * linux-low.c (linux_remove_process): Adjust.
17240 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
17241 * server.c (handle_query): Move code ...
17242 (handle_monitor_command): ... here. New function.
17243 * target.h (struct target_ops): New member.
17244 * thread-db.c (struct thread_db): New.
17245 (libthread_db_search_path): New variable.
17246 (thread_db_create_event, thread_db_enable_reporting)
17247 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
17248 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
17249 (try_thread_db_load_1, dladdr_to_soname): New functions.
17250 (try_thread_db_load, thread_db_load_search): New functions.
17251 (thread_db_init): Search for libthread_db.
17252 (thread_db_free): New function.
17253 (thread_db_handle_monitor_command): Likewise.
17254 * config.in: Regenerate.
17255 * configure: Regenerate.
17257 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
17259 * spu-low.c (spu_kill): Wait for inferior to terminate.
17260 Call clear_inferiors.
17261 (spu_detach): Call clear_inferiors.
17263 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
17265 * aclocal.m4: Regenerate.
17266 * config.in: Likewise.
17267 * configure: Likewise.
17269 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
17271 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
17272 (parse_spufs_run): New function.
17273 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
17274 (ppc_breakpoint_at): Handle SPU breakpoints.
17276 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
17278 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
17279 (SPUFS_MAGIC): Define.
17280 (spu_enumerate_spu_ids): New function.
17281 (linux_qxfer_spu): New function.
17282 (linux_target_ops): Install linux_qxfer_spu.
17284 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
17286 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
17287 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
17288 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
17289 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
17290 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
17291 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
17292 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
17293 (init_registers_powerpc_cell32l): Add prototype.
17294 (init_registers_powerpc_cell64l): Likewise.
17295 (ppc_arch_setup): Detect Cell/B.E. architecture.
17297 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
17299 * Makefile.in (datarootdir): New variable.
17301 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
17303 * linux-low.c (linux_write_memory): Update debugging output.
17304 * Makefile.in (clean): Add new descriptions.
17305 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
17306 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
17307 * configure.srv: Add new files for arm*-*-linux*.
17308 * linux-arm-low.c: Add new declarations.
17309 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
17310 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
17311 (HWCAP_VFPv3D16): New.
17312 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
17313 instead of __IWMMXT__.
17314 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
17315 (arm_arch_setup): New.
17316 (target_regsets): Remove #ifdef. Add VFP regset.
17317 (the_low_target): Use arm_arch_setup.
17319 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
17321 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
17322 the main thread again.
17324 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
17326 Adding Neutrino gdbserver.
17327 * configure: Regenerated.
17328 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
17329 * configure.srv (i[34567]86-*-nto*): New target.
17330 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
17331 * remote-utils.c [__QNX__]: Include sys/iomgr.h
17332 (nto_comctrl) [__QNX__]: New function.
17333 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
17335 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
17337 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
17340 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
17341 Pedro Alves <pedro@codesourcery.com>
17343 * win32-i386-low.c (i386_get_thread_context): Handle systems that
17344 don't support CONTEXT_EXTENDED_REGISTERS.
17345 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
17346 (the_low_target): Install them.
17347 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
17348 failing with ERROR_PIPE_NOT_CONNECTED.
17350 2009-06-30 Doug Evans <dje@google.com>
17351 Pierre Muller <muller@ics.u-strasbg.fr>
17353 Add h/w watchpoint support to x86-linux, win32-i386.
17354 * Makefile.in (SFILES): Add i386-low.c
17355 (i386_low_h): Define.
17356 (i386-low.o): Add dependencies.
17357 (linux-x86-low.o): Add i386-low.h dependency.
17358 (win32-i386-low.o): Ditto.
17359 * i386-low.c: New file.
17360 * i386-low.h: New file.
17361 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
17362 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
17363 * linux-low.c (linux_add_process): Initialize arch_private.
17364 (linux_remove_process): Free arch_private.
17365 (add_lwp): Initialize arch_private.
17366 (delete_lwp): Free arch_private.
17367 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
17369 * linux-low.h (process_info_private): New member arch_private.
17370 (lwp_info): New member arch_private.
17371 (linux_target_ops): New members new_process, new_thread,
17373 (ptid_of): New macro.
17374 * linux-x86-low.c: Include stddef.h, i386-low.h.
17375 (arch_process_info): New struct.
17376 (arch_lwp_info): New struct.
17377 (x86_linux_dr_get, x86_linux_dr_set): New functions.
17378 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
17379 (i386_dr_low_get_status): New function.
17380 (x86_insert_point, x86_remove_point): New functions.
17381 (x86_stopped_by_watchpoint): New function.
17382 (x86_stopped_data_address): New function.
17383 (x86_linux_new_process, x86_linux_new_thread): New functions.
17384 (x86_linux_prepare_to_resume): New function.
17385 (the_low_target): Add entries for insert_point, remove_point,
17386 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
17388 * server.c (debug_hw_points): New global.
17389 (monitor_show_help): Document set debug-hw-points.
17390 (handle_query): Process "set debug-hw-points".
17391 * server.h (debug_hw_points): Declare.
17392 (paddress): Declare.
17393 * utils.c (NUMCELLS, CELLSIZE): New macros.
17394 (get_sell, xsnprintf, paddress): New functions.
17395 * win32-arm-low.c (the_low_target): Add entries for insert_point,
17396 remove_point, stopped_by_watchpoint, stopped_data_address.
17397 * win32-i386-low.c: Include i386-low.h.
17398 (debug_reg_state): Replaces dr.
17399 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
17400 (i386_dr_low_get_status): New function.
17401 (i386_insert_point, i386_remove_point): New functions.
17402 (i386_stopped_by_watchpoint): New function.
17403 (i386_stopped_data_address): New function.
17404 (i386_initial_stuff): Update.
17405 (get_thread_context,set_thread_context,i386_thread_added): Update.
17406 (the_low_target): Add entries for insert_point,
17407 remove_point, stopped_by_watchpoint, stopped_data_address.
17408 * win32-low.c (win32_insert_watchpoint): New function.
17409 (win32_remove_watchpoint): New function.
17410 (win32_stopped_by_watchpoint): New function.
17411 (win32_stopped_data_address): New function.
17412 (win32_target_ops): Add entries for insert_watchpoint,
17413 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
17414 * win32-low.h (win32_target_ops): New members insert_point,
17415 remove_point, stopped_by_watchpoint, stopped_data_address.
17417 2009-06-25 Pedro Alves <pedro@codesourcery.com>
17419 * server.c (process_serial_event): Re-return unsupported, not
17420 error, if the type isn't recognized. Re-allow supporting only
17421 insert or remove packets. Also call require_running for
17422 breakpoints. Add missing break statement to default case. Tidy.
17423 * target.h (struct target_ops): Rename insert_watchpoint to
17424 insert_point, and remove_watchpoint to remove_point.
17426 * linux-low.h (struct linux_target_ops): Likewise.
17427 * linux-low.c (linux_insert_watchpoint): Rename to ...
17428 (linux_insert_point): ... this. Adjust.
17429 (linux_remove_watchpoint): Rename to ...
17430 (linux_remove_point): ... this. Adjust.
17431 (linux_target_ops): Adjust.
17432 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
17433 (cris_insert_point): ... this.
17434 (cris_remove_watchpoint): Rename to ...
17435 (cris_remove_point): ... this.
17436 (the_low_target): Adjust.
17438 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
17440 * server.c (handle_v_kill): Pass signal_pid to
17441 kill_inferior if multi_process is zero.
17443 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
17445 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
17446 * target.h (target_ops): Comment for *_watchpoint to make it clear
17447 the functions can get types '0' and '1'.
17449 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
17451 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
17452 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
17453 * regcache.c (get_regcache): Likewise.
17454 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
17455 * win32-low.c (child_fetch_inferior_registers): Remove check for
17458 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
17459 Pedro Alves <pedro@codesourcery.com>
17461 * target.h (struct target_ops) <supports_multi_process>: New
17463 (target_supports_multi_process): New.
17464 * server.c (handle_query): Even if GDB reports support, only
17465 enable multi-process if the target also supports it. Report
17466 multi-process support only if the target backend supports it.
17467 * linux-low.c (linux_supports_multi_process): New function.
17468 (linux_target_ops): Install it as target_supports_multi_process
17471 2009-05-24 Doug Evans <dje@google.com>
17473 Global renaming of find_thread_pid to find_thread_ptid.
17474 * server.h (find_thread_ptid): Renamed from find_thread_pid.
17475 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
17476 All callers updated.
17478 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
17479 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
17482 * linux-low.c (get_stop_pc): Print pc if debug_threads.
17483 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
17484 (linux_resume_one_lwp): Ditto.
17486 2009-05-23 Doug Evans <dje@google.com>
17488 * linux-low.c (linux_resume_one_lwp): Change type of first arg
17489 from struct inferior_list_entry * to struct lwp_info *.
17490 All callers updated.
17492 2009-05-13 Doug Evans <dje@google.com>
17494 * linux-x86-low.c: Don't include assert.h.
17495 (x86_siginfo_fixup): Use fatal, not assert.
17496 (x86_arch_setup): Fix comment.
17498 2009-05-12 Doug Evans <dje@google.com>
17500 Biarch support for i386/amd64 gdbserver.
17501 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
17502 Add linux-x86-low.c.
17503 (linux-i386-low.o, linux-x86-64-low.o): Delete.
17504 (linux-x86-low.o): Add.
17505 * linux-x86-64-low.c: Delete.
17506 * linux-i386-low.c: Delete.
17507 * linux-x86-low.c: New file.
17508 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
17510 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
17512 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
17513 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
17514 (linux_child_pid_to_exec_file): New function.
17515 (elf_64_header_p, elf_64_file_p): New functions.
17516 (siginfo_fixup): New function.
17517 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
17518 give target a chance to convert layout.
17519 * linux-low.h (linux_target_ops): New member siginfo_fixup.
17520 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
17522 2009-05-07 Doug Evans <dje@google.com>
17524 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
17525 (regsets_store_inferior_registers): Ditto.
17527 2009-05-06 Pedro Alves <pedro@codesourcery.com>
17531 * linux-low.c (must_set_ptrace_flags): Delete.
17532 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
17534 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
17535 `lwp->must_set_ptrace_flags' instead.
17536 (linux_wait_for_event_1): Set ptrace options here.
17537 (linux_wait_1): ... not here.
17539 2009-04-30 Doug Evans <dje@google.com>
17541 * inferiors.c (started_inferior_callback): New function.
17542 (attached_inferior_callback): New function.
17543 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
17544 * server.c (print_started_pid, print_attached_pid): New functions.
17545 (detach_or_kill_for_exit): New function.
17546 (main): Call it instead of for_each_inferior (kill_inferior_callback).
17547 * server.h (have_started_inferiors_p): Declare.
17548 (have_attached_inferiors_p): Declare.
17550 * inferiors.c (remove_process): Fix memory leak, free process.
17551 * linux-low.c (linux_remove_process): New function.
17552 (linux_kill): Call it instead of remove_process.
17553 (linux_detach, linux_wait_1): Ditto.
17555 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
17557 * configure.srv: Add x86 Windows CE target.
17559 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
17561 * inferiors.c (get_thread_process): Make global.
17562 * server.h (get_thread_process): Add prototype.
17563 * thread-db.c (find_one_thread): Use get_thread_process
17564 instead of current_process.
17565 (thread_db_get_tls_address): Do not crash if called when
17566 thread layer is not yet initialized.
17568 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
17570 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
17571 * spu-low.c (current_tid): Rename to ...
17572 (current_ptid): ... this.
17573 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
17574 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
17575 ptid_get_lwp (current_ptid) instead of current_tid.
17576 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
17577 instead of current_tid. Use find_process_pid to verify pid
17578 argument is valid. Pass proper argument to remove_process.
17579 (spu_thread_alive): Compare current_ptid instead of current_tid.
17580 (spu_resume): Likewise.
17582 2009-04-02 Pedro Alves <pedro@codesourcery.com>
17584 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
17587 2009-04-01 Pedro Alves <pedro@codesourcery.com>
17589 Implement the multiprocess extensions, and add linux multiprocess
17592 * server.h (ULONGEST): Declare.
17593 (struct ptid, ptid_t): New.
17594 (minus_one_ptid, null_ptid): Declare.
17595 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
17596 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
17597 (struct inferior_list_entry): Change `id' type from unsigned from
17599 (struct sym_cache, struct breakpoint, struct
17600 process_info_private): Forward declare.
17601 (struct process_info): Declare.
17602 (current_process): Declare.
17603 (all_processes): Declare.
17604 (initialize_inferiors): Declare.
17605 (add_thread): Adjust to use ptid_t.
17606 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
17607 (add_process, remove_process, find_thread_pid): Declare.
17608 (find_inferior_id): Adjust to use ptid_t.
17609 (cont_thread, general_thread, step_thread): Change type to ptid_t.
17610 (multi_process): Declare.
17611 (push_event): Adjust to use ptid_t.
17612 (read_ptid, write_ptid): Declare.
17613 (prepare_resume_reply): Adjust to use ptid_t.
17614 (clear_symbol_cache): Declare.
17615 * inferiors.c (all_processes): New.
17616 (null_ptid, minus_one_ptid): New.
17617 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
17618 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
17619 (add_thread): Change unsigned long to ptid. Remove gdb_id
17621 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
17622 (gdb_id_to_thread): Rename to ...
17623 (find_thread_pid): ... this. Change unsigned long to ptid.
17624 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
17625 (loaded_dll, pull_pid_from_list): Adjust.
17626 (add_process, remove_process, find_process_pid)
17627 (get_thread_process, current_process, initialize_inferiors): New.
17628 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
17629 (struct target_waitstatus) <related_pid>: Ditto.
17630 (struct target_ops) <kill, detach>: Add `pid' argument. Change
17631 return type to int.
17632 (struct target_ops) <join>: Add `pid' argument.
17633 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
17634 (struct target_ops) <wait>: Add `ptid' field. Change return type
17636 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
17637 (mywait): Add `ptid' argument. Change return type to ptid_t.
17638 (target_pid_to_str): Declare.
17639 * target.c (set_desired_inferior): Adjust to use ptids.
17640 (mywait): Add new `ptid' argument. Adjust.
17641 (target_pid_to_str): New.
17642 * mem-break.h (free_all_breakpoints): Declare.
17643 * mem-break.c (breakpoints): Delelete.
17644 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
17645 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
17646 to use per-process breakpoint list.
17647 (free_all_breakpoints): New.
17648 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
17649 (symbol_cache, all_symbols_looked_up): Delete.
17651 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
17653 (prepare_resume_reply): Change ptid argument's type from unsigned
17654 long to ptid_t. Adjust. Implement W;process and X;process.
17655 (free_sym_cache, clear_symbol_cache): New.
17656 (look_up_one_symbol): Adjust to per-process symbol cache. *
17657 * server.c (cont_thread, general_thread, step_thread): Change type
17659 (attached): Delete.
17660 (multi_process): New.
17661 (last_ptid): Change type to ptid_t.
17662 (struct vstop_notif) <ptid>: Change type to ptid_t.
17663 (queue_stop_reply, push_event): Change `ptid' argument's type to
17665 (discard_queued_stop_replies): Add `pid' argument.
17666 (start_inferior): Adjust to use ptids. Adjust to mywait interface
17667 changes. Don't reference the `attached' global.
17668 (attach_inferior): Adjust to mywait interface changes.
17669 (handle_query): Adjust to use ptids. Parse GDB's qSupported
17670 features. Handle and report "multiprocess+". Handle
17672 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
17674 (handle_v_kill): New.
17675 (handle_v_stopped): Adjust to use target_pid_to_str.
17676 (handle_v_requests): Allow multiple attaches and runs when
17677 multiprocess extensions are in effect. Handle "vKill".
17678 (myresume): Adjust to use ptids.
17679 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
17680 (handle_status): Adjust to discard_queued_stop_replies interface
17682 (first_thread_of, kill_inferior_callback)
17683 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
17684 (main): Call initialize_inferiors. Adjust to use ptids, killing
17685 and detaching from all inferiors. Handle multiprocess packet
17687 * linux-low.h: Include gdb_proc_service.h.
17688 (struct process_info_private): New.
17689 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
17690 <lwpid_of>: Use ptid_get_lwp.
17691 (get_lwp_thread): Adjust.
17692 (struct lwp_info): Add `dead' member.
17693 (find_lwp_pid): Declare.
17694 * linux-low.c (thread_db_active): Delete.
17695 (new_inferior): Adjust comment.
17696 (inferior_pid): Delete.
17697 (linux_add_process): New.
17698 (handle_extended_wait): Adjust.
17699 (add_lwp): Change unsigned long to ptid.
17700 (linux_create_inferior): Add process to processes table. Adjust
17701 to use ptids. Don't set new_inferior here.
17702 (linux_attach_lwp): Rename to ...
17703 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
17704 it. Adjust to use ptids.
17705 (linux_attach_lwp): New.
17706 (linux_attach): Add process to processes table. Don't set
17708 (struct counter): New.
17709 (second_thread_of_pid_p, last_thread_of_process_p): New.
17710 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
17711 multiple processes.
17712 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
17713 processes. Remove process from process table.
17714 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
17715 to multiple processes.
17716 (any_thread_of): New.
17717 (linux_detach): Add `pid' argument, and handle it. Remove process
17718 from processes table.
17719 (linux_join): Add `pid' argument. Handle it.
17720 (linux_thread_alive): Change unsighed long argument to ptid_t.
17721 Consider dead lwps as not being alive.
17722 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
17723 threads we're not interested in.
17724 (same_lwp, find_lwp_pid): New.
17725 (linux_wait_for_lwp): Change `pid' argument's type from int to
17727 (linux_wait_for_event): Rename to ...
17728 (linux_wait_for_event_1): ... this. Change `pid' argument's type
17729 from int to ptid_t. Adjust.
17730 (linux_wait_for_event): New.
17731 (linux_wait_1): Add `ptid' argument. Change return type to
17732 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
17733 that exit from the process table.
17734 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
17736 (mark_lwp_dead): New.
17737 (wait_for_sigstop): Adjust to use ptids. If a process exits while
17738 stopping all threads, mark its main lwp as dead.
17739 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
17741 (fetch_register, usr_store_inferior_registers)
17742 (regsets_fetch_inferior_registers)
17743 (regsets_store_inferior_registers, linux_read_memory)
17744 (linux_write_memory): Inline `inferior_pid'.
17745 (linux_look_up_symbols): Adjust to use per-process
17746 `thread_db_active'.
17747 (linux_request_interrupt): Adjust to use ptids.
17748 (linux_read_auxv): Inline `inferior_pid'.
17749 (initialize_low): Don't reference thread_db_active.
17750 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
17751 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
17752 (ps_getpid): Return the pid of the current inferior.
17753 * thread-db.c (proc_handle, thread_agent): Delete.
17754 (thread_db_create_event, thread_db_enable_reporting): Adjust to
17756 (find_one_thread): Change argument type to ptid_t. Adjust to
17758 (maybe_attach_thread): Adjust to per-process data and ptids.
17759 (thread_db_find_new_threads): Ditto.
17760 (thread_db_init): Ditto.
17761 * spu-low.c (spu_create_inferior, spu_attach): Add process to
17762 processes table. Adjust to use ptids.
17763 (spu_kill, spu_detach): Adjust interface. Remove process from
17765 (spu_join, spu_thread_alive): Adjust interface.
17766 (spu_wait): Adjust interface. Remove process from processes
17767 table. Adjust to use ptids.
17768 * win32-low.c (current_inferior_tid): Delete.
17769 (current_inferior_ptid): New.
17770 (debug_event_ptid): New.
17771 (thread_rec): Take a ptid. Adjust.
17772 (child_add_thread): Add `pid' argument. Adjust to use ptids.
17773 (child_delete_thread): Ditto.
17774 (do_initial_child_stuff): Add `attached' argument. Add process to
17776 (child_fetch_inferior_registers, child_store_inferior_registers):
17778 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
17779 (win32_attach): Pass 1 to do_initial_child_stuff.
17780 (win32_kill): Adjust interface. Remove process from processes
17782 (win32_detach): Ditto.
17783 (win32_join): Adjust interface.
17784 (win32_thread_alive): Take a ptid.
17785 (win32_resume): Adjust to use ptids.
17786 (get_child_debug_event): Ditto.
17787 (win32_wait): Adjust interface. Remove exiting process from
17790 2009-04-01 Pedro Alves <pedro@codesourcery.com>
17792 Non-stop mode support.
17794 * server.h (non_stop): Declare.
17795 (gdb_client_data, handler_func): Declare.
17796 (delete_file_handler, add_file_handler, start_event_loop):
17798 (handle_serial_event, handle_target_event, push_event)
17799 (putpkt_notif): Declare.
17800 * target.h (enum resume_kind): New.
17801 (struct thread_resume): Replace `step' field by `kind' field.
17802 (TARGET_WNOHANG): Define.
17803 (struct target_ops) <wait>: Add `options' argument.
17804 <supports_non_stop, async, start_non_stop>: New fields.
17805 (target_supports_non_stop, target_async): New.
17806 (start_non_stop): Declare.
17807 (mywait): Add `options' argument.
17808 * target.c (mywait): Add `options' argument. Print child exit
17809 notifications here.
17810 (start_non_stop): New.
17811 * server.c (non_stop, own_buf, mem_buf): New globals.
17812 (struct vstop_notif): New.
17813 (notif_queue): New global.
17814 (queue_stop_reply, push_event, discard_queued_stop_replies)
17815 (send_next_stop_reply): New.
17816 (start_inferior): Adjust to use resume_kind. Adjust to mywait
17818 (attach_inferior): In non-stop mode, don't wait for the target
17820 (handle_general_set): Handle QNonStop.
17821 (handle_query): When handling qC, return the current general
17822 thread, instead of the first thread of the list.
17823 (handle_query): If the backend supports non-stop mode, include
17824 QNonStop+ in the qSupported query response.
17825 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
17827 (handle_v_attach, handle_v_run): Handle non-stop mode.
17828 (handle_v_stopped): New.
17829 (handle_v_requests): Report support for vCont;t. Handle vStopped.
17830 (myresume): Adjust to use resume_kind. Handle non-stop.
17831 (queue_stop_reply_callback): New.
17832 (handle_status): Handle non-stop mode.
17833 (main): Clear non_stop flag on reconnection. Use the event-loop.
17834 Refactor serial protocol handling from here ...
17835 (process_serial_event): ... to this new function. When GDB
17836 selects any thread, select one here. In non-stop mode, wait until
17837 GDB acks all pending events before exiting.
17838 (handle_serial_event, handle_target_event): New.
17839 * remote-utils.c (remote_open): Install remote_desc in the event
17841 (remote_close): Remove remote_desc from the event loop.
17842 (putpkt_binary): Rename to...
17843 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
17844 (putpkt_binary): New as wrapper around putpkt_binary_1.
17845 (putpkt_notif): New.
17846 (prepare_resume_reply): In non-stop mode, don't change the
17848 * event-loop.c: New.
17849 * Makefile.in (OBJ): Add event-loop.o.
17850 (event-loop.o): New rule.
17852 * linux-low.h (pid_of): Moved here.
17854 (get_lwp_thread): Use lwpid_of.
17855 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
17856 * linux-low.c (pid_of): Delete.
17857 (inferior_pid): Use lwpid_of.
17858 (linux_event_pipe): New.
17859 (target_is_async_p): New.
17861 (handle_extended_wait): Use lwpid_of.
17862 (add_lwp): Don't set lwpid field.
17863 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
17864 (linux_kill_one_lwp): If killing a running lwp, stop it first.
17865 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
17866 (linux_detach_one_lwp): If detaching from a running lwp, stop it
17867 first. Adjust to linux_wait_for_event interface changes. Use
17869 (linux_detach): Don't delete the main lwp here.
17870 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
17871 (status_pending_p): Don't consider explicitly suspended lwps.
17872 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
17873 pointer. Add OPTIONS argument. Change return type to int. Use
17874 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
17875 (linux_wait_for_event): Take an integer pid instead of a lwp_info
17876 pointer. Add status pointer argument. Return a pid instead of a
17877 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
17878 changes. In non-stop mode, don't switch to a random thread.
17879 (linux_wait): Rename to...
17880 (linux_wait_1): ... this. Add target_options argument, and handle
17881 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
17882 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
17883 clean exit and signal exit code. Don't stop all threads in
17884 non-stop mode. In all-stop mode, only stop all threads when
17885 reporting a stop to GDB. Handle explicit thread stop requests.
17886 (async_file_flush, async_file_mark): New.
17888 (send_sigstop): Use lwpid_of.
17889 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
17890 interface changes. In non-stop mode, don't switch to a random
17892 (linux_resume_one_lwp): Use lwpid_of.
17893 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
17894 (linux_resume_one_thread): ... this. Handle resume_stop. In
17895 non-stop mode, don't look for pending flag in all threads.
17896 (resume_status_pending_p): Don't consider explicitly suspended
17898 (my_waitpid): Reimplement. Emulate __WALL.
17899 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
17901 (sigchld_handler, linux_supports_non_stop, linux_async)
17902 (linux_start_non_stop): New.
17903 (linux_target_ops): Register linux_supports_non_stop, linux_async
17904 and linux_start_non_stop.
17905 (initialize_low): Install SIGCHLD handler.
17906 * thread-db.c (thread_db_create_event, find_one_thread)
17907 (thread_db_get_tls_address): Use lwpid_of.
17908 * win32-low.c (win32_detach): Adjust to use resume_kind.
17909 (win32_wait): Add `options' argument.
17910 * spu-low.c (spu_resume): Adjust to use resume_kind.
17911 (spu_wait): Add `options' argument.
17913 2009-04-01 Pedro Alves <pedro@codesourcery.com>
17915 Decouple target code from remote protocol.
17917 * target.h (enum target_waitkind): New.
17918 (struct target_waitstatus): New.
17919 (struct target_ops) <wait>: Return an unsigned long. Take a
17920 target_waitstatus pointer instead of a char pointer.
17921 (mywait): Likewise.
17922 * target.c (mywait): Change prototype to return an unsigned long.
17923 Take a target_waitstatus pointer instead of a char pointer. Adjust.
17924 * server.h (thread_from_wait, old_thread_from_wait): Delete
17926 (prepare_resume_reply): Change prototype to take a
17928 * server.c (thread_from_wait, old_thread_from_wait): Delete.
17929 (last_status, last_ptid): New.
17930 (start_inferior): Remove "statusptr" argument. Adjust. Return a
17931 pid instead of a signal.
17932 (attach_inferior): Remove "status" and "signal" parameters.
17934 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
17936 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
17937 (handle_v_requests, myresume): Remove "status" and "signal"
17938 parameters. Adjust.
17939 (handle_status): New.
17940 (main): Delete local `status'. Adjust.
17941 * remote-utils.c: Include target.h.
17942 (prepare_resume_reply): Change prototype to take a
17943 target_waitstatus. Adjust.
17945 * linux-low.c (linux_wait): Adjust to new target_ops->wait
17947 * spu-low.c (spu_wait): Adjust.
17948 * win32-low.c (enum target_waitkind, struct target_waitstatus):
17950 (win32_wait): Adjust.
17952 2009-04-01 Pedro Alves <pedro@codesourcery.com>
17954 * target.h (struct thread_resume): Delete leave_stopped member.
17955 (struct target_ops): Add a `n' argument to the `resume' callback.
17956 * server.c (start_inferior): Adjust.
17957 (handle_v_cont, myresume): Adjust.
17958 * linux-low.c (check_removed_breakpoint): Adjust to resume
17959 interface change, and to removed leave_stopped field.
17960 (resume_ptr): Delete.
17961 (struct thread_resume_array): New.
17962 (linux_set_resume_request): Add new `arg' parameter. Adjust to
17963 resume interface change.
17964 (linux_continue_one_thread, linux_queue_one_thread)
17965 (resume_status_pending_p): Check if the resume field is NULL
17966 instead of checking the leave_stopped member.
17967 (linux_resume): Adjust to the target resume interface change.
17968 * spu-low.c (spu_resume): Adjust to the target resume interface
17970 * win32-low.c (win32_detach, win32_resume): Ditto.
17972 2009-04-01 Pedro Alves <pedro@codesourcery.com>
17974 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
17976 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
17978 (linux_continue_one_thread): Only preserve the stepping flag if
17979 there's a pending breakpoint.
17981 2009-03-31 Pedro Alves <pedro@codesourcery.com>
17983 * server.c (main): After the inferior having exited, call
17984 remote_close before exiting gdbserver.
17986 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
17988 Fix size of FPSCR in Power 7 processors.
17989 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
17990 (PPC_FEATURE_HAS_DFP): New #define.
17991 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
17994 2009-03-23 Pedro Alves <pedro@codesourcery.com>
17996 * server.c (handle_query) Whitespace and formatting.
17998 2009-03-22 Pedro Alves <pedro@codesourcery.com>
18000 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
18001 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
18002 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
18003 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
18004 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
18005 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
18006 Makefile.in, configure.ac: Fix whitespace throughout.
18007 * configure: Regenerate.
18009 2009-03-22 Pedro Alves <pedro@codesourcery.com>
18011 * inferiors.c (find_inferior): Make it safe for the callback
18012 function to delete the currently iterated inferior.
18014 2009-03-22 Pedro Alves <pedro@codesourcery.com>
18016 * Makefile.in (linuw_low_h): Move higher.
18017 (thread-db.o): Depend on $(linux_low_h).
18019 2009-03-17 Pedro Alves <pedro@codesourcery.com>
18021 Rename "process" to "lwp" throughout.
18023 * linux-low.c (all_processes): Rename to...
18024 (all_lwps): ... this.
18025 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
18026 (add_process): Rename to ...
18027 (add_lwp): ... this. Adjust.
18028 (linux_create_inferior): Adjust.
18029 (linux_attach_lwp): Adjust.
18030 (linux_attach): Adjust.
18031 (linux_kill_one_process): Rename to ...
18032 (linux_kill_one_lwp): ... this. Adjust.
18033 (linux_kill): Adjust.
18034 (linux_detach_one_process): Rename to ...
18035 (linux_detach_one_lwp): ... this. Adjust.
18036 (linux_detach): Adjust.
18037 (check_removed_breakpoint): Adjust.
18038 (status_pending_p): Adjust.
18039 (linux_wait_for_process): Rename to ...
18040 (linux_wait_for_lwp): ... this. Adjust.
18041 (linux_wait_for_event): Adjust.
18042 (send_sigstop): Adjust.
18043 (wait_for_sigstop): Adjust.
18044 (stop_all_processes): Rename to ...
18045 (stop_all_lwps): ... this.
18046 (linux_resume_one_process): Rename to ...
18047 (linux_resume_one_lwp): ... this. Adjust.
18048 (linux_set_resume_request, linux_continue_one_thread)
18049 (linux_queue_one_thread, resume_status_pending_p)
18050 (usr_store_inferior_registers, regsets_store_inferior_registers)
18051 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
18053 * linux-low.h (get_process): Rename to ...
18054 (get_lwp): ... this. Adjust.
18055 (get_thread_process): Rename to ...
18056 (get_thread_lwp): ... this. Adjust.
18057 (get_process_thread): Rename to ...
18058 (get_lwp_thread): ... this. Adjust.
18059 (struct process_info): Rename to ...
18060 (struct lwp_info): ... this.
18061 (all_processes): Rename to ...
18062 (all_lwps): ... this.
18063 * proc-service.c (ps_lgetregs): Adjust.
18064 * thread-db.c (thread_db_create_event, find_one_thread)
18065 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
18067 2009-03-14 Pedro Alves <pedro@codesourcery.com>
18069 * server.c (handle_query): Handle "qAttached".
18071 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
18073 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
18074 GPLv3, update license URL.
18076 2009-03-01 Doug Evans <dje@google.com>
18078 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
18079 (server_h): Add gdb_signals.h.
18080 (signals.o): Update.
18081 * server.h (target_signal_from_host,target_signal_to_host_p)
18082 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
18084 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
18086 * remote-utils.c (getpkt): Also generate remote-debug
18087 information if noack_mode is set.
18089 2009-02-06 Pedro Alves <pedro@codesourcery.com>
18091 * server.c (handle_query): Report qXfer:siginfo:read and
18092 qXfer:siginfo:write as supported and handle them.
18093 * target.h (struct target_ops) <qxfer_siginfo>: New field.
18094 * linux-low.c (linux_xfer_siginfo): New.
18095 (linux_target_ops): Set it.
18097 2009-01-26 Pedro Alves <pedro@codesourcery.com>
18099 * server.c (gdbserver_usage): Mention --remote-debug.
18100 (main): Accept '--remote-debug' switch.
18102 2009-01-18 Doug Evans <dje@google.com>
18104 * regcache.c (new_register_cache): No need to check result of xcalloc.
18105 * server.c (handle_search_memory): Back out calls to xmalloc,
18106 result is checked and error is returned to user upon failure.
18107 (handle_query): Ditto. Add more checks for result of malloc.
18108 (handle_v_cont): Check result of malloc, report error back to
18110 (handle_v_run): Ditto. Call freeargv.
18111 * server.h (freeargv): Declare.
18112 * utils.c (freeargv): New fn.
18114 2009-01-15 Doug Evans <dje@google.com>
18116 * gdbreplay.c (perror_with_name): Make arg const char *.
18117 * server.h (target_signal_to_name): Make return type const char *.
18118 * thread-db.c (thread_db_err_str): Make return type const char *.
18119 * utils.c (perror_with_name): Make arg const char *.
18121 2009-01-14 Pedro Alves <pedro@codesourcery.com>
18123 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
18124 when handling a EXIT_PROCESS_DEBUG_EVENT.
18126 2009-01-06 Joel Brobecker <brobecker@adacore.com>
18128 * gdbreplay.c (gdbreplay_version): Update copyright year.
18129 * server.c (gdbserver_version): Likewise.
18131 2009-01-05 Doug Evans <dje@google.com>
18133 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
18134 (handle_extended_wait): Improve comment.
18136 2008-12-13 Doug Evans <dje@google.com>
18138 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
18139 * server.h (ATTR_MALLOC): New macro.
18140 (xmalloc,xcalloc,xstrdup): Declare.
18141 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
18142 * inferiors.c: Ditto.
18143 * linux-low.c: Ditto.
18144 * mem-break.c: Ditto.
18145 * regcache.c: Ditto.
18146 * remote-utils.c: Ditto.
18149 * win32-low.c: Ditto.
18151 2008-12-12 Doug Evans <dje@google.com>
18153 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
18154 in debugging printf.
18156 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
18158 2008-12-09 Doug Evans <dje@google.com>
18160 * linux-low.h (struct process_info): Delete member tid, unused.
18161 * thread-db.c (find_one_thread): Update.
18162 (maybe_attach_thread): Update.
18164 2008-12-02 Pedro Alves <pedro@codesourcery.com>
18166 * target.h (struct target_ops): Add qxfer_osdata member.
18167 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
18169 (linux_qxfer_osdata): New functions.
18170 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
18172 * server.c (handle_query): Handle "qXfer:osdata:read:".
18173 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
18174 (buffer_xml_printf): New functions.
18175 * server.h (struct buffer): New.
18176 (buffer_grow_str, buffer_grow_str0): New macros.
18177 (buffer_grow, buffer_free, buffer_init, buffer_finish)
18178 (buffer_xml_printf): Declare.
18180 2008-11-24 Doug Evans <dje@google.com>
18182 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
18184 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
18186 * server.c (handle_v_run): Always use the supplied argument list.
18188 2008-11-19 Bob Wilson <bob.wilson@acm.org>
18190 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
18191 (xtensa_regmap_table): Add entry for scompare1.
18193 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
18195 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
18196 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
18197 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
18198 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
18199 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
18200 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
18201 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
18202 XML target descriptions.
18203 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
18204 when inferior is running on an ISA 2.05 or later processor. Add
18205 special case to return offset for full 64-bit slot of FPSCR when
18208 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
18210 * Makefile.in (SFILES, clean): Added sparc64 files.
18211 (reg-sparc64.o, reg-sparc64.c): New.
18212 * configure.srv (sparc*-*-linux*): New configuration.
18213 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
18214 syscall arguments for SPARC.
18215 (regsets_store_inferior_registers): Likewise.
18216 * linux-sparc-low.c: New file.
18218 2008-10-21 Doug Evans <dje@google.com>
18220 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
18221 (READLINE_DIR,READLINE_DEP): Delete.
18222 (INTERNAL_CFLAGS): Update.
18223 (LINTFLAGS): Update.
18225 2008-10-10 Pedro Alves <pedro@codesourcery.com>
18227 * server.c (handle_v_run): If GDB didn't specify an argv, use the
18228 whole argv from the last run, not just argv[0].
18230 2008-09-08 Pedro Alves <pedro@codesourcery.com>
18232 * regcache.c (new_register_cache): Return NULL if the register
18233 cache size isn't known yet.
18234 (free_register_cache): Avoid dereferencing a NULL regcache.
18236 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
18238 * configure.srv: Merge MIPS and MIPS64.
18240 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
18242 * Makefile.in (uninstall): Apply $(EXEEXT) too.
18244 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
18246 * Makefile.in: Add required vsx dependencies.
18248 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
18249 Declare init_registers_powerpc_vsx32l.
18250 Declare init_registers_powerpc_vsx64l.
18251 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
18252 (ppc_arch_setup): Check for VSX in hwcap.
18253 (ppc_fill_vsxregset): New function.
18254 (ppc_store_vsxregset): New function.
18255 Add new VSX entry in regset_info target_regsets.
18257 * configure.srv: Add new VSX dependencies.
18259 2008-08-12 Pedro Alves <pedro@codesourcery.com>
18261 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
18262 (remote_open): Set or clear transport_is_reliable.
18263 (putpkt_binary): Don't expect acks in noack mode.
18264 (getpkt): Don't send ack/nac in noack mode.
18265 * server.c (handle_general_set): Handle QStartNoAckMode.
18266 (handle_query): If connected by tcp pass QStartNoAckMode+ in
18268 (main): Reset noack_mode on every connection.
18269 * server.h (noack_mode): Declare.
18271 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18273 * Makefile.in (GDBREPLAY_OBS): New variable.
18274 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
18276 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
18277 Daniel Jacobowitz <dan@codesourcery.com>
18279 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
18280 (usr_store_inferior_registers): Likewise.
18281 (regsets_store_inferior_registers): Likewise.
18283 2008-07-31 Rolf Jansen <rj@surtec.com>
18284 Pedro Alves <pedro@codesourcery.com>
18286 * configure.ac: Check for memmem declaration.
18287 * server.c [HAVE_MALLOC_H]: Include malloc.h.
18288 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
18289 (disable_packet_qfThreadInfo): Unconditionally compile.
18290 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
18291 * configure, config.in: Regenerate.
18293 2008-07-28 Doug Kwan <dougkwan@google.com>
18295 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
18296 (linux_write_memory): Remove declaration of errno.
18298 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
18300 * linux-low.c (handle_extended_wait): Do not use "status"
18301 variable uninitialized.
18303 2008-07-07 Pedro Alves <pedro@codesourcery.com>
18305 * server.c (handle_v_attach): Inhibit reporting dll changes.
18307 2008-06-27 Pedro Alves <pedro@codesourcery.com>
18309 * remote-utils.c (prepare_resume_reply): If requested, don't
18310 output "thread:TID" in the T stop reply.
18312 * server.c (disable_packet_vCont, disable_packet_Tthread)
18313 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
18314 (handle_query): If requested, disable support for qC, qfThreadInfo
18316 (handle_v_requests): If requested, disable support for vCont.
18317 (gdbserver_show_disableable): New.
18318 (main): Handle --disable-packet and --disable-packet=LIST.
18320 * server.h (disable_packet_vCont, disable_packet_Tthread)
18321 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
18323 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
18325 * server.c (gdbserver_usage): Mention --version.
18327 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
18329 * Makefile.in (gdbreplay.o): New rule.
18331 2008-06-06 Joseph Myers <joseph@codesourcery.com>
18333 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
18334 message, not gdbserver.
18336 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
18337 Nathan Sidwell <nathan@codesourcery.com>
18338 Joseph Myers <joseph@codesourcery.com>
18340 * acinclude.m4: Include ../../config/acx.m4.
18341 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
18342 * configure, config.in: Regenerate.
18343 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
18344 * server.c (gdbserver_version): Print PKGVERSION.
18345 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
18346 (main): Adjust gdbserver_usage calls.
18347 * gdbreplay.c (version, host_name): Add declarations.
18348 (gdbreplay_version, gdbreplay_usage): New.
18349 (main): Accept --version and --help options.
18351 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
18353 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
18354 (arm_breakpoint_at): Handle Thumb.
18355 (the_low_target): Add comment.
18357 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
18359 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
18361 2008-05-09 Doug Evans <dje@google.com>
18363 * server.h (decode_search_memory_packet): Declare.
18364 * remote-utils.c (decode_search_memory_packet): New fn.
18365 * server.c (handle_search_memory_1): New fn.
18366 (handle_search_memory): New fn.
18367 (handle_query): Process qSearch:memory packets.
18369 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
18371 * regcache.c (registers_length): Remove.
18372 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
18373 full register packet.
18374 * regcache.h (registers_length): Remove prototype.
18375 * server.h (PBUFSIZ): Define to 16384.
18377 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
18379 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
18380 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
18381 powerpc-64l.o, and powerpc-altivec64l.o.
18382 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
18383 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
18384 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
18385 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
18386 rs6000/power-linux.xml, and rs6000/power64-linux.xml
18389 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
18390 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
18391 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
18392 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
18393 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
18394 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
18395 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
18396 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
18397 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
18398 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
18401 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
18402 (init_registers_powerpc_32l): ... this new prototype.
18403 (init_registers_powerpc_32): Remove, replace by ...
18404 (init_registers_powerpc_altivec32l): ... this new prototype.
18405 (init_registers_powerpc_e500): Remove, replace by ...
18406 (init_registers_powerpc_e500l): ... this new prototype.
18407 (init_registers_ppc64): Remove, replace by ...
18408 (init_registers_powerpc_64l): ... this new prototype.
18409 (init_registers_powerpc_64): Remove, replace by ...
18410 (init_registers_powerpc_altivec64l): ... this new prototype.
18411 (ppc_num_regs): Set to 73.
18412 (PT_ORIG_R3, PT_TRAP): Define if necessary.
18413 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
18414 (ppc_cannot_store_register): Handle orig_r3 and trap.
18415 (ppc_arch_setup): Update init_registers_... calls.
18416 (ppc_fill_gregset): Handle orig_r3 and trap.
18418 * inferiors.c (clear_inferiors): Reset current_inferior.
18420 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
18422 * acinclude.m4: Add override.m4.
18423 * configure: Regenerate.
18425 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
18427 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
18428 initial call to init_register_ppc64.
18430 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
18432 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
18433 single powerpc*-*-linux* case.
18434 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
18436 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
18438 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
18439 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
18441 * linux-ppc-low.c: Include <elf.h>.
18442 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
18443 (ppc_hwcap): New global variable.
18444 (ppc_regmap): Remove __SPE__ #ifdef sections.
18445 (ppc_regmap_e500): New global variable.
18446 (ppc_cannot_store_register): Update __SPE__ special case.
18447 (ppc_get_hwcap): New function.
18448 (ppc_arch_setup): Use it to determine whether inferior supports
18449 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
18450 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
18451 Do not access registers if target does not support AltiVec.
18452 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
18453 Do not access registers if target does not support SPE.
18454 (target_regsets): Unconditionally include AltiVec and SPE regsets.
18456 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
18458 * linux-low.c (disabled_regsets, num_regsets): New.
18459 (use_regsets_p): Delete.
18460 (linux_wait_for_process): Clear disabled_regsets.
18461 (regsets_fetch_inferior_registers): Check and set it.
18462 (regsets_store_inferior_registers): Likewise.
18463 (linux_fetch_registers, linux_store_registers): Do not use
18465 (initialize_low): Allocate disabled_regsets.
18467 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
18469 * Makefile.in (LIBOBJS): New.
18470 (OBS): Use LIBOBJS.
18471 (memmem.o): New rule.
18472 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
18473 * configure: Regenerated.
18475 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
18477 * server.c (handle_query): Never return "unsupported" for
18478 qXfer:features:read queries.
18480 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
18482 * server.c (get_features_xml): Fix inverted condition.
18483 (handle_query): Always support qXfer:feature:read.
18485 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
18487 * server.c (wrapper_argv): New.
18488 (start_inferior): Handle wrapper_argv. If set, expect an extra
18490 (gdbserver_usage): Document --wrapper.
18491 (main): Parse --wrapper.
18493 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
18495 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
18496 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
18497 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
18498 (ppc_set_pc): Likewise.
18499 (ppc_arch_setup): New function.
18500 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
18501 of collect_register.
18502 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
18504 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
18506 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
18507 instead of linux-ppc64-low.o.
18508 * linux-ppc64-low.c: Remove file.
18509 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
18510 (linux-ppc64-low.o): Remove rule.
18512 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
18513 (init_registers_powerpc_64): Likewise.
18514 (ppc_regmap): Conditionally define depending on __powerpc64__.
18515 (ppc_cannot_store_register): Do not special-case "fpscr" when
18516 compiled on __powerpc64__.
18517 (ppc_collect_ptrace_register): New function.
18518 (ppc_supply_ptrace_register): New function.
18519 (ppc_breakpoint): Change type to "unsigned int".
18520 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
18521 (the_low_target): Conditionally provide initializers for the
18522 arch_setup member depending on __powerpc64__. Install
18523 collect_ptrace_register and supply_ptrace_register members.
18525 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
18527 * regcache.h (gdbserver_xmltarget): Add extern declaration.
18528 * server.c (gdbserver_xmltarget): Define.
18529 (get_features_xml): Use it to replace "target.xml" and arch_string.
18531 * configure.srv: Remove srv_xmltarget. Add XML files that were
18532 mentioned there to srv_xmlfiles instead. Remove conditional tests
18533 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
18534 srv_xmlfiles and srv_regobj to include all possible choices.
18535 * configure.ac (srv_xmltarget): Remove.
18536 (srv_xmlfiles): Do not add "target.xml".
18537 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
18538 checks for supplementary target information.
18539 * configure: Regenerate.
18540 * Makefile.in (XML_TARGET): Remove.
18541 (target.xml): Remove rule.
18542 (clean): Do not clean up target.xml.
18543 (.PRECIOUS): Do not mention target.xml.
18545 * target.h (struct target_ops): Remove arch_string member.
18546 * linux-low.c (linux_arch_string): Remove.
18547 (linux_target_ops): Remove arch_string initializer.
18548 * linux-low.h (struct linux_target_ops): Remove arch_string member.
18549 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
18550 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
18551 * spu-low.c (spu_arch_string): Remove.
18552 (spu_target_ops): Remove arch_string initializer.
18553 * win32-low.c (win32_arch_string): Remove.
18554 (win32_target_ops): Remove arch_string initializer.
18555 * win32-low.h (struct win32_target_ops): Remove arch_string member.
18556 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
18557 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
18559 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
18561 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
18562 by collect_ptrace_register and supply_ptrace_register hooks.
18563 * linux-low.c (fetch_register): Use supply_ptrace_register callback
18564 instead of checking for the_low_target.left_pad_xfer.
18565 (usr_store_inferior_registers): Use collect_ptrace_register callback
18566 instead of checking for the_low_target.left_pad_xfer.
18568 * linux-s390-low.c (s390_collect_ptrace_register): New function.
18569 (s390_supply_ptrace_register): Likewise.
18570 (s390_fill_gregset): Call s390_collect_ptrace_register.
18571 (the_low_target): Update.
18573 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
18574 (ppc_supply_ptrace_register): Likewise.
18575 (the_low_target): Update.
18577 * linux-i386-low.c (the_low_target): Update.
18578 * linux-x86-64-low.c (the_low_target): Update.
18580 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
18582 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
18583 reg-s390.o and reg-s390x.o.
18585 * linux-low.c (new_inferior): New global variable.
18586 (linux_create_inferior, linux_attach): Set it.
18587 (linux_wait_for_process): Call the_low_target.arch_setup after the
18588 target has stopped for the first time.
18589 (initialize_low): Do not call the_low_target.arch_setup.
18591 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
18592 (s390_set_pc): Likewise.
18593 (s390_arch_setup): New function.
18594 (the_low_target): Use s390_arch_setup as arch_setup routine.
18596 * regcache.c (realloc_register_cache): New function.
18597 (set_register_cache): Call it for each existing regcache.
18599 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
18601 * server.h (init_registers): Remove prototype.
18603 * linux-low.h (struct linux_target_ops): Add arch_setup field.
18604 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
18605 instead of init_registers ().
18606 * linux-arm-low.c (init_registers_arm): Add prototype.
18607 (init_registers_arm_with_iwmmxt): Likewise.
18608 (the_low_target): Add initializer for arch_setup field.
18609 * linux-cris-low.c (init_registers_cris): Add prototype.
18610 (the_low_target): Add initializer for arch_setup field.
18611 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
18612 (the_low_target): Add initializer for arch_setup field.
18613 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
18614 (the_low_target): Add initializer for arch_setup field.
18615 * linux-ia64-low.c (init_registers_ia64): Add prototype.
18616 (the_low_target): Add initializer for arch_setup field.
18617 * linux-m32r-low.c (init_registers_m32r): Add prototype.
18618 (the_low_target): Add initializer for arch_setup field.
18619 * linux-m68k-low.c (init_registers_m68k): Add prototype.
18620 (the_low_target): Add initializer for arch_setup field.
18621 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
18622 (init_registers_mips64_linux): Likewise.
18623 (the_low_target): Add initializer for arch_setup field.
18624 * linux-ppc-low.c (init_registers_ppc): Add prototype.
18625 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
18626 (the_low_target): Add initializer for arch_setup field.
18627 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
18628 (init_registers_powerpc_64): Likewise.
18629 (the_low_target): Add initializer for arch_setup field.
18630 * linux-s390-low.c (init_registers_s390): Add prototype.
18631 (init_registers_s390x): Likewise.
18632 (the_low_target): Add initializer for arch_setup field.
18633 * linux-sh-low.c (init_registers_sh): Add prototype.
18634 (the_low_target): Add initializer for arch_setup field.
18635 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
18636 (the_low_target): Add initializer for arch_setup field.
18637 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
18638 (the_low_target): Add initializer for arch_setup field.
18640 * win32-low.h (struct win32_target_ops): Add arch_setup field.
18641 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
18642 instead of init_registers ().
18643 * win32-arm-low.c (init_registers_arm): Add prototype.
18644 (the_low_target): Add initializer for arch_setup field.
18645 * win32-i386-low.c (init_registers_i386): Add prototype.
18646 (the_low_target): Add initializer for arch_setup field.
18648 * spu-low.c (init_registers_spu): Add prototype.
18649 (initialize_low): Call initialie_registers_spu () instead of
18650 initialize_registers ().
18652 2008-02-19 Pedro Alves <pedro@codesourcery.com>
18654 * server.c (handle_v_requests): When handling the vRun and vAttach
18655 packets, if already debugging a process, don't kill it. Return an
18658 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
18660 * server.c (handle_query): Correct length check.
18662 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
18664 * win32-low.c (do_initial_child_stuff): Add process handle
18665 parameter. Set current_process_handle and current_process_id from the
18666 parameters. Clear globals.
18667 (win32_create_inferior): Don't set current_process_handle and
18668 current_process_id here. Instead pass them on the call to
18669 do_initial_child_stuff.
18670 (win32_attach): Likewise.
18671 (win32_clear_inferiors): New.
18672 (win32_kill): Don't close the current process handle or the
18673 current thread handle here. Instead call win32_clear_inferiors.
18674 (win32_detach): Don't open a new handle to the process. Call
18675 win32_clear_inferiors.
18676 (win32_join): Don't rely on current_process_handle; open a new
18677 handle using the process id.
18678 (win32_wait): Call win32_clear_inferiors when the inferior process
18681 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
18683 * server.c (monitor_show_help): Add "exit".
18685 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
18687 * Makefile.in (SFILES): Add linux-xtensa-low.c.
18688 (clean): Add reg-xtensa.c.
18689 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
18690 * configure.srv (xtensa*-*-linux*) New target.
18691 * linux-xtensa-low.c: New.
18692 * xtensa-xtregs.c: New.
18694 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
18696 * hostio.c: Don't include errno.h.
18697 (errno_to_fileio_errno): Move to hostio-errno.
18698 * hostio.c: (hostio_error): Remove the error parameter. Defer the
18699 error number outputting to the target->hostio_last_error callback.
18700 (hostio_packet_error): Use FILEIO_EINVAL directly.
18701 (handle_open, handle_pread, hostio_error, handle_unlink): Update
18702 calls to hostio_error.
18703 * hostio-errno.c: New.
18704 * server.h (hostio_last_error_from_errno): Declare.
18705 * target.h (target_ops): Add hostio_last_error member.
18706 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
18707 as hostio_last_error handler.
18708 * spu-low.c (spu_target_ops): Likewise.
18709 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
18710 (wince_hostio_last_error): New functions.
18711 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
18712 as hostio_last_error handler.
18713 (win32_target_ops) [!_WIN32_WCE]: Register
18714 hostio_last_error_from_errno as hostio_last_error handler.
18715 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
18716 (hostio-errno.o): New rule.
18717 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
18718 * configure.srv (srv_hostio_err_objs): New variable. Default to
18720 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
18721 * configure: Regenerate.
18723 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
18725 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
18726 (linux_kill, linux_detach): Clean up the process list.
18727 * remote-utils.c (remote_open): Improve port number parsing.
18728 (putpkt_binary, input_interrupt): Only send interrupts if the target
18730 * server.c (extended_protocol): Make static.
18731 (attached): Define earlier.
18732 (exit_requested, response_needed, program_argv): New variables.
18733 (target_running): New.
18734 (start_inferior): Clear attached here.
18735 (attach_inferior): Set attached here.
18736 (require_running): Define.
18737 (handle_query): Use require_running and target_running. Implement
18739 (handle_v_attach, handle_v_run): New.
18740 (handle_v_requests): Use require_running. Handle vAttach and vRun.
18741 (gdbserver_usage): Update.
18742 (main): Redo argument parsing. Handle --debug and --multi. Handle
18743 --attach along with other options or after the port. Save
18744 program_argv. Support no initial program. Resynchronize
18745 communication with GDB after an error. Handle "monitor exit".
18746 Use require_running and target_running. Always allow the extended
18747 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
18748 restart in extended mode.
18749 * README: Refer to the GDB manual. Update --attach usage.
18751 2007-12-20 Andreas Schwab <schwab@suse.de>
18753 * linux-low.c (STACK_SIZE): Define.
18754 (linux_tracefork_child): Use it. Use __clone2 on ia64.
18755 (linux_test_for_tracefork): Likewise.
18757 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
18759 * linux-low.c (linux_wait_for_event): Update messages. Do not
18760 reinsert auto-delete breakpoints.
18761 * mem-break.c (struct breakpoint): Change return type of handler to
18763 (set_breakpoint_at): Update handler type.
18764 (reinsert_breakpoint_handler): Return 1 instead of calling
18766 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
18768 (check_breakpoints): Delete auto-delete breakpoints and return 2.
18769 * mem-break.h (set_breakpoint_at): Update handler type.
18770 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
18771 * win32-low.c (auto_delete_breakpoint): New.
18772 (get_child_debug_event): Use it.
18774 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
18776 * configure.ac: Check for pread and pwrite.
18777 * hostio.c (handle_pread): Fall back to lseek and read.
18778 (handle_pwrite): Fall back to lseek and write.
18779 * config.in, configure: Regenerated.
18781 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
18783 * server.c (myresume): Add own_buf argument.
18784 (main): Update calls.
18786 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
18788 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
18789 * remote-utils.c (remote_open): Do not call disable_async_io.
18790 (block_async_io): Delete.
18791 (unblock_async_io): Make static.
18792 (initialize_async_io): New.
18793 * server.c (handle_v_cont): Handle async I/O here.
18794 (myresume): Likewise. Move other common resume tasks here...
18795 (main): ... from here. Call initialize_async_io. Disable async
18796 I/O before the main loop.
18797 * server.h (initialize_async_io): Declare.
18798 (block_async_io, unblock_async_io): Delete prototypes.
18799 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
18801 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
18803 * remote-utils.c (readchar): Allow binary data in received messages.
18805 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
18807 * win32-low.c (attaching): New global.
18808 (win32_create_inferior): Clear the `attaching' global.
18809 (win32_attach): Set the `attaching' global.
18810 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
18811 attaching. Only set a breakpoint at the entry point if not
18814 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
18816 * server.c (main): Don't report dll events on the initial
18817 connection on attaches.
18819 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
18821 * server.c (main): Relax numerical bases supported for the pid of
18822 the --attach command line argument.
18824 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
18826 * win32-low.c (win32_attach): Call OpenProcess before
18827 DebugActiveProcess, not after. Add last error output to error
18830 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
18832 * win32-low.c (win32_get_thread_context)
18833 (win32_set_thread_context): New functions.
18834 (thread_rec): Use win32_get_thread_context.
18835 (continue_one_thread, win32_resume): Use win32_set_thread_context.
18836 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
18839 2007-12-03 Leo Zayas
18840 Pedro Alves <pedro_alves@portugalmail.pt>
18842 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
18844 (child_add_thread): Minor cleanup.
18845 (child_continue): Resume artificially suspended threads before
18846 calling ContinueDebugEvent.
18847 (suspend_one_thread): New.
18848 (fake_breakpoint_event): New.
18849 (get_child_debug_event): Change return type to int. Check here if
18850 gdb sent an interrupt request. If a soft interrupt was requested,
18851 fake a breakpoint event. Return 0 if there is no event to handle,
18853 (win32_wait): Don't check here if gdb sent an interrupt request.
18854 Ensure there is a valid event to handle.
18855 (win32_request_interrupt): Add soft interruption method as last
18858 2007-12-03 Leo Zayas
18859 Pedro Alves <pedro_alves@portugalmail.pt>
18861 * win32-low.h (win32_thread_info): Add descriptions to the
18862 structure members. Replace `suspend_count' counter by a
18864 * win32-low.c (thread_rec): Update condition of when to get the
18865 context from the inferior. Rely on ContextFlags being set if it
18866 has already been retrieved. Only suspend the inferior thread if
18867 we haven't already. Warn if that fails.
18868 (continue_one_thread): s/suspend_count/suspended/. Only call
18869 ResumeThread once. Warn if that fails.
18871 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
18873 * win32-low.c (win32_wait): Don't read from the inferior when it
18874 has already exited.
18876 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
18878 * Makefile.in (win32_low_h): New variable.
18879 (win32-low.o): Add dependency on $(win32_low_h).
18880 (win32-arm-low.o, win32-i386-low.o): New rules.
18882 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
18884 * hostio.c: Correct copyright year.
18886 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
18888 * Makefile.in (OBS): Add hostio.o.
18889 (hostio.o): New rule.
18890 * server.h (handle_vFile): Declare.
18891 * hostio.c: New file.
18892 * server.c (handle_v_requests): Take packet_len and new_packet_len
18893 for binary packets. Call handle_vFile.
18894 (main): Update call to handle_v_requests.
18896 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
18898 * linux-low.c: Include <sched.h>.
18900 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
18902 * linux-low.c (linux_tracefork_grandchild): New.
18903 (linux_tracefork_child): Use clone.
18904 (linux_test_for_tracefork): Use clone; allocate and free a stack.
18906 2007-10-31 Joel Brobecker <brobecker@adacore.com>
18908 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
18910 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
18912 * linux-low.c (handle_extended_wait): Handle unexpected signals.
18914 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
18916 * inferiors.c (change_inferior_id): Delete.
18917 (add_pid_to_list, pull_pid_from_list): New.
18918 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
18919 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
18920 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
18921 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
18922 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
18923 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
18924 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
18925 (using_threads): Always set to 1.
18926 (handle_extended_wait): New.
18927 (add_process): Do not set TID.
18928 (linux_create_inferior): Set must_set_ptrace_flags.
18929 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
18930 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
18931 (linux_thread_alive): Rename TID argument to LWPID.
18932 (linux_wait_for_process): Handle unknown processes. Do not use TID.
18933 (linux_wait_for_event): Do not use TID or check using_threads. Update
18934 call to dead_thread_notify. Call handle_extended_wait.
18935 (linux_create_inferior): Use PTRACE_SETOPTIONS.
18936 (send_sigstop): Delete sigstop_sent.
18937 (wait_for_sigstop): Avoid TID.
18938 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
18939 (linux_test_for_tracefork): New.
18940 (linux_lookup_signals): Use thread_db_active and
18941 linux_supports_tracefork_flag.
18942 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
18943 * linux-low.h (get_process_thread): Avoid TID.
18944 (struct process_ifo): Move thread_known and tid to the end. Remove
18946 (linux_attach_lwp, thread_db_init): Update prototypes.
18947 * server.h (change_inferior_id): Delete prototype.
18948 (add_pid_to_list, pull_pid_from_list): New prototypes.
18949 * thread-db.c (thread_db_use_events): New.
18950 (find_first_thread): Rename to...
18951 (find_one_thread): ...this. Update callers and messages. Do not
18952 call fatal. Check thread_db_use_events. Do not call
18953 change_inferior_id or new_thread_notify.
18954 (maybe_attach_thread): Update. Do not call new_thread_notify.
18955 (thread_db_init): Set thread_db_use_events. Check use_events.
18956 * utils.c (fatal, warning): Correct message prefix.
18958 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
18960 * Makefile.in (clean): Remove new files.
18961 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
18962 (powerpc-64.o, powerpc-64.c): New rules.
18963 * configure.srv: Use alternate register sets for powerpc64-*-linux*
18964 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
18966 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
18968 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
18969 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
18970 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
18971 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
18972 (target_regsets): Add AltiVec and SPE register sets.
18973 * configure.ac: Check for AltiVec and SPE.
18974 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
18975 (ppc_fill_vrregset, ppc_store_vrregset): New.
18976 (target_regsets): Add AltiVec register set.
18977 * configure: Regenerated.
18979 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
18981 * linux-low.c (O_LARGEFILE): Define.
18982 (linux_read_memory): Use /proc/PID/mem.
18983 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
18984 * configure, config.in: Regenerated.
18986 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
18988 * linux-low.c (linux_wait_for_event): Do not pass signals while
18991 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
18993 * win32-low.c (create_process): New.
18994 (win32_create_inferior): Use create_process instead of
18995 CreateProcess. If create_process failed retry appending an ".exe"
18996 suffix. Store the GetLastError result immediatelly after
18997 create_process calls and use it on the call to error.
18999 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
19001 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
19003 2007-08-23 Joel Brobecker <brobecker@adacore.com>
19005 * configure.ac: Switch license to GPLv3.
19007 2007-08-01 Michael Snyder <msnyder@access-company.com>
19009 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
19011 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
19013 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
19015 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
19016 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
19017 CloseToolhelp32Snapshot.
19018 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
19019 CloseToolhelp32Snapshot.
19021 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
19023 * server.c (main): Check for inferior exit before main loop.
19025 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
19027 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
19028 instead of on tmp_desc.
19030 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
19031 Daniel Jacobowitz <dan@codesourcery.com>
19033 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
19034 (add_thread): Minor cleanups.
19035 (clear_inferiors): Move lower in the file. Clear the DLL
19037 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
19038 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
19039 (xml_escape_text): New.
19040 * server.c (handle_query): Handle qXfer:libraries:read. Report it
19042 (handle_v_cont): Report errors.
19043 (gdbserver_version): Update.
19044 (main): Correct size of own_buf. Do not report initial DLL events.
19045 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
19046 (unloaded_dll, xml_escape_text): New.
19047 * win32-low.c (enum target_waitkind): Update comments.
19048 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
19049 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
19050 (win32_EnumProcessModules, win32_GetModuleInformation)
19051 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
19052 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
19053 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
19054 (win32_Module32First, win32_Module32Next, load_toolhelp)
19055 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
19056 (get_child_debug_event): Handle DLL events.
19057 (win32_wait): Likewise.
19059 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
19061 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
19062 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
19064 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
19066 * win32-low.c (handle_output_debug_string): Ignore event if not
19069 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
19071 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
19073 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
19075 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
19077 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
19079 * inferiors.c (change_inferior_id): Add comment.
19080 * linux-low.c (check_removed_breakpoint): Add an early
19081 prototype. Improve debug output.
19082 (linux_attach): Doc update.
19083 (linux_detach_one_process, linux_detach): Clean up before releasing
19085 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
19086 * linux-low.h (struct process_info): Doc improvement.
19087 * mem-break.c (delete_all_breakpoints): New.
19088 * mem-break.h (delete_all_breakpoints): New prototype.
19089 * thread-db.c (find_first_thread): New.
19090 (thread_db_create_event): Call it instead of
19091 thread_db_find_new_threads. Clean up unused variables.
19092 (maybe_attach_thread): Remove first thread handling.
19093 (thread_db_find_new_threads): Use find_first_thread.
19094 (thread_db_get_tls_address): Likewise.
19096 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
19098 * thread-db.c (thread_db_find_new_threads): Add prototype.
19099 (thread_db_create_event): Check for the main thread before adding
19101 (maybe_attach_thread): Only enable event reporting if TID == 0.
19102 (thread_db_get_tls_address): Check for new threads.
19104 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
19106 * linux-low.c (linux_create_inferior): Try execv before execvp.
19107 * spu-low.c (spu_create_inferior): Likewise.
19109 2007-06-13 Mike Frysinger <vapier@gentoo.org>
19111 * linux-low.c (linux_create_inferior): Change execv to execvp.
19112 * spu-low.c (spu_create_inferior): Likewies.
19114 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
19116 * Makefile.in (clean): Clean new files instead of deleted ones.
19117 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
19118 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
19120 * configure.srv: Specify XML files and new regformats for MIPS and
19122 * linux-mips-low.c (mips_num_regs): Set to only used registers.
19123 (mips_regmap): Do not fetch $0. Remove unused registers. Add
19124 an entry for the restart register.
19125 (mips_cannot_fetch_register, mips_cannot_store_register)
19126 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
19127 register names to match the XML descriptions.
19128 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
19129 restart register instead of $0.
19131 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
19132 Markus Deuling <deuling@de.ibm.com>
19134 * remote-utils.c (decode_xfer_write): New function.
19135 * server.h (decode_xfer_write): Add prototype.
19136 * server.c (handle_query): Add PACKET_LEN argument. Support
19137 qXfer:spu:read and qXfer:spu:write packets.
19138 (main): Pass packet_len to handle_query.
19139 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
19140 * target.h (target_ops): Add qxfer_spu.
19142 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
19144 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
19145 accessing non-seekable spufs files.
19147 2007-05-16 Markus Deuling <deuling@de.ibm.com>
19149 * server.c (handle_query): Add reply for qC packet.
19151 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
19152 Leo Zayas <lerele@champenstudios@com>
19154 * server.h (check_remote_input_interrupt_request): New function.
19155 * remote_utils.c (INVALID_DESCRIPTOR): New define.
19156 (remote_desc): Initialize with INVALID_DESCRIPTOR.
19157 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
19158 (check_remote_input_interrupt_request): New function.
19159 * server.h (check_remote_input_interrupt_request): Declare.
19160 * win32-low.c (winapi_DebugBreakProcess,
19161 winapi_GenerateConsoleCtrlEvent): New typedefs.
19162 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
19164 (win32_wait): Check for remote interrupt request
19165 with check_remote_input_interrupt_request.
19166 (win32_request_interrupt): New function.
19167 (win32_target_op): Set request_interrupt to win32_request_interrupt.
19169 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
19171 * win32-low.c (debug_registers_changed,
19172 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
19173 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
19174 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
19175 (thread_rec): Get context using the low target.
19176 (child_add_thread): Call thread_added on the low target,
19177 which does the same thing.
19179 (do_initial_child_stuff): Remove debug registers references.
19180 Set context using the low target. Resume threads after
19181 setting the contexts.
19182 (child_continue): Remove dead variable. Remove debug
19183 registers references.
19184 (child_fetch_inferior_registers): Go through the low target.
19185 (do_child_store_inferior_registers): Remove.
19186 (child_store_inferior_registers): Go through the low target.
19187 (win32_resume): Remove debug registers references.
19188 Set context using the low target.
19189 (handle_exception): Change return type to void. Don't record
19190 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
19191 first chance exception.
19192 (get_child_debug_event): Change return type to void. Remove
19193 goto loop. Always return after waiting for debug event.
19194 (win32_wait): Convert to switch statement. Handle spurious
19197 * win32-i386-low.c (debug_registers_changed,
19198 debug_registers_used): New.
19199 (initial_stuff): Rename to ...
19200 (i386_initial_stuff): ... this. Clear debug registers
19202 (store_debug_registers): Delete.
19203 (i386_get_thread_context): New.
19204 (load_debug_registers): Delete.
19205 (i386_set_thread_context): New.
19206 (i386_thread_added): New.
19207 (single_step): Rename to ...
19208 (i386_single_step): ... this.
19209 (do_fetch_inferior_registers): Rename to ...
19210 (i386_fetch_inferior_register): ... this.
19211 (i386_store_inferior_register): New.
19212 (the_low_target): Adapt to new interface.
19214 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
19215 (arm_get_thread_context): New.
19216 (arm_set_thread_context): New.
19218 (do_fetch_inferior_registers): Rename to ...
19219 (arm_fetch_inferior_register): ... this.
19220 (arm_store_inferior_register): New.
19221 (arm_wince_breakpoint): Reimplement as unsigned long.
19222 (arm_wince_breakpoint_len): Define.
19223 (the_low_target): Adapt to new interface.
19225 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
19226 load_debug_registers. Add get_thread_context, set_thread_context,
19227 thread_added and store_inferior_register. Rename
19228 fetch_inferior_registers to fetch_inferior_register.
19229 (regptr): Remove declaration.
19231 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
19233 * linux-low.c (linux_detach): Change return type to int. Return 0.
19234 * spu-low.c (spu_detach): Likewise.
19236 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
19238 * target.h (target_ops): Change return type of detach to int.
19240 (join_inferior): New.
19241 * server.c (main): Don't skip detach support on mingw32.
19242 If the inferior doesn't support detaching return error.
19243 Call join_inferior instead of using waitpid.
19244 * linux-low.c (linux_join): New.
19245 (linux_target_op): Add linux_join.
19246 * spu-low.c (spu_join): New.
19247 (spu_target_ops): Add spu_join.
19248 * win32-low.c (win32_detach): Adapt to new interface.
19249 Reopen current_process_handle before detaching. Issue a child
19250 resume before detaching.
19252 (win32_target_op): Add win32_join.
19254 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
19256 * win32-low.c (win32-attach): Fix return value.
19257 * target.h (target_ops): Describe ATTACH return values.
19259 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
19261 * win32-low.c (GETPROCADDRESS): Define.
19262 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
19263 (winapi_DebugSetProcessKillOnExit): Likewise.
19264 (win32_create_inferior): Force usage of ansi CreateProcessA.
19265 (win32_attach): Use GETPROCADDRESS.
19266 (win32_detach): Likewise.
19268 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
19270 * win32-low.c (win32_wait): Don't use WSTOPSIG.
19272 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
19274 * win32-low.c: Commit leftover changes from 2007-03-29.
19276 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
19278 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
19279 fields short instead of int. Add explicit padding.
19280 (i387_cache_to_fsave): Remove unnecessary casts.
19281 (i387_fsave_to_cache): Doc fix.
19282 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
19284 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
19286 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
19287 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
19289 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
19291 * configure.srv (arm*-*-mingw32ce*): Move near the other
19294 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
19296 * configure.ac: Add errno checking.
19297 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
19298 sys/file.h and malloc.h.
19299 (AC_CHECK_DECLS): Add perror.
19300 (srv_mingwce): Handle.
19301 * configure.srv (i[34567]86-*-cygwin*): Add
19302 win32-i386-low.o to srv_tgtobj.
19303 (i[34567]86-*-mingw*): Likewise.
19304 (arm*-*-mingw32ce*): Add case.
19305 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
19306 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
19307 [__MINGW32CE__] (strerror): New function.
19308 [__MINGW32CE__] (errno): Define to GetLastError.
19309 [__MINGW32CE__] (COUNTOF): New macro.
19310 (remote_open): Remove extra close call.
19311 * mem-break.c (delete_breakpoint_at): New function.
19312 * mem-break.h (delete_breakpoint_at): Declare.
19313 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
19314 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
19315 [USE_WIN32API] (read, write): Add char* casts.
19316 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
19317 * server.h: Include wincecompat.h on Windows CE.
19318 [HAVE_ERRNO_H]: Check.
19319 (perror): Declare if not declared.
19320 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
19321 (perror_with_name): Remove errno declaration.
19322 * wincecompat.h: New.
19323 * wincecompat.c: New.
19324 * win32-low.h: New.
19325 * win32-arm-low.c: New.
19326 * win32-i386-low.c: New.
19327 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
19328 (OUTMSG2): Make it safe.
19330 (COUNTOF): New macro.
19331 (NUM_REGS): Get it from the low target.
19332 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
19333 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
19334 (thread_rec): Let low target handle debug registers.
19335 (child_add_thread): Likewise.
19336 (child_init_thread_list): Likewise.
19337 (continue_one_thread): Likewise.
19339 (do_child_fetch_inferior_registers): Move to ...
19340 * win32-i386-low.c: ... here, and rename to ...
19341 (do_fetch_inferior_registers): ... this.
19342 * win32-low.c (child_fetch_inferior_registers):
19343 Go through the low target.
19344 (do_child_store_inferior_registers): Use regptr.
19345 (strwinerror): New function.
19346 (win32_create_inferior): Handle Windows CE.
19347 Use strwinerror instead of strerror on Windows error
19348 codes. Add program to the error output.
19349 Don't close the main thread handle on Windows CE.
19350 (win32_attach): Use coredll.dll on Windows CE.
19351 (win32_kill): Close current process and current
19353 (win32_detach): Use coredll.dll on Windows CE.
19354 (win32_resume): Let low target handle debug registers, and
19356 (handle_exception): Add/Remove initial breakpoint. Avoid
19357 non-existant WSTOPSIG on Windows CE.
19358 (win32_read_inferior_memory): Cast to remove warning.
19359 (win32_arch_string): Go through the low target.
19360 (initialize_low): Call set_breakpoint_data with the low
19361 target's breakpoint.
19362 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
19363 FOP_REGNUM, mappings): Move to ...
19364 * win32-i386-low.c: ... here.
19365 * win32-low.c (win32_thread_info): Move to ...
19366 * win32-low.h: ... here.
19367 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
19368 win32-arm-low.c and wincecompat.c.
19369 (all:): Add $EXEEXT.
19370 (install-only:): Likewise.
19371 (gdbserver:): Likewise.
19372 (gdbreplay:): Likewise.
19373 * config.in: Regenerate.
19374 * configure: Regenerate.
19376 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
19378 * win32-low.c: Rename typedef thread_info to
19379 win32_thread_info throughout.
19381 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
19383 * win32-i386-low.c: Rename to ...
19384 * win32-low.c: ... this.
19385 * configure.srv: Replace win32-i386-low.o with win32-low.o.
19386 * Makefile.in: Likewise.
19388 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
19390 * remote-utils.c (monitor_output): Constify msg parameter.
19391 * server.h (monitor_output): Likewise.
19392 * win32-i386-low.c (handle_output_debug_string): New.
19393 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
19394 handle_output_debug_string.
19395 (get_child_debug_event): Likewise.
19397 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
19399 * server.c (main): Correct strtoul check.
19401 2007-03-27 Jon Ringle <jon@ringle.org>
19403 * linux-low.c: Check __ARCH_HAS_MMU__ also.
19405 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
19407 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
19409 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
19411 * terminal.h: Check HAVE_SGTTY_H.
19413 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
19415 * remote-utils.c (remote_open): Print out the assigned port number.
19417 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
19419 * remote-utils.c (monitor_output): New function.
19420 * server.c (debug_threads): Define here.
19421 (monitor_show_help): New function.
19422 (handle_query): Handle qRcmd.
19423 (main): Do not handle 'd' packet.
19424 * server.h (debug_threads, remote_debug, monitor_output): Declare.
19425 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
19428 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
19430 * Makefile.in (EXEEXT): New.
19431 (clean): Use $(EXEEXT).
19433 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
19435 * target.h (target_ops): Rename send_signal to request_interrupt,
19436 and remove enum target_signal parameter.
19437 * linux-low.c (linux_request_interrupt): Rename from
19438 linux_send_signal, and always send SIGINT.
19439 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
19440 and always send SIGINT.
19441 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
19443 (input_interrupt): Likewise.
19445 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
19447 * server.c (get_features_xml): Check if target implemented
19449 * win32-i386-low.c (win32_arch_string): New.
19450 (win32_target_ops): Add win32_arch_string as arch_string member.
19452 2007-02-22 Markus Deuling <deuling@de.ibm.com>
19454 * spu-low.c (spu_arch_string): New.
19455 (spu_target_ops): Add spu_arch_string.
19457 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
19459 * remote-utils.c: Remove HAVE_TERMINAL_H check.
19460 * configure.ac: Do not check for terminal.h.
19461 * configure, config.in: Regenerated.
19463 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
19465 * Makefile.in (OBS): Add $(XML_BUILTIN).
19466 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
19468 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
19469 (arm-with-iwmmxt.c): New.
19470 * config.in, configure: Regenerate.
19471 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
19472 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
19473 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
19474 (arm*-*-linux*): Add iWMMXt and regset support.
19475 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
19476 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
19477 (arm_store_wmmxregset, target_regsets): New.
19478 * server.c (get_features_xml): Take annex argument. Check builtin
19480 (handle_query): Handle multiple annexes.
19482 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
19484 * remote-utils.c [USE_WIN32API] (read, write): Define.
19485 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
19488 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
19490 * linux-i386-low.c (the_low_target): Set arch_string.
19491 * linux-x86-64-low.c (the_low_target): Likewise.
19492 * linux-low.c (linux_arch_string): New.
19493 (linux_target_ops): Add it.
19494 * linux-low.h (struct linux_target_ops): Add arch_string.
19495 * server.c (write_qxfer_response): Use const void * for DATA.
19496 (get_features_xml): New.
19497 (handle_query): Handle qXfer:features:read. Report it for qSupported.
19498 * target.h (struct target_ops): Add arch_string method.
19500 2007-01-03 Denis Pilat <denis.pilat@st.com>
19501 Daniel Jacobowitz <dan@codesourcery.com>
19503 * linux-low.c (linux_kill): Handle being called with no threads.
19504 * win32-i386-low.c (win32_kill): Likewise.
19505 (get_child_debug_event): Clear current_process_handle.
19507 2006-12-30 Denis PILAT <denis.pilat@st.com>
19508 Daniel Jacobowitz <dan@codesourcery.com>
19510 * remote-utils.c (remote_open): Check the type of specified
19511 serial port devices before opening them.
19512 * server.c (main): Kill the inferior if an error occurs during
19513 the first remote_open.
19515 2006-12-05 Markus Deuling <deuling@de.ibm.com>
19517 * README: Update supported targets.
19519 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
19521 * Makefile.in (clean): Remove reg-mips64.c.
19522 (reg-mips64.c, reg-mips64.o): New rules.
19523 * configure.srv: Handle mips64. Include regset support for mips.
19524 * linux-mips-low.c (union mips_register): New.
19525 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
19526 (mips_breakpoint, mips_breakpoint_at): Use int.
19527 (mips_collect_register, mips_supply_register)
19528 (mips_collect_register_32bit, mips_supply_register_32bit)
19529 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
19530 (mips_store_fpregset, target_regsets): New.
19531 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
19533 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
19535 * configure.srv: Add target "spu*-*-*".
19536 * Makefile.in (clean): Remove reg-spu.c.
19537 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
19538 * spu-low.c: New file.
19540 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
19542 * configure.ac: Correct td_thr_tls_get_addr test.
19543 * configure: Regenerated.
19545 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
19547 * linux-low.c (linux_wait_for_event): Reformat. Use the
19548 pass_signals array.
19549 * remote-utils.c (decode_address_to_semicolon): New.
19550 * server.c (pass_signals, handle_general_set): New.
19551 (handle_query): Mention QPassSignals for qSupported.
19552 (main): Call handle_general_set.
19553 * server.h (pass_signals, decode_address_to_semicolon): New.
19555 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
19557 * server.c (handle_query): Correct error handling for read_auxv.
19559 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
19561 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
19562 and srv_linux_thread_db to yes.
19563 * linux-s390-low.c (s390_fill_gregset): New function.
19564 (target_regsets): Define data structure.
19566 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
19568 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
19569 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
19570 * config.in, configure: Regenerated.
19571 * inferiors.c (gdb_id_to_thread): New function.
19572 (gdb_id_to_thread_id): Use it.
19573 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
19574 * linux-low.h (struct process_info): Add th member.
19575 (thread_db_get_tls_address): New prototype.
19576 * remote-utils.c (decode_address): Make non-static.
19577 * server.c (handle_query): Handle qGetTLSAddr.
19578 * server.h (gdb_id_to_thread, decode_address): New prototypes.
19579 * target.h (struct target_ops): Add get_tls_address.
19580 * thread-db.c (maybe_attach_thread): Save the thread handle.
19581 (thread_db_get_tls_address): New.
19583 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
19585 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
19586 (linux_resume_one_process): Take a siginfo_t *. Update all
19587 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
19588 (struct pending_signals): Add a siginfo_t.
19589 (linux_wait_for_process): Always set last_status.
19590 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
19591 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
19592 * linux-low.h (struct process_info): Add last_status.
19594 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
19596 * remote-utils.c (try_rle): New function.
19597 (putpkt_binary): Use it.
19599 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
19601 * Makefile.in (clean): Clean reg-x86-64-linux.c.
19602 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
19603 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
19604 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
19605 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
19608 2006-08-08 Richard Sandiford <richard@codesourcery.com>
19610 * server.c (terminal_fd): New variable.
19611 (old_foreground_pgrp): Likewise.
19612 (restore_old_foreground_pgrp): New function.
19613 (start_inferior): Record the terminal file descriptor in terminal_fd
19614 and its original foreground group in old_foreground_pgrp. Register
19615 restore_old_foreground_pgrp with atexit().
19617 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
19619 * server.c (handle_query): Correct qPart to qXfer.
19621 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
19623 * configure.ac: Check for more headers which are missing on
19624 Windows. Automatically supply -lwsock32 and USE_WIN32API.
19625 * configure.srv: Add Cygwin and mingw32.
19626 * remote-utils.c: Don't include headers unconditionally which
19627 are missing on mingw32. Include <winsock.h> for mingw32.
19628 (remote_open): Adjust for mingw32 support. Flush
19629 standard error after writing to it.
19630 (remote_close, putpkt_binary, input_interrupt, block_async_io)
19631 (unblock_async_io, enable_async_io, disable_async_io)
19632 (readchar, getpkt): Update for Winsock support.
19633 (prepare_resume_reply): Expect a protocol signal number.
19634 * server.c: Disable <sys/wait.h> on mingw32.
19635 (start_inferior): Adjust for mingw32 support. Flush
19636 standard error after writing to it.
19637 (attach_inferior): Likewise. Use protocol signal
19639 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
19641 * win32-i386-low.c: New file.
19642 * Makefile.in (XM_CLIBS): Set.
19643 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
19644 (win32-i386-low.o): New dependency rule.
19645 * linux-low.c (linux_wait): Use target signal numbers.
19646 * target.h (struct target_ops): Doc fix.
19647 * server.h (target_signal_to_name): New prototype.
19648 * gdbreplay.c: Don't include headers unconditionally which
19649 are missing on mingw32. Include <winsock.h> for mingw32.
19650 (remote_close, remote_open): Adjust for Winsock support.
19651 * configure, config.in: Regenerated.
19653 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
19655 * server.c (decode_xfer_read, write_qxfer_response): New.
19656 (handle_query): Take a packet length argument. Handle
19657 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
19658 the qSupported response.
19659 (main): Update call to handle_query.
19661 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
19663 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
19664 (putpkt_binary): Renamed from putpkt and adjusted for binary
19666 (putpkt): New wrapper for putpkt_binary.
19667 (readchar): Don't mask off the high bit.
19668 (decode_X_packet): New function.
19669 * server.c (main): Call putpkt_binary if a handler sets the packet
19670 length. Save the length of the incoming packet. Handle 'X'.
19671 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
19673 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
19675 * server.c (handle_query): Handle qSupported.
19677 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
19679 * remote-utils.c (all_symbols_looked_up): New variable.
19680 (look_up_one_symbol): Check it.
19681 * server.h (look_up_one_symbol): New declaration.
19682 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
19684 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
19686 * Makefile.in (linux-arm-low.o): Update dependencies.
19687 * linux-arm-low.c: Include "gdb_proc_service.h".
19688 (PTRACE_GET_THREAD_AREA): Define.
19689 (ps_get_thread_area): New function.
19691 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
19693 * configure.srv (m68k*-*-uclinux*): New target.
19694 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
19695 (linux_resume_one_process): Remove extraneous cast.
19696 (linux_read_offsets): New.
19697 (linux_target_op): Add linux_read_offsets on mmuless systems.
19698 * server.c (handle_query): Add qOffsets logic.
19699 * target.h (struct target_ops): Add read_offsets.
19701 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
19703 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
19704 (PTRACE_GET_THREAD_AREA): Define.
19705 (ps_get_thread_area): New function.
19706 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
19707 (linux-x86-64-low.o): Update.
19709 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
19711 * configure.ac: Remove checks for prfpregset_t.
19712 * gdb_proc_service.h: New file.
19713 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
19714 new "gdb_proc_service.h".
19715 * proc-service.c: Likewise.
19716 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
19717 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
19718 * Makefile.in (gdb_proc_service_h): Updated.
19719 * configure, config.in: Regenerated.
19721 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
19723 * remote-utils.c (prepare_resume_reply): Move declaration
19724 of gdb_id_from_wait to the top of the block.
19726 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
19728 * linux-low.c (regsets_store_inferior_registers): Read the regset
19729 from the target before filling it.
19731 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
19733 * server.c (attach_inferior): Return SIGTRAP for a successful
19736 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
19738 * Makefile.in (OBS): Add version.o.
19739 (STAGESTUFF): Delete.
19740 (version.o): Add dependencies.
19741 (version.c): Replace rule.
19742 (clean): Remove version.c.
19743 * server.c (gdbserver_version): New.
19744 (gdbserver_usage): Use printf.
19745 (main): Handle --version and --help.
19746 * server.h (version, host_name): Add declarations.
19748 2005-12-23 Eli Zaretskii <eliz@gnu.org>
19760 * linux-x86-64-low.c:
19762 * linux-s390-low.c:
19763 * linux-ppc64-low.c:
19765 * linux-mips-low.c:
19766 * linux-m68k-low.c:
19767 * linux-m32r-low.c:
19770 * linux-ia64-low.c:
19771 * linux-i386-low.c:
19772 * linux-crisv32-low.c:
19784 * gdbserver.1: Add (C) after Copyright. Update the FSF
19787 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
19789 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
19790 (arm_breakpoint_at): Recognize both breakpoints.
19791 (the_low_target): Use the correct breakpoint instruction.
19793 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
19795 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
19796 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
19797 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
19798 (the_low_target): Update.
19800 2005-10-25 Andreas Schwab <schwab@suse.de>
19802 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
19804 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
19805 (ia64_num_regs): Reduce to 462.
19807 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
19809 * acinclude.m4: Correct quoting.
19810 * aclocal.m4: Regenerated.
19812 Suggested by SZOKOVACS Robert <szo@ies.hu>:
19813 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
19814 (thread_db_init): Call thread_db_err_str.
19815 * configure.ac: Check for TD_VERSION.
19816 * config.in, configure: Regenerated.
19818 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
19820 * server.h (error, fatal, warning): Add ATTR_FORMAT.
19822 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
19824 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
19825 is not available. Define HAVE_PTRACE_GETREGS if it is.
19826 * config.in, configure: Regenerated.
19827 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
19828 * linux-i386-low.c, linux-m68k-low.c: Update to use
19829 HAVE_PTRACE_GETREGS.
19830 * linux-low.c (regsets_fetch_inferior_registers)
19831 (regsets_store_inferior_registers): Only return 0 if we processed
19833 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
19834 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
19836 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
19838 * inferiors.c (struct thread_info): Add gdb_id.
19839 (add_thread): Add gdb_id argument.
19840 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
19841 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
19842 calls to add_thread.
19843 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
19844 * server.c (handle_query): Use thread_to_gdb_id.
19845 (handle_v_cont, main): Use gdb_id_to_thread_id.
19846 * server.h (add_thread): Update prototype.
19847 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
19850 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
19852 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
19853 left-padded registers.
19854 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
19855 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
19857 2005-07-01 Steve Ellcey <sje@cup.hp.com>
19859 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
19860 * configure: Regenerate.
19861 * config.in: Regenerate.
19862 * server.h (NEED_DECLARATION_STRERROR):
19863 Replace with !HAVE_DECL_STRERROR.
19865 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
19867 * linux-low.c (linux_wait, linux_send_signal): Don't test
19868 an unsigned long variable for > 0 if it could be MAX_ULONG.
19869 * server.c (myresume): Likewise.
19870 * target.c (set_desired_inferior): Likewise.
19872 2005-06-13 Mark Kettenis <kettenis@gnu.org>
19874 * configure.ac: Simplify and improve check for socklen_t.
19875 * configure, config.in: Regenerate.
19877 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
19879 * acconfig.h: Remove.
19880 * configure.ac: Add a test for socklen_t. Use three-argument
19881 AC_DEFINE throughout.
19882 * config.in: Regenerated using autoheader 2.59.
19883 * configure: Regenerated.
19885 * gdbreplay.c (socklen_t): Provide a default.
19886 (remote_open): Use socklen_t.
19887 * remote-utils.c (socklen_t): Provide a default.
19888 (remote_open): Use socklen_t.
19889 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
19892 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
19894 * linux-low.c (linux_read_memory, linux_write_memory)
19895 (linux_read_auxv): Likewise.
19896 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
19897 (check_mem_write): Likewise.
19898 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
19900 * regcache.c (struct inferior_rgcache_data, registers_to_string)
19901 (registers_from_string, register_data): Likewise.
19902 * server.c (handle_query, main): Likewise.
19903 * server.h (convert_ascii_to_int, convert_int_to_ascii)
19904 (decode_M_packet): Likewise.
19905 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
19906 * target.h (struct target_ops): Update read_memory, write_memory,
19908 (read_inferior_memory, write_inferior_memory): Update.
19909 * linux-low.h (struct linux_target_ops): Change type of breakpoint
19910 to unsigned char *.
19911 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
19912 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
19913 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
19914 linux-s390-low.c, linux-sh-low.c: Update for changes in
19915 read_inferior_memory and the_low_target->breakpoint.
19917 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
19919 * Makefile.in (SFILES): Add linux-ppc64-low.c.
19920 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
19921 * configure.srv: Add powerpc64-*-linux*.
19922 * linux-ppc64-low.c: New file.
19924 2005-05-23 Orjan Friberg <orjanf@axis.com>
19926 * linux-cris-low.c: New file with support for CRIS.
19927 * linux-crisv32-low.c: Ditto for CRISv32.
19928 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
19929 (clean): Add reg-cris.c and reg-crisv32.c.
19930 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
19931 reg-crisv32.o, and reg-crisv32.c to make rules.
19932 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
19933 recognized targets.
19935 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
19937 * linux-low.c (fetch_register): Ensure buffer size is a multiple
19938 of sizeof (PTRACE_XFER_TYPE).
19939 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
19941 2005-05-12 Orjan Friberg <orjanf@axis.com>
19943 * target.h (struct target_ops): Add insert_watchpoint,
19944 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
19945 pointers for hardware watchpoint support.
19946 * linux-low.h (struct linux_target_ops): Ditto.
19947 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
19948 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
19949 to linux_target_ops.
19950 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
19952 * server.c (main): Recognize 'Z' and 'z' packets.
19954 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
19956 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
19957 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
19958 (the_low_target): Add new members.
19960 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
19962 * proc-service.c (ps_lgetregs): Search all_processes instead of
19965 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
19967 * server.c (start_inferior): Change return type to int.
19968 (attach_inferior): Change sigptr to int *.
19969 (handle_v_cont, handle_v_requests): Change signal to int *.
19970 (main): Change signal to int.
19972 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
19974 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
19975 * configure.srv: Add m32r*-*-linux*.
19976 * linux-m32r-low.c: New file.
19978 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
19980 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
19982 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
19984 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
19985 Take unsigned long arguments for PIDs.
19986 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
19987 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
19988 (wait_for_sigstop, linux_resume_one_process)
19989 (regsets_fetch_inferior_registers, linux_send_signal)
19990 (linux_read_auxv): Likewise. Update the types of variables holding
19991 PIDs. Update format string specifiers.
19992 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
19993 * remote-utils.c (prepare_resume_reply): Likewise.
19994 * server.c (cont_thread, general_thread, step_thread)
19995 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
19997 (handle_query): Update format specifiers.
19998 (handle_v_cont, main): Use strtoul for thread IDs.
19999 * server.h (struct inferior_list_entry): Use unsigned long for ID.
20000 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
20001 (general_thread, step_thread, thread_from_wait)
20002 (old_thread_from_wait): Update.
20003 * target.h (struct thread_resume): Use unsigned long for THREAD.
20004 (struct target_ops): Use unsigned long for arguments to attach and
20007 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
20009 * acinclude.m4: Include bfd/bfd.m4 directly.
20010 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
20011 <agriffis@toolchain.org>.
20012 * aclocal.m4, configure: Regenerated.
20014 2005-01-07 Andrew Cagney <cagney@gnu.org>
20016 * configure.ac: Rename configure.in, require autoconf 2.59.
20017 * configure: Re-generate.
20019 2004-12-08 Daniel Jacobowitz <dan@debian.org>
20021 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
20022 LIBS when finished.
20023 * aclocal.m4: Regenerated.
20024 * configure: Regenerated.
20026 2004-11-21 Andreas Schwab <schwab@suse.de>
20028 * linux-m68k-low.c (m68k_num_gregs): Define.
20029 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
20030 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
20031 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
20032 (m68k_breakpoint_at): New. Add to the_low_target.
20034 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
20035 srv_linux_thread_db to yes.
20037 2004-10-20 Joel Brobecker <brobecker@gnat.com>
20039 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
20040 (ARCH_SET_FS): Likewise.
20041 (ARCH_GET_FS): Likewise.
20042 (ARCH_GET_GS): Likewise.
20044 2004-10-16 Daniel Jacobowitz <dan@debian.org>
20046 * linux-i386-low.c (ps_get_thread_area): New.
20047 * linux-x86-64-low.c (ps_get_thread_area): New.
20048 * linux-low.c: Include <sys/syscall.h>.
20049 (linux_kill_one_process): Don't kill the first thread here.
20050 (linux_kill): Kill the first thread here.
20051 (kill_lwp): New function.
20052 (send_sigstop, linux_send_signal): Use it.
20053 * proc-service.c: Clean up #ifdefs.
20054 (fpregset_info): Delete.
20055 (ps_lgetregs): Update and enable implementation.
20056 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
20058 * remote-utils.c (struct sym_cache, symbol_cache): New.
20059 (input_interrupt): Print a clearer message.
20060 (async_io_enabled): New variable.
20061 (enable_async_io, disable_async_io): Use it. Update comments.
20062 (look_up_one_symbol): Use the symbol cache.
20063 * thread-db.c (thread_db_look_up_symbols): New function.
20064 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
20066 2004-10-16 Daniel Jacobowitz <dan@debian.org>
20068 * configure.in: Test for -rdynamic.
20069 * configure: Regenerated.
20070 * Makefile (INTERNAL_LDFLAGS): New.
20071 (gdbserver, gdbreplay): Use it.
20073 2004-09-02 Andrew Cagney <cagney@gnu.org>
20075 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
20077 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
20079 * linux-low.c (linux_wait): Clear all_processes list also.
20081 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
20083 * linux-low.c: Include <errno.h>. Remove extern declaration of
20086 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
20088 * gdbreplay.c, server.h, utils.c: Update copyright years.
20090 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
20092 * server.c (main): Print child status or termination signal from
20093 variable 'signal', not 'sig'.
20095 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
20097 * linux-low.c (linux_read_memory): Change return type to
20098 int. Check for and return error from ptrace().
20099 * target.c (read_inferior_memory): Change return type to int. Pass
20100 back return status from the_target->read_memory().
20101 * target.h (struct target_ops): Adapt *read_memory() prototype.
20103 (read_inferior_memory): Adapt prototype.
20104 * server.c (main): Return an error packet if
20105 read_inferior_memory() returns an error.
20107 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
20109 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
20110 Unify with other clean targets.
20112 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
20114 * server.c (handle_v_cont): Call set_desired_inferior.
20116 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
20118 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
20120 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
20122 * linux-low.c (linux_wait): Unblock async I/O.
20123 (linux_resume): Block and enable async I/O.
20124 * remote-utils.c (block_async_io, unblock_async_io): New functions.
20125 * server.h (block_async_io, unblock_async_io): Add prototypes.
20127 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
20129 * remote-utils.c (remote_open): Print a status notice after
20130 opening a TCP port.
20131 * server.c (attach_inferior): Print a status notice after
20134 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
20136 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
20138 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
20140 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
20142 * server.c, target.h: Update copyright years.
20144 2004-02-25 Roland McGrath <roland@redhat.com>
20146 * target.h (struct target_ops): New member `read_auxv'.
20147 * server.c (handle_query): Handle qPart:auxv:read: query using that.
20148 * linux-low.c (linux_read_auxv): New function.
20149 (linux_target_ops): Initialize `read_auxv' member to that.
20151 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
20153 Committed by Jim Blandy <jimb@redhat.com>.
20155 * linux-s390-low.c (s390_num_regs): Update.
20156 (s390_regmap): Remove control registers. Use __s390x__ predefine
20157 instead of GPR_SIZE to distiguish s390 and s390x targets.
20159 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
20161 * linux-low.c: Update copyright year.
20162 (check_removed_breakpoint): Clear pending_is_breakpoint.
20163 (linux_set_resume_request, linux_queue_one_thread)
20164 (resume_status_pending_p): New functions.
20165 (linux_continue_one_thread): Use process->resume.
20166 (linux_resume): Only resume threads if there are no pending events.
20167 * linux-low.h (struct process_info): Add resume request
20170 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
20172 * regcache.c (new_register_cache): Clear the allocated register
20173 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
20175 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
20177 * linux-low.c (linux_resume): Take a struct thread_resume *
20179 (linux_wait): Update call.
20180 (resume_ptr): New static variable.
20181 (linux_continue_one_thread): Renamed from
20182 linux_continue_one_process. Use resume_ptr.
20183 (linux_resume): Use linux_continue_one_thread.
20184 * server.c (handle_v_cont, handle_v_requests): New functions.
20185 (myresume): New function.
20186 (main): Handle 'v' case.
20187 * target.h (struct thread_resume): New type.
20188 (struct target_ops): Change argument of "resume" to struct
20190 (myresume): Delete macro.
20192 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
20194 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
20195 (uninstall): Support DESTDIR.
20197 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
20199 * configure.srv: Add xscale*linux copy of arm*linux entry.
20201 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
20203 * linux-arm-low.c (arm_reinsert_addr): New function.
20204 (the_low_target): Add arm_reinsert_addr.
20206 2003-07-08 Mark Kettenis <kettenis@gnu.org>
20208 * mem-break.c: Remove whitespace at end of file.
20210 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
20212 * configure.in: Check whether we need to prototype strerror.
20213 * server.h: Optionally prototype strerror.
20214 * gdbreplay.c (perror_with_name): Use strerror.
20215 * linux-low.c (linux_attach_lwp): Use strerror.
20216 * utils.c (perror_with_name): Use strerror.
20217 * config.in, configure: Regenerated.
20219 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
20221 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
20222 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
20224 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
20226 * Makefile.in (SFILES): Update.
20227 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
20228 low-sun3.c: Remove files.
20230 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
20232 * linux-low.c: Move comment to linux_thread_alive where it belonged.
20233 (linux_detach_one_process, linux_detach): New functions.
20234 (linux_target_ops): Add linux_detach.
20235 * server.c (main): Handle 'D' packet.
20236 * target.h (struct target_ops): Add "detach" member.
20237 (detach_inferior): Define.
20239 2003-06-13 Mark Kettenis <kettenis@gnu.org>
20241 From Kelley Cook <kelleycook@wideopenwest.com>:
20242 * configure.srv: Accept i[34567]86 variants.
20244 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
20246 * linux-low.c (linux_wait_for_event): Correct comment typos.
20247 (linux_resume_one_process): Call check_removed_breakpoint.
20248 (linux_send_signal): New function.
20249 (linux_target_ops): Add linux_send_signal.
20250 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
20252 * target.h (struct target_ops): Add send_signal.
20254 2003-05-29 Jim Blandy <jimb@redhat.com>
20256 * linux-low.c (usr_store_inferior_registers): Transfer buf in
20257 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
20258 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
20259 away part of the register's value.
20261 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
20263 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
20264 (linux_wait_for_event, linux_init_signals): Likewise.
20266 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
20268 * configure.in: Check for stdlib.h.
20269 * configure: Regenerated.
20270 * config.in: Regenerated.
20272 2003-01-04 Andreas Schwab <schwab@suse.de>
20274 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
20276 2003-01-02 Andrew Cagney <ac131313@redhat.com>
20278 * Makefile.in: Remove obsolete code.
20280 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
20282 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
20283 defined(PT_FPR0_HI).
20285 2002-11-17 Stuart Hughes <seh@zee2.com>
20287 * linux-arm-low.c (arm_num_regs): Increase.
20288 (arm_regmap): Include status register.
20290 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
20292 * linux-low.c (register_addr): Remove incorrect -1 check.
20294 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
20296 * linux-low.c (linux_create_inferior): Call setpgid. Return
20298 (unstopped_p, linux_signal_pid): Remove.
20299 (linux_target_ops): Remove linux_signal_pid.
20300 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
20301 global instead of target method.
20302 * target.h (struct target_ops): Remove signal_pid. Update comment
20303 for create_inferior.
20304 * server.c (signal_pid): New variable.
20305 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
20306 gdbserver. Set the child to be the foreground process group.
20307 (attach_inferior): Set signal_pid.
20309 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
20311 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
20313 2002-08-20 Jim Blandy <jimb@redhat.com>
20315 * Makefile.in (LDFLAGS): Allow the configure script to establish a
20318 2002-08-01 Andrew Cagney <cagney@redhat.com>
20320 * Makefile.in: Make chill references obsolete.
20322 2002-07-24 Kevin Buettner <kevinb@redhat.com>
20324 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
20325 * configure: Regenerate.
20326 * config.in: Regenerate.
20328 2002-07-09 David O'Brien <obrien@FreeBSD.org>
20330 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
20331 (perror_with_name, remote_close, remote_open, expect, play): Static.
20333 2002-07-04 Michal Ludvig <mludvig@suse.cz>
20335 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
20336 byte offsets instead of an array of indexes.
20337 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
20339 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
20341 * regcache.c: Add comment.
20343 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
20345 * thread-db.c: New file.
20346 * proc-service.c: New file.
20347 * acinclude.m4: New file.
20348 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
20349 proc-service.o, and thread-db.o.
20350 (linux-low.o): Add USE_THREAD_DB.
20351 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
20352 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
20353 * aclocal.m4: Regenerated.
20354 * config.in: Regenerated.
20355 * configure: Regenerated.
20356 * configure.in: Check for proc_service.h, sys/procfs.h,
20357 thread_db.h, and linux/elf.h headrs.
20358 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
20359 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
20360 Check for -lthread_db and thread support.
20361 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
20362 PowerPC, and SuperH.
20363 * i387-fp.c: Constify arguments.
20364 * i387-fp.h: Likewise.
20365 * inferiors.c: (struct thread_info): Renamed from
20366 `struct inferior_info'. Remove PID member. Use generic inferior
20367 list header. All uses updated.
20368 (inferiors, signal_pid): Removed.
20369 (all_threads): New variable.
20370 (get_thread): Define.
20371 (add_inferior_to_list): New function.
20372 (for_each_inferior): New function.
20373 (change_inferior_id): New function.
20374 (add_inferior): Removed.
20375 (remove_inferior): New function.
20376 (add_thread): New function.
20377 (free_one_thread): New function.
20378 (remove_thread): New function.
20379 (clear_inferiors): Use for_each_inferior and free_one_thread.
20380 (find_inferior): New function.
20381 (find_inferior_id): New function.
20382 (inferior_target_data): Update argument type.
20383 (set_inferior_target_data): Likewise.
20384 (inferior_regcache_data): Likewise.
20385 (set_inferior_regcache_data): Likewise.
20386 * linux-low.c (linux_bp_reinsert): Remove.
20387 (all_processes, stopping_threads, using_thrads)
20388 (struct pending_signals, debug_threads, pid_of): New.
20389 (inferior_pid): Replace with macro.
20390 (struct inferior_linux_data): Remove.
20391 (get_stop_pc, add_process): New functions.
20392 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
20393 Use add_process and add_thread.
20394 (linux_attach_lwp): New function, based on old linux_attach. Use
20395 add_process and add_thread. Set stop_expected for new threads.
20396 (linux_attach): New function.
20397 (linux_kill_one_process): New function.
20398 (linux_kill): Kill all LWPs.
20399 (linux_thread_alive): Use find_inferior_id.
20400 (check_removed_breakpoints, status_pending_p): New functions.
20401 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
20402 Update. Use WNOHANG. Wait for cloned processes also. Update process
20403 struct for the found process.
20404 (linux_wait_for_event): New function.
20405 (linux_wait): Use it. Support LWPs.
20406 (send_sigstop, wait_for_sigstop, stop_all_processes)
20407 (linux_resume_one_process, linux_continue_one_process): New functions.
20408 (linux_resume): Support LWPs.
20409 (REGISTER_RAW_SIZE): Remove.
20410 (fetch_register): Use register_size instead. Call supply_register.
20411 (usr_store_inferior_registers): Likewise. Call collect_register.
20412 Fix recursive case.
20413 (regsets_fetch_inferior_registers): Improve error message.
20414 (regsets_store_inferior_registers): Add debugging.
20415 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
20416 (unstopped_p, linux_signal_pid): New functions.
20417 (linux_target_ops): Add linux_signal_pid.
20418 (linux_init_signals): New function.
20419 (initialize_low): Call it. Initialize using_threads.
20420 * regcache.c (inferior_regcache_data): Add valid
20422 (get_regcache): Fetch registers lazily. Add fetch argument
20423 and update all callers.
20424 (regcache_invalidate_one, regcache_invalidate): New
20426 (new_register_cache): Renamed from create_register_cache.
20427 Return the new regcache.
20428 (free_register_cache): Change argument to a void *.
20429 (registers_to_string, registers_from_string): Call get_regcache
20430 with fetch flag set.
20431 (register_data): Make static. Pass fetch flag to get_regcache.
20432 (supply_register): Call get_regcache with fetch flag clear.
20433 (collect_register): Call get_regcache with fetch flag set.
20434 (collect_register_as_string): New function.
20435 * regcache.h: Update.
20436 * remote-utils.c (putpkt): Flush after debug output and use
20438 Handle input interrupts while waiting for an ACK.
20439 (input_interrupt): Use signal_pid method.
20440 (getpkt): Flush after debug output and use stderr.
20441 (outreg): Use collect_register_as_string.
20442 (new_thread_notify, dead_thread_notify): New functions.
20443 (prepare_resume_reply): Check using_threads. Set thread_from_wait
20444 and general_thread.
20445 (look_up_one_symbol): Flush after debug output.
20446 * server.c (step_thread, server_waiting): New variables.
20447 (start_inferior): Don't use signal_pid. Update call to mywait.
20448 (attach_inferior): Update call to mywait.
20449 (handle_query): Handle qfThreadInfo and qsThreadInfo.
20450 (main): Don't fetch/store registers explicitly. Use
20451 set_desired_inferior. Support proposed ``Hs'' packet. Update
20453 * server.h: Update.
20454 (struct inferior_list, struct_inferior_list_entry): New.
20455 * target.c (set_desired_inferior): New.
20456 (write_inferior_memory): Constify.
20457 (mywait): New function.
20458 * target.h: Update.
20459 (struct target_ops): New signal_pid method.
20460 (mywait): Removed macro, added prototype.
20462 * linux-low.h (regset_func): Removed.
20463 (regset_fill_func, regset_store_func): New.
20464 (enum regset_type): New.
20465 (struct regset_info): Add type field. Use new operation types.
20466 (struct linux_target_ops): stop_pc renamed to get_pc.
20467 Add decr_pc_after_break and breakpoint_at.
20468 (get_process, get_thread_proess, get_process_thread)
20469 (strut process_info, all_processes, linux_attach_lwp)
20470 (thread_db_init): New.
20472 * linux-arm-low.c (arm_get_pc, arm_set_pc,
20473 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
20474 (the_low_target): Add new members.
20475 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
20476 (i386_store_fpxregset): Constify.
20477 (target_regsets): Add new kind identifier.
20478 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
20479 (i386_set_pc): Add debugging.
20480 (i386_breakpoint_at): New function.
20481 (the_low_target): Add new members.
20482 * linux-mips-low.c (mips_get_pc, mips_set_pc)
20483 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
20484 (mips_breakpoint_at): New.
20485 (the_low_target): Add new members.
20486 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
20487 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
20488 (the_low_target): Add new members.
20489 * linux-sh-low.c (sh_get_pc, sh_set_pc)
20490 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
20491 (the_low_target): Add new members.
20492 * linux-x86-64-low.c (target_regsets): Add new kind
20495 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
20497 From Martin Pool <mbp@samba.org>:
20498 * server.c (gdbserver_usage): New function.
20501 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
20503 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
20504 stop_at -> stop_pc.
20506 2002-05-04 Andrew Cagney <ac131313@redhat.com>
20508 * Makefile.in: Remove obsolete code.
20510 2002-04-24 Michal Ludvig <mludvig@suse.cz>
20512 * linux-low.c (regsets_fetch_inferior_registers),
20513 (regsets_store_inferior_registers): Removed cast to int from
20515 * regcache.h: Added declaration of struct inferior_info.
20517 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
20519 * inferiors.c (struct inferior_info): Add regcache_data.
20520 (add_inferior): Call create_register_cache.
20521 (clear_inferiors): Call free_register_cache.
20522 (inferior_regcache_data, set_inferior_regcache_data): New functions.
20523 * regcache.c (struct inferior_regcache_data): New.
20524 (registers): Remove.
20525 (get_regcache): New function.
20526 (create_register_cache, free_register_cache): New functions.
20527 (set_register_cache): Don't initialize the register cache here.
20528 (registers_to_string, registers_from_string, register_data): Call
20530 * regcache.h: Add prototypes.
20531 * server.h: Likewise.
20533 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
20535 * mem-break.c: New file.
20536 * mem-break.h: New file.
20537 * Makefile.in: Add mem-break.o rule; update server.h
20539 * inferiors.c (struct inferior_info): Add target_data
20541 (clear_inferiors): Free target_data member if set.
20542 (inferior_target_data, set_inferior_target_data): New functions.
20543 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
20544 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
20545 * linux-low.c (linux_bp_reinsert): New variable.
20546 (struct inferior_linux_data): New.
20547 (linux_create_inferior): Use set_inferior_target_data.
20548 (linux_attach): Likewise. Call add_inferior.
20549 (linux_wait_for_one_inferior): New function.
20550 (linux_wait): Call it.
20551 (linux_write_memory): Add const.
20552 (initialize_low): Call set_breakpoint_data.
20553 * linux-low.h (struct linux_target_ops): Add breakpoint
20555 * server.c (attach_inferior): Remove extra add_inferior
20557 * server.h: Include mem-break.h. Update inferior.c
20559 * target.c (read_inferior_memory)
20560 (write_inferior_memory): New functions.
20561 * target.h (read_inferior_memory)
20562 (write_inferior_memory): Change macros to prototypes.
20563 (struct target_ops): Update comments. Add const to write_memory
20566 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
20568 * linux-low.c (usr_store_inferior_registers): Support
20569 registers which are allowed to fail to store.
20570 * linux-low.h (linux_target_ops): Likewise.
20571 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
20572 (ppc_cannot_store_register): FPSCR may not be storable.
20574 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
20576 * server.h: Include <string.h> if HAVE_STRING_H.
20577 * ChangeLog: Correct paths in last ChangeLog entry.
20579 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
20581 * linux-low.h: Remove obsolete prototypes.
20582 (struct linux_target_ops): New.
20583 (extern the_low_target): New.
20584 * linux-low.c (num_regs, regmap): Remove declarations.
20585 (register_addr): Use the_low_target explicitly.
20586 (fetch_register): Likewise.
20587 (usr_fetch_inferior_registers): Likewise.
20588 (usr_store_inferior_registers): Likewise.
20589 * linux-arm-low.c (num_regs): Remove.
20590 (arm_num_regs): Define.
20591 (arm_regmap): Renamed from regmap, made static.
20592 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
20594 (arm_cannot_store_register): Renamed from cannot_store_register,
20596 (the_low_target): New.
20597 * linux-i386-low.c (num_regs): Remove.
20598 (i386_num_regs): Define.
20599 (i386_regmap): Renamed from regmap, made static.
20600 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
20602 (i386_cannot_store_register): Renamed from cannot_store_register,
20604 (the_low_target): New.
20605 * linux-ia64-low.c (num_regs): Remove.
20606 (ia64_num_regs): Define.
20607 (ia64_regmap): Renamed from regmap, made static.
20608 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
20610 (ia64_cannot_store_register): Renamed from cannot_store_register,
20612 (the_low_target): New.
20613 * linux-m68k-low.c (num_regs): Remove.
20614 (m68k_num_regs): Define.
20615 (m68k_regmap): Renamed from regmap, made static.
20616 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
20618 (m68k_cannot_store_register): Renamed from cannot_store_register,
20620 (the_low_target): New.
20621 * linux-mips-low.c (num_regs): Remove.
20622 (mips_num_regs): Define.
20623 (mips_regmap): Renamed from regmap, made static.
20624 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
20626 (mips_cannot_store_register): Renamed from cannot_store_register,
20628 (the_low_target): New.
20629 * linux-ppc-low.c (num_regs): Remove.
20630 (ppc_num_regs): Define.
20631 (ppc_regmap): Renamed from regmap, made static.
20632 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
20634 (ppc_cannot_store_register): Renamed from cannot_store_register,
20636 (the_low_target): New.
20637 * linux-s390-low.c (num_regs): Remove.
20638 (s390_num_regs): Define.
20639 (s390_regmap): Renamed from regmap, made static.
20640 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
20642 (s390_cannot_store_register): Renamed from cannot_store_register,
20644 (the_low_target): New.
20645 * linux-sh-low.c (num_regs): Remove.
20646 (sh_num_regs): Define.
20647 (sh_regmap): Renamed from regmap, made static.
20648 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
20650 (sh_cannot_store_register): Renamed from cannot_store_register,
20652 (the_low_target): New.
20653 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
20654 (the_low_target): New.
20656 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
20658 * Makefile.in: Add stamp-h target.
20659 * configure.in: Create stamp-h.
20660 * configure: Regenerated.
20662 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
20664 * inferiors.c: New file.
20665 * target.c: New file.
20666 * target.h: New file.
20667 * Makefile.in: Add target.o and inferiors.o. Update
20669 * linux-low.c (inferior_pid): New static variable,
20670 moved from server.c.
20671 (linux_create_inferior): Renamed from create_inferior.
20672 Call add_inferior. Return 0 on success instead of a PID.
20673 (linux_attach): Renamed from myattach.
20674 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
20675 (linux_thread_alive): Renamed from mythread_alive.
20676 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
20678 (linux_resume): Renamed from myresume. Add missing ``return 0''.
20679 (regsets_store_inferior_registers): Correct error message.
20680 Add missing ``return 0''.
20681 (linux_fetch_registers): Renamed from fetch_inferior_registers.
20682 (linux_store_registers): Renamed from store_inferior_registers.
20683 (linux_read_memory): Renamed from read_inferior_memory.
20684 (linux_write_memory): Renamed from write_inferior_memory.
20685 (linux_target_ops): New structure.
20686 (initialize_low): Call set_target_ops ().
20687 * remote-utils.c (unhexify): New function.
20688 (hexify): New function.
20689 (input_interrupt): Send signals to ``signal_pid''.
20690 * server.c (inferior_pid): Remove.
20691 (start_inferior): Update create_inferior call.
20692 (attach_inferior): Call add_inferior.
20693 (handle_query): New function.
20694 (main): Call handle_query for `q' packets.
20695 * server.h: Include "target.h". Remove obsolete prototypes.
20696 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
20698 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
20700 * Makefile.in: Add WARN_CFLAGS. Update configury
20702 * configure.in: Check for <string.h>
20703 * configure: Regenerate.
20704 * config.in: Regenerate.
20705 * gdbreplay.c: Include needed system headers.
20706 (remote_open): Remove strchr prototype.
20707 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
20708 * regcache.c (supply_register): Change buf argument to const void *.
20709 (supply_register_by_name): Likewise.
20710 (collect_register): Change buf argument to void *.
20711 (collect_register_by_name): Likewise.
20712 * regcache.h: Add missing prototypes.
20713 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
20714 * server.c (handle_query): New function.
20715 (attached): New static variable, moved out of main.
20716 (main): Quiet longjmp clobber warnings.
20717 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
20718 * utils.c (error): Remove NORETURN.